/* ==========================================================================
   THE ROYAL NIKAH & WALIMA — ZAYD & ZOYA
   Luxury Islamic Wedding Invitation Design System
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. CSS Variables & Design Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Royal Islamic Emerald & Night Colors */
  --bg-dark: #041611;
  --bg-deep: #020d0a;
  --bg-card: rgba(10, 36, 28, 0.85);
  --bg-card-hover: rgba(15, 52, 41, 0.95);
  --bg-surface: #0a2920;
  
  /* Imperial Gold Tones */
  --gold-primary: #d4af37;
  --gold-light: #f7e7a9;
  --gold-bright: #ffe082;
  --gold-dark: #997b1a;
  --gold-antique: #b38f2a;
  --gold-glow: rgba(212, 175, 55, 0.45);
  --gold-border: rgba(212, 175, 55, 0.42);
  --gold-border-subtle: rgba(212, 175, 55, 0.2);

  /* Jewel Accent Tones */
  --accent-ruby: #881326;
  --accent-sapphire: #0e2744;
  --accent-amber: #f59e0b;
  --accent-henna: #15432a;

  /* Typography Colors */
  --text-pure: #ffffff;
  --text-cream: #faf5e8;
  --text-gold: #f5df9e;
  --text-muted: #b0c9c2;
  --text-dim: #7a9c93;

  /* Fonts */
  --font-arabic: 'Amiri', serif;
  --font-royal: 'Cinzel Decorative', 'Cinzel', serif;
  --font-serif: 'Cinzel', serif;
  --font-script: 'Great Vibes', cursive;
  --font-sans: 'Montserrat', sans-serif;

  /* Elevations & Effects */
  --shadow-gold: 0 10px 30px -5px rgba(212, 175, 55, 0.3), 0 0 20px rgba(212, 175, 55, 0.18);
  --shadow-card: 0 14px 40px -8px rgba(0, 0, 0, 0.75), 0 0 1px 1px var(--gold-border);
  --radius-mehrab: 140px 140px 16px 16px;
  --radius-card: 18px;
  --transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --------------------------------------------------------------------------
   2. Reset & Base Setup
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-cream);
  font-family: var(--font-sans);
  overflow-x: hidden;
  line-height: 1.65;
  position: relative;
  min-height: 100vh;
  /* Islamic Arabesque Star Pattern */
  background-image: 
    radial-gradient(var(--bg-surface) 1px, transparent 1px),
    radial-gradient(rgba(212, 175, 55, 0.08) 1px, transparent 1px);
  background-size: 28px 28px, 56px 56px;
  background-position: 0 0, 14px 14px;
  background-attachment: fixed;
}

::selection {
  background: var(--gold-primary);
  color: var(--bg-dark);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 9px;
}
::-webkit-scrollbar-track {
  background: var(--bg-deep);
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(to bottom, var(--gold-primary), var(--gold-dark));
  border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold-light);
}

/* --------------------------------------------------------------------------
   3. WINDOW DESIGNER FRAME & CORNER ORNAMENTS (Luxury Border)
   -------------------------------------------------------------------------- */
.window-designer-frame {
  position: fixed;
  inset: 14px;
  border: 1.5px solid rgba(212, 175, 55, 0.45);
  box-shadow: 
    inset 0 0 25px rgba(212, 175, 55, 0.08),
    0 0 35px rgba(0, 0, 0, 0.85);
  pointer-events: none;
  z-index: 38;
  border-radius: 12px;
}

.window-designer-frame::before {
  content: '';
  position: absolute;
  inset: 5px;
  border: 1px dashed rgba(212, 175, 55, 0.28);
  border-radius: 9px;
  pointer-events: none;
}

.corner-ornament {
  position: fixed;
  width: 90px;
  height: 90px;
  pointer-events: none;
  z-index: 39;
}

.corner-top-left {
  top: 14px;
  left: 14px;
}

.corner-top-right {
  top: 14px;
  right: 14px;
  transform: scaleX(-1);
}

.corner-bottom-left {
  bottom: 14px;
  left: 14px;
  transform: scaleY(-1);
}

.corner-bottom-right {
  bottom: 14px;
  right: 14px;
  transform: scale(-1, -1);
}

.corner-svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 8px rgba(212, 175, 55, 0.5));
}

.frame-pelmet-top {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: 240px;
  height: 28px;
  pointer-events: none;
  z-index: 39;
}

.frame-crest-bottom {
  position: fixed;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 24px;
  pointer-events: none;
  z-index: 39;
}

/* --------------------------------------------------------------------------
   4. Card Designer Borders & Corner Notches
   -------------------------------------------------------------------------- */
.ayah-box,
.scratch-box,
.person-card,
.ceremony-card,
.venue-card,
.blessings-card,
.rsvp-card-cta,
.modal-dialog {
  border: 1.5px solid var(--gold-border);
  box-shadow: 
    0 14px 40px -8px rgba(0, 0, 0, 0.75),
    0 0 0 1px rgba(212, 175, 55, 0.15),
    inset 0 0 20px rgba(212, 175, 55, 0.05);
  position: relative;
}

.card-corner {
  position: absolute;
  width: 16px;
  height: 16px;
  border-color: var(--gold-primary);
  border-style: solid;
  pointer-events: none;
  opacity: 0.85;
}

