@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400;1,600&family=Jost:wght@200;300;400;500&display=swap');

/* ── Palette pulled from the save-the-date illustration ─────── */
:root {
  --midnight:   #0D1B2A;
  --deep-teal:  #1A3A3A;
  --palm:       #2D5A3D;
  --palm-light: #4A8C60;
  --candle:     #E8A020;
  --candle-soft:#F5D080;
  --saffron:    #C8600A;
  --ivory:      #FAF5EC;
  --ivory-dark: #F0E8D5;
  --cream:      #FDF8EF;
  --gold:       #BFA06A;
  --gold-dark:  #8C7040;
  --petal-pink: #D4908A;
  --text:       #1C1A18;
  --text-muted: #5A4E3E;
  --border:     rgba(191,160,106,0.22);
  --hero-grad: linear-gradient(
    180deg,
    rgba(13,27,42,0.5) 0%,
    rgba(13,27,42,0.05) 40%,
    rgba(13,27,42,0.05) 55%,
    rgba(13,27,42,0.72) 100%
  );
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--cream);
  color: var(--text);
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3 { font-family: 'Cormorant Garamond', serif; font-weight: 400; line-height: 1.15; }
h2 { font-size: clamp(2rem, 5vw, 3.2rem); letter-spacing: 0.02em; }
h3 { font-size: 1.5rem; }

.eyebrow {
  font-family: 'Jost', sans-serif;
  font-weight: 400;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--candle);
}

/* ── Gold rule divider ── */
.gold-rule {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2.5rem auto;
  max-width: 320px;
  opacity: 0.6;
}
.gold-rule::before, .gold-rule::after {
  content: '';
  flex: 1;
  height: 0.5px;
  background: var(--gold);
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.1rem 3rem;
  background: transparent;
  transition: background 0.4s ease;
}
nav.scrolled {
  background: rgba(13,27,42,0.9);
  backdrop-filter: blur(12px);
  border-bottom: 0.5px solid rgba(191,160,106,0.2);
}
.nav-logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-style: italic;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.06em;
  text-shadow: 0 1px 8px rgba(0,0,0,0.6);
}
.nav-links { display: flex; gap: 2.5rem; list-style: none; }
.nav-links a {
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.9);
  text-decoration: none;
  transition: color 0.2s;
  text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}
.nav-links a:hover { color: var(--candle-soft); }

/* ── HERO ── */
.hero {
  position: relative;
  width: 100%;
  aspect-ratio: 2750 / 1536;
  background: var(--midnight);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding-top: 2rem;
  padding-bottom: 2.5rem;
  overflow: hidden;
}
.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--hero-grad);
  pointer-events: none;
}
.hero-vignette {
  position: absolute;
  inset: 0;
  box-shadow: inset 0 0 140px rgba(13,27,42,0.4);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding: 0 1.5rem;
  max-width: 640px;
}
.hero-save-the-date {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.1rem, 2.5vw, 1.6rem);
  color: var(--candle-soft);
  letter-spacing: 0.1em;
  margin-bottom: 0.4rem;
  text-shadow: 0 2px 12px rgba(0,0,0,0.7);
}
.hero-names {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: clamp(2.8rem, 8vw, 5rem);
  letter-spacing: 0.04em;
  line-height: 1;
  text-shadow: 0 3px 28px rgba(0,0,0,0.6);
  margin-bottom: 0.7rem;
}
.hero-date-venue {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: clamp(0.7rem, 1.8vw, 0.9rem);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
  text-shadow: 0 1px 8px rgba(0,0,0,0.6);
  margin-bottom: 2rem;
}

/* ── Countdown ── */
.countdown {
  display: flex;
  gap: 0;
  margin: 0 auto 0.5rem;
  justify-content: center;
  align-items: flex-start;
  border: 0.5px solid rgba(255,255,255,0.18);
  backdrop-filter: blur(6px);
  background: rgba(13,27,42,0.4);
}
.countdown-unit {
  text-align: center;
  padding: 0.9rem 1.4rem;
  border-right: 0.5px solid rgba(255,255,255,0.12);
}
.countdown-unit:last-child { border-right: none; }
.countdown-number {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 300;
  color: var(--candle-soft);
  line-height: 1;
  display: block;
}
.countdown-label {
  font-size: 0.58rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  margin-top: 0.25rem;
  display: block;
}

