@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Inter:wght@300;400;500;600&family=Playfair+Display:ital,wght@0,400;0,600;0,700;1,400&display=swap');

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

:root {
  --pink: #e84393;
  --rose: #d63384;
  --gold: #c7854a;
  --soft-pink: #f472b6;
  --deep-purple: #7c3aed;
  --lavender: #c084fc;
  --bg: #fff5f7;
  --bg-warm: #ffeef3;
  --text: #3d1f2e;
  --text-soft: rgba(61, 31, 46, 0.55);
  --text-muted: rgba(61, 31, 46, 0.35);
  --glass: rgba(255, 255, 255, 0.55);
  --glass-border: rgba(232, 67, 147, 0.12);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  cursor: none;
}

/* ===== CUSTOM CURSOR ===== */
#cursor-trail {
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
}

/* ===== NOISE TEXTURE ===== */
.noise-overlay {
  position: fixed;
  inset: 0;
  z-index: 9990;
  pointer-events: none;
  opacity: 0.018;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px;
}

/* ===== PRELOADER ===== */
#preloader {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  transition: opacity 1s cubic-bezier(0.4, 0, 0, 1), visibility 1s;
}
#preloader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.preloader-outer-ring {
  position: absolute;
  width: 130px;
  height: 130px;
  border-radius: 50%;
  border: 1px solid rgba(232, 67, 147, 0.1);
  animation: spin 6s linear infinite reverse;
  top: calc(50% - 65px - 28px);
  left: calc(50% - 65px);
}
.preloader-ring {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 2px solid rgba(232, 67, 147, 0.1);
  border-top-color: var(--pink);
  border-right-color: var(--gold);
  animation: spin 1.2s linear infinite;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 40px rgba(232, 67, 147, 0.12);
}
.preloader-heart {
  font-size: 36px;
  animation: pulse 1.5s ease-in-out infinite, spin 8s linear infinite reverse;
}
.preloader-text {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 15px;
  color: var(--text-soft);
  margin-top: 28px;
  letter-spacing: 1px;
  min-height: 24px;
}
.preloader-progress {
  width: 120px;
  height: 2px;
  background: rgba(232, 67, 147, 0.08);
  border-radius: 2px;
  margin-top: 16px;
  overflow: hidden;
}
.preloader-bar {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--pink), var(--soft-pink));
  border-radius: 2px;
  transition: width 0.3s ease;
}

/* ===== AURORA ===== */
.aurora {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  opacity: 0.5;
}
.aurora-band {
  position: absolute;
  width: 200%;
  height: 300px;
  filter: blur(80px);
  opacity: 0.4;
  animation: auroraWave 12s ease-in-out infinite alternate;
}
.aurora-1 {
  background: linear-gradient(90deg, transparent 10%, rgba(244, 114, 182, 0.2) 30%, rgba(192, 132, 252, 0.15) 50%, rgba(251, 191, 213, 0.2) 70%, transparent 90%);
  top: -50px;
  left: -50%;
  animation-duration: 12s;
}
.aurora-2 {
  background: linear-gradient(90deg, transparent 20%, rgba(192, 132, 252, 0.12) 40%, rgba(244, 114, 182, 0.15) 60%, transparent 80%);
  top: 100px;
  left: -30%;
  animation-duration: 15s;
  animation-delay: -3s;
}
.aurora-3 {
  background: linear-gradient(90deg, transparent 15%, rgba(251, 191, 213, 0.15) 35%, rgba(244, 114, 182, 0.12) 55%, rgba(192, 132, 252, 0.1) 75%, transparent 95%);
  top: 50px;
  left: -40%;
  animation-duration: 18s;
  animation-delay: -6s;
}

/* ===== MESH GRADIENT BACKGROUND ===== */
.mesh-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.mesh-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.2;
  animation: orbFloat 20s ease-in-out infinite;
  will-change: transform;
}
.mesh-orb-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(244, 114, 182, 0.4), transparent 70%);
  top: -10%; left: -10%;
}
.mesh-orb-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(192, 132, 252, 0.35), transparent 70%);
  top: 50%; right: -15%;
  animation-delay: -5s;
  animation-duration: 25s;
}
.mesh-orb-3 {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(251, 191, 213, 0.4), transparent 70%);
  bottom: -10%; left: 30%;
  animation-delay: -10s;
  animation-duration: 22s;
}
.mesh-orb-4 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(244, 114, 182, 0.3), transparent 70%);
  top: 20%; right: 20%;
  animation-delay: -15s;
  animation-duration: 18s;
}

