:root {
  --ivory: #FDFBF7;
  --rose-deep: #8A3A59;
  --rose-mid: #A64B77;
  --rose-soft: #C95F8A;
  --rose-light: #E888AA;
  --rose-pale: #F7A3BE;
  --rose-whisper: #FDF0F4;
  --blush: #FCECED;
  --green-deep: #3D5E42;
  --green-mid: #557A5A;
  --green-soft: #6B8E70;
  --green-light: #84A98C;
  --green-pale: #A3D4AE;
  --green-whisper: #D4EDDA;
  --taupe: #8C6B77;
  --warm-shadow: rgba(138, 58, 89, 0.15);
  --pink-400: #F687B3;
}

/* ═══════════════════════════════════════
   INTRO PAGE STYLES
   ═══════════════════════════════════════ */
body[data-page="intro"] {
  background-color: var(--ivory);
  color: #4A5568;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
  font-family: 'Nunito', sans-serif;
  position: relative;
  transition: background-color 1s ease;
}

/* ═══════════════════════════════════════
   LOADING
   ═══════════════════════════════════════ */
.loading-screen {
  position: fixed;
  inset: 0;
  background: var(--ivory);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 99999;
}
.loading-screen.hidden { display: none; }
.loading-flower {
  width: 60px; height: 60px;
  animation: spin 2s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text {
  margin-top: 16px;
  font-size: 16px;
  font-weight: 600;
  color: var(--rose-deep);
}

/* ═══════════════════════════════════════
   SCENE
   ═══════════════════════════════════════ */
#intro-scene {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.background-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 30%, rgba(242, 142, 173, 0.10) 0%, transparent 55%),
    radial-gradient(circle at 30% 70%, rgba(132, 169, 140, 0.06) 0%, transparent 50%),
    radial-gradient(circle at 70% 60%, rgba(201, 95, 138, 0.05) 0%, transparent 45%);
  pointer-events: none;
}

.vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, transparent 40%, rgba(135, 42, 91, 0.04) 100%);
  pointer-events: none;
}

.noise-overlay {
  position: absolute;
  inset: 0;
  opacity: 0.05;
  z-index: 1;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

.bottom-mist {
  position: absolute;
  bottom: 0; left: 0;
  width: 100%; height: 40vh;
  background: linear-gradient(to top,
    rgba(253, 251, 247, 1) 5%,
    rgba(253, 251, 247, 0.8) 20%,
    rgba(253, 251, 247, 0) 100%);
  z-index: 3;
  pointer-events: none;
}

.foreground-depth {
  position: absolute;
  bottom: -5%; left: 0;
  width: 100%; height: 30vh;
  pointer-events: none;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  opacity: 0.35;
  filter: blur(6px);
}
.foreground-depth svg {
  width: 45vw; max-width: 300px; height: auto;
  fill: var(--green-light);
  transform-origin: bottom center;
}

/* ═══════════════════════════════════════
   FLOWER CONTAINER
   ═══════════════════════════════════════ */
.flower-container {
  position: relative;
  width: 100%;
  max-width: 450px;
  height: 55vh;
  min-height: 400px;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

#hero-flower {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 20px 40px rgba(138, 58, 89, 0.12))
          drop-shadow(0 8px 16px rgba(61, 94, 66, 0.08));
}

/* ═══════════════════════════════════════
   SVG ANIMATIONS
   ═══════════════════════════════════════ */
@keyframes gentleSway {
  0%, 100% { transform: rotate(0deg); }
  25%      { transform: rotate(0.6deg); }
  75%      { transform: rotate(-0.6deg); }
}

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

@keyframes dewGlisten {
  0%, 100% { opacity: 0.5; }
  50%      { opacity: 1; }
}

@keyframes floatingMote {
  0%   { transform: translateY(0) scale(1); opacity: 0; }
  15%  { opacity: 0.7; }
  85%  { opacity: 0.5; }
  100% { transform: translateY(-60px) scale(0.4); opacity: 0; }
}

@keyframes leafSway {
  0%, 100% { transform: rotate(0deg) scaleX(1); }
  50%      { transform: rotate(0.8deg) scaleX(1.01); }
}

@keyframes stemBreath {
  0%, 100% { stroke-width: 5.5; }
  50%      { stroke-width: 6; }
}

@keyframes auraBreath {
  0%, 100% { opacity: 0.15; transform: scale(1); }
  50%      { opacity: 0.25; transform: scale(1.05); }
}

#hero-plant-group {
  transform-origin: 150px 400px;
  animation: gentleSway 6s ease-in-out infinite;
}

