/* =====================================================================
   Nayara Invitation — Template "Jawa Modern"
   Palet: Maroon (#6B0F1A), Emas (#C9A227), Krem (#FDF8F0)
   Font: Playfair Display / Cormorant Garamond (judul), Poppins (isi)
   ===================================================================== */

:root {
  --maroon: #6B0F1A;
  --maroon-dark: #4A0A12;
  --maroon-light: #8A2530;
  --gold: #C9A227;
  --gold-light: #E4C767;
  --cream: #FDF8F0;
  --cream-dark: #EFE3C8;
  --ink: #2B2118;
  --font-heading: 'Playfair Display', 'Cormorant Garamond', serif;
  --font-script: 'Cormorant Garamond', serif;
  --font-body: 'Poppins', sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  overflow-x: hidden;
}

img { max-width: 100%; }

.db-warning {
  background: #fff3cd;
  color: #664d03;
  text-align: center;
  padding: 10px 16px;
  font-size: 0.85rem;
  position: relative;
  z-index: 2000;
}

/* ---------------------------------------------------------------------
   Utility: motif batik overlay (kawung) sebagai tekstur latar
   --------------------------------------------------------------------- */
.batik-overlay {
  position: absolute;
  inset: 0;
  background-image: url('../img/pattern-kawung.svg');
  background-repeat: repeat;
  background-size: 120px 120px;
  opacity: 0.5;
  pointer-events: none;
}
.batik-overlay-light { opacity: 0.15; }

/* ---------------------------------------------------------------------
   COVER SCREEN
   --------------------------------------------------------------------- */
.cover-screen {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background: radial-gradient(circle at 50% 20%, var(--maroon-light) 0%, var(--maroon) 55%, var(--maroon-dark) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}
.cover-screen.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.cover-content {
  position: relative;
  z-index: 2;
  color: var(--cream);
  padding: 2rem;
  max-width: 480px;
}
.cover-gunungan { filter: drop-shadow(0 4px 12px rgba(0,0,0,0.35)); }
.cover-eyebrow {
  font-family: var(--font-script);
  letter-spacing: 3px;
  font-size: 1rem;
  color: var(--gold-light);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.cover-names {
  font-family: var(--font-heading);
  font-size: 3rem;
  margin-bottom: 1rem;
}
.cover-names .amp { color: var(--gold); font-style: italic; }
.cover-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--gold);
  margin: 1rem 0;
}
.cover-divider span { width: 40px; height: 1px; background: var(--gold); display: inline-block; }
.cover-guest-label { font-size: 0.85rem; opacity: 0.85; margin-bottom: 0.25rem; }
.cover-guest-name {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--gold-light);
}
.btn-open-invitation {
  background: var(--gold);
  color: var(--maroon-dark);
  border: none;
  padding: 0.75rem 2rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-open-invitation:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(201, 162, 39, 0.4);
  color: var(--maroon-dark);
}

/* ---------------------------------------------------------------------
   MUSIC TOGGLE
   --------------------------------------------------------------------- */
.btn-music-toggle {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1600;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--maroon);
  color: var(--gold-light);
  border: 2px solid var(--gold);
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 16px rgba(0,0,0,0.25);
}
.btn-music-toggle.playing i { animation: spin 3.5s linear infinite; }
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------------
   MAIN CONTENT VISIBILITY
   --------------------------------------------------------------------- */
.main-content {
  visibility: hidden;
  opacity: 0;
}
.main-content.show {
  visibility: visible;
  opacity: 1;
  transition: opacity 0.6s ease;
}

/* ---------------------------------------------------------------------
   HERO
   --------------------------------------------------------------------- */
.hero-section {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, var(--maroon) 0%, var(--maroon-dark) 100%);
  color: var(--cream);
  overflow: hidden;
}
.hero-eyebrow {
  font-family: var(--font-script);
  font-size: 1.1rem;
  letter-spacing: 3px;
  color: var(--gold-light);
  text-transform: uppercase;
}
.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  margin: 0.5rem 0;
}
.hero-date {
  font-family: var(--font-script);
  font-size: 1.4rem;
  color: var(--gold-light);
}
.scroll-indicator {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--gold-light);
  font-size: 1.5rem;
  animation: bounce 1.8s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 10px); }
}

/* ---------------------------------------------------------------------
   SECTION HEADINGS (umum)
   --------------------------------------------------------------------- */