/* ===== CANVAS ===== */
#stars-canvas, #particles-canvas {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}
#particles-canvas { z-index: 2; }

/* ===== FLOATING EMOJIS ===== */
#floating-emojis {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}
.float-emoji {
  position: absolute;
  bottom: -60px;
  opacity: 0;
  font-size: 20px;
  animation: floatEmoji linear infinite;
  filter: blur(0.5px);
}
@keyframes floatEmoji {
  0% { opacity: 0; transform: translateY(0) rotate(0deg) scale(0.6); }
  10% { opacity: 0.5; }
  85% { opacity: 0.2; }
  100% { opacity: 0; transform: translateY(-105vh) rotate(360deg) scale(1.1); }
}

/* ===== LANDING ===== */
.landing-container {
  position: relative;
  z-index: 3;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  gap: 36px;
}

/* Decorative line */
.deco-line {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, transparent, var(--pink), transparent);
  opacity: 0;
  animation: fadeIn 1s ease 0.3s forwards;
}

/* ===== HEADER ===== */
.landing-header {
  text-align: center;
}

.landing-tag {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 8px;
  text-transform: uppercase;
  color: var(--rose);
  opacity: 0;
  animation: fadeInUp 0.8s ease 0.5s forwards;
  text-shadow: 0 0 20px rgba(232, 67, 147, 0.15);
}

.landing-title {
  font-family: 'Great Vibes', cursive;
  font-size: clamp(60px, 14vw, 130px);
  background: linear-gradient(135deg, var(--pink), var(--deep-purple), var(--soft-pink), var(--rose));
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 6s ease-in-out infinite, fadeInUp 1s ease 0.7s both;
  filter: drop-shadow(0 0 40px rgba(232, 67, 147, 0.1));
  line-height: 1.3;
  margin-top: 8px;
  padding-top: 0.15em;
  position: relative;
}

.title-underline {
  width: 100px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--pink), var(--soft-pink), transparent);
  margin: 12px auto 16px;
  opacity: 0;
  animation: scaleIn 0.8s ease 1s forwards;
}

.landing-subtitle {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(13px, 2vw, 17px);
  color: var(--text-soft);
  font-weight: 400;
  display: inline;
}

.landing-subtitle-cursor {
  display: inline;
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(13px, 2vw, 17px);
  color: var(--pink);
  animation: blink 0.8s step-end infinite;
  font-weight: 300;
}

/* ===== LOVE QUOTE ===== */
.love-quote {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 28px;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(232, 67, 147, 0.1);
  border-radius: 50px;
  opacity: 0;
  animation: fadeInUp 0.8s ease 3.5s forwards;
  transition: all 0.5s ease;
  max-width: 500px;
  backdrop-filter: blur(10px);
}
.love-quote:hover {
  border-color: rgba(232, 67, 147, 0.25);
  background: rgba(255, 255, 255, 0.65);
  box-shadow: 0 8px 32px rgba(232, 67, 147, 0.08);
}
.quote-icon { font-size: 18px; flex-shrink: 0; }
.quote-text {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.5;
  min-height: 20px;
  transition: opacity 0.4s ease;
}

/* ===== CARDS ===== */
.cards-wrapper {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  justify-content: center;
  perspective: 1200px;
  opacity: 0;
  animation: fadeInUp 1s ease 1.3s forwards;
}

.date-card {
  position: relative;
  width: 340px;
  border-radius: 28px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  transform-style: preserve-3d;
}

.card-glass {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(40px) saturate(120%);
  -webkit-backdrop-filter: blur(40px) saturate(120%);
  border-radius: 28px;
  z-index: 0;
}

.card-border-glow {
  position: absolute;
  inset: 0;
  border-radius: 28px;
  border: 1px solid rgba(232, 67, 147, 0.12);
  z-index: 1;
  transition: all 0.5s ease;
}

