/* Twain website.
   Colours follow the app (lib/app_theme.dart): white, ink and the indigo primary.
   The phones are drawn in HTML after the app's screens, so they stay sharp and
   translate with the page. Light only, like the app. No web fonts: the system's
   faces read best in every one of the ten languages. */

:root {
  --bg: #ffffff;
  --bg-2: #f6f7fc;
  --panel: #ffffff;
  --line: #e4e7f2;
  --line-soft: #eef0f7;
  --ink: #1b1f33;
  --ink-2: #4c5269;
  --ink-3: #6b7187;
  --accent: #4a5bd4;
  --accent-strong: #3445bd;
  --accent-soft: #e3e7fb;
  --accent-wash: #f0f2fd;
  --on-accent: #ffffff;
  --their-bubble: #f1f3f8;
  --note: #f5f6fa;
  --c1: #d9480f;
  --c2: #2b8a3e;
  --radius-s: 8px;
  --radius-m: 16px;
  --radius-l: 24px;
  --shadow-card: 0 1px 2px rgba(27, 31, 51, .05), 0 20px 44px -24px rgba(40, 52, 140, .32);
  --shadow-phone: 0 1px 2px rgba(27, 31, 51, .1), 0 36px 64px -28px rgba(40, 52, 140, .45);
  --header-h: 60px;
  --font-latin: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  --font-sans: var(--font-latin), "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --lh: 1.6;
  color-scheme: light;
}

:lang(zh-Hant) { --font-sans: var(--font-latin), "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif; --lh: 1.85; }
:lang(ja) { --font-sans: var(--font-latin), "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", Meiryo, sans-serif; --lh: 1.85; }
:lang(ko) { --font-sans: var(--font-latin), "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif; --lh: 1.8; }
:lang(th) { --font-sans: var(--font-latin), "Thonburi", "Noto Sans Thai", "Leelawadee UI", Tahoma, sans-serif; --lh: 1.9; }
:lang(vi) { --lh: 1.8; }

*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + env(safe-area-inset-top, 0px) + 12px);
}
html, [lang] { font-family: var(--font-sans); }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-size: 1rem;
  line-height: var(--lh);
  background:
    radial-gradient(1100px 620px at 85% -120px, rgba(74, 91, 212, .13), rgba(74, 91, 212, 0) 70%),
    radial-gradient(800px 500px at -10% 180px, rgba(74, 91, 212, .07), rgba(74, 91, 212, 0) 70%),
    var(--bg);
  background-repeat: no-repeat;
  overflow-x: hidden;
}
.i18n-pending body { visibility: hidden; }
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  z-index: 60;
  height: env(safe-area-inset-top, 0px);
  background: var(--bg);
}

