/* The Sunnah Campus: dark, modern and calm. Calligraphy sits behind selected sections;
   the accent is a warm orange-to-yellow gradient, per the founder's brief. */
:root {
  --bg: #0f0f10;
  --surface: rgba(255, 255, 255, 0.035);
  --surface-hover: rgba(255, 255, 255, 0.06);
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #f4f2ee;
  --muted: #a6a39d;
  --dim: #77746e;
  /* Accent runs from the logo orange into a warm yellow */
  --accent: #ffbe3d;
  --accent-deep: #f08a24;
  --gradient: linear-gradient(100deg, #f08a24 0%, #ffbe3d 55%, #ffd76a 100%);
  --glow: 0 10px 40px -10px rgba(255, 170, 50, 0.55);
  --on-accent: #1a1204;
  --radius: 18px;
  --radius-sm: 12px;
  --wrap: 1140px;
  --display: "Montserrat", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
  --arabic: "Aref Ruqaa", serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); scroll-behavior: smooth; }
body { color: var(--text); font-family: var(--body); font-size: 16.5px; line-height: 1.65; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Calligraphy texture from the original site, behind page tops and [data-calligraphy]
   sections only. The overlay darkens it; the top and bottom fades blend it into the page.
   The tile repeats seamlessly downwards at a fixed scale: stretching it to "cover" a tall
   section zoomed the 1920px source several times over and blurred it. */
.intro, .page-hero, [data-calligraphy] {
  position: relative;
  background:
    linear-gradient(180deg, var(--bg) 0%, rgba(15, 15, 16, 0) 16%, rgba(15, 15, 16, 0) 84%, var(--bg) 100%),
    linear-gradient(rgba(15, 15, 16, 0.5), rgba(15, 15, 16, 0.5)),
    url("assets/calligraphy-tile.jpg") center top / max(100%, 1200px) auto repeat-y;
}

/* Layout */
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.section { padding: 110px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-head { margin-bottom: 52px; max-width: 640px; }
.section-head h2 { margin-bottom: 14px; }
.center { text-align: center; }
.section-head.center, .center .lead { margin-left: auto; margin-right: auto; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
.split h2 { margin-bottom: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }

/* Type: one modern sans for headings, one for body */
h1, h2, h3, h4 { font-family: var(--display); font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
h1 { font-size: clamp(36px, 4.6vw, 60px); }
h2 { font-size: clamp(28px, 3.1vw, 42px); }
h3 { font-size: 21px; }
h4 { font-size: 17px; }
p { color: var(--muted); }
.lead { font-size: 18px; color: var(--muted); max-width: 600px; }
.gradient-text { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.accent { color: var(--accent); }
.kicker { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.kicker::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--gradient); }

/* Buttons and links */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 15px 28px; border-radius: 999px; font-family: var(--display); font-weight: 600; font-size: 15px; border: 1px solid transparent; white-space: nowrap; transition: transform .25s var(--ease), box-shadow .25s, border-color .25s, background .25s; }
.btn svg { width: 16px; height: 16px; transition: transform .25s var(--ease); }
.btn:hover svg { transform: translateX(3px); }
.btn-primary { background: var(--gradient); color: var(--on-accent); box-shadow: var(--glow); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 16px 48px -10px rgba(255, 170, 50, 0.7); }
.btn-ghost { border-color: var(--line-strong); color: var(--text); background: rgba(255, 255, 255, 0.02); }
.btn-ghost:hover { border-color: var(--accent); }
/* In the bundle card the secondary button gets a gold outline to match the filled primary */
.bundle .btn-ghost { border-color: var(--accent); }
.btn-sm { padding: 11px 20px; font-size: 14px; }
.btn-block { width: 100%; }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-family: var(--display); font-weight: 600; font-size: 15px; color: var(--accent); }
.link-arrow svg { width: 15px; height: 15px; transition: transform .25s var(--ease); }
.link-arrow:hover svg, a:hover > .link-arrow svg, a:hover .link-arrow svg { transform: translateX(4px); }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(15, 15, 16, 0.78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 76px; gap: 24px; }
.brand { display: flex; align-items: center; }
/* Official logo artwork, rearranged side by side; never re-typeset the wordmark */
/* The lockup gives the icon most of the height, so it runs a little taller than the old one to keep the words legible */
.brand-logo { height: 62px; width: auto; }
.nav-links { display: flex; gap: 6px; padding: 5px; border: 1px solid var(--line); border-radius: 999px; background: rgba(255, 255, 255, 0.02); }
.nav-links a { white-space: nowrap; padding: 8px 16px; border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--muted); transition: color .2s, background .2s; }
.nav-links a:hover { color: var(--text); }
.nav-links a.active { color: var(--text); background: rgba(255, 255, 255, 0.07); }
.nav-actions { display: flex; align-items: center; gap: 18px; }
.nav-actions .login { font-size: 14px; color: var(--muted); }
.nav-actions .login:hover { color: var(--text); }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line-strong); align-items: center; justify-content: center; }
.menu-toggle svg { width: 20px; height: 20px; }
.mobile-menu { display: none; }

/* Homepage intro */
.intro { min-height: min(calc(100vh - 76px), 860px); overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 80px 24px 96px; }
.intro::after { content: ""; position: absolute; left: 50%; top: 42%; width: 640px; height: 640px; transform: translate(-50%, -50%); background: radial-gradient(circle, rgba(255, 170, 50, 0.12), transparent 65%); pointer-events: none; z-index: 0; }
.intro > :not(.sr-only) { position: relative; z-index: 1; }
.intro-logo { width: min(300px, 68vw); height: auto; margin-bottom: 40px; }
.intro .lead { margin: 0 auto 36px; }
.figures { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px 56px; margin-top: 64px; }
.figures dt { font-family: var(--display); font-weight: 700; font-size: 30px; line-height: 1; }
.figures dd { font-size: 13.5px; color: var(--dim); margin-top: 6px; }

