/* Learn Carepatron v2 — Academy polish × carepatron.com design language */
* { box-sizing: border-box; margin: 0; padding: 0; letter-spacing: 0; }
:root {
  --bg: #fafaf3;            /* carepatron.com body */
  --card: #ffffff;
  --ink: #101010;
  --ink-60: rgba(16,16,16,.62);
  --ink-40: rgba(16,16,16,.42);
  --hairline: rgba(16,16,16,.10);
  --hairline-soft: rgba(16,16,16,.06);
  --purple: #5b1db1;
  --purple-hover: #4e18a0;
  --violet: #a379d5;
  --lilac: #e5ddfb;
  --cream: #fef6ec;
  --badge-purple: #ebe6fa;
  --badge-lime: #dcf2a8;
  --r-sm: 10px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --pill: 3.125rem;
  --shadow-1: 0 1px 2px rgba(16,16,16,.04);
  --shadow-2: 0 14px 40px -12px rgba(16,16,16,.14);
  --font: 'Helvetica Now Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; }
strong, b { font-weight: 700; }
button { font: inherit; cursor: pointer; background: transparent; border: none; color: inherit; }
:focus-visible { outline: 2px solid var(--purple); outline-offset: 2px; border-radius: 4px; }

.proto-tag {
  position: fixed; bottom: 14px; left: 14px; z-index: 90;
  font-size: 12px; font-weight: 700; color: var(--ink-60);
  background: var(--card); padding: 5px 12px; border-radius: var(--pill);
  border: 1px solid var(--hairline); box-shadow: var(--shadow-1);
}

/* ================= Nav ================= */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 250, 243, 0.88);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s var(--ease);
}
.nav.scrolled { border-bottom-color: var(--hairline-soft); }
.nav-inner {
  max-width: 1152px; margin: 0 auto; padding: 0 32px;
  height: 64px; display: flex; align-items: center; gap: 4px;
}
.brand { font-size: 17px; font-weight: 700; text-decoration: none; display: flex; align-items: center; gap: 9px; margin-right: 18px; }
.brand .mark { width: 24px; height: 24px; border-radius: 50%; background: var(--purple); position: relative; flex-shrink: 0; }
.brand .mark::after { content: ""; position: absolute; right: -4px; top: 4px; width: 14px; height: 14px; border-radius: 50%; background: var(--violet); }
.brand .suffix { font-weight: 400; color: var(--ink-60); }
.nav-links { display: flex; align-items: center; gap: 2px; font-size: 15px; }
.nav-links a { text-decoration: none; padding: 8px 13px; border-radius: var(--pill); color: var(--ink-60); transition: color .15s var(--ease), background .15s var(--ease); }
.nav-links a:hover { color: var(--ink); background: rgba(16,16,16,.05); }
.nav-search {
  margin-left: auto; display: flex; align-items: center; gap: 9px;
  background: var(--card); border: 1px solid var(--hairline);
  border-radius: var(--pill); padding: 8px 16px; min-width: 230px; cursor: text;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
.nav-search:hover, .nav-search:focus-within { border-color: rgba(16,16,16,.22); box-shadow: var(--shadow-1); }
.nav-search .icon { width: 15px; height: 15px; flex-shrink: 0; color: var(--ink-40); }
.nav-search input { border: none; outline: none; background: none; font: inherit; font-size: 15px; width: 100%; color: var(--ink); }
.nav-search input::placeholder { color: var(--ink-40); }
.nav-search kbd {
  font-family: inherit; font-size: 12px; font-weight: 700; color: var(--ink-40);
  border: 1px solid var(--hairline); border-radius: 5px; padding: 1px 6px;
}
.btn-pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 2.875rem; padding: 0 1.5rem;
  border-radius: var(--pill);
  font-size: 1.06rem; font-weight: 700; line-height: 1; text-decoration: none;
  border: 1px solid transparent; white-space: nowrap;
  transition: background-color .2s, border-color .2s, color .2s, transform .18s var(--ease);
}
.btn-pill:active { transform: scale(.985); }
.btn-primary { background: var(--purple); border-color: var(--purple); color: #fff; }
.btn-primary:hover { background: var(--purple-hover); border-color: var(--purple-hover); }
.btn-secondary { background: var(--card); border-color: var(--hairline); color: var(--ink); }
.btn-secondary:hover { border-color: var(--ink); }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { background: #2a2a2a; }
.btn-sm { height: 2.375rem; padding: 0 1.15rem; font-size: .94rem; }
.nav .btn-pill { margin-left: 10px; }

/* ================= Badges (carepatron.com mini-badge) ================= */
.badge {
  display: inline-block; font-size: 11.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--purple); background: var(--badge-purple);
  border-radius: 6px; padding: 4px 8px 3px; line-height: 1;
}
.badge-lime { background: var(--badge-lime); color: var(--ink); }

/* meta line */
.meta { font-size: 14.5px; color: var(--ink-60); display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.meta .badge { position: relative; top: -1px; }

/* ================= Page scaffolding ================= */
.page { max-width: 1152px; margin: 0 auto; padding: 0 32px; }
.page-narrow { max-width: 820px; margin: 0 auto; padding: 0 32px; }
.page-tight { max-width: 720px; margin: 0 auto; padding: 0 32px; }

/* ================= Hero (home) ================= */
.hero { padding: 96px 0 84px; text-align: center; }
.hero .badge { margin-bottom: 22px; }
.hero h1 {
  font-size: clamp(44px, 5vw, 64px); font-weight: 400; line-height: 1.12;
  max-width: 760px; margin: 0 auto 20px;
}
.hero .lede { font-size: 20px; line-height: 1.5; color: var(--ink-60); max-width: 560px; margin: 0 auto 36px; }
.hero-ctas { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }

/* ================= Sections ================= */
.section { padding: 30px 0 44px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.section-head h2 { font-size: clamp(26px, 2.6vw, 32px); font-weight: 400; line-height: 1.25; }
.section-head .more { font-size: 15px; font-weight: 700; color: var(--purple); text-decoration: none; white-space: nowrap; transition: color .15s; }
.section-head .more:hover { color: var(--purple-hover); }
.section-sub { font-size: 16.5px; color: var(--ink-60); max-width: 560px; margin-bottom: 26px; }

/* ================= Course cards ================= */
.area-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 20px; }
.area-card {
  background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg);
  text-decoration: none; overflow: hidden;
  display: flex; flex-direction: column;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.area-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: rgba(16,16,16,.16); }
.area-card .body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.area-card h3 { font-size: 19px; font-weight: 700; line-height: 1.3; }
.area-card .desc { font-size: 15px; line-height: 1.5; color: var(--ink-60); flex: 1; }
.area-card .meta { margin-top: 8px; }

/* Real product-UI thumbnails (from carepatron.com) */
.thumb { display: block; position: relative; overflow: hidden; aspect-ratio: 16 / 9.4; background: var(--cream); }
.thumb img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .35s var(--ease);
}
.area-card:hover .thumb img { transform: scale(1.03); }

