:root {
  --bg: #F3EADA;
  --bg-soft: #F8F2E8;
  --paper: #F5ECDD;
  --ink: #121B0B;
  --olive: #38451D;
  --olive-2: #50552F;
  --gold: #906516;
  --gold-soft: rgba(144, 101, 22, 0.45);
  --gold-faint: rgba(144, 101, 22, 0.25);
  --lock: #9A8A6E;
  --check: #44561E;
  --white: #FFFDF8;
  --rule: rgba(144, 101, 22, 0.45);
  --shadow: 0 10px 30px rgba(62, 47, 25, 0.08);
  --radius-hero: 20px;
  --s1: 6px; --s2: 10px; --s3: 14px; --s4: 20px; --s5: 28px; --s6: 40px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: Georgia, 'Times New Roman', serif;
  line-height: 1.5;
}
button, a { font: inherit; color: inherit; }

.pw-visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.lesson-shell {
  position: relative;
  max-width: 430px;
  margin: 0 auto;
  min-height: 100svh;
  padding: var(--s4) var(--s4) var(--s6);
  overflow: hidden;
}
.lesson-shell::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid var(--gold-faint);
  border-radius: 30px;
  pointer-events: none;
}

/* ---------- header ---------- */
.lesson-header {
  display: grid;
  grid-template-columns: 1fr 1px 1.08fr;
  gap: var(--s4);
  align-items: center;
  position: relative;
  z-index: 1;
}
.brand, .day-heading { text-align: center; }
.brand h1 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(46px, 13.5vw, 66px);
  line-height: 0.92;
  margin: 0;
  font-weight: 500;
}
.brand-mark { display: block; color: var(--olive); }
.brand p, .day-heading p, .day-kicker {
  font-size: clamp(10px, 2.9vw, 13px);
  line-height: 1.55;
  letter-spacing: 0.16em;
  margin: var(--s2) 0 0;
  color: var(--olive);
}
.header-rule { height: 58%; background: var(--gold-soft); }
.day-kicker { text-align: right; color: var(--gold); margin: 0 0 var(--s2); }
.day-script {
  font-family: 'Great Vibes', 'Segoe Script', cursive;
  font-size: clamp(50px, 14.5vw, 76px);
  line-height: 0.9;
  color: var(--olive);
  margin: 0;
}

/* ---------- journey / rail ---------- */
.journey { position: relative; margin-top: var(--s5); padding-left: 44px; }
.rail {
  position: absolute;
  left: 25px; top: 30px; bottom: 22px;
  width: 1px;
  background: var(--gold);
}

/* ---------- step node ---------- */
.step-node {
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border: 1px solid var(--gold);
  border-radius: 999px;
  background: var(--bg);
  color: var(--gold);
  font-size: 17px;
  flex: 0 0 auto;
}
.hero-step > .step-node {
  position: absolute;
  left: -44px; top: 36px;
  width: 58px; height: 58px;
  font-size: 26px;
  z-index: 3;
}
.hero-step > .step-node .step-node__num {}
.check {
  position: absolute;
  right: -14px; bottom: -4px;
  width: 32px; height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--check);
  color: var(--white);
  border: 2px solid var(--bg);
  box-shadow: 0 2px 6px rgba(62, 47, 25, 0.25);
}
.check[hidden] { display: none; }

