
/* ===== 10-tokens.css ===== */
/* ==========================================================================
   10-tokens.css — CAPGAIN V2 design tokens · category themes · motion
   ========================================================================== */
@property --accent      { syntax: "<color>"; inherits: true; initial-value: oklch(58% 0.19 262); }
@property --accent-2    { syntax: "<color>"; inherits: true; initial-value: oklch(80% 0.15 75); }
@property --spec-angle  { syntax: "<angle>"; inherits: true; initial-value: 115deg; }
@property --spec-pos    { syntax: "<percentage>"; inherits: true; initial-value: 30%; }
@property --glass-alpha { syntax: "<number>"; inherits: true; initial-value: 0.42; }
@property --shadow-a    { syntax: "<number>"; inherits: true; initial-value: 0.16; }
@property --ring        { syntax: "<number>"; inherits: false; initial-value: 0; }

:root {
  color-scheme: light dark;
  /* brand (sampled from the registered logo) */
  --brand-blue: #2C68DC;
  --brand-orange: #FAAF40;
  --brand-ink: #0E0E0E;

  /* canvas + ink — plain light values first (Safari 17.0–17.4 / Samsung ≤ 24 have no light-dark()); modern engines re-declare below */
  --canvas: oklch(96.5% 0.012 262);
  --canvas-2: oklch(99% 0.004 262);
  --ink: oklch(21% 0.03 262);
  --ink-2: oklch(42% 0.03 262);
  --ink-3: oklch(51% 0.03 262);
  --line: rgb(20 30 60 / .10);
  --line-2: rgb(20 30 60 / .18);

  /* semantic */
  --good: oklch(58% 0.15 155);
  --warn: oklch(66% 0.16 65);
  --risk: oklch(58% 0.2 25);
  --info: oklch(56% 0.16 250);

  /* accent derivatives */
  --accent-ink:  color-mix(in oklab, var(--accent) 78%, var(--ink));
  --accent-soft: color-mix(in oklab, var(--accent) 13%, var(--canvas));
  --accent-line: color-mix(in oklab, var(--accent) 34%, transparent);
  --on-accent: #fff;

  /* glass material */
  --glass-blur: 18px;
  --glass-sat: 1.55;
  --glass-bright: 1.04;
  --glass-user: 0.42;                 /* the user's transparency slider */
  --glass-alpha: var(--glass-user);   /* per-surface floors override this */
  --glass-tint: color-mix(in oklab, var(--accent) 10%, transparent);
  --rim:  rgb(255 255 255 / .78);
  --edge: rgb(0 0 0 / .11);
  --shadow-a: 0.16;

  /* frosted card (no backdrop; cheap) */
  --card: color-mix(in oklab, var(--canvas-2) 82%, transparent);
  --card-solid: var(--canvas-2);

  /* geometry (concentric radii: inner = outer − padding) */
  --r-xl: 28px; --r-lg: 22px; --r-md: 16px; --r-sm: 12px; --r-xs: 9px;
  --r-bar: 34px; --pad-bar: 6px; --r-tab: calc(var(--r-bar) - var(--pad-bar));
  --bar-h: 66px;
  --top-h: 58px;
  --gutter: 16px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);

  /* type */
  --font: -apple-system, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, system-ui, sans-serif;
  --font-display: -apple-system, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Roboto, "Noto Sans", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Roboto Mono", monospace;
  --fs-0: 11px; --fs-1: 12px; --fs-2: 13px; --fs-3: 14.5px; --fs-4: 16px; --fs-5: 19px; --fs-6: 23px; --fs-7: 28px;

  /* motion — M3 expressive springs as linear() with bezier fallbacks (see 35-icons.css for icon tokens) */
  --ease-spatial-fast: cubic-bezier(.2,.9,.25,1.15);
  --dur-spatial-fast: 360ms;
  --ease-spatial-default: cubic-bezier(.2,.8,.2,1);
  --dur-spatial-default: 440ms;
  --ease-spatial-slow: cubic-bezier(.2,.8,.2,1);
  --dur-spatial-slow: 600ms;
  --ease-effects-fast: cubic-bezier(.2,0,0,1);
  --dur-effects-fast: 150ms;
  --ease-effects-default: cubic-bezier(.2,0,0,1);
  --dur-effects-default: 240ms;
  --ease-effects-slow: cubic-bezier(.2,0,0,1);
  --dur-effects-slow: 330ms;

  /* sub-category colour families */
  --c-tax: oklch(58% 0.18 258);
  --c-legal: oklch(52% 0.17 285);
  --c-rera: oklch(60% 0.12 195);
  --c-finance: oklch(70% 0.15 70);
  --c-nri: oklch(56% 0.17 315);
  --c-verify: oklch(60% 0.15 155);
  --c-market: oklch(64% 0.17 30);
  --c-infra: oklch(58% 0.1 240);
  --c-land: oklch(60% 0.11 75);
  --c-cities: oklch(60% 0.12 215);
}
/* ---- scheme tokens: legacy engines get explicit dark overrides, modern engines get light-dark() ---- */
@supports not (color: light-dark(#000, #fff)) {
  html[data-scheme="dark"] {
    --canvas: oklch(15% 0.025 262); --canvas-2: oklch(20% 0.028 262);
    --ink: oklch(95% 0.012 262); --ink-2: oklch(76% 0.02 262); --ink-3: oklch(72% 0.02 262);
    --line: rgb(255 255 255 / .10); --line-2: rgb(255 255 255 / .18);
    --good: oklch(74% 0.15 155); --warn: oklch(80% 0.15 75); --risk: oklch(72% 0.18 25); --info: oklch(76% 0.13 250);
    --rim: rgb(255 255 255 / .28); --edge: rgb(0 0 0 / .5);
  }
  @media (prefers-color-scheme: dark) {
    html:not([data-scheme="light"]) {
      --canvas: oklch(15% 0.025 262); --canvas-2: oklch(20% 0.028 262);
      --ink: oklch(95% 0.012 262); --ink-2: oklch(76% 0.02 262); --ink-3: oklch(72% 0.02 262);
      --line: rgb(255 255 255 / .10); --line-2: rgb(255 255 255 / .18);
      --good: oklch(74% 0.15 155); --warn: oklch(80% 0.15 75); --risk: oklch(72% 0.18 25); --info: oklch(76% 0.13 250);
      --rim: rgb(255 255 255 / .28); --edge: rgb(0 0 0 / .5);
    }
  }
}
@supports (color: light-dark(#000, #fff)) {
  :root {
    --canvas: light-dark(oklch(96.5% 0.012 262), oklch(15% 0.025 262));
    --canvas-2: light-dark(oklch(99% 0.004 262), oklch(20% 0.028 262));
    --ink: light-dark(oklch(21% 0.03 262), oklch(95% 0.012 262));
    --ink-2: light-dark(oklch(42% 0.03 262), oklch(76% 0.02 262));
    --ink-3: light-dark(oklch(51% 0.03 262), oklch(72% 0.02 262));
    --line: light-dark(rgb(20 30 60 / .10), rgb(255 255 255 / .10));
    --line-2: light-dark(rgb(20 30 60 / .18), rgb(255 255 255 / .18));
    --good: light-dark(oklch(58% 0.15 155), oklch(74% 0.15 155));
    --warn: light-dark(oklch(66% 0.16 65), oklch(80% 0.15 75));
    --risk: light-dark(oklch(58% 0.2 25), oklch(72% 0.18 25));
    --info: light-dark(oklch(56% 0.16 250), oklch(76% 0.13 250));
    --rim:  light-dark(rgb(255 255 255 / .78), rgb(255 255 255 / .28));
    --edge: light-dark(rgb(0 0 0 / .11), rgb(0 0 0 / .5));
  }
}
@supports (animation-timing-function: linear(0, 1)) {
  :root {
    --ease-spatial-fast: linear(0, 0.07539, 0.2492, 0.458, 0.6588, 0.8269, 0.952, 1.034, 1.078, 1.094, 1.091, 1.076, 1.056, 1.037, 1.02, 1.007, 0.9984, 0.9934, 0.9912, 0.9912, 0.9924, 0.9942, 0.996, 0.9977, 1);
    --ease-spatial-default: linear(0, 0.05271, 0.1736, 0.3214, 0.4702, 0.6051, 0.7193, 0.8108, 0.8807, 0.9316, 0.9669, 0.99, 1.004, 1.012, 1.015, 1.015, 1.014, 1.012, 1.009, 1.007, 1.005, 1.004, 1.002, 1.002, 1);
    --ease-spatial-slow: linear(0, 0.05169, 0.1706, 0.3166, 0.464, 0.5984, 0.7127, 0.8047, 0.8755, 0.9274, 0.9638, 0.9878, 1.003, 1.011, 1.014, 1.015, 1.014, 1.012, 1.01, 1.008, 1.006, 1.004, 1.003, 1.002, 1);
    --ease-effects-fast: linear(0, 0.1807, 0.4558, 0.6718, 0.8128, 0.897, 0.9448, 0.9709, 0.9849, 0.9923, 0.9961, 0.998, 1);
    --ease-effects-default: linear(0, 0.1912, 0.4751, 0.6916, 0.8288, 0.9084, 0.9523, 0.9756, 0.9877, 0.9939, 0.997, 0.9985, 1);
    --ease-effects-slow: linear(0, 0.1833, 0.4606, 0.6768, 0.8169, 0.8999, 0.9467, 0.9722, 0.9857, 0.9927, 0.9963, 0.9982, 1);
  }
}

/* ---- scheme override (system by default) ---- */
html[data-scheme="light"] { color-scheme: light; }
html[data-scheme="dark"]  { color-scheme: dark; }
/* host-stamped theme (artifact viewer) applies only while the in-app choice is "system" */
html[data-theme="dark"]:not([data-scheme="light"]) { color-scheme: dark; }
html[data-theme="light"]:not([data-scheme="dark"]) { color-scheme: light; }

/* ---- category themes: one accent pair per section; everything derives ---- */
html[data-section="home"]       { --accent: oklch(58% 0.19 262); --accent-2: oklch(80% 0.15 75); --on-accent:#fff; }
html[data-section="advisory"]   { --accent: oklch(50% 0.19 268); --accent-2: oklch(62% 0.17 300); --on-accent:#fff; }
html[data-section="properties"] { --accent: oklch(64% 0.14 60);  --accent-2: oklch(66% 0.18 30);  --on-accent:#221400; --accent-ink: oklch(46% 0.11 62); }
html[data-section="knowledge"]  { --accent: oklch(58% 0.13 165); --accent-2: oklch(66% 0.11 200); --on-accent:#fff; }
html[data-section="my"]         { --accent: oklch(52% 0.18 305); --accent-2: oklch(62% 0.16 340); --on-accent:#fff; }
/* dark-scheme lifts for legibility of accent text */
html[data-scheme="dark"][data-section="advisory"], html[data-scheme="dark"][data-section="my"] { --accent-ink: color-mix(in oklab, var(--accent) 60%, white); }
html[data-scheme="dark"][data-section="properties"] { --accent-ink: oklch(82% 0.13 72); }
@media (prefers-color-scheme: dark) {
  html:not([data-scheme="light"])[data-section="advisory"], html:not([data-scheme="light"])[data-section="my"],
  html:not([data-scheme="light"])[data-section="knowledge"], html:not([data-scheme="light"])[data-section="home"] { --accent-ink: color-mix(in oklab, var(--accent) 62%, white); }
  html:not([data-scheme="light"])[data-section="properties"] { --accent-ink: oklch(82% 0.13 72); }
}
html.theme-anim { transition: --accent var(--dur-effects-slow) var(--ease-effects-slow), --accent-2 var(--dur-effects-slow) var(--ease-effects-slow); }

/* sub-category helpers */
.cat-tax { --cat: var(--c-tax); } .cat-legal { --cat: var(--c-legal); } .cat-rera { --cat: var(--c-rera); }
.cat-finance { --cat: var(--c-finance); } .cat-nri { --cat: var(--c-nri); } .cat-verify { --cat: var(--c-verify); }
.cat-market { --cat: var(--c-market); } .cat-infra { --cat: var(--c-infra); } .cat-land { --cat: var(--c-land); } .cat-cities { --cat: var(--c-cities); }
.cat-home { --cat: oklch(58% 0.19 262); } .cat-advisory { --cat: oklch(50% 0.19 268); } .cat-properties { --cat: oklch(70% 0.16 68); }
.cat-knowledge { --cat: oklch(58% 0.13 165); } .cat-my { --cat: oklch(52% 0.18 305); }

/* ---- accessibility preferences ---- */
@media (prefers-reduced-transparency: reduce) { :root { --glass-user: .94; --glass-blur: 8px; } }
html[data-reduce-transparency] { --glass-user: .94; --glass-blur: 8px; }
@media (prefers-contrast: more) {
  :root { --glass-alpha: 1; --glass-user: 1; --rim: transparent; --edge: transparent; --line: color-mix(in oklab, var(--ink) 45%, transparent); }
}
@media (prefers-reduced-motion: reduce) {
  :root { --ease-spatial-fast: ease-out; --ease-spatial-default: ease-out; --ease-spatial-slow: ease-out; --dur-spatial-fast: 120ms; --dur-spatial-default: 160ms; --dur-spatial-slow: 180ms; }
}
html[data-reduce-motion] { --ease-spatial-fast: ease-out; --ease-spatial-default: ease-out; --ease-spatial-slow: ease-out; --dur-spatial-fast: 120ms; --dur-spatial-default: 160ms; --dur-spatial-slow: 180ms; }
html[data-reduce-motion] *, html[data-reduce-motion] *::before, html[data-reduce-motion] *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .12s !important; }

/* ===== 20-glass.css ===== */
/* ==========================================================================
   20-glass.css — liquid glass frame: base, ambient, glass surface, bars, sheets, toasts
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--canvas); scroll-padding-bottom: calc(var(--bar-h) + 40px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100dvh; font-family: var(--font); font-size: var(--fs-3); line-height: 1.45; color: var(--ink);
  background: transparent; overscroll-behavior-y: none; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  padding-bottom: calc(var(--bar-h) + 28px + var(--safe-b));
}
button, input, select, textarea { font: inherit; color: inherit; }
button { border: 0; background: none; padding: 0; margin: 0; cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
a { color: var(--accent-ink); text-decoration: none; }
a, label, [role="button"], [data-act], .li, .touch { -webkit-tap-highlight-color: transparent; }
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
::selection { background: color-mix(in oklab, var(--accent) 30%, transparent); }

/* ---- phone frame on wide screens (desktop preview) ---- */
.frame { position: relative; width: 100%; max-width: 480px; margin: 0 auto; min-height: 100dvh; }
@media (min-width: 720px) {
  body { background: radial-gradient(120% 80% at 50% 0%, color-mix(in oklab, var(--accent) 12%, var(--canvas)), var(--canvas) 70%); }
  .frame { max-width: 430px; box-shadow: 0 0 0 1px var(--line), 0 30px 80px -30px rgb(0 0 0 / .45); border-radius: 0; }
}

/* ---- ambient environment (double-buffered by JS; only opacity animates) ---- */
.ambient {
  position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
  background: var(--canvas);
  transition: opacity var(--dur-effects-slow) var(--ease-effects-slow);
}
.ambient::before, .ambient::after { content: ""; position: absolute; inset: -8%; animation-iteration-count: 1; animation-fill-mode: forwards; }
.ambient::before {
  background:
    radial-gradient(60% 46% at 18% 12%, color-mix(in oklab, var(--accent) 38%, transparent), transparent 70%),
    radial-gradient(48% 42% at 88% 26%, color-mix(in oklab, var(--accent-2) 34%, transparent), transparent 70%),
    radial-gradient(42% 40% at 60% 92%, color-mix(in oklab, var(--accent) 22%, transparent), transparent 72%);
  animation: ambient-drift 14s ease-in-out 1 forwards;
}
.ambient::after {
  background:
    radial-gradient(30% 24% at 70% 60%, color-mix(in oklab, var(--accent-2) 20%, transparent), transparent 70%),
    radial-gradient(26% 22% at 30% 70%, color-mix(in oklab, var(--accent) 16%, transparent), transparent 70%);
  animation: ambient-drift-2 18s ease-in-out 1 forwards;
  mix-blend-mode: plus-lighter;
}
.ambient[data-section="home"]       { --accent: oklch(58% 0.19 262); --accent-2: oklch(80% 0.15 75); }
.ambient[data-section="advisory"]   { --accent: oklch(50% 0.19 268); --accent-2: oklch(62% 0.17 300); }
.ambient[data-section="properties"] { --accent: oklch(72% 0.16 68);  --accent-2: oklch(66% 0.18 30); }
.ambient[data-section="knowledge"]  { --accent: oklch(58% 0.13 165); --accent-2: oklch(66% 0.11 200); }
.ambient[data-section="my"]         { --accent: oklch(52% 0.18 305); --accent-2: oklch(62% 0.16 340); }
.ambient.is-next { opacity: 0; }
@keyframes ambient-drift   { from { transform: translate3d(0,0,0) scale(1); } to { transform: translate3d(3%, 2%, 0) scale(1.06); } }
@keyframes ambient-drift-2 { from { transform: translate3d(0,0,0) rotate(0deg); } to { transform: translate3d(-3%, -2%, 0) rotate(4deg); } }
/* category signature motion: each section moves its light differently */
html[data-section="properties"] .ambient::before { animation-duration: 10s; }
html[data-section="knowledge"] .ambient::before { animation-duration: 22s; }
html[data-section="my"] .ambient::after { animation-duration: 9s; }
@media (prefers-reduced-motion: reduce) { .ambient::before, .ambient::after { animation: none; } }
html[data-reduce-motion] .ambient::before, html[data-reduce-motion] .ambient::after { animation: none; }
.ambient .grain { position: absolute; inset: 0; opacity: .5; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .5 0 0 0 0 .5 0 0 0 0 .5 0 0 0 .05 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); mix-blend-mode: normal; opacity: .28; }

/* ---- the canonical glass surface (navigation layer only) ---- */
.glass {
  position: relative; isolation: isolate; border-radius: var(--r, var(--r-lg)); color: var(--ink);
  --glass-fill: color-mix(in oklab, var(--canvas-2) calc(var(--glass-alpha) * 100%), transparent);   /* resolved per surface */
  background: linear-gradient(var(--glass-tint), var(--glass-tint)), var(--glass-fill);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) brightness(var(--glass-bright));
          backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-sat)) brightness(var(--glass-bright));
  box-shadow:
    inset 0 1px 0 var(--rim),
    inset 0 -0.5px 0 color-mix(in srgb, var(--rim) 40%, transparent),
    inset 0 0 0 0.5px color-mix(in srgb, var(--rim) 30%, transparent),
    inset 0 0 18px -10px var(--edge),
    0 1px 1.5px rgb(0 0 0 / calc(var(--shadow-a) * .6)),
    0 8px 24px -8px rgb(0 0 0 / var(--shadow-a)),
    0 24px 48px -20px rgb(0 0 0 / calc(var(--shadow-a) * .8));
}
.topbar, .tabbar { transform: translateZ(0); }   /* promote only the two persistent bars */
.glass::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  background: linear-gradient(var(--spec-angle),
    rgb(255 255 255 / .34) 0%, rgb(255 255 255 / .10) calc(var(--spec-pos) - 12%),
    transparent var(--spec-pos), transparent calc(var(--spec-pos) + 34%), rgb(255 255 255 / .12) 100%);
  mix-blend-mode: plus-lighter;
}
.glass::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; padding: 1px;
  background: linear-gradient(var(--spec-angle), rgb(255 255 255 / .9), rgb(255 255 255 / .28) 35%, rgb(255 255 255 / .06) 60%, rgb(255 255 255 / .4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); mask-composite: exclude;
  opacity: .9;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .glass { --glass-alpha: .96; } }
@supports (corner-shape: squircle) { .glass, .card, .btn { corner-shape: squircle; } }
@media (prefers-contrast: more) { .glass { border: 1.5px solid currentColor; box-shadow: none; } .glass::before, .glass::after { display: none; } }
@media (forced-colors: active) { .glass { backdrop-filter: none; -webkit-backdrop-filter: none; background: Canvas; color: CanvasText; border: 1px solid ButtonBorder; forced-color-adjust: none; } }

/* touch illumination mixin */
.touch { --tx: 50%; --ty: 50%; position: relative; }
.touch > .glow { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 0;
  background: radial-gradient(150px 150px at var(--tx) var(--ty), rgb(255 255 255 / .5), transparent 70%);
  opacity: 0; transition: opacity var(--dur-effects-slow) var(--ease-effects-slow); }
.touch:active > .glow, .touch.is-lit > .glow { opacity: 1; transition-duration: 60ms; }

/* ---- top bar ---- */
.topbar {
  position: sticky; top: 0; z-index: 30; margin: 0 0 6px; --r: 0 0 var(--r-lg) var(--r-lg); --glass-alpha: max(.6, var(--glass-user));
  padding: calc(6px + var(--safe-t)) 10px 6px 14px; display: flex; align-items: center; gap: 4px; min-height: var(--top-h);
  will-change: transform;
}
.topbar .brand { display: flex; align-items: center; gap: 9px; flex: none; }
.topbar .brand .mark { width: 34px; height: 33px; object-fit: contain; }
.topbar .brand .word { height: 26px; width: auto; object-fit: contain; }
.topbar .brand .word.dark { display: none; }
html[data-scheme="dark"] .topbar .brand .word.light { display: none; }
html[data-scheme="dark"] .topbar .brand .word.dark { display: block; }
@media (prefers-color-scheme: dark) {
  html:not([data-scheme="light"]) .topbar .brand .word.light { display: none; }
  html:not([data-scheme="light"]) .topbar .brand .word.dark { display: block; }
}


.topbar .spacer { flex: 1; }
.topbar .demo { font-size: 10.5px; font-weight: 800; letter-spacing: .6px; padding: 3px 8px; border-radius: 999px; color: #6a3f00; margin-right: 2px;
  background: color-mix(in oklab, var(--brand-orange) 32%, var(--canvas-2)); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--brand-orange) 50%, transparent); }
