@import url('https://fonts.googleapis.com/css2?family=Arvo:wght@400;700&display=swap');
@import url('https://fonts.cdnfonts.com/css/patricia-signature');
@import url('https://fonts.googleapis.com/css2?family=Amiri:ital,wght@0,400;0,700;1,400&family=Cairo:wght@400;600;700&family=Aref+Ruqaa:wght@400;700&display=swap');

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

html, body {
  background-color: #ffffff !important;
  color-scheme: light;
}

/* ── Hero Shell ─────────────────────────────────── */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* ── Flowers ─────────────────────────────────────── */
.flower {
  position: absolute;
  z-index: 1;
  opacity: 0;
  pointer-events: none;
}

/* Top-left cluster */
.f1  { width: 310px; top: -10px; left: -15px;  transform-origin: top left;    animation: fadeIn 1.2s .1s  ease forwards, sway  6s   .8s  ease-in-out infinite; }
.f2  { width: 240px; top: -5px;  left: 210px;  transform-origin: top center;  animation: fadeIn 1.2s .2s  ease forwards, bob   5s   1s   ease-in-out infinite; }
.f3  { width: 190px; top: 0;     left: 410px;  transform-origin: top center;  animation: fadeIn 1.2s .3s  ease forwards, sway  7s   1.2s ease-in-out infinite; }

/* Top-right cluster */
.f4  { width: 170px; top: 0;     right: 380px; transform-origin: top center;  animation: fadeIn 1.2s .25s ease forwards, bob   6s   .9s  ease-in-out infinite; }
.f5  { width: 200px; top: -5px;  right: 190px; transform-origin: top center;  animation: fadeIn 1.2s .15s ease forwards, sway  8s   1.1s ease-in-out infinite; }
.f6  { width: 230px; top: -8px;  right: -10px; transform-origin: top right;   animation: fadeIn 1.2s .05s ease forwards, bob   5.5s .7s  ease-in-out infinite; }

/* Left side */
.f13 { width: 185px; top: 28vh;  left: -15px;  transform-origin: left center;  animation: fadeIn 1.2s .4s  ease forwards, float 7s   1.4s ease-in-out infinite; }

/* Right side */
.f7  { width: 210px; top: 20vh;  right: -18px; transform-origin: right center; animation: fadeIn 1.2s .35s ease forwards, float 6.5s 1.3s ease-in-out infinite; }

/* Bottom row */
.f8  { width: 185px; bottom: 0; left: -10px;  transform-origin: bottom left;   animation: fadeIn 1.2s .5s  ease forwards, sway  7s   1.5s ease-in-out infinite; }
.f9  { width: 170px; bottom: 0; left: 155px;  transform-origin: bottom center;  animation: fadeIn 1.2s .6s  ease forwards, bob   5.5s 1.6s ease-in-out infinite; }
.f10 { width: 270px; bottom: 0; left: 50%;    transform: translateX(-50%);      animation: fadeIn 1.2s .55s ease forwards, float 8s   1.8s ease-in-out infinite; }
.f11 { width: 170px; bottom: 0; right: 165px; transform-origin: bottom center;  animation: fadeIn 1.2s .6s  ease forwards, bob   6s   1.7s ease-in-out infinite; }
.f12 { width: 225px; bottom: 0; right: -10px; transform-origin: bottom right;   animation: fadeIn 1.2s .5s  ease forwards, sway  7.5s 1.5s ease-in-out infinite; }

/* ── Keyframes ──────────────────────────────────── */
@keyframes fadeIn {
  from { opacity: 0; transform: scale(.95); }
  to   { opacity: 1; transform: scale(1);   }
}
@keyframes sway {
  0%, 100% { transform: rotate(0deg);  }
  33%       { transform: rotate(3deg);  }
  66%       { transform: rotate(-2deg); }
}
@keyframes bob {
  0%, 100% { transform: translateY(0);    }
  50%       { transform: translateY(-9px); }
}
@keyframes float {
  0%, 100% { transform: translateX(0);   }
  50%       { transform: translateX(7px); }
}

/* ── Centered content ────────────────────────────── */
.hero-content {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 42px;          /* exact Figma gap */
  padding: 0 20px;
}

/* Date: 26 07 26 */
.hero-date {
  font-family: 'Arvo', serif;
  font-weight: 700;
  font-size: 18px;
  line-height: 22px;
  letter-spacing: 0.515em;
  color: #000000;
  text-transform: uppercase;
}

