/* ==========================================================================
   BIRTHDAY WHITE BLOOM (birthday-white-bloom-001)
   VanviMoments — Pure Light Luxury Template
   Palette: Pearl White · Soft Ivory · Light Blush · Soft Rose · Lavender · Champagne
   ========================================================================== */

:root {
  --pearl: #fffdf9;
  --ivory: #fffbf7;
  --blush: #f9e4e8;
  --rose: #b95a73;
  --rose-deep: #84364f;
  --lavender: #e9e3f5;
  --champagne: #d8b477;
  --ink: #402e35;
  --muted: #745d67;
  --glass: rgba(255, 255, 255, 0.72);
  --line: rgba(132, 54, 79, 0.14);
  --shadow: 0 24px 58px rgba(104, 60, 78, 0.12);
  --shadow-sm: 0 8px 24px rgba(104, 60, 78, 0.08);
  --safe-x: max(16px, env(safe-area-inset-left));
  --safe-r: max(16px, env(safe-area-inset-right));
}

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

html {
  scroll-behavior: smooth;
}

body {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: radial-gradient(circle at 10% 8%, #ffffff 0, transparent 32%),
              linear-gradient(145deg, #fffdfb 0%, #faedf0 48%, #f2edf9 100%);
  color: var(--ink);
  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, a {
  font: inherit;
  color: inherit;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  touch-action: manipulation;
}

button:focus-visible, a:focus-visible, [role="tab"]:focus-visible {
  outline: 3px solid var(--champagne);
  outline-offset: 3px;
}

.display {
  font-family: "Playfair Display", Georgia, serif;
}

.app-shell {
  width: 100%;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.stage[hidden] {
  display: none !important;
}

/* Glassmorphism */
.glass {
  background: var(--glass);
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* Floating Gentle Petals */
.petal {
  position: absolute;
  width: 14px;
  height: 20px;
  border-radius: 80% 20% 80% 20%;
  background: rgba(217, 147, 169, 0.35);
  pointer-events: none;
  animation: drift 14s ease-in-out infinite;
  z-index: 1;
}
.petal:nth-child(2n) {
  background: rgba(194, 174, 220, 0.35);
  animation-duration: 18s;
  animation-delay: -3s;
}
.petal:nth-child(3n) {
  background: rgba(221, 189, 125, 0.28);
  animation-duration: 22s;
  animation-delay: -7s;
}
@keyframes drift {
  0% { transform: translate(0, 0) rotate(0deg); opacity: 0.7; }
  50% { transform: translate(28px, 42px) rotate(80deg); opacity: 0.95; }
  100% { transform: translate(0, 0) rotate(0deg); opacity: 0.7; }
}

/* Intro Overlay Modal */
.intro {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: grid;
  place-items: center;
  padding: 24px var(--safe-r) 24px var(--safe-x);
  background: radial-gradient(circle at center, rgba(255, 253, 249, 0.98), rgba(242, 231, 243, 0.97));
  backdrop-filter: blur(18px);
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.intro.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.intro-box {
  width: min(100%, 460px);
  padding: clamp(32px, 8vw, 52px) clamp(24px, 6vw, 36px);
  text-align: center;
  border-radius: 32px;
}
.intro-box h1 {
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  line-height: 1.15;
  margin: 14px 0 20px;
  color: var(--ink);
}
.eyebrow {
  color: var(--rose-deep);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.intro-skip, .text-button {
  min-height: 44px;
  padding: 10px 18px;
  color: var(--rose-deep);
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: opacity 0.2s;
}
.intro-skip:hover, .text-button:hover {
  opacity: 0.8;
}

/* Top Reveal Banner */
.reveal-banner {
  display: none;
  position: fixed;
  left: 50%;
  top: max(18px, env(safe-area-inset-top));
  transform: translateX(-50%);
  z-index: 800;
  max-width: calc(100% - 32px);
  padding: 12px 24px;
  border-radius: 999px;
  color: var(--rose-deep);
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 10px 30px rgba(185, 90, 115, 0.2);
}
.reveal-banner.show {
  display: block;
  animation: bannerReveal 0.85s ease both;
}
@keyframes bannerReveal {
  from { opacity: 0; transform: translate(-50%, -14px) scale(0.95); }
  to { opacity: 1; transform: translate(-50%, 0) scale(1); }
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: clamp(70px, 10vw, 110px) var(--safe-r) clamp(40px, 6vw, 70px) var(--safe-x);
  position: relative;
  isolation: isolate;
}
.hero:before, .hero:after {
  content: "";
  position: absolute;
  border-radius: 50%;
  z-index: -1;
  pointer-events: none;
}
.hero:before {
  width: min(48vw, 480px);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(250, 202, 211, 0.75), transparent 68%);
  top: 4%;
  right: -8%;
}
.hero:after {
  width: min(46vw, 420px);
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(202, 190, 231, 0.65), transparent 68%);
  left: -10%;
  bottom: 2%;
}
.hero-inner {
  width: min(100%, 1140px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.hero h1 {
  font-size: clamp(2.8rem, 7.5vw, 5.8rem);
  line-height: 1;
  margin: 0.75rem 0 1.2rem;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.hero-copy {
  max-width: 520px;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.75;
  color: var(--muted);
}

/* Buttons */
.primary-button, .share-button, .modal-button {
  min-height: 48px;
  padding: 13px 26px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.95rem;
  color: #ffffff;
  background: linear-gradient(135deg, var(--rose), #d68196);
  box-shadow: 0 12px 24px rgba(185, 90, 115, 0.26);
  transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}
.primary-button:hover, .share-button:hover, .modal-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(185, 90, 115, 0.32);
  filter: brightness(1.03);
}
.primary-button:active {
  transform: translateY(0);
}

/* Garden Art Decorative Visual */
.garden-art {
  min-height: clamp(280px, 38vw, 440px);
  position: relative;
  border-radius: 40px;
  overflow: hidden;
}
.garden-art:before {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 48% 52% 45% 55%;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.88), rgba(244, 206, 217, 0.48));
  box-shadow: inset 0 0 36px rgba(255, 255, 255, 0.85), 0 35px 55px rgba(129, 85, 114, 0.12);
}
.orb {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.92), rgba(242, 185, 203, 0.45));
  box-shadow: inset 8px 8px 20px rgba(255, 255, 255, 0.75), 12px 20px 32px rgba(122, 81, 100, 0.15);
}
.orb.one {
  width: 36%;
  aspect-ratio: 1;
  top: 16%;
  left: 12%;
}
.orb.two {
  width: 24%;
  aspect-ratio: 1;
  bottom: 18%;
  right: 14%;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.88), rgba(202, 190, 231, 0.55));
}
.orb.three {
  width: 15%;
  aspect-ratio: 1;
  top: 20%;
  right: 18%;
}
.flower {
  position: absolute;
  width: 24%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: conic-gradient(from 30deg, #e9b1c1, #fff5f7, #e5d9f3, #e9b1c1);
  filter: drop-shadow(0 12px 16px rgba(136, 69, 94, 0.16));
}
.flower:after {
  content: "";
  position: absolute;
  inset: 35%;
  border-radius: 50%;
  background: #d4ad6d;
}
.flower.one {
  bottom: 12%;
  left: 22%;
  transform: rotate(22deg);
}
.flower.two {
  top: 14%;
  right: 22%;
  transform: scale(0.68) rotate(74deg);
}

/* Soundtrack Audio Toggle Control */
.sound-control {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 0.88rem;
}
.sound-control button {
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  color: var(--rose-deep);
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  transition: transform 0.2s, background 0.2s;
  box-shadow: var(--shadow-sm);
}
.sound-control button:hover {
  transform: scale(1.08);
  background: #ffffff;
}

/* Experience Stage Navigation */
.experience-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 12px var(--safe-r);
  background: rgba(255, 253, 249, 0.8);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(132, 54, 79, 0.1);
}
.experience-nav-inner {
  width: min(100%, 1140px);
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}
.progress-copy {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 700;
}
.progress-line {
  width: clamp(90px, 18vw, 180px);
  height: 6px;
  border-radius: 99px;
  background: rgba(185, 90, 115, 0.15);
  overflow: hidden;
}
.progress-line span {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--rose), var(--champagne));
}