html[data-scheme="dark"] .topbar .demo { color: #ffd79a; }
@media (prefers-color-scheme: dark) { html:not([data-scheme="light"]) .topbar .demo { color: #ffd79a; } }
.iconbtn { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: var(--ink-2); position: relative; isolation: isolate; overflow: hidden;
  transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast), background var(--dur-effects-fast); }
.iconbtn:active { transform: scale(.92); }
.iconbtn.on, .iconbtn[aria-pressed="true"] { color: var(--accent-ink); background: var(--accent-soft); }
.iconbtn .icon { font-size: 22px; }
.iconbtn .dot { position: absolute; top: 8px; right: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--risk); box-shadow: 0 0 0 2px var(--canvas-2); }

/* ---- floating tab bar ---- */
.tabbar {
  position: fixed; left: 50%; bottom: max(12px, var(--safe-b)); transform: translateX(-50%) translateZ(0); z-index: 40;
  display: flex; gap: 2px; padding: var(--pad-bar); border-radius: var(--r-bar); height: var(--bar-h); --r: var(--r-bar);
  width: min(430px - 24px, 100vw - 24px); overflow: visible; will-change: transform;
  transition: transform var(--dur-spatial-default) var(--ease-spatial-default), opacity var(--dur-effects-default);
}
.tabbar .tabs { display: flex; flex: 1; gap: 2px; min-width: 0; }
.tabbar .tab {
  position: relative; flex: 1 1 0; min-width: 0; border-radius: var(--r-tab); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  height: calc(var(--bar-h) - var(--pad-bar) * 2); color: var(--ink-2); font-size: 11px; font-weight: 700; letter-spacing: 0; isolation: isolate; overflow: hidden;
  transition: color var(--dur-effects-default) var(--ease-effects-default), transform var(--dur-spatial-fast) var(--ease-spatial-fast);
}
.tabbar .tab:active { transform: scale(.93); }
.tabbar .tab .icon { font-size: 25px; position: relative; z-index: 1; }
.tabbar .tab span { position: relative; z-index: 1; white-space: nowrap; }
.tabbar .tab[aria-selected="true"] { color: var(--on-accent); }
.tabbar .tab .pill {
  position: absolute; inset: 0; border-radius: inherit; z-index: 0; opacity: 0; transform: scale(.7);
  background: linear-gradient(160deg, color-mix(in oklab, var(--accent) 94%, white) 0%, color-mix(in oklab, var(--accent) 86%, black) 45%, color-mix(in oklab, var(--accent) 80%, black));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .45), inset 0 -1px 0 rgb(0 0 0 / .12), 0 6px 16px -6px color-mix(in oklab, var(--accent) 70%, transparent);
  transition: opacity var(--dur-effects-default) var(--ease-effects-default), transform var(--dur-spatial-fast) var(--ease-spatial-fast);
}
.tabbar .tab[aria-selected="true"] .pill { opacity: 1; transform: scale(1); view-transition-name: tab-pill; }
::view-transition-group(tab-pill) { animation-duration: var(--dur-spatial-default); animation-timing-function: var(--ease-spatial-default); }
::view-transition-old(tab-pill), ::view-transition-new(tab-pill) { animation: none; mix-blend-mode: normal; height: 100%; }
.tabbar .tab .badge { position: absolute; top: 6px; right: 14%; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: #c8262b; color: #fff; font-size: 9.5px; font-weight: 800; display: grid; place-items: center; z-index: 2; box-shadow: 0 0 0 2px var(--canvas-2); }
html[data-bar-min] .tabbar { transform: translateX(-50%) translateY(8px) scale(.9); }
.scroll-edge { position: fixed; left: 0; right: 0; bottom: 0; height: calc(var(--bar-h) + 54px); pointer-events: none; z-index: 20;
  background: linear-gradient(to top, color-mix(in oklab, var(--canvas) 92%, transparent) 0%, color-mix(in oklab, var(--canvas) 55%, transparent) 45%, transparent 100%); }

/* ---- pages + view transitions ---- */
.page { display: none; padding: 6px var(--gutter) 24px; animation: page-in var(--dur-effects-slow) var(--ease-effects-slow) both; }
.page.on { display: block; }
@keyframes page-in { from { transform: translateY(6px); } }
.tabbar { view-transition-name: tabbar; } .topbar { view-transition-name: topbar; }
::view-transition-group(tabbar), ::view-transition-group(topbar) { animation: none; }
.frame > .pages { view-transition-name: content; }
::view-transition-old(content), ::view-transition-new(content) { animation-duration: 260ms; animation-timing-function: var(--ease-effects-slow); }
html[data-dir="forwards"]::view-transition-old(content)  { animation-name: vt-out-left; }
html[data-dir="forwards"]::view-transition-new(content)  { animation-name: vt-in-right; }
html[data-dir="backwards"]::view-transition-old(content) { animation-name: vt-out-right; }
html[data-dir="backwards"]::view-transition-new(content) { animation-name: vt-in-left; }
@keyframes vt-out-left  { to { translate: -22px 0; opacity: 0; } }
@keyframes vt-in-right  { from { translate: 22px 0; opacity: 0; } }
@keyframes vt-out-right { to { translate: 22px 0; opacity: 0; } }
@keyframes vt-in-left   { from { translate: -22px 0; opacity: 0; } }
@media (prefers-reduced-motion: reduce) { ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; } }

/* ---- sheet (dialog) ---- */
.sheet {
  position: fixed; inset: auto 8px max(8px, var(--safe-b)) 8px; width: auto; max-width: 414px; margin: 0 auto; max-height: 86dvh;
  border: 0; padding: 0; border-radius: 30px; --r: 30px; --glass-alpha: max(.9, var(--glass-user)); color: var(--ink); overflow: hidden; z-index: 60;
  translate: 0 0;
  transition: translate var(--dur-spatial-default) var(--ease-spatial-default);
}
@supports (transition-behavior: allow-discrete) {
  .sheet { transition: translate var(--dur-spatial-default) var(--ease-spatial-default), display var(--dur-spatial-default) allow-discrete, overlay var(--dur-spatial-default) allow-discrete; }
  .sheet::backdrop { transition: background 240ms, display 240ms allow-discrete, overlay 240ms allow-discrete; }
}
.sheet:not([open]) { translate: 0 calc(100% + 40px); }
@starting-style { .sheet[open] { translate: 0 calc(100% + 40px); } }
.sheet::backdrop { background: rgb(8 12 30 / .38); transition: background 240ms; }
@starting-style { .sheet[open]::backdrop { background: rgb(8 12 30 / 0); } }
html[data-scheme="dark"] .sheet { --glass-alpha: max(.88, var(--glass-user)); }
@media (prefers-color-scheme: dark) { html:not([data-scheme="light"]) .sheet { --glass-alpha: max(.88, var(--glass-user)); } }
.sheet[data-expanded] { inset: max(10px, var(--safe-t)) 0 0 0; max-width: 430px; max-height: none; border-radius: 30px 30px 0 0; -webkit-backdrop-filter: none; backdrop-filter: none; background: linear-gradient(var(--glass-tint), var(--glass-tint)), var(--canvas-2); }
#sheet:focus, #sheet:focus-visible, #sheet-title:focus { outline: none; box-shadow: none; }
.sheet .result, .sheet .table, .sheet .script { background: color-mix(in oklab, var(--canvas-2) 92%, transparent); }
.sheet .tscroll { padding: 6px 8px; border-radius: var(--r-md); background: color-mix(in oklab, var(--canvas-2) 92%, transparent); }
.sheet .sheet-in { max-height: 86dvh; overflow-y: auto; overscroll-behavior: contain; padding: 10px 18px calc(22px + var(--safe-b)); -webkit-overflow-scrolling: touch; }
.sheet[data-expanded] .sheet-in { max-height: calc(100dvh - max(10px, var(--safe-t))); }
.sheet .hdl { width: 42px; height: 5px; border-radius: 3px; background: color-mix(in oklab, var(--ink) 22%, transparent); margin: 8px auto 12px; }
.sheet .sheet-head { display: flex; align-items: center; gap: 10px; margin: 0 -18px 10px; position: sticky; top: -10px; padding: 6px 18px 10px; z-index: 2;
  background: linear-gradient(color-mix(in oklab, var(--canvas-2) 96%, transparent) 75%, transparent); }
