/* CTRL+ALT+DEFEND career assessment - SquareUp dark/lime skin, app density.
   System fonts only (no third-party requests; keeps the "nothing collected"
   claim honest). Swap in a self-hosted display woff2 later if desired. */

:root {
  --bg: #0d0d0d;
  --surface: #161616;
  --surface-2: #1e1e1e;
  --border: #2b2b2b;
  --border-strong: #3a3a3a;
  --text: #f4f4f2;
  --muted: #b4b4ae;          /* ~7:1 on --bg, passes AA body */
  --lime: #c6f84e;
  --lime-press: #b2e63f;
  --amber: #f4b740;
  --radius: 14px;
  --maxw: 720px;
  --display: ui-sans-serif, system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --body: ui-sans-serif, system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  padding: 0 16px calc(24px + env(safe-area-inset-bottom));
}

#app { max-width: var(--maxw); margin: 0 auto; }

.skip-link {
  position: absolute; left: -999px; top: 0;
  background: var(--lime); color: #000; padding: 10px 14px; border-radius: 8px; z-index: 10;
}
.skip-link:focus { left: 12px; top: 12px; }

.noscript { max-width: var(--maxw); margin: 48px auto; text-align: center; }
.noscript a { color: var(--lime); }

/* ---- Typography ---- */
h1, h2, h3 { font-family: var(--display); font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; margin: 0 0 .5em; }
h1 { font-size: clamp(1.9rem, 6vw, 3rem); }
h2 { font-size: clamp(1.4rem, 4.5vw, 2rem); }
.eyebrow { color: var(--lime); font-family: var(--display); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; }
.lead { color: var(--muted); font-size: 1.06rem; }
.muted { color: var(--muted); }

/* ---- Layout helpers ---- */
.screen { padding: clamp(28px, 8vh, 64px) 0 40px; animation: fade .3s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.stack > * + * { margin-top: 16px; }
.center { text-align: center; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 26px; border-radius: 999px; border: 1px solid transparent;
  font: inherit; font-weight: 700; font-family: var(--display); letter-spacing: -0.01em;
  cursor: pointer; text-decoration: none; transition: transform .08s ease, background .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--lime); color: #000; }
.btn-primary:hover { background: var(--lime-press); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--lime); }
.btn-full { width: 100%; }
.btn:focus-visible, a:focus-visible, input:focus-visible + .opt, .opt:focus-within {
  outline: 3px solid var(--lime); outline-offset: 2px;
}
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---- Cards ---- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; }
.card-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 560px) { .card-grid { grid-template-columns: 1fr 1fr; } }

/* Selectable career card */
.pick {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  text-align: left; width: 100%; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px 18px; color: var(--text); font: inherit; cursor: pointer;
}
.pick:hover { border-color: var(--border-strong); }
.pick .arrow { color: var(--lime); font-weight: 700; }

/* Numbered "how it works" blocks */
.steps { display: grid; gap: 14px; margin-top: 24px; }
@media (min-width: 640px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step .num { font-family: var(--display); font-weight: 700; font-size: 2.6rem; color: var(--lime); line-height: 1; }
.step h3 { margin: 6px 0 4px; font-size: 1.05rem; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }

/* ---- Progress ---- */
.progress-wrap { position: sticky; top: 0; background: var(--bg); padding: 14px 0 10px; z-index: 5; }
.progress-meta { display: flex; justify-content: space-between; font-size: .85rem; color: var(--muted); margin-bottom: 8px; }
.progress-track { height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--lime); width: 0; transition: width .35s ease; }

