/* =========================================================
   KISAH CINTA H & H (HIMAM & HILDA) - STYLESHEET
   Aesthetics: Luxury Romantic Storybook, Glassmorphism & Micro-animations
   ========================================================= */

:root {
  /* Color Palette */
  --bg-dark: #0c0814;
  --bg-gradient: radial-gradient(circle at 50% 20%, #2b1035 0%, #150921 50%, #0a0512 100%);
  --rose-primary: #f43f5e;
  --rose-light: #fb7185;
  --rose-deep: #be123c;
  --gold-primary: #fbbf24;
  --gold-light: #fef08a;
  --gold-glow: rgba(251, 191, 36, 0.4);
  --purple-accent: #a855f7;
  --blue-himam: #3b82f6;
  --pink-hilda: #ec4899;
  
  /* Glassmorphism Variables */
  --glass-bg: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.12);
  --glass-blur: blur(16px);
  --glass-shadow: 0 12px 40px rgba(0, 0, 0, 0.45), 0 0 20px rgba(244, 63, 94, 0.15);

  /* Typography */
  --font-romantic: 'Dancing Script', cursive;
  --font-serif: 'Playfair Display', Georgia, serif;
  --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Transitions */
  --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* ================= Global Reset & Setup ================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  min-height: 100%;
  background: var(--bg-dark);
  background-image: var(--bg-gradient);
  color: #f8fafc;
  font-family: var(--font-sans);
  overflow-x: hidden;
  scroll-behavior: smooth;
}

/* Background Canvas for Starfield & Hearts */
#ambient-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* ================= Audio Player Button ================= */
.audio-control-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 999;
}

.glass-pill-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-radius: 50px;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  transition: var(--transition-smooth);
}

.glass-pill-btn:hover {
  background: rgba(244, 63, 94, 0.25);
  border-color: var(--rose-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(244, 63, 94, 0.35);
}

.sound-wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 14px;
}

.sound-wave span {
  display: inline-block;
  width: 3px;
  height: 100%;
  background-color: var(--rose-light);
  border-radius: 2px;
  animation: wave 1.2s ease-in-out infinite alternate;
  transform-origin: bottom;
}

.sound-wave span:nth-child(1) { animation-delay: 0.1s; height: 40%; }
.sound-wave span:nth-child(2) { animation-delay: 0.3s; height: 90%; }
.sound-wave span:nth-child(3) { animation-delay: 0.2s; height: 60%; }
.sound-wave span:nth-child(4) { animation-delay: 0.4s; height: 100%; }

.sound-wave.paused span {
  animation-play-state: paused;
  height: 20% !important;
  opacity: 0.5;
}

@keyframes wave {
  0% { transform: scaleY(0.2); }
  100% { transform: scaleY(1); }
}

/* ================= SCENE 1: 3D BOOK COVER INTRO ================= */
.book-intro-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #2e1038 0%, #11071c 60%, #06020c 100%);
  perspective: 1600px;
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1), visibility 1s;
}

