/* ==========================================================================
   T-MOTHER-INFINITE-GRATITUDE: ROSE VELVET & CHAMPAGNE GOLD
   ========================================================================== */
:root {
  --bg-deep: #14070b;
  --bg-card: rgba(36, 12, 20, 0.78);
  --bg-card-hover: rgba(50, 16, 28, 0.92);
  --primary-rose: #f43f5e;
  --rose-glow: rgba(244, 63, 94, 0.45);
  --accent-gold: #fbbf24;
  --gold-glow: rgba(251, 191, 36, 0.4);
  --text-main: #fff1f2;
  --text-muted: #fda4af;
  --border-theme: rgba(244, 63, 94, 0.25);
  --border-gold: rgba(251, 191, 36, 0.3);
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, sans-serif;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--bg-deep);
  color: var(--text-main);
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Background Canvas Layers */
#petals-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

#confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 100;
  pointer-events: none;
}

/* Floating Audio Control */
.audio-ctrl {
  position: fixed;
  top: 1.25rem;
  right: 1.25rem;
  z-index: 50;
}

.audio-btn {
  background: rgba(36, 12, 20, 0.88);
  color: var(--accent-gold);
  border: 1px solid var(--border-gold);
  padding: 0.6rem 1.15rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  backdrop-filter: blur(12px);
  transition: all 0.25s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.audio-btn:hover {
  background: rgba(244, 63, 94, 0.2);
  border-color: var(--primary-rose);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px var(--rose-glow);
}

/* Passcode Modal Screen */
.passcode-modal {
  position: fixed;
  inset: 0;
  background: rgba(12, 3, 6, 0.96);
  backdrop-filter: blur(18px);
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.passcode-modal.unlocked {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.passcode-container {
  background: rgba(28, 9, 16, 0.95);
  border: 1px solid var(--border-theme);
  border-radius: 1.5rem;
  padding: 2.25rem 1.75rem;
  max-width: 360px;
  width: 100%;
  text-align: center;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6), 0 0 30px var(--rose-glow);
}

.passcode-icon {
  font-size: 2.75rem;
  margin-bottom: 0.75rem;
  display: inline-block;
  animation: floatHeart 3s ease-in-out infinite;
}

.passcode-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: var(--accent-gold);
  margin-bottom: 0.35rem;
}

.passcode-sub {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
}

.pin-display {
  display: flex;
  justify-content: center;
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.pin-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--primary-rose);
  background: transparent;
  transition: all 0.2s ease;
}

.pin-dot.filled {
  background: var(--accent-gold);
  border-color: var(--accent-gold);
  box-shadow: 0 0 12px var(--gold-glow);
  transform: scale(1.15);
}

.keypad-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}

.key-btn {
  background: rgba(45, 14, 25, 0.85);
  border: 1px solid var(--border-theme);
  color: var(--text-main);
  font-size: 1.25rem;
  font-weight: 600;
  padding: 0.85rem 0;
  border-radius: 0.85rem;
  cursor: pointer;
  transition: all 0.18s ease;
}

.key-btn:hover {
  background: rgba(244, 63, 94, 0.25);
  border-color: var(--primary-rose);
  transform: translateY(-2px);
}

.key-btn:active {
  transform: scale(0.96);
}

.key-btn.action-key {
  font-size: 0.95rem;
  color: var(--text-muted);
}

.bypass-btn {
  background: transparent;
  border: 1px dashed var(--border-gold);
  color: var(--accent-gold);
  font-size: 0.82rem;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
}

.bypass-btn:hover {
  background: rgba(251, 191, 36, 0.12);
}

/* Page Layout */
.page-container {
  position: relative;
  z-index: 10;
  max-width: 900px;
  margin: 0 auto;
  padding: 3.5rem 1.25rem 5rem;
}

