:root {
  --shell-header: 64px;
  --shell-dock: 76px;
  --shell-rail: 232px;
  --shell-context: 320px;
  --shell-gutter: clamp(16px, 2.2vw, 32px);
  --focus: #ffdb86;
  --paper-cool: #f3f0e8;
  --paper-warm: #fffaf0;
  --academy: #081522;
  --academy-raised: #102536;
  --route-motion: 320ms;
}

html {
  background: var(--academy);
}

body {
  min-height: 100svh;
  overflow-x: hidden;
  background: var(--academy);
}

body[data-layout="compact"] {
  --shell-gutter: 16px;
}

body[data-layout="medium"] {
  --shell-gutter: 24px;
}

button,
input,
textarea {
  font: inherit;
}

textarea:focus-visible,
[data-route]:focus-visible,
.context-prompt:focus-visible,
.context-link:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

[data-route-view] h1[tabindex="-1"]:focus-visible,
.lesson-screen h3[tabindex="-1"]:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 6px;
  border-radius: 8px;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.product-shell {
  position: relative;
  min-height: 100svh;
  padding-bottom: calc(var(--shell-dock) + env(safe-area-inset-bottom));
  container-name: elunavi-shell;
  container-type: inline-size;
}

.site-header.app-header {
  position: fixed;
  z-index: 50;
  inset: 0 0 auto;
  width: 100%;
  min-height: calc(var(--shell-header) + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) max(14px, env(safe-area-inset-right)) 0
    max(14px, env(safe-area-inset-left));
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  transform: none;
  background: linear-gradient(180deg, rgba(5, 15, 25, 0.96), rgba(5, 15, 25, 0.76));
  border-bottom: 1px solid rgba(255, 250, 240, 0.12);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.brand {
  min-width: 0;
  gap: 10px;
  text-shadow: none;
}

.brand::before {
  display: none;
}

.brand-compass {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  fill: none;
  stroke: var(--gold-bright);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
}

.brand strong {
  font-family: ui-serif, Georgia, "Times New Roman", serif;
  font-size: 15px;
  letter-spacing: 0.2em;
}

.brand small {
  max-width: 170px;
  overflow: hidden;
  color: rgba(255, 250, 240, 0.7);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.header-status {
  display: flex;
  align-items: center;
  gap: 8px;
}

.connection-status {
  color: rgba(255, 250, 240, 0.82);
  font-size: 12px;
  font-weight: 750;
}

.icon-button {
  width: 44px;
  min-width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 250, 240, 0.18);
  border-radius: 50%;
  cursor: pointer;
}

.icon-button svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.family-access {
  display: none;
}

.mode-switch {
  margin: 0;
}

.mode-button {
  min-height: 44px;
}

.primary-rail,
.context-rail,
.atlas-shelf {
  display: none;
}

.app-main {
  width: 100%;
  min-width: 0;
  min-height: 100svh;
  padding-top: calc(var(--shell-header) + env(safe-area-inset-top));
  background: var(--paper-cool);
}

.route-surface:not([hidden]) {
  animation: route-enter var(--route-motion) ease both;
}

@keyframes route-enter {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

body[data-route="today"] .app-main {
  position: relative;
  display: grid;
  min-height: calc(100svh - var(--shell-dock) - env(safe-area-inset-bottom));
  overflow: hidden;
  background: var(--academy);
}

body[data-route="today"] .app-main > [data-route-view="today"] {
  grid-area: 1 / 1;
}

/* Private nonrelease CWP visual lab. Enabled only with ?visual=world-first. */
body[data-visual-preview="world-first"][data-route="today"] .hero-media {
  position: fixed;
  inset: 0;
}

body[data-visual-preview="world-first"][data-route="today"] .landing {
  color: #0a1d2e;
  background: transparent;
}

body[data-visual-preview="world-first"][data-route="today"] .landing::before {
  background: linear-gradient(90deg, rgba(242, 229, 203, 0.12), transparent 46%);
}

body[data-visual-preview="world-first"][data-route="today"] .landing::after {
  display: none;
}

body[data-visual-preview="world-first"][data-route="today"] .landing .eyebrow {
  color: #775619;
}

body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1,
body[data-visual-preview="world-first"][data-route="today"] .hero-lead,
body[data-visual-preview="world-first"][data-route="today"] .duration {
  color: #0a1d2e;
  text-shadow: 0 1px 16px rgba(255, 248, 226, 0.42);
}

body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1 {
  max-width: 13ch;
  font-size: clamp(42px, 8vw, 64px);
}

body[data-visual-preview="world-first"][data-route="today"] .hero-lead {
  max-width: 42ch;
}

body[data-visual-preview="world-first"][data-route="today"] .today-card {
  color: var(--ivory);
  background: rgba(5, 16, 27, 0.82);
  border-color: rgba(255, 245, 218, 0.2);
}

body[data-visual-preview="world-first"][data-route="today"] .today-card h2,
body[data-visual-preview="world-first"][data-route="today"] .today-card p:not(.eyebrow) {
  color: var(--ivory);
}

body[data-visual-preview="world-first"][data-route="today"] .today-card .eyebrow {
  color: var(--gold-bright);
}

body[data-visual-preview="world-first"][data-route="today"] .today-card .status-chip {
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.1);
}

body[data-visual-preview="world-first"][data-route="today"] .app-footer {
  display: none;
}

body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .hero-copy .eyebrow,
body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .hero-lead,
body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .duration,
body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .today-card p,
body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .today-card .status-chip {
  display: none !important;
}

body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .hero-actions .button {
  white-space: nowrap;
}

body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .today-card {
  grid-template-columns: minmax(0, 1fr);
}

.landing {
  min-height: calc(100svh - var(--shell-dock) - env(safe-area-inset-bottom));
  align-items: flex-end;
  padding: 72px var(--shell-gutter) 232px;
}

.landing::before {
  background:
    linear-gradient(180deg, rgba(5, 14, 23, 0.5) 0%, rgba(5, 14, 23, 0.08) 28%, rgba(5, 14, 23, 0.42) 58%, rgba(5, 14, 23, 0.98) 90%),
    linear-gradient(90deg, rgba(5, 15, 25, 0.34), rgba(5, 15, 25, 0.05));
}

.landing::after {
  height: 42%;
}

.hero-media img {
  object-position: 51% center;
}

.hero-copy {
  width: 100%;
  max-width: 560px;
  margin: 0;
}

.hero-copy h1 {
  max-width: 15ch;
  margin: 8px 0 14px;
  font-size: clamp(39px, 11vw, 54px);
  line-height: 0.98;
}

.hero-lead {
  display: none;
}

.hero-actions {
  align-items: stretch;
  flex-direction: column;
  gap: 9px;
  margin-top: 18px;
}

.hero-actions .button {
  width: 100%;
  min-height: 56px;
}

.duration {
  color: rgba(255, 250, 240, 0.72);
  text-align: center;
}

.today-card {
  z-index: 4;
  width: auto;
  align-self: end;
  margin: 0 var(--shell-gutter) 18px;
  padding: 17px 18px;
  grid-template-columns: 1fr auto;
  gap: 12px;
  color: var(--ivory);
  background: rgba(8, 21, 34, 0.82);
  border: 1px solid rgba(255, 250, 240, 0.18);
  border-radius: 20px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.24);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.today-card h2 {
  margin: 2px 0 2px;
  color: var(--ivory);
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.3;
}

.today-card p:not(.eyebrow) {
  display: none;
}

.today-card .eyebrow {
  color: var(--gold-bright);
  font-size: 10px;
}

.status-chip {
  max-width: 116px;
  align-self: center;
  padding: 7px 9px;
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.16);
  font-size: 10px;
  line-height: 1.3;
  text-align: center;
}

.family-invitation[data-route-view="today"] {
  z-index: 5;
  width: auto;
  align-self: end;
  margin: 0 var(--shell-gutter) 18px;
  padding: 18px;
  color: var(--ivory);
  background: rgba(8, 21, 34, 0.92);
  border-color: rgba(255, 250, 240, 0.18);
  border-radius: 20px;
}

.family-invitation h2,
.family-invitation p {
  color: inherit;
}

.map-stage {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  color: var(--ivory);
  border-radius: 0 0 30px 30px;
  background: var(--academy);
}

.world-map-lab {
  display: none;
}

body[data-visual-preview="world-first"][data-route="map"] {
  background: #071522;
}

body[data-visual-preview="world-first"][data-route="map"] .product-shell {
  height: 100svh;
  min-height: 0;
  padding-bottom: 0;
  overflow: hidden;
}

body[data-visual-preview="world-first"][data-route="map"] .app-main {
  height: 100%;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  background: #071522;
}

body[data-visual-preview="world-first"][data-route="map"] .roadmap-section {
  height: 100%;
  min-height: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body[data-visual-preview="world-first"][data-route="map"] .roadmap-section > :not(.world-map-lab) {
  display: none;
}

body[data-visual-preview="world-first"][data-route="map"] .world-map-lab {
  --map-scale: 1;
  --map-x: 0px;
  --map-y: 0px;
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  margin: 0;
  display: block;
  overflow: clip;
  color: var(--ivory);
  background: #071522;
  touch-action: none;
  user-select: none;
}

.world-map-canvas {
  position: absolute;
  left: 50%;
  top: 50%;
  width: max(100%, calc(100svh * 1.5));
  aspect-ratio: 3 / 2;
  transform: translate(calc(-50% + var(--map-x)), calc(-50% + var(--map-y))) scale(var(--map-scale));
  transform-origin: center;
  transition: transform 700ms cubic-bezier(0.2, 0.8, 0.2, 1);
  cursor: grab;
}

.world-map-lab.is-dragging .world-map-canvas {
  cursor: grabbing;
  transition: none;
}

.world-map-canvas > img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  pointer-events: none;
}

.world-map-lab::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(4, 13, 22, 0.45), transparent 24%, transparent 72%, rgba(4, 13, 22, 0.52)),
    linear-gradient(90deg, rgba(4, 13, 22, 0.2), transparent 26%, transparent 78%, rgba(4, 13, 22, 0.16));
}

.world-map-markers {
  position: absolute;
  inset: 0;
}

.world-map-marker {
  position: absolute;
  z-index: 2;
  width: 46px;
  height: 46px;
  padding: 0;
  color: var(--ivory);
  background: transparent;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}

.world-map-marker::before {
  content: "";
  position: absolute;
  inset: 11px;
  border: 2px solid #f1ca74;
  border-radius: 50% 50% 50% 10%;
  background: rgba(6, 18, 29, 0.66);
  box-shadow: 0 0 0 7px rgba(240, 207, 132, 0.13), 0 0 26px rgba(240, 207, 132, 0.38);
  transform: rotate(-45deg);
}

.world-map-marker::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 21px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #f8dd9e;
}

.world-map-marker span {
  position: absolute;
  left: 50%;
  top: 45px;
  min-width: max-content;
  padding: 7px 11px;
  color: var(--ivory);
  background: rgba(5, 16, 27, 0.76);
  border: 1px solid rgba(255, 250, 240, 0.18);
  border-radius: 999px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transform: translateX(-50%);
  font-size: 12px;
  font-weight: 750;
  line-height: 1;
  white-space: nowrap;
}

.world-map-marker:hover span,
.world-map-marker:focus-visible span,
.world-map-marker[aria-pressed="true"] span {
  color: #f6d78f;
  background: rgba(5, 16, 27, 0.94);
}

.world-map-marker[data-map-current="true"]::before {
  border-color: #fff0b0;
  background: rgba(44, 35, 18, 0.88);
  box-shadow:
    0 0 0 8px rgba(240, 207, 132, 0.18),
    0 0 0 17px rgba(240, 207, 132, 0.07),
    0 0 38px rgba(255, 218, 124, 0.76);
  animation: current-world-place 2.8s ease-in-out infinite alternate;
}

.world-map-marker[data-map-current="true"] span {
  color: #ffe6a0;
  border-color: rgba(255, 226, 154, 0.5);
  background: rgba(5, 16, 27, 0.92);
}

@keyframes current-world-place {
  to { box-shadow: 0 0 0 11px rgba(240, 207, 132, 0.1), 0 0 0 23px transparent, 0 0 48px rgba(255, 218, 124, 0.9); }
}

.marker-mountains { left: 18%; top: 28%; }
.marker-academy { left: 55%; top: 16%; }
.marker-forest { left: 80%; top: 32%; }
.marker-harbor { left: 45%; top: 46%; }
.marker-bridge { left: 61%; top: 46%; }
.marker-garden { left: 18%; top: 68%; }
.marker-lake { left: 54%; top: 74%; }
.marker-observatory { left: 86%; top: 72%; }
.marker-home { left: 39%; top: 62%; }

