/* ==========================================================================
   ANAS ALI & RAJIYA MEHAJABBIN — LUXURY WEDDING INVITATION
   Design System & Stylesheet
   ========================================================================== */

/* --- CSS Variables & Design Tokens --- */
:root {
  --gold: #e2a833;
  --gold-light: #f5d47a;
  --gold-dim: #b8831a;
  --gold-glow: rgba(226, 168, 51, 0.45);
  --crimson: #9e1e30;
  --crimson-light: #c42840;
  --charcoal: #080e1a;
  --charcoal-2: #0d1424;
  --charcoal-3: #111c30;
  --charcoal-4: #1a2840;
  --door-bg: #0b1220;
  --text-light: #f5eedf;
  --text-dim: #d6c8ae;
  --text-muted: #7a8fa8;
  --ff-serif: "Cormorant Garamond", Garamond, Georgia, serif;
  --ff-sans: "Montserrat", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --ff-arabic: "Amiri", "Traditional Arabic", serif;
  --transition: 0.35s ease;
  --door-duration: 2.0s;
  --door-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* --- Reset & Global Baseline --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  background-color: var(--charcoal);
}

body {
  background: var(--charcoal);
  color: var(--text-light);
  font-family: var(--ff-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--charcoal);
}
::-webkit-scrollbar-thumb {
  background: var(--gold-dim);
  border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--gold);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: inherit;
  border: none;
  background: none;
  cursor: pointer;
}

/* ==========================================================================
   1. PREMIUM 3D CEREMONIAL DOUBLE-DOOR OPENING EXPERIENCE
   ========================================================================== */

.door-viewport {
  position: fixed;
  inset: 0;
  z-index: 9999;
  perspective: 1400px;
  perspective-origin: 50% 50%;
  overflow: hidden;
  background: transparent;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.door-viewport.opening {
  pointer-events: none;
}

.door-viewport.is-opened {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  display: none !important;
}

/* Background texture behind closed doors */
.door-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(17, 28, 48, 0.85) 0%, rgba(4, 8, 16, 0.98) 100%);
  z-index: 1;
  pointer-events: none;
  transition: opacity 1.2s cubic-bezier(0.2, 1, 0.3, 1);
}

.door-viewport.opening .door-backdrop {
  opacity: 0;
}

/* Center light burst during door parting */
.door-light-beam {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 80px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(245, 212, 122, 0.9) 0%, rgba(226, 168, 51, 0.5) 40%, rgba(226, 168, 51, 0) 80%);
  filter: blur(20px);
  opacity: 0;
  z-index: 10;
  pointer-events: none;
  transition: opacity 0.6s ease, width 1.2s ease;
}

.door-viewport.opening .door-light-beam {
  opacity: 1;
  width: 450px;
  animation: lightPulse 2s ease-out forwards;
}

@keyframes lightPulse {
  0% { opacity: 0; transform: translateX(-50%) scaleY(0.6); }
  25% { opacity: 1; transform: translateX(-50%) scaleY(1); }
  75% { opacity: 0.85; }
  100% { opacity: 0; transform: translateX(-50%) scaleY(1.1); }
}

/* Door leaf panels (Left & Right) */
.door-panel {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  height: 100%;
  z-index: 5;
  transform-style: preserve-3d;
  transition: transform var(--door-duration) var(--door-ease), box-shadow var(--door-duration) var(--door-ease);
  will-change: transform;
  overflow: hidden;
}

.door-panel-left {
  left: 0;
  transform-origin: left center;
  box-shadow: 12px 0 35px rgba(0, 0, 0, 0.85), inset -2px 0 10px rgba(226, 168, 51, 0.25);
}

.door-panel-right {
  right: 0;
  transform-origin: right center;
  box-shadow: -12px 0 35px rgba(0, 0, 0, 0.85), inset 2px 0 10px rgba(226, 168, 51, 0.25);
}

/* 3D door swinging states */
.door-viewport.opening .door-panel-left {
  transform: rotateY(-110deg);
  box-shadow: 25px 0 50px rgba(0, 0, 0, 0.95);
}

.door-viewport.opening .door-panel-right {
  transform: rotateY(110deg);
  box-shadow: -25px 0 50px rgba(0, 0, 0, 0.95);
}

/* Door surface art & texture */
.door-surface {
  position: absolute;
  inset: 0;
  background-color: var(--door-bg);
  background-image: linear-gradient(135deg, rgba(8, 14, 26, 0.92) 0%, rgba(13, 20, 36, 0.85) 50%, rgba(8, 14, 26, 0.95) 100%),
                    url('../assets/door-texture.jpg');
  background-size: cover;
  background-position: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 3rem 2rem;
}

