/* ==========================================================================
   RITUAL — Home Option B · "Index"
   Editorial / type-forward. Asymmetric hero on parchment,
   disciplines as an index list, horizontal class rail.
   ========================================================================== */

/* ── Hero (asymmetric, light) ────────────────────────────────── */
.b-hero {
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
  min-height: 100svh;
  background: var(--parchment);
}
@media (max-width: 880px) { .b-hero { grid-template-columns: 1fr; } }
.b-hero__copy {
  display: flex; flex-direction: column; justify-content: center;
  padding: 120px var(--gutter) 4rem;
  max-width: 720px; margin-left: auto; width: 100%;
}
.b-hero__index {
  display: flex; align-items: center; gap: 0.9rem;
  font-family: var(--font-caps); font-size: 0.66rem; letter-spacing: var(--track-wider);
  text-transform: uppercase; color: var(--sand-muted); margin-bottom: 2rem;
}
.b-hero__index::before { content: ''; width: 42px; height: 1px; background: var(--sand); }
.b-hero__title {
  font-size: clamp(3rem, 7.5vw, 5.75rem);
  line-height: 0.98; letter-spacing: 0.02em;
  margin-bottom: 1.75rem;
}
.b-hero__title em { font-style: italic; color: var(--sand-muted); }
.b-hero__sub { font-size: var(--t-lead); line-height: var(--lh-loose); color: var(--sand-muted); max-width: 42ch; margin-bottom: 2.5rem; }
.b-hero__actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }
.b-hero__meta {
  display: flex; gap: 2.5rem; flex-wrap: wrap;
  padding-top: 2rem; border-top: 1px solid var(--border-light);
}
.b-hero__meta div { display: flex; flex-direction: column; gap: 0.3rem; }
.b-hero__meta-num { font-family: var(--font-display); font-size: 1.5rem; letter-spacing: 0.03em; line-height: 1; }
.b-hero__meta-label { font-family: var(--font-caps); font-size: 0.58rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--sand-muted); }
.b-hero__art { position: relative; overflow: hidden; background: var(--sand); }
.b-hero__art img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.b-hero__art::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, rgba(46,43,38,0.16), transparent 40%); }
@media (max-width: 880px) { .b-hero__art { min-height: 56vw; } .b-hero__copy { margin: 0; max-width: 100%; } }

/* ── Section header (index style) ────────────────────────────── */
.b-shead {
  display: flex; align-items: baseline; gap: 1.25rem;
  padding-bottom: 1.5rem; margin-bottom: clamp(2rem, 4vw, 3.5rem);
  border-bottom: 1px solid var(--border);
}
.b-shead__main { flex: 1; }
.b-shead__eyebrow { font-family: var(--font-caps); font-size: 0.64rem; letter-spacing: var(--track-wider); text-transform: uppercase; color: var(--sand-muted); display: block; margin-bottom: 0.5rem; }
.b-shead__title { font-size: clamp(1.75rem, 3.5vw, 2.75rem); letter-spacing: var(--track-normal); margin: 0; }
.b-shead__aside { font-size: 0.9rem; color: var(--sand-muted); max-width: 30ch; text-align: right; }
@media (max-width: 680px) { .b-shead { flex-wrap: wrap; gap: 0.5rem 1rem; } .b-shead__aside { display: none; } }

/* ── Disciplines index list ──────────────────────────────────── */
.b-index-row {
  display: grid;
  grid-template-columns: 1.1fr 1.5fr auto;
  gap: 1.5rem; align-items: baseline;
  padding: clamp(1.5rem, 3vw, 2.25rem) 0.5rem;
  border-bottom: 1px solid var(--border-light);
  transition: background var(--fast) var(--ease);
}
.b-index-row:hover { background: var(--off-white); }
.b-index-row__title { font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: 0.03em; line-height: 1.1; }
.b-index-row__desc { font-size: 0.92rem; color: var(--sand-muted); line-height: var(--lh-base); }
.b-index-row__tag { font-family: var(--font-caps); font-size: 0.6rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--sand-muted); white-space: nowrap; }
@media (max-width: 760px) {
  .b-index-row { grid-template-columns: 1fr; gap: 0.4rem; }
  .b-index-row__desc,
  .b-index-row__tag { grid-column: auto; }
}