/* Sections */
.section {
  width: min(100%, 1140px);
  margin: auto;
  padding: clamp(52px, 8vw, 92px) var(--safe-r);
  scroll-margin-top: 72px;
}
.section-heading {
  max-width: 680px;
  margin-bottom: clamp(24px, 4vw, 36px);
}
.section-heading h2 {
  font-size: clamp(2.2rem, 4.8vw, 3.8rem);
  line-height: 1.08;
  margin: 0.4rem 0 0.65rem;
  color: var(--ink);
}
.section-heading p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* Gallery & Photos */
.gallery {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(12px, 1.8vw, 20px);
}
.gallery[data-count="1"] {
  grid-template-columns: minmax(0, 560px);
  justify-content: center;
}
.gallery[data-count="2"] {
  grid-template-columns: repeat(2, minmax(0, 420px));
  justify-content: center;
}
.gallery[data-count="3"] .memory-card:first-child,
.gallery[data-count="5"] .memory-card:first-child,
.gallery[data-count="7"] .memory-card:first-child {
  grid-row: span 2;
}
.memory-card {
  padding: 10px;
  border: 0;
  border-radius: 20px;
  text-align: left;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.memory-card:nth-child(2n) {
  transform: rotate(1.2deg);
}
.memory-card:nth-child(3n) {
  transform: rotate(-0.9deg);
}
.memory-card:hover {
  transform: translateY(-8px) rotate(0deg);
  box-shadow: 0 28px 60px rgba(104, 60, 78, 0.18);
}
.memory-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1.05;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--blush), var(--lavender));
}
.memory-card span {
  display: block;
  padding: 10px 6px 4px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1.4;
}
.gallery-empty {
  grid-column: 1 / -1;
  min-height: 240px;
  padding: 24px;
  border: 2px dashed rgba(132, 54, 79, 0.25);
  border-radius: 20px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--rose-deep);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.78), rgba(233, 227, 245, 0.5));
  box-shadow: var(--shadow);
}

