@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&display=swap");

/* Liquid glass brand. Public pages opt in with <body class="glass">.
   Dark and light share one set of tokens through light-dark(). With no saved
   choice the page follows the system; /theme saves one in a cookie. */

body.glass,
body.staff {
  color-scheme: dark light;
  --bg: light-dark(#edf1fa, #05070f);
  --text: light-dark(#0a1224, #eaf0ff);
  --muted: light-dark(#4a5672, #a3b0cc);
  --soft: light-dark(#2e3a55, #c9d3ea);
  --pane: light-dark(rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.06));
  --pane-strong: light-dark(rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.1));
  --edge: light-dark(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.14));
  --line: light-dark(rgba(10, 18, 36, 0.14), rgba(255, 255, 255, 0.16));
  --hi: light-dark(rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.22));
  --shadow: light-dark(0 30px 70px -34px rgba(30, 45, 90, 0.45), 0 30px 80px -30px rgba(0, 0, 0, 0.75));
  --accent: light-dark(#1d4ed8, #7dd3fc);
  --accent-2: light-dark(#7c3aed, #a78bfa);
  --ok: light-dark(#0f766e, #5eead4);
  --warn: light-dark(#b45309, #fdba74);
  --err: light-dark(#b42318, #fca5a5);
  --btn-a: light-dark(#2f55e8, #8ea6ff);
  --btn-b: light-dark(#1d6fa8, #5eead4);
  --btn-fg: light-dark(#ffffff, #04101f);
  --btn-glow: light-dark(rgba(47, 85, 232, 0.55), rgba(94, 234, 212, 0.5));
  --chip-bg: light-dark(#0a1224, #eaf0ff);
  --chip-fg: light-dark(#ffffff, #05070f);
  --field: light-dark(rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.06));
  --blob-1: light-dark(rgba(99, 132, 255, 0.45), rgba(76, 99, 255, 0.5));
  --blob-2: light-dark(rgba(45, 212, 191, 0.35), rgba(20, 184, 166, 0.36));
  --blob-3: light-dark(rgba(192, 132, 252, 0.35), rgba(168, 85, 247, 0.34));
  --display: "Space Grotesk", Inter, "Avenir Next", sans-serif;

  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.55;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body.glass[data-theme="dark"],
body.staff[data-theme="dark"] { color-scheme: dark; }
body.glass[data-theme="light"],
body.staff[data-theme="light"] { color-scheme: light; }

/* Aurora behind the glass. Soft gradients, no filter, so it stays cheap. */
body.glass::before,
body.staff::before {
  content: "";
  position: fixed;
  inset: -20vmax;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(40vmax 40vmax at 18% 12%, var(--blob-1), transparent 70%),
    radial-gradient(36vmax 36vmax at 88% 30%, var(--blob-2), transparent 70%),
    radial-gradient(38vmax 38vmax at 45% 100%, var(--blob-3), transparent 70%);
  animation: drift 26s ease-in-out infinite alternate;
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(3vmax, -2vmax, 0) scale(1.08); }
}

body.glass :where(h1, h2, h3),
body.staff :where(h1, h2, h3) {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

:where(body.glass) h1 { font-size: clamp(36px, 5.6vw, 68px); letter-spacing: -0.04em; }
:where(body.glass) h2 { font-size: clamp(28px, 3.6vw, 44px); }
:where(body.glass) h3 { font-size: 20px; letter-spacing: -0.02em; line-height: 1.2; }

:where(body.glass) a { color: var(--accent); }
:where(body.glass) :where(p, li) { font-size: 16px; line-height: 1.55; }

body.glass .skip {
  position: absolute;
  left: 12px;
  top: 8px;
  z-index: 40;
  transform: translateY(-160%);
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--pane-strong);
  color: var(--text);
}
body.glass .skip:focus { transform: none; }

:where(body.glass) :focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* Layout */
.site { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.site.narrow { width: min(760px, calc(100% - 32px)); }
.stack { display: grid; gap: 18px; }

.pane {
  position: relative;
  background: linear-gradient(160deg, var(--pane-strong) 0%, var(--pane) 55%);
  border: 1px solid var(--edge);
  border-radius: 24px;
  box-shadow: inset 0 1px 0 var(--hi), var(--shadow);
  -webkit-backdrop-filter: blur(22px) saturate(170%);
  backdrop-filter: blur(22px) saturate(170%);
  padding: 26px;
}
.pane::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(115deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 28%, rgba(255, 255, 255, 0) 72%, rgba(255, 255, 255, 0.07) 100%);
  mix-blend-mode: overlay;
}
.pane > * { position: relative; }
.pane.lift { transition: transform 0.25s ease; }
.pane.lift:hover { transform: translateY(-4px); }

.eyebrow {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}
.lede { margin: 12px 0 0; font-size: 18px; color: var(--muted); max-width: 40rem; }
.muted { color: var(--muted); }

.grad {
  background: linear-gradient(100deg, var(--text) 0%, var(--accent) 55%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Top bar */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  padding: 14px 0 0;
}
.bar-in {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px 10px 18px;
  border-radius: 18px;
}
.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--display);
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -0.02em;
}
.brand-mark i {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, #fff 0%, rgba(255, 255, 255, 0) 30%),
    radial-gradient(circle at 60% 65%, #5eead4 0%, rgba(94, 234, 212, 0) 60%),
    radial-gradient(circle, #4c63ff 0%, #1b2470 80%);
  box-shadow: 0 0 18px rgba(94, 234, 212, 0.5);
}
/* brand-orb.js swaps the sphere for a small particle globe. */
.brand-mark i { position: relative; flex: none; }
.brand-mark i.has-particles { background: none; box-shadow: none; }
.brand-mark i.has-particles::before { content: ""; position: absolute; inset: 10%; border-radius: 50%; background: radial-gradient(circle, rgba(94, 234, 212, 0.28), rgba(76, 99, 255, 0) 70%); filter: blur(4px); }
.brand-mark i canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.topbar nav.links { display: flex; gap: 22px; margin-left: 10px; }
.topbar nav.links a { color: var(--muted); text-decoration: none; font-weight: 500; font-size: 15px; padding: 8px 0; }
.topbar nav.links a:hover { color: var(--text); }
.topbar .spacer { flex: 1; }
.bar-in { flex-wrap: nowrap; }
body.glass .topbar .btn { white-space: nowrap; min-height: 44px; padding: 0 16px; }

/* Language and theme controls */
.langs { display: flex; gap: 6px; }
.langs a {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--pane);
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}
.langs a[aria-current="true"] { background: var(--chip-bg); color: var(--chip-fg); border-color: transparent; }

.theme-toggle { margin: 0; display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 14px; background: var(--pane); }
body.glass .theme-toggle button,
body.staff .theme-toggle button {
  width: 44px;
  min-height: 44px;
  padding: 0;
  transform: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  box-shadow: none;
  cursor: pointer;
}
body.glass .theme-toggle button[aria-pressed="true"],
body.staff .theme-toggle button[aria-pressed="true"] { background: var(--chip-bg); color: var(--chip-fg); }
.theme-toggle svg { width: 18px; height: 18px; }

/* Settings menu: one gear in the top bar opens language and theme. */
.settings { position: relative; }
.settings > summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  min-height: 44px;
  padding: 0 10px 0 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--pane);
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}
.settings > summary::-webkit-details-marker { display: none; }
.settings > summary svg { width: 19px; height: 19px; transition: transform 0.3s ease; }
.settings > summary .caret { width: 14px; height: 14px; }
.settings > summary:hover,
.settings[open] > summary { color: var(--text); }
.settings[open] > summary svg:first-child { transform: rotate(60deg); }
.settings[open] > summary .caret { transform: rotate(180deg); }
.settings > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.settings-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 60;
  display: grid;
  gap: 8px;
  min-width: 196px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: var(--shadow);
  animation: settings-in 0.18s ease both;
}
@keyframes settings-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.settings-label { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.settings-label + .langs, .settings-label + .theme-toggle { margin-bottom: 4px; }
.topbar .settings-menu .langs { display: flex; gap: 4px; }
.settings-menu .langs a { flex: 1; min-width: 0; min-height: 44px; border-radius: 10px; }
.settings-menu .theme-toggle { display: flex; }
.settings-menu .theme-toggle button { flex: 1; }

/* Buttons */
body.glass .btn,
body.glass button,
body.glass .tap {
  font: inherit;
  font-weight: 600;
  min-height: 48px;
  padding: 0 20px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--pane);
  color: var(--text);
  box-shadow: none;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.15s ease, filter 0.15s ease, background-color 0.15s ease;
}
body.glass .btn:hover,
body.glass button:hover,
body.glass .tap:hover { transform: translateY(-1px); background: var(--pane-strong); }

body.glass .btn.primary,
body.glass button.primary,
body.glass .tap.primary,
body.glass form button[type="submit"]:not(.ghost):not(.link):not(.google) {
  border: 0;
  background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%);
  color: var(--btn-fg);
  box-shadow: 0 10px 30px -8px var(--btn-glow), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
body.glass .btn.primary:hover,
body.glass button.primary:hover,
body.glass .tap.primary:hover,
body.glass form button[type="submit"]:not(.ghost):not(.link):not(.google):hover { filter: brightness(1.08) saturate(1.1); background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%); }
body.glass .btn.lg, body.glass .tap.lg { min-height: 56px; padding: 0 26px; font-size: 17px; }
body.glass .link {
  min-height: 44px;
  border: 0;
  background: none;
  color: var(--muted);
  text-decoration: underline;
}

/* Orb: the assistant */
.orb { position: relative; width: 220px; height: 220px; border-radius: 50%; }
.orb .core {
  position: absolute;
  inset: 18%;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0) 22%),
    radial-gradient(circle at 60% 65%, #5eead4 0%, rgba(94, 234, 212, 0) 55%),
    radial-gradient(circle at 35% 70%, #a78bfa 0%, rgba(167, 139, 250, 0) 60%),
    radial-gradient(circle at 50% 50%, #4c63ff 0%, #1b2470 75%);
  box-shadow: inset 0 -14px 30px rgba(0, 0, 0, 0.35), inset 0 10px 24px rgba(255, 255, 255, 0.35), 0 0 60px rgba(94, 234, 212, 0.35);
  animation: breathe 4s ease-in-out infinite;
}
.orb .ring,
.orb .ring.two {
  position: absolute;
  inset: 4%;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(125, 211, 252, 0), rgba(125, 211, 252, 0.85), rgba(167, 139, 250, 0.8), rgba(94, 234, 212, 0) 70%);
  -webkit-mask: radial-gradient(circle, transparent 63%, #000 64%, #000 67%, transparent 68%);
  mask: radial-gradient(circle, transparent 63%, #000 64%, #000 67%, transparent 68%);
  animation: spin 6s linear infinite;
}
.orb .ring.two { inset: 0; opacity: 0.6; animation-duration: 10s; animation-direction: reverse; }
.orb .halo { position: absolute; inset: -8%; border-radius: 50%; border: 1px solid var(--line); animation: ping 3s ease-out infinite; }
.orb.live .core { animation-duration: 1.1s; }
.orb.live .ring { animation-duration: 2s; }
.orb.live .halo { animation-duration: 1.4s; }
/* Particle orb: the canvas fills the hero behind its text and fades out at the edges.
   The .orb box stays in the layout as the place the waveform gathers. */
.orb-particles {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
  -webkit-mask: radial-gradient(farthest-side, #000 80%, transparent);
  mask: radial-gradient(farthest-side, #000 80%, transparent);
}
.orb.has-particles .core,
.orb.has-particles .ring,
.orb.has-particles .halo { display: none; }
.orb.sm { width: 72px; height: 72px; }
.orb.md { width: 112px; height: 112px; }

@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.05); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes ping { 0% { transform: scale(0.9); opacity: 0.9; } 100% { transform: scale(1.25); opacity: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* Home */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
  padding: clamp(48px, 8vw, 104px) 0 clamp(56px, 8vw, 104px);
  animation: rise 0.8s ease both;
}
.hero .orb { width: clamp(180px, 24vw, 260px); height: clamp(180px, 24vw, 260px); }
.hero h1 { margin: 6px 0 0; max-width: 18ch; }
.hero .lede { margin: 0; max-width: 40rem; }
.actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.chip-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--pane);
  color: var(--soft);
  font-size: 13px;
  font-weight: 600;
}
.chip i { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 12px var(--ok); }

.section { padding: clamp(40px, 6vw, 72px) 0; }
/* A jump from the top bar (#how, #cases, #pricing) lands the section's card
   28px below the sticky bar (about 80px tall), whatever the section padding. */
.section[id] { scroll-margin-top: calc(108px - clamp(40px, 6vw, 72px)); }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
.section > header { max-width: 44rem; margin-bottom: 30px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; }
.cards.wide { grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); }
.cards > .pane { display: flex; flex-direction: column; gap: 14px; }

.num { font-family: var(--display); font-weight: 700; font-size: 44px; line-height: 1; background: linear-gradient(100deg, var(--accent), var(--accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.icon {
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: var(--pane-strong);
  color: var(--accent);
}
.icon svg { width: 22px; height: 22px; }
.pane p { margin: 0; color: var(--muted); }
.pane .grad { color: transparent; }
.pane h3 { margin: 0; }
.pane h2 { margin: 0; }

.say {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 16px 16px 16px 4px;
  background: var(--pane);
  color: var(--text) !important;
}
.steps-small { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; counter-reset: s; }
.steps-small li { display: flex; gap: 10px; color: var(--soft); font-size: 15px; }
.steps-small li::before {
  counter-increment: s;
  content: counter(s);
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}
.gets {
  margin-top: auto !important;
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--pane-strong);
  color: var(--text) !important;
  font-size: 14px;
}
.gets b { color: var(--ok); }

/* Switchboard. CSS only, no script needed. Five calls take turns,
   one per --slot: the call rings in, the hub answers, the rules light up in
   order, a wire draws to one department and it shows the outcome. Per-call
   parts loop over five slots with a delay of --i slots; per-step parts loop
   once per slot, so the two stay in step. */
.fan { --slot: 4.4s; display: grid; gap: 14px; }
.calls > :nth-child(1), .spokes > :nth-child(1), .wires .live > :nth-child(1) { --i: 0; --tone: var(--ok); }
.calls > :nth-child(2), .spokes > :nth-child(2), .wires .live > :nth-child(2) { --i: 1; }
.calls > :nth-child(3), .spokes > :nth-child(3), .wires .live > :nth-child(3) { --i: 2; }
.calls > :nth-child(4), .spokes > :nth-child(4), .wires .live > :nth-child(4) { --i: 3; }
.calls > :nth-child(5), .spokes > :nth-child(5), .wires .live > :nth-child(5) { --i: 4; --tone: var(--accent-2); }

.calls { display: grid; justify-items: center; }
.fan .call {
  grid-area: 1 / 1;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
  margin: 0;
  padding: 8px 16px 8px 8px;
  border: 1px solid var(--line);
  border-radius: 20px 20px 20px 6px;
  background: var(--pane-strong);
  color: var(--text);
  font-size: 15px;
  opacity: 0;
  animation: call-in calc(var(--slot) * 5) ease both infinite;
  animation-delay: calc(var(--i) * var(--slot));
}
.call i {
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--btn-a), var(--btn-b));
  box-shadow: 0 6px 16px -6px var(--btn-glow);
  animation: ringing var(--slot) ease-in-out infinite;
}
.call i::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  background: var(--btn-fg);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-6 -6 36 36' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.91.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-6 -6 36 36' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.91.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.call b { flex: none; padding: 2px 7px; border-radius: 6px; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); font-size: 11px; letter-spacing: 0.08em; }

.lead { justify-self: center; position: relative; width: 2px; height: 36px; margin: -14px 0; background: var(--line); overflow: hidden; border-radius: 2px; }
.lead::after {
  content: "";
  position: absolute;
  left: 0;
  top: -40%;
  width: 100%;
  height: 40%;
  background: linear-gradient(transparent, var(--btn-b));
  opacity: 0;
  animation: lead-pulse var(--slot) ease-in infinite;
}

.hub {
  position: relative;
  justify-self: center;
  padding: 12px 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--btn-a), var(--btn-b));
  color: var(--btn-fg) !important;
  font-weight: 700;
  box-shadow: 0 10px 30px -8px var(--btn-glow);
  animation: hub-answer var(--slot) ease-out infinite;
}
.hub::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 2px solid var(--btn-b);
  opacity: 0;
  animation: hub-ping var(--slot) ease-out infinite;
}

.rules { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0; padding: 0; list-style: none; }
/* Lit states sit on a ::before overlay and only its opacity animates:
   light-dark() tokens inside @keyframes resolve to the light value. */
.rules li { position: relative; isolation: isolate; padding: 8px 14px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--soft); }
.rules li::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: -1;
  border-radius: inherit;
  border: 1px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 18%, transparent);
  box-shadow: 0 0 18px -6px var(--accent);
  opacity: 0;
  animation: rule-check var(--slot) ease infinite;
}
.rules li:nth-child(2)::before { animation-delay: calc(var(--slot) * 0.08); }
.rules li:nth-child(3)::before { animation-delay: calc(var(--slot) * 0.16); }

