:root {
  --bg: #04070d;
  --line: rgba(255, 255, 255, 0.12);
  --text: #f6f2ef;
  --text-soft: rgba(246, 242, 239, 0.78);
  --gold: #ecd3a7;
  --rose: #d592a5;
  --blue: #88a2ea;
  --shadow: 0 30px 100px rgba(0, 0, 0, 0.42);
  --font-cn: "Noto Serif SC", serif;
  --font-en: "Cormorant Garamond", serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    radial-gradient(circle at top, rgba(111, 53, 79, 0.34), transparent 24%),
    radial-gradient(circle at 15% 18%, rgba(65, 88, 170, 0.22), transparent 26%),
    radial-gradient(circle at 82% 18%, rgba(221, 185, 121, 0.15), transparent 18%),
    linear-gradient(180deg, #03050b 0%, #08111d 48%, #03050a 100%);
  font-family: var(--font-cn);
  overflow-x: hidden;
}

button {
  font: inherit;
}

#ambientCanvas,
.grain,
.vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

#ambientCanvas {
  z-index: 0;
}

.grain {
  z-index: 1;
  opacity: 0.08;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 3px 3px;
  mix-blend-mode: soft-light;
}

.vignette {
  z-index: 2;
  background:
    radial-gradient(circle at center, transparent 36%, rgba(0, 0, 0, 0.26) 72%, rgba(0, 0, 0, 0.56) 100%);
}

.page-shell {
  position: relative;
  z-index: 3;
  padding: 24px;
}

.start-gate {
  position: fixed;
  inset: 0;
  z-index: 12;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at center, rgba(70, 92, 166, 0.25), transparent 24%),
    rgba(3, 4, 8, 0.78);
  backdrop-filter: blur(16px);
  transition: opacity 900ms ease, visibility 900ms ease;
}

.start-gate.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.start-gate__glow {
  position: absolute;
  width: min(70vw, 700px);
  aspect-ratio: 1;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(226, 151, 176, 0.24), transparent 40%),
    radial-gradient(circle, rgba(109, 129, 213, 0.18), transparent 58%);
  filter: blur(18px);
  animation: haloFloat 10s ease-in-out infinite;
}

.start-gate__card,
.timeline,
.story {
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow);
}

.start-gate__card {
  position: relative;
  width: min(92vw, 760px);
  padding: clamp(28px, 5vw, 54px);
  border-radius: 32px;
  background: linear-gradient(180deg, rgba(9, 13, 24, 0.88), rgba(7, 11, 20, 0.72));
  text-align: center;
}

.start-gate__eyebrow,
.hero__eyebrow,
.timeline__eyebrow,
.memory-modal__eyebrow {
  margin: 0 0 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-family: var(--font-en);
  font-size: 0.92rem;
  color: rgba(245, 226, 186, 0.82);
}

.start-gate h1,
.hero h2,
.story h3,
.timeline h3,
.story-card h4,
.memory-modal h4 {
  margin: 0;
  font-weight: 600;
  line-height: 1.18;
}

.start-gate h1 {
  font-size: clamp(2.2rem, 5vw, 4.5rem);
}

.start-gate__copy,
.hero__lede,
.hero__audio,
.story-card p,
.timeline__copy,
.memory-modal__text,
.memory-quote {
  color: var(--text-soft);
  line-height: 1.95;
}

.start-gate__copy {
  margin: 18px auto 28px;
  max-width: 580px;
}

.primary-button,
.secondary-button {
  border-radius: 999px;
  border: 1px solid transparent;
  padding: 14px 24px;
  cursor: pointer;
  transition: transform 220ms ease, background 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.primary-button {
  color: #120f15;
  background: linear-gradient(135deg, #f7dfbf, #df96ac 52%, #8aa5ee);
  box-shadow: 0 12px 32px rgba(212, 145, 164, 0.34);
}

.secondary-button {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(10px);
}

.primary-button:hover,
.secondary-button:hover,
.week-card:hover,
.memory-modal__close:hover {
  transform: translateY(-2px);
}

.hero {
  position: relative;
  min-height: 92vh;
  border-radius: 38px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 36px 110px rgba(0, 0, 0, 0.44);
  background: rgba(6, 9, 16, 0.46);
}

.hero__slides,
.hero__fireworks,
.hero__cosmos,
.hero__stars,
.hero__shards {
  position: absolute;
  inset: 0;
}

.hero__fireworks {
  z-index: 2;
  pointer-events: none;
  mix-blend-mode: screen;
  opacity: 0.95;
}

.hero__slide {
  position: absolute;
  inset: -2%;
  opacity: 0;
  transform: scale(1.08);
  background-position: center;
  background-size: cover;
  filter: saturate(1.05) brightness(0.42);
  transition: opacity 1400ms ease;
}

.hero__slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(3, 7, 13, 0.78)),
    radial-gradient(circle at 22% 20%, rgba(129, 74, 98, 0.24), transparent 26%),
    radial-gradient(circle at 82% 16%, rgba(108, 132, 208, 0.18), transparent 24%);
}

