/*
  CaseStep website.
  Layout: the page is the app's own background, an indigo field with a moving glass ribbon,
  and every block floats on it in the app's glass materials. A dashed road with the yellow
  dot (the app mark) runs under the header and tracks how far you've read.
  Colors are the app's tokens (PLAN.md §6.2), light and dark.
*/

:root {
  /* Background and text on it */
  --base: #4339CE;
  --base-hi: #5A51E8;
  --on-bg: #FFFFFF;
  --on-bg-2: rgba(255, 255, 255, 0.80);
  --nav-bg: rgba(67, 57, 206, 0.72);
  --frame-bg: rgba(255, 255, 255, 0.08);

  /* Glass materials */
  --glass: rgba(255, 255, 255, 0.74);
  --glass-thick: rgba(255, 255, 255, 0.82);
  --glass-clear: rgba(255, 255, 255, 0.18);
  --glass-border: rgba(255, 255, 255, 0.60);
  --glass-clear-border: rgba(255, 255, 255, 0.40);
  --glass-hl: rgba(255, 255, 255, 0.90);
  --glass-selected: rgba(79, 70, 229, 0.12);
  --seg-selected: #FFFFFF;
  --sel-bg: #FFFFFF;
  --sel-border: rgba(255, 255, 255, 0.90);
  --sel-fg: #3730A3;

  /* Text on glass */
  --text: #0F172A;
  --text-strong: #3B4452;
  --text-2: #444B5B;
  --text-3: #6B7280;
  --divider: rgba(15, 23, 42, 0.10);
  --chip: rgba(15, 23, 42, 0.07);
  --fill: rgba(15, 23, 42, 0.06);
  --input: rgba(255, 255, 255, 0.72);
  --input-border: rgba(15, 23, 42, 0.12);
  --switch-off: #C5C9D2;
  --switch-knob: #FFFFFF;

  /* Brand */
  --primary: #4F46E5;
  --primary-glow: rgba(79, 70, 229, 0.35);
  --link: #4338CA;
  --highlight: #FBBF24;
  --on-highlight: #1E1B4B;
  --check: #16A34A;
  --mark-road: #FFFFFF;
  --cta-bg: #FFFFFF;
  --cta-fg: #3730A3;
  --timeline: #A5B4FC;
  --shadow: rgba(30, 27, 75, 0.18);
  --bezel: #17152E;
  --bezel-edge: rgba(255, 255, 255, 0.14);
  --phone-shadow: rgba(12, 10, 48, 0.55);

  /* Status tones */
  --progress-bg: #EEF2FF; --progress-fg: #3730A3;
  --action-bg: #FEF3C7;   --action-fg: #92400E;
  --done-bg: #E5F4EB;     --done-fg: #1B6239;
  --neutral-bg: #F0F2F5;  --neutral-fg: #3B4452;
  --danger-bg: #FEE4E2;   --danger-fg: #B42318;

  /* Ribbon strength, read by main.js */
  --ribbon: 0.72;

  /* Type */
  --font-display: "Bricolage Grotesque", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  /* Shape */
  --r-card: 24px;
  --r-panel: 34px;
  --r-row: 14px;
  --r-note: 16px;
  --r-chip: 8px;
  --r-tile: 10px;
  --wrap: 1180px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --base: #181448; --base-hi: #251F66; --on-bg-2: rgba(255, 255, 255, 0.72);
    --nav-bg: rgba(24, 20, 72, 0.74); --frame-bg: rgba(255, 255, 255, 0.04);
    --glass: rgba(22, 20, 52, 0.70); --glass-thick: rgba(22, 20, 52, 0.78); --glass-clear: rgba(255, 255, 255, 0.10);
    --glass-border: rgba(255, 255, 255, 0.14); --glass-clear-border: rgba(255, 255, 255, 0.18); --glass-hl: rgba(255, 255, 255, 0.14);
    --glass-selected: rgba(165, 180, 252, 0.16); --seg-selected: rgba(255, 255, 255, 0.16);
    --sel-bg: rgba(255, 255, 255, 0.22); --sel-border: rgba(255, 255, 255, 0.32); --sel-fg: #FFFFFF;
    --text: #F1F2F8; --text-strong: #C9CBE0; --text-2: #A7A9C4; --text-3: #8E90B4;
    --divider: rgba(255, 255, 255, 0.10); --chip: rgba(255, 255, 255, 0.10); --fill: rgba(255, 255, 255, 0.10);
    --input: rgba(255, 255, 255, 0.06); --input-border: rgba(255, 255, 255, 0.14); --switch-off: #3A3670;
    --primary-glow: rgba(0, 0, 0, 0.35); --link: #A5B4FC; --timeline: #6B66B8; --shadow: rgba(0, 0, 0, 0.40);
    --cta-bg: #FFFFFF; --cta-fg: #312E81; --bezel: #0B0A1C; --phone-shadow: rgba(0, 0, 0, 0.6);
    --progress-bg: #2A2760; --progress-fg: #C7D2FE; --action-bg: #3A2A0A; --action-fg: #FCD34D;
    --done-bg: #12301F; --done-fg: #86EFAC; --neutral-bg: #25224A; --neutral-fg: #C9CBE0;
    --danger-bg: #3D1414; --danger-fg: #F97066;
    --ribbon: 0.5;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --base: #181448; --base-hi: #251F66; --on-bg-2: rgba(255, 255, 255, 0.72);
  --nav-bg: rgba(24, 20, 72, 0.74); --frame-bg: rgba(255, 255, 255, 0.04);
  --glass: rgba(22, 20, 52, 0.70); --glass-thick: rgba(22, 20, 52, 0.78); --glass-clear: rgba(255, 255, 255, 0.10);
  --glass-border: rgba(255, 255, 255, 0.14); --glass-clear-border: rgba(255, 255, 255, 0.18); --glass-hl: rgba(255, 255, 255, 0.14);
  --glass-selected: rgba(165, 180, 252, 0.16); --seg-selected: rgba(255, 255, 255, 0.16);
  --sel-bg: rgba(255, 255, 255, 0.22); --sel-border: rgba(255, 255, 255, 0.32); --sel-fg: #FFFFFF;
  --text: #F1F2F8; --text-strong: #C9CBE0; --text-2: #A7A9C4; --text-3: #8E90B4;
  --divider: rgba(255, 255, 255, 0.10); --chip: rgba(255, 255, 255, 0.10); --fill: rgba(255, 255, 255, 0.10);
  --input: rgba(255, 255, 255, 0.06); --input-border: rgba(255, 255, 255, 0.14); --switch-off: #3A3670;
  --primary-glow: rgba(0, 0, 0, 0.35); --link: #A5B4FC; --timeline: #6B66B8; --shadow: rgba(0, 0, 0, 0.40);
  --cta-bg: #FFFFFF; --cta-fg: #312E81; --bezel: #0B0A1C; --phone-shadow: rgba(0, 0, 0, 0.6);
  --progress-bg: #2A2760; --progress-fg: #C7D2FE; --action-bg: #3A2A0A; --action-fg: #FCD34D;
  --done-bg: #12301F; --done-fg: #86EFAC; --neutral-bg: #25224A; --neutral-fg: #C9CBE0;
  --danger-bg: #3D1414; --danger-fg: #F97066;
  --ribbon: 0.5;
  color-scheme: dark;
}

