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

:root {
  --midnight:  #1a0a12;
  --deep:      #260d1c;
  --blush:     #f2c4ce;
  --rose:      #c0647a;
  --mauve:     #9e6e78;
  --champagne: #f7e7d3;
  --gold:      #d4a853;
  --cream:     #fdf6f0;
  --white:     #ffffff;
}

html { scroll-behavior: smooth; background-color: #1a0a12; }

body {
  background-color: var(--midnight);
  background-image:
    radial-gradient(ellipse 80% 60% at 50% 0%,   #6b1b3a55 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 20% 100%, #9e6e7833 0%, transparent 60%),
    radial-gradient(ellipse 70% 50% at 80% 50%,  #3d0e2844 0%, transparent 60%);
  background-attachment: fixed;
  color: var(--champagne);
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
}

/* ── FLOATING HEARTS ─────────────────────────────────────── */
.hearts-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.heart-particle {
  position: absolute;
  bottom: -60px;
  font-size: 1.2rem;
  opacity: 0;
  animation: floatUp linear infinite;
  font-variant-emoji: text;
  font-family: 'Lato', monospace, sans-serif;
}
@keyframes floatUp {
  0%   { transform: translateY(0)      rotate(0deg);  opacity: 0; }
  10%  { opacity: 0.4; }
  90%  { opacity: 0.15; }
  100% { transform: translateY(-110vh) rotate(20deg); opacity: 0; }
}

/* ── GATE (verify.html) ──────────────────────────────────── */
.gate {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
  position: relative;
  z-index: 1;
  text-align: center;
}

.gate-eyebrow {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  color: var(--champagne);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  opacity: 0.75;
  margin-bottom: 1.5rem;
}

.gate-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 6vw, 3.8rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 0.5rem;
}
.gate-title em { font-style: italic; color: var(--blush); }

.gate-divider {
  width: 220px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--blush), transparent);
  border-radius: 2px;
  margin: 1.8rem auto;
}

.gate-sub {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  color: var(--champagne);
  opacity: 0.7;
  letter-spacing: 0.05em;
  margin-bottom: 2.5rem;
}

.gate-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
  max-width: 320px;
  margin: 0 auto;
}

.gate-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(242, 196, 206, 0.25);
  border-radius: 4px;
  padding: 0.9rem 1.2rem;
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  color: var(--white);
  letter-spacing: 0.05em;
  text-align: center;
  outline: none;
  transition: border-color 0.25s ease, background 0.25s ease;
  -webkit-appearance: none;
  appearance: none;
}
.gate-input:focus {
  border-color: rgba(242, 196, 206, 0.65);
  background: rgba(255, 255, 255, 0.09);
}
.gate-input::-webkit-datetime-edit         { color: var(--champagne); opacity: 0.5; }
.gate-input::-webkit-datetime-edit-fields-wrapper { opacity: 1; }
.gate-input:valid::-webkit-datetime-edit   { opacity: 1; }
.gate-input::-webkit-calendar-picker-indicator {
  filter: invert(1) opacity(0.3);
  cursor: pointer;
}

.gate-btn {
  width: 100%;
  padding: 0.9rem 1.2rem;
  background: linear-gradient(135deg, var(--rose), #8a2a46);
  color: var(--white);
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 0.85rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.gate-btn:hover  { opacity: 0.88; transform: translateY(-1px); }
.gate-btn:active { transform: translateY(0); }

.gate-message {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  min-height: 1.2em;
  transition: opacity 0.3s ease;
}
.gate-message.error   { color: var(--blush);     opacity: 0.9; }
.gate-message.success { color: var(--champagne); opacity: 0.9; }

/* Success screen */
.gate-success-screen { display: none; flex-direction: column; align-items: center; text-align: center; }
.gate-success-screen.visible { display: flex; }

.gate-success-heart {
  font-size: 3rem;
  color: var(--blush);
  font-variant-emoji: text;
  margin-bottom: 1.5rem;
}
.gate-success-title {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  color: var(--white);
  margin-bottom: 1rem;
}
.gate-success-sub {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 0.95rem;
  color: var(--champagne);
  opacity: 0.7;
  letter-spacing: 0.05em;
  margin-bottom: 2rem;
}
.gate-enter-btn {
  display: inline-block;
  padding: 0.9rem 2.5rem;
  background: linear-gradient(135deg, var(--rose), #8a2a46);
  color: var(--white);
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 4px;
  transition: opacity 0.2s ease, transform 0.2s ease;
}
.gate-enter-btn:hover { opacity: 0.88; transform: translateY(-1px); }

/* ── HERO ────────────────────────────────────────────────── */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3rem 1.5rem 5rem;
}

.hero-eyebrow {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  color: var(--champagne);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  opacity: 0.75;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3.2rem, 10vw, 7.5rem);
  font-weight: 700;
  line-height: 1.05;
  color: var(--white);
}
.hero-title em { font-style: italic; color: var(--blush); }

.hero-divider {
  width: 220px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--blush), transparent);
  margin: 2rem auto;
  border-radius: 2px;
}