/* WEDDING INVITATION */
.hero-label {
  font-family: 'Arvo', serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  letter-spacing: 0.515em;
  color: #000000;
  text-transform: uppercase;
}

/* Ayoub & Merieme */
.hero-names {
  font-family: 'Patricia Signature', cursive;
  font-weight: 400;
  font-size: 72px;
  line-height: 125px;
  letter-spacing: 0.15em;
  color: #000000;
}

/* Countdown */
.hero-countdown {
  font-family: 'Arvo', serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 22px;
  letter-spacing: 0.515em;
  color: #000000;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
  flex-wrap: wrap;
}

.cd-num  { font-weight: 700; }
.cd-sep  { margin: 0 8px; opacity: .35; }

/* ══════════════════════════════════════════════════
   SHARED SECTION STYLES
══════════════════════════════════════════════════ */
.info-section {
  position: relative;
  width: 100%;
  background: #ffffff;
  overflow: hidden;
  padding: 80px 20px;
}

.section-inner {
  position: relative;
  z-index: 2;
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.section-label {
  font-family: 'Arvo', serif;
  font-weight: 400;
  font-size: 13px;
  letter-spacing: 0.52em;
  color: #000000;
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 20px;
}

.ornament-line {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  max-width: 320px;
  margin-bottom: 48px;
}
.ornament-line::before,
.ornament-line::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #000;
  opacity: .18;
}
.ornament-line span {
  font-size: 10px;
  opacity: .35;
  letter-spacing: 0;
}

/* corner decoration flowers for sections */
.deco-flower {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  opacity: .65;
}
.deco-tl { width: 180px; top: -16px;  left: -18px;  }
.deco-tr { width: 180px; top: -16px;  right: -18px; transform: scaleX(-1); }
.deco-bl { width: 180px; bottom: -10px; left: -10px; }
.deco-br { width: 180px; bottom: -10px; right: -10px; transform: scaleX(-1); }

/* ══════════════════════════════════════════════════
   VENUE / MAP SECTION
══════════════════════════════════════════════════ */
.venue-section {
  background: #f5f2ed;
}

.venue-section .section-inner {
  max-width: 1300px;
}

.venue-row {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0;
  width: 100%;
  margin-bottom: 28px;
}

.venue-col-divider {
  width: 0px;
  background: rgba(0,0,0,.12);
  flex-shrink: 0;
  margin: 0 28px;
  border-radius: 1px;
}

.venue-video-wrapper {
  flex: 1;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.08);
  box-shadow: 0 6px 32px rgba(0,0,0,.08);
  aspect-ratio: 3/4;
  min-height: 500px;
}

.venue-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.map-wrapper {
  flex: 1;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.1);
  box-shadow: 0 6px 32px rgba(0,0,0,.06);
  aspect-ratio: 3/2;
  min-height: 420px;
}

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

.map-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: 'Arvo', serif;
  font-size: 12px;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: #ffffff;
  background: #000000;
  text-decoration: none;
  padding: 14px 32px;
  border-radius: 2px;
  transition: background .2s, transform .15s;
}
.map-btn:hover {
  background: #222;
  transform: translateY(-1px);
}
.map-btn svg {
  flex-shrink: 0;
  opacity: .85;
}

/* ══════════════════════════════════════════════════
   PROGRAM / TIMELINE SECTION
══════════════════════════════════════════════════ */
.program-section {
  background: #0e0e0e;
  border-top: none;
  padding-top: 120px;
  padding-bottom: 120px;
}

.program-section .section-label {
  color: #ffffff;
}
.program-section .ornament-line::before,
.program-section .ornament-line::after {
  background: #fff;
  opacity: .2;
}
.program-section .ornament-line span {
  color: #fff;
  opacity: .3;
}
.prog-fl {
  opacity: .13;
  filter: none;
}

.prog-fl--tl { width: 220px; top: -30px;  left: -30px;  transform: rotate(160deg) scaleX(-1); }
.prog-fl--tr { width: 220px; top: -30px;  right: -30px; transform: rotate(200deg); }
.prog-fl--bl { width: 200px; bottom: -30px; left: -30px; transform: rotate(340deg); }
.prog-fl--br { width: 200px; bottom: -30px; right: -30px; transform: rotate(20deg) scaleX(-1); }

.timeline {
  width: 100%;
  max-width: 680px;
  display: flex;
  flex-direction: column;
}

.tl-item {
  display: grid;
  grid-template-columns: 68px 32px 1fr;
  align-items: stretch;
  min-height: 72px;
}

