/* =====================================================
   ALEXIA JUAREZ — Landing page
   Design tokens
   Palette   : blanc / beige clair / noir chaud / or discret
   Display   : Fraunces (serif romantique, chaleureuse)
   Body/UI   : Manrope (sans-serif claire, moderne)
   Signature : anneau doré (ring) + waveform — "une chanson pour l'alliance"
   ===================================================== */

:root {
  --white:        #FFFFFF;
  --cream:        #FAF5EC;
  --cream-deep:   #F1E7D6;
  --black:        #1B1815;
  --ink:          #2B2620;
  --ink-soft:     #56504A;
  --muted:        #8C8477;
  --gold:         #C6A567;
  --gold-light:   #E7D9B7;
  --gold-dark:    #A5813F;

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --radius-s: 10px;
  --radius-m: 18px;
  --radius-l: 28px;

  --shadow-soft: 0 20px 60px -25px rgba(27, 24, 21, 0.18);
  --shadow-softer: 0 10px 30px -15px rgba(27, 24, 21, 0.12);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --container-w: 1120px;
  --container-narrow: 720px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
button { font: inherit; }

:focus-visible {
  outline: 2px solid var(--gold-dark);
  outline-offset: 4px;
  border-radius: 4px;
}

.container {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 32px;
}
.container--narrow {
  max-width: var(--container-narrow);
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .reveal.is-visible {
    opacity: 1;
    transform: none;
    transition: none;
  }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

/* ---------- Eyebrow labels ---------- */
.eyebrow {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 18px;
}
.eyebrow--light { color: var(--gold-light); }

/* =====================================================
   Ring progress — signature element, top-right corner
   ===================================================== */
.ring-progress {
  position: fixed;
  top: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  z-index: 50;
  opacity: 0.85;
  pointer-events: none;
}
.ring-progress svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-progress__track {
  fill: none;
  stroke: rgba(27,24,21,0.08);
  stroke-width: 1.4;
}
.ring-progress__fill {
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 106.8;
  stroke-dashoffset: 106.8;
  transition: stroke-dashoffset 0.15s linear;
}
@media (max-width: 640px) {
  .ring-progress { top: 16px; right: 16px; width: 30px; height: 30px; }
}

/* =====================================================
   HERO
   ===================================================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 140px 24px 100px;
  text-align: center;
  overflow: hidden;
}

.hero__glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 50% at 50% 8%, rgba(198,165,103,0.16), transparent 70%),
    radial-gradient(80% 60% at 50% 100%, var(--cream-deep), var(--cream) 60%);
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 760px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.avatar {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  padding: 4px;
  margin-bottom: 28px;
  background: conic-gradient(from 180deg, var(--gold-light), var(--gold), var(--gold-light));
  box-shadow: var(--shadow-softer);
}
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--cream);
  background: var(--cream-deep);
}

.hero__title {
  font-family: var(--font-display);
  font-optical-sizing: auto;
  font-weight: 500;
  font-size: clamp(2.1rem, 5.2vw, 3.6rem);
  line-height: 1.18;
  letter-spacing: -0.01em;
  color: var(--black);
  max-width: 15ch;
  margin-bottom: 22px;
}

.hero__subtitle {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  color: var(--ink-soft);
  max-width: 46ch;
  margin-bottom: 40px;
}

/* Waveform signature */
.waveform {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 28px;
  margin-bottom: 28px;
}
.waveform span {
  width: 3px;
  border-radius: 3px;
  background: var(--gold);
  opacity: 0.75;
  animation: wave 1.8s ease-in-out infinite;
}
.waveform span:nth-child(1){ height: 30%; animation-delay: -1.2s; }
.waveform span:nth-child(2){ height: 60%; animation-delay: -0.9s; }
.waveform span:nth-child(3){ height: 100%; animation-delay: -1.5s; }
.waveform span:nth-child(4){ height: 45%; animation-delay: -0.3s; }
.waveform span:nth-child(5){ height: 80%; animation-delay: -1.8s; }
.waveform span:nth-child(6){ height: 35%; animation-delay: -0.6s; }
.waveform span:nth-child(7){ height: 90%; animation-delay: -1.1s; }
.waveform span:nth-child(8){ height: 50%; animation-delay: -0.4s; }
.waveform span:nth-child(9){ height: 100%; animation-delay: -1.6s; }
.waveform span:nth-child(10){ height: 40%; animation-delay: -0.8s; }
.waveform span:nth-child(11){ height: 70%; animation-delay: -1.3s; }
.waveform span:nth-child(12){ height: 30%; animation-delay: -0.2s; }
.waveform span:nth-child(13){ height: 55%; animation-delay: -1.0s; }

@keyframes wave {
  0%, 100% { transform: scaleY(0.5); opacity: 0.55; }
  50% { transform: scaleY(1); opacity: 0.9; }
}

/* =====================================================
   PROPOSITION DE DON — sous les notes de musique animées
   ===================================================== */
.hero-donation {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-bottom: 44px;
}
.hero-donation__text {
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.hero-donation__btn {
  padding: 13px 28px;
  font-size: 0.9rem;
}

.hero__actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.scroll-cue {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  width: 22px;
  height: 36px;
  border: 1.4px solid rgba(27,24,21,0.25);
  border-radius: 20px;
  z-index: 1;
}
.scroll-cue span {
  position: absolute;
  top: 6px; left: 50%;
  width: 4px; height: 4px;
  margin-left: -2px;
  background: var(--gold-dark);
  border-radius: 50%;
  animation: scrollcue 1.8s ease-in-out infinite;
}
@keyframes scrollcue {
  0% { top: 6px; opacity: 1; }
  70% { opacity: 0.4; }
  100% { top: 20px; opacity: 0; }
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 15px 30px;
  border-radius: 100px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease), background 0.3s ease, color 0.3s ease;
  will-change: transform;
}
.btn:hover { transform: translateY(-3px); }
.btn:active { transform: translateY(-1px); }

.btn--primary {
  background: var(--black);
  color: var(--white);
  box-shadow: var(--shadow-softer);
}
.btn--primary:hover { box-shadow: var(--shadow-soft); background: #2A241E; }

.btn--ghost {
  background: transparent;
  color: var(--black);
  border: 1.4px solid rgba(27,24,21,0.18);
}
.btn--ghost:hover { border-color: var(--gold-dark); background: rgba(198,165,103,0.08); }

.btn--outline {
  background: transparent;
  color: var(--black);
  border: 1.4px solid var(--gold);
}
.btn--outline:hover { background: var(--gold); color: var(--white); }

.btn--gold {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--black);
  box-shadow: 0 14px 34px -16px rgba(198,165,103,0.65);
}
.btn--gold:hover { box-shadow: 0 18px 40px -14px rgba(198,165,103,0.8); }

.btn--large {
  padding: 18px 40px;
  font-size: 1rem;
}

/* =====================================================
   SECTIONS — shared
   ===================================================== */
.section {
  padding: 120px 0;
  position: relative;
}
.section__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  color: var(--black);
  max-width: 18ch;
  margin-bottom: 18px;
}
.section__lead {
  color: var(--ink-soft);
  max-width: 50ch;
  font-size: 1.05rem;
  margin-bottom: 56px;
}

.divider {
  display: flex;
  justify-content: center;
  padding: 8px 0;
}
.divider svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.4;
  opacity: 0.6;
}

