/* ==========================================================================
   PENSANDO EN TI, CARITO — STYLESHEET RESPONSIVE
   Aesthetic: Melancólico-cursi, sofisticado, nocturno & editorial
   100% Adaptable para Móviles (iPhone, Android), Tablets y Laptops
   ========================================================================== */

:root {
  /* Color Palette */
  --bg-dark: #09080e;
  --bg-card: rgba(22, 18, 30, 0.78);
  --bg-card-border: rgba(235, 195, 175, 0.15);
  --bg-card-highlight: rgba(255, 255, 255, 0.05);

  --accent-rose: #e6859d;
  --accent-rose-glow: rgba(230, 133, 157, 0.35);
  --accent-blush: #f7d2db;
  --accent-gold: #e2ba7d;
  --accent-gold-glow: rgba(226, 186, 125, 0.28);
  --accent-wine: #5c182b;
  
  --text-main: #fbf8f5;
  --text-secondary: #c9c1d5;
  --text-muted: #857e95;

  /* Typography */
  --font-serif: "Cormorant Garamond", Georgia, serif;
  --font-display: "Cinzel", serif;
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-cursive: "Italianno", cursive;

  /* Transitions */
  --ease-smooth: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --transition-fast: 0.22s ease;
  --transition-normal: 0.45s var(--ease-smooth);
  --transition-slow: 0.85s var(--ease-smooth);
}

/* Base Reset & Box Model */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  height: 100%;
  background-color: var(--bg-dark);
  overflow-x: hidden;
}

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

/* Background Atmosphere & Canvases */
#ambient-canvas,
#rain-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
}

#ambient-canvas {
  z-index: 1;
}

#rain-canvas {
  z-index: 25;
}

.vignette-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 50% 40%, rgba(26, 18, 38, 0.45) 0%, rgba(9, 8, 14, 0.95) 85%);
  pointer-events: none;
  z-index: 2;
}

.grain-overlay {
  position: fixed;
  inset: 0;
  opacity: 0.035;
  pointer-events: none;
  z-index: 3;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* ==========================================================================
   NAVIGATION BAR (RESPONSIVE HEADER)
   ========================================================================== */
.narrative-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 1.8rem;
  background: linear-gradient(180deg, rgba(9, 8, 14, 0.92) 0%, rgba(9, 8, 14, 0.6) 75%, rgba(9, 8, 14, 0) 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  gap: 0.5rem;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 0.92rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-blush);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}

.nav-star {
  color: var(--accent-gold);
  font-size: 0.8rem;
  animation: starPulse 3s infinite ease-in-out;
}

.nav-steps {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  background: rgba(22, 17, 30, 0.65);
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.step-indicator {
  background: transparent;
  border: none;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  cursor: pointer;
  padding: 0.25rem 0.35rem;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 0.76rem;
  transition: all var(--transition-fast);
}

.step-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-muted);
  transition: all var(--transition-normal);
}

.step-label {
  display: none;
}

@media (min-width: 820px) {
  .step-label {
    display: inline-block;
  }
}

.step-indicator.active {
  color: var(--accent-blush);
}

.step-indicator.active .step-dot {
  background: var(--accent-rose);
  box-shadow: 0 0 10px var(--accent-rose-glow), 0 0 18px var(--accent-rose-glow);
  transform: scale(1.35);
}

.ambient-audio-ctrl {
  display: flex;
  align-items: center;
}

.audio-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.audio-btn:hover {
  background: rgba(230, 133, 157, 0.18);
  border-color: var(--accent-rose);
  color: var(--accent-blush);
  transform: scale(1.05);
}

.audio-btn svg {
  width: 17px;
  height: 17px;
}

.audio-btn .off-icon {
  display: none;
}

.audio-btn.muted .on-icon {
  display: none;
}

.audio-btn.muted .off-icon {
  display: block;
}

/* ==========================================================================
   LAYOUT CONTAINERS & SECTIONS
   ========================================================================== */
.story-container {
  position: relative;
  z-index: 10;
  width: 100%;
}

.story-section {
  min-height: 100vh;
  min-height: 100svh;
  padding: 5.8rem 1.4rem 4rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  width: 100%;
}

