/* =========================================================
   CV Grégory Boulanger — feuille de style
   Direction : éditoriale / suisse. Papier chaud, encre, un
   seul accent orange signal, filets fins, serif display.
   ========================================================= */

:root {
  --bg: #F3F0E8;
  --surface: #FBFAF6;
  --ink: #151412;
  --ink-2: #4A4740;
  --ink-3: #8A857A;
  --line: #DAD5C8;
  --line-strong: #151412;
  --accent: #E0461C;
  --accent-ink: #FFFFFF;
  --accent-soft: #F6DACE;
  --c-product: var(--accent);
  --c-project: #151412;
  --c-training: #8A857A;
  --c-dev: #151412;

  --serif: 'Instrument Serif', 'Times New Roman', serif;
  --sans: 'Geist', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --gutter: clamp(16px, 4vw, 40px);
  --maxw: 1240px;
  --radius: 4px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #11110F;
    --surface: #1A1916;
    --ink: #EEEAE0;
    --ink-2: #BAB5A9;
    --ink-3: #7F7A6F;
    --line: #2E2C28;
    --line-strong: #EEEAE0;
    --accent: #FF6A3D;
    --accent-ink: #11110F;
    --accent-soft: #3A1E14;
    --c-project: #EEEAE0;
    --c-training: #7F7A6F;
    --c-dev: #EEEAE0;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #11110F;
  --surface: #1A1916;
  --ink: #EEEAE0;
  --ink-2: #BAB5A9;
  --ink-3: #7F7A6F;
  --line: #2E2C28;
  --line-strong: #EEEAE0;
  --accent: #FF6A3D;
  --accent-ink: #11110F;
  --accent-soft: #3A1E14;
  --c-project: #EEEAE0;
  --c-training: #7F7A6F;
  --c-dev: #EEEAE0;
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 96px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  font-feature-settings: 'ss01', 'cv11';
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .3s, color .3s;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ol, ul, figure { margin: 0; }
ol, ul { padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--accent); color: var(--accent-ink); }
#app:focus { outline: none; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); font-weight: 400; }
.display { font-family: var(--serif); font-weight: 400; letter-spacing: -.01em; }
.muted { color: var(--ink-3); }
.ico { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ico-sm { width: 13px; height: 13px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--ink); color: var(--bg); padding: 8px 12px; }
.skip:focus { left: 8px; }

/* Apparition douce à chaque vue */
.rise { animation: rise .7s var(--ease) both; animation-delay: calc(var(--d, 0) * 70ms); }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .rise { animation: none; }
  * { transition: none !important; }
}
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .25s; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  height: 46px; padding: 0 20px;
  border-radius: 999px; font-size: 15px; font-weight: 500;
  border: 1px solid transparent;
  transition: transform .2s var(--ease), background-color .2s, color .2s, border-color .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { height: 36px; padding: 0 14px; font-size: 13.5px; gap: 8px; }
.btn-sm .ico { width: 16px; height: 16px; }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-accent:hover { background: var(--ink); color: var(--bg); }
.btn-ink { background: var(--ink); color: var(--bg); }
.btn-ink:hover { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); }
.icon-btn {
  width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  transition: border-color .2s, transform .3s var(--ease);
}
.icon-btn:hover { border-color: var(--ink); transform: rotate(-20deg); }

