:root {
  --teal: #007080;
  --teal-dark: #005a66;
  --gold: #C9A227;
  --gold-light: #E8D48B;
  --gold-dark: #9A7B0A;
  --rose: #c9596d;
  --rose-light: #f4c2c2;
  --rose-deep: #8b2942;
  --bronze: #a67c52;
  --primary: #1a7a4c;
  --accent: #e8f5ee;
  --blue: #1a3d7c;
  --dark: #1a1a1a;
  --text: #2d2d2d;
  --bg: #faf9f6;
  --card-bg: rgba(255, 255, 255, 0.12);
  --info-bg: rgba(255, 252, 247, 0.96);
  --info-bg-end: rgba(245, 237, 225, 0.94);
  --brown-warm: #5d3a1a;
  --cyan-accent: #00a8c5;
  --bs-primary: #1a7a4c;
  --bs-primary-rgb: 26, 122, 76;
  --carousel-aspect: 1026 / 1280;
  --carousel-poster-aspect: 3 / 4;
}
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  overflow-y: scroll;
  -webkit-overflow-scrolling: touch;
}

html::-webkit-scrollbar {
  width: 6px;
}
html::-webkit-scrollbar-thumb {
  background: rgba(201, 162, 39, 0.45);
  border-radius: 999px;
}
html {
  scrollbar-width: thin;
  scrollbar-color: rgba(201, 162, 39, 0.45) transparent;
}

/* Animation de chargement */
.loader {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background:
    radial-gradient(ellipse at 50% 40%, rgba(201, 89, 109, 0.35) 0%, transparent 55%),
    linear-gradient(145deg, rgba(74, 20, 40, 0.98), rgba(139, 41, 66, 0.95), rgba(201, 162, 39, 0.88));
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.6s ease-out, visibility 0.6s ease-out;
  pointer-events: auto;
}
.loader-content {
  text-align: center;
  animation: loaderFadeIn 0.8s ease-out both;
}
.loader-ring-wrap {
  position: relative;
  width: 110px;
  height: 110px;
  margin: 0 auto 1rem;
}
.loader-ring {
  width: 100%;
  height: 100%;
  object-fit: contain;
  animation: ringFloat 2.5s ease-in-out infinite, loaderPulse 2s ease-in-out infinite;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.25));
}
.loader-orbit {
  position: absolute;
  inset: -8px;
  border: 2px solid transparent;
  border-top-color: rgba(255, 255, 255, 0.85);
  border-right-color: rgba(232, 212, 139, 0.6);
  border-radius: 50%;
  animation: rotate 1.4s linear infinite;
}
.loader-text {
  font-family: 'Freestyle Script', cursive;
  font-size: 2.75rem;
  color: #fff;
  letter-spacing: 4px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.2);
}
.loader-sub {
  margin-top: 0.35rem;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.82);
}
.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
body.is-loading { overflow: hidden; }
@keyframes loaderFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes loaderPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

