/* rabbithole.pro: the Rabbithole brand on the web. Aqua #00D2E6, charcoal #131F24, white; Nunito for words, the
   drawn serif wordmark for the name. Light and dark follow the system. Contrast: body text and links are AA on every
   ground they sit on; aqua is a fill or an underline on light grounds (white on aqua is only 1.9:1), and the words on
   aqua buttons are charcoal (8.9:1). */

@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("/assets/fonts/nunito-latin.woff2") format("woff2");
}

:root {
  --canvas: #ffffff;
  --raised: #f3f7f8;
  --stroke: #dfe7ea;
  --ink: #131f24;
  --text: #1e2c32;
  --soft: #52636a;       /* 6.1:1 on white, 5.7:1 on raised */
  --aqua: #00d2e6;
  --aqua-edge: #00a3b3;
  --wash: #e3f9fb;
  --link: #131f24;
  --link-line: #00c2d6;
  --focus: #131f24;
  --gold-wash: #fff4cc;
  --gold-edge: #e5b400;
  --gold-ink: #6b5200;
  --radius: 20px;
  --radius-s: 14px;
  --font: "Nunito", ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #131f24;
    --raised: #1a2a31;
    --stroke: #2e4049;
    --ink: #ffffff;
    --text: #e8f0f2;
    --soft: #a3b3ba;     /* 7.4:1 on the dark canvas */
    --wash: #15343b;
    --link: #00d2e6;     /* 9.1:1 on the dark canvas */
    --link-line: #00d2e6;
    --focus: #00d2e6;
    --gold-wash: #3a3214;
    --gold-edge: #8a6d00;
    --gold-ink: #ffd95c;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--canvas); color: var(--text);
  font-family: var(--font); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
picture { display: block; }
[hidden] { display: none !important; }

a { color: var(--link); font-weight: 700; text-decoration: underline; text-decoration-color: var(--link-line);
  text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 3px; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 8px;
}
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; background: var(--ink); color: var(--canvas);
  padding: 8px 14px; border-radius: 10px; text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 780px; margin: 0 auto; padding: 0 16px; }
.wrap-wide { max-width: 1080px; }
body { min-height: 100vh; display: flex; flex-direction: column; }
main { padding: 32px 0 72px; flex: 1 0 auto; }

/* Header */
.site-header { border-bottom: 2px solid var(--stroke); background: var(--canvas); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; min-height: 72px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; padding: 10px 0; }
.brand-icon { width: 36px; height: 36px; }
.brand .wordmark { width: 133px; height: auto; }
.nav { display: flex; gap: 6px; }
.nav a { color: var(--soft); text-decoration: none; font-size: 15px; font-weight: 800; padding: 8px 12px; border-radius: 12px; }
.nav a:hover { color: var(--ink); background: var(--raised); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--wash); }
@media (max-width: 640px) {
  .bar { min-height: 0; padding-top: 4px; padding-bottom: 8px; }
  .nav { width: 100%; justify-content: space-between; gap: 0; margin: 0 -10px; width: calc(100% + 20px); }
  .nav a { padding: 8px 10px; }
}

/* Type */
h1, h2, h3 { color: var(--ink); font-weight: 900; line-height: 1.15; letter-spacing: -0.3px; }
h1 { font-size: clamp(32px, 5.2vw, 52px); margin: 0 0 14px; }
h2 { font-size: clamp(23px, 3vw, 28px); margin: 48px 0 12px; }
h3 { font-size: 19px; margin: 0 0 6px; }
p { margin: 0 0 14px; }
.lede { font-size: clamp(18px, 2.2vw, 20px); color: var(--soft); margin: 0 0 24px; }
.soft, .meta { color: var(--soft); }
.meta { font-size: 15px; font-weight: 600; }
.eyebrow { font-size: 14px; font-weight: 900; text-transform: uppercase; letter-spacing: 0.8px; color: var(--soft); margin: 0 0 8px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin: 6px 0; }

/* Breadcrumbs */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 0; padding: 0; margin: 0 0 22px;
  font-size: 14px; color: var(--soft); }
.crumbs li + li::before { content: "/"; margin: 0 8px; color: var(--stroke); font-weight: 900; }
.crumbs a { color: var(--soft); text-decoration: none; font-weight: 700; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }

/* Buttons */
.button {
  appearance: none; border: 0; cursor: pointer; font: inherit; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 22px;
  border-radius: 14px; background: var(--aqua); color: #131f24; box-shadow: 0 4px 0 var(--aqua-edge);
  font-size: 15px; font-weight: 900; text-transform: uppercase; letter-spacing: 0.5px;
  transition: transform 0.06s ease, box-shadow 0.06s ease;
}
.button:hover { text-decoration: none; filter: brightness(1.04); }
.button:active { transform: translateY(4px); box-shadow: 0 0 0 var(--aqua-edge); }
.button-quiet { background: var(--canvas); color: var(--ink); border: 2px solid var(--stroke); box-shadow: 0 4px 0 var(--stroke); }
.button[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .button { transition: none; } }
/* A status label, not a button: no border, no button shape, plain-case words. */
.soon { display: inline-flex; align-items: center; gap: 10px; margin: 0; padding: 0 4px;
  color: var(--soft); font-weight: 800; font-size: 16px; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--aqua); box-shadow: 0 0 0 4px var(--wash); }
.cta-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

/* Home hero */
.hero { display: grid; grid-template-columns: 1fr; gap: 8px; align-items: center; padding: 8px 0 24px; }
.hero h1 { font-size: clamp(38px, 6.4vw, 64px); letter-spacing: -1px; }
.hero-art { order: -1; display: flex; justify-content: center; }
.hop-stage { position: relative; display: block; width: min(42vw, 170px); aspect-ratio: 280 / 352; padding: 0;
  border: 0; background: none; cursor: pointer; overflow: hidden; border-radius: 24px; }
.hop-stage .hop img { width: 100%; height: auto; }
.hop-anim { position: absolute; inset: 0; visibility: hidden; pointer-events: none; }
.hop-anim > svg { position: absolute; width: 182.857% !important; height: 145.455% !important;
  left: -42.857%; top: -36.364%; }
.hop-stage.playing .hop-anim { visibility: visible; }
.hop-stage.playing .hop-poster { visibility: hidden; }
@media (min-width: 800px) {
  .hero { grid-template-columns: 1.25fr 0.75fr; gap: 40px; padding: 24px 0 32px; }
  .hero-art { order: 0; }
  .hop-stage { width: 320px; }
}