/* ---------- Barre du haut ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar-in { display: flex; align-items: center; gap: 24px; height: 64px; }
.mark { display: flex; align-items: center; gap: 10px; flex: none; }
.mark-logo {
  width: 32px; height: 32px; border-radius: 8px;
  display: grid; place-items: center;
  background: var(--ink); color: var(--bg);
  font-family: var(--serif); font-style: italic; font-size: 19px; line-height: 1;
  padding-bottom: 3px;
  transition: background-color .2s;
}
.mark:hover .mark-logo { background: var(--accent); color: var(--accent-ink); }
.mark-name { font-weight: 500; font-size: 14.5px; letter-spacing: -.01em; }
.nav { display: flex; gap: 4px; margin: 0 auto; }
.nav a {
  position: relative; padding: 8px 12px; font-size: 14.5px; color: var(--ink-2);
  transition: color .2s;
}
.nav a::after {
  content: ''; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease);
}
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"]::after, .nav a:hover::after { transform: scaleX(1); }
.tools { display: flex; align-items: center; gap: 10px; flex: none; }
.lang { display: flex; border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.lang a {
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .06em;
  padding: 5px 10px; border-radius: 999px; color: var(--ink-3);
  transition: background-color .2s, color .2s;
}
.lang a[aria-current="true"] { background: var(--ink); color: var(--bg); }
.lang a:not([aria-current]):hover { color: var(--ink); }

@media (max-width: 1020px) {
  .mark-name { display: none; }
}
@media (max-width: 860px) {
  .topbar-in { flex-wrap: wrap; height: auto; padding-top: 12px; gap: 12px; }
  .mark-name { display: inline; }
  .tools { margin-left: auto; }
  .nav {
    order: 3; width: calc(100% + 2 * var(--gutter)); margin: 0 calc(-1 * var(--gutter));
    padding: 0 calc(var(--gutter) - 12px) 4px;
    overflow-x: auto; scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; }
}
@media (max-width: 520px) {
  .mark-name { display: none; }
  .tools .btn span { display: none; }
  .tools .btn { width: 36px; padding: 0; justify-content: center; }
}

/* ---------- Hero ---------- */
.hero { padding-top: clamp(28px, 5vw, 56px); }
.hero-top { display: flex; justify-content: space-between; gap: 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line-strong); }
.name {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(44px, 6.2vw, 88px);
  line-height: .95; letter-spacing: -.03em;
  margin: clamp(20px, 3vw, 32px) 0 clamp(20px, 3vw, 36px);
  display: flex; flex-wrap: wrap; column-gap: .22em;
}
.name .last { font-style: italic; position: relative; }
.name .dot {
  display: inline-block; width: .13em; height: .13em; border-radius: 50%;
  background: var(--accent); margin-left: .05em; vertical-align: baseline;
}
.hero-grid {
  display: grid; gap: clamp(24px, 4vw, 56px);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) minmax(220px, .8fr);
  align-items: start;
  padding-bottom: clamp(40px, 6vw, 80px);
}
.role { font-size: clamp(20px, 2vw, 24px); line-height: 1.25; font-weight: 500; letter-spacing: -.015em; margin-bottom: 28px; }
.top-label { margin-bottom: 12px; }
.pillars { display: grid; gap: 10px; }
.pillars li {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 16px 12px 12px;
  background: var(--surface); border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.pil-ico {
  width: 38px; height: 38px; flex: none; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent);
}
.pil-ico .ico { width: 20px; height: 20px; }
.pil-t { font-family: var(--serif); font-size: clamp(22px, 2vw, 26px); line-height: 1.1; letter-spacing: -.01em; }
.intro { font-size: clamp(17px, 1.5vw, 19px); line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }
.now {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin: 24px 0; padding: 14px 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  font-size: 15px; transition: border-color .2s;
}
.now .ico { margin-left: auto; transition: transform .3s var(--ease); }
.now:hover { border-color: var(--ink); }
.now:hover .ico { transform: translateX(4px); }
.pulse { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; display: inline-block; }
.pulse::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--accent);
  animation: pulse 2s ease-out infinite;
}
@keyframes pulse { from { transform: scale(1); opacity: .7; } to { transform: scale(3.2); opacity: 0; } }
.cta { display: flex; gap: 10px; flex-wrap: wrap; }

.portrait {
  position: relative; aspect-ratio: 7 / 8; overflow: hidden; border-radius: var(--radius);
  background: var(--line);
}
.portrait img {
  width: 100%; height: 100%; object-fit: cover;
  filter: grayscale(1) contrast(1.05);
  transition: filter .6s var(--ease), transform .8s var(--ease);
}
.portrait:hover img { filter: none; transform: scale(1.03); }
.portrait::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: var(--accent); mix-blend-mode: multiply; opacity: .16;
  transition: opacity .6s var(--ease);
}
.portrait:hover::after { opacity: 0; }

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr 1fr; }
  .portrait { grid-row: 1; grid-column: 2; }
  .hero-intro { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .hero-grid { grid-template-columns: 1fr; }
  .portrait { grid-row: auto; grid-column: auto; max-width: 320px; }
  .hero-top .mono:last-child { text-align: right; }
}

