/* Site personnel — feuille de style unique.
   Direction « Atelier » : catalogue technique, EB Garamond + IBM Plex Mono, fonts self-hosted (no third-party request). */

@font-face { font-family: "EB Garamond"; font-style: normal; font-weight: 400 600; font-display: swap; src: url(fonts/eb-garamond.woff2) format("woff2"); }
@font-face { font-family: "EB Garamond"; font-style: italic; font-weight: 400 600; font-display: swap; src: url(fonts/eb-garamond-italic.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-mono.woff2) format("woff2"); }

/* Palette. Jour (default): cream + burgundy. Nuit: night + British green.
   Follows the OS setting unless the visitor picked one (data-theme on <html>). */
:root { --bg: #f3eee4; --bg-2: #ebe4d6; --ink: #1d1a16; --muted: #5c554b; --rule: #cfc5b3; --accent: #7a1f2b; color-scheme: light; }
:root[data-theme="nuit"] { --bg: #0e1216; --bg-2: #151b21; --ink: #ebe5d8; --muted: #a49d90; --rule: #2c343c; --accent: #8bb8a0; color-scheme: dark; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="jour"]) { --bg: #0e1216; --bg-2: #151b21; --ink: #ebe5d8; --muted: #a49d90; --rule: #2c343c; --accent: #8bb8a0; color-scheme: dark; }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--bg); color: var(--ink); transition: background .4s, color .4s; -webkit-font-smoothing: antialiased; }
::selection { background: var(--accent); color: var(--bg); }
a { color: inherit; text-decoration-color: var(--accent); text-underline-offset: .22em; text-decoration-thickness: 1px; }
a:focus-visible, summary:focus-visible, button:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }
img, svg { display: block; }
.mono { font-family: "IBM Plex Mono", ui-monospace, monospace; font-size: .82rem; letter-spacing: 0; }
.acc { color: var(--accent); }
.skip { position: absolute; left: -9999px; top: 0; }
.skip:focus { left: 16px; top: 16px; z-index: 10; background: var(--bg); padding: 8px 12px; }
.portrait { width: 100%; height: auto; object-fit: cover; filter: saturate(.8) sepia(.04) contrast(1.03); transition: filter .4s; }
:root[data-theme="nuit"] .portrait { filter: saturate(.78) brightness(.95) contrast(1.05); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="jour"]) .portrait { filter: saturate(.78) brightness(.95) contrast(1.05); } }
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
.sum-mark { width: 11px; height: 11px; position: relative; flex: none; }
.sum-mark::before, .sum-mark::after { content: ""; position: absolute; background: var(--accent); left: 0; top: 5px; width: 11px; height: 1px; transition: transform .3s cubic-bezier(.16,1,.3,1); }
.sum-mark::after { transform: rotate(90deg); }
details[open] .sum-mark::after { transform: rotate(0deg); }
table { border-collapse: collapse; width: 100%; font-variant-numeric: tabular-nums; }
td, th { text-align: left; vertical-align: baseline; padding: .55em .9em .55em 0; border-bottom: 1px solid var(--rule); font-weight: inherit; }
th { color: var(--muted); }
.diagram text { fill: var(--ink); }
.diagram .lbl { fill: var(--muted); }
.diagram .box { fill: none; stroke: var(--rule); }
.diagram .line { stroke: var(--accent); }
::-webkit-scrollbar { width: 10px; } ::-webkit-scrollbar-track { background: var(--bg); } ::-webkit-scrollbar-thumb { background: var(--rule); }

body { font-family: "EB Garamond", serif; font-size: 19px; line-height: 1.55; }
.sc { font-variant-caps: all-small-caps; letter-spacing: .1em; }
.frame { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; max-width: 1440px; margin: 0 auto; }
aside { border-right: 1px solid var(--rule); padding: 34px 28px; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; justify-content: space-between; }
aside .name { font-size: 1.15rem; line-height: 1.25; }
aside .name i { display: block; color: var(--muted); font-size: .95rem; }
aside ol { list-style: none; margin: 0; padding: 0; }
aside li a { display: flex; gap: 14px; padding: 6px 0; text-decoration: none; color: var(--muted); }
aside li a .mono { color: var(--accent); font-size: .75rem; }
aside li a:hover, aside li a.cur { color: var(--ink); }
.theme { display: flex; gap: 14px; }
.theme button { font: inherit; letter-spacing: inherit; background: none; border: 0; padding: 2px 0; color: var(--muted); cursor: pointer; border-bottom: 1px solid transparent; }
.theme button:hover { color: var(--ink); }
.theme button[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--accent); }
main { padding: 0 56px; width: 100%; max-width: 1100px; margin: 0 auto; }
.blk { padding: 72px 0; border-bottom: 1px solid var(--rule); }
/* Editorial plate: the photo meets the sidebar rule and the top of the page with hard edges (page edges),
   and dissolves only where it meets the text (right) and the content below (bottom). The title overlaps the fade. */