img { max-width: 100%; }
a { color: var(--accent); text-underline-offset: .18em; }
a:hover { color: var(--accent-strong); }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
/* Sections an in-page link moved focus to (site.js) */
[tabindex="-1"]:focus { outline: none; }
::selection { background: rgba(74, 91, 212, .2); }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon {
  width: 24px;
  height: 24px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon-small { width: 16px; height: 16px; }
.icon-tiny { width: 11px; height: 11px; vertical-align: -1px; }

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

.skip {
  position: fixed;
  left: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.display {
  font-weight: 700;
  letter-spacing: -.01em;
  line-height: 1.3;
  text-wrap: balance;
}
:lang(zh-Hant) .display, :lang(ja) .display { letter-spacing: .01em; line-height: 1.4; }
.wordmark { font-family: var(--font-latin), sans-serif; font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }

/* -- header ------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 50;
  height: var(--header-h);
  background: rgba(255, 255, 255, .72);
  -webkit-backdrop-filter: saturate(1.4) blur(16px);
  backdrop-filter: saturate(1.4) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s, background-color .25s;
}
.site-header.is-scrolled { background: rgba(255, 255, 255, .9); border-bottom-color: var(--line); }
.header-row { height: 100%; display: flex; align-items: center; gap: 16px; }

.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--accent); }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.brand .wordmark { font-size: 1.125rem; }

.header-nav { display: none; gap: 2px; }
.header-nav a {
  padding: 6px 12px;
  border-radius: 999px;
  color: var(--ink-2);
  font-size: .9375rem;
  text-decoration: none;
  white-space: nowrap;
}
.header-nav a:hover { color: var(--ink); background: var(--accent-wash); }
.header-end { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .2s;
}
.btn:hover { background: var(--accent-strong); color: var(--on-accent); }
.btn-small { min-height: 36px; padding: 0 16px; font-size: .9375rem; }

.back-link {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink-2);
  text-decoration: none;
  font-size: .9375rem;
}
.back-link .icon { width: 18px; height: 18px; transform: scaleX(-1); }
.back-link:hover { color: var(--accent); }

@media (min-width: 860px) {
  .header-nav { display: flex; margin-left: 12px; }
}

.lang { position: relative; }
.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 10px 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .8);
  color: var(--ink-2);
  font: inherit;
  font-size: .9375rem;
  cursor: pointer;
}
.lang-toggle:hover, .lang-toggle[aria-expanded="true"] { color: var(--ink); border-color: #c5cbe6; }
.lang-toggle .icon:first-child { width: 18px; height: 18px; }
.lang-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 60;
  display: grid;
  min-width: 200px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-card);
}
.lang-menu[hidden] { display: none; }
.lang-menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--ink);
  font: inherit;
  font-size: .9375rem;
  text-align: left;
  cursor: pointer;
}
.lang-menu button:hover, .lang-menu button:focus-visible { background: var(--accent-wash); }
.lang-menu button[aria-pressed="true"] { color: var(--accent); font-weight: 600; }
.lang-menu button[aria-pressed="true"]::after {
  content: "";
  width: 6px;
  height: 11px;
  margin-right: 4px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
}
/* On narrow screens the toggle shows only the globe. */
@media (max-width: 520px) {
  .lang-current { display: none; }
  .lang-toggle { padding: 0 8px 0 10px; }
}

/* -- sections ----------------------------------------------------------- */

section { padding: 72px 0; }
.section-head { max-width: 640px; margin: 0 auto 40px; text-align: center; }
.section-head h2 { margin: 0 0 12px; font-size: clamp(1.75rem, 4.4vw, 2.5rem); }
.section-head p { margin: 0; color: var(--ink-2); }
.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: .8125rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

/* -- hero --------------------------------------------------------------- */

.hero { padding: 40px 0 64px; }
.hero-grid { display: grid; gap: 48px; align-items: center; }
.kicker { display: flex; align-items: center; gap: 10px; margin: 0 0 18px; color: var(--accent); font-weight: 600; }
.kicker-dot { width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: .6; }
.hero-title { margin: 0 0 20px; font-size: clamp(2.25rem, 7.4vw, 3.75rem); }
/* Latin, Thai and Vietnamese titles run longer than the CJK ones. */
:root:not(:lang(zh)):not(:lang(ja)):not(:lang(ko)) .hero-title { font-size: clamp(2.125rem, 5.8vw, 3.25rem); }
.lead { margin: 0 0 28px; color: var(--ink-2); font-size: 1.125rem; max-width: 34em; }
.hero-note { margin: 16px 0 0; color: var(--ink-3); font-size: .9375rem; }

.stores { display: flex; flex-wrap: wrap; gap: 12px; }
.store-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 0 20px 0 16px;
  border-radius: 14px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
}
.store-btn:hover { background: #2c3250; color: #fff; }
.store-btn.is-soon { background: var(--panel); color: var(--ink); border: 1px solid var(--line); cursor: default; }
.store-btn.is-soon small { color: var(--accent); font-weight: 600; }
.store-text { display: flex; flex-direction: column; line-height: 1.2; }
.store-text small { font-size: .75rem; opacity: .85; }
.store-name { font-size: 1.0625rem; font-weight: 600; }

.hero-art { position: relative; display: flex; justify-content: center; padding: 8px 0 24px; }
.hero-bubble {
  position: absolute;
  right: max(0px, calc(50% - 230px));
  top: 26%;
  margin: 0;
  padding: 10px 16px;
  border-radius: 18px 18px 4px 18px;
  background: var(--panel);
  box-shadow: var(--shadow-card);
  font-size: .9375rem;
  font-weight: 600;
  transform: rotate(3deg);
}

@media (min-width: 900px) {
  .hero { padding: 64px 0 88px; }
  .hero-grid { grid-template-columns: 1.05fr .95fr; }
  .hero-bubble { right: 0; }
}
@media (max-width: 520px) {
  .hero-bubble { display: none; }
}

/* -- the phones (drawn after the app's screens) -------------------------- */

.phone {
  --w: 290px;
  position: relative;
  width: var(--w);
  aspect-ratio: 9 / 19;
  margin: 0;
  padding: 10px;
  border-radius: 44px;
  background: #11142a;
  box-shadow: var(--shadow-phone);
  flex: none;
}
.phone::before {
  content: "";
  position: absolute;
  top: 19px;
  left: 50%;
  width: 72px;
  height: 20px;
  margin-left: -36px;
  border-radius: 999px;
  background: #11142a;
  z-index: 2;
}
.screen {
  position: relative;
  height: 100%;
  overflow: hidden;
  border-radius: 34px;
  background: #fff;
  display: flex;
  flex-direction: column;
  font-size: 13px;
  line-height: 1.45;
  padding: 44px 16px 16px;
}
.app-bar { display: flex; align-items: center; justify-content: space-between; color: var(--ink); }
.app-bar > .icon { width: 20px; height: 20px; }
.lang-pair {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-weight: 600;
  font-size: 14px;
}
.lang-pair .icon { color: var(--ink-3); }
.auto-play {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--ink-3);
  background: var(--note);
}
.big-area { flex: 1; display: flex; align-items: center; min-height: 0; }
.big {
  margin: 0;
  font-size: 30px;
  line-height: 1.25;
  font-weight: 600;
  letter-spacing: 0;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.panel-actions { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink-2);
  font-size: 12px;
}
.round {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
}
.divider { width: 100%; margin: 10px 0; border: 0; border-top: 1px solid var(--line); }
.source { margin: 0; color: var(--ink-2); font-size: 14px; }
.talk-bar { display: flex; gap: 8px; margin-top: 18px; }
.their-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 52px;
  border-radius: 26px;
  background: var(--ink);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
}
.their-btn .icon { width: 20px; height: 20px; }
.their-btn.is-pressed { box-shadow: 0 0 0 5px rgba(27, 31, 51, .14); }
.my-btn {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  flex: none;
}
.my-btn .icon { width: 20px; height: 20px; }