/* Time column */
.tl-time {
  font-family: 'Arvo', serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.04em;
  color: #fff;
  padding-top: 2px;
  text-align: right;
  line-height: 1.2;
  align-self: flex-start;
}
.tl-colon { opacity: .35; }

/* Spine column (dot + vertical line) */
.tl-spine {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 4px;
}

.tl-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #fff;
  flex-shrink: 0;
}

.tl-dot--star {
  background: none;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-radius: 50%;
  position: relative;
}
.tl-dot--star::after {
  content: '✦';
  position: absolute;
  font-size: 7px;
  top: 50%;
  left: 50%;
  transform: translate(-50%,-50%);
  color: #fff;
  line-height: 1;
}

.tl-line {
  flex: 1;
  width: 1px;
  background: rgba(255,255,255,.18);
  margin-top: 6px;
  min-height: 36px;
}

/* Content column */
.tl-body {
  padding: 0 0 28px 16px;
}

.tl-event {
  font-family: 'Patricia Signature', cursive;
  font-size: 32px;
  line-height: 1.2;
  color: #ffffff;
  margin-bottom: 6px;
}

.tl-sub {
  font-family: 'Arvo', serif;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: #fff;
  opacity: .4;
  margin-bottom: 6px;
}

.tl-detail {
  font-family: 'Arvo', serif;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #fff;
  opacity: .45;
  font-style: italic;
  line-height: 1.6;
}

.tl-last .tl-body {
  padding-bottom: 0;
}

.tl-ampm {
  font-size: 10px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,.45);
  font-weight: 400;
  display: block;
  margin-top: 2px;
}

.tl-list {
  list-style: none;
  margin: 8px 0 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tl-list li {
  font-family: 'Arvo', serif;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,.62);
  line-height: 1.65;
  padding-left: 16px;
  position: relative;
}

.tl-list li::before {
  content: '·';
  position: absolute;
  left: 0;
  top: 0;
  color: rgba(255,255,255,.4);
}

.tl-list li strong {
  color: rgba(255,255,255,.95);
  font-weight: 700;
}

.tl-list li em {
  font-style: italic;
  color: rgba(255,255,255,.45);
}

.tl-note {
  margin-top: 48px;
  max-width: 600px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 4px;
  padding: 22px 28px;
  text-align: center;
}

.tl-note p {
  font-family: 'Arvo', serif;
  font-size: 13px;
  letter-spacing: 0.05em;
  color: rgba(255,255,255,.5);
  line-height: 1.9;
}

.tl-note p strong {
  color: rgba(255,255,255,.85);
  font-weight: 700;
}

/* ══════════════════════════════════════════════════
   ARABIC / RTL OVERRIDES
══════════════════════════════════════════════════ */

[dir="rtl"] .hero-names {
  font-family: 'Aref Ruqaa', serif;
  font-size: 84px;
  letter-spacing: 0.04em;
  line-height: 1.25;
}

[dir="rtl"] .hero-label {
  font-family: 'Cairo', sans-serif;
  letter-spacing: 0;
  font-size: 22px;
}

[dir="rtl"] .hero-countdown {
  direction: ltr;
  font-family: 'Cairo', sans-serif;
  font-size: 18px;
  letter-spacing: 0.3em;
}

[dir="rtl"] .section-label {
  font-family: 'Cairo', sans-serif;
  letter-spacing: 0.08em;
  font-size: 16px;
}

[dir="rtl"] .tl-time {
  text-align: left;
}

[dir="rtl"] .tl-body {
  padding: 0 16px 28px 0;
}

[dir="rtl"] .tl-last .tl-body {
  padding-bottom: 0;
}

[dir="rtl"] .tl-event {
  font-family: 'Amiri', serif;
  font-size: 32px;
  letter-spacing: 0;
  line-height: 1.3;
}

[dir="rtl"] .tl-list li {
  padding-left: 0;
  padding-right: 16px;
  font-family: 'Cairo', sans-serif;
  font-size: 17px;
  letter-spacing: 0;
  line-height: 1.9;
}

[dir="rtl"] .tl-list li strong {
  font-weight: 700;
  color: rgba(255,255,255,.95);
}

[dir="rtl"] .tl-list li em {
  font-style: normal;
  color: rgba(255,255,255,.4);
  font-size: 12px;
}

[dir="rtl"] .tl-list li::before {
  left: auto;
  right: 0;
}

[dir="rtl"] .map-btn {
  font-family: 'Cairo', sans-serif;
  letter-spacing: 0.05em;
}