.blk.intro { display: grid; grid-template-columns: 50% 1fr; align-items: end; margin-left: -56px; padding: 0 0 72px; }
/* The photo keeps its own proportions so the face is never cropped; the fade only covers the background right of the cheek. */
.intro .portrait { grid-row: 1; grid-column: 1; aspect-ratio: 1050 / 1200; object-position: 0 0;
  -webkit-mask-image: linear-gradient(to right, #000 85%, transparent 100%), linear-gradient(to bottom, #000 76%, transparent 100%), linear-gradient(to bottom left, transparent 6%, #000 30%); -webkit-mask-composite: source-in, source-in;
  mask-image: linear-gradient(to right, #000 85%, transparent 100%), linear-gradient(to bottom, #000 76%, transparent 100%), linear-gradient(to bottom left, transparent 6%, #000 30%); mask-composite: intersect; }
.intro > div { grid-row: 1; grid-column: 2; padding: 0 0 6px 28px; }
.intro h1 { font-size: clamp(2.2rem, 3.1vw, 3.7rem); }
.intro .lead { font-size: 1.2rem; color: var(--ink); max-width: 28em; }
h1 { font-weight: 400; font-style: italic; font-size: clamp(2.4rem, 5vw, 3.9rem); line-height: 1.06; margin: 0 0 26px; letter-spacing: -.015em; text-wrap: balance; }
.lead { max-width: 33em; margin: 0; color: var(--muted); }
h2 { font-weight: 400; font-size: 1.05rem; margin: 0 0 34px; display: flex; gap: 16px; align-items: baseline; }
h2 .mono { color: var(--accent); }
.feat { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: end; padding: 30px 0 40px; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); text-decoration: none; }
.feat .ref { display: flex; gap: 22px; color: var(--muted); }
.feat .ref .mono { color: var(--accent); }
.feat .nm { font-style: italic; font-size: clamp(3.2rem, 5.6vw, 5.4rem); line-height: 1; margin: 14px 0 18px; letter-spacing: -.02em; transition: color .3s; }
.feat .one { margin: 0 0 10px; font-size: 1.15rem; max-width: 30em; }
.feat .facts { margin: 0 0 22px; color: var(--muted); }
.feat .more { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: .22em; text-decoration-thickness: 1px; }
a.feat:hover .nm { color: var(--accent); }
.feat .proof { background: var(--bg-2); border: 1px solid var(--rule); padding: 22px 24px; font-size: .78rem; line-height: 2; }
.feat .proof .ok { color: var(--accent); }
.feat .proof p { margin: 10px 0 0; font-family: "EB Garamond", serif; font-style: italic; font-size: .95rem; color: var(--muted); }
.bench { display: grid; grid-template-columns: 160px auto 1fr; gap: 24px; align-items: baseline; padding: 20px 0; border-bottom: 1px solid var(--rule); color: var(--muted); }
.bench .nm { font-style: italic; font-size: 1.5rem; color: var(--ink); }
.ask .q { font-style: italic; font-size: clamp(1.8rem, 2.6vw, 2.5rem); line-height: 1.2; margin: 0 0 30px; max-width: 22em; }
.ask dl { display: grid; grid-template-columns: 120px 1fr; gap: 10px 24px; margin: 0; font-size: 1.1rem; }
.ask dt { color: var(--muted); }
.ask dd { margin: 0; }
.sign { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; flex-wrap: wrap; }
.sign .nm { font-style: italic; font-size: 1.4rem; color: var(--ink); }
.cat { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; border-top: 1px solid var(--ink); }
.cal { padding: 26px 28px 30px 0; text-decoration: none; display: block; }
.cal + .cal { border-left: 1px solid var(--rule); padding-left: 28px; }
.cal .ref { display: flex; justify-content: space-between; color: var(--muted); }
.cal .ref .mono { color: var(--accent); }
.cal .nm { font-style: italic; font-size: 2.4rem; line-height: 1.1; margin: 18px 0 8px; }
.cal dl { display: grid; grid-template-columns: auto 1fr; gap: 2px 18px; margin: 18px 0 0; font-size: .95rem; }
.cal dt { color: var(--muted); }
.cal dd { margin: 0; }
a.cal:hover .nm { color: var(--accent); }
.cal.wip .nm { color: var(--muted); }
.method { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 48px; }
.method div { border-top: 1px solid var(--rule); padding-top: 14px; }
.method p { margin: 4px 0 0; }
.method .ex { color: var(--muted); font-size: .95rem; }
footer { padding: 56px 0; color: var(--muted); }
/* C — calibre page */
.cal-head { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: end; padding: 64px 0 40px; border-bottom: 1px solid var(--ink); }
.cal-head .nm { font-style: italic; font-size: clamp(3.4rem, 8vw, 5.8rem); line-height: 1; margin: 10px 0 18px; letter-spacing: -.02em; }
.cal-head .one { margin: 0; max-width: 30em; font-size: 1.15rem; }
.cal-head dl { margin: 0; display: grid; grid-template-columns: auto auto; gap: 4px 18px; font-size: .95rem; }
.cal-head dt { color: var(--muted); }
.cal-head dd { margin: 0; }
.points { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--rule); }
.points p { margin: 0; padding: 20px 20px 22px 0; font-size: .98rem; line-height: 1.4; }
.points p + p { padding-left: 20px; border-left: 1px solid var(--rule); }
.macro { margin: 56px 0; padding: 34px 36px; background: var(--bg-2); border: 1px solid var(--rule); }
.macro .mono { font-size: .9rem; line-height: 1.9; }
.macro .mono .ok { color: var(--accent); }
.macro .cap { margin: 16px 0 0; color: var(--muted); font-style: italic; font-size: .95rem; }
details { border-top: 1px solid var(--rule); }
details:last-of-type { border-bottom: 1px solid var(--rule); }
summary { display: grid; grid-template-columns: 56px 1fr auto auto; gap: 16px; align-items: baseline; padding: 18px 0; font-size: 1.25rem; }
summary .mono { color: var(--accent); }
summary .meta { color: var(--muted); font-size: .9rem; }
summary .sum-mark { align-self: center; }
.det { padding: 0 0 34px 72px; }
@media (max-width: 860px) { .frame { grid-template-columns: minmax(0, 1fr); } aside { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--rule); gap: 20px; } main { padding: 0 24px; } .cat, .method, .cal-head { grid-template-columns: 1fr; }
  .feat { grid-template-columns: 1fr; gap: 28px; } .bench { grid-template-columns: 1fr; gap: 4px; } .ask dl { grid-template-columns: 90px 1fr; }
  .blk.intro { grid-template-columns: 1fr; margin: 0 -24px; min-height: 0; padding-bottom: 56px; }
  .intro .portrait { height: auto; -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent 100%); mask-image: linear-gradient(to bottom, #000 60%, transparent 100%); }
  .intro > div { grid-row: 2; grid-column: 1; margin: -36px 24px 0; padding: 0; } .cal + .cal { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); } .points { grid-template-columns: 1fr 1fr; } .points p:nth-child(3) { border-left: 0; padding-left: 0; } .det { padding-left: 0; } summary { grid-template-columns: 44px 1fr auto; } summary .meta { display: none; } }