.door-panel-left .door-surface {
  align-items: flex-end;
  border-right: 2px solid rgba(226, 168, 51, 0.55);
}

.door-panel-right .door-surface {
  align-items: flex-start;
  border-left: 2px solid rgba(226, 168, 51, 0.55);
}

/* Ornamental framing inside each door leaf */
.door-frame-border {
  position: absolute;
  inset: 1.25rem;
  border: 1px solid rgba(226, 168, 51, 0.35);
  pointer-events: none;
}

.door-frame-border::before {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(226, 168, 51, 0.18);
}

/* Corner filigree decorations for doors */
.corner-filigree {
  position: absolute;
  width: 38px;
  height: 38px;
  border-color: var(--gold);
  opacity: 0.7;
  border-style: solid;
  pointer-events: none;
}

.corner-top-left {
  top: 1.7rem;
  left: 1.7rem;
  border-width: 2px 0 0 2px;
}
.corner-top-right {
  top: 1.7rem;
  right: 1.7rem;
  border-width: 2px 2px 0 0;
}
.corner-bottom-left {
  bottom: 1.7rem;
  left: 1.7rem;
  border-width: 0 0 2px 2px;
}
.corner-bottom-right {
  bottom: 1.7rem;
  right: 1.7rem;
  border-width: 0 2px 2px 0;
}

/* Golden edge beading along the center seam */
.door-seam-trim {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, transparent, var(--gold) 20%, var(--gold-light) 50%, var(--gold) 80%, transparent);
  box-shadow: 0 0 8px var(--gold-glow);
}

.door-panel-left .door-seam-trim { right: 0; }
.door-panel-right .door-seam-trim { left: 0; }

/* Half Monogram Crest on each door */
.seal-half {
  position: absolute;
  top: 50%;
  width: 58px;
  height: 116px;
  transform: translateY(-50%);
  background: radial-gradient(circle at center, #1a2840 0%, #0d1424 70%, #080e1a 100%);
  border: 2px solid var(--gold);
  box-shadow: 0 0 24px rgba(226, 168, 51, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  z-index: 12;
}

.door-panel-left .seal-half {
  right: 0;
  border-top-left-radius: 60px;
  border-bottom-left-radius: 60px;
  border-right: none;
  padding-right: 6px;
}

.door-panel-right .seal-half {
  left: 0;
  border-top-right-radius: 60px;
  border-bottom-right-radius: 60px;
  border-left: none;
  padding-left: 6px;
}

.seal-letter {
  font-family: var(--ff-serif);
  font-size: 2.2rem;
  color: var(--gold-light);
  font-weight: 500;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}

/* ==========================================================================
   Center Invitation Presentation Layer (Hovering over the doors)
   ========================================================================== */

.door-center-envelope {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 20;
  text-align: center;
  width: 90%;
  max-width: 520px;
  padding: 2.8rem 2rem;
  background: rgba(8, 14, 26, 0.76);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(226, 168, 51, 0.45);
  border-radius: 8px;
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.85), 0 0 35px rgba(226, 168, 51, 0.15);
  transition: opacity 0.8s ease, transform 0.8s ease;
  pointer-events: auto;
}

.door-viewport.opening .door-center-envelope {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.92) translateY(-20px);
  pointer-events: none;
}

/* Bismillah Arabic Typography */
.bismillah-ar {
  font-family: var(--ff-arabic);
  color: var(--gold);
  letter-spacing: 0.04em;
  text-shadow: 0 2px 24px rgba(226, 168, 51, 0.55);
  direction: rtl;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4em;
  font-size: clamp(1.8rem, 6vw, 3rem);
  line-height: 1.45;
}

.bismillah-en {
  font-family: var(--ff-serif);
  color: var(--text-dim);
  letter-spacing: 0.03em;
  margin-top: 0.6rem;
  font-size: clamp(0.85rem, 2.4vw, 1.05rem);
  font-style: italic;
}

.intro-mark {
  font-family: var(--ff-sans);
  letter-spacing: 0.38em;
  color: var(--gold);
  text-transform: uppercase;
  margin-top: 1.8rem;
  font-size: 0.7rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
}

.intro-mark::before,
.intro-mark::after {
  content: "";
  width: 40px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-dim));
}
.intro-mark::after {
  background: linear-gradient(to left, transparent, var(--gold-dim));
}

.intro-names {
  margin: 1.5rem 0 0.8rem;
}

.hero-names {
  font-family: var(--ff-serif);
  color: var(--text-light);
  letter-spacing: -0.01em;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15em;
  font-size: clamp(3.2rem, 10vw, 5.2rem);
  font-weight: 300;
  line-height: 1.15;
}