.section-content {
  width: 100%;
  max-width: 780px;
  margin: 0 auto;
}

.text-center {
  text-align: center;
}

/* ==========================================================================
   TYPOGRAPHY & TAGS
   ========================================================================== */
.subheading-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  margin-bottom: 1.3rem;
  max-width: 100%;
}

.tag-line {
  display: inline-block;
  width: 28px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-gold));
  flex-shrink: 0;
}

.subheading-tag .tag-line:last-child {
  background: linear-gradient(90deg, var(--accent-gold), transparent);
}

.tag-text {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
  text-align: center;
  line-height: 1.4;
}

.section-badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-rose);
  background: rgba(230, 133, 157, 0.1);
  border: 1px solid rgba(230, 133, 157, 0.25);
  padding: 0.32rem 0.95rem;
  border-radius: 999px;
  margin-bottom: 1.1rem;
}

.main-title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5.8vw, 4.2rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--text-main);
  margin-bottom: 1.4rem;
}

.serif-italic {
  font-style: italic;
  font-weight: 300;
}

.gradient-text {
  background: linear-gradient(135deg, #fff2f5 20%, #f7c3d1 60%, #deb1c0 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.hero-paragraph {
  font-size: clamp(0.96rem, 2vw, 1.2rem);
  color: var(--text-secondary);
  font-weight: 300;
  max-width: 580px;
  margin: 0 auto 2.2rem;
  line-height: 1.75;
}

.section-title {
  font-family: var(--font-serif);
  font-size: clamp(1.85rem, 4.4vw, 3rem);
  font-weight: 400;
  line-height: 1.2;
  color: var(--text-main);
  margin-bottom: 0.9rem;
}

.section-description {
  font-size: clamp(0.92rem, 1.8vw, 1.1rem);
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 2rem;
  line-height: 1.7;
}

.soft-quote {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.05em;
  color: var(--accent-blush);
  margin-top: 0.6rem;
  opacity: 0.92;
}

/* ==========================================================================
   BUTTONS & CTAs
   ========================================================================== */
.cta-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.primary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, #e5879e 0%, #bd4b69 100%);
  color: #ffffff;
  border: none;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  padding: 0.95rem 2.2rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: 0 8px 28px rgba(189, 75, 105, 0.38);
  max-width: 100%;
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 36px rgba(230, 133, 157, 0.55);
}

.pulse-glow {
  animation: gentlePulse 2.8s infinite ease-in-out;
}

.btn-arrow {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  transition: transform var(--transition-fast);
}

.primary-btn:hover .btn-arrow,
.secondary-btn:hover .btn-arrow {
  transform: translateX(4px);
}

.cta-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
  text-align: center;
}

.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: rgba(30, 24, 42, 0.75);
  border: 1px solid rgba(230, 133, 157, 0.3);
  color: var(--accent-blush);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  cursor: pointer;
  backdrop-filter: blur(12px);
  transition: all var(--transition-fast);
  max-width: 100%;
}

.secondary-btn:hover {
  background: rgba(230, 133, 157, 0.16);
  border-color: var(--accent-rose);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(230, 133, 157, 0.25);
}

/* ==========================================================================
   ACTO 2: FLOWER GARDEN CANVAS
   ========================================================================== */
.flowers-stage-wrapper {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.flower-canvas-box {
  width: 100%;
  height: 480px;
  max-height: 60vh;
  background: radial-gradient(circle at 50% 60%, rgba(35, 23, 48, 0.75) 0%, rgba(14, 11, 20, 0.95) 85%);
  border: 1px solid var(--bg-card-border);
  border-radius: 28px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.65), 0 0 40px rgba(189, 75, 105, 0.12);
  margin-bottom: 1.8rem;
  cursor: crosshair;
}

#flower-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.flower-interactive-hint {
  position: absolute;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(14, 11, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  font-size: 0.74rem;
  color: var(--accent-blush);
  pointer-events: none;
  backdrop-filter: blur(8px);
  max-width: 88%;
  text-align: center;
  line-height: 1.3;
  z-index: 5;
}

.sparkle-icon {
  color: var(--accent-gold);
  flex-shrink: 0;
  animation: starPulse 2s infinite ease-in-out;
}