/* Reduce Transparency means solid, as in the app. */
@media (prefers-reduced-transparency: reduce) {
  :root { --glass: #FFFFFF; --glass-thick: #FFFFFF; --glass-clear: #4F46E5; --frame-bg: transparent; }
  :root[data-theme="dark"] { --glass: #1A1838; --glass-thick: #232046; }
}
@media (prefers-reduced-transparency: reduce) and (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --glass: #1A1838; --glass-thick: #232046; }
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
body {
  margin: 0;
  background: radial-gradient(90rem 60rem at 85% -20%, var(--base-hi), transparent 60%), var(--base);
  background-attachment: fixed;
  color: var(--on-bg);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: env(safe-area-inset-top, 0px);
  z-index: 30;
  background: var(--base);
}
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
a { color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
img, svg, canvas { max-width: 100%; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.nowrap { white-space: nowrap; }
.ico { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 2px solid var(--highlight); outline-offset: 3px; border-radius: 6px; }
.glass :focus-visible, .glass-thick :focus-visible { outline-color: var(--link); }

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

.ribbon { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
main, .footer { position: relative; z-index: 1; }

/* Glass */
.glass, .glass-thick, .glass-clear {
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 1px 0 var(--glass-hl), 0 18px 40px -18px var(--shadow);
}
.glass { background: var(--glass); color: var(--text); -webkit-backdrop-filter: blur(24px) saturate(170%); backdrop-filter: blur(24px) saturate(170%); }
.glass-thick { background: var(--glass-thick); color: var(--text); -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%); }
.glass-clear { background: var(--glass-clear); border-color: var(--glass-clear-border); color: var(--on-bg); box-shadow: inset 0 1px 0 var(--glass-clear-border); -webkit-backdrop-filter: blur(16px) saturate(180%); backdrop-filter: blur(16px) saturate(180%); }

/* Mark */
.mark { display: block; width: 32px; height: 32px; flex: none; }
.mark .m-bg { fill: var(--primary); }
.mark .m-road { fill: none; stroke: var(--mark-road); stroke-width: 10; stroke-linecap: round; }
.mark .m-dash { fill: none; stroke: var(--primary); stroke-width: 1.6; stroke-linecap: round; stroke-dasharray: 2.5 3; }
.mark .m-dot { fill: var(--highlight); }
.mark .m-check { opacity: 0; transition: opacity 0.2s; }
.mark .m-check circle { fill: var(--check); }
.mark .m-check path { fill: none; stroke: var(--mark-road); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mark-bare .m-dash { stroke: var(--base); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 24px; border-radius: 999px; border: 0;
  font-weight: 600; font-size: 16px; text-decoration: none; cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 15px; }
.btn-light { background: var(--cta-bg); color: var(--cta-fg); box-shadow: 0 10px 30px -10px var(--phone-shadow), inset 0 -2px 0 rgba(55, 48, 163, 0.08); }
.btn-light:hover { transform: translateY(-1px); box-shadow: 0 14px 34px -10px var(--phone-shadow); }
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; cursor: pointer;
  background: var(--glass-clear); border: 1px solid var(--glass-clear-border); color: var(--on-bg);
}
.icon-btn .ico { width: 20px; height: 20px; }

/* Header */
.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; }
.nav::before {
  content: ""; position: absolute; inset: 0;
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(18px) saturate(180%); backdrop-filter: blur(18px) saturate(180%);
  opacity: 0; transition: opacity 0.3s;
}
.nav.scrolled::before { opacity: 1; }
.nav-inner {
  position: relative; display: flex; align-items: center; gap: 20px;
  max-width: var(--wrap); margin-inline: auto; padding-block: 12px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: 21px; letter-spacing: -0.02em; min-height: 44px; }
.brand .mark { width: 34px; height: 34px; }
.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a { padding: 10px 12px; border-radius: 999px; color: var(--on-bg-2); text-decoration: none; font-size: 15px; font-weight: 500; transition: color 0.2s, background-color 0.2s; }
.nav-links a:hover { color: var(--on-bg); background: var(--glass-clear); }
.nav-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.road {
  position: relative; height: 4px; max-width: var(--wrap); margin-inline: auto;
  background: repeating-linear-gradient(90deg, var(--on-bg-2) 0 6px, transparent 6px 13px) center / 100% 2px no-repeat;
  opacity: 0.55; transition: opacity 0.3s;
}
.nav.scrolled .road { opacity: 0.85; }
.road-dot {
  position: absolute; top: 50%; left: 0; width: 12px; height: 12px; margin-top: -6px; border-radius: 50%;
  background: var(--highlight); box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.25), 0 0 16px rgba(251, 191, 36, 0.6);
  will-change: transform;
}
@media (max-width: 980px) { .nav-links { display: none; } }

/* Phone menu: the nav links in a panel of the header's own glass. Needs JS to open, so without it the
   button and panel stay hidden and the bar keeps its Get CaseStep button. */
.menu-btn, .menu { display: none; }
.menu-btn path { transition: transform 0.25s; transform-box: fill-box; transform-origin: center; }
.menu-btn[aria-expanded="true"] .mb-1 { transform: translateY(3px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .mb-2 { transform: translateY(-3px) rotate(-45deg); }
.nav.menu-open::before { opacity: 1; }
.nav.menu-open .road { opacity: 0.85; }
@media (max-width: 980px) {
  .js .menu-btn { display: inline-grid; }
  .js .menu {
    display: flex; flex-direction: column; gap: 10px;
    position: absolute; top: calc(100% + 8px);
    left: max(12px, env(safe-area-inset-left, 0px)); right: max(12px, env(safe-area-inset-right, 0px));
    max-height: calc(100dvh - 110px); overflow-y: auto; overscroll-behavior: contain;
    padding: 10px; border-radius: 26px; border: 1px solid var(--glass-clear-border);
    background: var(--nav-bg); color: var(--on-bg);
    -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
    box-shadow: 0 24px 60px -20px var(--phone-shadow);
    opacity: 0; visibility: hidden; transform: translateY(-8px) scale(0.98); transform-origin: top right;
    transition: opacity 0.2s, transform 0.2s, visibility 0s 0.2s;
  }
  .js .menu.open { opacity: 1; visibility: visible; transform: none; transition: opacity 0.2s, transform 0.2s, visibility 0s; }
}
.menu nav { display: flex; flex-direction: column; gap: 2px; }
.menu nav a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; padding: 0 16px;
  border-radius: 16px; color: var(--on-bg); text-decoration: none; font-size: 17px; font-weight: 600; transition: background-color 0.2s;
}
.menu nav a:hover, .menu nav a:active { background: var(--glass-clear); }
.menu nav a .ico { width: 18px; height: 18px; color: var(--on-bg-2); }
.menu .btn { width: 100%; }
@media (min-width: 561px) { .menu .btn { display: none; } }
@media (max-width: 560px) { .js .nav-actions .btn-sm { display: none; } }

/* Hero */
.hero { padding-block: clamp(40px, 7vw, 88px) clamp(48px, 7vw, 96px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero-copy { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.eyebrow {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px 7px 10px; border-radius: 999px; background: var(--glass-clear); border: 1px solid var(--glass-clear-border);
  font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase;
}
.eyebrow-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--highlight); }
h1 {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(2.6rem, 6.4vw, 5rem);
  line-height: 0.98; letter-spacing: -0.04em; font-variation-settings: "opsz" 96;
}
.lede { font-size: clamp(1.08rem, 1.6vw, 1.25rem); line-height: 1.55; color: var(--on-bg-2); max-width: 36em; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
.soon { display: inline-flex; align-items: center; gap: 10px; font-weight: 500; color: var(--on-bg-2); }
.soon-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--highlight); box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.6); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0.55); } 70% { box-shadow: 0 0 0 10px rgba(251, 191, 36, 0); } 100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); } }
.trust { display: flex; flex-wrap: wrap; gap: 10px 22px; font-size: 14.5px; color: var(--on-bg-2); }
.trust li { display: inline-flex; align-items: center; gap: 8px; }
.hero-device { display: flex; justify-content: center; min-width: 0; }

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
}