/* Hero Section */
.hero-section {
  text-align: center;
  padding: 3rem 1rem 2.5rem;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid var(--border-theme);
  color: var(--accent-gold);
  padding: 0.4rem 1.1rem;
  border-radius: 9999px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(2.3rem, 6vw, 3.8rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
  color: #fff;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.title-highlight {
  background: linear-gradient(135deg, #fb7185, #fbbf24);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: block;
  font-style: italic;
}

.hero-desc {
  max-width: 620px;
  margin: 0 auto 2.5rem;
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* Interactive Golden Heart Stage */
.heart-stage-wrapper {
  margin: 2rem auto 1rem;
  text-align: center;
}

.heart-stage {
  position: relative;
  width: 160px;
  height: 160px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.heart-stage:hover {
  transform: scale(1.08);
}

.heart-stage:active {
  transform: scale(0.95);
}

.heart-ring-outer {
  position: absolute;
  inset: -15px;
  border-radius: 50%;
  border: 2px dashed rgba(251, 191, 36, 0.4);
  animation: spinSlow 20s linear infinite;
}

.heart-ring-inner {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid var(--primary-rose);
  opacity: 0.6;
  box-shadow: 0 0 25px var(--rose-glow);
  animation: pulseRing 3s ease-in-out infinite;
}

.heart-core {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #f43f5e, #881337);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), inset 0 0 15px rgba(251, 191, 36, 0.4);
  position: relative;
  z-index: 2;
}

.heart-core-icon {
  font-size: 3.2rem;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4));
  animation: pulseHeart 2s ease-in-out infinite;
}

.stage-caption {
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: var(--accent-gold);
  font-style: italic;
  font-weight: 500;
}

/* Quotes Section */
.quotes-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  margin: 3.5rem 0;
}

.quote-box {
  background: var(--bg-card);
  border: 1px solid var(--border-theme);
  border-radius: 1.25rem;
  padding: 1.75rem 1.5rem;
  position: relative;
  backdrop-filter: blur(8px);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.quote-box:hover {
  transform: translateY(-4px);
  border-color: var(--primary-rose);
  background: var(--bg-card-hover);
}

.quote-text {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-style: italic;
  color: #fff1f2;
  line-height: 1.65;
  margin-bottom: 0.75rem;
}

.quote-author {
  font-size: 0.85rem;
  color: var(--accent-gold);
  font-weight: 600;
  text-align: right;
}

/* Memories Section */
.section-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  text-align: center;
  color: #fff;
  margin-bottom: 0.4rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 2.25rem;
}

.memories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-bottom: 4rem;
}

.memory-card {
  background: var(--bg-card);
  border: 1px solid var(--border-theme);
  border-radius: 1.25rem;
  padding: 1.6rem 1.4rem;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}

.memory-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-gold);
  box-shadow: 0 8px 25px rgba(244, 63, 94, 0.2);
}

.mem-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.85rem;
}

.mem-icon {
  font-size: 1.75rem;
}

.mem-tag {
  background: rgba(251, 191, 36, 0.15);
  color: var(--accent-gold);
  border: 1px solid var(--border-gold);
  padding: 0.2rem 0.65rem;
  border-radius: 9999px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.mem-era {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.mem-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 0.6rem;
}

.mem-desc {
  font-size: 0.9rem;
  color: #fbcfe8;
  line-height: 1.6;
}

/* Letter Article */
.letter-article {
  background: rgba(24, 7, 13, 0.9);
  border: 1px solid var(--border-gold);
  border-radius: 1.5rem;
  padding: 2.75rem 2rem;
  margin-bottom: 3.5rem;
  position: relative;
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.5), inset 0 0 40px rgba(244, 63, 94, 0.08);
}

.letter-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-theme);
}

.letter-date {
  font-size: 0.85rem;
  color: var(--accent-gold);
  font-weight: 600;
}

.letter-badge {
  font-size: 0.78rem;
  background: rgba(244, 63, 94, 0.2);
  color: #fda4af;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
}

.letter-salutation {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  color: var(--accent-gold);
  margin-bottom: 1.5rem;
}

.letter-body p {
  font-size: 1.02rem;
  line-height: 1.8;
  color: #fdf2f8;
  margin-bottom: 1.25rem;
}

.letter-ps {
  margin-top: 1.75rem;
  padding: 1rem 1.25rem;
  background: rgba(244, 63, 94, 0.12);
  border-left: 3px solid var(--primary-rose);
  border-radius: 0.5rem;
  font-size: 0.95rem;
  color: #fda4af;
  font-style: italic;
}