body,
body.page-bg {
  margin: 0;
  min-height: 100vh;
  min-height: -webkit-fill-available;
  background-color: #3d2818;
  background-image: url('../img/background.avif');
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  background-attachment: fixed;
  color: var(--text);
  font-family: 'Montserrat', system-ui, -apple-system, sans-serif;
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
@media (max-width: 768px) {
  body.page-bg {
    background-attachment: scroll;
    background-position: center top;
    background-size: cover;
  }
  /* Le chargement ne doit jamais empêcher le geste de défilement sur téléphone. */
  body.is-loading { overflow-y: auto; }
}
@media (min-aspect-ratio: 16/10) {
  body.page-bg {
    background-size: cover;
    background-position: center 20%;
  }
}
.page-overlay {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(201, 89, 109, 0.18) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 30%, rgba(201, 162, 39, 0.15) 0%, transparent 45%),
    linear-gradient(
      90deg,
      rgba(45, 20, 18, 0.78) 0%,
      rgba(255, 255, 255, 0.22) 16%,
      rgba(255, 248, 242, 0.48) 50%,
      rgba(255, 255, 255, 0.22) 84%,
      rgba(45, 20, 18, 0.78) 100%
    ),
    linear-gradient(
      180deg,
      rgba(139, 41, 66, 0.12) 0%,
      rgba(255, 255, 255, 0.35) 40%,
      rgba(255, 240, 245, 0.55) 100%
    );
}
.page-wrapper {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 1rem 0 2.5rem;
}
.invitation-container {
  width: min(80%, 720px);
  max-width: 80%;
  margin-left: auto;
  margin-right: auto;
  padding-left: env(safe-area-inset-left, 0.5rem);
  padding-right: env(safe-area-inset-right, 0.5rem);
}
.invitation-card {
  position: relative;
  width: 100%;
  overflow: visible;
  background: transparent;
  border-radius: 20px;
  box-shadow:
    0 24px 64px rgba(74, 20, 40, 0.28),
    0 0 0 1px rgba(201, 162, 39, 0.2);
  border: none;
  animation: cardReveal 1.1s cubic-bezier(0.22, 1, 0.36, 1) both;
  padding: 0.5rem;
}
body.is-ready .invitation-card {
  animation: cardReveal 1.1s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes cardReveal {
  from { opacity: 0; transform: translateY(32px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.invitation-info {
  position: relative;
  background:
    linear-gradient(
      165deg,
      rgba(255, 252, 250, 0.99) 0%,
      rgba(255, 248, 245, 0.97) 40%,
      rgba(252, 240, 244, 0.96) 100%
    );
  border-radius: 16px;
  border: 1px solid rgba(201, 162, 39, 0.4);
  box-shadow:
    0 8px 32px rgba(139, 41, 66, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(201, 89, 109, 0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow: hidden;
}
.invitation-info::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--rose-deep), var(--gold), var(--rose), var(--gold-light), var(--gold));
  z-index: 1;
  pointer-events: none;
}
.invitation-section {
  padding: 1rem 1.15rem;
}
.section-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.35rem 1.5rem;
  color: var(--gold);
  opacity: 0.55;
  font-size: 0.75rem;
}
.section-divider::before,
.section-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(201, 162, 39, 0.45), transparent);
}
.section-divider span {
  animation: sparkle 3s ease-in-out infinite;
}
.invitation-header {
  padding-top: 1.25rem;
}
.invitation-header .quote-section {
  margin-bottom: 1rem;
}
.invitation-header .families-section {
  margin: 0.75rem 0;
}
.invitation-header .names {
  margin: 0.75rem 0;
}
.gallery-section {
  margin-top: 0.5rem;
  padding: 0.85rem 1rem 1.15rem;
  background: rgba(255, 255, 255, 0.88);
  border-radius: 12px;
  border: 1px solid rgba(0, 168, 197, 0.25);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.border-gold {
  border-color: rgba(201, 162, 39, 0.35) !important;
}
.border-gold-subtle {
  border-color: rgba(201, 162, 39, 0.2) !important;
}
.btn-primary {
  --bs-btn-bg: var(--teal);
  --bs-btn-border-color: var(--teal);
  --bs-btn-hover-bg: var(--teal-dark);
  --bs-btn-hover-border-color: var(--teal-dark);
  --bs-btn-active-bg: var(--teal-dark);
  --bs-btn-active-border-color: var(--teal-dark);
}
/* Cadre décoratif autour de la carte */
.frame {
  position: absolute;
  inset: -40px;
  border: 3px solid transparent;
  border-radius: 24px;
  background: linear-gradient(#fff, #fff) padding-box,
              linear-gradient(135deg, rgba(201,162,39,0.5), rgba(232,212,139,0.35), rgba(201,162,39,0.5)) border-box;
  pointer-events: none;
  z-index: 0;
  animation: frameGlow 3s ease-in-out infinite;
}
.frame::before {
  content: "";
  position: absolute;
  inset: -20px;
  border: 2px solid rgba(196,160,119,0.2);
  border-radius: 28px;
  animation: framePulse 4s ease-in-out infinite;
}
/* Coins décoratifs du cadre */
.corner-decoration {
  position: absolute;
  width: 60px;
  height: 60px;
  pointer-events: none;
  z-index: -1;
}
.corner-decoration.top-left {
  top: -30px;
  left: -30px;
  background: radial-gradient(circle, rgba(201,162,39,0.28), transparent 70%);
  border-radius: 50%;
  animation: cornerFloat 6s ease-in-out infinite;
}
.corner-decoration.top-right {
  top: -30px;
  right: -30px;
  background: radial-gradient(circle, rgba(201,162,39,0.28), transparent 70%);
  border-radius: 50%;
  animation: cornerFloat 6s ease-in-out infinite 1.5s;
}
.corner-decoration.bottom-left {
  bottom: -30px;
  left: -30px;
  background: radial-gradient(circle, rgba(201,162,39,0.28), transparent 70%);
  border-radius: 50%;
  animation: cornerFloat 6s ease-in-out infinite 3s;
}
.corner-decoration.bottom-right {
  bottom: -30px;
  right: -30px;
  background: radial-gradient(circle, rgba(201,162,39,0.28), transparent 70%);
  border-radius: 50%;
  animation: cornerFloat 6s ease-in-out infinite 4.5s;
}
.invitation-card::before, .invitation-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(166,124,82,0.25);
  border-radius: 14px;
  pointer-events: none;
  will-change: transform;
}
.invitation-card::before {
  transform: translate(10px, 10px);
  opacity: 0.35;
}
.invitation-card::after {
  transform: translate(20px, 20px);
  opacity: 0.18;
}
.monogram {
  width: 140px;
  height: 140px;
  margin: 0 auto 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: grid;
  place-items: center;
  color: #fff;
  font-family: 'Freestyle Script', cursive;
  font-size: 48px;
  letter-spacing: 1px;
  box-shadow: inset 0 0 0 8px rgba(255,255,255,0.5),
              0 12px 40px rgba(166,124,82,0.25);
  position: relative;
  overflow: hidden;
  animation: pulse 2.2s ease-in-out infinite;
  z-index: 1;
  font-weight: normal;
  text-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.monogram::before {
  content: "";
  position: absolute;
  inset: -50%;
  background: conic-gradient(from 0deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: rotate 4s linear infinite;
}
.monogram::after {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  z-index: -1;
}
h1 {
  text-align: center;
  margin: 0 0 12px;
  font-family: 'Freestyle Script', cursive;
  font-size: 56px;
  color: var(--dark);
  letter-spacing: 2px;
  animation: fadeUp 900ms ease-out both;
  font-weight: normal;
  text-shadow: 0 2px 12px rgba(0,0,0,0.08);
  line-height: 1.2;
}
h2 {
  margin: 12px 0 32px;
  text-align: center;
  font-weight: normal;
}
/* Styles pour index2.html - Sections du PDF */
.quote-section {
  margin: 0;
  padding: 0.85rem 0.75rem;
  text-align: center;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 10px;
  border: 1px solid rgba(0, 168, 197, 0.15);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}
.quote-text {
  font-family: 'Playfair Display', serif;
  font-size: clamp(0.8rem, 2.8vw, 0.95rem);
  font-style: italic;
  color: var(--dark);
  line-height: 1.55;
  margin: 0;
}
.invocation {
  margin: 10px 0;
  text-align: center;
  padding: 5px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 12px;
  animation: fadeUp 1s ease-out both 100ms;
}
.arabic-text {
  font-family: 'Arial', sans-serif;
  font-size: 18px;
  color: var(--primary);
  margin: 8px 0;
  direction: rtl;
  text-align: center;
  font-weight: 500;
}
.translation {
  font-family: 'Montserrat', sans-serif;
  font-size: 13px;
  color: rgba(0, 0, 0, 0.6);
  margin: 4px 0;
  font-style: italic;
}
.families-section {
  margin: 32px 0;
  text-align: center;
  animation: fadeUp 1s ease-out both 140ms;
}
.family-group {
  margin: 20px 0;
}
.family-title {
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: rgba(0, 0, 0, 0.6);
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.family-name {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-weight: 700;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold), var(--gold-light));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 0;
  letter-spacing: 2px;
}
.separator-large {
  font-family: 'Freestyle Script', cursive;
  font-size: 48px;
  color: var(--accent);
  margin: 16px 0;
  text-align: center;
  opacity: 0.8;
}
.invitation-message {
  margin: 10px 0 40px;
  text-align: center;
  padding: 10px;
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  color: var(--dark);
  line-height: 1.8;
  animation: fadeUp 1s ease-out both 160ms;
}
.invitation-message p {
  margin: 0;
}
h2 {
  margin: 12px 0 32px;
  text-align: center;
  font-weight: normal;
  letter-spacing: 4px;
  text-transform: none;
  color: var(--primary);
  font-size: 24px;
  font-family: 'Freestyle Script', cursive;
  opacity: 0.9;
}
.names {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  position: relative;
}
.rings-showcase {
  position: relative;
  width: clamp(88px, 18vw, 120px);
  height: clamp(88px, 18vw, 120px);
  margin: 0.65rem auto 0.85rem;
  display: grid;
  place-items: center;
}
.rings-glow {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 39, 0.45) 0%, rgba(232, 212, 139, 0.15) 45%, transparent 72%);
  animation: ringGlowPulse 2.8s ease-in-out infinite;
  z-index: 0;
}
.rings-sparkle {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle, #fff 0%, var(--gold-light) 40%, transparent 100%);
  opacity: 0;
  z-index: 3;
  animation: ringSparkle 3s ease-in-out infinite;
}
.rings-sparkle--left {
  top: 18%;
  left: 8%;
  animation-delay: 0.4s;
}
.rings-sparkle--right {
  bottom: 22%;
  right: 6%;
  animation-delay: 1.6s;
}
.names .rings {
  position: relative;
  z-index: 2;
  width: clamp(72px, 15vw, 96px);
  height: auto;
  margin: 0;
  pointer-events: none;
  animation: ringFloat 3.5s ease-in-out infinite, ringShimmer 5s ease-in-out infinite;
  filter: drop-shadow(0 6px 14px rgba(201, 162, 39, 0.5));
  transform-origin: center center;
}
@keyframes ringFloat {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-6px) rotate(2deg); }
}
@keyframes ringShimmer {
  0%, 100% { filter: drop-shadow(0 6px 14px rgba(201, 162, 39, 0.45)) brightness(1); }
  50% { filter: drop-shadow(0 8px 20px rgba(232, 212, 139, 0.75)) brightness(1.08); }
}
@keyframes ringGlowPulse {
  0%, 100% { transform: scale(0.92); opacity: 0.65; }
  50% { transform: scale(1.08); opacity: 1; }
}
@keyframes ringSparkle {
  0%, 100% { opacity: 0; transform: scale(0.5); }
  45%, 55% { opacity: 1; transform: scale(1.2); }
}
.names::before,
.names::after {
  content: "✦";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  color: var(--gold);
  font-size: 14px;
  opacity: 0.35;
}
.names::before {
  top: -8px;
}
.names::after {
  bottom: -8px;
}
.names .name-groom,
.names .name-bride {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: clamp(1.25rem, 4.5vw, 1.75rem) !important;
  line-height: 1.3;
  animation: fadeUp 1s ease-out both;
}
.name-groom {
  animation-delay: 0.1s;
  background: linear-gradient(180deg, #E8D48B 0%, #C9A227 45%, #9A7B0A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  -webkit-text-stroke: 0.5px rgba(154, 123, 10, 0.35);
}
.name-bride {
  animation-delay: 0.2s;
  color: var(--dark) !important;
}
.separator {
  text-align: center;
  letter-spacing: 12px;
  color: rgba(201, 162, 39, 0.55);
  font-size: 18px;
  font-family: 'Freestyle Script', cursive;
  margin: 8px 0;
  position: relative;
}
.separator::before,
.separator::after {
  content: "✿";
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-size: 14px;
  opacity: 0.6;
}
.separator::before {
  left: 20%;
}
.separator::after {
  right: 20%;
}
.details {
  text-align: center;
  margin: 0;
  line-height: 1.65;
  font-size: 1.15rem;
  color: var(--dark);
  font-family: 'Freestyle Script', cursive;
}
.date {
  margin: 0.5rem auto 0;
  width: fit-content;
  max-width: 100%;
  padding: 0.65rem 1.25rem;
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 12px;
  color: var(--gold-dark);
  letter-spacing: 0.5px;
  background: rgba(255, 255, 255, 0.85);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  line-height: 1.5;
  box-shadow: 0 4px 16px rgba(201, 162, 39, 0.1);
}
.cta {
  text-align: center;
  margin-top: 26px;
}
.cta a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.5px;
  box-shadow: 0 10px 25px rgba(166,124,82,0.35);
  transition: transform 160ms ease, box-shadow 160ms ease;
  position: relative;
  overflow: hidden;
  animation: buttonGlow 3s ease-in-out infinite;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
}
.cta a:active {
  transform: translateY(0);
  box-shadow: 0 8px 20px rgba(166,124,82,0.3);
}
.cta a::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s ease;
}
.cta a:hover::before {
  transform: translateX(100%);
}
.cta a:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(166,124,82,0.32); }
.program {
  margin: 0;
  padding-top: 0;
  border-top: none;
}
.program h3,
.program-title {
  margin: 0 auto 1rem;
  text-align: center;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(135deg, var(--teal-dark), var(--teal), #0099a8);
  padding: 12px 36px;
  border-radius: 999px;
  width: fit-content;
  box-shadow: 0 6px 20px rgba(0, 112, 128, 0.35);
}
.program-intro {
  margin: 0 0 1.25rem;
  font-size: 0.9rem;
  color: rgba(0, 0, 0, 0.65);
  line-height: 1.5;
}
.program-cards {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.name-couple {
  font-size: clamp(1.35rem, 5vw, 1.9rem) !important;
  letter-spacing: 2px !important;
}
.countdown {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin: 1rem auto 0;
  padding: 0.75rem 1rem;
  max-width: 100%;
  background: linear-gradient(135deg, rgba(0, 112, 128, 0.08), rgba(201, 162, 39, 0.1));
  border: 1px solid rgba(201, 162, 39, 0.28);
  border-radius: 14px;
  animation: fadeUp 1s ease-out both 0.3s;
}
.countdown-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.2rem;
}
.countdown-num {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--teal-dark);
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
.countdown-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(0, 0, 0, 0.5);
  margin-top: 0.15rem;
}
.countdown-sep {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  color: var(--gold);
  opacity: 0.7;
  align-self: flex-start;
  padding-top: 0.15rem;
}
.countdown-done {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--teal-dark);
  font-size: 1rem;
}
.invitation-closing {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1rem !important;
  color: rgba(0, 0, 0, 0.72) !important;
  line-height: 1.65 !important;
  max-width: 32rem;
  margin-left: auto !important;
  margin-right: auto !important;
}
.contact-row {
  margin-top: 0.5rem;
}
[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--reveal-delay, 0ms);
}
[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}
.program-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(201, 162, 39, 0.28);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
  transform: translateY(0);
  transition:
    box-shadow 0.3s ease,
    transform 0.3s ease,
    border-color 0.3s ease,
    background 0.3s ease;
}
.program-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.1);
}
.home-item {
  border-left: 3px solid rgba(201, 162, 39, 0.45);
}
.home-item:hover {
  border-left-color: var(--gold);
  background: rgba(201, 162, 39, 0.04);
}
.program-card-head {
  margin-bottom: 0.5rem;
}
.program-day {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gold-dark);
  background: rgba(201, 162, 39, 0.12);
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 0.4rem;
}
.program-day-reception {
  color: var(--blue);
  background: rgba(26, 61, 124, 0.1);
}
.program-event {
  margin: 0;
  font-family: 'Freestyle Script', cursive;
  font-size: 1.75rem;
  font-weight: normal;
  color: var(--teal-dark);
  line-height: 1.2;
}
.program-event-reception {
  color: var(--blue);
}
.program-time {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  color: var(--dark);
}
.program-place {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  line-height: 1.55;
  color: rgba(0, 0, 0, 0.72);
}
.program-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  margin-top: 0.35rem;
  padding-top: 0.65rem;
  border-top: 1px dashed rgba(201, 162, 39, 0.22);
}
.program-actions .icon-btn {
  width: 100%;
  min-width: 0;
  height: 46px;
  min-height: 46px;
  padding: 0.35rem 0.5rem;
  border: 1px solid rgba(201, 162, 39, 0.22);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.07);
}
.program-actions .icon-btn img {
  width: auto;
  height: 100%;
  max-width: 88%;
  max-height: 32px;
  object-fit: contain;
  margin: 0 auto;
}
.program-actions .icon-btn img[src="img/yango.png"],
.program-actions .icon-btn img[src="../img/yango.png"] {
  width: auto;
  height: 100%;
  max-width: 72%;
  max-height: 28px;
  object-fit: contain;
}
.program-actions .icon-btn img[src="img/maps.jpg"],
.program-actions .icon-btn img[src="../img/maps.jpg"] {
  width: auto;
  height: 100%;
  max-width: 88%;
  max-height: 32px;
  object-fit: contain;
}
/* Info-bulle pour les localisations */
.info-bubble {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  margin: -8px 0 20px;
  padding: 10px 16px;
  background: rgba(201, 162, 39, 0.1);
  border-radius: 12px;
  font-size: 12px;
  color: rgba(0, 0, 0, 0.7);
  font-family: 'Montserrat', sans-serif;
  font-weight: 400;
  line-height: 1.4;
  border: 1px solid rgba(201, 162, 39, 0.15);
}
.info-bubble svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--gold);
}
.info-bubble span {
  flex: 1;
  text-align: center;
}
.program-list .program-item {
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}
.program-list .program-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.program-row {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}
.program-content {
  flex: 1;
  min-width: 0;
}
.program-item {
  list-style: none;
  animation: fadeUp 900ms ease-out both;
  transition: background 200ms ease;
  border-radius: 8px;
}
.program-item:hover {
  transform: translateX(4px);
  background: rgba(201, 162, 39, 0.05);
}
.event-type {
  font-family: 'Freestyle Script', cursive;
  font-size: 1.35em;
  font-weight: normal;
  color: var(--gold-dark);
  letter-spacing: 0;
  text-transform: none;
}
.event-reception {
  color: var(--blue);
}
.reception-item .text .label {
  color: var(--text);
}
.program-item .text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.program-item:nth-child(1) { animation-delay: 0.1s; }
.program-item:nth-child(2) { animation-delay: 0.2s; }
.program-item:nth-child(3) { animation-delay: 0.3s; }
.program-item:last-child { border-bottom: none; }
.icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(201,162,39,0.12), rgba(232,212,139,0.18));
  display: grid;
  place-items: center;
  color: var(--primary);
  transition: transform 200ms ease, background 200ms ease, box-shadow 200ms ease;
  animation: iconFloat 3s ease-in-out infinite;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.icon svg {
  width: 28px;
  height: 28px;
}
.icon:hover {
  transform: scale(1.1) rotate(5deg);
  background: linear-gradient(135deg, rgba(166,124,82,0.2), rgba(196,160,119,0.25));
}
/* Styles spécifiques pour les icônes d'événements */
.mosque-icon {
  background: linear-gradient(135deg, rgba(34, 139, 34, 0.15), rgba(50, 205, 50, 0.12));
  color: #228B22;
  animation: iconFloat 3s ease-in-out infinite, mosqueGlow 2s ease-in-out infinite;
}
.mosque-icon:hover {
  background: linear-gradient(135deg, rgba(34, 139, 34, 0.25), rgba(50, 205, 50, 0.2));
  transform: scale(1.15) rotate(-3deg);
}
.reception-icon {
  background: linear-gradient(135deg, rgba(255, 140, 0, 0.15), rgba(255, 165, 0, 0.12));
  color: #FF8C00;
  animation: iconFloat 3s ease-in-out infinite 0.5s, receptionPulse 2.5s ease-in-out infinite;
}
.reception-icon:hover {
  background: linear-gradient(135deg, rgba(255, 140, 0, 0.25), rgba(255, 165, 0, 0.2));
  transform: scale(1.15) rotate(3deg);
}
.dance-icon {
  background: linear-gradient(135deg, rgba(186, 85, 211, 0.15), rgba(221, 160, 221, 0.12));
  color: #BA55D3;
  animation: iconFloat 3s ease-in-out infinite 1s, danceShake 2s ease-in-out infinite;
}
.dance-icon:hover {
  background: linear-gradient(135deg, rgba(186, 85, 211, 0.25), rgba(221, 160, 221, 0.2));
  transform: scale(1.15) rotate(-5deg);
}
/* Styles pour les items de programme */
.mosque-item {
  border-left: 3px solid rgba(34, 139, 34, 0.3);
}
.mosque-item:hover {
  background: rgba(34, 139, 34, 0.05);
  border-left-color: rgba(34, 139, 34, 0.6);
}
.reception-item {
  border-left: 3px solid rgba(255, 140, 0, 0.3);
}
.reception-item:hover {
  background: rgba(255, 140, 0, 0.05);
  border-left-color: rgba(255, 140, 0, 0.6);
}
.dance-item {
  border-left: 3px solid rgba(186, 85, 211, 0.3);
}
.dance-item:hover {
  background: rgba(186, 85, 211, 0.05);
  border-left-color: rgba(186, 85, 211, 0.6);
}
/* Animations spécifiques */
@keyframes mosqueGlow {
  0%, 100% { box-shadow: 0 0 8px rgba(34, 139, 34, 0.3); }
  50% { box-shadow: 0 0 16px rgba(34, 139, 34, 0.5); }
}
@keyframes receptionPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}
@keyframes danceShake {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-2deg); }
  75% { transform: rotate(2deg); }
}
.program-item:nth-child(1) .icon { animation-delay: 0s; }
.program-item:nth-child(2) .icon { animation-delay: 1s; }
.program-item:nth-child(3) .icon { animation-delay: 2s; }
.icon svg { width: 26px; height: 26px; }
.text .label {
  font-weight: 500;
  color: var(--dark);
  margin-bottom: 4px;
  word-wrap: break-word;
  hyphens: auto;
  line-height: 1.4;
}
.text .time {
  color: rgba(0,0,0,0.68);
  font-size: 14px;
  margin-bottom: 4px;
  line-height: 1.5;
}
.infoline {
  text-align: center;
  margin: 20px 0 0;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}
