/* =====================================================================
   ReadQuest AI — base.css
   Design tokens, reset, typography, sky decoration
   Ported unchanged from the original app.css (v2) unless marked NEW.
   ===================================================================== */
:root {
  --ink: #1f2544;
  --ink-2: #3d4466;
  --muted: #5d6488;
  --line: #e3e7f5;
  --bg: #eef5ff;
  --card: #ffffff;

  --primary: #5b5bf7;
  --primary-600: #4a45e0;
  --primary-700: #3a35c2;
  --primary-50: #eeeeff;
  --sun: #ffc93c;
  --sun-600: #f0b11a;
  --sun-50: #fff7dc;
  --coral: #ff6b6b;
  --coral-700: #d64545;
  --coral-50: #ffeded;
  --mint: #22b8a7;
  --mint-700: #12857a;
  --mint-50: #e2f8f5;
  --grape: #9b5de5;
  --grape-50: #f3eaff;
  --sky: #4cc9f0;

  --r-sm: 12px;
  --r: 20px;
  --r-lg: 28px;
  --shadow-sm: 0 2px 6px rgba(31, 37, 68, .06);
  --shadow: 0 10px 30px rgba(52, 63, 140, .10), 0 2px 6px rgba(52, 63, 140, .06);
  --shadow-lg: 0 24px 60px rgba(52, 63, 140, .18);
  --pop: 0 6px 0 rgba(0, 0, 0, .14);

  --font-display: "Baloo 2", "Comic Sans MS", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Nunito", "Segoe UI", system-ui, -apple-system, sans-serif;
  --focus: 0 0 0 4px #fff, 0 0 0 7px #ff8a00;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 10% -10%, #dff0ff 0%, transparent 60%),
    radial-gradient(900px 500px at 110% 10%, #fff1d9 0%, transparent 55%),
    linear-gradient(180deg, #eaf4ff 0%, #f6f3ff 55%, #fff8ec 100%);
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
}
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 .4em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 3.4vw, 2.8rem); font-weight: 800; }
h2 { font-size: clamp(1.45rem, 2.4vw, 1.9rem); font-weight: 800; }
h3 { font-size: 1.3rem; font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--primary-600); font-weight: 700; }
a:hover { color: var(--primary-700); }
code { background: var(--primary-50); padding: 2px 6px; border-radius: 6px; font-size: .9em; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 12px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 12px; z-index: 999; }
.skip-link:focus { top: 12px; }
[hidden] { display: none !important; }

/* ---------- Decorative clouds ---------- */
.sky-decor { position: fixed; inset: 0; pointer-events: none; z-index: -1; overflow: hidden; }
.cloud { position: absolute; background: #fff; border-radius: 999px; opacity: .65; filter: blur(.3px); }
.cloud::before, .cloud::after { content: ""; position: absolute; background: #fff; border-radius: 50%; }
.cloud.c1 { width: 180px; height: 52px; top: 120px; left: -40px; animation: drift 70s linear infinite; }
.cloud.c1::before { width: 80px; height: 80px; top: -40px; left: 30px; }
.cloud.c1::after { width: 60px; height: 60px; top: -26px; left: 92px; }
.cloud.c2 { width: 140px; height: 42px; top: 340px; right: 4%; opacity: .5; animation: drift 90s linear infinite reverse; }
.cloud.c2::before { width: 64px; height: 64px; top: -32px; left: 24px; }
.cloud.c2::after { width: 48px; height: 48px; top: -20px; left: 74px; }
.cloud.c3 { width: 120px; height: 36px; bottom: 120px; left: 30%; opacity: .45; animation: drift 110s linear infinite; }
.cloud.c3::before { width: 54px; height: 54px; top: -26px; left: 20px; }
@keyframes drift { from { transform: translateX(-5vw); } to { transform: translateX(15vw); } }

/* v2 brand colour */
:root { --primary: #4f5bff; --primary-600: #3f49e6; --primary-700: #3039c4; }
