/* ═══════════════════════════════════════════
   SAM & JUSTINE — WEDDING SITE STYLES
   ═══════════════════════════════════════════ */

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

:root {
  --olive: #3B3B27;
  --olive-lt: #4A4A35;
  --olive-md: #555542;
  --cream: #F4EDE3;
  --cream-dk: #E8E0D4;
  --beige: #D4C9B8;
  --brown: #8B7355;
  --brown-lt: #A8956F;
  --gold: #C4A962;
  --gold-soft: rgba(196,169,98,0.15);
  --white: #FDFCFA;
  --warm-bg: #EDE5D8;
  --error: #A04040;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  color: var(--olive);
  background: var(--cream);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── NAV ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 0 24px; height: 56px;
  display: flex; align-items: center; justify-content: space-between;
  transition: background 0.4s ease, border-color 0.4s ease;
  background: var(--olive);
  border-bottom: 1px solid transparent;
}
.nav.transparent { background: transparent; }
.nav.scrolled { background: var(--olive); border-bottom-color: rgba(196,169,98,0.15); }

.nav-logo {
  background: none; border: none; cursor: pointer;
  font-family: 'Playfair Display', serif; font-size: 15px; font-style: italic;
  color: var(--cream); letter-spacing: 1px; text-decoration: none;
}

.nav-links { display: flex; gap: 28px; align-items: center; flex-wrap: wrap; }

.nav-link {
  font-family: 'Josefin Sans', sans-serif; font-size: 10px; font-weight: 300;
  letter-spacing: 3px; text-transform: uppercase; color: var(--cream);
  text-decoration: none; transition: opacity 0.3s;
}
.nav-link:hover { opacity: 0.7; }
.nav-link.cta {
  border: 1px solid var(--gold); padding: 6px 16px; border-radius: 1px;
}

/* ── SECTION HERO (olive header) ── */
.section-hero {
  width: 100%; padding: 100px 24px 50px; text-align: center;
  background: linear-gradient(170deg, var(--olive) 0%, var(--olive-lt) 60%, var(--olive-md) 100%);
  color: var(--cream); position: relative;
}
.section-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 50%, rgba(196,169,98,0.06) 0%, transparent 50%),
              radial-gradient(ellipse at 80% 30%, rgba(196,169,98,0.04) 0%, transparent 50%);
}
.section-hero > * { position: relative; }
.section-hero .the { font-family: 'Playfair Display', serif; font-style: italic; font-size: 18px; opacity: 0.6; margin-bottom: 4px; }
.section-hero h1 { font-family: 'Playfair Display', serif; font-size: clamp(32px, 6vw, 48px); font-weight: 400; letter-spacing: 5px; text-transform: uppercase; margin: 0 0 10px; }
.section-hero .subtitle { font-family: 'Playfair Display', serif; font-style: italic; font-size: clamp(18px, 3vw, 24px); color: var(--gold); letter-spacing: 2px; margin: 0 0 16px; }
.section-hero .detail { font-family: 'Josefin Sans', sans-serif; font-size: 11px; font-weight: 300; letter-spacing: 5px; text-transform: uppercase; opacity: 0.6; }

.gold-divider { width: 40px; height: 1px; background: var(--gold); margin: 0 auto 16px; opacity: 0.5; }