.hero-names .name-word {
  display: block;
}

.hero-names .name-amp {
  color: var(--gold);
  font-size: 0.55em;
  font-style: italic;
  font-weight: 400;
  line-height: 1;
}

/* Open Invitation CTA Button */
.open-invite-btn {
  background: linear-gradient(135deg, var(--charcoal-3) 0%, var(--charcoal-4) 100%);
  color: var(--gold-light);
  font-family: var(--ff-sans);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(226, 168, 51, 0.55);
  border-radius: 999px;
  margin-top: 1.8rem;
  padding: 1rem 3.2rem;
  font-size: 0.82rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  box-shadow: 0 8px 32px rgba(8, 14, 26, 0.9), 0 0 20px rgba(226, 168, 51, 0.2);
  transition: all var(--transition);
}

.open-invite-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(245, 212, 122, 0.25), transparent);
  transition: left 0.75s ease;
}

.open-invite-btn:hover::before {
  left: 100%;
}

.open-invite-btn:hover {
  background: linear-gradient(135deg, var(--charcoal-4) 0%, var(--charcoal-3) 100%);
  border-color: var(--gold);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(8, 14, 26, 0.95), 0 0 30px rgba(226, 168, 51, 0.4);
}

.open-invite-btn:active {
  transform: translateY(-1px);
}

.open-invite-btn i {
  font-size: 0.95rem;
  color: var(--gold);
  transition: transform 0.3s ease;
}

.open-invite-btn:hover i {
  transform: rotate(45deg);
}

/* Subtle instruction note */
.invite-click-hint {
  font-family: var(--ff-serif);
  font-style: italic;
  color: var(--text-dim);
  font-size: 0.85rem;
  margin-top: 0.9rem;
  opacity: 0.8;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   2. MAIN WEBSITE BODY & HERO SECTION
   ========================================================================== */

.wed-root {
  background: var(--charcoal);
  position: relative;
  overflow-x: hidden;
  transition: filter 1.4s ease, transform 1.4s ease;
}

/* Initial state while doors are closed */
.wed-root.is-closed {
  filter: blur(8px);
  transform: scale(0.97);
  pointer-events: none;
}

.wed-root.is-opened {
  filter: blur(0px);
  transform: scale(1);
  pointer-events: auto;
}

/* Hero Section */
.hero {
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100dvh;
  position: relative;
  overflow: hidden;
  padding: 4rem 1.5rem;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('../assets/hero-couple.jpg');
  background-position: center 30%;
  background-repeat: no-repeat;
  background-size: cover;
  filter: brightness(0.42) saturate(0.85);
  animation: heroZoom 24s ease-in-out infinite alternate;
  transform: scale(1.05);
}

@keyframes heroZoom {
  0% { transform: scale(1.05); }
  100% { transform: scale(1.14); }
}

.hero-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, 
    rgba(8, 14, 26, 0.95) 0%, 
    rgba(8, 14, 26, 0.45) 45%, 
    rgba(8, 14, 26, 0.96) 100%
  );
}

.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 760px;
  padding: 2rem 1.5rem;
}

.hero-bismillah {
  font-family: var(--ff-arabic);
  color: var(--gold);
  text-shadow: 0 2px 20px rgba(226, 168, 51, 0.5);
  text-align: center;
  direction: rtl;
  font-size: clamp(1.8rem, 5vw, 2.5rem);
  line-height: 1.4;
  margin-bottom: 0.5rem;
}

.hero-divider {
  color: var(--gold-dim);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin: 1.2rem auto 1.6rem;
  font-size: 0.85rem;
}

.hero-divider::before,
.hero-divider::after {
  content: "";
  display: block;
  width: 90px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-dim));
}
.hero-divider::after {
  background: linear-gradient(to left, transparent, var(--gold-dim));
}

.hero-meta {
  margin-top: 2rem;
}

.hero-tag {
  color: var(--text-dim);
  letter-spacing: 0.05em;
  max-width: 440px;
  margin: 0 auto 1.2rem;
  font-size: clamp(0.85rem, 2.2vw, 1.05rem);
  font-family: var(--ff-serif);
  font-style: italic;
  line-height: 1.7;
}

.hero-date {
  font-family: var(--ff-sans);
  letter-spacing: 0.25em;
  color: var(--gold);
  text-transform: uppercase;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  font-size: clamp(0.78rem, 2.2vw, 0.92rem);
  font-weight: 500;
}

.hero-date .dot {
  color: var(--gold-dim);
}