.wires { display: block; width: 100%; height: 64px; margin: -6px 0 -4px; }
.wires path { fill: none; stroke-width: 1.5; }
.wires .base path { stroke: var(--line); }
.wires .live path {
  stroke: var(--tone, var(--accent));
  stroke-width: 2.5;
  stroke-dasharray: 1 1;
  stroke-dashoffset: 1;
  animation: route calc(var(--slot) * 5) ease-in-out both infinite;
  animation-delay: calc(var(--i) * var(--slot));
}

.spokes { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 0; padding: 0; list-style: none; }
.spokes li {
  --tone: var(--accent);
  position: relative;
  isolation: isolate;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--pane);
  font-weight: 600;
  animation: dept-lift calc(var(--slot) * 5) ease both infinite;
  animation-delay: calc(var(--i) * var(--slot));
}
.spokes li::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: -1;
  border-radius: inherit;
  border: 1px solid var(--tone);
  background: color-mix(in srgb, var(--tone) 16%, transparent);
  box-shadow: 0 0 0 1px var(--tone), 0 16px 34px -16px var(--tone);
  opacity: 0;
  animation: dept-take calc(var(--slot) * 5) ease both infinite;
  animation-delay: calc(var(--i) * var(--slot));
}
.spokes .out {
  position: absolute;
  top: -11px;
  left: 50%;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--tone);
  color: var(--bg);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  opacity: 0;
  transform: translate(-50%, 4px) scale(0.9);
  animation: dept-out calc(var(--slot) * 5) ease both infinite;
  animation-delay: calc(var(--i) * var(--slot));
}