/* ── HERO (home) ── */
.hero {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  padding: 80px 24px 60px; position: relative; overflow: hidden;
}
.hero-photo {
  width: 280px; height: 340px; border-radius: 180px 180px 4px 4px;
  background: linear-gradient(180deg, #8FAABD 0%, #6A8FA8 40%, #4A7A95 100%);
  margin-bottom: 40px; position: relative; overflow: hidden;
  box-shadow: 0 20px 60px rgba(59,59,39,0.15);
}
.hero-photo .placeholder {
  position: absolute; bottom: 16px; left: 0; right: 0; text-align: center;
  font-family: 'Josefin Sans', sans-serif; font-size: 9px; letter-spacing: 3px;
  color: rgba(255,255,255,0.6); text-transform: uppercase;
}
.hero-pre { font-family: 'Josefin Sans', sans-serif; font-size: 12px; font-weight: 300; letter-spacing: 6px; text-transform: uppercase; color: var(--brown); margin-bottom: 8px; }
.hero h1 { font-family: 'Playfair Display', serif; font-weight: 400; font-size: clamp(32px, 7vw, 56px); line-height: 1.15; margin: 0 0 4px; letter-spacing: 3px; text-transform: uppercase; }
.hero h1.script { font-style: italic; font-size: clamp(36px, 8vw, 64px); line-height: 1; margin: 0 0 24px; text-transform: none; }
.hero .venue { font-family: 'Josefin Sans', sans-serif; font-size: 11px; font-weight: 300; letter-spacing: 5px; text-transform: uppercase; color: var(--brown); }

/* ── THE PLAN ── */
.plan {
  padding: 80px 24px;
  background-image: linear-gradient(rgba(244,237,227,0.85), rgba(244,237,227,0.85)),
    repeating-linear-gradient(0deg, transparent, transparent 40px, rgba(59,59,39,0.03) 40px, rgba(59,59,39,0.03) 41px),
    repeating-linear-gradient(90deg, transparent, transparent 40px, rgba(59,59,39,0.03) 40px, rgba(59,59,39,0.03) 41px);
}
.plan-inner { max-width: 600px; margin: 0 auto; }
.plan .the { font-family: 'Playfair Display', serif; font-style: italic; font-size: 20px; color: var(--olive); margin-bottom: 2px; opacity: 0.7; }
.plan h2 { font-family: 'Playfair Display', serif; font-size: clamp(28px, 5vw, 40px); font-weight: 400; letter-spacing: 2px; margin: 0 0 48px; }

.plan-item { display: flex; align-items: baseline; gap: 20px; margin-bottom: 28px; padding-bottom: 28px; border-bottom: 1px solid var(--beige); }
.plan-item:last-child { border-bottom: none; }
.plan-date { font-family: 'Josefin Sans', sans-serif; font-size: 13px; font-weight: 400; letter-spacing: 3px; white-space: nowrap; min-width: 130px; }
.plan-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; margin-top: 6px; }
.plan-dot.gold { background: var(--gold); }
.plan-dot.brown { background: var(--brown-lt); }
.plan-event { font-family: 'Cormorant Garamond', serif; font-size: 19px; color: var(--olive-md); }

/* ── THE WEDDING ── */
.wedding { background: var(--olive); color: var(--cream); padding: 80px 24px; text-align: center; }
.wedding .the { font-family: 'Playfair Display', serif; font-style: italic; font-size: 18px; opacity: 0.6; margin-bottom: 2px; }
.wedding h2 { font-family: 'Playfair Display', serif; font-size: clamp(30px, 6vw, 48px); font-weight: 400; letter-spacing: 5px; text-transform: uppercase; margin: 0 0 50px; }
.wedding-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; max-width: 800px; margin: 0 auto; }
.wedding-card { text-align: center; }
.wedding-card .icon { margin-bottom: 18px; opacity: 0.7; }
.wedding-card h3 { font-family: 'Playfair Display', serif; font-size: 18px; font-weight: 400; letter-spacing: 2px; margin-bottom: 14px; }
.wedding-card p { font-family: 'Cormorant Garamond', serif; font-size: 16px; font-weight: 300; line-height: 1.7; opacity: 0.8; max-width: 220px; margin: 0 auto; }