/* ── Venue stacks on tablets ─────────────────────── */
@media (max-width: 900px) {
  .venue-section .section-inner { max-width: 100%; }
  .venue-row { flex-direction: column; }
  .venue-col-divider { width: 100%; height: 1px; margin: 24px 0; }
  .venue-video-wrapper { aspect-ratio: 4/4; min-height: unset; }
  .map-wrapper { aspect-ratio: 4/4; min-height: unset; }
  .prog-fl { display: none; }
}

/* ── Responsive ─────────────────────────────────── */
@media (max-width: 600px) {
  .f2, .f3, .f4, .f5 { display: none; }
  .f1  { width: 220px; }
  .f6  { width: 170px; }
  .f10 { width: 200px; }
  .f13 { width: 140px; }
  .f7  { width: 155px; }

  .hero-names { font-size: 48px; line-height: 80px; }
  .hero-content { gap: 24px; }

  .info-section { padding: 56px 16px; }

  .deco-tl, .deco-tr { width: 110px; }
  .deco-bl, .deco-br { width: 110px; }

  .tl-item { grid-template-columns: 56px 28px 1fr; }
  .tl-time { font-size: 15px; }
  .tl-event { font-size: 26px; }
  .tl-list li { font-size: 13px; }

  [dir="rtl"] .hero-names { font-size: 58px; line-height: 1.3; }
  [dir="rtl"] .tl-event { font-size: 26px; }
  [dir="rtl"] .tl-list li { font-size: 15px; }
}

/* ── Page Loader ─────────────────────────────────── */
#page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #faf7f2;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: opacity .7s ease, visibility .7s ease;
}

#page-loader.ld-out {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

/* Corner flowers */
.ld-fl {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ld-tl {
  width: clamp(160px, 28vw, 340px);
  top: -10px; left: -10px;
  transform-origin: top left;
  animation: ldCornerIn .9s .1s cubic-bezier(.22,1,.36,1) forwards,
             sway 7s 1.2s ease-in-out infinite;
}
.ld-tr {
  width: clamp(140px, 26vw, 280px);
  top: -8px; right: -10px;
  transform-origin: top right;
  animation: ldCornerIn .9s .15s cubic-bezier(.22,1,.36,1) forwards,
             bob 6s 1.3s ease-in-out infinite;
}
.ld-bl {
  width: clamp(140px, 24vw, 240px);
  bottom: 0; left: -10px;
  transform-origin: bottom left;
  animation: ldCornerIn .9s .2s cubic-bezier(.22,1,.36,1) forwards,
             sway 8s 1.4s ease-in-out infinite;
}
.ld-br {
  width: clamp(160px, 28vw, 280px);
  bottom: 0; right: -10px;
  transform-origin: bottom right;
  animation: ldCornerIn .9s .25s cubic-bezier(.22,1,.36,1) forwards,
             bob 7s 1.5s ease-in-out infinite;
}

/* Center cluster */
.ld-core {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  opacity: 0;
  animation: ldCoreIn 1s .35s cubic-bezier(.22,1,.36,1) forwards;
}

.ld-center-fl {
  width: clamp(140px, 22vw, 260px);
  animation: ldPulse 2.8s 1.4s ease-in-out infinite;
}

.ld-names {
  font-family: 'Patricia Signature', cursive;
  font-weight: 400;
  font-size: clamp(32px, 6vw, 72px);
  line-height: 1.3;
  letter-spacing: 0.15em;
  color: #000000;
  white-space: nowrap;
}

[dir="rtl"] .ld-names {
  font-family: 'Aref Ruqaa', serif;
  font-size: clamp(36px, 6.5vw, 84px);
  letter-spacing: 0.04em;
}

.ld-dots {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}
.ld-dots span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #b8a898;
  animation: ldDot 1.4s ease-in-out infinite;
}
.ld-dots span:nth-child(2) { animation-delay: .2s; }
.ld-dots span:nth-child(3) { animation-delay: .4s; }

/* Keyframes */
@keyframes ldCornerIn {
  from { opacity: 0; transform: scale(.82); }
  to   { opacity: 1; transform: scale(1);   }
}
@keyframes ldCoreIn {
  from { opacity: 0; transform: translateY(14px) scale(.94); }
  to   { opacity: 1; transform: translateY(0)    scale(1);   }
}
@keyframes ldPulse {
  0%, 100% { transform: scale(1);    }
  50%       { transform: scale(1.06); }
}
@keyframes ldDot {
  0%, 80%, 100% { transform: scale(.6); opacity: .4; }
  40%            { transform: scale(1);  opacity: 1;  }
}
