/* =========================================================================
   Wordoverse — shared stylesheet
   Palette + claymorphism taken from the app (shared/theme/tokens.ts and the
   feature screens): warm off-white surfaces, orange accent, golden gradients,
   cream cards, a blue radial background, thick darker outlines + soft shadows.
   ========================================================================= */

:root {
  /* Surfaces */
  --bg: #FAF7F2;
  --bg-grad-start: #C0E2FD;
  --bg-grad-end: #5CB4FA;
  --card: #FFFFFF;
  --card-cream: #FFF7E0;
  --card-warm: #FEF8EF;

  /* Ink */
  --ink: #1A1A1A;
  --muted: #6B6B6B;
  --faint: #9E9E9E;

  /* Lines */
  --border: #E2E0DA;
  --divider: #EEEAE2;

  /* Brand */
  --accent: #E8622A;         /* orange */
  --accent-ink: #B8461A;     /* darker orange for text on light */
  --accent-soft: #FFEFE5;
  --gold-1: #FDC900;
  --gold-2: #E17507;
  --gold-outline: #C6600A;
  --yellow: #FFD54A;
  --brown-ink: #4A2600;      /* readable text on gold */

  /* Shape */
  --radius: 22px;
  --radius-sm: 14px;
  --radius-pill: 999px;

  /* Elevation (claymorphism) */
  --shadow-clay: 0 12px 26px rgba(20, 24, 34, 0.10), 0 2px 0 rgba(0, 0, 0, 0.04);
  --shadow-soft: 0 8px 18px rgba(20, 24, 34, 0.08);

  --maxw: 1080px;
  --maxw-read: 760px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  line-height: 1.65;
  background: var(--bg);
  background-image: radial-gradient(130% 85% at 50% -10%, var(--bg-grad-start) 0%, var(--bg-grad-end) 72%);
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

/* Brand / display font */
.font-display,
h1, h2, h3, .brand__name, .btn {
  font-family: "Braah One", var(--fallback-display, "Segoe UI"), system-ui, sans-serif;
  letter-spacing: 0.2px;
}

h1, h2, h3 { line-height: 1.2; color: var(--ink); }

a { color: var(--accent-ink); text-underline-offset: 2px; }
a:hover { text-decoration: underline; }

/* Visible keyboard focus everywhere */
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 6px;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  border-radius: 0 0 12px 0;
  z-index: 200;
}
.skip-link:focus { left: 0; }

/* ------------------------------ Layout -------------------------------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 20px; }
.container--read { max-width: var(--maxw-read); }

.section { padding-block: 40px; }

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

/* ------------------------------ Header -------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 64px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand__logo {
  width: 34px; height: 34px; border-radius: 10px;
  box-shadow: var(--shadow-soft);
}
.brand__name { font-size: 20px; font-weight: 400; }

/* Nav */
.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font: inherit;
  cursor: pointer;
  color: var(--ink);
}
.nav-toggle__bars { display: inline-block; width: 18px; height: 2px; background: var(--ink); position: relative; }
.nav-toggle__bars::before, .nav-toggle__bars::after {
  content: ""; position: absolute; left: 0; width: 18px; height: 2px; background: var(--ink);
}
.nav-toggle__bars::before { top: -6px; }
.nav-toggle__bars::after { top: 6px; }

.site-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
}
.site-nav a {
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
}
.site-nav a:hover { background: var(--accent-soft); text-decoration: none; }
.site-nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent-ink); }

@media (max-width: 720px) {
  .site-nav {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 100%;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 10px 16px 16px; gap: 4px; }
  .site-nav a { padding: 12px 14px; border-radius: var(--radius-sm); }
}
@media (min-width: 721px) {
  .nav-toggle { display: none; }
}

/* ------------------------------ Buttons ------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 22px;
  border-radius: 16px;
  font-size: 16px;
  font-weight: 400;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: transform 0.06s ease, box-shadow 0.06s ease;
  will-change: transform;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(2px); }

.btn--gold {
  background: linear-gradient(180deg, var(--gold-1), var(--gold-2));
  color: var(--brown-ink);
  border-bottom: 4px solid var(--gold-outline);
  box-shadow: var(--shadow-clay);
}
.btn--gold:active { border-bottom-width: 2px; }

.btn--dark {
  background: var(--ink);
  color: #fff;
  border-bottom: 4px solid #000;
  box-shadow: var(--shadow-clay);
}
.btn--dark:active { border-bottom-width: 2px; }

.btn--ghost {
  background: var(--card);
  color: var(--ink);
  border: 2px solid var(--border);
}

.btn--block { display: flex; width: 100%; }

/* Store buttons */
.store-badges { display: flex; flex-wrap: wrap; gap: 12px; }
.store-badge {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  border-radius: 16px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  border-bottom: 4px solid #000;
  box-shadow: var(--shadow-clay);
  min-width: 190px;
}
.store-badge:hover { text-decoration: none; transform: translateY(-1px); }
.store-badge:active { transform: translateY(2px); border-bottom-width: 2px; }
.store-badge svg { flex: none; }
.store-badge__text { display: flex; flex-direction: column; line-height: 1.1; }
.store-badge__text small { font-size: 11px; color: #cfd2d8; }
.store-badge__text b { font-size: 17px; font-weight: 700; }
.store-note { color: var(--muted); font-size: 13px; margin-top: 10px; }

/* ------------------------------- Cards -------------------------------- */
.card {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-clay);
  padding: 24px;
}
.card--cream { background: var(--card-cream); border-color: #F2E4B8; }
.card--warm { background: var(--card-warm); border-color: #F6E2CE; }

/* -------------------------------- Hero -------------------------------- */
.hero {
  padding-block: 48px 40px;
  text-align: center;
}
.hero__badge {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent-ink);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.hero h1 {
  font-size: clamp(34px, 7vw, 58px);
  margin: 0 0 14px;
  color: #10233a;
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.5);
}
.hero__lead {
  font-size: clamp(17px, 2.6vw, 21px);
  max-width: 620px;
  margin: 0 auto 26px;
  color: #14304d;
}
.hero .store-badges { justify-content: center; }

/* --------------------------- Feature grid ----------------------------- */
.grid {
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
}
@media (min-width: 620px) { .grid--2 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 820px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
}

.feature__icon {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border-radius: 14px;
  background: linear-gradient(180deg, var(--gold-1), var(--gold-2));
  color: var(--brown-ink);
  font-size: 22px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-soft);
}
.feature h3 { margin: 0 0 6px; font-size: 20px; }
.feature p { margin: 0; color: var(--muted); }