/* Boxes: the shared building block, with a soft lift on hover */
.box, .card, .prog, .plan, .step, .choice, .quote, .path, .fact { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: transform .35s var(--ease), border-color .3s, background .3s; }
a.box:hover, a.prog:hover, a.choice:hover, a.path:hover, .card:hover, .plan:hover, .quote:hover { transform: translateY(-4px); border-color: rgba(255, 190, 61, 0.35); background: var(--surface-hover); }
.card { padding: 30px; }
.card h3, .card h4 { margin-bottom: 10px; }
.card p { font-size: 15.5px; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* Three ways to study (homepage) and choose-your-format (Arabic) */
.paths { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.paths.two { grid-template-columns: repeat(2, 1fr); }
.path { position: relative; display: flex; flex-direction: column; overflow: hidden; }
.path-media { aspect-ratio: 16 / 10; overflow: hidden; background: #1a1a1a; }
.path-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.path:hover .path-media img { transform: scale(1.05); }
.path-media-split { display: grid; grid-template-columns: 1fr 1fr; aspect-ratio: 32 / 9; }
.path-media-split img { min-height: 0; }
.path-body { display: flex; flex-direction: column; flex: 1; padding: 28px; }
.path-body h3 { font-size: 24px; margin-bottom: 8px; }
.path-body p { font-size: 15px; margin-bottom: 22px; }
/* Card call to action as a clear outlined button, matching "Study one subject" in the bundle card */
.path-body .link-arrow { margin-top: auto; align-self: stretch; justify-content: center; gap: 10px; padding: 15px 28px; border: 1px solid var(--accent); border-radius: 999px; background: rgba(255, 255, 255, 0.02); color: var(--text); transition: background .25s var(--ease); }
.path:hover .path-body .link-arrow { background: rgba(255, 190, 61, 0.08); }
.path .tag { position: absolute; top: 16px; left: 16px; z-index: 1; padding: 4px 8px; border-radius: 4px; background: rgba(15, 15, 16, 0.75); backdrop-filter: blur(8px); font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }

/* Featured Islamic Studies + Arabic bundle, placed first so it is the default choice */
.bundle { display: grid; grid-template-columns: 1.05fr 1fr; overflow: hidden; border: 1px solid rgba(255, 190, 61, 0.45); border-radius: 24px; background: linear-gradient(135deg, rgba(255, 190, 61, 0.08), var(--surface) 55%); box-shadow: 0 30px 80px -40px rgba(255, 170, 50, 0.45); }
.bundle-media { position: relative; display: grid; grid-template-rows: 1fr 1fr; min-height: 100%; background: #1a1a1a; }
.bundle-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.bundle:hover .bundle-media img { transform: scale(1.03); }
/* A bundle card with one image instead of two, e.g. the Student of Knowledge plan */
.bundle-media-single { grid-template-rows: 1fr; }
.bundle-media-single img { object-fit: cover; }
/* Teacher names in the recorded-course library */
.lib-teacher { font-size: 13px; color: var(--dim); line-height: 1.4; padding-right: 12px; }
/* Book covers are not 16:9, so show them whole on a dark mat */
#books .prog-media img { object-fit: contain; background: #151515; }
.bundle-body { padding: 40px; align-self: center; }
.bundle-body .ribbon { display: inline-block; margin-bottom: 12px; font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.bundle-body h3, .bundle-body .bundle-title { font-size: clamp(26px, 2.6vw, 34px); margin-bottom: 12px; }
.page-hero .bundle-body .bundle-title { font-size: clamp(30px, 3.4vw, 44px); }
.bundle-body .check-list { margin: 20px 0 24px; }
.bundle-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 12px; margin-bottom: 26px; }
.bundle-price b { font-family: var(--display); font-weight: 700; font-size: 40px; line-height: 1; letter-spacing: -0.03em; }
.bundle-price span { font-size: 14px; color: var(--muted); }
.bundle-price s { flex-basis: 100%; font-size: 14px; color: var(--dim); }
.paths-divider { display: flex; align-items: center; gap: 18px; margin: 56px 0 28px; font-family: var(--display); font-weight: 600; font-size: 15px; color: var(--muted); scroll-margin-top: 110px; }
.paths-divider::before, .paths-divider::after { content: ""; flex: 1; height: 1px; background: var(--line-strong); }

/* More courses: a full-width strip of course thumbnails that scrolls on its own.
   main.js duplicates the cards once so the loop is seamless, and sets the duration
   from the strip's width so the speed stays the same however many courses there are. */
.marquee-block { margin-top: 80px; }
.marquee-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.marquee-title { font-size: 24px; }
.marquee-controls { display: flex; gap: 10px; }
.marquee-btn { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text); background: rgba(255, 255, 255, 0.03); transition: background .25s, border-color .25s, color .25s, transform .2s var(--ease); }
.marquee-btn svg { width: 18px; height: 18px; }
.marquee-btn:hover { background: var(--gradient); border-color: transparent; color: var(--on-accent); }
.marquee-btn:active { transform: scale(0.92); }
.marquee-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
/* Break out of the centred column to span the whole page width */
.marquee { width: 100vw; margin-left: calc(50% - 50vw); overflow: hidden; padding: 8px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee { touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.marquee.dragging { cursor: grabbing; }
.marquee.dragging .marquee-card { pointer-events: none; }
.marquee-track { display: flex; gap: 22px; width: max-content; will-change: transform; }
.marquee-card { flex: none; width: clamp(300px, 32vw, 560px); aspect-ratio: 16 / 9; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: #1a1a1a; transition: transform .4s var(--ease), border-color .3s, box-shadow .3s; }
.marquee-card img { width: 100%; height: 100%; object-fit: cover; }
.marquee-card:hover, .marquee-card:focus-visible { transform: scale(1.03); border-color: rgba(255, 190, 61, 0.5); box-shadow: 0 18px 50px -20px rgba(255, 170, 50, 0.45); }

/* Key facts strip on course pages */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 44px; }
.fact { padding: 20px 22px; }
.fact b { display: block; font-family: var(--display); font-size: 19px; font-weight: 700; margin-bottom: 2px; }
.fact span { font-size: 13.5px; color: var(--dim); }

/* Inner page hero */
.page-hero { padding: 96px 0 80px; }
.page-hero h1 { margin-bottom: 18px; max-width: 820px; }
.crumbs { font-size: 13.5px; color: var(--dim); margin-bottom: 24px; }
.crumbs a:hover { color: var(--text); }
.hero-facts { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 30px; font-size: 14.5px; color: var(--muted); }
.hero-facts span { display: inline-flex; align-items: center; gap: 8px; }
.hero-facts svg { width: 15px; height: 15px; color: var(--accent); }

/* In-page navigation */
.subnav { position: sticky; top: 76px; z-index: 40; background: rgba(15, 15, 16, 0.86); backdrop-filter: blur(12px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.subnav .wrap { display: flex; align-items: center; gap: 26px; height: 56px; overflow-x: auto; scrollbar-width: none; }
.subnav .wrap::-webkit-scrollbar { display: none; }
.subnav a { font-size: 14px; color: var(--muted); white-space: nowrap; transition: color .2s; }
.subnav a:hover { color: var(--text); }
.subnav .btn { margin-left: auto; color: var(--on-accent); }

/* Programme cards */
.prog { display: flex; flex-direction: column; overflow: hidden; }
.prog-media, .card-media { aspect-ratio: 16 / 9; overflow: hidden; background: #1a1a1a; }
.card-media { margin: -30px -30px 24px; border-radius: var(--radius) var(--radius) 0 0; }
.prog-media img, .card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.prog:hover .prog-media img { transform: scale(1.05); }
.prog-body { display: flex; flex-direction: column; flex: 1; padding: 26px; }
.prog-body h3 { margin-bottom: 8px; }
.prog-body p { font-size: 15px; margin-bottom: 18px; }
.pills { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 12px; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.pill.accent { color: var(--accent); }
.pill.live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); }
.meta { list-style: none; display: grid; gap: 8px; margin-bottom: 22px; font-size: 14px; color: var(--muted); }
.meta li { display: flex; gap: 10px; align-items: flex-start; }
.meta svg { width: 15px; height: 15px; flex: none; margin-top: 4px; color: var(--dim); }
.prog-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 18px; border-top: 1px solid var(--line); }
.price-tag { font-family: var(--display); font-weight: 700; font-size: 21px; line-height: 1.1; }
.price-tag small { display: block; font-family: var(--body); font-weight: 400; font-size: 12.5px; color: var(--dim); margin-top: 4px; }

/* Roadmap: a lit line down one side with expandable boxes */
.roadmap { position: relative; max-width: 820px; }
/* One segment per year: main.js sets where its line starts and ends (year ring to last
   marker) and how much of it is lit, so the light breaks between years */
.rm-segment { position: relative; padding-left: 64px; --line-top: 10px; --line-length: 0px; --progress: 0px; }
.rm-segment + .rm-segment { margin-top: 72px; }
.rm-segment::before, .rm-segment::after { content: ""; position: absolute; left: 21px; top: var(--line-top); width: 2px; border-radius: 2px; }
.rm-segment::before { height: var(--line-length); background: var(--line-strong); }
.rm-segment::after { height: var(--progress); background: linear-gradient(180deg, #ffd76a, #f08a24); box-shadow: 0 0 14px rgba(255, 190, 61, 0.6); transition: height .2s linear; }
.rm-item { position: relative; padding-bottom: 34px; }
.rm-item:last-child { padding-bottom: 0; }
.rm-item::before { content: ""; position: absolute; left: -52px; top: 6px; width: 16px; height: 16px; border-radius: 50%; background: #2a2a2c; border: 2px solid var(--line-strong); transition: background .4s, box-shadow .4s, border-color .4s; z-index: 1; }
.rm-item:not([data-stage])::before { top: 26px; }
.rm-format { margin-left: 4px; white-space: nowrap; padding: 2px 8px; border-radius: 6px; background: rgba(255, 255, 255, 0.06); font-size: 12px; color: var(--muted); }
.rm-item.lit::before { background: #fff; border-color: #fff; box-shadow: 0 0 0 6px rgba(255, 215, 106, 0.16), 0 0 22px rgba(255, 190, 61, 0.9); }
.rm-stage { display: inline-block; padding: 6px 14px; margin-bottom: 14px; border: 1px solid rgba(255, 190, 61, 0.35); border-radius: 999px; background: rgba(255, 190, 61, 0.06); font-family: var(--display); font-size: 12.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
/* Year (or level) headings: a larger ring on the line marks each new stage */
.rm-year { position: relative; margin: 0 0 24px; font-size: clamp(24px, 2.4vw, 30px); }
.rm-year::before { content: ""; position: absolute; left: -57px; top: calc(50% - 12px); width: 24px; height: 24px; border-radius: 50%; background: var(--bg); border: 3px solid var(--line-strong); transition: background .4s, border-color .4s, box-shadow .4s; z-index: 1; }
.rm-year.lit::before { background: var(--gradient); border-color: #ffd76a; box-shadow: 0 0 0 6px rgba(255, 215, 106, 0.14), 0 0 26px rgba(255, 190, 61, 0.9); }

/* Milestones: checkpoints between years, not modules. Diamond marker, open gold panel, ticked goals */
.rm-item.milestone::before { left: -53px; top: 30px; width: 18px; height: 18px; border-radius: 3px; transform: rotate(45deg); }
.rm-item.milestone.lit::before { background: var(--gradient); border-color: #ffd76a; }
.rm-milestone-card { padding: 26px 28px; border: 1px dashed rgba(255, 190, 61, 0.55); border-radius: var(--radius); background: linear-gradient(135deg, rgba(255, 190, 61, 0.13), rgba(255, 190, 61, 0.03) 70%); }
.rm-milestone-head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
/* The badge starts as an empty slot and pins on like a brooch once the reader scrolls past
   (the roadmap script adds .lit). Removing .lit on the way back up lets it replay. */
.rm-milestone-icon { position: relative; flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; border: 1px dashed var(--line-strong); background: rgba(255, 255, 255, 0.04); color: var(--dim); transition: background .3s, color .3s, border-color .3s, box-shadow .3s; }
.rm-milestone-icon::before { content: ""; position: absolute; inset: -6px; border-radius: 18px; border: 2px solid #ffd76a; opacity: 0; pointer-events: none; }
.rm-milestone-icon::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, 0.8) 50%, transparent 70%) no-repeat; background-size: 250% 100%; opacity: 0; pointer-events: none; }
.rm-item.milestone.lit .rm-milestone-icon { border-color: transparent; background: var(--gradient); color: var(--on-accent); box-shadow: var(--glow); animation: badge-pin .9s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
.rm-item.milestone.lit .rm-milestone-icon::before { animation: badge-ring .8s .35s ease-out both; }
.rm-item.milestone.lit .rm-milestone-icon::after { animation: badge-shine 1s .55s ease-out both; }
.rm-item.milestone .rm-milestone-card { transition: border-color .5s, background .5s; }
.rm-item.milestone.lit .rm-milestone-card { border-style: solid; border-color: rgba(255, 190, 61, 0.7); }
@keyframes badge-pin { 0% { transform: scale(0) rotate(-40deg); opacity: 0; } 55% { transform: scale(1.3) rotate(10deg); opacity: 1; } 75% { transform: scale(0.92) rotate(-4deg); } 100% { transform: scale(1) rotate(0); } }
@keyframes badge-ring { 0% { opacity: 0.9; transform: scale(0.6); } 100% { opacity: 0; transform: scale(1.7); } }
@keyframes badge-shine { 0% { opacity: 0; background-position: 150% 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { opacity: 0; background-position: -60% 0; } }
.rm-milestone-icon svg { width: 22px; height: 22px; }
.rm-milestone-kicker { display: block; margin-bottom: 2px; font-family: var(--display); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.rm-milestone-head h3 { font-size: 20px; }
.rm-milestone-body { font-size: 15.5px; color: var(--text); }
.rm-milestone-body ul { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; }
.rm-milestone-body li { position: relative; padding-left: 30px; }
.rm-milestone-body li::before { content: "\2713"; position: absolute; left: 0; top: 2px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--gradient); color: var(--on-accent); font-size: 12px; font-weight: 700; }

.rm-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); transition: border-color .3s, background .3s; }
.rm-card:hover, .rm-card.open { border-color: rgba(255, 190, 61, 0.3); background: var(--surface-hover); }
.rm-toggle { display: flex; align-items: center; justify-content: space-between; gap: 20px; width: 100%; padding: 22px 24px; text-align: left; }
.rm-heading { display: grid; gap: 8px; }
.rm-title { font-family: var(--display); font-weight: 700; font-size: 18px; color: var(--text); }
/* Sits inside the h3 toggle, so reset to the body font */
.rm-teacher { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-family: var(--body); font-weight: 500; font-size: 13.5px; line-height: 1.3; color: var(--muted); }
.rm-teacher img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; object-position: top; border: 1px solid rgba(255, 190, 61, 0.4); }
/* Exams sit between the modules and the milestone: a square marker and a compact card */
.rm-item.exam::before { border-radius: 4px; }
.rm-item.exam.lit::before { background: var(--accent); border-color: var(--accent); }
.rm-exam-card { display: flex; gap: 16px; padding: 20px 24px; border: 1px solid rgba(255, 190, 61, 0.3); border-radius: var(--radius); background: rgba(255, 190, 61, 0.05); font-size: 15px; color: var(--muted); }
.rm-exam-card h3 { margin-bottom: 6px; font-size: 18px; }
.rm-exam-icon { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; border: 1px solid rgba(255, 190, 61, 0.45); color: var(--accent); }
.rm-exam-icon svg { width: 20px; height: 20px; }
/* Diploma grading: five bands, brighter towards the top grade */
.grading { max-width: 820px; margin-top: 56px; }
.grading h3 { margin-bottom: 18px; font-size: 20px; }
.grade-scale { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.grade { display: grid; gap: 4px; padding: 16px; border: 1px solid rgba(255, 190, 61, 0.3); border-radius: 14px; background: rgba(255, 190, 61, 0.06); }
.grade b { font-family: var(--display); font-size: 15px; color: var(--text); }
.grade span { font-size: 14px; color: var(--muted); }
.grade.is-fail { border-color: var(--line); background: var(--surface); }
.grade.is-fail b { color: var(--muted); }
.grade.is-top { border-color: transparent; background: var(--gradient); }
.grade.is-top b, .grade.is-top span { color: var(--on-accent); }
.rm-plus { flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-strong); transition: transform .35s var(--ease), border-color .3s, background .3s; }
.rm-plus svg { width: 15px; height: 15px; }
.rm-card.open .rm-plus { transform: rotate(45deg); border-color: transparent; background: var(--gradient); color: var(--on-accent); }
/* Animate open/close by transitioning the grid row instead of a fixed height */
.rm-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s var(--ease); }
.rm-card.open .rm-panel { grid-template-rows: 1fr; }
.rm-panel > div { overflow: hidden; }
.rm-panel-inner { padding: 0 24px 24px; font-size: 15.5px; color: var(--muted); }
.rm-panel-inner ul { list-style: none; display: grid; gap: 8px; margin-top: 10px; }
.rm-panel-inner li { position: relative; padding-left: 18px; }
.rm-panel-inner li::before { content: ""; position: absolute; left: 0; top: 10px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.rm-panel-inner b { color: var(--text); font-weight: 600; }
.rm-panel-inner .rm-book { margin-bottom: 10px; color: var(--text); }
.rm-panel-inner .rm-book i { color: var(--accent); }

/* Prospectus flipbook (StPageFlip renders the pages into .flipbook-stage) */
.flipbook { max-width: 860px; margin: 0 auto; outline: none; }
.flipbook-stage { position: relative; min-height: 420px; filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.6)); }
.flipbook:not(.is-ready):not(.is-fallback) .flipbook-stage { display: grid; place-items: center; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.flipbook:not(.is-ready):not(.is-fallback) .flipbook-stage::before { content: "Opening the prospectus..."; color: var(--muted); font-size: 15px; }
.flipbook:not(.is-ready):not(.is-fallback) .flip-page { display: none; }
.flip-page { background: #fff; overflow: hidden; }
.flip-page img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; }
.flipbook.is-fallback .flipbook-stage { display: grid; gap: 16px; max-height: 80vh; overflow-y: auto; }
.flipbook-controls { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 26px; }
.flipbook-controls button { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text); transition: background .25s, border-color .25s, color .25s; }
.flipbook-controls button:hover, .flipbook-controls button:focus-visible { background: var(--gradient); border-color: transparent; color: var(--on-accent); }
.flipbook-controls svg { width: 18px; height: 18px; }
.flip-count { min-width: 70px; text-align: center; font-family: var(--display); font-weight: 600; font-size: 14.5px; color: var(--muted); }
.flipbook:focus-visible .flipbook-stage { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 4px; }
.flipbook-download { margin-top: 18px; text-align: center; font-size: 14.5px; }
.flipbook-download a { color: var(--accent); }

/* Terms and privacy pages */
.legal p { color: var(--muted); font-size: 16px; }
.legal p + p { margin-top: 10px; }
.legal a { color: var(--accent); }
.legal-intro { font-size: 17.5px; margin-bottom: 36px; }
.legal-section { padding: 26px 0; border-top: 1px solid var(--line); }
.legal-section h2 { display: flex; align-items: baseline; gap: 14px; font-size: 20px; margin-bottom: 10px; }
.legal-section h2 span { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--gradient); color: var(--on-accent); font-size: 14px; }
.legal-closing { margin-top: 26px; padding-top: 26px; border-top: 1px solid var(--line); }

/* Lists and steps */
.check-list { list-style: none; display: grid; gap: 12px; margin: 24px 0 30px; }
.check-list li { position: relative; padding-left: 24px; color: var(--muted); font-size: 16px; }
.check-list li b { color: var(--text); font-weight: 600; }
.check-list li::before { content: ""; position: absolute; left: 2px; top: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--gradient); }
.steps, .numbered { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: step; }
.step, .numbered > div { padding: 30px; }
.numbered > div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.step-num, .numbered > div::before { display: grid; place-items: center; width: 40px; height: 40px; margin-bottom: 18px; border-radius: 50%; background: var(--gradient); color: var(--on-accent); font-family: var(--display); font-weight: 700; font-size: 15px; }
.numbered > div::before { counter-increment: step; content: counter(step); }
.step h3, .numbered h3 { margin-bottom: 8px; }
.step p, .numbered p { font-size: 15px; }

/* Subjects as small boxes */
.subjects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.subject { padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); transition: border-color .3s, transform .35s var(--ease); }
.subject:hover { border-color: rgba(255, 190, 61, 0.35); transform: translateY(-3px); }
.subject b { display: flex; justify-content: space-between; align-items: baseline; font-family: var(--display); font-weight: 700; font-size: 16.5px; margin-bottom: 2px; }
.subject b i { font-family: var(--arabic); font-style: normal; font-weight: 700; font-size: 22px; color: var(--accent); opacity: 0.8; }
.subject span { font-size: 14px; color: var(--muted); }

/* Key dates: the academic year as one line. Each stop starts a period and the stretch after
   it shows what that period is: solid gold for teaching, dashed for breaks. Horizontal on wide
   screens, vertical on narrow ones. main.js marks the stop for the current period with "Now". */
.dates-line { list-style: none; display: flex; padding-top: 38px; }
.date-stop { position: relative; flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 34px 18px 0 0; }
.date-stop::before { content: ""; position: absolute; top: 8px; left: 0; right: 0; height: 2px; background: var(--gradient); opacity: 0.85; }
.date-stop::after { content: ""; position: absolute; top: 2px; left: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); box-sizing: border-box; }
.date-stop.is-break::before { background: none; border-top: 2px dashed var(--line-strong); height: 0; opacity: 1; }
.date-stop.is-break::after { border-color: var(--line-strong); }
.date-stop.is-exam::after { background: var(--accent); }
/* The final stop opens the next year, so its line fades out instead of running on */
.date-stop.is-next::before { background: linear-gradient(90deg, var(--accent), transparent); }
/* Room for a two-line label keeps every date on one baseline across the line */
.date-label { min-height: 2.7em; font-size: 13px; font-weight: 600; color: var(--muted); line-height: 1.35; }
.date-main { font-family: var(--display); font-weight: 700; font-size: 26px; line-height: 1.15; letter-spacing: -0.02em; color: var(--text); }
.date-sub { font-size: 13px; color: var(--dim); }
.date-stop.is-break .date-main { color: var(--muted); }
.date-stop.is-now::after { background: var(--accent); box-shadow: 0 0 0 6px rgba(255, 190, 61, 0.18), 0 0 22px rgba(255, 190, 61, 0.7); }
.date-stop.is-now .date-main { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.date-now { position: absolute; top: -34px; left: -6px; display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--gradient); color: var(--on-accent); font-size: 12px; font-weight: 700; }
.date-now::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--on-accent); animation: now-pulse 1.6s ease-in-out infinite; }
@keyframes now-pulse { 50% { opacity: 0.3; } }
@media (prefers-reduced-motion: reduce) { .date-now::before { animation: none; } }
@media (max-width: 1180px) {
  .nav-links, .nav-actions .login, .nav-actions .btn { display: none; }
  .menu-toggle { display: inline-flex; }
  .mobile-menu { position: fixed; inset: 76px 0 0 0; z-index: 49; display: flex; flex-direction: column; padding: 24px 24px 40px; background: var(--bg); overflow-y: auto; opacity: 0; pointer-events: none; transition: opacity .25s; }
  .mobile-menu.open { opacity: 1; pointer-events: auto; }
  .mobile-menu a { font-family: var(--display); font-weight: 700; font-size: 18px; line-height: 1.3; padding: 11px 0; border-bottom: 1px solid var(--line); }
  .mobile-menu .btn { font-size: 16px; margin-top: 24px; border-bottom: 0; padding: 16px; }
}
@media (max-width: 920px) {
  .dates-line { flex-direction: column; padding-top: 0; max-width: 520px; }
  .date-stop { padding: 0 0 26px 34px; }
  .date-stop:last-child { padding-bottom: 0; }
  .date-stop::before { top: 4px; bottom: 0; left: 6px; right: auto; width: 2px; height: auto; }
  .date-stop.is-break::before { border-top: 0; border-left: 2px dashed var(--line-strong); width: 0; height: auto; }
  .date-stop.is-next::before { background: linear-gradient(180deg, var(--accent), transparent); }
  .date-stop::after { top: 3px; }
  .date-label { min-height: 0; }
  .date-main { font-size: 22px; }
  .date-now { top: 0; left: auto; right: 0; }
}

/* Enrolment: one question per card, so the choice never feels like a long form */
.enrol-hero { min-height: calc(100vh - 80px); }
.enrol { max-width: 720px; margin: 0 auto; padding: 28px 32px 36px; border: 1px solid var(--line-strong); border-radius: 24px; background: rgba(15, 15, 16, 0.82); backdrop-filter: blur(6px); }
.enrol-top { display: flex; align-items: center; justify-content: space-between; min-height: 32px; }
.enrol-back { padding: 6px 0; background: none; border: 0; color: var(--muted); font: inherit; font-size: 14px; cursor: pointer; }
.enrol-back::before { content: "\2190  "; }
.enrol-back:hover { color: var(--text); }
.enrol-back[hidden] { visibility: hidden; display: block; }
.enrol-count { font-size: 13.5px; color: var(--dim); }
.enrol-progress { height: 4px; margin: 12px 0 30px; border-radius: 4px; background: var(--line); overflow: hidden; }
.enrol-progress span { display: block; width: 0; height: 100%; background: var(--gradient); transition: width .5s var(--ease); }
.enrol-body { opacity: 0; transform: translateY(14px); }
.enrol-body.is-in { opacity: 1; transform: none; transition: opacity .45s var(--ease), transform .45s var(--ease); }
.enrol-title { font-size: 28px; margin-bottom: 22px; }
.enrol-options { display: grid; gap: 12px; }
.enrol-option { position: relative; display: grid; gap: 4px; width: 100%; padding: 20px 22px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); color: var(--text); font: inherit; text-align: left; cursor: pointer; transition: border-color .25s, transform .25s var(--ease), background .25s; }
.enrol-option:hover:not(:disabled), .enrol-option:focus-visible { border-color: var(--accent); background: rgba(255, 190, 61, 0.06); transform: translateY(-2px); outline: none; }
.enrol-option.is-selected { border-color: var(--accent); background: rgba(255, 190, 61, 0.08); }
.enrol-option:disabled { opacity: 0.45; cursor: not-allowed; }
.enrol-option .pill { position: absolute; top: 18px; right: 18px; }
.enrol-option-label { font-family: var(--display); font-weight: 700; font-size: 19px; }
.enrol-option-price { font-family: var(--display); font-weight: 700; font-size: 26px; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.enrol-option-price small { font-family: var(--body, inherit); font-size: 14px; font-weight: 500; color: var(--muted); -webkit-text-fill-color: var(--muted); }
.enrol-option-note { font-size: 14.5px; color: var(--muted); }
.enrol-summary { display: grid; gap: 2px; margin-bottom: 26px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.enrol-summary div { display: flex; justify-content: space-between; gap: 16px; padding: 15px 20px; background: var(--surface); }
.enrol-summary dt { color: var(--muted); font-size: 14.5px; }
.enrol-summary dd { font-weight: 600; text-align: right; }
.enrol-fineprint { margin-top: 14px; font-size: 13.5px; color: var(--dim); text-align: center; }
.enrol-help { margin-top: 26px; font-size: 15px; }
@media (prefers-reduced-motion: reduce) { .enrol-body, .enrol-body.is-in { transition: none; transform: none; } }

/* Schedule rows */
.schedule { display: grid; border-top: 1px solid var(--line); }
.slot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.slot b { display: block; font-size: 15.5px; color: var(--text); font-weight: 600; }
.slot span { font-size: 13.5px; color: var(--muted); }
.slot .when { font-family: var(--display); font-weight: 700; font-size: 16px; white-space: nowrap; color: var(--text); }
.timeline { border-left: 2px solid var(--line-strong); margin-left: 4px; }
.tl { position: relative; padding: 0 0 22px 24px; }
.tl::before { content: ""; position: absolute; left: -6px; top: 8px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px rgba(255, 190, 61, 0.7); }
.tl b { display: block; font-size: 15.5px; color: var(--text); font-weight: 600; }
.tl span { font-size: 14px; color: var(--muted); }

/* Pricing */
.pricing { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: stretch; }
.pricing.two { grid-template-columns: repeat(2, 1fr); max-width: 820px; margin: 0 auto; }
.plan { position: relative; display: flex; flex-direction: column; padding: 32px 28px; }
.plan.best { border-color: rgba(255, 190, 61, 0.5); background: linear-gradient(180deg, rgba(255, 190, 61, 0.07), var(--surface) 55%); }
.plan .ribbon { align-self: flex-start; margin-bottom: 12px; font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.plan h3 { margin-bottom: 4px; }
.plan .desc { font-size: 14.5px; margin-bottom: 22px; }
.plan .amount { font-family: var(--display); font-weight: 700; font-size: 46px; line-height: 1; letter-spacing: -0.03em; }
.plan .amount sup { font-size: 20px; vertical-align: 18px; margin-right: 2px; }
.plan .per { font-size: 14px; color: var(--muted); margin: 8px 0 22px; }
.plan ul { list-style: none; display: grid; gap: 10px; margin-bottom: 28px; font-size: 15px; }
.plan ul li { display: flex; gap: 10px; }
.plan ul svg { width: 15px; height: 15px; flex: none; margin-top: 5px; color: var(--accent); }
.plan .btn { margin-top: auto; }
/* Reassurance under the discounts, pointing people who cannot afford fees to us */
.fees-help { margin-top: 32px; font-size: 15px; color: var(--muted); }
.fees-help a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
/* Course chooser: three big choices, then a plain price list (not options) and one button */
.course-picker { max-width: 640px; margin: 0 auto; }
.picker-choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
.picker-choice { position: relative; display: grid; gap: 2px; padding: 18px 14px 16px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); text-align: center; transition: border-color .25s, background .25s; }
.picker-choice b { font-family: var(--display); font-size: 16px; color: var(--text); }
.picker-choice span { font-size: 12.5px; color: var(--muted); }
.picker-choice:hover { border-color: rgba(255, 190, 61, 0.45); }
.picker-choice[aria-pressed="true"] { border: 2px solid var(--accent); background: rgba(255, 190, 61, 0.08); }
.picker-choice .picker-flag { position: absolute; top: -10px; left: 50%; transform: translateX(-50%); padding: 2px 10px; border-radius: 6px; background: var(--gradient); color: var(--on-accent); font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.picker-prices { display: grid; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.price-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; }
.price-row + .price-row { border-top: 1px solid var(--line); }
.price-row b { display: block; font-size: 16px; color: var(--text); }
.price-row span { font-size: 13px; color: var(--muted); }
.price-row.featured { background: linear-gradient(100deg, rgba(240, 138, 36, 0.16), rgba(255, 190, 61, 0.06)); }
.price-row.featured span { color: var(--accent); font-weight: 600; }
.price-amount { font-family: var(--display); font-weight: 700; font-size: 22px; white-space: nowrap; color: var(--text); }
.price-row.featured .price-amount { font-size: 26px; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.price-amount small { font-family: var(--body); font-size: 13px; font-weight: 500; color: var(--muted); -webkit-text-fill-color: var(--muted); }
.picker-note { margin: 12px 0 20px; font-size: 13.5px; color: var(--dim); text-align: center; }
.discount-list { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; max-width: 640px; margin: 40px auto 14px; }
.discount-list li { display: grid; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; font-size: 13.5px; color: var(--muted); }
.discount-list b { font-family: var(--display); font-size: 18px; color: var(--accent); }
.included-head { margin: 64px 0 8px; font-size: 20px; }
.check-list.two-col { grid-template-columns: 1fr 1fr; gap: 12px 28px; margin-top: 16px; }

.note { display: flex; gap: 14px; align-items: flex-start; padding: 20px 22px; margin-top: 20px; border: 1px solid var(--line); border-radius: var(--radius); font-size: 15px; color: var(--muted); }
.note svg { width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--accent); }
.note b { color: var(--text); }
/* Small qualifier under an item, e.g. "Subject to passing" */
.note small, .check-list small { display: block; margin-top: 2px; font-size: 13px; color: var(--dim); }

/* Teachers */
.teacher { display: flex; flex-direction: column; }
/* Full bio opens in place under the short one (toggle added by main.js) */
.bio-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .45s var(--ease); }
.bio-panel > div { overflow: hidden; }
.teacher.bio-open .bio-panel { grid-template-rows: 1fr; }
.teacher.bio-open > p:not(.bio-panel p) { display: none; }
.bio-panel p { color: var(--muted); }
.teaches { margin-top: 16px; }
.teaches h5 { font-family: var(--display); font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.teaches ul { display: grid; gap: 6px; padding: 0; list-style: none; }
.teaches a { color: var(--accent); font-size: 14.5px; text-decoration: underline; text-underline-offset: 3px; }

/* Teacher profile dialog (homepage faces) */
html.profile-open { overflow: hidden; }
.profile { width: min(560px, calc(100% - 32px)); max-height: calc(100dvh - 48px); margin: auto; padding: 32px 28px 28px; overflow-y: auto; border: 1px solid var(--line-strong); border-radius: var(--radius); background: #141414; color: var(--text); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.8); }
.profile::backdrop { background: rgba(0, 0, 0, 0.7); backdrop-filter: blur(4px); }
.profile[open] { animation: profile-in .35s var(--ease); }
@keyframes profile-in { from { opacity: 0; transform: translateY(16px) scale(0.98); } }
.profile-close { position: absolute; top: 14px; right: 14px; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text); }
.profile-close svg { width: 16px; height: 16px; }
.profile-head { display: flex; align-items: center; gap: 20px; margin-bottom: 18px; padding-right: 44px; }
.profile-photo { flex: none; width: 96px; height: 96px; padding: 3px; border-radius: 50%; object-fit: cover; object-position: top; background: var(--gradient); }
.profile .role { font-size: 13.5px; font-weight: 600; color: var(--accent); margin-bottom: 4px; }
.profile h3 { font-size: 22px; line-height: 1.25; }
.profile-bio { color: var(--muted); font-size: 15.5px; line-height: 1.7; }
.profile .link-arrow { margin-top: 22px; }
@media (prefers-reduced-motion: reduce) { .profile[open] { animation: none; } }
.bio-toggle { align-self: flex-start; text-align: left; margin-top: 12px; padding: 0; font-weight: 600; font-size: 14.5px; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.portrait, .avatar { width: 80px; height: 80px; border-radius: 50%; margin-bottom: 18px; flex: none; }
.portrait { object-fit: cover; object-position: top; border: 2px solid rgba(255, 190, 61, 0.4); }
.avatar { display: grid; place-items: center; border: 1px solid var(--line-strong); font-family: var(--display); font-weight: 700; font-size: 20px; color: var(--muted); }
.teacher .role { font-size: 13.5px; font-weight: 600; color: var(--accent); margin-bottom: 4px; }
.creds { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.creds span { font-size: 12.5px; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); }
.faces { display: grid; grid-template-columns: repeat(4, 1fr); gap: 36px 24px; margin-bottom: 40px; }
@media (max-width: 720px) { .faces { grid-template-columns: repeat(2, 1fr); gap: 32px 16px; } }
.faces figure { min-width: 0; text-align: center; transition: transform .4s var(--ease); }
/* Full colour portraits inside a glowing gradient ring (padding shows the gradient behind the photo) */
.faces img { width: 112px; height: 112px; padding: 3px; border-radius: 50%; object-fit: cover; object-position: top; display: block; margin: 0 auto 16px; background: var(--gradient); box-shadow: 0 0 0 6px rgba(255, 190, 61, 0.08), 0 12px 36px -10px rgba(255, 170, 50, 0.55); transition: box-shadow .4s, transform .4s var(--ease); }
.faces figure:hover { transform: translateY(-6px); }
.faces figure:hover img { transform: scale(1.04); box-shadow: 0 0 0 8px rgba(255, 190, 61, 0.14), 0 18px 48px -8px rgba(255, 170, 50, 0.8); }
.face-btn { display: block; width: 100%; padding: 0; text-align: center; border-radius: 12px; }
.face-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; }
.faces figcaption { font-size: 13.5px; color: var(--accent); line-height: 1.45; }
.faces figcaption b, .quote figcaption b { display: block; font-weight: 600; color: var(--text); }

/* Testimonials */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.quote { display: flex; flex-direction: column; padding: 32px 28px; }
.quote blockquote { font-size: 16.5px; line-height: 1.7; color: var(--text); margin-bottom: 24px; }
.quote blockquote::before { content: "\201C"; display: block; font-family: var(--display); font-size: 48px; line-height: 0.8; margin-bottom: 8px; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.quote figcaption { margin-top: auto; font-size: 13.5px; color: var(--dim); }

/* Accordion */
.faq { display: grid; gap: 10px; max-width: 820px; }
.faq.center-x { margin: 0 auto; }
.acc { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); transition: border-color .3s; }
.acc[open] { border-color: rgba(255, 190, 61, 0.3); }
.acc summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 22px; font-family: var(--display); font-weight: 600; font-size: 16px; color: var(--text); }
.acc summary::-webkit-details-marker { display: none; }
.acc summary .plus { flex: none; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--muted); transition: transform .3s var(--ease), background .3s; }
.acc summary .plus svg { width: 13px; height: 13px; }
.acc[open] summary .plus { transform: rotate(45deg); background: var(--gradient); border-color: transparent; color: var(--on-accent); }
.acc .acc-body { padding: 0 22px 22px; font-size: 15.5px; color: var(--muted); }
.acc .acc-body p + p { margin-top: 10px; }
.acc .acc-body a { color: var(--accent); }

/* Tabs and the online / in person form switch */
.tabs { display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 5px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); }
.tab { padding: 10px 20px; border-radius: 999px; font-family: var(--display); font-size: 14.5px; font-weight: 600; color: var(--muted); transition: color .2s, background .3s; }
.tab:hover { color: var(--text); }
.tab.active { background: var(--gradient); color: var(--on-accent); }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fade-up .45s var(--ease); }
@keyframes fade-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* Closing call to action */
.cta-band { text-align: center; padding: 64px 32px; border: 1px solid var(--line); border-radius: 28px; background: radial-gradient(ellipse at top, rgba(255, 170, 50, 0.12), transparent 70%), var(--surface); }
.cta-band h2 { margin-bottom: 14px; }
.cta-band p { max-width: 520px; margin: 0 auto 30px; }
.cta-band .btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* Registration */
.reg-choice { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.choice { display: block; padding: 28px; }
.choice h4 { margin-bottom: 6px; }
.choice p { font-size: 15px; margin-bottom: 14px; }
.form-shell { position: relative; min-height: 640px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: #1b1b1b; }
.form-shell iframe { position: relative; z-index: 1; display: block; width: 100%; height: 900px; border: 0; }
.form-shell .loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); }
.form-help { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-top: 16px; font-size: 14px; color: var(--dim); }
.form-help a { color: var(--accent); }
.backup-prices { display: grid; border-top: 1px solid var(--line); }
.bp { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.bp b { font-size: 15.5px; font-weight: 600; }
.bp span { font-family: var(--display); font-weight: 700; font-size: 17px; white-space: nowrap; }

/* Sponsor */
.sponsor-card { padding: 40px; border: 1px solid rgba(255, 190, 61, 0.35); border-radius: var(--radius); background: linear-gradient(180deg, rgba(255, 190, 61, 0.06), var(--surface)); }
.sponsor-card .amount { font-family: var(--display); font-weight: 700; font-size: 64px; line-height: 1; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 0 0 40px; }
/* Newsletter and social links, centred on the calligraphy texture like the original site */
.newsletter { padding: 84px 0 56px; text-align: center; }
/* The same stacked logo as the homepage hero, centred above the sign-up form */
.foot-logo { display: inline-block; margin-bottom: 40px; }
.foot-logo img { width: 200px; height: auto; }
.newsletter h2 { font-size: clamp(24px, 2.6vw, 32px); margin-bottom: 8px; }
.newsletter > .wrap > p { margin-bottom: 26px; }
.newsletter-form { display: flex; gap: 10px; max-width: 640px; margin: 0 auto; }
.newsletter-form input { flex: 1; min-width: 0; padding: 14px 18px; border-radius: 999px; border: 1px solid var(--line-strong); background: rgba(15, 15, 16, 0.6); color: var(--text); font: inherit; font-size: 15px; }
.newsletter-form input:focus { outline: none; border-color: var(--accent); }
.newsletter-form .btn { flex: none; }
.newsletter-form .btn:disabled { opacity: 0.6; cursor: wait; }
/* The bot trap stays in the form but off screen */
.newsletter-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.newsletter-status { min-height: 24px; margin: 14px 0 0; font-size: 14.5px; color: var(--accent); }
.newsletter-status.is-error { color: #ff8a7a; }
.newsletter .socials { justify-content: center; gap: 22px; margin-top: 18px; }
.newsletter .socials a { color: var(--text); }
.newsletter .socials a:hover { color: var(--accent); }
.newsletter .socials svg { width: 24px; height: 24px; }
.foot-main { padding-top: 56px; }
.foot-top { display: flex; justify-content: center; margin-bottom: 40px; }
.foot-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 28px; max-width: 760px; }
.foot-links a { font-size: 14.5px; color: var(--muted); transition: color .2s; }
.foot-links a:hover { color: var(--text); }
.socials { display: flex; gap: 18px; }
.socials a { color: var(--muted); transition: color .2s; }
.socials a:hover { color: var(--accent); }
.socials svg { width: 18px; height: 18px; }
.foot-bottom { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding-top: 26px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--dim); }
.foot-bottom div { display: flex; gap: 22px; }
.foot-bottom a:hover { color: var(--text); }