.hero-sub {
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--champagne);
  max-width: 520px;
  line-height: 1.8;
  opacity: 0.85;
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  color: var(--mauve);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.scroll-arrow {
  width: 18px;
  height: 18px;
  border-right: 1px solid var(--mauve);
  border-bottom: 1px solid var(--mauve);
  transform: rotate(45deg);
  animation: arrowBounce 1.6s ease-in-out infinite;
}
@keyframes arrowBounce {
  0%, 100% { transform: rotate(45deg) translate(0,  0);  }
  50%       { transform: rotate(45deg) translate(3px, 3px); }
}

/* ── SECTIONS ────────────────────────────────────────────── */
.section {
  position: relative;
  z-index: 1;
  padding: 5rem 1.5rem;
}

.section-label {
  text-align: center;
  font-family: 'Lato', sans-serif;
  font-weight: 300;
  font-size: 1rem;
  color: var(--champagne);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  opacity: 0.75;
  margin-bottom: 0.5rem;
}
.section-title {
  text-align: center;
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.75rem;
}
.section-sub {
  text-align: center;
  font-size: 0.95rem;
  color: var(--mauve);
  max-width: 480px;
  margin: 0 auto 4rem;
  line-height: 1.8;
}

/* ── POLAROID GALLERY ────────────────────────────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 3rem 2.5rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 0 2rem;
}

.polaroid {
  background: var(--cream);
  padding: 14px 14px 52px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.5), 0 2px 6px rgba(0,0,0,0.3);
  transition: transform 0.35s cubic-bezier(.22,.68,0,1.2), box-shadow 0.35s ease;
  cursor: pointer;
  position: relative;
}
.polaroid:hover {
  box-shadow: 0 16px 50px rgba(0,0,0,0.65), 0 4px 10px rgba(0,0,0,0.35);
  z-index: 10;
}

/* Tape strip */
.polaroid::before {
  content: '';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 22px;
  background: rgba(247, 231, 211, 0.55);
  border-radius: 2px;
  backdrop-filter: blur(2px);
}

/* Per-card tilts */
.polaroid:nth-child(1)       { transform: rotate(-3deg); }
.polaroid:nth-child(1):hover { transform: rotate(-3deg) scale(1.06); }
.polaroid:nth-child(2)       { transform: rotate(2.5deg); }
.polaroid:nth-child(2):hover { transform: rotate(2.5deg) scale(1.06); }
.polaroid:nth-child(3)       { transform: rotate(-1.5deg); }
.polaroid:nth-child(3):hover { transform: rotate(-1.5deg) scale(1.06); }
.polaroid:nth-child(4)       { transform: rotate(3.5deg) translateY(-8px); }
.polaroid:nth-child(4):hover { transform: rotate(3.5deg) translateY(-8px) scale(1.06); }
.polaroid:nth-child(5)       { transform: rotate(-2deg) translateY(6px); }
.polaroid:nth-child(5):hover { transform: rotate(-2deg) translateY(6px) scale(1.06); }
.polaroid:nth-child(6)       { transform: rotate(1.5deg); }
.polaroid:nth-child(6):hover { transform: rotate(1.5deg) scale(1.06); }
.polaroid:nth-child(7)       { transform: rotate(-4deg) translateY(4px); }
.polaroid:nth-child(7):hover { transform: rotate(-4deg) translateY(4px) scale(1.06); }
.polaroid:nth-child(8)       { transform: rotate(2deg) translateY(-4px); }
.polaroid:nth-child(8):hover { transform: rotate(2deg) translateY(-4px) scale(1.06); }