/* ── DETAILS SPLIT ── */
.details-split { display: flex; flex-wrap: wrap; min-height: 400px; }
.details-photo { flex: 1 1 50%; min-width: 300px; min-height: 400px; background: linear-gradient(135deg, #5A7A4A 0%, #4A6A3A 50%, #3A5A2A 100%); display: flex; align-items: center; justify-content: center; }
.details-content { flex: 1 1 50%; min-width: 300px; background: var(--warm-bg); display: flex; align-items: center; justify-content: center; padding: 60px 40px; text-align: center; }
.details-content .the { font-family: 'Playfair Display', serif; font-style: italic; font-size: 14px; color: var(--brown); margin-bottom: 2px; opacity: 0.7; }
.details-content h2 { font-family: 'Playfair Display', serif; font-size: clamp(26px, 4vw, 38px); font-weight: 400; letter-spacing: 4px; text-transform: uppercase; margin: 0 0 36px; }
.details-content h3 { font-family: 'Playfair Display', serif; font-size: 18px; font-weight: 400; margin-bottom: 14px; letter-spacing: 1px; }
.details-content p { font-family: 'Cormorant Garamond', serif; font-size: 16px; font-weight: 300; color: var(--olive-md); line-height: 1.7; max-width: 340px; margin: 0 auto 28px; }
.details-divider { width: 30px; height: 1px; background: var(--beige); margin: 0 auto 28px; }

/* ── REGISTRY TEASER ── */
.registry-teaser { background: var(--olive); color: var(--cream); padding: 80px 24px; text-align: center; }
.registry-teaser .inner { max-width: 600px; margin: 0 auto; }
.registry-teaser .gift-the { font-family: 'Playfair Display', serif; font-style: italic; font-size: 22px; opacity: 0.5; margin-bottom: 0; }
.registry-teaser h2 { font-family: 'Playfair Display', serif; font-size: clamp(30px, 5vw, 44px); font-weight: 400; letter-spacing: 4px; text-transform: uppercase; margin: 0 0 24px; }
.registry-teaser .lead { font-family: 'Cormorant Garamond', serif; font-size: 20px; font-weight: 300; line-height: 1.7; font-style: italic; opacity: 0.85; max-width: 440px; margin: 0 auto 12px; }
.registry-teaser .sub { font-family: 'Cormorant Garamond', serif; font-size: 17px; font-weight: 300; opacity: 0.6; margin-bottom: 32px; }

/* ── FAQs ── */
.faqs { padding: 80px 24px; text-align: center; }
.faqs h2 { font-family: 'Playfair Display', serif; font-size: clamp(28px, 5vw, 42px); font-weight: 400; letter-spacing: 3px; margin: 0 0 50px; }
.faqs-inner { max-width: 540px; margin: 0 auto; }

.faq-item { border-bottom: 1px solid var(--beige); text-align: left; }
.faq-question {
  width: 100%; background: none; border: none; cursor: pointer;
  padding: 20px 0; display: flex; justify-content: space-between; align-items: center;
  font-family: 'Playfair Display', serif; font-size: 17px; font-weight: 400;
  color: var(--olive);
}
.faq-toggle {
  font-family: 'Josefin Sans', sans-serif; font-size: 18px; font-weight: 200;
  color: var(--brown); transition: transform 0.3s;
}
.faq-item.open .faq-toggle { transform: rotate(45deg); }
.faq-answer {
  max-height: 0; overflow: hidden; transition: max-height 0.4s ease, opacity 0.3s; opacity: 0;
}
.faq-item.open .faq-answer { max-height: 200px; opacity: 1; }
.faq-answer p {
  font-family: 'Cormorant Garamond', serif; font-size: 16px; font-weight: 300;
  color: var(--olive-md); line-height: 1.7; padding-bottom: 20px;
}

/* ── RSVP FOOTER ── */
.rsvp-footer { background: var(--olive); color: var(--cream); padding: 80px 24px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 40px; }
.rsvp-footer h2 { font-family: 'Playfair Display', serif; font-size: clamp(26px, 5vw, 40px); font-weight: 400; line-height: 1.3; }
.rsvp-footer .gold { font-style: italic; color: var(--gold); }
.footer-bottom { width: 100%; margin-top: 40px; padding-top: 24px; border-top: 1px solid rgba(196,169,98,0.15); display: flex; justify-content: space-between; align-items: center; }
.footer-sig { font-family: 'Playfair Display', serif; font-style: italic; font-size: 14px; opacity: 0.5; }

/* ── BUTTONS ── */
.btn {
  display: inline-block; padding: 14px 36px; border-radius: 2px;
  font-family: 'Josefin Sans', sans-serif; font-size: 11px; font-weight: 300;
  letter-spacing: 4px; text-transform: uppercase; cursor: pointer;
  transition: all 0.3s ease; text-decoration: none; border: none;
}
.btn-outline { background: transparent; border: 1px solid var(--gold); color: var(--cream); }
.btn-outline:hover { background: var(--gold); color: var(--olive); }
.btn-solid { background: var(--olive); color: var(--cream); }
.btn-solid:hover { background: var(--olive-lt); }
.btn-light { background: none; border: 1px solid var(--beige); color: var(--olive); }
.btn-light:hover { background: var(--olive); color: var(--cream); border-color: var(--olive); }
.btn-full { width: 100%; text-align: center; }

/* ── FORMS ── */
.form-container { max-width: 560px; margin: 0 auto; padding: 40px 24px 60px; }
.form-section-title {
  font-family: 'Josefin Sans', sans-serif; font-size: 13px; font-weight: 300;
  letter-spacing: 5px; text-transform: uppercase; color: var(--brown);
  margin-bottom: 28px; text-align: center;
}
.field { margin-bottom: 28px; }
.field label {
  display: block; font-family: 'Josefin Sans', sans-serif; font-size: 10px;
  font-weight: 400; letter-spacing: 3px; text-transform: uppercase;
  color: var(--olive-md); margin-bottom: 8px;
}
.field input, .field select, .field textarea {
  width: 100%; padding: 14px 16px;
  border: 1px solid var(--beige); border-radius: 2px; background: var(--white);
  font-family: 'Cormorant Garamond', serif; font-size: 17px; color: var(--olive);
  outline: none; transition: border-color 0.3s;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brown); }
.field textarea { resize: vertical; min-height: 80px; }
.field select { appearance: none; cursor: pointer; }
.field .select-wrap { position: relative; }
.field .select-arrow { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--brown); font-size: 10px; }
.field-error { font-family: 'Josefin Sans', sans-serif; font-size: 11px; color: var(--error); margin-top: 6px; }
.field.has-error input, .field.has-error select { border-color: var(--error); }

