/* HSM University
   Layout: marketplace style. White header with search, full-width bands,
   card grids with thumbnails, dark title bands and footer. One sans family
   (Figtree) at heavy weights for headings; mono only for course codes and code. */

:root {
  --ink: #1d1e20;
  --ink-2: #2d2f31;
  --muted: #5d6268;
  --line: #d1d7dc;
  --line-soft: #e6eaed;
  --bg: #ffffff;
  --tint: #f7f9fa;
  --accent: #1c6b58;        /* HSM green: primary buttons, links */
  --accent-dark: #134e40;
  --accent-soft: #dcefe8;
  --gold: #c58b1b;          /* HSM brass: stars of the brand, highlights */
  --gold-soft: #f6ebcf;
  --band: #1d1e20;          /* dark title bands and footer */
  --on-band: #ffffff;
  --on-band-muted: #c9ccd0;
  --ok: #1e7a4c;
  --err: #b42d26;

  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --radius: 8px;
  --radius-lg: 12px;
  --gutter: 24px;
  --maxw: 1340px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1rem/1.55 var(--sans); }
img { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-dark); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3 { font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(1.9rem, 1.4rem + 2vw, 2.6rem); }
h2 { font-size: clamp(1.4rem, 1.2rem + 0.8vw, 1.75rem); }
h3 { font-size: 1.05rem; font-weight: 700; }
p { margin: 0; }
.mono { font-family: var(--mono); font-size: .85em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; color: var(--muted); }
.center { text-align: center; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
@media (max-width: 600px) { :root { --gutter: 16px; } }

.skip { position: absolute; left: -999px; top: 0; }
.skip:focus { left: 1rem; top: 1rem; background: var(--bg); padding: .5rem 1rem; z-index: 60; }

.eyebrow, .kicker { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); margin-bottom: .5rem; }
.lede { font-size: 1.1rem; color: var(--muted); max-width: 46rem; margin-top: .75rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  font: 700 .95rem/1 var(--sans); padding: .8rem 1.2rem; border-radius: var(--radius);
  border: 1px solid transparent; text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s;
  background: var(--accent); color: #fff; white-space: nowrap;
}
.btn:hover { background: var(--accent-dark); color: #fff; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #3e4143; color: #fff; }
.btn-outline, .btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-outline:hover, .btn-ghost:hover { background: var(--tint); color: var(--ink); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: #eef1f3; color: var(--ink); }
.btn-ghost-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.btn-ghost-light:hover { background: rgba(255,255,255,.1); color: #fff; }
.btn-small { padding: .6rem .9rem; font-size: .875rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header { background: var(--bg); border-bottom: 1px solid var(--line-soft); box-shadow: 0 2px 4px rgba(0,0,0,.06); position: sticky; top: env(safe-area-inset-top, 0px); z-index: 30; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); background: var(--bg); z-index: 31; }
.header-row {
  max-width: var(--maxw); margin-inline: auto; min-height: 4.5rem;
  display: flex; align-items: center; gap: 1rem;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px)); padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
.brand { display: flex; align-items: center; gap: .55rem; color: var(--ink); text-decoration: none; font-size: 1.2rem; white-space: nowrap; }
.brand strong { font-weight: 800; letter-spacing: .02em; }
.brand:hover { color: var(--ink); }

.explore { position: relative; }
.explore summary { list-style: none; cursor: pointer; font-size: .92rem; padding: .5rem .6rem; border-radius: var(--radius); }
.explore summary::-webkit-details-marker { display: none; }
.explore summary:hover, .explore[open] summary { color: var(--accent); }
.explore-menu {
  position: absolute; top: calc(100% + .6rem); left: 0; z-index: 40; width: min(60rem, 92vw); max-height: min(75vh, 44rem); overflow-y: auto;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 24px rgba(0,0,0,.12);
  padding: 1.1rem 1.25rem; display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: 1rem 1.5rem;
}
.explore-stream { display: block; font-weight: 700; color: var(--ink); text-decoration: none; margin-bottom: .4rem; }
.explore-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .3rem; }
.explore-col a:not(.explore-stream) { color: var(--muted); text-decoration: none; font-size: .92rem; }
.explore-col a:hover { color: var(--accent); }
.explore-all { grid-column: 1 / -1; border-top: 1px solid var(--line-soft); padding-top: .75rem; font-weight: 700; text-decoration: none; }

.header-search {
  flex: 1; min-width: 0; display: flex; align-items: center; gap: .6rem;
  border: 1px solid var(--ink); border-radius: 999px; padding: 0 1rem; height: 3rem; background: var(--tint);
}
.header-search svg { color: var(--muted); flex: none; }
.header-search input { border: 0; background: transparent; font: inherit; font-size: .95rem; width: 100%; min-width: 0; padding: 0; color: var(--ink); }
.header-search input:focus { outline: none; }
.header-search:focus-within { box-shadow: 0 0 0 2px var(--accent); }

.site-nav { display: flex; align-items: center; gap: 1rem; }
.site-nav > a:not(.btn) { color: var(--ink); text-decoration: none; font-size: .92rem; white-space: nowrap; }
.site-nav > a:not(.btn):hover, .site-nav > a[aria-current="page"]:not(.btn) { color: var(--accent); }
.nav-mobile-only { display: none; }
.country-switch { display: inline-flex; border: 1px solid var(--line, #d6d9dc); border-radius: 999px; padding: 2px; font-size: .8rem; font-weight: 600; }
.country-switch > * { padding: .2rem .55rem; border-radius: 999px; text-decoration: none; color: var(--muted, #5d6268); white-space: nowrap; }
.country-switch > span { background: var(--ink); color: #fff; }
.country-switch > a:hover { color: var(--accent); }
.inline-form { display: inline; margin: 0; }
@media (min-width: 1061px) and (max-width: 1240px) {
  .nav-wide-only { display: none; }
  .site-nav { gap: .8rem; }
  .header-search { min-width: 9rem; }
}
.nav-toggle { display: none; background: none; border: 0; color: var(--ink); padding: .4rem; cursor: pointer; border-radius: var(--radius); }

@media (max-width: 1060px) {
  .header-row { flex-wrap: wrap; row-gap: .5rem; padding-block: .6rem; }
  .explore { display: none; }
  .header-search { order: 3; flex-basis: 100%; height: 2.75rem; }
  .nav-toggle { display: block; margin-left: auto; }
  .site-nav {
    display: none; order: 4; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 0;
    border-top: 1px solid var(--line-soft); padding-top: .25rem;
  }
  .site-nav.open { display: flex; }
  .site-nav > a:not(.btn) { padding: .8rem 0; border-bottom: 1px solid var(--line-soft); font-size: 1rem; }
  .site-nav .btn, .site-nav .inline-form { margin-top: .6rem; }
  .country-switch { align-self: flex-start; margin-top: .7rem; font-size: .9rem; }
  .site-nav .inline-form .btn { width: 100%; }
  .nav-mobile-only { display: block; }
}

.notice { background: var(--accent-soft); color: var(--accent-dark); padding-block: .8rem; font-weight: 600; }

/* ---------- Generic sections ---------- */
.section { padding-block: clamp(2.5rem, 5vw, 4rem); }
.section-tight { padding-block: 2rem clamp(2.5rem, 5vw, 3.5rem); }
.section-tint { background: var(--tint); }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: 1.25rem; flex-wrap: wrap; }
.h-section { font-size: clamp(1.5rem, 1.25rem + 1vw, 2rem); }
.h-page { font-size: clamp(1.6rem, 1.3rem + 1.2vw, 2.2rem); margin-top: .5rem; }
.h-sub { font-size: 1.35rem; margin: 2.25rem 0 1rem; }
.h-sub:first-child { margin-top: 0; }
.h-note { font-size: .9rem; font-weight: 500; margin-left: .4rem; }
.h-block { font-size: 1.45rem; margin-bottom: .75rem; }
.section-sub { color: var(--muted); max-width: 46rem; margin: .4rem 0 1.5rem; }
.more { font-weight: 700; text-decoration: none; }

.page-head { padding-block: clamp(2rem, 4vw, 3rem) 1.25rem; border-bottom: 1px solid var(--line-soft); }

/* Dark title band used across stream, program and account pages */
.page-band { background: var(--band); color: var(--on-band); padding-block: clamp(2rem, 4vw, 3rem); }
.page-band .lede { color: var(--on-band-muted); }
.page-band .kicker { color: #8fd3bd; }
.crumbs { font-size: .88rem; font-weight: 600; color: #a7c8ff; display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin-bottom: .75rem; }
.crumbs a { color: #a7c8ff; text-decoration: none; }
.crumbs a:hover { text-decoration: underline; color: #cfe0ff; }
.crumbs-light, .crumbs-light a { color: var(--accent); }
.crumbs-light a:hover { color: var(--accent-dark); }
.band-stats { display: flex; flex-wrap: wrap; gap: 2.5rem; margin: 1.5rem 0 0; }
.band-stats div { display: grid; }
.band-stats dt { order: 2; font-size: .82rem; color: var(--on-band-muted); }
.band-stats dd { margin: 0; font-size: 1.75rem; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ---------- Hero ---------- */
.hero { padding-block: 1.5rem 0; }
.hero-inner { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); align-items: center; gap: 2rem; }
.hero-card { background: var(--bg); padding: clamp(1.5rem, 3vw, 2.25rem); border-radius: var(--radius-lg); box-shadow: 0 4px 24px rgba(0,0,0,.1); display: grid; gap: 1rem; position: relative; z-index: 1; margin-right: -6rem; }
.hero-card h1 { font-size: clamp(2rem, 1.5rem + 2.2vw, 2.9rem); }
.hero-card p { color: var(--muted); font-size: 1.05rem; }
.hero-search { display: flex; gap: .5rem; margin-top: .25rem; }
.hero-search input { flex: 1; min-width: 0; border: 1px solid var(--ink); border-radius: var(--radius); padding: .8rem .9rem; font: inherit; }
.hero-art { position: relative; min-height: 22rem; border-radius: var(--radius-lg); overflow: hidden; background: linear-gradient(135deg, #0f3d33 0%, #1c6b58 55%, #c58b1b 140%); }
.art-grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px); background-size: 32px 32px; }
.art-card { position: absolute; background: #fff; color: var(--ink); border-radius: var(--radius); padding: .75rem 1rem; font-weight: 700; box-shadow: 0 8px 20px rgba(0,0,0,.2); display: grid; gap: .15rem; font-size: .95rem; }
.art-card span { font-family: var(--mono); font-size: .72rem; color: var(--accent); font-weight: 500; }
.art-1 { top: 16%; right: 10%; transform: rotate(3deg); }
.art-2 { top: 44%; right: 34%; transform: rotate(-4deg); }
.art-3 { bottom: 12%; right: 8%; transform: rotate(-1deg); }
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-card { margin-right: 0; order: 2; margin-top: -4rem; margin-inline: .5rem; }
  .hero-art { min-height: 14rem; }
  .art-2 { display: none; }
  .art-1 { top: 12%; right: auto; left: 8%; }
}
@media (max-width: 480px) { .hero-search { flex-direction: column; } }

.stats-strip { background: var(--tint); border-block: 1px solid var(--line-soft); margin-top: 2rem; }
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: 1rem; padding-block: 1.25rem; color: var(--muted); font-size: .95rem; }
.stats-row strong { display: block; color: var(--ink); font-size: 1.5rem; font-weight: 800; font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .stats-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: .25rem; border-bottom: 1px solid var(--line); margin-bottom: 1.25rem; overflow-x: auto; }
.tab { background: none; border: 0; font: 700 1rem var(--sans); color: var(--muted); padding: .75rem 1rem; cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.tab:hover { color: var(--ink); }
html.js .tab-panel[data-inactive] { display: none; }
.tab-panel + .tab-panel { margin-top: 2rem; }
html.js .tab-panel + .tab-panel { margin-top: 0; }
.panel-intro { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.5rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.panel-intro h3 { font-size: 1.3rem; font-weight: 800; }
.panel-intro p { color: var(--muted); margin-top: .3rem; max-width: 44rem; }

/* ---------- Course cards ---------- */
.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); gap: 1.5rem 1.25rem; }
.course-row { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(15rem, 1fr); gap: 1.25rem; overflow-x: auto; padding-bottom: .75rem; scroll-snap-type: x proximity; }
.course-row > * { scroll-snap-align: start; }
@media (min-width: 1100px) { .course-row { grid-auto-columns: calc((100% - 3 * 1.25rem) / 4); } }

.course-card { position: relative; display: flex; flex-direction: column; gap: .6rem; min-width: 0; }
.course-card .card-body { display: grid; gap: .3rem; }
.course-card h3 { font-size: 1rem; font-weight: 700; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-link { color: var(--ink); text-decoration: none; }
.card-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.course-card:hover .card-link { color: var(--ink); }
.course-card:hover .thumb { filter: brightness(.92); }
.card-by { font-size: .8rem; color: var(--muted); }
.card-meta { font-size: .8rem; color: var(--muted); }
.card-tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .15rem; }
.course-card.is-outline .thumb { filter: grayscale(.85) brightness(1.05); opacity: .8; }

.tag { display: inline-block; font: 700 .72rem/1 var(--sans); padding: .35rem .5rem; border-radius: 4px; background: var(--line-soft); color: var(--ink-2); white-space: nowrap; }
.tag-free { background: var(--accent-soft); color: var(--accent-dark); }
.tag-dev { background: var(--gold-soft); color: #6b4a0a; }
.tag-ok { background: var(--accent-soft); color: var(--ok); }
.tag-band { background: rgba(255,255,255,.14); color: #fff; font-family: var(--mono); font-weight: 500; }
.tag-wide { display: block; text-align: center; padding: .55rem; }
.pill { display: inline-block; font: 700 .72rem/1 var(--sans); padding: .35rem .55rem; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }
.pill-ok { color: var(--ok); border-color: var(--ok); background: var(--accent-soft); }
.pill-ready { color: var(--accent-dark); border-color: var(--accent); }

/* Thumbnails: one colour per subject area */
.thumb {
  aspect-ratio: 16 / 9; max-width: 100%; border-radius: var(--radius); position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end; padding: .8rem .9rem; color: #fff;
  background-color: var(--th, #3b4a5a);
  background-image:
    radial-gradient(circle at 85% 20%, rgba(255,255,255,.22) 0 18%, transparent 19%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.07) 0 2px, transparent 2px 14px),
    linear-gradient(160deg, rgba(255,255,255,.12), rgba(0,0,0,.18));
  transition: filter .15s;
}
.thumb-code { font: 500 1.15rem/1.1 var(--mono); letter-spacing: .02em; }
.thumb-area { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .85; margin-top: .25rem; }
.thumb-lg .thumb-code { font-size: 1.6rem; }
.thumb-core { --th: #2f4f8f; }
.thumb-civil { --th: #8a5a2b; }
.thumb-mechanical { --th: #2d6e6a; }
.thumb-electrical { --th: #a8730e; }
.thumb-chemical { --th: #2e7d4f; }
.thumb-computer { --th: #5a3f8f; }
.thumb-petroleum { --th: #3d4148; }
.thumb-professional { --th: #a5462f; }
.thumb-business { --th: #1f5f7a; }
.thumb-accounting { --th: #2a6f97; }
.thumb-mba { --th: #14324a; }
.thumb-health-sci { --th: #9b3d5a; }
.thumb-nursing { --th: #b5536f; }
.thumb-medicine { --th: #7a2440; }
.thumb-pharmacy { --th: #6b4f9e; }
.thumb-mathematics { --th: #3b5ba5; }
.thumb-biology { --th: #3f7f3a; }
.thumb-chemistry { --th: #1f7a75; }
.thumb-physics { --th: #4a3a8c; }
.thumb-biochemistry { --th: #5e7d2a; }
.thumb-computing { --th: #34495e; }
.thumb-arts-core { --th: #8c5a3c; }
.thumb-history { --th: #7d4e24; }
.thumb-philosophy { --th: #5b4b3a; }
.thumb-psychology { --th: #b0603a; }
.thumb-canadian-law { --th: #8e2b2b; }
.thumb-american-law { --th: #23395d; }
.thumb-lsat { --th: #6d2e46; }
.thumb-mcat { --th: #2d6a4f; }
.thumb-safety { --th: #c4561a; }
.thumb-ai { --th: #4b2f7a; }
.thumb-datacenter { --th: #1d4e5f; }
.thumb-trades-core { --th: #b04a12; }
.thumb-electrician { --th: #b8860b; }
.thumb-plumbing { --th: #1f5f99; }
.thumb-refrigeration { --th: #2a7f9e; }
.thumb-sheet-metal { --th: #55606b; }
.thumb-elevator { --th: #6a4c93; }
.thumb-welding { --th: #a33a1e; }
.thumb-automotive { --th: #2b2f36; }
.thumb-boilermaker { --th: #7a3b1d; }
.thumb-low-voltage { --th: #2e6b3f; }
.thumb-fire-alarm { --th: #b3261e; }
.thumb-dc-tech { --th: #275a73; }

.progress { height: 6px; background: var(--line-soft); border-radius: 99px; overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--accent); border-radius: 99px; }

/* ---------- Streams ---------- */
.stream-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr)); gap: 1.25rem; }
.stream-tile { display: flex; flex-direction: column; gap: .5rem; padding: 1.5rem; border-radius: var(--radius-lg); background: var(--bg); border: 1px solid var(--line); color: var(--ink); text-decoration: none; transition: box-shadow .15s, transform .15s; }
a.stream-tile:hover { color: var(--ink); box-shadow: 0 6px 18px rgba(0,0,0,.1); transform: translateY(-2px); }
.stream-tile h3 { font-size: 1.3rem; font-weight: 800; }
.stream-tile p { color: var(--muted); }
.stream-count { font-size: .78rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--accent); }
.stream-go { margin-top: auto; padding-top: .5rem; font-weight: 700; color: var(--accent); text-decoration: none; }
.stream-engineering { border-top: 6px solid #2f4f8f; }
.stream-safety { border-top: 6px solid #c4561a; }
.stream-trades { border-top: 6px solid #b04a12; }
.stream-professional { border-top: 6px solid #a5462f; }
.stream-business { border-top: 6px solid #1f5f7a; }
.stream-health { border-top: 6px solid #9b3d5a; }
.stream-science { border-top: 6px solid #3f7f3a; }
.stream-arts { border-top: 6px solid #8c5a3c; }
.stream-law { border-top: 6px solid #8e2b2b; }
.stream-test-prep { border-top: 6px solid #6d2e46; }
.stream-soon { border-style: dashed; background: transparent; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 1.5rem; counter-reset: s; }
.steps li { counter-increment: s; display: grid; gap: .5rem; align-content: start; }
.steps li::before { content: counter(s); width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-weight: 800; }
.steps h3 { font-size: 1.15rem; }
.steps p { color: var(--muted); }

/* ---------- Feature band ---------- */
.feature-band { background: var(--band); color: var(--on-band); padding-block: clamp(2.5rem, 5vw, 3.5rem); }
.feature-inner { display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap; }
.feature-inner > div:first-child { max-width: 44rem; }
.feature-band .kicker { color: #8fd3bd; }
.feature-band h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); }
.feature-band p { color: var(--on-band-muted); margin-top: .6rem; }
.feature-actions { display: flex; gap: .75rem; flex-wrap: wrap; }

/* ---------- Forms ---------- */
.field { display: grid; gap: .35rem; min-width: 0; }
label { font-weight: 700; font-size: .9rem; }
input, select, textarea { font: inherit; color: var(--ink); background: var(--bg); border: 1px solid var(--ink); border-radius: var(--radius); padding: .7rem .8rem; width: 100%; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.hint { font-size: .825rem; color: var(--muted); }
.error { font-size: .85rem; color: var(--err); font-weight: 600; }
.error-box, .success-box { padding: 1rem 1.2rem; border-radius: var(--radius); border: 1px solid; }
.error-box { color: var(--err); margin-bottom: 1rem; background: #fdf1f0; }
.success-box { border-color: var(--ok); background: var(--accent-soft); }
.success-box h2 { font-size: 1.25rem; color: var(--ok); margin-bottom: .4rem; }
.stack { display: grid; gap: 1.1rem; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 1.1rem; }
.hp { position: absolute; left: -9999px; }
.check { display: flex; gap: .5rem; align-items: center; font-weight: 500; }
.check input { width: auto; accent-color: var(--accent); }

/* ---------- Catalog ---------- */
.catalog { display: grid; grid-template-columns: 16rem minmax(0, 1fr); gap: 2rem; margin-top: 1.5rem; align-items: start; }
.filters { display: grid; gap: 1rem; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); position: sticky; top: 6rem; }
.filters-h { font-size: 1.1rem; }
.filter-actions { display: flex; align-items: center; gap: 1rem; }
.clear { font-size: .9rem; font-weight: 600; }
.result-count { color: var(--muted); font-weight: 600; margin-bottom: 1rem; }
@media (max-width: 860px) { .catalog { grid-template-columns: 1fr; } .filters { position: static; } }
.empty { padding: 2.5rem 1.5rem; text-align: center; border: 1px dashed var(--line); border-radius: var(--radius); display: grid; gap: .5rem; justify-items: center; }
.empty p { color: var(--muted); max-width: 32rem; }

/* ---------- Auth ---------- */
.auth { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.auth-wrap { display: grid; place-items: center; }
.auth-card { width: 100%; max-width: 26rem; display: grid; gap: 1rem; }
.auth-card h1 { font-size: 1.75rem; }
.auth-card .eyebrow { margin-bottom: -.5rem; }

/* ---------- Course landing page ---------- */
.course-band { background: var(--band); color: var(--on-band); padding-block: 2rem 2.5rem; }
.course-band-inner { display: grid; gap: .75rem; }
.course-band-inner > * { max-width: min(48rem, calc(100% - 23rem)); }
.course-band h1 { font-size: clamp(1.7rem, 1.3rem + 1.6vw, 2.3rem); }
.course-sub { font-size: 1.15rem; color: #e6e8ea; }
.course-facts { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; font-size: .9rem; color: var(--on-band-muted); }
.course-by { font-size: .88rem; color: var(--on-band-muted); }
.course-layout { display: grid; grid-template-columns: minmax(0, 1fr) 21rem; gap: 2.5rem; padding-block: 2rem 4rem; align-items: start; }
.course-main { display: grid; gap: 2.25rem; grid-column: 1; grid-row: 1; min-width: 0; }
.enroll-card { grid-column: 2; grid-row: 1; margin-top: -15rem; position: sticky; top: 6rem; background: var(--bg); border-radius: var(--radius-lg); box-shadow: 0 4px 24px rgba(0,0,0,.16); overflow: hidden; z-index: 2; }
.enroll-card .thumb { border-radius: 0; }
.enroll-body { padding: 1.25rem 1.4rem 1.5rem; display: grid; gap: .75rem; }
.price { font-size: 2rem; font-weight: 800; }
.includes-h { font-size: 1rem; margin-top: .5rem; }
.includes { margin: 0; padding-left: 1.1rem; display: grid; gap: .3rem; font-size: .92rem; }
@media (max-width: 980px) {
  .course-band-inner > * { max-width: 100%; }
  .course-layout { grid-template-columns: 1fr; }
  .enroll-card { grid-column: 1; grid-row: 1; margin-top: 0; position: static; }
  .course-main { grid-row: 2; }
}
.learn-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.learn-box h2 { font-size: 1.45rem; margin-bottom: 1rem; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: .65rem 1.5rem; }
.checks li { padding-left: 1.6rem; position: relative; font-size: .95rem; }
.checks li::before { content: ""; position: absolute; left: .1rem; top: .35em; width: .8rem; height: .45rem; border-left: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(-45deg); }
.prereqs { list-style: none; padding: 0; margin: 0 0 .5rem; display: grid; gap: .5rem; }
.prereqs li { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.prereqs .mono { color: var(--muted); margin-right: .2rem; }

.lesson-list { list-style: none; margin: .5rem 0 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.lesson-list li { display: grid; grid-template-columns: 2rem minmax(0, 1fr) auto; gap: .75rem; align-items: center; padding: .85rem 1rem; border-bottom: 1px solid var(--line-soft); background: var(--bg); }
.lesson-list li:last-child { border-bottom: 0; }
.lesson-n { width: 1.75rem; height: 1.75rem; border-radius: 50%; display: grid; place-items: center; font-size: .78rem; font-weight: 700; border: 1px solid var(--line); color: var(--muted); }
.lesson-list .is-done .lesson-n { background: var(--ok); border-color: var(--ok); color: #fff; }
.lesson-m { font-size: .82rem; color: var(--muted); white-space: nowrap; }
a.lesson-t, .lesson-t a { color: var(--ink); text-decoration: none; }
a.lesson-t:hover { color: var(--accent); text-decoration: underline; }
.lesson-list.outline .lesson-t { color: var(--muted); }
.lesson-list.compact li { grid-template-columns: 1.75rem minmax(0, 1fr); padding: .7rem .9rem; font-size: .9rem; }
.lesson-list .is-current { background: var(--tint); box-shadow: inset 3px 0 0 var(--ink); }
.lesson-list .is-current .lesson-t { font-weight: 700; }
.exam-row .lesson-n { background: var(--ink); color: #fff; border-color: var(--ink); }

/* ---------- Lesson page (content left, course content right) ---------- */
.lesson-layout { display: grid; grid-template-columns: minmax(0, 1fr) 20rem; gap: clamp(2rem, 4vw, 3.5rem); padding-block: 2rem 4rem; }
.lesson { max-width: 46rem; min-width: 0; }
.lesson-nav { grid-column: 2; grid-row: 1; display: grid; gap: .75rem; align-content: start; position: sticky; top: 6rem; max-height: calc(100vh - 7rem); overflow: auto; }
.lesson-nav-h { font-size: 1.05rem; }
.lesson { grid-column: 1; grid-row: 1; }
.back { font-size: .9rem; font-weight: 700; text-decoration: none; }
.lesson .eyebrow { color: var(--muted); }
.lesson h1 { font-size: clamp(1.7rem, 1.3rem + 1.4vw, 2.3rem); margin-bottom: 1.25rem; }
@media (max-width: 980px) {
  .lesson-layout { grid-template-columns: minmax(0, 1fr); }
  .lesson-nav { grid-column: 1; grid-row: 2; position: static; max-height: none; }
}

.prose { font-size: 1.06rem; line-height: 1.75; display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.1rem; }
.prose ul { margin: 0; padding-left: 1.25rem; display: grid; gap: .4rem; }
.prose h2 { font-size: 1.35rem; margin-top: .5rem; }
.callout { border-left: 4px solid var(--gold); background: var(--gold-soft); padding: 1rem 1.2rem; border-radius: 0 var(--radius) var(--radius) 0; }
.callout .label { display: block; font-size: .75rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: #6b4a0a; margin-bottom: .3rem; }
.lesson-actions { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.lesson-actions form { margin: 0; }
.signin-hint { margin-top: 1.25rem; font-size: .92rem; color: var(--muted); }

.equation { overflow-x: auto; padding: .25rem 0; }
.example { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.4rem; display: grid; gap: .6rem; background: var(--tint); }
.example-label { font-size: .75rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.example h3 { font-size: 1.1rem; }
.example details summary { cursor: pointer; font-weight: 700; color: var(--accent); padding: .25rem 0; }
.example-steps { margin: .75rem 0 0; padding: 0; list-style: none; display: grid; gap: .55rem; counter-reset: step; }
.example-steps li { position: relative; padding-left: 1.6rem; min-width: 0; }
.example-steps li:not(.step-eq) { counter-increment: step; }
.example-steps li:not(.step-eq)::before { content: counter(step) "."; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.example-steps .step-eq { overflow-x: auto; }
.example-answer { margin-top: .75rem; padding: .7rem .9rem; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); }

.code { margin: 0; min-width: 0; }
.code figcaption { font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: .35rem; }
.code pre { margin: 0; overflow-x: auto; background: var(--band); color: #f1f3f5; padding: 1rem 1.2rem; border-radius: var(--radius); font: 500 .88rem/1.6 var(--mono); }

.quiz-cta { margin-top: 2rem; padding: 1.25rem 1.4rem; border: 1px solid var(--line); border-radius: var(--radius); display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; background: var(--tint); }
.quiz-cta.is-done { border-color: var(--ok); background: var(--accent-soft); }
.quiz-cta p { margin-top: .25rem; }

/* Chapter features */
.toc { border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; margin-bottom: 1.75rem; background: var(--tint); }
.toc summary { font-weight: 800; cursor: pointer; }
.toc ol { margin: .6rem 0 0; padding-left: 1.3rem; display: grid; gap: .3rem; columns: 2; column-gap: 2rem; }
.toc li { break-inside: avoid; }
.toc a { color: var(--ink); text-decoration: none; font-size: .95rem; }
.toc a:hover { color: var(--accent); text-decoration: underline; }
@media (max-width: 600px) { .toc ol { columns: 1; } }
.prose h2[id], .prose section[class] h2 { scroll-margin-top: 6rem; }
.prose h2 { font-size: 1.5rem; margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--line-soft); }
.prose h3 { font-size: 1.15rem; margin-top: .25rem; }
.fig { margin: .5rem 0; display: grid; gap: .5rem; justify-items: center; }
.fig img { width: 100%; max-width: 40rem; border: 1px solid var(--line-soft); border-radius: var(--radius); background: #fff; }
.fig figcaption { font-size: .88rem; color: var(--muted); text-align: center; max-width: 40rem; }
.mistakes ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .9rem; }
.mistakes li { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.mistakes p { padding: .75rem 1rem; font-size: .98rem; line-height: 1.6; }
.m-wrong { background: #fdf1f0; }
.m-right { background: var(--accent-soft); }
.m-tag { display: inline-block; font-size: .7rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; margin-right: .5rem; }
.m-wrong .m-tag { color: var(--err); }
.m-right .m-tag { color: var(--accent-dark); }
.summary-points { margin: 0; padding-left: 1.25rem; display: grid; gap: .45rem; }
.key-terms { margin: 1rem 0 0; display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.key-terms div { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 1rem; padding: .7rem 1rem; border-bottom: 1px solid var(--line-soft); }
.key-terms div:last-child { border-bottom: 0; }
.key-terms dt { font-weight: 800; }
.key-terms dd { margin: 0; color: var(--ink-2); }
@media (max-width: 600px) { .key-terms div { grid-template-columns: 1fr; gap: .2rem; } }
.practice-list { margin: .5rem 0 0; padding-left: 1.4rem; display: grid; gap: 1rem; }
.practice-list li::marker { font-weight: 800; }
.practice-list details { margin-top: .35rem; }
.practice-list summary { cursor: pointer; font-weight: 700; color: var(--accent); font-size: .95rem; }
.practice-list details p { margin-top: .4rem; padding: .7rem .9rem; background: var(--tint); border-radius: var(--radius); }

/* ---------- Quiz and exam ---------- */
.quiz-wrap { max-width: 48rem; }
.quiz-head .back { display: inline-block; margin-bottom: 1rem; }
.quiz { display: grid; gap: 1.25rem; }
.question { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.4rem; margin: 0; min-width: 0; display: grid; gap: .5rem; }
.question legend { float: left; width: 100%; font-weight: 700; margin-bottom: .5rem; padding: 0; }
.q-n { display: inline-grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--ink); color: #fff; font-size: .78rem; margin-right: .4rem; }
.option { display: flex; gap: .7rem; align-items: flex-start; padding: .7rem .85rem; border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; font-weight: 500; font-size: 1rem; }
.option:hover { background: var(--tint); }
.option input { width: auto; margin-top: .3rem; accent-color: var(--accent); }
.option.opt-correct { border-color: var(--ok); background: var(--accent-soft); }
.option.opt-picked { border-color: var(--err); background: #fdf1f0; }
.question.is-right { border-left: 4px solid var(--ok); }
.question.is-wrong { border-left: 4px solid var(--err); }
.why { font-size: .95rem; color: var(--muted); margin-top: .25rem; }
.why strong { color: var(--ink); }
.quiz-submit { padding-top: .5rem; }
.result { display: flex; gap: 1.25rem; align-items: center; flex-wrap: wrap; padding: 1.25rem 1.4rem; border-radius: var(--radius); border: 1px solid; margin-bottom: 1.5rem; }
.result > div { flex: 1; min-width: 14rem; }
.result h2 { font-size: 1.25rem; }
.result-pass { border-color: var(--ok); background: var(--accent-soft); }
.result-fail { border-color: var(--err); background: #fdf1f0; }
.result-score { font-size: 2.2rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.result-pass .result-score { color: var(--ok); }
.result-fail .result-score { color: var(--err); }

/* ---------- Programs ---------- */
.program-feature { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 2rem; align-items: center; padding: clamp(1.5rem, 4vw, 2.25rem); background: var(--band); color: var(--on-band); border-radius: var(--radius-lg); text-decoration: none; margin-bottom: 1.25rem; }
.program-feature:hover { color: var(--on-band); background: #2d2f31; }
.program-feature .kicker { color: #8fd3bd; }
.program-feature h3 { font-size: 1.5rem; font-weight: 800; }
.program-feature p { color: var(--on-band-muted); margin-top: .5rem; }
@media (max-width: 760px) { .program-feature { grid-template-columns: 1fr; } }
.mini-stats { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.mini-stats div { display: grid; }
.mini-stats dt { order: 2; font-size: .8rem; color: var(--on-band-muted); }
.mini-stats dd { margin: 0; font-size: 1.6rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.program-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr)); gap: 1.25rem; }
.program-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem; text-decoration: none; color: var(--ink); display: flex; flex-direction: column; gap: .5rem; transition: box-shadow .15s; }
.program-card:hover { color: var(--ink); box-shadow: 0 6px 18px rgba(0,0,0,.1); }
.program-card h3 { font-size: 1.15rem; }
.program-card p { color: var(--muted); font-size: .95rem; }
.program-card .card-meta { margin-top: auto; }
.note-box { margin-top: 2rem; padding: 1.25rem 1.4rem; border-left: 4px solid var(--gold); background: var(--gold-soft); border-radius: 0 var(--radius) var(--radius) 0; max-width: 52rem; }
.note-box h3 { font-size: 1.05rem; margin-bottom: .35rem; }
.note-box p { color: #5b4a24; font-size: .95rem; }
.program-progress { display: grid; gap: .5rem; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); margin-bottom: 1.5rem; }
.program-progress:hover { color: var(--ink); }
.subject + .subject { margin-top: 2.5rem; }
.subject .section-head h3 { font-size: 1.25rem; font-weight: 800; }

.year { padding-block: 1.5rem; border-top: 1px solid var(--line); }
.year:first-child { border-top: 0; padding-top: 0; }
.year h2 { margin-bottom: 1rem; }
.terms { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr)); gap: 1.5rem; }
.term h3 { font-size: .82rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: .6rem; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.course-table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.course-table th { text-align: left; font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; padding: .65rem .8rem; border-bottom: 1px solid var(--line); background: var(--tint); }
.course-table td { padding: .7rem .8rem; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.course-table tr:last-child td { border-bottom: 0; }
.course-table .mono { color: var(--muted); white-space: nowrap; }
.course-table a { color: var(--ink); font-weight: 600; }
.course-table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Dashboard, about, contact ---------- */
.cert-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); }
.cert-list li { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) auto auto; gap: 1rem; align-items: center; padding: .9rem 1rem; border-bottom: 1px solid var(--line-soft); }
.cert-list li:last-child { border-bottom: 0; }
.cert-list .mono { color: var(--muted); }
.cert-title { font-weight: 600; }
@media (max-width: 600px) { .cert-list li { grid-template-columns: minmax(0, 1fr) auto; } .cert-list .mono, .cert-list .muted { grid-column: 1 / -1; } }

.about-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 3rem; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 3rem; }
.contact-aside { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem; align-self: start; }
@media (max-width: 820px) { .about-grid, .contact-grid { grid-template-columns: 1fr; } }
.facts { margin: 0; display: grid; gap: .5rem; }
.facts div { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line-soft); padding-bottom: .5rem; }
.facts div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt { color: var(--muted); font-size: .9rem; }
.facts dd { margin: 0; font-weight: 600; text-align: right; }

.ledger { border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem; margin: 0; display: grid; gap: .6rem; align-self: start; }
.ledger div { display: flex; align-items: baseline; gap: .5rem; }
.ledger dt { flex: none; }
.ledger div::before { content: ""; order: 2; flex: 1; border-bottom: 1px dotted var(--line); transform: translateY(-.3em); }
.ledger dd { margin: 0 0 0 auto; order: 3; font-weight: 700; font-variant-numeric: tabular-nums; }
.ledger-total { border-top: 1px solid var(--line); padding-top: .7rem; font-weight: 800; }
.ledger-total dd { color: var(--accent); font-size: 1.2rem; }

.faq-wrap { max-width: 50rem; display: grid; gap: 1.25rem; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 1rem 2rem 1rem 0; font-weight: 700; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: .25rem; top: .8rem; font-size: 1.3rem; font-weight: 400; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 0 1.1rem; color: var(--muted); max-width: 44rem; }

/* ---------- Certificate ---------- */
.certificate { max-width: 46rem; margin: 0 auto 2rem; border: 1px solid var(--line); outline: 6px double var(--gold); outline-offset: -18px; padding: clamp(2.5rem, 7vw, 4.5rem) clamp(1.5rem, 6vw, 4rem); text-align: center; display: grid; gap: .6rem; justify-items: center; }
.cert-kicker { letter-spacing: .2em; text-transform: uppercase; font-size: .8rem; font-weight: 800; color: var(--accent); }
.cert-line { font-size: clamp(1.5rem, 1.1rem + 2vw, 2.2rem); font-weight: 800; margin-bottom: 1rem; }
.cert-small { color: var(--muted); font-size: .95rem; }
.cert-name { font-size: clamp(1.8rem, 1.2rem + 3vw, 2.7rem); font-weight: 700; border-bottom: 1px solid var(--line); padding: 0 1.5rem .4rem; margin: .25rem 0 .5rem; }
.cert-course { font-size: 1.3rem; font-weight: 800; color: var(--accent); }
.cert-foot { display: flex; gap: 3rem; justify-content: center; flex-wrap: wrap; margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); width: 100%; }
.cert-foot div { display: grid; gap: .2rem; }
.cert-foot .label { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.no-print { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }
@media print {
  .site-header, .site-footer, .no-print, .notice { display: none !important; }
  .section { padding: 0; }
  .certificate { border: 0; }
}

/* ---------- Ads ---------- */
.ad { margin-block: 1.5rem; text-align: center; min-width: 0; overflow: hidden; }
.ad-label { display: block; font-size: .68rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: .35rem; }
.ad-preview { border: 2px dashed var(--gold); background: var(--gold-soft); color: #6b4a0a; font: 500 .85rem var(--mono); padding: 2.25rem 1rem; border-radius: var(--radius); }
.ad-sidebar.ad-preview { padding: 5rem 1rem; }
.ad-row .ad { margin-block: 1.25rem 0; }
.grid-ad { grid-column: 1 / -1; }
.grid-ad .ad { margin: 0; }
@media (max-width: 980px) { .ad-sidebar { display: none; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--band); color: var(--on-band-muted); padding-block: 3rem 1.5rem; font-size: .92rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 2rem; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.footer-brand { display: flex; align-items: center; gap: .5rem; color: #fff; font-size: 1.2rem; margin-bottom: .75rem; }
.footer-about p:not(.footer-brand) { max-width: 22rem; }
.footer-h { font-size: .95rem; font-weight: 700; color: #fff; margin-bottom: .75rem; }
.footer-base { margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid #3e4143; font-size: .82rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* keep long equations from widening the lesson column on phones */
.lesson-layout > * { min-width: 0; }
.katex-display { overflow-x: auto; overflow-y: hidden; padding: .2rem 0; }
.prose p, .prose li { overflow-wrap: break-word; }

/* program pages */
.program-model { color: var(--muted); max-width: 52rem; margin: 0 0 1.5rem; }
.terms-stages { grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); }

/* ---------- Accounts, activity, certificates, employers ---------- */
.card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1.25rem 1.4rem; }
.card h2 { font-size: 1.2rem; }
.account-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); gap: 1.25rem; align-items: start; margin-top: 1.25rem; }
.employer-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 2rem; align-items: start; }
@media (max-width: 860px) { .employer-grid { grid-template-columns: minmax(0, 1fr); } }
.feature-list { padding-left: 1.1rem; display: grid; gap: .7rem; }
.danger-zone { border-color: #e7b9b5; }
.btn-danger { background: var(--err); color: #fff; }
.btn-danger:hover { background: #8f231e; color: #fff; }
.link-button { background: none; border: 0; padding: 0; color: var(--accent); font: inherit; text-decoration: underline; cursor: pointer; }
.row-actions, .team-actions, .cert-actions, .share-buttons { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.cert-actions { justify-content: center; margin: 1.25rem 0; }
.warn-box { background: var(--gold-soft); border: 1px solid var(--gold); border-radius: var(--radius); padding: .8rem 1rem; }
.pill-warn { color: var(--err); border-color: var(--err); background: #fbe9e7; }
.band-stats { flex-wrap: wrap; }

.resume-card { display: flex; flex-wrap: wrap; gap: .3rem 1rem; align-items: center; margin-top: 1.25rem; padding: .9rem 1.1rem; border-radius: var(--radius-lg);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.25); color: var(--on-band); text-decoration: none; }
.resume-card:hover { background: rgba(255,255,255,.14); color: var(--on-band); }
.resume-label { font-size: .78rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--on-band-muted); width: 100%; }
.resume-go { margin-left: auto; font-weight: 700; }
.invite-banner { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; justify-content: space-between; background: var(--accent-soft); border: 1px solid var(--accent); border-radius: var(--radius-lg); padding: .9rem 1.1rem; margin-bottom: 1rem; }
.invite-banner p { margin: 0; }

.activity-list { list-style: none; padding: 0; margin: 0 0 1rem; border-left: 2px solid var(--line); }
.activity-list li { position: relative; display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: .75rem; padding: .45rem 0 .45rem 1rem; }
.activity-list li::before { content: ""; position: absolute; left: -6px; top: .85rem; width: 10px; height: 10px; border-radius: 50%; background: var(--line); }
.activity-list li.act-course_complete::before, .activity-list li.act-certificate::before { background: var(--gold); }
.activity-list li.act-lesson_complete::before, .activity-list li.act-quiz::before, .activity-list li.act-exam::before { background: var(--accent); }
.activity-list time { color: var(--muted); font-size: .85rem; }
@media (max-width: 560px) { .activity-list li { grid-template-columns: minmax(0, 1fr); gap: 0; } }
.pager { display: flex; gap: 1rem; align-items: center; }
.cert-links { display: inline-flex; flex-wrap: wrap; gap: .4rem .9rem; }

.share-box { max-width: 46rem; margin: 1.5rem auto; text-align: center; }
.share-box h2 { font-size: 1.25rem; }
.share-buttons { justify-content: center; margin: .75rem 0; }
.share-linkedin { background: #0a66c2; border-color: #0a66c2; color: #fff; }
.share-linkedin:hover { background: #004182; color: #fff; }
.share-linkedin.btn-ghost { background: transparent; color: #0a66c2; }
.share-linkedin.btn-ghost:hover { background: #e8f1fb; color: #004182; }
.share-facebook { background: #1877f2; border-color: #1877f2; color: #fff; }
.share-facebook:hover { background: #0e5ac0; color: #fff; }

.narrow { max-width: 46rem; }
.verify-ok { border: 2px solid var(--ok); border-radius: var(--radius-lg); padding: 1.5rem 1.6rem; background: var(--accent-soft); }
.verify-facts { display: grid; gap: .6rem; margin: 1rem 0; }
.verify-facts dt { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.verify-facts dd { margin: 0; font-weight: 600; }
.verify-form { max-width: 26rem; }

.join-box { display: flex; flex-wrap: wrap; gap: .6rem 1rem; align-items: center; justify-content: space-between; background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: .8rem 1rem; margin: 1rem 0; }
.join-box p { margin: 0; overflow-wrap: anywhere; }
.filter-row { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1rem 0; }
.filter-row input { flex: 1 1 16rem; }
.team-table td { vertical-align: top; }
.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); gap: .4rem 1rem; max-height: 22rem; overflow: auto; padding: .25rem; border: 1px solid var(--line-soft); border-radius: var(--radius); }
.message-template { white-space: pre-wrap; background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius); padding: .9rem; font-family: var(--sans); }