/* Spotlight that follows mouse */
.card-spotlight {
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(244, 114, 182, 0.1), transparent 70%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.date-card:hover .card-spotlight { opacity: 1; }

.date-card:hover .card-border-glow {
  border-color: rgba(232, 67, 147, 0.3);
  box-shadow:
    0 0 40px rgba(232, 67, 147, 0.08),
    inset 0 0 40px rgba(244, 114, 182, 0.04);
}

.date-card:hover {
  transform: translateY(-12px);
  box-shadow: 0 40px 80px -20px rgba(232, 67, 147, 0.15);
}

.date-card.locked {
  opacity: 0.5;
  filter: saturate(0.5) brightness(0.95);
  cursor: not-allowed;
}
.date-card.locked:hover {
  transform: none;
  box-shadow: none;
}
.date-card.locked .card-border-glow {
  border-color: rgba(232, 67, 147, 0.08);
  box-shadow: none;
}
.date-card.locked .card-spotlight { opacity: 0 !important; }

.card-inner {
  position: relative;
  z-index: 2;
  padding: 40px 32px 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.card-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--text-muted);
  background: rgba(232, 67, 147, 0.06);
  padding: 5px 14px;
  border-radius: 20px;
  border: 1px solid rgba(232, 67, 147, 0.08);
}

.card-icon-wrap {
  position: relative;
  margin-bottom: 24px;
}
.card-icon-ring {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 1px solid rgba(232, 67, 147, 0.15);
  animation: ringPulse 3s ease-in-out infinite;
}
.card-icon-ring-2 {
  inset: -24px;
  border-color: rgba(232, 67, 147, 0.08);
  animation-delay: -1.5s;
  animation-duration: 4s;
}
.card-icon {
  font-size: 56px;
  filter: drop-shadow(0 8px 24px rgba(232, 67, 147, 0.15));
  animation: iconFloat 4s ease-in-out infinite;
}

.card-date {
  font-family: 'Playfair Display', serif;
  font-size: 32px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--text), rgba(61, 31, 46, 0.7));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

.card-desc {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 300;
  letter-spacing: 0.5px;
}

.card-divider {
  width: 40px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232, 67, 147, 0.3), transparent);
  margin: 20px 0;
}

.card-lock-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: rgba(232, 67, 147, 0.04);
  border-radius: 50px;
  border: 1px solid rgba(232, 67, 147, 0.08);
}
.lock-icon { font-size: 16px; transition: transform 0.5s ease; }
.lock-text {
  font-size: 11px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  font-weight: 400;
}

/* ===== PASSWORD FORM ===== */
.card-password-form {
  margin-top: 20px;
  width: 100%;
}

.password-hint {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--text-soft);
  font-size: 13px;
  margin-bottom: 14px;
}

.input-wrap {
  position: relative;
}
.input-glow {
  position: absolute;
  inset: -2px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--pink), var(--deep-purple), var(--soft-pink));
  background-size: 200% 200%;
  animation: gradientShift 4s ease-in-out infinite;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: -1;
  filter: blur(4px);
}
.input-wrap:focus-within .input-glow {
  opacity: 0.4;
}

.password-input {
  width: 100%;
  padding: 14px 20px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(232, 67, 147, 0.15);
  border-radius: 14px;
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  text-align: center;
  outline: none;
  transition: all 0.3s ease;
  font-weight: 300;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
}
.password-input:focus {
  border-color: rgba(232, 67, 147, 0.35);
  background: rgba(255, 255, 255, 0.85);
  box-shadow: 0 4px 20px rgba(232, 67, 147, 0.08);
}
.password-input::placeholder {
  color: rgba(61, 31, 46, 0.25);
  font-style: italic;
}

.password-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 12px;
  padding: 14px;
  background: linear-gradient(135deg, var(--pink), var(--rose));
  border: none;
  border-radius: 14px;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 2px;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(232, 67, 147, 0.2);
}
.password-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent, rgba(255,255,255,0.2), transparent);
  transform: translateX(-100%);
  transition: transform 0.7s ease;
}
.password-btn:hover::before { transform: translateX(100%); }
.password-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(232, 67, 147, 0.3);
}
.password-btn:active { transform: translateY(0) scale(0.98); }

.password-error {
  color: var(--rose);
  font-size: 12px;
  margin-top: 10px;
  min-height: 18px;
  font-weight: 300;
}
.password-error.shake { animation: shake 0.5s ease; }

/* ===== CARD SHIMMER ===== */
.card-shimmer {
  position: absolute;
  top: 0; left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmerSlide 5s ease-in-out infinite;
  z-index: 3;
  pointer-events: none;
}