.scroll-indicator {
  position: absolute;
  bottom: 2.2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  color: var(--gold-dim);
  transition: color var(--transition);
  animation: bounce 2.4s ease-in-out infinite;
}

.scroll-indicator:hover {
  color: var(--gold);
}

.scroll-indicator-text {
  font-family: var(--ff-sans);
  font-size: 0.62rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
}

.chev {
  display: block;
  width: 18px;
  height: 18px;
  border-right: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  opacity: 0.8;
  transform: rotate(45deg);
}

@keyframes bounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 9px); }
}

/* ==========================================================================
   3. SHARED SECTION STYLING & DIVIDERS
   ========================================================================== */

.section {
  max-width: 860px;
  margin: 0 auto;
  padding: 6rem 1.5rem;
  position: relative;
}

.section-full {
  max-width: 100%;
}

.section-title {
  font-family: var(--ff-serif);
  color: var(--text-light);
  text-align: center;
  letter-spacing: -0.01em;
  font-size: clamp(2.2rem, 5.5vw, 3.2rem);
  font-weight: 400;
}

.section-sub {
  text-align: center;
  letter-spacing: 0.3em;
  color: var(--gold-dim);
  text-transform: uppercase;
  margin-top: 0.6rem;
  margin-bottom: 3.2rem;
  font-size: 0.72rem;
  font-weight: 500;
}

.line-divider {
  color: var(--gold-dim);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin: 1.8rem 0;
  font-size: 0.8rem;
}

.line-divider::before,
.line-divider::after {
  content: "";
  flex: 1;
  max-width: 120px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-dim));
}
.line-divider::after {
  background: linear-gradient(to left, transparent, var(--gold-dim));
}

.line-divider.small::before,
.line-divider.small::after {
  max-width: 60px;
}

/* ==========================================================================
   4. QURANIC VERSE / BLESSING SECTION
   ========================================================================== */

.verse-section {
  background: var(--charcoal-2);
  padding: 6rem 1.5rem;
  border-top: 1px solid rgba(226, 168, 51, 0.15);
  border-bottom: 1px solid rgba(226, 168, 51, 0.15);
}

.verse-card {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
  padding: 2.5rem 2rem;
  background: linear-gradient(160deg, rgba(17, 28, 48, 0.5) 0%, rgba(26, 40, 64, 0.3) 100%);
  border: 1px solid rgba(226, 168, 51, 0.25);
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(8, 14, 26, 0.7);
  position: relative;
}

.verse-text {
  font-family: var(--ff-serif);
  color: var(--text-light);
  letter-spacing: 0.01em;
  font-size: clamp(1.25rem, 3.2vw, 1.7rem);
  font-style: italic;
  font-weight: 300;
  line-height: 1.7;
}

.verse-ref {
  color: var(--gold);
  letter-spacing: 0.12em;
  margin-top: 1.2rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  font-weight: 500;
}

/* ==========================================================================
   5. THE COUPLE SECTION
   ========================================================================== */

.couple-section {
  background: var(--charcoal);
  padding: 6rem 1.5rem;
}

.couple-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 720px;
  margin: 0 auto;
}