/* One slot = 20% of a five-slot loop. Within a slot: ring 0-15%, answer at
   20%, rules 26-62%, route 56-68%, outcome 68-94%. */
@keyframes call-in {
  0% { opacity: 0; transform: translateY(10px) scale(0.98); }
  1.2%, 18.4% { opacity: 1; transform: none; }
  19.6%, 100% { opacity: 0; transform: translateY(-6px); }
}
@keyframes ringing {
  0%, 16%, 100% { transform: none; }
  2%, 6%, 10% { transform: rotate(-14deg); }
  4%, 8%, 12% { transform: rotate(14deg); }
}
@keyframes lead-pulse {
  0%, 8% { top: -40%; opacity: 0; }
  10% { opacity: 1; }
  20% { top: 100%; opacity: 1; }
  21%, 100% { top: 100%; opacity: 0; }
}
@keyframes hub-answer {
  0%, 19%, 32%, 100% { transform: none; }
  23% { transform: scale(1.07); }
}
@keyframes hub-ping {
  0%, 19% { opacity: 0; transform: scale(1); }
  21% { opacity: 0.8; transform: scale(1); }
  42%, 100% { opacity: 0; transform: scale(1.35, 1.7); }
}
@keyframes rule-check {
  0%, 24%, 46%, 100% { opacity: 0; }
  28%, 40% { opacity: 1; }
}
@keyframes route {
  0%, 11.2% { stroke-dashoffset: 1; opacity: 1; }
  13.6%, 18.8% { stroke-dashoffset: 0; opacity: 1; }
  19.8%, 100% { stroke-dashoffset: 0; opacity: 0; }
}
@keyframes dept-take {
  0%, 13.2%, 19.8%, 100% { opacity: 0; }
  14%, 18.8% { opacity: 1; }
}
@keyframes dept-lift {
  0%, 13.2%, 19.8%, 100% { transform: none; }
  14%, 18.8% { transform: translateY(-3px); }
}
@keyframes dept-out {
  0%, 13.6% { opacity: 0; transform: translate(-50%, 4px) scale(0.9); }
  14.6%, 18.8% { opacity: 1; transform: translate(-50%, 0) scale(1); }
  19.6%, 100% { opacity: 0; transform: translate(-50%, -2px) scale(0.96); }
}

/* Narrow: the departments wrap, so the wires go and the cards light alone. */
@media (max-width: 820px) {
  .wires { display: none; }
  .spokes { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px 10px; margin-top: 12px; }
  .spokes li { min-height: 52px; padding: 10px 16px; }
}

/* Reduced motion: hold one routed call still. */
@media (max-width: 420px) {
  .topbar .brand-mark { font-size: 0; gap: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .fan *, .fan *::before, .fan *::after { animation: none !important; }
  .calls > :first-child { opacity: 1; }
  .wires .live > :first-child { stroke-dashoffset: 0; }
  .spokes > :first-child::before { opacity: 1; }
  .spokes > :first-child .out { opacity: 1; transform: translate(-50%, 0); }
}

.ticks { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.ticks li { display: flex; gap: 12px; color: var(--soft); }
.ticks li::before { content: "✓"; flex: none; font-weight: 700; color: var(--ok); }

.price { font-family: var(--display); font-weight: 700; font-size: clamp(44px, 6vw, 64px); letter-spacing: -0.04em; line-height: 1; margin: 6px 0; }
.pricing {
  display: grid;
  justify-items: center;
  gap: 0;
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(36px, 5vw, 56px) clamp(24px, 5vw, 56px);
  text-align: center;
}
.pricing .price { margin: 18px 0 16px; padding-bottom: 0.08em; }
.pricing .price-detail { display: grid; gap: 6px; max-width: 34rem; }
.pricing .price-detail p { font-size: 17px; line-height: 1.5; }
.pricing .actions { margin-top: 32px; }
/* Fluid bento: each row shares its width; the tile under the pointer takes more of it. */
.faq { display: grid; gap: 14px; }
.faq-row { display: flex; gap: 14px; }
.faq-row > .pane {
  flex: 1 1 0;
  min-width: 0;
  min-height: 132px;
  border-radius: 32px;
  transition: flex-grow 0.55s cubic-bezier(0.34, 1.2, 0.64, 1), border-color 0.3s, box-shadow 0.3s;
}
.faq-row > .pane.wide { flex-grow: 1.35; }
.faq-row:hover > .pane { flex-grow: 0.85; }
.faq-row:hover > .pane.wide { flex-grow: 1.15; }
.faq-row > .pane:hover,
.faq-row > .pane:focus-within { flex-grow: 2.1; border-color: var(--accent); }
.faq h3 { margin-bottom: 6px; }
@media (max-width: 720px) {
  .faq-row { flex-direction: column; }
  .faq-row > .pane { min-height: 0; }
}
.demo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; align-items: center; }

body.glass footer { padding: 36px 0 64px; display: grid; gap: 18px; color: var(--muted); border-top: 1px solid var(--line); }
body.glass footer a { color: var(--soft); }
body.glass footer address { font-style: normal; }
.legal-nav { display: flex; flex-wrap: wrap; gap: 0 18px; }
/* Tap targets: footer, legal links and the brand mark reach 44px. */
body.glass footer a, .legal-nav a, .legal-links a { display: inline-flex; align-items: center; min-height: 44px; }
.brand-mark { min-height: 44px; min-width: 44px; }
.todo { font-family: var(--mono); font-size: 14px; }

/* Forms: onboarding and sign in */
body.glass label {
  display: grid;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
body.glass input,
body.glass textarea,
body.glass select {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--field);
  color: var(--text);
  font: 16px/1.4 var(--sans);
  text-transform: none;
  letter-spacing: 0;
}
body.glass textarea { min-height: 120px; resize: vertical; }
body.glass input::placeholder { color: var(--muted); opacity: 0.8; }
body.glass input:focus,
body.glass textarea:focus,
body.glass select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 28%, transparent); }
body.glass input:disabled,
body.glass select:disabled { opacity: 0.55; cursor: not-allowed; }
body.glass select option { color: #0a1224; background: #fff; }

/* Select: the browser's own chevron sits hard against the edge. Ours is drawn to match the field, with room for the
   text, a hairline before it, and the accent colour while the field has focus. The chevron colours follow the theme
   the same way the tokens do: the saved choice on <body>, else the system. */
body.glass select {
  --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%234a5672' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --chev-on: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%231d4ed8' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  -webkit-appearance: none;
  appearance: none;
  padding-right: 54px;
  cursor: pointer;
  text-overflow: ellipsis;
  background-image: var(--chev), linear-gradient(var(--line), var(--line));
  background-repeat: no-repeat;
  background-position: right 20px center, right 46px center;
  background-size: 12px 8px, 1px 22px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-position 0.18s ease;
}
@media (prefers-color-scheme: dark) {
  body.glass:not([data-theme="light"]) select { --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%23b8c4e0' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); --chev-on: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%237dd3fc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
}
body.glass[data-theme="dark"] select { --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%23b8c4e0' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); --chev-on: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1.5 1.75 6 6.25l4.5-4.5' stroke='%237dd3fc' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
body.glass select:hover:not(:disabled):not(:focus) { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); }
body.glass select:focus { --chev: var(--chev-on); background-position: right 20px center, right 46px center; }
body.glass select:disabled { cursor: not-allowed; background-image: var(--chev); }
@media (prefers-reduced-motion: reduce) { body.glass select { transition: none; } }
body.glass input[type="checkbox"],
body.glass input[type="radio"] { width: 20px; min-height: 20px; height: 20px; padding: 0; accent-color: var(--accent); }

body.glass form:not(.theme-toggle) { display: grid; gap: 14px; margin-top: 18px; }
body.glass fieldset { margin: 0; padding: 14px 16px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--pane); min-width: 0; }
body.glass legend { padding: 0 8px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
body.glass fieldset label {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text);
}

/* Voice step: every language is a switch. The ones that are on get a main-language chip and the voice that speaks
   them, as cards with a native player. Only tokens set colour, so it follows the theme; no script. */
.lang-list { list-style: none; margin: 0; padding: 0; display: grid; }
.lang { display: grid; gap: 10px; padding: 6px 0 14px; border-top: 1px solid var(--line); }
.lang:first-child { border-top: 0; padding-top: 2px; }
.lang:last-child { padding-bottom: 2px; }
.lang-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 14px; }
body.glass fieldset label.switch {
  position: relative;
  flex: 1 1 200px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
}
body.glass fieldset .lang.off label.switch { color: var(--soft); }
/* The real checkbox stays in the page, focusable and announced as a switch, but unseen: the label (the whole row) is the
   tap target and draws the track in its place. */