.sheet .sheet-head h2 { font-size: var(--fs-5); font-weight: 800; letter-spacing: -.2px; flex: 1; font-family: var(--font-display); margin: 0; }
.sheet .sheet-head .sub { font-size: var(--fs-1); color: var(--ink-3); font-weight: 600; }

/* ---- toasts + nudges ---- */
.toasts { position: fixed; inset: auto auto calc(var(--bar-h) + 30px + var(--safe-b)) 50%; transform: translateX(-50%); z-index: 70; margin: 0; padding: 0; border: 0; background: transparent; color: inherit; overflow: visible; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(400px, 92vw); }
.toasts:not(:popover-open) { display: flex; }
.toast { --r: 18px; --glass-alpha: .82; padding: 10px 14px; font-size: var(--fs-2); font-weight: 600; display: flex; gap: 10px; align-items: center; pointer-events: none; max-width: 100%;
  animation: toast-in var(--dur-spatial-fast) var(--ease-spatial-fast) both; }
.toast.out { animation: toast-out var(--dur-effects-default) var(--ease-effects-default) both; }
.toast .icon { font-size: 20px; flex: none; }
.toast.good { color: var(--good); } .toast.warn { color: var(--warn); } .toast.risk { color: var(--risk); }
.toast .t { color: var(--ink); }

@keyframes toast-in { from { transform: translateY(14px) scale(.9); opacity: 0; } }
@keyframes toast-out { to { transform: translateY(8px) scale(.96); opacity: 0; } }

/* ---- focus (two-tone, token-based) ---- */
:where(button, a, input, select, textarea, [tabindex]):focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; box-shadow: 0 0 0 4px var(--canvas-2); }
.tabbar .tab:focus-visible { outline-offset: -3px; }
.sheet :focus-visible { outline-offset: -3px; box-shadow: inset 0 0 0 4px var(--canvas-2); }
/* transient surfaces are frosted, not glass (no backdrop readback) */
.toast { -webkit-backdrop-filter: none; backdrop-filter: none; background: linear-gradient(var(--glass-tint), var(--glass-tint)), color-mix(in oklab, var(--canvas-2) 94%, transparent); }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ===== 30-components.css ===== */
/* ==========================================================================
   30-components.css — frosted cards, buttons, chips, fields, results, lists, meters
   ========================================================================== */
/* ---- section headings ---- */
.sec { display: flex; align-items: center; gap: 8px; margin: 18px 0 10px; }
.sec h2 { font-family: var(--font-display); font-size: var(--fs-2); font-weight: 800; letter-spacing: .3px; text-transform: uppercase; color: var(--accent-ink); }
.sec .more { margin-left: auto; font-size: var(--fs-1); font-weight: 700; color: var(--accent-ink); display: inline-flex; align-items: center; gap: 2px; min-height: 44px; padding: 12px 6px; margin: -12px -6px -12px auto; }
.sec .more .icon { font-size: 16px; }
.sec:first-child { margin-top: 4px; }
.h-display { font-family: var(--font-display); font-weight: 800; letter-spacing: -.4px; font-size: var(--fs-6); line-height: 1.15; }
.h-display .grad { background: linear-gradient(100deg, var(--accent-ink), color-mix(in oklab, var(--accent-2) 70%, var(--ink))); -webkit-background-clip: text; background-clip: text; color: transparent; }
.muted { color: var(--ink-3); } .small { font-size: var(--fs-1); } .tiny { font-size: var(--fs-0); } .b { font-weight: 700; } 
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: -.2px; }
.num { font-variant-numeric: tabular-nums; }
.hide { display: none !important; }
.row { display: flex; align-items: center; gap: 8px; } .row.wrap { flex-wrap: wrap; } .grow { flex: 1; min-width: 0; } .end { justify-content: flex-end; } .between { justify-content: space-between; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.mt { margin-top: 10px; } .mt2 { margin-top: 16px; } .mb { margin-bottom: 10px; } 

/* ---- category hero header ---- */
.hero-cat { display: flex; align-items: center; gap: 14px; padding: 6px 2px 2px; margin-bottom: 8px; }
.hero-cat .icon-hero { flex: none; width: 72px; height: 72px; color: var(--accent-ink); }
.hero-cat .icon-hero .icon { --icon-fill-opacity: .14; width: 72px; height: 72px; }
.hero-cat h1 { font-family: var(--font-display); font-size: var(--fs-6); font-weight: 800; letter-spacing: -.5px; line-height: 1.1; text-wrap: balance; }
.hero-cat p { font-size: var(--fs-1); color: var(--ink-2); margin-top: 4px; line-height: 1.4; }
.hero-cat .kicker { font-size: var(--fs-0); font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; color: var(--accent-ink); margin-bottom: 2px; }

/* ---- frosted card (no backdrop; performance) ---- */
.card {
  position: relative; background: var(--card); border-radius: var(--r-lg); padding: 14px 15px; margin-bottom: 12px; color: var(--ink);
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--line), 0 1px 1.5px rgb(0 0 0 / .06), 0 10px 26px -14px rgb(0 0 0 / .22);
}
.card.solid { background: var(--card-solid); }
.card.tint { background: linear-gradient(160deg, color-mix(in oklab, var(--accent) 12%, var(--card)), var(--card) 70%); }
.card.cat { padding-left: 17px; }
.card.cat::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 3px; border-radius: 0 2px 2px 0; background: var(--cat, var(--accent)); }
.card.press { transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); }
.card.press:active { transform: scale(.985); }

.card .title { font-weight: 800; font-size: var(--fs-3); letter-spacing: -.1px; line-height: 1.25; }
.card .desc { font-size: var(--fs-1); color: var(--ink-2); margin-top: 2px; line-height: 1.4; }
.note { font-size: var(--fs-1); color: var(--ink-2); background: color-mix(in oklab, var(--canvas-2) 60%, transparent); border: 1px dashed var(--line-2); border-radius: var(--r-md); padding: 10px 12px; line-height: 1.5; margin: 10px 0; }
.note.info { border-style: solid; border-color: color-mix(in oklab, var(--info) 35%, transparent); background: color-mix(in oklab, var(--info) 8%, transparent); }
.note.warn { border-style: solid; border-color: color-mix(in oklab, var(--warn) 45%, transparent); background: color-mix(in oklab, var(--warn) 10%, transparent); }
.note.risk { border-style: solid; border-color: color-mix(in oklab, var(--risk) 40%, transparent); background: color-mix(in oklab, var(--risk) 9%, transparent); }
.note.good { border-style: solid; border-color: color-mix(in oklab, var(--good) 40%, transparent); background: color-mix(in oklab, var(--good) 9%, transparent); }
.note .icon { font-size: 18px; flex: none; }

