/* ============================================================================
   Maro for TOEFL — sub-brand identity.
   Family link to parent Maro (cerulean) but its own warmer voice for the ESL /
   high-stakes audience. Loaded AFTER /css/maro.css (reuses .btn + the ink-blot
   mascot; overrides type, color, and defines the page + question components).

   Type (contrast axis, none on the reflex-reject list):
     display = Bricolage Grotesque · body = Literata (reading serif) · labels = Geist Mono
   Color: cerulean kept as the credibility anchor; deep terracotta carries warmth.
   Warmth lives in accent + type + warm panels — NOT a cream body (clean light bg
   for reading legibility).
============================================================================ */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,400..800&family=Literata:ital,opsz,wght@0,7..72,400..600;1,7..72,400..500&family=Geist+Mono:wght@400;500&display=swap');

:root{
  --t-bg:#F6F8FB;            /* light, faintly cool — ties to Maro's sky, reads clean for passages */
  --t-surface:#FFFFFF;
  --t-warm:#FBF2EC;          /* soft clay wash — hero/human panels only (accent surface, not body) */
  --t-ink:#1F2D36;           /* deep slate — body text, ~12:1 on bg */
  --t-muted:#53626C;         /* secondary — ~6:1 on bg */
  --t-faint:#7C8A93;         /* labels/tertiary — large/label use only */
  --t-pen:#2D7DBA;           /* cerulean — family link to Maro */
  --t-pen-deep:#1B567E;      /* deep cerulean — inline links on light (~5.6:1) */
  --t-clay:#A8442C;          /* deep terracotta — primary warm accent; white text passes (~5.3:1) */
  --t-clay-soft:#C75D43;     /* lighter terracotta — fills, large text */
  --t-clay-wash:rgba(168,68,44,0.10);
  --t-line:rgba(31,45,54,0.12);
  --t-line-soft:rgba(31,45,54,0.07);
  --t-pen-line:rgba(45,125,186,0.22);

  --t-display:'Bricolage Grotesque',system-ui,sans-serif;
  --t-body:'Literata',Georgia,serif;
  --t-mono:'Geist Mono',ui-monospace,monospace;

  --t-maxw:1080px;
  --t-shadow:0 22px 60px -40px rgba(31,45,54,0.5);
  --t-shadow-warm:0 18px 44px -26px rgba(168,68,44,0.4);
  --ease:cubic-bezier(0.22,1,0.36,1);
}

/* ---- base (overrides maro.css body) ---- */
body{ background:var(--t-bg); color:var(--t-ink); font-family:var(--t-body); font-optical-sizing:auto; }
.t a{ color:inherit; }
::selection{ background:var(--t-clay-wash); }

.wrap{ max-width:var(--t-maxw); margin:0 auto; padding-left:24px; padding-right:24px; }

/* ---- type ---- */
.t-display, h1.title, .hero h1, .sec h2, .band-num{
  font-family:var(--t-display); font-weight:600; letter-spacing:-0.02em; line-height:1.05; text-wrap:balance;
}
.t-eyebrow{ font-family:var(--t-mono); font-size:12px; letter-spacing:0.14em; text-transform:uppercase; color:var(--t-clay); }
.t-label{ font-family:var(--t-mono); font-size:11px; letter-spacing:0.14em; text-transform:uppercase; color:var(--t-faint); }
.lede{ font-size:clamp(17px,2.2vw,20px); line-height:1.55; color:var(--t-muted); max-width:60ch; text-wrap:pretty; }
.ink-link{ color:var(--t-pen-deep); text-decoration:underline; text-decoration-color:var(--t-pen-line); text-underline-offset:3px; }
.ink-link:hover{ text-decoration-color:var(--t-pen); }

/* ---- nav / footer (shared) ---- */
.t-nav{ display:flex; align-items:center; justify-content:space-between; gap:14px; padding:20px 0; }
.t-nav .brand{ display:flex; align-items:center; gap:10px; font-family:var(--t-display); font-weight:600; font-size:21px; color:var(--t-ink); }
.t-nav .brand .tag{ font-family:var(--t-mono); font-size:10px; letter-spacing:0.08em; color:var(--t-clay); background:var(--t-clay-wash); border:1px solid rgba(168,68,44,0.28); border-radius:20px; padding:4px 9px; text-transform:uppercase; }
.navlinks{ display:flex; gap:20px; align-items:center; font-size:15px; }
.navlinks a{ color:var(--t-muted); } .navlinks a:hover{ color:var(--t-pen-deep); }
.t-foot{ margin:48px 0 32px; padding-top:18px; border-top:1px solid var(--t-line-soft); font-size:12.5px; color:var(--t-faint); line-height:1.7; display:flex; flex-wrap:wrap; gap:14px; justify-content:space-between; }
.t-foot a{ color:var(--t-muted); }