.hero__slide.is-active {
  opacity: 1;
}

.hero__cosmos {
  z-index: 1;
  mix-blend-mode: screen;
}

.hero__nebula,
.hero__planet,
.hero__orbit {
  position: absolute;
}

.hero__nebula {
  border-radius: 50%;
  filter: blur(30px);
  opacity: 0.6;
}

.hero__nebula--left {
  width: 34vw;
  max-width: 460px;
  aspect-ratio: 1;
  top: 12%;
  left: -5%;
  background: radial-gradient(circle, rgba(225, 132, 164, 0.34), transparent 62%);
  animation: haloFloat 14s ease-in-out infinite;
}

.hero__nebula--right {
  width: 38vw;
  max-width: 520px;
  aspect-ratio: 1;
  right: -8%;
  bottom: 4%;
  background: radial-gradient(circle, rgba(106, 127, 223, 0.28), transparent 64%);
  animation: haloFloat 18s ease-in-out infinite reverse;
}

.hero__planet {
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: inset -20px -20px 40px rgba(0, 0, 0, 0.26), 0 0 60px rgba(117, 145, 230, 0.12);
}

.hero__planet--one {
  width: clamp(120px, 15vw, 210px);
  aspect-ratio: 1;
  top: 10%;
  right: 12%;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 237, 206, 0.46), transparent 12%),
    radial-gradient(circle at 70% 70%, rgba(92, 114, 197, 0.38), transparent 42%),
    linear-gradient(160deg, rgba(236, 180, 151, 0.22), rgba(63, 82, 154, 0.56));
  animation: slowSpin 30s linear infinite;
}

.hero__planet--two {
  width: clamp(70px, 9vw, 124px);
  aspect-ratio: 1;
  left: 10%;
  bottom: 15%;
  background:
    radial-gradient(circle at 36% 30%, rgba(241, 211, 177, 0.4), transparent 14%),
    linear-gradient(155deg, rgba(88, 104, 178, 0.48), rgba(36, 44, 82, 0.74));
  animation: slowSpin 24s linear infinite reverse;
}

.hero__orbit {
  border-radius: 50%;
  border: 1px solid rgba(193, 211, 255, 0.12);
  transform-origin: center;
  --tilt: -18deg;
}

.hero__orbit--one {
  width: 420px;
  height: 220px;
  right: -40px;
  top: 40px;
  --tilt: -18deg;
  transform: rotate(var(--tilt));
  animation: orbitPulse 14s linear infinite;
}

.hero__orbit--two {
  width: 260px;
  height: 130px;
  left: -20px;
  bottom: 70px;
  --tilt: 18deg;
  transform: rotate(var(--tilt));
  animation: orbitPulse 11s linear infinite reverse;
}

.hero__star {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 248, 224, 0.95), rgba(255, 248, 224, 0.08));
  box-shadow: 0 0 18px rgba(255, 245, 213, 0.4);
  animation: starBlink var(--blink, 4s) ease-in-out infinite;
}

.hero__shard {
  position: absolute;
  border-radius: 18px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.18), rgba(152, 182, 255, 0.02));
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(2px);
  transform-origin: center;
  animation: shardFloat var(--duration, 16s) ease-in-out infinite;
}

.hero__shard::after {
  content: "";
  position: absolute;
  inset: 8%;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.08);
  opacity: 0.6;
}

.hero__halo {
  position: absolute;
  width: 42vw;
  max-width: 560px;
  aspect-ratio: 1;
  border-radius: 50%;
  filter: blur(30px);
  opacity: 0.48;
  z-index: 1;
}

.hero__halo--left {
  top: 8%;
  left: -8%;
  background: radial-gradient(circle, rgba(213, 111, 145, 0.34), transparent 62%);
  animation: haloFloat 13s ease-in-out infinite;
}