/* ---- buttons ---- */
.btn {
  position: relative; isolation: isolate; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 11px 16px; border-radius: 15px; font-weight: 800; font-size: var(--fs-3); letter-spacing: -.1px; width: 100%; color: var(--on-accent);
  background: linear-gradient(160deg, color-mix(in oklab, var(--accent) 88%, white), var(--accent) 55%, color-mix(in oklab, var(--accent) 82%, var(--accent-2)));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .45), inset 0 -1px 0 rgb(0 0 0 / .14), 0 8px 18px -8px color-mix(in oklab, var(--accent) 80%, transparent);
  transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast), filter var(--dur-effects-fast), opacity var(--dur-effects-fast);
}
.btn:active { transform: scale(.975); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn .icon { font-size: 20px; }
.btn.orange { color: #2a1900; background: linear-gradient(160deg, #ffd27a, var(--brand-orange) 55%, #f39a1b); box-shadow: inset 0 1px 0 rgb(255 255 255 / .55), inset 0 -1px 0 rgb(0 0 0 / .12), 0 8px 18px -8px rgb(250 175 64 / .7); }
.btn.ghost { color: var(--accent-ink); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-line); }
.btn.plain { color: var(--ink-2); background: color-mix(in oklab, var(--ink) 6%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.btn.danger { color: #fff; background: linear-gradient(160deg, color-mix(in oklab, var(--risk) 85%, white), var(--risk)); }
.btn.sm { width: auto; min-height: 38px; padding: 8px 13px; font-size: var(--fs-2); border-radius: 12px; white-space: nowrap; }
.btn.sm.block { width: 100%; white-space: normal; text-align: center; line-height: 1.25; }
.btn.xs { width: auto; min-height: 36px; padding: 6px 11px; font-size: var(--fs-1); border-radius: 10px; white-space: nowrap; }
.btn-row.stack { flex-direction: column; }
.btn.auto { width: auto; }
.btn-row { display: flex; gap: 8px; margin-top: 10px; } .btn-row .btn { flex: 1; }
.link { color: var(--accent-ink); font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.link .icon { font-size: 15px; }

/* ---- chips / segmented ---- */
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 3px 28px 8px 2px; margin: 0 -2px; -webkit-overflow-scrolling: touch; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 8px 14px; border-radius: 999px; font-size: var(--fs-1); font-weight: 700; color: var(--ink-2); white-space: nowrap; flex: none;
  background: color-mix(in oklab, var(--canvas-2) 70%, transparent); box-shadow: inset 0 0 0 1px var(--line), inset 0 1px 0 color-mix(in srgb, var(--rim) 50%, transparent);
  transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast), background var(--dur-effects-fast), color var(--dur-effects-fast); position: relative; isolation: isolate; overflow: hidden; }
.chip:active { transform: scale(.95); }
.chip.on, .chip[aria-pressed="true"] { color: var(--on-accent); background: color-mix(in oklab, var(--accent) 88%, black); box-shadow: inset 0 1px 0 rgb(255 255 255 / .4), 0 4px 10px -6px var(--accent); }
.chip .icon { font-size: 16px; }
.chip.cat { color: color-mix(in oklab, var(--cat) 62%, var(--ink)); background: color-mix(in oklab, var(--cat) 12%, transparent); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--cat) 30%, transparent); }
.chip.cat.on { color: #fff; background: color-mix(in oklab, var(--cat) 88%, black); }
.seg { display: flex; position: relative; padding: 3px; border-radius: 14px; background: color-mix(in oklab, var(--ink) 7%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.seg button { flex: 1; position: relative; z-index: 1; padding: 8px 6px; border-radius: 11px; font-size: var(--fs-1); font-weight: 800; color: var(--ink-2); transition: color var(--dur-effects-default); display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap; }
.seg button[aria-pressed="true"] { color: var(--accent-ink); }
.seg .thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; border-radius: 11px; background: var(--canvas-2); background: light-dark(var(--canvas-2), color-mix(in oklab, var(--ink) 14%, var(--canvas-2))); box-shadow: 0 1px 2px rgb(0 0 0 / .12), inset 0 0 0 1px var(--line), inset 0 1px 0 var(--rim); transition: transform var(--dur-spatial-default) var(--ease-spatial-default), width var(--dur-spatial-default) var(--ease-spatial-default); z-index: 0; }

/* ---- pills / badges ---- */
.pill { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-0); font-weight: 800; padding: 3px 8px; border-radius: 999px; letter-spacing: .2px; white-space: nowrap; line-height: 1.3; }
.pill .icon { font-size: 12px; }
.p-good { background: color-mix(in oklab, var(--good) 15%, transparent); color: color-mix(in oklab, var(--good) 70%, var(--ink)); color: light-dark(color-mix(in oklab, var(--good) 70%, var(--ink)), var(--good)); }
.p-warn { background: color-mix(in oklab, var(--warn) 18%, transparent); color: color-mix(in oklab, var(--warn) 60%, var(--ink)); color: light-dark(color-mix(in oklab, var(--warn) 60%, var(--ink)), color-mix(in oklab, var(--warn) 80%, var(--ink))); }
.p-risk { background: color-mix(in oklab, var(--risk) 14%, transparent); color: color-mix(in oklab, var(--risk) 78%, var(--ink)); color: light-dark(color-mix(in oklab, var(--risk) 78%, var(--ink)), var(--risk)); }
.p-info { background: color-mix(in oklab, var(--info) 14%, transparent); color: color-mix(in oklab, var(--info) 70%, var(--ink)); color: light-dark(color-mix(in oklab, var(--info) 70%, var(--ink)), var(--info)); }
.p-acc  { background: var(--accent-soft); color: var(--accent-ink); }
.p-org  { background: color-mix(in oklab, var(--brand-orange) 26%, transparent); color: #8a5600; }
.p-cat  { background: color-mix(in oklab, var(--cat, var(--accent)) 14%, transparent); color: color-mix(in oklab, var(--cat, var(--accent)) 70%, var(--ink)); }
.p-mute { background: color-mix(in oklab, var(--ink) 7%, transparent); color: var(--ink-2); }
html[data-scheme="dark"] .p-org { color: #ffd79a; }
@media (prefers-color-scheme: dark) { html:not([data-scheme="light"]) .p-org { color: #ffd79a; } }
.price-tag { font-weight: 800; color: #8f5500; font-size: var(--fs-1); white-space: nowrap; }
html[data-scheme="dark"] .price-tag { color: #ffc46b; }
@media (prefers-color-scheme: dark) { html:not([data-scheme="light"]) .price-tag { color: #ffc46b; } }

/* ---- fields ---- */
.field { margin-bottom: 10px; min-width: 0; }
.field label, .field .lbl { display: block; font-size: var(--fs-0); color: var(--ink-2); font-weight: 800; margin: 0 0 5px 2px; letter-spacing: .3px; text-transform: uppercase; }
.field input::placeholder, .field textarea::placeholder { color: var(--ink-3); opacity: 1; }
.field input[type="search"] { -webkit-appearance: none; appearance: none; }
input[type="search"]::-webkit-search-decoration, input[type="search"]::-webkit-search-cancel-button, input[type="search"]::-webkit-search-results-button, input[type="search"]::-webkit-search-results-decoration { -webkit-appearance: none; display: none; }
.field input, .field select, .field textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line-2); border-radius: 13px; background: color-mix(in oklab, var(--canvas-2) 82%, transparent); color: var(--ink); font-size: 16px; min-height: 46px;
  box-shadow: inset 0 1px 2px rgb(0 0 0 / .04); transition: border-color var(--dur-effects-fast), box-shadow var(--dur-effects-fast);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in oklab, var(--accent) 22%, transparent); }
.field .hint, .hint { font-size: var(--fs-0); color: var(--ink-3); margin: 4px 2px 0; line-height: 1.4; }
.field .with { position: relative; }
.field .with .pre { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); font-weight: 700; }
.field .with input { padding-left: 26px; }
.field .with .suf { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); font-size: var(--fs-1); font-weight: 700; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; row-gap: 10px; }
@supports (grid-template-rows: subgrid) { .grid2 > .field { display: grid; grid-template-rows: subgrid; grid-row: span 4; align-content: start; margin-bottom: 0; } }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.money-echo { font-size: var(--fs-0); color: var(--accent-ink); font-weight: 700; margin: 4px 2px 0; min-height: 14px; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.switch:last-child { border-bottom: 0; }
.switch .lab { font-size: var(--fs-2); font-weight: 700; } .switch .lab small { display: block; font-size: var(--fs-0); color: var(--ink-3); font-weight: 600; margin-top: 1px; }
.tog { width: 48px; height: 28px; border-radius: 14px; background: color-mix(in oklab, var(--ink) 18%, transparent); position: relative; flex: none; transition: background var(--dur-effects-default); box-shadow: inset 0 1px 2px rgb(0 0 0 / .18); }
.tog::before { content: ""; position: absolute; inset: -8px; }
.tog::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / .3); transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); }
.tog[aria-checked="true"] { background: var(--accent); } .tog[aria-checked="true"]::after { transform: translateX(20px); }
.range { -webkit-appearance: none; appearance: none; width: 100%; height: 28px; background: transparent; }
.range::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--accent) var(--pct, 50%), color-mix(in oklab, var(--ink) 14%, transparent) var(--pct, 50%)); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; border-radius: 50%; background: #fff; margin-top: -10px; box-shadow: 0 1px 4px rgb(0 0 0 / .3), 0 0 0 1px var(--line-2); }
.range::-moz-range-track { height: 6px; border-radius: 3px; background: color-mix(in oklab, var(--ink) 14%, transparent); }
.range::-moz-range-progress { height: 6px; border-radius: 3px; background: var(--accent); }
.range::-moz-range-thumb { width: 26px; height: 26px; border: 0; border-radius: 50%; background: #fff; box-shadow: 0 1px 4px rgb(0 0 0 / .3); }
.chk { display: flex; gap: 10px; align-items: flex-start; font-size: var(--fs-1); color: var(--ink-2); line-height: 1.5; margin: 10px 0; }
.chk input { margin-top: 2px; accent-color: var(--accent); width: 20px; height: 20px; flex: none; }

/* ---- result rows ---- */
.result { background: color-mix(in oklab, var(--accent) 6%, var(--canvas-2)); border: 1px solid color-mix(in oklab, var(--accent) 22%, transparent); border-radius: var(--r-md); padding: 10px 13px; font-size: var(--fs-2); }
.result .r { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px dashed color-mix(in oklab, var(--accent) 20%, transparent); align-items: baseline; }
.result .r:last-child { border-bottom: 0; }
.result .r .k { color: var(--ink-2); min-width: 0; } .result .r .k small { display: block; font-size: var(--fs-0); color: var(--ink-3); font-weight: 500; }
.result .r .v { font-weight: 800; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.result .r.long { flex-direction: column; align-items: flex-start; gap: 2px; } .result .r.long .v { text-align: left; white-space: normal; }
.result .r.tot { border-top: 2px solid var(--accent); margin-top: 6px; padding-top: 10px; font-size: var(--fs-4); }
.result .r.tot .v { color: var(--accent-ink); font-size: var(--fs-5); letter-spacing: -.4px; }
.result .r.tot .v.money { color: #b06a00; }
html[data-scheme="dark"] .result .r.tot .v.money { color: #ffc46b; }
@media (prefers-color-scheme: dark) { html:not([data-scheme="light"]) .result .r.tot .v.money { color: #ffc46b; } }
.headline { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; padding: 4px 2px 10px; }
.headline .k { font-size: var(--fs-1); color: var(--ink-2); font-weight: 700; }
.headline .v { font-family: var(--font-display); font-size: var(--fs-7); font-weight: 800; letter-spacing: -1px; color: var(--accent-ink); line-height: 1; font-variant-numeric: tabular-nums; }
.routes { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 8px 0; }
.route-card { border-radius: var(--r-md); padding: 10px 12px; background: color-mix(in oklab, var(--canvas-2) 70%, transparent); box-shadow: inset 0 0 0 1px var(--line); position: relative; }
.route-card.best { box-shadow: inset 0 0 0 2px var(--accent); background: var(--accent-soft); }
.route-card .k { font-size: var(--fs-0); font-weight: 800; color: var(--ink-2); text-transform: uppercase; letter-spacing: .4px; }
.route-card .v { font-size: var(--fs-5); font-weight: 800; color: var(--accent-ink); letter-spacing: -.4px; margin-top: 2px; font-variant-numeric: tabular-nums; }
.route-card .s { font-size: var(--fs-0); color: var(--ink-3); margin-top: 2px; }
.route-card .best-tag { position: absolute; top: -8px; right: 8px; }
.working { margin-top: 8px; }
.working details { border-radius: var(--r-md); background: color-mix(in oklab, var(--canvas-2) 60%, transparent); box-shadow: inset 0 0 0 1px var(--line); padding: 0 12px; }
.working summary { list-style: none; cursor: pointer; padding: 10px 0; font-size: var(--fs-1); font-weight: 800; color: var(--accent-ink); display: flex; align-items: center; gap: 6px; }
.working summary::-webkit-details-marker { display: none; }
.working summary .icon { font-size: 16px; transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); }
.working details[open] summary .icon { transform: rotate(180deg); }
.working ol { margin: 0; padding: 0 0 10px 18px; font-size: var(--fs-1); color: var(--ink-2); line-height: 1.5; }
.working li { margin-bottom: 6px; } .working li b { color: var(--ink); }
.cites { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.cite { font-family: var(--mono); font-size: 10.5px; font-weight: 700; padding: 3px 8px; border-radius: 8px; background: color-mix(in oklab, var(--ink) 6%, transparent); color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); }
.warnings { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.warnings .w { display: flex; gap: 8px; font-size: var(--fs-1); line-height: 1.45; padding: 8px 10px; border-radius: 12px; }
.warnings .w.info { background: color-mix(in oklab, var(--info) 9%, transparent); color: var(--ink-2); }
.warnings .w.warn { background: color-mix(in oklab, var(--warn) 12%, transparent); color: var(--ink); }
.warnings .w.risk { background: color-mix(in oklab, var(--risk) 10%, transparent); color: var(--ink); }
.warnings .w .icon { font-size: 16px; flex: none; margin-top: 1px; }
.warnings .w.info .icon { color: var(--info); } .warnings .w.warn .icon { color: var(--warn); } .warnings .w.risk .icon { color: var(--risk); }

/* ---- tiles / lists ---- */
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tile { position: relative; isolation: isolate; overflow: hidden; text-align: left; padding: 13px 13px 12px; border-radius: var(--r-lg); background: var(--card); box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--line), 0 10px 26px -16px rgb(0 0 0 / .25); min-height: 118px; display: flex; flex-direction: column; gap: 8px;
  transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); }
.tile:active { transform: scale(.97); }
.tile::before { content: ""; position: absolute; inset: auto -30% -50% auto; width: 70%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, color-mix(in oklab, var(--cat, var(--accent)) 26%, transparent), transparent); z-index: -1; }
.tile b { font-size: var(--fs-2); font-weight: 800; letter-spacing: -.1px; line-height: 1.2; }
.tile small { font-size: var(--fs-0); color: var(--ink-2); line-height: 1.35; }
.tile .arrow { position: absolute; right: 10px; top: 12px; color: var(--ink-3); font-size: 16px; }
.list { display: flex; flex-direction: column; }
.li { display: flex; gap: 11px; align-items: flex-start; padding: 11px 0; border-bottom: 1px solid var(--line); text-align: left; width: 100%; }
.li:last-child { border-bottom: 0; }
.li .t { font-size: var(--fs-2); font-weight: 800; line-height: 1.25; } .li .s { font-size: var(--fs-0); color: var(--ink-2); margin-top: 2px; line-height: 1.4; }
.li .r { margin-left: auto; text-align: right; flex: none; }
.li.press { transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); } .li.press:active { transform: scale(.985); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; font-size: var(--fs-1); }
.kv dt { color: var(--ink-2); font-weight: 600; } .kv dd { margin: 0; font-weight: 600; text-align: right; }
.table { width: 100%; border-collapse: collapse; font-size: var(--fs-1); }
.table th { text-align: left; font-size: var(--fs-0); text-transform: uppercase; letter-spacing: .4px; color: var(--ink-3); padding: 6px 6px; border-bottom: 1px solid var(--line-2); }
.table td { padding: 7px 6px; border-bottom: 1px dashed var(--line); vertical-align: top; }
.table td.n, .table th.n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tscroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -4px; padding: 0 4px; }
.divider { height: 1px; background: var(--line); margin: 12px 0; }
.empty { text-align: center; padding: 26px 14px; color: var(--ink-3); font-size: var(--fs-2); }
.empty .icon { font-size: 40px; margin: 0 auto 8px; color: var(--accent-ink); opacity: .8; }
.avatar { width: 52px; height: 52px; border-radius: 18px; display: grid; place-items: center; font-weight: 900; font-size: 20px; color: var(--on-accent); background: linear-gradient(160deg, color-mix(in oklab, var(--accent) 85%, white), var(--accent-2)); box-shadow: inset 0 1px 0 rgb(255 255 255 / .5); }

/* ---- accordion service card ---- */
.svc { position: relative; background: var(--card); border-radius: var(--r-lg); margin-bottom: 10px; box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--line), 0 10px 26px -16px rgb(0 0 0 / .25); overflow: clip; }
.svc::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 3px; border-radius: 0 2px 2px 0; background: var(--cat, var(--accent)); z-index: 1; }

 










/* ---- stepper ---- */
.steps { display: flex; gap: 6px; margin: 8px 0 14px; align-items: center; }
.steps .st { flex: 1; height: 6px; border-radius: 4px; background: color-mix(in oklab, var(--ink) 10%, transparent); position: relative; overflow: hidden; }
.steps .st::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transform: scaleX(0); transform-origin: left; transition: transform var(--dur-spatial-default) var(--ease-spatial-default); border-radius: inherit; }
.steps .st.on::after { transform: scaleX(1); }
.steps .lbl { font-size: var(--fs-0); font-weight: 800; color: var(--accent-ink); white-space: nowrap; }

