/* Common Radius launch pages. Values from docs/design/prototypes/launch (Main, Signup, Privacy).
   Referenced as /assets/site.css?v=<ASSET_VERSION>: bump ASSET_VERSION in src/pages/layout.mts after editing,
   and keep the ?v= on the font url()s below equal to it. */

/* ---------- Fonts (self-hosted, Latin subset, SIL OFL: see fonts/OFL-*.txt) ---------- */
@font-face {
  font-family: 'Baloo 2';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/baloo-2-latin-700-normal.woff2?v=4) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/dm-sans-latin-400-normal.woff2?v=4) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/dm-sans-latin-500-normal.woff2?v=4) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens (renderVals() in the prototype) ---------- */
:root {
  color-scheme: light;
  --bg: #F4F4F5;
  --card: #FFFFFF;
  --field: #FFFFFF;
  --line: #E4E4E7;
  --ink: #1E1C1A;
  --muted: #52525B;
  --ring: #D4D4D8;
  --chip: #F4F4F5;
  --solid: #1E1C1A;
  --on-solid: #FFFFFF;
  --shadow: rgba(24, 24, 27, 0.06);
  --tile-edge: rgba(0, 0, 0, 0);
  --overlay: rgba(14, 14, 16, 0.44);
  --soon-bg: rgba(255, 255, 255, 0.45);
  --danger: #B42318;
  --danger-soft: #FEF3F2;
  --field-line: #D4D4D8;
  --website-tile: #1E1C1A;
  --display: 'Baloo 2', system-ui, sans-serif;
  --text: 'DM Sans', system-ui, sans-serif;
}
/* Dark: the saved choice (data-theme), else the system setting when the bootstrap could not run. */
:root[data-theme='dark'] {
  color-scheme: dark;
  --bg: #0E0E10;
  --card: #18181B;
  --field: #0E0E10;
  --line: #27272A;
  --ink: #F4F4F5;
  --muted: #A1A1AA;
  --ring: #3F3F46;
  --chip: #27272A;
  --solid: #F4F4F5;
  --on-solid: #0E0E10;
  --shadow: rgba(0, 0, 0, 0.35);
  --tile-edge: rgba(255, 255, 255, 0.14);
  --overlay: rgba(0, 0, 0, 0.62);
  --soon-bg: rgba(24, 24, 27, 0.45);
  --danger: #F97066;
  --danger-soft: rgba(249, 112, 102, 0.12);
  --field-line: #3F3F46;
  --website-tile: #F4F4F5;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --bg: #0E0E10;
    --card: #18181B;
    --field: #0E0E10;
    --line: #27272A;
    --ink: #F4F4F5;
    --muted: #A1A1AA;
    --ring: #3F3F46;
    --chip: #27272A;
    --solid: #F4F4F5;
    --on-solid: #0E0E10;
    --shadow: rgba(0, 0, 0, 0.35);
    --tile-edge: rgba(255, 255, 255, 0.14);
    --overlay: rgba(0, 0, 0, 0.62);
    --soon-bg: rgba(24, 24, 27, 0.45);
    --danger: #F97066;
    --danger-soft: rgba(249, 112, 102, 0.12);
    --field-line: #3F3F46;
    --website-tile: #F4F4F5;
  }
}

/* Theme-specific images: light copies by default, dark copies in dark mode. */
.only-dark { display: none !important; }
:root[data-theme='dark'] .only-light { display: none !important; }
:root[data-theme='dark'] .only-dark { display: block !important; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .only-light { display: none !important; }
  :root:not([data-theme]) .only-dark { display: block !important; }
}

/* Controls that need JavaScript (theme toggle, share) show only once the inline bootstrap has run. */
:root:not([data-theme]) .js-only { display: none !important; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--text);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img, svg { display: block; }
button { font: inherit; color: inherit; }
h1, h2, p { margin: 0; }