.book-intro-screen.zoom-open {
  transform: scale(2.2);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.book-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

/* 3D Realistic Book Styling */
.book-3d {
  position: relative;
  width: 320px;
  height: 460px;
  transform-style: preserve-3d;
  transform: rotateY(-18deg) rotateX(8deg);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.6s ease;
  cursor: pointer;
}

.book-3d:hover {
  transform: rotateY(-8deg) rotateX(4deg) translateY(-8px);
}

.book-spine {
  position: absolute;
  top: 0;
  left: 0;
  width: 32px;
  height: 100%;
  background: linear-gradient(90deg, #420d1a 0%, #881337 50%, #420d1a 100%);
  border-radius: 8px 0 0 8px;
  transform: rotateY(90deg) translateZ(-16px) translateX(-16px);
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.8);
}

.book-pages-side {
  position: absolute;
  top: 10px;
  right: -16px;
  width: 22px;
  height: calc(100% - 20px);
  background: repeating-linear-gradient(
    0deg,
    #fffbf0,
    #fffbf0 2px,
    #dfd3c3 2px,
    #dfd3c3 4px
  );
  border-radius: 0 4px 4px 0;
  transform: rotateY(90deg) translateZ(10px) translateX(10px);
  box-shadow: 4px 0 10px rgba(0, 0, 0, 0.4);
}

.book-cover {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 40% 30%, #a21caf 0%, #701a75 35%, #4c0519 80%, #2b040e 100%);
  border-radius: 6px 16px 16px 6px;
  box-shadow: 
    -10px 15px 35px rgba(0, 0, 0, 0.7),
    0 0 30px rgba(244, 63, 94, 0.3),
    inset 0 0 25px rgba(0, 0, 0, 0.8);
  border: 1px solid rgba(251, 191, 36, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px 24px;
  overflow: hidden;
  user-select: none;
}

/* Embossed Gold Border */
.cover-emboss-border {
  position: absolute;
  inset: 16px;
  border: 2px solid rgba(251, 191, 36, 0.65);
  border-radius: 8px;
  box-shadow: 
    inset 0 0 12px rgba(251, 191, 36, 0.3),
    0 0 8px rgba(251, 191, 36, 0.2);
  pointer-events: none;
}

.cover-emboss-border::after {
  content: '';
  position: absolute;
  inset: 6px;
  border: 1px dashed rgba(251, 191, 36, 0.4);
  border-radius: 4px;
}

/* Golden Corner Ornaments */
.cover-corner {
  position: absolute;
  width: 22px;
  height: 22px;
  border: 3px solid var(--gold-primary);
  pointer-events: none;
}
.cover-corner.top-left { top: 22px; left: 22px; border-right: none; border-bottom: none; }
.cover-corner.top-right { top: 22px; right: 22px; border-left: none; border-bottom: none; }
.cover-corner.bottom-left { bottom: 22px; left: 22px; border-right: none; border-top: none; }
.cover-corner.bottom-right { bottom: 22px; right: 22px; border-left: none; border-top: none; }

/* Ribbon Bookmark Hanging Out */
.ribbon-bookmark {
  position: absolute;
  top: 0;
  right: 40px;
  width: 20px;
  height: 70px;
  background: linear-gradient(180deg, #f43f5e, #be123c);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 85%, 0 100%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.cover-content {
  position: relative;
  z-index: 2;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.cover-sub-badge {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 4px;
  font-weight: 700;
  color: var(--gold-light);
  text-transform: uppercase;
  text-shadow: 0 0 8px var(--gold-glow);
}

.monogram-wrapper {
  position: relative;
  margin: 10px 0;
}

.monogram-glow {
  position: absolute;
  inset: -15px;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.35) 0%, transparent 70%);
  filter: blur(12px);
  z-index: -1;
  animation: pulseGlow 3s ease-in-out infinite alternate;
}

.monogram-title {
  font-family: var(--font-serif);
  font-size: 3.8rem;
  font-weight: 800;
  letter-spacing: 2px;
  background: linear-gradient(135deg, #fff 0%, #fef08a 35%, #fbbf24 60%, #f59e0b 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 12px rgba(251, 191, 36, 0.4));
  line-height: 1;
}

.monogram-names {
  font-family: var(--font-romantic);
  font-size: 2.1rem;
  color: #fff;
  text-shadow: 0 2px 10px rgba(244, 63, 94, 0.8);
  margin-top: 4px;
}

.cover-decor-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 75%;
}

.cover-decor-divider .line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
}

.cover-decor-divider .heart-symbol {
  font-size: 1.1rem;
  animation: heartbeat 1.6s ease-in-out infinite;
}

.cover-quote {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: #fed7aa;
  font-style: italic;
  max-width: 220px;
  line-height: 1.4;
}

.open-book-pulse-btn {
  position: relative;
  margin-top: 14px;
  padding: 12px 28px;
  background: linear-gradient(135deg, #f43f5e 0%, #e11d48 50%, #9f1239 100%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50px;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(225, 29, 72, 0.6);
  transition: var(--transition-bounce);
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 8px;
}

.open-book-pulse-btn:hover {
  transform: scale(1.06);
  box-shadow: 0 12px 35px rgba(225, 29, 72, 0.85);
}

.btn-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
  transform: skewX(-25deg);
  animation: shineLoop 3s infinite;
}

.hint-text {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
  font-style: italic;
  letter-spacing: 0.5px;
  animation: floatHint 2.5s ease-in-out infinite alternate;
}

/* ================= MAIN STORY INTERFACE ================= */
.main-story-container {
  position: relative;
  z-index: 10;
  opacity: 1;
  transition: opacity 0.8s ease;
  padding-bottom: 80px;
}

.main-story-container.hidden {
  display: none;
  opacity: 0;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Glassmorphism Generic Card */
.glass-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-radius: 24px;
  box-shadow: var(--glass-shadow);
  padding: 32px;
  position: relative;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.glass-card:hover {
  border-color: rgba(244, 63, 94, 0.35);
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.55), 0 0 25px rgba(244, 63, 94, 0.25);
}

/* Floating Navbar */
.story-header {
  position: sticky;
  top: 15px;
  z-index: 90;
  margin: 0 auto 30px auto;
  max-width: 900px;
  width: calc(100% - 40px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  border-radius: 50px;
  background: rgba(20, 11, 31, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-monogram {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--gold-light);
  letter-spacing: 1px;
}

.brand-divider {
  color: rgba(255, 255, 255, 0.2);
}

.brand-desc {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 500;
}

.sparkle-btn {
  background: linear-gradient(135deg, #f43f5e 0%, #ec4899 100%);
  border: none;
  padding: 8px 18px;
  border-radius: 30px;
  color: white;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(244, 63, 94, 0.4);
  transition: var(--transition-smooth);
}

.sparkle-btn:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 8px 25px rgba(244, 63, 94, 0.6);
}

/* Story Section Shared */
.story-section {
  padding: 60px 0;
  position: relative;
}

.section-title-wrap {
  margin-bottom: 45px;
}

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

.script-subtitle {
  font-family: var(--font-romantic);
  font-size: 2.2rem;
  color: var(--rose-light);
  display: block;
  margin-bottom: 4px;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, #fff 0%, #fed7aa 60%, #fda4af 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 12px;
}

.section-desc {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  border-radius: 50px;
  color: var(--rose-light);
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 24px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--rose-primary);
  border-radius: 50%;
  animation: pulseDot 1.5s infinite;
}

/* ================= SECTION 1: 13 OKTOBER & LOVE ROBOT ================= */
.date-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: stretch;
}

/* Calendar Card */
.calendar-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(244, 63, 94, 0.08) 100%);
}