/* ================= List rows (popular lessons) ================= */
.list-card { background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); overflow: hidden; margin-top: 20px; }
.list-row {
  display: flex; align-items: center; gap: 18px;
  padding: 16px 22px; text-decoration: none;
  transition: background .15s var(--ease);
}
.list-row + .list-row { border-top: 1px solid var(--hairline-soft); }
.list-row:hover { background: var(--bg); }
.list-row .t { font-size: 16.5px; font-weight: 700; }
.list-row .m { margin-left: auto; }
.list-row .go { color: var(--ink-40); font-size: 16px; transition: transform .15s var(--ease), color .15s var(--ease); }
.list-row:hover .go { transform: translateX(3px); color: var(--purple); }

/* ================= Playbook rows (bare, hairline) ================= */
.pb-rows { margin-top: 6px; }
.pb-row {
  display: flex; align-items: baseline; gap: 18px;
  padding: 17px 2px; text-decoration: none;
  border-top: 1px solid var(--hairline-soft);
  transition: padding .18s var(--ease);
}
.pb-row:last-child { border-bottom: 1px solid var(--hairline-soft); }
.pb-row .t { font-size: 17.5px; transition: color .15s var(--ease); }
.pb-row:hover .t { color: var(--purple); }
.pb-row .m { margin-left: auto; }

