/* ===================================================================
   DESIGN TOKENS — Miamies.ch Redesign
   Source de vérité absolue. Aucune valeur hardcodée ailleurs.
   =================================================================== */

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

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

body {
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

input, button, textarea, select {
  font: inherit;
}

a {
  text-decoration: none;
  color: inherit;
}

ul, ol {
  list-style: none;
}

/* ===== Variables CSS ===== */
:root {
  /* --- Couleurs --- */
  --c-green:          #92C01F;
  --c-green-mid:      #5A8A10;
  --c-green-dark:     #2D4A1A;
  --c-yellow:         #F2A922;
  --c-yellow-light:   #F7C948;
  --c-cream:          #FAF6EE;
  --c-cream-dark:     #F0E9DB;
  --c-brown:          #3B2F20;
  --c-brown-mid:      #6B5D4F;
  --c-brown-light:    #9A8B7A;
  --c-white:          #FFFFFF;
  --c-error:          #D94032;

  /* --- Typographie --- */
  --f-heading:  'Young Serif', Georgia, serif;
  --f-body:     'DM Sans', system-ui, sans-serif;

  --fs-hero:    clamp(3rem, 8vw, 7rem);
  --fs-h1:      clamp(2.25rem, 5vw, 4rem);
  --fs-h2:      clamp(1.75rem, 4vw, 3rem);
  --fs-h3:      clamp(1.25rem, 2.5vw, 1.75rem);
  --fs-body:    clamp(1rem, 1.2vw, 1.125rem);
  --fs-body-lg: clamp(1.125rem, 1.5vw, 1.375rem);
  --fs-small:   clamp(0.8125rem, 1vw, 0.9375rem);
  --fs-caption: 0.75rem;

  --fw-regular:  400;
  --fw-medium:   500;
  --fw-semibold: 600;
  --fw-bold:     700;

  --lh-tight:   1.1;
  --lh-heading: 1.2;
  --lh-body:    1.6;
  --lh-loose:   1.8;

  /* --- Espacements --- */
  --sp-4:   0.25rem;
  --sp-8:   0.5rem;
  --sp-12:  0.75rem;
  --sp-16:  1rem;
  --sp-24:  1.5rem;
  --sp-32:  2rem;
  --sp-48:  3rem;
  --sp-64:  4rem;
  --sp-80:  5rem;
  --sp-96:  6rem;
  --sp-128: 8rem;

  /* --- Layout --- */
  --container-max:    1200px;
  --container-narrow: 800px;
  --gutter:           clamp(1rem, 4vw, 2rem);

  /* --- Rayons --- */
  --r-sm:   8px;
  --r-md:   16px;
  --r-lg:   24px;
  --r-xl:   32px;
  --r-full: 9999px;

  /* --- Ombres --- */
  --shadow-sm:  0 2px 8px rgba(59, 47, 32, 0.06);
  --shadow-md:  0 4px 20px rgba(59, 47, 32, 0.08);
  --shadow-lg:  0 8px 40px rgba(59, 47, 32, 0.12);

  /* --- Transitions --- */
  --ease-out:  cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in:   cubic-bezier(0.55, 0, 1, 0.45);
  --ease-snap: cubic-bezier(0.2, 0, 0, 1);
  --dur-fast:  150ms;
  --dur-base:  300ms;
  --dur-slow:  500ms;
}

/* ===== Composants de base ===== */
body {
  font-family: var(--f-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--c-brown);
  background-color: var(--c-cream);
}

h1, h2, h3, h4 {
  font-family: var(--f-heading);
  font-weight: var(--fw-bold);
  line-height: var(--lh-heading);
  color: var(--c-brown);
}

/* ===== Focus visible ===== */
:focus-visible {
  outline: 3px solid var(--c-yellow);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

/* ===== Classes GSAP initiales ===== */
.gs-hidden {
  opacity: 0;
  visibility: hidden;
}

.gs-reveal {
  opacity: 0;
  transform: translateY(30px);
}

.gs-reveal-scale {
  opacity: 0;
  transform: scale(0.85) rotate(2deg);
}

/* ===== Prefers reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .gs-hidden,
  .gs-reveal,
  .gs-reveal-scale {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
}
