/* Voice Me — one page: first screen with the live mascot, ticker, voices with filters, pricing.
   Night (default) and day themes share one set of tokens. Type steps follow the Tailwind scale;
   spacing uses 2/4/8/12/16/24/32/40/48/64/80/96 only. */

:root {
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  /* Fonts from the references: Wix Madefor Display (superconscious wordmark), Geist (cryptomannn). */
  --font-display: "Wix Madefor Display", "Geist", system-ui, sans-serif;
  --font-body: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --maxw: 1120px;
  --gutter: 16px;
  color-scheme: dark;

  --bg: #000000;
  --surface: #181818;
  --raised: #1f1f1f;
  --line: #272727;
  --line-strong: #313131;
  --text: #ffffff;
  --muted: #9b9b9b;
  --ink: #ffffff;               /* mascot ink: the logo draws itself in this colour */
  --glass: rgba(24, 24, 24, 0.72);
  --btn-bg: #ffffff;
  --btn-text: #000000;
  --hero-text: linear-gradient(90deg, #ffffff, #9b9b9b);
  --chrome-edge: linear-gradient(160deg, #ffffff 0%, #5c5c5c 38%, #d4d4d4 62%, #3a3a3a 100%);
  --glow: rgba(255, 255, 255, 0.10);
  --grain-opacity: 0.07;
  --star: 255, 255, 255;
  --wave: #3a3a3a;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #f4f4f5;
  --raised: #ededee;
  --line: #e4e4e7;
  --line-strong: #d4d4d8;
  --text: #0a0a0a;
  --muted: #666666;
  --ink: #0d0d0f;
  --glass: rgba(255, 255, 255, 0.72);
  --btn-bg: #0a0a0a;
  --btn-text: #ffffff;
  --hero-text: linear-gradient(90deg, #000000, #666666);
  --chrome-edge: linear-gradient(160deg, #0a0a0a 0%, #b5b5b5 38%, #3d3d3d 62%, #d9d9d9 100%);
  --glow: rgba(0, 0, 0, 0.06);
  --grain-opacity: 0.05;
  --star: 10, 10, 10;
  --wave: #cfcfd3;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 24px;
  overflow-x: hidden;
  transition: background-color 300ms var(--ease), color 300ms var(--ease);
}
body::after {                  /* film grain over everything */
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5 0 0 0 0 .5 0 0 0 0 .5 0 0 0 1 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
img, svg { display: block; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip {
  position: absolute; left: 16px; top: -64px; z-index: 100;
  padding: 8px 12px; border-radius: 8px;
  background: var(--btn-bg); color: var(--btn-text); font-weight: 600; text-decoration: none;
}
.skip:focus { top: 16px; }
:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; border-radius: 8px; }

#stars { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.wrap { position: relative; z-index: 1; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.mascot svg { width: 100%; height: 100%; }

/* ── Navigation: a compact pill floating off the top edge ─────────────────────────────── */
.nav {
  position: fixed; top: 16px; left: 50%; z-index: 50;
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 16px;
  padding: 8px 8px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 9999px;
  background: var(--glass);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  max-width: calc(100vw - 32px);
  transition: background-color 300ms var(--ease), border-color 300ms var(--ease);
}
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; }
.brand .mark { width: 24px; height: 24px; color: var(--ink); }
.brand-word { font-family: var(--font-display); font-weight: 600; font-size: 14px; line-height: 20px; letter-spacing: 0.01em; }
.nav-links { display: flex; gap: 4px; }
.nav-links a {
  font-size: 14px; line-height: 20px; font-weight: 500; text-decoration: none; color: var(--muted);
  padding: 8px 12px; border-radius: 9999px;
  transition: color 300ms var(--ease), background-color 300ms var(--ease);
}
.nav-links a:hover, .nav-links a[aria-current="true"] { color: var(--text); background: var(--raised); }
.nav-tools { display: flex; align-items: center; gap: 8px; }

.seg { display: flex; padding: 2px; border-radius: 9999px; background: var(--raised); border: 1px solid var(--line); }
.seg button {
  border: 0; background: transparent; cursor: pointer;
  font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 500;
  padding: 4px 8px; border-radius: 9999px; color: var(--muted);
  transition: color 300ms var(--ease), background-color 300ms var(--ease);
}
.seg button:hover { color: var(--text); }
.seg button[aria-pressed="true"] { background: var(--btn-bg); color: var(--btn-text); }
.seg-lg button { font-family: var(--font-body); font-size: 14px; line-height: 20px; padding: 8px 12px; }

.icon-btn {
  display: grid; place-items: center; width: 32px; height: 32px; padding: 0;
  border: 1px solid var(--line); border-radius: 9999px; background: var(--raised); cursor: pointer;
  transition: background-color 300ms var(--ease), transform 300ms var(--ease);
}
.icon-btn:hover { background: var(--line); }
.icon-btn:active { transform: scale(0.96); }
.icon-btn svg { width: 16px; height: 16px; }
.theme-icon { position: relative; width: 16px; height: 16px; }
.theme-icon svg { position: absolute; inset: 0; transition: transform 500ms var(--ease), opacity 300ms var(--ease); }
:root[data-theme="light"] .i-sun, :root:not([data-theme="light"]) .i-moon { opacity: 0; transform: rotate(-90deg) scale(0.6); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 8px 12px; border: 0; border-radius: 9999px; cursor: pointer;
  background: var(--btn-bg); color: var(--btn-text);
  font-size: 16px; line-height: 24px; font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: transform 300ms var(--ease), opacity 300ms var(--ease), background-color 300ms var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }
.btn-sm { font-size: 14px; line-height: 20px; padding: 4px 12px; }
.btn-ghost { background: transparent; color: var(--text); border: 1px solid var(--line-strong); }
.btn-ghost:hover { background: var(--raised); }

.menu-btn { display: none; position: relative; }
.menu-btn span { position: absolute; left: 9px; width: 14px; height: 2px; border-radius: 2px; background: currentColor;
                 transition: transform 500ms var(--ease); }
.menu-btn span:first-child { transform: translateY(-3px); }
.menu-btn span:last-child { transform: translateY(3px); }
.menu-open .menu-btn span:first-child { transform: rotate(45deg); }
.menu-open .menu-btn span:last-child { transform: rotate(-45deg); }

.mobile-panel {
  position: fixed; inset: 0; z-index: 40;
  display: flex; flex-direction: column; justify-content: center; gap: 24px;
  padding: 96px 24px 48px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px);
  opacity: 0; pointer-events: none; transition: opacity 500ms var(--ease);
}
.menu-open .mobile-panel { opacity: 1; pointer-events: auto; }
.mobile-panel > * { opacity: 0; transform: translateY(24px); transition: opacity 500ms var(--ease), transform 500ms var(--ease); }
.menu-open .mobile-panel > * { opacity: 1; transform: none; }
.mobile-panel a.big { font-family: var(--font-display); font-weight: 600; font-size: 36px; line-height: 40px; text-decoration: none; }
.mobile-panel .row { display: flex; gap: 12px; align-items: center; }

/* ── First screen: live mascot left, the name right, the ticker along the bottom ──────── */
.hero { position: relative; display: flex; flex-direction: column; }
.hero-in {
  flex: 1; width: 100%;
  display: flex; align-items: center; justify-content: center; gap: 48px;
  padding-top: 96px; padding-bottom: 48px;
}
.hero .mascot { flex: none; width: 280px; height: 280px; color: var(--ink); }
.hero-word h1 {
  font-family: var(--font-display); font-weight: 600;
  font-size: 96px; line-height: 1; letter-spacing: -0.035em;
  background: var(--hero-text); -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-bottom: 8px; white-space: nowrap;
}
.hero-cap {
  margin-top: 16px; padding-left: 4px;
  font-family: var(--font-mono); font-weight: 400; font-size: 20px; line-height: 28px;
  letter-spacing: 0.32em; text-transform: uppercase; color: var(--muted);
}

/* Ticker: one black and white line, sliding right to left like subtitles */
.ticker {
  position: relative; z-index: 1; overflow: hidden;
  background: var(--btn-bg); color: var(--btn-text);
  border-block: 1px solid var(--line);
}
.ticker-track { display: flex; width: max-content; animation: ticker 70s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-group { display: flex; flex: none; align-items: center; }
.ticker-item {
  display: flex; align-items: center; gap: 16px; padding: 12px 0 12px 16px; white-space: nowrap;
  font-family: var(--font-mono); font-size: 14px; line-height: 20px; letter-spacing: 0.04em;
}
.ticker-item b { font-weight: 500; }
.ticker-item i { width: 4px; height: 4px; border-radius: 9999px; background: currentColor; opacity: 0.45; display: block; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ── Sections ─────────────────────────────────────────────────────────────────────────── */
section { scroll-margin-top: 96px; }
.block { padding: 96px var(--gutter); }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 32px; }
.sec-head h2 { font-family: var(--font-display); font-weight: 600; font-size: 48px; line-height: 1; letter-spacing: -0.02em; }
.count { color: var(--muted); font-family: var(--font-mono); font-size: 14px; line-height: 20px; }

/* Voices: filters, then plain rows — pick a voice, press play */
.filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 16px; }
.field { position: relative; display: flex; }
.field.grow { flex: 1 1 200px; }
.field select, .field input {
  appearance: none; -webkit-appearance: none;
  height: 40px; padding: 8px 16px; border-radius: 9999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 14px; line-height: 20px; color: var(--text);
  transition: border-color 300ms var(--ease);
}
.field select { padding-right: 40px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%239b9b9b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; background-size: 16px; }
.field input { width: 100%; }
.field input::placeholder { color: var(--muted); }
.field select:hover, .field input:hover { border-color: var(--line-strong); }
.field select:focus-visible, .field input:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; }
.seg-lg { height: 40px; align-items: center; }

.vlist { border: 1px solid var(--line); border-radius: 24px; background: var(--surface); overflow: hidden; }
.vrow {
  display: grid; grid-template-columns: 40px minmax(160px, 240px) 1fr 56px; align-items: center; gap: 16px;
  padding: 12px 16px; transition: background-color 300ms var(--ease);
}
.vrow + .vrow { box-shadow: inset 0 1px 0 var(--line); }
.vrow:hover { background: var(--raised); }
.vrow.is-playing { background: var(--raised); }
.vmeta b { display: block; font-size: 16px; line-height: 24px; font-weight: 600; }
.vmeta span { display: block; color: var(--muted); font-size: 12px; line-height: 16px; }
.play {
  position: relative; display: grid; place-items: center; width: 40px; height: 40px; padding: 0;
  border: 0; border-radius: 9999px; background: var(--btn-bg); color: var(--btn-text); cursor: pointer;
  transition: transform 300ms var(--ease), opacity 300ms var(--ease);
}
.play:hover { transform: scale(1.06); }
.play:active { transform: scale(0.96); }
.play svg { width: 16px; height: 16px; position: absolute; }
.play .i-pause, .is-playing .play .i-play { display: none; }
.is-playing .play .i-pause { display: block; }
.play[aria-disabled="true"] { opacity: 0.35; cursor: not-allowed; transform: none; }
.is-loading .play { opacity: 0.6; }
.track { position: relative; height: 32px; cursor: pointer; }
.track svg { width: 100%; height: 100%; }
.track .wave rect { fill: var(--wave); }
.track .done rect { fill: var(--text); }
.track .done { clip-path: inset(0 100% 0 0); }
.track[aria-disabled="true"] { cursor: default; }
.dur { text-align: right; color: var(--muted); font-family: var(--font-mono); font-size: 12px; line-height: 16px; }
.vnote { grid-column: 2 / -1; color: var(--muted); font-size: 12px; line-height: 16px; margin-top: -8px; }
.vnote:empty { display: none; }
.empty { padding: 48px 16px; text-align: center; color: var(--muted); border: 1px solid var(--line); border-radius: 24px; }
.empty p { margin-bottom: 16px; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: stretch; }
.plan {
  position: relative; display: flex; flex-direction: column; gap: 24px; padding: 32px 24px 24px;
  border: 1px solid var(--line); border-radius: 24px; background: var(--surface);
  transition: border-color 300ms var(--ease);
}
.plan:hover { border-color: var(--line-strong); }
.plan.featured {
  border: 1px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--chrome-edge) border-box;
}
.tag { font-family: var(--font-mono); font-size: 12px; line-height: 16px; color: var(--muted);
       padding: 4px 8px; border: 1px solid var(--line); border-radius: 9999px; white-space: nowrap; }
.plan .badge { position: absolute; top: 16px; right: 16px; }
.plan h3 { font-family: var(--font-mono); font-weight: 500; font-size: 14px; line-height: 20px; letter-spacing: 0.08em;
           text-transform: uppercase; color: var(--muted); }
.price { display: flex; align-items: baseline; gap: 8px; }
.price b { font-family: var(--font-display); font-weight: 600; font-size: 48px; line-height: 1; letter-spacing: -0.02em; }
.price span { color: var(--muted); font-size: 14px; line-height: 20px; }
.chars b { display: block; font-family: var(--font-mono); font-weight: 500; font-size: 20px; line-height: 28px; }
.chars span { display: block; color: var(--muted); font-size: 14px; line-height: 20px; }
.per { display: flex; justify-content: space-between; gap: 12px; padding-top: 16px; box-shadow: inset 0 1px 0 var(--line);
       font-size: 14px; line-height: 20px; color: var(--muted); }
.per em { font-style: normal; color: var(--text); font-family: var(--font-mono); font-size: 12px; line-height: 20px; }
.plan .btn { margin-top: auto; width: 100%; }
.plan:not(.featured) .btn { background: transparent; color: var(--text); border: 1px solid var(--line-strong); }
.plan:not(.featured) .btn:hover { background: var(--raised); }
.plan .note { color: var(--muted); font-size: 12px; line-height: 16px; min-height: 16px; margin-top: -12px; }
.includes {
  margin-top: 16px; padding: 24px; border: 1px solid var(--line); border-radius: 24px;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 32px; color: var(--muted);
  font-size: 14px; line-height: 20px;
}
.includes ul { list-style: none; margin: 0; padding: 0; display: contents; }
.includes li { display: flex; align-items: center; gap: 8px; }
.includes svg { width: 16px; height: 16px; color: var(--text); }

footer { position: relative; z-index: 1; padding-bottom: 32px; }
.foot-row { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
            padding-top: 24px; box-shadow: inset 0 1px 0 var(--line); color: var(--muted); font-size: 14px; line-height: 20px; }

@media (max-width: 960px) {
  .hero .mascot { width: 224px; height: 224px; }
  .hero-word h1 { font-size: 72px; }
  .plans { grid-template-columns: repeat(2, 1fr); }
  .plans .plan:last-child { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .nav { gap: 8px; }
  .nav-links, .nav .seg, .nav .theme-toggle { display: none; }
  .menu-btn { display: grid; }
  .hero-in { flex-direction: column; gap: 16px; text-align: center; padding-top: 96px; padding-bottom: 32px; }
  .hero .mascot { width: 192px; height: 192px; }
  .hero-word h1 { font-size: 48px; }
  .hero-cap { font-size: 14px; line-height: 20px; margin-top: 12px; padding-left: 0.32em; }
  .block { padding: 64px var(--gutter); }
  .sec-head h2 { font-size: 36px; line-height: 40px; }
  .filters .field:first-child, .seg-lg { flex: 1 1 auto; }
  .seg-lg button { flex: 1; }
  .field select { width: 100%; }
  .vrow { grid-template-columns: 40px 1fr 48px; gap: 12px; }
  .vrow .track { grid-column: 2 / -1; grid-row: 2; margin-top: -4px; }
  .vnote { grid-row: 3; }
  .plans { grid-template-columns: 1fr; }
  .plans .plan:last-child { grid-column: auto; }
  .includes { justify-content: flex-start; gap: 12px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker-track { animation: none; }
  .ticker { overflow-x: auto; }
  .mobile-panel > * { transform: none; }
}