/* Phone */
.phone {
  position: relative; width: min(318px, 100%); aspect-ratio: 9 / 19.2; border-radius: 54px; padding: 11px;
  background: var(--bezel);
  box-shadow: 0 50px 90px -40px var(--phone-shadow), inset 0 0 0 1.5px var(--bezel-edge), 0 0 0 1px rgba(0, 0, 0, 0.25);
}
.phone::after { /* the camera island */
  content: ""; position: absolute; top: 22px; left: 50%; width: 31%; height: 3.3%; transform: translateX(-50%);
  border-radius: 999px; background: var(--bezel); z-index: 5;
}
.phone-screen {
  position: absolute; inset: 11px; overflow: hidden; border-radius: 44px; background: var(--base);
  container-type: inline-size; color: var(--on-bg);
}
.phone-screen > * { font-size: 4.3cqw; }
.screen-bg { position: absolute; inset: 0; width: 100%; height: 100%; }
.status-bar {
  position: relative; display: flex; justify-content: space-between; align-items: center;
  padding: 5.4cqw 8cqw 0 10cqw; font-weight: 600; font-size: 4.6cqw; height: 13cqw;
}
.sb-icons { display: inline-flex; gap: 1.4cqw; align-items: flex-end; }
.sb-icons i { display: block; width: 1.4cqw; background: var(--on-bg); border-radius: 0.5cqw; }
.sb-icons i:nth-child(1) { height: 1.8cqw; } .sb-icons i:nth-child(2) { height: 2.6cqw; } .sb-icons i:nth-child(3) { width: 6cqw; height: 2.8cqw; border-radius: 1cqw; }
.screen-body { position: relative; padding: 2cqw 4.6cqw 0; display: flex; flex-direction: column; gap: 3cqw; }
.screen-caption { font-size: 0.82em; color: var(--on-bg-2); margin-top: 1cqw; }
.screen-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.5cqw; }
.title-word { display: inline-flex; align-items: center; font-weight: 700; font-size: 2.2em; letter-spacing: -0.02em; line-height: 1; }
.title-word .mark { width: 0.92em; height: 0.92em; margin-right: -0.1em; transform: scale(1.5); transform-origin: 70% 50%; }
.round-btn { display: grid; place-items: center; width: 11cqw; height: 11cqw; border-radius: 50%; background: var(--glass-clear); border: 1px solid var(--glass-clear-border); }
.round-btn .ico { width: 5.4cqw; height: 5.4cqw; }

.case { border-radius: 6.4cqw; padding: 3.8cqw; display: flex; flex-direction: column; gap: 2.6cqw; }
.case-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.case-id { min-width: 0; }
.case-name { font-weight: 600; font-size: 1.12em; line-height: 1.25; }
.receipt { font-family: var(--font-mono); font-weight: 500; font-size: 0.86em; color: var(--text-2); letter-spacing: 0.02em; }
.form-chip { display: inline-block; font-family: var(--font-mono); font-weight: 500; font-size: 12px; line-height: 1.5; padding: 2px 8px; border-radius: var(--r-chip); background: var(--chip); color: var(--text-strong); white-space: nowrap; }
.case .form-chip { font-size: 0.82em; }
.status-row {
  display: flex; align-items: center; gap: 0.6em; padding: 0.6em 0.75em; border-radius: var(--r-row);
  background: var(--tone-bg); color: var(--tone-fg); font-weight: 600; font-size: 0.92em; line-height: 1.3;
  transition: background-color 0.5s, color 0.5s;
}
.status-row .dot { width: 0.5em; height: 0.5em; border-radius: 50%; background: currentColor; flex: none; }
.status-row .st { min-width: 0; }
.case-foot { display: flex; align-items: center; justify-content: space-between; font-size: 0.82em; color: var(--text-2); min-height: 1.6em; }
.badge-updated { background: var(--highlight); color: var(--on-highlight); font-weight: 700; font-size: 0.86em; padding: 0.1em 0.6em; border-radius: 999px; transition: opacity 0.3s, transform 0.3s; }
.badge-updated.off { opacity: 0; transform: scale(0.6); }

.tone-progress { --tone-bg: var(--progress-bg); --tone-fg: var(--progress-fg); }
.tone-action { --tone-bg: var(--action-bg); --tone-fg: var(--action-fg); }
.tone-done { --tone-bg: var(--done-bg); --tone-fg: var(--done-fg); }
.tone-neutral { --tone-bg: var(--neutral-bg); --tone-fg: var(--neutral-fg); }
.tone-danger { --tone-bg: var(--danger-bg); --tone-fg: var(--danger-fg); }

.notif {
  display: flex; gap: 2.8cqw; align-items: flex-start; padding: 3cqw 3.4cqw; border-radius: 6cqw;
  background: var(--glass-thick); color: var(--text); border: 1px solid var(--glass-border);
  -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 0 10px 30px -10px var(--shadow);
}
.notif-mark { width: 9cqw; height: 9cqw; }
.notif-mark .m-bg { rx: 15; }
.notif-text { min-width: 0; flex: 1; font-size: 0.86em; line-height: 1.32; }
.notif-app { display: flex; justify-content: space-between; color: var(--text-2); font-size: 0.9em; }
.notif-title { font-weight: 600; }
.notif-body { color: var(--text-strong); }
#hero-notif {
  position: absolute; top: 3.6cqw; left: 3cqw; right: 3cqw; z-index: 6;
  transform: translateY(-140%); transition: transform 0.55s cubic-bezier(0.2, 0.9, 0.3, 1.15);
}
#hero-notif.show { transform: translateY(0); }