/* Steps */
.steps { counter-reset: step; }
.step__num {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent); color: #fff; font-weight: 700;
  margin-bottom: 12px;
  box-shadow: var(--shadow-soft);
}

.section-head { text-align: center; margin-bottom: 26px; }
.section-head h2 { font-size: clamp(26px, 4.5vw, 36px); margin: 0 0 8px; color: #10233a; }
.section-head p { margin: 0 auto; max-width: 560px; color: #14304d; }

/* ------------------------------ Legal --------------------------------- */
.legal { padding-block: 32px 56px; }
.legal__header { margin-bottom: 24px; }
.legal__header h1 { font-size: clamp(30px, 6vw, 44px); margin: 0 0 8px; color: #10233a; }
.updated {
  display: inline-block;
  background: var(--card-cream);
  border: 2px solid #F2E4B8;
  color: var(--brown-ink);
  border-radius: var(--radius-pill);
  padding: 5px 14px;
  font-size: 13px;
  font-weight: 700;
}

.legal-body {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-clay);
  padding: clamp(20px, 4vw, 40px);
}
.legal-body h2 {
  font-size: 24px;
  margin: 34px 0 12px;
  padding-left: 14px;
  border-left: 5px solid var(--gold-1);
  scroll-margin-top: 84px;
}
.legal-body h2:first-of-type { margin-top: 6px; }
.legal-body h3 { font-size: 18px; margin: 22px 0 8px; }
.legal-body p, .legal-body li { color: #23262b; }
.legal-body ul, .legal-body ol { padding-left: 22px; }
.legal-body li { margin-bottom: 8px; }
.legal-body a { color: var(--accent-ink); }

/* Short-version / callout box */
.callout {
  background: var(--accent-soft);
  border: 2px solid #FAD9C6;
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 18px 0;
}
.callout p:last-child { margin-bottom: 0; }
.callout strong { color: var(--accent-ink); }

/* Table of contents */
.toc {
  background: var(--card-warm);
  border: 2px solid #F6E2CE;
  border-radius: var(--radius-sm);
  padding: 16px 18px 16px 34px;
  margin: 0 0 26px;
}
.toc h2 {
  border: 0; padding: 0; margin: 0 0 8px;
  font-size: 15px; text-transform: uppercase; letter-spacing: 0.6px; color: var(--muted);
}
.toc ol { margin: 0; }
.toc li { margin-bottom: 4px; }

/* Data / sub-processor table */
.table-wrap { overflow-x: auto; margin: 16px 0; -webkit-overflow-scrolling: touch; }
table.data {
  border-collapse: collapse;
  width: 100%;
  min-width: 520px;
  font-size: 15px;
}
table.data caption { text-align: left; color: var(--muted); font-size: 13px; margin-bottom: 8px; }
table.data th, table.data td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--divider);
  vertical-align: top;
}
table.data thead th {
  background: var(--card-cream);
  border-bottom: 2px solid #F2E4B8;
  white-space: nowrap;
}
table.data tr:last-child td { border-bottom: none; }

/* FAQ */
.faq details {
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 4px 18px;
  margin-bottom: 12px;
  background: var(--card);
}
.faq summary {
  cursor: pointer;
  font-weight: 700;
  padding: 12px 0;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--accent); font-size: 22px; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details > p, .faq details > ul { margin-top: 0; padding-bottom: 12px; color: #23262b; }

.contact-line {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  font-size: 18px; margin: 8px 0 0;
}

/* ------------------------------ Footer -------------------------------- */
.site-footer {
  margin-top: 24px;
  background: var(--ink);
  color: #d7d9de;
  padding-block: 34px;
}
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-brand { max-width: 320px; }
.footer-brand .brand__name { color: #fff; }
.footer-brand p { color: #a7abb4; margin: 10px 0 0; font-size: 14px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 26px; }
.footer-nav h4 { color: #fff; font-size: 14px; text-transform: uppercase; letter-spacing: 0.6px; margin: 0 0 10px; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; }
.footer-nav li { margin-bottom: 8px; }
.footer-bottom {
  border-top: 1px solid #33363d;
  margin-top: 26px; padding-top: 18px;
  font-size: 13px; color: #9296a0;
  display: flex; flex-wrap: wrap; gap: 8px 18px; justify-content: space-between;
}

/* Utility */
.mt-0 { margin-top: 0; }
.center { text-align: center; }
.lead { font-size: 18px; color: #14304d; }