.calendar-header {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 14px;
}

.calendar-year {
  font-size: 0.85rem;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--gold-light);
}

.calendar-body {
  text-align: center;
  padding: 24px 0;
}

.calendar-month {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 4px;
  color: var(--rose-light);
}

.calendar-day {
  font-family: var(--font-serif);
  font-size: 6.5rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, #ffffff 0%, #fecdd3 50%, #f43f5e 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 6px 20px rgba(244, 63, 94, 0.4));
  margin: 6px 0;
}

.calendar-love-stamp {
  display: inline-block;
  padding: 6px 18px;
  background: rgba(225, 29, 72, 0.2);
  border: 1px dashed var(--rose-primary);
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.85rem;
  color: #fff;
  letter-spacing: 1.5px;
  transform: rotate(-3deg);
}

.calendar-footer {
  text-align: center;
  margin-top: 14px;
}

.quote-date {
  font-family: var(--font-romantic);
  font-size: 1.5rem;
  color: #fbcfe8;
  line-height: 1.3;
}

/* Days Together Counter */
.days-together-counter {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.counter-label {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 12px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.counter-values {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.time-block {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 10px 4px;
  text-align: center;
}

.time-block span {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--gold-light);
}

.time-block label {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
}

/* Robot Card */
.robot-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 16px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.07) 0%, rgba(168, 85, 247, 0.08) 100%);
}