.card-corner-tl {
  top: 8px;
  left: 8px;
  border-width: 2px 0 0 2px;
}
.card-corner-tr {
  top: 8px;
  right: 8px;
  border-width: 2px 2px 0 0;
}
.card-corner-bl {
  bottom: 8px;
  left: 8px;
  border-width: 0 0 2px 2px;
}
.card-corner-br {
  bottom: 8px;
  right: 8px;
  border-width: 0 2px 2px 0;
}

/* --------------------------------------------------------------------------
   5. Icon Utilities (Lucide & Vector SVGs)
   -------------------------------------------------------------------------- */
.icon-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: -0.15em;
  width: 1.15em;
  height: 1.15em;
  stroke-width: 2px;
  color: var(--gold-light);
}

.ceremony-icon-wrapper {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.22) 0%, rgba(5, 25, 18, 0.75) 100%);
  border: 1.5px solid var(--gold-primary);
  box-shadow: 0 4px 18px rgba(212, 175, 55, 0.25);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.ceremony-card:hover .ceremony-icon-wrapper {
  transform: scale(1.1);
  box-shadow: 0 6px 22px rgba(212, 175, 55, 0.45);
}

.ceremony-icon-wrapper i,
.ceremony-icon-wrapper svg {
  width: 28px;
  height: 28px;
  color: var(--gold-bright);
}

.avatar-icon {
  width: 44px;
  height: 44px;
  color: var(--gold-bright);
}

.rsvp-top-icon {
  width: 48px;
  height: 48px;
  color: var(--gold-primary);
  margin: 0 auto 12px;
  display: block;
  filter: drop-shadow(0 0 10px var(--gold-glow));
}

.float-icon {
  width: 22px;
  height: 22px;
  color: var(--gold-light);
}

.nav-crest-svg {
  width: 28px;
  height: 28px;
  color: var(--gold-primary);
  filter: drop-shadow(0 0 6px var(--gold-glow));
}

/* --------------------------------------------------------------------------
   6. Ambient Background Petals Canvas
   -------------------------------------------------------------------------- */
#ambient-petals-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 5;
}

/* --------------------------------------------------------------------------
   7. Hanging Royal Fanoos (Islamic Lanterns)
   -------------------------------------------------------------------------- */
.fanoos-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  padding: 0 28px;
  pointer-events: none;
  z-index: 40;
}

.lantern-wrapper {
  pointer-events: auto;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform-origin: top center;
  transition: transform 0.2s ease;
}

.lantern-wrapper:hover {
  filter: drop-shadow(0 0 16px rgba(255, 224, 130, 0.95));
}

.lantern-left {
  animation: lanternSwingLeft 5.5s ease-in-out infinite alternate;
}

.lantern-right {
  animation: lanternSwingRight 6.2s ease-in-out infinite alternate;
  animation-delay: -1.8s;
}

@keyframes lanternSwingLeft {
  0% { transform: rotate(-4.5deg); }
  100% { transform: rotate(5deg); }
}

@keyframes lanternSwingRight {
  0% { transform: rotate(4deg); }
  100% { transform: rotate(-5.5deg); }
}

.lantern-sway-pulse {
  animation: lanternClickJolt 0.8s cubic-bezier(0.25, 1, 0.5, 1) !important;
}

@keyframes lanternClickJolt {
  0% { transform: rotate(0deg) scale(1.05); }
  25% { transform: rotate(-12deg) scale(1.08); }
  50% { transform: rotate(10deg) scale(1.04); }
  75% { transform: rotate(-6deg) scale(1.02); }
  100% { transform: rotate(0deg) scale(1); }
}

.fanoos-svg {
  width: 75px;
  height: 220px;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.6));
}

.lantern-hint {
  font-size: 10px;
  font-family: var(--font-serif);
  color: var(--gold-light);
  letter-spacing: 1px;
  opacity: 0.75;
  margin-top: -10px;
  text-transform: uppercase;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* --------------------------------------------------------------------------
   8. Top Audio Autoplay Announcement Banner
   -------------------------------------------------------------------------- */
.audio-banner {
  position: fixed;
  top: 78px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 20px;
  border-radius: 30px;
  background: rgba(10, 36, 28, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--gold-primary);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5), 0 0 15px var(--gold-glow);
  cursor: pointer;
  animation: bannerFloat 3s ease-in-out infinite alternate;
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.audio-banner.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(-20px);
}

@keyframes bannerFloat {
  0% { transform: translateX(-50%) translateY(0); }
  100% { transform: translateX(-50%) translateY(4px); }
}

.audio-banner-text {
  font-size: 0.78rem;
  color: var(--text-gold);
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.audio-banner-btn {
  font-size: 0.68rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 1px;
  background: var(--gold-primary);
  color: var(--bg-deep);
  padding: 3px 12px;
  border-radius: 12px;
}

/* --------------------------------------------------------------------------
   9. Navigation Bar
   -------------------------------------------------------------------------- */
.royal-navbar {
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 50;
  background: rgba(4, 22, 17, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--gold-border-subtle);
  transition: var(--transition);
}

.nav-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 12px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
  white-space: nowrap;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-family: var(--font-royal);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--gold-light);
  letter-spacing: 1.5px;
  white-space: nowrap;
}

.brand-sub {
  font-family: var(--font-arabic);
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
}

