:root {
  --black: #100608;
  --black-2: #1a0b0e;
  --wine: #5f1018;
  --wine-2: #8b2028;
  --wine-3: #b44842;
  --ivory: #fff8ec;
  --ivory-soft: #f5ead8;
  --champagne: #e7d2a0;
  --gold: #c79c52;
  --gold-bright: #f3d98d;
  --bronze: #8d5f30;
  --ink: #442419;
  --shadow: rgba(0, 0, 0, .42);
  --glass: rgba(255, 248, 236, .08);
  --border: rgba(243, 217, 141, .38);
  --max: 520px;
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  /* Stop iOS/Android from inflating our type in landscape. */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  color: var(--ivory);
  /* Kill the grey flash Android paints over every tap target. */
  -webkit-tap-highlight-color: transparent;
  background:
    radial-gradient(circle at 50% -8%, rgba(199,156,82,.24), transparent 26rem),
    radial-gradient(circle at 10% 18%, rgba(139,32,40,.28), transparent 18rem),
    radial-gradient(circle at 90% 76%, rgba(199,156,82,.16), transparent 16rem),
    linear-gradient(180deg, #080405 0%, #130709 42%, #220c10 100%);
  font-family: Cairo, Tahoma, Arial, sans-serif;
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

body::before {
  opacity: .25;
  background-image:
    linear-gradient(120deg, transparent 0 45%, rgba(243,217,141,.12) 45.2%, transparent 45.8% 100%),
    linear-gradient(60deg, transparent 0 45%, rgba(243,217,141,.09) 45.2%, transparent 45.8% 100%);
  background-size: 210px 210px, 210px 210px;
}

body::after {
  opacity: .13;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.7) 0 1px, transparent 1.6px),
    radial-gradient(circle at 80% 30%, rgba(243,217,141,.9) 0 1px, transparent 1.8px),
    radial-gradient(circle at 40% 84%, rgba(255,255,255,.58) 0 1px, transparent 1.7px);
  background-size: 110px 140px, 160px 180px, 190px 210px;
  animation: starDrift 18s linear infinite;
}

.gold-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .28;
  background-image:
    radial-gradient(circle at 22% 18%, rgba(243,217,141,.16) 0 1px, transparent 1.4px),
    radial-gradient(circle at 72% 64%, rgba(255,248,236,.12) 0 1px, transparent 1.5px);
  background-size: 28px 32px, 34px 41px;
  mix-blend-mode: screen;
}

.spark-field {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}
.spark-field i {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 999px;
  background: var(--gold-bright);
  box-shadow: 0 0 18px rgba(243,217,141,.75);
  animation: floatSpark linear infinite;
  opacity: .65;
}

@keyframes starDrift { to { background-position: 110px 140px, -160px 180px, 190px -210px; } }
@keyframes floatSpark {
  0% { transform: translate3d(0, 20px, 0) scale(.7); opacity: 0; }
  12% { opacity: .85; }
  100% { transform: translate3d(var(--x, 18px), -96vh, 0) scale(1.1); opacity: 0; }
}

.experience {
  position: relative;
  z-index: 2;
  width: min(100%, var(--max));
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 50% 4%, rgba(243,217,141,.16), transparent 16rem),
    linear-gradient(180deg, rgba(30,9,12,.94) 0%, rgba(14,6,7,.98) 46%, rgba(24,9,11,.96) 100%);
  box-shadow: 0 0 80px rgba(0,0,0,.62);
  overflow: hidden;
  border-inline: 1px solid rgba(243,217,141,.12);
}

.no-cover { background: transparent; }

.audio-button {
  position: fixed;
  z-index: 80;
  /* Clear the notch / status bar on iPhone and cut-out Androids. */
  top: calc(18px + env(safe-area-inset-top, 0px));
  left: max(calc(16px + env(safe-area-inset-left, 0px)), calc(50vw - 242px));
  width: 46px;
  height: 46px;
  /* Keeps the tap target at the 48px minimum without growing the visible circle. */
  outline-offset: 2px;
  touch-action: manipulation;
  display: grid;
  place-items: center;
  border: 1px solid rgba(243,217,141,.45);
  border-radius: 999px;
  color: var(--gold-bright);
  background: rgba(16,6,8,.62);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 34px rgba(0,0,0,.36), inset 0 0 18px rgba(243,217,141,.08);
  cursor: pointer;
  transition: .3s ease;
}
.audio-button:hover { transform: translateY(-2px); border-color: rgba(243,217,141,.75); }
.audio-button.playing {
  color: #18080a;
  background: linear-gradient(135deg, var(--gold), var(--gold-bright));
  box-shadow: 0 0 0 6px rgba(243,217,141,.08), 0 16px 36px rgba(0,0,0,.45);
}
.audio-icon { font-size: 24px; line-height: 1; transform: translateY(-1px); }

