/* Hosted VeroMCP. Brand: green #006600, navy #13213C, Funnel Display (headings) and Figtree (text),
   both SIL Open Font Licence, self-hosted from /static/vendor/fonts (copied at build time). */
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 400; font-display: swap; src: url('/static/vendor/fonts/figtree-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 500; font-display: swap; src: url('/static/vendor/fonts/figtree-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 600; font-display: swap; src: url('/static/vendor/fonts/figtree-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 700; font-display: swap; src: url('/static/vendor/fonts/figtree-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Funnel Display'; font-style: normal; font-weight: 600; font-display: swap; src: url('/static/vendor/fonts/funnel-display-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Funnel Display'; font-style: normal; font-weight: 700; font-display: swap; src: url('/static/vendor/fonts/funnel-display-latin-700-normal.woff2') format('woff2'); }

:root {
  --green: #006600;
  --green-dark: #004d00;
  --green-soft: #e3f1e3;
  --navy: #13213c;
  --ink: #13213c;
  --ink-2: #2d3a52;
  --muted: #4a5568;
  --line: #dce1ea;
  --line-soft: #e6eaf0;
  --line-strong: #b8c1d1;
  --input: #8a96ab;
  --bg: #f3f5f9;
  --card: #ffffff;
  --chip: #eef1f6;
  --warn-bg: #fff6e5;
  --warn-line: #f0d29a;
  --warn-chip: #fff1d6;
  --warn-ink: #7a4100;
  --ok-dot: #28a745;
  --header-meta: #d5dce8;
  --display: 'Funnel Display', 'Figtree', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-family: 'Figtree', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--ink); }
a { color: var(--green); }
a:hover { color: var(--green-dark); }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: 600; letter-spacing: -0.01em; }
code { overflow-wrap: anywhere; font-family: var(--mono); }
.icon { flex: none; }
.muted { color: var(--muted); }
.small-text { font-size: 15px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid #4d9cff; outline-offset: 2px; }

/* Header */
.site-header { background: var(--navy); color: #fff; }
.site-header-inner { max-width: 1200px; margin: 0 auto; padding: 12px 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.site-header.narrow .site-header-inner { max-width: 1040px; }
.site-header.medium .site-header-inner { max-width: 800px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: #fff; text-decoration: none; }
.brand:hover { color: #fff; }
.brand-mark { width: 36px; height: 36px; border-radius: 10px; background: var(--green); border: 1.5px solid rgba(255, 255, 255, 0.35); color: #fff; display: inline-flex; align-items: center; justify-content: center; }
.brand-name { font-family: var(--display); font-weight: 700; font-size: 22px; letter-spacing: -0.01em; }
.header-meta { font-size: 15px; color: var(--header-meta); }
.header-meta strong { color: #fff; font-weight: 600; }

/* Page containers */
.page { margin: 0 auto; padding: 48px 16px 72px; display: flex; flex-direction: column; gap: 20px; }
.page.narrow { max-width: 640px; }
.page.medium { max-width: 800px; padding-top: 24px; }
.page.wide { max-width: 1180px; padding-top: 24px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 36px; display: flex; flex-direction: column; gap: 24px; }
.card.tight { gap: 18px; padding: 32px; }
.card.emph { border: 2px solid var(--navy); }
.card h1 { font-size: 30px; line-height: 1.2; letter-spacing: -0.02em; text-wrap: balance; }
.card h1.large { font-size: 36px; line-height: 1.12; }
.card .state-title { font-size: 30px; line-height: 1.15; }
.heading-block { display: flex; flex-direction: column; gap: 6px; }
.lead { color: var(--ink-2); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 20px; border-radius: 12px; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; border: 1px solid var(--line-strong); background: #fff; color: var(--ink); }
.btn:hover { border-color: var(--muted); color: var(--ink); }
.btn.primary { min-height: 56px; border: 0; border-radius: 14px; background: var(--green); color: #fff; font-size: 18px; font-weight: 700; padding: 0 22px; }
.btn.primary:hover { background: var(--green-dark); color: #fff; }
.btn.primary.huge { min-height: 60px; font-size: 19px; }
.btn.block { width: 100%; }
.btn.start { align-self: flex-start; }
.btn.small { min-height: 44px; padding: 0 16px; font-size: 15px; border-radius: 10px; }
.btn.small.primary { font-size: 16px; }
.btn-link { align-self: center; min-height: 44px; padding: 0 16px; border: 0; background: transparent; color: var(--ink); font: inherit; font-weight: 600; text-decoration: underline; cursor: pointer; }
.btn-link.green { color: var(--green); padding: 0 12px; }
.btn[disabled], .btn-link[disabled] { opacity: 0.6; cursor: wait; }
.back-link { align-self: flex-start; min-height: 44px; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; }
.button-stack { display: flex; flex-direction: column; gap: 10px; }

/* Chips, callouts, footnotes */
.chip { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: var(--chip); color: var(--ink); font-weight: 700; font-size: 14px; }
.chip.ok { background: var(--green-soft); color: var(--green-dark); }
.chip.warn { background: var(--warn-chip); color: var(--warn-ink); }
.callout { display: flex; gap: 12px; align-items: flex-start; padding: 16px 20px; border-radius: 14px; }
.callout.warn { background: var(--warn-bg); border: 1px solid var(--warn-line); color: var(--ink); }
.callout.warn .icon { color: var(--warn-ink); margin-top: 1px; }
.callout.ok { background: var(--green-soft); }
.callout.ok .icon { color: var(--green); margin-top: 2px; }
.callout.info { background: var(--chip); }
.footnote { padding-top: 16px; border-top: 1px solid var(--line-soft); display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); font-size: 15px; }
.footnote .icon { color: var(--green); margin-top: 1px; }
.footnote.plain { color: var(--muted); }

/* Consent */
.app-identity { display: flex; align-items: center; gap: 18px; }
.app-logo { width: 76px; height: 76px; flex: none; border-radius: 18px; border: 1px solid var(--line); background: var(--bg); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.app-logo img { width: 100%; height: 100%; object-fit: contain; }
.app-logo.initial { background: var(--navy); border-color: var(--navy); color: #fff; font-family: var(--display); font-size: 34px; font-weight: 700; }
.app-identity .name { font-family: var(--display); font-size: 28px; font-weight: 700; overflow-wrap: anywhere; }
.app-identity .facts { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.unverified { color: var(--warn-ink); font-weight: 600; font-size: 15px; }
.options { margin: 0; padding: 0; border: 0; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.options legend { padding: 0; margin-bottom: 12px; font-family: var(--display); font-size: 20px; font-weight: 600; }
.option { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); }
.option.choosable { border: 2px solid var(--navy); background: #fff; cursor: pointer; }
.option input { width: 24px; height: 24px; margin: 1px 0 0; accent-color: var(--green); flex: none; }
.option-text { display: flex; flex-direction: column; gap: 4px; }
.option-text strong { font-size: 17px; }
.option-text span { color: var(--ink-2); font-size: 15px; }
.option.fixed .option-text span { color: var(--muted); }
.company-pick { display: flex; flex-direction: column; gap: 6px; font-weight: 600; }
select { font: inherit; font-weight: 400; min-height: 48px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--input); width: 100%; background: #fff; color: var(--ink); }
.center-note { text-align: center; color: var(--muted); font-size: 15px; }

/* Approval */
.facts-table { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.facts-table .caption { padding: 12px 16px; font-weight: 700; background: var(--bg); border-bottom: 1px solid var(--line-soft); }
.facts-table table { width: 100%; border-collapse: collapse; font-size: 16px; }
.facts-table caption { text-align: left; padding: 12px 16px; font-weight: 700; background: var(--bg); }
.facts-table th, .facts-table td { padding: 12px 16px; border-top: 1px solid var(--line-soft); vertical-align: top; }
.facts-table th { text-align: left; font-weight: 400; }
.facts-table td { text-align: right; font-weight: 600; overflow-wrap: break-word; }
.facts-table td.note { text-align: left; font-weight: 400; color: var(--muted); font-size: 15px; }
h2.sub { font-size: 20px; }
.summary { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; padding: 16px; font-family: var(--mono); font-size: 14px; line-height: 1.55; color: var(--ink); background: #fff; }
.summary.agent-text { border-left: 4px solid var(--warn-ink); }
.fingerprint { padding: 18px 20px; border: 2px solid var(--navy); border-radius: 14px; display: flex; flex-wrap: wrap; gap: 6px 20px; align-items: baseline; justify-content: space-between; }
.fingerprint .label { font-weight: 700; }
.fingerprint .value { font-family: var(--mono); font-size: 26px; font-weight: 600; letter-spacing: 0.06em; overflow-wrap: anywhere; }
.fingerprint .hint { flex-basis: 100%; color: var(--muted); font-size: 15px; }
.contact-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.contact-row .label { color: var(--muted); }
.contact-form { margin: 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: 14px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.contact-form legend { padding: 0 6px; font-weight: 700; }
.field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 12px; }
.field { display: flex; flex-direction: column; gap: 4px; font-weight: 600; }
.field input, .field textarea, .field select { min-height: 48px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--input); font: inherit; font-weight: 400; color: var(--ink); background: #fff; width: 100%; }
.field textarea { padding: 10px 12px; min-height: 0; }
.field .help { font-weight: 400; color: var(--muted); font-size: 15px; }
.receipt { margin: 0; padding: 18px 20px; background: var(--bg); border-radius: 12px; display: flex; flex-direction: column; gap: 10px; }
.receipt div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; }
.receipt dt { color: var(--muted); }
.receipt dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.receipt dd.mono { font-family: var(--mono); }
.radio-options { margin: 0; padding: 0; border: 0; display: flex; flex-direction: column; gap: 8px; }
.radio-options legend { padding: 0; margin-bottom: 8px; font-weight: 700; }
.radio-option { display: flex; gap: 12px; align-items: center; min-height: 48px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 12px; cursor: pointer; }
.radio-option input { width: 22px; height: 22px; margin: 0; accent-color: var(--green); }
.stack-form { display: flex; flex-direction: column; gap: 12px; }

/* Account shell: side menu on wide screens, bottom tab bar on phones */
.site-header.wide .site-header-inner { max-width: 1200px; }
.shell { max-width: 1200px; margin: 0 auto; padding: 28px 16px 72px; display: flex; gap: 32px; align-items: flex-start; }
.sidebar { flex: 0 0 260px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 16px; }
.sidebar hr { width: 100%; margin: 10px 0; border: 0; border-top: 1px solid var(--line-soft); }
.sidebar-company { padding: 6px 12px 14px; display: flex; flex-direction: column; }
.sidebar-company strong { font-size: 17px; }
.sidebar-company span { color: var(--muted); font-size: 14px; }
.company-switch { display: flex; flex-direction: column; gap: 2px; padding: 0 12px 10px; font-size: 14px; }
.nav-link { min-height: 48px; padding: 0 14px; border-radius: 10px; color: var(--ink); font: inherit; font-weight: 600; text-decoration: none; display: flex; align-items: center; gap: 12px; border: 0; background: transparent; cursor: pointer; text-align: left; }
.nav-link:hover { background: var(--bg); color: var(--ink); }
.nav-link[aria-current='page'] { background: var(--green-soft); color: var(--green-dark); font-weight: 700; }
.nav-label { flex: 1; }
.nav-badge { min-width: 24px; height: 24px; padding: 0 6px; border-radius: 999px; background: var(--navy); color: #fff; font-size: 13px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.shell-main { flex: 1 1 640px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.tabbar { display: none; }
.phone-only { display: none !important; }
.page-head { display: flex; flex-direction: column; gap: 4px; }
.page-head h1 { font-size: 40px; line-height: 1.1; letter-spacing: -0.02em; }
.page-head p { font-size: 17px; }
.section-title { font-size: 24px; }
.card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 12px; }
.pending-text { flex: 999 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.mono { font-family: var(--mono); }
.strong { font-weight: 600; color: var(--ink); }
.onboarding-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; }
.progress { flex: 0 1 220px; height: 10px; border-radius: 999px; background: var(--line); overflow: hidden; }
.progress span { display: block; height: 100%; width: 0; background: var(--green); }
.progress.done-1 span { width: 25%; }
.progress.done-2 span { width: 50%; }
.progress.done-3 span { width: 75%; }
.progress.done-4 span { width: 100%; }
.steps { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.step { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; color: var(--muted); }
.step strong { flex: 1 1 200px; color: var(--ink); }
.step-mark { width: 28px; height: 28px; border-radius: 999px; background: var(--chip); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; flex: none; font-weight: 700; font-size: 14px; }
.step.done .step-mark { background: var(--green-soft); color: var(--green-dark); }
.step.next .step-mark { background: var(--navy); color: #fff; }
.status-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); gap: 16px; }
.status-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 22px; color: var(--ink); text-decoration: none; display: flex; flex-direction: column; gap: 10px; }
.status-card:hover { border-color: var(--line-strong); color: var(--ink); }
.status-label { display: flex; align-items: center; gap: 10px; font-weight: 600; color: var(--muted); }
.status-value { display: flex; align-items: center; gap: 8px; font-family: var(--display); font-size: 22px; font-weight: 600; }
.status-note { color: var(--muted); font-size: 15px; }
.dot { width: 10px; height: 10px; border-radius: 999px; flex: none; background: var(--line-strong); }
.dot.ok { background: var(--ok-dot); }
.dot.warn { background: #e0a100; }
.dot.bad { background: #c0392b; }
.items, .log { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; }
.items { gap: 12px; }
.item { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; }
.item-text { flex: 999 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.item-title { font-size: 17px; }
.item-meta { display: block; color: var(--muted); font-size: 15px; }
.item-meta::first-letter { text-transform: uppercase; }
.item-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--green-soft); color: var(--green); display: flex; align-items: center; justify-content: center; flex: none; }
.app-logo.small { width: 52px; height: 52px; border-radius: 14px; font-size: 24px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip.small { padding: 2px 10px; font-weight: 600; }
.log li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 12px 0; border-bottom: 1px solid var(--line-soft); }
.log li:last-child { border-bottom: 0; }
.log li > pre { flex: 1 1 100%; margin: 0; }
.facts-grid { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); gap: 16px; padding: 20px; background: var(--bg); border-radius: 12px; }
.facts-grid div { display: flex; flex-direction: column; gap: 2px; }
.facts-grid dt { font-size: 14px; color: var(--muted); }
.facts-grid dd { margin: 0; font-weight: 600; }
.note-line { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); }
.note-line .icon { color: var(--green); margin-top: 2px; }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; }
.pair-code { padding: 18px 20px; border: 2px solid var(--navy); border-radius: 14px; display: flex; flex-direction: column; gap: 6px; }

@media (max-width: 860px) {
  .shell { padding: 16px 16px 112px; display: block; }
  .sidebar { display: none; }
  .shell-main { gap: 16px; }
  .desktop-only { display: none !important; }
  .phone-only { display: inline-flex !important; }
  .page-head h1 { font-size: 30px; }
  .section-title { font-size: 20px; }
  .status-card { padding: 16px; border-radius: 14px; }
  .item { padding: 14px; gap: 12px; }
  .tabbar { display: grid; position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; background: var(--card); border-top: 1px solid var(--line); padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
  .tab { position: relative; min-height: 56px; border-radius: 12px; color: var(--ink); text-decoration: none; font-size: 13px; font-weight: 600; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
  .tab[aria-current='page'] { background: var(--green-soft); color: var(--green-dark); font-weight: 700; }
  .tab .nav-badge { position: absolute; top: 4px; right: calc(50% - 22px); min-width: 18px; height: 18px; font-size: 11px; padding: 0 4px; }
  .shell-main > .btn.phone-only { justify-content: center; }
}

/* Status line written by app.js */
.status { color: var(--muted); }
.status.error { color: #b3261e; font-weight: 600; }

/* Pages still on the earlier single-card layout */
main.legacy { width: min(560px, calc(100% - 32px)); margin: 32px auto; background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 24px; }
main.legacy h1 { font-size: 1.5rem; margin: 0 0 16px; }
main.legacy h2 { font-size: 1.1rem; margin: 24px 0 8px; }
main.legacy h3 { font-size: 1rem; margin: 18px 0 6px; }
main.legacy p { margin: 0 0 12px; line-height: 1.55; }
main.legacy .muted { font-size: 0.92rem; }
.app-host { font-size: 1.25rem; font-weight: 700; margin: 4px 0 8px; overflow-wrap: anywhere; }
.list { list-style: none; padding: 0; margin: 0; }
.list li { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.list li > span { display: inline-flex; gap: 8px; align-items: center; }
.list li > pre { flex: 1 1 100%; margin: 0; }
main.legacy fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 12px 16px; margin: 16px 0; }
main.legacy label { display: flex; gap: 8px; align-items: flex-start; padding: 6px 0; cursor: pointer; }
main.legacy .field { cursor: default; }
input[type='radio'] { accent-color: var(--green); }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.button { display: inline-flex; gap: 8px; align-items: center; border: 2px solid var(--green); background: var(--green); color: #fff; border-radius: 10px; padding: 10px 16px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
.button:hover { background: var(--green-dark); border-color: var(--green-dark); color: #fff; }
.button.secondary { background: transparent; color: var(--ink); border-color: var(--line); }
.button.secondary:hover { border-color: var(--muted); }
.button.small { padding: 6px 10px; font-size: 0.9rem; }
.button[disabled] { opacity: 0.6; cursor: wait; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; background: var(--chip); }
.notice.warning { background: var(--warn-bg); color: var(--ink); }
.notice.success { background: var(--green-soft); }
.notice .icon { flex: none; margin-top: 2px; }
.company { border-top: 1px solid var(--line); padding-top: 8px; margin-top: 16px; }
.pair-code .code { font-size: 1.8rem; font-weight: 700; letter-spacing: 0.08em; font-family: var(--mono); }
.stack { display: flex; flex-direction: column; gap: 4px; }

@media (max-width: 600px) {
  .brand-mark { width: 32px; height: 32px; border-radius: 9px; }
  .brand-name { font-size: 20px; }
  .header-meta { font-size: 14px; }
  .page { padding: 16px 16px 40px; gap: 12px; }
  .page.narrow { padding-top: 24px; }
  .card, .card.tight { padding: 20px; border-radius: 18px; gap: 18px; }
  .card h1 { font-size: 26px; }
  .card h1.large { font-size: 26px; line-height: 1.15; }
  .card .state-title { font-size: 24px; }
  .app-logo { width: 60px; height: 60px; border-radius: 14px; }
  .app-identity .name { font-size: 24px; }
  .fingerprint { padding: 14px; flex-direction: column; gap: 4px; }
  .fingerprint .value { font-size: 18px; letter-spacing: 0.02em; }
  .facts-table th, .facts-table td { padding: 10px 12px; }
  .facts-table td { min-width: 7em; }
  .btn.primary.huge { min-height: 58px; font-size: 18px; }
}
.sentence { display: block; }
.sentence::first-letter { text-transform: uppercase; }
.login-title { font-size: 34px !important; line-height: 1.15; }
.large-text { font-size: 18px; }
.card.login { padding: 40px 36px; gap: 22px; }
.apps-row { display: flex; flex-direction: column; gap: 10px; }
.apps-row-label { font-size: 15px; font-weight: 600; color: var(--muted); }
.app-chips { margin: 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.app-chips li { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--bg); border: 1px solid var(--line); font-size: 15px; font-weight: 600; }
.hints { margin: 0; padding: 0 8px; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.hints li { display: flex; gap: 12px; align-items: flex-start; }
.hints .icon { color: var(--green); margin-top: 2px; }
@media (max-width: 600px) {
  .card.login { padding: 24px 20px; }
  .login-title { font-size: 28px !important; }
}

/* Mac pairing steps */
.pair-steps { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.pair-step-head { width: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px 20px; background: var(--card); border: 1px dashed var(--line-strong); border-radius: 14px; font: inherit; color: var(--muted); text-align: left; cursor: pointer; }
.pair-step-head strong { flex: 1 1 200px; color: var(--ink); }
.step-done-label { display: none; color: var(--green-dark); font-weight: 700; }
.pair-step.done .pair-step-head { border: 1px solid var(--line); }
.pair-step.done .step-mark { background: var(--green-soft); color: var(--green-dark); }
.pair-step.done .step-done-label { display: inline; }
.pair-step-body { display: none; background: var(--card); border: 2px solid var(--navy); border-radius: 18px; padding: 28px; flex-direction: column; gap: 16px; }
.pair-step.open .pair-step-head { display: none; }
.pair-step.open .pair-step-body { display: flex; }
.step-count { font-size: 14px; font-weight: 700; color: var(--muted); }
.step-title { font-size: 28px; }
.pair-code-box { padding: 22px; border-radius: 14px; background: var(--navy); color: #fff; display: flex; flex-direction: column; gap: 8px; align-items: center; text-align: center; }
.pair-code-box .label { font-size: 15px; color: var(--header-meta); }
.pair-code-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px; }
.pair-copy { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 14px; border-radius: 10px; border: 1.5px solid rgba(255, 255, 255, 0.35); background: transparent; color: #fff; font: inherit; font-weight: 600; cursor: pointer; }
.pair-copy:hover { border-color: #fff; }
.pair-copy [data-copy-idle], .pair-copy [data-copy-done] { display: inline-flex; align-items: center; gap: 8px; }
.pair-copy [hidden] { display: none; }
.pair-code-box .code { font-family: var(--mono); font-size: 40px; font-weight: 600; letter-spacing: 0.08em; overflow-wrap: anywhere; }
.btn.disabled { opacity: 0.65; cursor: not-allowed; }
@media (max-width: 600px) {
  .pair-step-body { padding: 20px; }
  .step-title { font-size: 22px; }
  .pair-code-box .code { font-size: 28px; }
}

/* Start, welcome and expired-link pages */
.header-link { min-height: 44px; padding: 0 14px; border-radius: 10px; border: 1px solid #5b6b8a; color: #fff; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; }
.header-link:hover { color: #fff; border-color: #fff; }
.card.login h1 { font-size: 38px; line-height: 1.1; letter-spacing: -0.02em; }
.big-icon { width: 64px; height: 64px; border-radius: 18px; background: #fff; border: 1px solid var(--line); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; }
.big-icon.ok { background: var(--green-soft); border-color: var(--green-soft); color: var(--green); }
.button-row.divided { padding-top: 16px; border-top: 1px solid var(--line-soft); align-items: center; }
.page.narrow-wide { max-width: 1040px; padding-top: 56px; }
.site-header.narrow-wide .site-header-inner { max-width: 1040px; }
.welcome { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-start; }
.welcome-card { flex: 999 1 540px; min-width: 0; padding: 40px; }
.welcome-title { font-size: 44px !important; line-height: 1.1; letter-spacing: -0.02em; }
.welcome-next { flex: 1 1 300px; min-width: 0; padding: 8px 4px; display: flex; flex-direction: column; gap: 18px; }
.welcome-next h2 { font-size: 22px; }
.welcome-steps { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 16px; }
.welcome-steps li { display: flex; gap: 14px; align-items: flex-start; }
.welcome-steps .step-mark { width: 32px; height: 32px; background: #fff; border: 1px solid var(--line-strong); }
.welcome-steps .step-mark.current { background: var(--navy); color: #fff; border-color: var(--navy); }
.expired-head { gap: 16px; }
.hero-title { font-size: 44px; line-height: 1.1; letter-spacing: -0.02em; text-wrap: balance; }
.two-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 20px; }
.push { margin-top: auto; }
@media (max-width: 600px) {
  .card.login h1 { font-size: 30px; }
  .page.narrow-wide { padding-top: 24px; }
  .welcome-card { padding: 24px 20px; }
  .welcome-title { font-size: 32px !important; }
  .hero-title { font-size: 32px; }
}

/* Inviting a person */
.invite-form { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-end; }
.invite-form .grow { flex: 999 1 280px; }
.role-pick { flex: 1 1 240px; margin: 0; padding: 0; border: 0; display: flex; flex-direction: column; gap: 6px; }
.role-pick legend { padding: 0; margin-bottom: 6px; font-weight: 600; }
.role-options { display: flex; gap: 8px; }
.role-options .radio-option { flex: 1; }
.welcome-title.long { font-size: 40px !important; line-height: 1.12; text-wrap: balance; }
@media (max-width: 600px) { .welcome-title.long { font-size: 30px !important; } }
/* Self-service start: one main thing per view */
.page.narrow-start { max-width: 560px; padding-top: 40px; padding-bottom: 40px; }
.site-header.narrow-start .site-header-inner { max-width: 1040px; }
.needs { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 14px; }
.needs li { display: flex; gap: 14px; align-items: flex-start; background: var(--green-soft); border-radius: 14px; padding: 16px 18px; }
.needs .icon { color: var(--green); margin-top: 1px; }

/* The pending filing: soft amber, navy text, dark "Tarkastele" */
.pending-banner { background: #fef6e4; color: var(--ink); border: 1px solid #e8b04b; border-radius: 20px; padding: 28px; display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between; }
.pending-banner h2 { font-size: 26px; }
.pending-banner .pending-text p { color: #3d4a63; }
.pending-icon { width: 48px; height: 48px; flex: none; border-radius: 14px; background: #fce7b8; color: #b45309; display: inline-flex; align-items: center; justify-content: center; }
.btn.dark { min-height: 52px; border: 0; background: var(--navy); color: #fff; font-weight: 700; font-size: 17px; padding: 0 24px; }
.btn.dark:hover { background: #0b1528; color: #fff; }
/* Ilmoitukset: a plain table */
.table-scroll { overflow-x: auto; }
table.filings { width: 100%; border-collapse: collapse; font-size: 16px; min-width: 620px; }
table.filings th { text-align: left; padding: 10px 12px; font-size: 14px; font-weight: 700; color: var(--muted); white-space: nowrap; }
table.filings td { padding: 14px 12px; border-top: 1px solid var(--line-soft); vertical-align: middle; }
table.filings td:first-child, table.filings td:nth-child(3) { white-space: nowrap; }
table.filings .filing-name { font-weight: 600; }
table.filings a { font-weight: 700; }
table.filings a.mono { font-size: 14px; font-weight: 600; }
.chip.status-pending { background: #fef6e4; color: #8a4b00; border: 1px solid #e8b04b; padding: 2px 10px; }
.chip.status-sent { background: var(--green-soft); color: var(--green-dark); border: 1px solid #b7ddb7; padding: 2px 10px; }
.chip.status-rejected { background: #fdecec; color: #9b1c1c; border: 1px solid #f3b8b8; padding: 2px 10px; }
.chip.status-unknown { background: var(--chip); color: var(--ink); border: 1px solid var(--line); padding: 2px 10px; }
@media (max-width: 860px) {
  .pending-banner { padding: 20px; border-radius: 16px; }
  .pending-banner h2 { font-size: 20px; }
  table.filings { min-width: 0; }
  table.filings thead { display: none; }
  table.filings tr { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 14px 0; border-top: 1px solid var(--line-soft); }
  table.filings td { border: 0; padding: 0; }
  table.filings td:nth-child(1) { grid-row: 3; color: var(--muted); font-size: 15px; }
  table.filings td:nth-child(2) { grid-row: 1; }
  table.filings td:nth-child(3) { grid-row: 2; color: var(--muted); font-size: 15px; }
  table.filings td:nth-child(4) { grid-column: 2; grid-row: 1; }
  table.filings td:nth-child(5) { grid-column: 2; grid-row: 2 / span 2; text-align: right; }
}

/* What will be sent: one generic list for every filing kind */
.fields { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.fields > h2 { margin: 0; padding: 12px 16px; background: var(--bg); font-family: inherit; font-size: 16px; font-weight: 700; letter-spacing: 0; }
.field-list { margin: 0; padding: 0 16px 4px; }
.field-list h3 { margin: 0; padding: 12px 0 2px; font-family: inherit; font-size: 13px; font-weight: 700; letter-spacing: 0.02em; color: var(--muted); }
.field-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 0; border-top: 1px solid var(--line-soft); }
.field-list h3 + .field-row, .field-list > .field-row:first-child { border-top: 0; }
.field-row dt { color: var(--ink-2); }
.field-row dd { margin: 0; font-weight: 600; text-align: right; font-family: var(--mono); overflow-wrap: anywhere; }
.field-row .unit { color: var(--muted); font-weight: 400; font-family: 'Figtree', ui-sans-serif, system-ui, sans-serif; }
.fields-caption { padding: 10px 16px 12px; border-top: 1px solid var(--line-soft); color: var(--muted); font-size: 14px; }
.agent-box { padding: 4px 16px 12px; display: flex; flex-direction: column; gap: 10px; }
.agent-box h3 { font-family: inherit; font-size: 16px; }
.external-link { align-self: flex-start; min-height: 44px; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; }