.flower-controls {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  left: 1rem;
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  flex-wrap: wrap;
  z-index: 5;
}

.glass-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(22, 17, 30, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--text-secondary);
  font-size: 0.76rem;
  font-family: var(--font-sans);
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  cursor: pointer;
  backdrop-filter: blur(10px);
  transition: all var(--transition-fast);
}

.glass-pill-btn:hover {
  background: rgba(230, 133, 157, 0.2);
  border-color: var(--accent-rose);
  color: var(--accent-blush);
}

.step-transition-btn-box {
  margin-top: 0.5rem;
  text-align: center;
  width: 100%;
}

/* ==========================================================================
   ACTO 3: ENVELOPE & LETTER (RESPONSIVE 3D)
   ========================================================================== */
.letter-section-content {
  max-width: 680px;
}

.envelope-outer-scene {
  perspective: 1200px;
  margin: 1.5rem auto 2.2rem;
  width: 100%;
  max-width: 580px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.envelope-card {
  position: relative;
  width: 100%;
  min-height: 320px;
  background: linear-gradient(145deg, #1d1828 0%, #151020 100%);
  border-radius: 18px;
  border: 1px solid rgba(226, 186, 125, 0.22);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 35px rgba(226, 186, 125, 0.08);
  cursor: pointer;
  transition: transform 0.6s var(--ease-smooth);
}

.envelope-card:hover:not(.opened) {
  transform: translateY(-4px) scale(1.01);
}

/* Flap of the envelope */
.envelope-flap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 52%;
  background: linear-gradient(180deg, #251f33 0%, #1b1626 100%);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: top center;
  transition: transform 0.85s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 5;
  border-top-left-radius: 18px;
  border-top-right-radius: 18px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.wax-seal {
  position: absolute;
  top: calc(52% - 26px);
  left: 50%;
  transform: translateX(-50%);
  width: 52px;
  height: 52px;
  background: radial-gradient(circle at 35% 35%, #d94164 0%, #7d1931 85%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.75), 0 0 24px rgba(230, 83, 120, 0.5);
  cursor: pointer;
  border: 2px solid rgba(255, 215, 225, 0.45);
  z-index: 15;
  transition: transform 0.4s var(--ease-spring), opacity 0.4s ease;
}

.wax-seal:hover {
  transform: translateX(-50%) scale(1.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.8), 0 0 32px rgba(230, 83, 120, 0.7);
}

.seal-symbol {
  color: #ffccd7;
  font-size: 1.35rem;
  line-height: 1;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.seal-glow {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px dashed rgba(226, 186, 125, 0.55);
  animation: rotateGlow 14s infinite linear;
}

.seal-tap-label {
  position: absolute;
  top: calc(52% + 34px);
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.74rem;
  font-family: var(--font-display);
  letter-spacing: 0.14em;
  color: var(--accent-gold);
  white-space: nowrap;
  pointer-events: none;
  opacity: 0.95;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9);
  z-index: 15;
  transition: opacity 0.3s ease;
}

.envelope-card.opened .seal-tap-label {
  opacity: 0;
  pointer-events: none;
}

.envelope-front {
  position: absolute;
  inset: 0;
  padding: 3rem 1.8rem 1.8rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(0deg, rgba(14, 11, 20, 0.85) 0%, rgba(14, 11, 20, 0.1) 60%);
  border-radius: 18px;
}

.envelope-address {
  border-top: 1px dashed rgba(255, 255, 255, 0.15);
  padding-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.to-label {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.15em;
  color: var(--accent-gold);
  text-transform: uppercase;
}

.to-name {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.35rem;
  color: var(--text-main);
  word-break: break-word;
}

.to-subname {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.95rem;
  color: var(--accent-rose);
  opacity: 0.9;
  word-break: break-word;
}

.to-date {
  font-size: 0.76rem;
  color: var(--text-muted);
}

/* The actual physical letter paper */
.letter-paper {
  position: relative;
  width: 94%;
  margin: 0 auto;
  background: linear-gradient(180deg, #faf7f2 0%, #f3ede2 100%);
  color: #27212b;
  border-radius: 12px;
  padding: 2.6rem 2rem 2rem;
  box-shadow: 0 15px 45px rgba(0, 0, 0, 0.5), inset 0 0 35px rgba(226, 186, 125, 0.18);
  border: 1px solid rgba(226, 186, 125, 0.5);
  z-index: 6;
  opacity: 0;
  transform: translateY(30px) scale(0.96);
  pointer-events: none;
  transition: transform 0.85s var(--ease-smooth), opacity 0.6s ease;
  cursor: default;
  word-wrap: break-word;
}

.letter-top-accent {
  text-align: center;
  margin-bottom: 1.1rem;
}

.letter-emblem {
  color: #b08447;
  font-size: 1.1rem;
}

.letter-salutation {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 600;
  color: #1f1a26;
  margin-bottom: 1.1rem;
}

.letter-main-statement {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  line-height: 1.65;
  color: #241d2d;
  font-style: italic;
  font-weight: 500;
  padding: 1.1rem 1.3rem;
  background: rgba(189, 75, 105, 0.06);
  border-left: 3px solid #b83d58;
  border-radius: 4px;
  margin-bottom: 1.3rem;
}

.letter-reflection,
.letter-closing-thought {
  font-family: var(--font-serif);
  font-size: 1.12rem;
  line-height: 1.7;
  color: #3b3344;
  margin-bottom: 1.1rem;
}

.letter-signature {
  margin-top: 1.8rem;
  padding-top: 1.1rem;
  border-top: 1px dashed rgba(60, 40, 50, 0.2);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.signature-block {
  display: flex;
  flex-direction: column;
}

.signature-note {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.12rem;
  color: #3b3344;
  line-height: 1.3;
}

.signature-to {
  font-family: var(--font-cursive);
  font-size: 2.2rem;
  color: #8c1f3b;
  line-height: 1;
}

.signature-flourish {
  font-size: 1.3rem;
  color: #a8425b;
}

.letter-action-bar {
  margin-top: 1.6rem;
  text-align: right;
}

.fold-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(40, 30, 50, 0.08);
  border: 1px solid rgba(40, 30, 50, 0.18);
  color: #4f435c;
  font-size: 0.76rem;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.fold-btn:hover {
  background: rgba(40, 30, 50, 0.16);
  color: #1f1a26;
}

/* State when envelope is OPENED */
.envelope-card.opened {
  cursor: default;
}

.envelope-card.opened .envelope-flap {
  transform: rotateX(180deg);
  z-index: 1;
}

.envelope-card.opened .wax-seal {
  opacity: 0;
  transform: translateX(-50%) scale(1.3);
  pointer-events: none;
}

.envelope-card.opened .letter-paper {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(-40px) scale(1);
  box-shadow: 0 30px 75px rgba(0, 0, 0, 0.65);
}

@media (min-width: 680px) {
  .envelope-card.opened .letter-paper {
    transform: translateY(-70px) scale(1.02);
  }
}

/* ==========================================================================
   ACTO 4: SPOTIFY & MUSIC SHOWCASE
   ========================================================================== */
.music-section-content {
  max-width: 660px;
}

.music-card-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 28px;
  padding: 2.4rem 1.6rem;
  box-shadow: 0 25px 65px rgba(0, 0, 0, 0.6), 0 0 35px rgba(189, 75, 105, 0.1);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  margin-bottom: 1.8rem;
}

.vinyl-display-box {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 2.2rem;
  height: 190px;
}

.vinyl-jacket {
  position: relative;
  z-index: 2;
  width: 165px;
  height: 165px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.7);
  background: linear-gradient(135deg, #1b1725 0%, #0d0a14 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  transform: translateX(-25px);
  transition: transform var(--transition-normal);
}

.jacket-art {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.1rem;
  background: linear-gradient(180deg, rgba(30, 20, 45, 0.3) 0%, rgba(10, 7, 16, 0.95) 100%);
}

.jacket-tag {
  font-family: var(--font-display);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  color: var(--accent-gold);
  margin-bottom: 0.2rem;
}

.jacket-title {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  color: #fff;
  line-height: 1.1;
  font-style: italic;
}

.jacket-artist {
  font-size: 0.74rem;
  color: var(--text-secondary);
  letter-spacing: 0.08em;
}

/* Vinyl Disc */
.vinyl-disc {
  position: absolute;
  z-index: 1;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, #222 0%, #080808 85%);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateX(45px);
  animation: spinVinyl 16s linear infinite;
  border: 2px solid #111;
}

.vinyl-grooves {
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.07);
  box-shadow: 
    inset 0 0 0 12px rgba(255, 255, 255, 0.015),
    inset 0 0 0 24px rgba(255, 255, 255, 0.025),
    inset 0 0 0 38px rgba(255, 255, 255, 0.015),
    inset 0 0 0 52px rgba(255, 255, 255, 0.02);
}

.vinyl-center-label {
  position: relative;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a33550 0%, #571322 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.vinyl-artist {
  font-size: 0.52rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.1em;
}

.vinyl-title {
  font-size: 0.44rem;
  color: var(--accent-blush);
  letter-spacing: 0.05em;
}

.vinyl-hole {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #09080e;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Lyrics Card */
.lyrics-card {
  position: relative;
  padding: 1.3rem 1.6rem;
  margin-bottom: 1.8rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.quote-mark {
  position: absolute;
  top: 0.2rem;
  left: 0.8rem;
  font-family: var(--font-serif);
  font-size: 2.8rem;
  color: rgba(230, 133, 157, 0.2);
  line-height: 1;
}

.lyric-quote {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-style: italic;
  color: var(--accent-blush);
  line-height: 1.5;
  margin-bottom: 0.4rem;
}

.lyric-sub {
  font-size: 0.76rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}

/* Spotify Embed & Direct Link */
.spotify-embed-container {
  margin-bottom: 1.5rem;
  width: 100%;
}

.spotify-direct-cta {
  display: flex;
  justify-content: center;
}

.spotify-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: #1ed760;
  color: #000000;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  padding: 0.88rem 1.6rem;
  border-radius: 999px;
  text-decoration: none;
  transition: all var(--transition-fast);
  box-shadow: 0 8px 24px rgba(30, 215, 96, 0.3);
  max-width: 100%;
  text-align: center;
}

.spotify-btn:hover {
  background: #24e569;
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(30, 215, 96, 0.45);
}

.spotify-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.external-icon {
  opacity: 0.75;
  flex-shrink: 0;
}

.spotify-note {
  margin-top: 1rem;
  font-size: 0.76rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

/* ==========================================================================
   ACTO 5: FAREWELL & GOODNIGHT
   ========================================================================== */
.farewell-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--bg-card-border);
  border-radius: 32px;
  padding: 3.2rem 1.8rem 2.6rem;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.65), 0 0 45px rgba(226, 186, 125, 0.12);
}

.night-glow-orb {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(189, 75, 105, 0.18) 0%, rgba(9, 8, 14, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
  filter: blur(40px);
}

.farewell-constellation {
  font-family: var(--font-display);
  font-size: 0.82rem;
  letter-spacing: 0.4em;
  color: var(--accent-gold);
  display: block;
  margin-bottom: 0.9rem;
}

.farewell-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4.8vw, 3.4rem);
  font-style: italic;
  font-weight: 400;
  color: var(--text-main);
  margin-bottom: 1.1rem;
}

.farewell-message {
  font-size: clamp(0.96rem, 1.9vw, 1.16rem);
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: 520px;
  margin: 0 auto 2.2rem;
  font-weight: 300;
}

.farewell-heart-button-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.8rem;
  width: 100%;
}

.heart-pulse-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: rgba(230, 133, 157, 0.12);
  border: 1px solid rgba(230, 133, 157, 0.35);
  color: var(--accent-blush);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.85rem 1.7rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all var(--transition-fast);
  max-width: 100%;
}

.heart-pulse-btn:hover {
  background: rgba(230, 133, 157, 0.25);
  transform: scale(1.03);
  box-shadow: 0 0 25px rgba(230, 133, 157, 0.4);
}

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

.heart-emoji {
  font-size: 1.25rem;
  animation: heartThrob 1.6s infinite ease-in-out;
}

.heart-counter {
  font-size: 0.76rem;
  color: var(--accent-gold);
  min-height: 1.2em;
  text-align: center;
  padding: 0 0.5rem;
}

.quick-reply-wrapper {
  margin-bottom: 1.8rem;
}

.reply-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.84rem;
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all var(--transition-fast);
  max-width: 100%;
  text-align: center;
}

