/* ==========================================================================
   Tolo design system
   Deep-space canvas, neon gradient light (violet → cyan → magenta), frosted
   glass panes, live particle field and floating website mock-ups.
   ========================================================================== */

@font-face { font-family: "Inter"; src: url("../fonts/Inter-Regular.woff") format("woff"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-Medium.woff") format("woff"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/Inter-SemiBold.woff") format("woff"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-Light.woff") format("woff"); font-weight: 300; font-display: swap; }
@font-face { font-family: "Inter Display"; src: url("../fonts/InterDisplay-SemiBold.woff") format("woff"); font-weight: 600 800; font-display: swap; }

/* ---------- Tokens ---------- */
:root {
  --night: #05060f;
  --night-2: #0b0d1f;
  --text: #f1f2ff;
  --muted: #9ba1c4;
  --ion: #8b7bff;
  --ion-strong: #b3a8ff;
  --ion-ink: #ffffff;
  --signal: #ffb547;
  --ok: #4ee6b0;
  --danger: #ff8a8a;

  --brand-a: #7c5cff;
  --brand-b: #22d3ee;
  --brand-c: #ff5fd2;
  --brand-grad: linear-gradient(110deg, var(--brand-a) 0%, var(--brand-b) 55%, var(--brand-c) 100%);

  --pane: rgba(255, 255, 255, 0.045);
  --pane-strong: rgba(255, 255, 255, 0.08);
  --edge: rgba(255, 255, 255, 0.09);
  --edge-strong: rgba(255, 255, 255, 0.18);
  --grid: rgba(140, 150, 255, 0.07);
  --shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.9);
  --aurora-a: rgba(124, 92, 255, 0.40);
  --aurora-b: rgba(34, 211, 238, 0.22);
  --aurora-c: rgba(255, 95, 210, 0.16);
  --mock-bg: #0f1226;
  --mock-ink: #e9ebff;
  --mock-muted: #7d84ab;
  --mock-line: rgba(255, 255, 255, 0.08);

  --font-body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Inter Display", "Inter", ui-sans-serif, system-ui, sans-serif;

  --step--1: 0.8125rem;
  --step-0: 1.0625rem;
  --step-1: 1.4rem;
  --step-2: 1.875rem;
  --step-3: clamp(2.1rem, 1.4rem + 2.6vw, 3.4rem);
  --step-4: clamp(2.6rem, 1.6rem + 4vw, 4.6rem);
  --step-5: clamp(2.9rem, 1.2rem + 6vw, 6.4rem);

  --radius-pane: 24px;
  --radius-control: 14px;
  --radius-pill: 999px;
  --gutter: clamp(16px, 4vw, 40px);
  --measure: 66ch;
  --header-h: 76px;

  color-scheme: dark;
}

:root[data-theme="light"] {
  --night: #f5f6fc; --night-2: #eceefa; --text: #0d0f2b; --muted: #555b85;
  --ion: #5b45ff; --ion-strong: #4330e6; --ion-ink: #ffffff; --signal: #a86200; --ok: #0f8a5f; --danger: #c0392b;
  --brand-a: #6a4bff; --brand-b: #0ab3d4; --brand-c: #e8399f;
  --pane: rgba(255, 255, 255, 0.7); --pane-strong: rgba(255, 255, 255, 0.92);
  --edge: rgba(13, 15, 43, 0.08); --edge-strong: rgba(13, 15, 43, 0.16); --grid: rgba(91, 69, 255, 0.07);
  --shadow: 0 40px 80px -40px rgba(40, 30, 120, 0.35);
  --aurora-a: rgba(124, 92, 255, 0.22); --aurora-b: rgba(34, 211, 238, 0.18); --aurora-c: rgba(255, 95, 210, 0.12);
  --mock-bg: #ffffff; --mock-ink: #12153a; --mock-muted: #7a80a6; --mock-line: rgba(13, 15, 43, 0.08);
  color-scheme: light;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --night: #f5f6fc; --night-2: #eceefa; --text: #0d0f2b; --muted: #555b85;
    --ion: #5b45ff; --ion-strong: #4330e6; --ion-ink: #ffffff; --signal: #a86200; --ok: #0f8a5f; --danger: #c0392b;
    --brand-a: #6a4bff; --brand-b: #0ab3d4; --brand-c: #e8399f;
    --pane: rgba(255, 255, 255, 0.7); --pane-strong: rgba(255, 255, 255, 0.92);
    --edge: rgba(13, 15, 43, 0.08); --edge-strong: rgba(13, 15, 43, 0.16); --grid: rgba(91, 69, 255, 0.07);
    --shadow: 0 40px 80px -40px rgba(40, 30, 120, 0.35);
    --aurora-a: rgba(124, 92, 255, 0.22); --aurora-b: rgba(34, 211, 238, 0.18); --aurora-c: rgba(255, 95, 210, 0.12);
    --mock-bg: #ffffff; --mock-ink: #12153a; --mock-muted: #7a80a6; --mock-line: rgba(13, 15, 43, 0.08);
    color-scheme: light;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--text);
  background-color: var(--night);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Fine grid + drifting aurora, fixed behind everything */
body::before, body::after { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1; }
body::before {
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 20%, transparent 80%);
}
body::after {
  background:
    radial-gradient(45% 40% at 75% 5%, var(--aurora-a), transparent 70%),
    radial-gradient(35% 35% at 15% 20%, var(--aurora-b), transparent 70%),
    radial-gradient(35% 35% at 85% 70%, var(--aurora-c), transparent 70%);
  filter: blur(20px);
  animation: aurora 28s ease-in-out infinite alternate;
}
@keyframes aurora { to { transform: translate3d(-4%, 3%, 0) scale(1.08); } }

img, svg { display: block; max-width: 100%; }
a { color: var(--ion-strong); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--text); }
p { margin: 0 0 1em; max-width: var(--measure); }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.05; margin: 0 0 0.5em; letter-spacing: -0.03em; font-weight: 600; }
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); letter-spacing: -0.015em; }
small, .small { font-size: var(--step--1); }
.muted { color: var(--muted); }
.lede { font-size: var(--step-1); line-height: 1.45; color: var(--muted); max-width: 46ch; }

:focus-visible { outline: 2px solid var(--brand-b); outline-offset: 3px; border-radius: 6px; }
[tabindex="-1"]:focus, h1:focus { outline: none; }
::selection { background: var(--brand-a); color: #fff; }

.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--ion); color: var(--ion-ink); padding: 8px 14px; border-radius: 8px; }
.skip-link:focus { left: 8px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: min(1240px, 100% - 2 * var(--gutter)); margin-inline: auto; }
.stack > * + * { margin-top: var(--stack-gap, 1rem); }

/* ---------- Glass ---------- */
.glass {
  background: var(--pane);
  border: 1px solid var(--edge);
  border-radius: var(--radius-pane);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
}