/* ---- meters / rings / bars / sparkline ---- */
.ring { position: relative; width: 58px; height: 58px; flex: none; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring circle { fill: none; stroke-width: 6; stroke-linecap: round; }
.ring .bg { stroke: color-mix(in oklab, var(--ink) 10%, transparent); }
.ring svg, .ring .fg { --ring: inherit; } /* --ring is registered with inherits:false; pass it down explicitly */
.ring .fg { stroke: var(--ring-c, var(--accent)); stroke-dasharray: 100 100; stroke-dashoffset: calc((100 - var(--ring, 0)) * 1px); transition: stroke-dashoffset 900ms var(--ease-spatial-slow); }
.ring .val { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 900; font-size: var(--fs-3); letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.ring .val small { font-size: 9.5px; display: block; text-align: center; color: var(--ink-3); font-weight: 800; letter-spacing: .3px; margin-top: -2px; }
.ring.lg { width: 96px; height: 96px; } .ring.lg .val { font-size: var(--fs-6); }
.bar { height: 8px; border-radius: 5px; background: color-mix(in oklab, var(--ink) 9%, transparent); overflow: hidden; flex: 1; }
.bar i { display: block; height: 100%; border-radius: inherit; width: var(--w, 0%); background: linear-gradient(90deg, color-mix(in oklab, var(--bar-c, var(--accent)) 80%, black), var(--bar-c, var(--accent))); transition: width 800ms var(--ease-spatial-slow); }
.bars .brow { display: flex; align-items: center; gap: 10px; font-size: var(--fs-1); padding: 5px 0; }
.bars .brow .k { width: 78px; color: var(--ink-2); font-weight: 700; flex: none; } .bars .brow .n { width: 44px; text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; flex: none; }
.spark { width: 100%; height: 36px; overflow: visible; }
.spark path { fill: none; stroke: var(--spark-c, var(--accent)); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.spark .area { fill: url(#sparkfill); stroke: none; opacity: .5; }
.spark .dot { fill: var(--spark-c, var(--accent)); }
.band-Strong { --ring-c: var(--good); --bar-c: var(--good); } .band-Watch { --ring-c: var(--warn); --bar-c: var(--warn); } .band-Risk { --ring-c: var(--risk); --bar-c: var(--risk); }

/* ---- timeline ---- */
.tl { position: relative; padding-left: 26px; margin: 8px 0; }
.tl::before { content: ""; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(var(--accent), color-mix(in oklab, var(--accent) 20%, transparent)); border-radius: 2px; }
.tl .node { position: relative; padding: 0 0 14px; }
.tl .node:last-child { padding-bottom: 0; }
.tl .node::before { content: ""; position: absolute; left: -22px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--canvas-2); box-shadow: 0 0 0 2px var(--accent); }
.tl .node.done::before { background: var(--accent); box-shadow: 0 0 0 2px var(--accent), 0 0 0 6px color-mix(in oklab, var(--accent) 18%, transparent); }
.tl .node.now::before { background: var(--accent-2); box-shadow: 0 0 0 2px var(--accent-2); }
.tl .node.now::after { content: ""; position: absolute; left: -22px; top: 4px; width: 12px; height: 12px; border-radius: 50%; box-shadow: 0 0 0 2px var(--accent-2); animation: tl-ring 1.6s ease-out infinite; }
@keyframes tl-ring { to { transform: scale(2.4); opacity: 0; } }
.tl .node.todo::before { box-shadow: 0 0 0 2px var(--line-2); }
@keyframes tl-pulse { 0%,100% { box-shadow: 0 0 0 2px var(--accent-2); } 50% { box-shadow: 0 0 0 2px var(--accent-2), 0 0 0 8px color-mix(in oklab, var(--accent-2) 22%, transparent); } }
.tl .node b { font-size: var(--fs-2); display: block; } .tl .node small { font-size: var(--fs-0); color: var(--ink-2); display: block; line-height: 1.4; margin-top: 1px; }
.tl .node .rcpt { margin-top: 6px; font-family: var(--mono); font-size: 10px; color: var(--ink-3); background: color-mix(in oklab, var(--ink) 5%, transparent); border-radius: 8px; padding: 5px 8px; display: inline-block; }

/* ---- skeleton + typing ---- */


@keyframes shimmer { to { transform: translateX(100%); } }
.caret { display: inline-block; width: 2px; height: 1em; background: var(--accent); vertical-align: -2px; margin-left: 1px; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.term { border-bottom: 1.5px dotted var(--accent-line); cursor: pointer; color: inherit; font-weight: 700; }

html[data-privacy] .pv { color: transparent !important; text-shadow: 0 0 9px var(--ink-2); user-select: none; }
html[data-privacy] .pv * { color: transparent !important; }
.pulse { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; margin: 14px auto; color: var(--on-accent); background: linear-gradient(160deg, color-mix(in oklab, var(--accent) 85%, white), var(--accent)); position: relative; }
.pulse::after { content: ""; position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 3px color-mix(in oklab, var(--accent) 45%, transparent); animation: tl-ring 1.2s ease-out infinite; }
.pulse .icon { font-size: 36px; }
@keyframes pu { 0% { box-shadow: 0 0 0 0 color-mix(in oklab, var(--accent) 45%, transparent); } 100% { box-shadow: 0 0 0 26px color-mix(in oklab, var(--accent) 0%, transparent); } }
@media (prefers-reduced-motion: reduce) { .pulse::after, .tl .node.now::after, .caret { animation: none; } .page { animation-name: none; } .spark path, .ring .fg, .bar i, .steps .st::after { animation: none !important; transition: none !important; }  }
html[data-reduce-motion] .pulse::after, html[data-reduce-motion] .tl .node.now::after { animation: none; }
.clamp2 { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; white-space: normal; }

/* ===== 35-icons.css ===== */
/* ==========================================================================
   35-icons.css — CAPGAIN icon system (owner: ICON AGENT)
   Inline-SVG icons produced by CG.icons.icon(); all motion tokens live here.
   Colour comes only from currentColor / --cat / --accent (set by core).
   ========================================================================== */

/* ---- 1. motion tokens (prefixed as in the research prototype) ---- */
:where(:root) {   /* defaults; core tokens of the same name (10-tokens.css) take precedence */
  --dur-instant: 90ms;    /* press-down */
  --dur-fast:    150ms;   /* hover, colour, opacity */
  --dur-base:    240ms;   /* state change, fill morph, path morph */
  --dur-draw:    320ms;   /* one path draw-in */
  --dur-slow:    400ms;   /* choreographed multi-part */
  --dur-gesture: 600ms;   /* wiggle / ring / one-shot flourish */
  --dur-loop:    1200ms;  /* orbit / sweep / pulse cycle */
  --stagger:     60ms;    /* between parts */

  --ease-out:        cubic-bezier(0.2, 0, 0, 1);
  --ease-emph-decel: cubic-bezier(0.05, 0.7, 0.1, 1);
  --ease-emph-accel: cubic-bezier(0.3, 0, 0.8, 0.15);
  --ease-in-out:     cubic-bezier(0.45, 0, 0.55, 1);

  /* springs: cubic-bezier fallbacks; linear() upgrades below */
  --spring-settle-dur: 190ms; --spring-settle: cubic-bezier(0.2, 0, 0, 1);       /* zeta 1.0: fill, colour, opacity */
  --spring-tap-dur:    300ms; --spring-tap:    cubic-bezier(0.34, 1.3, 0.64, 1);  /* zeta .75, 3% overshoot */
  --spring-bounce-dur: 500ms; --spring-bounce: cubic-bezier(0.34, 1.56, 0.64, 1); /* zeta .55, 12.6% overshoot */

  --icon-stroke: 1.75;
  --icon-fill-opacity: 0;   /* duotone layer; 0 = outline only */
}
@supports (animation-timing-function: linear(0, 1)) {
  :where(:root) {
    /* k=1600 c=80 zeta=1.00 */
    --spring-settle: linear(0, 0.005783 1.5%, 0.0215 3.0%, 0.08527 6.5%, 0.4506 20.5%, 0.616 28.0%, 0.7334 35.0%, 0.7827 38.8%, 0.8238 42.5%, 0.8657 47.2%, 0.8998 52.2%, 0.9279 57.8%, 0.95 63.7%, 0.966 70.0%, 0.9781 77.0%, 0.9885 87.0%, 0.995 99.8%, 1);
    /* k=600 c=36.7 zeta=0.75 */
    --spring-tap: linear(0, 0.005527 1.5%, 0.02434 3.2%, 0.1045 7.2%, 0.2089 11.0%, 0.5487 22.0%, 0.7286 29.0%, 0.8527 35.5%, 0.8994 38.8%, 0.9395 42.2%, 0.9739 46.2%, 0.9992 50.5%, 1.017 55.2%, 1.026 60.5%, 1.026 72.2%, 1.005 99.8%, 1);
    /* k=350 c=20.6 zeta=0.55 */
    --spring-bounce: linear(0, 0.009124 1.5%, 0.03459 3.0%, 0.1328 6.2%, 0.6788 18.2%, 0.8789 23.5%, 0.953 26.0%, 1.013 28.5%, 1.058 31.0%, 1.094 33.8%, 1.112 36.0%, 1.122 38.2%, 1.126 40.8%, 1.122 43.5%, 1.103 48.2%, 1.019 63.2%, 1 68.5%, 0.9888 74.0%, 0.9845 79.2%, 0.985 85.2%, 0.9949 99.8%, 1);
  }
}

/* ---- 2. base ---- */
.icon {
  display: inline-block;
  width: var(--icon-size, 1em); height: var(--icon-size, 1em);   /* size via font-size, or icon(name,{size}) */
  vertical-align: -0.125em;
  overflow: visible;                       /* overshoot / orbits may leave the 24 box */
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: var(--icon-stroke);
  stroke-linecap: round;
  stroke-linejoin: round;
  color: inherit;
  transition: color var(--dur-fast) var(--ease-out),
              stroke-width var(--dur-base) var(--ease-out),
              opacity var(--dur-fast) var(--ease-out),
              transform var(--spring-tap-dur) var(--spring-tap);
  -webkit-tap-highlight-color: transparent;
  pointer-events: none;                    /* the host control is the hit target */
}
.icon[role="img"] { pointer-events: auto; }
.icon[data-cat] { color: var(--cat, currentColor); }
.icon [data-part] {
  transform-box: fill-box;                 /* rotate/scale parts about their own centre */
  transform-origin: center;
  transition: opacity var(--dur-fast) var(--ease-out),
              fill-opacity var(--dur-base) var(--ease-out),
              transform var(--spring-tap-dur) var(--spring-tap);
}
.icon [data-part="fill"], .icon [data-fillable] { fill: currentColor; fill-opacity: var(--icon-fill-opacity); }
.icon [data-part="fill"] { stroke: none; }
.icon [data-hidden] { opacity: 0; }                                   /* parts shown only by a state/gesture */
.icon [data-hidden][pathLength] {                                     /* drawable hidden strokes (eye slash) */
  stroke-dasharray: 1 1.1; stroke-dashoffset: 1.05;
  transition: stroke-dashoffset var(--dur-draw) var(--ease-out), opacity var(--dur-fast) var(--ease-out);
}
.icon [data-soft] { stroke-width: 4; stroke-opacity: 0.18; }         /* wide translucent glow strokes (no filters) */

/* ---- 3. mount draw-in (pathLength="1" parts) + pops, staggered by --i ---- */
@keyframes icon-draw { 0% { stroke-dashoffset: 1.05; opacity: 0; } 15% { opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 1; } }
@keyframes icon-pop  { 0% { transform: scale(0.4); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes icon-fade { from { opacity: 0; } to { opacity: 1; } }
.icon[data-animate="mount"] [pathLength]:not([data-hidden]) {
  stroke-dasharray: 1 1.1;
  animation: icon-draw var(--dur-draw) var(--ease-out) backwards;
  animation-delay: calc(var(--i, 0) * var(--stagger));
}
.icon[data-animate="mount"] [data-pop]:not([data-hidden]) {
  animation: icon-pop var(--spring-tap-dur) var(--spring-tap) backwards;
  animation-delay: calc(var(--i, 0) * var(--stagger) + 120ms);
}

/* ---- 4. states (precedence: hover → selected → loading → pressed → disabled) ---- */
.icon.is-hover    { --icon-stroke: 1.9; }
.icon.is-selected { --icon-fill-opacity: 0.16; --icon-stroke: 2; }
[data-icon-btn][aria-selected="true"] .icon,
[data-icon-btn].on .icon { --icon-fill-opacity: 0.16; --icon-stroke: 2; }   /* CSS mirror of .is-selected */
.icon--percent.is-selected, .icon--heart.is-selected, .icon--star.is-selected,
[data-icon-btn][aria-selected="true"] .icon--heart, [data-icon-btn].on .icon--heart,
[data-icon-btn][aria-selected="true"] .icon--star,  [data-icon-btn].on .icon--star { --icon-fill-opacity: 1; }
.icon.is-loading [data-part="check"] { opacity: 0; }
.icon.is-pressed  { transform: scale(0.92); transition: transform var(--dur-instant) var(--ease-emph-accel); }
.icon.is-disabled { opacity: 0.38; }

/* morph states */
.icon--sun-moon [data-part="ray"]  { transition: opacity var(--dur-fast) var(--ease-out), transform var(--spring-tap-dur) var(--spring-tap); transition-delay: calc(var(--i, 0) * 20ms); }
.icon--sun-moon.is-moon [data-part="ray"]  { opacity: 0; transform: scale(0.3); }
.icon--sun-moon [data-part="star"] { transition-delay: 0ms; }
.icon--sun-moon.is-moon [data-part="star"] { opacity: 1; transition-delay: var(--dur-base); }
.icon--eye.is-off [data-part="slash"] { opacity: 1; stroke-dashoffset: 0; }
.icon--eye.is-off [data-part="pupil"] { transform: scale(0.55); opacity: 0.55; }

/* ---- 5. loading loops (only while .is-loading) ---- */
@keyframes icon-orbit   { to { transform: rotate(360deg); } }
@keyframes icon-blink   { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }
@keyframes icon-breathe { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.04); opacity: 0.6; } }
@keyframes icon-sweep   { 0% { transform: translateY(-3.5px); opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { transform: translateY(9px); opacity: 0; } }
@keyframes icon-wave    { 0%, 100% { opacity: 0.25; transform: scale(0.94); } 40% { opacity: 1; transform: scale(1); } }
@keyframes icon-write   { 0% { stroke-dashoffset: 1.05; opacity: 0; } 20% { opacity: 1; } 70% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes icon-flip    { 0% { transform: scaleX(1); opacity: 0; } 15% { opacity: 1; } 50% { transform: scaleX(0); } 85% { opacity: 1; } 100% { transform: scaleX(-1); opacity: 0; } }
@keyframes icon-spinx   { 0% { transform: translateX(0) scaleX(1); } 49.9% { transform: translateX(3.6px) scaleX(0.08); } 50% { transform: translateX(-3.6px) scaleX(0.08); } 100% { transform: translateX(0) scaleX(1); } }
@keyframes icon-scribble{ 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-0.6px, 0.6px); } 75% { transform: translate(0.5px, -0.4px); } }

.icon--ask.is-loading          [data-part="orbit"]   { animation: icon-orbit var(--dur-loop) linear infinite; }
.icon--advisory.is-loading     [data-part="rupee"]   { animation: icon-blink 900ms var(--ease-in-out) infinite; }
.icon--properties.is-loading   [data-part="win"]     { animation: icon-blink 1000ms var(--ease-in-out) infinite; animation-delay: calc(var(--i, 0) * 120ms); }
.icon--knowledge.is-loading    [data-part="leaf"]    { animation: icon-flip 1100ms var(--ease-in-out) infinite; }
.icon--my.is-loading           [data-part="shield"]  { animation: icon-breathe 1600ms var(--ease-in-out) infinite; }
.icon--rupee-calc.is-loading   [data-part="key"]     { animation: icon-blink 900ms var(--ease-in-out) infinite; animation-delay: calc(var(--i, 0) * 150ms); }
.icon--percent.is-loading      [data-part^="dot"]    { animation: icon-blink 900ms var(--ease-in-out) infinite; }
.icon--percent.is-loading      [data-part="dot-b"]   { animation-delay: 450ms; }
.icon--shield-check.is-loading [data-part="shield"]  { animation: icon-breathe 1600ms var(--ease-in-out) infinite; }
.icon--doc-pen.is-loading      [data-part="line"]    { stroke-dasharray: 1 1.1; animation: icon-write 1400ms var(--ease-in-out) infinite; animation-delay: calc(var(--i, 0) * 200ms); }
.icon--doc-pen.is-loading      [data-part="pen"]     { animation: icon-scribble 700ms var(--ease-in-out) infinite; }
.icon--seal-check.is-loading   [data-part="badge"]   { animation: icon-orbit 2400ms linear infinite; }
.icon--bank.is-loading         [data-part="col"]     { animation: icon-blink 900ms var(--ease-in-out) infinite; animation-delay: calc(var(--i, 0) * 150ms); }
.icon--globe.is-loading        [data-part="meridian"]{ animation: icon-spinx 1400ms linear infinite; }
.icon--scan.is-loading         [data-part="scanline"],
.icon--scan.is-loading         [data-part="glow"]    { animation: icon-sweep var(--dur-loop) var(--ease-in-out) infinite; }
.icon--phone.is-loading        [data-part="wave"]    { animation: icon-wave var(--dur-loop) var(--ease-in-out) infinite; animation-delay: calc(var(--i, 0) * 140ms); }
.icon--vault.is-loading        [data-part="dial"]    { animation: icon-orbit 1600ms var(--ease-in-out) infinite; }
.icon--mic.is-loading          [data-part="capsule"] { animation: icon-breathe 1200ms var(--ease-in-out) infinite; }
.icon--refresh.is-loading      [data-part="glyph"]   { animation: icon-orbit var(--dur-loop) linear infinite; }
.icon--scan [data-part="glow"], .icon--qr [data-part="glow"] { stroke-width: 4; stroke-opacity: 0.18; opacity: 0; }

/* ---- 6. ripple + interactive host ---- */
:where([data-icon-btn]) { position: relative; isolation: isolate; overflow: hidden; touch-action: manipulation; -webkit-tap-highlight-color: transparent; user-select: none; -webkit-user-select: none; }   /* zero specificity: core's own button rules win */
.ripple { position: absolute; border-radius: 50%; background: currentColor; opacity: 0.18; transform: scale(0); pointer-events: none; z-index: 0;
          animation: ripple 550ms var(--ease-out) forwards; }
@keyframes ripple { to { transform: scale(4); opacity: 0; } }

/* ---- 7. icon chip (36–40px tile) + hero (72px, idle breathe) ---- */
.icon-chip {
  display: inline-grid; place-items: center; flex: none;
  width: 40px; height: 40px; border-radius: 12px;
  color: var(--cat, var(--accent, currentColor));
  background: color-mix(in oklab, var(--cat, var(--accent, currentColor)) 14%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--cat, var(--accent, currentColor)) 22%, transparent);
  transition: background var(--dur-fast) var(--ease-out), transform var(--spring-tap-dur) var(--spring-tap);
}
.icon-chip > .icon { font-size: 22px; }
.icon-chip.sm { width: 36px; height: 36px; border-radius: 10px; }
.icon-chip.sm > .icon { font-size: 20px; }
.icon-chip.lg { width: 48px; height: 48px; border-radius: 14px; }
.icon-chip.lg > .icon { font-size: 26px; }
.icon-chip.is-pressed { transform: scale(0.94); }

@keyframes icon-hero-breathe { 0%, 100% { transform: translateY(0) scale(1); } 50% { transform: translateY(-1.5px) scale(1.035); } }
.icon-hero { display: inline-block; --icon-size: 72px; font-size: 72px; }
.icon-hero > .icon, .icon.icon-hero { --icon-size: 72px; animation: icon-hero-breathe 4200ms var(--ease-in-out) infinite; }
.icon-hero > .icon [data-part="fill"] { fill-opacity: max(var(--icon-fill-opacity), 0.1); }
.icon.flip { rotate: 180deg; }
.icons-paused .icon, .icons-paused > .icon,
.icons-paused .icon-hero > .icon, .icons-paused .icon.icon-hero,
.icons-paused .icon.is-loading [data-part] { animation-play-state: paused; }   /* set on <html> while document.hidden */

/* ---- 8. reduced motion: reduce, don't remove ---- */
@media (prefers-reduced-motion: reduce) {
  .icon, .icon [data-part], .icon-chip { transition-duration: var(--dur-fast); }
  .icon[data-animate="mount"] [pathLength]:not([data-hidden]),
  .icon[data-animate="mount"] [data-pop]:not([data-hidden]) { animation-name: icon-fade; animation-duration: var(--dur-fast); animation-delay: 0ms; stroke-dasharray: none; }
  .icon.is-loading [data-part] { animation-name: icon-blink !important; animation-duration: 1400ms !important; transform: none !important; }
  .icon.is-pressed, .icon-chip.is-pressed { transform: none; }
  .icon--sun-moon.is-moon [data-part="ray"] { transform: none; }
  .icon--eye.is-off [data-part="pupil"] { transform: none; }
  .icon-hero > .icon, .icon.icon-hero { animation: none; }
  .ripple { animation-duration: 200ms; }
}

/* ===== 40-pages.css ===== */
/* ==========================================================================
   40-pages.css — screen-specific styling
   ========================================================================== */
/* ---- HOME / ASK ---- */



 





#ai-thread { scroll-margin-top: calc(var(--top-h) + 8px); }
.ask { --r: 24px; margin: 12px 0 10px; padding: 8px; }
/* content-layer search bars are frosted cards, not navigation glass (no backdrop readback) */
.ask, .ksearch { -webkit-backdrop-filter: none; backdrop-filter: none; background: linear-gradient(var(--glass-tint), var(--glass-tint)), color-mix(in oklab, var(--canvas-2) 86%, transparent); }

.ask input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 10px 6px 10px 10px; font-size: 16px; color: var(--ink); outline: none; }
.ask input::placeholder, .ksearch input::placeholder { color: var(--ink-2); opacity: 1; }
.ask input, .ksearch input { -webkit-appearance: none; appearance: none; border-radius: 0; text-overflow: ellipsis; }
.ask input:focus-visible, .ksearch input:focus-visible { outline: none; box-shadow: none; }
.ask:focus-within, .ksearch:focus-within { outline: 2px solid var(--accent-line); outline-offset: 2px; }
.ask .go { width: 44px; height: 44px; border-radius: 16px; display: grid; place-items: center; color: #2a1900; background: linear-gradient(160deg, #ffd27a, var(--brand-orange) 55%, #f39a1b); box-shadow: inset 0 1px 0 rgb(255 255 255 / .55), 0 6px 14px -6px rgb(250 175 64 / .8); flex: none; transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); position: relative; isolation: isolate; overflow: hidden; }
.ask .go:active { transform: scale(.92); } .ask .go .icon { font-size: 22px; }



 

.ai-card { border-radius: var(--r-xl); padding: 14px 15px; margin: 10px 0 14px; background: linear-gradient(165deg, color-mix(in oklab, var(--accent) 10%, var(--card)), var(--card) 60%); box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--accent-line), 0 16px 34px -20px color-mix(in oklab, var(--accent) 60%, transparent); }

 






 









.next-action { display: flex; align-items: center; gap: 12px; padding: 12px 13px; border-radius: var(--r-lg); background: linear-gradient(120deg, color-mix(in oklab, var(--brand-orange) 22%, var(--card)), var(--card) 70%); box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--line); margin-bottom: 12px; text-align: left; width: 100%; }
.next-action .icon-chip { --cat: var(--brand-orange); }
.next-action b { display: block; font-size: var(--fs-2); } .next-action small { font-size: var(--fs-0); color: var(--ink-2); line-height: 1.35; display: block; margin-top: 1px; }



 

.delta.up { color: color-mix(in oklab, var(--good) 70%, var(--ink)); color: light-dark(color-mix(in oklab, var(--good) 70%, var(--ink)), var(--good)); }
.delta.down { color: color-mix(in oklab, var(--risk) 80%, var(--ink)); color: light-dark(color-mix(in oklab, var(--risk) 80%, var(--ink)), var(--risk)); }
.intel-item { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); text-align: left; width: 100%; }
.intel-item:last-child { border-bottom: 0; }
.intel-item .rule { width: 3px; border-radius: 2px; background: var(--cat, var(--accent)); flex: none; align-self: stretch; }
.intel-item b { font-size: var(--fs-2); display: block; line-height: 1.3; } .intel-item small { display: block; font-size: var(--fs-0); color: var(--ink-3); margin-top: 3px; }
.intel-item .meta { display: flex; gap: 6px; align-items: center; margin-top: 5px; flex-wrap: wrap; }

/* ---- PROPERTIES ---- */













 
















                 /* let labels shrink before they clip */
         /* on the detail sheet, two per row rather than four squeezed */





.deals { font-size: var(--fs-1); }



 
.approvals .ap { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: var(--fs-1); }
.approvals .ap:last-child { border-bottom: 0; }
.script { display: flex; flex-direction: column; gap: 8px; margin: 8px 0; }
.script .msg { max-width: 88%; padding: 8px 11px; border-radius: 16px; font-size: var(--fs-1); line-height: 1.45; animation: msg-in var(--dur-spatial-fast) var(--ease-spatial-fast) both; }
.script .msg.you { align-self: flex-end; background: var(--accent); color: var(--on-accent); border-bottom-right-radius: 6px; }
.script .msg.builder { align-self: flex-start; background: color-mix(in oklab, var(--ink) 7%, transparent); border-bottom-left-radius: 6px; }
.script .msg.system { align-self: center; font-size: var(--fs-0); color: var(--ink-3); background: transparent; text-align: center; max-width: 100%; }
.script .msg .at { display: block; font-size: 9.5px; opacity: .7; margin-top: 2px; font-family: var(--mono); }
@keyframes msg-in { from { opacity: 0; transform: translateY(8px) scale(.98); } }

/* ---- KNOWLEDGE ---- */
.ksearch { --r: 22px; padding: 8px 8px; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.ksearch input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 9px 8px; font-size: 16px; color: var(--ink); outline: none; }
.kres { margin: 0 0 12px; }
.kres .li .icon-chip { width: 34px; height: 34px; border-radius: 10px; } .kres .li .icon-chip .icon { font-size: 18px; }
.ktiles { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.ktile { position: relative; isolation: isolate; overflow: hidden; text-align: left; padding: 12px 12px 11px; border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 1px 0 color-mix(in srgb, var(--rim) 70%, transparent), inset 0 0 0 .5px var(--line); display: flex; gap: 10px; align-items: center; min-height: 64px; transition: transform var(--dur-spatial-fast) var(--ease-spatial-fast); }
.ktile:active { transform: scale(.97); }
.ktile b { font-size: var(--fs-1); font-weight: 800; line-height: 1.2; display: block; } .ktile small { font-size: var(--fs-0); color: var(--ink-3); display: block; margin-top: 1px; }
.ktile .icon-chip { width: 36px; height: 36px; border-radius: 11px; } .ktile .icon-chip .icon { font-size: 20px; }
.gloss-item { padding: 10px 0; border-bottom: 1px dashed var(--line); text-align: left; width: 100%; }
.gloss-item:last-child { border-bottom: 0; }
.gloss-item b { font-size: var(--fs-2); } .gloss-item .def { font-size: var(--fs-1); color: var(--ink-2); margin-top: 2px; line-height: 1.45; }
.gloss-item .st { font-size: var(--fs-0); color: var(--ink-3); margin-top: 3px; }
.alpha { display: flex; gap: 4px; flex-wrap: wrap; margin: 8px 0; }
.alpha button { width: 36px; height: 36px; border-radius: 10px; font-size: var(--fs-0); font-weight: 800; color: var(--ink-2); background: color-mix(in oklab, var(--ink) 5%, transparent); }
.alpha button.on { color: var(--on-accent); background: var(--accent); }
.tl-year { position: relative; padding-left: 22px; }
.tl-year::before { content: ""; position: absolute; left: 6px; top: 8px; bottom: 8px; width: 2px; background: var(--accent-line); }
.tl-year .ev { position: relative; padding: 6px 0 12px; }
.tl-year .ev::before { content: ""; position: absolute; left: -20px; top: 11px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px color-mix(in oklab, var(--accent) 20%, transparent); }
.tl-year .ev .d { font-family: var(--mono); font-size: 10.5px; color: var(--accent-ink); font-weight: 800; }
.tl-year .ev .e { font-size: var(--fs-1); color: var(--ink-2); line-height: 1.45; }

/* ---- MY CAPGAIN ---- */
.profile { display: flex; align-items: center; gap: 12px; padding: 6px 2px 10px; }
.profile .who b { font-size: var(--fs-4); display: block; } .profile .who small { font-size: var(--fs-0); color: var(--ink-3); display: block; }
.tier { display: inline-flex; align-items: center; gap: 5px; font-size: var(--fs-0); font-weight: 800; padding: 3px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-ink); margin-top: 4px; }
.matter { padding: 12px 13px; }
.matter .mh { display: flex; align-items: center; gap: 10px; }
.matter .mh b { font-size: var(--fs-2); display: block; line-height: 1.2; } .matter .mh small { font-size: var(--fs-0); color: var(--ink-3); display: block; margin-top: 1px; }
.sla { font-size: var(--fs-0); font-weight: 800; padding: 3px 8px; border-radius: 999px; background: color-mix(in oklab, var(--good) 14%, transparent); color: var(--good); white-space: nowrap; }
.sla.due { background: color-mix(in oklab, var(--warn) 18%, transparent); color: color-mix(in oklab, var(--warn) 75%, var(--ink)); }
.sla.late { background: color-mix(in oklab, var(--risk) 14%, transparent); color: var(--risk); }
.cal .day { display: flex; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--line); align-items: center; }
.cal .day:last-child { border-bottom: 0; }
.cal .dt { width: 44px; text-align: center; flex: none; border-radius: 11px; padding: 4px 0; background: var(--accent-soft); color: var(--accent-ink); }
.cal .dt b { display: block; font-size: var(--fs-4); line-height: 1; } .cal .dt small { font-size: 9px; font-weight: 800; letter-spacing: .5px; }
.cal .what b { font-size: var(--fs-1); display: block; } .cal .what small { font-size: var(--fs-0); color: var(--ink-3); }
.consent { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); }
.consent:last-child { border-bottom: 0; }
.consent b { font-size: var(--fs-1); display: block; } .consent small { font-size: var(--fs-0); color: var(--ink-3); display: block; line-height: 1.4; }
.trust .officer { display: grid; grid-template-columns: 1fr; gap: 4px; font-size: var(--fs-1); }
.ladder { counter-reset: step; }
.ladder .rung { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: var(--fs-1); align-items: flex-start; }
.ladder .rung:last-child { border-bottom: 0; }
.ladder .rung::before { counter-increment: step; content: counter(step); width: 22px; height: 22px; border-radius: 8px; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-items: center; font-weight: 900; font-size: 11px; flex: none; }
.ladder .rung b { display: block; } .ladder .rung small { color: var(--ink-3); font-size: var(--fs-0); display: block; }