/* ---- buttons (extend maro .btn) ---- */
.btn{ font-family:var(--t-display); font-style:normal; font-weight:600; border-radius:14px; }
.btn-warm{ background:var(--t-clay); color:#fff; box-shadow:var(--t-shadow-warm); }
.btn-warm:hover{ background:#943A25; }
.btn-quiet{ background:var(--t-surface); color:var(--t-ink); border-color:var(--t-line); }
.btn-quiet:hover{ border-color:var(--t-pen); color:var(--t-pen-deep); }

/* ---- landing: hero ---- */
.hero{ padding:clamp(24px,6vw,64px) 0 24px; }
.hero h1{ font-size:clamp(38px,6.4vw,76px); margin:14px 0 18px; }
.hero h1 .warm{ color:var(--t-clay); }
.hero .cta{ display:flex; gap:14px; flex-wrap:wrap; margin-top:26px; align-items:center; }
.hero .reassure{ font-size:14px; color:var(--t-faint); }

/* ---- landing: sections ---- */
.sec{ padding:clamp(28px,5vw,56px) 0; }
.sec h2{ font-size:clamp(26px,3.6vw,40px); margin:0 0 10px; }
.sec .sub{ color:var(--t-muted); max-width:58ch; margin:0 0 26px; font-size:17px; }

/* four-skills: not identical cards — a typed list with leading skill marks */
.skills{ display:grid; grid-template-columns:repeat(auto-fit,minmax(230px,1fr)); gap:2px; background:var(--t-line-soft); border:1px solid var(--t-line-soft); border-radius:18px; overflow:hidden; }
.skill{ background:var(--t-surface); padding:22px 22px 24px; }
.skill .n{ font-family:var(--t-mono); font-size:12px; color:var(--t-clay); }
.skill h3{ font-family:var(--t-display); font-weight:600; font-size:21px; margin:8px 0 6px; }
.skill p{ margin:0; color:var(--t-muted); font-size:15px; line-height:1.55; }
.skill .tasks{ margin:10px 0 0; font-family:var(--t-mono); font-size:11px; letter-spacing:0.04em; color:var(--t-faint); }

/* seen-not-scored — a single warm panel (the human moment) */
.seen-panel{ background:var(--t-warm); border:1px solid rgba(168,68,44,0.16); border-radius:22px; padding:clamp(26px,4vw,42px); }
.seen-panel h2{ color:var(--t-ink); }
.seen-panel .pts{ display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:20px; margin-top:22px; }
.seen-panel .pt h4{ font-family:var(--t-display); font-weight:600; font-size:17px; margin:0 0 5px; }
.seen-panel .pt p{ margin:0; color:var(--t-muted); font-size:15px; line-height:1.55; }

/* CTA band */
.cta-band{ background:var(--t-ink); color:#fff; border-radius:24px; padding:clamp(30px,5vw,52px); text-align:center; }
.cta-band h2{ font-family:var(--t-display); font-weight:600; font-size:clamp(26px,3.6vw,38px); margin:0 0 10px; color:#fff; }
.cta-band p{ color:#C6D2DA; margin:0 auto 22px; max-width:46ch; font-size:16px; }

/* ============================================================================
   App components — shared by practice.html + diagnostic.html (class names match
   what their scripts produce; do not rename without updating the scripts).
============================================================================ */
.intro{ padding:14px 0 6px; }
.intro h1{ font-family:var(--t-display); font-weight:600; font-size:clamp(28px,5vw,42px); line-height:1.08; margin:14px 0 10px; letter-spacing:-0.02em; }
h1.title{ font-size:clamp(28px,4.8vw,42px); margin:14px 0 8px; }
p.lede{ color:var(--t-muted); }

.pill{ display:inline-block; font-family:var(--t-mono); font-size:10px; letter-spacing:0.08em; padding:5px 12px; border-radius:20px; color:var(--t-pen-deep); background:#EAF2FA; border:1px solid var(--t-pen-line); text-transform:uppercase; }
.label{ font-family:var(--t-mono); font-size:11px; letter-spacing:0.12em; text-transform:uppercase; color:var(--t-faint); }
.label.pen{ color:var(--t-pen-deep); }
.eyebrow{ font-family:var(--t-mono); font-size:12px; letter-spacing:0.14em; text-transform:uppercase; color:var(--t-clay); }
.underline-pen{ text-decoration:underline; text-decoration-color:var(--t-pen-line); text-underline-offset:3px; }

.tabs{ display:flex; gap:8px; flex-wrap:wrap; margin:22px 0 6px; }
.tab{ font-family:var(--t-mono); font-size:12px; letter-spacing:0.08em; text-transform:uppercase; padding:8px 14px; border-radius:20px; border:1px solid var(--t-line); background:var(--t-surface); color:var(--t-muted); cursor:pointer; }
.tab[aria-selected="true"]{ background:var(--t-clay-wash); color:var(--t-clay); border-color:rgba(168,68,44,0.3); }
.tab[disabled]{ opacity:0.5; cursor:default; } .tab .soon{ font-size:9px; opacity:0.8; }

.steps{ display:flex; gap:6px; flex-wrap:wrap; margin:8px 0 6px; }
.step{ font-family:var(--t-mono); font-size:11px; letter-spacing:0.08em; text-transform:uppercase; padding:6px 12px; border-radius:18px; border:1px solid var(--t-line); color:var(--t-faint); }
.step.on{ background:var(--t-clay-wash); color:var(--t-clay); border-color:rgba(168,68,44,0.3); }
.step.done{ color:#2E7D52; border-color:rgba(46,125,82,0.4); }

.qcard{ background:var(--t-surface); border:1px solid var(--t-line); border-radius:18px; padding:22px 24px; margin-top:16px; box-shadow:var(--t-shadow); }
.qmeta{ display:flex; gap:10px; align-items:center; margin-bottom:12px; }
.passage{ background:var(--t-bg); border:1px solid var(--t-line-soft); border-radius:12px; padding:14px 16px; white-space:pre-wrap; font-size:16px; line-height:1.75; color:var(--t-ink); margin-bottom:14px; }
.qtext{ font-size:18px; line-height:1.5; margin:0 0 14px; color:var(--t-ink); }

.opt{ display:flex; gap:10px; align-items:flex-start; border:1px solid var(--t-line); border-radius:12px; padding:11px 14px; margin:8px 0; cursor:pointer; transition:border-color .15s var(--ease), background .15s var(--ease); }
.opt:hover{ border-color:var(--t-pen); }
.opt input{ margin-top:4px; accent-color:var(--t-pen); }
.opt.correct{ border-color:#2E7D52; background:rgba(46,125,82,0.08); }
.opt.wrong{ border-color:#A8442C; background:var(--t-clay-wash); }
.opt .ltr{ font-family:var(--t-mono); font-size:12px; color:var(--t-faint); }

.cloze input{ font-family:var(--t-mono); font-size:15px; border:1px solid var(--t-line); border-radius:8px; padding:8px 10px; width:160px; margin:6px 8px 6px 0; color:var(--t-ink); background:var(--t-surface); }
.cloze input:focus{ outline:none; border-color:var(--t-pen); box-shadow:0 0 0 3px var(--t-pen-line); }
.cloze-item{ display:inline-flex; align-items:center; gap:8px; margin:6px 14px 6px 0; }
.cloze-item .shown-word{ font-family:var(--t-mono); font-size:15px; letter-spacing:0.1em; color:var(--t-muted); }
.cloze-item input{ width:96px; margin:0; }

textarea{ font-family:var(--t-body); font-size:16px; color:var(--t-ink); background:var(--t-surface); border:1px solid var(--t-line); border-radius:12px; padding:12px 14px; width:100%; resize:vertical; line-height:1.6; }
textarea:focus{ outline:none; border-color:var(--t-pen); box-shadow:0 0 0 3px var(--t-pen-line); }

.result{ margin-top:12px; font-size:15px; min-height:20px; } .result.ok{ color:#2E7D52; } .result.no{ color:#A8442C; }
.reader-row{ display:flex; justify-content:space-between; gap:12px; padding:7px 0; border-bottom:1px solid var(--t-line-soft); font-size:15px; }
.reader-row:last-child{ border-bottom:none; }
.pip{ display:inline-block; width:9px; height:9px; border-radius:50%; background:var(--t-line); margin-left:4px; } .pip.on{ background:var(--t-pen); }

.placeholder-chip, .ph-badge{ font-family:var(--t-mono); font-size:11px; letter-spacing:0.03em; color:#7A4A12; background:#FBF3E4; border:1px dashed #D8A24E; border-radius:10px; padding:6px 10px; display:inline-block; line-height:1.45; }
.placeholder-chip{ display:block; margin:6px 0; }

.band-num{ font-family:var(--t-display); font-weight:700; font-size:54px; color:var(--t-clay); }

.actions{ margin-top:18px; display:flex; gap:12px; align-items:center; flex-wrap:wrap; }
.cta-row{ margin:26px 0 8px; }
#err{ color:#A8442C; font-size:14px; margin-top:12px; }

/* ---- motion (reveal enhances an already-visible default) ---- */
@media (prefers-reduced-motion: no-preference){
  .reveal{ opacity:0; transform:translateY(14px); animation:t-rise .7s var(--ease) forwards; }
  .reveal.d1{ animation-delay:.06s } .reveal.d2{ animation-delay:.12s } .reveal.d3{ animation-delay:.18s } .reveal.d4{ animation-delay:.24s }
  @keyframes t-rise{ to{ opacity:1; transform:none; } }
  .opt:active,.btn:active{ transform:translateY(1px); }
}

/* ---- responsive ---- */
@media (max-width:640px){
  .wrap{ padding-left:18px; padding-right:18px; }
  .navlinks{ gap:14px; font-size:14px; }
  .hero .cta{ gap:10px; }
  .skills{ grid-template-columns:1fr; }
}