/* ---- Quiz question + Likert ---- */
.q { border: 0; margin: 0 0 22px; padding: 0; }
.q legend { font-family: var(--display); font-weight: 600; font-size: 1.12rem; padding: 0 0 12px; }
.likert { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.likert input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  min-height: 60px; padding: 8px 4px; border: 1px solid var(--border-strong); border-radius: 12px;
  background: var(--surface); cursor: pointer; text-align: center;
}
.opt .n { font-family: var(--display); font-weight: 700; font-size: 1.15rem; }
.opt .l { font-size: .62rem; color: var(--muted); line-height: 1.1; }
.opt:hover { border-color: var(--muted); }
/* Selected: not colour alone - lime fill + black text + ring + bold */
input:checked + .opt {
  background: var(--lime); border-color: var(--lime); color: #000; font-weight: 700;
  box-shadow: inset 0 0 0 2px #000;
}
input:checked + .opt .l { color: #000; }
.likert-ends { display: flex; justify-content: space-between; font-size: .72rem; color: var(--muted); margin-top: 6px; }
.q.unanswered legend::after { content: " · answer to continue"; color: var(--amber); font-weight: 600; font-size: .85rem; }
.q.unanswered .likert { outline: 2px solid var(--amber); outline-offset: 6px; border-radius: 14px; }

.affirm { color: var(--lime); font-family: var(--display); font-weight: 600; margin: 4px 0 20px; }

/* ---- Result ---- */
.badge { display: inline-block; background: var(--lime); color: #000; font-family: var(--display); font-weight: 700; padding: 6px 14px; border-radius: 999px; letter-spacing: .02em; }
.role-card { border: 1px solid var(--lime); }
.scores { display: grid; gap: 10px; margin: 6px 0; }
.score-row { display: grid; grid-template-columns: 92px 1fr 34px; align-items: center; gap: 10px; font-size: .92rem; }
.score-bar { height: 12px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.score-bar > span { display: block; height: 100%; background: var(--lime); border-radius: 999px; }
.score-bar.dim > span { background: var(--border-strong); }
.quote { border-left: 3px solid var(--lime); padding: 4px 0 4px 14px; color: var(--muted); }
.callout { border-radius: var(--radius); padding: 16px; border: 1px solid var(--border); }
.callout.agree { border-color: var(--lime); }
.callout.diverge { border-color: var(--amber); }
.cta-block { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; text-align: center; margin-top: 28px; }
.foot { color: var(--muted); font-size: .8rem; text-align: center; margin-top: 28px; }

/* ---- Roadmap page ---- */
.backlink { display: inline-block; color: var(--lime); text-decoration: none; font-weight: 600; margin-bottom: 4px; }
.backlink:hover { text-decoration: underline; }
.chip { display: inline-block; background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 999px; padding: 8px 14px; font-size: .85rem; color: var(--text); }
.rm-phase { margin-top: 30px; }
.rm-phase h2 { font-size: 1.15rem; color: var(--lime); border-bottom: 1px solid var(--border); padding-bottom: 8px; }
.rm-item { padding: 14px 16px; }
.rm-item-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.rm-item-head strong { font-family: var(--display); font-size: 1rem; }
.tag { font-size: .68rem; text-transform: uppercase; letter-spacing: .08em; color: var(--bg); background: var(--muted); border-radius: 999px; padding: 3px 9px; white-space: nowrap; }
.rm-meta { color: var(--lime); font-size: .85rem; margin-top: 4px; }
.rm-res { color: var(--muted); font-size: .9rem; margin: 6px 0 0; }

/* ---- First 3 steps checklist ---- */
.steps-list { list-style: none; counter-reset: step; margin: 8px 0 0; padding: 0; }
.step-item {
  display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start;
  padding: 12px 0; border-top: 1px solid var(--border);
}
.step-item:first-child { border-top: 0; }
.step-item input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--lime); cursor: pointer; }
.step-item label { cursor: pointer; }
.step-item.done label { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--border-strong); }

/* ---- Email capture ---- */
.capture .field { display: block; text-align: left; }
.capture .field > span { display: block; font-size: .85rem; color: var(--muted); margin-bottom: 6px; }
.capture input[type="text"],
.capture input[type="email"] {
  width: 100%; min-height: 48px; padding: 0 14px; font: inherit; color: var(--text);
  background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 12px;
}
.capture input[type="text"]:focus-visible,
.capture input[type="email"]:focus-visible { outline: 3px solid var(--lime); outline-offset: 2px; border-color: var(--lime); }
.capture .consent { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; text-align: left; font-size: .9rem; color: var(--muted); }
.capture .consent input { width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--lime); cursor: pointer; }
.capture-msg { min-height: 1.2em; margin: 0; font-size: .9rem; color: var(--amber); text-align: left; }
.capture-msg.err { color: var(--amber); }

/* ---- Consent banner ---- */
.consent-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 10px 20px; padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
  background: var(--surface); border-top: 1px solid var(--border-strong);
}
.consent-bar-text { margin: 0; color: var(--muted); font-size: .9rem; max-width: 620px; }
.consent-bar-text a { color: var(--lime); }
.consent-bar-btns { display: flex; gap: 10px; }
.consent-bar .btn { min-height: 42px; padding: 0 20px; }

@media (prefers-reduced-motion: reduce) {
  *, .screen { animation: none !important; transition: none !important; }
}