.tabbar {
  position: absolute; left: 6cqw; right: 6cqw; bottom: 5cqw; display: flex; justify-content: space-around;
  padding: 2cqw 2cqw; border-radius: 999px;
}
.tab { display: flex; flex-direction: column; align-items: center; gap: 0.6cqw; font-size: 2.9cqw; font-weight: 600; color: var(--text-3); padding: 1cqw 3cqw; border-radius: 999px; }
.tab .ico { width: 5.6cqw; height: 5.6cqw; }
.tab.on { color: var(--primary); background: var(--glass-selected); }

/* "What's in the app" strip */
.tab-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: clamp(40px, 6vw, 72px); }
.strip-item {
  display: flex; gap: 12px; align-items: flex-start; height: 100%; padding: 16px; border-radius: 20px; text-decoration: none;
  background: var(--glass-clear); border: 1px solid var(--glass-clear-border);
  -webkit-backdrop-filter: blur(16px) saturate(180%); backdrop-filter: blur(16px) saturate(180%);
  transition: transform 0.2s, background-color 0.2s;
}
.strip-item:hover { transform: translateY(-2px); }
.strip-item strong { display: block; font-size: 16px; }
.strip-item span:last-child { font-size: 14px; color: var(--on-bg-2); line-height: 1.4; min-width: 0; }
.strip-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-tile); background: var(--cta-bg); color: var(--primary); flex: none; }
@media (max-width: 900px) { .tab-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 460px) { .tab-strip { grid-template-columns: minmax(0, 1fr); } }

/* Sections */
.section { padding-block: clamp(72px, 10vw, 128px); }
.sec-head { display: flex; flex-direction: column; gap: 14px; max-width: 46rem; margin-bottom: clamp(28px, 4vw, 48px); }
.kicker { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--on-bg-2); }
.kicker::before { content: ""; width: 26px; height: 2px; background: repeating-linear-gradient(90deg, var(--on-bg-2) 0 4px, transparent 4px 8px); }
.kicker::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--highlight); order: -1; margin-right: -4px; }
h2 { font-family: var(--font-display); font-weight: 800; font-size: clamp(2.1rem, 4.6vw, 3.5rem); line-height: 1.02; letter-spacing: -0.035em; font-variation-settings: "opsz" 96; }
.sec-lede { font-size: clamp(1.05rem, 1.5vw, 1.2rem); line-height: 1.55; color: var(--on-bg-2); max-width: 40em; }