.robot-speech-bubble {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 12px 20px;
  border-radius: 18px;
  border-bottom-left-radius: 4px;
  font-size: 0.95rem;
  color: #fff;
  max-width: 320px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  position: relative;
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.love-robot-container {
  width: 190px;
  height: 230px;
}

.love-robot-svg {
  width: 100%;
  height: 100%;
  animation: robotHover 3.5s ease-in-out infinite;
}

.robot-antenna-bulb {
  animation: antennaPulse 1.2s infinite alternate;
}

.robot-chest-heart {
  animation: heartbeat 1.3s infinite;
  transform-origin: 100px 157px;
}

.robot-arm-right {
  animation: waveArm 2s ease-in-out infinite alternate;
  transform-origin: 140px 140px;
}

.floating-balloon-heart {
  animation: balloonSway 3s ease-in-out infinite alternate;
  transform-origin: 25px 25px;
}

.robot-thruster {
  animation: thrusterFlicker 0.3s infinite alternate;
}

.glass-pill-sm {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 18px;
  border-radius: 30px;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.glass-pill-sm:hover {
  background: rgba(244, 63, 94, 0.25);
  border-color: var(--rose-light);
  transform: translateY(-2px);
}

/* ================= SECTION 2: TUGU MALANG & UMM ================= */
.landmarks-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.landmark-card {
  padding: 0;
  display: flex;
  flex-direction: column;
}

.landmark-artwork {
  width: 100%;
  height: 220px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.landmark-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.tugu-flame-glow {
  animation: flameGlow 1.8s infinite alternate;
}

.twinkle-star-1 { animation: starTwinkle 2s infinite ease-in-out; }
.twinkle-star-2 { animation: starTwinkle 3s infinite ease-in-out 0.5s; }
.twinkle-star-3 { animation: starTwinkle 2.5s infinite ease-in-out 1s; }

.floating-campus-heart-1 {
  animation: floatUpSlow 4s infinite linear;
}
.floating-campus-heart-2 {
  animation: floatUpSlow 5s infinite linear 1.5s;
}

.landmark-info {
  padding: 24px;
}

.landmark-tag {
  font-size: 0.75rem;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--gold-light);
  margin-bottom: 6px;
}

.landmark-name {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 10px;
}

.landmark-quote {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.55;
  font-style: italic;
}

/* ================= SECTION 3: INFORMATIKA & PSIKOLOGI ================= */
.faculties-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  align-items: center;
}

.faculty-card {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.faculty-role-badge {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--gold-light);
}

.himam-card {
  border-top: 3px solid var(--blue-himam);
}

.hilda-card {
  border-top: 3px solid var(--pink-hilda);
}

.faculty-icon-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tech-symbol, .psy-symbol {
  font-size: 2.2rem;
  font-weight: 800;
  font-family: monospace;
}

.tech-symbol {
  color: var(--blue-himam);
  text-shadow: 0 0 15px rgba(59, 130, 246, 0.6);
}

.psy-symbol {
  color: var(--pink-hilda);
  text-shadow: 0 0 15px rgba(236, 72, 153, 0.6);
}

.binary-stream {
  font-family: monospace;
  font-size: 0.72rem;
  color: rgba(59, 130, 246, 0.7);
  letter-spacing: 1px;
}

.psycho-keywords {
  font-size: 0.8rem;
  color: rgba(236, 72, 153, 0.85);
  font-weight: 500;
}

/* Code Terminal Mockup */
.terminal-mockup {
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  overflow: hidden;
  font-family: 'Courier New', Courier, monospace;
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: #1e293b;
}

.terminal-bar .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot.red { background: #ef4444; }
.dot.yellow { background: #eab308; }
.dot.green { background: #22c55e; }

.terminal-title {
  margin-left: 10px;
  font-size: 0.75rem;
  color: #94a3b8;
}

.terminal-body {
  padding: 14px;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #e2e8f0;
}

.keyword { color: #f43f5e; font-weight: bold; }
.string { color: #38bdf8; }
.comment { color: #64748b; font-style: italic; }

/* Psychology Mind Card */
.mind-heart-mockup {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(236, 72, 153, 0.2);
  border-radius: 12px;
  padding: 16px;
}

.psycho-stats {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-name {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.8);
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar .fill {
  height: 100%;
  background: linear-gradient(90deg, #ec4899, #f43f5e);
  border-radius: 4px;
  animation: barPulse 2s ease-in-out infinite alternate;
}

.serotonin-badge {
  margin-top: 14px;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: #fbcfe8;
  padding: 6px;
  background: rgba(236, 72, 153, 0.15);
  border-radius: 8px;
}

.faculty-bridge {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
  padding: 10px;
}

.bridge-heart {
  font-size: 2.2rem;
  animation: heartbeat 1.2s infinite;
}

.bridge-text {
  font-size: 0.7rem;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--gold-light);
  white-space: nowrap;
  background: rgba(0, 0, 0, 0.4);
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.faculty-text p {
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.5;
  font-style: italic;
}

/* ================= SECTION 4: CHARACTERS (LONCAT, KETAWA, PELUKAN) ================= */
.stage-arena {
  padding: 40px 20px;
  position: relative;
  background: radial-gradient(circle at center, rgba(244, 63, 94, 0.12) 0%, rgba(20, 11, 31, 0.8) 75%);
}

.characters-play-field {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 80px;
  min-height: 320px;
  position: relative;
  margin-bottom: 30px;
  transition: all 0.6s ease;
}

.character-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s ease;
}

.char-nametag {
  font-size: 0.85rem;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.5);
  padding: 4px 14px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  margin-bottom: 8px;
  color: #fff;
}

.char-emotion-bubble {
  position: absolute;
  top: -45px;
  background: rgba(255, 255, 255, 0.95);
  color: #0f172a;
  padding: 6px 14px;
  border-radius: 14px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  animation: bubbleFloat 2s ease-in-out infinite alternate;
}

.chibi-character-svg {
  width: 140px;
  height: 200px;
}

/* Himam Jumping Animation */
.boy-character {
  animation: himamJump 1.1s cubic-bezier(0.28, 0.84, 0.42, 1) infinite;
}

@keyframes himamJump {
  0%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-38px) rotate(-3deg);
  }
  60% {
    transform: translateY(-44px) rotate(2deg);
  }
}

.boy-character .char-shadow {
  animation: shadowShrink 1.1s infinite;
  transform-origin: 80px 210px;
}

@keyframes shadowShrink {
  0%, 100% { transform: scale(1); opacity: 0.25; }
  50% { transform: scale(0.6); opacity: 0.1; }
}

/* Hilda Giggling Animation */
.girl-character {
  animation: hildaGiggle 0.9s ease-in-out infinite alternate;
}

@keyframes hildaGiggle {
  0% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-10px) rotate(-4deg);
  }
  100% {
    transform: translateY(-5px) rotate(4deg);
  }
}

.girl-hands-giggle {
  animation: giggleHands 0.4s ease-in-out infinite alternate;
  transform-origin: 80px 80px;
}

@keyframes giggleHands {
  0% { transform: translateY(0); }
  100% { transform: translateY(-4px); }
}

/* HUG SCENE & STATES */
.characters-play-field.is-hugging .boy-character {
  transform: translateX(110px) scale(0.8);
  opacity: 0;
  pointer-events: none;
}

.characters-play-field.is-hugging .girl-character {
  transform: translateX(-110px) scale(0.8);
  opacity: 0;
  pointer-events: none;
}

.hug-scene-container {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: hugFadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hug-scene-container.hidden {
  display: none;
}

.hug-svg {
  width: 200px;
  height: 190px;
  filter: drop-shadow(0 10px 25px rgba(244, 63, 94, 0.5));
  animation: hugSway 2.5s ease-in-out infinite alternate;
}

.beating-hug-heart {
  animation: heartbeat 0.9s infinite;
  transform-origin: 120px 42px;
}

.hug-message {
  margin-top: 14px;
}

.hug-message h3 {
  font-family: var(--font-romantic);
  font-size: 2.1rem;
  color: var(--rose-light);
  margin-bottom: 4px;
}

.hug-message p {
  font-size: 0.95rem;
  color: #fbcfe8;
}

/* Stage Action Controls */
.stage-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.hug-magic-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 34px;
  background: linear-gradient(135deg, #f43f5e 0%, #be123c 100%);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50px;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(244, 63, 94, 0.5);
  transition: var(--transition-bounce);
}

.hug-magic-btn:hover {
  transform: scale(1.05) translateY(-3px);
  box-shadow: 0 12px 40px rgba(244, 63, 94, 0.7);
}

.btn-heart-icon {
  font-size: 1.3rem;
}

/* ================= SECTION 5: "KU-KU-KU" WORDS OF ENDEARMENT ================= */
.love-cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-bottom: 40px;
}

.love-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 36px 28px;
}

.hilda-love-card {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.08) 0%, rgba(20, 11, 31, 0.8) 100%);
  border-color: rgba(244, 63, 94, 0.3);
}