/* ── Instructor (offset editorial) ───────────────────────────── */
.b-instructor { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 5rem); align-items: center; }
@media (max-width: 820px) { .b-instructor { grid-template-columns: 1fr; } }
.b-instructor__art { position: relative; }
.b-instructor__photo { aspect-ratio: 5/6; overflow: hidden; border-radius: var(--r); background: var(--sand); box-shadow: var(--shadow-lg); }
.b-instructor__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.b-instructor__stamp {
  position: absolute; bottom: -1.25rem; left: -1.25rem;
  background: var(--espresso); color: var(--off-white);
  padding: 1rem 1.5rem; border-radius: var(--r);
}
.b-instructor__stamp-num { font-family: var(--font-display); font-size: 1.8rem; line-height: 1; letter-spacing: 0.03em; }
.b-instructor__stamp-label { font-family: var(--font-caps); font-size: 0.56rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: rgba(245,242,236,0.6); margin-top: 0.3rem; }
.b-instructor__name { font-size: clamp(2.25rem, 4.5vw, 3.5rem); letter-spacing: 0.02em; margin-bottom: 0.5rem; }
.b-instructor__cred { font-family: var(--font-caps); font-size: 0.66rem; letter-spacing: var(--track-wider); text-transform: uppercase; color: var(--sage-accent); margin-bottom: 1.75rem; }
.b-instructor__bio { color: var(--sand-muted); font-size: 1rem; line-height: var(--lh-loose); margin-bottom: 1rem; max-width: 48ch; }
.b-instructor__bio--lead { color: var(--espresso); font-size: var(--t-lead); }

/* ── Class rail (horizontal scroll) ──────────────────────────── */
.b-rail-wrap { margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter); }
.b-rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(280px, 320px);
  gap: clamp(1rem, 2vw, 1.5rem);
  overflow-x: auto; scroll-snap-type: x mandatory;
  padding-bottom: 1.5rem; -webkit-overflow-scrolling: touch;
  scrollbar-width: thin; scrollbar-color: var(--sand) transparent;
}
.b-rail::-webkit-scrollbar { height: 4px; }
.b-rail::-webkit-scrollbar-thumb { background: var(--sand); border-radius: 2px; }
.b-vcard {
  scroll-snap-align: start;
  background: var(--off-white); border: 1px solid var(--border); border-radius: var(--r);
  overflow: hidden; cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}
.b-vcard:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.b-vcard__thumb { position: relative; aspect-ratio: 16/10; overflow: hidden; display: flex; align-items: center; justify-content: center; color: rgba(245,242,236,0.9); }
.b-vcard__thumb svg { width: 30px; height: 30px; opacity: 0.9; }
.b-vcard__dur { position: absolute; bottom: 0.6rem; right: 0.6rem; background: rgba(46,43,38,0.55); color: var(--off-white); font-family: var(--font-caps); font-size: 0.58rem; letter-spacing: 0.05em; padding: 0.2em 0.6em; border-radius: var(--r-sm); }
.b-vcard__body { padding: 1.1rem 1.25rem 1.4rem; }
.b-vcard__meta { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; }
.b-vcard__tag { font-family: var(--font-caps); font-size: 0.58rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--sand-muted); }
.b-vcard__tag--disc { color: var(--sage-accent); }
.b-vcard__title { font-family: var(--font-display); font-size: 1.2rem; letter-spacing: 0.03em; line-height: 1.25; }
.b-rail-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 1.5rem; gap: 1rem; flex-wrap: wrap; }
.b-rail-hint { font-family: var(--font-caps); font-size: 0.6rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: var(--sand-muted); }