/* Bento tiles */
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.span-2 { grid-column: span 2; }
.span-3 { grid-column: span 3; }
.tile { border-radius: var(--r-card); padding: clamp(20px, 2.4vw, 28px); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.tile h3 { font-family: var(--font-display); font-weight: 700; font-size: 1.4rem; line-height: 1.15; letter-spacing: -0.02em; }
:where(.tile, .tile-copy) > p { color: var(--text-2); font-size: 15.5px; line-height: 1.55; }
:where(.tile, .tile-copy) > p.small { font-size: 14px; color: var(--text-3); }
.tile-copy { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
@media (max-width: 900px) {
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .span-3 { grid-column: span 2; }
}
@media (max-width: 640px) {
  .bento { grid-template-columns: minmax(0, 1fr); }
  .span-2, .span-3 { grid-column: auto; }
}

/* Add case demo */
.tile-add { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 24px; align-items: start; }
@media (max-width: 760px) { .tile-add { grid-template-columns: minmax(0, 1fr); } }
.add-demo { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 20px; border-radius: 26px; background: var(--fill); }
.sheet-title { font-weight: 700; font-size: 18px; color: var(--text); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: 13px; font-weight: 600; color: var(--text-strong); }
.field-label .opt { font-weight: 400; color: var(--text-3); }
.input { display: flex; align-items: center; min-height: 52px; padding: 0 16px; border-radius: 16px; background: var(--input); border: 1px solid var(--input-border); color: var(--text); font-size: 16px; }
.input.mono { font-family: var(--font-mono); font-weight: 500; font-size: 17px; letter-spacing: 0.03em; }
.caret { width: 2px; height: 22px; margin-left: 2px; background: var(--primary); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.field-hint { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--text-3); min-height: 20px; }
.field-hint .ico { display: none; }
.field-hint.ok { color: var(--done-fg); }
.field-hint.ok .ico { display: block; }
.field-hint .mono, .field-hint b { font-family: var(--font-mono); font-weight: 500; }
.note { font-size: 13.5px; color: var(--text-2); background: var(--fill); padding: 10px 12px; border-radius: var(--r-note); }
.add-btn {
  display: grid; place-items: center; min-height: 52px; border-radius: 999px; background: var(--primary); color: #FFFFFF;
  font-weight: 600; box-shadow: 0 10px 24px -10px var(--primary-glow), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.add-btn > span { grid-area: 1 / 1; display: inline-flex; align-items: center; gap: 10px; transition: opacity 0.25s; }
.add-checking { opacity: 0; }
.add-btn.checking .add-label { opacity: 0; }
.add-btn.checking .add-checking { opacity: 1; }
.mark-inline { width: 26px; height: 26px; }
.mark-inline .m-bg { fill: #3730A3; }
.mark-inline .m-dash { stroke: #3730A3; }
.toast {
  position: absolute; left: 12px; right: 12px; top: 12px; display: flex; gap: 12px; align-items: center;
  padding: 12px 14px; border-radius: 24px; font-size: 14px; line-height: 1.35;
  opacity: 0; transform: translateY(-12px); transition: opacity 0.35s, transform 0.35s; pointer-events: none;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast strong { display: block; color: var(--text); }
.toast span:last-child { color: var(--text-2); }
.toast-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-tile); background: var(--tone-bg); color: var(--tone-fg); flex: none; }

/* Phases */
.phases { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.phases li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-strong); }
.phases li > span:last-child { min-width: 0; }
.pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; white-space: nowrap;
  background: var(--tone-bg); color: var(--tone-fg); font-size: 13px; font-weight: 600; line-height: 1.45; flex: none;
}
.pill .ico { width: 15px; height: 15px; stroke-width: 2.2; }
.phases .pill { min-width: 7.4em; justify-content: center; }

/* Detail + timeline */
.tile-detail { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 24px; align-items: start; }
@media (max-width: 760px) { .tile-detail { grid-template-columns: minmax(0, 1fr); } }
.detail-demo { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.status-card, .history { padding: 18px; border-radius: 20px; background: var(--fill); display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.status-title { font-weight: 700; font-size: 18px; line-height: 1.3; color: var(--text); }
.tile .status-desc { font-size: 14px; color: var(--text-2); }
.tile .status-meta { font-size: 13px; color: var(--text-3); }
.history { align-items: stretch; gap: 4px; }
.history-title { font-weight: 600; font-size: 15px; color: var(--text); margin-bottom: 6px; }
.timeline { position: relative; display: flex; flex-direction: column; }
.timeline li { position: relative; display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 4px 12px; align-items: start; padding-bottom: 14px; }
.timeline li::before { /* the dashed path */
  content: ""; position: absolute; left: 10px; top: 16px; bottom: -2px; width: 0; border-left: 2px dashed var(--timeline);
}
.timeline li:last-child::before { bottom: 6px; border-left-style: dashed; opacity: 0.6; }
.tl-dot { position: relative; z-index: 1; width: 12px; height: 12px; margin: 4px 0 0 5px; border-radius: 50%; background: var(--primary); }
.timeline li.now .tl-dot { width: 18px; height: 18px; margin: 1px 0 0 2px; background: var(--highlight); box-shadow: 0 0 0 3px var(--primary); }
.timeline li.now .tl-dot::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 2px solid var(--highlight); opacity: 0; animation: ring 2.4s infinite; }
@keyframes ring { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(1.5); opacity: 0; } }
.tl-title { font-size: 14px; font-weight: 600; color: var(--text); line-height: 1.35; }
.timeline li:not(.now) .tl-title { font-weight: 500; color: var(--text-strong); }
.tl-date { font-size: 13px; color: var(--text-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.show-all { font-size: 14px; font-weight: 600; color: var(--link); padding-left: 34px; }

/* Waiting tile */
.mini-case { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 14px; border-radius: 18px; background: var(--fill); font-size: 15px; }
.mini-case .case-head { width: 100%; }
.mini-case .receipt { font-size: 13px; }
.tile .mini-note { font-size: 13.5px; color: var(--text-2); }
.edit-link { font-size: 14px; font-weight: 600; color: var(--link); }

/* Priority date */
.tile-priority { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 28px; align-items: center; }
@media (max-width: 860px) { .tile-priority { grid-template-columns: minmax(0, 1fr); } }
.pd-table { width: 100%; border-collapse: collapse; font-size: 14.5px; color: var(--text-strong); margin-top: 6px; }
.pd-table th { text-align: left; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); padding: 0 12px 8px 0; }
.pd-table td { padding: 10px 12px 10px 0; border-top: 1px solid var(--divider); vertical-align: top; }
.pd-table td:first-child { width: 42%; line-height: 2; }
.pd-card { display: flex; flex-direction: column; gap: 10px; padding: 20px; border-radius: 22px; background: var(--fill); }
.pd-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pd-title { font-weight: 600; font-size: 16px; color: var(--text); }
.chip-amber { padding: 3px 10px; border-radius: 999px; background: var(--action-bg); color: var(--action-fg); font-size: 13px; font-weight: 600; }
.pd-date { font-weight: 700; font-size: 30px; letter-spacing: -0.02em; color: var(--text); font-variant-numeric: tabular-nums; }
.tile .pd-text { font-size: 14px; }
.pd-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.mini-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 0;
  background: var(--fill); color: var(--link); font-weight: 600; font-size: 14px; white-space: nowrap; cursor: default;
}
.mini-btn.primary { background: var(--primary); color: #FFFFFF; box-shadow: 0 8px 18px -8px var(--primary-glow); }
button.mini-btn { cursor: pointer; min-height: 44px; }

/* Split layout */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.split-wide { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); align-items: start; }
.split-flip { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
.split-flip .split-copy { order: 2; }
@media (min-width: 901px) { .split-wide .split-copy { position: sticky; top: 110px; } }
.split-copy { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.split-copy .sec-head { margin-bottom: 0; }
.split-device { display: flex; justify-content: center; min-width: 0; }
@media (max-width: 900px) {
  .split, .split-wide, .split-flip { grid-template-columns: minmax(0, 1fr); }
  .split-flip .split-copy { order: 0; }
}

/* Settings group with switches */
.settings { border-radius: var(--r-card); padding: 6px 18px 10px; }
.settings-group { font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); padding: 14px 0 4px; }
.set-row { display: flex; align-items: center; gap: 14px; min-height: 64px; border-bottom: 1px solid var(--divider); }
.set-row:last-child { border-bottom: 0; }
.set-row label { flex: 1; min-width: 0; display: flex; flex-direction: column; cursor: pointer; padding-block: 8px; }
.set-row strong { font-weight: 600; font-size: 16px; color: var(--text); }
.set-row label span { font-size: 13.5px; color: var(--text-2); line-height: 1.4; }
.switch {
  appearance: none; -webkit-appearance: none; position: relative; flex: none; margin: 0; cursor: pointer;
  width: 52px; height: 32px; border-radius: 999px; background: var(--switch-off); transition: background-color 0.25s;
}
.switch::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--switch-knob); box-shadow: 0 2px 6px rgba(15, 23, 42, 0.25); transition: transform 0.25s cubic-bezier(0.3, 1.3, 0.5, 1);
}
.switch:checked { background: var(--check); }
.switch:checked::after { transform: translateX(20px); }
.switch:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; }

.facts { display: flex; flex-direction: column; gap: 14px; }
.facts li { position: relative; padding-left: 22px; color: var(--on-bg-2); line-height: 1.55; }
.facts li::before { content: ""; position: absolute; left: 2px; top: 0.6em; width: 9px; height: 9px; border-radius: 50%; background: var(--highlight); }
.facts strong { color: var(--on-bg); font-weight: 600; }