.gate-screen {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  align-items: center;
  justify-items: center;
  padding: 40px 22px 30px;
  position: relative;
  isolation: isolate;
  transition: opacity .86s ease, transform 1s cubic-bezier(.7,0,.2,1), filter .7s ease;
}

/* thin double gold frame around the cover */
.gate-frame {
  position: absolute;
  inset: 14px;
  z-index: -1;
  pointer-events: none;
  border: 1px solid rgba(243,217,141,.26);
  border-radius: 30px;
  box-shadow: inset 0 0 60px rgba(0,0,0,.35);
  animation: frameIn 1.4s .1s both;
}
.gate-frame::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid rgba(243,217,141,.11);
  border-radius: 24px;
}
.gate-frame i {
  position: absolute;
  left: 50%;
  width: 9px;
  height: 9px;
  transform: translate(-50%, -50%) rotate(45deg);
  background: linear-gradient(135deg, var(--gold-bright), var(--bronze));
  box-shadow: 0 0 14px rgba(243,217,141,.5);
}
.gate-frame i:first-child { top: 0; }
.gate-frame i:last-child { top: 100%; }

body.cover-open .gate-screen {
  opacity: 0;
  transform: translateY(-36px) scale(1.05);
  filter: blur(18px);
  pointer-events: none;
  position: absolute;
  inset: 0;
}

.gate-glow {
  position: absolute;
  width: min(92vw, 430px);
  aspect-ratio: 1;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(243,217,141,.20), rgba(139,32,40,.08) 48%, transparent 68%);
  filter: blur(8px);
  z-index: -1;
  animation: glowBreath 7s ease-in-out infinite;
}

.gate-copy {
  text-align: center;
  align-self: end;
  padding-bottom: 8px;
}
.copy-rule {
  display: block;
  width: 130px;
  height: 1px;
  margin: 12px auto 14px;
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.6), transparent);
  position: relative;
  animation: riseIn 1s .5s both;
}
.copy-rule::before {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 6px;
  height: 6px;
  transform: translate(-50%, -50%) rotate(45deg);
  background: var(--gold-bright);
  box-shadow: 0 0 10px rgba(243,217,141,.7);
}
.gate-copy .tiny-caps { animation: riseIn 1s .2s both; }
.gate-copy h1 { animation: riseIn 1.1s .34s both; }
.gate-copy .bismillah { animation: riseIn 1s .62s both; }
.tiny-caps {
  margin: 0;
  color: rgba(243,217,141,.88);
  font: 700 10px/1.4 Cairo, sans-serif;
  letter-spacing: .32em;
  text-transform: uppercase;
}
.gate-copy h1 {
  margin: 10px 0 6px;
  color: var(--ivory);
  font-family: Aref Ruqaa, Amiri, serif;
  font-size: clamp(40px, 11vw, 70px);
  font-weight: 700;
  text-shadow: 0 10px 36px rgba(0,0,0,.48);
}
.bismillah {
  margin: 0;
  color: rgba(255,248,236,.68);
  font-family: Aref Ruqaa, Amiri, serif;
  font-size: 20px;
}

.royal-gate {
  position: relative;
  width: min(80vw, 352px);
  height: clamp(320px, 52dvh, 470px);
  margin: 10px 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  perspective: 1200px;
  filter: drop-shadow(0 34px 44px rgba(0,0,0,.48));
  animation: gateIn 1.3s .74s backwards;
  transition: transform .5s ease;
}
.royal-gate:hover { transform: translateY(-4px); }
.royal-gate:focus-visible { outline: 2px solid rgba(243,217,141,.7); outline-offset: 12px; border-radius: 190px 190px 28px 28px; }
.royal-gate::before {
  content: "";
  position: absolute;
  inset: -14px;
  border-radius: 190px 190px 28px 28px;
  background:
    linear-gradient(135deg, transparent 8%, rgba(243,217,141,.7), transparent 22% 78%, rgba(243,217,141,.62), transparent 92%),
    linear-gradient(180deg, rgba(243,217,141,.44), rgba(141,95,48,.12));
  padding: 1px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}