/* ── Features ruled list ─────────────────────────────────────── */
.b-feat-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 clamp(3rem, 6vw, 6rem);
}
.b-feat-item {
  padding: clamp(1.5rem, 2.5vw, 2rem) 0;
  border-bottom: 1px solid var(--border-light);
}
.b-feat-item__hd {
  display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem;
}
.b-feat-item__hd svg { flex-shrink: 0; width: 18px; height: 18px; color: var(--sand-muted); }
.b-feat-item__hd h3 { font-size: 1rem; margin: 0; letter-spacing: 0.03em; }
.b-feat-item p { font-size: 0.86rem; color: var(--sand-muted); line-height: var(--lh-loose); margin: 0; max-width: 38ch; }
@media (max-width: 680px) { .b-feat-list { grid-template-columns: 1fr; } }

/* ── Pricing (editorial split) ───────────────────────────────── */
.b-pricing { display: grid; grid-template-columns: 1fr 1fr; max-width: 920px; margin: 0 auto; border: 1.5px solid var(--border); border-radius: var(--r); overflow: hidden; background: var(--off-white); }
@media (max-width: 700px) { .b-pricing { grid-template-columns: 1fr; } }
.b-plan { padding: clamp(2rem, 4vw, 3rem); display: flex; flex-direction: column; position: relative; }
.b-plan + .b-plan { border-left: 1px solid var(--border); }
@media (max-width: 700px) { .b-plan + .b-plan { border-left: none; border-top: 1px solid var(--border); } }
.b-plan--featured { background: var(--espresso); color: var(--off-white); }
.b-plan__row { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 0.4rem; }
.b-plan__name { font-family: var(--font-display); font-size: 1.05rem; letter-spacing: 0.03em; color: var(--sand-muted); }
.b-plan--featured .b-plan__name { color: var(--sand); }
.b-plan__badge { font-family: var(--font-caps); font-size: 0.56rem; letter-spacing: var(--track-wide); text-transform: uppercase; background: var(--sand); color: var(--espresso); padding: 0.3em 0.8em; border-radius: var(--r-sm); white-space: nowrap; }
.b-plan__price { font-family: var(--font-display); font-size: clamp(2.75rem, 6vw, 3.75rem); line-height: 1; letter-spacing: 0.03em; margin: 1rem 0 0.3rem; }
.b-plan--featured .b-plan__price { color: var(--off-white); }
.b-plan__period { font-size: 0.8rem; color: var(--sand-muted); margin-bottom: 1.75rem; }
.b-plan--featured .b-plan__period { color: rgba(245,242,236,0.55); }
.b-plan__feats { list-style: none; display: flex; flex-direction: column; gap: 0.75rem; margin-bottom: 2rem; flex: 1; }
.b-plan__feats li { display: flex; align-items: center; gap: 0.7rem; font-size: 0.9rem; }
.b-plan--featured .b-plan__feats li { color: rgba(245,242,236,0.82); }
.b-plan__check { flex-shrink: 0; width: 16px; height: 16px; color: var(--sand); }
.b-pricing-trust { text-align: center; margin-top: 2rem; font-size: 0.84rem; color: var(--sand-muted); }

/* ── Instructor pull-quote (merged from the retired quote carousel) ── */
.b-instructor__quote {
  margin: 1.5rem 0 0;
  padding-left: 1.25rem;
  border-left: 2px solid var(--sand);
}
.b-instructor__quote p {
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2vw, 1.4rem);
  line-height: 1.4;
  letter-spacing: 0.01em;
  margin: 0 0 0.6rem;
}
.b-instructor__quote em { font-style: italic; }
.b-instructor__quote cite {
  font-style: normal;
  font-family: var(--font-caps);
  font-size: 0.6rem;
  letter-spacing: var(--track-wide);
  text-transform: uppercase;
  color: var(--sand-muted);
}