@media (min-width: 680px) {
  .couple-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

.couple-card {
  background: linear-gradient(160deg, var(--charcoal-3) 0%, rgba(26, 40, 64, 0.95) 100%);
  text-align: center;
  border: 1px solid rgba(226, 168, 51, 0.3);
  border-radius: 8px;
  padding: 3rem 2rem;
  box-shadow: 0 10px 45px rgba(8, 14, 26, 0.8);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.couple-card:hover {
  border-color: rgba(226, 168, 51, 0.65);
  transform: translateY(-4px);
  box-shadow: 0 14px 50px rgba(8, 14, 26, 0.95), 0 0 20px rgba(226, 168, 51, 0.15);
}

.couple-card-top-ornament {
  font-size: 1.2rem;
  color: var(--gold-dim);
  margin-bottom: 0.8rem;
}

.couple-role {
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 600;
  display: block;
}

.couple-person-name {
  font-family: var(--ff-serif);
  color: var(--text-light);
  letter-spacing: -0.01em;
  margin-top: 0.8rem;
  font-size: clamp(2.4rem, 6vw, 3rem);
  font-weight: 400;
  line-height: 1.2;
}

.mini-divider {
  background: var(--gold-dim);
  opacity: 0.6;
  width: 45px;
  height: 1px;
  margin: 1.2rem auto;
}

.couple-honorific {
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-size: 0.68rem;
  margin-top: 0.4rem;
}

.couple-tagline {
  font-family: var(--ff-serif);
  color: var(--text-dim);
  margin-top: 0.6rem;
  font-size: 1.05rem;
  font-style: italic;
}

/* ==========================================================================
   6. COUPLE SPOTLIGHT PHOTO
   ========================================================================== */

.spotlight-section {
  background: var(--charcoal-2);
  padding: 5rem 1.5rem;
  border-top: 1px solid rgba(226, 168, 51, 0.12);
  border-bottom: 1px solid rgba(226, 168, 51, 0.12);
}

.spotlight-frame {
  max-width: 520px;
  margin: 0 auto;
  border: 1px solid rgba(226, 168, 51, 0.45);
  border-radius: 6px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 60px rgba(8, 14, 26, 0.9), 0 0 0 1px rgba(226, 168, 51, 0.2);
}

.spotlight-frame img {
  width: 100%;
  height: auto;
  object-fit: cover;
  transition: transform 0.9s cubic-bezier(0.2, 1, 0.3, 1);
}

.spotlight-frame:hover img {
  transform: scale(1.04);
}

.spotlight-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(8, 14, 26, 0.95) 0%, rgba(8, 14, 26, 0.5) 70%, transparent 100%);
  padding: 2.5rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.spotlight-title {
  font-family: var(--ff-serif);
  color: var(--text-light);
  letter-spacing: 0.04em;
  font-size: 1.6rem;
}

.spotlight-date {
  letter-spacing: 0.3em;
  color: var(--gold);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 600;
}

/* ==========================================================================
   7. LIVE COUNTDOWN TIMER
   ========================================================================== */

.countdown-section {
  background: var(--charcoal);
  padding: 6rem 1.5rem;
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.2rem;
  max-width: 620px;
  margin: 0 auto;
}

@media (max-width: 520px) {
  .countdown-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
}

.cd-box {
  background: linear-gradient(160deg, var(--charcoal-3) 0%, var(--charcoal-4) 100%);
  text-align: center;
  border: 1px solid rgba(226, 168, 51, 0.35);
  border-radius: 6px;
  padding: 1.6rem 0.8rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 6px 25px rgba(8, 14, 26, 0.75);
}

.cd-box::before,
.cd-box::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  border-color: var(--gold-dim);
  border-style: solid;
  opacity: 0.7;
}

.cd-box::before {
  top: 6px;
  left: 6px;
  border-width: 1px 0 0 1px;
}

.cd-box::after {
  bottom: 6px;
  right: 6px;
  border-width: 0 1px 1px 0;
}

.cd-num {
  font-family: var(--ff-serif);
  color: var(--gold);
  letter-spacing: -0.02em;
  font-size: clamp(2.4rem, 8vw, 3.4rem);
  font-weight: 300;
  line-height: 1;
  display: block;
}

.cd-lbl {
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.6rem;
  font-size: 0.65rem;
  font-weight: 600;
  display: block;
}

/* ==========================================================================
   8. THE CELEBRATION & VENUE SECTION
   ========================================================================== */

.event-section {
  background: var(--charcoal-2);
  padding: 6rem 1.5rem;
  border-top: 1px solid rgba(226, 168, 51, 0.15);
  border-bottom: 1px solid rgba(226, 168, 51, 0.15);
}

.event-card {
  background: linear-gradient(160deg, var(--charcoal-3) 0%, rgba(26, 40, 64, 0.95) 100%);
  text-align: center;
  border: 1px solid rgba(226, 168, 51, 0.35);
  border-radius: 8px;
  max-width: 580px;
  margin: 0 auto;
  padding: 3.5rem 2.2rem;
  box-shadow: 0 12px 55px rgba(8, 14, 26, 0.85);
  position: relative;
}

.event-badge {
  color: var(--gold);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  background: rgba(17, 28, 48, 0.85);
  border: 1px solid rgba(226, 168, 51, 0.55);
  border-radius: 3px;
  padding: 0.4rem 1.2rem;
  font-size: 0.68rem;
  font-weight: 600;
  display: inline-block;
}

.event-title {
  font-family: var(--ff-serif);
  color: var(--text-light);
  margin-top: 1.2rem;
  font-size: clamp(1.8rem, 4.5vw, 2.3rem);
  font-weight: 400;
}

.event-rows {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  text-align: left;
}

.event-row {
  display: flex;
  align-items: flex-start;
  gap: 1.2rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid rgba(226, 168, 51, 0.12);
}

.event-row:last-child {
  border-bottom: none;
}

.event-row > i {
  color: var(--gold);
  background: rgba(17, 28, 48, 0.9);
  border: 1px solid rgba(226, 168, 51, 0.28);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.05rem;
  margin-top: 0.2rem;
}