.polaroid-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: linear-gradient(135deg, #e8cdd5 0%, #d4b8c4 40%, #c9a8b8 100%);
  overflow: hidden;
}

.polaroid-img-placeholder {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: linear-gradient(135deg, #e8cdd5 0%, #d4b8c4 40%, #c9a8b8 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}
.polaroid-img-placeholder .ph-icon { font-size: 2.8rem; opacity: 0.45; }
.polaroid-img-placeholder .ph-text {
  font-size: 0.65rem;
  color: #9e6e78;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-family: 'Lato', sans-serif;
}

.polaroid-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 10px;
}
.polaroid-caption span {
  font-family: 'Dancing Script', cursive;
  font-size: 1.05rem;
  color: #5a3045;
  text-align: center;
  line-height: 1.3;
}

/* ── LOVE LETTER ─────────────────────────────────────────── */
.letter-wrap {
  max-width: 680px;
  margin: 0 auto;
  background: var(--cream);
  padding: 3.5rem 3rem 3rem;
  position: relative;
  box-shadow: 0 20px 80px rgba(0,0,0,0.5);
}
.letter-wrap::before {
  content: '❝';
  position: absolute;
  top: -0.2rem;
  left: 2rem;
  font-size: 6rem;
  color: var(--blush);
  opacity: 0.3;
  font-family: 'Playfair Display', serif;
  line-height: 1;
}
.letter-text {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  color: #3a1f2d;
  line-height: 2;
  position: relative;
  z-index: 1;
}
.letter-signature {
  margin-top: 2rem;
  text-align: right;
  font-family: 'Dancing Script', cursive;
  font-size: 1.5rem;
  color: var(--rose);
}
.letter-date {
  text-align: right;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--mauve);
  margin-top: 0.25rem;
  font-family: 'Lato', sans-serif;
}

/* ── TIMELINE ────────────────────────────────────────────── */
.timeline {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  padding-left: 2rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--rose), var(--gold), var(--rose), transparent);
}
.timeline-item {
  position: relative;
  margin-bottom: 2.8rem;
  padding-left: 1.5rem;
}
.timeline-item::before {
  content: '\2665\FE0E';
  position: absolute;
  left: -1.55rem;
  top: 0.15rem;
  font-size: 0.85rem;
  color: var(--rose);
  background: var(--midnight);
  padding: 2px 0;
  font-variant-emoji: text;
}
.timeline-date {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--blush);
  margin-bottom: 0.3rem;
  font-family: 'Lato', sans-serif;
}
.timeline-event {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  color: var(--white);
  margin-bottom: 0.3rem;
}
.timeline-desc {
  font-size: 0.88rem;
  color: var(--mauve);
  line-height: 1.7;
}

/* ── FOOTER ──────────────────────────────────────────────── */
footer {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 3rem 1.5rem 4rem;
  background: var(--midnight);
  border-top: 1px solid #3a1528;
}
.footer-domain {
  font-family: 'Dancing Script', cursive;
  font-size: 1.6rem;
  color: var(--gold);
  margin-bottom: 0.5rem;
}
.footer-hearts {
  font-size: 1.5rem;
  margin: 1rem 0 0.5rem;
  letter-spacing: 0.3em;
  font-variant-emoji: text;
}
.footer-copy {
  font-size: 0.75rem;
  color: var(--mauve);
  letter-spacing: 0.1em;
  opacity: 0.6;
}

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 600px) {
  .gallery-grid { gap: 2.5rem 1.5rem; grid-template-columns: 1fr 1fr; }
  .letter-wrap  { padding: 2.5rem 1.5rem 2rem; }
  .hero-title   { font-size: clamp(2.8rem, 15vw, 5rem); }
}
@media (prefers-reduced-motion: reduce) {
  .heart-particle { animation: none; }
  .polaroid, .reveal { transition: none; }
  .polaroid:hover { transform: none; }
}
