/* ==========================================================================
   MARKIZE — base.css
   Tokens (palette, typographie, espacements), reset, atmosphère globale.
   Chargé sur toutes les pages.
   ========================================================================== */

:root {
  /* Couleurs */
  --bg: #0a0a0a;
  --bg-2: #131013;
  --bg-3: #1a1316;
  --bg-deep: #050304;

  --ink: #f3eee7;
  --ink-soft: #b9b3aa;
  --ink-mute: #6e6862;

  --crimson: #8b0000;
  --crimson-soft: #a31818;
  --crimson-deep: #2a0608;
  --silver: #c0c0c0;
  --gold: #d4af37;
  --gold-soft: #b8962f;

  --line: rgba(192, 192, 192, 0.14);
  --line-strong: rgba(212, 175, 55, 0.35);

  /* Typographies */
  --display: "Cinzel", "Cormorant Garamond", serif;
  --serif: "Cormorant Garamond", serif;
  --sans: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Espacements */
  --gutter: 48px;
  --gutter-mobile: 24px;
  --section-y: 140px;
  --section-y-mobile: 80px;

  /* Transitions */
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  background: var(--bg);
  /* Compense le topbar fixe quand on cible une ancre (#clips, #transparence, etc.) */
  scroll-padding-top: 90px;
}
section[id] { scroll-margin-top: 90px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection { background: var(--crimson); color: var(--ink); }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; }

/* Atmosphère globale : ronces dorées en fond fixe + halos cramoisi/or.
   Couche unique (pseudo-élément fixe) appliquée à TOUTES les pages.
   Le ronces est assombri pour garder le texte lisible par-dessus. */
body::before {
  content: "";
  position: fixed; inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 20% 0%, rgba(139, 0, 0, 0.16), transparent 65%),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(212, 175, 55, 0.06), transparent 60%),
    linear-gradient(180deg, rgba(8, 6, 7, 0.80) 0%, rgba(8, 6, 7, 0.85) 48%, rgba(8, 6, 7, 0.90) 100%),
    url("../assets/ronces-band.jpg") center center / cover no-repeat;
  background-color: var(--bg-deep);
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: "";
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.06 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: 0.5;
  mix-blend-mode: overlay;
  pointer-events: none;
  z-index: 1;
}

/* Tous les contenus restent au-dessus de l'atmosphère */
main, header, footer, .topbar { position: relative; z-index: 2; }

/* Reveal au scroll */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
}
.reveal.in { opacity: 1; transform: translateY(0); }

.reveal-stagger > * {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.reveal-stagger.in > *           { opacity: 1; transform: translateY(0); }
.reveal-stagger.in > *:nth-child(2) { transition-delay: 0.12s; }
.reveal-stagger.in > *:nth-child(3) { transition-delay: 0.24s; }
.reveal-stagger.in > *:nth-child(4) { transition-delay: 0.36s; }

/* Container et sections */
.section {
  padding: var(--section-y) var(--gutter);
  max-width: 1280px;
  margin: 0 auto;
}
@media (max-width: 720px) {
  .section { padding: var(--section-y-mobile) var(--gutter-mobile); }
}

.section-eyebrow {
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.section-eyebrow::before {
  content: "";
  width: 48px;
  height: 1px;
  background: var(--gold);
}

.section-title {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(32px, 5vw, 64px);
  line-height: 1.05;
  letter-spacing: 0.04em;
  margin: 0 0 24px;
}

.section-lede {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(18px, 2vw, 22px);
  color: var(--ink-soft);
  max-width: 680px;
  margin: 0 0 64px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
  .reveal, .reveal-stagger > * { opacity: 1; transform: none; }
}