.himam-love-card {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(20, 11, 31, 0.8) 100%);
  border-color: rgba(59, 130, 246, 0.3);
}

.love-card-badge {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--gold-light);
  margin-bottom: 16px;
}

.avatar-circle {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.avatar-emoji {
  font-size: 2.2rem;
}

.love-person-name {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 18px;
}

.tags-cloud {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.love-tag {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #fed7aa;
  transition: var(--transition-smooth);
  cursor: pointer;
}

.love-tag:hover {
  transform: translateY(-2px) scale(1.05);
  background: rgba(244, 63, 94, 0.3);
  border-color: var(--rose-light);
  color: #fff;
}

.love-tag.pulse-tag {
  border-color: var(--rose-primary);
  color: #fff;
}

.love-tag.highlight-tag {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.3), rgba(251, 191, 36, 0.3));
  border-color: var(--gold-primary);
  color: var(--gold-light);
}

.love-letter-quote {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 16px;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 24px;
}

.love-letter-quote p {
  font-family: var(--font-romantic);
  font-size: 1.35rem;
  color: #ffe4e6;
  line-height: 1.5;
}

.love-pop-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 10px 22px;
  border-radius: 30px;
  color: #fff;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.love-pop-btn:hover {
  background: var(--rose-primary);
  border-color: var(--rose-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(244, 63, 94, 0.4);
}