/* ---- FEATURES / SETTINGS ---- */


 

.sys { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sys .s { padding: 10px 11px; border-radius: var(--r-md); background: color-mix(in oklab, var(--ink) 5%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.sys .s b { font-family: var(--font-display); font-size: var(--fs-5); display: block; letter-spacing: -.5px; color: var(--accent-ink); font-variant-numeric: tabular-nums; } .sys .s small { font-size: var(--fs-0); color: var(--ink-3); }
.settings .switch .lab { flex: 1; }
.swatches { display: flex; gap: 8px; }
.swatch { flex: 1; height: 44px; border-radius: 14px; box-shadow: inset 0 0 0 1px var(--line); display: grid; place-items: center; font-size: var(--fs-0); font-weight: 800; color: var(--ink-2); position: relative; }
.swatch.on { box-shadow: inset 0 0 0 2px var(--accent); color: var(--accent-ink); }
.swatch.l { background: #f3f5fb; color: #2a3350; } .swatch.d { background: #141a2b; color: #dfe5f5; } .swatch.s { background: linear-gradient(120deg, #f3f5fb 50%, #141a2b 50%); }
.swatch .swl { padding: 3px 9px; border-radius: 999px; background: color-mix(in oklab, #f3f5fb 92%, transparent); color: #2a3350; }
.doc { display: flex; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.doc:last-child { border-bottom: 0; }
.doc b { font-size: var(--fs-1); display: block; } .doc small { font-size: var(--fs-0); color: var(--ink-3); }
.extract { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 8px 0; }
.extract .x { padding: 7px 9px; border-radius: 10px; background: color-mix(in oklab, var(--ink) 5%, transparent); box-shadow: inset 0 0 0 1px var(--line); font-size: var(--fs-0); color: var(--ink-3); }
.extract .x b { display: block; font-size: var(--fs-1); color: var(--ink); margin-top: 1px; }
.prog { display: flex; flex-direction: column; gap: 6px; margin: 8px 0; }
.prog .p { display: flex; align-items: center; gap: 8px; font-size: var(--fs-1); color: var(--ink-3); }
.prog .p .icon { font-size: 16px; }
.prog .p.done { color: var(--ink); } .prog .p.done .icon { color: var(--good); } .prog .p.now { color: var(--accent-ink); font-weight: 700; }

/* ===== artifact host overrides ===== */
:root { --safe-t: 0px; }
.topbar { top: env(safe-area-inset-top, 0px); }

/* ================= V2.1 "Atlas" — location · street view · live feed · ratings ================= */

/* --- location bar --- */








/* --- street view / map panels --- */






/* --- live feed --- */
.live-item .meta .pill { flex: none; }
.live-item b { font-weight: 750; }

@media (prefers-reduced-motion: no-preference) {
  
  @keyframes live-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .45; transform: scale(.8); } }
}


/* --- a .more used outside a .sec header still gets a 44px hit area --- */
.more { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; padding: 12px 6px; margin: -12px -6px;
  font-size: var(--fs-1); font-weight: 700; color: var(--accent-ink); }

/* --- rate tables --- */
.table td .tiny { font-weight: 600; }
.card > .tscroll + .tiny { margin-top: 6px; }

/* ===== 46-gst-portal-privacy.css ===== */
/* ==========================================================================
   45 — GST law library · portal integration console · privacy centre
   Reuses the V2 card, chip, pill and result primitives; adds only what is new.
   ========================================================================== */

/* ---- generic two-line list row used by the law library and the registers ---- */
.lrow { display: flex; gap: 11px; align-items: flex-start; padding: 11px 0; border-bottom: 1px solid var(--line); }
.lrow:last-child { border-bottom: 0; }
.lrow .grow { min-width: 0; }
.lrow b { display: block; font-size: var(--fs-2); font-weight: 800; letter-spacing: -.1px; line-height: 1.3; }
.lrow small { display: block; font-size: var(--fs-1); color: var(--ink-2); line-height: 1.45; margin-top: 3px; }
.lrow .ref { font-family: var(--mono); font-size: var(--fs-0); color: var(--accent-ink); font-weight: 700; margin-top: 4px; display: block; word-break: break-word; }
.lrow .when { flex: none; font-size: var(--fs-0); color: var(--ink-3); font-weight: 700; font-variant-numeric: tabular-nums; padding-top: 2px; }

/* ---- rate table ---- */
.rtab { width: 100%; border-collapse: collapse; font-size: var(--fs-1); margin: 4px 0 2px; }
.rtab th, .rtab td { text-align: left; padding: 8px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.rtab th { font-size: var(--fs-0); text-transform: uppercase; letter-spacing: .4px; color: var(--ink-3); font-weight: 800; }
.rtab td.n { text-align: right; font-variant-numeric: tabular-nums; font-weight: 800; white-space: nowrap; }
.rtab tr.on td { background: var(--accent-soft); }
.rtab tr.on td:first-child { border-radius: 8px 0 0 8px; } .rtab tr.on td:last-child { border-radius: 0 8px 8px 0; }
.tscroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ---- rail card (integration console) ---- */
.rail { display: flex; gap: 11px; align-items: flex-start; padding: 12px; border-radius: var(--r-md); background: color-mix(in oklab, var(--canvas-2) 72%, transparent); box-shadow: inset 0 0 0 1px var(--line); margin-bottom: 8px; }
.rail .grow { min-width: 0; }
.rail b { display: block; font-size: var(--fs-2); font-weight: 800; }
.rail .org { font-size: var(--fs-0); color: var(--ink-3); font-weight: 700; letter-spacing: .2px; }
.rail p { font-size: var(--fs-1); color: var(--ink-2); line-height: 1.45; margin-top: 5px; }
.rail .auth { font-size: var(--fs-0); color: var(--ink-3); line-height: 1.45; margin-top: 6px; border-left: 2px solid var(--line-2); padding-left: 8px; }
.rail .caps { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 7px; }
.rail .caps .t { font-size: var(--fs-0); font-weight: 700; padding: 2px 7px; border-radius: 999px; background: color-mix(in oklab, var(--good) 13%, transparent); color: color-mix(in oklab, var(--good) 72%, var(--ink)); }
.rail .caps .t.no { background: color-mix(in oklab, var(--ink) 7%, transparent); color: var(--ink-3); text-decoration: line-through; }
html[data-scheme="dark"] .rail .caps .t { color: var(--good); }

/* ---- credential policy split ---- */
.credsplit { display: grid; gap: 10px; }
@media (min-width: 400px) { .credsplit { grid-template-columns: 1fr 1fr; } }
.credcol { border-radius: var(--r-md); padding: 11px 12px; }
.credcol.keep { background: color-mix(in oklab, var(--good) 8%, transparent); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--good) 30%, transparent); }
.credcol.never { background: color-mix(in oklab, var(--risk) 8%, transparent); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--risk) 30%, transparent); }
.credcol h4 { font-size: var(--fs-1); font-weight: 800; margin: 0 0 7px; display: flex; align-items: center; gap: 6px; }
.credcol.keep h4 { color: color-mix(in oklab, var(--good) 70%, var(--ink)); }
.credcol.never h4 { color: color-mix(in oklab, var(--risk) 78%, var(--ink)); }
html[data-scheme="dark"] .credcol.keep h4 { color: var(--good); } html[data-scheme="dark"] .credcol.never h4 { color: var(--risk); }
.credcol ul { margin: 0; padding-left: 16px; }
.credcol li { font-size: var(--fs-1); line-height: 1.5; margin-bottom: 6px; }
.credcol li b { font-weight: 800; }
.credcol li span { color: var(--ink-2); }

/* ---- prefill field rows ---- */
.pfield { display: flex; gap: 9px; align-items: center; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.pfield:last-child { border-bottom: 0; }
.pfield .grow { min-width: 0; }
.pfield b { display: block; font-size: var(--fs-2); font-weight: 700; }
.pfield small { display: block; font-size: var(--fs-0); color: var(--ink-3); line-height: 1.4; margin-top: 2px; }
.pfield .val { font-size: var(--fs-1); font-weight: 800; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; max-width: 42%; overflow: hidden; text-overflow: ellipsis; }
.prov { display: inline-flex; align-items: center; gap: 3px; font-size: var(--fs-0); font-weight: 800; padding: 2px 7px; border-radius: 999px; white-space: nowrap; }
.prov.high { background: color-mix(in oklab, var(--good) 15%, transparent); color: color-mix(in oklab, var(--good) 70%, var(--ink)); }
.prov.medium { background: color-mix(in oklab, var(--warn) 18%, transparent); color: color-mix(in oklab, var(--warn) 62%, var(--ink)); }
.prov.low { background: color-mix(in oklab, var(--risk) 14%, transparent); color: color-mix(in oklab, var(--risk) 78%, var(--ink)); }
html[data-scheme="dark"] .prov.high { color: var(--good); } html[data-scheme="dark"] .prov.medium { color: var(--warn); } html[data-scheme="dark"] .prov.low { color: var(--risk); }

/* ---- coverage meter ---- */
.cover { height: 8px; border-radius: 4px; background: color-mix(in oklab, var(--ink) 12%, transparent); overflow: hidden; margin: 8px 0 4px; }
.cover i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width var(--dur-spatial-default) var(--ease-spatial-default); }

/* ---- cookie banner: compact bottom bar, equal-weight choices (§36; CCPA dark-pattern guidelines) ---- */
.cookiebar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--bar-h) + 18px + var(--safe-b));
  width: min(1128px, calc(100vw - 16px)); z-index: 55; --r: 16px; --glass-alpha: max(.95, var(--glass-user));
  padding: 12px 14px; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; animation: toast-in var(--dur-spatial-default) var(--ease-spatial-default) both;
}
.cookiebar .cb-text { flex: 1 1 320px; min-width: 0; font-size: var(--fs-1); color: var(--ink-2); line-height: 1.45; }
.cookiebar .cb-text b { display: flex; align-items: center; gap: 6px; color: var(--ink); font-size: var(--fs-2); margin-bottom: 2px; }
.cookiebar .cb-text a { color: var(--accent-ink); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.cookiebar .cb-acts { display: flex; flex-wrap: wrap; gap: 6px; }
.cookiebar .cb-acts .btn { width: auto; min-height: 40px; }
@media (min-width: 1024px) { .cookiebar { bottom: 16px; } }
/* the tab bar stays visible and usable while the cookie bar is open (non-obstructive consent layer) */

/* ---- consent purpose row ---- */
.purp { padding: 12px 0; border-bottom: 1px solid var(--line); }
.purp:last-child { border-bottom: 0; }
.purp .ph { display: flex; gap: 10px; align-items: flex-start; }
.purp .ph .grow { min-width: 0; }
.purp b { font-size: var(--fs-3); font-weight: 800; display: block; letter-spacing: -.1px; }
.purp .gives { font-size: var(--fs-1); color: var(--ink-2); line-height: 1.5; margin-top: 3px; }
.purp .items { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 8px; }
.purp .items .t { font-size: var(--fs-0); font-weight: 700; padding: 2px 8px; border-radius: 999px; background: color-mix(in oklab, var(--ink) 6%, transparent); color: var(--ink-2); }
.purp dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 10px; margin: 9px 0 0; font-size: var(--fs-0); }
.purp dt { color: var(--ink-3); font-weight: 800; text-transform: uppercase; letter-spacing: .3px; }
.purp dd { margin: 0; color: var(--ink-2); line-height: 1.45; }