/* ================= Dark CTA band (carepatron.com canvas) ================= */
.cta-band {
  background: var(--ink); color: #fff; border-radius: var(--r-xl);
  padding: 64px 48px; margin: 44px 0 0; text-align: center;
}
.cta-band h2 { font-size: clamp(28px, 3vw, 38px); font-weight: 400; line-height: 1.2; margin-bottom: 12px; }
.cta-band p { font-size: 17px; color: rgba(255,255,255,.72); max-width: 460px; margin: 0 auto 30px; }
.cta-band .btn-pill { background: #fff; border-color: #fff; color: var(--ink); }
.cta-band .btn-pill:hover { background: var(--cream); border-color: var(--cream); }
.cta-band .quiet-link { display: inline-block; margin-left: 18px; font-size: 16px; color: rgba(255,255,255,.72); }
.cta-band .quiet-link:hover { color: #fff; }

/* ================= Footer ================= */
.footer {
  margin-top: 64px; border-top: 1px solid var(--hairline-soft);
  padding: 30px 0 40px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 14.5px; color: var(--ink-60);
}
.footer nav { display: flex; gap: 22px; }
.footer a { text-decoration: none; color: var(--ink-60); }
.footer a:hover { color: var(--ink); }

/* ================= Course page ================= */
.crumbs { padding: 26px 0 0; font-size: 14.5px; color: var(--ink-60); }
.crumbs a { text-decoration: none; color: var(--ink-60); }
.crumbs a:hover { color: var(--purple); }
.crumbs .sep { margin: 0 8px; color: var(--ink-40); }

.course-hero { padding: 40px 0 14px; }
.course-hero .badge { margin-bottom: 18px; }
.course-hero h1 { font-size: clamp(38px, 4.4vw, 54px); font-weight: 400; line-height: 1.15; margin-bottom: 16px; }
.course-hero .lede { font-size: 19px; line-height: 1.55; color: var(--ink-60); max-width: 620px; margin-bottom: 20px; }
.course-hero .meta { margin-bottom: 30px; }
.course-ctas { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.course-ctas .note { font-size: 14.5px; color: var(--ink-60); }

.divider { border: none; border-top: 1px solid var(--hairline-soft); margin: 44px 0; }

.course-body h2 { font-size: 26px; font-weight: 400; margin: 0 0 20px; }
.learn-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 28px; max-width: 720px; }
.learn-item { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; line-height: 1.5; }
.learn-item .ck {
  width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; margin-top: 2px;
  background: var(--badge-purple); position: relative;
}
.learn-item .ck::after {
  content: ""; position: absolute; left: 5.5px; top: 5.5px;
  width: 8px; height: 4.5px;
  border-left: 2px solid var(--purple); border-bottom: 2px solid var(--purple);
  transform: rotate(-45deg);
}

.curriculum { background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); overflow: hidden; max-width: 720px; }
.lesson-row {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 20px; text-decoration: none;
  transition: background .15s var(--ease);
}
.lesson-row + .lesson-row { border-top: 1px solid var(--hairline-soft); }
.lesson-row:hover { background: var(--bg); }
.lesson-row .n {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  border: 1px solid var(--hairline); color: var(--ink-60);
  font-weight: 700; font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  position: relative; background: var(--card);
}
.lesson-row.is-done .n { background: var(--purple); border-color: var(--purple); color: transparent; }
.lesson-row.is-done .n::after {
  content: ""; position: absolute; left: 10px; top: 10px;
  width: 10px; height: 5.5px;
  border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}
.lesson-row.is-done .t { color: var(--ink-40); }
.lesson-row .n.q { background: var(--badge-lime); border-color: var(--badge-lime); color: var(--ink); }
.lesson-row .t { font-size: 16.5px; font-weight: 700; }
.lesson-row .resume-chip {
  font-size: 12px; font-weight: 700; color: var(--purple);
  background: var(--badge-purple); border-radius: var(--pill); padding: 3px 10px; margin-left: 4px;
  text-transform: uppercase; letter-spacing: .04em;
}
.lesson-row .m { margin-left: auto; font-size: 14.5px; color: var(--ink-60); white-space: nowrap; }

.about-course { max-width: 620px; }
.about-course p { margin-bottom: 13px; font-size: 16.5px; color: var(--ink-60); }
.about-course p b { color: var(--ink); }
.about-course .fine { font-size: 14.5px; color: var(--ink-40); }

/* ================= Lesson page ================= */
.lesson-grid {
  display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 64px;
  max-width: 1152px; margin: 0 auto; padding: 40px 32px 160px;
}
.rail { position: sticky; top: 96px; align-self: start; font-size: 14.5px; }
.rail .back { display: inline-flex; align-items: center; gap: 6px; font-size: 14.5px; text-decoration: none; color: var(--ink-60); font-weight: 700; margin-bottom: 22px; }
.rail .back:hover { color: var(--purple); }
.rail .course-label { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-40); margin-bottom: 12px; }
.rail ol { list-style: none; display: flex; flex-direction: column; }
.rail li { border-left: 1px solid var(--hairline-soft); }
.rail a {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; margin-left: -1px; text-decoration: none; color: var(--ink-60);
  border-left: 2px solid transparent;
  transition: color .15s var(--ease), border-color .15s var(--ease);
}
.rail a:hover { color: var(--ink); }
.rail .tickc { width: 15px; height: 15px; border-radius: 50%; flex-shrink: 0; border: 1px solid var(--hairline); background: var(--card); position: relative; }
.rail .is-done .tickc { background: var(--purple); border-color: var(--purple); }
.rail .is-done .tickc::after {
  content: ""; position: absolute; left: 3.5px; top: 3.5px;
  width: 6px; height: 3.5px;
  border-left: 1.5px solid #fff; border-bottom: 1.5px solid #fff;
  transform: rotate(-45deg);
}
.rail .tickc.q { background: var(--badge-lime); border-color: var(--badge-lime); }
.rail .is-current { color: var(--ink); font-weight: 700; border-left-color: var(--purple); }
.rail .is-current .tickc { border-color: var(--purple); }

