/* ==========================================================================
   Pages légales — même thème que la planche (variables reprises de style.css),
   mais en page de lecture qui défile.
   ========================================================================== */

:root {
  --bp: #174a8b;
  --bp-deep: #0f3a73;
  --line: #a9cdf5;
  --line-minor: rgba(169, 205, 245, 0.15);
  --paper: #f4f9ff;
  --signal: #ffcf33;

  --font-label:
    "Barlow Condensed", "Arial Narrow", ui-sans-serif, system-ui, sans-serif;
  --font-text: ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

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

body {
  min-height: 100vh;
  padding: 10px;
  background-color: var(--bp);
  /* grille blueprint fixe, sans animation */
  background-image:
    linear-gradient(var(--line-minor) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-minor) 1px, transparent 1px);
  background-size: 32px 32px;
  background-attachment: fixed;
  color: var(--paper);
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.doc {
  max-width: 760px;
  margin: 0 auto;
  min-height: calc(100vh - 20px);
  padding: clamp(24px, 6vw, 56px) clamp(16px, 5vw, 48px);
  background: var(--bp-deep);
  border: 1px solid var(--line);
  outline: 1px solid var(--line);
  outline-offset: -8px;
}

h1,
h2,
h3,
.back,
.meta,
dt {
  font-family: var(--font-label);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.15;
}

h1 {
  font-size: clamp(30px, 6vw, 48px);
  text-transform: uppercase;
  overflow-wrap: break-word;
  hyphens: auto;
}
h2 {
  margin-top: 2.2em;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line);
  font-size: 24px;
}
h3 {
  margin-top: 1.6em;
  font-size: 19px;
}

p,
ul,
dl {
  margin-top: 0.9em;
}
ul {
  padding-left: 1.2em;
}
li + li {
  margin-top: 0.35em;
}

.meta {
  margin-top: 6px;
  font-weight: 500;
  opacity: 0.72;
}
.back {
  font-size: 17px;
  font-weight: 500;
}
.back:last-child {
  margin-top: 2.4em;
}
.back + h1 {
  margin-top: 1em;
}

dl {
  display: grid;
  grid-template-columns: minmax(0, 220px) 1fr;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}
dt,
dd {
  padding: 8px 12px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
dt {
  font-size: 15px;
  font-weight: 500;
  opacity: 0.85;
}

a {
  color: inherit;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}
a:hover {
  color: var(--signal);
}
a:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
}

@media (max-width: 560px) {
  dl {
    grid-template-columns: 1fr;
  }
  dt {
    border-bottom: 0;
    padding-bottom: 0;
  }
}