/* ---------- Chiffres ---------- */
.stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
}
.stat { padding: 28px 24px 32px 0; border-right: 1px solid var(--line); border-top: 1px solid var(--line-strong); }
.stat + .stat { padding-left: 24px; }
.stat:last-child { border-right: 0; }
.stat-n { display: flex; align-items: baseline; gap: 6px; }
.stat-n .display { font-size: clamp(56px, 6vw, 84px); line-height: .9; letter-spacing: -.03em; }
.stat:first-child .stat-n .display { color: var(--accent); }
.stat-n .unit { font-size: 16px; font-weight: 500; }
.stat-l { margin-top: 12px; color: var(--ink-2); font-size: 14.5px; max-width: 24ch; }
@media (max-width: 860px) {
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(2) { border-right: 0; }
  .stat:nth-child(3) { padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ---------- Titres de section ---------- */
.sec-head {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap;
  padding: 18px 0; border-top: 1px solid var(--line-strong); margin-bottom: 24px;
}
.h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(30px, 3.4vw, 44px); line-height: 1.05; letter-spacing: -.02em; }
.h3 { font-size: 15px; font-weight: 500; }
.glance, .toc { padding-top: clamp(48px, 7vw, 96px); }

/* ---------- Frise ---------- */
.tl-ctrl { display: flex; align-items: center; gap: 8px; }
.tl-ctrl p { margin-right: 8px; font-size: 14px; }
.icon-btn:disabled { opacity: .35; cursor: default; transform: none; border-color: var(--line); }
.tl-wrap { position: relative; --tl-label: 132px; }
@media (max-width: 600px) { .tl-wrap { --tl-label: 96px; } .tl-label .tag { font-size: 9.5px; gap: 5px; letter-spacing: .02em; } }
.tl-scroll {
  overflow-x: auto; padding-bottom: 10px; scrollbar-width: thin;
  cursor: grab; user-select: none; -webkit-user-select: none;
}
.tl-scroll.dragging { cursor: grabbing; }
.tl-scroll.dragging .tl-bar { pointer-events: none; }
.tl { position: relative; min-width: 100%; padding-top: 34px; }
.tl-grid { position: absolute; inset: 0 0 0 var(--tl-label); pointer-events: none; }
.tl-grid span { position: absolute; top: 0; bottom: 0; border-left: 1px solid var(--line); }
.tl-grid span b {
  position: absolute; top: 6px; left: 8px;
  font: 400 11.5px/1 var(--mono); letter-spacing: .04em; color: var(--ink-3);
}
.tl-now { position: absolute; top: 0; bottom: 0; width: 0; border-left: 1.5px dashed var(--accent); }
.tl-lane {
  position: relative; display: grid; grid-template-columns: var(--tl-label) 1fr;
  border-top: 1px solid var(--line);
}
.tl-lane:last-of-type { border-bottom: 1px solid var(--line); }
.tl-label {
  display: flex; align-items: center; padding-right: 12px;
  background: var(--bg); position: sticky; left: 0; z-index: 3;
  border-right: 1px solid var(--line);
}
.tl-label .tag { white-space: normal; line-height: 1.25; }
.tl-corner {
  position: sticky; left: 0; z-index: 3;
  width: var(--tl-label); height: 34px; margin-top: -34px;
  background: var(--bg); border-right: 1px solid var(--line);
}
.tl-wrap::before {
  content: ''; position: absolute; top: 0; bottom: 10px; left: var(--tl-label); width: 40px; z-index: 4; pointer-events: none;
  background: linear-gradient(90deg, var(--bg), transparent); opacity: 0; transition: opacity .3s;
}
.tl-wrap.has-past::before { opacity: 1; }
.tl-label .tag { font-size: 11px; }
.tl-track { position: relative; height: calc(var(--rows) * 40px + 16px); }
.tl-bar {
  position: absolute; top: calc(8px + var(--row) * 40px); height: 32px;
  display: flex; align-items: center; padding: 0 10px; overflow: hidden;
  border-radius: 3px; font-size: 12.5px; font-weight: 500; white-space: nowrap;
  transition: transform .25s var(--ease), box-shadow .25s;
}
.tl-bar span { overflow: hidden; text-overflow: ellipsis; }
.tl-bar:hover, .tl-bar:focus-visible { transform: translateY(-2px); box-shadow: 0 6px 0 -2px var(--accent); z-index: 2; }
.bar-product { background: var(--c-product); color: var(--accent-ink); }
.bar-project { background: var(--c-project); color: var(--bg); }
.bar-training {
  background: repeating-linear-gradient(-45deg, transparent 0 5px, color-mix(in srgb, var(--ink) 18%, transparent) 5px 6px), var(--surface);
  color: var(--ink); border: 1px solid var(--ink-3);
}
.bar-dev { background: var(--surface); color: var(--ink); border: 1.5px solid var(--c-dev); }
.tl-bar.is-now { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.tl-bar.is-now::after {
  content: ''; position: absolute; right: 0; top: 0; bottom: 0; width: 14px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--bg) 70%, transparent));
}
.tl-tip {
  position: absolute; z-index: 5; pointer-events: none;
  transform: translate(-50%, calc(-100% - 10px)) translateY(4px);
  background: var(--ink); color: var(--bg);
  padding: 10px 12px; border-radius: var(--radius); width: max-content; max-width: 260px;
  display: grid; gap: 4px; font-size: 13.5px;
  opacity: 0; transition: opacity .15s, transform .2s var(--ease);
}
.tl-tip .mono { color: color-mix(in srgb, var(--bg) 65%, var(--ink)); font-size: 10.5px; }
.tl-tip.on { opacity: 1; transform: translate(-50%, calc(-100% - 10px)); }