/* Wax Envelope & Letter Reveal */
.letter-wrap {
  max-width: 820px;
  margin: auto;
  padding: clamp(24px, 5vw, 48px);
  border-radius: 32px;
  text-align: center;
}
.envelope {
  max-width: 640px;
  margin: 26px auto 0;
}
.envelope-toggle {
  width: 100%;
  min-height: 185px;
  position: relative;
  overflow: hidden;
  border: 0;
  border-radius: 20px;
  cursor: pointer;
  background: linear-gradient(145deg, #f4d9df, #e9dcec);
  box-shadow: 0 20px 38px rgba(123, 72, 92, 0.16);
  transition: transform 0.2s;
}
.envelope-toggle:hover {
  transform: translateY(-2px);
}
.seal {
  width: 56px;
  height: 56px;
  position: absolute;
  left: calc(50% - 28px);
  top: calc(50% - 28px);
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: var(--rose);
  font-size: 1.4rem;
  box-shadow: 0 4px 14px rgba(185, 90, 115, 0.4);
  transition: transform 0.3s ease;
}
.envelope-toggle:hover .seal {
  transform: scale(1.1);
}
.letter-paper {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  text-align: left;
  background: #fffdf8;
  border: 1px solid rgba(216, 180, 119, 0.25);
  border-radius: 0 0 20px 20px;
  box-shadow: inset 0 2px 10px rgba(104, 60, 78, 0.05);
  transition: max-height 0.7s ease, opacity 0.5s ease, padding 0.5s ease, margin 0.5s ease;
}
.letter-paper.open {
  max-height: 800px;
  margin-top: -16px;
  padding: clamp(28px, 6vw, 55px);
  opacity: 1;
}
.letter-paper p {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--ink);
  white-space: pre-line;
}

/* Birthday Countdown */
.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  max-width: 780px;
}
.count-box {
  padding: 24px 12px;
  border-radius: 20px;
  text-align: center;
}
.count-number {
  display: block;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 600;
  font-size: clamp(2.2rem, 5.5vw, 4.4rem);
  line-height: 1;
  color: var(--rose-deep);
}
.count-label {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-top: 6px;
}
.status-message {
  min-height: 1.6em;
  margin-top: 18px;
  color: var(--rose-deep);
  font-weight: 700;
  font-size: 1.05rem;
}