/* ── Scroll cue ── */
.scroll-cue {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  color: rgba(255,255,255,0.4);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.scroll-cue-line {
  width: 0.5px;
  height: 36px;
  background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.45) 100%);
  animation: scrollPulse 2.2s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* ── RSVP strip ── */
.rsvp-strip {
  background: var(--midnight);
  padding: 5rem 2rem;
  text-align: center;
}
.rsvp-strip .eyebrow { color: var(--candle-soft); margin-bottom: 0.5rem; }
.rsvp-strip h2 { color: #fff; margin-bottom: 0.5rem; }
.rsvp-strip > p { color: rgba(255,255,255,0.55); font-size: 0.9rem; max-width: 480px; margin: 0 auto 2.5rem; }

/* ── Buttons ── */
.btn {
  display: inline-block;
  padding: 0.9rem 2.5rem;
  font-family: 'Jost', sans-serif;
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.3s ease;
}
.btn-gold { background: var(--candle); color: var(--midnight); }
.btn-gold:hover { background: var(--candle-soft); transform: translateY(-1px); }
.btn-outline-white { background: transparent; color: #fff; border: 0.5px solid rgba(255,255,255,0.45); }
.btn-outline-white:hover { background: rgba(255,255,255,0.1); }
.btn-primary { background: var(--saffron); color: #fff; }
.btn-primary:hover { background: #a84e08; transform: translateY(-1px); }
.btn-dark { background: var(--midnight); color: #fff; }
.btn-dark:hover { background: var(--deep-teal); }

/* ── Forms ── */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 2rem;
  text-align: left;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
.form-field { display: flex; flex-direction: column; gap: 0.4rem; }
.form-field.full { grid-column: 1 / -1; }

.form-field label {
  font-size: 0.64rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}
.form-field input,
.form-field select,
.form-field textarea {
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.16);
  padding: 0.8rem 1rem;
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  color: #fff;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  appearance: none;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { border-color: var(--candle); }
.form-field textarea { resize: vertical; min-height: 80px; }
.form-field select option { background: var(--midnight); }

/* Light form variant */
.form-light .form-field label { color: var(--text-muted); }
.form-light .form-field input,
.form-light .form-field select,
.form-light .form-field textarea {
  background: var(--ivory);
  border: 0.5px solid rgba(191,160,106,0.4);
  color: var(--text);
}
.form-light .form-field input:focus,
.form-light .form-field select:focus,
.form-light .form-field textarea:focus { border-color: var(--saffron); }
.form-light .form-field select option { background: #fff; color: var(--text); }

.attending-toggle { display: flex; margin-top: 0.4rem; }
.attending-toggle label {
  flex: 1;
  text-align: center;
  padding: 0.75rem;
  border: 0.5px solid rgba(255,255,255,0.16);
  cursor: pointer;
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  transition: all 0.2s;
}
.attending-toggle.dark label {
  border-color: rgba(191,160,106,0.4);
  color: var(--text-muted);
}
.attending-toggle input { display: none; }
.attending-toggle input:checked + label { background: var(--candle); color: var(--midnight); border-color: var(--candle); }
.attending-toggle.dark input:checked + label { background: var(--saffron); color: #fff; border-color: var(--saffron); }

.form-submit { text-align: center; margin-top: 1.75rem; }
.form-success {
  display: none;
  text-align: center;
  padding: 1.5rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  font-style: italic;
  margin-top: 1.5rem;
}
.form-success.light { color: var(--palm); background: rgba(74,140,96,0.08); }
.form-success.on-dark { color: var(--candle-soft); }

/* ── Guest area gate ── */
.gate-section {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--midnight);
  padding: 2rem;
  position: relative;
  overflow: hidden;
}
.gate-palms {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 10% 80%, rgba(45,90,61,0.3) 0%, transparent 45%),
    radial-gradient(ellipse at 90% 80%, rgba(45,90,61,0.25) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 0%, rgba(13,27,42,0.8) 0%, transparent 50%);
  pointer-events: none;
}
.gate-box {
  position: relative;
  z-index: 2;
  max-width: 400px;
  width: 100%;
  border: 0.5px solid rgba(191,160,106,0.22);
  padding: 3rem 2.5rem;
  background: rgba(255,255,255,0.03);
  backdrop-filter: blur(6px);
  text-align: center;
}
.gate-box h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  font-weight: 300;
  font-style: italic;
  color: #fff;
  margin: 0.5rem 0 0.25rem;
}
.gate-box > p { color: rgba(255,255,255,0.45); font-size: 0.82rem; }
.gate-input {
  width: 100%;
  text-align: center;
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem;
  letter-spacing: 0.4em;
  border: none;
  border-bottom: 0.5px solid var(--candle);
  background: transparent;
  padding: 0.5rem;
  outline: none;
  color: var(--candle-soft);
  margin: 1.75rem 0;
}
.gate-error {
  font-size: 0.78rem;
  color: #E88080;
  letter-spacing: 0.08em;
  display: none;
  margin-bottom: 1rem;
}

/* Guest content */
.guest-content { display: none; }
.guest-content.unlocked { display: block; }

/* Guest welcome band */
.guest-hero {
  background: var(--midnight);
  padding: 6rem 2rem 4rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.guest-hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 15% 60%, rgba(45,90,61,0.22) 0%, transparent 50%),
    radial-gradient(ellipse at 85% 60%, rgba(45,90,61,0.18) 0%, transparent 50%);
  pointer-events: none;
}
.guest-hero h2 { color: #fff; font-style: italic; font-size: clamp(2.2rem, 6vw, 3.8rem); position: relative; }
.guest-hero p { color: rgba(255,255,255,0.5); max-width: 480px; margin: 1rem auto 0; position: relative; }

/* Inner sections */
.gs-section { padding: 5rem 2rem; max-width: 900px; margin: 0 auto; }
.gs-dark { background: var(--midnight); padding: 5rem 2rem; }
.gs-dark h2 { color: #fff; }
.gs-dark p { color: rgba(255,255,255,0.55); }
.gs-ivory { background: var(--ivory-dark); padding: 5rem 2rem; }
.section-inner { max-width: 680px; margin: 0 auto; text-align: center; }

/* Venue */
.venue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 2.5rem;
  text-align: left;
}
.venue-card {
  border: 0.5px solid var(--border);
  padding: 1.75rem;
  background: var(--ivory);
}
.venue-card h4 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-weight: 500;
  margin-bottom: 0.6rem;
}
.venue-card p { font-size: 0.88rem; color: var(--text-muted); line-height: 1.7; }

/* Accommodation */
.accom-box {
  border: 0.5px solid rgba(191,160,106,0.28);
  padding: 2.5rem;
  text-align: center;
  margin: 2.5rem auto;
  max-width: 580px;
  background: rgba(255,255,255,0.04);
}
.accom-box p { color: rgba(255,255,255,0.55); font-size: 0.92rem; margin-bottom: 1.75rem; }

/* Schedule */
.event-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-top: 2.5rem;
}
.event-card { border: 0.5px solid var(--border); padding: 1.75rem; background: var(--ivory); text-align: left; }
.event-card .event-date { font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--saffron); margin-bottom: 0.5rem; }
.event-card h4 { font-family: 'Cormorant Garamond', serif; font-size: 1.2rem; font-weight: 400; margin-bottom: 0.6rem; }
.event-card .event-meta { font-size: 0.84rem; color: var(--text-muted); line-height: 1.8; }
.event-card .event-dress {
  display: inline-block;
  margin-top: 1rem;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-dark);
  border: 0.5px solid var(--gold);
  padding: 0.3rem 0.75rem;
}