body.glass .switch input[type="checkbox"] { position: absolute; top: 0; left: 0; width: 1px; height: 1px; min-height: 0; margin: 0; opacity: 0; }
.switch .track {
  position: relative;
  flex: none;
  width: 48px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--muted) 60%, transparent);
  background: var(--field);
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.switch .track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--muted);
  transition: transform 0.22s cubic-bezier(0.34, 1.3, 0.64, 1), background-color 0.2s ease;
}
.switch input:checked + .track { border-color: transparent; background: linear-gradient(135deg, var(--btn-a), var(--btn-b)); }
.switch input:checked + .track::after { transform: translateX(20px); background: var(--btn-fg); }
.switch:hover input:not(:disabled):not(:checked) + .track { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.switch input:focus-visible + .track { outline: 2px solid var(--accent); outline-offset: 3px; }
.lang.locked .switch { cursor: not-allowed; }
.lang.locked .switch .track,
.lang.locked .lang-name { opacity: 0.55; }
.lang-note { font-size: 13px; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .switch .track, .switch .track::after { transition: none; } }

.voice-pick { display: grid; gap: 8px; margin-left: 62px; }
.onboard-card .voice-title { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.onboard-card .voice-note { margin: 0; font-size: 14px; color: var(--muted); }
.voice-cards { display: grid; gap: 8px; }
body.glass fieldset label.voice-card,
.voice-card.chosen {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 320px);
  align-items: center;
  gap: 6px 14px;
  min-height: 60px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--pane);
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  transition: border-color 0.18s ease, background-color 0.18s ease;
}
.voice-card.chosen { grid-template-columns: minmax(0, 1fr) auto minmax(0, 320px); cursor: default; border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); background: color-mix(in srgb, var(--accent) 12%, transparent); }
body.glass fieldset label.voice-card:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); }
body.glass fieldset label.voice-card:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); }
body.glass fieldset label.voice-card:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.voice-name { min-width: 0; overflow-wrap: anywhere; }
.voice-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.voice-tag svg { width: 14px; height: 14px; }
.voice-card audio { width: 100%; max-width: 320px; height: 40px; justify-self: end; }
.lang-update {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 14px;
  margin-top: 10px;
  padding: 10px 14px;
  border: 1px dashed var(--line);
  border-radius: 14px;
  background: var(--pane);
  font-size: 14px;
  color: var(--soft);
}
/* The note under the talking points box, while it holds suggestions the owner has not saved yet. */
.onboard-card small.suggested { color: var(--accent); }
/* The Update button only matters once a switch differs from the page as it was served. Without :has() it always shows. */
@supports selector(:has(*)) {
  .lang-update { display: none; }
  .lang-set:has(.lang.off input[role="switch"]:checked, .lang.on input[role="switch"]:not(:checked)) .lang-update { display: flex; }
}
@media (max-width: 560px) {
  .voice-pick { margin-left: 0; }
  body.glass fieldset label.voice-card { grid-template-columns: auto minmax(0, 1fr); }
  .voice-card.chosen { grid-template-columns: minmax(0, 1fr) auto; }
  .voice-card audio { grid-column: 1 / -1; max-width: none; justify-self: stretch; }
}
body.glass button.google,
body.glass form button.google[type="submit"] { width: 100%; gap: 10px; background: var(--pane); color: var(--text); border: 1px solid var(--line); box-shadow: none; }
body.glass button.google:disabled { opacity: 0.7; cursor: not-allowed; transform: none; }
.soon { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; background: var(--pane-strong); color: var(--muted); }
.or { display: flex; align-items: center; gap: 12px; margin-top: 16px; font-size: 13px; color: var(--muted); }
.or span { flex: 1; height: 1px; background: var(--line); }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 2px 16px; }
.two-up { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.form-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; margin-top: 6px; }
body.glass .form-actions .ghost { background: transparent; }
body.glass .form-actions button:not(.ghost) { margin-left: 0; }
.form-actions .back { margin-right: auto; }

body.glass .alert,
body.glass .notice,
body.glass .loading { margin: 0; padding: 12px 16px; border-radius: 14px; border: 1px solid var(--line); font-weight: 500; }
body.glass .alert { background: color-mix(in srgb, var(--err) 14%, transparent); border-color: var(--err); color: var(--text); }
body.glass .notice,
body.glass .loading { background: color-mix(in srgb, var(--ok) 14%, transparent); border-color: color-mix(in srgb, var(--ok) 50%, transparent); color: var(--text); }

body.glass dl { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 14px 0 0; }
body.glass dt { font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); align-self: center; }
body.glass dd { margin: 0; }

body.glass blockquote { margin: 0; display: grid; gap: 10px; }
.bubble { padding: 12px 16px; border: 1px solid var(--line); border-radius: 18px 18px 18px 4px; background: var(--pane); color: var(--text) !important; }
.bubble.ai { margin-left: auto; max-width: 92%; border-radius: 18px 18px 4px 18px; background: color-mix(in srgb, var(--accent) 16%, transparent); }

/* Onboarding stepper: eight nodes on one connected line */
.onboard-caption { display: flex; align-items: baseline; gap: 10px; margin: 0 0 14px; font-size: 14px; color: var(--muted); }
.onboard-caption b { color: var(--text); font-weight: 600; }
.onboard-caption span::before { content: "·"; margin-right: 10px; }

body.glass .progress {
  --r: 16px;
  --gap: 6px;
  display: flex;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}
body.glass .progress li { position: relative; flex: 1 1 0; min-width: 0; }
body.glass .progress li + li::before {
  content: "";
  position: absolute;
  top: calc(var(--r) - 1px);
  /* Edge to edge: the line stops short of both circles instead of running under them. */
  left: calc(-50% + var(--r) + var(--gap));
  right: calc(50% + var(--r) + var(--gap));
  height: 2px;
  border-radius: 2px;
  background: var(--line);
}
body.glass .progress li.done + li::before { background: var(--ok); }
body.glass .progress .node {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 0 2px;
  color: var(--muted);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 600;
  text-align: center;
}
body.glass .progress .n {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--pane-strong);
  font-family: var(--mono);
  font-size: 13px;
  transition: background 0.2s, box-shadow 0.2s;
}
body.glass .progress .lbl { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
body.glass .progress a.node:hover { color: var(--text); }
body.glass .progress a.node:hover .n { border-color: var(--accent); }
body.glass .progress a.node:focus-visible { outline: none; }
body.glass .progress a.node:focus-visible .n { box-shadow: 0 0 0 3px var(--accent); }
body.glass .progress .done .n { border-color: transparent; background: var(--ok); color: var(--bg); }
body.glass .progress [aria-current="step"] { color: var(--text); }
body.glass .progress [aria-current="step"] .n {
  border-color: transparent;
  background: linear-gradient(135deg, var(--btn-a), var(--btn-b));
  color: var(--btn-fg);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 24%, transparent);
}
body.glass .progress .tick { width: 17px; height: 17px; }
/* Finished onboarding: the last node is both the current step and done, so it wears the done colour. */
body.glass .progress li.done [aria-current="step"] .n {
  background: var(--ok);
  color: var(--bg);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--ok) 24%, transparent);
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
body.glass .progress .tick path { stroke-dasharray: 1; stroke-dashoffset: 0; }

/* Arriving on a step: the line from the step just finished springs forward,
   that step's tick draws itself, then the current step pops in with a ring.
   Plays once per page load; motion.dev's spring, path-drawing and layout
   examples, done in CSS so onboarding stays script-free. */
body.glass .progress li.fresh + li::before {
  transform-origin: left center;
  animation: step-line 0.7s cubic-bezier(0.34, 1.3, 0.64, 1) 0.1s both;
}
body.glass .progress li.fresh .n { animation: step-done 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
body.glass .progress li.fresh .tick path { animation: step-tick 0.4s ease-out 0.15s both; }
body.glass .progress li.fresh + li [aria-current="step"] .n {
  animation: step-pop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.55s both, step-ring 1.2s ease-out 0.75s both;
}
@keyframes step-line { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes step-done { from { transform: scale(0.7); } to { transform: none; } }
@keyframes step-tick { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes step-pop { from { transform: scale(0.55); opacity: 0.4; } to { transform: none; opacity: 1; } }
@keyframes step-ring {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); }
  60% { box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent) 0%, transparent); }
  100% { box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 24%, transparent); }
}
@media (prefers-reduced-motion: reduce) {
  body.glass .progress li.fresh + li::before,
  body.glass .progress li.fresh .n,
  body.glass .progress li.fresh .tick path,
  body.glass .progress li.fresh + li [aria-current="step"] .n { animation: none; }
}

@media (max-width: 640px) {
  body.glass .progress .lbl { display: none; }
  body.glass .progress { --r: 14px; --gap: 3px; }
  body.glass .progress .n { width: 28px; height: 28px; font-size: 12px; }
}