.hero__halo--right {
  right: -8%;
  bottom: 5%;
  background: radial-gradient(circle, rgba(115, 139, 224, 0.28), transparent 62%);
  animation: haloFloat 16s ease-in-out infinite reverse;
}

.hero__content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 92vh;
  padding: clamp(28px, 6vw, 74px);
  max-width: 900px;
}

.hero h2 {
  font-size: clamp(2.5rem, 6vw, 5.8rem);
  max-width: 10.5em;
}

.hero__lede {
  max-width: 46rem;
  margin: 22px 0 26px;
}

.hero__actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.hero__audio {
  margin: 16px 0 0;
  max-width: 38rem;
  font-size: 0.96rem;
}

.hero__disclosure {
  margin: 8px 0 0;
  font-size: 0.72rem;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: rgba(245, 241, 235, 0.42);
}

.hero__meta {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero__meta span,
.memory-tags span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
  color: rgba(246, 242, 239, 0.9);
}

.story,
.timeline {
  margin: 32px auto 0;
  max-width: 1380px;
  padding: 34px clamp(18px, 4vw, 36px) 44px;
  border-radius: 34px;
  background: linear-gradient(180deg, rgba(9, 13, 24, 0.82), rgba(5, 8, 16, 0.72));
}

.story__header,
.timeline__header {
  max-width: 900px;
  margin-bottom: 28px;
}

.story h3,
.timeline h3 {
  font-size: clamp(1.85rem, 4vw, 3.5rem);
}

.story__grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
}

.story-card {
  position: relative;
  grid-column: span 4;
  padding: 24px 22px;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)),
    radial-gradient(circle at top right, rgba(225, 188, 140, 0.08), transparent 26%);
  overflow: hidden;
}

.story-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent 38%),
    radial-gradient(circle at 88% 12%, rgba(128, 152, 234, 0.09), transparent 18%);
  pointer-events: none;
}

.story-card--wide {
  grid-column: span 8;
}

.story-card--quote {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    radial-gradient(circle at bottom left, rgba(219, 154, 184, 0.09), transparent 24%);
}

.story-card h4 {
  font-size: 1.55rem;
  margin-bottom: 12px;
}

.story-card p {
  position: relative;
  margin: 0 0 14px;
}

.story-card p:last-child {
  margin-bottom: 0;
}

.week-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.week-card {
  position: relative;
  min-height: 284px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 26px;
  overflow: hidden;
  padding: 18px;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.28);
}

.week-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(4, 6, 11, 0.06), rgba(4, 6, 11, 0.92)),
    radial-gradient(circle at 72% 18%, rgba(225, 172, 133, 0.2), transparent 20%),
    radial-gradient(circle at 22% 22%, rgba(99, 121, 208, 0.18), transparent 24%);
}

.week-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transform: scale(1.06);
  filter: brightness(0.56) saturate(1.02);
  transition: transform 300ms ease, filter 300ms ease;
}

.week-card:hover .week-card__bg {
  transform: scale(1.12);
  filter: brightness(0.7);
}

.week-card__content {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 248px;
}

.week-card__index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
  font-family: var(--font-en);
  font-size: 1.2rem;
}

.week-card__title {
  margin: auto 0 8px;
  font-size: 1.42rem;
  line-height: 1.34;
}

.week-card__dates,
.memory-modal__date {
  color: rgba(246, 242, 239, 0.7);
  font-size: 0.96rem;
}

.week-card__badge {
  width: fit-content;
  margin-top: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-size: 0.88rem;
  color: rgba(246, 242, 239, 0.82);
}

.memory-modal {
  position: fixed;
  inset: 0;
  z-index: 14;
  display: grid;
  place-items: center;
  padding: 20px;
}

.memory-modal[hidden] {
  display: none;
}

.memory-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 4, 8, 0.78);
  backdrop-filter: blur(18px);
}

.memory-modal__dialog {
  position: relative;
  width: min(1180px, 100%);
  min-height: min(76vh, 860px);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  background: linear-gradient(180deg, rgba(9, 12, 22, 0.96), rgba(6, 9, 16, 0.94));
  border-radius: 30px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.46);
}

.memory-modal__close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 2;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  cursor: pointer;
}

.memory-modal__media {
  position: relative;
  min-height: 620px;
}

.memory-scene {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: rgba(6, 8, 15, 0.8);
}

.memory-scene__bg,
.memory-scene__glow,
.memory-scene__effect,
.memory-scene__stickers,
.memory-scene__photos {
  position: absolute;
  inset: 0;
}