.infoline a {
  color: var(--primary);
  text-decoration: none;
}
.infoline a:hover {
  text-decoration: underline;
}
.actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 4px;
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 150px;
  height: 40px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255,255,255,0.85);
  box-shadow: 0 8px 18px rgba(0,0,0,0.12);
  transition: transform 140ms ease, box-shadow 140ms ease;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.icon-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(0,0,0,0.16); }
.icon-btn:active { transform: translateY(0); box-shadow: 0 6px 14px rgba(0,0,0,0.14); }
.icon-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* Réduire la taille du logo Yango dans les boutons */
.icon-btn img[src="img/yango.png"],
.icon-btn img[src="../img/yango.png"] {
  width: 60%;
  height: 60%;
  object-fit: contain;
  margin: auto;
}
/* Augmenter la taille de l'image Maps dans les boutons */
.icon-btn img[src="img/maps.jpg"],
.icon-btn img[src="../img/maps.jpg"] {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* .rings : styles définis dans .names .rings et .rings-showcase */
.glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 70% 80%, rgba(255, 215, 128, 0.18), transparent 40%),
              radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.15), transparent 30%);
  pointer-events: none;
  animation: glowPulse 4s ease-in-out infinite;
}
/* Effet de brillance animé */
.shimmer {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 3s ease-in-out infinite;
  pointer-events: none;
  border-radius: 18px;
  opacity: 0.6;
}
footer {
  text-align: center;
  margin-top: 34px;
  font-size: 13px;
  color: rgba(0,0,0,0.55);
}
/* Boutons de contact */
.contact-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 24px;
  flex-wrap: wrap;
}
.contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 12px;
  text-decoration: none;
  font-family: 'Montserrat', sans-serif;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  min-height: 44px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.contact-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.whatsapp-btn {
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #fff;
}
.whatsapp-btn:hover {
  background: linear-gradient(135deg, #128C7E, #25D366);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(37, 211, 102, 0.3);
}
.whatsapp-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(37, 211, 102, 0.2);
}
.call-btn:hover {
  transform: translateY(-2px);
}
/* Crédit du footer */
.footer-credit {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  text-align: center;
}
.footer-credit p {
  margin: 0;
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  color: rgba(0, 0, 0, 0.5);
  letter-spacing: 0.5px;
}
.credit-name {
  font-weight: 600;
  color: var(--primary);
  font-style: italic;
}
@keyframes floatIn {
  from { transform: translateY(16px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
@keyframes pulse {
  0%, 100% { box-shadow: inset 0 0 0 8px rgba(255,255,255,0.5), 0 0 20px rgba(166,124,82,0.3); transform: scale(1); }
  50% { box-shadow: inset 0 0 0 10px rgba(255,255,255,0.35), 0 0 30px rgba(166,124,82,0.4); transform: scale(1.02); }
}
@keyframes glowPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.8; }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes floatParticle {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.3; }
  25% { transform: translate(20px, -30px) scale(1.2); opacity: 0.6; }
  50% { transform: translate(-15px, -50px) scale(0.8); opacity: 0.4; }
  75% { transform: translate(30px, -20px) scale(1.1); opacity: 0.5; }
}
@keyframes frameGlow {
  0%, 100% { box-shadow: 0 0 30px rgba(196,160,119,0.2), 0 0 60px rgba(166,124,82,0.1); }
  50% { box-shadow: 0 0 40px rgba(196,160,119,0.3), 0 0 80px rgba(166,124,82,0.15); }
}
@keyframes framePulse {
  0%, 100% { opacity: 0.2; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(1.02); }
}
@keyframes cornerFloat {
  0%, 100% { transform: translate(0, 0) rotate(0deg); opacity: 0.3; }
  33% { transform: translate(5px, -8px) rotate(5deg); opacity: 0.5; }
  66% { transform: translate(-5px, -12px) rotate(-5deg); opacity: 0.4; }
}
@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}
@keyframes ringRotate {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-6px) rotate(2deg); }
  50% { transform: translateY(-8px) rotate(0deg); }
  75% { transform: translateY(-6px) rotate(-2deg); }
}
@keyframes buttonGlow {
  0%, 100% { box-shadow: 0 10px 25px rgba(166,124,82,0.35); }
  50% { box-shadow: 0 10px 30px rgba(166,124,82,0.45), 0 0 20px rgba(196,160,119,0.3); }
}
@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}
@keyframes sparkle {
  0%, 100% { opacity: 0.3; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.2); }
}
/* Optimisations pour mobile */
@media (max-width: 768px) {
  .page-wrapper {
    align-items: flex-start;
    padding: 0.5rem 0 calc(0.75rem + env(safe-area-inset-bottom));
  }
  .invitation-container {
    width: 94%;
    max-width: 94%;
    padding-left: 0;
    padding-right: 0;
  }
  .loader-ring {
    width: 100px;
    height: 100px;
  }
  .loader-text {
    font-size: 24px;
  }
  body.page-bg {
    background-color: #3d2818;
    background-image: url('../img/background.avif');
    background-position: center top;
    background-size: cover;
    background-attachment: scroll;
    padding: 0;
  }
  .page-overlay {
    background:
      linear-gradient(180deg, rgba(255,255,255,0.4) 0%, rgba(255,255,255,0.72) 100%);
  }
  .invitation-card {
    width: 100%;
    padding: 0.25rem;
    border-radius: 14px;
    margin: 0;
  }
  .invitation-section {
    padding: 0.9rem 1rem;
  }
  .invitation-header {
    padding-top: 1rem;
  }
  .quote-text {
    font-size: 0.82rem;
  }
  .names .name-groom,
  .names .name-bride {
    font-size: 1.35rem !important;
  }
  .program-title {
    font-size: 12px;
    padding: 10px 28px;
    letter-spacing: 2px;
  }
  .program-card {
    padding: 0.9rem 1rem;
  }
  .program-event {
    font-size: 1.55rem;
  }
  .contact-btn {
    width: 100%;
    min-height: 48px;
    font-size: 0.95rem;
  }
  .photo-carousel {
    --carousel-width: min(100%, 320px);
    --carousel-height: min(44vh, 400px);
  }
  .gallery-section {
    margin: 0.35rem 0.25rem 0.25rem;
    padding: 0.75rem 0.85rem 1rem;
  }
  .frame {
    inset: -20px;
    border-width: 2px;
    border-radius: 18px;
  }
  .frame::before {
    inset: -12px;
    border-width: 1.5px;
    border-radius: 20px;
  }
  .corner-decoration {
    width: 40px;
    height: 40px;
  }
  .corner-decoration.top-left {
    top: -20px;
    left: -20px;
  }
  .corner-decoration.top-right {
    top: -20px;
    right: -20px;
  }
  .corner-decoration.bottom-left {
    bottom: -20px;
    left: -20px;
  }
  .corner-decoration.bottom-right {
    bottom: -20px;
    right: -20px;
  }
  .monogram {
    width: 120px;
    height: 120px;
    font-size: 40px;
    margin-bottom: 24px;
  }
  h1 {
    font-size: 42px;
    margin-bottom: 8px;
  }
  h2 {
    font-size: 20px;
    margin: 8px 0 28px;
    letter-spacing: 2px;
  }
  .names {
    margin: 32px 0 36px;
    gap: 12px;
  }
  .names span {
    font-size: 34px;
    letter-spacing: 0.8px;
  }
  .separator {
    font-size: 16px;
    letter-spacing: 8px;
  }
  .details {
    font-size: 14px;
    line-height: 1.7;
    margin: 24px 0 22px;
  }
  .date {
    margin: 32px auto 36px;
    padding: 14px 24px;
    font-size: 22px;
    border-radius: 12px;
    margin: 24px auto;
  }
  .date::before,
  .date::after {
    font-size: 14px;
  }
  .cta {
    margin-top: 22px;
  }
  .cta a {
    padding: 14px 28px;
    font-size: 15px;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .program {
    margin-top: 36px;
    padding-top: 28px;
  }
  .program h3 {
    font-size: 20px;
    margin-bottom: 16px;
  }
  .info-bubble {
    font-size: 11px;
    padding: 8px 12px;
    margin: -6px 0 16px;
  }
  .info-bubble svg {
    width: 14px;
    height: 14px;
  }
  .quote-section {
    margin: 20px 0 32px;
    padding: 16px;
  }
  .quote-text {
    font-size: 14px;
  }
  .invocation {
    margin: 32px 0;
    padding: 14px;
  }
  .arabic-text {
    font-size: 16px;
  }
  .translation {
    font-size: 12px;
  }
  .family-name {
    font-size: 20px;
  }
  .separator-large {
    font-size: 40px;
  }
  .invitation-message {
    margin: 36px 0 32px;
    font-size: 16px;
    padding: 14px;
  }
  .program-item {
    grid-template-columns: 44px 1fr;
    gap: 12px;
    padding: 12px 0;
    align-items: start;
  }
  .program-item .icon {
    margin-top: 2px;
  }
  .icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
  }
  .icon svg {
    width: 24px;
    height: 24px;
  }
  .mosque-icon,
  .reception-icon,
  .dance-icon {
    width: 48px;
    height: 48px;
  }
  .text .label {
    font-size: 15px;
    line-height: 1.4;
    margin-bottom: 3px;
  }
  .text .time {
    font-size: 13px;
    margin-bottom: 6px;
  }
  .actions {
    gap: 8px;
    margin-top: 6px;
  }
  .program-actions {
    gap: 0.55rem;
  }
  .program-actions .icon-btn {
    height: 44px;
    min-height: 44px;
  }
  .rings-showcase {
    width: 80px;
    height: 80px;
  }
  .names .rings {
    width: 68px;
  }
  footer {
    font-size: 12px;
    margin-top: 28px;
    line-height: 1.6;
  }
  .contact-buttons {
    gap: 10px;
    margin-top: 20px;
  }
  .contact-btn {
    padding: 10px 16px;
    font-size: 13px;
    min-height: 44px;
  }
  .contact-btn svg {
    width: 18px;
    height: 18px;
  }
  .footer-credit {
    margin-top: 28px;
    padding-top: 20px;
  }
  .footer-credit p {
    font-size: 10px;
  }
  .particle {
    width: 3px;
    height: 3px;
  }
}
@media (max-width: 480px) {
  .loader-ring {
    width: 80px;
    height: 80px;
  }
  .loader-text {
    font-size: 20px;
  }
  body {
    padding: 8px;
  }
  .invitation-card {
    padding: 32px 20px 38px;
    border-radius: 14px;
  }
  .frame {
    inset: -16px;
    border-radius: 16px;
  }
  .monogram {
    width: 100px;
    height: 100px;
    font-size: 36px;
  }
  h1 {
    font-size: 36px;
  }
  h2 {
    font-size: 18px;
  }
  .names span {
    font-size: 28px;
  }
  .separator {
    font-size: 14px;
  }
  .details {
    font-size: 13px;
  }
  .date {
    padding: 12px 20px;
    font-size: 20px;
  }
  .date::before,
  .date::after {
    font-size: 12px;
  }
  .program-item {
    grid-template-columns: 40px 1fr;
    gap: 10px;
  }
  .icon {
    width: 40px;
    height: 40px;
  }
  .icon svg {
    width: 20px;
    height: 20px;
  }
  .text .label {
    font-size: 14px;
  }
  .actions {
    flex-direction: column;
    width: 100%;
  }
  .icon-btn {
    /* width: 100%; */
    height: 40px;
  }
  .rings-showcase {
    width: 72px;
    height: 72px;
  }
  .names .rings {
    width: 60px;
  }
  .contact-buttons {
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }
  .contact-btn {
    width: 100%;
    justify-content: center;
    padding: 12px 16px;
  }
  .footer-credit {
    margin-top: 24px;
    padding-top: 18px;
  }
  .footer-credit p {
    font-size: 9px;
  }
  .info-bubble {
    font-size: 10px;
    padding: 6px 10px;
    margin: -4px 0 14px;
  }
  .info-bubble svg {
    width: 12px;
    height: 12px;
  }
  .quote-section {
    margin: 16px 0 28px;
    padding: 12px;
  }
  .quote-text {
    font-size: 13px;
  }
  .invocation {
    margin: 28px 0;
    padding: 12px;
  }
  .arabic-text {
    font-size: 14px;
  }
  .translation {
    font-size: 11px;
  }
  .family-name {
    font-size: 18px;
  }
  .separator-large {
    font-size: 36px;
  }
  .invitation-message {
    margin: 28px 0 32px;
    font-size: 14px;
    padding: 12px;
  }
}
@media (max-width: 360px) {
  .invitation-card {
    padding: 28px 16px 34px;
  }
  h1 {
    font-size: 32px;
  }
  h2 {
    font-size: 16px;
  }
  .names span {
    font-size: 26px;
  }
  .separator {
    font-size: 12px;
  }
  .monogram {
    width: 90px;
    height: 90px;
    font-size: 32px;
  }
  .date {
    font-size: 18px;
    padding: 10px 16px;
  }
  .contact-btn {
    font-size: 12px;
    padding: 10px 14px;
  }
  .contact-btn svg {
    width: 16px;
    height: 16px;
  }
}
/* Section galerie — carrousel personnalisé (scroll vertical préservé) */
.gallery-title {
  margin: 0 auto 0.85rem;
  text-align: center;
  font-family: 'Freestyle Script', cursive;
  font-size: 1.85rem;
  font-weight: normal;
  color: var(--teal);
  line-height: 1.2;
  animation: fadeUp 0.9s ease-out both;
}
.photo-carousel {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  position: relative;
  --carousel-width: min(100%, 440px);
  --carousel-height: min(52vh, 480px);
  touch-action: pan-y pinch-zoom;
}
.photo-carousel-track {
  position: relative;
  width: var(--carousel-width);
  height: var(--carousel-height);
  margin: 0 auto;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid rgba(201, 162, 39, 0.45);
  box-shadow:
    0 12px 36px rgba(0, 0, 0, 0.16),
    inset 0 0 0 1px rgba(255, 255, 255, 0.15);
  background: linear-gradient(165deg, #2a2420 0%, #1a1816 100%);
  contain: layout style;
}
.photo-carousel-slide {
  position: absolute;
  inset: 0;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.9s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.9s;
  z-index: 0;
}
.photo-carousel-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}
.photo-carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  display: block;
  transform: none;
  pointer-events: none;
}
.photo-carousel-slide.active img {
  animation: none;
}
.photo-carousel-dots {
  position: absolute;
  bottom: 0.75rem;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 0.45rem;
  z-index: 3;
  padding: 0 0.5rem;
}
.photo-carousel-dots button {
  width: 8px;
  height: 8px;
  padding: 0;
  border-radius: 50%;
  border: 1px solid rgba(201, 162, 39, 0.65);
  background: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  transition: transform 0.25s ease, background 0.25s ease, width 0.25s ease;
  touch-action: manipulation;
}
.photo-carousel-dots button.active {
  background: var(--gold);
  transform: scale(1.25);
  box-shadow: 0 0 8px rgba(201, 162, 39, 0.6);
}
.photo-carousel-prev,
.photo-carousel-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 4;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88);
  color: var(--teal-dark);
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.photo-carousel-prev { left: 0.5rem; }
.photo-carousel-next { right: 0.5rem; }
.photo-carousel-prev:hover,
.photo-carousel-next:hover {
  background: #fff;
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
}
.photo-carousel-prev:active,
.photo-carousel-next:active {
  transform: translateY(-50%) scale(0.96);
}
@media (max-width: 768px) {
  .photo-carousel {
    --carousel-width: min(100%, 360px);
    --carousel-height: min(46vh, 420px);
  }
}
@media (max-width: 480px) {
  .invitation-section {
    padding: 0.85rem 1rem;
  }
  .photo-carousel {
    --carousel-width: min(100%, 300px);
    --carousel-height: min(42vh, 380px);
  }
  .gallery-title {
    font-size: 1.55rem;
  }
  .photo-carousel-prev,
  .photo-carousel-next {
    width: 34px;
    height: 34px;
  }
}
/* ─── Pétales de rose (canvas) ─── */
.petal-canvas {
  position: fixed;
  inset: 0;
  z-index: 99998;
  pointer-events: none;
  transition: opacity 0.8s ease;
}
.petal-canvas.is-done {
  opacity: 0;
}