article { max-width: 660px; }
.lesson-eyebrow { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14.5px; color: var(--ink-60); margin-bottom: 16px; }
article h1 { font-size: clamp(34px, 3.8vw, 44px); font-weight: 400; line-height: 1.15; margin-bottom: 16px; }
.summary { font-size: 19px; line-height: 1.55; color: var(--ink-60); margin-bottom: 34px; }
article h2 { font-size: 25px; font-weight: 400; margin: 48px 0 14px; }
article > p, article section p { margin-bottom: 14px; font-size: 16.5px; }
article ul { margin: 0 0 14px 22px; }
article li { margin-bottom: 7px; font-size: 16.5px; }

/* task card */
.taskcard {
  background: var(--badge-purple); border-radius: var(--r-lg);
  padding: 24px 26px; margin: 0 0 14px;
  display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center;
}
.taskcard .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--purple); margin-bottom: 6px; }
.taskcard .outcome { font-size: 17.5px; font-weight: 700; margin-bottom: 8px; line-height: 1.4; }
.taskcard .path { font-size: 14.5px; color: var(--ink-60); }
.taskcard .path b { color: var(--ink); }

/* prereqs */
.prereqs { padding: 18px 0 4px; }
.prereqs .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-40); margin-bottom: 10px; }
.prereqs ul { list-style: none; margin: 0; display: flex; flex-direction: column; gap: 7px; }
.prereqs li { display: flex; gap: 11px; align-items: baseline; font-size: 16px; color: var(--ink-60); margin: 0; }
.prereqs li::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--violet); flex-shrink: 0; position: relative; top: -3px; }