.nav-link {
  text-decoration: none;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  font-weight: 500;
  position: relative;
  transition: color 0.25s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0%;
  height: 1.5px;
  background: var(--gold-primary);
  transition: width 0.3s ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--gold-light);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-video-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 30px;
  background: rgba(8, 30, 23, 0.85);
  color: var(--gold-light);
  font-family: var(--font-serif);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--gold-border-subtle);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  transition: var(--transition);
  cursor: pointer;
  white-space: nowrap;
}

.nav-video-toggle:hover {
  border-color: var(--gold-primary);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.35);
}

.nav-video-toggle.active {
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.22) 0%, rgba(8, 30, 23, 0.95) 100%);
  border-color: var(--gold-primary);
  color: var(--gold-bright);
}

.toggle-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  display: inline-block;
  transition: background 0.3s ease, box-shadow 0.3s ease;
  flex-shrink: 0;
}

.nav-video-toggle.is-normal .toggle-indicator {
  background: #64748b;
  box-shadow: none;
}

.toggle-label-full {
  display: inline;
}

.toggle-label-short {
  display: none;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 22px;
  border-radius: 30px;
  background: linear-gradient(135deg, var(--gold-primary) 0%, #aa7c11 100%);
  color: #03140e;
  font-family: var(--font-serif);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--gold-light);
  box-shadow: 0 4px 15px rgba(212, 175, 55, 0.35);
  transition: var(--transition);
  cursor: pointer;
  white-space: nowrap;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.5);
  filter: brightness(1.1);
}

/* --------------------------------------------------------------------------
   10. Typography Utilities & Shimmers
   -------------------------------------------------------------------------- */
.gold-gradient-text {
  background: linear-gradient(135deg, #fff7d6 0%, #d4af37 45%, #b5881c 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.gold-glow-text {
  color: var(--gold-light);
  text-shadow: 0 0 18px var(--gold-glow);
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-serif);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--gold-primary);
  margin-bottom: 12px;
}

.section-heading {
  font-family: var(--font-royal);
  font-size: 2.3rem;
  text-align: center;
  margin-bottom: 10px;
  color: var(--gold-light);
}

.section-subheading {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 36px;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.6;
}

.ornament-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 16px auto 28px;
  max-width: 320px;
}

.ornament-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-primary), transparent);
}

.ornament-icon {
  color: var(--gold-primary);
  display: inline-flex;
  align-items: center;
}

/* --------------------------------------------------------------------------
   11. Hero Section & Video Background Layer
   -------------------------------------------------------------------------- */
.hero-section {
  position: relative;
  min-height: calc(100vh - 70px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 50px 20px 70px;
  overflow: hidden;
}

/* Dynamic Cinematic Video Background Layer (Fixed full viewport behind all content) */
.hero-video-bg-container {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.65s ease;
}

/* Normal Background State: hides video gracefully across the site */
body.normal-bg .hero-video-bg-container,
.hero-video-bg-container.is-normal-bg {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.hero-video-element {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100vw;
  min-height: 100vh;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%) scale(1.08); /* slightly enlarged to prevent blur edge gaps */
  object-fit: cover;
  filter: blur(5px) brightness(0.55) contrast(1.1);
  -webkit-filter: blur(5px) brightness(0.55) contrast(1.1);
  will-change: filter, transform;
}

.hero-video-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(ellipse at 50% 35%, rgba(3, 20, 14, 0.45) 0%, rgba(3, 20, 14, 0.72) 60%, rgba(2, 14, 10, 0.92) 100%),
    linear-gradient(180deg, rgba(3, 20, 14, 0.5) 0%, rgba(3, 20, 14, 0.25) 45%, rgba(2, 14, 10, 0.85) 100%);
  pointer-events: none;
}

/* All content sections scroll on top of the fixed background */
.hero-section,
.scratch-section,
.couple-section,
.ceremonies-section,
.venue-section,
.blessings-section,
.rsvp-section,
.royal-footer {
  position: relative;
  z-index: 2;
}

.bismillah {
  font-family: var(--font-arabic);
  font-size: 2.8rem;
  color: var(--gold-light);
  margin-bottom: 14px;
  text-shadow: 0 0 25px rgba(212, 175, 55, 0.6), 0 3px 6px rgba(0, 0, 0, 0.85);
  letter-spacing: 1px;
  animation: pulseGlow 4s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
  0% { text-shadow: 0 0 15px var(--gold-glow); }
  100% { text-shadow: 0 0 30px rgba(255, 224, 130, 0.8), 0 0 50px rgba(212, 175, 55, 0.4); }
}