.memory-scene__bg {
  background-size: cover;
  background-position: center;
  filter: brightness(0.38) saturate(0.95);
  transform: scale(1.08);
}

.memory-scene__glow {
  background:
    radial-gradient(circle at 20% 22%, rgba(215, 144, 158, 0.24), transparent 18%),
    radial-gradient(circle at 80% 24%, rgba(112, 138, 215, 0.16), transparent 22%),
    radial-gradient(circle at 50% 76%, rgba(236, 195, 145, 0.16), transparent 18%),
    linear-gradient(180deg, rgba(2, 4, 8, 0.12), rgba(5, 8, 14, 0.75));
}

.memory-scene__photos {
  display: grid;
  place-items: center;
}

.memory-scene__photos img {
  position: absolute;
  width: min(62%, 420px);
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.32);
}

#memoryPhotoMain {
  transform: translate(-7%, 5%) rotate(-5deg);
}

#memoryPhotoSub {
  width: min(38%, 250px);
  transform: translate(30%, -22%) rotate(10deg);
}

.memory-modal__content {
  position: relative;
  padding: 70px clamp(24px, 4vw, 44px) 34px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.memory-modal h4 {
  font-size: clamp(2rem, 4vw, 3.3rem);
  margin-bottom: 12px;
}

.memory-modal__text {
  margin: 20px 0 24px;
}

.memory-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

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

.memory-action-button {
  padding: 10px 18px;
}

.memory-narration-status {
  margin: 0;
  max-width: 24rem;
  color: rgba(246, 242, 239, 0.58);
  font-size: 0.84rem;
  line-height: 1.6;
}

.memory-quote {
  margin: 28px 0 0;
  padding: 18px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 1.08rem;
}

.playful-sticker {
  position: absolute;
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.02));
  color: rgba(255, 244, 224, 0.9);
  font-size: 1.35rem;
  backdrop-filter: blur(10px);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.24);
  animation: stickerFloat var(--duration, 8s) ease-in-out infinite;
}

.playful-sticker::after {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 14px;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  opacity: 0.7;
}

.playful-sticker--soft {
  color: rgba(255, 226, 206, 0.95);
}

.playful-sticker--blue {
  color: rgba(198, 216, 255, 0.92);
}

.playful-sticker--gold {
  color: rgba(255, 232, 176, 0.96);
}

.effect-piece {
  position: absolute;
  pointer-events: none;
  animation: driftLinear var(--duration, 8s) linear infinite;
  opacity: 0;
}

.effect-piece.is-heart {
  color: rgba(245, 176, 198, 0.95);
  font-size: var(--size, 22px);
  text-shadow: 0 0 16px rgba(244, 170, 197, 0.34);
}

.effect-piece.is-heart::before {
  content: "♥";
}

.effect-piece.is-star {
  width: var(--size, 10px);
  height: var(--size, 10px);
  background: radial-gradient(circle, rgba(255, 244, 199, 0.95), rgba(255, 244, 199, 0.16));
  border-radius: 50%;
  box-shadow: 0 0 18px rgba(255, 245, 204, 0.35);
}

.effect-piece.is-petal {
  width: calc(var(--size, 14px) * 0.7);
  height: var(--size, 14px);
  border-radius: 60% 20% 60% 20%;
  background: linear-gradient(180deg, rgba(247, 198, 208, 0.92), rgba(191, 120, 148, 0.72));
  box-shadow: 0 0 18px rgba(230, 174, 194, 0.26);
}

.effect-piece.is-comet {
  width: var(--size, 120px);
  height: 2px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(169, 197, 255, 0.95));
  transform-origin: left center;
  box-shadow: 0 0 14px rgba(178, 204, 255, 0.4);
}

.effect-piece.is-glow {
  width: var(--size, 18px);
  height: var(--size, 18px);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 218, 177, 0.95), rgba(255, 218, 177, 0.14));
  box-shadow: 0 0 26px rgba(255, 218, 177, 0.3);
}

.effect-piece.is-letter {
  width: calc(var(--size, 18px) * 1.2);
  height: var(--size, 18px);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(255, 247, 236, 0.92), rgba(218, 196, 176, 0.82));
  box-shadow: 0 0 22px rgba(255, 244, 225, 0.2);
}

.effect-piece.is-spark {
  width: var(--size, 18px);
  height: var(--size, 18px);
}

