/* ==========================================================================
   Helion product page (Views/Home/Helion.cshtml)
   The Helion app's own world inside the QNSET shell: app-icon night-ink,
   Argon paper, spectral amber, DM Serif Display wordmark, system serif text.
   Motion is transform/opacity (plus one clip-path fill), runs only on screen,
   and every animated element has a complete static state.
   ========================================================================== */

.he {
  /* night: the app icon's sky */
  --he-night-0: #0b0b10;
  --he-night-1: #14141f;
  --he-night-2: #1b1b29;
  --he-night-3: #29293c;
  --he-on-ink: #f2efe8;
  --he-on-ink-2: #b3ada2;
  --he-on-ink-3: #9a948a;
  --he-ink-line: rgba(242, 239, 232, 0.14);
  --he-gold: #d4a02a;
  --he-gold-hi: #e8b84a;

  /* day: the app's light-first palette */
  --he-argon: #fafaf7;
  --he-card: #ffffff;
  --he-membrane: #e8e4dd;
  --he-cal: #efece6;
  --he-cal-text: #5e5b55;
  --he-noble: #6b6862;
  --he-text: #3d3934;
  --he-nucleus: #1c1a17;
  --he-spectral: #b8860b;
  --he-block: #976c08;
  --he-deep: #8b6508;
  --he-diffuse: #f5edd8;
  --he-recovered: #2d9d5f;
  --he-recovered-text: #24784a;
  --he-strain: #c8443c;
  --he-strain-text: #a8352f;
  --he-strain-tint: #faeae9;
  --he-err-on-ink: #f28b82;
  --he-map: #f1ede4;

  --he-serif: ui-serif, "New York", Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, "Noto Serif", serif;
  --he-display: "DM Serif Display", ui-serif, Georgia, serif;

  --he-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --he-ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);

  font-family: var(--he-serif);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-kerning: normal;
}

/* The QNSET shell around this page: a near-black base instead of the grid,
   and a header dark enough to stay legible over the paper sections. */
body:has(.he) {
  background-color: #0b0b10;
  background-image: none;
}

body:has(.he) > header .navbar {
  background-color: rgba(11, 11, 16, 0.88);
}

body:has(.he) > .flex-grow > main {
  padding-bottom: 0;
}

.he *,
.he *::before,
.he *::after {
  box-sizing: border-box;
}

/* Zero-specificity resets, so every component class below wins. */
:where(.he) :where(p, h1, h2, h3, ol, ul, dl, dd, figure) {
  margin: 0;
}

:where(.he) :where(ol, ul) {
  list-style: none;
  padding: 0;
}

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

.he-sr,
.he-sr-input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.he-ic {
  width: 1em;
  height: 1em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.he-wrap {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 20px;
}

@media (min-width: 768px) {
  .he-wrap {
    padding-inline: 32px;
  }
}

/* ---------- type ---------- */

.he-h2 {
  font-family: var(--he-display);
  font-weight: 400;
  font-size: clamp(38px, 1.6rem + 3.4vw, 64px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
  margin-bottom: 22px;
}

.he-body {
  font-size: clamp(17px, 16px + 0.22vw, 19px);
  line-height: 1.62;
  max-width: 34em;
  text-wrap: pretty;
}

.he-label {
  font-size: 11.5px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--he-noble);
}

.he-cap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
  font-size: 13px;
  color: var(--he-on-ink-3);
}

.he-cap--paper {
  color: var(--he-noble);
}

/* ---------- controls ---------- */

.he-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 24px;
  border: 0;
  border-radius: 14px;
  font-family: var(--he-serif);
  font-size: 16.5px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s var(--he-ease-smooth), transform 0.25s var(--he-ease-out);
}

.he-btn:active {
  transform: scale(0.97);
}

.he-btn--gold {
  background: var(--he-gold);
  color: var(--he-night-2);
}

.he-btn--gold:hover {
  background: var(--he-gold-hi);
}

.he .he-btn:focus-visible {
  outline: 2px solid var(--he-gold-hi);
  outline-offset: 3px;
  border-radius: 14px;
}

.he-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-size: 16.5px;
  color: var(--he-on-ink);
  text-decoration: underline;
  text-decoration-color: rgba(242, 239, 232, 0.35);
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  transition: text-decoration-color 0.2s var(--he-ease-smooth);
}

.he-link:hover {
  text-decoration-color: var(--he-gold);
}

.he .he-link:focus-visible {
  outline: 2px solid var(--he-gold-hi);
  outline-offset: 4px;
  border-radius: 6px;
}

.he-link .he-ic {
  font-size: 15px;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.he-hero {
  position: relative;
  overflow: hidden;
  color: var(--he-on-ink);
  padding-block: clamp(44px, 7vw, 96px) clamp(72px, 9vw, 120px);
  background:
    radial-gradient(60% 55% at 50% 100%, rgba(212, 160, 42, 0.16), transparent 70%),
    radial-gradient(38% 48% at 80% 46%, rgba(212, 160, 42, 0.09), transparent 70%),
    linear-gradient(180deg, var(--he-night-0) 0%, var(--he-night-1) 34%, var(--he-night-2) 72%, #212133 100%);
}

.he-hero-grid {
  display: grid;
  gap: 56px;
  align-items: center;
}

@media (min-width: 1024px) {
  .he-hero-grid {
    grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
    gap: 48px;
  }
}

.he-h1 {
  margin: 0;
  font-weight: 400;
}

.he-wordmark {
  position: relative;
  display: inline-block;
  font-family: var(--he-display);
  font-size: clamp(64px, 2rem + 6.6vw, 96px);
  line-height: 1.12;
  letter-spacing: -0.015em;
}

.he-wordmark-base {
  color: rgba(242, 239, 232, 0.13);
}

/* The app's launch moment: amber rises through the letterforms, then
   settles into ink. */
.he-wordmark-fill {
  position: absolute;
  inset: 0;
  color: var(--he-on-ink);
  clip-path: inset(0 0 0 0);
  animation:
    he-fill 0.8s var(--he-ease-smooth) 0.2s both,
    he-settle 0.5s var(--he-ease-smooth) 1.15s both;
}

@keyframes he-fill {
  from { clip-path: inset(100% 0 0 0); }
  to { clip-path: inset(0 0 0 0); }
}

@keyframes he-settle {
  from { color: var(--he-gold); }
  to { color: var(--he-on-ink); }
}

/* helion.js holds the fill until DM Serif Display has loaded (1.5s at most),
   so the rise never plays on the fallback serif. */
.he-font-wait .he-wordmark-fill {
  animation-play-state: paused;
}

.he-hairline {
  display: block;
  width: 96px;
  height: 1px;
  margin: 14px 0 26px;
  background: var(--he-gold);
  opacity: 0.9;
  transform-origin: left center;
  animation: he-draw 0.5s var(--he-ease-out) 0.2s both;
}

@keyframes he-draw {
  from { transform: scaleX(0); opacity: 0; }
}

.he-h1-line {
  display: block;
  font-family: var(--he-display);
  font-size: clamp(36px, 1.2rem + 3.5vw, 58px);
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

.he-lede {
  margin-top: 26px;
  max-width: 33em;
  font-size: clamp(17px, 16px + 0.3vw, 19.5px);
  line-height: 1.6;
  color: var(--he-on-ink-2);
  text-wrap: pretty;
}

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

@media (max-width: 479px) {
  .he-actions .he-btn {
    width: 100%;
  }
}

.he-horizon {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 4%, rgba(212, 160, 42, 0.5) 30%, var(--he-gold-hi) 50%, rgba(212, 160, 42, 0.5) 70%, transparent 96%);
}

/* ---------- the phone: a realistic iPhone, staged in 3D ----------
   Layers, outside in: .he-stage (perspective) > .he-tilt (pointer and
   scroll, driven by helion.js) > .he-enter (fly-in) > .he-float (idle
   drift) > .he-phone (resting pose; turns to face you when Helion speaks).
   Nothing between them uses opacity, filter, clip-path or overflow, any of
   which would flatten the scene. */

.he-demo {
  --phone-w: 330px;
  --he-zoom: 1;
  justify-self: center;
  width: var(--phone-w);
  max-width: 100%;
}

/* The device scales as one object, UI included, so its proportions hold:
   it fits short laptop screens whole and sits comfortably on phones. */
@media (min-width: 1024px) and (max-height: 940px) {
  .he-demo { --he-zoom: 0.9; }
}

@media (min-width: 1024px) and (max-height: 800px) {
  .he-demo { --he-zoom: 0.8; }
}

@media (min-width: 1024px) and (max-height: 700px) {
  .he-demo { --he-zoom: 0.7; }
}

@media (max-width: 479px) {
  .he-demo { --he-zoom: 0.86; }
}

@media (max-width: 359px) {
  .he-demo { --he-zoom: 0.76; }
}

.he-stage {
  position: relative;
  padding: 10px 0 46px;
  zoom: var(--he-zoom);
  perspective: 1400px;
  perspective-origin: 50% 36%;
  animation: he-fade 0.9s var(--he-ease-smooth) 0.35s both;
}

@media (max-width: 1023px) {
  .he-stage {
    perspective: 1900px;
  }
}

.he-ground {
  position: absolute;
  left: 10%;
  right: 10%;
  bottom: 4px;
  height: 52px;
}

.he-ground i {
  display: block;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0));
  animation: he-ground 8s ease-in-out 2.1s infinite alternate;
  animation-play-state: paused;
}