/* ---------- hero card ---------- */
.hero-step { position: relative; }
.hero-card {
  position: relative;
  border: 1px solid var(--gold);
  border-radius: var(--radius-hero);
  overflow: hidden;
  background: var(--paper);
  box-shadow: var(--shadow);
}
.hero-label {
  position: absolute;
  z-index: 2;
  top: 0; left: 0;
  padding: var(--s4);
  display: flex;
  flex-direction: column;
  gap: var(--s1);
  letter-spacing: 0.12em;
  color: var(--white);
  text-shadow: 0 1px 8px rgba(18, 27, 11, 0.65);
}
.hero-label strong { font-size: clamp(20px, 6vw, 28px); font-weight: 500; line-height: 1; }
.hero-label span { font-size: clamp(11px, 3.2vw, 15px); letter-spacing: 0.18em; }
.hero-media {
  position: relative;
  aspect-ratio: 4 / 5;
  background: var(--ink) url('/assets/video-poster.png') center 30% / cover no-repeat;
}
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18,27,11,0.18) 0%, rgba(18,27,11,0) 45%, rgba(18,27,11,0.5) 100%);
  pointer-events: none;
}
.play {
  position: absolute;
  left: 50%; top: 46%;
  translate: -50% -50%;
  width: 74px; height: 74px;
  border-radius: 50%;
  border: 2px solid rgba(255, 253, 248, 0.92);
  background: rgba(41, 35, 24, 0.24);
  color: var(--white);
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 2;
}
.play svg { margin-left: 4px; }
.play:focus-visible { outline: 3px solid var(--olive); outline-offset: 4px; }
.hero-caption {
  position: absolute;
  left: var(--s4); right: var(--s4);
  bottom: var(--s4);
  z-index: 2;
  text-align: center;
  color: var(--white);
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(20px, 5.6vw, 28px);
  line-height: 1.15;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}
.hero-caption small {
  display: block;
  margin-top: var(--s2);
  font-family: Georgia, serif;
  font-size: 13px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
}

/* ---------- lower steps ---------- */
.steps { list-style: none; margin: var(--s3) 0 0; padding: 0; }
.step-row {
  position: relative;
  display: grid;
  grid-template-columns: 44px 1fr 24px;
  gap: var(--s3);
  align-items: center;
  min-height: 44px;
  padding: calc(var(--s3) - 3px) 0;
  border-bottom: 1px solid var(--gold-faint);
  min-width: 0;
}
.step-row:last-child { border-bottom: 0; }
.step-row > .step-node {
  position: absolute;
  left: -43px;
  width: 32px; height: 32px;
  font-size: 15px;
}
.step-icon { font-size: 0; color: var(--olive); text-align: center; }
.step-icon svg { display: block; margin: 0 auto; }
.step-copy { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.step-copy strong {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(17px, 4.8vw, 23px);
  font-weight: 500;
  letter-spacing: 0.06em;
  line-height: 1.1;
}
.step-copy small {
  font-size: clamp(9px, 2.6vw, 12px);
  letter-spacing: 0.14em;
  line-height: 1.35;
  color: #4b5160;
}
.lock { font-size: 0; color: var(--lock); justify-self: end; }
.lock svg { display: block; }
.step-row.is-unlocked { cursor: pointer; text-decoration: none; }
.step-row.is-unlocked:hover .step-copy strong { color: var(--gold); }
.go { font-size: 0; color: var(--olive); justify-self: end; }
.go svg { display: block; }
.step-row.is-unlocked:focus-visible { outline: 3px solid var(--olive); outline-offset: 2px; }

/* ---------- foliage ---------- */
.foliage {
  position: absolute;
  pointer-events: none;
  z-index: 0;
  opacity: 0.9;
}
.foliage--top-left {
  top: -6px;
  left: -8px;
  width: 84px;
  transform: scaleX(-1) rotate(-14deg);
}
.foliage--bottom-right {
  right: -10px;
  bottom: -6px;
  width: 96px;
  transform: scaleX(-1) rotate(150deg);
}

/* ---------- video layer ---------- */
.videoframe {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: #000;
  display: grid;
  place-items: center;
}
.videoframe video {
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  background: #000;
}
.videoframe .videoframe__close {
  position: absolute;
  top: 12px; right: 12px;
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.6);
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  z-index: 2;
}

/* ---------- responsive ---------- */
@media (max-width: 350px) {
  .lesson-header { gap: var(--s3); }
  .journey { padding-left: 40px; }
  .rail { left: 22px; }
  .hero-step > .step-node { left: -40px; }
  .step-row > .step-node { left: -39px; }
  .step-row { grid-template-columns: 38px 1fr 22px; gap: var(--s2); }
}

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