/* Landscape: the same layout, turned to show it reads either way. */
.phone-landscape { --w: 540px; aspect-ratio: 19 / 9; padding: 10px; border-radius: 40px; }
.phone-landscape::before { top: 50%; left: 19px; width: 20px; height: 64px; margin: -32px 0 0; }
.phone-landscape .screen { border-radius: 30px; padding: 14px 22px 14px 50px; }
.phone-landscape .big { font-size: 28px; }

/* The room. */
.room { padding: 44px 0 0; background: #fff; }
.room-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 0 12px 10px; border-bottom: 1px solid var(--line-soft); }
.room-leave { color: var(--ink-2); font-size: 12px; }
.room-title { display: flex; flex-direction: column; align-items: center; text-align: center; }
.room-title strong { font-size: 13.5px; }
.room-title small { color: var(--ink-3); font-size: 10.5px; white-space: nowrap; }
.room-title .online { color: var(--c2); }
.room-lines { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 12px; overflow: hidden; }
.note { align-self: center; margin: 0; padding: 2px 10px; border-radius: 999px; background: var(--note); color: var(--ink-3); font-size: 11px; }
.bubble { max-width: 82%; padding: 7px 12px; border-radius: 16px; font-size: 13px; }
.bubble.theirs { align-self: flex-start; background: var(--their-bubble); border-top-left-radius: 4px; }
.bubble.mine { align-self: flex-end; background: var(--accent); color: var(--on-accent); border-top-right-radius: 4px; }
.who { display: block; font-size: 11px; }
.c1 { color: var(--c1); }
.c2 { color: var(--c2); }
.room-talk { display: flex; align-items: center; gap: 8px; padding: 10px 12px 16px; border-top: 1px solid var(--line-soft); }
.my-lang { flex: 1; display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); font-size: 13px; }
.room-talk .my-btn { width: 42px; height: 42px; }