.page {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px 24px;
  padding-left: max(20px, env(safe-area-inset-left));
  padding-right: max(20px, env(safe-area-inset-right));
  padding-bottom: max(24px, env(safe-area-inset-bottom));
}
.column {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- Interaction ---------- */
.press {
  transition: transform 90ms ease, box-shadow 120ms ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
  .press:hover { box-shadow: 0 0 0 1.5px currentColor; }
  .press:hover .arrow { transform: translate(2px, -2px); }
  .press:hover .chevron { transform: translateX(2px); }
}
.press:active { transform: scale(0.975); }
.press:focus-visible { outline: 3px solid currentColor; outline-offset: 3px; }
.arrow, .chevron { transition: transform 120ms ease; }

/* Round icon buttons: theme toggle, share, close, back (44px); socials (48px). */
.round-btn {
  flex: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}
.round-btn-lg { width: 48px; height: 48px; }
.round-btn-chip { border: 0; background: var(--chip); }
.icon-sun { display: none; }
:root[data-theme='dark'] .icon-sun { display: block; }
:root[data-theme='dark'] .icon-moon { display: none; }

/* ---------- Brand header (links, signup) ---------- */
.hero {
  position: relative;
  width: 100%;
  height: 196px;
  display: flex;
  justify-content: center;
}
.header-start { position: absolute; top: 16px; left: 0; }
.header-end { position: absolute; top: 16px; right: 0; }
.hero-mark {
  position: absolute;
  top: 54px;
  width: 92px;
  height: 92px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 6px 20px var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero-mark-img { width: 44px; height: auto; }
.wordmark { margin-top: 4px; line-height: 0; }
.wordmark-img { width: 196px; height: auto; display: inline-block; }
.tagline {
  margin-top: 10px;
  font-size: 15px;
  line-height: 1.45;
  color: var(--muted);
  text-align: center;
}

/* ---------- Links page ---------- */
.group-label {
  align-self: stretch;
  margin: 28px 6px 8px;
  font-family: var(--text);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.4;
  color: var(--muted);
}
.group-label-touch { margin-top: 22px; }

.stores { width: 100%; display: flex; flex-direction: column; gap: 10px; }
.store {
  min-height: 68px;
  padding: 10px 12px 10px 10px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}
.store-live {
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 1px 2px var(--shadow);
  color: var(--ink);
}
.store-soon {
  padding-right: 16px;
  background: var(--soon-bg);
  border: 1px dashed var(--ring);
  color: var(--muted);
  cursor: default;
}
.store-tile {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 15px;
  overflow: hidden;
  background: #FFFFFF;
  box-shadow: inset 0 0 0 1px var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
}
.store-tile-website { background: var(--website-tile); box-shadow: none; }
.store-logo { width: 36px; height: 36px; object-fit: contain; }
.tile-mark { width: 24px; height: auto; }
.store-soon .store-tile { opacity: 0.55; }
.store-soon .store-logo { filter: grayscale(1); }
.store-text, .row-text {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.store-name {
  font-family: var(--display);
  font-weight: 700;
  font-size: 19px;
  line-height: 1.2;
}
.store-sub, .row-sub { font-size: 13px; line-height: 1.35; }
.store-live .store-sub, .row-sub { color: var(--muted); }
.store-arrow {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--chip);
  display: flex;
  align-items: center;
  justify-content: center;
}
.pill {
  flex: none;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--chip);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.2;
  color: var(--muted);
}

.card {
  width: 100%;
  border-radius: 22px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: 0 1px 2px var(--shadow);
}
.rows { overflow: hidden; }
.row {
  min-height: 64px;
  padding: 12px 16px 12px 12px;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: background-color 120ms ease;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
  .row:hover { background-color: rgba(127, 127, 127, 0.07); }
  .row:hover .chevron { transform: translateX(2px); }
}
.row:active { background-color: rgba(127, 127, 127, 0.14); }
.row:focus-visible { outline: 3px solid currentColor; outline-offset: -3px; }
.row .chevron { flex: none; color: var(--muted); }
.row-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.row-icon-solid { background: var(--solid); color: var(--on-solid); }
.row-icon-whatsapp { background: #25D366; }
.row-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 17px;
  line-height: 1.2;
}
.row-divider { height: 1px; margin-left: 66px; background: var(--line); }

/* ---------- Socials and footer (every page) ---------- */
.socials {
  margin-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
/* 5 × 48px + 4 × 12px = 288px is wider than a 320px screen's column: tighten the gap so they stay on one row. */
@media (max-width: 340px) {
  .socials { gap: 8px; }
}
.site-footer p {
  margin-top: 22px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}
.footer-link {
  display: inline-block;
  padding: 12px 4px;
  margin: -12px -4px;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-link:focus-visible { outline: 3px solid currentColor; outline-offset: -3px; border-radius: 6px; }

/* ---------- Share sheet (links page; used when navigator.share is missing) ---------- */
.sheet {
  width: 100%;
  max-width: 460px;
  max-height: calc(100dvh - 24px);
  margin: auto auto 0;
  padding: 10px 20px 28px;
  padding-bottom: max(28px, env(safe-area-inset-bottom));
  border: 0;
  border-radius: 28px 28px 0 0;
  background: var(--card);
  color: var(--ink);
  flex-direction: column;
  gap: 18px;
}
.sheet[open] { display: flex; animation: sheet-up 220ms cubic-bezier(.2, .8, .2, 1); }
.sheet::backdrop { background: rgba(14, 14, 16, 0.44); }
:root[data-theme='dark'] .sheet::backdrop { background: rgba(0, 0, 0, 0.62); }
@keyframes sheet-up { from { transform: translateY(24px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet-grabber { align-self: center; width: 40px; height: 4px; border-radius: 999px; background: var(--line); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; }
.sheet-title { font-family: var(--display); font-weight: 700; font-size: 20px; }
.share-card {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #1E1C1A;
  color: #FFFFFF;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.share-rings { position: absolute; right: -70px; top: 50%; transform: translateY(-50%); }
.share-card-mark {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
}
.share-card-mark img { width: 27px; height: auto; }
.share-card-text { position: relative; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.share-card-name { font-family: var(--display); font-weight: 700; font-size: 20px; line-height: 1.15; }
.share-card-host { font-size: 14px; color: #A1A1AA; overflow-wrap: anywhere; }
/* One column per visible item ("More" is hidden unless the system share menu exists). */
.share-grid { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
.share-item {
  border: 0;
  background: none;
  padding: 4px 0;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  border-radius: 14px;
}
.share-item[hidden] { display: none; }
.share-icon {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  background: var(--chip);
  display: flex;
  align-items: center;
  justify-content: center;
}
.share-icon-whatsapp { background: #25D366; }
.share-icon-x { background: #000000; box-shadow: inset 0 0 0 1px var(--tile-edge); }
.share-label { font-size: 12px; color: var(--muted); }
.icon-copied { display: none; }
.is-copied .icon-copied { display: block; }
.is-copied .icon-copy { display: none; }

/* ---------- Signup page ---------- */
.signup-card {
  margin-top: 24px;
  border-radius: 26px;
  padding: 24px 20px 22px;
}
.signup-form { display: flex; flex-direction: column; gap: 20px; }
.signup-form[hidden], .done[hidden] { display: none; }
.signup-intro { display: flex; flex-direction: column; gap: 6px; text-align: center; }
.chip {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 8px;
  border-radius: 999px;
  background: var(--chip);
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}
.signup-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: 27px;
  line-height: 1.15;
}
.signup-intro .signup-title { margin-top: 6px; }
.signup-title:focus { outline: none; }
.signup-lede { font-size: 16px; line-height: 1.5; color: var(--muted); }
.field { display: flex; flex-direction: column; gap: 8px; }
.field-label { font-size: 14px; font-weight: 500; }
.field-input {
  width: 100%;
  height: 56px;
  padding: 0 16px;
  border-radius: 16px;
  border: 1.5px solid var(--field-line);
  background: var(--field);
  color: var(--ink);
  font-family: var(--text);
  font-size: 17px;
  transition: box-shadow 120ms ease;
  -webkit-appearance: none;
  appearance: none;
}
.field-input::placeholder { color: var(--muted); opacity: 0.7; }
.field-input:focus { outline: none; box-shadow: 0 0 0 4px rgba(161, 161, 170, 0.35); }
.field-input[aria-invalid='true'] { border-color: var(--danger); }
.field-msg { display: flex; flex-direction: column; gap: 4px; }
.field-error {
  display: flex;
  gap: 6px;
  align-items: flex-start;
  font-size: 14px;
  line-height: 1.4;
  color: var(--danger);
}
.field-error svg { flex: none; margin-top: 2px; }
.field-hint { font-size: 14px; line-height: 1.4; color: var(--muted); }
.field-error[hidden], .field-hint[hidden], .alert[hidden] { display: none; }
.hint-fix {
  /* A 44px tall tap target that doesn't change the line: the padding is cancelled by negative margins. More of it
     sits below the text, so the target never reaches up over the field (8px above). */
  display: inline-block;
  min-height: 44px;
  padding: 8px 0 16px;
  margin: -8px 0 -16px;
  border: 0;
  background: none;
  font: inherit;
  color: var(--ink);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  overflow-wrap: anywhere;
}
.hint-fix:focus-visible { outline: 3px solid currentColor; outline-offset: 3px; border-radius: 4px; }
.alert {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  border-radius: 16px;
  background: var(--danger-soft);
  color: var(--ink);
}
.alert svg { flex: none; margin-top: 2px; color: var(--danger); }
.alert p { font-size: 14px; line-height: 1.45; }
.submit {
  height: 56px;
  border: 0;
  border-radius: 18px;
  background: var(--solid);
  color: var(--on-solid);
  font-family: var(--display);
  font-weight: 700;
  font-size: 20px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: transform 90ms ease, opacity 120ms ease;
  -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) { .submit:hover { opacity: 0.92; } }
.submit:active { transform: scale(0.98); }
.submit:disabled { cursor: progress; opacity: 0.85; transform: none; }
.submit:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.submit-label { padding-top: 3px; }
.submit .spinner { display: none; animation: spin 0.9s linear infinite; transform-origin: center; }
.submit[aria-busy='true'] .spinner { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }
.fine-print {
  margin-top: -6px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
  text-align: center;
}
.fine-link {
  display: inline-block;
  padding: 10px 2px;
  margin: -10px -2px;
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.fine-link:focus-visible { outline: 3px solid currentColor; outline-offset: -3px; border-radius: 6px; }
.cf-turnstile:empty { display: none; }

.done {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
  padding: 8px 0 4px;
}
.done-badge {
  position: relative;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ring);
}
.done-rings { position: absolute; inset: 0; }
.done-check {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  background: var(--solid);
  color: var(--on-solid);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pop 360ms cubic-bezier(.2, .9, .3, 1.3);
}
@keyframes pop { from { transform: scale(0.6); opacity: 0; } to { transform: none; opacity: 1; } }
.done-email { color: var(--ink); font-weight: 500; overflow-wrap: anywhere; }

.market-card {
  margin-top: 14px;
  width: 100%;
  min-height: 64px;
  padding: 10px 12px 10px 10px;
  border-radius: 22px;
  border: 1.5px dashed var(--ring);
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 14px;
}
.market-card .chevron { flex: none; margin-right: 9px; }
.market-sub { font-size: 13px; line-height: 1.35; color: var(--muted); }
.stack { flex: none; display: flex; }
.stack-tile {
  width: 34px;
  height: 34px;
  border-radius: 11px;
  overflow: hidden;
  background: #FFFFFF;
  box-shadow: 0 0 0 2px var(--bg), inset 0 0 0 1px var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
}
.stack-tile + .stack-tile { margin-left: -8px; }
.stack-tile img { width: 26px; height: 26px; object-fit: contain; }
.signup-card ~ .socials { margin-top: 24px; }

/* ---------- Privacy page ---------- */
.page-doc { padding-top: 16px; padding-bottom: max(32px, env(safe-area-inset-bottom)); }
.column-doc { max-width: 560px; align-items: stretch; }
.doc-bar { display: flex; align-items: center; justify-content: space-between; }
.doc-wordmark { width: 150px; height: auto; }
.doc-title {
  margin: 32px 0 4px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 34px;
  line-height: 1.1;
}
.doc-updated { font-size: 14px; color: var(--muted); }
.doc-intro { margin-top: 16px; font-size: 16px; line-height: 1.6; color: var(--muted); }
.policy { margin-top: 24px; overflow: hidden; }
.policy-item { padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; }
.policy-heading {
  font-family: var(--display);
  font-weight: 700;
  font-size: 19px;
  line-height: 1.25;
}
.policy-text { font-size: 15px; line-height: 1.6; color: var(--muted); }
.policy-divider { height: 1px; margin: 0 20px; background: var(--line); }
.contact-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.contact-btn {
  min-height: 52px;
  border-radius: 18px;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--display);
  font-weight: 700;
  font-size: 16px;
}
.contact-wa {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: #25D366;
  display: flex;
  align-items: center;
  justify-content: center;
}
.contact-address { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: center; }
.page-doc .site-footer p { margin-top: 28px; }

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

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