.reply-link:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
}

.restart-tour-box {
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  padding-top: 1.3rem;
}

.text-link-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.78rem;
  cursor: pointer;
  letter-spacing: 0.05em;
  transition: color var(--transition-fast);
}

.text-link-btn:hover {
  color: var(--accent-blush);
}

/* Floating Heart Burst Particles */
.floating-heart {
  position: fixed;
  pointer-events: none;
  z-index: 1000;
  font-size: 1.4rem;
  user-select: none;
  animation: floatHeart 2.4s ease-out forwards;
}

/* ==========================================================================
   ANIMATIONS & KEYFRAMES
   ========================================================================== */
@keyframes starPulse {
  0%, 100% { opacity: 0.4; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); }
}

@keyframes gentlePulse {
  0%, 100% { box-shadow: 0 8px 26px rgba(189, 75, 105, 0.38); }
  50% { box-shadow: 0 12px 42px rgba(230, 133, 157, 0.65); }
}

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

@keyframes spinVinyl {
  from { transform: translateX(45px) rotate(0deg); }
  to { transform: translateX(45px) rotate(360deg); }
}

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

@keyframes floatHeart {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(0.8) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translate(var(--tx, 0px), -180px) scale(1.4) rotate(var(--rot, 25deg));
  }
}

/* Entrance Animations */
.fade-in-up {
  opacity: 1;
  animation: fadeInUp 0.9s var(--ease-smooth) both;
}