@keyframes he-ground {
  to { transform: scaleX(0.86); opacity: 0.7; }
}

.he-tilt,
.he-enter,
.he-float,
.he-phone,
.he-face {
  transform-style: preserve-3d;
}

.he-tilt {
  will-change: transform;
}

.he-enter {
  animation: he-enter 1.8s var(--he-ease-out) 0.35s both;
}

@keyframes he-enter {
  from { transform: translate3d(40px, 120px, -340px) rotateX(40deg) rotateY(-48deg) rotateZ(12deg); }
}

/* Below the fold (phones), the fly-in waits until the phone scrolls in. */
.he-armed:not(.is-in) .he-stage,
.he-armed:not(.is-in) .he-enter {
  animation-play-state: paused;
}

.he-float {
  animation: he-float 8s ease-in-out 2.1s infinite alternate;
  animation-play-state: paused;
}

.he-demo.is-onscreen:not(.is-paused):not(.is-finished) .he-float,
.he-demo.is-onscreen:not(.is-paused):not(.is-finished) .he-ground i {
  animation-play-state: running;
}

@keyframes he-float {
  to { transform: translate3d(0, -12px, 0) rotateY(7deg) rotateX(-2.5deg); }
}

.he-phone {
  --r: 50px;
  --frame: 3px;
  --bezel: 5px;
  --inset: calc(var(--frame) + var(--bezel));
  --pose-x: 7deg;
  --pose-y: -18deg;
  --pose-z: 1.2deg;
  position: relative;
  width: var(--phone-w);
  margin-inline: auto;
  aspect-ratio: 71.5 / 150;
  transform: rotateX(var(--pose-x)) rotateY(var(--pose-y)) rotateZ(var(--pose-z));
  transition: transform 1.3s var(--he-ease-out);
}

/* Stacked under the copy, the phone faces you more squarely. */
@media (max-width: 1023px) {
  .he-phone {
    --pose-x: 5deg;
    --pose-y: -11deg;
    --pose-z: 0.8deg;
  }
}

/* When Helion has something to say, the phone turns to face you. */
.he-live.is-told {
  --pose-x: 2deg;
  --pose-y: -4deg;
  --pose-z: 0.3deg;
}

/* Body thickness: metal stacked behind the glass, darker toward the back. */
.he-slab {
  position: absolute;
  inset: 0;
  border-radius: var(--r);
}