.ayah-box {
  background: rgba(10, 38, 29, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 26px 32px;
  max-width: 740px;
  margin: 0 auto 30px;
  position: relative;
}

.ayah-arabic {
  font-family: var(--font-arabic);
  font-size: 1.35rem;
  color: var(--gold-bright);
  line-height: 1.8;
  margin-bottom: 10px;
  direction: rtl;
}

.ayah-english {
  font-size: 0.95rem;
  color: var(--text-cream);
  font-style: italic;
  font-family: 'Playfair Display', serif;
  line-height: 1.6;
}

.ayah-ref {
  display: block;
  margin-top: 8px;
  font-size: 0.78rem;
  color: var(--gold-primary);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-style: normal;
}

.hero-subtitle {
  font-family: var(--font-serif);
  text-transform: uppercase;
  letter-spacing: 3.5px;
  font-size: 0.88rem;
  color: var(--gold-light);
  margin-bottom: 12px;
}

.couple-hero-title {
  font-family: var(--font-royal);
  font-size: clamp(2.8rem, 7vw, 5.2rem);
  letter-spacing: 3px;
  line-height: 1.15;
  margin: 10px 0 16px;
  filter: drop-shadow(0 4px 18px rgba(0, 0, 0, 0.8));
}

.couple-hero-title .ampersand {
  font-family: var(--font-script);
  font-size: 1.15em;
  color: var(--gold-bright);
  margin: 0 12px;
  font-weight: 400;
  display: inline-block;
  transform: translateY(-4px);
}

.hero-invitation-text {
  color: var(--text-muted);
  max-width: 580px;
  font-size: 0.98rem;
  margin: 0 auto 20px;
  line-height: 1.7;
}

.hashtag-btn {
  background: rgba(12, 45, 35, 0.75);
  border: 1.5px solid var(--gold-border);
  border-radius: 30px;
  padding: 8px 22px;
  color: var(--gold-light);
  font-family: var(--font-serif);
  font-size: 0.88rem;
  letter-spacing: 2px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 34px;
}

.hashtag-btn:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: var(--gold-primary);
  transform: scale(1.04);
}

/* --------------------------------------------------------------------------
   12. 3D Mechanical Flip Clock Countdown
   -------------------------------------------------------------------------- */
.countdown-flip-container {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  max-width: 580px;
  margin: 0 auto;
  perspective: 700px;
}

.flip-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.flip-card {
  position: relative;
  width: 90px;
  height: 98px;
  background: #03140e;
  border-radius: 14px;
  box-shadow: 
    0 12px 30px rgba(0, 0, 0, 0.8),
    0 0 0 1.5px rgba(212, 175, 55, 0.45),
    0 0 20px rgba(212, 175, 55, 0.15);
  perspective: 500px;
}

/* Upper static half & Lower static half */
.flip-card-upper,
.flip-card-lower,
.flip-card-flap-front,
.flip-card-flap-back {
  position: absolute;
  left: 0;
  right: 0;
  overflow: hidden;
  display: flex;
  justify-content: center;
  color: var(--gold-bright);
  font-family: var(--font-royal);
  font-size: 2.5rem;
  font-weight: 700;
  text-shadow: 0 0 14px var(--gold-glow);
  box-sizing: border-box;
}