.delay-1 { animation-delay: 0.15s; }
.delay-2 { animation-delay: 0.3s; }
.delay-3 { animation-delay: 0.45s; }

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================================================
   MEDIA QUERIES — RESPONSIVE ADAPTATIONS (MOBILE, TABLET, SMALL HEIGHT)
   ========================================================================== */

/* Pantallas medianas y móviles (< 768px) */
@media (max-width: 768px) {
  .narrative-nav {
    padding: 0.85rem 1.1rem;
  }
  .story-section {
    padding: 5rem 1.1rem 3.5rem;
  }
  .main-title {
    font-size: 2.2rem;
  }
  .section-title {
    font-size: 1.85rem;
  }
  .flower-canvas-box {
    height: 380px;
    max-height: 52vh;
  }
  .envelope-card {
    min-height: 290px;
  }
  .envelope-card.opened .letter-paper {
    transform: translateY(-25px) scale(1);
  }
  .letter-paper {
    padding: 2.2rem 1.3rem 1.6rem;
  }
  .letter-main-statement {
    font-size: 1.14rem;
    padding: 0.9rem 1rem;
  }
  .signature-to {
    font-size: 1.9rem;
  }
}

/* Móviles compactos (< 480px) */
@media (max-width: 480px) {
  .narrative-nav {
    padding: 0.65rem 0.85rem;
  }
  .nav-brand {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
  }
  .nav-steps {
    padding: 0.25rem 0.55rem;
    gap: 0.55rem;
  }
  .step-indicator {
    padding: 0.15rem;
  }
  .audio-btn {
    width: 32px;
    height: 32px;
  }
  .audio-btn svg {
    width: 15px;
    height: 15px;
  }
  .story-section {
    padding: 4.6rem 0.85rem 3rem;
  }
  .main-title {
    font-size: 1.95rem;
    margin-bottom: 1.1rem;
  }
  .hero-paragraph {
    font-size: 0.94rem;
    margin-bottom: 1.8rem;
  }
  .primary-btn {
    width: 100%;
    padding: 0.88rem 1.4rem;
    font-size: 0.9rem;
  }
  .secondary-btn {
    width: 100%;
    padding: 0.82rem 1.2rem;
    font-size: 0.88rem;
  }
  .flower-canvas-box {
    height: 350px;
    border-radius: 20px;
  }
  .flower-interactive-hint {
    font-size: 0.68rem;
    padding: 0.3rem 0.75rem;
    top: 0.75rem;
  }
  .flower-controls {
    justify-content: center;
    bottom: 0.75rem;
    left: 0.5rem;
    right: 0.5rem;
    gap: 0.4rem;
  }
  .glass-pill-btn {
    font-size: 0.7rem;
    padding: 0.38rem 0.7rem;
  }
  .envelope-card {
    border-radius: 14px;
    min-height: 270px;
  }
  .envelope-front {
    padding: 2.2rem 1.2rem 1.4rem;
  }
  .to-name {
    font-size: 1.15rem;
  }
  .to-subname {
    font-size: 0.85rem;
  }
  .letter-paper {
    padding: 1.9rem 1.1rem 1.4rem;
    width: 96%;
  }
  .letter-salutation {
    font-size: 1.25rem;
  }
  .letter-main-statement {
    font-size: 1.08rem;
    padding: 0.8rem 0.9rem;
  }
  .letter-reflection,
  .letter-closing-thought {
    font-size: 1rem;
    line-height: 1.6;
  }
  .signature-note {
    font-size: 1rem;
  }
  .signature-to {
    font-size: 1.7rem;
  }
  .envelope-card.opened .letter-paper {
    transform: translateY(-15px) scale(1);
  }
  .music-card-wrapper {
    padding: 1.8rem 1.1rem;
    border-radius: 20px;
  }
  .vinyl-display-box {
    height: 145px;
    margin-bottom: 1.6rem;
  }
  .vinyl-jacket {
    width: 125px;
    height: 125px;
    transform: translateX(-15px);
  }
  .vinyl-disc {
    width: 120px;
    height: 120px;
    transform: translateX(25px);
  }
  @keyframes spinVinyl {
    from { transform: translateX(25px) rotate(0deg); }
    to { transform: translateX(25px) rotate(360deg); }
  }
  .spotify-btn {
    font-size: 0.84rem;
    padding: 0.8rem 1.1rem;
    width: 100%;
  }
  .farewell-card {
    padding: 2.2rem 1.1rem 1.8rem;
    border-radius: 22px;
  }
  .farewell-title {
    font-size: 1.85rem;
  }
  .farewell-message {
    font-size: 0.94rem;
  }
  .heart-pulse-btn {
    font-size: 0.88rem;
    padding: 0.8rem 1.2rem;
    width: 100%;
  }
  .reply-link {
    font-size: 0.8rem;
    width: 100%;
  }
}