/* video */
.video {
  position: relative; border-radius: var(--r-lg); overflow: hidden;
  background: var(--ink); aspect-ratio: 16 / 9;
  display: flex; align-items: center; justify-content: center;
  margin: 28px 0 10px; cursor: pointer;
}
.video .playbtn {
  width: 62px; height: 62px; border-radius: 50%;
  background: #fff; display: flex; align-items: center; justify-content: center;
  transition: transform .15s var(--ease);
}
.video:hover .playbtn { transform: scale(1.07); }
.video .playbtn::after {
  content: ""; margin-left: 4px;
  border-left: 18px solid var(--purple);
  border-top: 11px solid transparent; border-bottom: 11px solid transparent;
}
.video .duration {
  position: absolute; bottom: 12px; right: 14px;
  font-size: 12.5px; font-weight: 700; color: #fff;
  background: rgba(16,16,16,.55); padding: 4px 10px; border-radius: var(--pill);
}
.video-caption { font-size: 14.5px; color: var(--ink-40); margin-bottom: 30px; }

/* steps */
.steps { counter-reset: step; background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); overflow: hidden; margin: 20px 0 6px; }
.step { display: flex; gap: 16px; align-items: flex-start; padding: 17px 20px; }
.step + .step { border-top: 1px solid var(--hairline-soft); }
.step::before {
  counter-increment: step; content: counter(step);
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
  background: var(--badge-purple); color: var(--purple);
  font-weight: 700; font-size: 13.5px;
  display: flex; align-items: center; justify-content: center;
  margin-top: 1px;
}
.step p { margin: 0; font-size: 16px; line-height: 1.55; }

/* check it worked */
.checkit { background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); padding: 26px 28px; margin: 46px 0 8px; }
.checkit .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--purple); margin-bottom: 4px; }
.checkit .lead { font-size: 16px; color: var(--ink-60); margin-bottom: 16px; }
.checkit .item {
  display: flex; gap: 13px; align-items: flex-start; width: 100%;
  text-align: left; font-size: 16px; line-height: 1.5; padding: 10px 12px; margin: 0 -12px; width: calc(100% + 24px);
  border-radius: var(--r-sm);
  transition: background .15s var(--ease);
}
.checkit .item:hover { background: var(--bg); }
.checkit .cbx {
  width: 21px; height: 21px; border-radius: 7px; flex-shrink: 0; margin-top: 2px;
  border: 1.5px solid var(--hairline); background: var(--card);
  position: relative; transition: all .15s var(--ease);
}
.checkit .item.on .cbx { background: var(--purple); border-color: var(--purple); }
.checkit .item.on .cbx::after {
  content: ""; position: absolute; left: 5px; top: 5px;
  width: 9px; height: 5px;
  border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}
.checkit .item.on span:last-child { color: var(--ink-40); }
.checkit .allgood {
  margin: 14px -12px 0; padding: 12px 14px; border-radius: var(--r-sm);
  background: var(--badge-lime); font-size: 15px; font-weight: 700;
}

/* annotated still */
.still { margin: 26px 0 8px; }
.still-frame { background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); padding: 20px; position: relative; }
.still-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-40); margin-bottom: 12px; }
.still-row {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 13px; border-radius: var(--r-sm); background: var(--bg);
  margin-bottom: 6px; font-size: 15px;
}
.still-row .cb { width: 15px; height: 15px; border-radius: 5px; border: 1.5px solid var(--hairline); background: var(--card); flex-shrink: 0; }
.still-row .cb.on { background: var(--purple); border-color: var(--purple); }
.still-row .amt { margin-left: auto; font-weight: 700; }
.callout {
  position: relative; display: block; width: max-content; max-width: 90%;
  margin: 14px 0 4px auto;
  background: var(--ink); color: #fff;
  font-size: 13px; font-weight: 700; line-height: 1.4;
  padding: 9px 13px; border-radius: var(--r-sm);
}
.callout::before {
  content: ""; position: absolute; right: 22px; top: -6px;
  border-bottom: 6px solid var(--ink);
  border-left: 5px solid transparent; border-right: 5px solid transparent;
}
.still-caption { font-size: 14.5px; color: var(--ink-40); margin-top: 10px; }