/* Tags de catégorie */
.tag {
  display: inline-flex; align-items: center; gap: 7px;
  font: 400 11.5px/1 var(--mono); letter-spacing: .05em; text-transform: uppercase; color: var(--ink-2);
  white-space: nowrap;
}
.sw { width: 10px; height: 10px; border-radius: 2px; display: inline-block; flex: none; }
.sw-product { background: var(--c-product); }
.sw-project { background: var(--c-project); }
.sw-training { background: repeating-linear-gradient(-45deg, var(--ink-3) 0 1.5px, transparent 1.5px 3px); border: 1px solid var(--ink-3); }
.sw-dev { border: 1.5px solid var(--c-dev); }

/* ---------- Sommaire ---------- */
.toc-list { border-bottom: 1px solid var(--line-strong); }
.toc-row {
  position: relative; display: grid; align-items: center; gap: 24px;
  grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1fr) 40px;
  padding: 22px 0; border-top: 1px solid var(--line);
  isolation: isolate; overflow: hidden;
  transition: color .35s var(--ease), padding .35s var(--ease);
}
.toc-list li:first-child .toc-row { border-top: 0; }
.toc-row::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: var(--ink); transform: scaleY(0); transform-origin: bottom;
  transition: transform .45s var(--ease);
}
.toc-row:hover, .toc-row:focus-visible { color: var(--bg); padding-left: 16px; padding-right: 16px; }
.toc-row:hover::before, .toc-row:focus-visible::before { transform: scaleY(1); }
.toc-row:hover .mono, .toc-row:focus-visible .mono { color: var(--accent); }
.toc-t { font-size: clamp(34px, 4.6vw, 64px); line-height: 1; letter-spacing: -.025em; }
.toc-d { color: inherit; opacity: .7; font-size: 15px; }
.toc-a { justify-self: end; }
.toc-a .ico { width: 26px; height: 26px; transition: transform .35s var(--ease); }
.toc-row:hover .toc-a .ico { transform: translateX(4px) rotate(-45deg); color: var(--accent); }
@media (max-width: 720px) {
  .toc-row { grid-template-columns: 36px 1fr 28px; gap: 6px 14px; }
  .toc-d { grid-column: 2; grid-row: 2; }
  .toc-a { grid-row: 1 / 3; grid-column: 3; }
}