/* Khanda */
.khanda { width: 36px; height: 36px; opacity: 0.7; }

/* Footer */
footer {
  text-align: center;
  padding: 3.5rem 2rem;
  background: var(--midnight);
  border-top: 0.5px solid rgba(191,160,106,0.12);
}
footer .footer-names {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.6rem;
  font-style: italic;
  color: var(--candle-soft);
  margin-bottom: 0.5rem;
}
footer p { font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase; color: rgba(255,255,255,0.3); }
footer a { color: var(--candle); text-decoration: none; border-bottom: 0.5px solid var(--candle); }

/* Animations */
.fade-in { opacity: 0; transform: translateY(18px); animation: fadeUp 1s ease forwards; }
.d1 { animation-delay: 0.15s; }
.d2 { animation-delay: 0.4s; }
.d3 { animation-delay: 0.65s; }
.d4 { animation-delay: 0.9s; }
.d5 { animation-delay: 1.15s; }
.d6 { animation-delay: 1.4s; }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

/* ── Coming Soon (desktop) ── */
.coming-soon-row {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  max-width: 900px;
  margin: 0 auto;
}
.coming-soon-card-desktop {
  flex: 1;
  border: 0.5px solid rgba(191,160,106,0.18);
  padding: 2rem 1.5rem;
  text-align: center;
  background: rgba(255,255,255,0.02);
  max-width: 280px;
}
.coming-soon-card-desktop svg {
  margin-bottom: 1rem;
}
.coming-soon-card-desktop h4 {
  font-family: 'Jost', sans-serif;
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.75);
  margin-bottom: 0.5rem;
}
.coming-soon-card-desktop p {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.35);
  line-height: 1.6;
  margin: 0;
}