/* =====================================================
   TIKTOK SECTION
   ===================================================== */
.section--tiktok { background: var(--cream); text-align: center; }
.section--tiktok .section__title {
  margin-left: auto;
  margin-right: auto;
  width: fit-content;
  text-align: center;
}
.section--tiktok .section__lead { margin-left: auto; margin-right: auto; }

.tiktok-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  justify-items: center;
  margin-bottom: 48px;
}
.tiktok-grid > * { width: 100%; max-width: 325px; }

.tiktok-player {
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-m);
  overflow: hidden;
  box-shadow: var(--shadow-softer);
  background: var(--cream-deep);
}
.tiktok-player iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.tiktok-cta { display: flex; justify-content: center; }

.tiktok-note {
  font-size: 0.85rem;
  color: var(--muted);
  margin: -24px 0 40px;
}

/* =====================================================
   HISTOIRE
   ===================================================== */
.section--story { background: var(--white); }

.story {
  display: flex;
  flex-direction: column;
  gap: 22px;
  color: var(--ink-soft);
  font-size: 1.05rem;
}
.story p { max-width: 62ch; }
.story__lead {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.4vw, 1.6rem);
  color: var(--black);
  font-weight: 500;
  line-height: 1.5;
}
.story__signature {
  margin-top: 18px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.2rem;
  color: var(--black);
}
.story__name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--gold-dark);
}

.section--story .card {
  margin-top: 64px;
}

.story__actions {
  margin-top: 40px;
}

/* =====================================================
   CARDS — download & donation
   ===================================================== */
.section--download { background: var(--cream); }
.section--donation { background: var(--cream); padding-top: 0; }