/* ── FAQ (shares a-faq look but namespaced) ──────────────────── */
.b-faq { max-width: 760px; margin: 0 auto; }
.b-faq details { border-bottom: 1px solid var(--border); }
.b-faq details:first-child { border-top: 1px solid var(--border); }
.b-faq summary { list-style: none; cursor: pointer; font-family: var(--font-display); font-size: 1.15rem; letter-spacing: 0.03em; padding: 1.4rem 0; display: flex; justify-content: space-between; align-items: center; gap: 1rem; transition: color var(--fast) var(--ease); }
.b-faq summary::-webkit-details-marker { display: none; }
.b-faq summary:hover { color: var(--sand-muted); }
.b-faq summary::after { content: '+'; font-family: var(--font-display); font-size: 1.5rem; color: var(--sand-muted); transition: transform var(--fast) var(--ease); }
.b-faq details[open] summary::after { transform: rotate(45deg); }
.b-faq__body { padding: 0 0 1.6rem; font-size: 0.92rem; color: var(--sand-muted); line-height: var(--lh-loose); max-width: 60ch; }

/* ── Final CTA ───────────────────────────────────────────────── */
.b-cta { text-align: center; }
.b-cta h2 { color: var(--off-white); font-size: clamp(2.5rem, 6vw, 4.5rem); line-height: 1.04; letter-spacing: 0.02em; margin-bottom: 1.25rem; }
.b-cta h2 em { font-style: italic; color: var(--sand); }
.b-cta p { color: rgba(245,242,236,0.6); margin-bottom: 2.5rem; }
.b-cta__actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.b-cta__note { margin-top: 1.75rem; font-family: var(--font-caps); font-size: 0.62rem; letter-spacing: var(--track-wide); text-transform: uppercase; color: rgba(245,242,236,0.4); }

/* ── Product proof — real screenshots in pure-CSS device frames ──────────────
   Frames are drawn in CSS; the two <img> are live captures of the /library grid
   (laptop) and a class on a phone. Device corner radii are intentionally larger
   than --r / --r-sm: they depict hardware, not brand UI. */
.devices {
  position: relative;
  max-width: 940px;
  margin: 0 auto clamp(0.5rem, 3vw, 2rem);
  padding-bottom: clamp(2rem, 7vw, 4.5rem); /* room for the phone's overhang + shadows */
}