/* ---- ledger chain ---- */
.chain { font-family: var(--mono); font-size: var(--fs-0); color: var(--ink-3); }
.chain b { color: var(--ink-2); }
.ledrow { display: flex; gap: 8px; align-items: baseline; padding: 7px 0; border-bottom: 1px dashed var(--line); }
.ledrow:last-child { border-bottom: 0; }
.ledrow .ev { font-size: var(--fs-1); font-weight: 800; flex: none; }
.ledrow .ev.granted { color: color-mix(in oklab, var(--good) 70%, var(--ink)); }
.ledrow .ev.withdrawn { color: color-mix(in oklab, var(--risk) 75%, var(--ink)); }
html[data-scheme="dark"] .ledrow .ev.granted { color: var(--good); } html[data-scheme="dark"] .ledrow .ev.withdrawn { color: var(--risk); }

/* ---- timeline strip ---- */
.tline { display: flex; flex-direction: column; gap: 0; margin: 4px 0; }
.tline .tn { display: flex; gap: 12px; }
.tline .tn .dot { flex: none; width: 12px; display: flex; flex-direction: column; align-items: center; }
.tline .tn .dot i { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); margin-top: 5px; flex: none; }
.tline .tn .dot span { flex: 1; width: 2px; background: var(--line-2); }
.tline .tn:last-child .dot span { display: none; }
.tline .tn.past .dot i { background: var(--good); }
.tline .tn .body { padding-bottom: 14px; min-width: 0; }
.tline .tn .body b { font-size: var(--fs-2); font-weight: 800; }
.tline .tn .body .d { font-size: var(--fs-0); color: var(--accent-ink); font-weight: 800; letter-spacing: .3px; }
.tline .tn .body small { display: block; font-size: var(--fs-1); color: var(--ink-2); line-height: 1.45; margin-top: 3px; }

/* ---- risk / myth rows ---- */
.myth { padding: 10px 0; border-bottom: 1px solid var(--line); }
.myth:last-child { border-bottom: 0; }
.myth .w { font-size: var(--fs-2); font-weight: 700; color: color-mix(in oklab, var(--risk) 78%, var(--ink)); text-decoration: line-through; text-decoration-thickness: 1px; }
html[data-scheme="dark"] .myth .w { color: var(--risk); }
.myth .r { font-size: var(--fs-1); color: var(--ink-2); line-height: 1.5; margin-top: 4px; }

/* ---- faq accordion ---- */
.faq { border-bottom: 1px solid var(--line); }
.faq:last-child { border-bottom: 0; }
.faq summary { list-style: none; cursor: pointer; padding: 12px 0; display: flex; gap: 9px; align-items: flex-start; font-size: var(--fs-2); font-weight: 700; line-height: 1.4; min-height: 44px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { flex: none; margin-top: 1px; transition: transform var(--dur-effects-default) var(--ease-effects-default); }
.faq[open] summary .icon { transform: rotate(180deg); }
.faq .a { font-size: var(--fs-1); color: var(--ink-2); line-height: 1.6; padding: 0 0 12px 29px; }
.faq .a .ref { display: block; font-family: var(--mono); font-size: var(--fs-0); color: var(--accent-ink); margin-top: 6px; }


/* ===== 90-v23.css — "Enterprise" layer: calmer motion, line icons, layout fixes, wide-screen shell, new modules ===== */

/* ---- 1. motion: no overshoot, shorter, consistent ---- */
:root {
  --ease-spatial-fast: cubic-bezier(.2, .8, .2, 1); --dur-spatial-fast: 240ms;
  --ease-spatial-default: cubic-bezier(.2, .8, .2, 1); --dur-spatial-default: 320ms;
  --ease-spatial-slow: cubic-bezier(.2, .8, .2, 1); --dur-spatial-slow: 420ms;
  --spring-tap: cubic-bezier(.2, .8, .2, 1); --spring-tap-dur: 180ms; --spring-bounce: cubic-bezier(.2, .8, .2, 1);
  --icon-stroke: 1.6;
  --r-xl: 22px; --r-lg: 16px; --r-md: 12px; --r-sm: 10px;
}
@supports (animation-timing-function: linear(0, 1)) {
  :root { --ease-spatial-fast: cubic-bezier(.2, .8, .2, 1); --ease-spatial-default: cubic-bezier(.2, .8, .2, 1); --ease-spatial-slow: cubic-bezier(.2, .8, .2, 1); --spring-tap: cubic-bezier(.2, .8, .2, 1); --spring-bounce: cubic-bezier(.2, .8, .2, 1); }
}
html.is-resizing *, html.is-resizing *::before, html.is-resizing *::after { transition: none !important; }
.btn:active, .chip:active, .card.press:active, .tabbar .tab:active, .iconbtn:active { transform: scale(.98); }
::view-transition-old(content), ::view-transition-new(content) { animation-duration: 200ms; animation-timing-function: cubic-bezier(.2, 0, 0, 1); }
@keyframes vt-out-left  { to { translate: -10px 0; opacity: 0; } }
@keyframes vt-in-right  { from { translate: 10px 0; opacity: 0; } }
@keyframes vt-out-right { to { translate: 10px 0; opacity: 0; } }
@keyframes vt-in-left   { from { translate: -10px 0; opacity: 0; } }
.page { animation-duration: 220ms; }
@keyframes page-in { from { opacity: .001; transform: translateY(4px); } }
.sheet { transition-duration: 300ms; }
.toast { animation-duration: 220ms; }
@keyframes toast-in { from { transform: translateY(8px); opacity: 0; } }
.ambient::before { animation-duration: 30s !important; } .ambient::after { animation-duration: 36s !important; opacity: .7; }

/* ---- 2. icons: crisp line set — no duotone, no draw-in, no breathing ---- */
.icon { --icon-fill-opacity: 0; }
.icon[data-animate="mount"] [pathLength]:not([data-hidden]), .icon[data-animate="mount"] [data-pop]:not([data-hidden]) { animation: none !important; stroke-dasharray: none; }
[data-icon-btn][aria-selected="true"] .icon, [data-icon-btn].on .icon, .icon.is-selected { --icon-fill-opacity: 0; --icon-stroke: 1.9; }
.icon--heart.is-selected, [data-icon-btn].on .icon--heart, .icon--star.is-selected { --icon-fill-opacity: 1; }
.icon-hero > .icon, .icon.icon-hero { animation: none !important; }
.hero-cat .icon-hero { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; color: #fff; flex: none;
  background: linear-gradient(145deg, color-mix(in oklab, var(--accent) 88%, white), var(--accent) 60%, color-mix(in oklab, var(--accent) 70%, black));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .35), 0 8px 20px -10px color-mix(in oklab, var(--accent) 80%, transparent); }