/* ---------- Contact ---------- */
.contact { margin-top: clamp(64px, 9vw, 120px); background: var(--ink); color: var(--bg); }
.contact-in {
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
  padding-top: clamp(40px, 6vw, 64px); padding-bottom: clamp(40px, 6vw, 64px);
}
.talk { font-size: clamp(40px, 5vw, 64px); line-height: 1; letter-spacing: -.03em; }
.talk em { color: var(--accent); }
.talk-sub { margin-top: 10px; font-size: 16px; color: color-mix(in srgb, var(--bg) 70%, var(--ink)); }
.c-links { display: flex; gap: 12px; flex-wrap: wrap; }
.c-link { display: grid; justify-items: center; gap: 10px; width: 88px; }
.c-ico {
  width: 64px; height: 64px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid color-mix(in srgb, var(--bg) 30%, var(--ink));
  transition: background-color .2s, border-color .2s, color .2s, transform .3s var(--ease);
}
.c-ico .ico { width: 24px; height: 24px; }
.c-lbl { color: color-mix(in srgb, var(--bg) 60%, var(--ink)) !important; transition: color .2s; }
.c-link:hover .c-ico, .c-link:focus-visible .c-ico { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); transform: translateY(-3px); }
.c-link:hover .c-lbl { color: var(--bg) !important; }
@media (max-width: 480px) {
  .c-links { gap: 4px; width: 100%; justify-content: space-between; }
  .c-link { width: 72px; }
  .c-ico { width: 56px; height: 56px; }
}

/* ---------- Pied de page ---------- */
.footer-in {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-top: 24px; padding-bottom: 32px;
}
.footer a { display: inline-flex; gap: 6px; align-items: center; color: var(--ink-2); }
.footer a:hover { color: var(--accent); }
.footer .ico { width: 14px; height: 14px; }
[data-page="home"] ~ .footer { background: var(--ink); }
[data-page="home"] ~ .footer .footer-in { border-top: 1px solid color-mix(in srgb, var(--bg) 25%, var(--ink)); }
[data-page="home"] ~ .footer, [data-page="home"] ~ .footer .mono, [data-page="home"] ~ .footer a { color: color-mix(in srgb, var(--bg) 60%, var(--ink)); }

/* ---------- Pages internes ---------- */
.page { padding-top: clamp(24px, 4vw, 48px); padding-bottom: 40px; }
.page-head { padding-bottom: clamp(28px, 4vw, 48px); }
.back {
  display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3);
  transition: color .2s, gap .2s;
}
.back .ico { width: 15px; height: 15px; }
.back:hover { color: var(--accent); gap: 12px; }
.page-title {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
  margin-top: 28px; padding-bottom: 14px; border-bottom: 1px solid var(--line-strong);
}
.page-title .num { order: 2; padding-bottom: 12px; }
.page-title h1 { font-size: clamp(60px, 11vw, 160px); line-height: .85; letter-spacing: -.04em; }
.lead { margin-top: 20px; max-width: 60ch; font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-2); text-wrap: pretty; }

.next-sec {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
  margin-top: clamp(56px, 8vw, 96px); padding-top: 20px; border-top: 1px solid var(--line-strong);
}
.next-link { display: grid; justify-items: end; gap: 6px; text-align: right; }
.next-link .display { display: inline-flex; align-items: center; gap: 12px; font-size: clamp(36px, 5vw, 64px); line-height: 1; transition: color .2s; }
.next-link .display .ico { width: 30px; height: 30px; transition: transform .35s var(--ease); }
.next-link:hover .display { color: var(--accent); }
.next-link:hover .ico { transform: translateX(6px); }