.flip-card-upper {
  top: 0;
  height: 50%;
  align-items: flex-end;
  border-top-left-radius: 14px;
  border-top-right-radius: 14px;
  background: linear-gradient(180deg, #093326 0%, #051a13 100%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.75);
}

.flip-card-upper .flip-num {
  transform: translateY(50%);
}

.flip-card-lower {
  bottom: 0;
  height: 50%;
  align-items: flex-start;
  border-bottom-left-radius: 14px;
  border-bottom-right-radius: 14px;
  background: linear-gradient(180deg, #03140f 0%, #08281d 100%);
  border-top: 1px solid rgba(212, 175, 55, 0.25);
}

.flip-card-lower .flip-num {
  transform: translateY(-50%);
}

/* 3D Flipping Leaf (Flap) - Strictly Unidirectional Downwards */
.flip-leaf {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  transform-style: preserve-3d;
  transform-origin: bottom center;
  z-index: 5;
  /* Strictly NO transition property here to prevent reversing back up */
}

@keyframes flipDownUnidirectional {
  0% {
    transform: rotateX(0deg);
  }
  100% {
    transform: rotateX(-180deg);
  }
}

.flip-leaf.flipping {
  animation: flipDownUnidirectional 0.48s cubic-bezier(0.35, 0, 0.25, 1) forwards;
}

.flip-card-flap-front,
.flip-card-flap-back {
  position: absolute;
  inset: 0;
  overflow: hidden;
  display: flex;
  justify-content: center;
  color: var(--gold-bright);
  font-family: var(--font-royal);
  font-size: 2.5rem;
  font-weight: 700;
  text-shadow: 0 0 14px var(--gold-glow);
  box-sizing: border-box;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.flip-card-flap-front {
  height: 100%;
  align-items: flex-end;
  border-top-left-radius: 14px;
  border-top-right-radius: 14px;
  background: linear-gradient(180deg, #093326 0%, #051a13 100%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.75);
  transform: rotateX(0deg);
}

.flip-card-flap-front .flip-num {
  transform: translateY(50%);
  line-height: 0;
}

.flip-card-flap-back {
  height: 100%;
  align-items: flex-start;
  border-bottom-left-radius: 14px;
  border-bottom-right-radius: 14px;
  background: linear-gradient(180deg, #03140f 0%, #08281d 100%);
  border-top: 1px solid rgba(212, 175, 55, 0.25);
  transform: rotateX(180deg);
}

.flip-card-flap-back .flip-num {
  transform: translateY(-50%);
  line-height: 0;
}

/* Divider seam & Side Metal Hinges */
.flip-divider {
  position: absolute;
  top: calc(50% - 1px);
  left: 0;
  right: 0;
  height: 2px;
  background: rgba(0, 0, 0, 0.85);
  border-bottom: 1px solid rgba(212, 175, 55, 0.35);
  z-index: 10;
  pointer-events: none;
}

.flip-hinge-left, .flip-hinge-right {
  position: absolute;
  top: calc(50% - 5px);
  width: 4px;
  height: 10px;
  background: var(--gold-primary);
  border-radius: 2px;
  z-index: 12;
  box-shadow: 0 0 5px var(--gold-glow);
}

.flip-hinge-left { left: -2px; }
.flip-hinge-right { right: -2px; }

.flip-label {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-top: 10px;
  font-weight: 600;
  font-family: var(--font-serif);
}

/* --------------------------------------------------------------------------
   13. Interactive Scratch Card Section
   -------------------------------------------------------------------------- */
.scratch-section {
  padding: 90px 20px;
  background: linear-gradient(180deg, rgba(3, 19, 14, 0.8) 0%, rgba(5, 26, 19, 0.65) 50%, rgba(3, 19, 14, 0.85) 100%);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  position: relative;
  z-index: 2;
  border-top: 1.5px solid var(--gold-border-subtle);
  border-bottom: 1px solid var(--gold-border-subtle);
  box-shadow: 0 -25px 50px rgba(0, 0, 0, 0.75), 0 25px 50px rgba(0, 0, 0, 0.6);
}

.scratch-card-wrapper {
  max-width: 520px;
  margin: 0 auto;
}

.scratch-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding: 0 4px;
}

.scratch-progress-badge {
  font-size: 0.8rem;
  color: var(--gold-light);
  font-family: var(--font-serif);
}

.scratch-progress-badge strong {
  color: var(--gold-bright);
}

.reveal-all-btn {
  background: transparent;
  border: none;
  color: var(--gold-primary);
  font-size: 0.78rem;
  text-decoration: underline;
  cursor: pointer;
  font-family: var(--font-sans);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.2s ease;
}

.reveal-all-btn:hover {
  color: var(--gold-light);
}

.scratch-box {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 18px;
  overflow: hidden;
  border: 2px solid var(--gold-primary);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.7), 0 0 25px var(--gold-glow);
  background: #06221a;
}

.scratch-content {
  position: absolute;
  inset: 0;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  text-align: center;
  background: radial-gradient(circle at center, #0e3b2e 0%, #062017 100%);
}

.scratch-inner-border {
  position: absolute;
  inset: 10px;
  border: 1px dashed var(--gold-border);
  border-radius: 12px;
  pointer-events: none;
}

.scratch-header-tag {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 2.5px;
  color: var(--gold-light);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.scratch-dua-arabic {
  font-family: var(--font-arabic);
  font-size: 1.4rem;
  color: var(--gold-bright);
  direction: rtl;
  margin: 6px 0;
  line-height: 1.5;
}

.scratch-dua-meaning {
  font-size: 0.85rem;
  color: var(--text-cream);
  max-width: 420px;
  line-height: 1.5;
  font-style: italic;
  font-family: 'Playfair Display', serif;
}

.scratch-dawat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(212, 175, 55, 0.18);
  border: 1px solid var(--gold-primary);
  border-radius: 20px;
  padding: 4px 16px;
  font-size: 0.75rem;
  color: var(--gold-light);
  letter-spacing: 1px;
}

.scratch-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
  z-index: 2;
  transition: opacity 0.6s ease;
}

.scratch-hint {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 14px;
  font-style: italic;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* --------------------------------------------------------------------------
   14. Meet The Couple Section
   -------------------------------------------------------------------------- */
.couple-section {
  padding: 90px 20px;
  max-width: 1100px;
  margin: 0 auto;
}

.couple-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 30px;
  align-items: center;
  margin-top: 40px;
}

.person-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: var(--radius-mehrab);
  padding: 50px 30px 40px;
  text-align: center;
  transition: var(--transition);
}

.person-card:hover {
  transform: translateY(-6px);
  border-color: var(--gold-primary);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 20px var(--gold-glow);
}

.avatar-wrapper {
  width: 120px;
  height: 120px;
  margin: 0 auto 20px;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: #08281d;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #03130d;
}

.person-tag {
  display: inline-block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--gold-primary);
  margin-bottom: 8px;
}

.person-name {
  font-family: var(--font-royal);
  font-size: 1.8rem;
  color: var(--gold-light);
  margin-bottom: 8px;
}

.person-lineage {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 16px;
}

.person-quote {
  font-size: 0.88rem;
  color: var(--text-cream);
  font-style: italic;
  font-family: 'Playfair Display', serif;
  line-height: 1.6;
  border-top: 1px dashed var(--gold-border-subtle);
  padding-top: 14px;
}

.couple-center-emblem {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 10px;
}

.royal-crest-circle {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  border: 2px solid var(--gold-primary);
  background: radial-gradient(circle, #0e3a2c 0%, #051912 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 25px var(--gold-glow);
  margin-bottom: 14px;
}

.monogram-letters {
  font-family: var(--font-royal);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold-bright);
  letter-spacing: 1px;
}

.union-dua-quote {
  font-family: var(--font-script);
  font-size: 1.8rem;
  color: var(--gold-light);
  margin-top: 8px;
}

/* --------------------------------------------------------------------------
   15. Ceremonies & Festivities Timeline
   -------------------------------------------------------------------------- */
.ceremonies-section {
  padding: 90px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.ceremonies-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 26px;
  margin-top: 40px;
}

.ceremony-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: var(--radius-mehrab);
  padding: 42px 24px 30px;
  text-align: center;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.ceremony-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.65), 0 0 25px var(--gold-glow);
  border-color: var(--gold-primary);
}

