/* ============================================
   RESET & NORMALISATION MODERNE
   Baseline propre pour un contrôle total
   ============================================ */

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

/* Suppression des marges par défaut */
body,
h1, h2, h3, h4, h5, h6,
p, blockquote,
figure,
ul, ol, dl,
dd {
  margin: 0;
}

/* Hauteur minimale body */
html,
body {
  height: 100%;
}

/* Amélioration du rendu de texte */
html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Configuration body de base */
body {
  line-height: var(--leading-normal);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-black-soft);
  background-color: var(--color-white);
  overflow-x: hidden;
  overflow-y: auto;
}

/* Listes sans style par défaut */
ul[class],
ol[class] {
  list-style: none;
}

/* Images et médias responsives */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

/* Formulaires héritent des polices */
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* Suppression des styles button par défaut */
button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

/* Liens sans style par défaut */
a {
  text-decoration: none;
  color: inherit;
}

/* Suppression du style fieldset */
fieldset {
  border: none;
  padding: 0;
  margin: 0;
}

/* Reset legend */
legend {
  padding: 0;
}

/* Overflow des longs mots */
p,
h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

/* Amélioration focus pour accessibilité */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
}

/* Suppression du outline pour mouse users */
:focus:not(:focus-visible) {
  outline: none;
}

/* Smooth scroll (peut être désactivé selon préférences utilisateur) */
@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

/* Désactivation animations si demandé */
@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;
  }
}

/* Configuration de base pour le root */
#app {
  isolation: isolate;
}
