:root {
  --ink: #0f2036;
  --ink-soft: #1b3350;
  --paper: #f5f7f9;
  --white: #ffffff;
  --text: #1d2b3a;
  --muted: #55657a;
  --line: #d8dfe7;
  --amber: #e3a82b;
  --amber-hover: #f0ba44;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(20px, 5vw, 64px);
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--paper);
}
img, iframe, svg { display: block; max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.12; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }

.wrap { width: min(100%, var(--max)); margin-inline: auto; padding-inline: var(--gutter); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 28px;
  font: 600 1rem/1 var(--sans);
  border: 2px solid transparent; border-radius: 6px;
  text-decoration: none; cursor: pointer;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn-primary { background: var(--amber); color: var(--ink); }
.btn-primary:hover { background: var(--amber-hover); }
.btn-outline { background: transparent; color: var(--white); border-color: rgba(255,255,255,.55); }
.btn-outline:hover { border-color: var(--white); background: rgba(255,255,255,.08); }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: var(--ink-soft); }
form.inline { display: inline; margin: 0; }

/* ---------- top bar + hero ---------- */
.hero { background: var(--ink); color: var(--white); position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url("/images/contours.svg") right -8% bottom -30% / min(900px, 90%) no-repeat;
  opacity: .5;
}
.topbar { position: relative; display: flex; align-items: center; justify-content: space-between; padding-block: 22px; }
.brand { font-family: var(--serif); font-size: 1.25rem; text-decoration: none; letter-spacing: .005em; }
.topbar .login-link { font-size: .95rem; color: rgba(255,255,255,.85); text-underline-offset: 4px; }
.topbar .login-link:hover { color: var(--white); }

.hero-body { position: relative; padding-block: clamp(56px, 11vw, 132px) clamp(64px, 11vw, 124px); }
.hero h1 { font-size: clamp(2.5rem, 6.4vw, 4.75rem); max-width: 15ch; font-weight: 450; }
.hero .lede { margin-top: 28px; max-width: 34em; font-size: clamp(1.1rem, 1.7vw, 1.3rem); line-height: 1.55; color: rgba(255,255,255,.82); }
.hero .actions { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 14px; }

/* ---------- sections ---------- */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section h2 { font-size: clamp(2rem, 4vw, 3rem); }
.section-head { text-align: center; margin-bottom: clamp(32px, 5vw, 56px); }

.video-frame {
  width: min(100%, 960px); margin-inline: auto;
  aspect-ratio: 16 / 9; background: var(--ink);
  border-radius: 10px; overflow: hidden;
  box-shadow: 0 1px 0 var(--line), 0 24px 48px -28px rgba(15,32,54,.45);
}
.video-frame iframe { width: 100%; height: 100%; border: 0; }

.details { background: var(--white); }
.columns { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 48px); }
.column img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; background: #e7ecf1; }
.column h3 { margin-top: 24px; font-size: 1.5rem; }
.column p { margin-top: 12px; color: var(--muted); }

.instructor-grid { display: grid; grid-template-columns: minmax(240px, 380px) 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.instructor-grid img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 8px; background: #e7ecf1; }
.instructor-grid h2 { margin-bottom: 20px; }
.instructor-grid p { font-size: 1.15rem; max-width: 34em; }
.instructor-grid p + p { margin-top: 1em; }

.enroll { background: var(--ink); color: var(--white); text-align: center; }
.enroll h2 { max-width: 20ch; margin-inline: auto; }
.enroll .lede { margin: 20px auto 0; max-width: 32em; color: rgba(255,255,255,.82); }
.enroll .price { margin-top: 32px; font-family: var(--serif); font-size: 2.75rem; line-height: 1; }
.enroll .price small { display: block; margin-top: 8px; font: 400 .95rem/1.4 var(--sans); color: rgba(255,255,255,.7); }
.enroll .actions { margin-top: 28px; }
.enroll .return { margin-top: 24px; font-size: .95rem; color: rgba(255,255,255,.75); }
.enroll .return a { text-underline-offset: 4px; }

/* ---------- footer ---------- */
.site-footer { background: var(--paper); padding-block: 48px 56px; text-align: center; }
.disclaimer { max-width: 46em; margin-inline: auto; font-size: .8125rem; line-height: 1.55; color: var(--muted); }
.footer-logo { margin: 36px auto 0; height: 44px; width: auto; }
.footer-meta { margin-top: 18px; font-size: .95rem; color: var(--muted); }
.footer-meta p + p { margin-top: 4px; }
.footer-meta a { text-underline-offset: 3px; }
.copyright { margin-top: 18px; font-size: .85rem; color: var(--muted); }

/* ---------- login + course pages ---------- */
.simple-page { min-height: 100vh; display: flex; flex-direction: column; }
.simple-page .hero { flex: none; }
.simple-page main { flex: 1; }
.card { width: min(100%, 520px); margin: clamp(32px, 7vw, 72px) auto; background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: clamp(24px, 5vw, 40px); }
.card h1 { font-size: 2rem; }
.card p { margin-top: 12px; color: var(--muted); }
.card form { margin-top: 24px; display: grid; gap: 12px; }
.card label { font-weight: 600; font-size: .95rem; color: var(--text); }
.card input[type="email"] { width: 100%; min-height: 52px; padding: 0 14px; font: inherit; border: 1px solid #aab6c3; border-radius: 6px; background: var(--white); color: var(--text); }
.card input[type="email"]:focus-visible { outline: 3px solid var(--amber); outline-offset: 1px; border-color: var(--ink); }
.notice { margin-top: 20px; padding: 14px 16px; border-radius: 6px; font-size: .95rem; }
.notice.ok { background: #e8f1ea; color: #1f4a2a; }
.notice.err { background: #f8e7e4; color: #6d2118; }
[hidden] { display: none !important; }

.course-head { padding-block: clamp(32px, 6vw, 64px) 0; }
.course-head h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); }
.course-head p { margin-top: 12px; color: var(--muted); max-width: 40em; }
.course-video { padding-block: 32px clamp(48px, 7vw, 88px); }
.course-note { width: min(100%, 960px); margin: 24px auto 0; font-size: .95rem; color: var(--muted); }
.course-note a { text-underline-offset: 3px; }

/* ---------- small screens ---------- */
@media (max-width: 860px) {
  .columns { grid-template-columns: 1fr; max-width: 520px; margin-inline: auto; }
  .instructor-grid { grid-template-columns: 1fr; }
  .instructor-grid img { max-width: 380px; }
}
@media (max-width: 520px) {
  .hero .actions .btn { width: 100%; }
  .enroll .actions .btn, .enroll .actions form { width: 100%; }
  form.inline .btn { width: 100%; }
}
