/* Whiteboard Revision site. Colours and type follow the app (Highlighter design). */
:root {
  --ground: #faf8f5;
  --card: #ffffff;
  --text: #201e1d;
  --muted: #5d5957;
  --rule: #e7e2dc;
  --yellow: #f9d544;
  --ink: #201e1d;
  --on-ink: #ffffff;
  --bio: #90e9a3;
  --maths: #8edefe;
  --french: #a9d4ff;
  --chem: #ffc091;
  --hist: #87e4de;
  --phys: #d0c8ff;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #151413;
    --card: #201e1d;
    --text: #f3efea;
    --muted: #b3aeaa;
    --rule: #2e2b29;
    --ink: #f3efea;
    --on-ink: #151413;
  }
}
:root[data-theme="dark"] {
  --ground: #151413;
  --card: #201e1d;
  --text: #f3efea;
  --muted: #b3aeaa;
  --rule: #2e2b29;
  --ink: #f3efea;
  --on-ink: #151413;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font: 18px/1.55 "Source Serif 4", Georgia, "Times New Roman", serif;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

/* Brand mark: the app's yellow highlighter tag. */
.brand { font-weight: 800; font-size: 19px; text-decoration: none; white-space: nowrap; }
.brand span { background: var(--yellow); color: #201e1d; padding: 3px 8px; border-radius: 6px; }

header.top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 0; }
header.top nav { display: flex; align-items: center; gap: 22px; font-size: 16px; }
header.top nav a { text-decoration: none; color: var(--muted); }
header.top nav a:hover { color: var(--text); }
header.top nav .hide-sm { display: none; }
@media (min-width: 720px) { header.top nav .hide-sm { display: inline; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 26px; border-radius: 999px;
  font: 600 17px/1 "Source Serif 4", Georgia, serif; text-decoration: none; white-space: nowrap;
}
.btn-ink { background: var(--ink); color: var(--on-ink); }
.btn-line { border: 1.5px solid var(--text); color: var(--text); }
.btn-small { min-height: 40px; padding: 0 18px; font-size: 15px; }
header.top .btn-small { color: var(--on-ink); }

h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; margin: 0; }
h1 { font-size: clamp(44px, 8vw, 84px); line-height: 0.98; letter-spacing: -0.035em; }
h2 { font-size: clamp(32px, 5vw, 52px); line-height: 1.02; }
h3 { font-size: 24px; line-height: 1.15; }
.lede { font-size: clamp(19px, 2.2vw, 22px); color: var(--muted); max-width: 34em; margin: 22px 0 0; }
.kicker { font: 600 13px/1.2 "Source Serif 4", Georgia, serif; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.mark { background: var(--yellow); color: #201e1d; padding: 0 0.15em; }

/* Hero */
.hero { display: grid; gap: 40px; padding: 28px 0 56px; align-items: center; }
@media (min-width: 960px) { .hero { grid-template-columns: 1.05fr 1fr; padding: 48px 0 80px; } }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.small { font-size: 15px; color: var(--muted); margin-top: 18px; }
.phones { display: flex; justify-content: center; gap: 14px; }
.phones img {
  width: 31%; max-width: 230px; border-radius: 26px; border: 7px solid #111;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18); background: #111;
}
.phones img:nth-child(2) { transform: translateY(-22px); }

section { padding: 56px 0; }
section + section { border-top: 1px solid var(--rule); }

/* How it works */
.steps { display: grid; gap: 18px; margin-top: 34px; }
@media (min-width: 820px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { background: var(--card); border-radius: 22px; padding: 26px; border: 1px solid var(--rule); }
.step .n {
  display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--yellow); color: #201e1d; font-weight: 800; margin-bottom: 14px;
}
.step p { color: var(--muted); margin: 8px 0 0; }

/* Features: pastel cards like the app's subject tiles */
.features { display: grid; gap: 18px; margin-top: 34px; }
@media (min-width: 820px) { .features { grid-template-columns: repeat(2, 1fr); } }
.feature { border-radius: 26px; padding: 28px 28px 0; color: #201e1d; display: flex; flex-direction: column; overflow: hidden; }
.feature p { margin: 10px 0 22px; color: #3d3a38; }
.feature img { width: 62%; max-width: 280px; margin: auto auto 0; border-radius: 22px 22px 0 0; border: 6px solid #111; border-bottom: 0; }

/* Boards and subjects */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.chip { border: 1.5px solid var(--rule); border-radius: 999px; padding: 8px 16px; font-size: 16px; }
.chip.on { border-color: transparent; color: #201e1d; }

.split { display: grid; gap: 36px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; } }
.panel { background: var(--card); border: 1px solid var(--rule); border-radius: 26px; padding: 30px; }
.panel ul { margin: 14px 0 0; padding-left: 22px; color: var(--muted); }
.panel li + li { margin-top: 8px; }

footer { border-top: 1px solid var(--rule); padding: 30px 0 46px; font-size: 15px; color: var(--muted); }
footer .row { display: flex; flex-wrap: wrap; gap: 14px 26px; align-items: center; justify-content: space-between; }
footer nav { display: flex; flex-wrap: wrap; gap: 20px; }

/* Text pages: privacy, help */
.doc { max-width: 700px; padding: 24px 0 72px; }
.doc h1 { font-size: clamp(38px, 6vw, 52px); margin-bottom: 10px; }
.doc h2 { font-size: 24px; margin: 38px 0 8px; letter-spacing: -0.01em; }
.doc ul { padding-left: 22px; }
.doc li + li { margin-top: 6px; }
.doc .muted { color: var(--muted); }

/* Subject colours (classes, not inline styles, so the CSP can stay strict). */
.bg-bio { background: var(--bio); }
.bg-maths { background: var(--maths); }
.bg-french { background: var(--french); }
.bg-chem { background: var(--chem); }
.bg-hist { background: var(--hist); }
.bg-phys { background: var(--phys); }