.gate-panel {
  position: absolute;
  top: 15%;
  bottom: 0;
  width: 50%;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 12%, rgba(243,217,141,.16), transparent 22%),
    radial-gradient(circle at 50% 46%, rgba(243,217,141,.09) 0 2px, transparent 3px),
    radial-gradient(circle at 20% 30%, rgba(243,217,141,.07) 0 1.5px, transparent 2.5px),
    radial-gradient(circle at 80% 66%, rgba(243,217,141,.07) 0 1.5px, transparent 2.5px),
    linear-gradient(90deg, rgba(255,255,255,.05), transparent 14% 86%, rgba(0,0,0,.24)),
    repeating-linear-gradient(90deg, rgba(255,255,255,.05) 0 1px, transparent 1px 16px),
    linear-gradient(180deg, #721722, #2b0b10 68%, #15070a);
  background-size: auto, 54px 54px, 54px 54px, 54px 54px, auto, auto, auto;
  border: 1px solid rgba(243,217,141,.34);
  transition: transform 1.08s cubic-bezier(.7,.02,.2,1), filter .8s ease;
}
.gate-left {
  right: 50%;
  border-radius: 190px 0 0 24px;
  transform-origin: left center;
}
.gate-right {
  left: 50%;
  border-radius: 0 190px 24px 0;
  transform-origin: right center;
}
.gate-panel::before,
.gate-panel::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(243,217,141,.35);
  inset: 28px 18px 34px;
  border-radius: 140px 140px 18px 18px;
}
.gate-panel::after {
  inset: 60px 40px 72px;
  border-color: rgba(243,217,141,.18);
  box-shadow: inset 0 0 22px rgba(0,0,0,.22);
}
.gate-beam {
  position: absolute;
  top: 15%;
  bottom: 0;
  left: 50%;
  width: 3px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: linear-gradient(180deg, transparent, rgba(243,217,141,.85) 30% 70%, transparent);
  filter: blur(1.5px);
  opacity: .45;
  animation: seamGlow 4.2s ease-in-out infinite;
  transition: width 1.1s ease, opacity 1.1s ease, filter 1.1s ease;
  pointer-events: none;
}
body.cover-open .gate-beam {
  width: 150px;
  opacity: .95;
  filter: blur(30px);
  animation: none;
}
.gate-arch {
  position: absolute;
  inset: 0 2px;
  border-radius: 210px 210px 28px 28px;
  border: 2px solid rgba(243,217,141,.56);
  box-shadow: inset 0 0 0 7px rgba(199,156,82,.06), 0 0 44px rgba(199,156,82,.08);
  overflow: hidden;
}
.gate-arch::after {
  content: "";
  position: absolute;
  top: -30%;
  left: -60%;
  width: 45%;
  height: 160%;
  background: linear-gradient(100deg, transparent, rgba(255,248,236,.16), transparent);
  transform: rotate(8deg);
  animation: archSheen 6.5s ease-in-out 2.2s infinite;
}
.gate-lines {
  position: absolute;
  inset: 12% 8% 7%;
  border-radius: 180px 180px 16px 16px;
  border: 1px solid rgba(255,248,236,.16);
  box-shadow: inset 0 0 50px rgba(0,0,0,.35);
}
.seal-orb {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 128px;
  height: 128px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 28% 24%, rgba(255,255,255,.26), transparent 18%),
    radial-gradient(circle at 50% 50%, #7c1d25, #3f1014 68%, #1d0709);
  border: 1px solid rgba(243,217,141,.68);
  color: var(--gold-bright);
  box-shadow: 0 16px 44px rgba(0,0,0,.5), inset 0 0 0 8px rgba(0,0,0,.12), inset 0 0 0 10px rgba(243,217,141,.12);
  transition: transform .5s ease, opacity .5s ease;
  z-index: 2;
}
/* polished gold rim that slowly rotates its highlight */
.seal-orb::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  padding: 1.5px;
  background: conic-gradient(from 0deg, rgba(243,217,141,.95), rgba(141,95,48,.18) 22%, rgba(243,217,141,.9) 48%, rgba(141,95,48,.18) 72%, rgba(243,217,141,.95));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: spinSlow 14s linear infinite;
}
.seal-ring {
  position: absolute;
  inset: -17px;
  border-radius: 50%;
  border: 1px dashed rgba(243,217,141,.42);
  animation: spinSlow 34s linear infinite reverse;
}
.seal-pulse {
  position: absolute;
  inset: 0;
  margin: auto;
  width: var(--seal-size, 128px);
  height: var(--seal-size, 128px);
  pointer-events: none;
}
.seal-pulse::before,
.seal-pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(243,217,141,.55);
  animation: sealPulse 3.4s ease-out infinite;
}
.seal-pulse::after { animation-delay: 1.7s; }
body.cover-open .seal-pulse { opacity: 0; transition: opacity .4s ease; }
.seal-orb strong {
  font-family: Aref Ruqaa, serif;
  font-size: clamp(36px, 11vw, 46px);
  letter-spacing: .02em;
  transform: translateY(-11px);
  text-shadow: 0 0 18px rgba(243,217,141,.24);
}
.seal-orb em {
  position: absolute;
  bottom: 28px;
  font: 600 11px Cormorant Garamond, serif;
  letter-spacing: .22em;
  font-style: normal;
  color: rgba(255,248,236,.7);
}
.seal-shine {
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  border: 1px solid rgba(243,217,141,.18);
}
.royal-gate:hover .seal-orb { transform: scale(1.04); }
body.cover-open .gate-left { transform: rotateY(-73deg) translateX(-22px); filter: brightness(1.22); }
body.cover-open .gate-right { transform: rotateY(73deg) translateX(22px); filter: brightness(1.22); }
body.cover-open .seal-orb { transform: scale(.66); opacity: 0; }
.gate-footer {
  align-self: start;
  display: grid;
  justify-items: center;
  gap: 14px;
  animation: riseIn 1.1s 1.35s both;
}
.tap-hint {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 8px 18px;
  color: rgba(255,248,236,.72);
  font-size: 12.5px;
  letter-spacing: .04em;
  border: 1px solid rgba(243,217,141,.24);
  border-radius: 999px;
  background: rgba(16,6,8,.42);
  backdrop-filter: blur(10px);
  animation: hintPulse 2.4s ease-in-out infinite;
}
.tap-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold-bright);
  box-shadow: 0 0 0 0 rgba(243,217,141,.55);
  animation: dotPing 2.4s ease-out infinite;
}
.gate-date {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  direction: ltr;
  color: rgba(243,217,141,.8);
  font: 600 12px/1 Cormorant Garamond, serif;
  letter-spacing: .34em;
  text-indent: .34em;
}
.gate-date i {
  width: 4px;
  height: 4px;
  transform: rotate(45deg);
  background: rgba(243,217,141,.62);
}
@keyframes hintPulse { 50% { opacity: .62; } }
@keyframes dotPing {
  0% { box-shadow: 0 0 0 0 rgba(243,217,141,.5); }
  70%, 100% { box-shadow: 0 0 0 10px rgba(243,217,141,0); }
}
@keyframes riseIn {
  from { opacity: 0; transform: translateY(18px); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}
@keyframes gateIn {
  from { opacity: 0; transform: translateY(30px) scale(.93); }
  to { opacity: 1; transform: none; }
}
@keyframes frameIn {
  from { opacity: 0; transform: scale(1.03); }
  to { opacity: 1; transform: none; }
}
@keyframes glowBreath {
  0%, 100% { opacity: .78; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.07); }
}
@keyframes spinSlow { to { transform: rotate(360deg); } }
@keyframes seamGlow {
  0%, 100% { opacity: .32; }
  50% { opacity: .85; }
}
@keyframes archSheen {
  0% { transform: translateX(0) rotate(8deg); opacity: 0; }
  12% { opacity: 1; }
  46%, 100% { transform: translateX(280%) rotate(8deg); opacity: 0; }
}
@keyframes sealPulse {
  0% { transform: scale(1); opacity: .75; }
  100% { transform: scale(1.85); opacity: 0; }
}