/* MacBook — open lid (screen) sitting on a slim aluminium base */
.device--mac .device__screen {
  position: relative;
  border-radius: 16px;
  padding: 2.3%;                 /* even bezel */
  background: linear-gradient(#2c2a2b, #1a1919);
  box-shadow: var(--shadow-lg), inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}
.device--mac .device__screen::before {   /* camera dot, top-centre */
  content: ""; position: absolute; top: 1.1%; left: 50%; transform: translateX(-50%);
  width: 5px; height: 5px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
}
.device--mac .device__screen img {
  display: block; width: 100%; height: auto;
  border-radius: 4px; background: var(--parchment);
}
.device--mac .device__base {
  position: relative; left: 50%; transform: translateX(-50%);
  width: 105%; height: clamp(9px, 1.3vw, 13px);
  border-radius: 0 0 11px 11px;
  background: linear-gradient(#d6d1cc, #aca59e);
  box-shadow: var(--shadow-md);
}
.device--mac .device__base::before {     /* lid-open finger groove */
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: clamp(64px, 9vw, 100px); height: 38%;
  border-radius: 0 0 8px 8px;
  background: rgba(24, 21, 19, 0.16);
}

/* iPhone — titanium rail + thin black bezel around the capture (its own status
   bar & Dynamic Island live in the screenshot). Width is a constant % of the
   composition so the overlap scales down intact (never stacks); all frame dims
   are % so the frame scales with it. Radii depict hardware — exempt from --r. */
.device--phone {
  position: absolute; right: 2%; bottom: 0;
  width: 18%; z-index: 2;
  padding: 1.3%;                                      /* titanium rail */
  border-radius: 16% / 8.5%;
  background: linear-gradient(142deg, #ddd8d1 0%, #948d85 26%, #6b645e 50%, #a49d95 74%, #dcd7d0 100%);
  box-shadow: var(--shadow-lg);
}
/* side buttons — metallic nubs poking out from under the rail */
.device--phone::before,
.device--phone::after {
  content: ""; position: absolute; width: 1.6%;
  border-radius: 2px; background: linear-gradient(#cbc5be, #7d766f);
}
.device--phone::before { left: -1.2%;  top: 25%; height: 15%; }   /* volume */
.device--phone::after  { right: -1.2%; top: 30%; height: 10%; }   /* power  */

.device--phone .device__screen {
  position: relative;
  padding: 2.8%;                                      /* even black bezel */
  border-radius: 13.5% / 7.2%;
  background: #0b0a0a;
  overflow: hidden;
}
.device--phone .device__screen img {
  display: block; width: 100%; height: auto;   /* height:auto lets aspect-ratio govern (HTML height attr) */
  aspect-ratio: 1206 / 2380;      /* crops the Safari toolbar off the bottom so it reads as a full-screen app */
  object-fit: cover; object-position: top;
  border-radius: 11.5% / 6.2%;
  background: #000;
}

/* No stacked breakpoint — the overlap composition is retained at every width. */

/* Trailer slot — hidden until index.js is given a media URL */
.showcase-trailer { margin-bottom: clamp(1rem, 2vw, 1.5rem); }
.showcase-trailer video {
  width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block;
  border-radius: var(--r); box-shadow: var(--shadow-lg); background: var(--espresso);
}

/* ── Hierarchy pass: surface tones, type-scale ladder, dark studio interlude ──
   home-b.css loads only on the homepage, so these overrides are page-scoped. */
:root { --alt-surface-2: #D9D5D1; } /* deepened so parchment / alt-1 / alt-2 read as distinct steps */

/* Section-header scale builds toward Pricing, then quiets down after it */
#disciplines .b-shead__title { font-size: clamp(1.9rem, 3.9vw, 3rem); }
#about .b-shead__title { font-size: clamp(2.05rem, 4.4vw, 3.3rem); }
#pricing .b-shead__title { font-size: clamp(2.3rem, 5vw, 3.75rem); }
.shead-quiet .b-shead__title { font-size: clamp(1.5rem, 2.8vw, 2.1rem); }

/* Dark In-studio interlude (espresso, matching the final CTA family) */
.b-studio .b-shead__title { color: var(--off-white); }
.b-studio .b-shead__eyebrow { color: rgba(245,242,236,0.65); }
/* Booking must read clickable: firmer border than the 0.4-alpha ghost default,
   still clearly subordinate to the gold subscription CTAs */
.b-studio .btn--ghost { border-color: rgba(245,242,236,0.55); }

/* ── Subtle parallax — foreground imagery + product mockup only ─────────────
   Native CSS scroll-driven animation (no JS lib). Progressive enhancement:
   only runs where animation-timeline is supported AND motion is allowed; every
   other browser renders these elements static with no layout change. The
   instructor photo drifts inside its overflow-hidden frame with a baseline
   scale() overscan so the drift never reveals a gap (frame + stamp stay put). */
@keyframes parallax-drift {
  from { transform: translateY(14px) scale(var(--parallax-scale, 1)); }
  to   { transform: translateY(-14px) scale(var(--parallax-scale, 1)); }
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .b-instructor__photo img {
      animation: parallax-drift linear both;
      animation-timeline: view();
      animation-range: entry 0% exit 100%;
      will-change: transform;
    }
    .b-instructor__photo img { --parallax-scale: 1.08; }
  }
}