/* expanders */
details.layer { border-top: 1px solid var(--hairline-soft); }
details.layer:last-of-type { border-bottom: 1px solid var(--hairline-soft); }
details.layer summary {
  list-style: none; cursor: pointer;
  padding: 17px 2px; font-size: 16.5px; font-weight: 700;
  display: flex; align-items: center; gap: 12px;
  transition: color .15s var(--ease);
}
details.layer summary:hover { color: var(--purple); }
details.layer summary::-webkit-details-marker { display: none; }
details.layer summary::after {
  content: "+"; margin-left: auto; color: var(--ink-40); font-size: 21px; font-weight: 400;
  transition: transform .2s var(--ease);
}
details.layer[open] summary::after { transform: rotate(45deg); }
details.layer .layer-body { padding: 2px 2px 20px; font-size: 16px; color: var(--ink-60); }
details.layer .layer-body p { margin-bottom: 10px; }
details.layer .layer-body strong { color: var(--ink); }

/* finish / next */
.finish {
  margin: 48px 0 0; background: var(--card); border: 1px solid var(--hairline);
  border-radius: var(--r-lg); padding: 20px 24px;
  display: flex; align-items: center; gap: 18px; text-decoration: none;
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.finish:hover { border-color: rgba(16,16,16,.18); box-shadow: var(--shadow-1); }
.finish .k { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-40); margin-bottom: 3px; }
.finish .t { font-size: 17px; font-weight: 700; }
.finish .go { margin-left: auto; color: var(--purple); font-size: 18px; }

