* {
  box-sizing: border-box;
}

:root {
  --bg: #12070b;
  --bg-soft: #221017;
  --wine: #6e1938;
  --wine-light: #a7355d;
  --rose: #ef9ab9;
  --cream: #fff5ed;
  --gold: #d9b477;
  --text: #f9eef1;
  --muted: #cdb9c0;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top, rgba(110, 25, 56, 0.2), transparent 40%),
    var(--bg);
  color: var(--text);
  font-family: "Montserrat", sans-serif;
  line-height: 1.7;
  overflow-x: hidden;
}

body.locked {
  overflow: hidden;
}

h1, h2, h3, p {
  margin-top: 0;
}

h1, h2, h3, .brand {
  font-family: "Cormorant Garamond", serif;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input {
  font: inherit;
}

button {
  cursor: pointer;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.glass {
  background: rgba(28, 10, 17, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.music-toggle {
  position: fixed;
  right: clamp(16px, 4vw, 32px);
  bottom: clamp(16px, 4vw, 32px);
  z-index: 1000;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(28, 10, 17, 0.78);
  backdrop-filter: blur(12px);
  color: var(--cream);
  font-size: 1.3rem;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.music-toggle:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 38px rgba(110, 25, 56, .5);
}

.music-toggle.playing {
  animation: musicPulse 2.4s ease-in-out infinite;
}

@keyframes musicPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239, 154, 185, 0.35); }
  50% { box-shadow: 0 0 0 10px rgba(239, 154, 185, 0); }
}

.eyebrow {
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.72rem;
  font-weight: 600;
}

.gate {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(rgba(18, 7, 11, 0.68), rgba(18, 7, 11, 0.92)),
    url("assets/images/gate-bg.svg") center/cover no-repeat;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

.gate.hidden {
  opacity: 0;
  visibility: hidden;
}

.gate__card {
  width: min(620px, 100%);
  padding: clamp(32px, 7vw, 70px);
  border-radius: 30px;
  text-align: center;
}

.gate__card h1 {
  font-size: clamp(2.5rem, 8vw, 5rem);
  line-height: 0.98;
  margin-bottom: 20px;
}

.gate__hint {
  color: var(--muted);
}

#answerForm {
  display: grid;
  gap: 14px;
  margin-top: 30px;
}

#answerInput {
  width: 100%;
  padding: 17px 20px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.15);
  background: rgba(255,255,255,.06);
  color: white;
  outline: none;
  text-align: center;
}

#answerInput:focus {
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(239, 154, 185, 0.13);
}

#answerForm button,
.primary-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 16px 28px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, var(--wine-light), var(--wine));
  color: white;
  font-weight: 600;
  box-shadow: 0 14px 32px rgba(110, 25, 56, .35);
  transition: transform .25s ease, box-shadow .25s ease;
}

#answerForm button:hover,
.primary-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 38px rgba(110, 25, 56, .5);
}

.answer-message {
  min-height: 28px;
  margin: 18px 0 0;
  font-weight: 600;
}

.answer-message.error {
  color: #ff9da6;
  animation: shake .35s ease;
}

.answer-message.success {
  color: #b9ffd4;
}

.tiny-note {
  font-size: .76rem;
  color: #927d84;
  margin-bottom: 0;
}

.site-content {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s ease, transform 1s ease;
}

.site-content.visible {
  opacity: 1;
  transform: none;
}

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  padding: 110px max(6vw, 24px) 70px;
  background:
    linear-gradient(90deg, rgba(18,7,11,.95), rgba(18,7,11,.46)),
    url("assets/images/hero-bg.svg") center/cover no-repeat;
}

.nav {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 24px max(6vw, 24px);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  font-size: 2rem;
  font-weight: 700;
}

.nav__links {
  display: flex;
  gap: 28px;
  color: var(--muted);
  font-size: .9rem;
}

.nav__links a:hover {
  color: white;
}

.hero__content {
  max-width: 800px;
}

.hero h2 {
  font-size: clamp(4rem, 12vw, 8.5rem);
  line-height: .85;
  margin: 18px 0 30px;
}

.hero__subtitle {
  max-width: 660px;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.25rem);
}

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

.ghost-btn {
  padding: 15px 27px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.05);
  color: white;
}

.scroll-indicator {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--muted);
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .18em;
  display: grid;
  justify-items: center;
  gap: 8px;
}

.scroll-indicator span {
  width: 1px;
  height: 38px;
  background: linear-gradient(transparent, var(--rose));
  animation: pulse 1.8s infinite;
}

.section {
  padding: 110px max(6vw, 24px);
}

.section-heading {
  max-width: 720px;
  margin: 0 auto 55px;
  text-align: center;
}

.section-heading h2 {
  font-size: clamp(2.8rem, 7vw, 5rem);
  line-height: 1;
  margin-bottom: 18px;
}

.section-heading > p:last-child {
  color: var(--muted);
}

