/* ==========================================================================
   IRD360 public request site: the shell (templates/public_base.html) and the
   pages citizens and outside recipients use without an account.

   Loaded after ird.css, so it uses the same tokens, type and components
   (.ird-panel, .ird-btn, .ird-input, .ird-alert, .ird-tile, .ird-pill,
   .ird-ctab, .ird-kv, .ird-seg, .ird-commit). The site is the staff app's
   light world made public: a white header with the Branding logo, the soft
   grey ground, white 16px cards, an area tile beside every title (plum for
   requesting and tracking, green for verifying and receiving a copy, teal for
   memo acknowledgements: body[data-area] and --page-icon), numbered steps, and
   a status card that answers a lookup in a word, an icon tile and a reason.
   ========================================================================== */

/* ------------------------------------------------------------- shell --- */
body.ird-pub { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--ground); }

/* The header: white, a hairline, the logo and the office's name on the left,
   the site's two places on the right. */
.ird-pub-bar { background: var(--surface); border-bottom: 1px solid var(--rule); box-shadow: 0 1px 2px rgb(22 30 84 / 0.04); }
body[data-color-mode="contrast"] .ird-pub-bar { border-bottom: 2px solid #000; box-shadow: none; }
.ird-pub-bar__inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-3) var(--s-6);
  max-width: 1120px; margin: 0 auto; padding: 12px var(--s-6);
}
.ird-pub-brand {
  display: flex; align-items: center; gap: 12px; min-width: 0; min-height: 48px;
  color: var(--ink); text-decoration: none; border-radius: var(--r-md);
}
.ird-pub-brand .ird-rail__logo { flex: none; }
.ird-pub-brand .ird-rail__logo img { height: 44px; max-width: 120px; }
.ird-pub-brand .ird-rail__initials {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; flex: none;
  background: var(--navy); color: var(--on-navy); font-weight: 700; font-size: 14px;
}
.ird-pub-brand__text { display: flex; flex-direction: column; min-width: 0; }
.ird-pub-brand__name { font-size: 1.125rem; font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; color: var(--ink); overflow-wrap: anywhere; }
.ird-pub-brand__tagline { font-size: 12.5px; line-height: 1.3; color: var(--ink-3); overflow-wrap: anywhere; }
/* The full logo from Branding, when set, carries the name: it stands in for
   the mark and the name. Dark mode with no dark full logo: a white plate. */