/* floating pill */
.pill {
  position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 80px);
  z-index: 60; display: flex; align-items: center; gap: 4px;
  background: var(--card); border: 1px solid var(--hairline);
  border-radius: var(--pill); padding: 6px;
  box-shadow: var(--shadow-2);
  transition: transform .3s var(--ease);
}
.pill.show { transform: translate(-50%, 0); }
.pill a, .pill button {
  font-size: 14.5px; font-weight: 700; padding: 10px 16px; border-radius: var(--pill); text-decoration: none;
  transition: background .15s var(--ease); white-space: nowrap;
}
.pill a:hover { background: var(--bg); }
.pill .muted { color: var(--ink-60); font-weight: 400; }
.pill .done { background: var(--purple); color: #fff; }
.pill .done:hover { background: var(--purple-hover); }

/* ================= Quiz page ================= */
.quiz-wrap { max-width: 640px; margin: 0 auto; padding: 0 32px 90px; }
.quiz-hero { padding: 34px 0 30px; }
.quiz-hero .badge { margin-bottom: 18px; }
.quiz-hero h1 { font-size: clamp(34px, 4vw, 46px); font-weight: 400; line-height: 1.15; margin-bottom: 14px; }
.quiz-hero .lede { font-size: 18px; line-height: 1.55; color: var(--ink-60); }

.quiz-progress { display: flex; align-items: center; gap: 16px; margin: 6px 0 18px; }
.quiz-progress .count { font-size: 14.5px; font-weight: 700; color: var(--ink-60); white-space: nowrap; }
.track { flex: 1; height: 5px; border-radius: 3px; background: rgba(16,16,16,.08); overflow: hidden; }
.track .fill { display: block; height: 100%; width: 0%; border-radius: 3px; background: var(--purple); transition: width .4s var(--ease); }

.quiz-card {
  background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg);
  padding: 30px 32px;
  transition: opacity .25s var(--ease), transform .25s var(--ease);
}
.quiz-card.swap { opacity: 0; transform: translateY(6px); }
.quiz-card .q { font-size: 21px; font-weight: 700; line-height: 1.35; margin-bottom: 20px; }
.opts { display: flex; flex-direction: column; gap: 9px; }
.opt {
  display: flex; align-items: flex-start; gap: 12px;
  text-align: left; font-size: 16px; line-height: 1.45;
  background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-md);
  padding: 14px 16px; width: 100%;
  transition: border-color .15s var(--ease), background .15s var(--ease);
}
.opt .key {
  width: 24px; height: 24px; border-radius: 8px; flex-shrink: 0;
  border: 1px solid var(--hairline);
  font-size: 12.5px; font-weight: 700; color: var(--ink-40);
  display: flex; align-items: center; justify-content: center;
  margin-top: -1px;
  transition: all .15s var(--ease);
}
.opt:hover:not(:disabled) { border-color: var(--purple); }
.opt:hover:not(:disabled) .key { border-color: var(--purple); color: var(--purple); }
.opt:disabled { cursor: default; }
.opt.right { border-color: var(--purple); background: var(--badge-purple); font-weight: 700; }
.opt.right .key { background: var(--purple); border-color: var(--purple); color: #fff; }
.opt.wrong { color: var(--ink-40); }
.opt.faded { opacity: .55; }

.fb { margin-top: 18px; padding: 15px 17px; border-radius: var(--r-md); background: var(--bg); font-size: 15.5px; line-height: 1.55; color: var(--ink-60); }
.fb b { color: var(--ink); }
.quiz-actions { display: flex; align-items: center; justify-content: flex-end; gap: 14px; margin-top: 20px; min-height: 46px; }

/* quiz result */
.result-head { text-align: center; padding: 6px 0 26px; }
.result-head .score { font-size: 56px; font-weight: 400; line-height: 1.1; }
.result-head .score b { color: var(--purple); font-weight: 400; }
.result-head p { font-size: 17px; color: var(--ink-60); max-width: 440px; margin: 10px auto 0; }
.recap { background: var(--card); border: 1px solid var(--hairline); border-radius: var(--r-lg); overflow: hidden; }
.recap-row { display: flex; align-items: center; gap: 13px; padding: 15px 20px; font-size: 15.5px; }
.recap-row + .recap-row { border-top: 1px solid var(--hairline-soft); }
.recap-row .rc { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; background: var(--purple); position: relative; }
.recap-row .rc::after {
  content: ""; position: absolute; left: 5.5px; top: 5.5px;
  width: 8px; height: 4.5px;
  border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}
.recap-row.missed .rc { background: var(--card); border: 1.5px solid var(--violet); }
.recap-row.missed .rc::after { display: none; }
.recap-row .qq { color: var(--ink-60); }
.recap-row .revisit { margin-left: auto; font-size: 14.5px; font-weight: 700; color: var(--purple); text-decoration: none; white-space: nowrap; }
.recap-row .revisit:hover { color: var(--purple-hover); }
.result-ctas { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 30px; }

/* ================= Responsive ================= */
@media (max-width: 980px) {
  .area-grid { grid-template-columns: repeat(2, 1fr); }
  .nav-links { display: none; }
}
@media (max-width: 860px) {
  .lesson-grid { grid-template-columns: 1fr; gap: 28px; padding: 28px 22px 160px; }
  .rail { position: static; }
  .rail ol { display: none; }
  .callout { position: static; max-width: none; margin-top: 10px; display: inline-block; }
  .callout::before { display: none; }
  .page, .page-narrow, .page-tight { padding: 0 22px; }
  .hero { padding: 64px 0 56px; }
  .learn-grid { grid-template-columns: 1fr; }
  .cta-band { padding: 48px 28px; }
}
@media (max-width: 620px) {
  .area-grid { grid-template-columns: 1fr; }
  .nav-search { display: none; }
  .quiz-wrap { padding: 0 22px 70px; }
  .quiz-card { padding: 24px 20px; }
  .list-row .m .badge { display: none; }
}