/* Pantallas con poca altura (ej. teléfonos en horizontal o laptops con barras de herramientas) */
@media (max-height: 680px) {
  .story-section {
    padding-top: 4.8rem;
    padding-bottom: 2.8rem;
    justify-content: flex-start;
  }
  .flower-canvas-box {
    height: 310px;
  }
  .vinyl-display-box {
    height: 140px;
  }
}

/* ==========================================================================
   FLOATING FLOWER RAIN BUTTON (PERSISTENT EN ESQUINA INFERIOR)
   ========================================================================== */
.floating-rain-btn {
  position: fixed;
  bottom: 1.8rem;
  right: 1.8rem;
  z-index: 75;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: rgba(28, 18, 38, 0.88);
  border: 1px solid rgba(230, 133, 157, 0.45);
  color: var(--accent-blush);
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  padding: 0.72rem 1.25rem;
  border-radius: 999px;
  cursor: pointer;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65), 0 0 24px rgba(230, 133, 157, 0.35);
  transition: all var(--transition-normal);
  user-select: none;
}

.floating-rain-btn:hover {
  background: rgba(230, 133, 157, 0.22);
  border-color: var(--accent-rose);
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.7), 0 0 32px rgba(230, 133, 157, 0.6);
}

.floating-rain-btn:active {
  transform: translateY(-1px) scale(0.97);
}

.rain-btn-icon {
  font-size: 1.15rem;
  animation: gentleRotate 6s infinite ease-in-out;
}

@keyframes gentleRotate {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(18deg) scale(1.15); }
}

@media (max-width: 640px) {
  .floating-rain-btn {
    bottom: 1.2rem;
    right: 1.2rem;
    padding: 0.6rem 1.05rem;
    font-size: 0.78rem;
    gap: 0.45rem;
  }
}

@media (max-width: 400px) {
  .floating-rain-btn {
    bottom: 1rem;
    right: 1rem;
    padding: 0.55rem 0.9rem;
  }
  .rain-btn-text {
    font-size: 0.74rem;
  }
}
