:root {
  --ink: #0f172a;
  --text: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --bg: #ffffff;
  --bg-soft: #f8fafc;
  --bg-dark: #0b1220;
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-soft: #eff6ff;
  --error: #dc2626;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 4px 16px rgba(15, 23, 42, 0.06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 80px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }
h1, h2, h3 { color: var(--ink); line-height: 1.2; letter-spacing: -0.02em; margin: 0; }
p { margin: 0 0 14px; }
ul { margin: 0; padding-left: 20px; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 640px; }
[hidden] { display: none !important; }

/* header */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(255, 255, 255, 0.9); backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.brand { font-weight: 700; color: var(--ink); font-size: 17px; letter-spacing: -0.01em; white-space: nowrap; }
.brand:hover { color: var(--ink); }
.brand span { color: var(--accent); }
.brand { display: inline-flex; align-items: center; }
.brand img { display: block; margin-right: 10px; }
.brand span { margin-left: 0.28em; }
.site-nav { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.site-nav a { color: var(--muted); font-weight: 500; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); }
.site-nav .btn, .site-nav .btn[aria-current="page"] { color: #fff; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; font: inherit; font-size: 15px; font-weight: 600;
  color: #fff; background: var(--accent); border: 1px solid var(--accent); border-radius: 8px; cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-sm { padding: 8px 16px; font-size: 14px; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--bg-soft); border-color: #cbd5e1; color: var(--ink); }
.btn-light { background: #fff; color: var(--ink); border-color: #fff; }
.btn-light:hover { background: #e2e8f0; border-color: #e2e8f0; color: var(--ink); }
.btn:disabled { background: #f1f5f9; border-color: #f1f5f9; color: #94a3b8; cursor: not-allowed; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* sections */
section.block { padding: 88px 0; }
section.block.soft { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head h2 { font-size: 34px; margin-bottom: 14px; }
.section-head p { font-size: 18px; color: var(--muted); margin: 0; }

/* hero */
.hero { padding: 96px 0 80px; }
.hero .wrap { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: center; }
.hero h1 { font-size: 56px; letter-spacing: -0.035em; margin-bottom: 22px; }
.hero .lead { font-size: 20px; color: var(--muted); max-width: 560px; margin-bottom: 32px; }
.facts { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 8px 24px; }
.facts dl { margin: 0; }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.facts div:last-child { border-bottom: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; color: var(--ink); font-weight: 600; text-align: right; }

/* stats band */
.stats { background: var(--bg-dark); color: #cbd5e1; }
.stats .wrap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding-top: 36px; padding-bottom: 36px; }
.stats strong { display: block; color: #fff; font-size: 28px; font-weight: 700; line-height: 1.25; letter-spacing: -0.02em; }
.stats span { font-size: 14px; color: #94a3b8; }

.stats.rounded { border-radius: var(--radius); margin-bottom: 40px; }
.stats.rounded .wrap { padding-left: 28px; padding-right: 28px; }
section.block.flush-top { padding-top: 0; }

/* grids & cards */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card h3 { font-size: 19px; margin-bottom: 10px; }
.card h3 + .muted { margin-top: -4px; font-size: 15px; }
.card p:last-child { margin-bottom: 0; }
.card ul { color: var(--text); font-size: 15px; }
.card li + li { margin-top: 6px; }
.card.highlight { border-color: var(--accent); background: var(--accent-soft); }
.after-grid { margin: 28px 0 0; font-weight: 600; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.9em; background: var(--bg-soft); padding: 1px 5px; border-radius: 4px; }
.card-quote { font-size: 20px; line-height: 1.5; color: var(--ink); font-weight: 500; letter-spacing: -0.01em; }

.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 30px; margin-bottom: 12px; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: 5px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%232563eb'%3E%3Cpath d='M8.5 13.3 5.2 10l-1.1 1.1 4.4 4.4 8-8-1.1-1.1z'/%3E%3C/svg%3E") center/14px no-repeat;
}
.checklist.no li::before {
  background: #f1f5f9 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%2394a3b8'%3E%3Cpath d='M6 9h8v2H6z'/%3E%3C/svg%3E") center/14px no-repeat;
}

/* steps */
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.step { counter-increment: step; }
.step::before {
  content: counter(step); display: grid; place-items: center; width: 36px; height: 36px; margin-bottom: 16px;
  border-radius: 50%; background: var(--ink); color: #fff; font-weight: 700; font-size: 15px;
}
.step h3 { font-size: 17px; margin-bottom: 6px; }
.step p { font-size: 15px; color: var(--muted); margin: 0; }

/* curriculum */
.module { display: grid; grid-template-columns: 200px 1fr; gap: 32px; padding: 32px 0; border-top: 1px solid var(--line); }
.module:last-child { border-bottom: 1px solid var(--line); }
.module .when { font-size: 14px; color: var(--muted); }
.module .when strong { display: block; color: var(--accent); font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 4px; }
.module h3 { font-size: 22px; margin-bottom: 12px; }
.module ul { color: var(--text); }
.module li + li { margin-top: 6px; }

/* pricing */
.pricing { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.price-card { border-color: var(--ink); }
.price { font-size: 48px; font-weight: 700; color: var(--ink); letter-spacing: -0.03em; line-height: 1.1; margin-bottom: 6px; }
.was-line { margin: 0 0 6px; font-size: 14px; font-weight: 600; color: var(--accent-dark); }
.was, .was-line s { color: var(--muted); font-weight: 500; }
.price-tax { font-size: 18px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.price-card .checklist { margin: 20px 0 24px; }
.price-notes { display: grid; gap: 20px; }

/* instructor */
.instructor { display: grid; grid-template-columns: 96px 1fr; gap: 28px; align-items: start; }
.avatar { width: 96px; height: 96px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), #7c3aed); display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 28px; }

/* faq */
.faq { max-width: 760px; }
.faq details { border-bottom: 1px solid var(--line); padding: 20px 0; }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; font-weight: 600; color: var(--ink); font-size: 17px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-weight: 400; font-size: 22px; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { margin: 12px 0 0; color: var(--muted); }

/* cta */
.cta { background: var(--bg-dark); color: #cbd5e1; text-align: center; padding: 88px 0; }
.cta h2 { color: #fff; font-size: 38px; margin-bottom: 14px; }
.cta p { font-size: 18px; max-width: 560px; margin: 0 auto 30px; }
.cta .btn-row { justify-content: center; }
.cta .btn-ghost { color: #fff; border-color: #334155; }
.cta .btn-ghost:hover { background: #1e293b; color: #fff; }

/* footer */
.site-footer { border-top: 1px solid var(--line); padding: 28px 0; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-footer nav { display: flex; gap: 20px; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--ink); }

/* page header (inner pages) */
.page-head { padding: 72px 0 40px; }
.page-head h1 { font-size: 44px; margin-bottom: 14px; letter-spacing: -0.03em; }
.page-head p { font-size: 19px; color: var(--muted); max-width: 620px; margin: 0; }

/* legal pages */
.legal { padding-bottom: 88px; }
.legal h2 { font-size: 21px; margin: 40px 0 12px; }
.legal h3 { font-size: 17px; margin: 24px 0 8px; }
.legal ul { margin: 0 0 14px; }
.legal li + li { margin-top: 6px; }
.site-footer nav { flex-wrap: wrap; }

/* forms / flow panels */
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 36px; margin: 0 auto 96px; }
.panel h2 { font-size: 26px; margin-bottom: 10px; }
.panel .muted { color: var(--muted); }
.form { display: grid; gap: 18px; margin-top: 24px; }
label { display: grid; gap: 6px; font-size: 14px; font-weight: 600; color: var(--ink); }
input[type="email"], input[type="text"], textarea {
  width: 100%; padding: 12px 14px; font: inherit; font-size: 15px; color: var(--ink);
  border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; transition: border-color 0.15s, box-shadow 0.15s;
}
textarea { resize: vertical; min-height: 120px; }
input:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); }
.btn:focus-visible, a:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.check { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; color: var(--text); cursor: pointer; }
.check input { margin: 3px 0 0; width: 16px; height: 16px; accent-color: var(--accent); }
#contact-form { margin-top: 0; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.error { color: var(--error); font-size: 14px; margin: 0; min-height: 1em; }
.error:empty { display: none; }
.small { font-size: 14px; }

.weights { display: grid; gap: 10px; margin: 24px 0; }
.weights div { display: grid; grid-template-columns: 56px 1fr; gap: 16px; align-items: baseline; padding: 14px 16px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px; }
.weights strong { color: var(--accent); font-size: 18px; }
.weights span { font-size: 15px; }
.weights b { color: var(--ink); display: block; }

.quiz-meta { display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; }
.progress { height: 6px; background: #e2e8f0; border-radius: 999px; margin: 10px 0 28px; overflow: hidden; }
.progress > div { height: 100%; background: var(--accent); border-radius: 999px; transition: width 0.25s; }
fieldset { border: 0; margin: 0 0 24px; padding: 0; }
legend { font-size: 21px; font-weight: 600; color: var(--ink); margin-bottom: 18px; padding: 0; letter-spacing: -0.01em; }
.option { display: flex; align-items: center; gap: 12px; padding: 14px 16px; margin-bottom: 10px; border: 1px solid var(--line); border-radius: 8px; font-weight: 500; font-size: 15px; color: var(--text); cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.option:hover { border-color: #cbd5e1; }
.option:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); color: var(--ink); }
.option input { margin: 0; flex-shrink: 0; accent-color: var(--accent); }
.katex { font-size: 1.08em; }
legend .katex { font-size: 1.04em; }
.quiz-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.timer { font-variant-numeric: tabular-nums; font-weight: 700; font-size: 18px; color: var(--ink); background: var(--bg-soft); border: 1px solid var(--line); border-radius: 8px; padding: 4px 12px; }
.timer.low { color: var(--error); border-color: #fecaca; background: #fef2f2; }
.q-num { display: block; font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 8px; }
.quiz-nav { justify-content: space-between; }
.navigator { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; margin: 28px 0 20px; padding-top: 24px; border-top: 1px solid var(--line); }
.navigator button { aspect-ratio: 1; min-width: 0; padding: 0; font: inherit; font-size: 13px; font-weight: 600; color: var(--muted); background: #fff; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; }
.navigator button.answered { background: var(--accent-soft); border-color: #bfdbfe; color: var(--accent-dark); }
.navigator button[aria-current="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); color: var(--ink); }
.submit-bar { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; font-size: 14px; font-weight: 500; color: var(--accent); cursor: pointer; }
.link-btn:hover { color: var(--accent-dark); text-decoration: underline; }
.link-btn:disabled { color: var(--muted); cursor: not-allowed; text-decoration: none; }
.code-input { font-size: 22px !important; letter-spacing: 0.4em; font-variant-numeric: tabular-nums; max-width: 220px; }
.rules { margin: 0 0 24px; color: var(--text); font-size: 15px; }
.rules li + li { margin-top: 6px; }
#quiz-error { margin-top: 12px; }
#code-mode:empty { display: none; }

/* exam protections: no selection, blur when the window loses focus, email watermark */
.exam { position: relative; overflow: hidden; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
.exam .watermark {
  position: absolute; inset: 0; z-index: 2; pointer-events: none; overflow: hidden;
  display: flex; flex-wrap: wrap; align-content: space-around; justify-content: space-around; gap: 48px 32px;
  color: rgba(15, 23, 42, 0.06); font-size: 13px; font-weight: 600; transform: rotate(-18deg) scale(1.3);
}
.exam .cover { display: none; }
.exam.concealed > :not(.cover):not(.watermark) { filter: blur(14px); }
.exam.concealed .cover {
  display: grid; place-items: center; position: absolute; inset: 0; z-index: 3; cursor: pointer;
  text-align: center; font-weight: 600; color: var(--ink); background: rgba(255, 255, 255, 0.6);
}
@media print { body[data-page="placement"] main { display: none !important; } }

.cam-box { position: fixed; right: 16px; bottom: 16px; z-index: 20; margin: 0; width: 168px; background: var(--bg-dark); border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); }
.cam-box video { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transform: scaleX(-1); }
.cam-box figcaption { padding: 6px 10px; font-size: 12px; color: #e2e8f0; }
#intro-error { margin-bottom: 16px; }
.consent { display: grid; gap: 12px; margin: 0 0 20px; padding: 16px 18px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-soft); }
.consent .check { font-size: 14px; }
.consent .guardian { font-size: 14px; }
div.guardian { display: grid; gap: 12px; }
div.guardian[hidden] { display: none; }
@media (max-width: 640px) { .cam-box { width: 112px; right: 10px; bottom: 10px; } }
.breakdown { width: 100%; border-collapse: collapse; margin: 20px 0 24px; font-size: 15px; }
.breakdown th, .breakdown td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.breakdown th { color: var(--muted); font-weight: 600; font-size: 13px; }
.breakdown td:last-child, .breakdown th:last-child { text-align: right; font-variant-numeric: tabular-nums; }

.note { background: var(--accent-soft); border-radius: 8px; padding: 16px 18px; margin: 22px 0; color: var(--ink); font-size: 15px; }
.note p:last-child { margin: 0; }

/* responsive */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { font-size: 44px; }
  .grid-3, .steps { grid-template-columns: 1fr 1fr; }
  .stats .wrap { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .site-nav { gap: 16px; font-size: 14px; }
  .site-nav .hide-sm { display: none; }
  .hero { padding: 56px 0; }
  .hero h1 { font-size: 36px; }
  .hero .lead { font-size: 18px; }
  section.block, .cta { padding: 64px 0; }
  .section-head h2, .cta h2 { font-size: 28px; }
  .page-head { padding: 48px 0 28px; }
  .page-head h1 { font-size: 34px; }
  .grid-2, .grid-3, .steps, .pricing { grid-template-columns: 1fr; }
  .price { font-size: 40px; }
  .module { grid-template-columns: 1fr; gap: 8px; }
  .instructor { grid-template-columns: 1fr; }
  .panel { padding: 24px 20px; margin-bottom: 64px; }
  .navigator { grid-template-columns: repeat(6, 1fr); }
}