.step-head { display: flex; align-items: center; gap: 16px; margin-bottom: 4px; }
.step-head .icon { flex: none; }
.step-head p { margin: 4px 0 0; }
.onboard-card h1, .onboard-card h2 { font-size: clamp(26px, 3.2vw, 36px); margin: 0; }
.onboard-card h3 { margin: 20px 0 6px; }
.onboard-card p { margin: 10px 0 0; }
.onboard-card + .onboard-card { margin-top: 18px; }
.hint { font-size: 14px !important; color: var(--muted); }

.choices { display: grid; gap: 10px; }
.choices label { display: flex !important; align-items: center; gap: 14px; min-height: 60px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--pane); cursor: pointer; text-transform: none; letter-spacing: 0; font-size: 16px; font-weight: 500; color: var(--text); }
.choices label:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); }

/* Go live plan card: the price, then one action. Paying is the activation request. */
/* Forwarding codes on the phone step: one per line, the code set apart so it can be read off and dialled. */
.forwarding .codes { margin: 12px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.forwarding .codes li { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 14px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--pane); color: var(--text); }
.forwarding code { font-family: var(--mono); font-size: 15px; letter-spacing: 0.02em; color: var(--text); user-select: all; overflow-wrap: anywhere; }
.onboard-card .plan-box { margin-top: 18px; }
.onboard-card .plan-box h3 { margin: 0; }
.onboard-card .plan-price { margin-top: 8px; font-family: var(--display); font-size: clamp(30px, 4vw, 40px); font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; color: var(--text); }
.onboard-card .plan-price span { font-family: var(--sans); font-size: 15px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.onboard-card .plan-status { color: var(--text); font-weight: 600; }
.plan-box form { margin-top: 18px; }
.plan-box form button { width: 100%; }
.checklist { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 10px; }
.checklist li { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--pane); }
.checklist li::before { content: "✓"; flex: none; width: 24px; height: 24px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; background: var(--ok); color: var(--bg); }
.checklist li.todo-row::before { content: "·"; background: var(--pane-strong); color: var(--muted); font-size: 20px; line-height: 1; }
.checklist b { font-weight: 600; }
.checklist li.optional-row::before { content: "○"; background: transparent; color: var(--muted); border: 1px solid var(--line); font-size: 12px; font-weight: 400; }
.checklist li.optional-row { color: var(--soft); }
.checklist.dash-list li { align-items: center; flex-wrap: wrap; }
.checklist.dash-list .dash-item { flex: 1 1 200px; min-width: 0; }
.checklist.dash-list .dash-item .notice, .checklist.dash-list .dash-item .hint, .checklist.dash-list .dash-item form, .checklist.dash-list .dash-item p { margin: 8px 0 0; }
.checklist.dash-list .go { flex: none; min-height: 40px; margin-left: auto; }
.dash-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-top: 18px; }
.dash-card { display: grid; gap: 4px; padding: 18px 20px; text-decoration: none; color: inherit; }
.dash-card span { color: var(--muted); font-size: 14px; }

/* The short way in */
.areas { display: grid; gap: 10px; margin: 8px 0 14px; }
.area-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px 14px; }
.area-row .count { display: inline-flex; align-items: center; gap: 8px; }
.area-row .count input { width: 5em; text-align: center; }
details.more { margin-top: 18px; }
details.more summary { cursor: pointer; color: var(--soft); font-weight: 600; min-height: 44px; display: flex; align-items: center; }
details.more[open] summary { margin-bottom: 8px; }
.next-steps { margin: 6px 0 14px; padding-left: 22px; display: grid; gap: 6px; }

/* The end of the onboarding: a calm panel above the checklist, with the tick the stepper's last node gets. */
.finish {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  margin: 18px 0 6px;
  padding: 20px 22px;
  border: 1px solid color-mix(in srgb, var(--ok) 55%, var(--line));
  border-radius: 20px;
  background: color-mix(in srgb, var(--ok) 11%, var(--pane));
}
.finish-mark { flex: none; width: 44px; height: 44px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--ok); color: var(--bg); box-shadow: 0 0 0 6px color-mix(in srgb, var(--ok) 18%, transparent); }
.finish-mark .tick { width: 22px; height: 22px; }
.finish h2 { margin: 0 0 4px; font-size: 22px; }
.finish p { margin: 0 0 10px; color: var(--soft); }
.finish .next-steps { margin: 0 0 14px; padding-left: 20px; display: grid; gap: 6px; color: var(--text); }
.finish .finish-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.finish .finish-actions .btn { min-height: 44px; }
@media (max-width: 560px) { .finish { flex-direction: column; padding: 18px; } }
.onboard-caption .finished-note { color: var(--ok); font-weight: 600; }
.transcript { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.transcript li { padding: 10px 14px; border: 1px solid var(--line); border-radius: 16px 16px 16px 4px; background: var(--pane); }
.voice-line { display: flex; align-items: center; gap: 18px; }

/* Step 8: talking to the receptionist in the browser. agent-test.js sets data-state (idle, connecting, listening,
   speaking, ended, error) and gives the voice step's orb .live while the receptionist speaks or connects. */
.talk-lead { font-size: 17px !important; }
.agent-test { display: grid; gap: 12px; margin-top: 18px; }
.talk-stage {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: radial-gradient(120% 150% at 0% 0%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 62%), var(--pane);
}
.talk-stage .orb { flex: none; transition: opacity 0.4s ease, transform 0.4s ease; }
.agent-test:is([data-state="idle"], [data-state="ended"], [data-state="error"]) .talk-stage .orb { opacity: 0.6; transform: scale(0.92); }
.talk-controls { display: grid; gap: 6px; justify-items: start; min-width: 0; }
body.glass button.talk {
  min-height: 56px;
  min-width: 168px;
  padding: 0 32px;
  border: 0;
  border-radius: 999px;
  font-size: 18px;
  background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%);
  color: var(--btn-fg);
  box-shadow: 0 12px 34px -10px var(--btn-glow), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
body.glass button.talk:hover { filter: brightness(1.08) saturate(1.1); background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%); }
body.glass button.talk[data-active] {
  border: 1px solid color-mix(in srgb, var(--err) 55%, transparent);
  background: var(--pane-strong);
  color: var(--text);
  box-shadow: none;
}
body.glass button.talk[data-active]::before { content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--err); }
body.glass button.talk:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
body.glass button.talk:disabled { opacity: 0.6; cursor: progress; transform: none; filter: none; }
.talk-status { margin: 0 !important; font-weight: 600; color: var(--text); }
.agent-test[data-state="error"] .talk-status { color: var(--err); }
.talk-clock { margin: 0 !important; min-height: 1.3em; font-family: var(--mono); font-size: 13px !important; color: var(--muted); }
.live-lines:empty { display: none; }
.live-lines li { max-width: 88%; animation: rise 0.35s ease both; }
.live-lines li b { display: block; margin-bottom: 2px; font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.live-lines li.you { justify-self: end; border-radius: 16px 16px 4px 16px; background: color-mix(in srgb, var(--accent) 14%, var(--pane)); }
.agent-test > .hint { margin: 0 !important; }
.badge.test { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.test-result { margin-top: 22px; border-top: 1px solid var(--line); }
.test-cleanup .form-actions { justify-content: flex-start; }
a.tel { font-family: var(--mono); font-weight: 600; white-space: nowrap; }
@media (max-width: 560px) {
  .talk-stage { flex-direction: column; gap: 16px; padding: 20px 16px; text-align: center; }
  .talk-controls { justify-items: center; width: 100%; }
  body.glass button.talk { width: 100%; }
  .live-lines li { max-width: 100%; }
}

/* Google Maps review: every value, where it came from, and how sure we are */
.found-card h3 { margin-top: 20px; }
.found-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.badge { display: inline-flex; align-items: center; padding: 2px 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--pane-strong); color: var(--soft); font-size: 10.5px; font-weight: 700; letter-spacing: 0.06em; }
.badge.src { color: var(--accent); }
.badge.conf-high { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 45%, transparent); }
.badge.conf-mid { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.badge.conf-low,
.badge.miss { color: var(--err); border-color: color-mix(in srgb, var(--err) 45%, transparent); }
body.glass .found.miss input { border-style: dashed; border-color: color-mix(in srgb, var(--warn) 60%, transparent); }
.found-note { display: block; margin-top: 2px; font-size: 13px; font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--warn); }
.maps-credit { margin: 8px 0 0 !important; font-size: 13px; color: var(--muted); }
.owner-only { display: grid; gap: 4px; margin-top: 10px; padding: 12px 16px; border: 1px dashed var(--line); border-radius: 14px; background: var(--pane); font-size: 14px; color: var(--soft); }
.owner-only b { color: var(--text); }
.guest-voices { display: grid; gap: 8px; margin: 4px 0 12px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--pane); }
.guest-voices .hint { margin: 0; font-size: 13px; }
.guest-quote { margin: 0; padding: 8px 0 0; border-top: 1px solid var(--line); font-size: 14px; color: var(--soft); }
.guest-quote p { margin: 0 0 4px; }
.guest-quote cite { font-size: 12px; font-style: normal; color: var(--muted); }

