/* Pages légales et 404 ASHENN : même langage graphique que l'accueil (home.css), sans script ni animation lourde.
   Charte v1.1 (brand/CHARTE.md) : Manrope, noir dominant, rouge en accent, grilles et lignes techniques. */
@font-face { font-family: "Manrope"; font-weight: 400; font-display: swap; src: url("/fonts/manrope-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 700; font-display: swap; src: url("/fonts/manrope-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Manrope"; font-weight: 800; font-display: swap; src: url("/fonts/manrope-latin-800-normal.woff2") format("woff2"); }
:root {
  --bg: #09090B;
  --bg-alt: #0E0E11;
  --surface: #17171B;
  --text: #F5F5F7;
  --muted: #92929B;
  --line: #222227;
  --line-strong: #34343B;
  --accent: #D71935;
  --accent-deep: #8F1026;
  --link: #F0566B;
  --todo-bg: #3b3100;
  --todo-line: #d6a80f;
  --todo-text: #ffe69a;
  --shell: 80rem;
  --max: 50rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --ease: cubic-bezier(.22, 1, .36, 1);
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 6rem; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.7 "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--link); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent); color: #fff; }
.shell { position: relative; width: 100%; max-width: var(--shell); margin-inline: auto; padding-inline: var(--gutter); }
.wrap { width: 100%; max-width: calc(var(--max) + var(--gutter) * 2); margin: 0 auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--text); color: var(--bg); padding: .6rem 1rem; font-weight: 700; text-decoration: none; border-radius: 6px; }
.skip:focus { top: 1rem; }

/* Bouton (identique à l'accueil) */
.btn {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 2.75rem; padding: .5rem 1.15rem;
  background: var(--accent); color: #fff; border: 1px solid var(--accent); border-radius: 999px;
  font-weight: 700; font-size: .9rem; line-height: 1.2; text-decoration: none; white-space: nowrap;
  transition: background-color .25s var(--ease), border-color .25s var(--ease), box-shadow .3s var(--ease);
}
.btn::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .22) 50%, transparent 70%); transform: translateX(-120%); transition: transform .7s var(--ease); }
.btn:hover { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; box-shadow: 0 12px 40px -14px rgba(215, 25, 53, .8); }
.btn:hover::after { transform: translateX(120%); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn--ghost:hover { background: var(--surface); border-color: var(--accent); color: var(--text); box-shadow: none; }

/* En-tête */
.top {
  position: sticky; top: 0; z-index: 50;
  background: rgba(9, 9, 11, .82);
  -webkit-backdrop-filter: saturate(140%) blur(14px); backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.top__in { display: flex; align-items: center; gap: 1.5rem; min-height: 4.5rem; }
.brand { display: inline-flex; align-items: center; margin-right: auto; padding-block: .5rem; text-decoration: none; }
.brand img { height: 1.85rem; width: auto; display: block; }
.top__nav { display: flex; align-items: center; gap: 1.75rem; }
.top__nav a { position: relative; color: var(--muted); text-decoration: none; font-weight: 600; font-size: .9rem; padding-block: .6rem; transition: color .2s var(--ease); }
.top__nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: .3rem; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.top__nav a:hover, .top__nav a[aria-current="page"] { color: var(--text); }
.top__nav a:hover::after, .top__nav a[aria-current="page"]::after { transform: scaleX(1); }
@media (max-width: 52rem) {
  .top__in { flex-wrap: wrap; gap: .25rem .75rem; min-height: 4rem; }
  .brand img { height: 1.6rem; }
  .top__nav { order: 3; width: 100%; gap: 1.25rem; overflow-x: auto; scrollbar-width: none; border-top: 1px solid var(--line); }
  .top__nav a { white-space: nowrap; font-size: .85rem; }
}
@media (max-width: 23.5rem) { .brand img { height: 1.35rem; } .top .btn { padding-inline: .85rem; font-size: .82rem; } .top__nav { gap: .9rem; } .top__nav a { font-size: .8rem; } }

/* En-tête de page : grille technique, lueur rouge et monogramme filaire */
.page-head { position: relative; overflow: hidden; isolation: isolate; padding-block: clamp(3.5rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4rem); border-bottom: 1px solid var(--line); }
.page-head::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background-image: linear-gradient(to right, rgba(245, 245, 247, .05) 1px, transparent 1px), linear-gradient(to bottom, rgba(245, 245, 247, .05) 1px, transparent 1px);
  background-size: 64px 64px; background-position: -1px -1px;
  -webkit-mask-image: radial-gradient(ellipse 70% 90% at 80% 30%, #000 15%, transparent 72%); mask-image: radial-gradient(ellipse 70% 90% at 80% 30%, #000 15%, transparent 72%);
}
.page-head::after { content: ""; position: absolute; z-index: -2; right: -10rem; top: -12rem; width: 40rem; height: 40rem; background: radial-gradient(circle, rgba(215, 25, 53, .18), transparent 65%); pointer-events: none; }
.page-head__wire { position: absolute; z-index: -1; right: max(var(--gutter), calc((100% - var(--shell)) / 2 + var(--gutter))); top: 50%; width: clamp(12rem, 30vw, 24rem); transform: translateY(-50%); fill: none; stroke: var(--accent); stroke-width: .5; stroke-linejoin: round; opacity: .55; pointer-events: none; }
.page-head__wire use:nth-child(2) { opacity: .45; transform: translate(4px, 3px); }
.page-head__wire use:nth-child(3) { opacity: .25; transform: translate(8px, 6px); }
.kicker { display: flex; align-items: center; gap: .85rem; margin: 0; white-space: nowrap; color: var(--muted); font-size: .72rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; line-height: 1.4; }
.kicker__i { color: var(--link); letter-spacing: .08em; }
.kicker::after { content: ""; flex: 0 1 7rem; min-width: 1.5rem; height: 5px; background: linear-gradient(90deg, var(--line-strong), var(--line-strong)) left / calc(100% - 7px) 1px no-repeat, linear-gradient(var(--accent), var(--accent)) right center / 5px 5px no-repeat; }
@media (max-width: 48rem) { .page-head__wire { right: -3rem; top: 2rem; transform: none; width: 13rem; opacity: .3; } }

/* Contenu */
main { padding-top: 0; }
.legal { padding-block: clamp(2.5rem, 6vw, 4rem) clamp(4rem, 9vw, 6rem); }
h1 { font-size: clamp(2.4rem, 7vw, 4.6rem); line-height: .98; font-weight: 800; letter-spacing: -.05em; margin: 1.25rem 0 1.25rem; text-wrap: balance; max-width: 16ch; }
h2 { position: relative; font-size: clamp(1.35rem, 2.6vw, 1.75rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.2; margin: 3.5rem 0 1rem; padding-top: 1.75rem; border-top: 1px solid var(--line); scroll-margin-top: 6rem; }
h2::before { content: ""; position: absolute; left: 0; top: -1px; width: 3rem; height: 1px; background: var(--accent); }
h3 { font-size: 1.1rem; font-weight: 700; letter-spacing: -.01em; margin: 2rem 0 .6rem; scroll-margin-top: 6rem; }
.legal p, .legal li { color: #C4C4CC; }
.legal ul { padding-left: 1.25rem; }
.legal ul li { margin-block: .35rem; }
.legal ul li::marker { color: var(--accent); }
.legal strong { color: var(--text); }
.lead { color: #B4B4BC; font-size: clamp(1.05rem, 1.6vw, 1.2rem); max-width: 40rem; margin: 0; }
.meta { display: inline-flex; align-items: center; gap: .6rem; margin: 1.5rem 0 0; color: var(--muted); font-size: .85rem; }
.meta::before { content: ""; width: .45rem; height: .45rem; border-radius: 50%; background: var(--accent); }

/* Cartes à coin coupé, comme sur l'accueil */
.card {
  --c: 20px; position: relative;
  background: linear-gradient(160deg, var(--surface), rgba(23, 23, 27, .4)); border: 1px solid var(--line-strong);
  padding: clamp(1.1rem, 3vw, 1.6rem) clamp(1.1rem, 3vw, 1.75rem); margin: 1rem 0;
  clip-path: polygon(0 0, calc(100% - var(--c)) 0, 100% var(--c), 100% 100%, 0 100%);
}
.card::after { content: ""; position: absolute; top: 0; right: 0; width: var(--c); height: var(--c); background: linear-gradient(45deg, transparent calc(50% - .75px), var(--accent) 50%, transparent calc(50% + .75px)); }
.card p:first-child { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }
.note { border-color: rgba(215, 25, 53, .45); background: radial-gradient(30rem 12rem at 0% 0%, rgba(215, 25, 53, .12), transparent 70%), var(--surface); }
dl.id { display: grid; grid-template-columns: max-content 1fr; gap: .55rem 1.5rem; margin: 0; }
dl.id dt { color: var(--muted); font-size: .92rem; }
dl.id dd { margin: 0; font-weight: 700; }
dl.id a { font-weight: 700; }
@media (max-width: 30rem) { dl.id { grid-template-columns: 1fr; gap: .1rem; } dl.id dd { margin-bottom: .6rem; } }

/* Sommaire */
.toc { margin: 2.5rem 0 1rem; padding: 1.25rem 1.5rem; border: 1px solid var(--line-strong); background: var(--bg-alt); }
.toc p { margin: 0 0 .75rem; color: var(--muted); font-size: .72rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: 0 2rem; }
.toc li { counter-increment: toc; border-top: 1px solid var(--line); }
.toc a { display: flex; gap: .85rem; padding-block: .6rem; color: var(--text); font-weight: 600; text-decoration: none; transition: color .2s var(--ease); }
.toc a::before { content: counter(toc, decimal-leading-zero); color: var(--link); font-size: .78rem; font-weight: 700; padding-top: .15rem; font-variant-numeric: tabular-nums; }
.toc a:hover { color: var(--link); }

/* Tableaux */
.table-scroll { overflow-x: auto; margin: 1rem 0; border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: .95rem; }
th, td { text-align: left; vertical-align: top; padding: .75rem 1rem; border-bottom: 1px solid var(--line); }
tr:last-child th, tr:last-child td { border-bottom: 0; }
th { font-weight: 700; background: var(--surface); }
td { color: #C4C4CC; }
table.kv th { width: 9rem; color: var(--muted); font-size: .85rem; font-weight: 700; letter-spacing: .02em; background: var(--bg-alt); }
@media (max-width: 30rem) { table.kv th { width: 6.5rem; padding-inline: .75rem; } table.kv td { padding-inline: .75rem; } }
@media (max-width: 40rem) {
  table.stack thead { display: none; }
  table.stack tr { display: block; border: 1px solid var(--line); margin-bottom: .75rem; background: var(--surface); }
  table.stack td { display: block; border: 0; padding: .5rem .9rem; }
  table.stack td::before { content: attr(data-label); display: block; font-size: .8rem; color: var(--muted); font-weight: 700; }
}

/* Page 404 */
.notfound { padding-block: clamp(3rem, 10vw, 7rem); }
.notfound__code { font-size: clamp(6rem, 22vw, 13rem); font-weight: 800; line-height: .8; letter-spacing: -.07em; margin: 0 0 1rem; color: transparent; -webkit-text-stroke: 1.5px var(--accent); background: repeating-linear-gradient(180deg, rgba(215, 25, 53, .55) 0 1px, transparent 1px 7px); -webkit-background-clip: text; background-clip: text; }
.notfound__actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

/* Page d’annulation de rendez-vous */
.cancel { max-width: 40rem; margin-top: 1.5rem; }
.cancel .lead strong { color: var(--text); }
.cancel .notfound__actions { margin-top: 1.5rem; }
.cancel__help { margin: 1.5rem 0 0 !important; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; }
.cancel__status { margin-top: 1rem; color: var(--link); font-weight: 700; }
.cancel__status:empty { display: none; }
button.btn { font: inherit; font-weight: 700; font-size: .95rem; cursor: pointer; }
button.btn:disabled { opacity: .6; cursor: progress; }

/* Pied de page (identique à l'accueil) */
.foot { padding-block: clamp(3rem, 6vw, 4.5rem) 2rem; color: var(--muted); font-size: .92rem; border-top: 1px solid var(--line); background: var(--bg-alt); }
.foot p { margin: 0; }
.foot__grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1.2fr); gap: 2.5rem 3rem; padding-bottom: 2.5rem; border-bottom: 1px solid var(--line); }
.foot__brand img { height: 1.75rem; width: auto; margin-bottom: 1.1rem; }
.foot__brand p { max-width: 24rem; }
.foot__col { display: grid; align-content: start; gap: .1rem; }
.foot__k { color: var(--text); font-size: .72rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; margin-bottom: .6rem !important; }
.foot__col a { color: var(--muted); text-decoration: none; padding-block: .6rem; justify-self: start; }
.foot__col a:hover { color: var(--text); }
.foot__col span { padding-block: .6rem; }
.foot__bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem 2rem; padding-top: 1.25rem; }
.foot__sig { display: inline-flex; align-items: center; gap: .65rem; }
.foot__sig img { height: 1rem; width: auto; flex: none; }
.foot__bar nav { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.foot__bar nav a { color: var(--muted); display: inline-block; padding-block: .6rem; }
.foot__bar nav a:hover, .foot__bar nav a[aria-current="page"] { color: var(--text); }
@media (max-width: 48rem) { .foot__grid { grid-template-columns: 1fr 1fr; } .foot__brand { grid-column: 1 / -1; } }
@media (max-width: 30rem) { .foot__grid { grid-template-columns: 1fr; } }

/* Ancienne structure d'en-tête et de pied de page (brouillons dans drafts/) */
.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: .5rem 1rem; flex-wrap: wrap; min-height: 4rem; padding-block: .6rem; }
.site-header nav a { color: var(--muted); text-decoration: none; font-weight: 600; font-size: .95rem; margin-left: 1rem; }
.site-footer { border-top: 1px solid var(--line); margin-top: 4rem; color: var(--muted); font-size: .9rem; }
.site-footer .wrap { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; padding-block: 1.5rem 2rem; }
.site-footer .sym { height: 1rem; width: auto; }

/* Champs à compléter : bloquent le build tant qu'ils existent (voir scripts/check-placeholders.mjs) */
.todo { background: var(--todo-bg); color: var(--todo-text); border: 1px dashed var(--todo-line); border-radius: 4px; padding: 0 .3rem; font-weight: 600; }
.draft { background: var(--todo-bg); color: var(--todo-text); border-bottom: 2px solid var(--todo-line); padding: .6rem 1rem; text-align: center; font-size: .9rem; font-weight: 600; }