.video-frame {
  position: relative;
  width: min(1180px, 100%);
  aspect-ratio: 16 / 9;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: var(--shadow);
  background: #090407;
  border: 1px solid rgba(255,255,255,.08);
}

.video-frame video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
  padding: 30px;
  background:
    radial-gradient(circle at center, rgba(167,53,93,.24), transparent 35%),
    linear-gradient(145deg, #1c0b12, #090407);
}

.play-icon {
  width: 75px;
  height: 75px;
  display: grid;
  place-items: center;
  margin: 0 auto 24px;
  border-radius: 50%;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.15);
}

.video-placeholder h3 {
  font-size: clamp(2rem, 4vw, 3.2rem);
  margin-bottom: 10px;
}

.video-placeholder p {
  color: var(--muted);
}

.quote-strip {
  padding: 70px 24px;
  text-align: center;
  background: var(--cream);
  color: #32121e;
}

.quote-strip p {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1;
  margin-bottom: 12px;
}

.quote-strip span {
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .2em;
}

.memories-section {
  background:
    radial-gradient(circle at 10% 20%, rgba(110,25,56,.24), transparent 25%),
    var(--bg-soft);
}

.memory-grid {
  width: min(1250px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.memory-card {
  overflow: hidden;
  border-radius: 26px;
  background: rgba(255,255,255,.055);
  border: 1px solid rgba(255,255,255,.08);
  transition: transform .35s ease, border-color .35s ease;
}

.memory-card:hover {
  transform: translateY(-10px);
  border-color: rgba(239,154,185,.45);
}

.memory-card__image {
  aspect-ratio: 4/3;
  overflow: hidden;
  background: #2a111b;
}

.memory-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}

.memory-card:hover img {
  transform: scale(1.05);
}

.memory-card__body {
  padding: 28px;
}

.memory-card__date {
  color: var(--gold);
  font-size: .73rem;
  text-transform: uppercase;
  letter-spacing: .13em;
}

.memory-card h3 {
  font-size: 2rem;
  margin: 9px 0 12px;
}

.memory-card p {
  color: var(--muted);
  margin-bottom: 0;
}

.game-section {
  display: grid;
  place-items: center;
}

.game-card {
  width: min(760px, 100%);
  padding: clamp(30px, 6vw, 65px);
  text-align: center;
  border-radius: 30px;
}

.game-card h2 {
  font-size: clamp(2.7rem, 6vw, 4.8rem);
  line-height: 1;
}

.game-card > p:not(.eyebrow):not(.game-result) {
  color: var(--muted);
}

.choices {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin: 30px 0;
  flex-wrap: wrap;
}

.choice {
  min-width: 120px;
  padding: 20px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  background: rgba(255,255,255,.05);
  color: white;
  font-size: 2rem;
  transition: transform .25s ease, background .25s ease;
}

.choice:hover {
  transform: translateY(-5px);
  background: rgba(167,53,93,.3);
}

.choice span {
  display: block;
  font-size: .82rem;
  margin-top: 7px;
}

.game-result {
  min-height: 28px;
  font-weight: 600;
  color: var(--rose);
}

.final-section {
  min-height: 86vh;
  display: grid;
  place-items: center;
  text-align: center;
  background:
    linear-gradient(rgba(18,7,11,.75), rgba(18,7,11,.95)),
    url("assets/images/final-bg.svg") center/cover no-repeat;
}

.final-card {
  max-width: 850px;
}

.final-card h2 {
  font-size: clamp(4rem, 10vw, 7.5rem);
  line-height: .85;
}

.final-card > p:not(.eyebrow):not(.signature) {
  color: var(--muted);
  font-size: 1.05rem;
}

.signature {
  margin: 34px 0;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.7rem;
}

.surprise-text {
  margin-top: 30px;
  font-family: "Cormorant Garamond", serif;
  font-size: 2rem;
  animation: fadeUp .6s ease;
}

.surprise-text span {
  font-size: 3rem;
}

footer {
  padding: 28px;
  text-align: center;
  color: #907a82;
  font-size: .8rem;
  border-top: 1px solid rgba(255,255,255,.06);
}

.floating-heart {
  position: fixed;
  bottom: -40px;
  z-index: 1000;
  pointer-events: none;
  animation: floatHeart linear forwards;
}

@keyframes shake {
  25% { transform: translateX(-8px); }
  50% { transform: translateX(8px); }
  75% { transform: translateX(-5px); }
}

@keyframes pulse {
  50% { opacity: .3; }
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(15px); }
}

@keyframes floatHeart {
  to {
    transform: translateY(-115vh) rotate(25deg);
    opacity: 0;
  }
}

@media (max-width: 900px) {
  .memory-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 680px) {
  .nav__links {
    display: none;
  }

  .memory-grid {
    grid-template-columns: 1fr;
  }

  .hero h2 {
    font-size: 4.4rem;
  }

  .section {
    padding: 80px 20px;
  }

  .gate__card {
    padding: 38px 22px;
  }

  .choice {
    min-width: 92px;
  }
}