/* Lock screen */
.phone-lock .phone-screen { display: flex; flex-direction: column; }
.lock-top { position: relative; display: flex; flex-direction: column; align-items: center; padding-top: 4cqw; text-align: center; }
.lock-ico { width: 5.4cqw; height: 5.4cqw; }
.lock-date { font-weight: 600; font-size: 4.8cqw; margin-top: 2cqw; color: var(--on-bg-2); }
.lock-time { font-family: var(--font-display); font-weight: 700; font-size: 22cqw; line-height: 1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.lock-stack { position: relative; display: flex; flex-direction: column; gap: 2.6cqw; padding: 6cqw 3.4cqw 0; }
.lock-n { transition: opacity 0.35s, transform 0.35s, max-height 0.35s, padding 0.35s, margin 0.35s; max-height: 40cqw; }
.lock-n.off { opacity: 0; transform: scale(0.94); max-height: 0; padding-block: 0; margin-top: -2.6cqw; border-width: 0; overflow: hidden; }
.lock-empty { text-align: center; font-size: 0.9em; color: var(--on-bg-2); display: none; padding-top: 6cqw; }
.lock-empty.show { display: block; }
.notif-body .swap { transition: opacity 0.2s; }

/* Ticks list */
.ticks { display: flex; flex-direction: column; gap: 12px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; line-height: 1.5; }
.ticks li::before {
  content: ""; flex: none; width: 22px; height: 22px; margin-top: 1px; border-radius: 50%;
  background: var(--cta-bg) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234F46E5' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.source-note { font-size: 13.5px; color: var(--on-bg-2); border-left: 2px dashed var(--on-bg-2); padding-left: 12px; }

/* App frame (a screen without the phone) */
.app-frame {
  display: flex; flex-direction: column; gap: 16px; min-width: 0;
  padding: clamp(16px, 2.6vw, 26px); border-radius: var(--r-panel);
  background: var(--frame-bg); border: 1px solid var(--glass-clear-border);
}
.frame-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.frame-title { font-weight: 700; font-size: clamp(26px, 3vw, 32px); letter-spacing: -0.02em; line-height: 1.15; }
.frame-caption { font-size: 14px; color: var(--on-bg-2); margin-top: 2px; }
.frame-foot { font-size: 12.5px; color: var(--on-bg-2); line-height: 1.5; }
.month-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px; white-space: nowrap;
  background: var(--glass-clear); border: 1px solid var(--glass-clear-border); font-weight: 600; font-size: 14px;
}
.month-btn .ico { width: 16px; height: 16px; }

/* Segmented controls and chips */
.seg { display: flex; padding: 3px; border-radius: 999px; gap: 2px; }
.seg button {
  flex: 1; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid transparent; background: transparent;
  font-weight: 600; font-size: 14.5px; cursor: pointer; transition: background-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.seg-bg { background: var(--glass-clear); border: 1px solid var(--glass-clear-border); }
.seg-bg button { color: var(--on-bg-2); }
.seg-bg button[aria-pressed="true"] { background: var(--sel-bg); border-color: var(--sel-border); color: var(--sel-fg); }
.seg-glass { background: var(--fill); }
.seg-glass button { color: var(--text-2); }
.seg-glass button[aria-pressed="true"] { background: var(--seg-selected); color: var(--text); box-shadow: 0 2px 8px -2px var(--shadow); }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; margin-inline: -4px; padding-inline: 4px; }
.chips::-webkit-scrollbar { display: none; }
.chips button {
  flex: none; min-height: 40px; padding: 0 16px; border-radius: 999px; cursor: pointer;
  background: var(--glass-clear); border: 1px solid var(--glass-clear-border); color: var(--on-bg); font-weight: 600; font-size: 14.5px; white-space: nowrap;
  transition: background-color 0.2s, color 0.2s;
}
.chips button[aria-pressed="true"] { background: var(--sel-bg); border-color: var(--sel-border); color: var(--sel-fg); }

/* Visa Bulletin card */
.vb-card { border-radius: var(--r-card); padding: 20px; display: flex; flex-direction: column; gap: 14px; }
.vb-title { font-weight: 700; font-size: 20px; letter-spacing: -0.01em; color: var(--text); }
.vb-desc { font-size: 14.5px; color: var(--text-2); margin-top: -8px; }
.vb-live { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.vb-label { font-size: 14px; font-weight: 600; color: var(--text-2); }
.vb-value { font-weight: 700; font-size: clamp(34px, 4.6vw, 40px); line-height: 1.15; letter-spacing: -0.02em; color: var(--text); font-variant-numeric: tabular-nums; }
.vb-value.flash { animation: flash 0.5s ease-out; }
@keyframes flash { from { transform: translateY(6px); opacity: 0.2; } to { transform: none; opacity: 1; } }
.vb-explain { font-size: 14.5px; color: var(--text-2); line-height: 1.5; }
.vb-uscis { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; border-radius: var(--r-note); background: var(--tone-bg); color: var(--tone-fg); font-size: 14px; font-weight: 500; line-height: 1.45; }
.vb-uscis span { flex: 1; min-width: 0; }
.vb-uscis .mini-btn { background: var(--glass-thick); }
.vb-countries { border-radius: var(--r-card); padding: 16px 8px 8px; }
.list-title { font-weight: 600; font-size: 16px; color: var(--text); padding: 0 12px; }
.list-sub { font-size: 13.5px; color: var(--text-2); padding: 0 12px 8px; }
.vb-countries li + li { border-top: 1px solid var(--divider); }
.vb-countries button {
  width: 100%; display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 0 12px; border: 0; border-radius: 12px;
  background: transparent; color: var(--text); font-size: 15px; text-align: left; cursor: pointer;
}
.vb-countries button[aria-pressed="true"] { background: var(--glass-selected); font-weight: 600; }
.vb-countries .c-name { flex: 1; min-width: 0; }
.vb-countries .c-val { font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.vb-countries .c-arrow { width: 18px; height: 18px; flex: none; }
.c-arrow.up { color: var(--done-fg); }
.c-arrow.down { color: var(--danger-fg); }
.c-arrow.flat { opacity: 0; }

/* Processing times */
.pt-select { border-radius: var(--r-card); padding: 4px 0; }
.sel-row { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; align-items: center; padding: 12px 18px; min-height: 64px; cursor: pointer; }
.sel-row + .sel-row { border-top: 1px solid var(--divider); }
.sel-label { grid-column: 1; font-size: 13px; color: var(--text-2); }
.sel-value { grid-column: 1; display: flex; align-items: baseline; gap: 8px; font-weight: 600; font-size: 15.5px; line-height: 1.4; color: var(--text); min-width: 0; }
.sel-value .form-chip { flex: none; }
.sel-chev { grid-column: 2; grid-row: 1 / span 2; width: 18px; height: 18px; color: var(--text-3); }
.sel-native { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 16px; }
.sel-row:focus-within { outline: 2px solid var(--link); outline-offset: -4px; border-radius: 18px; }
.sel-row.single { cursor: default; }
.sel-row.single .sel-chev, .sel-row.single .sel-native { display: none; }
.pt-result { border-radius: var(--r-card); padding: 20px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.pt-r-title { font-weight: 600; font-size: 16px; color: var(--text); }
.pt-r-sub { font-size: 13.5px; color: var(--text-2); margin-top: -6px; }
.pt-range { display: flex; align-items: baseline; gap: 10px; margin-top: 4px; color: var(--text); }
.pt-range #pt-range { font-weight: 700; font-size: clamp(40px, 5.4vw, 52px); line-height: 1.05; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.unit { font-weight: 600; font-size: 16px; color: var(--text-2); }
.pt-inquiry { width: 100%; margin-top: 8px; padding-top: 14px; border-top: 1px solid var(--divider); display: flex; flex-direction: column; gap: 2px; }
.pt-i-label { font-size: 13.5px; color: var(--text-2); font-weight: 600; }
.pt-i-date { font-weight: 700; font-size: 22px; color: var(--text); font-variant-numeric: tabular-nums; }
.pt-i-text { font-size: 14px; color: var(--text-2); line-height: 1.5; }
.pt-data { font-size: 12.5px; color: var(--text-3); }
.pt-case { border-radius: var(--r-card); padding: 18px; display: flex; flex-direction: column; gap: 6px; }
.pt-case-head { display: flex; justify-content: space-between; align-items: center; }
.pt-case-sub { font-size: 13.5px; color: var(--text-2); }
.pt-case-range { font-weight: 700; font-size: 26px; color: var(--text); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.pt-case-choice { font-size: 13.5px; color: var(--text-2); line-height: 1.45; }
.ask { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin-top: 6px; padding: 14px; border-radius: var(--r-note); background: var(--tone-bg); color: var(--tone-fg); font-size: 14px; line-height: 1.45; }
.ask .mini-btn { background: var(--glass-thick); margin-top: 4px; }

/* Privacy */
.privacy-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.privacy-grid .tile h3 { font-size: 1.15rem; line-height: 1.25; }
.privacy-grid .tile p { font-size: 14.5px; }
.ico-tile { display: grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-tile); background: var(--primary); color: #FFFFFF; flex: none; }
.ico-tile .ico { width: 21px; height: 21px; }
@media (max-width: 1040px) { .privacy-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .privacy-grid { grid-template-columns: minmax(0, 1fr); } }
.affil { display: flex; align-items: center; gap: 10px; margin-top: 24px; color: var(--on-bg-2); font-size: 15px; }
.affil a { color: var(--on-bg); text-underline-offset: 3px; }

/* Everyone */

.lang-line {
  font-family: var(--font-display); font-weight: 800; font-size: clamp(1.9rem, 3.6vw, 2.8rem); line-height: 1.1; letter-spacing: -0.03em;
  color: var(--text); padding-block: 14px; min-height: 2.6em; display: flex; align-items: center;
  transition: opacity 0.35s, transform 0.35s;
}
.lang-line:lang(zh-Hans), .lang-line:lang(ko) { font-family: var(--font-body); letter-spacing: -0.01em; }
.lang-line.out { opacity: 0; transform: translateY(8px); }
.lang-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.lang-chips button {
  min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--input-border); background: var(--fill);
  color: var(--text-strong); font-weight: 600; font-size: 14.5px; cursor: pointer;
}
.lang-chips button[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #FFFFFF; }
.bento-everyone .seg { margin-top: auto; }

/* FAQ */
.faq-wrap { display: grid; grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
@media (max-width: 860px) { .faq-wrap { grid-template-columns: minmax(0, 1fr); } }
.faq { display: flex; flex-direction: column; gap: 10px; }
.faq details { border-radius: 20px; }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; padding: 14px 20px;
  font-weight: 600; font-size: 16.5px; cursor: pointer; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--fill)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234F46E5' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 14px no-repeat;
  transition: transform 0.25s;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 20px 18px; color: var(--text-2); font-size: 15.5px; line-height: 1.6; max-width: 62ch; }

/* Get */
.get-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 18px; }
.mark-hero { width: 112px; height: 112px; border-radius: 28px; box-shadow: 0 30px 60px -24px var(--phone-shadow); }
.store-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 8px; }
.store { display: inline-flex; flex-direction: column; align-items: flex-start; min-width: 190px; padding: 10px 22px; border-radius: 16px; font-weight: 700; font-size: 19px; line-height: 1.2; }
.store small { font-weight: 500; font-size: 12px; color: var(--on-bg-2); }

/* Footer */
.footer { padding-block: 48px 40px; border-top: 1px solid var(--glass-clear-border); background: var(--frame-bg); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.55fr) minmax(0, 0.6fr) minmax(0, 1fr); gap: 32px; }
@media (max-width: 980px) { .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 640px) { .footer-grid { grid-template-columns: minmax(0, 1fr); } }
.footer-brand { display: flex; flex-direction: column; gap: 8px; color: var(--on-bg-2); }
.footer-col { display: flex; flex-direction: column; gap: 2px; }
.footer-h { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-bg-2); margin-bottom: 6px; }
.footer-col a { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; color: var(--on-bg); text-decoration: none; font-size: 15px; }
.footer-col a:hover { text-decoration: underline; text-underline-offset: 3px; }
.footer-col a .ico { width: 14px; height: 14px; opacity: 0.7; }
.footer-legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--glass-clear-border); font-size: 13.5px; color: var(--on-bg-2); }
.footer-legal p:first-child { max-width: 60ch; }