/* Mouse-following light on cards (set by site.js via --mx/--my) */
.spot { position: relative; isolation: isolate; }
.spot::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: -1;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, -200%), color-mix(in srgb, var(--brand-a) 22%, transparent), transparent 60%);
  opacity: 0; transition: opacity 0.3s ease;
}
.spot:hover::after { opacity: 1; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  display: flex; align-items: center;
  transition: background-color 0.3s ease, border-color 0.3s ease;
  border-bottom: 1px solid transparent;
}
html.scrolled .site-header, .site-header--app {
  background: color-mix(in srgb, var(--night) 72%, transparent);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom-color: var(--edge);
}
.header-inner { display: flex; align-items: center; gap: 20px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; letter-spacing: -0.02em; }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; }
.brand-word { display: inline-flex; flex-direction: column; line-height: 1; }
.brand-word b { font-weight: 700; font-size: 1.3em; letter-spacing: -0.045em; }
.brand-word small { font-family: var(--font-body); font-weight: 500; font-size: 0.5em; letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }
.nav {
  display: flex; align-items: center; gap: 2px; margin-left: auto;
  padding: 5px; border-radius: var(--radius-pill);
  background: var(--pane); border: 1px solid var(--edge);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.nav a { color: var(--muted); text-decoration: none; padding: 8px 16px; border-radius: var(--radius-pill); font-size: 0.95rem; font-weight: 500; transition: color 0.2s ease, background-color 0.2s ease; }
.nav a:hover, .nav a.active { color: var(--text); background: var(--pane-strong); }
.nav .nav-cta { display: none; }
.header-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.nav + .header-actions { margin-left: 0; }
.icon-btn.menu-toggle { display: none; }

@media (max-width: 960px) {
  .icon-btn.menu-toggle { display: inline-grid; }
  .header-cta { display: none; }
  .nav {
    position: fixed; inset: var(--header-h) 12px auto 12px;
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 12px; border-radius: var(--radius-pane);
    background: color-mix(in srgb, var(--night-2) 94%, transparent);
    box-shadow: var(--shadow);
    opacity: 0; visibility: hidden; transform: translateY(-8px) scale(0.98);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  }
  .nav a { padding: 14px 16px; font-size: 1.1rem; border-radius: var(--radius-control); }
  .nav .nav-cta { display: flex; margin-top: 8px; color: #fff; }
  html.nav-open .nav { opacity: 1; visibility: visible; transform: none; }
}

/* ---------- Buttons & controls ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px;
  border-radius: var(--radius-control);
  border: 1px solid transparent;
  font: 600 0.95rem/1 var(--font-body);
  text-decoration: none; cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--brand-a); color: #fff; }
.btn--primary:hover { background: color-mix(in srgb, var(--brand-a) 85%, #fff); color: #fff; }
.btn--glow {
  color: #fff; border: 0; border-radius: var(--radius-pill);
  background: var(--brand-grad); background-size: 200% 100%; background-position: 0% 50%;
  box-shadow: 0 10px 40px -10px color-mix(in srgb, var(--brand-a) 80%, transparent), inset 0 1px 0 rgba(255,255,255,.35);
  transition: background-position 0.5s ease, box-shadow 0.3s ease, transform 0.15s ease;
}
.btn--glow:hover { color: #fff; background-position: 100% 50%; box-shadow: 0 14px 50px -10px color-mix(in srgb, var(--brand-b) 80%, transparent), inset 0 1px 0 rgba(255,255,255,.35); }
.btn--glass {
  color: var(--text); border-radius: var(--radius-pill); border-color: var(--edge-strong);
  background: var(--pane); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.btn--glass:hover { color: var(--text); background: var(--pane-strong); border-color: color-mix(in srgb, var(--brand-b) 50%, var(--edge-strong)); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--edge-strong); }
.btn--ghost:hover { background: var(--pane); color: var(--text); }
.btn--danger { background: transparent; color: var(--danger); border-color: color-mix(in srgb, var(--danger) 45%, transparent); }
.btn--sm { min-height: 36px; padding: 0 12px; font-size: 0.875rem; }
.btn--lg { min-height: 56px; padding: 0 28px; font-size: 1.02rem; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.icon-btn {
  display: inline-grid; place-items: center; width: 40px; height: 40px;
  border-radius: var(--radius-pill); border: 1px solid var(--edge);
  background: var(--pane); color: var(--text); cursor: pointer;
}
.icon-btn:hover { background: var(--pane); }
.icon { width: 20px; height: 20px; flex: none; }
.theme-icon-light { display: none; }
:root[data-theme="light"] .theme-icon-light { display: block; }
:root[data-theme="light"] .theme-icon-dark { display: none; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme]) .theme-icon-light { display: block; }
  :root:not([data-theme]) .theme-icon-dark { display: none; }
}

/* ---------- Forms ---------- */
.form { display: grid; gap: 18px; }
.form-row { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.field { display: grid; gap: 6px; }
.field label, .label { font-size: 0.9rem; font-weight: 500; }
.hint { font-size: var(--step--1); color: var(--muted); }
.input, .field input, .field select, .field textarea {
  width: 100%; min-height: 46px; padding: 11px 14px;
  font: 400 1rem/1.4 var(--font-body); color: var(--text);
  background: var(--pane-strong);
  border: 1px solid var(--edge-strong); border-radius: var(--radius-control);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field textarea { min-height: 150px; resize: vertical; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 40px; }
:root[data-theme="light"] .field select option, .field select option { color: #141a40; background: #fff; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--ion); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ion) 30%, transparent);
}
.field input.invalid, .field textarea.invalid, .field select.invalid { border-color: var(--danger); }
.validation-message, .field-error { color: var(--danger); font-size: var(--step--1); }
.validation-errors { margin: 0; padding: 12px 16px 12px 32px; border-radius: var(--radius-control); border: 1px solid color-mix(in srgb, var(--danger) 40%, transparent); color: var(--danger); }
.checkbox { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; }
.checkbox input { width: 18px; height: 18px; accent-color: var(--ion); }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.alert { padding: 14px 16px; border-radius: var(--radius-control); border: 1px solid var(--edge-strong); background: var(--pane); }
.alert--ok { border-color: color-mix(in srgb, var(--ok) 45%, transparent); }
.alert--error { border-color: color-mix(in srgb, var(--danger) 45%, transparent); color: var(--danger); }
.alert--warn { border-color: color-mix(in srgb, var(--signal) 45%, transparent); }

/* ---------- Sections ---------- */
.section { padding: clamp(48px, 7vw, 96px) 0; }
.section--tight { padding: clamp(32px, 5vw, 56px) 0; }
.section-head { display: grid; gap: 12px; margin-bottom: clamp(32px, 5vw, 56px); max-width: 720px; }
.section-head p { color: var(--muted); font-size: 1.1rem; margin: 0; }
.page-head { padding: clamp(48px, 8vw, 96px) 0 clamp(24px, 4vw, 40px); }
.page-head h1 { font-weight: 300; letter-spacing: -0.04em; font-size: var(--step-4); }
.page-head .lede { margin: 0; }
.breadcrumbs { font-size: var(--step--1); color: var(--muted); margin-bottom: 18px; }
.breadcrumbs a { color: var(--muted); }

/* Services as a spec sheet, grouped by what the client needs */
.capabilities { display: grid; gap: clamp(32px, 4vw, 48px); }
.cap-group { display: grid; grid-template-columns: 220px 1fr; gap: 24px; padding-top: 24px; border-top: 1px solid var(--edge); }
.cap-group h3 { font-size: 1rem; font-family: var(--font-body); font-weight: 600; color: var(--muted); letter-spacing: 0; }
.cap-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 32px; }
.cap {
  display: grid; grid-template-columns: 40px 1fr; gap: 14px; align-items: start;
  padding: 14px; margin: -14px; border-radius: 16px;
  color: var(--text); text-decoration: none;
}
.cap:hover { background: var(--pane); color: var(--text); }
.cap-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; border: 1px solid var(--edge-strong); color: var(--ion-strong); }
.cap-title { font-weight: 600; display: block; margin-bottom: 2px; }
.cap-text { color: var(--muted); font-size: 0.95rem; line-height: 1.5; }
@media (max-width: 860px) { .cap-group { grid-template-columns: 1fr; gap: 16px; } .cap-list { grid-template-columns: 1fr; } }

/* Two ways in */
.paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.path { padding: clamp(24px, 4vw, 40px); display: grid; gap: 14px; align-content: start; }
.path h3 { font-size: var(--step-2); font-weight: 300; letter-spacing: -0.03em; }
.path ul { margin: 0 0 8px; padding-left: 20px; color: var(--muted); }
.path ul li + li { margin-top: 4px; }
.path .btn { justify-self: start; }
.path--fix { border-color: color-mix(in srgb, var(--signal) 35%, var(--edge)); }
@media (max-width: 760px) { .paths { grid-template-columns: 1fr; } }

/* Process — a real sequence, so it is numbered */
.process { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; counter-reset: step; }
.process li { position: relative; padding: 28px 20px 0 0; counter-increment: step; }
.process li::before {
  content: counter(step);
  display: grid; place-items: center; width: 34px; height: 34px; margin-bottom: 16px;
  border-radius: 50%; border: 1px solid var(--edge-strong); background: var(--night);
  font-weight: 600; font-size: 0.9rem; font-variant-numeric: tabular-nums; position: relative; z-index: 1;
}
.process li::after { content: ""; position: absolute; top: 45px; left: 34px; right: 0; height: 1px; background: var(--edge-strong); }
.process li:last-child::after { display: none; }
.process h3 { font-size: 1.05rem; font-family: var(--font-body); }
.process p { color: var(--muted); font-size: 0.95rem; }
.process--vertical { grid-template-columns: 1fr; }
.process--vertical li { padding: 0 0 20px 52px; }
.process--vertical li::before { position: absolute; left: 0; top: 0; margin: 0; }
.process--vertical li::after { top: 34px; bottom: 0; left: 17px; right: auto; width: 1px; height: auto; }
.process--vertical h3 { margin-bottom: 2px; padding-top: 5px; }
.process--vertical p { margin: 0; }
@media (max-width: 900px) {
  .process { grid-template-columns: 1fr; }
  .process li { padding: 0 0 24px 52px; }
  .process li::before { position: absolute; left: 0; top: 0; margin: 0; }
  .process li::after { top: 34px; bottom: 0; left: 17px; right: auto; width: 1px; height: auto; }
}

.stack-chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--radius-pill); border: 1px solid var(--edge-strong); font-size: 0.875rem; color: var(--text); background: var(--pane); }

.principles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.principles h3 { font-size: 1.1rem; font-family: var(--font-body); }
.principles p { color: var(--muted); margin: 0; }
@media (max-width: 860px) { .principles { grid-template-columns: 1fr; } }

.cta-band { padding: clamp(32px, 5vw, 56px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.cta-band h2 { margin: 0; font-weight: 300; letter-spacing: -0.035em; max-width: 18ch; }

/* Service detail */
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.checklist { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.checklist li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: start; }
.checklist .icon { color: var(--ok); width: 20px; height: 20px; margin-top: 3px; }
.aside-pane { padding: 28px; display: grid; gap: 18px; position: sticky; top: calc(var(--header-h) + 24px); }
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; } .aside-pane { position: static; } }

/* Contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.form-pane { padding: clamp(22px, 4vw, 40px); }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }

/* Prose pages */
.prose { max-width: 72ch; }
.prose h2 { font-size: var(--step-2); margin-top: 1.6em; }
.prose ul { padding-left: 1.2em; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--edge); padding: 48px 0 32px; margin-top: 40px; color: var(--muted); font-size: 0.95rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; }
.footer-grid h2 { font-family: var(--font-body); font-size: 0.95rem; color: var(--text); margin-bottom: 12px; letter-spacing: 0; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.footer-grid a { color: var(--muted); text-decoration: none; }
.footer-grid a:hover { color: var(--text); }
.footer-base { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--edge); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: var(--step--1); }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* ---------- Auth ---------- */
.auth-wrap { min-height: calc(100vh - var(--header-h) - 200px); display: grid; place-items: center; padding: 48px 0; }
.auth-pane { width: min(460px, 100%); padding: clamp(24px, 5vw, 40px); }
.auth-pane h1 { font-size: var(--step-3); font-weight: 300; letter-spacing: -0.035em; }
.auth-switch { margin-top: 20px; text-align: center; color: var(--muted); font-size: 0.95rem; }

/* ---------- Portal ---------- */
.portal { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; padding: 32px 0 64px; align-items: start; }
.portal-nav { position: sticky; top: calc(var(--header-h) + 24px); padding: 12px; display: grid; gap: 2px; }
.portal-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-control); color: var(--muted); text-decoration: none; font-weight: 500; font-size: 0.95rem; }
.portal-nav a:hover { color: var(--text); background: var(--pane); }
.portal-nav a.active { color: var(--text); background: var(--pane-strong); }
.portal-nav .nav-sep { height: 1px; background: var(--edge); margin: 8px 4px; }
.portal-nav form { margin: 0; }
.portal-nav button.linklike { all: unset; box-sizing: border-box; display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: var(--radius-control); color: var(--muted); cursor: pointer; font-weight: 500; font-size: 0.95rem; }
.portal-nav button.linklike:hover { color: var(--text); background: var(--pane); }
.portal-nav button.linklike:focus-visible { outline: 2px solid var(--ion); }
.portal-main { display: grid; gap: 24px; min-width: 0; }
.portal-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px; }
.portal-head h1 { font-size: var(--step-3); font-weight: 300; letter-spacing: -0.035em; margin: 0 0 6px; }
@media (max-width: 900px) {
  .portal { grid-template-columns: 1fr; gap: 16px; }
  .portal-nav { position: static; display: flex; overflow-x: auto; padding: 6px; }
  .portal-nav a, .portal-nav button.linklike { white-space: nowrap; width: auto; }
  .portal-nav .nav-sep { display: none; }
}

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; }
.stat { padding: 20px; }
.stat-value { font-family: var(--font-display); font-weight: 300; font-size: var(--step-3); letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--muted); font-size: 0.9rem; margin-top: 8px; }

.panel { padding: clamp(18px, 3vw, 28px); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-head h2 { font-size: 1.15rem; font-family: var(--font-body); margin: 0; letter-spacing: 0; }

.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.table th { text-align: left; font-weight: 500; color: var(--muted); font-size: var(--step--1); padding: 0 12px 10px; border-bottom: 1px solid var(--edge); }
.table td { padding: 14px 12px; border-bottom: 1px solid var(--edge); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table a { color: var(--text); font-weight: 500; text-decoration: none; }
.table a:hover { color: var(--ion-strong); }
.num { text-align: right; font-variant-numeric: tabular-nums; }

.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--radius-pill); font-size: 0.8rem; font-weight: 500; border: 1px solid var(--edge-strong); white-space: nowrap; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--info { color: var(--ion-strong); }
.badge--live { color: var(--signal); }
.badge--ok { color: var(--ok); }
.badge--warn { color: var(--signal); }
.badge--muted { color: var(--muted); }

.empty { padding: 32px; text-align: center; color: var(--muted); display: grid; gap: 14px; justify-items: center; }

.project-layout { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
@media (max-width: 1100px) { .project-layout { grid-template-columns: 1fr; } }
.meta-list { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; font-size: 0.95rem; }
.meta-list dt { color: var(--muted); }
.meta-list dd { margin: 0; overflow-wrap: anywhere; }
.pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 0.95rem; }

.thread { display: grid; gap: 12px; max-height: 520px; overflow-y: auto; padding-right: 4px; }
.msg { padding: 12px 14px; border-radius: 16px; background: var(--pane); border: 1px solid var(--edge); max-width: 85%; }
.msg--mine { justify-self: end; background: color-mix(in srgb, var(--ion) 16%, transparent); border-color: color-mix(in srgb, var(--ion) 30%, transparent); }
.msg-meta { font-size: var(--step--1); color: var(--muted); margin-bottom: 4px; }
.msg-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.composer { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin-top: 16px; align-items: end; }
.composer textarea { min-height: 52px; max-height: 200px; }

.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.timeline li { display: grid; grid-template-columns: 12px 1fr; gap: 12px; font-size: 0.95rem; }
.timeline li::before { content: ""; width: 8px; height: 8px; margin-top: 8px; border-radius: 50%; background: var(--ion); }
.timeline time { display: block; color: var(--muted); font-size: var(--step--1); }

.type-picker { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.type-option { position: relative; }
.type-option input { position: absolute; opacity: 0; }
.type-option label { display: grid; gap: 4px; padding: 14px; border-radius: 14px; border: 1px solid var(--edge-strong); background: var(--pane); cursor: pointer; font-weight: 500; font-size: 0.95rem; }
.type-option input:checked + label { border-color: var(--ion); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ion) 25%, transparent); }
.type-option input:focus-visible + label { outline: 2px solid var(--ion); outline-offset: 2px; }