.invite-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: none;
  padding: 18px 18px 80px;
  background:
    radial-gradient(circle at 50% 0%, rgba(243,217,141,.16), transparent 300px),
    linear-gradient(180deg, rgba(23,7,10,.98), rgba(13,6,7,.98) 38%, rgba(34,13,15,.98) 100%);
  position: relative;
}
.invite-page::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .13;
  background:
    linear-gradient(90deg, transparent 0 16%, rgba(243,217,141,.22) 16% 16.3%, transparent 16.6% 83.4%, rgba(243,217,141,.22) 83.7% 84%, transparent 84%),
    radial-gradient(circle at 50% 10%, transparent 0 118px, rgba(243,217,141,.08) 119px 120px, transparent 121px);
}
body.cover-open .invite-page,
.invite-page.standalone { display: block; }

.top-ribbon {
  position: sticky;
  top: 12px;
  z-index: 12;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  margin: 0 auto 18px;
  max-width: 450px;
  color: rgba(255,248,236,.78);
  background: rgba(16,6,8,.44);
  border: 1px solid rgba(243,217,141,.18);
  border-radius: 999px;
  backdrop-filter: blur(18px);
  font: 700 11px/1 Cairo, sans-serif;
  letter-spacing: .16em;
  direction: ltr;
}