/* Tables step: areas as chips, a count per table size, and the summary card */
.templates { display: grid; gap: 6px; }
.templates .hint { margin: 0; }
.template-links, .chips { display: flex; flex-wrap: wrap; gap: 8px; }
body.glass label.chip-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--pane);
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text);
}
body.glass label.chip-check:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); }
body.glass label.chip-check:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.chips + label { margin-top: 12px; }
.sizes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 128px), 1fr)); gap: 12px; }
.sizes + .sizes { margin-top: 12px; }
body.glass fieldset label.count {
  display: grid;
  align-content: start;
  gap: 6px;
  min-height: 0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
body.glass fieldset .hint { margin: 0 0 10px; }
/* Only the areas that are ticked show their counts. Without :has() every area stays visible. */
@supports selector(:has(*)) {
  .tables-form:not(:has(input[name="area"][value="inside"]:checked)) .area-block[data-area="inside"],
  .tables-form:not(:has(input[name="area"][value="terrace"]:checked)) .area-block[data-area="terrace"],
  .tables-form:not(:has(input[name="area"][value="bar"]:checked)) .area-block[data-area="bar"],
  .tables-form:not(:has(input[name="area"][value="private"]:checked)) .area-block[data-area="private"],
  .tables-form:has(input[name="custom_name"]:placeholder-shown) .area-block[data-area="other"] { display: none; }
}
.summary {
  display: grid;
  gap: 4px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--pane-strong);
}
.onboard-card .summary h3 { margin: 0; }
.onboard-card .summary p { margin: 0; }
.summary .figures { font-size: 18px; color: var(--text); }
.summary .figures b { font-weight: 700; }
.summary-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 10px; }
body.glass .alert ul { margin: 0; padding-left: 20px; }
body.glass .notice.warn { background: color-mix(in srgb, var(--warn) 14%, transparent); border-color: color-mix(in srgb, var(--warn) 50%, transparent); margin-top: 8px; }
body.glass .onboard-card > .alert, body.glass .onboard-card > .notice { margin-top: 12px; }

/* Facts step: the week as one card per weekday, a name and three times for each service */
body.glass fieldset.hours { display: grid; gap: 12px; }
body.glass fieldset.hours > .hint { margin: 0; }
details.day { border: 1px solid var(--line); border-radius: 16px; background: var(--pane-strong); padding: 0 14px; }
details.day[open] { padding-bottom: 14px; }
details.day > summary { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; min-height: 52px; padding: 12px 24px 12px 0; position: relative; cursor: pointer; list-style: none; }
details.day > summary::-webkit-details-marker { display: none; }
details.day > summary::after { content: ""; position: absolute; right: 4px; top: 50%; width: 8px; height: 8px; margin-top: -6px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); }
details.day[open] > summary::after { margin-top: -2px; transform: rotate(-135deg); }
details.day > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 12px; }
.day .gist { font-size: 14px; color: var(--muted); }
.day > label.closed { margin: 0 0 10px; }
.services { display: grid; gap: 14px; }
.service { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 104px), 1fr)); gap: 10px; }
.service > label:first-child { grid-column: 1 / -1; }
.more > summary { display: flex; align-items: center; min-height: 44px; cursor: pointer; color: var(--accent); font-weight: 600; }
.more[open] > summary { margin-bottom: 6px; }
@supports selector(:has(*)) {
  .day:has(input[name="closed_weekday"]:checked) .services { display: none; }
}

@media (max-width: 860px) {
  .topbar nav.links { display: none; }
  .bar-in { gap: 8px; padding-left: 14px; }
  .topbar .langs { display: none; }
  .orb.sm { width: 56px; height: 56px; }
}

