/* ── Drill page — premium minimal, desktop-first ──────────────────
   No tabs, no clutter. The page is a stage for one daily ritual:
   open Drill → see how many words today → press Begin. Mini-games
   sit below as a quieter secondary path.

   Composition: centered editorial column, generous breathing room.
   Mobile gets a stacked, tightened version of the same layout.
*/

body.is-drill .stub-shell { overflow: hidden; }
body.is-drill .stub-body.is-drill-body {
  padding: 0;
  height: calc(100vh - 64px);
  height: calc(100dvh - 64px);
  display: flex;
  align-items: stretch;
  justify-content: center;
  /* Subtle warm radial behind the stage — gives the page depth without
     distracting. Uses brand cream + a faint warm light spot. */
  background:
    radial-gradient(ellipse at 50% 30%, rgba(192, 138, 62, 0.06) 0%, transparent 55%),
    var(--bg, #fdf9f1);
}

.drill-page {
  width: 100%;
  max-width: 720px;
  padding: 4vh 2.5rem 3vh;
  display: flex;
  flex-direction: column;
  gap: 0;
  box-sizing: border-box;
  animation: drillFadeIn 0.55s ease-out both;
}
@keyframes drillFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.drill-loading,
.drill-empty {
  margin: auto;
  text-align: center;
  color: var(--ink-soft, #6b6f78);
  padding: 2rem 1rem;
  max-width: 32ch;
}
.drill-empty h3 { margin: 0 0 .5rem; color: var(--ink); font-family: 'Fraunces', serif; }
.drill-empty p { margin: 0; line-height: 1.55; }
.drill-empty code {
  font-family: 'SF Mono', Menlo, monospace;
  background: var(--line-soft, #e8e2d6);
  padding: .15rem .4rem;
  border-radius: 4px;
  font-size: .85em;
}

/* ─── Hero ─── */
.drill-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: 2.5vh;
}
.drill-eyebrow {
  font-size: .7rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--brand-accent, #c08a3e);
  margin-bottom: 1.25rem;
}
.drill-numeral {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: clamp(6rem, 14vw, 10rem);
  line-height: 0.92;
  color: var(--ink, #1a1d23);
  letter-spacing: -0.04em;
  font-feature-settings: "lnum";
  /* Gentle warm-shadow gives weight without feeling heavy */
  text-shadow: 0 2px 0 rgba(192, 138, 62, 0.06);
}
.drill-numeral-label {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 1.45rem;
  color: var(--ink-soft, #6b6f78);
  margin-top: .5rem;
}
.drill-status {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  color: var(--ink-soft, #6b6f78);
  margin: 1.25rem 0 1.75rem;
  max-width: 28ch;
  line-height: 1.5;
}

/* Lesson-locked empty state — for German (and future zero-start
   courses) when the user hasn't completed any source lesson. Replaces
   the standard hero. Friendlier than a "0" numeral; funnels back to
   lessons. */
.drill-hero-locked {
  padding: 4vh 1rem 2vh;
  gap: 1rem;
}
.drill-hero-locked .drill-locked-icon {
  color: var(--ink-soft, #6b6f78);
  opacity: .55;
  margin: 1rem 0 .25rem;
}
.drill-hero-locked .drill-locked-title {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.7rem;
  letter-spacing: -.01em;
  color: var(--ink, #1a1d23);
  margin: 0;
}
.drill-hero-locked .drill-locked-blurb {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  color: var(--ink-soft, #6b6f78);
  max-width: 38ch;
  line-height: 1.55;
  margin: .25rem 0 1.4rem;
}

/* CTA */
.drill-cta-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.drill-cta {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  background: var(--ink, #1a1d23);
  color: var(--bg, #fdf9f1);
  border: none;
  padding: 1.05rem 2.2rem;
  border-radius: 999px;
  font-family: 'Inter', sans-serif;
  font-size: .98rem;
  font-weight: 600;
  letter-spacing: .005em;
  cursor: pointer;
  transition: transform .18s cubic-bezier(.2,.8,.2,1), box-shadow .18s, background .18s;
  box-shadow: 0 6px 18px rgba(26, 29, 35, 0.18), 0 1px 2px rgba(26, 29, 35, 0.12);
}
.drill-cta:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(26, 29, 35, 0.24), 0 2px 4px rgba(26, 29, 35, 0.14);
  background: #2a2f3a;
}
.drill-cta:not(:disabled):active { transform: translateY(0); }
.drill-cta:disabled {
  background: var(--line, #d9d2c1);
  color: var(--ink-soft);
  cursor: default;
  box-shadow: none;
}
.drill-cta-arrow {
  font-size: 1.05rem;
  transition: transform .2s ease-out;
}
.drill-cta:not(:disabled):hover .drill-cta-arrow { transform: translateX(4px); }
.drill-cta-meta {
  font-size: .85rem;
  color: var(--ink-soft, #6b6f78);
  font-weight: 500;
}

/* ─── Divider ─── */
.drill-divider {
  position: relative;
  margin: 4vh 0 3vh;
  text-align: center;
}
.drill-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line, #d9d2c1);
}
.drill-divider-mark {
  position: relative;
  display: inline-block;
  background: var(--bg, #fdf9f1);
  color: var(--brand-accent, #c08a3e);
  padding: 0 1rem;
  font-family: 'Fraunces', serif;
  font-size: 1.5rem;
  line-height: 1;
}

/* ─── Mini-game grid ─── */
.drill-mini-eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: .82rem;
  font-weight: 500;
  color: var(--ink-soft, #6b6f78);
  text-align: center;
  margin-bottom: 1.25rem;
}
.drill-mini-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.drill-mini-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .85rem;
  padding: 1.35rem 1.2rem 1.15rem;
  background: var(--bg, #fdf9f1);
  border: 1px solid var(--line, #d9d2c1);
  border-radius: 16px;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform .22s cubic-bezier(.2,.8,.2,1), border-color .2s, box-shadow .22s, background .2s;
  min-height: 150px;
}
/* Subtle warm gradient backplate — barely visible until hover, but adds
   a hint of depth to the otherwise flat cream card. */
.drill-mini-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 100% 0%, rgba(192, 138, 62, 0.06) 0%, transparent 60%);
  opacity: .7;
  pointer-events: none;
  transition: opacity .22s;
}
/* Bottom accent line — animates to full width on hover, like a magazine
   "more" indicator. */
.drill-mini-card::after {
  content: '';
  position: absolute;
  left: 1.2rem;
  right: 1.2rem;
  bottom: 0;
  height: 2px;
  background: var(--brand-accent, #c08a3e);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s cubic-bezier(.2,.8,.2,1);
}
.drill-mini-card:not(:disabled):hover {
  transform: translateY(-4px);
  border-color: rgba(26, 29, 35, 0.4);
  box-shadow: 0 14px 32px rgba(26, 29, 35, 0.1), 0 2px 6px rgba(26, 29, 35, 0.04);
}
.drill-mini-card:not(:disabled):hover::before { opacity: 1; }
.drill-mini-card:not(:disabled):hover::after { transform: scaleX(1); }
.drill-mini-card:disabled,
.drill-mini-card.is-disabled {
  opacity: .45;
  cursor: default;
}

/* Letter badge — postage-stamp style monogram. Larger, serif, with a
   warm gradient + inner highlight to feel printed-on rather than flat. */
.drill-mini-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d49a4d 0%, #b07930 100%);
  color: var(--bg, #fdf9f1);
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: -0.02em;
  position: relative;
  z-index: 1;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 2px 6px rgba(192, 138, 62, 0.25);
}

.drill-mini-title {
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--ink, #1a1d23);
  line-height: 1.25;
  letter-spacing: -0.005em;
  position: relative;
  z-index: 1;
}
.drill-mini-sub {
  font-size: .82rem;
  color: var(--ink-soft, #6b6f78);
  line-height: 1.5;
  margin-top: -.4rem;
  position: relative;
  z-index: 1;
}


/* ─── Footer ─── */
.drill-foot {
  margin-top: auto;
  padding-top: 2vh;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .8rem;
  color: var(--ink-soft, #6b6f78);
  font-weight: 500;
}
.drill-foot-deck { letter-spacing: .04em; }
.drill-foot-streak { font-family: 'Inter', sans-serif; }

/* ── God-only debug strip ─────────────────────────────────────
   Visible only to god accounts on the drill landing. Designed as
   a discrete dev-tool: small monospace counts, dashed border,
   subtle until hovered. Schema-aware mode names live in the JS
   (Meet/Build/Recall/Produce for IELTS chunks; Flashcard/Type/
   Cloze/Distinguish for legacy decks). */
.drill-god-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .55rem;
  padding: .55rem .65rem .55rem .75rem;
  margin-top: 1.2rem;
  background: rgba(26, 29, 35, 0.035);
  border: 1px dashed rgba(26, 29, 35, 0.18);
  border-radius: 10px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .72rem;
}
.drill-god-tag {
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .18em;
  padding: .22rem .45rem;
  border-radius: 4px;
  background: rgba(217, 162, 104, .14);
  color: #B57A2E;
  border: 1px solid rgba(217, 162, 104, .28);
}
.drill-god-label {
  color: var(--ink-soft, #6b6f78);
  font-weight: 500;
  letter-spacing: .04em;
  margin-right: .15rem;
}
.drill-god-modes {
  display: inline-flex;
  gap: .35rem;
  flex-wrap: wrap;
}
.drill-god-mode {
  display: inline-flex;
  align-items: center;
  gap: .42rem;
  padding: .3rem .55rem .3rem .35rem;
  background: transparent;
  border: 1px solid rgba(26, 29, 35, 0.18);
  border-radius: 6px;
  color: var(--ink, #1a1d23);
  font: inherit;
  font-size: .72rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .14s, border-color .14s, transform .14s;
}
.drill-god-mode-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  background: rgba(26, 29, 35, 0.08);
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  font-size: .68rem;
  font-weight: 700;
  color: var(--ink-soft, #6b6f78);
}
.drill-god-mode-name { letter-spacing: .005em; }
.drill-god-mode-count {
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  font-size: .64rem;
  color: var(--ink-mute, #9098a4);
  font-variant-numeric: tabular-nums;
  min-width: 1.2em;
  text-align: right;
}
.drill-god-mode:hover {
  background: rgba(217, 162, 104, .08);
  border-color: rgba(217, 162, 104, .45);
  transform: translateY(-1px);
}
.drill-god-mode:hover .drill-god-mode-box {
  background: rgba(217, 162, 104, .22);
  color: #B57A2E;
}
.drill-god-mode.is-here .drill-god-mode-box {
  background: rgba(217, 162, 104, .22);
  color: #B57A2E;
}
.drill-god-divider {
  width: 1px;
  height: 18px;
  background: rgba(26, 29, 35, 0.15);
}
.drill-god-aside {
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  font-size: .64rem;
  color: var(--ink-mute, #9098a4);
  letter-spacing: .04em;
}
.drill-god-total {
  margin-left: auto;
  font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  font-size: .64rem;
  color: var(--ink-mute, #9098a4);
  letter-spacing: .04em;
}
.drill-god-reset {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .3rem .65rem;
  background: transparent;
  border: 1px solid rgba(168, 89, 63, .35);
  border-radius: 6px;
  color: #A8593F;
  font: inherit;
  font-size: .7rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .14s, border-color .14s;
}
.drill-god-reset:hover {
  background: rgba(168, 89, 63, .08);
  border-color: #A8593F;
}

/* ─── Responsive ─── */
@media (max-width: 760px) {
  .drill-page { padding: 3vh 1.25rem 2vh; max-width: 520px; }
  .drill-numeral-label { font-size: 1.2rem; }
  .drill-status { font-size: .95rem; margin: 1rem 0 1.4rem; }
  .drill-cta { padding: .9rem 1.7rem; font-size: .92rem; }
  .drill-divider { margin: 3vh 0 2.5vh; }
  .drill-mini-grid { gap: .75rem; }
  .drill-mini-card { padding: 1rem .9rem .9rem; min-height: 118px; }
  .drill-mini-title { font-size: .9rem; }
  .drill-mini-sub { font-size: .75rem; }
  .drill-mini-count { font-size: 1.25rem; bottom: .8rem; right: .9rem; }
}
@media (max-width: 480px) {
  .drill-page { padding: 2vh 1rem 1.5vh; }
  .drill-mini-grid { grid-template-columns: 1fr; gap: .6rem; }
  .drill-mini-card { min-height: 0; flex-direction: row; align-items: center; gap: .8rem; padding: .75rem .9rem; }
  .drill-mini-card .drill-mini-sub { display: none; }
  .drill-mini-count { position: static; margin-left: auto; }
  .drill-foot { flex-direction: column; gap: .25rem; }
}

/* Editor entry — visible to god / editor / teacher / headmaster.
   Sits below the streak footer, low-key but findable. */
.drill-edit-btn {
  display: inline-flex; align-items: center; gap: .45rem;
  margin: 1.5rem auto 0;
  padding: .55rem 1rem;
  font-size: .85rem; font-weight: 500;
  color: var(--ink-soft);
  text-decoration: none;
  background: var(--card);
  border: 1px dashed var(--line);
  border-radius: 999px;
  transition: color .15s, border-color .15s, background .15s, transform .15s;
}
.drill-edit-btn:hover {
  color: var(--ink);
  border-color: var(--ink);
  border-style: solid;
  transform: translateY(-1px);
}
.drill-page > .drill-edit-btn { display: flex; width: max-content; }

/* ─── Trust pill (Leitner / memory science authority signal) ─── */
.drill-trust-pill {
  display: inline-flex; align-items: center; gap: .35rem;
  margin: .6rem auto 0;
  padding: .3rem .75rem;
  font-size: .72rem; font-weight: 600; letter-spacing: .005em;
  color: var(--ink-soft);
  background: var(--bg-tint, #f4ecdc);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: color .15s, border-color .15s, background .15s, transform .15s;
}
.drill-trust-pill:hover {
  color: var(--ink);
  border-color: var(--ink);
  transform: translateY(-1px);
}
.drill-trust-pill svg { color: #2a8f5a; flex-shrink: 0; }

/* Trust modal */
.drill-trust-bg {
  position: fixed; inset: 0;
  background: rgba(20,15,10,0.5);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 5vh 1.5rem;
  z-index: 200;
  overflow-y: auto;
}
.drill-trust-modal {
  position: relative;
  width: 100%; max-width: 560px;
  padding: 2rem 2rem 1.7rem;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 24px 56px -16px rgba(0,0,0,0.28);
  animation: drillTrustLift .18s ease-out;
}
@keyframes drillTrustLift {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.drill-trust-x {
  position: absolute; top: .85rem; right: .85rem;
  width: 32px; height: 32px;
  background: transparent; border: none;
  border-radius: 8px;
  color: var(--ink-soft);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s;
}
.drill-trust-x:hover { background: rgba(0,0,0,0.06); color: var(--ink); }
.drill-trust-eyebrow {
  font-size: .65rem; font-weight: 700; letter-spacing: .15em;
  color: #2a8f5a;
  margin-bottom: .55rem;
}
.drill-trust-h {
  font-size: 1.5rem; line-height: 1.2;
  color: var(--ink);
  margin: 0 0 .85rem;
  letter-spacing: -.005em;
}
.drill-trust-lede {
  font-size: .95rem; line-height: 1.6;
  color: var(--ink-soft);
  margin: 0 0 1.3rem;
}
.drill-trust-lede strong { color: var(--ink); }
.drill-trust-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .75rem;
  margin-bottom: 1.3rem;
}
.drill-trust-stat {
  padding: .85rem .9rem;
  background: var(--bg-tint, #f4ecdc);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-align: center;
}
.drill-trust-stat-n {
  font-family: var(--font-display, inherit);
  font-size: 1.5rem; font-weight: 600;
  color: var(--ink);
  letter-spacing: -.01em;
  margin-bottom: .25rem;
}
.drill-trust-stat-l {
  font-size: .72rem; line-height: 1.4;
  color: var(--ink-soft);
}
.drill-trust-stat-l em { font-style: italic; opacity: .85; }
.drill-trust-explain {
  font-size: .9rem; line-height: 1.6;
  color: var(--ink-soft);
  margin: 0 0 1rem;
  padding: .9rem 1rem;
  background: var(--bg-tint, #f4ecdc);
  border-left: 3px solid var(--accent-warm, #D67659);
  border-radius: 8px;
}
.drill-trust-foot {
  font-size: .88rem; line-height: 1.55;
  color: var(--ink);
  margin: 0;
  font-weight: 500;
}
@media (max-width: 540px) {
  .drill-trust-grid { grid-template-columns: 1fr; }
  .drill-trust-stat { display: flex; align-items: center; gap: .85rem; text-align: left; }
  .drill-trust-stat-n { margin-bottom: 0; flex-shrink: 0; min-width: 70px; }
  .drill-trust-modal { padding: 1.5rem 1.4rem 1.4rem; }
}

/* ═══════════════════════════════════════════════════════════════════
   IELTS Lexis Drill — editorial redesign.
   Makes /ielts/drill a faithful member of the /ielts page family: the
   dark espresso shell, a honey eyebrow + serif title (the rd-head
   pattern), and cream "paper" cards. Scoped to .is-drill-ielts so the
   German drill (everything above) is left untouched.
   ═══════════════════════════════════════════════════════════════════ */
body.is-drill-ielts {
  --dl-bg:             #2A1F18;
  --dl-ink:            #F2E6CC;
  --dl-ink-soft:       #B6A484;
  --dl-ink-mute:       #7A6A52;
  --dl-honey:          #D9A268;
  --dl-ember:          #D86840;
  --dl-line:           rgba(242, 230, 204, .10);
  --dl-line-strong:    rgba(242, 230, 204, .18);
  --dl-paper:          #F5EBD3;
  --dl-paper-tint:     #EFE2C4;
  --dl-paper-ink:      #1F1812;
  --dl-paper-ink-soft: #4A3F33;
  --dl-paper-ink-mute: #7A6A55;
  --dl-paper-honey:    #B57A2E;
  --dl-paper-line:     rgba(31, 24, 18, .14);
}

/* ── Shell surface — dark espresso with the IELTS corner glow. The
   glow lives on the fixed .stub-shell so it never scrolls; .stub-body
   stays transparent and is the scroll container. The shell starts
   below the fixed IELTS top nav (shown by router.js on this route). ── */
body.is-drill-ielts .stub-shell {
  top: 76px;
  background-color: var(--dl-bg);
  background-image:
    radial-gradient(circle 280px at 13% 5%,
      rgba(217, 162, 104, .15) 0%, rgba(217, 162, 104, 0) 62%),
    radial-gradient(ellipse 80% 55% at 100% 104%,
      rgba(216, 104, 64, .10) 0%, rgba(216, 104, 64, 0) 55%),
    radial-gradient(circle at 1px 1px,
      rgba(242, 230, 204, .045) 1px, transparent 1.6px);
  background-size: 100% 100%, 100% 100%, 3px 3px;
}
@media (max-width: 760px) {
  body.is-drill-ielts .stub-shell { top: 64px; }
}
/* The stub header (back / close / "Drill") is hidden — the IELTS top
   nav is the page chrome now, matching the other /ielts pages. */
body.is-drill-ielts .stub-header { display: none; }
body.is-drill.is-drill-ielts .stub-body.is-drill-body {
  display: block;
  height: auto;
  padding: 0;
  background: transparent;
}

/* ── Page column ── */
.dl-page {
  max-width: 820px;
  margin: 0 auto;
  padding: 2.6rem 1.6rem 4rem;
  box-sizing: border-box;
  animation: dlFade .4s ease-out both;
}
@keyframes dlFade {
  from { opacity: 0; transform: translateY(7px); }
  to   { opacity: 1; transform: none; }
}

/* ── Page head — the rd-head pattern (honey eyebrow + serif title) ── */
.dl-head { margin-bottom: 2rem; }
.dl-eyebrow {
  display: inline-block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--dl-honey);
  margin-bottom: .55rem;
}
.dl-title {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 400;
  font-size: clamp(2.4rem, 5vw, 3.3rem);
  line-height: 1.04;
  letter-spacing: -.02em;
  color: var(--dl-ink);
  margin: 0;
}

/* ── Sections — the rd-section pattern ── */
.dl-section { margin-bottom: 2.7rem; }
.dl-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.15rem;
  padding-bottom: .7rem;
  border-bottom: 1px solid var(--dl-line);
}
.dl-section-title {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: 1.5rem;
  letter-spacing: -.01em;
  color: var(--dl-ink);
  margin: 0;
}
.dl-section-meta {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .83rem;
  color: var(--dl-ink-soft);
}

/* ── Session card — the cream "paper" hero ── */
.dl-session {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: stretch;
  box-sizing: border-box;
  background: var(--dl-paper);
  border: 1px solid transparent;
  border-radius: 14px;
  padding: 2.5rem 2.4rem;
  box-shadow:
    0 1px 0 rgba(0, 0, 0, .2),
    0 20px 40px -20px rgba(0, 0, 0, .6);
}
.dl-session.is-done { grid-template-columns: auto 1fr; }
.dl-session-figure {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-right: 2rem;
  border-right: 1px solid var(--dl-paper-line);
}
.dl-session-num {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(3.4rem, 7.5vw, 5.2rem);
  line-height: .82;
  letter-spacing: -.02em;
  color: var(--dl-paper-honey);
  font-variant-numeric: oldstyle-nums;
}
.dl-session-check {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(181, 122, 46, .13);
  color: var(--dl-paper-honey);
}
.dl-session-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: .32rem;
  padding: 0 1.5rem 0 2rem;
  min-width: 0;
}
.dl-session-headline {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 500;
  font-size: 1.24rem;
  line-height: 1.25;
  letter-spacing: -.005em;
  color: var(--dl-paper-ink);
}
.dl-session-meta {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .85rem;
  color: var(--dl-paper-ink-mute);
}
.dl-session-cta {
  align-self: center;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .92rem 1.6rem;
  border: 0;
  border-radius: 10px;
  background: var(--dl-paper-ink);
  color: var(--dl-paper);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .92rem;
  font-weight: 600;
  letter-spacing: .005em;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 9px 20px -10px rgba(31, 24, 18, .65);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.dl-session-cta:hover {
  transform: translateY(-2px);
  background: #2C2017;
  box-shadow: 0 15px 28px -10px rgba(31, 24, 18, .75);
}
.dl-session-cta svg { transition: transform .15s ease; }
.dl-session-cta:hover svg { transform: translateX(3px); }

/* ── Tail — trust link + god/editor footer ── */
.dl-tail {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.1rem;
  margin-top: .4rem;
}
.dl-trust {
  padding: 0;
  border: 0;
  background: none;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: .82rem;
  color: var(--dl-ink-soft);
  cursor: pointer;
  text-decoration: underline;
  text-decoration-color: var(--dl-line-strong);
  text-underline-offset: 3px;
  transition: color .15s;
}
.dl-trust:hover { color: var(--dl-ink); }
.dl-foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .65rem;
}

/* God / editor controls — re-themed for the dark surface. */
body.is-drill-ielts .drill-edit-btn {
  margin: 0;
  color: var(--dl-ink-soft);
  background: rgba(242, 230, 204, .04);
  border: 1px dashed var(--dl-line-strong);
}
body.is-drill-ielts .drill-edit-btn:hover {
  color: var(--dl-ink);
  border-color: var(--dl-honey);
  border-style: solid;
}
/* God strip — IELTS dark-coffee overrides. Mirror the light-theme
   structure but pull from --dl-* tokens so it sits naturally on
   the espresso shell. Honey for the mode chips on hover/active,
   ember (terracotta) for the reset action. */
body.is-drill-ielts .drill-god-strip {
  background: rgba(242, 230, 204, .025);
  border: 1px dashed var(--dl-line-strong);
}
body.is-drill-ielts .drill-god-tag {
  background: rgba(217, 162, 104, .18);
  color: var(--dl-honey);
  border-color: rgba(217, 162, 104, .35);
}
body.is-drill-ielts .drill-god-label { color: var(--dl-ink-soft); }
body.is-drill-ielts .drill-god-mode {
  background: transparent;
  border: 1px solid var(--dl-line-strong);
  color: var(--dl-ink-soft);
}
body.is-drill-ielts .drill-god-mode-box {
  background: rgba(242, 230, 204, .08);
  color: var(--dl-ink-soft);
}
body.is-drill-ielts .drill-god-mode-name { color: var(--dl-ink); }
body.is-drill-ielts .drill-god-mode-count { color: var(--dl-ink-mute); }
body.is-drill-ielts .drill-god-mode:hover {
  background: rgba(217, 162, 104, .08);
  border-color: var(--dl-honey);
  color: var(--dl-ink);
}
body.is-drill-ielts .drill-god-mode:hover .drill-god-mode-box,
body.is-drill-ielts .drill-god-mode.is-here .drill-god-mode-box {
  background: rgba(217, 162, 104, .25);
  color: var(--dl-honey);
}
body.is-drill-ielts .drill-god-divider {
  background: rgba(242, 230, 204, .15);
}
body.is-drill-ielts .drill-god-aside,
body.is-drill-ielts .drill-god-total {
  color: var(--dl-ink-mute);
}
body.is-drill-ielts .drill-god-reset {
  color: var(--dl-ember);
  border-color: rgba(216, 104, 64, .4);
}
body.is-drill-ielts .drill-god-reset:hover {
  background: rgba(216, 104, 64, .1);
  border-color: rgba(216, 104, 64, .65);
}

/* Loading / empty — kept legible on the dark surface. */
body.is-drill-ielts .drill-loading,
body.is-drill-ielts .drill-empty {
  margin: 0 auto;
  padding: 6rem 2rem;
  color: var(--dl-ink-soft);
}
body.is-drill-ielts .drill-empty h3 { color: var(--dl-ink); }
body.is-drill-ielts .drill-empty code {
  background: rgba(242, 230, 204, .08);
  color: var(--dl-ink);
}

/* ── Responsive ── */
@media (max-width: 620px) {
  .dl-page { padding: 2rem 1.1rem 3rem; }
  .dl-head { margin-bottom: 1.6rem; }
  .dl-section { margin-bottom: 2.2rem; }
  .dl-session,
  .dl-session.is-done {
    grid-template-columns: 1fr;
    padding: 1.7rem 1.5rem;
    text-align: center;
  }
  .dl-session-figure {
    padding: 0 0 1.15rem;
    margin-bottom: 1.15rem;
    border-right: 0;
    border-bottom: 1px solid var(--dl-paper-line);
  }
  .dl-session-body {
    align-items: center;
    padding: 0;
  }
  .dl-session-cta {
    justify-self: center;
    margin-top: 1.25rem;
  }
}

/* ── Accessibility — reduced motion + focus rings ──────────────
   Honor OS-level "reduce motion" by tearing down the entry / hover
   transitions. Focus rings give keyboard users a visible anchor on
   buttons + links — both themes share this scope. */
@media (prefers-reduced-motion: reduce) {
  .drill-page *,
  .drill-page *::before,
  .drill-page *::after,
  .dl-page *,
  .dl-page *::before,
  .dl-page *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.drill-page button:focus-visible,
.drill-page a:focus-visible,
.dl-page button:focus-visible,
.dl-page a:focus-visible {
  outline: 2px solid var(--brand-accent, #c08a3e);
  outline-offset: 3px;
  border-radius: inherit;
}
body.is-drill-ielts .dl-page button:focus-visible,
body.is-drill-ielts .dl-page a:focus-visible {
  outline-color: var(--dl-honey, #D9A268);
}