.theme-haldi {
  background: linear-gradient(180deg, rgba(46, 36, 10, 0.88) 0%, rgba(12, 38, 29, 0.9) 100%);
  border-color: rgba(245, 158, 11, 0.5);
}

.theme-mehndi {
  background: linear-gradient(180deg, rgba(16, 50, 36, 0.88) 0%, rgba(8, 30, 22, 0.9) 100%);
  border-color: rgba(52, 211, 153, 0.5);
}

.theme-nikah {
  background: linear-gradient(180deg, rgba(38, 30, 16, 0.92) 0%, rgba(9, 28, 22, 0.92) 100%);
  border-color: rgba(212, 175, 55, 0.65);
  box-shadow: 0 10px 30px rgba(212, 175, 55, 0.2);
}

.theme-walima {
  background: linear-gradient(180deg, rgba(15, 30, 56, 0.88) 0%, rgba(7, 24, 20, 0.92) 100%);
  border-color: rgba(96, 165, 250, 0.5);
}

.ceremony-step-tag {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--gold-primary);
  font-weight: 600;
}

.ceremony-title {
  font-family: var(--font-royal);
  font-size: 1.5rem;
  color: #ffffff;
  margin: 8px 0 10px;
}

.ceremony-datetime {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.86rem;
  color: var(--gold-light);
  font-weight: 600;
  margin-bottom: 12px;
}

.ceremony-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 18px;
}

.dress-code-badge {
  background: rgba(3, 18, 14, 0.75);
  border-left: 3px solid var(--gold-primary);
  border-radius: 4px;
  padding: 8px 12px;
  font-size: 0.78rem;
  color: var(--text-cream);
  text-align: left;
  margin-bottom: 18px;
}

.dress-code-badge strong {
  color: var(--gold-light);
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.ceremony-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: 20px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--gold-primary);
  color: var(--gold-light);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: var(--transition);
  cursor: pointer;
  width: 100%;
}

.ceremony-action-btn:hover {
  background: var(--gold-primary);
  color: var(--bg-deep);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(212, 175, 55, 0.4);
}

/* --------------------------------------------------------------------------
   16. Venue Section
   -------------------------------------------------------------------------- */
.venue-section {
  padding: 90px 20px;
  max-width: 950px;
  margin: 0 auto;
}

.venue-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 24px;
  padding: 50px 36px;
  text-align: center;
  overflow: hidden;
}

.venue-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light), var(--gold-primary), var(--gold-dark));
}

.venue-palace-title {
  font-family: var(--font-royal);
  font-size: 2.4rem;
  color: var(--gold-light);
  margin-bottom: 8px;
}

.venue-address {
  font-size: 1rem;
  color: var(--text-cream);
  max-width: 580px;
  margin: 0 auto 16px;
}

.venue-details-grid {
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
  margin: 24px 0 34px;
  border-top: 1px dashed var(--gold-border-subtle);
  border-bottom: 1px dashed var(--gold-border-subtle);
  padding: 16px 0;
}

.venue-detail-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--text-muted);
}

/* Venue Interactive Map */
.venue-map-wrapper {
  position: relative;
  width: 100%;
  height: 330px;
  border-radius: 20px;
  overflow: hidden;
  border: 1.5px solid var(--gold-border);
  box-shadow: 
    0 14px 35px rgba(0, 0, 0, 0.75),
    0 0 20px rgba(212, 175, 55, 0.15);
  margin: 28px 0 34px;
}

.venue-map-iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.venue-map-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(4, 22, 17, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--gold-primary);
  border-radius: 20px;
  padding: 6px 16px;
  font-size: 0.78rem;
  color: var(--gold-light);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  z-index: 5;
}

.venue-btn-group {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.venue-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-dark) 100%);
  color: #03140e;
  font-family: var(--font-serif);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 30px;
  box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4);
  transition: var(--transition);
}

.venue-btn-primary:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.55);
}

.venue-btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: rgba(10, 36, 28, 0.85);
  border: 1px solid var(--gold-border);
  color: var(--gold-light);
  font-size: 0.84rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 30px;
  transition: var(--transition);
  cursor: pointer;
}

.venue-btn-secondary:hover {
  border-color: var(--gold-primary);
  background: rgba(212, 175, 55, 0.15);
}

/* --------------------------------------------------------------------------
   17. Family Blessings & Kids Farmaish
   -------------------------------------------------------------------------- */
.blessings-section {
  padding: 80px 20px;
  max-width: 900px;
  margin: 0 auto;
}

.blessings-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 40px 30px;
  text-align: center;
}

.kids-callout {
  margin-top: 30px;
  padding: 24px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(136, 19, 38, 0.3) 0%, rgba(10, 38, 29, 0.6) 100%);
  border: 1px solid rgba(212, 175, 55, 0.4);
  position: relative;
}