.section-eyebrow {
  font-family: var(--font-script);
  font-size: 1.1rem;
  letter-spacing: 2px;
  color: var(--maroon);
  text-transform: uppercase;
}
.section-eyebrow-light { color: var(--gold-light); }
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--maroon-dark);
  margin-bottom: 0.75rem;
}
.section-title-light { color: var(--cream); }
.section-subtitle { color: #6b6258; max-width: 640px; margin: 0 auto; }
.section-subtitle-light { color: #f1e6d3; }

/* ---------------------------------------------------------------------
   QUOTE
   --------------------------------------------------------------------- */
.section-quote { background: var(--cream-dark); }
.quote-icon { font-size: 2.5rem; color: var(--gold); }
.quote-text {
  font-family: var(--font-script);
  font-size: 1.4rem;
  font-style: italic;
  color: var(--maroon-dark);
  line-height: 1.8;
}

/* ---------------------------------------------------------------------
   MEMPELAI
   --------------------------------------------------------------------- */
.card-mempelai {
  background: #fff;
  border-radius: 16px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 10px 30px rgba(107, 15, 26, 0.08);
  border: 1px solid var(--cream-dark);
  height: 100%;
}
.mempelai-photo {
  width: 180px;
  height: 180px;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid var(--gold);
  margin-bottom: 1.25rem;
}
.mempelai-name {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  color: var(--maroon-dark);
  margin-bottom: 0.5rem;
}
.mempelai-parents { color: #6b6258; font-size: 0.92rem; }
.mempelai-amp {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: 3rem;
  color: var(--gold);
}

/* ---------------------------------------------------------------------
   COUNTDOWN
   --------------------------------------------------------------------- */
.section-countdown {
  position: relative;
  background: linear-gradient(135deg, var(--maroon-dark), var(--maroon));
  overflow: hidden;
}
.countdown-wrapper {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
  z-index: 2;
}
.countdown-box {
  background: rgba(255,255,255,0.08);
  border: 1px solid var(--gold);
  border-radius: 12px;
  padding: 1rem 1.4rem;
  min-width: 90px;
  color: var(--cream);
}
.countdown-box span {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.2rem;
  color: var(--gold-light);
}
.countdown-box small { letter-spacing: 1px; text-transform: uppercase; font-size: 0.75rem; }

/* ---------------------------------------------------------------------
   ACARA
   --------------------------------------------------------------------- */
.card-acara {
  background: #fff;
  border: 1px solid var(--cream-dark);
  border-radius: 16px;
  padding: 2rem;
  text-align: center;
  height: 100%;
  box-shadow: 0 10px 30px rgba(107, 15, 26, 0.06);
}
.card-acara-icon { font-size: 2.2rem; color: var(--gold); margin-bottom: 0.75rem; }
.card-acara h3 { font-family: var(--font-heading); color: var(--maroon-dark); margin-bottom: 0.75rem; }
.acara-date { font-weight: 600; color: var(--maroon); margin-bottom: 0.25rem; }
.acara-time { color: #6b6258; margin-bottom: 0.5rem; }
.acara-location { color: #6b6258; font-size: 0.92rem; }
.maps-frame { border-radius: 16px; overflow: hidden; box-shadow: 0 10px 30px rgba(0,0,0,0.12); }

.btn-outline-maroon {
  border: 1.5px solid var(--maroon);
  color: var(--maroon);
  background: transparent;
  border-radius: 999px;
  font-weight: 500;
}
.btn-outline-maroon:hover { background: var(--maroon); color: var(--cream); }
.btn-check:checked + .btn-outline-maroon {
  background: var(--maroon);
  color: var(--cream);
}
.btn-maroon {
  background: var(--maroon);
  color: var(--cream);
  border-radius: 999px;
  font-weight: 600;
  padding: 0.65rem 1.5rem;
  border: none;
}
.btn-maroon:hover { background: var(--maroon-dark); color: var(--gold-light); }

/* ---------------------------------------------------------------------
   LOVE STORY TIMELINE
   --------------------------------------------------------------------- */
.section-love-story { background: var(--cream-dark); }
.timeline { position: relative; max-width: 800px; margin: 0 auto; padding: 1rem 0; }
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--gold);
  transform: translateX(-50%);
}
.timeline-item { position: relative; width: 50%; padding: 1rem 2rem; margin-bottom: 1rem; }
.timeline-left { left: 0; text-align: right; }
.timeline-right { left: 50%; text-align: left; }
.timeline-dot {
  position: absolute;
  top: 1.5rem;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--maroon);
  border: 3px solid var(--gold);
}
.timeline-left .timeline-dot { right: -8px; }
.timeline-right .timeline-dot { left: -8px; }
.timeline-content {
  background: #fff;
  border-radius: 12px;
  padding: 1.2rem 1.4rem;
  box-shadow: 0 6px 20px rgba(107,15,26,0.08);
}
.timeline-date { color: var(--gold); font-weight: 600; font-size: 0.85rem; }
.timeline-content h4 { font-family: var(--font-heading); color: var(--maroon-dark); margin: 0.3rem 0; }
.timeline-content p { color: #6b6258; font-size: 0.92rem; margin: 0; }

@media (max-width: 767px) {
  .timeline::before { left: 12px; }
  .timeline-item, .timeline-left, .timeline-right {
    width: 100%;
    left: 0;
    text-align: left;
    padding-left: 2.5rem;
  }
  .timeline-left .timeline-dot, .timeline-right .timeline-dot { left: 4px; right: auto; }
}

/* ---------------------------------------------------------------------
   GALERI
   --------------------------------------------------------------------- */
.gallery-item {
  display: block;
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 6px 18px rgba(107,15,26,0.1);
}
.gallery-item img { width: 100%; height: 100%; aspect-ratio: 1/1; object-fit: cover; transition: transform 0.4s ease; }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-caption {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: linear-gradient(0deg, rgba(0,0,0,0.65), transparent);
  color: #fff;
  font-size: 0.78rem;
  padding: 0.5rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.gallery-item:hover .gallery-caption { opacity: 1; }

/* ---------------------------------------------------------------------
   RSVP & BUKU TAMU
   --------------------------------------------------------------------- */
.section-rsvp {
  position: relative;
  background: linear-gradient(160deg, var(--maroon-dark), var(--maroon));
}
.rsvp-card, .guestbook-card {
  background: #fff;
  border-radius: 18px;
  padding: 1.8rem;
  box-shadow: 0 15px 40px rgba(0,0,0,0.25);
  position: relative;
  z-index: 2;
  height: 100%;
}
.guestbook-summary { border-bottom: 1px solid var(--cream-dark); padding-bottom: 1rem; }
.gs-number { font-family: var(--font-heading); font-size: 1.8rem; color: var(--maroon); }
.gs-label { font-size: 0.78rem; color: #6b6258; text-transform: uppercase; letter-spacing: 0.5px; }
.guestbook-list { max-height: 420px; overflow-y: auto; padding-right: 4px; }
.guestbook-list::-webkit-scrollbar { width: 6px; }
.guestbook-list::-webkit-scrollbar-thumb { background: var(--cream-dark); border-radius: 4px; }
.guest-entry {
  border-bottom: 1px dashed var(--cream-dark);
  padding: 0.85rem 0;
}
.guest-entry:last-child { border-bottom: none; }
.guest-entry-name { font-weight: 600; color: var(--maroon-dark); }
.guest-entry-badge {
  font-size: 0.7rem;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  margin-left: 0.4rem;
  font-weight: 500;
}
.badge-hadir { background: #e6f4ea; color: #1e7e34; }
.badge-tidak_hadir, .badge-tidak-hadir { background: #fdecea; color: #c0392b; }
.badge-ragu { background: #fff8e1; color: #b8860b; }
.guest-entry-message { color: #4a4137; font-size: 0.9rem; margin: 0.3rem 0 0; }
.guest-entry-time { color: #a89f92; font-size: 0.72rem; }
.empty-state { text-align: center; color: #a89f92; padding: 2rem 0; }

/* ---------------------------------------------------------------------
   AMPLOP DIGITAL
   --------------------------------------------------------------------- */
.amplop-card {
  background: #fff;
  border: 1px solid var(--cream-dark);
  border-radius: 16px;
  padding: 1.8rem;
  text-align: center;
  height: 100%;
  box-shadow: 0 10px 30px rgba(107,15,26,0.06);
}
.amplop-icon { font-size: 2rem; color: var(--gold); margin-bottom: 0.5rem; }
.amplop-card h4 { font-family: var(--font-heading); color: var(--maroon-dark); }
.amplop-detail { color: var(--ink); margin-bottom: 0.3rem; }
.qris-img { width: 100%; max-width: 200px; margin: 0.5rem auto; border-radius: 8px; }
.copy-field {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--cream-dark);
  border-radius: 999px;
  padding: 0.4rem 0.6rem 0.4rem 1rem;
  margin: 0.5rem 0;
  font-weight: 600;
  color: var(--maroon-dark);
}
.btn-copy {
  border: none;
  background: var(--maroon);
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn-copy.copied { background: #1e7e34; }

/* ---------------------------------------------------------------------
   FOOTER
   --------------------------------------------------------------------- */
.footer-section {
  position: relative;
  background: var(--maroon-dark);
  color: var(--cream);
  overflow: hidden;
}
.footer-names { font-family: var(--font-heading); font-size: 2rem; color: var(--gold-light); }
.footer-thanks { max-width: 560px; margin: 0.8rem auto; color: #f1e6d3; }
.footer-wassalam { font-family: var(--font-script); font-style: italic; color: var(--gold-light); }
.footer-divider { border-color: rgba(255,255,255,0.15); max-width: 200px; margin: 1.5rem auto; }
.footer-credit { font-size: 0.82rem; color: #d8c9b0; }

/* ---------------------------------------------------------------------
   RESPONSIVE TWEAKS
   --------------------------------------------------------------------- */
@media (max-width: 575px) {
  .cover-names { font-size: 2.2rem; }
  .countdown-box { min-width: 70px; padding: 0.75rem 0.9rem; }
  .countdown-box span { font-size: 1.6rem; }
}