.event-row > div {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.event-row span {
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-size: 0.62rem;
  font-weight: 600;
}

.event-row strong {
  font-family: var(--ff-serif);
  color: var(--text-light);
  font-size: 1.15rem;
  font-weight: 400;
  line-height: 1.4;
}

.event-actions {
  margin-top: 2.5rem;
  display: flex;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
}

.btn {
  font-family: var(--ff-sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all var(--transition);
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.9rem 2rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-decoration: none;
}

.btn-gold {
  background: linear-gradient(135deg, var(--charcoal-3) 0%, var(--charcoal-4) 100%);
  color: var(--gold-light);
  border: 1px solid rgba(226, 168, 51, 0.55);
  box-shadow: 0 6px 24px rgba(8, 14, 26, 0.8);
}

.btn-gold:hover {
  background: linear-gradient(135deg, var(--charcoal-4) 0%, var(--charcoal-3) 100%);
  border-color: var(--gold);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(8, 14, 26, 0.95), 0 0 20px rgba(226, 168, 51, 0.3);
}

/* ==========================================================================
   9. INTERACTIVE RSVP / ATTENDANCE SECTION
   ========================================================================== */

.attend-section {
  background: var(--charcoal);
  text-align: center;
  padding: 6rem 1.5rem;
  position: relative;
  overflow: hidden;
}

.attend-label {
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.8rem;
  font-size: 0.7rem;
  font-weight: 600;
}

.attend-title {
  font-family: var(--ff-serif);
  color: var(--text-light);
  letter-spacing: -0.01em;
  margin-bottom: 0.6rem;
  font-size: clamp(2.2rem, 6vw, 3.4rem);
  font-weight: 400;
}

.attend-subtitle {
  font-family: var(--ff-serif);
  color: var(--gold-light);
  letter-spacing: 0.02em;
  margin-bottom: 0.4rem;
  font-size: clamp(1.05rem, 2.6vw, 1.25rem);
  font-style: italic;
}

.attend-divider {
  color: var(--gold-dim);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin: 1.2rem auto 2.8rem;
  font-size: 0.8rem;
}

.attend-divider::before,
.attend-divider::after {
  content: "";
  flex: 1;
  max-width: 100px;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--gold-dim));
}
.attend-divider::after {
  background: linear-gradient(to left, transparent, var(--gold-dim));
}

.attend-options {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  max-width: 440px;
  margin: 0 auto;
}

.attend-opt {
  background: linear-gradient(135deg, var(--charcoal-3) 0%, rgba(17, 28, 48, 0.95) 100%);
  width: 100%;
  color: var(--text-dim);
  font-family: var(--ff-serif);
  cursor: pointer;
  text-align: left;
  border: 1px solid rgba(226, 168, 51, 0.3);
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1.15rem 1.8rem;
  font-size: clamp(1.05rem, 2.6vw, 1.2rem);
  font-style: italic;
  transition: all 0.3s ease;
  position: relative;
}

.attend-opt:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--charcoal-4) 0%, rgba(26, 40, 64, 0.98) 100%);
  color: var(--text-light);
  border-color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(8, 14, 26, 0.85);
}

.attend-opt:disabled {
  cursor: default;
  opacity: 0.75;
}

.attend-opt-icon {
  width: 32px;
  height: 32px;
  border: 1.5px solid rgba(226, 168, 51, 0.45);
  border-radius: 50%;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  font-size: 0.95rem;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.attend-yes.is-selected {
  background: linear-gradient(135deg, rgba(17, 28, 48, 0.98) 0%, var(--charcoal-4) 100%);
  border-color: var(--gold);
  color: var(--gold-light);
  box-shadow: 0 6px 30px rgba(226, 168, 51, 0.25);
}

.attend-yes.is-selected .attend-opt-icon {
  border-color: var(--gold);
  background: rgba(226, 168, 51, 0.25);
  color: var(--gold);
}

.attend-no.is-selected {
  background: linear-gradient(135deg, rgba(17, 28, 48, 0.98) 0%, var(--charcoal-4) 100%);
  border-color: rgba(158, 30, 48, 0.7);
  color: var(--text-dim);
  box-shadow: 0 6px 30px rgba(158, 30, 48, 0.2);
}

.attend-no.is-selected .attend-opt-icon {
  border-color: var(--crimson-light);
  background: rgba(158, 30, 48, 0.25);
  color: var(--crimson-light);
}

/* Responses */
.attend-feedback {
  text-align: center;
  max-width: 440px;
  margin: 2.5rem auto 0;
  padding: 1.5rem 1.8rem;
  background: rgba(17, 28, 48, 0.6);
  border: 1px solid rgba(226, 168, 51, 0.35);
  border-radius: 8px;
  animation: feedbackIn 0.6s cubic-bezier(0.2, 1, 0.3, 1) forwards;
}

@keyframes feedbackIn {
  0% { opacity: 0; transform: translateY(20px) scale(0.96); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.feedback-emoji {
  font-size: 2.4rem;
  display: block;
  margin-bottom: 0.6rem;
}

.feedback-text-yes {
  font-family: var(--ff-serif);
  color: var(--gold-light);
  font-size: clamp(1.15rem, 3vw, 1.4rem);
  line-height: 1.55;
}

.feedback-text-no {
  font-family: var(--ff-serif);
  color: var(--text-dim);
  font-size: clamp(1.05rem, 2.5vw, 1.2rem);
  font-style: italic;
  line-height: 1.6;
}

/* Confetti container for RSVP */
.confetti-root {
  position: absolute;
  top: 60%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 25;
}

.confetti-dot {
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transform-origin: 50% 50%;
}

@keyframes confetti-burst {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(1) rotate(0deg);
  }
  60% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(var(--tx), var(--ty)) scale(0.2) rotate(720deg);
  }
}

/* ==========================================================================
   10. MOMENTS PHOTO GALLERY
   ========================================================================== */

.gallery-section {
  background: var(--charcoal-2);
  padding: 6rem 1.5rem;
  border-top: 1px solid rgba(226, 168, 51, 0.15);
}

.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 1.2rem;
  max-width: 680px;
  margin: 0 auto;
}