/* Secret Message Box */
.interactive-envelope-box {
  max-width: 650px;
  margin: 0 auto;
  cursor: pointer;
  background: radial-gradient(circle at center, rgba(251, 191, 36, 0.08) 0%, rgba(20, 11, 31, 0.9) 80%);
  border-color: rgba(251, 191, 36, 0.3);
}

.envelope-icon {
  font-size: 3.5rem;
  display: inline-block;
  margin-bottom: 10px;
  animation: envelopeWiggle 2.5s ease-in-out infinite;
  transition: transform 0.3s;
}

.envelope-icon:hover {
  transform: scale(1.15);
}

.envelope-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--gold-light);
  margin-bottom: 6px;
}

.envelope-desc {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}

.secret-message-box {
  margin-top: 20px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px dashed var(--gold-primary);
  border-radius: 16px;
  animation: fadeInDown 0.5s ease;
}

.secret-message-box.hidden {
  display: none;
}

.message-content {
  font-family: var(--font-romantic);
  font-size: 1.6rem;
  color: #fef08a;
  line-height: 1.4;
}

/* ================= FOOTER ================= */
.story-footer {
  padding-top: 40px;
}

.footer-stars {
  font-size: 1.4rem;
  letter-spacing: 6px;
  margin-bottom: 12px;
}

.footer-names {
  font-family: var(--font-serif);
  font-size: 2rem;
  color: var(--gold-light);
  margin-bottom: 6px;
}

.footer-tagline {
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 16px;
}

.footer-copyright {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 24px;
}

.reopen-link {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 8px 20px;
  border-radius: 30px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.82rem;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.reopen-link:hover {
  color: #fff;
  border-color: var(--rose-light);
  background: rgba(244, 63, 94, 0.2);
}

/* ================= KEYFRAME ANIMATIONS ================= */
@keyframes pulseGlow {
  0% { transform: scale(0.95); opacity: 0.5; }
  100% { transform: scale(1.08); opacity: 0.85; }
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.18); }
  35% { transform: scale(1.04); }
  45% { transform: scale(1.15); }
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.4; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.2); }
}