@media (max-width: 560px) {
  body.glass .hide-sm { display: none; }
  .bar-in { padding-left: 12px; gap: 6px; }
  .brand-mark { font-size: 17px; gap: 8px; }
  .pane { padding: 20px; border-radius: 20px; }
  .actions .btn { width: 100%; }
  body.glass dl { grid-template-columns: 1fr; gap: 2px; }
  body.glass dd { margin-bottom: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  body.glass *, body.glass::before, body.staff *, body.staff::before { animation: none !important; transition: none !important; }
}

/* Staff tools (floor and book). They keep their own layout and tokens; this
   block points those tokens at the glass palette so both themes work. */
body.staff {
  --canvas: var(--pane);
  --card: var(--pane-strong);
  --low: var(--pane);
  --high: var(--pane-strong);
  --ink: var(--text);
  --label: var(--soft);
  --occupied: light-dark(#2347c9, #4a5bd6);
  --free: var(--ok);
  --free-bg: color-mix(in srgb, var(--ok) 16%, transparent);
  --arrive: var(--warn);
  --arrive-bg: color-mix(in srgb, var(--warn) 18%, transparent);
  --danger: var(--err);
}
body.staff h1 { font-family: var(--display); letter-spacing: -0.03em; }
body.staff button,
body.staff .tap { border-radius: 12px; border-color: var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
body.staff button.primary,
body.staff .tap.primary { background: linear-gradient(135deg, var(--btn-a), var(--btn-b)); color: var(--btn-fg); border: 0; }
body.staff :is(.command, .floor, .roster, .gantt) { backdrop-filter: blur(18px) saturate(160%); -webkit-backdrop-filter: blur(18px) saturate(160%); }
body.staff :is(.pill, .banner, .error, .sheet, .matrix, .stat, .panel, .room) {
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: inset 0 1px 0 var(--hi), var(--shadow);
}
body.staff .room { background-image: radial-gradient(var(--line) 1px, transparent 1px); }
body.staff .table.occupied,
body.staff .block { color: #fff; }
body.staff .table.occupied.joined { outline-color: #fff; }
body.staff .block.joined { background: repeating-linear-gradient(135deg, var(--occupied) 0 8px, color-mix(in srgb, var(--occupied) 65%, #fff) 8px 16px); }
body.staff .filters button[aria-pressed="true"] { background: var(--chip-bg); color: var(--chip-fg); border-color: transparent; }
body.staff .ghost:hover, body.staff .ghost:focus-visible { color: var(--muted); }
body.staff :is(.slot .c.over, .cell.head.on, .sheet a, .lab.loose, .kind) { color: var(--accent); }
body.staff .banner.alert { border-color: var(--accent); }
body.staff tr.fresh { background: var(--arrive-bg); }
body.staff .cell.lab { background: color-mix(in srgb, var(--bg) 90%, var(--accent)); }
body.staff .cell.lab.stripe { background: color-mix(in srgb, var(--bg) 82%, var(--accent)); }

/* Legal pages: Impressum and privacy policy rendered from docs/legal */
.prose { padding: 40px 0 72px; }
.prose > .pane { padding: clamp(22px, 4vw, 44px); }
.prose h1 { font-size: clamp(30px, 4vw, 44px); margin: 0 0 12px; }
.prose h2 { font-size: 22px; margin: 30px 0 10px; }
.prose h3 { font-size: 18px; margin: 22px 0 8px; }
.prose p,
.prose li { color: var(--soft); }
.prose p { margin: 0 0 12px; }
.prose ul { margin: 0 0 14px; padding-left: 22px; display: grid; gap: 6px; }
.prose a { color: var(--accent); }
.prose strong { color: var(--text); }
.table-wrap { overflow-x: auto; margin: 4px 0 16px; border: 1px solid var(--line); border-radius: 14px; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; }
.prose th,
.prose td { padding: 10px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); color: var(--soft); }
.prose th { color: var(--text); font-weight: 600; background: var(--pane); }
.prose tr:last-child td { border-bottom: 0; }
.todo-box {
  padding: 1px 6px;
  border: 1px dashed var(--warn);
  border-radius: 6px;
  background: color-mix(in srgb, var(--warn) 14%, transparent);
  color: var(--text);
  font-family: var(--mono);
  font-size: 0.85em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.todo-summary {
  margin: 0 0 22px !important;
  padding: 12px 16px;
  border: 1px dashed var(--warn);
  border-radius: 14px;
  background: color-mix(in srgb, var(--warn) 12%, transparent);
  color: var(--text) !important;
  font-weight: 500;
}
/* A draft waits for counsel: a solid border tells it apart from the count of open items. */
.prose .draft-note { border-style: solid; }
.prose .english-only { color: var(--muted); font-size: 14px; }
.legal-links { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); }
.legal-links a[aria-current="page"] { color: var(--text); font-weight: 600; text-decoration: none; }

/* Call story on the home page. The markup is the finished frame. With .anim,
   static/call-story.js turns parts on along one loop; only opacity and
   transform move, and every part keeps its space, so nothing shifts. */
.story-stage {
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 22px;
  align-items: stretch;
}
.story-call, .story-owner { display: grid; align-content: start; gap: 14px; min-width: 0; }
.story-steps, .story-controls { grid-column: 1 / -1; }

.call-head { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 18px; background: var(--pane); }
.call-head .phone { position: relative; flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: var(--btn-fg); background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%); }
.call-head .phone svg { width: 20px; height: 20px; }
.call-head .phone::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--btn-b); opacity: 0; }
.call-head .who { display: grid; flex: 1; min-width: 0; line-height: 1.3; }
.call-head .who small { color: var(--muted); font-size: 13px; }
.orb.sm.story-orb { flex: none; width: 56px; height: 56px; }
.answered { margin: 0; display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--ok); }
.answered i, .toast i, .tablet-bar .live i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 12px var(--ok); }
.parallel { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.parallel .pill { padding: 5px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--pane); font-size: 13px; color: var(--soft); }
.langs-chip { position: relative; display: inline-grid; grid-template-columns: repeat(3, 38px); margin-left: auto; padding: 3px; border: 1px solid var(--line); border-radius: 999px; font-size: 12px; font-weight: 700; }
.langs-chip span { position: relative; padding: 3px 0; text-align: center; color: var(--muted); transition: color 0.4s ease; }
.langs-chip i { position: absolute; top: 3px; bottom: 3px; left: 3px; width: 38px; border-radius: 999px; background: linear-gradient(135deg, var(--btn-a) 0%, var(--btn-b) 100%); transition: transform 0.55s var(--ease); }
.langs-chip[data-state="en"] i { transform: translateX(38px); }
.langs-chip[data-state="de"] i { transform: translateX(76px); }
.langs-chip:not([data-state="en"]):not([data-state="de"]) span:nth-of-type(1),
.langs-chip[data-state="en"] span:nth-of-type(2),
.langs-chip[data-state="de"] span:nth-of-type(3) { color: var(--btn-fg); }

/* The conversation runs in a fixed window; the newest line sits at the bottom. */
.caps-window { display: flex; flex-direction: column; justify-content: flex-end; height: 372px; overflow: hidden; -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 44px); mask-image: linear-gradient(to bottom, transparent 0, #000 44px); }
.caps { position: relative; list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.story-stage.anim.ready .caps { transition: transform 0.8s var(--ease); }
.caps li { display: grid; gap: 2px; max-width: 92%; padding: 10px 14px; border: 1px solid var(--line); border-radius: 16px; background: var(--pane); }
.caps li > b { font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.caps .ai { justify-self: start; border-bottom-left-radius: 6px; }
.caps .guest { justify-self: end; border-bottom-right-radius: 6px; background: color-mix(in srgb, var(--accent) 12%, var(--pane)); }
.caps .spoken { font-size: 15px; color: var(--text); }
.caps .sub { font-size: 13px; color: var(--muted); }
.caps .sub:empty { display: none; }
.caps .check { justify-self: stretch; max-width: none; border-style: dashed; background: none; }
.checking { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.checking i { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--ok); animation: spin 0.9s linear infinite; }
.check:has(.pick.on) .checking i, .story-stage:not(.anim) .checking i { animation: none; border-color: var(--ok); }
.slots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.slot { position: relative; display: grid; place-items: center; padding: 8px 4px; border: 1px solid var(--line); border-radius: 12px; font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.slot small { font-size: 11px; color: var(--muted); }
.slot.full { opacity: 0.45; }
.slot.full small { text-decoration: line-through; }
.slot.pick small { color: var(--ok); }
.slot.pick::before, .floor .lit::before { content: ""; position: absolute; inset: -1px; border: 1px solid var(--ok); border-radius: inherit; background: color-mix(in srgb, var(--ok) 18%, transparent); box-shadow: 0 0 26px -6px var(--ok); }
.caps .note-drop { max-width: none; padding: 0; border: 0; background: none; }
.story-stage .tag { display: inline-flex; align-items: center; justify-self: start; padding: 5px 11px; border: 1px solid color-mix(in srgb, var(--warn) 45%, transparent); border-radius: 12px; background: color-mix(in srgb, var(--warn) 14%, transparent); color: var(--warn); font-size: 12.5px; font-weight: 700; }

.tablet { position: relative; display: grid; align-content: start; gap: 12px; height: 100%; box-sizing: border-box; padding: 16px; border: 1px solid var(--edge); border-radius: 22px; background: linear-gradient(160deg, var(--pane-strong) 0%, var(--pane) 60%); box-shadow: inset 0 1px 0 var(--hi); }
.tablet-bar { display: flex; align-items: center; gap: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.tablet-bar span { font-size: 14px; color: var(--muted); }
.tablet-bar .live { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ok); }
.toast { margin: 0; display: flex; align-items: center; gap: 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(135deg, color-mix(in srgb, var(--btn-a) 22%, transparent) 0%, color-mix(in srgb, var(--btn-b) 22%, transparent) 100%); font-size: 14px; font-weight: 600; }
.book { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.book li { display: grid; grid-template-columns: 52px minmax(0, 1fr); align-items: center; gap: 10px; }
.book time { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--muted); }
.book .card { grid-column: 2; grid-row: 1; display: grid; gap: 6px; min-height: 44px; align-content: center; padding: 8px 12px; box-sizing: border-box; border: 1px solid var(--line); border-radius: 12px; background: var(--pane); font-size: 14px; color: var(--soft); }
.book .card.muted { opacity: 0.55; }
.book .card.empty { border-style: dashed; background: none; }
.book .new::before { content: ""; grid-column: 2; grid-row: 1; align-self: stretch; border: 1px dashed var(--line); border-radius: 12px; }
.book .card.fresh { border-color: color-mix(in srgb, var(--ok) 55%, transparent); background: color-mix(in srgb, var(--ok) 10%, var(--pane)); color: var(--text); }
/* The home page's little floor. Scoped: the staff floor is also called .floor, and its tables are not these cells. */
.tablet .floor { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; padding-top: 4px; }
.tablet .floor span { position: relative; display: grid; place-items: center; height: 40px; border: 1px solid var(--line); border-radius: 10px; font-size: 12px; font-weight: 700; color: var(--muted); }
.tablet .floor .taken { background: color-mix(in srgb, var(--accent-2) 22%, transparent); }

.story-steps { list-style: none; margin: 4px 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
body.glass .story-steps button { position: relative; display: grid; justify-items: start; align-content: start; gap: 4px; width: 100%; height: 100%; min-height: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: none; color: var(--muted); font-weight: 400; text-align: left; }
body.glass .story-steps button:hover { transform: none; }
.story-steps b { font-size: 14px; color: var(--text); }
.story-steps span { font-size: 13px; line-height: 1.45; }
.story-steps button::before { content: ""; position: absolute; top: -1px; left: 14px; right: 14px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, var(--btn-a), var(--btn-b)); transform: scaleX(0); transform-origin: left; transition: transform 0.6s var(--ease); }
.story-stage:not(.anim) .story-steps button { cursor: default; }
.story-stage.anim .story-steps [aria-current] button { border-color: color-mix(in srgb, var(--btn-b) 50%, var(--line)); }
.story-stage.anim .story-steps [aria-current] button::before { transform: scaleX(1); }
.story-controls { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin-top: -6px; }
.story-stage:not(.anim) .story-controls { display: none; }
body.glass .story-controls .toggle { width: 48px; padding: 0; }
.story-controls svg { width: 18px; height: 18px; fill: currentColor; }
.story-controls .i-play, .story-stage.paused .story-controls .i-pause { display: none; }
.story-stage.paused .story-controls .i-play { display: inline; }
.story-end { display: grid; justify-items: center; gap: 18px; margin-top: 30px; text-align: center; }
.story-end .tagline { margin: 0; font-family: var(--display); font-size: clamp(24px, 3.2vw, 36px); font-weight: 700; line-height: 1.15; }

/* Motion. Parts start off and come on at their time; the two halves trade focus. */
.story-stage.anim [data-t]:not(.on) { opacity: 0; transform: translateY(10px); }
.story-stage.anim .w:not(.on) { transform: none; }
.story-stage.anim .fresh:not(.on) { transform: translateX(28px); }
.story-stage.anim .note-drop:not(.on) { transform: translateY(-16px); }
.story-stage.anim .toast:not(.on) { transform: translateY(-10px) scale(0.98); }
.story-stage.anim .slot.pick:not(.on), .story-stage.anim .floor .lit:not(.on) { opacity: 1; transform: none; }
.story-stage.anim .slot.pick:not(.on)::before, .story-stage.anim .floor .lit:not(.on)::before { opacity: 0; }
.story-stage.anim.ready [data-t], .story-stage.anim.ready .slot.pick::before, .story-stage.anim.ready .floor .lit::before { transition: opacity 0.6s var(--ease), transform 0.75s var(--ease); }
.story-stage.anim.ready .story-call, .story-stage.anim.ready .story-owner, .story-stage.anim.ready .story-orb { transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.story-stage.anim:not([data-scene="5"]) .story-owner { opacity: 0.5; transform: scale(0.98); }
.story-stage.anim[data-scene="5"] .story-call { opacity: 0.5; transform: scale(0.98); }
.story-stage.anim .story-orb[data-state="sleep"] { opacity: 0.45; transform: scale(0.86); }
.story-stage.anim .phone[data-state="ring"] { animation: ring 1.2s var(--ease) infinite; }
.story-stage.anim .phone[data-state="ring"]::after { animation: ping 1.2s ease-out infinite; }
.story-stage.idle *, .story-stage.idle *::before, .story-stage.idle *::after { animation-play-state: paused !important; }
@keyframes ring { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.07); } }

@media (max-width: 1023px) {
  .story-stage { grid-template-columns: minmax(0, 1fr); }
  .story-steps { grid-template-columns: minmax(0, 1fr); }
  .story-stage.anim[data-scene="5"] .story-call { opacity: 1; transform: none; }
  .caps-window { height: 330px; }
  /* While it plays, the scenes are a row of titles; the full list is the still frame. */
  .story-stage.anim .story-steps { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
  .story-stage.anim .story-steps li { flex: none; }
  .story-stage.anim .story-steps span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  body.glass .story-stage.anim .story-steps button { padding: 10px 14px; }
}
@media (max-width: 560px) {
  .story-stage.pane { padding: 16px; }
  .langs-chip { margin-left: 0; }
}

/* Mobile: the FAQ tiles stack as plain blocks (flex-basis 0 collapsed them
   in a column, so each card sat on the previous answer), and the sticky bar
   gets slimmer and opaque enough that content scrolling under it stays legible. */
@media (max-width: 720px) {
  .faq, .faq-row { gap: 12px; }
  .faq-row > .pane,
  .faq-row > .pane.wide,
  .faq-row:hover > .pane,
  .faq-row:hover > .pane.wide,
  .faq-row > .pane:hover,
  .faq-row > .pane:focus-within { flex: 0 0 auto; height: auto; min-height: 0; }
  .faq-row > .pane { border-radius: 22px; overflow: visible; }
  .faq h3 { margin: 0 0 8px; line-height: 1.25; }
  .faq p { margin: 0; }
  .topbar { padding-top: 8px; }
  .bar-in { padding-top: 6px; padding-bottom: 6px; border-radius: 16px; }
  body.glass .topbar .btn { min-height: 44px; padding: 0 14px; }
  .bar-in.pane {
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    -webkit-backdrop-filter: blur(18px) saturate(1.4);
    backdrop-filter: blur(18px) saturate(1.4);
  }
  /* Anything jumped to or focused clears the ~64px sticky bar. */
  html { scroll-padding-top: 80px; }
  .section[id] { scroll-margin-top: 80px; }
}
@media (prefers-reduced-motion: reduce) {
  .faq-row > .pane { transition: none; }
}

/* The floor as a form */
.floor-edit fieldset.area-edit { margin: 14px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; }
.floor-edit legend { padding: 0 8px; font-weight: 700; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--soft); }
.floor-edit .pair { display: inline-flex; align-items: center; gap: 8px; }
.floor-edit .pair .num { width: 4.5em; }
.floor-edit label.inline { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; }
.tables-list { border-collapse: separate; border-spacing: 6px 4px; font-size: 14px; }
.tables-list th { padding: 0 2px; font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); text-align: left; white-space: nowrap; }
.tables-list input, .tables-list select { min-height: 40px; padding: 0 8px; border-radius: 10px; width: auto; }
.tables-list .num { width: 4.2em; text-align: center; }
.tables-list select { min-width: 7em; max-width: 11em; }
.tables-list td:first-child input:not([type="hidden"]) { width: 5.5em; }
.combos { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 8px; }
.combos li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.combos .num { width: 4em; text-align: center; min-height: 40px; padding: 0 8px; }
.impact ul { margin: 8px 0; padding-left: 20px; }

/* The plan editor */
#fe[hidden], #fe-list[hidden], .fe-sheet[hidden] { display: none !important; }
.fe { display: grid; gap: 12px; }
.fe h1 { margin-bottom: 0; }
.fe-banner > * { margin: 0 0 8px; }
.fe-tabs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
body.glass .fe-tab { min-height: 44px; padding: 0 16px; white-space: nowrap; }
body.glass .fe-tab[aria-selected="true"] { background: var(--chip-bg); color: var(--chip-fg); border-color: transparent; }
.fe-scroll { overflow: auto; border: 1px solid var(--line); border-radius: 16px; background: var(--pane); }
.fe-room { position: relative; width: 100%; background-image: radial-gradient(var(--line) 1.2px, transparent 1.2px); background-size: calc(100% / var(--cw)) calc(100% / var(--ch)); }
.fe-links { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.fe-links line { stroke: var(--accent); stroke-width: 0.18; stroke-dasharray: 0.5 0.4; }
body.glass .fe-table { position: absolute; display: grid; place-items: center; align-content: center; gap: 0; min-height: 0; padding: 0; box-sizing: border-box; border: 2px solid var(--accent); border-radius: 10px; background: color-mix(in srgb, var(--accent) 14%, var(--bg)); color: var(--text); touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; font-weight: 700; line-height: 1.1; transition: none; }
body.glass .fe-table.fe-round { border-radius: 50%; }
body.glass .fe-table:active { cursor: grabbing; }
body.glass .fe-table[aria-pressed="true"] { outline: 3px solid var(--accent); outline-offset: 2px; background: color-mix(in srgb, var(--accent) 26%, var(--bg)); }
body.glass .fe-table.fe-problem { border-color: var(--err); }
body.glass .fe-table.fe-pushed::after { content: "+"; position: absolute; top: -9px; right: -9px; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; line-height: 1; background: var(--accent); color: var(--bg); }
.fe-label { font-size: 15px; }
.fe-seats { font-size: 11px; font-weight: 500; color: var(--muted); }
.fe-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.fe-palette { display: flex; flex-wrap: wrap; gap: 6px; }
body.glass .fe-add { min-height: 44px; padding: 0 14px; }
.fe-toolbar .fe-status { margin-left: auto; font-size: 13px; color: var(--muted); }
.fe-sheet { padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--pane); display: grid; gap: 10px; }
.fe-sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fe-sheet h2 { margin: 0; font-size: 18px; }
.fe-sheet-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.fe-field { display: grid; gap: 4px; font-size: 13px; }
body.glass .fe-save { background: linear-gradient(135deg, var(--btn-a), var(--btn-b)); color: var(--btn-fg); border: 0; min-height: 44px; }
body.glass .fe-save:disabled { opacity: 0.55; cursor: not-allowed; }
.fe-field.fe-wide { grid-column: span 2; }
.fe-turn { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.fe-degrees { min-width: 3.2em; text-align: center; font-variant-numeric: tabular-nums; }
.fe-impact ul { margin: 8px 0; padding-left: 20px; }
body.glass .fe-handle { position: absolute; display: block; width: 14px; height: 14px; padding: 0; min-height: 0; background: var(--bg); border: 2px solid var(--accent); border-radius: 50%; touch-action: none; z-index: 2; }
.fe-handle-nw { left: -8px; top: -8px; cursor: nwse-resize; }
.fe-handle-ne { right: -8px; top: -8px; cursor: nesw-resize; }
.fe-handle-se { right: -8px; bottom: -8px; cursor: nwse-resize; }
.fe-handle-sw { left: -8px; bottom: -8px; cursor: nesw-resize; }
.fe-handle-rot { left: 50%; top: -34px; margin-left: -7px; cursor: grab; }
.fe-handle-rot::before { content: ""; position: absolute; left: 50%; top: 100%; width: 2px; height: 18px; margin-left: -1px; background: var(--accent); }
.fe-marquee { position: absolute; border: 1.5px dashed var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); pointer-events: none; z-index: 3; }
.fe-selection { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; width: 100%; }
.fe-count { font-size: 13px; color: var(--muted); }
body.glass .fe-select.fe-on { background: var(--chip-bg); color: var(--chip-fg); border-color: transparent; }
body.glass .fe-tab-add, body.glass .fe-tab-settings { min-height: 44px; padding: 0 14px; white-space: nowrap; }

body.glass .fe-table.fe-overlap { border-style: dashed; border-color: var(--warn); }
.fe-overlap-note:empty { display: none; }
.fe-overlap-note { margin: 0; color: var(--warn); }
.fe-zoom { display: inline-flex; gap: 4px; }
body.glass .fe-zoom button { min-height: 44px; min-width: 44px; padding: 0 12px; }
.fe-versions { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.fe-versions li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.fe-scroll { touch-action: pan-x pan-y; }

/* Settings (app/owner_settings.py): the onboarding answers as named sections down the side; on a phone, a row on top. */
.settings-shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; align-items: start; }
.settings-nav { position: sticky; top: 16px; display: grid; gap: 10px; padding: 16px; }
.settings-title { margin: 0; font-size: 18px; font-weight: 700; }
.settings-nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.settings-nav a { display: block; padding: 9px 12px; border-radius: 10px; color: inherit; text-decoration: none; }
.settings-nav a:hover { background: color-mix(in srgb, currentColor 8%, transparent); }
.settings-nav a[aria-current="page"] { background: var(--chip-bg); color: var(--chip-fg); font-weight: 600; }
.settings-out { margin: 4px 0 0; font-size: 14px; }
.settings-out a { padding: 6px 12px; color: var(--muted); }
.settings-body { min-width: 0; }
@media (max-width: 760px) {
  .settings-shell { grid-template-columns: 1fr; gap: 12px; }
  .settings-nav { position: static; padding: 12px; }
  .settings-nav ul { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
  .settings-nav a { white-space: nowrap; border: 1px solid var(--line); }
  .settings-nav ul { position: relative; }
  .settings-out a { border: 0; padding-left: 4px; }
}

/* The owner's Sign out button in the top bar is a one-button form: it sits in line with the links beside it. */
body.glass .topbar form.sign-out { margin: 0; display: flex; align-items: center; }
