/* ============================================================
   GuideduFoyer — Base : reset, typographie, langage graphique
   ============================================================ */

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

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

body {
  margin: 0;
  font-family: var(--gdf-font-body);
  font-size: var(--gdf-text-base);
  line-height: var(--gdf-leading-body);
  color: var(--gdf-ink);
  background: var(--gdf-bg);
  font-feature-settings: "liga" 1;
  text-rendering: optimizeLegibility;
}

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

/* ---------- Titres ---------- */
h1, h2, h3, h4 {
  font-family: var(--gdf-font-display);
  color: var(--gdf-ink);
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: var(--gdf-text-h1); line-height: var(--gdf-leading-tight); font-weight: var(--gdf-weight-display); letter-spacing: -0.01em; }
h2 { font-size: var(--gdf-text-h2); line-height: var(--gdf-leading-snug); font-weight: var(--gdf-weight-bold); letter-spacing: -0.005em; }
h3 { font-size: var(--gdf-text-h3); line-height: var(--gdf-leading-snug); font-weight: var(--gdf-weight-bold); }
h4 { font-size: var(--gdf-text-h4); line-height: var(--gdf-leading-snug); font-weight: var(--gdf-weight-bold); }

p { margin: 0; text-wrap: pretty; }

a {
  color: var(--gdf-accent-deep);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  transition: color var(--gdf-duration-fast) var(--gdf-ease);
}
a:hover { color: var(--gdf-ink); }

a:focus-visible, button:focus-visible, input:focus-visible,
textarea:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid var(--gdf-accent);
  outline-offset: 2px;
  border-radius: 2px;
}

::selection { background: var(--gdf-accent-soft); }

/* ---------- Utilitaires typographiques ---------- */
.u-lead { font-size: var(--gdf-text-xl); line-height: 1.5; color: var(--gdf-ink-soft); }
.u-meta { font-size: var(--gdf-text-sm); color: var(--gdf-ink-faint); }
.u-small { font-size: var(--gdf-text-sm); }
.u-legal { font-size: var(--gdf-text-xs); color: var(--gdf-ink-faint); line-height: 1.55; }

/* Kicker — surtitre éditorial */
.u-kicker {
  font-family: var(--gdf-font-body);
  font-size: var(--gdf-text-sm);
  font-weight: var(--gdf-weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--gdf-accent-deep);
}

/* ---------- Langage graphique ---------- */

/* Coup de marqueur — surlignage signature */
.gdf-marker {
  background-image: linear-gradient(
    100deg,
    transparent 0%, var(--gdf-marker-color) 1.8%,
    var(--gdf-marker-color) 97.5%, transparent 100%
  );
  background-size: 100% 0.42em;
  background-position: 0 78%;
  background-repeat: no-repeat;
  padding: 0 0.08em;
  margin: 0 -0.08em;
}

/* Filet éditorial épais (presse) */
.gdf-rule {
  border: 0;
  border-top: var(--gdf-rule-weight) solid var(--gdf-ink);
  width: 56px;
  margin: 0;
}

/* En-tête de rubrique : filet épais + kicker, à la presse conso */
.gdf-rubrique {
  border-top: var(--gdf-rule-weight) solid var(--gdf-ink);
  padding-top: var(--gdf-space-3);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--gdf-space-4);
  flex-wrap: wrap;
}

/* Puce « toit » — listes éditoriales */
.gdf-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--gdf-space-3); }
.gdf-list li { position: relative; padding-left: 28px; }
.gdf-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.42em;
  width: 13px; height: 9px;
  background:
    linear-gradient(to bottom right, transparent 46%, var(--gdf-accent) 47%, var(--gdf-accent) 100%) left/50.5% 100% no-repeat,
    linear-gradient(to bottom left, transparent 46%, var(--gdf-accent) 47%, var(--gdf-accent) 100%) right/50.5% 100% no-repeat;
  -webkit-clip-path: polygon(0 100%, 50% 0, 100% 100%, 79% 100%, 50% 36%, 21% 100%);
          clip-path: polygon(0 100%, 50% 0, 100% 100%, 79% 100%, 50% 36%, 21% 100%);
}

/* ---------- Layout ---------- */
.l-container {
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--gdf-space-5);
}
.l-narrow { max-width: 720px; margin-inline: auto; padding-inline: var(--gdf-space-5); }

.u-visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
