/* base.css — Reset + typographie globale */

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-bg);
  color: var(--color-text);
  line-height: 1.65;
  overflow-x: hidden;
}

/* Grain texture subtile — rappel parchemin/bois */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* --- Typographie --- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  font-weight: 700;
  color: var(--color-text);
}

h1 { font-size: clamp(3rem, 7vw, 6rem); line-height: 1.0; }
h2 { font-size: clamp(2rem, 4vw, 3.5rem); line-height: 1.1; }
h3 { font-size: clamp(1.1rem, 2vw, 1.35rem); line-height: 1.3; }
h4 { font-size: clamp(1rem, 1.5vw, 1.1rem); }

p {
  font-size: clamp(0.95rem, 1.5vw, 1.05rem);
  line-height: 1.75;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--t-fast);
}

img, video {
  display: block;
  max-width: 100%;
}

ul, ol {
  list-style: none;
}

button {
  font-family: var(--font-body);
  cursor: pointer;
  border: none;
  background: none;
}

/* --- Accessibilité --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
  .anim-entree,
  .anim-entree-gauche,
  .anim-entree-droite {
    opacity: 1 !important;
    transform: none !important;
  }
}

:focus-visible {
  outline: 2px solid var(--color-gold);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* --- Sélection de texte --- */
::selection {
  background-color: rgba(200,137,10,0.20);
  color: var(--color-text);
}