/* ---------- Parcours ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.filter {
  display: inline-flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line); font-size: 14px;
  transition: background-color .2s, border-color .2s, color .2s;
}
.filter .mono { font-size: 11px; }
.filter:hover { border-color: var(--ink); }
.filter[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.filter[aria-pressed="true"] .mono { color: var(--accent); }
.filter[aria-pressed="true"] .sw-dev, .filter[aria-pressed="true"] .sw-project { border-color: var(--bg); }
.filter[aria-pressed="true"] .sw-project { background: var(--bg); }

.exp {
  display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px;
  padding: 36px 0; border-bottom: 1px solid var(--line);
  scroll-margin-top: 96px;
}
.exp[hidden] { display: none; }
.exp-list .exp:first-child { border-top: 1px solid var(--line); }
.exp.focus { animation: flash 2.2s var(--ease); }
@keyframes flash { 0%, 30% { background: var(--accent-soft); box-shadow: 0 0 0 12px var(--accent-soft); } 100% { background: transparent; box-shadow: 0 0 0 12px transparent; } }
.exp-when { display: grid; align-content: start; gap: 6px; }
.exp-when .mono { color: var(--ink-2); }
.dur { font-family: var(--serif); font-style: italic; font-size: 22px; color: var(--ink-3); }
.live { display: inline-flex; align-items: center; gap: 8px; color: var(--accent) !important; }
.exp-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.exp h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(30px, 3.4vw, 42px); line-height: 1.05; letter-spacing: -.02em; }
.exp-co { margin-top: 8px; color: var(--ink-2); }
.exp-co strong { color: var(--ink); font-weight: 600; }
.exp-co .sep { color: var(--ink-3); }
.exp-sum { margin-top: 14px; font-size: 17px; max-width: 70ch; }
.bullets { margin-top: 18px; display: grid; gap: 10px; max-width: 78ch; }
.bullets li { position: relative; padding-left: 22px; color: var(--ink-2); }
.bullets li::before {
  content: ''; position: absolute; left: 2px; top: .62em;
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
}
.bullets b { color: var(--ink); font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; max-width: 78ch; }
.chips li { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14px; }
.plain { margin-top: 16px; display: grid; gap: 6px; }
.plain li { padding-left: 20px; position: relative; color: var(--ink-2); }
.plain li::before { content: ''; position: absolute; left: 0; top: .72em; width: 10px; height: 1px; background: var(--ink-3); }
.note { margin-top: 14px; font-size: 14px; color: var(--ink-3); }
.note .mono { margin-right: 8px; }
.apps { margin-top: 20px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.apps li { padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); display: grid; gap: 6px; align-content: start; }
.apps .mono { color: var(--accent); }
.apps b { font-weight: 600; }
.apps p { font-size: 14.5px; color: var(--ink-2); }
.apps-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 78ch; }
@media (max-width: 760px) { .apps, .apps-2 { grid-template-columns: 1fr; } }

.more { margin-top: 22px; border-top: 1px solid var(--line); max-width: 78ch; }
.more summary {
  display: flex; align-items: center; gap: 10px; padding: 14px 0; cursor: pointer; list-style: none;
  font-weight: 500;
}
.more summary::-webkit-details-marker { display: none; }
.more summary:hover { color: var(--accent); }
.count { padding: 2px 8px; border: 1px solid var(--line); border-radius: 999px; font-size: 10.5px; }
.plus { position: relative; width: 14px; height: 14px; margin-left: auto; flex: none; }
.plus::before, .plus::after { content: ''; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px; background: currentColor; transition: transform .3s var(--ease); }
.plus::after { transform: rotate(90deg); }
.more[open] .plus::after, .key.open .plus::after { transform: rotate(0deg); }
.det { display: grid; padding-bottom: 8px; }
.det li { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 10px 0; border-top: 1px dashed var(--line); font-size: 15px; }
.det .kind { padding-top: 3px; }
.det-t { color: var(--ink-2); }
.det a { display: inline-flex; align-items: center; gap: 3px; color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }
.det a:hover { color: var(--accent); }
.off { font-style: normal; font-size: 10px; padding: 1px 6px; border: 1px solid var(--line); border-radius: 999px; }
.more[open] .det { animation: rise .45s var(--ease); }

@media (max-width: 760px) {
  .exp { grid-template-columns: 1fr; gap: 14px; padding: 28px 0; }
  .exp-when { grid-auto-flow: column; justify-content: start; align-items: baseline; gap: 12px; }
  .dur { font-size: 18px; }
  .det li { grid-template-columns: 1fr; gap: 2px; }
}

/* ---------- Compétences ---------- */
.block { padding-top: 32px; margin-top: 32px; border-top: 1px solid var(--line-strong); }
.page-head + .block { margin-top: 0; }
.mono-h { display: flex; align-items: baseline; gap: 12px; margin-bottom: 18px; font-size: 15px; font-weight: 500; text-transform: uppercase; letter-spacing: .04em; }
.mono-h .mono { color: var(--accent); }
.hint { font-size: 14px; margin: -8px 0 16px; }
.keys { border-top: 1px solid var(--line); }
.key { border-bottom: 1px solid var(--line); }
.key-btn {
  width: 100%; display: grid; grid-template-columns: 40px 1fr auto 18px; align-items: center; gap: 16px;
  padding: 12px 0; text-align: left;
  transition: color .2s, padding .3s var(--ease);
}
.key-t { font-size: 17px; font-weight: 500; line-height: 1.3; letter-spacing: -.01em; }
.key-n { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); font-size: 10.5px; }
.key-btn:hover { color: var(--accent); padding-left: 8px; }
.key.open .key-btn { color: var(--accent); }
.key-used { display: grid; gap: 8px; padding: 0 0 20px 56px; animation: rise .4s var(--ease); }
.key-used[hidden] { display: none; }
.used {
  display: flex; align-items: center; flex-wrap: wrap; gap: 4px 12px;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  transition: border-color .2s;
}
.used b { font-weight: 600; }
.used span:not(.mono) { color: var(--ink-2); }
.used .ico { margin-left: auto; transition: transform .3s var(--ease); }
.used:hover { border-color: var(--ink); }
.used:hover .ico { transform: translateX(4px); color: var(--accent); }
@media (max-width: 600px) {
  .key-btn { grid-template-columns: 28px 1fr auto 14px; gap: 10px; }
  .key-used { padding-left: 0; }
}