/* ══════════════════════════════════════════════
   MOBILE — tablet (≤768px)
   ══════════════════════════════════════════════ */
@media (max-width: 768px) {

  .hero {
    padding-top: 1.5rem;
    padding-bottom: 2rem;
  }
  .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(13,27,42,0.65) 0%,
      rgba(13,27,42,0.10) 35%,
      rgba(13,27,42,0.10) 55%,
      rgba(13,27,42,0.80) 100%
    );
  }

  /* Hide palm leaf SVGs on mobile */
  .hero svg[style*="position:absolute"] { display: none; }

  nav { padding: 1rem 1.25rem; }
  .nav-links { gap: 1.5rem; }
  .form-grid { grid-template-columns: 1fr; }
  .venue-grid { grid-template-columns: 1fr; }
  .countdown-unit { padding: 0.7rem 1rem; }
  .event-cards { grid-template-columns: 1fr; padding: 0 1.25rem; }
  .summary-row { grid-template-columns: 1fr 1fr; }
}

/* ══════════════════════════════════════════════
   MOBILE — phone (≤480px)
   ══════════════════════════════════════════════ */
@media (max-width: 480px) {

  .nav-links { display: none; }

  /* Hero text */
  .hero-content { padding: 0 1.25rem; max-width: 100%; }
  .hero-save-the-date { font-size: 1.1rem; }
  .hero-names { font-size: clamp(2.4rem, 12vw, 3.2rem); margin-bottom: 0.5rem; }

  /* Countdown */
  .countdown { margin-bottom: 0.4rem; }
  .countdown-unit { padding: 0.6rem 0.85rem; }
  .countdown-number { font-size: 1.6rem; }
  .countdown-label { font-size: 0.52rem; }

  /* Scroll cue */
  .scroll-cue { bottom: 1.25rem; }

  /* Guest page */
  .guest-hero { padding: 3.5rem 1.25rem 2.5rem; }
  .gs-section .section-inner,
  .gs-ivory .section-inner,
  .gs-dark .section-inner { padding: 3rem 1.25rem; }
  .venue-grid { gap: 0.75rem; }
  .venue-card { padding: 1.25rem; }
  .event-card { padding: 1.25rem; }
  .gate-box { padding: 2.5rem 1.5rem; margin: 0 1rem; }
  .guest-row { grid-template-columns: 1fr; }
  .attending-count-row { gap: 0.75rem; }

  /* Prevent iOS zoom on inputs */
  .form-field input,
  .form-field select,
  .form-field textarea { font-size: 16px; }
  .btn { padding: 0.85rem 1.75rem; width: 100%; }

  /* Admin */
  .admin-body { padding: 1rem; }
  .summary-row { grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-bottom: 1.5rem; }
  .summary-card { padding: 1rem; }
  .summary-card .s-number { font-size: 1.8rem; }
  .table-toolbar { flex-direction: column; align-items: stretch; }
  .search-input { max-width: 100%; }
  .rsvp-table-wrap { font-size: 0.72rem; }
  thead th { padding: 0.6rem 0.75rem; }
  tbody td { padding: 0.6rem 0.75rem; }
  .admin-nav { padding: 0.75rem 1rem; }
  .admin-nav-title { font-size: 0.9rem; }

  footer { padding: 2rem 1.25rem; }
  .desktop-footer { display: none; }
}
