/* Scoped to III-25. Other form assets and output remain byte-identical. */
html[data-id="annex-III-25"] main { display: block; max-width: 1200px; }
html[data-id="annex-III-25"] { scroll-padding-top: 0; }
.vat-declaration { max-width: 1200px; width: 100%; min-width: 0; padding-top: 0; }
.vat-declaration *, .vat-popup * { box-sizing: border-box; }
.vat-banner { position: sticky; top: calc(var(--bar-h) + var(--sat)); z-index: 12; margin: 0; padding: 12px 16px; border: 1px solid var(--accent); border-radius: 10px; background: var(--accent-soft); color: var(--ink); font-size: .86rem; font-weight: 700; }
.vat-title { padding-top: 12px; }
.vat-declaration .vat-step, .vat-declaration [id], .vat-declaration [data-vat-row], .vat-declaration h2, .vat-declaration h3, .vat-title, .vat-view-switch { scroll-margin-top: calc(var(--bar-h) + var(--sat) + var(--vat-banner-height, 90px)); }
.vat-title h1 { font-size: clamp(1.25rem, 3vw, 1.9rem); }
.vat-view-switch { display: flex; gap: 8px; flex-wrap: wrap; }
.vat-view-switch button { min-height: 44px; padding: 10px 16px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 8px; font: inherit; cursor: pointer; }
.vat-view-switch [aria-pressed="true"] { background: var(--navy); color: #fff; }
.vat-image-frame { width: 100%; max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; }
.vat-image { position: relative; width: 100%; }
.vat-image img { display: block; width: 100%; height: auto; }
.vat-hotspot { position: absolute; left: 0; width: 100%; min-height: 0; padding: 0; border: 0; border-radius: 0; background: transparent; cursor: help; }
.vat-hotspot:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; background: #e2093514; }
.vat-hotspot-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
@media (hover:hover) and (pointer:fine) { .vat-hotspot:hover { background: #131c3e12; box-shadow: inset 0 0 0 1px #131c3e40; } }
.vat-caption { font-size: .75rem; color: var(--ink-2); line-height: 1.6; }
.vat-portal-text { width: 100%; border-collapse: collapse; }
.vat-portal-text td { padding: 12px; border: 1px solid var(--line); }
.vat-steps ol { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.vat-steps li { flex: 1 1 96px; min-width: 0; }
.vat-steps a { display: flex; align-items: center; gap: 8px; padding: 8px; min-height: 44px; height: 100%; font-size: .74rem; line-height: 1.4; border: 1px solid var(--line); border-radius: 8px; text-decoration: none; background: var(--surface); overflow-wrap: anywhere; }
.vat-step-number { display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; width: 28px; height: 28px; flex: 0 0 28px; font-weight: 700; }
.vat-steps [aria-current="step"] { border-color: var(--accent); background: var(--accent-soft); }
.vat-steps [aria-current="step"] .vat-step-number { background: var(--accent); color: #fff; border-color: var(--accent); }
.vat-part-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--navy); color: #fff; border-radius: 10px 10px 0 0; padding: 12px 16px; margin-top: 24px; }
.vat-part-header h2 { margin: 0; font-size: 1rem; overflow-wrap: anywhere; }
.vat-part-header a { color: #fff; display: grid; place-items: center; width: 44px; height: 44px; flex: 0 0 44px; border: 1px solid currentColor; border-radius: 50%; text-decoration: none; }
.vat-sheet { min-width: 0; max-width: 100%; }
.vat-grid { max-width: 100%; min-width: 0; overflow-x: auto; overscroll-behavior-x: contain; background: var(--surface); }
.vat-source-table { border-collapse: collapse; width: 100%; min-width: 680px; font-size: .82rem; line-height: 1.5; }
.vat-source-table td { border: 1px solid var(--line); padding: 6px; vertical-align: middle; overflow-wrap: anywhere; }
.vat-source-table tr:has([data-vat-source-text]) { min-height: 44px; }
/* The owner's e-form layout is label | help | line | values. Source column
   numbers stay in the DOM for fidelity, but are not extra data rows on screen. */
.vat-operation-table [data-vat-column-numbers] { display: none; }
.vat-source-table a { color: var(--ink); text-decoration: none; display: flex; align-items: center; gap: 6px; min-height: 44px; }
.vat-source-table [data-vat-row] { cursor: pointer; }
.vat-source-table [data-vat-row]:hover, .vat-source-table [aria-expanded="true"] { background: var(--accent-soft); }
.vat-question { display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; min-width: 28px; height: 28px; margin-left: auto; color: var(--link); }
.vat-value-box { display: block; height: 34px; min-width: 20px; width: 100%; border: 1px solid var(--ink-3); border-radius: 4px; background: var(--bg); box-shadow: inset 0 1px 2px #131c3e0d; }
.vat-value-trigger { min-width: 74px; }
.vat-total { background: var(--line-2); font-weight: 700; }
.vat-nested-table { width: 100%; border-collapse: collapse; }
.vat-nested-table td { border: 0; }
.vat-fallback details { padding: 10px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.vat-hint-copy blockquote { margin: 12px 0; padding-left: 12px; border-left: 3px solid var(--line); }
.vat-hint-copy figure { margin: 12px 0; }
.vat-hint-copy figcaption { font-weight: 700; }
.vat-source-note { padding: 12px; background: var(--mark); color: var(--ink); border-radius: 8px; }
.vat-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 16px 0; }
.vat-actions p { margin: 0 auto 0 0; }
.vat-actions button, .vat-popup button { min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; }
.vat-actions [data-vat-next] { background: var(--accent); color: #fff; }
.vat-actions button:disabled { opacity: .45; cursor: default; }
.vat-declaration [hidden] { display: none !important; }
.vat-popup { position: fixed; z-index: 80; width: min(520px, calc(100vw - 32px)); max-height: 45vh; overflow-y: auto; overscroll-behavior: contain; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); box-shadow: var(--shadow); font-size: .88rem; overflow-wrap: anywhere; }
.vat-popup h2 { font-size: 1rem; margin-top: 14px; }
.vat-popup h3 { font-size: .94rem; }
.vat-popup [data-vat-close] { display: block; margin-left: auto; }
.vat-example { padding: 12px; border-radius: 8px; background: var(--bg); }
.vat-declaration :focus-visible { outline: 3px solid var(--link); outline-offset: 3px; }
@media (max-width: 640px) {
  .vat-declaration { width: 100%; max-width: 100%; min-width: 0; padding-inline: 12px; }
  .vat-grid { max-width: 100%; overflow-x: auto; }
  .vat-image { min-width: 1000px; }
  .vat-steps li { flex-basis: calc(50% - 8px); }
  .vat-enhanced .vat-steps li { flex: 1 1 calc((100% - 40px) / 6); }
  .vat-enhanced .vat-steps a { padding: 4px 2px; flex-direction: column; gap: 3px; text-align: center; font-size: .68rem; }
  .vat-enhanced .vat-steps a > span:last-child { white-space: nowrap; overflow-wrap: normal; }
  .vat-banner { font-size: .75rem; }
  .vat-part-header { padding: 10px; }
  .vat-operation-table { min-width: 0; }
  .vat-operation-table tbody { display: block; }
  .vat-operation-table [data-vat-table-header] { display: none; }
  .vat-operation-table tr[data-vat-row] { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 2px solid var(--line); }
  .vat-operation-table [data-vat-field="label"] { grid-column: 1 / 3; }
  .vat-operation-table [data-vat-field="number"] { grid-column: 3; text-align: right; }
  .vat-operation-table [data-vat-field="amount"]::before { content: attr(data-vat-column); display: block; font-size: .65rem; line-height: 1.4; margin-bottom: 6px; }
  .vat-operation-table .vat-value-trigger { min-width: 0; }
  .vat-popup { left: 0 !important; right: 0; top: auto !important; bottom: 0; width: 100%; max-width: 100%; max-height: 70vh; padding: 16px 16px calc(16px + var(--sab)); border-radius: 16px 16px 0 0; }
}
@media print {
  .vat-declaration { max-width: none; width: 100%; padding: 0; }
  .vat-declaration .vat-step[hidden] { display: block !important; }
  .vat-declaration [data-vat-text][hidden] { display: block !important; }
  .vat-declaration [data-vat-screenshot], .vat-view-switch { display: none !important; }
  .vat-step { break-before: page; }
  .vat-step:first-of-type { break-before: auto; }
  .vat-grid { overflow: visible; }
  .vat-source-table { min-width: 0; width: 100%; font-size: 8pt; }
  .vat-value-trigger { min-width: 0; }
  .vat-value-box { min-width: 0; }
  .vat-source-table a { min-height: 0; }
  .vat-banner { position: static; }
  .vat-declaration .vat-steps, .vat-declaration .vat-actions, .vat-declaration .vat-popup, .vat-declaration .vat-fallback, .vat-question, .vat-part-help { display: none !important; }
  .vat-part-header { background: white; color: black; border: 1px solid; }
}