/* ---- Print / download my plan ---- */
@media print {
  body { background: #fff; color: #000; padding: 0; }
  .btn, .btn-row, .capture, .consent-bar, .progress-wrap, .skip-link, .foot .btn { display: none !important; }
  .screen { animation: none; padding: 0; }
  .card, .role-card, .rm-item, .cta-block { background: #fff !important; border: 1px solid #bbb !important; box-shadow: none !important; }
  .cta-block { border: 0 !important; }
  a { color: #000 !important; text-decoration: underline; }
  .eyebrow, .badge, .rm-phase h2, .rm-phase h3, .affirm, .quote { color: #000 !important; }
  .badge { border: 1px solid #000; }
  .score-bar { border: 1px solid #000; }
  .score-bar > span { background: #000 !important; }
}

/* ---- Pre-render fallback ----
   Crawlable copy inside #app. app.replaceChildren() wipes it on first render, so
   only crawlers and no-JS visitors ever see it. Styled so it reads properly for
   the latter rather than dumping unstyled markup on them. */
.seo-fallback { max-width: var(--maxw); margin: 0 auto; padding: clamp(28px, 8vh, 64px) 0 48px; }
.seo-fallback h2 { margin-top: 1.6em; }
.seo-fallback h3 { margin-top: 1.2em; font-size: 1.05rem; }
.seo-fallback ul { padding-left: 1.2em; }
.seo-fallback li { margin-bottom: .5em; }
.seo-fallback a { color: var(--lime); }

/* ---- CV Checker additions ---- */
.drop { display:flex; flex-direction:column; gap:6px; align-items:center; justify-content:center;
  padding:28px 20px; border:2px dashed var(--line,#3a3a34); border-radius:12px; cursor:pointer;
  text-align:center; transition:border-color .15s ease, background .15s ease; }
.drop:hover, .drop.over { border-color:var(--lime); background:rgba(198,248,78,.06); }
.drop.has-file { border-style:solid; border-color:var(--lime); }
.drop-main { font-weight:700; }
.drop:focus-within { outline:2px solid var(--lime); outline-offset:3px; }

.verdict { border-radius:12px; padding:16px 18px; margin:4px 0 8px; }
.verdict p { margin:6px 0 0; }
.verdict-ok { background:rgba(198,248,78,.10); border:1px solid rgba(198,248,78,.45); }
.verdict-bad { background:rgba(251,113,133,.10); border:1px solid rgba(251,113,133,.5); }

.band { font-weight:700; margin:0 0 4px; }
.band-good { color:var(--lime); }
.band-warn { color:#e0ab4a; }
.band-bad  { color:#fb7185; }

.stat-row { display:flex; flex-wrap:wrap; gap:12px; }
.stat { flex:1 1 140px; background:rgba(255,255,255,.04); border-radius:10px; padding:12px 14px; }
.stat-n { display:block; font-size:1.7rem; font-weight:800; line-height:1.1; }
.stat-l { display:block; color:var(--muted); font-size:.86rem; margin-top:2px; }

.capture { display:flex; flex-direction:column; gap:6px; }
.capture label { font-weight:600; font-size:.92rem; }
.capture input[type=text], .capture input[type=email] {
  padding:11px 12px; border-radius:8px; border:1px solid var(--line,#3a3a34);
  background:rgba(255,255,255,.04); color:inherit; font:inherit; }
.capture input:focus-visible { outline:2px solid var(--lime); outline-offset:2px; }
.capture .check { display:flex; gap:10px; align-items:flex-start; font-weight:400;
  color:var(--muted); font-size:.9rem; margin-top:6px; }
.capture .btn { margin-top:10px; }
.error { color:#fb7185; font-weight:600; }
.note { background:rgba(255,255,255,.05); border-left:3px solid var(--lime);
  padding:10px 14px; border-radius:0 8px 8px 0; }
.bar { height:6px; background:rgba(255,255,255,.08); border-radius:99px; overflow:hidden; }
.bar-fill.indeterminate { height:100%; width:40%; background:var(--lime);
  animation:slide 1.1s ease-in-out infinite; }
@keyframes slide { 0%{margin-left:-40%} 100%{margin-left:100%} }
@media (prefers-reduced-motion:reduce){ .bar-fill.indeterminate{animation:none;width:100%} }
.pick.picked { border-color:var(--lime); background:rgba(198,248,78,.08); }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px;
  overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; border:0; }

/* Pre-render fallback (see index.html). */
.seo-fallback { max-width:var(--maxw); margin:0 auto; padding:clamp(28px,8vh,64px) 0 48px; }
.seo-fallback h2 { margin-top:1.6em; }
.seo-fallback h3 { margin-top:1.2em; font-size:1.05rem; }
.seo-fallback ul { padding-left:1.2em; }
.seo-fallback li { margin-bottom:.5em; }
.seo-fallback a { color:var(--lime); }