/* -- tone --------------------------------------------------------------- */

.tone { background: var(--bg-2); }
.tone-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 24px;
  border-radius: var(--radius-l);
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-card);
}
.tone-controls { display: grid; gap: 16px; }
.tone-field { display: flex; align-items: center; gap: 12px; }
.tone-field label { color: var(--ink-2); font-weight: 600; }
.tone-field select {
  min-height: 44px;
  padding: 0 40px 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234c5269' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6.5 9.5 5.5 5.5 5.5-5.5'/%3E%3C/svg%3E") right 12px center / 18px no-repeat;
  color: var(--ink);
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
}
.tone-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tone-tabs button {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-height: 64px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color .2s, background-color .2s;
}
.tone-tabs button small { color: var(--ink-3); font-size: .8125rem; line-height: 1.35; }
.tone-tabs button:hover { border-color: #c5cbe6; }
.tone-tabs button[aria-checked="true"] { border-color: var(--accent); background: var(--accent-wash); box-shadow: inset 0 0 0 1px var(--accent); }
.tone-tabs button[aria-checked="true"] strong { color: var(--accent); }
.tone-stage {
  margin-top: 20px;
  padding: 28px 20px;
  border-radius: var(--radius-m);
  background: var(--bg-2);
  text-align: center;
}
.tone-source { margin: 0 0 8px; color: var(--ink-3); font-size: .9375rem; }
.tone-result { margin: 0; min-height: 2.6em; display: grid; place-items: center; font-size: clamp(1.5rem, 5vw, 2.25rem); transition: opacity .18s; }
.tone-result.is-changing { opacity: 0; }
.tone-note { margin: 16px 0 0; color: var(--ink-3); font-size: .875rem; text-align: center; }

@media (min-width: 720px) {
  .tone-card { padding: 32px; }
  .tone-controls { grid-template-columns: auto 1fr; align-items: center; gap: 24px; }
}

/* -- features ----------------------------------------------------------- */

.feature { display: grid; gap: 32px; align-items: center; padding: 40px 0; }
.feature + .feature { border-top: 1px solid var(--line-soft); }
.feature-no { margin: 0 0 8px; color: var(--accent); font-weight: 700; font-variant-numeric: tabular-nums; }
.feature h3 { margin: 0 0 14px; font-size: clamp(1.5rem, 3.6vw, 2rem); }
.feature-copy p:last-child { margin: 0; color: var(--ink-2); max-width: 30em; }
.feature-art { display: flex; justify-content: center; }

/* Taking turns (site.js): the feature leaving fades out; then the next one's number fades
   in, its title types itself out and the text below follows, and its phone fades in,
   rising a little. */
.feature-track { --stage-pad: 24px; --stage-gap: 20px; }
.feature-track.is-animated .feature-copy > * { transition: opacity .5s ease .3s; }
.feature-track.is-animated .feature-art { transition: opacity .9s ease .3s, transform .9s cubic-bezier(.2, .7, .2, 1) .3s; }
.feature-track.is-animated .feature:not(.is-active) .feature-copy > *,
.feature-track.is-animated .feature:not(.is-active) .feature-art { opacity: 0; transition: opacity .35s ease, transform 0s .35s; }
.feature-track.is-animated .feature:not(.is-active) .feature-art { transform: translateY(40px); }
.feature-track.is-animated .feature-copy.is-typing > p:last-child { opacity: 0; }
.feature-track.is-animated .feature-copy.is-typing > h3 { transition: none; }

/* Pinned: the stage stays below the header while the page scrolls one step per feature. */
.feature-track.is-pinned {
  height: calc(100vh - var(--header-h) + var(--count, 3) * 70vh);
  height: calc(100svh - var(--header-h) + var(--count, 3) * 70svh);
}
.feature-track.is-pinned .feature-stage {
  position: sticky;
  top: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  height: calc(100vh - var(--header-h));
  height: calc(100svh - var(--header-h) - env(safe-area-inset-top, 0px));
  display: grid;
  grid-template: minmax(0, 1fr) / minmax(0, 1fr);
}
.feature-track.is-pinned .feature {
  grid-area: 1 / 1;
  align-content: center;
  gap: var(--stage-gap);
  padding: var(--stage-pad) 0;
  border-top: 0;
}
.feature-track.is-pinned .feature:not(.is-active) { pointer-events: none; }
@media (min-width: 900px) {
  .feature-track.is-pinned .feature { gap: 64px; }
}

.tw-char { opacity: 0; }
.tw-char.is-on { opacity: 1; }
.tw-char.is-caret { position: relative; }
.tw-char.is-caret::after {
  content: "";
  position: absolute;
  top: .12em;
  bottom: .06em;
  right: -.14em;
  width: 2px;
  border-radius: 1px;
  background: var(--accent);
  animation: tw-blink 1s steps(1) infinite;
}
@keyframes tw-blink { 50% { opacity: 0; } }

@media (min-width: 900px) {
  .feature { grid-template-columns: 1fr 1fr; gap: 64px; padding: 56px 0; }
  .feature.is-flipped .feature-copy { order: 2; }
}
@media (max-width: 620px) {
  .phone-landscape { --w: calc(100vw - 32px); padding: 7px; border-radius: 30px; }
  .phone-landscape::before { left: 12px; width: 14px; height: 44px; margin-top: -22px; }
  .phone-landscape .screen { border-radius: 23px; padding: 8px 12px 8px 34px; font-size: 11px; }
  .phone-landscape .app-bar > .icon { width: 16px; height: 16px; }
  .phone-landscape .lang-pair { font-size: 12px; }
  .phone-landscape .auto-play, .phone-landscape .round { width: 24px; height: 24px; }
  .phone-landscape .panel-actions { margin-top: 2px; }
  .phone-landscape .divider { margin: 4px 0; }
  .phone-landscape .source { font-size: 11.5px; }
  .phone-landscape .big { font-size: 18px; }
}

.more-title { margin: 56px 0 24px; text-align: center; font-size: 1.375rem; }
.more {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.more li { padding: 22px; border-radius: var(--radius-m); background: var(--bg-2); }
.more .icon { color: var(--accent); }
.more h4 { margin: 10px 0 6px; font-size: 1.0625rem; }
.more p { margin: 0; color: var(--ink-2); font-size: .9375rem; }
@media (min-width: 600px) { .more { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .more { grid-template-columns: repeat(3, 1fr); } }

/* -- privacy ------------------------------------------------------------ */

.privacy-card {
  max-width: 880px;
  margin: 0 auto;
  padding: 36px 24px;
  border-radius: var(--radius-l);
  background: linear-gradient(160deg, #283078, #1b1f33);
  color: #fff;
  text-align: center;
}
.privacy-card .eyebrow { color: #aab4ff; }
.privacy-card h2 { margin: 0 0 16px; font-size: clamp(1.625rem, 4.2vw, 2.25rem); }
.privacy-text { max-width: 36em; margin: 0 auto 24px; color: rgba(255, 255, 255, .82); }
.promises { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 0 20px; padding: 0; list-style: none; }
.promises li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .1);
  font-size: .9375rem;
}
.promises .icon { width: 18px; height: 18px; color: #aab4ff; }
.privacy-small { max-width: 36em; margin: 0 auto 20px; color: rgba(255, 255, 255, .66); font-size: .875rem; }
.text-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; }
.text-link .icon { width: 18px; height: 18px; }
.privacy-card .text-link { color: #fff; }
.privacy-card .text-link:hover { color: #d4d9ff; }

@media (min-width: 720px) { .privacy-card { padding: 56px 48px; } }

/* -- faq ---------------------------------------------------------------- */

.faq-list { max-width: 760px; margin: 0 auto; }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary {
  position: relative;
  padding: 18px 40px 18px 0;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -7px;
  border-right: 1.8px solid var(--ink-3);
  border-bottom: 1.8px solid var(--ink-3);
  transform: rotate(45deg);
  transition: transform .2s;
}
.faq-list details[open] summary::after { transform: rotate(225deg); margin-top: -2px; }
.faq-list details p { margin: 0 0 20px; color: var(--ink-2); }

/* -- download ----------------------------------------------------------- */

.download { text-align: center; padding-bottom: 96px; }
.download-icon { width: 88px; height: 88px; border-radius: 22px; box-shadow: var(--shadow-card); }
.download h2 { margin: 20px 0 10px; font-size: clamp(1.75rem, 4.4vw, 2.5rem); }
.download p { margin: 0 0 28px; color: var(--ink-2); }
.download .stores { justify-content: center; }

/* -- footer ------------------------------------------------------------- */

.site-footer { padding: 32px 0 calc(32px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); background: var(--bg-2); }
.footer-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.footer-brand { display: inline-flex; align-items: center; gap: 8px; }
.footer-brand img { border-radius: 6px; }
.footer-copy { color: var(--ink-3); font-size: .875rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.footer-links a { color: var(--ink-2); font-size: .9375rem; text-decoration: none; }
.footer-links a:hover { color: var(--accent); }
.footer-note { width: 100%; margin: 0; color: var(--ink-3); font-size: .8125rem; }

.to-top {
  position: fixed;
  right: max(16px, env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 40;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: var(--ink-2);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .25s, transform .25s;
}
.to-top.is-shown { opacity: 1; pointer-events: auto; transform: none; }
.to-top .icon { width: 20px; height: 20px; }

/* -- privacy policy page ------------------------------------------------ */

.policy-tabs {
  position: sticky;
  top: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  z-index: 30;
  background: rgba(255, 255, 255, .92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.tabs-row { display: flex; gap: 4px; overflow-x: auto; padding: 8px 0; scrollbar-width: none; }
.tabs-row::-webkit-scrollbar { display: none; }
.tabs-row a {
  flex: none;
  padding: 6px 14px;
  border-radius: 999px;
  color: var(--ink-2);
  font-size: .9375rem;
  text-decoration: none;
  white-space: nowrap;
}
.tabs-row a:hover { background: var(--accent-wash); color: var(--ink); }
.tabs-row a[aria-selected="true"] { background: var(--accent); color: var(--on-accent); }

.policy-body { max-width: 760px; padding-top: 40px; padding-bottom: 80px; }
.policy-body section[hidden] { display: none; }
.policy-body h1 { margin: 0 0 8px; font-size: clamp(1.75rem, 4.4vw, 2.25rem); line-height: 1.3; }
.policy-body .date { margin: 0 0 24px; color: var(--ink-3); font-size: .9375rem; }
.policy-body h2 { margin: 40px 0 10px; font-size: 1.25rem; }
.policy-body p, .policy-body li { color: var(--ink-2); }
.policy-body strong { color: var(--ink); }
.policy-body ul { padding-left: 1.3em; }
.policy-body li + li { margin-top: 6px; }
.policy-body .summary {
  margin: 0 0 8px;
  padding: 18px 20px;
  border-radius: var(--radius-m);
  background: var(--accent-wash);
  color: var(--ink);
}

/* -- join page (join.html, the room invite) ---------------------------- */

.join { padding: 48px 0 80px; }
.join-card { max-width: 640px; text-align: center; }
.join-icon { width: 72px; height: 72px; border-radius: 18px; box-shadow: var(--shadow-card); }
.join .kicker { justify-content: center; margin: 20px 0 14px; }
.join-title { margin: 0 0 16px; font-size: clamp(1.75rem, 6vw, 2.5rem); }
.join-lead { margin: 0 auto 28px; }
.join-room { display: flex; flex-direction: column; align-items: center; gap: 2px; margin: 0 auto 28px; padding: 16px 32px; border-radius: var(--radius-m); background: var(--accent-wash); }
.join-room[hidden] { display: none; }
.join-room-label { color: var(--ink-2); font-size: .9375rem; }
.join-room-code { color: var(--accent-strong); font-family: var(--font-latin), sans-serif; font-size: 2.5rem; font-weight: 700; letter-spacing: .18em; line-height: 1.3; padding-left: .18em; font-variant-numeric: tabular-nums; }
.join-near { margin: 0 auto 28px; color: var(--ink); }
.join .stores { justify-content: center; }
.join-soon { margin: 16px 0 0; color: var(--ink-3); font-size: .9375rem; }
.join-more { margin: 32px 0 0; }
.join-safe { margin: 28px 0 0; color: var(--ink-3); font-size: .875rem; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