.kids-title {
  font-family: var(--font-royal);
  font-size: 1.15rem;
  color: var(--gold-bright);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.kids-message {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  color: #ffffff;
  font-style: italic;
  margin-bottom: 8px;
}

.kids-names {
  font-size: 0.84rem;
  color: var(--gold-light);
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* --------------------------------------------------------------------------
   18. RSVP Section
   -------------------------------------------------------------------------- */
.rsvp-section {
  padding: 100px 20px;
  text-align: center;
  background: radial-gradient(circle at center, rgba(9, 51, 37, 0.75) 0%, rgba(2, 13, 10, 0.9) 100%);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-top: 1px solid var(--gold-border-subtle);
  position: relative;
  z-index: 2;
}

.rsvp-card-cta {
  max-width: 680px;
  margin: 0 auto;
  background: rgba(8, 30, 24, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-radius: 24px;
  padding: 50px 36px;
}

.rsvp-cta-btns {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 30px;
}

.rsvp-main-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 34px;
  border-radius: 30px;
  background: linear-gradient(135deg, var(--gold-primary) 0%, #aa7c11 100%);
  color: #03140e;
  font-family: var(--font-serif);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(212, 175, 55, 0.45);
  transition: var(--transition);
}

.rsvp-main-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(212, 175, 55, 0.65);
  filter: brightness(1.1);
}

.flower-shower-btn {
  padding: 13px 26px;
  border-radius: 30px;
  background: rgba(10, 36, 28, 0.85);
  border: 1px solid var(--gold-border);
  color: var(--gold-light);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.flower-shower-btn:hover {
  border-color: var(--gold-primary);
  background: rgba(212, 175, 55, 0.15);
  transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   19. RSVP Modal Dialog
   -------------------------------------------------------------------------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(1, 10, 8, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-dialog {
  background: #07221a;
  border-radius: 24px;
  width: 100%;
  max-width: 540px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 36px 30px;
  transform: scale(0.92) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .modal-dialog {
  transform: scale(1) translateY(0);
}

.modal-close-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid var(--gold-border);
  color: var(--gold-light);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.modal-close-btn:hover {
  background: var(--gold-primary);
  color: var(--bg-deep);
}

.modal-header {
  text-align: center;
  margin-bottom: 24px;
}

.modal-title {
  font-family: var(--font-royal);
  font-size: 1.8rem;
  color: var(--gold-light);
}

.form-group {
  margin-bottom: 18px;
}

.form-label {
  display: block;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--gold-light);
  margin-bottom: 6px;
  font-weight: 600;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 12px 16px;
  background: #041812;
  border: 1px solid var(--gold-border);
  border-radius: 12px;
  color: #ffffff;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: 0 0 12px var(--gold-glow);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.checkbox-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 6px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--text-cream);
  cursor: pointer;
}

.checkbox-label input {
  accent-color: var(--gold-primary);
  width: 16px;
  height: 16px;
}

.modal-submit-btn {
  width: 100%;
  padding: 14px;
  border-radius: 30px;
  background: linear-gradient(135deg, var(--gold-primary) 0%, var(--gold-dark) 100%);
  color: #020e0a;
  font-family: var(--font-serif);
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
  transition: var(--transition);
}

.modal-submit-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
}

.rsvp-success-toast {
  display: none;
  margin-top: 20px;
  padding: 16px;
  border-radius: 14px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid #10b981;
  text-align: center;
  color: #6ee7b7;
  font-size: 0.88rem;
}

.rsvp-success-toast.active {
  display: block;
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --------------------------------------------------------------------------
   20. Floating Controls (Sound & Petal Shower)
   -------------------------------------------------------------------------- */
.floating-controls {
  position: fixed;
  bottom: 28px;
  right: 28px;
  z-index: 45;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.float-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #092e22;
  border: 1.5px solid var(--gold-primary);
  color: var(--gold-light);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  transition: var(--transition);
}

.float-btn:hover {
  transform: scale(1.12);
  background: var(--gold-primary);
  color: #03140e;
  box-shadow: 0 0 20px var(--gold-glow);
}

/* --------------------------------------------------------------------------
   21. Footer
   -------------------------------------------------------------------------- */
.royal-footer {
  padding: 60px 20px 40px;
  text-align: center;
  background: #020d0a;
  border-top: 1px solid var(--gold-border-subtle);
  position: relative;
  z-index: 10;
}

.footer-filigree {
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.footer-dua {
  font-family: var(--font-arabic);
  font-size: 1.35rem;
  color: var(--gold-light);
  margin-bottom: 10px;
}

.footer-families {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.footer-credit {
  font-size: 0.74rem;
  color: var(--text-dim);
}

/* --------------------------------------------------------------------------
   22. Responsive Media Queries
   -------------------------------------------------------------------------- */
@media (max-width: 992px) {
  .couple-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  
  .couple-center-emblem {
    order: -1;
  }

  .nav-links {
    display: none;
  }
}

@media (max-width: 768px) {
  /* Hide top corner ornaments on mobile and tablet so they never collide with the sticky navbar */
  .corner-top-left,
  .corner-top-right,
  .frame-pelmet-top,
  .frame-crest-bottom {
    display: none !important;
  }

  .window-designer-frame {
    inset: 6px;
    border-radius: 8px;
    border-top: none; /* Sticky navbar provides the clean top border */
  }

  .window-designer-frame::before {
    inset: 3px;
    border-top: none;
  }
}

@media (max-width: 600px) {
  /* Mobile Sticky Navbar Header */
  .royal-navbar {
    border-bottom: 1.5px solid var(--gold-border-subtle);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.75);
    background: rgba(3, 18, 13, 0.95);
  }

  .nav-container {
    padding: 8px 12px;
    gap: 8px;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
  }

  .nav-brand {
    gap: 7px;
    flex-shrink: 0;
  }

  .nav-crest-svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
  }

  .brand-text {
    justify-content: center;
  }

  .brand-title {
    font-size: 0.96rem;
    letter-spacing: 0.8px;
    white-space: nowrap;
    line-height: 1.15;
  }

  /* Hide Arabic subtitle in header on mobile to prevent clumsy 2-line wrapping */
  .brand-sub {
    display: none !important;
  }

  .nav-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
  }

  /* Show concise 'Video' on mobile */
  .toggle-label-full {
    display: none;
  }

  .toggle-label-short {
    display: inline;
  }

  .nav-video-toggle {
    padding: 5px 10px;
    font-size: 0.68rem;
    gap: 5px;
    border-radius: 20px;
  }

  .toggle-indicator {
    width: 6px;
    height: 6px;
  }

  .nav-cta {
    padding: 5px 12px;
    font-size: 0.70rem;
    gap: 4px;
    border-radius: 20px;
  }

  .nav-video-toggle .icon-inline,
  .nav-cta .icon-inline {
    width: 13px;
    height: 13px;
  }

  .corner-ornament {
    width: 48px;
    height: 48px;
  }
  .corner-bottom-left { bottom: 6px; left: 6px; }
  .corner-bottom-right { bottom: 6px; right: 6px; }

  .floating-controls {
    bottom: 18px;
    right: 18px;
  }

  .section-heading {
    font-size: 1.85rem;
  }

  .bismillah {
    font-size: 2.1rem;
  }

  .couple-hero-title {
    font-size: 2.5rem;
  }

  .flip-card {
    width: 68px;
    height: 78px;
    border-radius: 10px;
  }

  .flip-card-upper,
  .flip-card-lower,
  .flip-card-flap-front,
  .flip-card-flap-back {
    font-size: 1.85rem;
  }

  .countdown-flip-container {
    gap: 10px;
  }

  .venue-map-wrapper {
    height: 240px;
    margin: 20px 0 24px;
  }

  .fanoos-container {
    padding: 0 10px;
  }

  .fanoos-svg {
    width: 55px;
    height: 170px;
  }

  .venue-palace-title {
    font-size: 1.8rem;
  }

  .venue-btn-group, .rsvp-cta-btns {
    flex-direction: column;
    width: 100%;
  }

  .venue-btn-primary, .venue-btn-secondary, .rsvp-main-btn, .flower-shower-btn {
    width: 100%;
    justify-content: center;
  }

  .form-row, .checkbox-group {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 360px) {
  .nav-container {
    padding: 6px 8px;
    gap: 4px;
  }

  .brand-title {
    font-size: 0.88rem;
    letter-spacing: 0.4px;
  }

  .nav-crest-svg {
    width: 17px;
    height: 17px;
  }

  .nav-video-toggle {
    padding: 4px 7px;
    font-size: 0.63rem;
    gap: 4px;
  }

  .nav-cta {
    padding: 4px 9px;
    font-size: 0.66rem;
    gap: 3px;
  }
}

/* --------------------------------------------------------------------------
   23. Reveal On Scroll (Both-Ways Scroll Appear Animation)
   -------------------------------------------------------------------------- */
.reveal-on-scroll {
  opacity: 0;
  will-change: opacity, transform;
  /* Instantaneous reset when scrolled off-screen so re-entry animation is primed immediately */
  transition: none;
}

/* Entering from below (user scrolling down) */
.reveal-on-scroll:not(.reveal-scale):not(.reveal-left):not(.reveal-right),
.reveal-on-scroll.from-below:not(.reveal-scale):not(.reveal-left):not(.reveal-right) {
  transform: translateY(38px);
}

/* Entering from above (user scrolling up) */
.reveal-on-scroll.from-above:not(.reveal-scale):not(.reveal-left):not(.reveal-right) {
  transform: translateY(-38px);
}

/* Scale variant (both directions) */
.reveal-on-scroll.reveal-scale {
  transform: scale(0.92) translateY(28px);
}

.reveal-on-scroll.reveal-scale.from-above {
  transform: scale(0.92) translateY(-28px);
}

/* Horizontal slide variants */
.reveal-on-scroll.reveal-left {
  transform: translateX(-48px);
}

.reveal-on-scroll.reveal-right {
  transform: translateX(48px);
}

/* Active In-View State: smoothly animates in when entering viewport from either direction */
.reveal-on-scroll.is-revealed {
  opacity: 1 !important;
  transform: translate(0, 0) scale(1) !important;
  transition: opacity 0.82s cubic-bezier(0.16, 1, 0.3, 1), transform 0.82s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Stagger Delays when revealed */
.reveal-on-scroll.is-revealed.stagger-1 { transition-delay: 0.08s; }
.reveal-on-scroll.is-revealed.stagger-2 { transition-delay: 0.16s; }
.reveal-on-scroll.is-revealed.stagger-3 { transition-delay: 0.24s; }
.reveal-on-scroll.is-revealed.stagger-4 { transition-delay: 0.32s; }

@media (prefers-reduced-motion: reduce) {
  .reveal-on-scroll,
  .reveal-on-scroll.from-above,
  .reveal-on-scroll.from-below,
  .reveal-on-scroll.reveal-scale,
  .reveal-on-scroll.reveal-left,
  .reveal-on-scroll.reveal-right {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}