.hero-cat .icon-hero .icon { width: 30px !important; height: 30px !important; --icon-size: 30px; --icon-stroke: 1.7; color: #fff; }
.hero-cat { gap: 14px; align-items: flex-start; padding-top: 10px; }
.hero-cat h1 { font-size: clamp(22px, 5.6vw, 30px); }
.icon-chip { border-radius: 11px; background: color-mix(in oklab, var(--cat, var(--accent)) 10%, var(--canvas-2)); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--cat, var(--accent)) 20%, transparent); }
.icon-chip > .icon { --icon-stroke: 1.7; }

/* ---- 3. tab bar: no clipping at 320–360 px ---- */
.tabbar .tab { font-size: 10.5px; letter-spacing: -.1px; gap: 2px; padding: 0 2px; }
.tabbar .tab span:not(.pill):not(.badge) { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.tabbar .tab .icon { font-size: 23px; }
.tabbar .tab .pill { transform: none; transition: opacity 200ms cubic-bezier(.2, 0, 0, 1); }
@media (max-width: 370px) { .tabbar .tab { font-size: 9.5px; } .tabbar .tab .icon { font-size: 21px; } }

/* ---- 4. overlap / overflow fixes found by the layout audit ---- */
.pill { max-width: 100%; }




.tile { min-width: 0; } .tile b, .tile small { overflow-wrap: anywhere; }
.sec h2 { min-width: 0; }
.result .r .v { white-space: normal; overflow-wrap: anywhere; min-width: 0; }
.result .r .k { flex: 1 1 auto; }
.headline .v { overflow-wrap: anywhere; text-align: right; }
.headline .v small { font-size: 55%; font-weight: 700; color: var(--ink-2); letter-spacing: 0; }
.btn-row.wrap { flex-wrap: wrap; } .btn-row.wrap .btn { flex: 1 1 200px; }
.sheet .sheet-head h2 { overflow-wrap: anywhere; }
.chips.scroll .chip { scroll-snap-align: start; }
.toasts { bottom: calc(var(--bar-h) + 24px + var(--safe-b)); }

/* ---- 5. Calculate / Reset bar + stale results ---- */
.calc-bar { display: grid; grid-template-columns: 2fr 1fr; gap: 8px; margin-top: 12px; }
.calc-bar .btn { min-height: 48px; }
#c-out, #land-out-box { position: relative; transition: opacity 200ms; }
#c-out.stale > *, #land-out-box.stale > * { opacity: .45; filter: saturate(.4); }
#c-out.stale::before, #land-out-box.stale::before { content: "Inputs changed — tap Calculate to update"; position: sticky; top: 64px; z-index: 3; display: block; width: max-content; max-width: 100%; margin: 0 auto 8px; padding: 6px 12px; border-radius: 999px; font-size: var(--fs-1); font-weight: 800; color: #6a3f00; background: color-mix(in oklab, var(--brand-orange) 30%, var(--canvas-2)); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--brand-orange) 55%, transparent); }

/* ---- 6. land calculator ---- */
.land-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) 42px; grid-template-areas: "label label label" "val unit del"; gap: 0 8px; padding: 10px 10px 2px; margin-bottom: 8px; border-radius: var(--r-md); background: color-mix(in oklab, var(--ink) 3.5%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.land-row .lr-label { grid-area: label; } .land-row .lr-val { grid-area: val; } .land-row .lr-unit { grid-area: unit; }
.land-row .lr-del { grid-area: del; align-self: start; margin-top: 21px; width: 42px; height: 46px; border-radius: 12px; }
.land-row .lr-del:disabled { opacity: .3; }
.land-row select { font-size: 15px; }
@media (min-width: 560px) { .land-row { grid-template-columns: minmax(0, 1.2fr) minmax(0, .9fr) minmax(0, 1.3fr) 42px; grid-template-areas: "label val unit del"; } }
.land-break { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: var(--r-md); background: var(--accent-soft); margin-bottom: 10px; }
.land-break b { font-size: var(--fs-4); color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.land-table { width: 100%; border-collapse: collapse; font-size: var(--fs-1); }
.land-table th { text-align: left; font-size: var(--fs-0); text-transform: uppercase; letter-spacing: .4px; color: var(--ink-3); font-weight: 800; padding: 6px 6px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
.land-table td { padding: 8px 6px; border-bottom: 1px solid var(--line); vertical-align: top; }
.land-table .r { text-align: right; white-space: nowrap; }
.land-table td small { display: block; color: var(--ink-3); font-size: var(--fs-0); margin-top: 2px; line-height: 1.35; }
.land-table tr.loc td:first-child b { color: var(--accent-ink); }
.land-table .pill { vertical-align: 1px; }

/* ---- 7. CTA rows ---- */
.crm-cta { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; margin: 4px 0 14px; border-radius: var(--r-lg); background: linear-gradient(120deg, color-mix(in oklab, var(--accent) 12%, var(--card)), var(--card)); box-shadow: inset 0 0 0 1px var(--accent-line), 0 8px 22px -14px rgb(0 0 0 / .3); transition: transform 180ms var(--ease-spatial-fast); }
.crm-cta b { display: block; font-size: var(--fs-3); } .crm-cta small { display: block; font-size: var(--fs-1); color: var(--ink-2); margin-top: 2px; }
.crm-cta:active { transform: scale(.99); }

/* ---- 8. Builder CRM ---- */
.crm .kicker { font-size: var(--fs-0); font-weight: 800; letter-spacing: .8px; text-transform: uppercase; color: var(--accent-ink); }









.kpi { padding: 11px 12px; border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 0 0 1px var(--line), 0 6px 16px -12px rgb(0 0 0 / .25); min-width: 0; }
.kpi small { display: block; font-size: var(--fs-0); font-weight: 800; letter-spacing: .3px; text-transform: uppercase; color: var(--ink-3); }
.kpi b { display: block; font-family: var(--font-display); font-size: clamp(18px, 5vw, 24px); font-weight: 800; letter-spacing: -.5px; margin-top: 3px; overflow-wrap: anywhere; }
.kpi span { display: block; font-size: var(--fs-0); color: var(--ink-2); margin-top: 2px; }
.kpi.good b { color: var(--good); } .kpi.risk b { color: var(--risk); }






 






 







 

 

  








  






 





 



  

.field textarea { resize: vertical; min-height: 64px; }

/* ---- 9. conduct centre ---- */
.conduct-list .li { align-items: flex-start; }
.conduct-rule b { font-size: var(--fs-2); line-height: 1.3; }
.conduct-rule .small { line-height: 1.5; margin-top: 4px; }

/* ---- 10. wide screens: enterprise shell with a side rail ---- */
@media (min-width: 1024px) {
  body { padding-bottom: 40px; background: var(--canvas); }
  .frame { max-width: 1240px; padding-left: 112px; box-shadow: none !important; }
  .topbar { border-radius: 0 0 var(--r-lg) var(--r-lg); padding-left: 20px; padding-right: 16px; }
  
  .tabbar { left: max(16px, calc(50vw - 620px + 12px)); top: 50%; bottom: auto; transform: translateY(-50%) translateZ(0); width: 88px; height: auto; flex-direction: column; padding: 8px; border-radius: 26px; }
  html[data-bar-min] .tabbar { transform: translateY(-50%) translateZ(0); }
  .tabbar .tabs { flex-direction: column; gap: 4px; }
  .tabbar .tab { height: 68px; flex: none; font-size: 11px; border-radius: 18px; }
  .tabbar .tab .icon { font-size: 24px; }
  .scroll-edge { display: none; }
  .page { padding: 12px 28px 40px; max-width: 1128px; }
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  #svc-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; align-items: start; }
  .svc.open { grid-column: 1 / -1; }
  #plist { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; align-items: start; }
  .hero-cat { padding: 18px 0 8px; } .hero-cat p { font-size: var(--fs-2); max-width: 760px; }
  .sheet { inset: 0; margin: auto; width: min(760px, calc(100vw - 64px)); max-width: none; max-height: min(88dvh, 920px); height: fit-content; border-radius: 22px; }
  .sheet[data-expanded] { inset: 0; margin: auto; width: min(980px, calc(100vw - 64px)); max-width: none; height: min(92dvh, 1000px); max-height: none; border-radius: 22px; }
  .sheet .sheet-in, .sheet[data-expanded] .sheet-in { max-height: min(92dvh, 1000px); padding-left: 28px; padding-right: 28px; }
  .sheet .sheet-head { margin: 0 -28px 10px; padding-left: 28px; padding-right: 28px; }
  .sheet:not([open]) { translate: 0 24px; opacity: 0; }
  @starting-style { .sheet[open] { translate: 0 24px; opacity: 0; } }
  .sheet { transition: translate 260ms cubic-bezier(.2, .8, .2, 1), opacity 200ms, display 260ms allow-discrete, overlay 260ms allow-discrete; }
  .sheet .hdl { display: none; }
  
  .toasts { bottom: 28px; }
  
}
@media (min-width: 1440px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 720px) and (max-width: 1023.98px) {
  .frame { max-width: 720px; }
  .tabbar { width: min(560px, 100vw - 24px); }
  .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sheet { max-width: 640px; } .sheet[data-expanded] { max-width: 720px; }
}
@media print { .tabbar, .topbar, .scroll-edge, .toasts, .ambient { display: none !important; } }

/* ---- 11. audit fixes (round 2) ---- */
.sheet .sheet-in:focus, .sheet .sheet-in:focus-visible { outline: none; }
.kpi b span { display: inline; font-size: inherit; color: inherit; margin: 0; }
.kpi > span { display: block; }
.crm .bars .n, .crm .bars .brow .n { min-width: 72px; white-space: nowrap; text-align: right; }

 
.land-row + .land-row .field > label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.land-row + .land-row { padding-top: 10px; }
.land-row + .land-row .lr-del { margin-top: 0; }
.land-row .field { margin-bottom: 8px; }
.land-row .field input, .land-row .field select { min-height: 42px; padding-top: 8px; padding-bottom: 8px; }
.land-row .lr-del { height: 42px; }
.crm .bars .brow .k { width: 96px; }
@media (min-width: 1024px) {
  .svc.open .grid2 { grid-template-columns: repeat(2, minmax(0, 360px)); }
  
}


/* ---- 12. QA polish (V2.3.1): 44 × 44 touch targets, link affordance, bottom-bar clearance ----
   Small controls keep their visual size; an invisible ::before "hit-slop" grows the tappable
   box to 44 × 44 around the centre. Pseudo-elements hit-test as their owner, but they are
   clipped by the owner's own overflow — so .chip / .btn.sm / .btn.xs / .iconbtn / .mini drop
   overflow:hidden (nothing inside them ever paints outside the rounded box; the audit checks it). */
:root { --tap: 44px; --slop: min(0px, calc(50% - var(--tap) / 2)); }
:is(.chip, .btn.sm, .btn.xs, .iconbtn):not(.glass) { overflow: visible; }
:is(.chip, .btn.sm, .btn.xs, .iconbtn, .seg button, .link, .topbar .brand, .working summary, .pill[data-act], .cite[data-act]):not(.glass) { position: relative; }
:is(.chip, .btn.sm, .btn.xs, .iconbtn, .seg button, .link, .topbar .brand, .working summary, .pill[data-act], .cite[data-act]):not(.glass)::before {
  content: ""; position: absolute; top: var(--slop); bottom: var(--slop); left: var(--slop); right: var(--slop); border-radius: inherit; background: none; pointer-events: auto;
}
/* segmented buttons: never narrower than a finger (M / F looked like 20 px targets) */
.seg { min-width: min-content; }  /* never squeeze the 44 px buttons out of the track */
.seg button { flex: 1 0 auto; min-width: var(--tap); min-height: 38px; padding-left: 8px; padding-right: 8px; }  /* 38 + the track's 3 px padding = a 44 px segmented control; the hit-slop stays inside the track */
/* form controls cannot carry pseudo-elements — lift the few short ones to 44 px */
.land-row .field input, .land-row .field select { min-height: var(--tap); }
.land-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) var(--tap); }
@media (min-width: 560px) { .land-row { grid-template-columns: minmax(0, 1.2fr) minmax(0, .9fr) minmax(0, 1.3fr) var(--tap); } }
.land-row .lr-del { width: var(--tap); height: var(--tap); }
.cookiebar .more { min-height: var(--tap); }
/* links set inside running text are underlined (WCAG 1.4.1 — colour is not the only cue) */
:is(p, li, dd, td, .small, .tiny, .note, .hint, .hero-cat p) a:not([class]) { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
/* the first-run cookie bar floats above the tab bar: pad the page so the last controls can scroll clear of it */
html[data-cookie-open] body { padding-bottom: calc(var(--cookie-h, 120px) + var(--bar-h) + 40px + var(--safe-b)); }
/* sideways-scrolling tables are keyboard-reachable (tabindex set at runtime) — show where focus is */
.tscroll:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.alpha { gap: 9px; }  /* 36 px letters on a 45 px pitch: each letter's 4 px hit-slop stops short of its neighbour's */
.alpha button { position: relative; }
.alpha button::before { content: ""; position: absolute; top: var(--slop); bottom: var(--slop); left: var(--slop); right: var(--slop); }
   /* room for the chips' 3 px hit-slop inside the scroller's clip */
.ksearch input[type="search"] { min-height: var(--tap); }
.li { min-height: var(--tap); }
.working summary { min-height: var(--tap); }   /* stacked FAQ disclosures sit edge to edge, so hit-slop cannot help — grow the row */
         /* keep the "Open ↗" link's hit-slop inside the clipped map panel */
/* long chips in wrapping rows (builder notes, circle-rate terms, action chips) wrap instead of running off a 360 px screen */
.chips:not(.scroll) > .chip { max-width: 100%; flex: 0 1 auto; white-space: normal; overflow-wrap: anywhere; text-align: left; line-height: 1.3; }
/* checklist rows: the whole row is the target (label wraps the checkbox) */
.chk { margin: 0; padding: 12px 0; }
.chk + .chk { border-top: 1px solid var(--line); }