.lines-editor { display: grid; gap: 10px; }
.line-row { display: grid; grid-template-columns: minmax(0, 3fr) 90px 140px 40px; gap: 10px; align-items: center; }
@media (max-width: 700px) { .line-row { grid-template-columns: 1fr 1fr; } }

.invoice-doc { padding: clamp(24px, 4vw, 44px); }
.invoice-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
.invoice-total { font-family: var(--font-display); font-size: var(--step-3); font-weight: 300; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }

.spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Blazor reconnect + error UI */
#blazor-error-ui { display: none; position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); z-index: 1000; padding: 12px 18px; border-radius: 12px; background: var(--night-2); border: 1px solid var(--danger); color: var(--text); box-shadow: var(--shadow); }
#blazor-error-ui .reload { margin-left: 12px; }
#blazor-error-ui .dismiss { margin-left: 12px; cursor: pointer; }

@media print {
  body::before, body::after, .site-header, .site-footer, .portal-nav, .no-print { display: none !important; }
  body { background: #fff; color: #000; }
  .glass { box-shadow: none; border: 0; backdrop-filter: none; background: #fff; }
  .portal { display: block; }
}

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

/* ==========================================================================
   Landing experience (x-*)
   ========================================================================== */
.x-grad {
  background: var(--brand-grad); background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: grad-shift 8s ease-in-out infinite alternate;
}
@keyframes grad-shift { to { background-position: 100% 50%; } }

.x-head { display: grid; gap: 14px; margin-bottom: clamp(36px, 5vw, 64px); max-width: 760px; }
.x-head h2 { margin: 0; font-size: var(--step-4); letter-spacing: -0.045em; line-height: 1; text-wrap: balance; }
.x-head p { margin: 0; color: var(--muted); font-size: 1.15rem; }
.x-center { text-align: center; margin: 32px auto 0; max-width: none; }
.x-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; color: var(--text); }
.x-link .icon { transition: transform 0.2s ease; }
.x-link:hover .icon { transform: translateX(4px); }

/* ---------- Hero ---------- */
.x-hero { position: relative; margin-top: calc(-1 * var(--header-h)); padding: calc(var(--header-h) + clamp(32px, 7vw, 96px)) 0 clamp(48px, 7vw, 96px); overflow: hidden; }
.x-hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: 0.9;
  mask-image: radial-gradient(ellipse 85% 75% at 60% 40%, #000 35%, transparent 85%); }
.x-hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
@media (max-width: 1020px) { .x-hero-grid { grid-template-columns: 1fr; } }

.x-pill {
  display: inline-flex; align-items: center; gap: 10px; margin: 0 0 24px;
  padding: 7px 16px 7px 12px; border-radius: var(--radius-pill);
  background: var(--pane); border: 1px solid var(--edge-strong); font-size: 0.9rem; font-weight: 500;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.x-pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 var(--ok); animation: pulse 2s ease-out infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

.x-title { font-size: var(--step-5); font-weight: 600; letter-spacing: -0.055em; line-height: 0.98; margin: 0 0 28px; }
.x-title-line { display: block; }
.x-rotator { position: relative; display: grid; height: 1.08em; overflow: hidden; align-items: end; }
.x-rotator-word {
  grid-area: 1 / 1; white-space: nowrap; justify-self: start; line-height: 1.05;
  background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  opacity: 0; transform: translateY(70%); filter: blur(6px);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(.2,.8,.2,1), filter 0.6s ease;
  padding-bottom: 0.08em;
}
.x-rotator-word.is-on { opacity: 1; transform: none; filter: none; }
.x-rotator-word.is-out { opacity: 0; transform: translateY(-70%); filter: blur(6px); }
.x-lede { font-size: clamp(1.1rem, 1rem + 0.5vw, 1.3rem); line-height: 1.55; color: var(--muted); max-width: 40ch; margin-bottom: 36px; }
.x-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.x-trust { list-style: none; padding: 0; margin: 36px 0 0; display: flex; flex-wrap: wrap; gap: 10px 24px; color: var(--muted); font-size: 0.95rem; }
.x-trust li { display: inline-flex; align-items: center; gap: 8px; }
.x-trust .icon { width: 18px; height: 18px; color: var(--ok); }

/* Floating site stack */
.x-stage { position: relative; height: clamp(380px, 42vw, 560px); perspective: 1600px; }
.x-stage > * { transition: transform 0.4s cubic-bezier(.2,.8,.2,1); }
.x-float { position: absolute; transform-style: preserve-3d; }
.x-float--main { inset: 10% 6% auto 8%; z-index: 2; transform: rotateY(-14deg) rotateX(6deg) translateZ(0); animation: bob 9s ease-in-out infinite; }
.x-float--back { inset: 0 auto auto 34%; width: 70%; z-index: 1; opacity: 0.85; transform: rotateY(-14deg) rotateX(6deg) translateZ(-120px); animation: bob 11s ease-in-out -3s infinite; }
.x-float--front { inset: auto auto 2% 0; width: 52%; z-index: 3; transform: rotateY(-14deg) rotateX(6deg) translateZ(80px); animation: bob 8s ease-in-out -5s infinite; }
@keyframes bob { 50% { translate: 0 -12px; } }
.x-chip {
  position: absolute; z-index: 4; display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: var(--radius-pill); font-size: 0.85rem; font-weight: 600;
  background: color-mix(in srgb, var(--night-2) 70%, transparent); border: 1px solid var(--edge-strong);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); box-shadow: var(--shadow);
  animation: bob 7s ease-in-out infinite;
}
.x-chip .icon { width: 18px; height: 18px; }
.x-chip--a { top: 4%; left: 2%; color: var(--ok); }
.x-chip--b { right: 0; bottom: 18%; color: var(--brand-b); animation-delay: -3s; }
@media (max-width: 1020px) {
  .x-stage { height: clamp(300px, 80vw, 480px); margin-top: 8px; }
}
@media (max-width: 560px) {
  .x-chip--a { top: -2%; }
  .x-float--front { width: 64%; }
}

/* ---------- Mini website mock-ups ---------- */
.mock {
  --u: 1; font-family: var(--font-body); color: var(--mock-ink);
  background: var(--mock-bg); border-radius: 16px; overflow: hidden;
  border: 1px solid var(--edge-strong);
  box-shadow: 0 50px 100px -30px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.03), 0 0 80px -20px color-mix(in srgb, var(--brand-a) 40%, transparent);
  font-size: 11px; line-height: 1.3; user-select: none;
}
.mock-bar { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--mock-line); background: color-mix(in srgb, var(--mock-bg) 92%, var(--mock-ink)); }
.mock-dots { display: inline-flex; gap: 5px; }
.mock-dots i { width: 8px; height: 8px; border-radius: 50%; background: #ff5f57; }
.mock-dots i:nth-child(2) { background: #febc2e; }
.mock-dots i:nth-child(3) { background: #28c840; }
.mock-url { flex: 1; text-align: center; color: var(--mock-muted); font-size: 10px; padding: 3px 10px; border-radius: 6px; background: var(--mock-line); max-width: 220px; margin-inline: auto; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.mock-body { padding: 12px; }
.m-nav { display: flex; align-items: center; gap: 12px; color: var(--mock-muted); margin-bottom: 10px; }
.m-nav b { color: var(--mock-ink); letter-spacing: .08em; margin-right: auto; }
.m-nav em { font-style: normal; color: var(--mock-ink); padding: 3px 8px; border-radius: 999px; border: 1px solid var(--mock-line); }
.m-btn { display: inline-block; margin-top: 8px; padding: 5px 10px; border-radius: 999px; background: var(--brand-grad); color: #fff; font-weight: 600; font-size: 10px; }
.m-hero { border-radius: 10px; padding: 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.m-hero small { display: block; color: var(--mock-muted); font-size: 9px; text-transform: none; margin-bottom: 3px; }
.m-hero strong { display: block; font-size: 17px; line-height: 1.1; letter-spacing: -0.02em; max-width: 14ch; }
.m-hero--shop { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-a) 25%, var(--mock-bg)), color-mix(in srgb, var(--brand-b) 18%, var(--mock-bg))); }
.m-orb { width: 70px; height: 70px; border-radius: 50%; flex: none; background: radial-gradient(circle at 35% 30%, #fff, var(--brand-b) 35%, var(--brand-a) 70%); box-shadow: 0 0 40px color-mix(in srgb, var(--brand-b) 60%, transparent); }
.m-products { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.m-product { display: grid; gap: 3px; }
.m-product span { color: var(--mock-muted); }
.m-img { aspect-ratio: 1; border-radius: 8px; background: radial-gradient(circle at 50% 35%, hsl(var(--h) 90% 75%), hsl(var(--h) 70% 45%) 45%, hsl(var(--h) 50% 20%)); }
.m-app { display: grid; grid-template-columns: 70px 1fr; gap: 10px; min-height: 180px; }
.m-side { display: grid; align-content: start; gap: 6px; color: var(--mock-muted); border-right: 1px solid var(--mock-line); padding-right: 8px; }
.m-side b { color: var(--mock-ink); margin-bottom: 6px; }
.m-side .on { color: var(--mock-ink); background: var(--mock-line); border-radius: 6px; padding: 2px 6px; margin-left: -6px; }
.m-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 8px; }
.m-tiles div { border: 1px solid var(--mock-line); border-radius: 8px; padding: 6px; display: grid; }
.m-tiles small { color: var(--mock-muted); font-size: 9px; }
.m-tiles b { font-size: 13px; }
.m-tiles em { font-style: normal; color: var(--ok); font-size: 9px; }
.m-chart { width: 100%; height: 70px; }
.m-line { stroke-dasharray: 600; stroke-dashoffset: 600; animation: draw 2.4s 0.4s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.m-rows { display: grid; gap: 5px; margin-top: 8px; }
.m-rows span { height: 7px; border-radius: 4px; background: var(--mock-line); }
.m-rows span:nth-child(2) { width: 80%; }
.m-rows span:nth-child(3) { width: 60%; }
.m-nav--light b { letter-spacing: 0; font-size: 13px; }
.m-hero--food { display: block; min-height: 120px; color: #fff;
  background: radial-gradient(circle at 80% 30%, #ffb547 0, #e8590c 22%, transparent 45%), linear-gradient(160deg, #3a1d14, #12080a); }
.m-hero--food small { color: #ffd6a8; }
.m-hero--food strong { font-size: 22px; }
.m-menu { display: grid; gap: 6px; }
.m-menu div { display: flex; justify-content: space-between; padding: 6px 2px; border-bottom: 1px dashed var(--mock-line); }
.m-menu span { color: var(--mock-muted); }
.m-booking { display: grid; grid-template-columns: 1.3fr 1fr; gap: 10px; }
.m-cal small, .m-slots small { display: block; color: var(--mock-muted); margin-bottom: 6px; }
.m-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.m-days i { font-style: normal; text-align: center; padding: 4px 0; border-radius: 6px; font-size: 10px; }
.m-days i.off { color: var(--mock-muted); opacity: .5; }
.m-days i.sel { background: var(--brand-grad); color: #fff; font-weight: 700; }
.m-slots { display: grid; gap: 5px; align-content: start; }
.m-slots span { padding: 5px; border-radius: 6px; border: 1px solid var(--mock-line); text-align: center; }
.m-slots span.sel { border-color: var(--brand-b); color: var(--brand-b); font-weight: 700; }
.m-slots .m-btn { text-align: center; }

/* ---------- Marquee ---------- */
.x-marquee { border-block: 1px solid var(--edge); padding: 20px 0; overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.x-marquee-track { display: flex; width: max-content; animation: marquee 40s linear infinite; }
.x-marquee:hover .x-marquee-track { animation-play-state: paused; }
.x-marquee ul { display: flex; gap: 14px; list-style: none; margin: 0; padding: 0 7px; }
.x-marquee li { white-space: nowrap; padding: 8px 18px; border-radius: var(--radius-pill); border: 1px solid var(--edge-strong); background: var(--pane); font-weight: 500; color: var(--text); }
.x-marquee li:nth-child(3n+1)::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 10px; border-radius: 50%; background: var(--brand-b); vertical-align: middle; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Bento ---------- */
.bento { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: minmax(190px, auto); gap: 16px; }
.tile {
  display: flex; flex-direction: column; gap: 10px; padding: 26px; overflow: hidden;
  border-radius: var(--radius-pane); border: 1px solid var(--edge);
  background: linear-gradient(160deg, var(--pane-strong), var(--pane));
  color: var(--text); text-decoration: none;
  transition: border-color 0.3s ease, transform 0.3s ease;
}
.tile:hover { color: var(--text); border-color: color-mix(in srgb, var(--brand-a) 50%, var(--edge)); transform: translateY(-3px); }
.tile h3 { margin: 6px 0 0; font-size: 1.25rem; }
.tile p { margin: 0; color: var(--muted); font-size: 0.97rem; }
.tile-icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px; color: #fff;
  background: var(--brand-grad); box-shadow: 0 10px 30px -10px color-mix(in srgb, var(--brand-a) 70%, transparent); }
.tile-icon .icon { width: 22px; height: 22px; }
.tile--xl { grid-column: span 2; grid-row: span 2; }
.tile--wide { grid-column: span 2; }
.tile-art { margin-top: auto; margin-right: -60px; margin-bottom: -60px; transform: rotate(-4deg) translateY(10px); transition: transform 0.5s cubic-bezier(.2,.8,.2,1); }
.tile:hover .tile-art { transform: rotate(-2deg) translateY(0); }
.tile-phones { display: flex; gap: 12px; margin-top: auto; margin-bottom: -50px; justify-content: flex-end; }
.tile-phones span { width: 90px; height: 150px; border-radius: 22px; border: 1px solid var(--edge-strong);
  background: linear-gradient(170deg, color-mix(in srgb, var(--brand-a) 40%, var(--mock-bg)), var(--mock-bg) 60%); box-shadow: var(--shadow); }
.tile-phones span:last-child { transform: translateY(-20px); background: linear-gradient(170deg, color-mix(in srgb, var(--brand-b) 40%, var(--mock-bg)), var(--mock-bg) 60%); }
@media (max-width: 1020px) { .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) {
  .bento { grid-template-columns: 1fr; }
  .tile--xl, .tile--wide { grid-column: auto; grid-row: auto; }
}

/* ---------- Showcase tabs ---------- */
.x-tabs { display: grid; gap: 28px; }
.x-tablist { display: flex; flex-wrap: wrap; gap: 8px; padding: 6px; border-radius: var(--radius-pill); background: var(--pane); border: 1px solid var(--edge); justify-self: start; }
.x-tablist button {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: var(--radius-pill);
  border: 0; background: transparent; color: var(--muted); font: 600 0.95rem/1 var(--font-body); cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}
.x-tablist button .icon { width: 18px; height: 18px; }
.x-tablist button:hover { color: var(--text); }
.x-tablist button[aria-selected="true"] { color: #fff; background: var(--brand-grad); box-shadow: 0 8px 24px -8px color-mix(in srgb, var(--brand-a) 70%, transparent); }
.x-panel { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 64px); align-items: center;
  padding: clamp(24px, 4vw, 48px); border-radius: 28px; border: 1px solid var(--edge); background: linear-gradient(160deg, var(--pane-strong), var(--pane)); }
.x-panel[hidden] { display: none; }
.x-panel:not([hidden]) { animation: panel-in 0.5s cubic-bezier(.2,.8,.2,1); }
@keyframes panel-in { from { opacity: 0; transform: translateY(12px); } }
.x-panel h3 { font-size: var(--step-2); letter-spacing: -0.03em; }
.x-panel p { color: var(--muted); }
.x-panel-art .mock { font-size: 13px; transform: perspective(1400px) rotateY(-8deg); }
.x-panel-art .mock .m-hero strong { font-size: 22px; }
@media (max-width: 900px) { .x-panel { grid-template-columns: 1fr; } .x-tablist { justify-self: stretch; border-radius: 20px; } }

.x-checks { list-style: none; padding: 0; margin: 0 0 26px; display: grid; gap: 10px; }
.x-checks li { display: flex; gap: 10px; align-items: flex-start; }
.x-checks .icon { width: 20px; height: 20px; color: var(--brand-b); margin-top: 2px; }

/* ---------- Steps ---------- */
.x-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; counter-reset: step; position: relative; }
.x-steps::before { content: ""; position: absolute; top: 27px; left: 28px; right: 28px; height: 2px; background: var(--edge-strong); }
.x-steps::after { content: ""; position: absolute; top: 27px; left: 28px; right: 28px; height: 2px; background: var(--brand-grad);
  transform-origin: left; transform: scaleX(var(--progress, 0)); transition: transform 1.6s cubic-bezier(.2,.8,.2,1); }
.x-steps.is-in { --progress: 1; }
.x-steps li { counter-increment: step; position: relative; z-index: 1; }
.x-steps li::before {
  content: "0" counter(step); display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 22px;
  border-radius: 18px; background: var(--night-2); border: 1px solid var(--edge-strong);
  font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; color: var(--text);
  box-shadow: 0 0 0 6px var(--night);
}
.x-steps li:hover::before { background: var(--brand-grad); color: #fff; border-color: transparent; }
.x-steps h3 { font-size: 1.3rem; }
.x-steps p { color: var(--muted); margin: 0; }
@media (max-width: 900px) {
  .x-steps { grid-template-columns: 1fr; gap: 28px; }
  .x-steps::before, .x-steps::after { top: 28px; bottom: 28px; left: 27px; right: auto; width: 2px; height: auto; }
  .x-steps::after { transform-origin: top; transform: scaleY(var(--progress, 0)); }
  .x-steps li { padding-left: 80px; }
  .x-steps li::before { position: absolute; left: 0; top: 0; }
}

/* ---------- Stats ---------- */
.x-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.x-stat { padding: 28px; display: grid; gap: 6px; }
.x-stat b { font-family: var(--font-display); font-size: clamp(2.6rem, 2rem + 2vw, 3.6rem); font-weight: 600; letter-spacing: -0.05em; line-height: 1;
  background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.x-stat span { color: var(--muted); }
@media (max-width: 900px) { .x-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Packages ---------- */
.x-packages { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; align-items: stretch; }
.x-pkg { padding: 32px; display: flex; flex-direction: column; }
.x-pkg h3 { font-size: var(--step-2); margin-bottom: 6px; }
.x-pkg-for { color: var(--muted); margin-bottom: 24px; }
.x-pkg .x-checks { flex: 1; }
.x-pkg .btn { align-self: flex-start; }
.x-pkg--hot { border: 1px solid transparent; background:
  linear-gradient(var(--night-2), var(--night-2)) padding-box, var(--brand-grad) border-box; }
.x-pkg-tag { position: absolute; top: 20px; right: 20px; padding: 4px 12px; border-radius: var(--radius-pill); font-size: 0.8rem; font-weight: 600; color: #fff; background: var(--brand-grad); }
@media (max-width: 960px) { .x-packages { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.x-faq-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.x-faq { display: grid; gap: 12px; }
.x-faq details { padding: 0; border-radius: 18px; }
.x-faq summary { list-style: none; cursor: pointer; padding: 20px 56px 20px 24px; font-weight: 600; font-size: 1.05rem; position: relative; }
.x-faq summary::-webkit-details-marker { display: none; }
.x-faq summary::after { content: "+"; position: absolute; right: 22px; top: 50%; translate: 0 -50%; width: 28px; height: 28px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--edge-strong); font-weight: 400; transition: transform 0.3s ease, background-color 0.3s ease; }
.x-faq details[open] summary::after { transform: rotate(45deg); background: var(--brand-grad); color: #fff; border-color: transparent; }
.x-faq details p { padding: 0 24px 22px; margin: 0; color: var(--muted); }
@media (max-width: 860px) { .x-faq-grid { grid-template-columns: 1fr; } }

/* ---------- CTA ---------- */
.x-cta {
  text-align: center; padding: clamp(48px, 8vw, 96px) clamp(24px, 5vw, 64px); border-radius: 36px; overflow: hidden;
  background:
    radial-gradient(60% 80% at 50% 0%, color-mix(in srgb, var(--brand-a) 35%, transparent), transparent 70%),
    radial-gradient(40% 60% at 100% 100%, color-mix(in srgb, var(--brand-c) 22%, transparent), transparent 70%),
    linear-gradient(var(--night-2), var(--night-2)) padding-box,
    var(--brand-grad) border-box;
  border: 1px solid transparent;
}
.x-cta h2 { font-size: var(--step-4); letter-spacing: -0.045em; line-height: 1; margin-bottom: 18px; }
.x-cta p { margin: 0 auto 32px; color: var(--muted); font-size: 1.15rem; max-width: 52ch; }

/* ---------- Sub-page heads ---------- */
.page-head { padding: clamp(56px, 9vw, 120px) 0 clamp(24px, 4vw, 48px); }
.page-head h1 { font-size: var(--step-5); font-weight: 600; letter-spacing: -0.055em; line-height: 1; }
.page-head .lede { margin: 0; }

/* ---------- Scroll reveal (enabled by site.js only when motion is allowed) ---------- */
.reveal-on [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 0.8s ease, transform 0.8s cubic-bezier(.2,.8,.2,1); }
.reveal-on [data-reveal].is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .x-marquee-track, .x-float, .x-chip, .x-grad, body::after { animation: none !important; }
  .reveal-on [data-reveal] { opacity: 1; transform: none; }
}

.bento--even { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: auto; }
.bento--even .tile { min-height: 240px; }
.tile-more { margin-top: auto; padding-top: 10px; font-size: 0.95rem; }
@media (max-width: 1020px) { .bento--even { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .bento--even { grid-template-columns: 1fr; } }
.tile--wide p { max-width: 46ch; }
@media (max-width: 620px) {
  .tile-phones { margin-top: 18px; margin-bottom: -60px; }
  .tile-phones span { width: 72px; height: 120px; }
}

/* Gradient text only paints inside the element box; tight letter-spacing makes the box narrower than
   the last glyph, which clipped its right edge. A little end padding gives the gradient room. */
.x-grad, .x-rotator-word, .x-stat b { padding-right: 0.1em; margin-right: -0.1em; }


/* ---------- Futuristic desktop nav: rotating light edge + gliding glow indicator ---------- */
@property --nav-ang { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.nav-ind { display: none; }
@media (min-width: 961px) {
  .nav {
    position: relative; isolation: isolate;
    padding: 6px; gap: 0;
    background: color-mix(in srgb, var(--night-2) 55%, transparent);
    border: 1px solid transparent;
    box-shadow: 0 10px 40px -16px color-mix(in srgb, var(--brand-a) 55%, transparent), inset 0 1px 0 rgba(255,255,255,.06);
  }
  /* Animated gradient border drawn with a masked conic gradient. */
  .nav::before {
    content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; z-index: -1; pointer-events: none;
    background: conic-gradient(from var(--nav-ang), transparent 0deg, var(--brand-a) 60deg, var(--brand-b) 120deg, transparent 180deg, transparent 220deg, var(--brand-c) 290deg, transparent 360deg), var(--edge-strong);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude;
    animation: nav-spin 7s linear infinite;
  }
  @keyframes nav-spin { to { --nav-ang: 360deg; } }

  .nav a { position: relative; z-index: 1; padding: 9px 20px; letter-spacing: 0.01em; transition: color 0.25s ease; }
  .nav a:hover, .nav a.active { background: transparent; color: var(--text); }
  /* Only the link sitting under the glowing indicator turns white. */
  .nav a.is-lit, .nav a.is-lit:hover { color: #fff; }

  .nav-ind {
    display: block; position: absolute; z-index: 0; top: 6px; bottom: 6px;
    left: var(--ind-x, 0); width: var(--ind-w, 0); opacity: var(--ind-o, 0);
    border-radius: var(--radius-pill);
    background: var(--brand-grad); background-size: 200% 100%;
    box-shadow: 0 0 24px -2px color-mix(in srgb, var(--brand-a) 75%, transparent), 0 0 48px -8px color-mix(in srgb, var(--brand-b) 60%, transparent), inset 0 1px 0 rgba(255,255,255,.35);
    transition: left 0.45s cubic-bezier(.2,.9,.2,1.15), width 0.45s cubic-bezier(.2,.9,.2,1.15), opacity 0.3s ease;
    animation: grad-shift 6s ease-in-out infinite alternate;
  }
}
@media (prefers-reduced-motion: reduce) {
  .nav::before, .nav-ind { animation: none !important; }
}


/* ---------- Shared "living light" treatment for buttons and the showcase tabs ---------- */
/* Rotating light edge (same look as the nav). Uses the --nav-ang property registered above. */
.btn--glass, .btn--glow, .x-tablist { position: relative; isolation: isolate; }
.btn--glass::before, .x-tablist::before, .btn--glow::before {
  content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; z-index: -1; pointer-events: none;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: nav-spin 6s linear infinite;
}
.btn--glass::before, .x-tablist::before {
  background: conic-gradient(from var(--nav-ang), transparent 0deg, var(--brand-a) 60deg, var(--brand-b) 120deg, transparent 180deg, transparent 220deg, var(--brand-c) 290deg, transparent 360deg), var(--edge-strong);
}
.btn--glow::before {
  inset: 0; padding: 1.5px;
  background: conic-gradient(from var(--nav-ang), transparent 0deg, rgba(255,255,255,.95) 40deg, transparent 100deg, transparent 360deg);
}
.btn--glass { border-color: transparent; }
.x-tablist { border-color: transparent; }

/* Glass buttons light up from inside on hover. */
.btn--glass { overflow: hidden; }
.btn--glass > * { position: relative; }
.btn--glass:hover {
  background: color-mix(in srgb, var(--brand-a) 14%, var(--pane-strong));
  box-shadow: 0 0 28px -6px color-mix(in srgb, var(--brand-b) 55%, transparent), inset 0 1px 0 rgba(255,255,255,.08);
}

/* Glow buttons: a light sweep crosses the button on hover. */
.btn--glow { overflow: hidden; }
.btn--glow::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 45%; pointer-events: none; z-index: 1;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.45), transparent);
  transform: skewX(-20deg); transition: left 0.7s ease;
}
.btn--glow:hover::after { left: 120%; }

/* Showcase tabs: gliding glow pill instead of a per-tab background. */
.x-tablist { background: color-mix(in srgb, var(--night-2) 55%, transparent); }
.x-tablist button { position: relative; z-index: 1; }
.x-tablist button[aria-selected="true"] { background: transparent; box-shadow: none; color: var(--text); }
.x-tablist button.is-lit, .x-tablist button.is-lit:hover { color: #fff; }
.glide-ind {
  position: absolute; z-index: 0; top: var(--ind-y, 6px); left: var(--ind-x, 0);
  width: var(--ind-w, 0); height: var(--ind-h, 0); opacity: var(--ind-o, 0);
  border-radius: var(--radius-pill);
  background: var(--brand-grad); background-size: 200% 100%;
  box-shadow: 0 0 24px -2px color-mix(in srgb, var(--brand-a) 75%, transparent), 0 0 48px -8px color-mix(in srgb, var(--brand-b) 60%, transparent), inset 0 1px 0 rgba(255,255,255,.35);
  transition: left 0.45s cubic-bezier(.2,.9,.2,1.15), top 0.45s cubic-bezier(.2,.9,.2,1.15), width 0.45s cubic-bezier(.2,.9,.2,1.15), height 0.3s ease, opacity 0.3s ease;
  animation: grad-shift 6s ease-in-out infinite alternate;
}
/* Without JS the selected tab still shows its own highlight. */
html:not(.js) .x-tablist button[aria-selected="true"] { background: var(--brand-grad); color: #fff; }

@media (prefers-reduced-motion: reduce) {
  .btn--glass::before, .btn--glow::before, .x-tablist::before, .glide-ind { animation: none !important; }
  .btn--glow::after { display: none; }
}

/* Stronger, clearly visible light edge (v2): thicker beam, wider coloured arc, soft outer glow. */
.btn--glass::before, .x-tablist::before {
  inset: -2px; padding: 2px;
  background: conic-gradient(from var(--nav-ang),
      var(--brand-a) 0deg, var(--brand-b) 70deg, transparent 130deg, transparent 200deg,
      var(--brand-c) 260deg, var(--brand-a) 360deg);
  filter: drop-shadow(0 0 6px color-mix(in srgb, var(--brand-b) 70%, transparent));
}
.btn--glow::before {
  inset: 0; padding: 2px;
  background: conic-gradient(from var(--nav-ang), transparent 0deg, #fff 30deg, rgba(255,255,255,.9) 70deg, transparent 120deg, transparent 360deg);
  filter: drop-shadow(0 0 4px rgba(255,255,255,.9));
}
.btn--glass { box-shadow: 0 0 22px -8px color-mix(in srgb, var(--brand-a) 60%, transparent); }
/* Light theme: deeper colours so the beam reads on pale backgrounds. */
:root[data-theme="light"] .btn--glass::before, :root[data-theme="light"] .x-tablist::before {
  background: conic-gradient(from var(--nav-ang), #5b45ff 0deg, #00a8cc 70deg, transparent 130deg, transparent 200deg, #e0168f 260deg, #5b45ff 360deg);
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .btn--glass::before, :root:not([data-theme="dark"]) .x-tablist::before {
    background: conic-gradient(from var(--nav-ang), #5b45ff 0deg, #00a8cc 70deg, transparent 130deg, transparent 200deg, #e0168f 260deg, #5b45ff 360deg);
  }
}
/* The glass button clipped its own outer edge; let the beam sit outside. */
.btn--glass { overflow: visible; }

/* ==========================================================================
   Night / day sections. "tone-alt" sections use the opposite palette of the
   page theme, so the home page alternates night → day → night…
   (theme toggle swaps the order). Colour tokens are re-declared locally, so
   every component inside simply follows.
   ========================================================================== */
:root[data-theme="dark"] .tone-alt, :root:not([data-theme]) .tone-alt {
  --night: #f5f6fc; --night-2: #eceefa; --text: #0d0f2b; --muted: #555b85;
  --ion: #5b45ff; --ion-strong: #4330e6; --signal: #a86200; --ok: #0f8a5f; --danger: #c0392b;
  --brand-a: #6a4bff; --brand-b: #0ab3d4; --brand-c: #e8399f;
  --pane: rgba(255, 255, 255, 0.7); --pane-strong: rgba(255, 255, 255, 0.92);
  --edge: rgba(13, 15, 43, 0.08); --edge-strong: rgba(13, 15, 43, 0.16); --grid: rgba(91, 69, 255, 0.07);
  --shadow: 0 40px 80px -40px rgba(40, 30, 120, 0.35);
  --mock-bg: #ffffff; --mock-ink: #12153a; --mock-muted: #7a80a6; --mock-line: rgba(13, 15, 43, 0.08);
  --tone-bg: #f5f6fc; --tone-glow-a: rgba(124, 92, 255, 0.16); --tone-glow-b: rgba(34, 211, 238, 0.14);
  color-scheme: light;
}
:root[data-theme="light"] .tone-alt {
  --night: #05060f; --night-2: #0b0d1f; --text: #f1f2ff; --muted: #9ba1c4;
  --ion: #8b7bff; --ion-strong: #b3a8ff; --signal: #ffb547; --ok: #4ee6b0; --danger: #ff8a8a;
  --brand-a: #7c5cff; --brand-b: #22d3ee; --brand-c: #ff5fd2;
  --pane: rgba(255, 255, 255, 0.045); --pane-strong: rgba(255, 255, 255, 0.08);
  --edge: rgba(255, 255, 255, 0.09); --edge-strong: rgba(255, 255, 255, 0.18); --grid: rgba(140, 150, 255, 0.07);
  --shadow: 0 40px 100px -40px rgba(0, 0, 0, 0.9);
  --mock-bg: #0f1226; --mock-ink: #e9ebff; --mock-muted: #7d84ab; --mock-line: rgba(255, 255, 255, 0.08);
  --tone-bg: #05060f; --tone-glow-a: rgba(124, 92, 255, 0.35); --tone-glow-b: rgba(34, 211, 238, 0.18);
  color-scheme: dark;
}
.tone-alt {
  --brand-grad: linear-gradient(110deg, var(--brand-a) 0%, var(--brand-b) 55%, var(--brand-c) 100%);
  position: relative; isolation: isolate; color: var(--text);
  margin-inline: clamp(8px, 1.4vw, 20px);
  border-radius: clamp(28px, 4vw, 48px);
  background:
    radial-gradient(60% 50% at 85% 0%, var(--tone-glow-a), transparent 70%),
    radial-gradient(50% 45% at 0% 100%, var(--tone-glow-b), transparent 70%),
    var(--tone-bg);
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}
/* Fine grid inside the alternate sections too. */
.tone-alt::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 0%, #000 20%, transparent 85%);
}
.tone-alt + .tone-alt { margin-top: 0; }
/* Breathing room between bands. */
.tone-alt { margin-block: clamp(12px, 2vw, 24px); }

/* ---------- About page ---------- */
.about-hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.about-hero h1 { font-size: var(--step-5); letter-spacing: -0.055em; line-height: 0.98; margin-bottom: 24px; }
@media (max-width: 1020px) { .about-hero-grid { grid-template-columns: 1fr; } }

.x-term { padding: 0; overflow: hidden; font-size: 0.92rem; }
.x-term-bar { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--edge); color: var(--muted); font-size: 0.85rem; }
.x-term-lines { list-style: none; margin: 0; padding: 18px 20px 22px; display: grid; gap: 10px; font-variant-numeric: tabular-nums; }
.x-term-lines li { display: flex; align-items: center; gap: 10px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.x-term-lines b { color: var(--brand-b); font-weight: 600; }
.x-term-lines em { font-style: normal; margin-left: auto; color: var(--ok); font-weight: 600; }
.x-term-ok { margin-top: 6px; padding-top: 12px; border-top: 1px dashed var(--edge-strong); font-weight: 600; }
.x-caret { display: inline-block; width: 8px; height: 1.1em; margin-left: 4px; background: var(--brand-b); animation: caret 1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
/* Lines type in one after another on load. */
.js .x-term-lines li { opacity: 0; transform: translateX(-6px); animation: term-in 0.4s ease forwards; }
.js .x-term-lines li:nth-child(1) { animation-delay: .2s; } .js .x-term-lines li:nth-child(2) { animation-delay: .45s; }
.js .x-term-lines li:nth-child(3) { animation-delay: .7s; } .js .x-term-lines li:nth-child(4) { animation-delay: .95s; }
.js .x-term-lines li:nth-child(5) { animation-delay: 1.2s; } .js .x-term-lines li:nth-child(6) { animation-delay: 1.45s; }
.js .x-term-lines li:nth-child(7) { animation-delay: 1.8s; }
@keyframes term-in { to { opacity: 1; transform: none; } }

.about-story { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.about-story-text p { font-size: 1.15rem; line-height: 1.7; color: var(--muted); }
.about-story-text p:first-child { color: var(--text); font-size: 1.3rem; }
@media (max-width: 860px) { .about-story { grid-template-columns: 1fr; } }

.about-who { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.about-who-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.about-who-list li { padding: 22px 24px; border-radius: 20px; }
.about-who-list h3 { font-size: 1.1rem; margin-bottom: 6px; }
.about-who-list p { margin: 0; color: var(--muted); font-size: 0.97rem; }
@media (max-width: 960px) { .about-who { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .about-who-list { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  .js .x-term-lines li { opacity: 1; transform: none; animation: none; }
  .x-caret { animation: none; }
}

.about-exp { display: grid; grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.about-exp-num { display: grid; justify-items: start; gap: 4px; }
.about-exp-num b {
  font-family: var(--font-display); font-weight: 600; line-height: 0.85; letter-spacing: -0.07em;
  font-size: clamp(9rem, 6rem + 12vw, 18rem); padding-right: 0.08em;
  background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 20px 60px color-mix(in srgb, var(--brand-a) 45%, transparent));
}
.about-exp-num > span { font-size: clamp(1.2rem, 1rem + 1vw, 1.8rem); font-weight: 600; letter-spacing: -0.02em; color: var(--text); padding-left: 0.4rem; }
.about-exp-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.about-exp-list li { display: grid; grid-template-columns: 46px 1fr; gap: 16px; align-items: start; }
.about-exp-list h3 { font-size: 1.15rem; margin: 2px 0 4px; }
.about-exp-list p { margin: 0; color: var(--muted); }
@media (max-width: 900px) { .about-exp { grid-template-columns: 1fr; } }

/* ==========================================================================
   Futuristic scroll entrances (enabled only when motion is allowed: html.reveal-on)
   ========================================================================== */
.reveal-on [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 56px, 0) scale(0.97);
  filter: blur(8px);
  transition:
    opacity 0.9s cubic-bezier(.16,1,.3,1),
    transform 1.1s cubic-bezier(.16,1,.3,1),
    filter 0.9s cubic-bezier(.16,1,.3,1),
    clip-path 1.2s cubic-bezier(.16,1,.3,1);
}
.reveal-on [data-reveal="left"]  { transform: perspective(1200px) translate3d(-90px, 20px, 0) rotateY(14deg); }
.reveal-on [data-reveal="right"] { transform: perspective(1200px) translate3d(90px, 20px, 0) rotateY(-14deg); }
.reveal-on [data-reveal="up"]    { transform: translate3d(0, 64px, 0); }
.reveal-on [data-reveal="blur"]  { transform: translate3d(0, 28px, 0); filter: blur(16px); letter-spacing: 0.02em; transition-property: opacity, transform, filter, letter-spacing; }
.reveal-on [data-reveal="zoom"]  { transform: scale(0.82) translate3d(0, 30px, 0); filter: blur(10px) saturate(1.6); }
.reveal-on [data-reveal="pop"]   { transform: scale(0.6) translate3d(0, 16px, 0); filter: blur(4px); transition-duration: 0.6s, 0.7s, 0.6s; }
.reveal-on [data-reveal="flip"]  { transform: perspective(1400px) rotateX(28deg) translate3d(0, 80px, 0) scale(0.94); transform-origin: 50% 100%; }

/* Day panels open from the centre like an iris, with a light beam sweeping down once. */
.reveal-on [data-reveal="iris"] {
  opacity: 1; filter: none;
  transform: translate3d(0, 40px, 0) scale(0.96);
  clip-path: inset(10% 8% 10% 8% round 60px);
}
.reveal-on [data-reveal="iris"].is-in { clip-path: inset(0 0 0 0 round clamp(28px, 4vw, 48px)); }
.tone-alt::after {
  content: ""; position: absolute; left: 0; right: 0; top: -20%; height: 18%; z-index: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--brand-b) 22%, transparent) 45%, color-mix(in srgb, var(--brand-a) 30%, transparent) 50%, transparent);
  opacity: 0;
}
.reveal-on .tone-alt.is-in::after { animation: beam 1.6s 0.15s cubic-bezier(.4,0,.2,1) forwards; }
@keyframes beam { 0% { top: -20%; opacity: 0; } 15% { opacity: 1; } 100% { top: 110%; opacity: 0; } }

.reveal-on [data-reveal].is-in {
  opacity: 1; transform: none; filter: none; letter-spacing: normal;
}
/* Headings keep their own tight tracking once revealed. */
.reveal-on .x-head[data-reveal].is-in, .reveal-on [data-reveal="blur"].is-in { letter-spacing: inherit; }

@media (prefers-reduced-motion: reduce) {
  .reveal-on [data-reveal] { opacity: 1 !important; transform: none !important; filter: none !important; clip-path: none !important; }
  .tone-alt::after { display: none; }
}

/* Light-beam sweep on day panels removed. */
.tone-alt::after { content: none; display: none; }

/* ==========================================================================
   One section = one screen (Home and About), on every screen size.
   Each section is exactly the window height; site.js scales the content down
   (CSS zoom) when it is taller than the screen, so nothing needs scrolling
   inside a section. Scrolling snaps to whole sections.
   ========================================================================== */
.fs-section {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: calc(var(--header-h) + clamp(12px, 3vh, 40px));
  padding-bottom: clamp(16px, 4vh, 48px);
  box-sizing: border-box;
}
.fs-section.tone-alt {
  min-height: calc(100svh - 2 * clamp(12px, 2vw, 24px));
  scroll-margin-top: clamp(12px, 2vw, 24px);
  padding-top: calc(var(--header-h) + clamp(8px, 2vh, 28px));
}
.fs-section > section { min-height: 0; padding-block: clamp(10px, 2.5vh, 40px); }
.x-hero.fs-section { margin-top: calc(-1 * var(--header-h)); padding-bottom: clamp(12px, 3vh, 32px); }
.x-hero.fs-section > .container { flex: 1; display: grid; align-content: center; }
.about-hero.fs-section { margin-top: calc(-1 * var(--header-h)); }
/* Content wrappers are what gets zoomed to fit. */
.fs-section > * { flex: none; }

/* The strip now lives inside the hero on every screen size. */
.x-hero > .x-marquee { margin-top: clamp(32px, 6vw, 64px); }
/* Used by site.js while measuring a section's natural content height. */
.fs-section.fs-measuring { min-height: 0 !important; justify-content: flex-start; }
.fs-section.fs-measuring > * { flex: none !important; }


/* ==========================================================================
   Height-aware sizing: type, artwork and spacing scale with the screen height
   as well as width, so each section fits a normal laptop screen at 100% —
   same scale as the menu, no shrinking. Long sections may still grow.
   ========================================================================== */
.x-title { font-size: min(var(--step-5), 10.5vh); }
.about-hero h1 { font-size: min(var(--step-5), 9.5vh); }
.x-head h2, .x-cta h2 { font-size: min(var(--step-4), 7.2vh); }
.x-lede { margin-bottom: clamp(18px, 3.2vh, 36px); }
.x-pill { margin-bottom: clamp(12px, 2.2vh, 24px); }
.x-title { margin-bottom: clamp(14px, 2.6vh, 28px); }
.x-trust { margin-top: clamp(16px, 3vh, 36px); }
.x-head { margin-bottom: clamp(20px, 4.5vh, 64px); }
.x-stage { height: min(clamp(380px, 42vw, 560px), 56vh); }
.x-panel { padding: clamp(20px, 3.5vh, 48px) clamp(20px, 4vw, 48px); }
.x-panel-art .mock { font-size: min(13px, 1.5vh); }
.bento { grid-auto-rows: minmax(min(190px, 21vh), auto); gap: clamp(10px, 1.6vh, 16px); }
.tile { padding: clamp(16px, 2.6vh, 26px); }
.x-steps li::before { margin-bottom: clamp(12px, 2.4vh, 22px); }
.x-stats { margin-top: clamp(8px, 2vh, 24px); }
.x-stat { padding: clamp(18px, 3vh, 28px); }
.x-pkg { padding: clamp(20px, 3.4vh, 32px); }
.x-faq summary { padding-block: clamp(12px, 2vh, 20px); }
.about-exp-num b { font-size: min(clamp(9rem, 6rem + 12vw, 18rem), 34vh); }
.about-exp-list { gap: clamp(10px, 1.8vh, 18px); }
@media (max-height: 820px) and (min-width: 1024px) {
  .tile-art { display: none; }          /* the big services tile keeps its text; mock hidden on short screens */
  .tile--xl { grid-row: span 1; }
}

/* ---- Fit tuning: every Home/About section fits laptop screens at 100% ---- */
@media (min-width: 1024px) {
  /* Section headings: title left, intro right — one compact row. */
  .fs-section .x-head { max-width: none; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); align-items: end; column-gap: clamp(24px, 4vw, 64px); }
  .fs-section .x-head > p { padding-bottom: 0.4em; }
  .fs-section .about-story .x-head, .fs-section .about-who .x-head, .fs-section .x-faq-grid .x-head, .fs-section .about-exp .x-head { grid-template-columns: 1fr; }

  /* Hero */
  .x-title { font-size: min(var(--step-5), 8.6vh); }
  .x-lede { max-width: 46ch; font-size: clamp(1.02rem, 0.9rem + 0.9vh, 1.25rem); }
  .x-trust { flex-wrap: nowrap; gap: 18px; font-size: 0.9rem; }
  .x-trust li { white-space: nowrap; }
  .x-hero > .x-marquee { margin-top: clamp(8px, 2vh, 28px); padding: clamp(10px, 1.6vh, 20px) 0; }

  /* Services bento: compact rows */
  .fs-section .bento:not(.bento--even) { grid-auto-rows: minmax(min(190px, 16vh), auto); }
  .fs-section .tile { padding: clamp(14px, 2vh, 26px); gap: 6px; }
  .fs-section .tile p { font-size: 0.93rem; }
  .fs-section .tile-icon { width: 40px; height: 40px; border-radius: 12px; }
  .fs-section .tile h3 { margin-top: 2px; font-size: 1.15rem; }

  /* Showcase panel */
  .x-panel-art .mock { font-size: min(13px, 1.3vh); }
  .x-panel-art .mock .m-hero strong { font-size: min(22px, 2.3vh); }
  .x-tabs { gap: clamp(14px, 2.4vh, 28px); }
}
@media (min-width: 1024px) and (max-height: 1000px) {
  .tile-phones { display: none; }
}
@media (min-width: 1024px) {
  /* The big services tile's mock-up floats in the corner instead of stretching the rows. */
  .fs-section .tile--xl { position: relative; overflow: hidden; }
  .fs-section .tile--xl .tile-art { position: absolute; right: -40px; bottom: -40px; width: 72%; margin: 0; }
  .fs-section .tile--xl > p { max-width: 34ch; }
  .fs-section .x-center { margin-top: clamp(10px, 1.6vh, 24px); }
  /* About: experience benefits in two columns. */
  .about-exp-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
}
@media (min-width: 1024px) and (max-height: 1000px) { .tile-art { display: block; } .tile--xl { grid-row: span 2; } }
/* Short laptop screens (e.g. 1366×768). */
@media (min-width: 1024px) and (max-height: 820px) {
  .fs-section { padding-top: calc(var(--header-h) + 6px); padding-bottom: 12px; }
  .fs-section .x-head { margin-bottom: 2vh; }
  .fs-section .tile { padding: 12px 16px; }
  .fs-section .tile p { font-size: 0.86rem; line-height: 1.42; }
  .fs-section .tile-icon { width: 34px; height: 34px; }
  .fs-section .tile-icon .icon { width: 18px; height: 18px; }
  .x-panel { padding: 18px 28px; }
  .x-panel-art .mock { font-size: 1.12vh; }
  .x-panel h3 { font-size: 1.6rem; }
  .x-panel .x-checks { gap: 6px; margin-bottom: 16px; }
}
@media (min-width: 1024px) {
  .fs-section .tile--xl .tile-art { width: 56%; right: -70px; bottom: -56px; }
  .fs-section .tile--xl > p { max-width: 24ch; }
  .x-panel-art .mock { font-size: min(12.5px, 1.2vh); }
}

/* Even rhythm between sections: short closing call-to-action sections keep their natural height
   instead of being centred in a full screen (which left a large empty band above them). */
.fs-section:has(.x-cta) { min-height: 0; padding-block: clamp(40px, 7vh, 88px); }
.x-hero.fs-section:has(.x-cta) { min-height: 100svh; }
/* Packages: features list is the longest part; keep it compact. */
.x-pkg .x-checks { gap: 8px; margin-bottom: 20px; }


/* Admin: theme picker */
.theme-choice { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.theme-card { display: flex; align-items: center; gap: 14px; padding: 16px; text-align: left; cursor: pointer;
  border-radius: 18px; border: 1px solid var(--edge-strong); background: var(--pane); color: var(--text); font: inherit; }
.theme-card.is-on { border-color: var(--brand-b); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-b) 30%, transparent); }
.theme-swatch { width: 56px; height: 40px; border-radius: 10px; flex: none; border: 1px solid var(--edge-strong); }
.theme-card--dark .theme-swatch { background: linear-gradient(135deg, #05060f 55%, #7c5cff); }
.theme-card--light .theme-swatch { background: linear-gradient(135deg, #f5f6fc 55%, #6a4bff); }

/* ==========================================================================
   Mobile polish (audited at 320, 360, 390, 414 and 768 px)
   ========================================================================== */
.btn--sm, .header-actions .btn, .nav .btn { white-space: nowrap; }
.aside-pane .btn { white-space: normal; text-align: center; height: auto; padding-block: 12px; line-height: 1.3; }
.btn--sm { min-height: 40px; }
.icon-btn { width: 44px; height: 44px; }
.x-tablist button { min-height: 44px; }
.checkbox input { width: 22px; height: 22px; }
@media (max-width: 700px) {
  /* Phones: natural section heights for an even rhythm (full-screen sections are a desktop feature). */
  .fs-section { min-height: 0; padding-top: calc(var(--header-h) + 8px); padding-bottom: 40px; }
  .fs-section.tone-alt { min-height: 0; padding-top: 48px; }
  .x-hero.fs-section { min-height: 100svh; }
  .section { padding-block: 48px; }
}
@media (max-width: 560px) {
  .x-actions .btn { flex: 1 1 100%; }
  .x-cta .x-actions .btn { flex: 1 1 100%; }
  .x-stage { margin-inline: 6px; }
  .x-float--front { left: 3%; }
  .x-float--main { left: 10%; right: 2%; }
  .x-title { font-size: clamp(2.5rem, 1.4rem + 6.4vw, 3.4rem); }
  .page-head h1, .about-hero h1 { font-size: clamp(2.4rem, 1.4rem + 6vw, 3.2rem); }
  .x-head h2, .x-cta h2 { font-size: clamp(2rem, 1.3rem + 4.4vw, 2.6rem); }
  .x-tablist button { flex: 1 1 calc(50% - 8px); justify-content: center; padding-inline: 10px; }
  .x-panel { padding: 20px; }
  .x-pkg, .x-stat { padding: 22px; }
}
@media (max-width: 359px) {
  .header-cta { display: none; }           /* the menu holds "Start a project" */
  .brand { font-size: 1.1rem; }
}
/* Room for descenders (g, p, y) in the rotating hero word. */
.x-rotator { height: 1.16em; }
@media (min-width: 1024px) and (max-height: 820px) { .x-tablist button { min-height: 38px; } .x-tabs { gap: 12px; } }

/* ==========================================================================
   Mobile design pass: proportionate type, compact header, normal-size buttons.
   Overrides earlier mobile rules.
   ========================================================================== */
@media (max-width: 700px) {
  :root { --header-h: 64px; }
  body { font-size: 1rem; }

  /* Header: logo + menu only; "Start a project" lives in the menu. */
  .header-cta { display: none; }
  .brand { font-size: 1.12rem; gap: 8px; }
  .brand-mark { width: 28px; height: 28px; }
  .icon-btn { width: 42px; height: 42px; }

  /* Hero */
  .x-hero.fs-section { min-height: 0; padding-top: calc(var(--header-h) + 20px); padding-bottom: 8px; }
  .x-pill { font-size: 0.8rem; padding: 5px 12px 5px 10px; margin-bottom: 16px; gap: 8px; }
  .x-title { font-size: clamp(2.2rem, 1.5rem + 3.4vw, 2.75rem); line-height: 1.02; letter-spacing: -0.045em; margin-bottom: 16px; }
  .x-lede { font-size: 1rem; line-height: 1.55; margin-bottom: 22px; }
  .x-actions { gap: 10px; flex-wrap: nowrap; }
  .x-actions .btn, .x-cta .x-actions .btn { flex: 1 1 0; min-width: 0; }
  .btn--lg { min-height: 50px; padding: 0 16px; font-size: 0.95rem; }
  .x-trust { margin-top: 18px; gap: 6px 16px; font-size: 0.85rem; }
  .x-trust .icon { width: 16px; height: 16px; }
  .x-stage { height: 300px; margin: 28px 0 0; }
  .x-chip { padding: 7px 12px; font-size: 0.75rem; }
  .x-hero > .x-marquee { margin-top: 20px; padding: 12px 0; }
  .x-marquee li { padding: 6px 14px; font-size: 0.88rem; }

  /* Section headings and pages */
  .page-head { padding: calc(var(--header-h) + 8px) 0 16px; }
  .page-head h1, .about-hero h1 { font-size: clamp(2.1rem, 1.5rem + 3vw, 2.6rem); line-height: 1.04; letter-spacing: -0.045em; }
  .lede { font-size: 1.05rem; }
  .x-head h2, .x-cta h2 { font-size: clamp(1.75rem, 1.3rem + 2.4vw, 2.2rem); letter-spacing: -0.04em; line-height: 1.05; }
  .x-head p, .x-cta p { font-size: 1rem; }
  .x-head { margin-bottom: 24px; gap: 10px; }
  .section { padding-block: 40px; }
  .tone-alt { border-radius: 28px; margin-inline: 8px; }
  .tile h3, .x-pkg h3 { font-size: 1.15rem; }
  .x-panel h3 { font-size: 1.4rem; }
  .x-stat b { font-size: 2.2rem; }
  .about-exp-num b { font-size: 7rem; }
  .x-cta { padding: 36px 20px; border-radius: 28px; }
}
@media (max-width: 359px) {
  .x-actions { flex-wrap: wrap; }
  .x-actions .btn { flex: 1 1 100%; }
}

/* ==========================================================================
   Phones & touch devices: smooth scrolling and a clean hero.
   ========================================================================== */
@media (max-width: 700px) {
  /* Header: logo left; "Get a quote" + menu on the right. */
  .header-actions, .nav + .header-actions { margin-left: auto; gap: 8px; }
  .header-cta { display: inline-flex; }

  /* Hero: one clean example that fits its box (no overlap with the strip below). */
  .x-stage { height: auto; perspective: none; margin: 28px 0 0; transform: none !important; }
  .x-float--back, .x-float--front, .x-chip { display: none; }
  .x-float--main { position: relative; inset: auto; transform: none; animation: none; }
  .x-float--main .mock { font-size: 10px; }
}
@media (max-width: 359px) { .header-cta { display: none; } }

/* Touch devices: drop effects that make mobile browsers repaint on every scroll frame. */
@media (max-width: 700px), (pointer: coarse) {
  body::after { filter: none; animation: none; }
  body::before { mask-image: none; -webkit-mask-image: none; opacity: 0.6; }
  .x-hero-canvas { display: none; }
  .glass, .tile, .x-panel, .x-pkg, .x-stat, .x-faq details, .x-marquee li, .x-pill, .nav, .btn--glass {
    backdrop-filter: none !important; -webkit-backdrop-filter: none !important;
  }
  .site-header, html.scrolled .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: color-mix(in srgb, var(--night) 94%, transparent); }
  .nav::before, .btn--glass::before, .btn--glow::before, .x-tablist::before,
  .x-grad, .nav-ind, .glide-ind, .x-float, .x-chip, .x-pulse, .m-line { animation: none !important; }
  .spot::after { display: none; }
  /* Simple, cheap scroll entrances: fade + short rise, no blur or 3D. */
  .reveal-on [data-reveal], .reveal-on [data-reveal="left"], .reveal-on [data-reveal="right"],
  .reveal-on [data-reveal="zoom"], .reveal-on [data-reveal="pop"], .reveal-on [data-reveal="flip"], .reveal-on [data-reveal="blur"] {
    filter: none; transform: translate3d(0, 24px, 0); letter-spacing: normal;
    transition: opacity 0.6s ease, transform 0.6s ease;
  }
  .reveal-on [data-reveal="iris"] { clip-path: none; transform: none; transition: none; }
  .reveal-on [data-reveal].is-in { transform: none; }
}
@media (max-width: 400px) { .x-actions .btn { font-size: 0.86rem; padding: 0 10px; white-space: nowrap; } }
/* Hero promises on phones: two side by side, the third centred below. */
@media (max-width: 700px) {
  .x-trust { display: grid; grid-template-columns: repeat(2, max-content); justify-content: center; gap: 10px 18px; }
  .x-trust li:last-child { grid-column: 1 / -1; justify-self: center; }
}
@media (max-width: 359px) { .x-trust { font-size: 0.78rem; gap: 8px 12px; } }
@media (max-width: 400px) { .x-trust { font-size: 0.76rem; gap: 8px 10px; } .x-trust li { gap: 5px; } .x-trust .icon { width: 14px; height: 14px; } }
@media (max-width: 340px) { .x-trust { font-size: 0.7rem; gap: 8px 8px; } }
@media (max-width: 380px) {
  .x-trust { grid-template-columns: 1fr 1fr; justify-content: stretch; font-size: 0.78rem; }
  .x-trust li { white-space: normal; align-items: flex-start; line-height: 1.3; }
  .x-trust li:last-child { justify-self: center; }
}

/* Phones: the full three-layer stack, sized to its box (overrides the single-mock rule above). */
@media (max-width: 700px) {
  .x-stage { position: relative; height: clamp(300px, 92vw, 420px); margin: 24px 0 0; perspective: 1200px; }
  .x-float--back, .x-float--front, .x-chip { display: block; }
  .x-chip { display: inline-flex; }
  .x-float { position: absolute; animation: none; }
  .x-float .mock { font-size: clamp(7.5px, 2.25vw, 10px); }
  .x-float--back  { inset: 0 0 auto 30%; width: 70%; opacity: 0.8; transform: rotateY(-12deg) rotateX(5deg) translateZ(-60px); }
  .x-float--main  { inset: 9% 3% auto 8%; width: auto; transform: rotateY(-12deg) rotateX(5deg); }
  .x-float--front { inset: auto auto 0 0; width: 56%; transform: rotateY(-12deg) rotateX(5deg) translateZ(40px); }
  .x-chip--a { top: 1%; left: 2%; }
  .x-chip--b { right: 0; bottom: 14%; }
}
@media (max-width: 700px) { .x-stage { height: clamp(350px, 104vw, 470px); margin-bottom: 8px; } }

/* ==========================================================================
   Phone / tablet menu: solid modern sheet + finger-following highlight
   ========================================================================== */
@media (max-width: 960px) {
  html.nav-open, html.nav-open body { overflow: hidden; }       /* page doesn't scroll behind the menu */
  .nav {
    position: fixed; inset: calc(var(--header-h) + 6px) 10px auto 10px;
    padding: 10px; gap: 4px; border-radius: 26px;
    background:
      radial-gradient(120% 80% at 100% 0%, color-mix(in srgb, var(--brand-a) 22%, transparent), transparent 60%),
      radial-gradient(90% 70% at 0% 100%, color-mix(in srgb, var(--brand-b) 14%, transparent), transparent 60%),
      var(--night-2) !important;
    border: 1px solid var(--edge-strong);
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.75);
    touch-action: none;                                            /* finger slides highlight instead of scrolling */
    -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
    transform-origin: top right;
    transition: opacity 0.22s ease, transform 0.32s cubic-bezier(.2,.9,.2,1.1), visibility 0.3s;
  }
  .nav::before { display: none; }
  .nav a {
    position: relative; z-index: 1;
    display: flex; align-items: center; justify-content: space-between;
    padding: 17px 20px; border-radius: 18px;
    font-size: 1.2rem; font-weight: 600; letter-spacing: -0.01em;
    color: var(--text);
    -webkit-tap-highlight-color: transparent;
    transition: color 0.2s ease, transform 0.2s ease;
  }
  .nav a:not(.nav-cta)::after {
    content: ""; width: 9px; height: 9px; flex: none;
    border-top: 2px solid currentColor; border-right: 2px solid currentColor;
    transform: rotate(45deg); opacity: 0.45; transition: opacity 0.2s ease, transform 0.2s ease;
  }
  .nav a.is-lit { color: #fff; }
  .nav a.is-lit::after { opacity: 1; transform: translateX(3px) rotate(45deg); }
  .nav a.active:not(.is-lit) { color: var(--brand-b); }
  .nav .nav-cta { margin-top: 8px; justify-content: center; min-height: 56px; font-size: 1.05rem; border-radius: 18px; }

  /* The highlight that glides under the finger. */
  .nav-ind {
    display: block; position: absolute; z-index: 0;
    left: var(--ind-x, 10px); top: var(--ind-y, 10px); width: var(--ind-w, 0); height: var(--ind-h, 0);
    opacity: var(--ind-o, 0); border-radius: 18px;
    background: var(--brand-grad);
    box-shadow: 0 10px 30px -8px color-mix(in srgb, var(--brand-a) 80%, transparent), inset 0 1px 0 rgba(255,255,255,.3);
    transition: top 0.28s cubic-bezier(.2,.9,.2,1.15), height 0.28s ease, opacity 0.2s ease;
    animation: none !important;
  }

  /* Opening: items slide in one after another. */
  .nav a { opacity: 0; transform: translateY(-8px); }
  html.nav-open .nav a { opacity: 1; transform: none; transition: opacity 0.35s ease, transform 0.4s cubic-bezier(.2,.9,.2,1.1), color 0.2s ease; }
  html.nav-open .nav a:nth-of-type(1) { transition-delay: 0.03s; }
  html.nav-open .nav a:nth-of-type(2) { transition-delay: 0.07s; }
  html.nav-open .nav a:nth-of-type(3) { transition-delay: 0.11s; }
  html.nav-open .nav a:nth-of-type(4) { transition-delay: 0.15s; }
  html.nav-open .nav a:nth-of-type(5) { transition-delay: 0.19s; }
  html.nav-open .nav a:nth-of-type(6) { transition-delay: 0.23s; }

  /* Menu button turns into a close (×) icon when open. */
  .menu-toggle .icon { transition: transform 0.3s ease; }
  html.nav-open .menu-toggle { background: var(--pane-strong); }
  html.nav-open .menu-toggle .icon { transform: rotate(90deg); }
}
@media (prefers-reduced-motion: reduce) {
  .nav a, html.nav-open .nav a { transition: none !important; opacity: 1; transform: none; }
}

@media (max-width: 960px) {
  .nav a:not(.nav-cta) { background: transparent !important; }
  .nav .nav-cta { color: #fff; }
  html.nav-open .menu-toggle .icon { transform: none; }
}
.menu-toggle .icon-close { display: none; }
html.nav-open .menu-toggle .icon-open { display: none; }
html.nav-open .menu-toggle .icon-close { display: block; }

/* Phones: keep the travelling light on buttons (cheap: a few small elements), pause it while scrolling. */
@media (max-width: 700px), (pointer: coarse) {
  .btn--glow::before, .btn--glass::before, .x-tablist::before { animation: nav-spin 6s linear infinite !important; }
  html.is-scrolling .btn--glow::before, html.is-scrolling .btn--glass::before, html.is-scrolling .x-tablist::before { animation-play-state: paused !important; }
}

/* ==========================================================================
   Legal pages (privacy, terms)
   ========================================================================== */
.legal-hero h1 { font-size: min(var(--step-5), 9vh); letter-spacing: -0.055em; line-height: 1; }
.legal-meta { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.legal-meta li { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: var(--radius-pill); border: 1px solid var(--edge-strong); background: var(--pane); font-size: 0.88rem; color: var(--muted); }
.legal-meta .icon { width: 16px; height: 16px; color: var(--brand-b); }

.legal-band { padding-block: clamp(40px, 7vw, 88px); }
.legal-grid { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.legal-toc { position: sticky; top: calc(var(--header-h) + 24px); }
.legal-toc-title { font-size: 0.8rem; font-weight: 600; color: var(--muted); margin: 0 0 12px; }
.legal-toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; counter-reset: toc; border-left: 1px solid var(--edge-strong); }
.legal-toc li { counter-increment: toc; }
.legal-toc a { display: flex; gap: 10px; padding: 7px 14px; margin-left: -1px; border-left: 2px solid transparent; color: var(--muted); text-decoration: none; font-size: 0.92rem; transition: color 0.2s ease, border-color 0.2s ease; }
.legal-toc a::before { content: counter(toc, decimal-leading-zero); font-variant-numeric: tabular-nums; opacity: 0.6; }
.legal-toc a:hover, .legal-toc a.is-current { color: var(--text); border-left-color: var(--brand-a); }

.legal-article { max-width: 760px; }
.legal-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: clamp(28px, 5vw, 48px); }
.legal-card { display: flex; gap: 12px; align-items: flex-start; padding: 18px; border-radius: 18px; }
.legal-card > .icon { width: 22px; height: 22px; flex: none; color: var(--brand-a); margin-top: 2px; }
.legal-card strong { display: block; margin-bottom: 4px; }
.legal-card span { font-size: 0.9rem; color: var(--muted); line-height: 1.45; display: block; }

.legal-sec { padding-block: 26px; border-top: 1px solid var(--edge); scroll-margin-top: calc(var(--header-h) + 20px); }
.legal-sec:first-of-type { border-top: 0; padding-top: 0; }
.legal-sec h2 { display: flex; align-items: baseline; gap: 14px; font-size: clamp(1.4rem, 1.1rem + 1vw, 1.8rem); letter-spacing: -0.03em; margin-bottom: 14px; }
.legal-sec h2 span { font-size: 0.75em; font-variant-numeric: tabular-nums; background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 0.08em; }
.legal-sec p, .legal-list li { color: var(--muted); line-height: 1.75; }
.legal-sec p strong, .legal-list strong { color: var(--text); }
.legal-list { padding: 0; margin: 0 0 1em; list-style: none; display: grid; gap: 10px; }
.legal-list li { position: relative; padding-left: 24px; }
.legal-list li::before { content: ""; position: absolute; left: 4px; top: 0.72em; width: 8px; height: 8px; border-radius: 50%; background: var(--brand-grad); }

.legal-facts { display: grid; grid-template-columns: max-content 1fr; gap: 8px 20px; margin: 0; padding: 18px 20px; border-radius: 16px; border: 1px solid var(--edge); background: var(--pane); }
.legal-facts dt { color: var(--muted); font-size: 0.92rem; }
.legal-facts dd { margin: 0; font-weight: 500; }

.legal-table { border: 1px solid var(--edge); border-radius: 16px; overflow: hidden; margin-bottom: 1em; }
.legal-row { display: grid; grid-template-columns: minmax(140px, 0.6fr) minmax(0, 1.4fr); gap: 16px; padding: 14px 18px; border-top: 1px solid var(--edge); font-size: 0.95rem; }
.legal-row:first-child { border-top: 0; }
.legal-row > span:first-child { font-weight: 600; color: var(--text); }
.legal-row > span:last-child { color: var(--muted); line-height: 1.6; }
.legal-row--head { background: var(--pane); font-size: 0.8rem; }
.legal-row--head > span { color: var(--muted) !important; font-weight: 600; }
.legal-row code { font-size: 0.85em; padding: 2px 6px; border-radius: 6px; background: var(--pane-strong); }

.legal-rights { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 1em; }
.legal-rights > div { padding: 14px 16px; border-radius: 14px; border: 1px solid var(--edge); background: var(--pane); }
.legal-rights strong { display: block; margin-bottom: 4px; }
.legal-rights span { font-size: 0.88rem; color: var(--muted); line-height: 1.45; }

.legal-callout { padding: 18px 20px; border-radius: 16px; margin-bottom: 14px; border: 1px solid transparent;
  background: linear-gradient(var(--night-2), var(--night-2)) padding-box, var(--brand-grad) border-box; }
.legal-callout p { margin: 0; color: var(--text); }

@media (max-width: 960px) {
  .legal-grid { grid-template-columns: 1fr; }
  .legal-toc { position: static; }
  .legal-toc ol { grid-template-columns: repeat(2, minmax(0, 1fr)); border-left: 0; gap: 4px 10px; }
  .legal-toc a { border-left: 0; padding: 6px 0; margin: 0; }
}
@media (max-width: 700px) {
  .legal-summary, .legal-rights { grid-template-columns: 1fr; }
  .legal-row { grid-template-columns: 1fr; gap: 4px; }
  .legal-hero h1 { font-size: clamp(2.2rem, 1.5rem + 3.4vw, 2.75rem); }
}

/* Touch devices (iPhone Safari can't animate the @property-based light): the travelling light is a
   rotating conic layer behind an inner fill — plain transform animation, works everywhere. */
@media (max-width: 700px), (pointer: coarse) {
  .btn--glow, .btn--glass { position: relative; isolation: isolate; overflow: hidden; }
  .btn--glow::before, .btn--glass::before {
    content: ""; position: absolute; z-index: -2; inset: auto; padding: 0;
    left: 50%; top: 50%; width: 220%; aspect-ratio: 1; height: auto;
    -webkit-mask: none; mask: none; filter: none; border-radius: 0;
    transform: translate(-50%, -50%) rotate(0deg);
    animation: ring-rotate 4s linear infinite !important;
  }
  .btn--glow::before { background: conic-gradient(from 0deg, transparent 0deg, rgba(255,255,255,.95) 40deg, transparent 95deg, transparent 360deg); }
  .btn--glass::before { background: conic-gradient(from 0deg, var(--brand-a) 0deg, var(--brand-b) 70deg, transparent 130deg, transparent 200deg, var(--brand-c) 260deg, var(--brand-a) 360deg); }
  /* Inner fill leaves a 2px ring where the light shows through. */
  .btn--glow::after, .btn--glass::after {
    content: ""; position: absolute; z-index: -1; inset: 2px; left: 2px; top: 2px; right: 2px; bottom: 2px;
    width: auto; height: auto; border-radius: inherit; transform: none; transition: none; pointer-events: none;
  }
  .btn--glow::after { background: var(--brand-grad); }
  .btn--glass::after { background: color-mix(in srgb, var(--night-2) 96%, transparent); }
  .btn--glass { border-color: transparent; background: transparent; }
  html.is-scrolling .btn--glow::before, html.is-scrolling .btn--glass::before { animation-play-state: paused !important; }
}
@keyframes ring-rotate { to { transform: translate(-50%, -50%) rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .btn--glow::before, .btn--glass::before { animation: none !important; } }