@media (max-width: 540px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}

.gal-frame {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  border: 1px solid rgba(226, 168, 51, 0.3);
  box-shadow: 0 6px 25px rgba(8, 14, 26, 0.7);
  margin: 0;
  cursor: zoom-in;
}

.gal-frame.tall {
  grid-row: span 2;
}

.gal-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.2, 1, 0.3, 1);
  display: block;
}

.gal-frame:hover img {
  transform: scale(1.06);
}

.gal-hover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 14, 26, 0.85) 0%, rgba(226, 168, 51, 0.08) 100%);
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1.2rem;
}

.gal-frame:hover .gal-hover-overlay {
  opacity: 1;
}

.gal-hover-caption {
  font-family: var(--ff-serif);
  font-style: italic;
  color: var(--gold-light);
  font-size: 0.95rem;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   11. FOOTER SECTION
   ========================================================================== */

.wed-footer {
  background: var(--charcoal);
  text-align: center;
  border-top: 1px solid rgba(226, 168, 51, 0.2);
  padding: 5rem 1.5rem 3rem;
  position: relative;
}

.footer-thanks {
  font-family: var(--ff-serif);
  color: var(--text-light);
  margin-top: 1.6rem;
  font-size: clamp(2.2rem, 5.5vw, 3rem);
  font-weight: 300;
}

.footer-msg {
  color: var(--text-dim);
  max-width: 440px;
  margin: 1.2rem auto;
  font-size: 0.95rem;
  line-height: 1.8;
  font-family: var(--ff-serif);
  font-style: italic;
}

.footer-couple {
  font-family: var(--ff-serif);
  color: var(--gold);
  margin-top: 1.6rem;
  font-size: 1.5rem;
  letter-spacing: 0.05em;
}

.footer-meta {
  letter-spacing: 0.22em;
  color: var(--text-muted);
  text-transform: uppercase;
  border-top: 1px solid rgba(226, 168, 51, 0.12);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin-top: 2.8rem;
  padding-top: 2.2rem;
  font-size: 0.7rem;
}

.footer-meta .dot {
  color: var(--gold-dim);
}

/* ==========================================================================
   12. FLOATING AUDIO FAB & PETAL CANVAS
   ========================================================================== */

.audio-fab {
  position: fixed;
  bottom: 1.8rem;
  right: 1.8rem;
  z-index: 990;
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--charcoal-3) 0%, var(--charcoal-4) 100%);
  color: var(--gold);
  border: 1px solid rgba(226, 168, 51, 0.45);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.15rem;
  cursor: pointer;
  box-shadow: 0 6px 24px rgba(8, 14, 26, 0.85);
  transition: all var(--transition);
}

.audio-fab:hover {
  background: linear-gradient(135deg, var(--charcoal-4) 0%, var(--charcoal-3) 100%);
  border-color: var(--gold);
  transform: scale(1.08);
  box-shadow: 0 8px 30px rgba(8, 14, 26, 0.95), 0 0 20px rgba(226, 168, 51, 0.35);
}

.audio-fab.playing {
  animation: pulse-fab 2.4s ease-in-out infinite;
}