@keyframes floatHint {
  0% { transform: translateY(0); opacity: 0.6; }
  100% { transform: translateY(-6px); opacity: 0.9; }
}

@keyframes shineLoop {
  0% { left: -100%; }
  20%, 100% { left: 150%; }
}

@keyframes robotHover {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes antennaPulse {
  0% { fill: #f43f5e; filter: drop-shadow(0 0 2px #f43f5e); }
  100% { fill: #fda4af; filter: drop-shadow(0 0 8px #f43f5e); }
}

@keyframes waveArm {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(20deg); }
}

@keyframes balloonSway {
  0% { transform: rotate(-5deg); }
  100% { transform: rotate(8deg); }
}

@keyframes thrusterFlicker {
  0% { opacity: 0.6; rx: 14px; }
  100% { opacity: 1; rx: 18px; }
}

@keyframes starTwinkle {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.3); }
}

@keyframes flameGlow {
  0% { filter: drop-shadow(0 0 4px #fbbf24); }
  100% { filter: drop-shadow(0 0 12px #fef08a); }
}

@keyframes floatUpSlow {
  0% { transform: translateY(0); opacity: 0.8; }
  100% { transform: translateY(-40px); opacity: 0; }
}

@keyframes barPulse {
  0% { opacity: 0.85; }
  100% { opacity: 1; filter: drop-shadow(0 0 6px #f43f5e); }
}

@keyframes bubbleFloat {
  0% { transform: translateY(0); }
  100% { transform: translateY(-5px); }
}

@keyframes hugFadeIn {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes hugSway {
  0% { transform: rotate(-2deg); }
  100% { transform: rotate(2deg); }
}

@keyframes envelopeWiggle {
  0%, 100% { transform: rotate(0); }
  20% { transform: rotate(-8deg); }
  40% { transform: rotate(8deg); }
  60% { transform: rotate(-4deg); }
  80% { transform: rotate(4deg); }
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Floating Click Hearts Effect */
.click-heart-particle {
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  font-size: 1.5rem;
  animation: floatClickHeart 1.4s ease-out forwards;
}

@keyframes floatClickHeart {
  0% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(0.5);
  }
  50% {
    transform: translate(calc(-50% + var(--dx, 0px)), calc(-50% - 60px)) scale(1.3);
  }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--dx, 0px)), calc(-50% - 120px)) scale(1);
  }
}

/* ================= RESPONSIVE MEDIA QUERIES ================= */
@media (max-width: 900px) {
  .date-hero-grid,
  .landmarks-grid,
  .love-cards-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .faculties-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .faculty-bridge {
    flex-direction: row;
    padding: 10px 0;
  }

  .characters-play-field {
    gap: 30px;
  }

  .chibi-character-svg {
    width: 120px;
    height: 180px;
  }

  .characters-play-field.is-hugging .boy-character {
    transform: translateX(60px) scale(0.6);
  }

  .characters-play-field.is-hugging .girl-character {
    transform: translateX(-60px) scale(0.6);
  }
}

@media (max-width: 540px) {
  .book-3d {
    width: 280px;
    height: 420px;
  }

  .monogram-title {
    font-size: 3.2rem;
  }

  .monogram-names {
    font-size: 1.8rem;
  }

  .calendar-day {
    font-size: 5rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .script-subtitle {
    font-size: 1.8rem;
  }

  .story-header {
    width: calc(100% - 24px);
    padding: 10px 16px;
  }

  .brand-desc {
    display: none;
  }

  .characters-play-field {
    gap: 15px;
  }

  .chibi-character-svg {
    width: 105px;
    height: 160px;
  }

  .char-emotion-bubble {
    font-size: 0.72rem;
    padding: 4px 8px;
    top: -38px;
  }

  .glass-card {
    padding: 22px 16px;
    border-radius: 18px;
  }
}