.skills-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 48px; }
@media (max-width: 860px) { .skills-grid { grid-template-columns: 1fr; } }
.langs li { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.langs li:first-child { border-top: 1px solid var(--line); }
.l-name { font-family: var(--serif); font-size: 30px; line-height: 1; }
.l-lbl { grid-column: 1 / -1; }
.meter { display: flex; gap: 5px; }
.meter i {
  width: 26px; height: 8px; border-radius: 2px; background: var(--line); position: relative; overflow: hidden;
}
.meter i::after { content: ''; position: absolute; inset: 0; background: var(--accent); transform: scaleX(var(--f)); transform-origin: left; }
.certs { display: grid; gap: 10px; }
.cert {
  display: grid; grid-template-columns: auto 1fr; gap: 2px 16px; align-items: baseline;
  padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
}
.cert-n { font-size: 34px; line-height: 1; grid-row: span 2; min-width: 3.4ch; }
.cert-t { font-weight: 500; }

.book-in { display: grid; grid-template-columns: 180px 1fr; gap: 32px; align-items: center; }
.cover {
  aspect-ratio: 2 / 3; padding: 16px 14px; border-radius: 2px 6px 6px 2px;
  background: var(--accent); color: var(--accent-ink);
  display: flex; flex-direction: column; justify-content: space-between;
  box-shadow: inset 6px 0 0 color-mix(in srgb, #000 18%, transparent), 10px 12px 0 -2px var(--line);
  transform: rotate(-3deg); transition: transform .5s var(--ease);
}
.book-in:hover .cover { transform: rotate(0) translateY(-4px); }
.cover-img {
  display: block; border-radius: 2px 4px 4px 2px; overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line), 10px 12px 0 -2px var(--line);
  transform: rotate(-3deg); transition: transform .5s var(--ease);
}
.cover-img img { width: 100%; height: auto; }
.book-in:hover .cover-img { transform: rotate(0) translateY(-4px); }
.cover .mono { color: inherit; opacity: .8; font-size: 9.5px; }
.cover-t { font-family: var(--serif); font-size: 30px; line-height: .95; letter-spacing: -.02em; }
.cover-s { font-size: 10.5px; line-height: 1.35; opacity: .85; }
.book-t { font-size: clamp(32px, 4.4vw, 56px); line-height: 1; letter-spacing: -.025em; }
.book-s { font-size: 18px; margin: 10px 0 12px; color: var(--ink-2); }
.book-btn { margin-top: 20px; }
.book-btn .ico-sm { width: 15px; height: 15px; }
@media (max-width: 600px) { .book-in { grid-template-columns: 120px 1fr; gap: 20px; } .cover-t { font-size: 20px; } .cover-s { display: none; } }

/* Liste « fiche technique » : texte simple, rien de cliquable */
.spec { display: flex; flex-wrap: wrap; row-gap: 10px; }
.spec li {
  font-family: var(--serif); font-size: clamp(22px, 2.2vw, 28px); line-height: 1.1; letter-spacing: -.01em;
  padding: 0 18px; border-left: 1px solid var(--line);
}
.spec li:first-child { padding-left: 0; border-left: 0; }
.sub-l { margin-bottom: 12px; }
.ai-grid { display: grid; grid-template-columns: 1.1fr 1fr 1fr; gap: 32px; align-items: start; }
.ai-grid .spec { display: grid; gap: 8px; }
.ai-grid .spec li { padding: 0 0 8px; border-left: 0; border-bottom: 1px solid var(--line); }
.concept { padding-left: 24px; border-left: 1px solid var(--line); display: grid; gap: 8px; }
.concept h3 { font-size: clamp(26px, 2.6vw, 34px); line-height: 1; letter-spacing: -.02em; }
.concept h3::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-right: 10px; vertical-align: middle; }
.concept p { color: var(--ink-2); }
@media (max-width: 860px) {
  .ai-grid { grid-template-columns: 1fr; gap: 24px; }
  .concept { padding-left: 0; border-left: 0; padding-top: 20px; border-top: 1px solid var(--line); }
}