.mobile-cta { display: none; }

/* Fade and rise on scroll; main.js staggers siblings via --delay */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--delay, 0s); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .rm-item.milestone.lit .rm-milestone-icon, .rm-item.milestone.lit .rm-milestone-icon::before, .rm-item.milestone.lit .rm-milestone-icon::after { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
  .rm-segment::after { transition: none; }
}

/* Responsive */
@media (max-width: 1024px) {
  .grid-4, .facts { grid-template-columns: repeat(2, 1fr); }
  .nav-links a { padding: 8px 12px; }
}
@media (max-width: 920px) {
  .bundle { grid-template-columns: 1fr; }
  .bundle-media { grid-template-rows: none; grid-template-columns: 1fr 1fr; aspect-ratio: 32 / 9; }
  .split, .compare, .grid-3, .steps, .numbered, .pricing, .pricing.two, .quotes, .paths, .paths.two { grid-template-columns: 1fr; }
  .split { gap: 40px; }
  .subjects { grid-template-columns: 1fr 1fr; }
  .subnav .btn { display: none; }
  .mobile-cta { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 45; display: flex; gap: 10px; padding: 8px; border: 1px solid var(--line-strong); border-radius: 999px; background: rgba(15, 15, 16, 0.92); backdrop-filter: blur(12px); transform: translateY(140%); transition: transform .35s var(--ease); }
  .mobile-cta.show { transform: none; }
  .mobile-cta .btn { flex: 1; padding: 12px; }
  .mobile-cta .btn-stack { flex: 2.2; white-space: nowrap; flex-direction: column; gap: 1px; padding: 8px 12px; line-height: 1.15; }
  .mobile-cta .btn-stack small { font-size: 11.5px; font-weight: 600; opacity: .8; }
}
@media (max-width: 640px) {
  .newsletter-form { flex-direction: column; }
  .marquee-card { width: 78vw; }
  .marquee-track { gap: 14px; }
  .wrap { padding: 0 16px; }
  .section { padding: 56px 0; }
  .page-hero { padding: 48px 0 36px; }
  .section-head { margin-bottom: 28px; }
  .enrol { padding: 20px 18px 26px; }
  .enrol-title { font-size: 23px; }
  .enrol-option { padding: 18px; }
  .enrol-option .pill { position: static; justify-self: start; margin-bottom: 4px; }
  .grid-2, .grid-4, .reg-choice, .subjects { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr 1fr; gap: 10px; }
  .bundle-body { padding: 28px 20px; }
  .card, .step, .plan, .prog-body, .choice, .path-body, .numbered > div { padding: 24px 20px; }
  .card-media { margin: -24px -20px 20px; }
  .figures { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .sponsor-card { padding: 28px 20px; }
  .brand-logo { height: 50px; }
  .btn { white-space: normal; text-align: center; }
  .hero-ctas .btn { flex: 1; }
  .hero-facts { flex-direction: column; gap: 10px; }
  .slot { flex-direction: column; align-items: flex-start; gap: 4px; }
  .rm-segment { padding-left: 44px; }
  .rm-segment::before, .rm-segment::after { left: 13px; }
  .rm-item::before { left: -40px; }
  .rm-item.milestone::before { left: -41px; }
  .rm-year::before { left: -45px; }
  .rm-milestone-card { padding: 22px 18px; }
  .rm-milestone-body ul { grid-template-columns: 1fr; }
  .rm-toggle { padding: 18px 18px; }
  .picker-choice { padding: 16px 6px 14px; }
  .picker-choice span { font-size: 11.5px; }
  .discount-list { grid-template-columns: 1fr; gap: 0; border: 1px solid var(--line); border-radius: 14px; }
  .discount-list li { grid-template-columns: 92px 1fr; align-items: baseline; border: 0; border-radius: 0; }
  .discount-list li + li { border-top: 1px solid var(--line); }
  .check-list.two-col { grid-template-columns: 1fr; }
  .rm-item:not([data-stage])::before { top: 22px; }
  .rm-panel-inner { padding: 0 18px 20px; }
  .rm-exam-card { padding: 18px; }
  .grade-scale { grid-template-columns: 1fr; }
  .grade { grid-template-columns: 1fr auto; align-items: center; padding: 12px 16px; }
  .cta-band { padding: 48px 20px; }
}

/* Utilities: one-off spacing and type tweaks that used to be inline style attributes.
   Kept as classes so the Content-Security-Policy can forbid inline styles; !important
   preserves the precedence the inline styles had. */
.u-c-dim { color: var(--dim) !important; }
.u-d-flex { display: flex !important; }
.u-dir-row { flex-direction: row !important; }
.u-flex-1 { flex: 1 !important; }
.u-fs-14 { font-size: 14px !important; }
.u-fs-14_5 { font-size: 14.5px !important; }
.u-fs-15 { font-size: 15px !important; }
.u-fs-16 { font-size: 16px !important; }
.u-gap-14 { gap: 14px !important; }
.u-gap-28 { gap: 28px !important; }
.u-h-120 { height: 120px !important; }
.u-items-flex-start { align-items: flex-start !important; }
.u-items-start { align-items: start !important; }
.u-m-0 { margin: 0 !important; }
.u-m-0-0-30 { margin: 0 0 30px !important; }
.u-m-0-auto { margin: 0 auto !important; }
.u-m-18-0-22 { margin: 18px 0 22px !important; }
.u-m-24-auto-0 { margin: 24px auto 0 !important; }
.u-m-6-0-14 { margin: 6px 0 14px !important; }
.u-m-6-0-24 { margin: 6px 0 24px !important; }
.u-m-6-0-26 { margin: 6px 0 26px !important; }
.u-m-72-0-28 { margin: 72px 0 28px !important; }
.u-mb-10 { margin-bottom: 10px !important; }
.u-mb-14 { margin-bottom: 14px !important; }
.u-mb-16 { margin-bottom: 16px !important; }
.u-mb-18 { margin-bottom: 18px !important; }
.u-mb-20 { margin-bottom: 20px !important; }
.u-mb-22 { margin-bottom: 22px !important; }
.u-mb-24 { margin-bottom: 24px !important; }
.u-mb-28 { margin-bottom: 28px !important; }
.u-mb-36 { margin-bottom: 36px !important; }
.u-mb-6 { margin-bottom: 6px !important; }
.u-mb-8 { margin-bottom: 8px !important; }
.u-minw-240 { min-width: 240px !important; }
.u-ml-auto { margin-left: auto !important; }
.u-mr-auto { margin-right: auto !important; }
.u-mt-12 { margin-top: 12px !important; }
.u-mt-14 { margin-top: 14px !important; }
.u-mt-22 { margin-top: 22px !important; }
.u-mt-24 { margin-top: 24px !important; }
.u-mt-28 { margin-top: 28px !important; }
.u-mt-32 { margin-top: 32px !important; }
.u-mt-34 { margin-top: 34px !important; }
.u-mt-40 { margin-top: 40px !important; }
.u-mt-44 { margin-top: 44px !important; }
.u-mt-56 { margin-top: 56px !important; }
.u-mw-860 { max-width: 860px !important; }
.u-mw-900 { max-width: 900px !important; }
.u-pt-0 { padding-top: 0 !important; }
.u-w-120 { width: 120px !important; }
.u-wrap-wrap { flex-wrap: wrap !important; }

/* Course pages (generated from data/courses.mjs by scripts/build-course-pages.mjs) */
.course-cover { aspect-ratio: 16 / 9; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: #1a1a1a; }
.course-cover img { width: 100%; height: 100%; object-fit: cover; }
.course-about p + p { margin-top: 14px; }
.course-subhead { margin-top: 30px; font-size: 18px; }
.course-subhead + .check-list { margin-top: 16px; }
.course-related { display: flex; flex-wrap: wrap; gap: 12px 26px; }
.course-price { max-width: 480px; margin: 0 auto; }
.course-checkout-note { margin-top: 14px; font-size: 13.5px; color: var(--dim); text-align: center; }
.sponsor-once { margin-top: 16px; font-size: 14px; color: var(--muted); text-align: center; }
.sponsor-once a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* Touch screens: every standalone link and button gets a 44px tap area (WCAG 2.5.5) without
   changing how the text looks, form fields stay at 16px so iOS doesn't zoom in on focus, and
   no label drops below 12px. */
@media (pointer: coarse), (max-width: 640px) {
  .foot-links { gap: 0 22px; }
  /* flex: none keeps each link at its natural width: min-width alone lets flex rows squash them */
  .foot-links a, .foot-bottom a, .subnav a, .form-help a, .crumbs a, .link-arrow { display: inline-flex; flex: none; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; }
  .crumbs { margin-bottom: 10px; }
  .form-help { gap: 0 22px; }
  .socials { gap: 4px; }
  .socials a { display: grid; place-items: center; width: 44px; height: 44px; }
  .bio-toggle { min-height: 44px; margin-top: 4px; }
  .tab { min-height: 44px; }
  .newsletter-form input { font-size: 16px; }
  .picker-choice span { font-size: 13px; }
  .picker-choice .picker-flag { font-size: 12px; }
}
@media (max-width: 920px) {
  /* Leave room under the footer so the floating Register bar never covers its last links */
  body:has(.mobile-cta) .site-footer { padding-bottom: 110px; }
}
@media (max-width: 640px) {
  /* Button labels never break mid-label: a pair that doesn't fit side by side stacks instead,
     each stretching to the full width */
  .hero-ctas .btn { flex: 1 1 auto; justify-content: center; white-space: nowrap; }
  /* Long tab labels ("In person, High Wycombe") stack as full-width rows instead of wrapping
     inside the pill */
  .tabs { display: grid; width: 100%; border-radius: 24px; }
  .tab { text-align: center; }
}
@media (max-width: 920px) {
  /* A single cover fills the card on phones (the two-cover layout splits it into columns) */
  .bundle-media.bundle-media-single { grid-template-columns: 1fr; aspect-ratio: 16 / 9; }
}

/* "+ Arabic" / "+ Islamic Studies" bundle panels on the single-subject diploma pages */
.addon { margin-top: 28px; border: 1px solid var(--accent); border-radius: var(--radius); background: rgba(255, 190, 61, 0.04); }
.grid-2 > .addon { grid-column: 1 / -1; }
.addon summary { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; padding: 18px 22px; cursor: pointer; list-style: none; font-family: var(--display); font-weight: 600; font-size: 17px; }
.addon summary::-webkit-details-marker { display: none; }
.addon-plus { flex-shrink: 0; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--gradient); color: var(--on-accent); font-size: 20px; line-height: 1; transition: transform .3s var(--ease); }
.addon[open] .addon-plus { transform: rotate(45deg); }
.addon-note { color: var(--muted); font-weight: 500; }
.addon-tag { margin-left: auto; font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.addon-body { padding: 4px 22px 24px; }
.addon-body > p { margin-bottom: 18px; }
.addon-years { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 18px 28px; margin-bottom: 18px; }
.addon-years h4 { margin-bottom: 10px; color: var(--accent); }
.addon .grid-2 { margin-bottom: 18px; }
.addon-cta { margin-top: 8px; }
@media (max-width: 640px) { .addon-tag { margin-left: 44px; } .addon-cta .btn { width: 100%; } }

/* Student reviews carousel (homepage): swipe or use the arrows; long reviews open with Read more */
.reviews-section { padding-top: 24px; }
.reviews-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.reviews-head h2 { margin: 0; }
.reviews { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0 2px; padding: 4px 2px 12px; scrollbar-width: none; }
.reviews::-webkit-scrollbar { display: none; }
.review { flex: none; width: min(380px, 82vw); scroll-snap-align: start; display: flex; flex-direction: column; padding: 28px 26px 24px; border: 1px solid var(--line); border-radius: var(--radius); background: #18181a; }
.review-text { position: relative; font-size: 15.5px; line-height: 1.7; color: var(--text); max-height: calc(1.7em * 7); overflow: hidden; }
.review-text p + p { margin-top: 12px; }
.review-text::before { content: "\201C"; display: block; font-family: var(--display); font-size: 44px; line-height: 0.8; margin-bottom: 6px; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.review.clamped .review-text::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3.4em; background: linear-gradient(rgba(24, 24, 26, 0), #18181a); }
.review.open .review-text { max-height: none; }
.review.open .review-text::after { display: none; }
.review-more { align-self: flex-start; margin-top: 10px; padding: 0; font-family: var(--display); font-weight: 600; font-size: 14px; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.review figcaption { margin-top: auto; padding-top: 18px; font-size: 13.5px; color: var(--dim); }
.review figcaption b { display: block; font-weight: 600; color: var(--text); }
@media (max-width: 640px) { .reviews-head { align-items: center; } .reviews-head .kicker { margin-bottom: 8px; } }

/* Homepage teacher faces: every photo sits in .face-pic; .pop photos are cut-outs whose heads rise
   above the ring. Cut-outs are 320x400 with the ring filling the bottom 320x320, faces scaled alike. */
.face-pic { position: relative; display: block; width: 112px; margin: 0 auto 16px; transition: transform .4s var(--ease); }
.faces .face-pic img { margin: 0; }
.face-pic.pop { height: 140px; }
.face-pic.pop::before { content: ""; position: absolute; left: 0; bottom: 0; width: 112px; height: 112px; border-radius: 50%; background: var(--gradient); box-shadow: 0 0 0 6px rgba(255, 190, 61, 0.08), 0 12px 36px -10px rgba(255, 170, 50, 0.55); transition: box-shadow .4s var(--ease); }
.face-pic.pop::after { content: ""; position: absolute; left: 3px; bottom: 3px; width: 106px; height: 106px; border-radius: 50%; background: #1a1a1c; }
.faces .face-pic.pop img { position: absolute; inset: 0; z-index: 1; width: 112px; height: 140px; padding: 0; border-radius: 0; background: none; box-shadow: none; object-fit: contain; clip-path: inset(0 3px 3px 3px round 0 0 53px 53px); }
.faces figure:hover .face-pic.pop img { transform: none; box-shadow: none; }
.faces figure:hover .face-pic.pop { transform: scale(1.04); }
.faces figure:hover .face-pic.pop::before { box-shadow: 0 0 0 8px rgba(255, 190, 61, 0.14), 0 18px 48px -8px rgba(255, 170, 50, 0.8); }
.face-pic:not(.pop) { margin-top: 28px; }

/* Homepage top, tightened: smaller hero logo, no full-screen intro, stats on one line each,
   and less empty space between the stats, the reviews and Choose your path */
.intro { min-height: 0; padding: 56px 24px 24px; }
.intro-logo { width: min(220px, 52vw); margin-bottom: 26px; }
.intro .lead { margin-bottom: 28px; }
.figures { margin-top: 40px; }
.figures dd { white-space: nowrap; }
.reviews-section { padding: 48px 0 56px; }
#paths { padding-top: 56px; }
.reviews-head { margin-bottom: 20px; }
.reviews-head h2 { font-size: clamp(24px, 2.4vw, 32px); }
.review { width: min(300px, 76vw); padding: 22px 20px 18px; }
.review-text { font-size: 14.5px; line-height: 1.65; max-height: calc(1.65em * 5); }
.review-text::before { font-size: 34px; margin-bottom: 2px; }
.review figcaption { padding-top: 14px; font-size: 13px; }
@media (max-width: 640px) {
  .intro { padding: 40px 20px 16px; }
  .figures { margin-top: 32px; gap: 10px; }
  .figures dt { font-size: 26px; }
  .figures dd { font-size: 12px; }
  .reviews-section { padding: 36px 0 44px; }
  #paths { padding-top: 44px; }
}

/* Homepage header logo hides while the big intro logo is on screen (main.js toggles .brand-tucked) */
.brand { transition: opacity .35s var(--ease), transform .35s var(--ease); }
.brand.brand-tucked { opacity: 0; transform: translateY(-6px); pointer-events: none; }

/* Teacher cards: cut-out photos whose heads rise above the gold ring (scripts/build-portraits.mjs).
   --s is the ring size; the image is 320x400 with the ring filling its bottom 320x320. */
.portrait-pop { --s: 80px; position: relative; display: block; width: var(--s); height: calc(var(--s) * 1.25); margin-bottom: 18px; border: 0; border-radius: 0; flex: none; }
.portrait-pop.u-w-120 { --s: 120px; height: 150px !important; }
.portrait-pop::before { content: ""; position: absolute; left: 0; bottom: 0; width: var(--s); height: var(--s); border-radius: 50%; background: var(--gradient); box-shadow: 0 10px 30px -12px rgba(255, 170, 50, 0.5); }
.portrait-pop::after { content: ""; position: absolute; left: 2px; bottom: 2px; width: calc(var(--s) - 4px); height: calc(var(--s) - 4px); border-radius: 50%; background: #1a1a1c; }
.portrait-pop img { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; object-fit: contain; clip-path: inset(0 2px 2px 2px round 0 0 calc(var(--s) / 2) calc(var(--s) / 2)); }

/* Homepage winter registration banner, full width on phones, framed on desktop */
.promo { max-width: 1140px; margin: 24px auto 0; }
.promo-ctas { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.promo-banner { display: block; overflow: hidden; border: 1px solid rgba(255, 190, 61, 0.35); border-radius: var(--radius); box-shadow: 0 30px 80px -40px rgba(255, 170, 50, 0.5); transition: transform .35s var(--ease); }
.promo-banner img { display: block; width: 100%; height: auto; }
.promo-banner:hover { transform: translateY(-3px); }
@media (max-width: 1180px) { .promo { margin: 16px 16px 0; } }
@media (max-width: 640px) { .promo-ctas .btn { flex: 1 1 100%; } }

/* Diploma registration form (register-form.js) */
.reg-wrap { max-width: 760px; margin: 0 auto; }
.reg-form { display: grid; gap: 18px; padding: 28px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: rgba(18, 18, 20, 0.84); backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
.reg-group { border: 0; margin: 0; padding: 0; min-width: 0; }
.reg-group[hidden] { display: none; }
.reg-group legend { font-family: var(--display); font-weight: 700; font-size: 17px; margin-bottom: 12px; }
.reg-hint { font-size: 13.5px; color: var(--muted); margin: -4px 0 12px; }
.reg-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.reg-choice { position: relative; display: block; cursor: pointer; }
.reg-choice input { position: absolute; opacity: 0; pointer-events: none; }
.reg-choice span { display: flex; flex-direction: column; gap: 3px; height: 100%; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: 12px; transition: border-color .2s, background .2s; }
.reg-choice b { font-size: 15px; font-weight: 600; }
.reg-choice small { font-size: 13px; color: var(--muted); }
.reg-choice input:checked + span { border-color: var(--accent); background: rgba(255, 190, 61, 0.08); }
.reg-choice input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.reg-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.reg-fields label { display: grid; gap: 6px; font-size: 13.5px; color: var(--muted); }
.reg-fields input { width: 100%; min-height: 46px; padding: 10px 14px; border: 1px solid var(--line-strong); border-radius: 10px; background: rgba(0, 0, 0, 0.25); color: var(--text); font: inherit; font-size: 16px; }
.reg-fields input:focus { outline: none; border-color: var(--accent); }
.reg-summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 16px 18px; border-radius: 12px; background: rgba(255, 190, 61, 0.08); border: 1px solid rgba(255, 190, 61, 0.35); }
.reg-summary span { color: var(--accent); font-weight: 600; }
.reg-status { min-height: 1.4em; font-size: 14.5px; color: var(--muted); }
.reg-status.done { font-size: 16px; color: var(--text); }
.reg-fineprint { font-size: 13px; color: var(--dim); text-align: center; }
@media (max-width: 640px) { .reg-form { padding: 20px 16px; } .reg-fields { grid-template-columns: 1fr; } }
.reg-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.reg-form [hidden] { display: none !important; }
@media (max-width: 640px) { .reg-choices { grid-template-columns: 1fr 1fr; } .reg-choice span { padding: 12px; } .reg-choice b { font-size: 14px; } .reg-choice small { font-size: 12px; } }
.promo-ctas .btn-ghost { border-color: var(--accent); }
.promo-best { position: relative; }
.promo-flag { position: absolute; top: -11px; right: 14px; transform: rotate(4deg); padding: 3px 10px; border-radius: 999px; background: var(--text); color: var(--bg); font-size: 10.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; white-space: nowrap; }
@media (max-width: 640px) { .promo-ctas { display: grid; grid-template-columns: 1fr 1fr; } .promo-ctas .btn { flex: none; } .promo-best { grid-column: 1 / -1; grid-row: 1; margin-top: 8px; } }
@media (max-width: 640px) { .promo-ctas .btn { white-space: nowrap; padding: 14px 12px; } }

/* Winter offer on the price chooser and registration form */
.price-was { margin-right: 8px; font-size: 0.55em; font-weight: 500; color: var(--dim); }
.picker-promo, .reg-promo { padding: 12px 16px; border-radius: 12px; border: 1px dashed var(--accent); background: rgba(255, 190, 61, 0.08); font-size: 14.5px; text-align: center; }
.reg-promo { display: grid; gap: 4px; text-align: left; }
.reg-promo b { color: var(--accent); }
.reg-note { font-size: 14px; color: var(--muted); }
.reg-summary s, .reg-choice s { color: var(--dim); font-weight: 400; }
.reg-code input { width: 100%; min-height: 46px; padding: 10px 14px; border: 1px solid var(--accent); border-radius: 10px; background: rgba(0, 0, 0, 0.25); color: var(--text); font: inherit; font-size: 16px; letter-spacing: 0.06em; text-transform: uppercase; }
.reg-code input:focus { outline: none; box-shadow: 0 0 0 3px rgba(255, 190, 61, 0.25); }
.reg-code input::placeholder { text-transform: none; letter-spacing: 0; color: var(--dim); }
.reg-promo-note { display: flex; align-items: center; gap: 12px; margin-top: 12px; padding: 14px 16px; border-radius: 12px; background: var(--gradient); color: var(--on-accent); font-size: 15.5px; font-weight: 600; line-height: 1.45; box-shadow: var(--glow); }
.reg-promo-note::before { content: "✓"; display: grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 50%; background: rgba(0, 0, 0, 0.18); font-weight: 800; }
.reg-promo-note b { color: inherit; font-weight: 800; letter-spacing: 0.04em; }
.reg-form .req { color: var(--accent); font-weight: 700; }
.reg-sub { margin: 4px 0 10px; font-size: 13.5px; color: var(--muted); }
.reg-required { margin-top: 12px; font-size: 12.5px; color: var(--dim); }
.reg-selfpaced { margin: 0; padding: 0 0 0 12px; border-left: 3px solid var(--accent); font-size: 14.5px; color: var(--muted); }
.reg-selfpaced b { color: var(--text); }
.paths.one { grid-template-columns: minmax(0, 560px); justify-content: center; }

/* Bundle page: collapsible syllabus sections (scripts/build-addons.mjs) */
.syllabus-list { display: grid; gap: 16px; }
.syllabus-drop { border: 1px solid var(--accent); border-radius: var(--radius); background: rgba(255, 190, 61, 0.04); }
.syllabus-drop summary { display: flex; align-items: center; gap: 14px; padding: 20px 22px; cursor: pointer; list-style: none; font-family: var(--display); font-weight: 700; font-size: 19px; }
.syllabus-drop summary::-webkit-details-marker { display: none; }
.syllabus-drop[open] .addon-plus { transform: rotate(45deg); }
.syllabus-hint { margin-left: auto; font-family: var(--body, inherit); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.syllabus-drop[open] .syllabus-hint { display: none; }
.syllabus-body { padding: 0 22px 26px; }
.syllabus-body > .lead { margin-bottom: 22px; }
@media (max-width: 640px) { .syllabus-drop summary { font-size: 17px; padding: 18px 16px; } .syllabus-body { padding: 0 14px 20px; } }
/* Section tabs: land with the heading clear of the sticky header and tab bar */
.section[id] { scroll-margin-top: 40px; }
@media (max-width: 640px) { .section[id] { scroll-margin-top: 84px; } }
.bundle-price .winter-tag { display: block; margin-top: 10px; padding-left: 12px; border-left: 3px solid var(--accent); color: var(--accent); font-size: 14px; font-weight: 600; line-height: 1.45; }
.reg-agree { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: 12px; cursor: pointer; font-size: 15px; line-height: 1.5; }
.reg-agree input { flex: none; width: 22px; height: 22px; margin-top: 1px; accent-color: var(--accent); }
.reg-agree a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.reg-form textarea { width: 100%; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 10px; background: rgba(0, 0, 0, 0.25); color: var(--text); font: inherit; font-size: 16px; resize: vertical; }
.reg-form textarea:focus { outline: none; border-color: var(--accent); }
.reg-form .reg-fields input::placeholder { color: var(--dim); }
.reg-submit:disabled { opacity: 0.45; cursor: not-allowed; box-shadow: none; }
.winter-note { margin: 4px 0 22px; padding-left: 12px; border-left: 3px solid var(--accent); color: var(--accent); font-size: 15px; font-weight: 600; line-height: 1.45; }
.btn-down:hover svg { transform: translateY(3px); }

/* Bundle "What's included": thumbnail plus plain course facts, no links */
.course-info { padding-bottom: 22px; }
.course-info .card-media { margin-bottom: 18px; }
.card.course-info:hover { transform: none; border-color: var(--line); background: var(--surface); }
.card.course-info:hover .card-media img { transform: none; }
.info-list { display: grid; gap: 0; margin: 0; }
.info-list div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-top: 1px solid var(--line); }
.info-list div:first-child { border-top: 0; padding-top: 0; }
.info-list dt { white-space: nowrap; color: var(--muted, #a8a8a8); font-size: 14.5px; }
.info-list dd { margin: 0; text-align: right; font-weight: 600; font-size: 15px; }

/* Bundle page hero: the winter banner with the course name on one line underneath */
.bundle-hero img { display: block; width: 100%; height: auto; border: 1px solid rgba(255, 190, 61, 0.35); border-radius: var(--radius); box-shadow: 0 30px 80px -40px rgba(255, 170, 50, 0.5); }
.bundle-hero-title { margin-top: 22px; font-size: clamp(22px, 6.2vw, 48px); white-space: nowrap; text-align: center; }
.bundle-hero { max-width: 900px; margin: 0 auto; }
.reg-promo-note.picker-winter { margin: 18px auto; max-width: 600px; text-align: left; }

/* Bundle page prospectus cards: cover, title and two links */
.prospectus-card .prospectus-cover { display: block; max-width: 220px; margin: 0 auto 20px; border-radius: 10px; overflow: hidden; box-shadow: 0 20px 50px -25px rgba(0, 0, 0, 0.8); }
.prospectus-card .prospectus-cover img { display: block; width: 100%; height: auto; }
.prospectus-card h3, .prospectus-card p { text-align: center; }
.prospectus-links { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 10px 22px; margin-top: 14px; font-weight: 600; }
.book-title { text-align: center; margin: 56px 0 22px; }
.section-head + .book-title { margin-top: 10px; }
/* Keep a turning page inside the book so it never widens the page on phones */
.flipbook-stage { overflow: clip; overflow-clip-margin: 0px; }
.picker-equiv { margin: 22px 0 10px; text-align: right; font-size: 13.5px; font-weight: 600; letter-spacing: 0.02em; color: var(--accent); }
.picker-equiv + .picker-prices { margin-top: 0; }
.flipbook-stage { transition: transform .5s var(--ease); }
/* Register button with a second line naming what it covers */
.btn.btn-stack { flex-direction: column; gap: 2px; line-height: 1.15; }
.btn.btn-stack small { font-size: 12.5px; font-weight: 600; opacity: .8; }
.paths.two { margin-top: 48px; }
/* Gradient buttons: draw the fade under the transparent border too, so its pale end never
   repeats as a thin line down the left edge */
.btn, .btn-primary, .btn-primary:hover { background-origin: border-box; }
/* Register page: one card per kind of course */
.reg-paths { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.reg-paths .choice { display: flex; flex-direction: column; align-items: flex-start; }
.reg-paths .choice p { flex: 1; }
@media (max-width: 920px) { .reg-paths { grid-template-columns: 1fr; } }
.path-body .link-arrow.link-stack { flex-direction: column; gap: 2px; line-height: 1.2; padding: 11px 28px; }
.link-stack small { font-family: var(--body, inherit); font-size: 12.5px; font-weight: 500; color: var(--muted); }
/* All courses page: thumbnails only */
.thumb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.thumb-card { display: block; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--line); aspect-ratio: 16 / 9; background: #1a1a1a; transition: transform .35s var(--ease), border-color .3s; }
.thumb-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb-card:hover { transform: translateY(-4px); border-color: rgba(255, 190, 61, 0.45); }
@media (max-width: 920px) { .thumb-grid { grid-template-columns: 1fr 1fr; gap: 14px; } }
@media (max-width: 560px) { .thumb-grid { grid-template-columns: 1fr; } }
.path-body h3 { margin-bottom: 18px; }