.effect-piece.is-spark::before,
.effect-piece.is-spark::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 243, 207, 0), rgba(255, 243, 207, 0.95), rgba(255, 243, 207, 0));
}

.effect-piece.is-spark::after {
  transform: rotate(90deg);
}

.scene-heartfall .memory-scene__glow {
  background:
    radial-gradient(circle at 20% 22%, rgba(217, 108, 143, 0.28), transparent 20%),
    radial-gradient(circle at 74% 18%, rgba(116, 137, 204, 0.2), transparent 18%),
    linear-gradient(180deg, rgba(4, 6, 11, 0.08), rgba(7, 9, 14, 0.78));
}

.scene-stardust .memory-scene__glow {
  background:
    radial-gradient(circle at 24% 24%, rgba(132, 158, 255, 0.22), transparent 16%),
    radial-gradient(circle at 76% 28%, rgba(255, 230, 165, 0.16), transparent 16%),
    linear-gradient(180deg, rgba(4, 6, 11, 0.1), rgba(5, 9, 17, 0.82));
}

.scene-letter .memory-scene__glow {
  background:
    radial-gradient(circle at 35% 24%, rgba(230, 195, 152, 0.22), transparent 18%),
    radial-gradient(circle at 74% 72%, rgba(193, 137, 156, 0.16), transparent 18%),
    linear-gradient(180deg, rgba(8, 7, 10, 0.08), rgba(9, 8, 12, 0.78));
}

.scene-comet .memory-scene__glow {
  background:
    radial-gradient(circle at 18% 18%, rgba(89, 120, 214, 0.22), transparent 18%),
    radial-gradient(circle at 76% 74%, rgba(255, 205, 141, 0.14), transparent 18%),
    linear-gradient(180deg, rgba(5, 7, 12, 0.06), rgba(4, 8, 14, 0.84));
}

@keyframes haloFloat {
  0%, 100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(0, -20px, 0) scale(1.05);
  }
}

@keyframes slowSpin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes orbitPulse {
  0%, 100% {
    opacity: 0.42;
    transform: scale(1) rotate(var(--tilt));
  }
  50% {
    opacity: 0.68;
    transform: scale(1.04) rotate(var(--tilt));
  }
}

@keyframes starBlink {
  0%, 100% {
    opacity: 0.18;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1.2);
  }
}

@keyframes shardFloat {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotate(var(--rotate, 0deg));
    opacity: 0.1;
  }
  50% {
    transform: translate3d(var(--drift-x, 0), var(--drift-y, -22px), 0) rotate(calc(var(--rotate, 0deg) + 6deg));
    opacity: 0.36;
  }
}

@keyframes driftLinear {
  0% {
    transform: translate3d(var(--x-start, 0), var(--y-start, 0), 0) rotate(var(--rotate-start, 0deg)) scale(0.82);
    opacity: 0;
  }
  12% {
    opacity: 0.9;
  }
  88% {
    opacity: 0.85;
  }
  100% {
    transform: translate3d(var(--x-end, 0), var(--y-end, -520px), 0) rotate(var(--rotate-end, 0deg)) scale(1.1);
    opacity: 0;
  }
}

@keyframes stickerFloat {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotate(var(--tilt, 0deg)) scale(0.96);
    opacity: 0.52;
  }
  50% {
    transform: translate3d(var(--drift-x, 0), var(--drift-y, -18px), 0) rotate(calc(var(--tilt, 0deg) + 6deg)) scale(1.04);
    opacity: 0.96;
  }
}

@media (max-width: 1100px) {
  .story-card,
  .story-card--wide {
    grid-column: span 12;
  }
}

@media (max-width: 980px) {
  .memory-modal__dialog {
    grid-template-columns: 1fr;
    max-height: 92vh;
    overflow: auto;
  }

  .memory-modal__media {
    min-height: 420px;
  }
}

@media (max-width: 720px) {
  .page-shell {
    padding: 14px;
  }

  .hero,
  .story,
  .timeline,
  .start-gate__card,
  .memory-modal__dialog {
    border-radius: 24px;
  }

  .hero__content {
    min-height: 82vh;
  }

  .memory-actions {
    align-items: flex-start;
  }

  .memory-action-button {
    width: 100%;
    justify-content: center;
  }

  .memory-narration-status {
    max-width: none;
  }

  .hero__orbit {
    opacity: 0.5;
  }

  .memory-scene__photos img {
    width: min(72%, 320px);
  }

  #memoryPhotoSub {
    width: min(44%, 170px);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