.hero-card {
  position: relative;
  display: grid;
  place-items: center;
  padding: 6px 2px 30px;
}
.hero-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
  bottom: 6px;
  width: 74%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.5), transparent);
}
.hero-frame {
  --photo-h: clamp(320px, 88vw, 430px);
  position: relative;
  z-index: 1;
  width: min(100%, 412px);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 20px 40px;
  border: 1px solid rgba(243,217,141,.5);
  border-radius: 208px 208px 34px 34px;
  background:
    radial-gradient(circle at 50% 96%, rgba(139,32,40,.4), transparent 62%),
    linear-gradient(180deg, rgba(255,248,236,.06), rgba(255,248,236,.03));
  box-shadow: inset 0 0 0 7px rgba(255,248,236,.025), 0 38px 76px rgba(0,0,0,.5);
  overflow: hidden;
  isolation: isolate;
}
.hero-frame::before {
  content: "";
  position: absolute;
  inset: 13px;
  border-radius: 196px 196px 24px 24px;
  border: 1px solid rgba(243,217,141,.26);
  pointer-events: none;
  z-index: 3;
}

.hero-photo {
  position: absolute;
  inset: 0 0 auto;
  height: var(--photo-h);
  z-index: 0;
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 26%;
  filter: saturate(1.03) contrast(1.02);
  -webkit-mask-image: linear-gradient(180deg, #000 0 50%, rgba(0,0,0,.78) 70%, rgba(0,0,0,.28) 88%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0 50%, rgba(0,0,0,.78) 70%, rgba(0,0,0,.28) 88%, transparent 100%);
}
.photo-wash {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(22,8,11,.5) 0 12%, rgba(22,8,11,.06) 34%, rgba(22,8,11,.34) 66%, rgba(19,7,9,.86) 92%, rgba(19,7,9,.98) 100%),
    radial-gradient(112% 66% at 50% 30%, transparent 48%, rgba(74,20,26,.42) 100%);
}
.photo-shine {
  position: absolute;
  top: -30%;
  left: -55%;
  width: 46%;
  height: 170%;
  transform: rotate(16deg);
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255,248,236,.22), transparent);
  animation: photoSweep 9s ease-in-out 2s infinite;
}
@keyframes photoSweep {
  0%, 66% { left: -55%; opacity: 0; }
  73% { opacity: 1; }
  100% { left: 116%; opacity: 0; }
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: center;
  width: 100%;
  margin-top: calc(var(--photo-h) - 66px);
}
.corner-mark {
  position: absolute;
  width: 42px;
  height: 42px;
  border-color: rgba(243,217,141,.68);
  pointer-events: none;
}
.top-left { top: 18px; left: 18px; border-top: 1px solid; border-left: 1px solid; border-radius: 18px 0 0 0; }
.top-right { top: 18px; right: 18px; border-top: 1px solid; border-right: 1px solid; border-radius: 0 18px 0 0; }
.bottom-left { bottom: 18px; left: 18px; border-bottom: 1px solid; border-left: 1px solid; border-radius: 0 0 0 18px; }
.bottom-right { bottom: 18px; right: 18px; border-bottom: 1px solid; border-right: 1px solid; border-radius: 0 0 18px 0; }