@keyframes pulse-fab {
  0%, 100% {
    box-shadow: 0 6px 24px rgba(8, 14, 26, 0.85);
  }
  50% {
    box-shadow: 0 6px 36px rgba(226, 168, 51, 0.45), 0 0 0 5px rgba(226, 168, 51, 0.15);
  }
}

/* Floating background stars */
.floating-shapes {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.shape {
  position: absolute;
  color: var(--gold);
  opacity: 0;
  font-size: 0.9rem;
  animation: floatUp 14s ease-in-out infinite;
}

.s1 { top: 18%; left: 8%; font-size: 0.7rem; opacity: 0.35; animation-delay: 0s; animation-duration: 16s; }
.s2 { top: 25%; left: 85%; font-size: 0.85rem; opacity: 0.25; animation-delay: 3s; animation-duration: 13s; }
.s3 { top: 65%; left: 52%; font-size: 0.65rem; opacity: 0.3; animation-delay: 6s; animation-duration: 18s; }
.s4 { top: 75%; left: 18%; font-size: 0.8rem; opacity: 0.2; animation-delay: 2s; animation-duration: 14s; }
.s5 { top: 52%; left: 92%; font-size: 0.7rem; opacity: 0.28; animation-delay: 8s; animation-duration: 15s; }

@keyframes floatUp {
  0% { opacity: 0; transform: translateY(0) rotate(0deg); }
  20% { opacity: 0.4; }
  80% { opacity: 0.3; }
  100% { opacity: 0; transform: translateY(-70px) rotate(25deg); }
}

/* Reveal animations for GSAP / Fallback */
[data-reveal="true"],
[data-stagger-item="true"] {
  will-change: transform, opacity;
}

/* ==========================================================================
   13. COMPREHENSIVE RESPONSIVE ENHANCEMENTS (Mobile & Tablet)
   ========================================================================== */

@media (max-width: 768px) {
  .section {
    padding: 4.5rem 1.25rem;
  }
  
  .door-center-envelope {
    padding: 2.4rem 1.5rem;
    width: 92%;
  }

  .event-card {
    padding: 2.5rem 1.5rem;
  }

  .verse-section {
    padding: 4.5rem 1.25rem;
  }
}

@media (max-width: 480px) {
  .door-viewport {
    perspective: 1000px;
  }

  .door-center-envelope {
    padding: 1.8rem 1rem;
    width: 92%;
    border-radius: 6px;
    left: 50%;
    transform: translate(-50%, -50%);
  }

  .bismillah-ar {
    font-size: 1.7rem;
    gap: 0.25em;
  }

  .bismillah-en {
    font-size: 0.82rem;
    margin-top: 0.4rem;
  }

  .intro-mark {
    margin-top: 1.2rem;
    font-size: 0.65rem;
    letter-spacing: 0.25em;
  }

  .intro-names {
    margin: 1rem 0 0.6rem;
  }

  .hero-names.intro-names {
    font-size: clamp(1.9rem, 7.5vw, 2.6rem);
  }

  .hero-names {
    font-size: clamp(2.2rem, 8.5vw, 3.2rem);
  }

  .open-invite-btn {
    padding: 0.85rem 2rem;
    font-size: 0.75rem;
    letter-spacing: 0.18em;
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }

  .seal-half {
    width: 42px;
    height: 84px;
  }

  .seal-letter {
    font-size: 1.6rem;
  }

  .hero {
    padding: 3.5rem 1rem;
  }

  .hero-inner {
    padding: 1rem 0.5rem;
  }

  .hero-bismillah {
    font-size: 1.5rem;
  }

  .hero-names {
    font-size: 2.7rem;
  }

  .hero-tag {
    font-size: 0.85rem;
    margin-bottom: 0.8rem;
  }

  .hero-date {
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    flex-wrap: wrap;
  }

  .verse-card {
    padding: 2rem 1.2rem;
  }

  .verse-text {
    font-size: 1.18rem;
  }

  .couple-card {
    padding: 2.2rem 1.4rem;
  }

  .couple-person-name {
    font-size: 2.2rem;
  }

  .event-card {
    padding: 2rem 1.2rem;
  }

  .event-title {
    font-size: 1.6rem;
  }

  .event-row {
    gap: 0.8rem;
  }

  .event-row strong {
    font-size: 1.02rem;
  }

  .btn {
    width: 100%;
    justify-content: center;
    padding: 0.85rem 1.4rem;
  }

  .attend-opt {
    padding: 1rem 1.2rem;
    font-size: 1rem;
  }

  .audio-fab {
    bottom: 1.2rem;
    right: 1.2rem;
    width: 46px;
    height: 46px;
    font-size: 1rem;
  }
}