.facts { list-style: none; padding: 0; margin: 8px 0 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.facts li { background: var(--raised); border: 2px solid var(--stroke); border-radius: var(--radius-s); padding: 14px 16px; }
.facts strong { display: block; font-size: clamp(28px, 4vw, 36px); font-weight: 900; color: var(--ink); line-height: 1.1; }
.facts span { color: var(--soft); font-weight: 700; font-size: 15px; }
@media (min-width: 800px) { .facts { grid-template-columns: repeat(4, 1fr); } }

/* Cards */
.cards { display: grid; grid-template-columns: 1fr; gap: 16px; margin: 16px 0 0; padding: 0; list-style: none; }
@media (min-width: 800px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.card { position: relative; border: 2px solid var(--stroke); border-bottom-width: 5px; border-radius: var(--radius);
  padding: 20px; background: var(--canvas); }
.card:hover { border-color: var(--aqua); }
.card .icon img { width: 56px; height: 56px; margin-bottom: 12px; }
.card h2, .card h3 { font-size: 21px; margin: 0 0 6px; }
.card h2 a, .card h3 a { color: var(--ink); text-decoration: none; }
.card h2 a::after, .card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card p { margin: 0 0 8px; color: var(--soft); }
.card .meta { margin: 0; color: var(--ink); }

/* How a lesson works */
.how { list-style: none; counter-reset: how; display: grid; grid-template-columns: 1fr; gap: 16px; padding: 0; margin: 16px 0 0; }
@media (min-width: 640px) { .how { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .how { grid-template-columns: repeat(4, 1fr); } }
.how li { counter-increment: how; background: var(--raised); border-radius: var(--radius); padding: 18px; }
.how li::before { content: counter(how); display: grid; place-items: center; width: 36px; height: 36px;
  border-radius: 50%; background: var(--aqua); color: #131f24; font-weight: 900; margin-bottom: 12px; }
.how p { margin: 0; color: var(--soft); }

/* Trust band */
.band { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: center; margin-top: 48px;
  background: var(--wash); border-radius: 28px; padding: 24px; }
.band h2 { margin-top: 0; }
.band p { color: var(--text); }
.band-hop img { width: 120px; margin: 0 auto; }
@media (min-width: 700px) { .band { grid-template-columns: 1fr auto; padding: 32px 40px; } .band-hop img { width: 140px; } }
.arrow::after { content: " \2192"; }

/* Chips */
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 12px 0 0; }
.chips a { display: inline-block; padding: 6px 12px; border-radius: 999px; border: 2px solid var(--stroke);
  color: var(--ink); text-decoration: none; font-size: 15px; }
.chips a:hover { border-color: var(--aqua); background: var(--wash); }

/* Features */
.features { list-style: none; display: grid; grid-template-columns: 1fr; gap: 12px 28px; padding: 0; margin: 16px 0 0; }
@media (min-width: 700px) { .features { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .features { grid-template-columns: repeat(3, 1fr); } }
.features li { position: relative; padding: 14px 16px 14px 48px; font-weight: 700; color: var(--ink);
  background: var(--raised); border-radius: var(--radius-s); }
.features li::before { content: ""; position: absolute; left: 16px; top: 17px; width: 20px; height: 20px;
  border-radius: 50%; background: var(--aqua); }
.features li::after { content: ""; position: absolute; left: 23px; top: 21px; width: 5px; height: 10px;
  border: solid #131f24; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.pro-line { margin-top: 24px; font-size: 18px; }
.after-how { margin: 18px 0 0; }

/* End-of-page card on course, unit and tool pages */
.end-card { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: center; margin: 40px 0 0;
  background: var(--wash); border-radius: 28px; padding: 24px; }
.end-card h2 { margin: 0 0 6px; font-size: 24px; }
.end-card p { margin: 0 0 16px; color: var(--text); }
.end-hop img { width: 96px; }
/* Dark mode: Hop's dark hoodie sinks into the dark wash, so he stands on a soft aqua glow there. */
@media (prefers-color-scheme: dark) {
  .end-card { background: var(--raised); border: 2px solid var(--stroke); }
  .end-hop { background: radial-gradient(closest-side, rgba(0, 210, 230, .22), rgba(0, 210, 230, 0) 100%); border-radius: 50%; }
}
@media (min-width: 640px) { .end-card { grid-template-columns: auto 1fr; gap: 28px; padding: 28px 32px; }
  .end-hop img { width: 120px; } }

/* Course and unit pages */
.split { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: center; }
.split > picture img { width: 120px; }
.split .icon img { width: 72px; height: 72px; }
@media (min-width: 640px) { .split { grid-template-columns: auto 1fr; gap: 28px; } .split > picture img { width: 140px; } }
.stages, .lessons, .lessons-more, .sources { list-style: none; padding: 0; margin: 12px 0 0; }
.stage { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; padding: 14px 0; border-bottom: 2px solid var(--stroke); }
.stage > a, .stage-name { font-size: 18px; font-weight: 800; }
.stage-name { color: var(--ink); }
.badge { display: inline-block; font-size: 12px; font-weight: 900; text-transform: uppercase; letter-spacing: 0.5px;
  padding: 2px 8px; border-radius: 999px; background: var(--wash); color: var(--ink); }
.inline-lessons { flex-basis: 100%; margin: 4px 0 0; padding-left: 20px; color: var(--soft); font-size: 16px; }
.lessons { counter-reset: lesson; }
.lessons li { counter-increment: lesson; display: flex; gap: 12px; justify-content: space-between; align-items: baseline;
  padding: 12px 0; border-bottom: 2px solid var(--stroke); }
.lessons li::before { content: counter(lesson); flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid;
  place-items: center; background: var(--raised); border: 2px solid var(--stroke); font-weight: 900; font-size: 14px; color: var(--soft); }
.lessons li > span:first-child { flex: 1; font-weight: 700; color: var(--ink); }
.lvl { flex: none; font-size: 13px; font-weight: 900; color: var(--soft); white-space: nowrap; }
.lessons-more li { padding: 8px 0; border-bottom: 2px solid var(--stroke); }
.lessons-more li > span:first-child { font-weight: 700; color: var(--ink); }
.sources li { padding: 6px 0; }
ol.sources { list-style: decimal; padding-left: 22px; }
/* Not a link, so flat: no raised bottom edge like the tappable cards. */
.lesson-card { border: 2px solid var(--stroke); background: var(--raised); border-radius: var(--radius); padding: 18px 20px; margin: 8px 0 0; }
.lesson-card h2 { margin: 6px 0 4px; font-size: 22px; }
.lesson-card .meta { margin: 0; }
.pager { display: flex; justify-content: space-between; gap: 16px; margin: 40px 0 0; padding-top: 16px; border-top: 2px solid var(--stroke); }
.status-line { margin-top: 32px; color: var(--soft); font-weight: 700; }
.pager + .status-line { margin-top: 20px; }

/* Platform directory */
.filter { margin: 8px 0 8px; }
.filter label { display: block; font-weight: 800; margin-bottom: 6px; color: var(--ink); }
.filter input { width: 100%; max-width: 420px; font: inherit; padding: 12px 14px; border-radius: 14px;
  border: 2px solid var(--stroke); background: var(--canvas); color: var(--text); }
.directory { columns: 1; column-gap: 32px; }
@media (min-width: 700px) { .directory { columns: 2; } }
.letter { break-inside: avoid; padding-top: 4px; }
.letter h2 { margin: 20px 0 6px; font-size: 22px; color: var(--soft); }
.letter ul { list-style: none; padding: 0; margin: 0; }
.letter li { display: flex; flex-direction: column; padding: 8px 0; border-bottom: 2px solid var(--stroke); }
.letter li a { font-size: 18px; }

/* FAQ page */
.qa h2 { font-size: 21px; margin: 36px 0 8px; }

/* Comparison table */
.table-scroll { overflow-x: auto; margin: 16px 0 24px; }
.compare { width: 100%; min-width: 640px; border-collapse: collapse; font-size: 16px; }
.compare th, .compare td { text-align: left; vertical-align: top; padding: 12px 12px 12px 0; border-bottom: 2px solid var(--stroke); }
.compare thead th { font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--soft); }
.compare tbody th { color: var(--ink); }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { background: var(--wash); }

/* Help Center (details) */
.faq { margin: 0; padding: 0; list-style: none; display: grid; gap: 12px; }
.faq details { border: 2px solid var(--stroke); border-radius: var(--radius-s); background: var(--canvas); }
.faq summary { list-style: none; cursor: pointer; padding: 16px 48px 16px 18px; position: relative; font-weight: 800; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 20px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
  border-right: 3px solid var(--soft); border-bottom: 3px solid var(--soft); transform: rotate(45deg); transition: transform 0.2s ease; }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq .answer { padding: 0 18px 16px; }
.faq .answer p:last-child { margin-bottom: 0; }
.faq .answer ul { margin: 0 0 10px; padding-left: 20px; }
@media (prefers-reduced-motion: reduce) { .faq summary::after { transition: none; } }
.section-head { display: flex; align-items: center; gap: 12px; margin: 40px 0 12px; }
.section-head h2 { margin: 0; }
code { font-size: 0.92em; background: var(--raised); border: 1px solid var(--stroke); border-radius: 6px; padding: 1px 5px; }

/* Feedback */
.email-box { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; border: 2px solid var(--stroke);
  border-radius: var(--radius-s); background: var(--raised); padding: 16px 18px; margin: 8px 0 28px; }
.email { font-size: 22px; font-weight: 900; color: var(--ink); user-select: all; -webkit-user-select: all; overflow-wrap: anywhere; flex: 1 1 auto; }
.email-box .button { min-width: 104px; min-height: 44px; }
.steps { counter-reset: step; list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; position: relative; padding-left: 44px; min-height: 30px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -1px; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; background: var(--raised); border: 2px solid var(--stroke); font-weight: 900; font-size: 15px; color: var(--soft); }
.after-steps { margin-top: 28px; }

/* Legal */
.draft-banner { background: var(--gold-wash); border-bottom: 2px solid var(--gold-edge); color: var(--gold-ink);
  font-weight: 800; text-align: center; padding: 12px 16px; font-size: 16px; }
.draft-banner span { font-weight: 600; }
.legal h2 { font-size: 21px; margin-top: 36px; }
.legal h3 { font-size: 17px; margin-top: 20px; }
.legal p, .legal li { font-size: 16px; }
.legal ul { padding-left: 22px; }
.legal li { margin: 4px 0; }
.legal .updated { color: var(--soft); font-size: 15px; margin: 0 0 24px; }
.legal table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 15px; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: 10px 10px 10px 0; border-bottom: 2px solid var(--stroke); }
.legal th { font-weight: 800; color: var(--soft); font-size: 13px; text-transform: uppercase; letter-spacing: 0.4px; }
.note { background: var(--raised); border: 2px solid var(--stroke); border-radius: var(--radius-s); padding: 12px 14px; }
.placeholder { background: var(--gold-wash); color: var(--gold-ink); border-radius: 4px; padding: 0 4px; font-weight: 700; }

/* 404 and the invite page */
.center { text-align: center; }
.center picture img { margin: 0 auto 16px; }

/* Footer */
.site-footer { border-top: 2px solid var(--stroke); padding: 36px 0 40px; background: var(--raised); }
.foot-grid { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 800px) { .foot-grid { grid-template-columns: 1fr 2fr; } }
.foot-brand { display: flex; gap: 14px; align-items: flex-start; }
.foot-brand img { width: 40px; height: 40px; flex: none; }
.foot-brand p { margin: 0; color: var(--soft); font-weight: 700; max-width: 320px; }
.foot-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px 24px; }
.foot-h { font-size: 13px; text-transform: uppercase; letter-spacing: 0.8px; color: var(--soft); margin: 0 0 8px; }
.foot-cols ul { list-style: none; padding: 0; margin: 0; }
.foot-cols li { margin: 6px 0; }
.foot-cols a { color: var(--ink); text-decoration: none; font-size: 15px; }
.foot-cols a:hover { text-decoration: underline; }
.foot-small { margin: 28px 0 0; color: var(--soft); }
.foot-small a { color: var(--soft); font-weight: 600; }