.hero-copy .tiny-caps {
  color: rgba(243,217,141,.72);
  letter-spacing: .42em;
  text-indent: .42em;
}
.arabic-kicker {
  margin: 12px 0 0;
  color: rgba(255,248,236,.7);
  font-family: Aref Ruqaa, serif;
  font-size: 22px;
  position: relative;
  z-index: 1;
}
.names-ar {
  display: grid;
  justify-items: center;
  gap: 2px;
  margin: 6px 0 2px;
  color: var(--ivory);
  font-family: Aref Ruqaa, Amiri, serif;
  font-weight: 700;
  font-size: clamp(44px, 12vw, 66px);
  line-height: 1.34;
  text-shadow: 0 18px 38px rgba(0,0,0,.55), 0 0 38px rgba(199,156,82,.14);
  position: relative;
  z-index: 1;
}
.names-ar .amp {
  color: var(--gold-bright);
  font: 400 .46em/1 Cormorant Garamond, serif;
  margin: 2px 0 4px;
  opacity: .92;
}
.names-en {
  margin: 0;
  color: var(--gold-bright);
  font-family: Great Vibes, Cormorant Garamond, serif;
  font-size: clamp(30px, 8.6vw, 46px);
  line-height: 1.1;
  direction: ltr;
  text-shadow: 0 8px 28px rgba(0,0,0,.45);
}
.names-en.hero-signature {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 3.4vw, 18px);
  width: min(100%, 350px);
  margin-top: 20px;
  font-size: clamp(26px, 7vw, 36px);
  line-height: 1.25;
  white-space: nowrap;
}
.names-en.hero-signature::before,
.names-en.hero-signature::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  transform: translateY(.12em);
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.55), transparent);
}
.date-lockup {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  margin-top: 26px;
  direction: ltr;
  width: min(100%, 330px);
}
.date-lockup span {
  color: rgba(255,248,236,.62);
  font: 800 10px/1 Cairo, sans-serif;
  letter-spacing: .18em;
  padding-block: 11px;
  border-top: 1px solid rgba(243,217,141,.24);
  border-bottom: 1px solid rgba(243,217,141,.24);
}
.date-lockup time {
  color: var(--ivory);
  font: 700 22px/1 Cormorant Garamond, serif;
  letter-spacing: .08em;
  white-space: nowrap;
}

.statement {
  padding: 18px 24px 28px;
  text-align: center;
}
.line-flourish {
  width: 220px;
  height: 18px;
  margin: 0 auto 18px;
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.55), transparent);
  position: relative;
}
.line-flourish::before,
.line-flourish::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 8px;
  height: 8px;
  transform: translate(-50%, -50%) rotate(45deg);
  background: var(--gold-bright);
  box-shadow: -50px 0 0 rgba(243,217,141,.45), 50px 0 0 rgba(243,217,141,.45);
}
.statement p {
  margin: 0 auto;
  max-width: 390px;
  color: rgba(255,248,236,.86);
  font: 400 21px/1.9 Aref Ruqaa, serif;
}
.statement .en-small {
  margin-top: 8px;
  color: rgba(255,248,236,.58);
  font: 500 15px/1.6 Cormorant Garamond, serif;
  direction: ltr;
}

.countdown-panel {
  margin: 10px auto 34px;
  padding: 36px 18px 30px;
  max-width: 452px;
  text-align: center;
  border-radius: 34px;
  background:
    linear-gradient(180deg, rgba(255,248,236,.08), rgba(255,248,236,.03)),
    radial-gradient(circle at 50% 0%, rgba(243,217,141,.2), transparent 150px);
  border: 1px solid rgba(243,217,141,.24);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.025), 0 26px 54px rgba(0,0,0,.28);
  position: relative;
  overflow: hidden;
}
.countdown-panel::before {
  content: "";
  position: absolute;
  top: -70px;
  left: 50%;
  width: 150px;
  height: 150px;
  border-radius: 999px;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(243,217,141,.18), transparent 70%);
}
.script-title {
  position: relative;
  margin: 0 0 22px;
  color: var(--gold-bright);
  font-family: Great Vibes, Cormorant Garamond, serif;
  font-size: 46px;
  direction: ltr;
}
.countdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  direction: ltr;
}
.time-tile {
  min-height: 92px;
  display: grid;
  align-content: center;
  border-radius: 19px;
  background: rgba(16,6,8,.5);
  border: 1px solid rgba(243,217,141,.22);
  box-shadow: inset 0 0 18px rgba(243,217,141,.04);
}
.time-tile strong {
  color: var(--ivory);
  font: 700 clamp(27px, 8vw, 40px)/1 Cormorant Garamond, serif;
  letter-spacing: .02em;
}
.time-tile span {
  margin-top: 9px;
  color: rgba(255,248,236,.48);
  font: 800 8px/1 Cairo, sans-serif;
  letter-spacing: .18em;
}