/* ---------- Formation ---------- */
.edu { border-top: 1px solid var(--line-strong); }
.edu-item { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 32px; padding: 36px 0; border-bottom: 1px solid var(--line); }
.edu-when { display: grid; align-content: start; gap: 8px; }
.edu-y { font-size: clamp(56px, 7vw, 96px); line-height: .85; letter-spacing: -.04em; color: var(--ink-3); transition: color .3s; }
.edu-item:hover .edu-y { color: var(--accent); }
.edu h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3.2vw, 40px); line-height: 1.08; letter-spacing: -.02em; }
.edu-lvl { margin-top: 6px; font-size: 17px; color: var(--ink-2); }
.edu-school { margin-top: 10px; color: var(--ink) !important; }
.edu-more { margin-top: 18px; }
.edu-proj { padding-bottom: 12px; animation: rise .45s var(--ease); }
.edu-proj ul { border-left: 1px solid var(--line); margin-left: 4px; }
.edu-proj li { position: relative; display: grid; grid-template-columns: 90px 1fr; gap: 12px; padding: 7px 0 7px 18px; color: var(--ink-2); }
.edu-proj li::before { content: ''; position: absolute; left: -4px; top: 15px; width: 7px; height: 7px; border-radius: 50%; background: var(--bg); border: 1.5px solid var(--accent); }
.edu-proj li .mono { padding-top: 3px; color: var(--ink); }
@media (max-width: 760px) {
  .edu-item { grid-template-columns: 1fr; gap: 12px; }
  .edu-proj li { grid-template-columns: 1fr; gap: 0; }
}

/* ---------- Centres d'intérêt ---------- */
.other { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.other-card {
  padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
  display: grid; gap: 10px; align-content: start;
}
.other-card h3 { font-size: clamp(28px, 3vw, 38px); line-height: 1.05; letter-spacing: -.02em; }
.other-card p { color: var(--ink-2); }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; color: var(--accent) !important; margin-top: 6px; }
.link-arrow .ico { width: 15px; height: 15px; transition: transform .3s var(--ease); }
.link-arrow:hover .ico { transform: translateX(4px); }
.likes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.likes li {
  display: grid; align-content: space-between; gap: 40px; min-height: 220px; padding: 22px;
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
  transition: background-color .3s, color .3s;
}
.like-ico svg { width: 52px; height: 52px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; transition: transform .5s var(--ease); }
.like-t { font-family: var(--serif); font-size: clamp(24px, 2.4vw, 32px); line-height: 1.1; letter-spacing: -.015em; }
.likes li:hover { background: var(--accent); color: var(--accent-ink); }
.likes li:hover .like-ico svg { transform: rotate(-8deg) scale(1.08); }
@media (max-width: 860px) { .likes { grid-template-columns: 1fr 1fr; } .likes li { min-height: 170px; } }
@media (max-width: 600px) { .other { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .likes { grid-template-columns: 1fr; } .likes li { min-height: 0; grid-template-columns: auto 1fr; align-items: center; gap: 16px; } .like-ico svg { width: 40px; height: 40px; } }

/* ---------- Toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 60;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 18px; border-radius: 999px; font-size: 14px; font-weight: 500;
  transition: opacity .2s, transform .3s var(--ease);
}
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Impression ---------- */
@media print {
  .topbar, .footer, .cta, .back, .next-sec, .filters, .toast, .chip-btn, .tl-scroll { display: none !important; }
  body { background: #fff; color: #000; }
  .rise { animation: none; }
  details > * { display: block; }
  .contact { background: none; color: #000; }
}