.he-slab--1 { transform: translateZ(-6px); background: #8a8fa1; }
.he-slab--2 { transform: translateZ(-12px); background: #6b6f80; }
.he-slab--3 { transform: translateZ(-18px); background: #4d5060; }
.he-slab--back { transform: translateZ(-24px); background: #262830; }

/* Hardware: Action button and volume on the left; side button and Camera
   Control on the right, at mid-depth and standing proud of the frame. */
.he-hw {
  position: absolute;
  width: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, #3f4250, #a3a8ba 50%, #4a4d5b);
  transform: translateZ(-12px);
}

.he-hw--action { left: -3px; top: 16.5%; height: 4.4%; }
.he-hw--up { left: -3px; top: 23.5%; height: 7.8%; }
.he-hw--down { left: -3px; top: 33%; height: 7.8%; }
.he-hw--side { right: -3px; top: 25.5%; height: 12%; }

.he-hw--camera {
  right: -2.5px;
  top: 57%;
  height: 8.2%;
  background: linear-gradient(90deg, #22242c, #6a6f82 50%, #22242c);
}

/* The front: a machined frame band catching the light, the black glass
   border, then the display. */
.he-face {
  position: absolute;
  inset: 0;
  border-radius: var(--r);
  background: linear-gradient(135deg, #c3c7d6 0%, #5f6374 16%, #2b2d38 42%, #3b3e4b 70%, #b7bccc 100%);
  box-shadow: inset 0 0 0 0.75px rgba(255, 255, 255, 0.45);
}

.he-face::before {
  content: "";
  position: absolute;
  inset: var(--frame);
  border-radius: calc(var(--r) - var(--frame));
  background: #030304;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.he-screen {
  position: absolute;
  inset: var(--inset);
  overflow: hidden;
  padding: 46px 16px 0;
  border-radius: calc(var(--r) - var(--inset));
  background: var(--he-argon);
  color: var(--he-nucleus);
  transform: translateZ(0.4px);
}

.he-island {
  position: absolute;
  top: 10px;
  left: 50%;
  width: 31%;
  height: 28px;
  border-radius: 999px;
  background: #050506;
  transform: translateX(-50%);
}

.he-island::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 10px;
  width: 9px;
  height: 9px;
  margin-top: -4.5px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #3c4a6c 0%, #111624 55%, #07090f 100%);
}

.he-statusbar {
  position: absolute;
  top: 17px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 24px 0 32px;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}

.he-status-icons {
  display: flex;
  align-items: center;
  gap: 5px;
}

.he-sb {
  display: block;
  height: 11px;
  fill: currentColor;
}

.he-sb--cell { width: 16.5px; }
.he-sb--wifi { width: 15.5px; }
.he-sb--batt { width: 25px; }

.he-app-head {
  margin-top: 6px;
}

/* iOS 26 floating tab bar, the app's real tabs. */
.he-tabbar {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 22px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.93);
  box-shadow:
    inset 0 0 0 1px rgba(28, 26, 23, 0.07),
    0 12px 26px -14px rgba(28, 26, 23, 0.4);
}

.he-tab {
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 6px 0 5px;
  border-radius: 999px;
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
  color: #4a4640;
}

.he-tab .he-ic {
  font-size: 19px;
  stroke-width: 1.8;
}

.he-tab.is-on {
  background: rgba(184, 134, 11, 0.13);
  color: var(--he-deep);
}

.he-homebar {
  position: absolute;
  left: 50%;
  bottom: 7px;
  width: 36%;
  height: 5px;
  border-radius: 3px;
  background: rgba(28, 26, 23, 0.9);
  transform: translateX(-50%);
}

/* A sheen across the glass that slides against the tilt. */
.he-glare {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: var(--r);
  pointer-events: none;
  transform: translateZ(0.8px);
}

.he-glare i {
  position: absolute;
  top: -10%;
  bottom: -10%;
  left: -45%;
  width: 80%;
  background: linear-gradient(105deg, rgba(255, 255, 255, 0) 20%, rgba(255, 255, 255, 0.13) 48%, rgba(255, 255, 255, 0) 72%);
}

.he-greet {
  font-size: 21px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.he-date {
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--he-noble);
}

.he-here {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 5px 11px 5px 9px;
  border-radius: 999px;
  background: var(--he-card);
  border: 1px solid var(--he-membrane);
  font-size: 12px;
  color: var(--he-text);
}

.he-here-dot {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--he-spectral);
}

.he-here-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid var(--he-spectral);
  opacity: 0;
}

.he-screen .he-label {
  margin: 18px 2px 8px;
}

/* ---------- schedule rows (shared by the hero phone and the lab) ---------- */

.he-rows {
  --row-h: 58px;
  --row-gap: 8px;
  position: relative;
  height: calc(var(--row-h) * 3 + var(--row-gap) * 2);
}

.he-row {
  --slot: 0;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--row-h);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-radius: 12px;
  background: var(--he-card);
  border: 1px solid var(--he-membrane);
  transform: translateY(calc(var(--slot) * (var(--row-h) + var(--row-gap))));
  transition:
    transform 0.7s var(--he-ease-out),
    border-color 0.4s var(--he-ease-smooth),
    opacity 0.4s var(--he-ease-smooth);
}

/* Spanish is the block that jumps ahead, so it passes over the gym row. */
.he-row--spanish { --slot: 1; z-index: 2; }
.he-row--gym { z-index: 1; }
.he-row--dinner { --slot: 2; }

.he-row-bar {
  flex: none;
  width: 3px;
  height: 34px;
  border-radius: 2px;
  background: var(--he-spectral);
}

.he-row--dinner .he-row-bar {
  background: var(--he-membrane);
}

.he-row-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 3px;
}

.he-row-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

.he-row-time {
  display: grid;
  font-size: 11.5px;
  color: var(--he-noble);
  font-variant-numeric: tabular-nums;
}

.he-t {
  grid-area: 1 / 1;
  transition: opacity 0.35s var(--he-ease-smooth);
}

.he-t--moved,
.he-t--later {
  opacity: 0;
}

.he-ic--cal {
  font-size: 12px;
  color: var(--he-noble);
}

.he-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 7px 2px 5px;
  border-radius: 999px;
  background: var(--he-diffuse);
  color: var(--he-deep);
  font-size: 11px;
  font-weight: 500;
  line-height: 1.3;
  transition: background-color 0.3s var(--he-ease-smooth), color 0.3s var(--he-ease-smooth);
}

.he-chip .he-ic {
  font-size: 10px;
  stroke-width: 2.4;
}

.he-flag {
  flex: none;
  padding: 2px 7px;
  border-radius: 999px;
  background: var(--he-diffuse);
  color: var(--he-deep);
  font-size: 10.5px;
  font-weight: 600;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.35s var(--he-ease-smooth) 0.35s, transform 0.5s var(--he-ease-out) 0.35s;
}

@media (max-width: 359px) {
  .he-screen .he-flag {
    display: none;
  }
}

/* "Happening now": the block at the top of the evening */
.he-row--gym {
  border-color: rgba(184, 134, 11, 0.55);
}

/* ---------- plan states ----------
   SWAP: still at the office. Spanish comes forward, the gym moves later.
   LATER: home instead. Spanish comes forward, the gym waits for tomorrow. */