/* ---------- Legal pages (privacy.html, terms.html, delete-account.html) ---------- */
.legal-hero { padding-block: clamp(36px, 6vw, 80px) clamp(28px, 4vw, 44px); }
.legal-hero .wrap { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; }
.legal-hero .sec-lede { max-width: 44em; }
.doc-switch { display: inline-flex; flex-wrap: wrap; gap: 4px; max-width: 100%; padding: 4px; border-radius: 24px; }
.doc-switch a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 999px; color: var(--on-bg-2); text-decoration: none; font-size: 14.5px; font-weight: 600; transition: background-color 0.2s, color 0.2s; }
.doc-switch a:hover { color: var(--on-bg); }
.doc-switch a[aria-current="page"] { background: var(--cta-bg); color: var(--cta-fg); }
@media (max-width: 600px) {
  .doc-switch { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; }
  .doc-switch a { justify-content: center; min-height: 44px; padding: 6px 8px; font-size: 13.5px; line-height: 1.2; text-align: center; }
}
.doc-meta { display: flex; flex-wrap: wrap; gap: 8px 10px; font-size: 14px; color: var(--on-bg-2); }
.doc-meta span { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--glass-clear); border: 1px solid var(--glass-clear-border); }
.doc-meta .ico { width: 16px; height: 16px; }

.glance { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: clamp(28px, 4vw, 48px); }
.glance .tile h3 { font-size: 1.12rem; line-height: 1.25; }
.glance .tile p { font-size: 14.5px; }
@media (max-width: 1040px) { .glance { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .glance { grid-template-columns: minmax(0, 1fr); } }

.doc-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: start; padding-bottom: clamp(64px, 9vw, 112px); }
.toc { position: sticky; top: 96px; max-height: calc(100vh - 120px); overflow: auto; border-radius: 20px; padding: 6px; }
.toc summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 0 12px; cursor: pointer; list-style: none; font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-bg-2); }
.toc summary::-webkit-details-marker { display: none; }
.toc summary .ico { width: 18px; height: 18px; transition: transform 0.2s; }
.toc[open] summary .ico { transform: rotate(180deg); }
.toc ol { display: flex; flex-direction: column; gap: 1px; padding: 0 0 6px; counter-reset: toc; }
.toc a { position: relative; display: flex; gap: 10px; align-items: baseline; min-height: 40px; padding: 9px 12px; border-radius: 12px; color: var(--on-bg-2); text-decoration: none; font-size: 14.5px; line-height: 1.35; transition: background-color 0.2s, color 0.2s; }
.toc a::before { counter-increment: toc; content: counter(toc); flex: none; min-width: 1.4em; font-family: var(--font-mono); font-size: 12px; opacity: 0.75; }
.toc a:hover { color: var(--on-bg); background: var(--glass-clear); }
.toc a[aria-current] { color: var(--on-bg); background: var(--glass-clear); font-weight: 600; }
.toc a[aria-current]::after { content: ""; position: absolute; left: -1px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--highlight); }
@media (min-width: 1001px) { .toc summary { pointer-events: none; } .toc summary .ico { display: none; } }
@media (max-width: 1000px) {
  .doc-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { position: relative; top: 0; max-height: none; }
}