.rsvp-toggle { display: flex; gap: 12px; }
.rsvp-option {
  flex: 1; padding: 16px; border: 1px solid var(--beige); border-radius: 2px;
  background: var(--white); color: var(--olive); text-align: center;
  font-family: 'Josefin Sans', sans-serif; font-size: 11px;
  letter-spacing: 3px; text-transform: uppercase; cursor: pointer; transition: all 0.3s;
}
.rsvp-option.selected { background: var(--olive); color: var(--cream); border-color: var(--olive); }

.radio-option {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border: 1px solid var(--beige); border-radius: 2px;
  background: var(--white); margin-bottom: 8px; cursor: pointer; transition: border-color 0.3s;
}
.radio-option.selected { border-color: var(--brown); }
.radio-check {
  width: 18px; height: 18px; border: 1px solid var(--beige); border-radius: 1px;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; transition: all 0.2s;
}
.radio-option.selected .radio-check { background: var(--olive); border-color: var(--olive); }
.radio-check .tick { color: var(--cream); font-size: 11px; display: none; }
.radio-option.selected .radio-check .tick { display: block; }
.radio-label { font-family: 'Cormorant Garamond', serif; font-size: 16px; }

.form-note { text-align: center; margin-top: 36px; font-family: 'Josefin Sans', sans-serif; font-size: 10px; font-weight: 300; letter-spacing: 4px; text-transform: uppercase; color: var(--beige); }
.back-link { display: block; text-align: center; margin-top: 20px; background: none; border: none; cursor: pointer; font-family: 'Josefin Sans', sans-serif; font-size: 10px; letter-spacing: 2px; color: var(--brown); text-decoration: underline; text-underline-offset: 3px; text-transform: uppercase; }

/* ── SUCCESS ── */
.success-page { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px 24px; }
.success-icon { width: 60px; height: 60px; border-radius: 50%; border: 1px solid var(--gold); display: flex; align-items: center; justify-content: center; margin-bottom: 30px; color: var(--gold); font-size: 24px; }
.success-page h2 { font-family: 'Playfair Display', serif; font-size: 28px; font-weight: 400; margin-bottom: 12px; }
.success-page p { font-family: 'Cormorant Garamond', serif; font-size: 19px; color: var(--olive-md); line-height: 1.6; max-width: 400px; }

/* ── REGISTRY PAGE ── */
.registry-intro { max-width: 560px; margin: 0 auto; padding: 48px 24px 16px; text-align: center; }
.registry-intro p { font-family: 'Cormorant Garamond', serif; font-size: 20px; font-weight: 300; line-height: 1.7; color: var(--olive-md); font-style: italic; }

.funds-section { max-width: 700px; margin: 0 auto; padding: 0 24px 48px; }
.funds-label { font-family: 'Josefin Sans', sans-serif; font-size: 11px; font-weight: 300; letter-spacing: 5px; text-transform: uppercase; color: var(--brown); text-align: center; margin-bottom: 32px; }

.fund-card {
  background: var(--white); border: 1px solid var(--beige); border-radius: 2px;
  padding: 32px; margin-bottom: 20px; position: relative; overflow: hidden;
}
.fund-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(90deg, var(--gold), transparent); }
.fund-header { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.fund-icon { margin-top: 4px; opacity: 0.6; }
.fund-body { flex: 1; min-width: 240px; }
.fund-title { font-family: 'Playfair Display', serif; font-size: 22px; font-weight: 400; letter-spacing: 1px; margin: 0 0 2px; }
.fund-subtitle { font-family: 'Josefin Sans', sans-serif; font-size: 10px; letter-spacing: 3px; text-transform: uppercase; color: var(--gold); margin: 0 0 14px; }
.fund-desc { font-family: 'Cormorant Garamond', serif; font-size: 16px; font-weight: 300; color: var(--olive-md); line-height: 1.7; margin: 0 0 20px; }
.fund-progress-labels { display: flex; justify-content: space-between; margin-bottom: 6px; }
.fund-progress-labels span { font-family: 'Josefin Sans', sans-serif; font-size: 10px; letter-spacing: 2px; }
.fund-progress-labels .raised { color: var(--olive-md); }
.fund-progress-labels .goal { color: var(--beige); }
.fund-bar { width: 100%; height: 4px; background: var(--cream-dk); border-radius: 2px; overflow: hidden; }
.fund-bar-fill { height: 100%; background: linear-gradient(90deg, var(--gold), var(--brown-lt)); border-radius: 2px; transition: width 0.6s ease; }

.gifts-section { background: var(--warm-bg); padding: 60px 24px; }
.gifts-inner { max-width: 700px; margin: 0 auto; }
.gifts-label { font-family: 'Josefin Sans', sans-serif; font-size: 11px; font-weight: 300; letter-spacing: 5px; text-transform: uppercase; color: var(--brown); text-align: center; margin-bottom: 8px; }
.gifts-title { font-family: 'Playfair Display', serif; font-size: 26px; font-weight: 400; text-align: center; margin: 0 0 36px; letter-spacing: 2px; }
.gifts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }

.gift-card {
  background: var(--white); border: 1px solid var(--beige); border-radius: 2px;
  padding: 24px 20px; position: relative; transition: opacity 0.3s;
}
.gift-card.claimed { opacity: 0.55; border-color: var(--cream-dk); }
.gift-claimed-badge {
  position: absolute; top: 12px; right: 12px;
  font-family: 'Josefin Sans', sans-serif; font-size: 8px; letter-spacing: 2px;
  text-transform: uppercase; color: var(--gold); background: var(--gold-soft);
  padding: 3px 8px; border-radius: 1px;
}
.gift-card h4 { font-family: 'Playfair Display', serif; font-size: 16px; font-weight: 400; margin: 0 0 6px; }
.gift-card .desc { font-family: 'Cormorant Garamond', serif; font-size: 14px; font-weight: 300; color: var(--olive-md); line-height: 1.5; margin: 0 0 12px; }
.gift-card .price { font-family: 'Josefin Sans', sans-serif; font-size: 14px; font-weight: 400; margin: 0 0 14px; }

/* ── MODALS ── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(59,59,39,0.6);
  z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 24px;
}
.modal {
  background: var(--cream); border-radius: 2px; max-width: 440px; width: 100%;
  max-height: 90vh; overflow: auto; padding: 36px 32px;
}
.modal h3 { font-family: 'Playfair Display', serif; font-size: 22px; font-weight: 400; margin: 0 0 4px; }
.modal .modal-sub { font-family: 'Josefin Sans', sans-serif; font-size: 10px; letter-spacing: 3px; color: var(--gold); text-transform: uppercase; margin: 0 0 24px; }
.modal-close { background: none; border: none; font-size: 24px; color: var(--beige); cursor: pointer; font-weight: 200; }
.modal-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 24px; }
.modal-note { font-family: 'Cormorant Garamond', serif; font-size: 14px; color: var(--olive-md); line-height: 1.6; margin-bottom: 20px; font-style: italic; }

.preset-amounts { display: flex; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.preset-btn {
  padding: 8px 16px; border: 1px solid var(--beige); border-radius: 2px;
  background: var(--white); color: var(--olive);
  font-family: 'Josefin Sans', sans-serif; font-size: 12px; cursor: pointer; transition: all 0.2s;
}
.preset-btn.selected { background: var(--olive); color: var(--cream); border-color: var(--olive); }

.modal-actions { display: flex; gap: 12px; }
.modal-actions .btn { flex: 1; padding: 14px; text-align: center; }

.page-nav { background: var(--cream); padding: 40px 24px; text-align: center; display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ── PHOTO PLACEHOLDER ── */
.photo-placeholder {
  width: 200px; height: 260px; border: 1px solid rgba(255,255,255,0.2); border-radius: 2px;
  display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 8px;
}
.photo-placeholder span {
  font-family: 'Josefin Sans', sans-serif; font-size: 9px; letter-spacing: 3px;
  color: rgba(255,255,255,0.4); text-transform: uppercase;
}

/* ── LOADING ── */
.loading { min-height: 60vh; display: flex; align-items: center; justify-content: center; }
.loading p { font-family: 'Cormorant Garamond', serif; font-size: 18px; color: var(--olive-md); }

/* ── HIDDEN SECTIONS ── */
.hidden { display: none !important; }

/* ── RESPONSIVE ── */
@media (max-width: 640px) {
  .nav-links { gap: 16px; }
  .nav-link { font-size: 9px; letter-spacing: 2px; }
  .plan-item { flex-direction: column; gap: 8px; }
  .plan-date { min-width: auto; }
  .rsvp-footer { text-align: center; justify-content: center; }
  .details-photo { min-height: 280px; }
}