/* Interactive Cake & Candles */
.cake-area {
  display: grid;
  justify-items: center;
  gap: 22px;
  padding: 34px 16px;
  border-radius: 28px;
}
.cake {
  position: relative;
  width: min(290px, 88vw);
  height: 230px;
}
.cake-plate {
  position: absolute;
  bottom: 0;
  left: 4%;
  width: 92%;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(#f6e7d4, #d8b477);
  box-shadow: 0 10px 24px rgba(104, 60, 78, 0.15);
}
.cake-layer {
  position: absolute;
  left: 12%;
  width: 76%;
  border-radius: 22px 22px 15px 15px;
  background: linear-gradient(90deg, #f7c8d4, #f1adbf, #f8d7df);
  box-shadow: inset 0 9px rgba(255, 255, 255, 0.45);
}
.layer-one {
  bottom: 22px;
  height: 65px;
}
.layer-two {
  bottom: 78px;
  left: 19%;
  width: 62%;
  height: 56px;
}
.icing {
  position: absolute;
  bottom: 125px;
  left: 18%;
  width: 64%;
  height: 24px;
  border-radius: 50%;
  background: #fff6f2;
}
.candles {
  position: absolute;
  left: 18%;
  right: 18%;
  bottom: 145px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}
.candle {
  width: 26px;
  height: 65px;
  border: 0;
  border-radius: 8px 8px 4px 4px;
  cursor: pointer;
  background: repeating-linear-gradient(90deg, #e990a7 0 5px, #fff5f2 5px 10px);
  position: relative;
  transition: opacity 0.2s;
}
.candle:before {
  content: "";
  width: 12px;
  height: 20px;
  position: absolute;
  left: 7px;
  top: -23px;
  border-radius: 50%;
  background: #ffc969;
  box-shadow: 0 0 18px 7px rgba(255, 194, 92, 0.65);
  animation: flicker 1.8s infinite alternate ease-in-out;
  transition: opacity 0.35s ease, transform 0.35s ease;
}
@keyframes flicker {
  0% { transform: scale(1) rotate(-2deg); opacity: 0.95; }
  100% { transform: scale(1.1) rotate(2deg); opacity: 1; }
}
.candle.off:before {
  opacity: 0;
  transform: scale(0.2);
}
.reset-button {
  min-height: 44px;
  padding: 11px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.85);
  color: var(--rose-deep);
  font-weight: 700;
  font-size: 0.9rem;
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}
.reset-button:hover {
  background: #ffffff;
  transform: translateY(-1px);
}
.wish {
  min-height: 28px;
  margin: 0;
  color: var(--rose-deep);
  font-weight: 700;
  font-size: 1.15rem;
}

/* Timeline */
.timeline {
  max-width: 820px;
  margin: auto;
  padding-left: 36px;
  position: relative;
  list-style: none;
}
.timeline:before {
  content: "";
  position: absolute;
  left: 8px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(var(--champagne), rgba(185, 90, 115, 0.15));
}
.timeline-item {
  position: relative;
  padding: 0 0 34px 28px;
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.timeline-item.visible {
  opacity: 1;
  transform: none;
}
.timeline-item:before {
  content: "";
  position: absolute;
  left: 0px;
  top: 8px;
  width: 16px;
  height: 16px;
  border: 3px solid var(--pearl);
  border-radius: 50%;
  background: var(--champagne);
  box-shadow: 0 0 8px rgba(216, 180, 119, 0.5);
}
.timeline-card {
  display: grid;
  grid-template-columns: 115px minmax(0, 1fr);
  gap: 18px;
  padding: 16px;
  border-radius: 20px;
}
.timeline-card.text-only {
  grid-template-columns: 1fr;
}
.timeline-card img {
  width: 115px;
  height: 115px;
  object-fit: cover;
  border-radius: 14px;
  background: var(--blush);
}
.timeline-date {
  font-size: 0.78rem;
  color: var(--rose-deep);
  letter-spacing: 0.12em;
  font-weight: 700;
  text-transform: uppercase;
}
.timeline-card h3 {
  margin: 0.35rem 0;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.35rem;
  color: var(--ink);
}
.timeline-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 0.95rem;
}

/* Surprise Drawer */
.surprise {
  padding: clamp(36px, 7vw, 60px) 24px;
  border-radius: 30px;
  text-align: center;
}
.surprise-message {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  color: var(--rose-deep);
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.5rem, 3.2vw, 2.3rem);
  line-height: 1.35;
  transition: max-height 0.6s ease, opacity 0.6s ease, margin 0.6s ease;
}
.surprise-message.open {
  max-height: 220px;
  margin-top: 24px;
  opacity: 1;
}

/* Sharing */
.share-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.share-button {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  color: var(--rose-deep);
  font-weight: 700;
}
.share-button:hover {
  background: #ffffff;
  color: var(--rose);
}

/* Footer */
.footer {
  padding: 42px var(--safe-r) calc(42px + env(safe-area-inset-bottom));
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
  border-top: 1px solid rgba(132, 54, 79, 0.08);
}

/* Modal & Lightbox */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top)) var(--safe-r) max(16px, env(safe-area-inset-bottom)) var(--safe-x);
  background: rgba(55, 33, 42, 0.6);
  backdrop-filter: blur(8px);
}
.modal.open {
  display: flex;
}
.modal-panel {
  width: min(100%, 760px);
  max-height: calc(100vh - 32px);
  overflow: auto;
  position: relative;
  padding: 20px;
  border-radius: 24px;
  background: #fffdf9;
  box-shadow: 0 32px 80px rgba(30, 13, 20, 0.35);
}
.modal-close {
  width: 44px;
  height: 44px;
  margin-left: auto;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #ffffff;
  cursor: pointer;
  color: var(--rose-deep);
  font-size: 1.3rem;
  transition: transform 0.2s;
}
.modal-close:hover {
  transform: scale(1.1);
}
.lightbox-image {
  width: 100%;
  max-height: 60vh;
  object-fit: contain;
  border-radius: 16px;
  background: var(--blush);
}
.modal-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