#hero-bloom {
  transform-origin: 0 0;
  animation: petalBreath 5s ease-in-out infinite;
}

#hero-leaf-left {
  transform-origin: 150px 370px;
  animation: leafSway 7s ease-in-out infinite;
}

#hero-leaf-right {
  transform-origin: 150px 340px;
  animation: leafSway 7s ease-in-out infinite reverse;
}

#hero-leaf-small-left {
  transform-origin: 148px 290px;
  animation: leafSway 6s ease-in-out infinite reverse;
}

#hero-leaf-small-right {
  transform-origin: 151px 385px;
  animation: leafSway 6s ease-in-out infinite;
}

.hero-dew {
  animation: dewGlisten 3s ease-in-out infinite;
}
.hero-dew:nth-of-type(2) { animation-delay: 1s; }
.hero-dew:nth-of-type(3) { animation-delay: 2s; }

.hero-mote {
  animation: floatingMote 5s ease-out infinite;
}

/* ═══════════════════════════════════════
   TEXT
   ═══════════════════════════════════════ */
.text-container {
  text-align: center;
  z-index: 4;
  padding-bottom: 2rem;
  min-height: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

#hero-title {
  font-family: 'Dancing Script', cursive;
  font-size: 3.8rem;
  color: var(--rose-deep);
  margin: 0;
  opacity: 0;
  transform: translateY(20px);
  font-weight: 700;
  letter-spacing: 0.02em;
  text-shadow: 0 4px 20px rgba(138, 58, 89, 0.1);
}

#hero-subtitle {
  font-family: 'Nunito', sans-serif;
  font-size: 1.15rem;
  color: var(--taupe);
  margin: 0;
  opacity: 0;
  transform: translateY(20px);
  font-weight: 600;
  letter-spacing: 0.03em;
}

/* ═══════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════ */
#tap-hint {
  position: absolute;
  bottom: 8%;
  font-family: 'Nunito', sans-serif;
  font-size: 1.1rem;
  color: var(--taupe);
  opacity: 0.8;
  animation: gentlePulse 3s infinite ease-in-out;
  cursor: pointer;
  padding: 1rem 2rem;
  z-index: 10;
  letter-spacing: 0.05em;
  background: none;
  border: none;
}

@keyframes gentlePulse {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50%      { opacity: 0.9; transform: scale(1.02); }
}

#hero-cta {
  position: absolute;
  bottom: 6%;
  background: rgba(252, 236, 240, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(242, 142, 173, 0.5);
  color: #7A2E4D;
  padding: 1rem 3.5rem;
  border-radius: 50px;
  font-family: 'Nunito', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  cursor: pointer;
  box-shadow: 0 8px 25px var(--warm-shadow),
              inset 0 0 0 1px rgba(255,255,255,0.8);
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
  transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 10;
}

#hero-cta:hover {
  background: rgba(255, 245, 248, 1);
  box-shadow: 0 12px 30px rgba(138, 58, 89, 0.2),
              inset 0 0 0 1px rgba(255,255,255,1);
  transform: translateY(-3px) scale(1.02) !important;
  border-color: rgba(242, 142, 173, 0.8);
  color: #5C1E36;
}

.particle {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
}

/* ═══════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════ */
@media (max-width: 480px) {
  #hero-title { font-size: 2.8rem; }
  #hero-subtitle { font-size: 1rem; }
  .flower-container { height: 50vh; min-height: 320px; }
  #hero-cta { padding: 0.85rem 2.5rem; font-size: 1rem; }
}

@media (max-height: 700px) {
  .flower-container { height: 45vh; min-height: 280px; }
  .text-container { padding-bottom: 1rem; }
  #hero-title { font-size: 2.6rem; }
}
