* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: var(--breaths-font);
  color: var(--breaths-text);
  line-height: 1.6;
  background: linear-gradient(180deg, var(--breaths-bg-top) 0%, var(--breaths-bg-mid) 70%, var(--breaths-bg-deep) 100%);
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

a { color: var(--breaths-blue); }

h1, h2, h3 { color: var(--breaths-text); }

/* Kicker — uppercase deep-gold eyebrow with a short gold underline (brand signature) */
.kicker {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--breaths-gold-soft);
}
.kicker::after {
  content: '';
  display: block;
  width: 44px;
  height: 3px;
  margin-top: 0.35rem;
  background: var(--breaths-gold-fill);
  border-radius: 2px;
}

/* Header */
.site-header {
  background: var(--breaths-bg-top);
  border-bottom: 1.5px solid var(--breaths-panel-border);
  padding: 0.8rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo-wrap { display: flex; align-items: center; text-decoration: none; }
.logo-lockup { height: 42px; width: auto; display: block; }

.site-header nav { display: flex; align-items: center; gap: 0.2rem; }
.nav-links { display: flex; align-items: center; gap: 0.2rem; }
.nav-toggle { display: none; }

.site-header nav a {
  color: var(--breaths-text);
  text-decoration: none;
  font-weight: 600;
  padding: 0.45rem 0.7rem;
  border-radius: 8px;
  white-space: nowrap;
}
.site-header nav a:hover { background: var(--breaths-bg-deep); }
.site-header nav a.nav-ext .ext-mark { color: var(--breaths-gold-soft); font-size: 0.85em; font-weight: 700; }

/* Phones: the links collapse behind ☰ so the header row always fits the frame. */
@media (max-width: 640px) {
  .site-header { padding: 0.6rem 0.8rem; gap: 0.4rem; }
  .logo-lockup { height: 34px; }
  .nav-toggle {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 44px; min-height: 44px;
    font: inherit; font-size: 1.1rem; line-height: 1; cursor: pointer;
    color: var(--breaths-text);
    background: transparent;
    border: 1.5px solid var(--breaths-panel-border);
    border-radius: 10px;
  }
  /* Anchored to .site-header — sticky, so it's a positioned containing block. */
  .nav-links {
    display: none;
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0.8rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.1rem;
    min-width: 190px;
    padding: 0.4rem;
    background: var(--breaths-bg-top);
    border: 1.5px solid var(--breaths-panel-border);
    border-radius: 14px;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.16);
    z-index: 20;
  }
  .site-header nav.open .nav-links { display: flex; }
  .site-header nav a { padding: 0.6rem 0.7rem; }
  .install-btn { font-size: 0.78rem; padding: 0.45rem 0.75rem; margin-inline-start: 0; }
}

/* Narrowest phones: the install button sheds its label and becomes an icon. */
@media (max-width: 400px) {
  .logo-lockup { height: 30px; }
  .install-btn .ib-label { display: none; }
  .install-btn { min-width: 44px; min-height: 44px; padding: 0.45rem; font-size: 1rem; }
}
/* Site-wide ambient aurora — very faint, fixed behind everything, on every view */
.ambient { position: fixed; inset: 0; pointer-events: none; z-index: -1; overflow: hidden; }
.ambient span {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  animation: orb-drift 26s ease-in-out infinite alternate;
}
.ambient span:first-child { width: 46vmax; height: 46vmax; background: rgba(253, 185, 19, 0.07); top: -18vmax; left: -10vmax; }
.ambient span:last-child { width: 40vmax; height: 40vmax; background: rgba(127, 169, 155, 0.09); bottom: -16vmax; right: -8vmax; animation-delay: -13s; }
@media (prefers-reduced-motion: reduce) { .ambient span { animation: none; } }

.sound-toggle {
  font: inherit;
  font-size: 1rem;
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: 8px;
  padding: 0.3rem 0.5rem;
  margin-inline-start: 0.35rem;
  cursor: pointer;
}
.sound-toggle:hover { border-color: var(--breaths-gold-fill); }

.lang-switch {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--breaths-text);
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: 8px;
  padding: 0.35rem 0.5rem;
  margin-inline-start: 0.5rem;
  cursor: pointer;
}

/* Hero — white canvas, blue headline, one gold moment. "Everything breathes":
   the mark pulses on a slow sine, air particles drift up, words rise in. */
.hero {
  text-align: center;
  padding: 3.25rem 1.5rem 2.25rem;
  position: relative;
  overflow: hidden;
}
.hero h1 {
  font-size: clamp(1.8rem, 5vw, 2.7rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0.75rem 0 0.6rem;
  position: relative;
}
.hero p { max-width: 560px; margin: 0 auto; color: var(--breaths-muted); font-weight: 500; position: relative; }
.hero .kicker { position: relative; }

.hero-mark {
  height: 74px;
  margin-bottom: 0.75rem;
  animation: breathe 6s ease-in-out infinite;
  position: relative;
}
@keyframes breathe {
  0%, 100% { transform: scale(1); }
  45% { transform: scale(1.09); }
  60% { transform: scale(1.07); }
}
.hero-word {
  display: inline-block;
  animation: rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both;
  white-space: pre;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.air-field { position: absolute; inset: 0; pointer-events: none; }
.air-particle {
  position: absolute;
  bottom: -10px;
  border-radius: 50%;
  background: var(--breaths-air);
  animation-name: float-up;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}
@keyframes float-up {
  from { transform: translateY(0) translateX(0); }
  25% { transform: translateY(-28vh) translateX(14px); }
  50% { transform: translateY(-55vh) translateX(-10px); }
  75% { transform: translateY(-80vh) translateX(10px); }
  to { transform: translateY(-108vh) translateX(-6px); }
}
/* Aurora depth: large blurred colour orbs drifting behind the hero content */
.orb-field { position: absolute; inset: 0; pointer-events: none; transition: transform 0.4s ease-out; }
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(52px);
  animation: orb-drift 16s ease-in-out infinite alternate;
}
.orb-gold { width: 320px; height: 320px; background: rgba(253, 185, 19, 0.20); top: -90px; left: 12%; }
.orb-air  { width: 380px; height: 380px; background: rgba(127, 169, 155, 0.22); bottom: -140px; right: 8%; animation-delay: -6s; }
.orb-blue { width: 260px; height: 260px; background: rgba(0, 106, 149, 0.10); top: 30%; right: 28%; animation-delay: -11s; }
@keyframes orb-drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(34px, -22px) scale(1.12); }
}

/* Flowing breath-wave ribbon */
.breath-waves { position: absolute; inset: 0; pointer-events: none; transition: transform 0.4s ease-out; }
.breath-waves svg { width: 100%; height: 100%; }
.wave { animation: wave-sway 9s ease-in-out infinite alternate; transform-origin: center; }
.wave.w2 { animation-duration: 12s; animation-delay: -4s; }
@keyframes wave-sway {
  from { transform: translateY(-7px) scaleY(1); }
  to { transform: translateY(9px) scaleY(1.06); }
}