/* Real QR Code Presentation */
.qr-canvas-wrap {
  width: 190px;
  height: 190px;
  margin: 20px auto;
  padding: 10px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 30px rgba(104, 60, 78, 0.12);
  display: grid;
  place-items: center;
}
.qr-canvas-wrap canvas {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

/* Toast */
.toast {
  position: fixed;
  z-index: 1100;
  bottom: max(24px, env(safe-area-inset-bottom));
  left: 50%;
  max-width: calc(100% - 32px);
  transform: translateX(-50%);
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--ink);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.toast.show {
  opacity: 1;
}

/* Responsive Media Queries */
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-copy {
    margin-inline: auto;
  }
  .sound-control {
    justify-content: center;
  }
  .garden-art {
    width: min(100%, 420px);
    min-height: 260px;
    margin: auto;
  }
  .gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .gallery[data-count="1"], .gallery[data-count="2"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .gallery[data-count="1"] .memory-card {
    grid-column: 1 / -1;
    width: min(100%, 420px);
    justify-self: center;
  }
  .gallery[data-count="3"] .memory-card:first-child,
  .gallery[data-count="5"] .memory-card:first-child,
  .gallery[data-count="7"] .memory-card:first-child {
    grid-row: auto;
  }
  .countdown-grid {
    gap: 8px;
  }
  .count-box {
    padding: 16px 6px;
  }
}

@media (max-width: 420px) {
  .hero h1 {
    font-size: clamp(2.4rem, 13vw, 3.4rem);
  }
  .timeline {
    padding-left: 22px;
  }
  .timeline-item {
    padding-left: 20px;
  }
  .timeline-card {
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
  }
  .timeline-card img {
    width: 78px;
    height: 78px;
  }
  .timeline-card.text-only {
    grid-template-columns: 1fr;
  }
  .count-label {
    font-size: 0.68rem;
  }
}

@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;
  }
  .timeline-item {
    opacity: 1;
    transform: none;
  }
}