.letter-sig {
  margin-top: 2rem;
  text-align: right;
}

.sig-title {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 0.25rem;
}

.sig-name {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--accent-gold);
  font-weight: 700;
}

/* Apology / Late Banner */
.apology-box {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.2), rgba(251, 191, 36, 0.15));
  border: 1px solid var(--border-gold);
  border-radius: 1.25rem;
  padding: 1.75rem 1.5rem;
  text-align: center;
  margin-bottom: 3.5rem;
}

.apology-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent-gold);
  margin-bottom: 0.5rem;
}

.apology-heading {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  color: #fff;
  margin-bottom: 0.5rem;
}

.apology-subtext {
  font-size: 0.92rem;
  color: #fbcfe8;
  max-width: 600px;
  margin: 0 auto;
}

/* Birthday Cake & Candles Section */
.cake-section {
  text-align: center;
  margin-bottom: 3.5rem;
  padding: 2.5rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-theme);
  border-radius: 1.5rem;
}

.cake-stage {
  display: inline-block;
  margin: 1.5rem auto 1.5rem;
  cursor: pointer;
}

.candles-row {
  display: flex;
  justify-content: center;
  gap: 1.75rem;
  margin-bottom: 0.35rem;
}

.candle {
  width: 14px;
  height: 52px;
  background: linear-gradient(180deg, #fbbf24, #f43f5e);
  border-radius: 6px 6px 2px 2px;
  position: relative;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.flame {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  width: 14px;
  height: 24px;
  background: radial-gradient(ellipse at bottom, #fff, #fbbf24 60%, #ea580c);
  border-radius: 50% 50% 20% 20%;
  box-shadow: 0 0 15px #fbbf24, 0 0 25px #ea580c;
  animation: flameFlicker 1.2s infinite alternate ease-in-out;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.candle.extinguished .flame {
  opacity: 0;
  transform: translateX(-50%) scale(0.2);
}

.cake-tier {
  width: 190px;
  height: 55px;
  background: linear-gradient(180deg, #be185d, #881337);
  border-radius: 12px 12px 6px 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4), inset 0 2px 8px rgba(251, 191, 36, 0.5);
  border: 1px solid var(--border-gold);
}

.blow-btn {
  background: linear-gradient(135deg, #f43f5e, #be185d);
  color: #fff;
  border: none;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 0.9rem 1.85rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 20px var(--rose-glow);
}

.blow-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(244, 63, 94, 0.6);
}

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

/* Connect / CTA Section */
.cta-section {
  text-align: center;
  padding: 2.5rem 1.5rem;
  background: rgba(30, 10, 18, 0.85);
  border: 1px solid var(--border-gold);
  border-radius: 1.5rem;
}

.cta-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: #fff;
  margin-bottom: 0.35rem;
}

.cta-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

.cta-row {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.6rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  transition: all 0.25s ease;
}

.btn-wa {
  background: #25d366;
  color: #0b2e13;
}

.btn-wa:hover {
  background: #20ba59;
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(37, 211, 102, 0.4);
}

.btn-ig {
  background: linear-gradient(135deg, #c13584, #e1306c);
  color: #fff;
}

.btn-ig:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(225, 48, 108, 0.4);
}

/* Animations */
@keyframes floatHeart {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes pulseHeart {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

@keyframes pulseRing {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.08); opacity: 0.9; }
}

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

@keyframes flameFlicker {
  0% { transform: translateX(-50%) rotate(-2deg) scale(1); }
  50% { transform: translateX(-50%) rotate(2deg) scale(1.08); }
  100% { transform: translateX(-50%) rotate(-1deg) scale(0.95); }
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .page-container {
    padding: 2rem 1rem 4rem;
  }
  .hero-section {
    padding: 1.5rem 0.5rem;
  }
  .letter-article {
    padding: 1.75rem 1.25rem;
  }
  .keypad-grid {
    gap: 0.45rem;
  }
  .key-btn {
    padding: 0.75rem 0;
    font-size: 1.15rem;
  }
  .cake-tier {
    width: 160px;
    height: 48px;
    font-size: 1rem;
  }
}