.det p { margin: 0 0 14px; max-width: 42em; }
.det .note { color: var(--muted); font-size: .92em; }
.det td.code { color: var(--accent); white-space: nowrap; }
.det td.pri { color: var(--muted); }
.det .tests { margin: 16px 0 0; padding: 0; list-style: none; }
.det .tests li { padding: 3px 0; }
.det .tests li span { color: var(--accent); margin-right: 1.2em; }
.det .diagram { width: 100%; max-width: 640px; height: auto; margin: 8px 0 24px; }
/* Phones: compact header instead of the tall sidebar. */
@media (max-width: 860px) {
  aside { padding: 18px 24px; gap: 12px; }
  .feat .proof div, .ask dd, .det td { overflow-wrap: anywhere; }
  aside ol { display: flex; flex-wrap: wrap; gap: 0 18px; }
  aside li a { padding: 2px 0; gap: 6px; }
  .intro .portrait { -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent 100%), linear-gradient(to bottom left, transparent 6%, #000 30%); -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to bottom, #000 60%, transparent 100%), linear-gradient(to bottom left, transparent 6%, #000 30%); mask-composite: intersect; }
  .legal { padding: 48px 0; }
}

/* Mentions légales */
.legal { padding: 72px 0; max-width: 44em; }
.legal h1 { font-size: clamp(2.2rem, 4vw, 3.2rem); }
.legal h2 { margin: 36px 0 10px; }
.legal p { margin: 0 0 12px; }