/* ─── Bokeh ambiant ─── */
.ambient-bokeh {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.ambient-bokeh span {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 180, 0.5) 0%, transparent 70%);
  animation: bokehFloat 12s ease-in-out infinite;
}
.ambient-bokeh span:nth-child(1) { width: 120px; height: 120px; top: 10%; left: 8%; animation-delay: 0s; }
.ambient-bokeh span:nth-child(2) { width: 80px; height: 80px; top: 60%; left: 5%; animation-delay: 2s; opacity: 0.6; }
.ambient-bokeh span:nth-child(3) { width: 100px; height: 100px; top: 25%; right: 10%; animation-delay: 4s; }
.ambient-bokeh span:nth-child(4) { width: 60px; height: 60px; bottom: 20%; right: 15%; animation-delay: 1s; opacity: 0.5; }
.ambient-bokeh span:nth-child(5) { width: 140px; height: 140px; bottom: 10%; left: 30%; animation-delay: 3s; opacity: 0.4; }
.ambient-bokeh span:nth-child(6) { width: 50px; height: 50px; top: 45%; left: 45%; animation-delay: 5s; background: radial-gradient(circle, rgba(244, 194, 194, 0.45) 0%, transparent 70%); }
@keyframes bokehFloat {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.35; }
  33% { transform: translate(15px, -20px) scale(1.1); opacity: 0.55; }
  66% { transform: translate(-10px, -35px) scale(0.95); opacity: 0.4; }
}