/* ===== COUNTDOWN ===== */
.countdown-mini {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  justify-content: center;
}
.countdown-unit {
  text-align: center;
  min-width: 48px;
  padding: 8px 6px;
  background: rgba(232, 67, 147, 0.04);
  border-radius: 12px;
  border: 1px solid rgba(232, 67, 147, 0.08);
  transition: all 0.3s ease;
}
.countdown-unit:hover {
  background: rgba(232, 67, 147, 0.08);
  border-color: rgba(232, 67, 147, 0.15);
}
.countdown-unit .number {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  color: var(--rose);
  font-weight: 600;
  line-height: 1;
  text-shadow: 0 0 20px rgba(232, 67, 147, 0.15);
}
.countdown-unit .label {
  font-size: 9px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 4px;
  font-weight: 400;
}

/* ===== BIRTHDAY CARD VARIANT ===== */
.card-birthday .card-icon-ring {
  border-color: rgba(192, 132, 252, 0.15);
}
.card-birthday .card-icon-ring-2 {
  border-color: rgba(192, 132, 252, 0.08);
}
.card-birthday .card-spotlight {
  background: radial-gradient(circle, rgba(192, 132, 252, 0.1), transparent 70%);
}
.card-birthday:hover .card-border-glow {
  border-color: rgba(192, 132, 252, 0.3);
  box-shadow:
    0 0 40px rgba(192, 132, 252, 0.08),
    inset 0 0 40px rgba(192, 132, 252, 0.04);
}
.card-birthday:hover {
  box-shadow: 0 40px 80px -20px rgba(192, 132, 252, 0.15);
}
.card-birthday .password-btn {
  background: linear-gradient(135deg, var(--lavender), var(--deep-purple));
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.2);
}
.card-birthday .password-btn:hover {
  box-shadow: 0 12px 32px rgba(124, 58, 237, 0.3);
}

/* ===== BOTTOM ===== */
.landing-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.scroll-hint {
  width: 24px;
  height: 40px;
  border: 1.5px solid rgba(232, 67, 147, 0.2);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
  opacity: 0;
  animation: fadeIn 1s ease 4s forwards;
}
.scroll-dot {
  width: 3px;
  height: 8px;
  background: var(--pink);
  border-radius: 2px;
  animation: scrollDot 1.8s ease-in-out infinite;
  box-shadow: 0 0 8px rgba(232, 67, 147, 0.3);
}

.landing-footer {
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 2px;
  font-weight: 300;
  opacity: 0;
  animation: fadeIn 1s ease 4.2s forwards;
  display: flex;
  align-items: center;
  gap: 6px;
}
.footer-heart {
  font-size: 14px;
  animation: heartbeat 1.5s ease-in-out infinite;
  display: inline-block;
}

/* ===== KEYFRAMES ===== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes scaleIn {
  from { opacity: 0; transform: scaleX(0); }
  to { opacity: 1; transform: scaleX(1); }
}
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}
@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  15% { transform: scale(1.15); }
  30% { transform: scale(1); }
  45% { transform: scale(1.1); }
}
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(5px); }
}
@keyframes shimmerSlide {
  0%, 100% { left: -100%; }
  50% { left: 200%; }
}
@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(50px, -30px) scale(1.1); }
  50% { transform: translate(-20px, 50px) scale(0.95); }
  75% { transform: translate(30px, 20px) scale(1.05); }
}
@keyframes ringPulse {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.2); opacity: 0.1; }
}
@keyframes scrollDot {
  0% { opacity: 1; transform: translateY(0); }
  50% { opacity: 0.2; transform: translateY(14px); }
  100% { opacity: 1; transform: translateY(0); }
}
@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}
@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes auroraWave {
  0% { transform: translateX(-20%) skewX(-5deg); }
  100% { transform: translateX(10%) skewX(5deg); }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  body { cursor: auto; }
  #cursor-trail { display: none; }
  .cards-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 24px;
  }
  .date-card {
    width: 90vw;
    max-width: 360px;
  }
  .landing-container {
    padding: 40px 16px;
    gap: 28px;
  }
  .deco-line { height: 40px; }
  .mesh-orb { opacity: 0.15; }
  .aurora { opacity: 0.3; }
  .love-quote { max-width: 90vw; }
}

@media (max-width: 380px) {
  .landing-tag { letter-spacing: 4px; font-size: 9px; }
  .countdown-unit { min-width: 42px; }
}
