/* ==========================================================
   Reset moderne — Capital Talent Invest
   Inspiré d'Andy Bell + Josh Comeau, adapté à l'accessibilité.
   ========================================================== */

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

* {
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 96px;  /* compense le header sticky */
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

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

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

button {
  background: none;
  border: none;
  cursor: pointer;
  color: inherit;
}

p, h1, h2, h3, h4, h5, h6 {
  overflow-wrap: break-word;
}

ul, ol {
  list-style: none;
}

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

table {
  border-collapse: collapse;
  border-spacing: 0;
}

address {
  font-style: normal;
}

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

/* Focus visible accessible partout */
:focus-visible {
  outline: 3px solid var(--brand-cyan);
  outline-offset: 2px;
  border-radius: var(--radius-xs);
}

/* Cache hors-écran mais accessible aux lecteurs d'écran */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link pour navigation clavier */
.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  background: var(--ink);
  color: white;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  z-index: var(--z-toast);
  font-weight: 600;
  transition: top var(--t-base) var(--ease);
}

.skip-link:focus {
  top: 16px;
}

/* Disable scroll quand nav mobile ou modal ouvert */
body.no-scroll {
  overflow: hidden;
}