.hero-mark { transition: transform 0.4s ease-out; will-change: transform; }
.hero [data-depth] { transition: transform 0.3s ease-out; }

@media (prefers-reduced-motion: reduce) {
  .orb, .wave { animation: none; }
}

.streak-chip {
  display: inline-block;
  margin-top: 1rem;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-gold-fill);
  color: var(--breaths-gold-soft);
  font-weight: 700;
  font-size: 0.85rem;
  position: relative;
}
@media (prefers-reduced-motion: reduce) {
  .hero-mark, .hero-word, .air-particle { animation: none; }
  .hero-word { opacity: 1; transform: none; }
  .air-field { display: none; }
}

/* Continue-learning resume card */
.continue-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-gold-fill);
  border-radius: var(--breaths-radius-md);
  box-shadow: var(--breaths-panel-shadow);
  padding: 1.1rem 1.3rem;
  margin: 1.25rem 0 0.5rem;
  text-decoration: none;
  color: var(--breaths-text);
  transition: transform 0.2s, box-shadow 0.2s;
}
.continue-card:hover { transform: translateY(-2px); }
.cc-text { display: flex; flex-direction: column; gap: 0.25rem; min-width: 220px; }
.cc-kicker { text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.7rem; font-weight: 700; color: var(--breaths-gold-soft); }
.cc-progress { display: flex; align-items: center; gap: 0.6rem; font-size: 0.8rem; color: var(--breaths-muted); }
.cc-track { flex: 0 0 120px; height: 6px; border-radius: 999px; background: var(--breaths-bg-deep); overflow: hidden; }
.cc-fill { display: block; height: 100%; border-radius: 999px; background: var(--breaths-gold-fill); }
.cc-btn { white-space: nowrap; }

