/* ═══════════════════════════════════════════════════════════════════════
   Theme — the one palette, type scale, depth and motion for the hub, Hoy
   and Repaso (2026-10-22 redesign, at his request: "I just really like
   beautiful things").

   The rule it follows, from the research on design and learning:
   - beauty in the FORM helps or is neutral: attractive interfaces are
     judged easier to use (the aesthetic-usability effect), and warm colour
     plus rounded shapes ("positive emotional design") gave small gains in
     motivation and retention in a meta-analysis (Wong & Adesope, 2021);
   - decoration that competes with the CONTENT hurts (seductive details).
   So the chrome is rich — the key's gold, deep indigo, soft depth, rounded
   type — and the card you are answering stays calm: one font for the
   Spanish, nothing moving, nothing decorative inside it.

   Fonts are the phone's own (no web fonts, works offline): SF Pro Rounded
   for headings, New York for the story, SF for everything else.

   Green and red stay reserved for right and wrong. Gold is the brand.   */
:root{
  --bg:#F6F2EA;      --bg-alt:#EEE7DA;   --card:#FFFFFF;
  --ink:#1D2140;     --muted:#6A6A84;    --line:#E4DCCD;
  --accent:#3E50A0;  --accent-2:#2C3A7E; --accent-soft:#E8EBF7; --on-accent:#FFFFFF;
  --gold:#B8862A;    --gold-bright:#D9A441; --gold-soft:#F5EBD3;
  --good:#1E8E5A; --good-soft:#DDF0E5; --good-ink:#0F3D27;
  --bad:#C0392B;  --bad-soft:#F7E0DC;  --bad-ink:#8A2018;
  --shadow:0 1px 2px rgba(29,33,64,.05), 0 6px 20px rgba(29,33,64,.07);
  --shadow-lift:0 2px 4px rgba(29,33,64,.06), 0 14px 34px rgba(29,33,64,.12);
  --hero:linear-gradient(145deg, #3E50A0 0%, #2C3A7E 58%, #232E66 100%);
  --r-card:22px; --r-btn:15px; --r-chip:11px;
  --f-ui:-apple-system,BlinkMacSystemFont,"SF Pro Text","Segoe UI",Roboto,sans-serif;
  --f-round:ui-rounded,"SF Pro Rounded",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;
  --f-story:ui-serif,"New York",Charter,Georgia,serif;
  --f-mono:ui-monospace,SFMono-Regular,Menlo,monospace;
}
@media (prefers-color-scheme: dark){
  :root{
    --bg:#0F1328;    --bg-alt:#161B35;   --card:#1B2142;
    --ink:#EEF0FA;   --muted:#A2A7C4;    --line:#2A3158;
    --accent:#9AABF2; --accent-2:#7C8FE0; --accent-soft:#252C58; --on-accent:#0F1328;
    --gold:#E0B152;  --gold-bright:#F0C468; --gold-soft:#332B1A;
    --good:#4FC98A; --good-soft:#123324; --good-ink:#9DEABC;
    --bad:#E2453B;  --bad-soft:#3D1310;  --bad-ink:#F5A89E;
    --shadow:0 0 0 1px rgba(255,255,255,.04), 0 8px 24px rgba(0,0,0,.35);
    --shadow-lift:0 0 0 1px rgba(255,255,255,.06), 0 16px 40px rgba(0,0,0,.45);
    --hero:linear-gradient(145deg, #2E3C86 0%, #222C66 55%, #1A2250 100%);
  }
}

*{box-sizing:border-box;-webkit-tap-highlight-color:transparent}
html,body{margin:0;padding:0}
body{
  background:var(--bg); color:var(--ink);
  font:16px/1.55 var(--f-ui);
  padding:0 18px calc(56px + env(safe-area-inset-bottom));
  max-width:560px; margin:0 auto; -webkit-text-size-adjust:100%;
  -webkit-font-smoothing:antialiased;
}
a{color:inherit}
h1,h2,h3{font-family:var(--f-round);letter-spacing:-.01em}

/* the round back button in every page header */
.back{
  width:42px;height:42px;flex:0 0 auto;border-radius:50%;display:flex;align-items:center;justify-content:center;
  background:var(--card);box-shadow:var(--shadow);text-decoration:none;font-size:19px;color:var(--ink);
}
.back:active{transform:scale(.94)}

/* buttons: a rounded gradient primary, a quiet ghost */
button{
  font:inherit;font-weight:600;width:100%;min-height:50px;line-height:1.2;
  border-radius:var(--r-btn);border:0;cursor:pointer;padding:14px;
  background:var(--hero);color:#fff;box-shadow:0 6px 16px rgba(44,58,126,.25);
  transition:transform .12s ease, box-shadow .12s ease;
}
@media (prefers-color-scheme: dark){ button{color:#fff} }
button:active{transform:scale(.98);box-shadow:0 2px 8px rgba(44,58,126,.25)}
button.ghost{background:transparent;color:var(--accent);box-shadow:none;border:1.5px solid var(--line);margin-top:10px}
button:focus-visible,a:focus-visible{outline:3px solid var(--gold-bright);outline-offset:2px}

/* small capitals label used for "where this card comes from" */
.eyebrow{font:600 11px/1.3 var(--f-round);letter-spacing:.09em;text-transform:uppercase;color:var(--muted)}

/* motion: one gentle arrival per screen, never inside a card while you
   answer, and none at all for people who ask for less motion */
@keyframes rise{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
.rise{animation:rise .28s cubic-bezier(.2,.7,.2,1) both}
@media (prefers-reduced-motion: reduce){ .rise{animation:none} button{transition:none} }

/* the key, drawn in CSS-free SVG by the pages that show it */
.keymark{display:block}