.doc { border-radius: var(--r-panel); padding: clamp(22px, 4.5vw, 60px); min-width: 0; }
.doc > section { max-width: 72ch; padding-block: 8px 30px; }
.doc > section + section { border-top: 1px solid var(--divider); padding-top: 30px; }
.doc > section:last-child { padding-bottom: 0; }
.doc h2 { display: flex; align-items: baseline; gap: 14px; font-size: clamp(1.45rem, 2.4vw, 1.9rem); line-height: 1.15; letter-spacing: -0.025em; margin-bottom: 14px; }
.doc h2 .num { flex: none; display: inline-grid; place-items: center; min-width: 34px; height: 34px; padding: 0 8px; border-radius: 999px; background: var(--glass-selected); color: var(--link); font-family: var(--font-mono); font-size: 14px; font-weight: 500; letter-spacing: 0; transform: translateY(-3px); }
.doc h3 { font-family: var(--font-body); font-weight: 700; font-size: 1.05rem; line-height: 1.3; letter-spacing: -0.01em; color: var(--text); margin: 22px 0 8px; }
.doc p, .doc li { color: var(--text-2); font-size: 16px; line-height: 1.65; }
.doc p + p, .doc p + ul, .doc ul + p, .doc .callout + p, .doc p + .callout, .doc ul + .callout, .doc .table-scroll + p, .doc p + .table-scroll { margin-top: 12px; }
.doc strong { color: var(--text); font-weight: 600; }
.doc a { color: var(--link); text-underline-offset: 3px; }
.doc ul { display: flex; flex-direction: column; gap: 6px; }
.doc ul li { position: relative; padding-left: 22px; }
.doc ul li::before { content: ""; position: absolute; left: 4px; top: 0.68em; width: 7px; height: 7px; border-radius: 50%; background: var(--timeline); }
.doc ul.no-list li::before { width: 12px; height: 2px; border-radius: 1px; top: 0.82em; background: var(--danger-fg); }
.doc ul.yes-list li::before { width: 10px; height: 6px; border-radius: 0; background: none; border: solid var(--check); border-width: 0 0 2px 2px; transform: rotate(-45deg); top: 0.5em; left: 3px; }
.doc .caps { font-size: 14.5px; letter-spacing: 0.01em; text-transform: uppercase; color: var(--text-strong); }
.doc ol.steps { display: flex; flex-direction: column; gap: 10px; counter-reset: step; }
.doc ol.steps li { position: relative; min-height: 28px; padding-left: 42px; counter-increment: step; }
.doc ol.steps li::before { content: counter(step); position: absolute; left: 0; top: -1px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--glass-selected); color: var(--link); font-family: var(--font-mono); font-size: 13px; font-weight: 500; }
.doc .steps + p { margin-top: 14px; }
.doc p + .facts, .doc .facts + p, .doc .facts + .doc-end { margin-top: 14px; }
.doc code { font-family: var(--font-mono); font-size: 0.88em; padding: 1px 6px; border-radius: 6px; background: var(--chip); color: var(--text); }

.callout { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border-radius: var(--r-note); background: var(--fill); }
.callout > .ico { width: 22px; height: 22px; margin-top: 2px; color: var(--link); }
.callout > div { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.doc .callout p, .doc .callout li { font-size: 15px; }
.doc .callout-title { font-weight: 700; color: var(--text); }
.callout-warn { background: var(--action-bg); }
.callout-warn > .ico, .doc .callout-warn p, .doc .callout-warn .callout-title { color: var(--action-fg); }
.facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 16px; margin: 0; }
.facts dt { font-size: 14px; color: var(--text-3); }
.facts dd { margin: 0; font-size: 15px; color: var(--text); font-weight: 500; overflow-wrap: anywhere; }
@media (max-width: 480px) { .facts { grid-template-columns: minmax(0, 1fr); } .facts dd { margin-bottom: 6px; } }

.table-scroll { overflow-x: auto; border-radius: var(--r-note); border: 1px solid var(--divider); }
.doc-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14.5px; line-height: 1.5; }
.doc-table th, .doc-table td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--divider); color: var(--text-2); }
.doc-table th { font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); background: var(--fill); }
.doc-table td:first-child { color: var(--text); font-weight: 600; }
.doc-table tr:last-child td { border-bottom: 0; }

@media (max-width: 600px) {
  /* Phones: each row becomes a small card, labelled from its column header. */
  .table-scroll { overflow: visible; border: 0; border-radius: 0; }
  .doc-table { min-width: 0; }
  .doc-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .doc-table, .doc-table tbody, .doc-table tr, .doc-table td { display: block; }
  .doc-table tr { padding: 8px 0; border: 1px solid var(--divider); border-radius: var(--r-note); }
  .doc-table tr + tr { margin-top: 10px; }
  .doc-table td { padding: 4px 14px; border: 0; }
  .doc-table td + td::before { content: attr(data-label); display: block; font-size: 11.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
}

.doc-end { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--divider); color: var(--text-3); font-size: 14px; }
.doc-end a { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 600; text-decoration: none; }
.doc-end a .ico { width: 18px; height: 18px; }

@media print {
  .ribbon, .nav, .toc, .footer, .doc-switch, .glance { display: none !important; }
  body { background: #FFFFFF; color: #000000; }
  .legal-hero, .legal-hero .sec-lede, .doc-meta, .doc-meta span { color: #000000; background: none; border: 0; }
  .doc-layout { display: block; padding: 0; }
  .doc { background: none; border: 0; box-shadow: none; padding: 0; -webkit-backdrop-filter: none; backdrop-filter: none; }
}

/* Entrance: content is always readable; it only rises into place as it scrolls in. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .tile, .app-frame, .settings, .faq details, .split-device .phone, .pt-case {
      animation: rise linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 40%;
    }
  }
}
@keyframes rise { from { transform: translateY(28px) scale(0.98); } to { transform: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

@media (max-width: 480px) {
  .btn { width: 100%; }
  .nav .btn { width: auto; }
  .phases .pill { min-width: 0; }
  .timeline li { grid-template-columns: 22px minmax(0, 1fr); }
  .tl-date { grid-column: 2; }
  .vb-uscis { flex-wrap: wrap; }
}
@media (max-width: 380px) {
  .nav .btn-sm { display: none; }
}