:is(.he-live.is-moved, .he-lab:not(.is-reverted):has(#he-at-office:checked)) .he-row--spanish,
.he-lab:not(.is-reverted):has(#he-at-home:checked) .he-row--spanish {
  --slot: 0;
  border-color: rgba(184, 134, 11, 0.55);
}

:is(.he-live.is-moved, .he-lab:not(.is-reverted):has(#he-at-office:checked)) .he-row--gym {
  --slot: 1;
  border-color: var(--he-membrane);
}

.he-lab:not(.is-reverted):has(#he-at-home:checked) .he-row--dinner {
  --slot: 1;
}

.he-lab:not(.is-reverted):has(#he-at-home:checked) .he-row--gym {
  --slot: 2;
  border-style: dashed;
  border-color: var(--he-membrane);
  opacity: 0.72;
}

:is(.he-live.is-moved, .he-lab:not(.is-reverted):has(#he-at-office:checked)) :is(.he-row--gym, .he-row--spanish) .he-t--plan,
.he-lab:not(.is-reverted):has(#he-at-home:checked) :is(.he-row--gym, .he-row--spanish) .he-t--plan {
  opacity: 0;
}

:is(.he-live.is-moved, .he-lab:not(.is-reverted):has(#he-at-office:checked)) :is(.he-row--gym, .he-row--spanish) .he-t--moved,
.he-lab:not(.is-reverted):has(#he-at-home:checked) .he-row--spanish .he-t--moved,
.he-lab:not(.is-reverted):has(#he-at-home:checked) .he-row--gym .he-t--later {
  opacity: 1;
}

:is(.he-live.is-moved, .he-lab:not(.is-reverted):has(:is(#he-at-office, #he-at-home):checked)) :is(.he-row--gym, .he-row--spanish) .he-flag {
  opacity: 1;
  transform: none;
}

/* The dashboard continues below the schedule and runs off the screen's
   edge, so the phone reads as a scrolled Today view. */
.he-goals {
  border-top: 1px solid var(--he-membrane);
}

.he-goals li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 10px;
  padding: 10px 2px;
  border-bottom: 1px solid var(--he-membrane);
}

.he-goal-name {
  overflow: hidden;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.he-goal-pct {
  font-size: 13px;
  color: var(--he-text);
  font-variant-numeric: tabular-nums;
}

.he-goal-note {
  grid-column: 1 / -1;
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--he-recovered-text);
}

/* ---------- hero sequence (driven by helion.js) ---------- */

.he-live.is-cue .he-row--gym .he-chip {
  background: var(--he-strain-tint);
  color: var(--he-strain-text);
}

.he-live.is-cue .he-here-dot::after {
  animation: he-ping 1.1s var(--he-ease-out) 2;
}

@keyframes he-ping {
  from { transform: scale(0.6); opacity: 0.9; }
  to { transform: scale(2.1); opacity: 0; }
}

/* The message is its own layer above the glass: it rises off the screen
   toward you, casting its shadow onto the display below. */
.he-alert {
  position: absolute;
  left: calc(var(--inset) + 12px);
  right: calc(var(--inset) + 12px);
  bottom: calc(var(--inset) + 92px);
  padding: 13px 14px 10px;
  border-radius: 18px;
  background: var(--he-card);
  box-shadow:
    0 2px 6px rgba(12, 12, 20, 0.08),
    0 28px 46px -18px rgba(12, 12, 20, 0.55);
  opacity: 0;
  transform: translate3d(0, 16px, 1px) scale(0.94);
  transition: transform 0.9s var(--he-ease-out), opacity 0.35s var(--he-ease-smooth);
}

.he-live.is-told .he-alert {
  opacity: 1;
  transform: translate3d(0, 0, 36px);
}

.he-alert-from {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--he-noble);
}

.he-alert-icon {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 5px;
  background: linear-gradient(180deg, var(--he-night-3), var(--he-night-2));
  color: #f0f0f5;
  font-family: var(--he-display);
  font-size: 10px;
  line-height: 1;
}

.he-alert-msg {
  margin-top: 7px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--he-nucleus);
}

.he-alert-actions {
  display: flex;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--he-noble);
}

.he-alert-actions span {
  padding: 6px 12px;
  border-radius: 10px;
  transition: background-color 0.2s var(--he-ease-smooth), transform 0.2s var(--he-ease-out);
}

.he-alert-actions .he-alert-ok {
  color: var(--he-deep);
}

.he-live.is-ack .he-alert-ok {
  background: var(--he-diffuse);
  transform: scale(0.95);
}

/* Loop restart: fade the list out, jump back without animating, fade in. */
.he-live.is-resetting .he-rows,
.he-live.is-resetting .he-alert {
  opacity: 0;
  transition: opacity 0.3s var(--he-ease-smooth);
}

.he-live .he-rows {
  transition: opacity 0.4s var(--he-ease-smooth);
}

.he-live.is-instant *,
.he-live.is-instant *::after {
  transition: none !important;
}

.he-pause {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 12px 0 10px;
  border: 1px solid var(--he-ink-line);
  border-radius: 999px;
  background: transparent;
  color: var(--he-on-ink-2);
  font-family: var(--he-serif);
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s var(--he-ease-smooth), color 0.2s var(--he-ease-smooth);
}

.he-pause:hover {
  border-color: rgba(242, 239, 232, 0.35);
  color: var(--he-on-ink);
}

.he .he-pause:focus-visible {
  outline: 2px solid var(--he-gold-hi);
  outline-offset: 2px;
  border-radius: 999px;
}

.he-pause .he-ic {
  font-size: 14px;
}

.he-pause[hidden] {
  display: none;
}

/* ==========================================================================
   Paper sections
   ========================================================================== */

.he-sec {
  position: relative;
  padding-block: clamp(84px, 10vw, 140px);
}

.he-paper {
  background: var(--he-argon);
  color: var(--he-nucleus);
}

.he-paper .he-body {
  color: var(--he-text);
}

.he-paper :focus-visible {
  outline-color: var(--he-deep);
}

/* ---------- the briefing ---------- */

.he-plan-grid {
  display: grid;
  gap: 56px;
}

@media (min-width: 1024px) {
  .he-plan-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 72px;
    align-items: center;
  }
}

/* The four inputs. Each lights up as the card shows it being applied, and
   the one playing now is lifted. */
.he-steps {
  display: grid;
  gap: 4px;
  max-width: 30em;
  margin: 30px 0 0 -14px;
}

.he-step {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 17.5px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--he-nucleus);
  transition: opacity 0.45s var(--he-ease-smooth), background-color 0.45s var(--he-ease-smooth), box-shadow 0.45s var(--he-ease-smooth);
}

.he-step-mark {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 22px;
  border-radius: 6px;
  transition: transform 0.6s var(--he-ease-out);
}

.he-step-mark--cal {
  background: var(--he-cal);
  box-shadow: inset 0 0 0 1px #ddd7cc;
}

.he-step-mark--energy {
  background: linear-gradient(90deg, rgba(232, 228, 221, 0.9), rgba(45, 157, 95, 0.6) 50%, rgba(232, 228, 221, 0.9));
}

.he-step-mark--goal {
  background: var(--he-block);
}

.he-step-mark--place {
  background: var(--he-diffuse);
  color: var(--he-deep);
}

.he-step-mark--place .he-ic {
  font-size: 14px;
  stroke-width: 2.2;
}

.he-armed:not(.is-b1) [data-beat="1"],
.he-armed:not(.is-b2) [data-beat="2"],
.he-armed:not(.is-b3) [data-beat="3"],
.he-armed:not(.is-b4) [data-beat="4"] {
  opacity: 0.32;
}

.he-armed:not(.is-b1) [data-beat="1"] .he-step-mark,
.he-armed:not(.is-b2) [data-beat="2"] .he-step-mark,
.he-armed:not(.is-b3) [data-beat="3"] .he-step-mark,
.he-armed:not(.is-b4) [data-beat="4"] .he-step-mark {
  transform: scale(0.7);
}

.is-b1:not(.is-b2) [data-beat="1"],
.is-b2:not(.is-b3) [data-beat="2"],
.is-b3:not(.is-b4) [data-beat="3"],
.is-b4:not(.is-b5) [data-beat="4"] {
  background: var(--he-card);
  box-shadow: 0 12px 26px -18px rgba(61, 57, 52, 0.4);
}

.he-brief-fig {
  width: 100%;
  max-width: 520px;
  justify-self: center;
}

.he-brief {
  --hh: 38px;
  padding: 24px 22px 22px;
  border-radius: 16px;
  background: var(--he-card);
  box-shadow: 0 30px 60px -30px rgba(61, 57, 52, 0.28);
  color: var(--he-nucleus);
}

@media (max-width: 479px) {
  .he-brief {
    --hh: 34px;
    padding: 20px 16px 18px;
  }
}

.he-brief-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.he-brief .he-greet {
  font-size: 22px;
}

.he-ring {
  position: relative;
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 68px;
  height: 68px;
}

.he-ring svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.he-ring circle {
  fill: none;
  stroke-width: 5;
}

.he-ring-track {
  stroke: var(--he-membrane);
}

.he-ring-val {
  stroke: var(--he-recovered);
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 16;
  transition: stroke-dashoffset 1.2s var(--he-ease-out) 0.2s;
}

.he-ring-num {
  font-size: 20px;
  font-weight: 600;
  line-height: 1;
}

.he-ring-word {
  margin-top: 3px;
  font-size: 10px;
  line-height: 1;
  color: var(--he-recovered-text);
}

.he-brief-note {
  margin: 20px 0 22px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--he-membrane);
}

.he-brief-text {
  margin-top: 6px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--he-text);
}

.he-brief > .he-label {
  margin-bottom: 10px;
}

.he-day {
  position: relative;
  display: grid;
  grid-template-columns: 22px 28px minmax(0, 1fr);
  gap: 0 10px;
  height: calc(var(--hh) * 13);
}

.he-day-hours li {
  height: var(--hh);
  font-size: 10.5px;
  line-height: 1;
  color: var(--he-noble);
  font-variant-numeric: tabular-nums;
  transform: translateY(-4px);
}

.he-day-energy {
  position: relative;
}

.he-energy {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.he-energy-peak {
  fill: rgba(45, 157, 95, 0.12);
  transition: opacity 0.6s var(--he-ease-smooth) 0.5s;
}

.he-energy-area {
  fill: rgba(45, 157, 95, 0.1);
  transition: opacity 0.6s var(--he-ease-smooth) 0.7s;
}

.he-energy-line {
  fill: none;
  stroke: var(--he-recovered);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.1s var(--he-ease-smooth);
}

.he-day-track {
  position: relative;
  background-image: linear-gradient(var(--he-membrane) 1px, transparent 1px);
  background-size: 100% var(--hh);
}

.he-blk {
  --s: 0;
  --d: 1;
  position: absolute;
  left: 0;
  right: 0;
  top: calc(var(--s) * var(--hh) + 2px);
  height: calc(var(--d) * var(--hh) - 4px);
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  align-items: center;
  gap: 2px 8px;
  padding: 4px 10px;
  overflow: hidden;
  border-radius: 8px;
  font-size: 12.5px;
  line-height: 1.2;
  transition: opacity 0.5s var(--he-ease-smooth), transform 0.8s var(--he-ease-out);
}

@media (max-width: 479px) {
  .he-blk {
    padding: 3px 8px;
    font-size: 12px;
  }
}

.he-blk b {
  font-weight: 600;
}

.he-blk small {
  flex-basis: 100%;
  font-size: 11px;
  opacity: 0.92;
  font-variant-numeric: tabular-nums;
}

.he-blk--cal {
  background: var(--he-cal);
  color: var(--he-cal-text);
  box-shadow: inset 0 0 0 1px #e3ded5;
}

.he-blk--he {
  background: var(--he-block);
  color: #fff;
}

.he-blk .he-chip {
  font-size: 10.5px;
  padding: 1px 6px 1px 4px;
}

.he-at-proposal { --s: 1.5; --d: 2; }
.he-at-lunch { --s: 4.5; --d: 1; }
.he-at-review { --s: 6; --d: 1; }
.he-at-numbers { --s: 7.25; --d: 1.5; }
.he-at-strength { --s: 9.5; --d: 1; }
.he-at-spanish { --s: 10.75; --d: 0.75; }
.he-at-dinner { --s: 12; --d: 1; }

/* Arming hides an element's pre-reveal state without animating the hide. */
.he-instant,
.he-instant *,
.he-instant::before,
.he-instant *::before {
  transition: none !important;
}

/* ---------- the day builds itself (beats set by helion.js) ----------
   1 meetings drop in, 2 the energy curve draws, 3 goals fly into the gaps,
   4 places pop onto the blocks, 5 the ring fills and the brief appears.
   Without the script every element simply rests in place. */

.he-armed:not(.is-b1) .he-blk--cal {
  opacity: 0;
  transform: translateY(-18px);
}

.he-armed:not(.is-b2) .he-energy-line {
  stroke-dashoffset: 1;
}

.he-armed:not(.is-b2) .he-energy-peak,
.he-armed:not(.is-b2) .he-energy-area {
  opacity: 0;
}

.he-armed:not(.is-b3) .he-blk--he {
  opacity: 0;
  transform: translateX(48px) scale(0.94);
}

.he-armed:not(.is-b4) .he-blk .he-chip {
  opacity: 0;
  transform: scale(0.4);
}

.he-armed:not(.is-b5) .he-brief-text {
  opacity: 0;
  transform: translateY(6px);
}

.he-armed:not(.is-b5) .he-ring-val {
  stroke-dashoffset: 100;
}

.he-blk .he-chip {
  transition: opacity 0.3s var(--he-ease-smooth), transform 0.55s var(--he-ease-out);
}

.he-brief-text {
  transition: opacity 0.6s var(--he-ease-smooth), transform 0.8s var(--he-ease-out);
}

.he-at-lunch { transition-delay: 0s; }
.he-at-review { transition-delay: 0.1s; }
.he-at-dinner { transition-delay: 0.2s; }
.he-at-proposal { transition-delay: 0s; }
.he-at-numbers { transition-delay: 0.14s; }
.he-at-strength { transition-delay: 0.28s; }
.he-at-spanish { transition-delay: 0.42s; }
.he-at-numbers .he-chip { transition-delay: 0.12s; }
.he-at-strength .he-chip { transition-delay: 0.24s; }

/* The demanding block lands in the energy peak with a green flash. */
.he-at-proposal::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 8px;
  box-shadow: inset 0 0 0 2px #56c98a;
  opacity: 0;
  pointer-events: none;
}

.he-armed.is-b3 .he-at-proposal::after {
  animation: he-land 1.1s var(--he-ease-smooth) 0.45s both;
}

@keyframes he-land {
  0% { opacity: 0; }
  25% { opacity: 1; }
  100% { opacity: 0; }
}

.he-replay {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 36px;
  padding: 0 13px 0 10px;
  border: 1px solid var(--he-membrane);
  border-radius: 999px;
  background: transparent;
  color: var(--he-noble);
  font-family: var(--he-serif);
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s var(--he-ease-smooth), color 0.2s var(--he-ease-smooth);
}

.he-replay:hover {
  border-color: #d6cfc2;
  color: var(--he-nucleus);
}

.he-replay .he-ic {
  font-size: 14px;
}

.he-replay[hidden] {
  display: none;
}

.he-replay--ink {
  border-color: var(--he-ink-line);
  color: var(--he-on-ink-2);
}

.he-replay--ink:hover {
  border-color: rgba(242, 239, 232, 0.35);
  color: var(--he-on-ink);
}

.he .he-replay:focus-visible {
  outline: 2px solid var(--he-deep);
  outline-offset: 2px;
  border-radius: 999px;
}

.he .he-replay--ink:focus-visible {
  outline-color: var(--he-gold-hi);
}

/* ---------- where are you: the lab ---------- */

.he-where {
  border-top: 1px solid var(--he-membrane);
}

.he-where-intro {
  max-width: 44em;
}

.he-lab {
  display: grid;
  gap: 20px;
  margin-top: 48px;
  grid-template-areas:
    "choose"
    "map"
    "plan";
}

@media (min-width: 900px) {
  .he-lab {
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    grid-template-areas:
      "choose choose"
      "map plan";
    gap: 24px 32px;
    align-items: start;
  }
}

.he-choose {
  grid-area: choose;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.he-choose-q {
  padding: 0;
  margin-bottom: 14px;
  font-size: clamp(18px, 16.5px + 0.4vw, 21px);
  line-height: 1.4;
  color: var(--he-text);
}

.he-choose-q strong {
  color: var(--he-nucleus);
}

.he-choose-opts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

@media (min-width: 640px) {
  .he-choose-opts {
    display: flex;
    flex-wrap: wrap;
  }
}

.he-choose-opts label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid var(--he-membrane);
  background: var(--he-card);
  font-size: 15.5px;
  color: var(--he-text);
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  transition: background-color 0.2s var(--he-ease-smooth), border-color 0.2s var(--he-ease-smooth), color 0.2s var(--he-ease-smooth), transform 0.2s var(--he-ease-out);
}

@media (max-width: 479px) {
  .he-choose-opts label {
    padding: 0 10px;
    gap: 6px;
    font-size: 15px;
  }
}

@media (max-width: 359px) {
  .he-choose-opts {
    grid-template-columns: 1fr;
  }
}

.he-choose-opts label:hover {
  border-color: #d6cfc2;
}

.he-choose-opts label:active {
  transform: scale(0.97);
}

.he-choose-opts .he-ic {
  font-size: 16px;
  color: var(--he-deep);
}

.he-sr-input:checked + label {
  background: var(--he-nucleus);
  border-color: var(--he-nucleus);
  color: var(--he-argon);
}

.he-sr-input:checked + label .he-ic {
  color: var(--he-gold);
}

.he-sr-input:focus-visible + label {
  outline: 2px solid var(--he-deep);
  outline-offset: 3px;
}

/* the map */

.he-map {
  grid-area: map;
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 16px;
  background: var(--he-map);
}

.he-map-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.he-roads path {
  fill: none;
  stroke: #fff;
  stroke-width: 11;
  stroke-linecap: round;
}

.he-roads .he-road-thin {
  stroke-width: 6;
}

.he-route {
  fill: none;
  stroke: var(--he-spectral);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 1 7;
  opacity: 0;
  transition: opacity 0.4s var(--he-ease-smooth);
}

.he-fence {
  fill: rgba(184, 134, 11, 0.05);
  stroke: rgba(139, 101, 8, 0.32);
  stroke-width: 1.5;
  stroke-dasharray: 3 4;
  transition: fill 0.4s var(--he-ease-smooth), stroke 0.4s var(--he-ease-smooth);
}

.he-place-dot {
  fill: var(--he-deep);
}

.he-place--library .he-fence,
.he-place--cafe .he-fence {
  fill: transparent;
  stroke: rgba(107, 104, 98, 0.28);
}

.he-place--library .he-place-dot,
.he-place--cafe .he-place-dot {
  fill: #a39d92;
}

/* Arriving somewhere: the geofence ripples once the dot has landed. */
.he-ripple {
  fill: none;
  stroke: var(--he-spectral);
  stroke-width: 2;
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
}

.he-lab.is-onscreen:has(#he-at-gym:checked) .he-place--gym .he-ripple,
.he-lab.is-onscreen:has(#he-at-office:checked) .he-place--office .he-ripple,
.he-lab.is-onscreen:has(#he-at-home:checked) .he-place--home .he-ripple {
  animation: he-ripple 1.4s var(--he-ease-out) 0.75s 2;
}

@keyframes he-ripple {
  from { opacity: 0.75; transform: scale(0.75); }
  to { opacity: 0; transform: scale(1.8); }
}

.he-map-tag {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px 3px 6px;
  border-radius: 999px;
  background: var(--he-card);
  box-shadow: 0 4px 10px -4px rgba(61, 57, 52, 0.3);
  font-size: 12px;
  font-weight: 500;
  color: var(--he-deep);
  transform: translate(-50%, 0);
  white-space: nowrap;
}

.he-map-tag .he-ic {
  font-size: 11px;
  stroke-width: 2.3;
}

.he-map-tag--office { left: 23%; top: 39%; }
.he-map-tag--gym { left: 78%; top: 63%; }
.he-map-tag--home { left: 22%; top: 63%; transform: translate(-50%, -100%); }
.he-map-tag--library { left: 64.5%; top: 25%; color: var(--he-cal-text); }
.he-map-tag--cafe { left: 56.5%; top: 73%; transform: translate(-50%, -100%); color: var(--he-cal-text); }

/* you are here */
.he-you {
  transform: translate(92px, 78px);
  transition: transform 0.9s var(--he-ease-out);
}

.he-you-dot {
  fill: var(--he-gold);
  stroke: #fff;
  stroke-width: 3;
}

.he-you-halo {
  fill: rgba(212, 160, 42, 0.22);
  transform-box: fill-box;
  transform-origin: center;
}

.he-lab:has(#he-at-gym:checked) .he-you { transform: translate(312px, 150px); }
.he-lab:has(#he-at-office:checked) .he-you { transform: translate(92px, 78px); }
.he-lab:has(#he-at-home:checked) .he-you { transform: translate(88px, 228px); }
.he-lab:has(#he-at-move:checked) .he-you { transform: translate(205px, 148px); }

.he-lab:has(#he-at-gym:checked) .he-place--gym .he-fence,
.he-lab:has(#he-at-office:checked) .he-place--office .he-fence,
.he-lab:has(#he-at-home:checked) .he-place--home .he-fence {
  fill: rgba(212, 160, 42, 0.16);
  stroke: rgba(139, 101, 8, 0.6);
  stroke-dasharray: none;
}

.he-lab:has(#he-at-move:checked) .he-route:not(.he-route--home),
.he-lab:has(#he-at-home:checked) .he-route--home {
  opacity: 1;
}

/* the plan beside the map */

.he-lab-plan {
  grid-area: plan;
  min-width: 0;
}

.he-label--row {
  display: flex;
  justify-content: space-between;
  margin: 0 2px 10px;
}

.he-lab-now {
  font-variant-numeric: tabular-nums;
}

.he-rows--lab {
  --row-h: 60px;
}

.he-rows--lab .he-row-title {
  font-size: 14.5px;
}

.he-rows--lab .he-row-time {
  font-size: 12.5px;
}

.he-outcomes {
  display: grid;
  margin-top: 14px;
}

.he-out {
  grid-area: 1 / 1;
  align-self: start;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.35s var(--he-ease-smooth), transform 0.5s var(--he-ease-out), visibility 0s linear 0.35s;
}

.he-lab:not(.is-reverted):not(.is-acked):has(#he-at-gym:checked) .he-out--gym,
.he-lab:not(.is-reverted):not(.is-acked):has(#he-at-office:checked) .he-out--office,
.he-lab:not(.is-reverted):not(.is-acked):has(#he-at-home:checked) .he-out--home,
.he-lab:not(.is-reverted):not(.is-acked):has(#he-at-move:checked) .he-out--move,
.he-lab.is-reverted .he-out--reverted,
.he-lab.is-acked:not(.is-reverted) .he-out--acked {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.35s var(--he-ease-smooth) 0.15s, transform 0.6s var(--he-ease-out) 0.15s, visibility 0s;
}

.he-msg {
  padding: 14px 16px 10px;
  border-radius: 16px;
  background: var(--he-card);
  box-shadow: 0 14px 30px -14px rgba(61, 57, 52, 0.32);
}

.he-msg-text {
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--he-nucleus);
}

.he-msg-actions {
  display: flex;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 6px;
}

.he-msg-btn {
  min-height: 40px;
  padding: 0 14px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  font-family: var(--he-serif);
  font-size: 14.5px;
  font-weight: 600;
  color: var(--he-noble);
  cursor: pointer;
  transition: background-color 0.2s var(--he-ease-smooth);
}

.he-msg-btn:hover {
  background: var(--he-cal);
}

.he-msg-btn--ok {
  color: var(--he-deep);
}

.he-msg-btn--ok:hover {
  background: var(--he-diffuse);
}

.he .he-msg-btn:focus-visible {
  outline: 2px solid var(--he-deep);
  outline-offset: 1px;
  border-radius: 10px;
}

.he-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 14px 2px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--he-text);
}

.he-note .he-ic {
  margin-top: 3px;
  font-size: 17px;
  color: var(--he-deep);
}

.he-out--gym .he-ic {
  color: var(--he-recovered-text);
}

.he-cap--lab {
  justify-content: flex-start;
  margin-top: 6px;
}

/* guardrails */

.he-rules {
  display: grid;
  gap: 0 32px;
  margin-top: 64px;
}

@media (min-width: 640px) {
  .he-rules {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .he-rules {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.he-rules li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  border-top: 1px solid var(--he-membrane);
  font-size: 16.5px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--he-nucleus);
}

.he-rules .he-ic {
  flex: none;
  width: 34px;
  height: 34px;
  padding: 8px;
  border-radius: 50%;
  background: var(--he-diffuse);
  color: var(--he-deep);
}

/* ==========================================================================
   Night sections
   ========================================================================== */

.he-dusk {
  overflow-x: clip;
  color: var(--he-on-ink);
  background:
    radial-gradient(70% 55% at 50% 0%, rgba(212, 160, 42, 0.13), transparent 70%),
    linear-gradient(180deg, #212133 0%, var(--he-night-2) 55%, #16161f 100%);
}

.he-dusk::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 4%, rgba(212, 160, 42, 0.5) 30%, var(--he-gold-hi) 50%, rgba(212, 160, 42, 0.5) 70%, transparent 96%);
}

.he-dusk .he-body,
.he-close .he-body {
  color: var(--he-on-ink-2);
}

.he-tonight-copy {
  max-width: 44em;
}

/* ---------- the night arc (beats set by helion.js) ----------
   1 the arc draws and the stars come out, 2 the moon rises at the evening
   debrief, 3 it crosses the overnight review, 4 it turns into the sun at
   the morning briefing as dawn breaks. The orb rides an arm pivoting on the
   arc's centre, so the whole journey is one rotation. */

.he-sky {
  margin-top: 56px;
}

.he-sky-art {
  position: relative;
  aspect-ratio: 8 / 3;
}

.he-sky-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.he-stars {
  opacity: 0.3;
  transition: opacity 1.2s var(--he-ease-smooth);
}

.he-stars circle {
  fill: #f2efe8;
}

.he-armed:not(.is-b1) .he-stars {
  opacity: 0;
}

.he-armed.is-b1:not(.is-b4) .he-stars {
  opacity: 0.9;
}

.he-sky-horizon {
  stroke: rgba(242, 239, 232, 0.14);
  stroke-width: 1;
}

.he-arc {
  fill: none;
  stroke: rgba(212, 160, 42, 0.55);
  stroke-width: 1.5;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.6s var(--he-ease-smooth);
}

.he-armed:not(.is-b1) .he-arc {
  stroke-dashoffset: 1;
}

.he-tick {
  fill: var(--he-gold);
  stroke: var(--he-night-2);
  stroke-width: 3;
  transition: fill 0.5s var(--he-ease-smooth);
}

.he-armed:not(.is-b2) .he-tick--1,
.he-armed:not(.is-b3) .he-tick--2,
.he-armed:not(.is-b4) .he-tick--3 {
  fill: var(--he-night-3);
}

.he-orbit {
  position: absolute;
  left: 50%;
  top: 18%;
  width: 0;
  height: 133.333%;
  transform-origin: 50% 100%;
  transform: rotate(64deg);
  transition: transform 3.4s cubic-bezier(0.45, 0, 0.25, 1);
  pointer-events: none;
}

.he-armed:not(.is-b2) .he-orbit {
  transform: rotate(-64deg);
}

.he-orb {
  position: absolute;
  top: 0;
  left: 0;
  width: 26px;
  height: 26px;
  margin: -13px 0 0 -13px;
  transition: opacity 0.6s var(--he-ease-smooth);
}

.he-armed:not(.is-b2) .he-orb {
  opacity: 0;
}

.he-orb i {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  transition: opacity 0.9s var(--he-ease-smooth);
}

.he-orb-moon {
  opacity: 0;
  background: radial-gradient(circle at 38% 36%, #fbf8f0, #d9d3c4 70%);
  box-shadow: 0 0 22px 4px rgba(242, 239, 232, 0.28);
}

.he-orb-sun {
  background: radial-gradient(circle at 40% 38%, #fff3c8, #e8b84a 55%, #d4a02a);
  box-shadow: 0 0 34px 10px rgba(232, 184, 74, 0.45);
}

.he-armed:not(.is-b4) .he-orb-moon {
  opacity: 1;
}

.he-armed:not(.is-b4) .he-orb-sun {
  opacity: 0;
}

/* Dawn breaks from the sun's point on the horizon. */
.he-dawn {
  position: absolute;
  left: 95%;
  top: 93.3%;
  width: 84%;
  height: 170%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(232, 184, 74, 0.28), rgba(212, 160, 42, 0.07) 55%, transparent);
  transform: translate(-50%, -50%);
  pointer-events: none;
  transition: opacity 1.4s var(--he-ease-smooth);
}

.he-armed:not(.is-b4) .he-dawn {
  opacity: 0;
}

.he-stations {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.he-station {
  transition: opacity 0.6s var(--he-ease-smooth), transform 0.8s var(--he-ease-out);
}

.he-station--2 {
  text-align: center;
}

.he-station--3 {
  text-align: right;
}

.he-station-name {
  font-family: var(--he-display);
  font-weight: 400;
  font-size: clamp(19px, 14px + 1.2vw, 28px);
  line-height: 1.1;
}

.he-station p {
  margin-top: 6px;
  font-size: clamp(13.5px, 12.5px + 0.3vw, 16px);
  line-height: 1.45;
  color: var(--he-on-ink-2);
}

.he-armed:not(.is-b2) .he-station--1,
.he-armed:not(.is-b3) .he-station--2,
.he-armed:not(.is-b4) .he-station--3 {
  opacity: 0.25;
  transform: translateY(8px);
}

.he-sky-controls {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

/* ---------- waitlist ---------- */

.he-close {
  color: var(--he-on-ink);
  padding-bottom: clamp(96px, 12vw, 160px);
  background:
    radial-gradient(ellipse 34rem 18rem at 50% 14rem, rgba(212, 160, 42, 0.1), transparent 70%),
    linear-gradient(180deg, #16161f 0%, var(--he-night-1) 55%, var(--he-night-0) 100%);
}

.he-wl {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 720px;
}

.he-appicon {
  position: relative;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  margin-bottom: 30px;
  border-radius: 22px;
  background: linear-gradient(180deg, var(--he-night-3), var(--he-night-2));
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 24px 44px -18px rgba(0, 0, 0, 0.8);
  font-family: var(--he-display);
  font-size: 50px;
  line-height: 1;
}

.he-appicon span {
  grid-area: 1 / 1;
  padding-top: 4px;
}

.he-appicon-base {
  color: rgba(240, 240, 245, 0.16);
}

.he-appicon-fill {
  color: #f0f0f5;
}

/* The pull-to-refresh "He": waits empty until it scrolls in, fills with
   amber, then settles. */
.he-armed:not(.is-in) .he-appicon-fill {
  clip-path: inset(100% 0 0 0);
}

.he-appicon.is-in .he-appicon-fill {
  animation:
    he-fill 0.8s var(--he-ease-smooth) 0.1s both,
    he-settle 0.5s var(--he-ease-smooth) 1s both;
}

.he-h2--wl {
  max-width: 14ch;
}

.he-body--wl {
  margin-inline: auto;
}

/* Reading and focus order is email, consent, submit. From 560px the
   button is placed beside the input without changing that order. */
.he-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 12px;
  width: 100%;
  max-width: 560px;
  margin-top: 36px;
  text-align: left;
}

@media (min-width: 560px) {
  .he-form {
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 10px;
  }

  .he-form > * {
    grid-column: 1 / -1;
  }

  .he-form > .he-input {
    grid-column: 1;
    grid-row: 1;
  }

  .he-form > .he-btn--submit {
    grid-column: 2;
    grid-row: 1;
  }
}

.he-input {
  flex: 1;
  min-width: 0;
  min-height: 52px;
  padding: 0 18px;
  border-radius: 14px;
  border: 1px solid rgba(242, 239, 232, 0.2);
  background: rgba(242, 239, 232, 0.06);
  color: var(--he-on-ink);
  font-family: var(--he-serif);
  font-size: 16.5px;
  transition: border-color 0.2s var(--he-ease-smooth), background-color 0.2s var(--he-ease-smooth);
}

.he-input::placeholder {
  color: var(--he-on-ink-3);
  opacity: 1;
}

.he-input:hover {
  border-color: rgba(242, 239, 232, 0.32);
}

.he .he-input:focus-visible,
.he .he-input:focus {
  outline: 2px solid var(--he-gold-hi);
  outline-offset: 2px;
  border-color: transparent;
  border-radius: 14px;
}

.he-input[aria-invalid="true"] {
  border-color: var(--he-err-on-ink);
}

.he-btn--submit {
  flex: none;
}

.he-btn--submit[disabled] {
  cursor: progress;
  opacity: 0.75;
}

.he-field-error {
  display: block;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--he-err-on-ink);
}

.he-field-error:empty {
  display: none;
}

.he-consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 6px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--he-on-ink-2);
  cursor: pointer;
}

.he-check {
  flex: none;
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  accent-color: var(--he-gold);
  cursor: pointer;
}

.he .he-check:focus-visible {
  outline: 2px solid var(--he-gold-hi);
  outline-offset: 2px;
  border-radius: 4px;
}

.he-privacy {
  margin-top: 30px;
  font-size: 14px;
  color: var(--he-on-ink-3);
}

.he-done {
  display: grid;
  justify-items: center;
  gap: 6px;
  margin-top: 36px;
  outline: none;
}

.he-done-ic {
  width: 44px;
  height: 44px;
  padding: 10px;
  border-radius: 50%;
  background: rgba(212, 160, 42, 0.14);
  color: var(--he-gold);
  stroke-width: 2.4;
}

.he-done-title {
  margin-top: 8px;
  font-family: var(--he-display);
  font-size: 30px;
}

.he-done-body {
  font-size: 17px;
  color: var(--he-on-ink-2);
}

.he-done-body strong {
  color: var(--he-on-ink);
  font-weight: 600;
  word-break: break-all;
}

/* ==========================================================================
   Ambient motion: only while the section is on screen
   ========================================================================== */

.he-lab.is-onscreen .he-you-halo {
  animation: he-halo 2.6s var(--he-ease-out) infinite;
}

.he-lab.is-onscreen:has(#he-at-move:checked) .he-route:not(.he-route--home) {
  animation: he-march 1.2s linear infinite;
}

@keyframes he-halo {
  0% { transform: scale(0.55); opacity: 0.9; }
  70%, 100% { transform: scale(1.5); opacity: 0; }
}

@keyframes he-march {
  to { stroke-dashoffset: -16; }
}

/* ==========================================================================
   Reduced motion: nothing slides, scales, or wipes. Changes still happen,
   as dissolves (the way iOS itself handles Reduce Motion), and every
   element's resting state is complete.
   ========================================================================== */

@keyframes he-fade {
  from { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .he-wordmark-fill {
    animation: he-settle 1s var(--he-ease-smooth) 0.5s both;
  }

  .he-appicon.is-in .he-appicon-fill {
    animation: he-settle 1s var(--he-ease-smooth) 0.3s both;
  }

  .he-armed:not(.is-in) .he-appicon-fill {
    clip-path: none;
    color: var(--he-gold);
  }

  .he-hairline,
  .he-here-dot::after,
  .he-lab.is-onscreen .he-you-halo,
  .he-lab.is-onscreen:has(#he-at-move:checked) .he-route:not(.he-route--home) {
    animation: none;
  }

  /* The phone rests at one still angle: no fly-in, drift, or turn. */
  .he-stage {
    animation: he-fade 0.6s var(--he-ease-smooth) 0.3s both;
  }

  .he-enter,
  .he-float,
  .he-ground i {
    animation: none;
  }

  .he-phone,
  .he-live.is-told {
    --pose-x: 5deg;
    --pose-y: -12deg;
    --pose-z: 0.8deg;
    transition: none;
  }

  .he-row {
    transition: opacity 0.35s var(--he-ease-smooth), border-color 0.35s var(--he-ease-smooth);
  }

  /* The motion graphics keep their story but trade movement for dissolves:
     pieces fade into place, curves and the orbit arrive already drawn. */
  .he-flag,
  .he-out,
  .he-armed:not(.is-b1) .he-blk--cal,
  .he-armed:not(.is-b3) .he-blk--he,
  .he-armed:not(.is-b4) .he-blk .he-chip,
  .he-armed:not(.is-b5) .he-brief-text,
  .he-armed:not(.is-b2) .he-station--1,
  .he-armed:not(.is-b3) .he-station--2,
  .he-armed:not(.is-b4) .he-station--3,
  .he-armed:not(.is-b1) [data-beat="1"] .he-step-mark,
  .he-armed:not(.is-b2) [data-beat="2"] .he-step-mark,
  .he-armed:not(.is-b3) [data-beat="3"] .he-step-mark,
  .he-armed:not(.is-b4) [data-beat="4"] .he-step-mark {
    transform: none;
  }

  .he-energy-line,
  .he-arc,
  .he-orbit {
    transition: none;
  }

  .he-armed.is-b3 .he-at-proposal::after,
  .he-lab.is-onscreen .he-ripple {
    animation: none;
  }

  .he-flag {
    transition: opacity 0.35s var(--he-ease-smooth) 0.2s;
  }

  /* The message still sits above the glass; it only fades. */
  .he-alert,
  .he-live.is-told .he-alert {
    transform: translate3d(0, 0, 36px);
    transition: opacity 0.4s var(--he-ease-smooth);
  }

  .he-out,
  .he-lab .he-out {
    transition: opacity 0.35s var(--he-ease-smooth), visibility 0s linear 0.35s;
  }

  .he-you {
    transition: none;
  }

  .he-lab.is-swapping .he-rows--lab .he-row {
    opacity: 0;
    transition: none;
  }

  .he-btn:active,
  .he-choose-opts label:active {
    transform: none;
  }
}

/* the animated day-track pokes ~5px past the viewport on phones */
.he-plan { overflow-x: clip; }