.ird-pub-brand__wide { display: flex; align-items: center; flex: none; }
.ird-pub-brand__wide img { height: 56px; width: auto; }
html.dark .ird-pub-brand__wide img:only-child { background: #fff; border-radius: var(--r-md); padding: 4px 8px; }
.ird-pub-brand:focus-visible, .ird-pub-nav a:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Where you are: the current place is solid brand, as the staff menu's
   current item; the other is a quiet link with its area-coloured icon. */
.ird-pub-nav { display: flex; gap: 6px; padding: 4px; border-radius: 14px; background: var(--surface-sunk); border: 1px solid var(--rule); }
.ird-pub-nav a {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px;
  border-radius: 10px; color: var(--ink-2); font-size: var(--text-sm); font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: background-color var(--t-fast) ease, color var(--t-fast) ease, box-shadow var(--t-fast) ease;
}
.ird-pub-nav a .material-symbols-outlined { font-size: 20px; color: var(--hue-ink, var(--area-ink)); }
.ird-pub-nav a:hover { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-1); }
.ird-pub-nav a[aria-current="page"] { background: var(--navy); color: var(--on-navy); box-shadow: var(--shadow-1); }
.ird-pub-nav a[aria-current="page"] .material-symbols-outlined { color: inherit; font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24; }
body[data-color-mode="contrast"] .ird-pub-nav { border: 2px solid #000; background: #fff; }
body[data-color-mode="contrast"] .ird-pub-nav a { color: #000; }
body[data-color-mode="contrast"] .ird-pub-nav a[aria-current="page"] { background: #000; color: #fff; }

@media (max-width: 719.98px) {
  .ird-pub-bar__inner { padding: 10px var(--s-4) 12px; }
  .ird-pub-brand .ird-rail__logo img { height: 38px; max-width: 96px; }
  .ird-pub-brand .ird-rail__initials { width: 38px; height: 38px; }
  .ird-pub-brand__wide img { height: 48px; }
  .ird-pub-brand__name { font-size: var(--text-md); }
  /* The two places share the width under the name: no menu to open. */
  .ird-pub-nav { width: 100%; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ird-pub-nav a { padding: 0 8px; white-space: normal; text-align: center; line-height: 1.2; }
}

.ird-pub-main { flex: 1 0 auto; }
/* One task per page, in one column. Forms read at 46rem; the tracking page
   is wider for its two columns. */
.ird-pub-page { max-width: 48rem; margin: 0 auto; padding: var(--s-8) var(--s-6) var(--s-10); }
.ird-pub-page--wide { max-width: 72rem; }
.ird-pub-page--narrow { max-width: 36rem; }
@media (max-width: 639.98px) { .ird-pub-page { padding: var(--s-5) var(--s-4) var(--s-8); } }
.ird-pub-messages { max-width: 48rem; margin: var(--s-6) auto 0; padding: 0 var(--s-6); display: grid; gap: var(--s-2); }
@media (max-width: 639.98px) { .ird-pub-messages { margin-top: var(--s-4); padding: 0 var(--s-4); } }
.ird-pub-messages + .ird-pub-main .ird-pub-page { padding-top: var(--s-5); }
.ird-pub-messages .ird-alert p { margin: 0; }

/* The same slim footer as the staff pages: one line, pinned to the bottom of
   the window wider than 640px (sticky, so its line is kept at the end of the
   page and nothing scrolls out from under it), the end of the page on a phone. */
.ird-pub-foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0 var(--s-4);
  margin-top: var(--s-6); padding: var(--s-2) var(--s-4); border-top: 1px solid var(--rule); background: var(--surface);
  font-size: 12px; line-height: 16px; color: var(--ink-3); text-align: center; overflow-wrap: anywhere;
}
.ird-pub-foot p { margin: 0; }
.ird-pub-foot__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 var(--s-4); }
.ird-pub-foot a { color: var(--ink-2); text-decoration: underline; text-underline-offset: 2px; }
.ird-pub-foot a:hover { color: var(--ink); }
body[data-color-mode="contrast"] .ird-pub-foot { border-top: 2px solid #000; color: #000; }
@media (min-width: 640.02px) {
  .ird-pub-foot {
    position: sticky; bottom: 0; z-index: 30; flex-wrap: nowrap; height: 28px; padding: 0 var(--s-4);
    white-space: nowrap; overflow: hidden;
  }
  .ird-pub-foot > * { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .ird-pub-foot__links { flex-wrap: nowrap; }
  .ird-pub-foot a { display: inline-flex; align-items: center; min-height: 24px; }
}
@media (max-width: 640px) {
  .ird-pub-foot a { display: inline-flex; align-items: center; min-height: 44px; }
}

/* ------------------------------------------------------- page head --- */
/* The title with its area tile, as every staff page has: the tile spans the
   title and its line of explanation. */
.ird-pub-head { margin-bottom: var(--s-6); }
.ird-pub-head:has(> .ird-h1) { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 16px; align-items: center; }
.ird-pub-head:has(> .ird-h1)::before {
  content: var(--page-icon) / ""; grid-row: span 2; align-self: start;
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px;
  background: var(--area-tint); color: var(--area-ink);
  font-family: "Material Symbols Outlined"; font-size: 28px; line-height: 1; font-weight: normal; font-style: normal;
  letter-spacing: normal; text-transform: none; white-space: nowrap; direction: ltr; overflow: hidden;
  font-feature-settings: "liga"; -webkit-font-feature-settings: "liga";
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}
.ird-pub-head:has(> .ird-h1) > * { grid-column: 2; }
.ird-pub-head:has(> .ird-h1):not(:has(> .ird-pub-lede))::before { grid-row: span 1; align-self: center; }
body[data-color-mode="contrast"] .ird-pub-head:has(> .ird-h1)::before { border: 2px solid #000; }
@media (max-width: 639.98px) {
  .ird-pub-head:has(> .ird-h1) { column-gap: 12px; }
  .ird-pub-head:has(> .ird-h1)::before { width: 44px; height: 44px; border-radius: 13px; font-size: 24px; }
}
.ird-pub-head .ird-h1 { margin: 0; font-size: 1.75rem; letter-spacing: -0.02em; }
@media (max-width: 639.98px) { .ird-pub-head .ird-h1 { font-size: 1.4375rem; } }
.ird-pub-lede { margin: 6px 0 0; max-width: 62ch; color: var(--ink-3); font-size: var(--text-base); line-height: 1.55; }
.ird-pub-lede strong { color: var(--ink); overflow-wrap: anywhere; }
/* A result head that also holds the page title above it (Verify a document). */
.ird-pub-head > .ird-pub-result { grid-column: 1 / -1; }

/* ------------------------------------------------------ the steps --- */
/* Where the visitor is: three numbered dots on a line in a white card. A
   step behind is a green tick, the current one is solid brand, the next ones
   are outlined; a stage that waits on the visitor is orange, one where the
   request stopped is red. Words say each state too. */
.ird-pub-steps {
  margin: 0 0 var(--s-5); padding: 14px 20px 16px;
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-lg); box-shadow: var(--shadow-1);
}
body[data-color-mode="contrast"] .ird-pub-steps { border: 2px solid #000; }
.ird-pub-steps__count { display: block; margin-bottom: 10px; font-size: var(--text-xs); font-weight: 700; color: var(--area-ink); font-variant-numeric: tabular-nums; }
.ird-pub-stepper { display: flex; margin: 0; padding: 0; list-style: none; }
.ird-pub-stepper > li { position: relative; flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
/* The line from this step to the one before it. */
.ird-pub-stepper > li + li::before {
  content: ""; position: absolute; top: 15px; right: calc(50% + 22px); left: calc(-50% + 22px); height: 2px; border-radius: 2px;
  background: var(--rule-strong);
}
.ird-pub-stepper > li:is([data-state="done"], [data-state="current"], [data-state="blocked"]) + li:not([data-state="upcoming"])::before,
.ird-pub-stepper > li[data-state="done"] + li::before { background: var(--ok); }
.ird-pub-stepper__dot {
  position: relative; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; flex: none;
  background: var(--surface); border: 2px solid var(--control-border); color: var(--ink-3);
  font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1;
}
.ird-pub-stepper__dot .material-symbols-outlined { font-size: 18px; font-variation-settings: "FILL" 0, "wght" 700, "GRAD" 0, "opsz" 20; }
.ird-pub-stepper__name { font-size: var(--text-sm); font-weight: 500; color: var(--ink-3); line-height: 1.25; overflow-wrap: anywhere; }
.ird-pub-stepper > li[data-state="done"] .ird-pub-stepper__dot { background: var(--ok); border-color: var(--ok); color: var(--surface); }
.ird-pub-stepper > li[data-state="done"] .ird-pub-stepper__name { color: var(--ink-2); }
.ird-pub-stepper > li[data-state="current"] .ird-pub-stepper__dot { background: var(--navy); border-color: var(--navy); color: var(--on-navy); box-shadow: 0 0 0 4px var(--navy-100); }
.ird-pub-stepper > li[data-state="current"] .ird-pub-stepper__name { color: var(--ink); font-weight: 700; }
.ird-pub-stepper > li.is-mine .ird-pub-stepper__dot { background: var(--act); border-color: var(--act); color: #2b1600; box-shadow: 0 0 0 4px var(--act-50); }
.ird-pub-stepper > li.is-mine .ird-pub-stepper__name { color: var(--act-ink); }
.ird-pub-stepper > li[data-state="blocked"] .ird-pub-stepper__dot { background: var(--danger); border-color: var(--danger); color: var(--on-danger); }
html.dark .ird-pub-stepper > li[data-state="blocked"] .ird-pub-stepper__dot { color: #2a0b08; }
.ird-pub-stepper > li[data-state="blocked"] .ird-pub-stepper__name { color: var(--danger); font-weight: 700; }
html.dark .ird-pub-stepper > li[data-state="done"] .ird-pub-stepper__dot { color: #0d1029; }
body[data-color-mode="contrast"] .ird-pub-stepper__dot { border-color: #000; color: #000; }
body[data-color-mode="contrast"] .ird-pub-stepper > li:is([data-state="done"], [data-state="current"], [data-state="blocked"]) .ird-pub-stepper__dot,
body[data-color-mode="contrast"] .ird-pub-stepper > li.is-mine .ird-pub-stepper__dot { background: #000; border-color: #000; color: #fff; box-shadow: none; }
body[data-color-mode="contrast"] .ird-pub-stepper > li[data-state="current"] .ird-pub-stepper__name { text-decoration: underline; text-underline-offset: 3px; }
body[data-color-mode="contrast"] .ird-pub-stepper > li + li::before { background: #000; }
/* Inside the tracking card: the same dots, left aligned in the card. */
.ird-pub-stepper--track { margin-top: var(--s-4); padding: 14px 4px 12px; border-radius: var(--r-ctl); background: var(--surface-2); border: 1px solid var(--rule); }
@media (max-width: 379.98px) { .ird-pub-stepper__name { font-size: var(--text-xs); } }

/* ------------------------------------------------------- form layout --- */
.ird-pub-panel { padding: 24px; }
@media (max-width: 479.98px) { .ird-pub-panel { padding: 18px 16px; } }
.ird-pub-panel > * + * { margin-top: var(--s-3); }
.ird-pub-panel.ird-pub-form > * + * { margin-top: 0; }
.ird-pub-panel > .ird-kv:first-child + * { margin-top: var(--s-5); }
.ird-pub-panel .ird-h-tile { margin-bottom: var(--s-1); }
.ird-pub-panel > .ird-h2.ird-h-tile, .ird-pub-panel > .ird-h2 { font-size: var(--text-lg); }
.ird-pub-form { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-6); }
.ird-pub-section { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-4); min-width: 0; }
.ird-pub-section + .ird-pub-section { padding-top: var(--s-6); border-top: 1px solid var(--rule); }
.ird-pub-section__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px var(--s-3); }
.ird-pub-section__head .ird-h2 { font-size: var(--text-lg); }
.ird-pub-section__head p { margin: 0; font-size: var(--text-sm); color: var(--ink-3); }
.ird-pub-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-4) var(--s-5); }
@media (min-width: 640px) {
  .ird-pub-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ird-pub-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.ird-pub-grid > * { min-width: 0; }
.ird-pub .ird-label { line-height: 1.3; font-weight: 600; }
.ird-pub-opt { font-weight: 400; color: var(--ink-3); }
.ird-pub .ird-hint { line-height: 1.4; color: var(--ink-3); }
/* Large fields: 48px tall, 16px text, so a phone does not zoom on focus. */
.ird-pub :is(.ird-input, .ird-select):not(textarea) { min-height: 48px; }
.ird-pub :is(.ird-input, .ird-select) { font-size: 16px; border-radius: var(--r-ctl); }
.ird-pub .ird-select:disabled { background-color: var(--surface-sunk); color: var(--ink-2); opacity: 1; }
/* An error sits right under its field, in a tinted line that says how to fix it. */
.ird-pub .ird-field-error { padding: 6px 10px; border-radius: 8px; background: var(--danger-soft); font-size: var(--text-sm); }
body[data-color-mode="contrast"] .ird-pub .ird-field-error { border: 1px solid #000; }
/* A number with a fixed country code in front of it. */
.ird-pub-prefixed { display: flex; min-width: 0; }
.ird-pub-prefixed__code {
  display: inline-flex; align-items: center; padding: 0 var(--s-3); flex: none;
  border: 1px solid var(--control-border); border-right: 0; border-radius: var(--r-ctl) 0 0 var(--r-ctl);
  background: var(--surface-sunk); color: var(--ink-2); font-weight: 700; font-variant-numeric: tabular-nums;
}
.ird-pub-prefixed .ird-input { border-radius: 0 var(--r-ctl) var(--r-ctl) 0; min-width: 0; }
.ird-pub-code-input { font-family: var(--font-mono); font-size: 1.75rem !important; font-weight: 700; letter-spacing: 0.4em; text-align: center; min-height: 64px !important; font-variant-numeric: tabular-nums; }

/* Choice cards: a radio with its words, the whole card the target. The
   chosen card takes the brand edge and a brand tint, as a selected place does. */
.ird-pub-choices { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@media (min-width: 640px) { .ird-pub-choices--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* Copy type: three short cards side by side once they fit. */
@media (min-width: 900px) { .ird-pub-choices--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ird-pub-choice {
  display: flex; align-items: flex-start; gap: var(--s-3); min-width: 0; min-height: 52px; padding: 14px 16px;
  background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--r-ctl);
  cursor: pointer; transition: border-color var(--t-fast) ease, box-shadow var(--t-fast) ease, background-color var(--t-fast) ease;
}
.ird-pub-choice:hover { border-color: var(--control-border); background: var(--surface-hover); box-shadow: var(--shadow-1); }
.ird-pub-choice:has(> input:checked), .ird-pub-choice:has(> .ird-pub-choice__radio > input:checked) {
  border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy), var(--shadow-1); background: var(--navy-50);
}
.ird-pub-choice:has(input:disabled) { cursor: not-allowed; }
.ird-pub-choice:has(input:disabled):hover { border-color: var(--rule-strong); background: var(--surface); box-shadow: none; }
.ird-pub .ird-pub-choice > input[type="radio"], .ird-pub .ird-pub-choice__radio > input[type="radio"] { flex: none; width: 20px; height: 20px; margin-top: 1px; }
.ird-pub-choice__body { min-width: 0; flex: 1 1 auto; }
.ird-pub-choice__title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px var(--s-2); font-weight: 600; color: var(--ink); line-height: 1.35; overflow-wrap: anywhere; }
.ird-pub-choice__text { display: block; margin-top: 2px; font-size: var(--text-sm); color: var(--ink-3); line-height: 1.4; overflow-wrap: anywhere; }
.ird-pub-choice__text:empty { display: none; }
.ird-pub-choice__tag { display: inline-flex; align-items: center; gap: 3px; height: 22px; padding: 0 7px; border-radius: 6px; background: var(--surface-sunk); font-size: 12px; font-weight: 700; color: var(--ink-2); white-space: nowrap; }
.ird-pub-choice__tag .material-symbols-outlined { font-size: 15px; }
/* What the chosen document needs, shown only on the chosen card. */
.ird-pub-choice__more { display: none; margin-top: var(--s-3); gap: var(--s-3); }
.ird-pub-choice:has(input:checked) .ird-pub-choice__more { display: grid; }
.ird-pub-choice__more .ird-label { display: block; margin-bottom: 6px; }
.ird-pub-choice__more .ird-input { background: var(--surface); }
body[data-color-mode="contrast"] .ird-pub-choice { border: 2px solid #000; }
body[data-color-mode="contrast"] .ird-pub-choice:has(input:checked) { box-shadow: inset 0 0 0 2px #000; background: #fff; }
body[data-color-mode="contrast"] .ird-pub-choice:has(input:checked) .ird-pub-choice__title { text-decoration: underline; text-underline-offset: 3px; }

/* The segmented control of ird.css, for a radio group with a label above. */
.ird-pub .ird-seg { display: inline-flex; }
.ird-pub .ird-seg > label { min-width: 5.5rem; min-height: 40px; }
.ird-pub .ird-seg > label:has(input:checked) { color: var(--navy-ink); }
.ird-pub-ok { display: flex; align-items: flex-start; gap: 6px; margin: 0; font-size: var(--text-sm); font-weight: 600; color: var(--ok); }
.ird-pub-ok .material-symbols-outlined { font-size: 18px; flex: none; }

/* Long text the visitor must read before agreeing: a ruled box that scrolls. */
.ird-pub-legal {
  max-height: 15rem; overflow-y: auto; padding: var(--s-4) var(--s-5);
  background: var(--surface-2); border: 1px solid var(--rule); border-radius: var(--r-ctl);
  font-size: var(--text-sm); line-height: 1.6; color: var(--ink); overflow-wrap: anywhere;
}
.ird-pub-legal--short { max-height: 11rem; }
.ird-pub-legal p { margin: 0; }
.ird-pub-legal p + p { margin-top: var(--s-3); }
.ird-pub-legal:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.ird-pub-legal__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px var(--s-3); margin-bottom: var(--s-2); }
.ird-pub-legal__head .ird-h3 { font-size: var(--text-base); }
.ird-pub-legal__head span { font-size: var(--text-xs); color: var(--ink-3); }
/* The agreement tick: a bordered row, so the one thing it commits to is plain. */
.ird-pub-agree { padding: 14px 16px; background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--r-ctl); cursor: pointer; }
.ird-pub-agree:has(input:checked) { border-color: var(--ok); background: var(--ok-soft); }
.ird-pub-agree.ird-checkrow { font-size: var(--text-sm); line-height: 1.5; }
.ird-pub-agree input[type="checkbox"] { width: 20px; height: 20px; }
.ird-pub-agree.g360-invalid { background: var(--danger-soft); border-color: var(--danger); }
body[data-color-mode="contrast"] .ird-pub-agree { border: 2px solid #000; background: #fff; }

/* A second, smaller task under the main one (tracking under the request form). */
.ird-pub-aside { margin-top: var(--s-6); }
.ird-pub-aside > summary { width: 100%; justify-content: space-between; background: var(--surface); border: 1px solid var(--rule); box-shadow: var(--shadow-1); border-radius: var(--r-ctl); min-height: 52px; }
.ird-pub-aside .ird-disclose__panel { max-width: none; margin-top: var(--s-3); padding: var(--s-5); background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-lg); box-shadow: var(--shadow-1); }
.ird-pub-aside__text { font-size: var(--text-sm); color: var(--ink-3); max-width: 62ch; margin-top: 0; }

/* The consequential row is ird.css's .ird-commit; this is its quiet way back. */
.ird-pub .ird-commit .ird-btn--primary { min-height: 52px; font-size: var(--text-md); padding: 0 var(--s-6); }
.ird-pub-back { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 44px; padding: 0 var(--s-3); font-size: var(--text-sm); font-weight: 600; color: var(--ink-2); text-decoration: none; border-radius: var(--r-md); }
.ird-pub-back:hover { color: var(--ink); background: var(--surface-hover); text-decoration: underline; text-underline-offset: 3px; }
.ird-pub-back .material-symbols-outlined { font-size: 18px; }

/* ------------------------------------------------------ result card ---
   The answer of a lookup (verify, track, acknowledge, a dead link): a white
   card with the state's icon tile, the word in the state's ink and the
   reason under it. Never colour alone: the icon and the word say it. */
.ird-pub-result {
  display: flex; align-items: flex-start; gap: 16px; padding: 22px 24px;
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-lg); box-shadow: var(--shadow-2);
}
body[data-color-mode="contrast"] .ird-pub-result { border: 2px solid #000; box-shadow: none; }
.ird-pub-result + * { margin-top: var(--s-5); }
.ird-pub-result__icon {
  display: grid !important; place-items: center; width: 56px; height: 56px; flex: none; border-radius: 16px;
  font-size: 30px !important; background: var(--surface-sunk); color: var(--ink-2);
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24 !important;
}
.ird-pub-result__word { margin: 0; font-size: var(--text-2xl); font-weight: 700; line-height: 1.15; letter-spacing: -0.015em; overflow-wrap: anywhere; text-wrap: balance; color: var(--ink); }
.ird-pub-result__text { margin: 6px 0 0; max-width: 62ch; color: var(--ink-2); line-height: 1.55; }
.ird-pub-result[data-tone="ok"] .ird-pub-result__icon { background: var(--ok-soft); color: var(--ok); }
.ird-pub-result[data-tone="ok"] .ird-pub-result__word { color: var(--ok); }
.ird-pub-result[data-tone="danger"] .ird-pub-result__icon { background: var(--danger-soft); color: var(--danger); }
.ird-pub-result[data-tone="danger"] .ird-pub-result__word { color: var(--danger); }
.ird-pub-result[data-tone="warn"] .ird-pub-result__icon { background: var(--warn-soft); color: var(--warn); }
.ird-pub-result[data-tone="warn"] .ird-pub-result__word { color: var(--warn); }
body[data-color-mode="contrast"] .ird-pub-result__icon { background: #fff !important; color: #000 !important; border: 2px solid #000; }
@media (max-width: 639.98px) {
  .ird-pub-result { gap: 12px; padding: 18px 16px; }
  .ird-pub-result__icon { width: 46px; height: 46px; border-radius: 14px; font-size: 26px !important; }
  .ird-pub-result__word { font-size: var(--text-xl); }
}

/* A record: a white card with its classification chip and reference on top. */
.ird-pub-record { position: relative; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-lg); box-shadow: var(--shadow-1); overflow: hidden; }
body[data-color-mode="contrast"] .ird-pub-record { border: 2px solid #000; }
.ird-pub-record--tab { padding-top: 0 !important; }
.ird-pub .ird-pub-record__tab { display: block; margin: 0 !important; padding: 18px 24px 0 !important; }
.ird-pub-record__body { padding: 16px 24px 22px; }
.ird-pub-record__body > .ird-h2 { font-size: var(--text-lg); margin-bottom: var(--s-2); }
@media (max-width: 479.98px) {
  .ird-pub .ird-pub-record__tab { padding: 16px 16px 0 !important; }
  .ird-pub-record__body { padding: 12px 16px 18px; }
}
.ird-pub-record__title { margin: 8px 0 0; font-size: var(--text-lg); font-weight: 700; line-height: 1.3; color: var(--ink); overflow-wrap: anywhere; }
.ird-pub-record__foot { padding: 16px 24px; border-top: 1px solid var(--rule); background: var(--surface-2); }
@media (max-width: 479.98px) { .ird-pub-record__foot { padding: 14px 16px; } }
/* Key and value: label over value on phones, so long names have the width. */
@media (max-width: 519.98px) {
  .ird-pub .ird-kv { grid-template-columns: minmax(0, 1fr); }
  .ird-pub .ird-kv dt { padding-bottom: 0; }
  .ird-pub .ird-kv dd { padding-top: 2px; border-top: 0; text-align: left; }
}
.ird-pub .ird-kv { font-size: var(--text-base); }
.ird-pub .ird-kv dt { color: var(--ink-3); }
/* Values start at the value column on the public record, so one that wraps keeps a straight left edge. */
.ird-pub .ird-kv dd { font-weight: 600; text-align: left; }
.ird-pub .ird-kv dd small { display: block; font-weight: 400; color: var(--ink-3); font-size: var(--text-xs); }
.ird-pub-withheld { font-weight: 400 !important; font-style: italic; color: var(--ink-3) !important; }

/* A reference read character by character: large, tabular, never broken. */
.ird-pub-ref {
  display: block; margin: 2px 0 0; font-family: var(--font-mono); font-size: var(--text-xl); font-weight: 700; letter-spacing: 0.03em;
  color: var(--area-ink); font-variant-numeric: tabular-nums slashed-zero; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
body[data-color-mode="contrast"] .ird-pub-ref { color: #000; }
@media (max-width: 379.98px) { .ird-pub-ref { font-size: var(--text-lg); } }
/* The reference and its Copy button share a line when both fit; otherwise the button drops below. */
.ird-pub-refrow { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2) var(--s-3); min-width: 0; margin-top: 2px; padding: 12px 14px; border-radius: var(--r-ctl); background: var(--area-soft); border: 1px dashed var(--area-ink); }
.ird-pub-refrow .ird-pub-ref { flex: 0 1 auto; min-width: 0; margin: 0; }
.ird-pub-refrow .ird-btn { flex: none; margin-left: auto; }
body[data-color-mode="contrast"] .ird-pub-refrow { background: #fff; border-color: #000; }

.ird-pub-note { margin: 0; font-size: var(--text-xs); color: var(--ink-3); max-width: 70ch; line-height: 1.5; }
.ird-pub-panel .ird-steps { --step-pad-x: 0px; }
.ird-pub-panel .ird-steps > .ird-step { border-top: 0; padding-top: var(--s-2); padding-bottom: var(--s-2); }
.ird-pub-panel .ird-steps > li:first-child::before { top: 22px; }
.ird-pub-panel .ird-steps > li:last-child::before { bottom: calc(100% - 22px); }
.ird-pub-panel .ird-step__title { font-weight: 400; }
.ird-pub-panel .ird-step[data-state="current"] .ird-step__title { font-weight: 700; }
.ird-pub-stack { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-5); }
.ird-pub-stack > * { min-width: 0; }
.ird-pub-stack > .ird-panel { margin-top: 0 !important; }

/* The tracking page: the request on the left, what to do and its history right. */
.ird-pub-split { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-5); align-items: start; }
@media (min-width: 960px) { .ird-pub-split { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); } }
.ird-pub-split > * { min-width: 0; }
.ird-pub-lookup { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--s-3) var(--s-4); align-items: end; }
@media (min-width: 720px) { .ird-pub-lookup { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto; } }
.ird-pub-lookup--one { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .ird-pub-lookup--one { grid-template-columns: minmax(0, 1fr) auto; } }
.ird-pub-lookup .ird-btn { min-height: 48px; }
@media (max-width: 719.98px) { .ird-pub-lookup .ird-btn { width: 100%; } }
@media (min-width: 560px) { .ird-pub-lookup--one:has(.ird-hint) .ird-btn { margin-bottom: 26px; } }

/* The delivery timeline: a marker per event on a thread, the newest last. */
.ird-pub .ird-rq-timeline { list-style: none; margin: var(--s-3) 0 0; padding: 0; }
.ird-pub .ird-rq-timeline > li { position: relative; padding: 0 0 var(--s-4) 30px; }
.ird-pub .ird-rq-timeline > li::before {
  content: ""; position: absolute; left: 3px; top: 3px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--surface); border: 3px solid var(--area-ink); box-sizing: border-box;
}
.ird-pub .ird-rq-timeline > li::after { content: ""; position: absolute; left: 9px; top: 21px; bottom: 3px; width: 2px; border-radius: 2px; background: var(--rule-strong); }
.ird-pub .ird-rq-timeline > li:last-child { padding-bottom: 0; }
.ird-pub .ird-rq-timeline > li:last-child::after { display: none; }
.ird-pub .ird-rq-timeline > li[data-tone="success"]::before { border-color: var(--ok); background: var(--ok); }
.ird-pub .ird-rq-timeline > li[data-tone="danger"]::before { border-color: var(--danger); background: var(--danger); }
.ird-pub .ird-rq-timeline > li[data-tone="warning"]::before { border-color: var(--warn); }
.ird-pub .ird-rq-timeline__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px var(--s-3); }
.ird-pub .ird-rq-timeline__title { font-weight: 700; color: var(--ink); }
.ird-pub .ird-rq-timeline__when { font-size: var(--text-xs); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.ird-pub .ird-rq-timeline__text { margin: 4px 0 0; font-size: var(--text-sm); color: var(--ink-2); overflow-wrap: anywhere; }
body[data-color-mode="contrast"] .ird-pub .ird-rq-timeline > li::before { border-color: #000; }
body[data-color-mode="contrast"] .ird-pub .ird-rq-timeline > li::after { background: #000; }

/* The next step, set apart: it is the page's one action when there is one.
   A tile in the page's area leads it. */
.ird-pub-next { position: relative; padding: 22px 24px 22px 92px; box-shadow: var(--shadow-2); }
.ird-pub-next::before {
  content: "arrow_circle_right" / ""; position: absolute; left: 24px; top: 22px;
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px;
  background: var(--area-ink); color: var(--surface);
  font-family: "Material Symbols Outlined"; font-size: 26px; line-height: 1; font-weight: normal; font-style: normal;
  letter-spacing: normal; text-transform: none; white-space: nowrap; overflow: hidden;
  font-feature-settings: "liga"; -webkit-font-feature-settings: "liga"; font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}
/* A card whose action downloads the copy says so; on the tracking page that action waits on the requester, so it is orange. */
.ird-pub-next:has(a[href*="download"], a[href*="/delivery/"])::before { content: "download" / ""; }
.ird-pub-page--wide .ird-pub-next:has(a[href*="/delivery/"])::before { background: var(--act); color: #2b1600; }
.ird-pub-next__title { margin: 0; font-size: var(--text-lg); font-weight: 700; color: var(--ink); overflow-wrap: anywhere; }
.ird-pub-next__text { margin: 6px 0 0; color: var(--ink-2); overflow-wrap: anywhere; }
.ird-pub-next__actions { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-3); margin-top: var(--s-4); }
.ird-pub-next__actions .ird-btn--primary { min-height: 48px; }
body[data-color-mode="contrast"] .ird-pub-next::before { background: #000 !important; color: #fff !important; }
@media (max-width: 479.98px) {
  .ird-pub-next { padding: 72px 16px 18px; }
  .ird-pub-next::before { left: 16px; top: 16px; width: 44px; height: 44px; }
  .ird-pub-next__actions .ird-btn { width: 100%; }
}

/* ------------------------------------------------- signature pad --- */
.ird-pub-sig { display: grid; gap: var(--s-2); }
.ird-pub-sig__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-2) var(--s-3); }
.ird-pub-sig__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-2); }
.ird-pub-sig canvas.ird-sigpad { height: 160px; border-radius: var(--r-ctl); }
.ird-pub-sig.g360-invalid .ird-sigpad, .ird-pub-sig.is-invalid .ird-sigpad { border-color: var(--danger); border-style: solid; }

/* ------------------------------------------------------- small pieces --- */
.ird-pub-errlist { margin: var(--s-1) 0 0; padding-left: 1.25rem; list-style: disc; }
.ird-pub-errlist li + li { margin-top: 2px; }
.ird-pub-verify-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-3); margin-top: var(--s-5) !important; padding-top: var(--s-4); border-top: 1px solid var(--rule); }
.ird-pub-signin { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-3); }
.ird-pub-signin .ird-h3, .ird-pub-signin .ird-pub-note { margin: 0; }
.ird-pub-list { margin: 0; padding-left: 1.4rem; list-style: decimal; display: grid; gap: var(--s-2); color: var(--ink); max-width: 68ch; }
.ird-pub-list li::marker { color: var(--area-ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.ird-pub-prose { line-height: 1.65; max-width: 72ch; overflow-wrap: anywhere; }
.ird-pub-prose p { margin: 0; }
.ird-pub-prose p + p { margin-top: var(--s-3); }
.ird-pub-date { max-width: 16rem; }
/* A native file picker in the field style: the button part takes the secondary look. */
.ird-pub-fileinput { padding: 5px; min-height: 48px; line-height: 1.9; }
.ird-pub-fileinput::file-selector-button {
  margin-right: var(--s-3); min-height: 36px; padding: 0 var(--s-3);
  border: 1px solid var(--control-border); border-radius: 8px; background: var(--surface-sunk); color: var(--ink);
  font: inherit; font-size: var(--text-sm); font-weight: 700; cursor: pointer;
}
/* The empty tracking page: the shared empty state, in a card, led by the page's tile. */
.ird-pub .ird-empty { margin-top: var(--s-5); padding: var(--s-8) var(--s-6) !important; max-width: none; background: var(--surface); border: 1px dashed var(--rule-strong); border-radius: var(--r-lg); }
body[data-color-mode="contrast"] .ird-pub .ird-empty { border: 2px dashed #000; }
@media (pointer: coarse), (max-width: 1023.98px) {
  .ird-pub-standalone { display: inline-flex; align-items: center; min-height: 44px; }
  .ird-pub .ird-empty .ird-link { display: inline-flex; align-items: center; min-height: 44px; }
}

/* ------------------------------------------------------------ motion --- */
@media (prefers-reduced-motion: reduce) {
  .ird-pub-nav a, .ird-pub-choice { transition: none !important; }
}

/* ------------------------------------------------------------- print --- */
@media print {
  .ird-pub-bar, .ird-pub-foot, .ird-skip { display: none !important; }
  body.ird-pub { background: #fff; }
  .ird-pub-result, .ird-pub-record, .ird-panel { box-shadow: none !important; }
}

/* -------------------------------------------------------- drop zone --- */
/* The ID upload: ird.css's drop zone, taller, in the page's soft wash, its
   icon in a tile. */
.ird-pub .ird-drop { min-height: 156px; gap: 6px; border-width: 2px; border-radius: var(--r-lg); background: var(--area-soft); }
.ird-pub .ird-drop:hover, .ird-pub .ird-drop.is-over { background: var(--area-tint); border-color: var(--area-ink); }
.ird-pub .ird-drop > .material-symbols-outlined {
  display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 4px; border-radius: 16px;
  background: var(--area-tint); color: var(--area-ink); font-size: 28px;
  font-variation-settings: "FILL" 1, "wght" 500, "GRAD" 0, "opsz" 24;
}
.ird-pub .ird-drop__title { font-size: var(--text-md); font-weight: 700; }
body[data-color-mode="contrast"] .ird-pub .ird-drop { background: #fff; border-color: #000; }
body[data-color-mode="contrast"] .ird-pub .ird-drop > .material-symbols-outlined { background: #fff; color: #000; border: 2px solid #000; }