.venue-section {
  padding: 18px 0 46px;
}
.venue-card {
  position: relative;
  max-width: 430px;
  margin: 0 auto;
  padding: 42px 24px 34px;
  text-align: center;
  border-radius: 38px;
  color: var(--ivory);
  background:
    radial-gradient(circle at 50% -20%, rgba(243,217,141,.24), transparent 220px),
    linear-gradient(160deg, rgba(255,248,236,.1), rgba(255,248,236,.035));
  border: 1px solid rgba(243,217,141,.3);
  box-shadow: 0 34px 70px rgba(0,0,0,.34), inset 0 0 0 8px rgba(255,248,236,.02);
  overflow: hidden;
}
.venue-card::before {
  content: "";
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(243,217,141,.14);
  border-radius: 30px;
  pointer-events: none;
}
.venue-halo {
  position: absolute;
  inset: auto 50% -90px auto;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  transform: translateX(50%);
  background: radial-gradient(circle, rgba(139,32,40,.36), transparent 68%);
  pointer-events: none;
}
.spaced {
  margin: -14px 0 24px;
  color: rgba(255,248,236,.42);
  font: 800 9px/1.5 Cairo, sans-serif;
  letter-spacing: .35em;
  direction: ltr;
}
.lux-divider {
  width: 220px;
  height: 24px;
  margin: 0 auto 24px;
  position: relative;
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.48), transparent);
  mask: linear-gradient(#000 0 0) center/100% 1px no-repeat;
}
.lux-divider span {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 14px;
  height: 14px;
  transform: translate(-50%, -50%) rotate(45deg);
  background: linear-gradient(135deg, var(--gold), var(--gold-bright));
  border-radius: 3px;
}
.venue-card h3,
.venue-card h2 {
  margin: 0 0 14px;
  color: var(--gold-bright);
  font: 500 42px/1 Great Vibes, Cormorant Garamond, serif;
}
.venue-name {
  margin: 0 0 14px;
  color: var(--ivory);
  font: 800 18px/1.55 Cormorant Garamond, serif;
  letter-spacing: .14em;
  direction: ltr;
}
.address {
  margin: 0 auto 22px;
  max-width: 310px;
  color: rgba(255,248,236,.66);
  font: 600 13px/1.9 Cairo, sans-serif;
  direction: ltr;
}
.time-badge {
  display: inline-block;
  margin: 0 auto 28px;
  padding: 10px 18px;
  border-radius: 999px;
  color: var(--gold-bright);
  border: 1px solid rgba(243,217,141,.32);
  background: rgba(16,6,8,.38);
  font: 800 11px/1 Cairo, sans-serif;
  letter-spacing: .18em;
  direction: ltr;
}
.actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  direction: ltr;
}
.btn {
  min-width: 138px;
  padding: 13px 18px;
  border-radius: 999px;
  border: 1px solid rgba(243,217,141,.38);
  text-decoration: none;
  color: var(--ivory);
  background: rgba(16,6,8,.46);
  font: 800 12px/1 Cairo, sans-serif;
  letter-spacing: .08em;
  box-shadow: 0 14px 32px rgba(0,0,0,.22);
  transition: transform .28s ease, border-color .28s ease, background .28s ease;
}
.btn:hover { transform: translateY(-3px); border-color: rgba(243,217,141,.82); }
.btn.primary {
  color: #170809;
  background: linear-gradient(135deg, var(--gold), var(--gold-bright));
}

