/* tribune-pic-petrolier.org — design éditorial (intégration Superdesign draft editorial-v1)
   CSS auto-contenu : polices système uniquement, aucune ressource externe. */

:root {
  --bg: #f7f9fc;
  --surface: #ffffff;
  --ink: #101a2e;
  --ink-soft: #344357;
  --ink-muted: #66768d;
  --ink-faint: #93a4bb;
  --border: #e1e8f1;
  --accent: #1a4fd9;
  --accent-dark: #1b3989;
  --accent-soft: #c1dcfc;
  --font-serif: Georgia, Cambria, "Times New Roman", Times, serif;
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  line-height: 1.7;
}

/* ---------- Header ---------- */

body > header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

body > header nav {
  max-width: 56rem;
  margin: 0 auto;
  padding: 0 1.5rem;
  min-height: 4rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
}

body > header nav a {
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.15s ease;
}

body > header nav a:hover {
  color: var(--accent);
}

body > header nav a.brand {
  margin-right: auto;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-serif);
  font-size: 1.1875rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
}

body > header nav a.brand svg.brand-mark {
  display: block;
  flex-shrink: 0;
}

body > header nav a.brand em {
  font-style: normal;
  color: var(--accent);
}

body > header nav a.brand:hover {
  color: var(--accent-dark);
}

/* ---------- Contenu principal ---------- */

main {
  max-width: 45rem;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

h1 {
  font-family: var(--font-sans);
  font-size: clamp(1.9rem, 4.5vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 1.25rem;
}

h1::after {
  content: "";
  display: block;
  width: 5rem;
  height: 4px;
  margin-top: 1.25rem;
  background: var(--accent);
}

/* chapeau : premier paragraphe après le H1 */
h1 + p {
  font-size: 1.1875rem;
  font-style: italic;
  color: var(--ink-soft);
  line-height: 1.55;
  border-left: 4px solid var(--border);
  padding-left: 1.5rem;
}

h2 {
  font-family: var(--font-sans);
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--ink);
  margin: 2.75rem 0 1rem;
}

p {
  margin: 0 0 1.35rem;
}

main a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: var(--accent-soft);
  text-underline-offset: 4px;
  transition: color 0.15s ease;
}

main a:hover {
  color: var(--accent-dark);
  text-decoration-color: currentColor;
}

main ul {
  padding-left: 1.35rem;
  margin: 0 0 1.35rem;
}

main li {
  margin-bottom: 0.6rem;
}

/* liste d'articles (index) et listes légales : cartes légères */
main > ul,
article + p {
  font-family: inherit;
}

main > ul > li {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  padding: 1rem 1.25rem;
  margin-bottom: 0.85rem;
  list-style: none;
  box-shadow: 0 1px 2px rgb(16 26 46 / 0.04);
}

main > ul {
  padding-left: 0;
}

/* ---------- Questions (accordéons) ---------- */

.questions {
  margin-top: 3.25rem;
  border-top: 3px double var(--border);
  padding-top: 0.5rem;
}

.questions details {
  border-bottom: 1px solid var(--border);
}

.questions summary {
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
  position: relative;
  padding: 0.95rem 2.25rem 0.95rem 0;
}

.questions summary::-webkit-details-marker {
  display: none;
}

summary h3 {
  margin: 0;
  display: inline;
  font: inherit;
  color: inherit;
}

.questions summary::after {
  content: "+";
  position: absolute;
  right: 0.25rem;
  top: 50%;
  translate: 0 -50%;
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 1.35rem;
  color: var(--accent);
  transition: rotate 0.2s ease;
}

.questions details[open] summary::after {
  rotate: 45deg;
}

.questions summary:hover {
  color: var(--accent-dark);
}

.questions details > p {
  margin: 0 0 1.15rem;
  padding-right: 1rem;
  color: var(--ink-soft);
}

@media (prefers-reduced-motion: reduce) {
  .questions summary::after {
    transition: none;
  }
}

/* ---------- Images ---------- */

main img {
  max-width: 100%;
  height: auto;
}

main img.lead {
  display: block;
  width: 100%;
  border-radius: 0.5rem;
  border: 1px solid var(--border);
  margin: 0 0 2rem;
  box-shadow: 0 1px 3px rgb(16 26 46 / 0.08);
}

main > ul > li img {
  display: block;
  width: 100%;
  border-radius: 0.375rem;
  border: 1px solid var(--border);
  margin-bottom: 0.85rem;
}

/* ---------- Footer ---------- */

body > footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  margin-top: 3rem;
  padding: 3rem 1.5rem;
}

body > footer nav,
body > footer p {
  max-width: 56rem;
  margin: 0 auto;
  font-family: var(--font-sans);
}

body > footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body > footer nav a {
  color: var(--ink-faint);
  text-decoration: none;
  transition: color 0.15s ease;
}

body > footer nav a:hover {
  color: var(--ink-soft);
}

body > footer p.copyright {
  margin: 1.25rem auto 0;
  font-size: 0.75rem;
  color: var(--ink-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* ---------- Petits écrans ---------- */

@media (max-width: 480px) {
  main {
    padding-top: 2rem;
  }

  body > header nav {
    padding: 0.75rem 1rem;
  }
}