.world-map-titlebar {
  position: absolute;
  z-index: 3;
  top: 24px;
  left: var(--shell-gutter);
  pointer-events: none;
  text-shadow: 0 3px 20px rgba(0, 0, 0, 0.62);
}

.world-map-titlebar p,
.world-map-titlebar span {
  margin: 0;
  color: rgba(255, 250, 240, 0.74);
  font-size: 11px;
  font-weight: 760;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.world-map-titlebar h1 {
  margin: 3px 0 6px;
  color: var(--ivory);
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1;
}

.world-map-controls {
  position: absolute;
  z-index: 4;
  top: 24px;
  right: var(--shell-gutter);
  display: flex;
  gap: 8px;
}

.world-map-controls button,
.world-map-arrival-close {
  min-width: 46px;
  min-height: 46px;
  padding: 0 14px;
  color: var(--ivory);
  background: rgba(5, 16, 27, 0.68);
  border: 1px solid rgba(255, 250, 240, 0.18);
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  font-size: 20px;
  font-weight: 750;
}

.world-map-controls button[data-map-zoom="reset"] {
  font-size: 11px;
}

.world-map-arrival {
  position: absolute;
  z-index: 5;
  right: var(--shell-gutter);
  bottom: 24px;
  width: min(380px, calc(100% - 32px));
  padding: 22px;
  color: var(--ivory);
  background: rgba(5, 16, 27, 0.86);
  border: 1px solid rgba(255, 250, 240, 0.18);
  border-radius: 24px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
  -webkit-backdrop-filter: blur(22px);
  backdrop-filter: blur(22px);
}

.world-map-arrival-close {
  position: absolute;
  top: 12px;
  right: 12px;
  min-width: 42px;
  min-height: 42px;
  padding: 0;
}

.world-map-arrival > p:first-of-type {
  margin: 0 48px 6px 0;
  color: #efc66e;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.world-map-arrival h2 {
  margin: 0 48px 8px 0;
  color: var(--ivory);
  font-size: 28px;
}

.world-map-arrival > p:last-of-type {
  margin: 0 0 18px;
  color: rgba(255, 250, 240, 0.76);
}

.world-map-arrival .button {
  width: 100%;
}

@media (max-width: 599px) {
  body[data-visual-preview="world-first"][data-route="map"] .world-map-lab {
    height: calc(100svh - var(--shell-header) - var(--shell-dock) - env(safe-area-inset-bottom));
    margin-top: var(--shell-header);
  }

  .world-map-titlebar {
    top: 18px;
  }

  .world-map-titlebar span {
    display: none;
  }

  .world-map-controls {
    top: auto;
    right: 12px;
    bottom: 12px;
    flex-direction: column;
  }

  .world-map-controls button {
    min-width: 44px;
    min-height: 44px;
    padding-inline: 10px;
  }

  .world-map-controls button[data-map-zoom="reset"] {
    max-width: 58px;
    border-radius: 16px;
    line-height: 1.1;
  }

  .world-map-marker span {
    opacity: 0;
    pointer-events: none;
  }

  .world-map-marker:focus-visible span,
  .world-map-marker[aria-pressed="true"] span {
    opacity: 1;
  }

  .world-map-arrival {
    right: auto;
    bottom: 12px;
    left: 12px;
    width: calc(100% - 24px);
    max-width: none;
    box-sizing: border-box;
    padding: 18px;
  }

  .world-map-arrival h2 {
    font-size: 24px;
  }
}

@media (min-width: 1280px) {
  body[data-visual-preview="world-first"][data-route="map"] .product-shell {
    grid-template-rows: var(--shell-header) minmax(0, 1fr);
    grid-template-areas:
      "header header"
      "rail main";
  }

  body[data-visual-preview="world-first"][data-route="map"] .world-map-lab {
    height: 100%;
  }

  body[data-visual-preview="world-first"][data-route="map"] .app-footer {
    display: none;
  }
}

@media (min-width: 1440px) {
  body[data-visual-preview="world-first"][data-route="map"] .product-shell {
    grid-template-columns: var(--shell-rail) minmax(0, 1fr);
    grid-template-areas:
      "header header"
      "rail main";
  }

  body[data-visual-preview="world-first"][data-route="map"] .context-rail {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .world-map-canvas {
    transition: none;
  }
  .world-map-marker[data-map-current="true"]::before {
    animation: none;
  }
}

.map-stage picture,
.map-stage::after {
  position: absolute;
  inset: 0;
}

.map-stage::after {
  content: "";
  background: linear-gradient(180deg, rgba(5, 15, 25, 0.08), rgba(5, 15, 25, 0.9));
}

.map-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 54% center;
}

.map-stage-copy {
  position: absolute;
  z-index: 1;
  inset: auto var(--shell-gutter) 28px;
  max-width: 650px;
}

.map-stage-copy h1 {
  margin: 6px 0 10px;
  color: var(--ivory);
  font-size: clamp(34px, 9vw, 50px);
  line-height: 1;
}

.map-stage-copy p:last-child {
  margin: 0;
  color: rgba(255, 250, 240, 0.78);
}

.roadmap-section {
  width: 100%;
  margin: 0;
  padding: 0 0 42px;
  border-radius: 0;
}

.roadmap-section > :not(.map-stage) {
  margin-inline: var(--shell-gutter);
}

.roadmap-section .section-heading {
  padding-top: 30px;
}

.roadmap-card.is-available {
  position: relative;
}

.roadmap-action {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  margin-top: 18px;
  color: var(--ink);
  font-weight: 850;
  text-decoration: underline;
  text-decoration-color: rgba(21, 35, 49, 0.3);
  text-underline-offset: 5px;
}

.practice-workspace,
.journal-workspace {
  min-height: calc(100svh - var(--shell-header) - var(--shell-dock));
  padding: 30px var(--shell-gutter) 48px;
  background:
    radial-gradient(circle at 82% 12%, rgba(212, 167, 78, 0.15), transparent 24rem),
    var(--paper-cool);
}

.pause-clearing-media {
  display: none;
}

.private-preview-badge {
  position: fixed;
  z-index: 90;
  top: max(5px, env(safe-area-inset-top));
  left: 50%;
  margin: 0;
  padding: 3px 8px;
  color: rgba(255, 244, 211, 0.78);
  background: rgba(2, 9, 15, 0.7);
  border: 1px solid rgba(255, 219, 134, 0.24);
  border-radius: 999px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.13em;
  line-height: 1.4;
  pointer-events: none;
  transform: translateX(-50%);
}

/* Private, nonrelease CWP13 practice lab. Enabled only with ?visual=pause-clearing. */
body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-workspace {
  position: relative;
  isolation: isolate;
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  overflow: hidden;
  color: var(--ivory);
  background: #07131e;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .product-shell {
  height: 100svh;
  min-height: 0;
  padding-bottom: 0;
  overflow: hidden;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .app-main {
  height: 100%;
  min-height: 0;
  padding: 0;
  overflow: hidden;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-workspace::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  content: "";
  background:
    linear-gradient(180deg, rgba(3, 12, 19, 0.48) 0%, rgba(3, 12, 19, 0.08) 28%, rgba(3, 12, 19, 0.18) 58%, rgba(3, 12, 19, 0.84) 100%),
    linear-gradient(90deg, rgba(3, 12, 19, 0.46), transparent 52%, rgba(3, 12, 19, 0.18));
  pointer-events: none;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .pause-clearing-media {
  position: absolute;
  z-index: -2;
  inset: 0;
  display: block;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .pause-clearing-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading {
  width: min(100%, 1040px);
  margin-bottom: 0;
  color: var(--ivory);
  text-shadow: 0 2px 20px rgba(2, 9, 15, 0.72);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading h1,
body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading > p {
  color: var(--ivory);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading h1 {
  line-height: 1.08;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading .eyebrow {
  color: var(--gold-bright);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-canvas {
  width: min(100%, 920px);
  grid-template-columns: minmax(0, 1fr);
  place-content: center;
  gap: 20px;
  margin-block: 16px;
  padding: 12px;
  color: var(--ivory);
  background: transparent;
  border: 0;
  box-shadow: none;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .breath-orbit {
  width: min(38vw, 210px);
  border-color: rgba(255, 226, 157, 0.58);
  background: radial-gradient(circle, rgba(255, 211, 114, 0.28), rgba(255, 211, 114, 0.06) 46%, transparent 69%);
  box-shadow: 0 0 70px rgba(234, 177, 74, 0.16);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .breath-orbit span {
  background: radial-gradient(circle at 34% 30%, #fff2c9, #d9a746 66%, #78571d);
  box-shadow: 0 0 0 16px rgba(255, 223, 151, 0.1), 0 0 42px rgba(255, 210, 112, 0.42);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-instruction {
  justify-self: center;
  max-width: 620px;
  text-align: center;
  text-shadow: 0 2px 20px rgba(2, 9, 15, 0.84);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-step,
body[data-visual-preview="pause-clearing"][data-route="practices"] #practiceHint {
  color: var(--ivory);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-actions {
  justify-content: center;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-actions .text-button {
  color: var(--ivory);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary {
  width: auto;
  min-height: 44px;
  display: flex;
  justify-self: center;
  align-items: center;
  justify-content: center;
  margin-top: 0;
  padding: 6px 14px;
  color: var(--ivory);
  background: rgba(5, 16, 27, 0.66);
  border-color: rgba(255, 245, 218, 0.22);
  border-radius: 999px;
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary > span,
body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary h2,
body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary p {
  display: none;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary .text-button::before {
  content: "Если стало неприятно · ";
  font-weight: 500;
  text-decoration: none;
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary h2,
body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary p,
body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary .text-button {
  color: var(--ivory);
}

body[data-visual-preview="pause-clearing"][data-route="practices"] .app-footer {
  display: none;
}

body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .practice-workspace {
  height: auto;
  min-height: calc(100svh - var(--shell-header) - var(--shell-dock));
  grid-template-rows: auto auto auto;
  overflow: visible;
}

body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .product-shell,
body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .app-main {
  height: auto;
  min-height: 100svh;
  overflow: visible;
}

body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .workspace-heading .eyebrow,
body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .workspace-heading h1,
body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .practice-instruction,
body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .practice-boundary {
  max-width: 100%;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: normal;
}

@media (max-width: 599px) {
  body[data-visual-preview="pause-clearing"][data-route="practices"] .app-main {
    padding-top: calc(var(--shell-header) + env(safe-area-inset-top));
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-workspace {
    height: calc(100svh - var(--shell-header) - var(--shell-dock) - env(safe-area-inset-bottom));
    padding: 24px 16px calc(24px + env(safe-area-inset-bottom));
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading > p {
    display: none;
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading {
    margin-top: 0;
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading .eyebrow {
    display: none;
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .workspace-heading h1 {
    font-size: clamp(38px, 12vw, 54px);
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .breath-orbit {
    width: min(42vw, 170px);
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-canvas {
    margin-block: 6px;
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-step {
    font-size: clamp(26px, 8vw, 36px);
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary {
    padding: 4px 10px;
    background: rgba(5, 16, 27, 0.74);
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-boundary .text-button::before {
    content: "";
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"][data-text-scale="200"] .mobile-dock {
    position: static;
  }
}

@media (min-width: 600px) and (max-width: 1279px) and (orientation: portrait) {
  body[data-visual-preview="pause-clearing"][data-route="practices"] .app-main {
    height: calc(100svh - var(--shell-header));
  }

  body[data-visual-preview="pause-clearing"][data-route="practices"] .practice-workspace {
    height: 100%;
    padding-bottom: calc(106px + env(safe-area-inset-bottom));
  }
}

.workspace-heading {
  max-width: 1040px;
  display: grid;
  gap: 8px;
  margin: 0 auto 26px;
}

.workspace-heading h1 {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: clamp(36px, 9vw, 56px);
  line-height: 1;
}

.workspace-heading > p {
  max-width: 58ch;
  margin: 0;
  color: var(--ink-soft);
}

.practice-canvas {
  max-width: 920px;
  display: grid;
  gap: 26px;
  margin: 0 auto;
  padding: 28px;
  background: rgba(255, 250, 240, 0.78);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
}

.breath-orbit {
  width: min(54vw, 220px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  justify-self: center;
  border: 1px solid rgba(82, 116, 103, 0.28);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(82, 116, 103, 0.18), transparent 66%);
}

.breath-orbit span {
  width: 44%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--sage);
  box-shadow: 0 0 0 16px rgba(82, 116, 103, 0.09);
  transform: scale(0.76);
  transition: transform 1800ms ease-in-out;
}

.practice-canvas.is-active .breath-orbit span {
  transform: scale(1.12);
}

.practice-instruction {
  align-self: center;
}

.practice-step {
  margin: 0 0 8px;
  color: var(--ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(28px, 7vw, 42px);
  line-height: 1.08;
}

.practice-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.practice-boundary {
  max-width: 920px;
  margin: 20px auto 0;
}

.journal-gate,
.journal-editor {
  max-width: 920px;
  margin: 0 auto;
  padding: clamp(22px, 5vw, 42px);
  background: var(--paper-warm);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow-soft);
}

.journal-gate {
  display: grid;
  gap: 22px;
}

.privacy-seal {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  color: var(--sage);
  background: var(--sage-pale);
  border-radius: 22px;
}

.privacy-seal svg {
  width: 36px;
  height: 36px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.journal-gate h2 {
  margin: 0 0 12px;
  font-size: clamp(28px, 7vw, 42px);
}

.journal-editor label {
  display: block;
  margin-bottom: 12px;
  color: var(--ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(25px, 6vw, 36px);
  font-weight: 700;
}

.journal-editor textarea {
  width: 100%;
  min-height: 320px;
  resize: vertical;
  padding: 20px;
  color: var(--ink);
  background:
    repeating-linear-gradient(180deg, transparent 0, transparent 31px, rgba(21, 35, 49, 0.09) 32px),
    rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(21, 35, 49, 0.22);
  border-radius: 18px;
  font-family: ui-serif, Georgia, serif;
  font-size: 19px;
  line-height: 32px;
}

.journal-meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
  color: var(--ink-soft);
  font-size: 13px;
}

.family-route-title {
  margin: 0 0 22px;
  color: var(--ink);
  font-size: clamp(38px, 8vw, 58px);
}

.adult-note[data-route-view="family"],
.family-studio[data-route-view="family"] {
  width: calc(100% - (2 * var(--shell-gutter)));
}

.adult-note[data-route-view="family"] {
  margin: 30px auto 16px;
}

.family-studio[data-route-view="family"] {
  margin: 0 auto 48px;
}

.lesson-shell {
  width: 100%;
  min-height: calc(100svh - var(--shell-header) - var(--shell-dock));
  margin: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.lesson-header {
  position: sticky;
  z-index: 8;
  top: 0;
  padding: 16px var(--shell-gutter);
  color: var(--ivory);
  background: rgba(8, 21, 34, 0.96);
  border-bottom: 1px solid rgba(255, 250, 240, 0.14);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.lesson-header h1 {
  margin: 0;
  color: var(--ivory);
  font-size: 22px;
  line-height: 1.15;
}

.lesson-header .text-button {
  min-height: 44px;
  color: var(--ivory);
}

.stepper {
  position: sticky;
  z-index: 7;
  top: calc(var(--shell-header) + env(safe-area-inset-top) + 100px);
  padding-inline: var(--shell-gutter);
  background: rgba(252, 248, 239, 0.96);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.lesson-stage {
  padding: 30px var(--shell-gutter) 46px;
}

.lesson-screen {
  max-width: 980px;
  margin-inline: auto;
}

.story-world img {
  object-position: 52% center;
}

.privacy-strip {
  display: none;
}

.app-footer {
  display: none;
}

.mobile-dock {
  position: fixed;
  z-index: 45;
  inset: auto 0 0;
  min-height: calc(var(--shell-dock) + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: start;
  padding: 7px max(8px, env(safe-area-inset-right)) env(safe-area-inset-bottom)
    max(8px, env(safe-area-inset-left));
  background: rgba(7, 19, 31, 0.96);
  border-top: 1px solid rgba(255, 250, 240, 0.14);
  box-shadow: 0 -14px 40px rgba(0, 0, 0, 0.22);
  -webkit-backdrop-filter: blur(22px);
  backdrop-filter: blur(22px);
}

.mobile-dock a,
.atlas-shelf a {
  min-width: 0;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 3px;
  color: rgba(255, 250, 240, 0.64);
  border-radius: 14px;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.2;
  text-decoration: none;
}

.mobile-dock svg,
.atlas-shelf svg,
.primary-rail svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.65;
}

.mobile-dock [data-route].is-active,
.mobile-dock [data-route][aria-current="page"],
.atlas-shelf [data-route].is-active,
.atlas-shelf [data-route][aria-current="page"],
.primary-rail [data-route].is-active,
.primary-rail [data-route][aria-current="page"],
.family-access.is-active {
  color: var(--gold-bright);
  background: rgba(240, 207, 132, 0.1);
}

.context-prompt,
.context-link {
  width: 100%;
  min-height: 48px;
  display: flex;
  align-items: center;
  margin-top: 10px;
  padding: 12px 14px;
  color: var(--ivory);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 250, 240, 0.14);
  border-radius: 13px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
  text-align: left;
  text-decoration: none;
}

.help-dialog {
  width: min(620px, calc(100% - 28px));
  max-height: min(720px, calc(100svh - 28px));
  padding: 0;
  color: var(--ink);
  background: var(--paper-warm);
  border: 1px solid rgba(255, 250, 240, 0.4);
  border-radius: 24px;
  box-shadow: 0 35px 100px rgba(0, 0, 0, 0.42);
}

.help-dialog::backdrop {
  background: rgba(2, 9, 15, 0.72);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.help-dialog > * {
  margin-inline: 24px;
}

.help-dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-top: 24px;
}

.help-dialog-head h2 {
  margin: 4px 0 0;
  font-size: clamp(28px, 7vw, 42px);
}

.help-dialog .icon-button {
  flex: 0 0 auto;
  color: var(--ink);
  background: rgba(21, 35, 49, 0.06);
  border-color: var(--line);
  font-size: 26px;
}

.help-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-block: 24px;
}

.help-reset {
  margin-bottom: 24px;
}

body[data-visual-preview="world-first"][data-route="today"] .product-shell {
  height: 100svh;
  min-height: 0;
  padding-bottom: 0;
  overflow: hidden;
}

body[data-visual-preview="world-first"][data-route="today"] .app-main {
  height: 100%;
  min-height: 0;
  display: grid;
  padding: 0;
  overflow: hidden;
}

body[data-visual-preview="world-first"][data-route="today"] .app-main > [data-route-view="today"] {
  grid-area: 1 / 1;
}

body[data-visual-preview="world-first"][data-route="today"] .landing {
  width: 100%;
  height: 100%;
  min-height: 0;
}

body[data-visual-preview="world-first"][data-route="today"] .today-card {
  z-index: 4;
  align-self: end;
}

@media (max-width: 599px) {
  .connection-status {
    position: fixed;
    top: calc(var(--shell-header) + env(safe-area-inset-top) + 8px);
    left: 50%;
    padding: 6px 10px;
    color: var(--night);
    background: var(--gold-bright);
    border-radius: 999px;
    box-shadow: var(--shadow-soft);
    transform: translateX(-50%);
  }

  body[data-session-mode="child-alpha"] .connection-status {
    top: calc(env(safe-area-inset-top) + 14px);
    right: 68px;
    left: auto;
    width: auto;
    max-width: 86px;
    min-height: 34px;
    padding: 7px 10px;
    overflow: hidden;
    font-size: 0;
    line-height: 1;
    text-overflow: clip;
    white-space: nowrap;
    transform: none;
  }

  body[data-session-mode="child-alpha"] .connection-status::after {
    content: "Временно";
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.02em;
  }

  body[data-session-mode="child-alpha"][data-route="lesson"] .connection-status {
    display: none;
  }

  .brand small {
    display: none;
  }

  .mode-switch {
    display: none;
  }

  .family-access {
    display: inline-grid;
  }

  .site-header.app-header {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .hero-copy .eyebrow {
    font-size: 10px;
  }

  .practice-actions,
  .screen-actions,
  .help-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .practice-actions .button,
  .screen-actions .button,
  .screen-actions a,
  .help-actions .button {
    width: 100%;
  }

  .lesson-header {
    grid-template-columns: 1fr auto;
  }

  .lesson-actions {
    grid-column: 1 / -1;
    grid-row: 3;
  }

  .lesson-heading {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .lesson-header .step-count {
    align-self: center;
    text-align: right;
  }

  .stepper {
    position: static;
  }

  .stepper li small {
    font-size: 10px;
  }

  .story-world {
    height: min(34svh, 270px);
  }

  .lesson-screen h3 {
    font-size: clamp(29px, 8.5vw, 40px);
  }

  .journal-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }

  .toast {
    right: 12px;
    bottom: calc(var(--shell-dock) + env(safe-area-inset-bottom) + 12px);
    max-width: calc(100% - 24px);
  }
}

@media (min-width: 600px) and (max-width: 1279px) {
  .product-shell {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    padding-bottom: calc(82px + env(safe-area-inset-bottom));
  }

  .site-header.app-header {
    position: sticky;
    grid-row: 1;
  }

  .app-main {
    grid-row: 2;
    min-height: 0;
    padding: 0;
  }

  .mobile-dock {
    display: none;
  }

  .atlas-shelf {
    position: fixed;
    z-index: 45;
    inset: auto 20px max(10px, env(safe-area-inset-bottom));
    min-height: 70px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    padding: 6px;
    background: rgba(7, 19, 31, 0.94);
    border: 1px solid rgba(255, 250, 240, 0.16);
    border-radius: 22px;
    box-shadow: 0 16px 50px rgba(0, 0, 0, 0.28);
    -webkit-backdrop-filter: blur(22px);
    backdrop-filter: blur(22px);
  }

  .atlas-shelf a {
    min-height: 58px;
    font-size: 11px;
  }

  body[data-route="today"] .app-main {
    min-height: calc(100svh - var(--shell-header));
  }

  .landing {
    min-height: calc(100svh - var(--shell-header));
    padding: 90px 7vw 250px;
  }

  .hero-copy {
    max-width: 620px;
    padding: 28px;
    background: rgba(7, 19, 31, 0.68);
    border: 1px solid rgba(255, 250, 240, 0.16);
    border-radius: 26px;
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
  }

  .hero-copy h1 {
    font-size: clamp(48px, 7vw, 70px);
  }

  .hero-lead {
    display: block;
  }

  .hero-actions {
    align-items: center;
    flex-direction: row;
  }

  .hero-actions .button {
    width: auto;
    min-width: 220px;
  }

  .today-card,
  .family-invitation[data-route-view="today"] {
    margin: 0 7vw 104px;
  }

  .roadmap-section,
  .practice-workspace,
  .journal-workspace,
  .lesson-shell {
    min-height: calc(100svh - var(--shell-header));
    border-radius: 0;
  }

  .map-stage {
    min-height: 480px;
    border-radius: 0 0 34px 34px;
  }

  .practice-canvas {
    grid-template-columns: minmax(220px, 0.7fr) minmax(0, 1.3fr);
  }

  .journal-gate {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .lesson-header {
    top: 0;
  }

  .stepper {
    position: static;
  }
}

@media (min-width: 600px) and (max-width: 1279px) and (orientation: landscape) {
  .product-shell {
    padding-bottom: 0;
    padding-left: 84px;
  }

  .site-header.app-header {
    margin-left: -84px;
    width: calc(100% + 84px);
  }

  .atlas-shelf {
    inset: calc(var(--shell-header) + 14px) auto 14px 10px;
    width: 66px;
    grid-template-columns: 1fr;
    grid-template-rows: repeat(5, minmax(0, 1fr));
  }

  .atlas-shelf a {
    min-height: 52px;
  }

  .landing {
    padding-bottom: 190px;
  }

  .today-card,
  .family-invitation[data-route-view="today"] {
    margin-bottom: 28px;
  }
}

@media (min-width: 1280px) {
  body {
    overflow: hidden;
  }

  .product-shell {
    height: 100svh;
    display: grid;
    grid-template-columns: var(--shell-rail) minmax(0, 1fr);
    grid-template-rows: var(--shell-header) minmax(0, 1fr) auto;
    grid-template-areas:
      "header header"
      "rail main"
      "rail footer";
    padding: 0;
  }

  .site-header.app-header {
    position: relative;
    grid-area: header;
    min-height: var(--shell-header);
    padding: 0 22px;
    background: var(--academy);
  }

  .brand strong {
    font-size: 17px;
  }

  .connection-status {
    color: rgba(255, 250, 240, 0.72);
  }

  .primary-rail {
    min-width: 0;
    display: flex;
    flex-direction: column;
    grid-area: rail;
    padding: 18px 14px 16px;
    color: var(--ivory);
    background:
      radial-gradient(circle at 50% 4%, rgba(212, 167, 78, 0.12), transparent 16rem),
      var(--academy);
    border-right: 1px solid rgba(255, 250, 240, 0.12);
  }

  .primary-rail nav {
    display: grid;
    gap: 6px;
  }

  .primary-rail a,
  .rail-help {
    width: 100%;
    min-height: 50px;
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 10px 13px;
    color: rgba(255, 250, 240, 0.68);
    background: transparent;
    border: 1px solid transparent;
    border-radius: 14px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 750;
    text-align: left;
    text-decoration: none;
  }

  .primary-rail a.is-active,
  .primary-rail a[aria-current="page"] {
    color: var(--gold-bright);
    background: rgba(240, 207, 132, 0.1);
    border-color: rgba(240, 207, 132, 0.15);
  }

  .rail-help {
    margin-top: auto;
  }

  .app-main {
    grid-area: main;
    min-height: 0;
    padding: 24px;
    overflow: auto;
    overscroll-behavior: contain;
  }

  .mobile-dock,
  .atlas-shelf {
    display: none;
  }

  body[data-route="today"] .app-main {
    min-height: 0;
    display: block;
    overflow: auto;
    background:
      linear-gradient(135deg, rgba(255, 250, 240, 0.65), rgba(232, 226, 211, 0.88)),
      var(--paper-cool);
  }

  .landing {
    min-height: min(650px, calc(100svh - 160px));
    align-items: center;
    padding: 48px;
    border-radius: 32px;
    box-shadow: var(--shadow);
  }

  .landing::before {
    background:
      linear-gradient(90deg, rgba(5, 15, 25, 0.92), rgba(5, 15, 25, 0.57) 48%, rgba(5, 15, 25, 0.08) 76%),
      linear-gradient(180deg, rgba(5, 15, 25, 0.18), rgba(5, 15, 25, 0.46));
  }

  .hero-copy {
    max-width: 630px;
    margin: 0;
  }

  .hero-copy h1 {
    font-size: clamp(52px, 5vw, 78px);
  }

  .hero-lead {
    display: block;
    max-width: 56ch;
  }

  .hero-actions {
    align-items: center;
    flex-direction: row;
  }

  .hero-actions .button {
    width: auto;
    min-width: 220px;
  }

  .today-card {
    width: min(760px, calc(100% - 80px));
    margin: -42px auto 18px;
    padding: 24px 26px;
    color: var(--ink);
    background: rgba(255, 250, 240, 0.94);
    border-color: rgba(21, 35, 49, 0.13);
  }

  .today-card h2 {
    color: var(--ink);
    font-size: 20px;
  }

  .today-card p:not(.eyebrow) {
    display: block;
    margin: 5px 0 0;
    color: var(--ink-soft);
  }

  .today-card .eyebrow {
    color: var(--sage);
  }

  .today-card .status-chip {
    max-width: 180px;
    color: var(--ink);
    background: var(--sage-pale);
  }

  .family-invitation[data-route-view="today"] {
    width: min(760px, calc(100% - 80px));
    margin: -42px auto 18px;
  }

  .roadmap-section,
  .practice-workspace,
  .journal-workspace,
  .lesson-shell {
    min-height: 100%;
    overflow: hidden;
    border: 1px solid rgba(21, 35, 49, 0.1);
    border-radius: 28px;
    box-shadow: var(--shadow-soft);
  }

  .map-stage {
    min-height: 450px;
    border-radius: 0;
  }

  .roadmap-section {
    padding-bottom: 48px;
  }

  .practice-workspace,
  .journal-workspace {
    padding: 50px;
  }

  .workspace-heading {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.6fr);
    align-items: end;
  }

  .workspace-heading h1 {
    font-size: clamp(48px, 5vw, 68px);
  }

  .practice-canvas {
    grid-template-columns: 0.7fr 1.3fr;
    padding: 42px;
  }

  .journal-gate {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .adult-note[data-route-view="family"] {
    margin-top: 0;
  }

  .lesson-header {
    top: 0;
    grid-template-columns: 180px minmax(0, 1fr) 190px;
  }

  .lesson-header h1 {
    font-size: 26px;
  }

  .stepper {
    top: 98px;
  }

  .lesson-stage {
    padding: 46px;
  }

  .privacy-strip {
    width: 100%;
  }

  .app-footer {
    grid-area: footer;
    min-height: 26px;
    display: flex;
    justify-content: space-between;
    padding: 3px 24px 5px;
    color: rgba(21, 35, 49, 0.52);
    background: var(--paper-cool);
    border: 0;
    font-size: 10px;
  }

  .toast {
    bottom: 28px;
  }
}

@media (min-width: 1440px) {
  .product-shell {
    grid-template-columns: var(--shell-rail) minmax(0, 1fr) var(--shell-context);
    grid-template-areas:
      "header header header"
      "rail main context"
      "rail footer context";
  }

  .context-rail {
    min-width: 0;
    display: block;
    grid-area: context;
    overflow: auto;
    padding: 24px 18px;
    color: rgba(255, 250, 240, 0.76);
    background:
      radial-gradient(circle at 50% 0, rgba(92, 119, 143, 0.18), transparent 22rem),
      var(--academy-raised);
    border-left: 1px solid rgba(255, 250, 240, 0.11);
  }

  .context-rail > header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 250, 240, 0.12);
  }

  .context-rail header strong,
  .context-rail header small {
    display: block;
  }

  .context-rail header small {
    margin-top: 2px;
    color: rgba(255, 250, 240, 0.5);
    font-size: 10px;
    line-height: 1.35;
  }

  .elvi-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    color: var(--academy);
    background: var(--gold-bright);
    border-radius: 50%;
    font-family: ui-serif, Georgia, serif;
    font-size: 20px;
    font-weight: 800;
  }

  .context-rail section {
    padding-top: 24px;
  }

  .context-rail h2 {
    margin: 7px 0 10px;
    color: var(--ivory);
    font-size: 28px;
    line-height: 1.05;
  }

  .context-rail p {
    font-size: 13px;
    line-height: 1.55;
  }

  .context-response {
    margin-top: 14px;
    padding: 14px;
    color: var(--ivory);
    background: rgba(240, 207, 132, 0.09);
    border: 1px solid rgba(240, 207, 132, 0.18);
    border-radius: 14px;
    font-size: 13px;
  }
}

@media (prefers-contrast: more) {
  .site-header.app-header,
  .mobile-dock,
  .atlas-shelf,
  .primary-rail,
  .context-rail {
    background: #02090f;
  }

  .button,
  .context-prompt,
  .context-link,
  .today-card,
  .journal-gate,
  .journal-editor {
    border-width: 2px;
  }

  .mobile-dock [data-route].is-active,
  .atlas-shelf [data-route].is-active,
  .primary-rail [data-route].is-active {
    text-decoration: underline;
    text-underline-offset: 4px;
  }
}

/* The 8–10 living week owns the whole frame. Global academy chrome is deliberately
   removed here: a child enters a place, not another page inside a dashboard. */
body[data-route="childProgram"] {
  overflow: hidden;
  background: #07131f;
}

body[data-route="childProgram"] .site-header.app-header,
body[data-route="childProgram"] .primary-rail,
body[data-route="childProgram"] .context-rail,
body[data-route="childProgram"] .atlas-shelf,
body[data-route="childProgram"] .mobile-dock,
body[data-route="childProgram"] .young-mobile-dock,
body[data-route="childProgram"] .teen-mobile-dock,
body[data-route="childProgram"] .adult-mobile-dock {
  display: none !important;
}

body[data-route="childProgram"] .product-shell {
  display: block;
  width: 100vw;
  height: 100dvh;
  min-height: 100dvh;
  padding: 0;
  grid-template: none;
}

body[data-route="childProgram"] .app-main {
  display: block;
  grid-area: auto;
  width: 100%;
  height: 100dvh;
  min-height: 0;
  padding: 0;
  overflow: auto;
  background: #07131f;
}

/* The 8–10 living week is a place, not a document. One stage owns the frame; the
   controls sit on top of the world and disappear again after each decision. */
.child-program-workspace {
  position: relative;
  isolation: isolate;
  min-height: 100dvh;
  overflow: hidden;
  color: #fff8e8;
  background:
    radial-gradient(circle at 72% 26%, rgba(242, 198, 95, 0.12), transparent 34%),
    linear-gradient(145deg, #0b2030 0%, #07131f 58%, #030b13 100%);
}

.child-program-world,
.child-program-world::after,
.child-program-world img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.child-program-world img {
  object-fit: cover;
  object-position: 58% center;
  filter: saturate(0.92) contrast(1.04) brightness(0.78);
  transform: scale(1.02);
  opacity: 1;
  transition: opacity 220ms ease;
}

.child-program-workspace[data-world-asset-state="loading"] .child-program-world img,
.child-program-workspace[data-world-asset-state="missing"] .child-program-world img {
  opacity: 0;
}

.child-program-world::after {
  content: "";
  background:
    linear-gradient(90deg, rgba(3, 12, 22, 0.94) 0%, rgba(3, 12, 22, 0.72) 35%, rgba(3, 12, 22, 0.05) 72%),
    linear-gradient(0deg, rgba(3, 12, 22, 0.82) 0%, transparent 42%, rgba(3, 12, 22, 0.28) 100%);
}

.child-program-atmosphere {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

.fictional-harbour-response {
  position: absolute;
  z-index: 1;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition: opacity 420ms ease;
}

.child-program-workspace[data-experience="fictional-harbour"][data-harbour-stage="consequence"] .fictional-harbour-response,
.child-program-workspace[data-experience="fictional-harbour"][data-harbour-stage="complete"] .fictional-harbour-response {
  opacity: 1;
}

.fictional-harbour-response > span {
  position: absolute;
  display: none;
}

.child-program-workspace[data-harbour-outcome*="pause-and-compare"] .harbour-clock-ring {
  top: 19%;
  right: 11%;
  display: block;
  width: min(38vw, 34rem);
  aspect-ratio: 1;
  border: 1px solid rgba(255, 222, 135, 0.58);
  border-radius: 50%;
  background:
    repeating-conic-gradient(from -4deg, rgba(255, 224, 144, 0.62) 0 1deg, transparent 1deg 30deg),
    radial-gradient(circle, transparent 0 45%, rgba(248, 194, 76, 0.14) 46% 47%, transparent 48% 63%, rgba(248, 194, 76, 0.2) 64% 65%, transparent 66%);
  box-shadow: inset 0 0 4rem rgba(240, 183, 67, 0.12), 0 0 5rem rgba(240, 183, 67, 0.16);
  animation: harbour-clock-arrive 900ms cubic-bezier(.2,.8,.2,1) both;
}

.child-program-workspace[data-harbour-outcome*="signal-and-wait"] .harbour-beacon {
  display: block;
  width: 0.75rem;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #fff0aa;
  box-shadow: 0 0 0 0.65rem rgba(244, 187, 64, 0.14), 0 0 4.5rem 1.6rem rgba(244, 187, 64, 0.65);
  animation: harbour-beacon-reply 1.8s ease-in-out infinite alternate;
}

.child-program-workspace[data-harbour-outcome*="signal-and-wait"] .harbour-beacon-west {
  top: 37%;
  right: 35%;
}

.child-program-workspace[data-harbour-outcome*="signal-and-wait"] .harbour-beacon-east {
  top: 51%;
  right: 18%;
  animation-delay: -0.9s;
}

.child-program-workspace[data-harbour-outcome*="map-alternate-route"] .harbour-route-line {
  right: 8%;
  bottom: 17%;
  display: block;
  width: 46%;
  height: 30%;
  border-top: 3px dashed rgba(255, 218, 120, 0.88);
  border-radius: 50%;
  filter: drop-shadow(0 0 0.6rem rgba(244, 187, 64, 0.75));
  transform: rotate(-11deg);
  animation: harbour-route-arrive 850ms ease-out both;
}

.child-program-workspace[data-harbour-outcome*="map-alternate-route"] .harbour-route-point {
  display: block;
  width: 0.7rem;
  aspect-ratio: 1;
  border: 2px solid #fff0b5;
  border-radius: 50%;
  background: #d9a33a;
  box-shadow: 0 0 1.4rem rgba(244, 187, 64, 0.85);
}

.harbour-route-point-a { right: 52%; bottom: 40%; }
.harbour-route-point-b { right: 31%; bottom: 29%; }
.harbour-route-point-c { right: 9%; bottom: 42%; }

@keyframes harbour-clock-arrive {
  from { opacity: 0; transform: scale(0.82) rotate(-12deg); }
  to { opacity: 1; transform: scale(1) rotate(0); }
}

@keyframes harbour-beacon-reply {
  from { opacity: 0.45; transform: scale(0.76); }
  to { opacity: 1; transform: scale(1.12); }
}

@keyframes harbour-route-arrive {
  from { opacity: 0; transform: rotate(-11deg) scaleX(0.2); transform-origin: right; }
  to { opacity: 1; transform: rotate(-11deg) scaleX(1); transform-origin: right; }
}

.child-program-atmosphere span {
  position: absolute;
  width: 0.35rem;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #ffd77b;
  box-shadow: 0 0 1.25rem 0.4rem rgba(255, 198, 80, 0.72);
  animation: child-program-drift 9s ease-in-out infinite alternate;
}

.child-program-atmosphere span:nth-child(1) { left: 48%; top: 29%; }
.child-program-atmosphere span:nth-child(2) { left: 73%; top: 54%; animation-delay: -3s; }
.child-program-atmosphere span:nth-child(3) { left: 88%; top: 22%; animation-delay: -6s; }

@keyframes child-program-drift {
  to { transform: translate3d(1.4rem, -1.8rem, 0); opacity: 0.45; }
}

.child-program-header,
.child-program-stage,
.child-program-rights {
  position: relative;
  z-index: 2;
}

.child-program-header {
  display: grid;
  grid-template-columns: minmax(10rem, auto) minmax(14rem, 34rem) auto;
  align-items: center;
  gap: 1.5rem;
  padding: clamp(1.15rem, 2.2vw, 2rem) clamp(1.25rem, 3.4vw, 3.5rem);
  border-bottom: 1px solid rgba(255, 240, 199, 0.16);
  background: linear-gradient(180deg, rgba(2, 10, 19, 0.72), rgba(2, 10, 19, 0));
}

.child-program-location,
.child-program-position {
  margin: 0;
}

.child-program-location {
  color: #f8ce73;
  font: 600 0.8rem/1.2 var(--font-sans, sans-serif);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.child-program-position {
  margin-top: 0.35rem;
  color: rgba(255, 248, 232, 0.7);
  font-size: 0.82rem;
}

.child-program-lanterns {
  display: flex;
  justify-content: center;
  gap: clamp(0.4rem, 1.1vw, 0.85rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.child-program-lanterns li {
  width: clamp(0.55rem, 1vw, 0.75rem);
  aspect-ratio: 1;
  border: 1px solid rgba(255, 236, 186, 0.45);
  border-radius: 50%;
  background: rgba(3, 12, 22, 0.42);
}

.child-program-lanterns li[data-state="complete"] {
  background: #e9b84f;
  box-shadow: 0 0 1rem rgba(244, 193, 84, 0.65);
}

.child-program-lanterns li[data-state="current"] {
  border-color: #ffe7a8;
  background: #fff3ca;
  box-shadow: 0 0 1.2rem rgba(255, 217, 123, 0.9);
  transform: scale(1.2);
}

.child-program-close {
  justify-self: end;
  min-height: 44px;
  padding: 0.65rem 1rem;
  border: 1px solid rgba(255, 240, 199, 0.28);
  border-radius: 999px;
  color: inherit;
  background: rgba(3, 12, 22, 0.36);
  backdrop-filter: blur(14px);
}

.child-program-stage {
  display: grid;
  grid-template-columns: minmax(0, 42rem) minmax(13rem, 20rem);
  align-items: end;
  gap: clamp(1.25rem, 3vw, 3rem);
  min-height: calc(100dvh - 13rem);
  padding: clamp(2.5rem, 7vh, 6rem) clamp(1.25rem, 5vw, 5rem) clamp(4.5rem, 8vh, 7rem);
}

.child-program-copy {
  max-width: 42rem;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}

.child-program-copy .eyebrow {
  color: #f5c866;
}

.child-program-copy h1 {
  max-width: 12ch;
  margin: 0.4rem 0 1rem;
  color: #fff8e8;
  font: 500 clamp(2.6rem, 5.1vw, 4.75rem)/0.98 var(--font-serif, serif);
  letter-spacing: -0.045em;
}

/* Route headings receive programmatic focus for screen readers. Keep that
   focus visible without turning the story title into a giant SaaS-style card. */
.child-program-copy h1[tabindex="-1"]:focus-visible {
  padding-left: 0.18em;
  outline: 0;
  box-shadow: inset 0.055em 0 rgba(248, 202, 101, 0.95);
}

.child-program-body {
  max-width: 38rem;
  color: rgba(255, 248, 232, 0.91);
  font-size: clamp(1.05rem, 1.5vw, 1.28rem);
  line-height: 1.55;
}

.child-program-body > * {
  margin: 0;
}

.child-program-body > * + * {
  margin-top: 0.9rem;
}

.child-program-body strong {
  color: #ffe5a0;
}

.child-program-choices {
  display: grid;
  gap: 0.7rem;
  max-width: 42rem;
  margin-top: 1.45rem;
}

.child-program-choice {
  min-height: 52px;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(255, 238, 197, 0.2);
  border-radius: 1rem;
  color: #fff8e8;
  text-align: left;
  background: rgba(3, 12, 22, 0.58);
  box-shadow: 0 0.8rem 2.5rem rgba(0, 0, 0, 0.14);
  backdrop-filter: blur(18px);
}

.child-program-choice:hover,
.child-program-choice:focus-visible {
  border-color: rgba(255, 221, 139, 0.7);
  background: rgba(40, 39, 31, 0.72);
}

.child-program-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.55rem;
}

.child-program-actions .button-primary {
  color: #101b26;
  background: linear-gradient(135deg, #ffe29a, #dca63d);
  box-shadow: 0 0.8rem 2.5rem rgba(218, 159, 49, 0.25);
}

.child-program-actions .button-secondary,
.child-program-actions .text-button {
  color: #fff8e8;
}

.child-program-elvi {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  padding: 1rem;
  border: 1px solid rgba(255, 238, 197, 0.16);
  border-radius: 1.25rem;
  background: rgba(3, 12, 22, 0.5);
  backdrop-filter: blur(18px);
}

.child-program-elvi > span {
  display: grid;
  flex: 0 0 2.35rem;
  width: 2.35rem;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  color: #17212a;
  background: #f2c65f;
  box-shadow: 0 0 1.2rem rgba(242, 198, 95, 0.48);
}

.child-program-elvi strong,
.child-program-elvi p { margin: 0; }
.child-program-elvi p { margin-top: 0.3rem; color: rgba(255, 248, 232, 0.78); line-height: 1.45; }

.child-program-workspace[data-experience="fictional-harbour"] .child-program-world img {
  filter: saturate(0.82) contrast(1.08) brightness(0.64) hue-rotate(8deg);
  transform: scale(1.05);
}

.child-program-workspace[data-experience="fictional-harbour"] .child-program-stage {
  grid-template-columns: minmax(0, 48rem) minmax(13rem, 20rem);
}

.fictional-harbour-field {
  position: relative;
  width: min(100%, 44rem);
  min-height: clamp(15rem, 31vh, 22rem);
  margin-top: 1.3rem;
  overflow: hidden;
  border: 1px solid rgba(255, 224, 143, 0.18);
  border-radius: 1.5rem;
  background:
    radial-gradient(circle at 50% 52%, rgba(244, 192, 78, 0.16), transparent 28%),
    linear-gradient(145deg, rgba(5, 17, 27, 0.38), rgba(5, 17, 27, 0.78));
  box-shadow: inset 0 0 4rem rgba(3, 12, 22, 0.35), 0 1.4rem 4rem rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(8px);
}

.fictional-harbour-field::before,
.fictional-harbour-field::after {
  content: "";
  position: absolute;
  inset: 18% 28%;
  border: 1px solid rgba(255, 220, 132, 0.16);
  border-radius: 50%;
  pointer-events: none;
}

.fictional-harbour-field::after {
  inset: 33% 40%;
  border-color: rgba(255, 220, 132, 0.28);
  box-shadow: 0 0 3rem rgba(238, 179, 61, 0.14);
}

.fictional-harbour-marker {
  position: absolute;
  display: grid;
  width: auto;
  min-width: 9.5rem;
  min-height: 52px;
  max-width: 13rem;
  place-items: center;
  padding: 0.75rem 1rem 0.75rem 2.7rem;
  border: 1px solid rgba(255, 229, 160, 0.34);
  border-radius: 999px;
  color: #fff8e8;
  text-align: left;
  background: rgba(3, 12, 22, 0.76);
  box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(16px);
}

.fictional-harbour-marker::before {
  content: "";
  position: absolute;
  left: 0.85rem;
  width: 1.15rem;
  aspect-ratio: 1;
  border: 2px solid #ffe29a;
  border-radius: 50%;
  background: #d8a43e;
  box-shadow: 0 0 0 0.45rem rgba(242, 198, 95, 0.1), 0 0 1.4rem rgba(242, 198, 95, 0.66);
}

.fictional-harbour-marker[data-marker-index="1"] { top: 12%; left: 7%; }
.fictional-harbour-marker[data-marker-index="2"] { top: 58%; left: 35%; }
.fictional-harbour-marker[data-marker-index="3"] { top: 22%; right: 6%; }

.fictional-harbour-marker:hover,
.fictional-harbour-marker:focus-visible {
  border-color: #f4c967;
  transform: translateY(-2px);
}

.fictional-harbour-marker[aria-pressed="true"] {
  border-color: rgba(174, 222, 197, 0.72);
  color: #e7fff2;
  background: rgba(18, 55, 49, 0.76);
  opacity: 1;
}

.fictional-harbour-marker[aria-pressed="true"]::before {
  border-color: #dffff0;
  background: #6bb89b;
  box-shadow: 0 0 0 0.45rem rgba(107, 184, 155, 0.12), 0 0 1.4rem rgba(107, 184, 155, 0.66);
}

.child-program-rights {
  position: absolute;
  right: clamp(1.25rem, 3.4vw, 3.5rem);
  bottom: 1rem;
  left: clamp(1.25rem, 3.4vw, 3.5rem);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  color: rgba(255, 248, 232, 0.62);
  font-size: 0.78rem;
}

.child-program-rights p { margin: 0; }
.child-program-rights .text-button { color: rgba(255, 248, 232, 0.8); }

@media (max-width: 899px) {
  .child-program-header {
    grid-template-columns: 1fr auto;
  }
  .child-program-lanterns {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-content: flex-start;
  }
  .child-program-stage {
    grid-template-columns: 1fr;
    align-content: end;
  }
  .child-program-elvi {
    max-width: 34rem;
  }
  .child-program-workspace[data-experience="fictional-harbour"] .child-program-stage {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 599px) {
  .child-program-workspace {
    min-height: 100dvh;
  }
  .child-program-world img {
    object-position: 67% center;
  }
  .child-program-world::after {
    background:
      linear-gradient(0deg, rgba(3, 12, 22, 0.96) 0%, rgba(3, 12, 22, 0.72) 56%, rgba(3, 12, 22, 0.18) 100%),
      linear-gradient(90deg, rgba(3, 12, 22, 0.38), transparent);
  }
  .child-program-header {
    padding: max(1rem, env(safe-area-inset-top)) 1rem 0.85rem;
  }
  .child-program-location {
    max-width: 18ch;
  }
  .child-program-close {
    width: 44px;
    height: 44px;
    min-height: 44px;
    max-height: 44px;
    align-self: start;
    padding: 0;
    overflow: hidden;
    color: transparent;
  }
  .child-program-close::before {
    content: "×";
    display: grid;
    height: 100%;
    place-items: center;
    color: #fff8e8;
    font-size: 1.5rem;
  }
  .child-program-stage {
    min-height: calc(100dvh - 8.8rem);
    padding: 3.5rem 1rem calc(6rem + env(safe-area-inset-bottom));
  }
  .child-program-copy h1 {
    max-width: 10.5ch;
    font-size: clamp(2.25rem, 11.4vw, 3.15rem);
  }
  .child-program-body {
    font-size: 1rem;
  }
  .child-program-choice {
    background: rgba(3, 12, 22, 0.72);
  }
  .child-program-elvi {
    padding: 0.85rem;
  }
  .fictional-harbour-field {
    min-height: 17rem;
    border-radius: 1.15rem;
  }
  .fictional-harbour-marker {
    min-width: 0;
    max-width: 10.8rem;
    padding: 0.7rem 0.8rem 0.7rem 2.45rem;
    font-size: 0.84rem;
  }
  .fictional-harbour-marker[data-marker-index="1"] { top: 8%; left: 4%; }
  .fictional-harbour-marker[data-marker-index="2"] { top: 65%; left: 18%; }
  .fictional-harbour-marker[data-marker-index="3"] { top: 30%; right: 3%; }
  .child-program-workspace[data-harbour-outcome*="pause-and-compare"] .harbour-clock-ring {
    top: 16%;
    right: -25%;
    width: 92vw;
    opacity: 0.72;
  }
  .child-program-workspace[data-harbour-outcome*="signal-and-wait"] .harbour-beacon-west {
    top: 23%;
    right: 58%;
  }
  .child-program-workspace[data-harbour-outcome*="signal-and-wait"] .harbour-beacon-east {
    top: 37%;
    right: 17%;
  }
  .child-program-workspace[data-harbour-outcome*="map-alternate-route"] .harbour-route-line {
    right: -12%;
    bottom: 40%;
    width: 92%;
    height: 18%;
  }
  .child-program-rights {
    right: 1rem;
    bottom: calc(0.65rem + env(safe-area-inset-bottom));
    left: 1rem;
  }
  .child-program-rights p {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .child-program-atmosphere span {
    animation: none;
  }
  .fictional-harbour-response {
    transition: none;
  }
  .fictional-harbour-response > span {
    animation: none !important;
  }
  .child-program-world img {
    transform: none;
    transition: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .route-surface:not([hidden]) {
    animation-duration: 80ms;
    transform: none;
  }

  .breath-orbit span {
    transition: opacity 80ms linear;
  }

  .practice-canvas.is-active .breath-orbit span {
    opacity: 0.72;
    transform: scale(0.76);
  }
}

@media (min-width: 2000px) {
  .app-main {
    padding-inline: max(24px, calc((100vw - 1920px) / 2));
  }
}

/* ELUNAVI Practice · adult editorial application shell */
body[data-mode="adult"][data-route="adultPractice"] {
  --adult-ink: #202626;
  --adult-muted: #68706d;
  --adult-paper: #f2eee5;
  --adult-sheet: #fffdf8;
  --adult-line: rgba(32, 38, 38, 0.15);
  --adult-accent: #87503f;
  --adult-accent-soft: #eadbd3;
  --adult-moss: #4e665b;
  --adult-night: #182321;
  color: var(--adult-ink);
  background: var(--adult-night);
}

body[data-mode="adult"][data-route="adultPractice"] .site-header.app-header,
body[data-mode="adult"][data-route="adultPractice"] .primary-rail,
body[data-mode="adult"][data-route="adultPractice"] .context-rail {
  background-color: var(--adult-night);
}

body[data-mode="adult"][data-route="adultPractice"] .brand-compass {
  stroke: #d9c5a0;
}

body[data-mode="adult"][data-route="adultPractice"] .app-main {
  background: var(--adult-paper);
}

.adult-practice-workspace {
  min-height: calc(100svh - var(--shell-header) - var(--shell-dock));
  padding: clamp(28px, 5vw, 68px) var(--shell-gutter) 112px;
  color: var(--adult-ink, var(--ink));
  background:
    linear-gradient(90deg, rgba(32, 38, 38, 0.035) 1px, transparent 1px),
    var(--adult-paper, var(--paper-cool));
  background-size: 42px 42px;
}

.adult-practice-hero {
  max-width: 1260px;
  display: grid;
  gap: 24px;
  margin: 0 auto 32px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--adult-line, var(--line));
}

.adult-practice-hero h1 {
  max-width: 15ch;
  margin: 6px 0 14px;
  color: var(--adult-ink, var(--ink));
  font-family: ui-serif, Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 9vw, 74px);
  font-weight: 560;
  letter-spacing: -0.035em;
  line-height: 0.98;
}

.adult-practice-hero > div:first-child > p:last-child {
  max-width: 64ch;
  margin: 0;
  color: var(--adult-muted, var(--ink-soft));
}

.adult-practice-hero .eyebrow,
.adult-practice-workspace .eyebrow {
  color: var(--adult-accent, #87503f);
}

.adult-session-state {
  align-self: end;
  padding: 18px 20px;
  color: var(--adult-sheet, var(--ivory));
  background: var(--adult-night, var(--night));
  border-radius: 3px 20px 3px 20px;
}

.adult-session-state span,
.adult-session-state strong,
.adult-session-state small {
  display: block;
}

.adult-session-state span {
  color: rgba(255, 253, 248, 0.62);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.adult-session-state strong {
  margin-top: 5px;
  font-family: ui-serif, Georgia, serif;
  font-size: 24px;
  font-weight: 600;
}

.adult-session-state small {
  margin-top: 8px;
  color: rgba(255, 253, 248, 0.7);
  line-height: 1.45;
}

.adult-day-nav {
  max-width: 1260px;
  display: flex;
  gap: 8px;
  margin: 0 auto 24px;
  padding: 2px 2px 12px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
}

.adult-day-tab {
  width: min(238px, 72vw);
  min-width: min(238px, 72vw);
  min-height: 92px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 14px;
  color: var(--adult-ink);
  background: rgba(255, 253, 248, 0.68);
  border: 1px solid var(--adult-line);
  border-radius: 12px;
  cursor: pointer;
  scroll-snap-align: start;
  text-align: left;
}

.adult-day-tab > span:first-child {
  color: var(--adult-accent);
  font-family: ui-serif, Georgia, serif;
  font-size: 22px;
  line-height: 1;
}

.adult-day-tab strong,
.adult-day-tab small {
  display: block;
}

.adult-day-tab strong {
  font-size: 13px;
  line-height: 1.3;
  overflow-wrap: anywhere;
  white-space: normal;
}

.adult-day-tab small {
  margin-top: 5px;
  color: var(--adult-muted);
  font-size: 10px;
  line-height: 1.25;
}

.adult-day-tab[data-state="preview"] {
  background: transparent;
  border-style: dashed;
}

.adult-day-tab[data-state="completed"] {
  border-color: rgba(78, 102, 91, 0.34);
}

.adult-day-tab.is-current {
  background: var(--adult-sheet);
  border-color: var(--adult-accent);
  box-shadow: 0 10px 32px rgba(44, 35, 30, 0.09);
}

.adult-practice-layout {
  max-width: 1260px;
  display: grid;
  gap: 20px;
  margin: 0 auto;
}

.adult-session-card,
.adult-method-card,
.adult-source-card,
.adult-field-tool {
  background: var(--adult-sheet, var(--paper-warm));
  border: 1px solid var(--adult-line, var(--line));
  box-shadow: 0 18px 50px rgba(44, 35, 30, 0.07);
}

.adult-session-card {
  min-width: 0;
  padding: clamp(24px, 5vw, 54px);
  border-radius: 4px 28px 4px 28px;
}

.adult-session-heading {
  margin-bottom: 34px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--adult-line);
}

.adult-session-meta,
.adult-block-meta,
.adult-result-label,
.adult-source-meta {
  margin: 0 0 8px;
  color: var(--adult-accent);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.13em;
  line-height: 1.4;
  text-transform: uppercase;
}

.adult-session-heading h2 {
  max-width: 20ch;
  margin: 0;
  color: var(--adult-ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(36px, 7vw, 58px);
  font-weight: 560;
  letter-spacing: -0.025em;
  line-height: 1.02;
}

.adult-session-heading > p:last-child {
  max-width: 70ch;
  margin: 15px 0 0;
  color: var(--adult-muted);
}

.adult-session-blocks {
  display: grid;
  gap: 16px;
}

.adult-content-block {
  padding: 20px 0;
  border-bottom: 1px solid var(--adult-line);
}

.adult-content-block:first-child {
  padding-top: 0;
}

.adult-content-block[data-kind="case-file"],
.adult-content-block[data-kind="delayed-case"],
.adult-content-block[data-kind="repair-rehearsal"] {
  margin-inline: -14px;
  padding: 22px 18px;
  background: #eee8dc;
  border: 0;
  border-left: 3px solid var(--adult-accent);
}

.adult-content-block[data-kind="scope-limit"] {
  color: var(--adult-muted);
  font-size: 14px;
}

.adult-content-block h3 {
  margin: 0 0 10px;
  color: var(--adult-ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(24px, 4vw, 34px);
  font-weight: 600;
  line-height: 1.12;
}

.adult-content-block p:not(.adult-block-meta) {
  max-width: 74ch;
  margin: 8px 0 0;
  color: #3f4744;
}

.adult-session-form {
  margin-top: 30px;
  padding-top: 28px;
  border-top: 2px solid var(--adult-ink);
}

.adult-response-fieldset,
.adult-factor-fieldset,
.adult-branch-fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.adult-response-fieldset > legend,
.adult-factor-fieldset > legend,
.adult-branch-fieldset > legend {
  max-width: 72ch;
  margin-bottom: 20px;
  color: var(--adult-ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(23px, 4vw, 31px);
  font-weight: 600;
  line-height: 1.2;
}

.adult-response-field {
  display: grid;
  gap: 7px;
  margin-top: 15px;
}

.adult-response-field > span,
.adult-private-branch > strong {
  color: var(--adult-ink);
  font-size: 13px;
  font-weight: 850;
}

.adult-response-field textarea,
.adult-private-branch textarea {
  width: 100%;
  min-height: 92px;
  resize: vertical;
  padding: 14px 15px;
  color: var(--adult-ink);
  background: #fbf8f1;
  border: 1px solid rgba(32, 38, 38, 0.26);
  border-radius: 9px;
  line-height: 1.5;
}

.adult-response-field textarea:focus,
.adult-private-branch textarea:focus {
  border-color: var(--adult-accent);
  box-shadow: 0 0 0 3px rgba(135, 80, 63, 0.12);
}

.adult-draft-note {
  margin: 18px 0 0;
  padding: 12px 14px;
  color: var(--adult-muted);
  background: rgba(78, 102, 91, 0.08);
  border-left: 3px solid var(--adult-moss);
  font-size: 13px;
  line-height: 1.45;
}

.adult-factor-fieldset,
.adult-branch-fieldset {
  display: grid;
  gap: 9px;
}

.adult-factor-fieldset > label,
.adult-branch-choice {
  min-height: 52px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 14px;
  background: #fbf8f1;
  border: 1px solid var(--adult-line);
  border-radius: 9px;
  cursor: pointer;
}

.adult-factor-fieldset input,
.adult-branch-choice input {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  margin: 2px 0 0;
  accent-color: var(--adult-accent);
}

.adult-private-branch {
  margin-top: 10px;
  padding: 18px;
  background: rgba(78, 102, 91, 0.08);
  border: 1px solid rgba(78, 102, 91, 0.22);
  border-radius: 10px;
}

.adult-private-branch p {
  color: var(--adult-muted);
  font-size: 14px;
}

.adult-private-branch textarea {
  min-height: 180px;
}

.adult-session-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 26px;
}

.adult-primary-action {
  min-width: min(100%, 280px);
  background: var(--adult-accent);
  border-color: var(--adult-accent);
  box-shadow: none;
}

.adult-primary-action:hover:not(:disabled) {
  background: #6e3f32;
  border-color: #6e3f32;
}

.adult-assessment-result {
  margin-top: 24px;
  padding: 22px;
  background: #edf0ec;
  border: 1px solid rgba(78, 102, 91, 0.25);
  border-radius: 4px 18px 4px 18px;
}

.adult-assessment-result h3 {
  margin: 0 0 8px;
  color: var(--adult-ink);
  font-size: 24px;
}

.adult-assessment-result p,
.adult-assessment-result li {
  color: #46504c;
  font-size: 14px;
}

.adult-assessment-result ul {
  margin-bottom: 0;
  padding-left: 20px;
}

.adult-practice-sidebar {
  display: grid;
  align-content: start;
  gap: 14px;
}

.adult-method-card,
.adult-source-card {
  padding: 22px;
  border-radius: 4px 18px 4px 18px;
}

.adult-method-card h2 {
  margin: 5px 0 10px;
  color: var(--adult-ink);
  font-family: ui-serif, Georgia, serif;
  font-size: 25px;
  font-weight: 600;
  line-height: 1.08;
}

.adult-method-card p:last-child {
  margin-bottom: 0;
  color: var(--adult-muted);
  font-size: 14px;
}

.adult-source-card summary {
  min-height: 44px;
  color: var(--adult-ink);
  cursor: pointer;
  font-weight: 850;
}

.adult-source-card summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
}

.adult-source-card article {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--adult-line);
}

.adult-source-card p,
.adult-source-card li {
  color: var(--adult-muted);
  font-size: 12px;
  line-height: 1.55;
}

.adult-source-disclosure {
  color: var(--adult-ink) !important;
  font-weight: 750;
}

.adult-field-tool {
  max-width: 1260px;
  margin: 28px auto 0;
  padding: clamp(24px, 4vw, 42px);
  border-radius: 4px 26px 4px 26px;
}

.adult-field-tool > header {
  display: grid;
  gap: 18px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--adult-line);
}

.adult-field-tool h2 {
  margin: 5px 0 8px;
  color: var(--adult-ink);
  font-family: ui-serif, Georgia, serif;
  font-size: clamp(30px, 5vw, 46px);
  font-weight: 560;
  line-height: 1;
}

.adult-field-tool header p:last-child {
  margin: 0;
  color: var(--adult-muted);
}

.adult-field-tool ol {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.adult-field-tool li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--adult-line);
}

.adult-field-tool li > span:first-child {
  color: var(--adult-accent);
  font-family: ui-serif, Georgia, serif;
  font-size: 22px;
}

.adult-field-tool li strong,
.adult-field-tool li span span {
  display: block;
}

.adult-field-tool li strong {
  color: var(--adult-ink);
}

.adult-field-tool li span span {
  margin-top: 4px;
  color: var(--adult-muted);
  font-size: 14px;
}

.adult-safety-override {
  margin: 22px 0 0;
  padding: 16px;
  color: #493a34;
  background: var(--adult-accent-soft);
  border-left: 3px solid var(--adult-accent);
  font-size: 14px;
}

.adult-data-controls {
  max-width: 1260px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 18px auto 0;
  color: var(--adult-muted);
  font-size: 12px;
}

.adult-data-controls p {
  max-width: 72ch;
  margin: 0;
}

.adult-data-controls .text-button {
  flex: 0 0 auto;
}

.adult-mobile-dock {
  position: fixed;
  z-index: 45;
  inset: auto 0 0;
  min-height: calc(var(--shell-dock) + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 7px max(8px, env(safe-area-inset-right)) env(safe-area-inset-bottom)
    max(8px, env(safe-area-inset-left));
  background: rgba(24, 35, 33, 0.97);
  border-top: 1px solid rgba(255, 253, 248, 0.14);
  box-shadow: 0 -14px 40px rgba(0, 0, 0, 0.2);
}

.adult-mobile-dock a,
.adult-mobile-dock button {
  min-width: 0;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 3px;
  padding: 5px;
  color: rgba(255, 253, 248, 0.68);
  background: transparent;
  border: 0;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.2;
  text-decoration: none;
}

.adult-mobile-dock svg,
.adult-primary-nav svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.65;
}

.adult-mobile-dock [data-route="adultPractice"] {
  color: #e7cfaa;
  background: rgba(231, 207, 170, 0.09);
}

.adult-primary-nav {
  display: grid;
  gap: 6px;
}

.adult-primary-nav .adult-rail-action {
  width: 100%;
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 10px 13px;
  color: rgba(255, 253, 248, 0.68);
  background: transparent;
  border: 1px solid transparent;
  border-radius: 14px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 750;
  text-align: left;
}

@media (max-width: 599px) {
  body[data-mode="adult"][data-route="adultPractice"] .site-header.app-header {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .adult-practice-workspace {
    padding-top: 32px;
  }

  .adult-practice-hero h1 {
    font-size: clamp(40px, 13vw, 57px);
  }

  .adult-session-card {
    padding: 22px 18px 28px;
  }

  .adult-session-actions,
  .adult-data-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .adult-session-actions .button,
  .adult-data-controls .text-button {
    width: 100%;
  }
}

@media (min-width: 600px) {
  .adult-practice-hero {
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.42fr);
    align-items: end;
  }

  .adult-field-tool > header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
  }

  .adult-field-tool ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
  }
}

@media (min-width: 600px) and (max-width: 1279px) {
  .adult-mobile-dock {
    inset: auto 20px max(10px, env(safe-area-inset-bottom));
    border: 1px solid rgba(255, 253, 248, 0.14);
    border-radius: 18px;
  }

  .adult-practice-workspace {
    min-height: calc(100svh - var(--shell-header));
    padding-bottom: 128px;
  }
}

@media (min-width: 1280px) {
  .adult-mobile-dock {
    display: none;
  }

  .adult-practice-workspace {
    min-height: 100%;
    padding: 44px;
    border: 1px solid rgba(32, 38, 38, 0.1);
    border-radius: 24px;
    box-shadow: 0 18px 60px rgba(28, 35, 32, 0.08);
  }

  .adult-practice-layout {
    grid-template-columns: minmax(0, 1fr) 310px;
    align-items: start;
  }

  .adult-day-tab {
    min-width: 190px;
  }
}

@media (min-width: 1500px) {
  .adult-practice-workspace {
    padding-inline: 52px;
  }
}

@media (prefers-contrast: more) {
  .adult-session-card,
  .adult-method-card,
  .adult-source-card,
  .adult-field-tool,
  .adult-day-tab,
  .adult-response-field textarea {
    border-width: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .adult-day-nav {
    scroll-behavior: auto;
  }
}

@media print {
  body[data-mode="adult"][data-route="adultPractice"] {
    overflow: visible;
    background: white;
  }

  body[data-mode="adult"][data-route="adultPractice"] .site-header,
  body[data-mode="adult"][data-route="adultPractice"] .primary-rail,
  body[data-mode="adult"][data-route="adultPractice"] .context-rail,
  body[data-mode="adult"][data-route="adultPractice"] .adult-practice-hero,
  body[data-mode="adult"][data-route="adultPractice"] .adult-day-nav,
  body[data-mode="adult"][data-route="adultPractice"] .adult-practice-layout,
  body[data-mode="adult"][data-route="adultPractice"] .adult-data-controls,
  body[data-mode="adult"][data-route="adultPractice"] .adult-mobile-dock,
  body[data-mode="adult"][data-route="adultPractice"] .app-footer,
  body[data-mode="adult"][data-route="adultPractice"] .adult-field-tool button {
    display: none !important;
  }

  body[data-mode="adult"][data-route="adultPractice"] .product-shell,
  body[data-mode="adult"][data-route="adultPractice"] .app-main,
  body[data-mode="adult"][data-route="adultPractice"] .adult-practice-workspace {
    display: block;
    height: auto;
    min-height: 0;
    padding: 0;
    overflow: visible;
    background: white;
    border: 0;
    box-shadow: none;
  }

  .adult-field-tool {
    margin: 0;
    padding: 16mm;
    border: 0;
    box-shadow: none;
    page-break-inside: avoid;
  }

  .adult-field-tool ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 599px) {
  body[data-visual-preview="world-first"][data-route="today"] .landing {
    min-height: 0;
    justify-content: flex-end;
    padding: 58svh 16px 230px;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-media img {
    object-position: center center;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1 {
    max-width: 14ch;
    margin-bottom: 12px;
    font-size: clamp(35px, 9.5vw, 46px);
    line-height: 1;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy .eyebrow,
  body[data-visual-preview="world-first"][data-route="today"] .hero-lead {
    display: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-actions {
    margin-top: 12px;
  }

  body[data-visual-preview="world-first"][data-route="today"] .duration,
  body[data-visual-preview="world-first"][data-route="today"] .today-card .status-chip {
    display: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .today-card {
    margin-bottom: calc(var(--shell-dock) + env(safe-area-inset-bottom) + 12px);
  }
}

/* AGE-002 · distinct teen runtime surfaces on the shared tact seed. */
.young-journey-workspace {
  position: relative;
  min-height: calc(100svh - var(--shell-header));
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 16px;
  padding: clamp(250px, 47svh, 440px) var(--shell-gutter)
    calc(var(--shell-dock) + env(safe-area-inset-bottom) + 30px);
  overflow: hidden;
  isolation: isolate;
  color: #fff8e9;
  background: #071521;
}

.young-world-stage {
  position: absolute;
  z-index: -2;
  inset: 0;
}

.young-world-stage::after {
  position: absolute;
  content: "";
  inset: 0;
  background: linear-gradient(180deg, rgba(3, 12, 20, 0.08) 0%, rgba(3, 12, 20, 0.24) 38%, rgba(3, 12, 20, 0.94) 78%, #071521 100%);
}

.young-world-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 67% center;
  filter: saturate(0.9) brightness(0.93);
}

.young-journey-hero,
.young-journey-play,
.young-rights {
  position: relative;
  z-index: 1;
}

.young-journey-hero {
  max-width: 680px;
}

.young-journey-hero .eyebrow,
.young-elvi-question .eyebrow {
  color: #f0cf84;
}

.young-journey-hero h1 {
  max-width: 13ch;
  margin: 7px 0 10px;
  color: #fff8e9;
  font-family: var(--font-story, ui-serif, Georgia, serif);
  font-size: clamp(36px, 9vw, 62px);
  font-weight: 560;
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.72);
}

.young-journey-hero > p:not(.eyebrow) {
  max-width: 62ch;
  margin: 0;
  color: rgba(255, 248, 233, 0.82);
  font-size: clamp(16px, 2.3vw, 19px);
  line-height: 1.55;
}

.young-journey-hero > span {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  margin-top: 12px;
  padding: 5px 10px;
  color: rgba(255, 248, 233, 0.78);
  background: rgba(7, 21, 33, 0.5);
  border: 1px solid rgba(255, 248, 233, 0.18);
  border-radius: 999px;
}

.young-journey-play {
  display: grid;
  gap: 12px;
}

.young-elvi-question,
.young-choice-sheet,
.young-rights {
  background: rgba(8, 27, 40, 0.9);
  border: 1px solid rgba(255, 248, 233, 0.18);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.3);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.young-elvi-question {
  padding: 16px 18px;
  border-radius: 20px;
}

.young-elvi-question p {
  margin: 0;
}

.young-elvi-question p:last-child {
  margin-top: 5px;
  color: rgba(255, 248, 233, 0.82);
  font-size: 16px;
  line-height: 1.45;
}

.young-choice-sheet {
  padding: 18px;
  border-radius: 24px;
}

.young-choice-sheet fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.young-choice-sheet legend {
  margin-bottom: 12px;
  color: #fff8e9;
  font-family: var(--font-story, ui-serif, Georgia, serif);
  font-size: clamp(22px, 4vw, 30px);
}

.young-choice {
  min-height: 54px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 13px 14px;
  color: #fff8e9;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  cursor: pointer;
  line-height: 1.35;
}

.young-choice + .young-choice {
  margin-top: 9px;
}

.young-choice:has(input:checked) {
  background: rgba(240, 207, 132, 0.12);
  border-color: rgba(240, 207, 132, 0.58);
}

.young-choice input {
  width: 22px;
  height: 22px;
  accent-color: #f0cf84;
}

.young-choice:focus-within {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.young-result {
  margin-top: 14px;
  padding: 15px;
  color: #fff8e9;
  background: rgba(240, 207, 132, 0.09);
  border-left: 3px solid #f0cf84;
  border-radius: 0 14px 14px 0;
  line-height: 1.5;
}

.young-result strong,
.young-result span {
  display: block;
}

.young-result span {
  margin-top: 6px;
  color: rgba(255, 248, 233, 0.76);
}

.young-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 16px;
}

.young-actions .button,
.young-actions .text-button {
  min-height: 48px;
}

.young-actions .text-button {
  color: rgba(255, 248, 233, 0.72);
}

.young-rights {
  padding: 14px 17px;
  color: rgba(255, 248, 233, 0.7);
  border-radius: 18px;
  font-size: 13px;
}

.young-rights > p {
  margin: 0;
}

.young-rights summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  color: #f0cf84;
  cursor: pointer;
  font-weight: 760;
}

.young-rights ul {
  padding-left: 20px;
  line-height: 1.5;
}

.young-mobile-dock {
  color: rgba(255, 248, 233, 0.76);
}

.young-mobile-dock[hidden] {
  display: none;
}

@media (min-width: 820px) {
  .young-journey-play {
    grid-template-columns: minmax(240px, 0.55fr) minmax(430px, 1.45fr);
    align-items: start;
  }
}

@media (min-width: 1280px) {
  .young-journey-workspace {
    min-height: 100%;
    padding: clamp(260px, 37vh, 360px) clamp(28px, 3vw, 48px) 48px;
    border-radius: 26px;
  }

  .young-mobile-dock {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .young-journey-workspace,
  .young-choice,
  .young-result {
    animation: none !important;
    transition: none !important;
  }
}

.age-mode-badge {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  color: var(--gold-bright);
  background: rgba(240, 207, 132, 0.1);
  border: 1px solid rgba(240, 207, 132, 0.24);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 780;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.age-mode-badge[hidden] {
  display: none;
}

body[data-mode="teen"] {
  --teen-night: #071521;
  --teen-raised: rgba(10, 29, 43, 0.9);
  --teen-line: rgba(255, 248, 228, 0.18);
  --teen-gold: #f0cf84;
  --teen-ivory: #fff8e9;
  --teen-muted: rgba(255, 248, 233, 0.7);
}

body[data-mode="teen"] .app-main {
  color: var(--teen-ivory);
  background: var(--teen-night);
}

.teen-studio-workspace,
.teen-academy-workspace {
  position: relative;
  min-height: calc(100svh - var(--shell-header));
  padding: clamp(250px, 44svh, 430px) var(--shell-gutter)
    calc(var(--shell-dock) + env(safe-area-inset-bottom) + 34px);
  overflow: hidden;
  isolation: isolate;
  color: var(--teen-ivory);
  background: var(--teen-night);
}

.teen-world-stage {
  position: absolute;
  z-index: -2;
  inset: 0 0 auto;
  height: min(58svh, 570px);
  overflow: hidden;
}

.teen-world-stage::after {
  position: absolute;
  content: "";
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 14, 23, 0.08) 0%, rgba(5, 14, 23, 0.35) 54%, var(--teen-night) 100%),
    linear-gradient(90deg, rgba(5, 14, 23, 0.54), transparent 62%);
}

.teen-world-stage img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% center;
  filter: saturate(0.82) contrast(1.04);
}

.teen-academy-stage img {
  object-position: 72% center;
  filter: saturate(0.68) contrast(1.08) brightness(0.88);
}

.teen-hero {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: 0 0 20px;
  padding: 0;
}

.teen-hero .eyebrow {
  color: var(--teen-gold);
}

.teen-hero h1 {
  max-width: 18ch;
  margin: 7px 0 10px;
  overflow-wrap: anywhere;
  hyphens: auto;
  color: var(--teen-ivory);
  font-family: var(--font-story, ui-serif, Georgia, serif);
  font-size: clamp(34px, 8.6vw, 58px);
  font-weight: 560;
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.7);
}

.teen-hero > div > p:last-child {
  max-width: 64ch;
  margin: 0;
  color: var(--teen-muted);
  line-height: 1.55;
}

.teen-duration {
  display: inline-flex;
  margin-top: 13px;
  padding: 7px 10px;
  color: var(--teen-ivory);
  background: rgba(7, 21, 33, 0.56);
  border: 1px solid var(--teen-line);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 750;
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.teen-studio-layout,
.teen-academy-layout {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 16px;
}

.teen-case,
.teen-decision-bench,
.teen-elvi-note,
.teen-academy-method,
.teen-rights-strip {
  background: var(--teen-raised);
  border: 1px solid var(--teen-line);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.28);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.teen-case,
.teen-decision-bench,
.teen-academy-method {
  padding: clamp(18px, 3vw, 28px);
  border-radius: 24px;
}

.teen-case-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  color: var(--teen-muted);
  border-bottom: 1px solid var(--teen-line);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.teen-case-heading strong {
  color: var(--teen-gold);
  text-align: right;
}

.teen-case h2 {
  margin: 19px 0 9px;
  color: var(--teen-ivory);
  font-size: clamp(24px, 4.8vw, 34px);
}

.teen-case > p {
  max-width: 72ch;
  color: var(--teen-muted);
  line-height: 1.65;
}

.teen-known-grid {
  display: grid;
  gap: 13px;
  margin-top: 20px;
}

.teen-known-grid section {
  padding: 15px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
}

.teen-known-grid h3 {
  margin: 0 0 9px;
  color: var(--teen-gold);
  font-size: 13px;
}

.teen-known-grid ul,
.teen-rights-strip ul {
  margin: 0;
  padding-left: 20px;
  color: var(--teen-muted);
}

.teen-known-grid li + li,
.teen-rights-strip li + li {
  margin-top: 6px;
}

.teen-decision-bench fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.teen-decision-bench legend {
  margin-bottom: 14px;
  color: var(--teen-ivory);
  font-family: var(--font-story, ui-serif, Georgia, serif);
  font-size: clamp(22px, 4vw, 30px);
  line-height: 1.08;
}

.teen-choice {
  min-height: 52px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 14px;
  color: var(--teen-ivory);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 15px;
  cursor: pointer;
  line-height: 1.4;
}

.teen-choice + .teen-choice {
  margin-top: 9px;
}

.teen-choice:has(input:checked) {
  background: rgba(240, 207, 132, 0.1);
  border-color: rgba(240, 207, 132, 0.55);
}

.teen-choice input {
  width: 20px;
  height: 20px;
  accent-color: var(--teen-gold);
}

.teen-choice:focus-within {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.teen-result {
  margin-top: 16px;
  padding: 16px;
  color: var(--teen-ivory);
  background: rgba(240, 207, 132, 0.08);
  border-left: 3px solid var(--teen-gold);
  border-radius: 0 14px 14px 0;
  line-height: 1.55;
}

.teen-result strong,
.teen-result span {
  display: block;
}

.teen-result span {
  margin-top: 7px;
  color: var(--teen-muted);
}

.teen-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 18px;
}

.teen-actions .button {
  min-height: 48px;
}

.teen-actions .text-button {
  color: var(--teen-muted);
}

.teen-elvi-note {
  position: relative;
  padding: 18px 50px 18px 18px;
  border-radius: 20px;
}

.teen-elvi-note > button {
  position: absolute;
  inset: 10px 10px auto auto;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  padding: 0;
  overflow: clip;
  font-size: 18px;
  line-height: 1;
  color: var(--teen-muted);
  background: transparent;
  border: 1px solid var(--teen-line);
  border-radius: 50%;
  cursor: pointer;
}

.teen-elvi-note .eyebrow {
  color: var(--teen-gold);
}

.teen-elvi-note p:last-child {
  margin: 7px 0 0;
  color: var(--teen-muted);
  line-height: 1.5;
}

.teen-elvi-quiet {
  opacity: 0.88;
}

.teen-academy-method ol {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 22px;
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--teen-muted);
}

.teen-rights-strip {
  position: relative;
  z-index: 2;
  margin-top: 16px;
  padding: 16px 18px;
  border-radius: 18px;
  color: var(--teen-muted);
  font-size: 13px;
}

.teen-rights-strip > p {
  margin: 0;
}

.teen-rights-strip details {
  margin-top: 10px;
}

.teen-rights-strip summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  color: var(--teen-gold);
  cursor: pointer;
  font-weight: 760;
}

.teen-rights-strip details > p {
  margin: 12px 0 0;
  line-height: 1.55;
}

.teen-mobile-dock {
  position: fixed;
  z-index: 48;
  inset: auto max(10px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left));
  min-height: var(--shell-dock);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 6px;
  color: var(--teen-muted);
  background: rgba(5, 16, 27, 0.94);
  border: 1px solid var(--teen-line);
  border-radius: 22px;
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.42);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
}

.teen-mobile-dock[hidden] {
  display: none;
}

.teen-mobile-dock a,
.teen-mobile-dock button {
  min-width: 0;
  min-height: 58px;
  display: grid;
  place-items: center;
  gap: 2px;
  padding: 6px 2px;
  color: inherit;
  background: transparent;
  border: 0;
  border-radius: 16px;
  font-size: 10px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.teen-mobile-dock svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}

.teen-mobile-dock [aria-current="page"] {
  color: var(--teen-gold);
  background: rgba(240, 207, 132, 0.1);
}

/* At 200% browser text/zoom a 390 px phone exposes a roughly 195 px
   layout viewport. Keep the four safe exits operable without forcing
   their visible labels into 40 px columns; accessible names remain on
   the controls through their text and enclosing navigation context. */
@media (max-width: 260px) {
  .teen-mobile-dock {
    inset-inline: max(4px, env(safe-area-inset-left));
    padding: 4px;
    border-radius: 18px;
  }

  .teen-mobile-dock a,
  .teen-mobile-dock button {
    min-height: 52px;
    padding: 4px 0;
    overflow: clip;
  }

  .teen-mobile-dock span {
    display: none;
  }
}

@media (min-width: 700px) {
  .teen-known-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .teen-studio-workspace,
  .teen-academy-workspace {
    padding-top: clamp(310px, 48svh, 470px);
  }

  .teen-hero {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
  }
}

@media (min-width: 960px) {
  .teen-studio-layout {
    grid-template-columns: minmax(0, 1.2fr) minmax(340px, 0.8fr);
  }

  .teen-studio-layout .teen-elvi-note {
    grid-column: 2;
  }

  .teen-academy-layout {
    grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  }

  .teen-academy-layout .teen-case-file {
    grid-row: span 2;
  }
}

@media (min-width: 1280px) {
  .teen-studio-workspace,
  .teen-academy-workspace {
    min-height: 100%;
    padding: clamp(280px, 39vh, 380px) clamp(28px, 3vw, 48px) 48px;
    border-radius: 26px;
  }

  .teen-world-stage {
    height: min(51vh, 480px);
  }

  .teen-mobile-dock {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .teen-studio-workspace,
  .teen-academy-workspace,
  .teen-choice,
  .teen-result {
    animation: none !important;
    transition: none !important;
  }
}

@media (min-width: 600px) and (max-width: 1279px) and (orientation: portrait) {
  body[data-visual-preview="world-first"][data-route="today"] .landing {
    justify-content: flex-end;
    padding: 62svh 8vw 238px;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy {
    max-width: 540px;
    padding: 0;
    background: transparent;
    border: 0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1 {
    max-width: 13ch;
    margin-bottom: 12px;
    font-size: clamp(38px, 5.2vw, 48px);
    line-height: 0.98;
    color: var(--ivory);
    text-shadow: 0 2px 20px rgba(2, 10, 18, 0.78);
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy .eyebrow,
  body[data-visual-preview="world-first"][data-route="today"] .hero-lead {
    display: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-actions {
    max-width: 430px;
    margin-top: 12px;
  }

  body[data-visual-preview="world-first"][data-route="today"] .duration {
    display: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .today-card {
    margin-inline: 7vw;
  }
}

@media (min-width: 600px) and (max-width: 1279px) and (orientation: landscape) {
  body[data-visual-preview="world-first"][data-route="today"] .landing {
    justify-content: center;
    padding: 90px 4vw 130px 61vw;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy {
    max-width: 34vw;
    padding: 0;
    background: transparent;
    border: 0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1 {
    font-size: clamp(36px, 4.8vw, 58px);
  }

  body[data-visual-preview="world-first"][data-route="today"] .today-card {
    width: min(520px, 38vw);
    margin: 0 4vw 22px auto;
  }

  body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .hero-copy {
    width: 100%;
    max-width: none;
    transform: translateY(-32px);
  }

  body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .landing {
    padding-left: 58vw;
  }

  body[data-visual-preview="world-first"][data-route="today"][data-text-scale="200"] .hero-actions .button {
    width: 100%;
    gap: 6px;
    padding-inline: 12px;
  }
}

@media (min-width: 1280px) {
  body[data-visual-preview="world-first"][data-route="today"] .app-main {
    position: relative;
    min-height: 0;
    padding: 0;
    overflow: hidden;
    background: transparent;
  }

  body[data-visual-preview="world-first"][data-route="today"] .landing {
    min-height: 100%;
    padding: 64px 48px 210px;
    border-radius: 0;
    box-shadow: none;
  }

  body[data-visual-preview="world-first"][data-route="today"] .landing::before {
    background: linear-gradient(90deg, rgba(242, 229, 203, 0.1), transparent 48%);
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy {
    max-width: 500px;
  }

  body[data-visual-preview="world-first"][data-route="today"] .hero-copy h1 {
    font-size: clamp(48px, 3.8vw, 60px);
  }

  body[data-visual-preview="world-first"][data-route="today"] .today-card {
    width: min(560px, calc(100% - 96px));
    margin: 0 0 28px 48px;
    padding: 20px 22px;
  }
}