.closing-card {
  min-height: 420px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  text-align: center;
  position: relative;
  padding: 26px 16px 10px;
}
.closing-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 74%;
  height: 1px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, rgba(243,217,141,.45), transparent);
}
.window-symbol {
  position: relative;
  width: 154px;
  height: 232px;
  border: 2px solid rgba(243,217,141,.78);
  border-radius: 90px 90px 10px 10px;
  background:
    radial-gradient(circle at 50% 22%, rgba(243,217,141,.18), transparent 32%),
    linear-gradient(180deg, rgba(139,32,40,.44), rgba(16,6,8,.18));
  box-shadow: 0 0 38px rgba(243,217,141,.08), inset 0 0 0 8px rgba(0,0,0,.2);
  overflow: hidden;
}
.window-symbol::before,
.window-symbol::after {
  content: "";
  position: absolute;
  background: rgba(243,217,141,.62);
}
.window-symbol::before { top: 16px; bottom: 14px; left: 50%; width: 1px; }
.window-symbol::after { left: 16px; right: 16px; top: 50%; height: 1px; }
.window-symbol span:nth-child(1),
.window-symbol span:nth-child(2),
.window-symbol span:nth-child(3) {
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(243,217,141,.2);
  border-radius: 80px 80px 8px 8px;
}
.window-symbol span:nth-child(2) { inset: 36px 24px; opacity: .7; }
.window-symbol span:nth-child(3) { inset: auto 0 0; height: 20px; border: 0; background: repeating-linear-gradient(90deg, rgba(243,217,141,.52) 0 8px, transparent 8px 14px); border-radius: 0; }
.closing-card time {
  direction: ltr;
  color: rgba(255,248,236,.6);
  font: 700 13px/1 Cairo, sans-serif;
  letter-spacing: .28em;
}
.arabic-footer {
  margin: 4px 0 0;
  color: rgba(255,248,236,.78);
  font: 400 24px/1.8 Aref Ruqaa, serif;
}

/* Scoped to .js so the invitation is never hidden behind a script that failed
   to run. Without JS these elements keep their default visible state, because
   nothing else ever adds .visible to them. */
.js .reveal {
  opacity: 0;
  transform: translateY(32px) scale(.98);
  filter: blur(7px);
  transition: opacity .72s ease, transform .72s cubic-bezier(.2,.8,.2,1), filter .72s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

@media (max-width: 420px) {
  .experience { border-inline: 0; }
  .gate-screen { padding-inline: 16px; }
  .gate-frame { inset: 10px; border-radius: 24px; }
  .gate-frame::before { inset: 6px; border-radius: 19px; }
  .royal-gate { width: 84vw; }
  .seal-orb { width: 112px; height: 112px; }
  .seal-pulse { --seal-size: 112px; }
  .gate-date { letter-spacing: .26em; text-indent: .26em; font-size: 11px; }
  .invite-page { padding-inline: 12px; }
  .hero-card { min-height: 590px; }
  .hero-frame { min-height: 520px; padding-inline: 16px; }
  .date-lockup { gap: 8px; }
  .date-lockup time { font-size: 19px; }
  .countdown { gap: 6px; }
  .time-tile { min-height: 84px; border-radius: 16px; }
  .venue-card { padding-inline: 18px; }
  .btn { width: 100%; }
}

.noscript-link {
  display: inline-block;
  margin-top: 14px;
  padding: 12px 26px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--gold-bright);
  background: rgba(16, 6, 8, .62);
  font: 700 13px/1 Cairo, sans-serif;
  letter-spacing: .08em;
  text-decoration: none;
}

/* ---------------------------------------------------------------------------
   Mobile rendering budget.

   Three effects here are cheap on a desktop GPU and expensive on a mid-range
   phone, because each one forces work on every single frame over the full
   viewport:
     - starDrift animates background-position on a fixed, full-screen layer,
       which repaints the whole screen rather than compositing it;
     - mix-blend-mode: screen on .gold-noise forces an offscreen blend pass;
     - backdrop-filter blurs everything painted behind the element, and the
       audio button is fixed, so that cost is paid continuously.
   The static gradients stay, so the texture still reads as intended.
   --------------------------------------------------------------------------- */
@media (max-width: 560px) {
  body::after { animation: none; }
  .gold-noise { mix-blend-mode: normal; opacity: .18; }
  .audio-button { backdrop-filter: blur(8px); }
  .top-ribbon { backdrop-filter: none; background: rgba(16,6,8,.82); }
}

/* Phones that report a metered or slow connection get the plain page. */
@media (prefers-reduced-data: reduce) {
  body::after,
  .gold-noise,
  .spark-field { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  /* Without their animation the sparks would sit frozen mid-screen, so drop them. */
  .spark-field { display: none; }
}