/* ─── Ornements de carte ─── */
.card-ornament {
  position: absolute;
  width: 48px;
  height: 48px;
  z-index: 2;
  pointer-events: none;
  opacity: 0.7;
  background:
    linear-gradient(135deg, var(--gold) 2px, transparent 2px) 0 0 / 18px 18px no-repeat,
    linear-gradient(225deg, var(--gold) 2px, transparent 2px) 100% 0 / 18px 18px no-repeat,
    linear-gradient(315deg, var(--gold) 2px, transparent 2px) 100% 100% / 18px 18px no-repeat,
    linear-gradient(45deg, var(--gold) 2px, transparent 2px) 0 100% / 18px 18px no-repeat;
}
.card-ornament--tl { top: 4px; left: 4px; }
.card-ornament--tr { top: 4px; right: 4px; transform: scaleX(-1); }
.card-ornament--bl { bottom: 4px; left: 4px; transform: scaleY(-1); }
.card-ornament--br { bottom: 4px; right: 4px; transform: scale(-1); }

/* ─── Hero banner ─── */
.hero-banner {
  position: relative;
  text-align: center;
  padding: 1.5rem 1.25rem 1.25rem;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(201, 89, 109, 0.1) 0%, transparent 60%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, transparent 100%);
}
.hero-banner-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hero-banner-bg .rings-showcase {
  width: min(320px, 85%);
  height: min(320px, 55vw);
  margin: 0;
  opacity: 0.22;
  transform: translateY(8%);
}
.hero-banner-bg .rings {
  width: 100%;
  height: auto;
  max-width: 300px;
  filter: drop-shadow(0 8px 24px rgba(201, 162, 39, 0.35));
  animation: ringFloat 4s ease-in-out infinite;
}
.hero-banner-bg .rings-glow {
  opacity: 0.6;
}
.hero-banner-bg .rings-sparkle {
  opacity: 0;
  animation: none;
}
.hero-banner-content {
  position: relative;
  z-index: 1;
}
.hero-banner-content .hero-title,
.hero-banner-content .hero-date,
.hero-banner-content .countdown {
  position: relative;
  z-index: 2;
}
.hero-date {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.hero-banner .countdown {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(255, 248, 245, 0.9));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.hero-bismillah {
  font-family: 'Cormorant Garamond', 'Playfair Display', serif;
  font-size: clamp(0.78rem, 2.5vw, 0.92rem);
  font-style: italic;
  color: var(--rose-deep);
  margin: 0 0 0.65rem;
  letter-spacing: 0.5px;
  line-height: 1.5;
}
.hero-families {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(0.65rem, 2vw, 0.75rem);
  font-weight: 600;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: rgba(0, 0, 0, 0.55);
  margin: 0 0 0.5rem;
}
.hero-families span {
  color: var(--gold-dark);
}
.hero-invite {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(0.88rem, 2.8vw, 1rem);
  font-style: italic;
  color: rgba(0, 0, 0, 0.62);
  margin: 0 0 0.75rem;
  line-height: 1.55;
  max-width: 28rem;
  margin-left: auto;
  margin-right: auto;
}
.hero-title {
  margin: 0.5rem auto 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 1.1rem 1.35rem;
  max-width: 22rem;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 18px;
  box-shadow:
    0 10px 36px rgba(139, 41, 66, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}
.hero-name {
  /* font-family: 'Playfair Display', serif; */
  font-family: Great Vibes;
  font-weight: 700;
  font-size: clamp(1.45rem, 5.5vw, 2rem);
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: #6b4f0a;
  background: none;
  -webkit-background-clip: unset;
  background-clip: unset;
  -webkit-text-fill-color: #6b4f0a;
  animation: none;
  line-height: 1.25;
  text-shadow: none;
}
.hero-amp {
  font-family: 'Freestyle Script', cursive;
  font-size: clamp(1.85rem, 6vw, 2.5rem);
  color: var(--rose-deep);
  line-height: 1;
  margin: 0.05rem 0;
  text-shadow: none;
}
@keyframes goldShimmer {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}
.hero-date {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 0.75rem;
  margin: 0.75rem auto 0;
  padding: 0.6rem 1.25rem;
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 999px;
  box-shadow: 0 4px 20px rgba(139, 41, 66, 0.08);
  max-width: fit-content;
}
.hero-date-line {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--rose-deep);
}
.hero-date-dot {
  display: inline-flex;
  align-items: center;
  color: var(--green-mid);
}
.hero-date-dot svg {
  width: 14px;
  height: 14px;
}

.hero-banner .countdown {
  margin-top: 1rem;
  border-color: rgba(201, 89, 109, 0.25);
}
.hero-banner .countdown-num {
  color: var(--rose-deep);
}

/* ─── Séparateurs rose ─── */
.section-divider--rose {
  color: var(--rose);
  opacity: 0.65;
}
.section-divider--rose::before,
.section-divider--rose::after {
  background: linear-gradient(90deg, transparent, rgba(201, 89, 109, 0.35), transparent);
}

/* ─── Galerie ─── */
.gallery-section {
  border-color: rgba(201, 89, 109, 0.2);
  background: rgba(255, 252, 250, 0.92);
}
.gallery-title {
  color: var(--rose-deep);
}

/* ─── Cartes programme ─── */
.program-card {
  position: relative;
  padding-top: 1.15rem;
}
.program-card-icon {
  position: absolute;
  top: -14px;
  right: 14px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  background: #fff;
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}
.program-title {
  background: linear-gradient(135deg, var(--rose-deep), var(--rose), #a03050);
  box-shadow: 0 6px 24px rgba(139, 41, 66, 0.35);
}
.btn-primary {
  --bs-btn-bg: var(--rose-deep);
  --bs-btn-border-color: var(--rose-deep);
  --bs-btn-hover-bg: #6d2035;
  --bs-btn-hover-border-color: #6d2035;
  --bs-btn-active-bg: #6d2035;
  --bs-btn-active-border-color: #6d2035;
}
.credit-name {
  color: var(--rose-deep);
}
.quote-block .quote-section {
  border-color: rgba(201, 89, 109, 0.15);
  background: rgba(255, 255, 255, 0.7);
}

@media (max-width: 768px) {
  .hero-banner { padding: 1.25rem 1rem 1rem; }
  .hero-banner-bg .rings-showcase {
    width: min(260px, 90%);
    opacity: 0.18;
  }
  .card-ornament { width: 36px; height: 36px; }
}
@media (max-width: 480px) {
  .hero-name { letter-spacing: 2px; }
  .hero-date { padding: 0.5rem 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  [data-reveal] {
    opacity: 1;
    transform: none;
  }
  .photo-carousel-slide img {
    animation: none !important;
    transform: none !important;
  }
}
/* Amélioration du touch sur mobile */
@media (hover: none) and (pointer: coarse) {
  .cta a,
  .icon-btn,
  .program-item {
    -webkit-tap-highlight-color: rgba(201,162,39,0.2);
  }
  .program-item:active {
    transform: translateX(2px);
    background: rgba(201,162,39,0.05);
  }
  .cta a:active {
    transform: translateY(0);
  }
  .icon-btn:active {
    transform: translateY(0);
  }
}
/* Styles pour l'impression PDF */
@media print {
  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
  }
  body {
    background: white !important;
    padding: 0 !important;
  }
  .loader,
  .particles,
  .petal-canvas,
  .ambient-bokeh,
  .floating-petals {
    display: none !important;
  }
  .invitation-card {
    box-shadow: none !important;
    border: none !important;
    margin: 0 !important;
    padding: 20px !important;
  }
  a {
    color: inherit !important;
    text-decoration: underline !important;
  }
  .icon-btn,
  .contact-btn {
    border: 1px solid #ccc !important;
    page-break-inside: avoid;
  }
  @page {
    margin: 0.5cm;
    size: A4;
  }
}

/* Mise en page tactile : ces règles sont placées en dernier pour neutraliser
   les anciens styles mobile qui se chevauchaient. */
@media (max-width: 768px) {
  html,
  body {
    width: 100%;
    min-height: 100%;
    overflow-x: clip;
    overscroll-behavior-x: none;
  }

  body.page-bg {
    background-attachment: scroll;
  }

  .page-wrapper {
    display: block;
    min-height: auto;
    padding: max(0.5rem, env(safe-area-inset-top)) 0 calc(1rem + env(safe-area-inset-bottom));
  }

  .invitation-container {
    width: min(100% - 1rem, 42rem);
    max-width: none;
  }

  .invitation-card {
    overflow: hidden;
    border-radius: 16px;
  }

  .invitation-section {
    padding: 1rem;
  }

  .hero-banner {
    min-height: 0;
  }

  .hero-date {
    width: 100%;
    border-radius: 14px;
    padding: 0.65rem 0.75rem;
  }

  .hero-date-dot {
    display: none;
  }

  .countdown {
    gap: 0.25rem;
    padding: 0.7rem 0.35rem;
  }

  .countdown-item {
    min-width: 0;
    flex: 1 1 3.6rem;
  }

  .countdown-sep {
    display: none;
  }

  .program-card {
    padding: 1rem;
  }

  .program-day {
    max-width: 100%;
    white-space: normal;
    line-height: 1.4;
  }

  .program-event {
    font-size: clamp(1.25rem, 7vw, 1.55rem);
  }

  .program-actions {
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
  }

  .program-actions .icon-btn {
    height: 50px;
    min-height: 50px;
    border-radius: 14px;
  }

  .contact-row {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 0.65rem !important;
    margin-top: 0.9rem;
  }

  .contact-btn {
    width: 100%;
    min-height: 50px;
    padding: 0.7rem 1rem;
    font-size: 0.95rem;
  }

  /* Les décorations fixes sont jolies mais coûteuses au défilement tactile. */
  .ambient-bokeh,
  .floating-petals {
    display: none;
  }
}

@media (min-width: 576px) and (max-width: 768px) {
  .contact-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .contact-btn {
    font-size: 0.82rem;
    padding-inline: 0.5rem;
  }
}