.card {
  background: var(--white);
  border-radius: var(--radius-l);
  padding: clamp(36px, 6vw, 64px);
  text-align: center;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(198,165,103,0.16);
}
.card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  color: var(--black);
  margin-bottom: 16px;
}
.card__text {
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 auto 34px;
}

.card--dark {
  background: var(--black);
  border: 1px solid rgba(198,165,103,0.25);
}
.card__title--light { color: var(--white); }
.card__text--light { color: rgba(255,255,255,0.72); }

.tipeee-widget {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

/* =====================================================
   POP-UP DE DON (après téléchargement)
   ===================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(27, 24, 21, 0.55);
  backdrop-filter: blur(3px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 200;
}
.modal-overlay.is-open { display: flex; }

.modal-card {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-l);
  padding: clamp(32px, 5vw, 48px);
  max-width: 440px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-soft);
  animation: modal-in 0.35s var(--ease);
}
@keyframes modal-in {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: color 0.2s ease, background 0.2s ease;
}
.modal-close:hover { color: var(--black); background: var(--cream); }

.modal-card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.3rem, 2.6vw, 1.6rem);
  color: var(--black);
  margin-bottom: 14px;
}
.modal-card__text {
  color: var(--ink-soft);
  font-size: 0.98rem;
  margin-bottom: 28px;
}

.modal-skip {
  display: block;
  margin: 16px auto 0;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.85rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.modal-skip:hover { color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  .modal-card { animation: none; }
}

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
  background: var(--black);
  color: rgba(255,255,255,0.7);
  padding: 56px 0 40px;
}
.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}
.footer__brand {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--white);
}
.footer__links {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  justify-content: center;
}
.footer__links a {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: rgba(255,255,255,0.72);
  position: relative;
  padding-bottom: 4px;
  transition: color 0.3s ease;
}
.footer__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0%;
  height: 1px;
  background: var(--gold);
  transition: width 0.35s var(--ease);
}
.footer__links a:hover { color: var(--white); }
.footer__links a:hover::after { width: 100%; }

.footer__copy {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
.br-desktop { display: inline; }

@media (max-width: 640px) {
  .br-desktop { display: none; }
  .hero { padding: 120px 20px 80px; }
  .section { padding: 84px 0; }
  .container { padding: 0 22px; }
  .hero__actions { flex-direction: column; width: 100%; }
  .hero__actions .btn { width: 100%; }
  .card { padding: 32px 24px; }
}

/* =====================================================
   LIEN RETOUR VERS LE HUB
   ===================================================== */
.hub-back {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 50;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(4px);
  padding: 8px 16px;
  border-radius: 100px;
  border: 1px solid rgba(27,24,21,0.08);
  transition: color 0.3s ease, border-color 0.3s ease;
}
.hub-back:hover { color: var(--gold-dark); border-color: var(--gold-dark); }
@media (max-width: 640px) {
  .hub-back { top: 16px; left: 16px; font-size: 0.78rem; padding: 6px 12px; }
}

/* =====================================================
   HUB — page d'accueil (choix de version)
   ===================================================== */
.hub-hero { min-height: 72svh; padding: 160px 24px 60px; }
.hero__subtitle {
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 0 40px;
}

.section--hub { padding-top: 20px; padding-bottom: 100px; }

.hub-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: stretch;
  gap: 32px;
  max-width: 980px;
  margin: 0 auto;
}
@media (max-width: 720px) {
  .hub-grid { grid-template-columns: 1fr; max-width: 480px; }
}

.hub-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--white);
  border-radius: var(--radius-l);
  padding: clamp(36px, 5vw, 52px) clamp(28px, 4vw, 40px);
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(198,165,103,0.16);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}
.hub-card:hover { transform: translateY(-6px); box-shadow: 0 26px 70px -28px rgba(27,24,21,0.24); }

.hub-card--dark {
  background: var(--black);
  border: 1px solid rgba(198,165,103,0.25);
}

.hub-card__eyebrow {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 14px;
}
.hub-card__eyebrow--light { color: var(--gold-light); }

.hub-card__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.3rem, 2.6vw, 1.6rem);
  color: var(--black);
  margin-bottom: 12px;
  line-height: 1.3;
  min-height: 2.6em;
  display: flex;
  align-items: center;
  justify-content: center;
}
.hub-card__title--light { color: var(--white); }

.hub-card__text {
  color: var(--ink-soft);
  margin-bottom: 30px;
  max-width: 34ch;
}
.hub-card__text--light { color: rgba(255,255,255,0.72); }

.hub-card__btn {
  pointer-events: none;
  align-self: center;
  margin-top: auto;
  width: 100%;
  max-width: 280px;
}