/* ── Hero redesign: split layout, depth, 3D card cluster, parallax ── */
.hero-split { padding: 2.75rem 1.25rem 2.75rem; text-align: start; }
.hero-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.hero-grain {
  position: absolute; inset: 0; pointer-events: none; opacity: 0.045; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-inner {
  position: relative; z-index: 1; max-width: 1120px; margin-inline: auto;
  display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  align-items: center; gap: 2rem;
}
.hero-copy { position: relative; }
.hero-copy .hero-mark { height: 52px; margin-bottom: 0.6rem; display: block; margin-inline: 0; }
.hero-copy .kicker { margin-inline: 0; }

.hero-sub { max-width: 540px; font-size: 1.1rem; color: var(--breaths-text); font-weight: 500; margin-top: 0.5rem; }
.benefits { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: flex-start; margin: 1.2rem 0 0; position: relative; }
.benefit {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: rgba(255, 255, 255, 0.72); backdrop-filter: blur(9px); -webkit-backdrop-filter: blur(9px);
  border: 1.5px solid rgba(255, 255, 255, 0.85); border-radius: 999px;
  padding: 0.4rem 0.85rem; font-size: 0.85rem; font-weight: 600; color: var(--breaths-text);
  box-shadow: 0 6px 18px rgba(0, 70, 100, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.benefit .b-ico { font-size: 0.95rem; line-height: 1; }
.hero-cta { margin-top: 1.5rem; position: relative; }
.cta-primary {
  font-size: 1.05rem; padding: 0.85rem 1.9rem;
  box-shadow: 0 10px 28px rgba(253, 185, 19, 0.4); animation: cta-pulse 3.2s ease-in-out infinite;
}
@keyframes cta-pulse { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
.hero-trust { margin-top: 1rem !important; font-size: 0.82rem; color: var(--breaths-muted); font-weight: 500; }
.hero-copy .streak-chip { margin-top: 0.9rem; }

/* Social-proof stats (learners + rating) */
.hero-stats { display: flex; gap: 1.5rem; margin-top: 1.25rem; flex-wrap: wrap; }
.hstat { display: flex; flex-direction: column; line-height: 1.15; }
.hstat b { font-size: 1.4rem; font-weight: 800; color: var(--breaths-text); letter-spacing: -0.01em; }
.hstat span:last-child { font-size: 0.74rem; color: var(--breaths-muted); font-weight: 600; }
@media (max-width: 900px) { .hero-stats { justify-content: center; } }

/* Right column — floating 3D course-card cluster */
.hero-visual { position: relative; display: grid; grid-template-areas: "stack"; place-items: center; min-height: 400px; perspective: 1300px; cursor: pointer; max-width: 100%; }
.visual-glow {
  /* Decorative only. A fixed 360px width here set the floor for the whole hero
     grid column, pushing the copy off-screen on phones — keep it fluid so it
     can never drive layout. */
  grid-area: stack; width: min(360px, 100%); aspect-ratio: 1; border-radius: 50%; z-index: 0;
  background: radial-gradient(circle, rgba(253, 185, 19, 0.30), rgba(127, 169, 155, 0.12) 45%, transparent 70%);
  filter: blur(6px); animation: glow-pulse 7s ease-in-out infinite;
}
@keyframes glow-pulse { 0%, 100% { transform: scale(1); opacity: 0.85; } 50% { transform: scale(1.12); opacity: 1; } }
.card-cluster {
  grid-area: stack; position: relative; z-index: 2; width: 250px; transform-style: preserve-3d;
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); animation: cluster-float 8s ease-in-out infinite;
}
@keyframes cluster-float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -12px; } }
.hero-card {
  border-radius: 22px; padding: 0.95rem 1rem 1.1rem;
  background: rgba(255, 255, 255, 0.82); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 34px 66px -22px rgba(0, 70, 100, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
.card-front { position: relative; z-index: 3; }
.card-back1, .card-back2 { position: absolute; inset: 0; z-index: 1; }
.card-back1 { transform: translate3d(30px, 30px, -70px) rotate(4.5deg); opacity: 0.9; }
.card-back2 { transform: translate3d(-26px, 52px, -140px) rotate(-6deg); opacity: 0.72; }
.hc-head { display: flex; align-items: center; justify-content: space-between; }
.hc-num { font-size: 0.6rem; font-weight: 800; letter-spacing: 0.14em; color: var(--breaths-gold-soft); }
.hc-ring { width: 20px; height: 20px; border-radius: 50%; border: 3px solid var(--breaths-panel-border); border-top-color: var(--breaths-gold-fill); transform: rotate(120deg); }
.hc-video {
  position: relative; margin: 0.65rem 0 0.7rem; aspect-ratio: 5 / 4; border-radius: 14px; overflow: hidden;
  background: linear-gradient(140deg, #FFF4D2, #FCE199); display: grid; place-items: center;
}
.cc-airway { position: absolute; width: 62%; height: 62%; color: rgba(0, 80, 110, 0.22); }
.hc-play {
  position: relative; z-index: 1; width: 48px; height: 48px; border-radius: 50%; border: 0;
  background: var(--breaths-gold-fill); color: var(--breaths-on-gold); font-size: 1rem; padding-left: 3px;
  display: grid; place-items: center; box-shadow: 0 8px 22px rgba(253, 185, 19, 0.55); cursor: default;
}
.hc-time { position: absolute; right: 8px; bottom: 8px; font-size: 0.58rem; font-weight: 700; color: #fff; background: rgba(0, 60, 82, 0.72); border-radius: 999px; padding: 2px 7px; }
.hc-title { font-size: 0.98rem; font-weight: 800; color: var(--breaths-text); letter-spacing: -0.01em; }
.hc-dots { display: flex; gap: 4px; margin-top: 0.55rem; }
.hc-dots i { width: 16px; height: 5px; border-radius: 3px; background: var(--breaths-panel-border); }
.hc-dots i.on { background: var(--breaths-gold-fill); }
.hc-line { height: 8px; border-radius: 4px; background: var(--breaths-panel-border); margin-top: 0.55rem; }
.hc-line.short { width: 58%; }

.float-chip {
  position: absolute; z-index: 4; display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.78rem; font-weight: 700; color: var(--breaths-text);
  background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border: 1.5px solid rgba(255, 255, 255, 0.85); border-radius: 999px; padding: 0.4rem 0.75rem;
  box-shadow: 0 14px 32px -10px rgba(0, 70, 100, 0.34);
}
.chip-free { top: 6%; left: -4%; }
.chip-cert { bottom: 9%; right: -8%; }
.chip-min { top: 48%; right: -10%; }

@media (max-width: 900px) {
  .hero-split { text-align: center; }
  .hero-inner { grid-template-columns: 1fr; gap: 1.5rem; }
  .hero-copy { order: 1; }
  .hero-visual { order: 2; min-height: 320px; }
  .hero-copy .hero-mark, .hero-copy .kicker { margin-inline: auto; }
  .benefits { justify-content: center; }
  .hero-sub { margin-inline: auto; }
}
@media (max-width: 480px) {
  .hero-visual { min-height: 280px; transform: scale(0.88); }
  .card-back2 { display: none; }
  .chip-cert { right: 0; }
  .chip-min { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .cta-primary, .visual-glow, .card-cluster { animation: none; }
  .card-cluster { transition: none; }
}

/* How it works — three-step reassurance strip */
.how {
  display: flex; align-items: stretch; justify-content: center; flex-wrap: wrap;
  gap: 0.6rem 1rem; max-width: 900px; margin: 0.5rem auto 0; padding: 0 1.25rem;
}
.how .step { display: flex; align-items: center; gap: 0.7rem; text-align: start; max-width: 260px; }
.how .step-ico {
  flex: none; width: 40px; height: 40px; display: grid; place-items: center; font-size: 1.25rem;
  background: color-mix(in srgb, var(--breaths-gold-fill) 16%, #fff); border-radius: 12px;
}
.how .step strong { display: block; font-size: 0.92rem; color: var(--breaths-text); }
.how .step span { font-size: 0.8rem; color: var(--breaths-muted); }
.how-arrow { display: flex; align-items: center; color: var(--breaths-gold-soft); font-weight: 700; font-size: 1.1rem; }
@media (max-width: 640px) { .how-arrow { display: none; } .how .step { max-width: none; width: 100%; } }

/* Sticky category jump-nav with scroll-spy */
.cat-nav {
  position: sticky; top: 66px; z-index: 8;
  display: flex; align-items: center; gap: 0.7rem;
  max-width: 960px; margin: 1.75rem auto 0; padding: 0.55rem 1.25rem;
  background: color-mix(in srgb, var(--breaths-bg-top, #fff) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(8px);
  border-block: 1.5px solid var(--breaths-panel-border);
}
.cat-nav-label { flex: none; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--breaths-gold-soft); }
.cat-pills { display: flex; gap: 0.45rem; overflow-x: auto; scrollbar-width: thin; padding-bottom: 2px; }
.cat-pills::-webkit-scrollbar { height: 4px; }
.cat-pills::-webkit-scrollbar-thumb { background: var(--breaths-panel-border); border-radius: 4px; }
.cat-pill {
  flex: none; display: inline-flex; align-items: center; gap: 0.4rem; white-space: nowrap;
  text-decoration: none; font-size: 0.85rem; font-weight: 600; color: var(--breaths-text);
  background: var(--breaths-panel); border: 1.5px solid var(--breaths-panel-border);
  border-radius: 999px; padding: 0.35rem 0.85rem; transition: border-color 0.2s, background 0.2s, transform 0.15s;
}
.cat-pill::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: var(--dot, var(--breaths-gold-fill)); flex: none; }
.cat-pill:hover { transform: translateY(-1px); border-color: var(--dot, var(--breaths-gold-fill)); }
.cat-pill.active { background: color-mix(in srgb, var(--dot, #FDB913) 14%, #fff); border-color: var(--dot, var(--breaths-gold-fill)); }
.cat-pill[hidden] { display: none; }

/* Catalogue */
.catalogue { max-width: 960px; margin: 0 auto; padding: 1rem 1.25rem 4rem; }
.series-block { margin-top: 2.5rem; scroll-margin-top: 130px; }
.series-head { display: flex; align-items: baseline; gap: 0.75rem; margin-bottom: 0.35rem; }
.series-head h2 { font-size: 1.35rem; font-weight: 700; }
.series-head .count { color: var(--breaths-muted); font-size: 0.9rem; }
.series-desc { color: var(--breaths-muted); margin-bottom: 1.1rem; max-width: 640px; }

.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.module-tile {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: var(--breaths-radius-md);
  box-shadow: 0 6px 20px rgba(0, 70, 100, 0.06);
  padding: 1.1rem 1.2rem;
  text-decoration: none;
  color: var(--breaths-text);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  position: relative;
  overflow: hidden;
}
/* Breath-mark watermark drifts in on hover — quiet at rest, alive on touch */
.module-tile::after {
  content: '';
  position: absolute;
  inset-inline-end: -26px;
  bottom: -26px;
  width: 96px;
  height: 96px;
  background: url('../assets/breaths-mark.svg') no-repeat center / contain;
  opacity: 0.05;
  transition: opacity 0.25s, transform 0.35s ease;
  transform: rotate(-6deg);
  pointer-events: none;
}
.module-tile:hover::after { opacity: 0.14; transform: rotate(0deg) translate(-4px, -4px) scale(1.05); }
.module-tile:hover {
  border-color: var(--breaths-gold-fill);
  box-shadow: 0 16px 44px rgba(0, 70, 100, 0.12), 0 0 0 4px rgba(253, 185, 19, 0.16);
  transform: translateY(-3px);
}
.module-tile:hover .num { animation: kicker-shimmer 0.9s ease; }
@keyframes kicker-shimmer {
  0%, 100% { color: var(--breaths-gold-soft); }
  50% { color: var(--breaths-gold-fill); letter-spacing: 0.18em; }
}
.module-tile .ring { transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1); }
.module-tile:hover .ring { transform: scale(1.14); }
.module-tile:hover .time-chip { background: var(--breaths-gold-fill); color: var(--breaths-on-gold); }
.time-chip { transition: background 0.2s, color 0.2s; }
@media (prefers-reduced-motion: reduce) { .module-tile:hover .num { animation: none; } }
/* Specular sheen that follows the cursor while a tile is tilted (3D effect) */
.module-tile::before, .continue-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(220px circle at var(--sheen-x, 50%) var(--sheen-y, 50%), rgba(253, 185, 19, 0.10), transparent 60%);
  opacity: 0;
  transition: opacity 0.25s;
  pointer-events: none;
}
.module-tile:hover::before, .continue-card:hover::before { opacity: 1; }
.module-tile, .continue-card { will-change: transform; transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s ease-out; }
.continue-card { position: relative; overflow: hidden; }

/* Scroll reveal */
.series-block.reveal-pending { opacity: 0; transform: translateY(22px); }
.series-block.revealed { opacity: 1; transform: none; transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1); }
.module-tile.is-done { border-color: #CBE7D8; }
.tile-top { display: flex; align-items: center; justify-content: space-between; }
.module-tile .num {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--breaths-gold-soft);
  letter-spacing: 0.14em;
}
.ring-wrap { display: inline-flex; }
.module-tile h3 { font-size: 1rem; line-height: 1.35; font-weight: 600; position: relative; }
.module-tile .meta { margin-top: auto; display: flex; gap: 0.6rem; align-items: center; font-size: 0.82rem; color: var(--breaths-muted); position: relative; }
.time-chip {
  padding: 0.05rem 0.5rem;
  border-radius: 999px;
  background: var(--breaths-bg-deep);
  font-weight: 600;
  font-size: 0.76rem;
}
.series-progress { display: inline-flex; align-items: center; gap: 0.5rem; font-size: 0.8rem; color: var(--breaths-muted); margin-inline-start: 0.5rem; }
.sp-track { width: 90px; height: 5px; border-radius: 999px; background: var(--breaths-bg-deep); overflow: hidden; display: inline-block; }
.sp-fill { display: block; height: 100%; border-radius: 999px; background: var(--breaths-good); }
.badge {
  display: inline-block;
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 600;
}
.badge.done { background: #E7F5EE; color: var(--breaths-good); }
.badge.external { background: var(--breaths-bg-deep); color: var(--breaths-muted); }
.badge.preview { background: #ECE7F3; color: #5b4a86; }

/* Team preview (#/preview/<token>) — unlisted content surfaced for the team only. */
.preview-banner { background: #5b4a86; color: #fff; text-align: center; padding: 0.6rem 1rem; font-size: 0.86rem; font-weight: 500; line-height: 1.4; }
.module-tile.is-preview { border-color: #C9BEE0; border-style: dashed; }

/* Player */
.player { max-width: 720px; margin: 0 auto; padding: 1.5rem 1.25rem 4rem; }
.draft-banner {
  background: var(--breaths-gold-fill);
  color: var(--breaths-on-gold);
  font-weight: 700;
  font-size: 0.85rem;
  text-align: center;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}
.player-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 0.75rem; }
.player-top .back { text-decoration: none; font-weight: 600; font-size: 0.9rem; }
.player-top .series-tag {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--breaths-gold-soft);
  letter-spacing: 0.14em;
}
.player h1 { font-size: 1.45rem; font-weight: 800; line-height: 1.25; margin-bottom: 1rem; }

.progress-track {
  height: 6px;
  background: var(--breaths-bg-deep);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.progress-fill {
  height: 100%;
  width: 0;
  background: var(--breaths-gold-fill); /* the hero gold moment of the player */
  border-radius: 999px;
  transition: width 0.3s ease;
}

.card-stage {
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: var(--breaths-radius);
  box-shadow: var(--breaths-panel-shadow);
  padding: 1.9rem 1.6rem;
  min-height: 300px;
}
/* Each card rises in as it appears */
.card-stage > * { animation: card-in 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes card-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) { .card-stage > * { animation: none; } }

.card-stage h2 { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.75rem; }
.card-stage p { margin-bottom: 0.9rem; }
.card-stage ul { padding-inline-start: 1.25rem; margin-bottom: 0.9rem; }
.card-stage li { margin-bottom: 0.5rem; }
.card-stage img { max-width: 100%; border-radius: var(--breaths-radius-sm); }
.card-stage strong { color: var(--breaths-text); }

/* Video facade — no third-party requests until the learner presses play */
.video-facade {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--breaths-radius-sm);
  overflow: hidden;
  background: var(--breaths-text) center / cover no-repeat;
  border: 0;
  width: 100%;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.video-facade .play {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: var(--breaths-gold-fill);
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  color: var(--breaths-on-gold);
  box-shadow: 0 4px 16px rgba(0, 40, 60, 0.35);
}
.video-facade .consent-note {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: rgba(0, 59, 82, 0.85);
  color: #fff;
  font-size: 0.75rem;
  padding: 0.35rem 0.75rem;
  text-align: center;
}
.video-embed { aspect-ratio: 16 / 9; width: 100%; border: 0; border-radius: var(--breaths-radius-sm); overflow: hidden; }
/* When the IFrame API drives playback, .video-embed is a container and the player
   iframe is its child — make it fill the framed box. */
.video-embed iframe { width: 100%; height: 100%; border: 0; display: block; }
.video-facade.vertical, .video-embed.vertical { aspect-ratio: 9 / 16; max-width: 320px; margin-inline: auto; display: block; }
.video-facade.vertical { display: grid; }

/* Resources */
.resource-links { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 1rem; }
.resource-link { text-align: center; }

/* Star rating — gold fills (large graphics: on-brand use of bright gold) */
.stars { display: flex; gap: 0.4rem; margin: 1rem 0 0.5rem; }
.star { font-size: 2.1rem; line-height: 1; background: none; border: none; cursor: pointer; color: var(--breaths-grey); padding: 0.1rem; }
.star.filled { color: var(--breaths-gold-fill); }
.star:disabled { cursor: default; }
.rating-thanks { color: var(--breaths-good); font-weight: 600; }

/* MCQ */
.mcq-options { display: flex; flex-direction: column; gap: 0.6rem; margin: 1rem 0; }
.mcq-option {
  text-align: start;
  font: inherit;
  color: var(--breaths-text);
  padding: 0.8rem 1rem;
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: var(--breaths-radius-sm);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.mcq-option:hover:not(:disabled) { border-color: var(--breaths-gold-fill); }
.mcq-option:disabled { cursor: default; }
.mcq-option.correct { border-color: var(--breaths-good); background: #E7F5EE; }
.mcq-option.incorrect { border-color: var(--breaths-error); background: var(--breaths-error-bg); }
.mcq-feedback {
  border-inline-start: 4px solid var(--breaths-gold-fill);
  background: var(--breaths-bg-mid);
  border-radius: 0 var(--breaths-radius-sm) var(--breaths-radius-sm) 0;
  padding: 0.85rem 1rem;
  margin-top: 0.75rem;
}
/* Nudge toward the explanation card when a wrong answer has no inline feedback. */
.fb-next-hint { display: block; margin-top: 0.35rem; font-size: 0.88rem; font-weight: 600; color: var(--breaths-muted); }

/* Order (sequence builder) */
.order-seq { list-style: none; min-height: 2.4rem; margin-bottom: 0.9rem; padding: 0.5rem; border: 1.5px dashed var(--breaths-air); border-radius: var(--breaths-radius-sm); display: flex; flex-direction: column; gap: 0.4rem; counter-reset: step; }
.order-seq:empty::before { content: 'Tap the steps below in order…'; color: var(--breaths-muted); font-size: 0.85rem; }
.order-pool { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.order-item {
  font: inherit; font-size: 0.9rem; text-align: start; cursor: pointer;
  padding: 0.55rem 0.9rem; border-radius: 10px;
  background: var(--breaths-panel); border: 1.5px solid var(--breaths-panel-border); color: var(--breaths-text);
  transition: border-color 0.15s, transform 0.15s, background 0.2s;
}
.order-item:hover { border-color: var(--breaths-gold-fill); }
li.order-item.placed { counter-increment: step; display: flex; gap: 0.6rem; }
li.order-item.placed::before { content: counter(step); font-weight: 700; color: var(--breaths-gold-soft); }
.order-item.right { border-color: var(--breaths-good); background: #E7F5EE; cursor: default; }
.order-item.wrong { border-color: var(--breaths-error); background: var(--breaths-error-bg); animation: shake 0.3s; }
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* VAS slider */
.vas-wrap { position: relative; padding: 2.1rem 0 0.4rem; }
.vas { width: 100%; appearance: none; height: 8px; border-radius: 999px; outline-offset: 4px;
  background: linear-gradient(to right, var(--breaths-gold-fill) var(--fill, 50%), var(--breaths-bg-deep) var(--fill, 50%)); }
.vas::-webkit-slider-thumb { appearance: none; width: 26px; height: 26px; border-radius: 50%; background: var(--breaths-gold-fill); border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0, 60, 90, 0.3); cursor: grab; }
.vas::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--breaths-gold-fill); border: 3px solid #fff; cursor: grab; }
.vas-bubble { position: absolute; top: 0; inset-inline-start: calc(50% - 14px); min-width: 28px; text-align: center; font-weight: 800; color: var(--breaths-text); background: var(--breaths-bg-deep); border-radius: 8px; padding: 0.1rem 0.3rem; transition: inset-inline-start 0.05s; }
.vas-labels { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--breaths-muted); margin-top: 0.4rem; }

/* Flip cards */
.flip-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 0.8rem; margin-top: 0.8rem; }
.flip-card { background: none; border: 0; padding: 0; cursor: pointer; perspective: 700px; min-height: 130px; font: inherit; }
.flip-inner { position: relative; display: block; width: 100%; height: 100%; min-height: 130px; transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); transform-style: preserve-3d; }
.flip-card.flipped .flip-inner { transform: rotateY(180deg); }
.flip-face {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; text-align: center;
  padding: 0.9rem; border-radius: 14px; backface-visibility: hidden; font-size: 0.88rem; line-height: 1.4;
}
.flip-front { background: var(--breaths-text); color: #fff; font-weight: 600; }
.flip-back { background: var(--breaths-panel); color: var(--breaths-text); border: 1.5px solid var(--breaths-gold-fill); transform: rotateY(180deg); }
@media (prefers-reduced-motion: reduce) { .flip-inner { transition: none; } }

/* Branching case */
.case-trail .case-node.dim { opacity: 0.55; }
.case-node { background: var(--breaths-panel); border: 1.5px solid var(--breaths-panel-border); border-radius: 14px; padding: 0.9rem 1rem; margin-bottom: 0.6rem; animation: rise 0.4s cubic-bezier(0.2,0.8,0.2,1); }
.case-text { margin: 0 0 0.6rem !important; }
.case-said { text-align: end; font-weight: 600; color: var(--breaths-gold-soft); margin: 0.2rem 0 0.5rem; }
.case-note { font-size: 0.82rem; color: var(--breaths-muted); border-inline-start: 3px solid var(--breaths-air); padding-inline-start: 0.6rem; margin-bottom: 0.7rem; }
.case-choices { display: flex; flex-direction: column; gap: 0.5rem; }
.case-choice { font: inherit; text-align: start; cursor: pointer; padding: 0.6rem 0.9rem; border-radius: 10px; background: #fff; border: 1.5px solid var(--breaths-panel-border); color: var(--breaths-text); transition: border-color 0.15s, transform 0.1s; }
.case-choice:hover { border-color: var(--breaths-gold-fill); transform: translateX(3px); }
.case-good { border-color: var(--breaths-good); background: #F2FAF5; }
.case-caution { border-color: var(--breaths-gold-fill); background: #FFFAEB; }
.case-outcome { display: block; font-weight: 800; margin-bottom: 0.6rem; }
.case-good .case-outcome { color: var(--breaths-good); }
.case-caution .case-outcome { color: var(--breaths-gold-soft); }
.case-restart { font-size: 0.85rem; padding: 0.45rem 1rem; }

/* Evidence jigsaw */
.jig-meter { position: relative; height: 22px; border-radius: 999px; background: var(--breaths-bg-deep); overflow: hidden; margin: 0.8rem 0; }
.jig-meter-fill { position: absolute; inset: 0 auto 0 0; width: 0; background: linear-gradient(90deg, var(--breaths-gold-fill), #ffd45e); transition: width 0.5s cubic-bezier(0.2,0.8,0.2,1); }
.jig-meter-text { position: relative; display: block; text-align: center; font-size: 0.75rem; font-weight: 700; line-height: 22px; color: var(--breaths-text); }
.jig-zones { display: grid; grid-template-columns: 1fr 1fr; gap: 0.7rem; margin-bottom: 0.8rem; }
.jig-zone { min-height: 96px; border: 1.5px dashed var(--breaths-air); border-radius: 12px; padding: 0.5rem; cursor: pointer; display: flex; flex-direction: column; gap: 0.35rem; transition: border-color 0.15s, background 0.15s; }
.jig-zone:hover { border-color: var(--breaths-gold-fill); background: #FFFDF4; }
.jig-zone-label { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--breaths-muted); }
.jig-pool { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.jig-piece { font: inherit; font-size: 0.85rem; text-align: start; cursor: pointer; padding: 0.5rem 0.8rem; border-radius: 10px; background: var(--breaths-panel); border: 1.5px solid var(--breaths-panel-border); color: var(--breaths-text); transition: border-color 0.15s, box-shadow 0.15s; }
.jig-piece.sel { border-color: var(--breaths-gold-fill); box-shadow: 0 0 0 3px rgba(253, 185, 19, 0.25); }
.jig-piece.right { border-color: var(--breaths-good); background: #E7F5EE; font-size: 0.78rem; cursor: default; }
.jig-piece.wrong { border-color: var(--breaths-error); background: var(--breaths-error-bg); animation: shake 0.3s; }

/* Guided breathing */
.breathe-box { position: relative; width: min(280px, 80%); aspect-ratio: 1; margin: 1rem auto; border: 2.5px solid var(--breaths-air); border-radius: 22px; display: grid; place-items: center; }
.breathe-circle { position: absolute; width: 34%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffe9ad, var(--breaths-gold-fill)); opacity: 0.85; transition: transform linear; transform: scale(1); }
.breathe-box.inhale .breathe-circle { transform: scale(1.9); }
.breathe-box.exhale .breathe-circle { transform: scale(1); }
.breathe-label { position: relative; font-weight: 800; font-size: 1.15rem; color: var(--breaths-text); text-shadow: 0 1px 6px rgba(255,255,255,0.8); }
.breathe-count { position: absolute; bottom: 0.7rem; font-weight: 700; color: var(--breaths-muted); font-variant-numeric: tabular-nums; }
.breathe-actions { text-align: center; }
@media (prefers-reduced-motion: reduce) { .breathe-circle { transition: none !important; } }

/* Player nav */
.player-nav { display: flex; justify-content: space-between; gap: 1rem; margin-top: 1.25rem; }
.btn {
  font: inherit;
  font-weight: 700;
  padding: 0.75rem 1.6rem;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  background: var(--breaths-gold-fill);
  color: var(--breaths-on-gold);
  text-decoration: none;
  display: inline-block;
  transition: background 0.15s, transform 0.15s;
}
.btn:hover { background: #E8A900; transform: translateY(-1px); }
.btn.ghost { background: var(--breaths-panel); color: var(--breaths-text); border: 1.5px solid var(--breaths-panel-border); }
.btn.ghost:hover { background: var(--breaths-bg-deep); }
.btn:disabled { opacity: 0.4; cursor: default; transform: none; }

/* Completion */
.completion { text-align: center; padding: 2rem 0; position: relative; }
.burst { position: absolute; top: 2.6rem; left: 50%; width: 0; height: 0; pointer-events: none; }
.burst span {
  position: absolute;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--breaths-gold-fill);
  animation: burst-out 0.9s cubic-bezier(0.1, 0.7, 0.3, 1) forwards;
}
.burst span:nth-child(3n) { background: var(--breaths-air); }
.burst span:nth-child(4n) { width: 5px; height: 5px; }
@keyframes burst-out {
  from { transform: rotate(var(--angle)) translateX(0) scale(1); opacity: 1; }
  to { transform: rotate(var(--angle)) translateX(var(--dist)) scale(0.4); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .burst { display: none; } }
.completion .big { font-size: 2.5rem; }
.completion h2 { font-weight: 800; margin: 0.5rem 0 0.75rem; }
.completion p { color: var(--breaths-muted); max-width: 460px; margin: 0 auto 1rem; }
.completion .actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; margin-top: 1rem; }
.completion .disclaimer { font-size: 0.8rem; color: var(--breaths-muted); max-width: 540px; margin: 1.75rem auto 0; text-align: start; }

/* Certificate */
.certificate-view { max-width: 720px; margin: 0 auto; padding: 1.5rem 1.25rem 4rem; }
.certificate-view h1 { font-weight: 800; }
.name-form { display: flex; gap: 0.75rem; flex-wrap: wrap; margin: 1rem 0 1.5rem; }
.name-form input {
  font: inherit;
  color: var(--breaths-text);
  padding: 0.7rem 1rem;
  border: 1.5px solid var(--breaths-panel-border);
  border-radius: var(--breaths-radius-sm);
  background: var(--breaths-panel);
  flex: 1;
  min-width: 220px;
}
.name-form input:focus { outline: 2px solid var(--breaths-gold-fill); outline-offset: 1px; }
.cert-privacy { font-size: 0.85rem; color: var(--breaths-muted); margin-bottom: 1.5rem; }

.certificate {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 50% 0%, #FFFDF4 0%, var(--breaths-panel) 55%),
    var(--breaths-panel);
  border: 2.5px solid var(--breaths-gold-fill);
  outline: 1.5px solid var(--breaths-air);
  outline-offset: -12px;
  border-radius: var(--breaths-radius);
  box-shadow: var(--breaths-panel-shadow);
  padding: 3rem 2.25rem 2.5rem;
  text-align: center;
}
/* watermark breath-mark behind the content */
.certificate::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('../assets/breaths-mark.svg') no-repeat center 58% / 260px;
  opacity: 0.05;
  pointer-events: none;
}
.certificate > * { position: relative; }
.certificate .cert-lockup { height: 52px; width: auto; }
.certificate .cert-title {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.32em;
  color: var(--breaths-gold-soft);
  font-weight: 700;
  margin: 1.5rem 0 0.75rem;
}
.certificate .cert-title::before, .certificate .cert-title::after {
  content: '—'; color: var(--breaths-gold-fill); margin: 0 0.6rem; letter-spacing: 0;
}
.certificate .cert-name {
  font-size: 2.2rem; font-weight: 800; letter-spacing: -0.01em;
  margin: 0.25rem auto 0.35rem; min-height: 3rem; max-width: 90%;
}
.certificate .cert-name:not(:empty)::after {
  content: ''; display: block; width: 110px; height: 3px; margin: 0.55rem auto 0;
  background: linear-gradient(90deg, transparent, var(--breaths-gold-fill), transparent);
  border-radius: 2px;
}
.certificate .cert-module { font-size: 1.02rem; max-width: 500px; margin: 0.75rem auto 1rem; }
.certificate .cert-date { color: var(--breaths-muted); font-size: 0.9rem; font-weight: 600; }
.certificate .cert-footer {
  margin-top: 1.9rem; padding-top: 1rem; font-size: 0.75rem; color: var(--breaths-muted);
  border-top: 1px solid var(--breaths-panel-border); max-width: 540px; margin-inline: auto;
}

/* About */
.about { max-width: 720px; margin: 0 auto; padding: 2rem 1.25rem 4rem; }
.about h1 { font-weight: 800; margin: 0.5rem 0 1rem; }
.about p { color: var(--breaths-muted); margin-bottom: 1rem; }
.objectives {
  background: var(--breaths-panel);
  border: 1.5px solid var(--breaths-panel-border);
  border-inline-start: 4px solid var(--breaths-gold-fill);
  box-shadow: 0 6px 20px rgba(0, 70, 100, 0.06);
  padding: 1.5rem 1.75rem;
  margin: 1.5rem 0;
  border-radius: var(--breaths-radius-md);
}
.objectives ul { list-style: none; }
.objectives li { position: relative; padding-inline-start: 1.5rem; margin-bottom: 0.6rem; color: var(--breaths-text); }
.objectives li::before { content: '✓'; position: absolute; inset-inline-start: 0; color: var(--breaths-good); font-weight: 700; }

/* Footer — blue as the workhorse ink block */
.site-footer {
  background: var(--breaths-text);
  color: #fff;
  padding: 1.75rem 1.5rem;
  text-align: center;
  font-size: 0.9rem;
}
.site-footer a { color: rgba(255, 255, 255, 0.92); }
.site-footer .privacy-note { opacity: 0.75; font-size: 0.8rem; margin-top: 0.5rem; }

.loading, .error-view { text-align: center; padding: 4rem 1.5rem; color: var(--breaths-muted); }

/* Consent banner (only ever shown when Meta measurement is configured) */
.consent-banner {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 60;
  background: var(--breaths-panel);
  border-top: 3px solid var(--breaths-gold-fill);
  box-shadow: 0 -10px 40px rgba(0, 70, 100, 0.15);
  padding: 1rem 1.25rem;
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  animation: rise 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.consent-text { max-width: 560px; font-size: 0.85rem; color: var(--breaths-muted); }
.consent-text strong { display: block; color: var(--breaths-text); font-size: 0.95rem; margin-bottom: 0.2rem; }
.consent-text p { margin: 0; }
.consent-actions { display: flex; gap: 0.6rem; }
.consent-actions .btn { padding: 0.6rem 1.3rem; font-size: 0.9rem; }

/* Optional anonymous demographics snapshot (not ads consent — voluntary survey). */
.demo-panel {
  position: fixed; z-index: 55;
  inset-inline-end: 1rem; bottom: 1rem; width: min(360px, calc(100vw - 2rem));
  background: var(--breaths-panel); border: 1.5px solid var(--breaths-panel-border);
  border-top: 3px solid var(--breaths-gold-fill); border-radius: 16px;
  box-shadow: 0 16px 44px rgba(0, 70, 100, 0.18);
  padding: 1.1rem 1.2rem 1.15rem; animation: rise 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.demo-panel > strong { display: block; font-size: 0.98rem; color: var(--breaths-text); }
.demo-x { position: absolute; top: 0.55rem; inset-inline-end: 0.65rem; border: 0; background: none; cursor: pointer; font-size: 0.95rem; color: var(--breaths-muted); line-height: 1; }
.demo-intro { font-size: 0.76rem; color: var(--breaths-muted); margin: 0.25rem 0 0.7rem; }
.demo-field { margin-bottom: 0.65rem; }
.demo-q { display: block; font-size: 0.72rem; font-weight: 700; color: var(--breaths-gold-soft); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.3rem; }
.demo-opts { display: flex; flex-wrap: wrap; gap: 0.3rem; }
.demo-opt {
  font: inherit; font-size: 0.76rem; cursor: pointer; color: var(--breaths-text);
  background: var(--breaths-bg-mid, #F6FBFC); border: 1.5px solid var(--breaths-panel-border);
  border-radius: 999px; padding: 0.3rem 0.7rem; min-height: 34px;
}
.demo-opt:hover { border-color: var(--breaths-gold-fill); }
.demo-opt.on { background: var(--breaths-gold-fill); border-color: var(--breaths-gold-fill); color: var(--breaths-on-gold, #003B52); font-weight: 700; }
.demo-actions { display: flex; justify-content: flex-end; gap: 0.5rem; margin-top: 0.5rem; }
.demo-actions .btn { padding: 0.5rem 1rem; font-size: 0.82rem; min-height: 40px; }
.demo-thanks { font-size: 0.9rem; color: var(--breaths-text); margin: 0; }
@media (prefers-reduced-motion: reduce) { .demo-panel { animation: none; } }

/* Print: certificate only, correctly sized on one landscape A4 page */
@media print {
  @page { size: A4 landscape; margin: 0; }
  body { background: #fff; display: block; }
  body * { visibility: hidden; }
  .certificate, .certificate * { visibility: visible; }
  .certificate {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 250mm;
    height: 175mm;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-width: 1.2mm;
    border-radius: 8mm;
    outline-offset: -5mm;
    box-shadow: none;
    padding: 12mm 18mm;
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }
  .certificate::before { background-size: 70mm; }
  .certificate .cert-name { font-size: 13mm; }
  .certificate .cert-module { font-size: 5mm; max-width: 170mm; }
  .certificate .cert-footer { font-size: 3.2mm; max-width: 190mm; }
}

/* ---- Sprint 1/2 additions ---- */
.sr-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.transcript { margin-top: 0.8rem; border: 1.5px solid var(--breaths-panel-border); border-radius: var(--breaths-radius-sm); padding: 0.6rem 0.9rem; background: #fff; }
.transcript summary { cursor: pointer; font-weight: 600; color: var(--breaths-blue); }
.transcript-body { margin-top: 0.6rem; white-space: pre-wrap; font-size: 0.92rem; }
.nav-mid { flex: 1; text-align: center; align-self: center; }
.gate-hint { font-size: 0.8rem; font-weight: 600; color: var(--breaths-gold-soft); }
.card-counter { font-size: 0.8rem; font-weight: 600; color: var(--breaths-muted); font-variant-numeric: tabular-nums; }
.order-hint { color: var(--breaths-muted); font-size: 0.85rem; list-style: none; }
.progress-fill { box-shadow: inset 0 0 0 1px var(--breaths-gold-soft); }
.sp-fill, .cc-fill, .jig-meter-fill { box-shadow: inset 0 0 0 1px rgba(0, 70, 100, 0.18); }
.jig-zone { font: inherit; text-align: start; }
.search-box {
  width: 100%; font: inherit; font-size: 0.95rem;
  padding: 0.7rem 1rem; margin: 1rem 0 0.25rem;
  border: 1.5px solid var(--breaths-panel-border); border-radius: 999px;
  background: var(--breaths-panel) url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="%235F727B" stroke-width="2.4"><circle cx="11" cy="11" r="7"/><path d="m20 20-3.5-3.5"/></svg>') no-repeat right 1rem center;
}
.search-box:focus { outline: 2px solid var(--breaths-gold-fill); outline-offset: 1px; }
.review-card { border-color: var(--breaths-blue); }
.review-card .cc-kicker { color: var(--breaths-blue); }
.spinner {
  display: inline-block; width: 22px; height: 22px; vertical-align: -5px;
  border: 3px solid var(--breaths-bg-deep); border-top-color: var(--breaths-gold-fill);
  border-radius: 50%; animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 2s; } }
.install-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.35rem;
  font: inherit; font-size: 0.85rem; font-weight: 700; cursor: pointer;
  background: var(--breaths-gold-fill); color: var(--breaths-on-gold);
  border: 0; border-radius: 999px; padding: 0.45rem 1rem; margin-inline-start: 0.4rem;
  white-space: nowrap;
}
.install-btn[hidden] { display: none; } /* [hidden] must beat the flex display */
/* Touch targets ≥44px (audit UX#11) */
.sound-toggle, .lang-switch { min-height: 44px; min-width: 44px; }
.star { min-width: 44px; min-height: 44px; }

/* Learning objective — the pre-video filter page */
.objective-card h2 { display: flex; align-items: center; gap: .45rem; font-size: 1.3rem; }
.objective-card hr { border: 0; height: 3px; width: 46px; background: var(--breaths-gold-fill); border-radius: 2px; margin: .55rem 0 1.1rem; }
.objective-card p { font-size: 1.06rem; }
.objective-card p + p { color: var(--breaths-muted); font-size: .96rem; }

/* Intro / welcome page — a front pre-start filter (see PRESTART in player.js).
   Reaching it is not a course start, so low-intent visitors can bounce here
   without denting the completion rate. */
.intro-card .intro-kicker { display: inline-block; text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.72rem; font-weight: 700; color: var(--breaths-gold-soft); }
.intro-card h2 { font-size: 1.3rem; margin: 0.3rem 0 0.2rem; }
.intro-card .intro-body { position: relative; padding-top: 0.9rem; }
.intro-card .intro-body::before { content: ""; display: block; position: absolute; top: 0; left: 0; height: 3px; width: 46px; background: var(--breaths-gold-fill); border-radius: 2px; }
.intro-card .intro-body p { font-size: 1.04rem; }
.intro-card .intro-body p + p { color: var(--breaths-muted); font-size: .96rem; }

/* ============ Case study card — one continuous clinical story ============ */
.cs-rail { display: flex; align-items: center; gap: 5px; margin: 0 0 1.1rem; }
.cs-pip { flex: 1; height: 5px; border-radius: 3px; background: var(--breaths-panel-border); transition: background .3s; }
.cs-pip--q { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; }
.cs-pip.done { background: var(--breaths-gold-fill); }
.cs-pip.current { background: var(--breaths-gold-soft); }
.cs-head { margin-bottom: 1rem; }
.cs-kicker { display: inline-block; text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.72rem; font-weight: 700; color: var(--breaths-gold-soft); }
.cs-head h2 { font-size: 1.25rem; margin-top: 0.3rem; }

/* Single-cell grid: the media and the checkpoint overlay share one cell, so the
   cell grows to whichever is taller. That lets a long feedback panel flow at full
   width and scroll with the page, instead of being trapped inside the 9:16 video
   box with its own scrollbar. */
/* minmax(0, 1fr): an implicit `auto` column sizes to max-content and would push
   the card wider than a phone viewport. This caps it to the available width. */
.cs-stage { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); }
.cs-media { grid-area: 1 / 1; align-self: start; position: relative; border-radius: var(--breaths-radius-sm); overflow: hidden; background: var(--breaths-bg-mid); transition: filter 0.3s ease, opacity 0.3s ease; }
.cs-media.vertical { aspect-ratio: 9 / 16; width: 100%; max-width: 320px; margin-inline: auto; }
.cs-media.dim { filter: blur(3px) brightness(0.72); }
.cs-media .video-embed, .cs-media iframe { width: 100%; height: 100%; border: 0; display: block; }
.cs-media .video-facade.vertical { aspect-ratio: auto; height: 100%; max-width: none; margin: 0; }

/* placeholder segment (real vertical render pending) */
.cs-placeholder { width: 100%; height: 100%; background-size: cover; background-position: center; position: relative; display: grid; place-content: center; justify-items: center; gap: 0.85rem; }
.cs-placeholder::before { content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(255,255,255,0.15), rgba(0,60,90,0.4)); }
.cs-ph-tag { position: relative; font-family: 'Poppins', sans-serif; font-weight: 700; font-size: 0.78rem; color: #fff; background: rgba(0,59,82,0.78); padding: 0.35rem 0.75rem; border-radius: 999px; }
.cs-skip { position: relative; z-index: 1; }
.cs-ph-bar { position: absolute; left: 0; bottom: 0; height: 4px; width: 0; background: var(--breaths-gold-fill); }
.cs-ph-bar.run { width: 100%; transition: width 6s linear; }

/* checkpoint question — overlays the paused media (aula feel) */
.cs-overlay { grid-area: 1 / 1; min-width: 0; position: relative; display: flex; align-items: center; justify-content: center; padding: 0.6rem; background: rgba(0,40,60,0.30); border-radius: var(--breaths-radius-sm); }
/* `display: flex` above defeats the hidden attribute, so the empty overlay stayed
   on top of the video and ate mouse clicks (keyboard still reached the facade
   underneath). Restore hidden = gone. */
.cs-overlay[hidden] { display: none; }
/* Full card width (not the 320px video column) and no inner scrollbar — long
   per-option feedback reads as normal page content. */
.cs-question { background: #fff; border: 1.5px solid var(--breaths-panel-border); border-radius: var(--breaths-radius-sm); box-shadow: var(--breaths-panel-shadow); padding: 1.1rem 1.15rem 1.2rem; width: 100%; max-width: 100%; }
.cs-q-kicker { display: inline-block; text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.66rem; font-weight: 700; color: var(--breaths-gold-soft); }
.cs-q-title { font-size: 1.02rem; line-height: 1.3; margin: 0.3rem 0 0.2rem; }
/* Heading receives programmatic focus (tabindex=-1) only for screen-reader
   announcement when a checkpoint appears — never via keyboard — so suppress the
   UA focus ring that would otherwise box the question text. */
.cs-q-title:focus { outline: none; }
.cs-question .mcq-options { margin: 0.7rem 0 0; }
.cs-continue { margin-top: 0.85rem; }
.cs-manual { text-align: center; margin-top: 0.6rem; }

/* case complete */
.cs-end { width: 100%; height: 100%; display: grid; place-content: center; justify-items: center; text-align: center; gap: 0.3rem; padding: 1rem; background: var(--breaths-bg-mid); }
.cs-end-tick { font-size: 2.4rem; line-height: 1; color: var(--breaths-good); }
.cs-end h3 { font-size: 1.2rem; }
.cs-end p { color: var(--breaths-muted); font-size: 0.92rem; }

@media (prefers-reduced-motion: reduce) {
  .cs-media, .cs-pip, .cs-ph-bar.run { transition: none; }
}
