
@font-face {
  font-family: 'Barlow Semi Condensed';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/barlow-semi-condensed-600.woff2) format('woff2');
}
@font-face {
  font-family: 'Barlow Semi Condensed';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/barlow-semi-condensed-700.woff2) format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin.woff2) format('woff2');
}

:root {
  color-scheme: light;
  --bg: #f5f2eb;
  --surface: #ffffff;
  --surface-alt: #ebe5d8;
  --surface-elevated: #faf8f3;
  --ink: #0f2027;
  --muted: #465b65;
  --line: #cfc7b6;
  --line-strong: #9c927e;
  --teal: #0d4a5a;
  --teal-bright: #0284c7;
  --ochre: #c96428;
  --ochre-soft: #f5e6d6;
  --badge-bg: #dfeff4;
  --badge-ink: #093a47;
  --slate-hero: #0b1922;
  --slate-panel: #112634;
  --slate-line: #1f3f54;
  --font-display: 'Barlow Semi Condensed', system-ui, -apple-system, sans-serif;
  --font-body: 'IBM Plex Sans', system-ui, -apple-system, sans-serif;
  --font-mono: ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  --radius-sm: 4px;
  --radius-md: 6px;
  --shadow: 0 8px 24px rgba(11, 25, 34, 0.07);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1922;
  --surface: #112430;
  --surface-alt: #162e3d;
  --surface-elevated: #142a38;
  --ink: #edf5f8;
  --muted: #9abbc9;
  --line: #213f52;
  --line-strong: #325b73;
  --teal: #38bdf8;
  --teal-bright: #7dd3fc;
  --ochre: #f59e0b;
  --ochre-soft: #292117;
  --badge-bg: #173849;
  --badge-ink: #7dd3fc;
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    color-scheme: dark;
    --bg: #0b1922;
    --surface: #112430;
    --surface-alt: #162e3d;
    --surface-elevated: #142a38;
    --ink: #edf5f8;
    --muted: #9abbc9;
    --line: #213f52;
    --line-strong: #325b73;
    --teal: #38bdf8;
    --teal-bright: #7dd3fc;
    --ochre: #f59e0b;
    --ochre-soft: #292117;
    --badge-bg: #173849;
    --badge-ink: #7dd3fc;
    --shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17.5px;
  line-height: 1.72;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 0.2em; transition: color 0.16s ease; }
a:hover { color: var(--ochre); }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}
p, ul, ol, dl, figure { margin: 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip {
  position: absolute; left: 16px; top: -100px; z-index: 100;
  background: var(--ochre); color: #fff; padding: 10px 18px; border-radius: var(--radius-sm);
  font-weight: 700; text-decoration: none;
}
.skip:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }

.wrap { width: min(1280px, calc(100% - 40px)); margin-inline: auto; }

/* ==========================================================================
   STRICT SINGLE-LINE TOPBAR (HEIGHT: 64PX, NO WRAP, ZERO SUBTITLE OVERFLOW)
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 95%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  white-space: nowrap;
  height: 64px;
  gap: 1.25rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.brand-logo {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}
.brand-name {
  font-family: var(--font-display);
  font-size: 1.38rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  white-space: nowrap;
}
.brand-name span {
  color: var(--ochre);
  margin-left: 3px;
}
.main-nav {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  white-space: nowrap;
  gap: 1.5rem;
}
.main-nav a {
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  white-space: nowrap;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
}
.main-nav a.active,
.main-nav a:hover {
  color: var(--ochre);
  border-bottom-color: var(--ochre);
}
.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  white-space: nowrap;
}
.nav-cta {
  display: inline-flex;
  align-items: center;
  background: var(--teal);
  color: #ffffff !important;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.nav-cta:hover {
  background: var(--ochre);
  color: #ffffff !important;
}
:root[data-theme="dark"] .nav-cta {
  color: #07131a !important;
}
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] .nav-cta {
    color: #07131a !important;
  }
}
.nav-burger {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
}
.mobile-nav-drawer {
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding-block: 14px 18px;
}
.mobile-nav-links {
  display: grid;
  gap: 8px;
}
.mobile-nav-links a {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid var(--line);
  background: var(--surface-elevated);
}
.mobile-nav-links .mobile-nav-cta {
  background: var(--teal);
  color: #ffffff !important;
  border-color: var(--teal);
  text-align: center;
  font-weight: 700;
}
:root[data-theme="dark"] .mobile-nav-links .mobile-nav-cta {
  color: #07131a !important;
}

/* ==========================================================================
   HERO ATLAS TOPOGRAPHIQUE — SPLIT ASYMÉTRIQUE 55% / 45% SUR FOND #0b1922
   ========================================================================== */
.hero-atlas {
  background-color: var(--slate-hero);
  background-image:
    linear-gradient(to right, rgba(56, 189, 248, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(56, 189, 248, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  color: #edf5f8;
  border-bottom: 2px solid var(--ochre);
  padding-block: 44px 52px;
}
.hero-split {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: 36px;
  align-items: stretch;
}
.hero-topo-left {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.coord-bar {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.77rem;
  letter-spacing: 0.08em;
  color: #7dd3fc;
  background: rgba(17, 38, 52, 0.9);
  border: 1px solid var(--slate-line);
  border-left: 3px solid #f59e0b;
  padding: 7px 12px;
  margin-bottom: 18px;
  width: fit-content;
}
.coord-sep { color: #567d94; }
.hero-topo-left h1 {
  font-size: clamp(2.35rem, 4.1vw, 3.65rem);
  line-height: 1.05;
  color: #ffffff;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}
.hero-lead {
  font-size: 1.04rem;
  line-height: 1.66;
  color: #c5dce6;
  margin-bottom: 24px;
  max-width: 64ch;
}

/* Interactive 3-Tab Massif Selector inside Hero */
.massif-selector-box {
  background: var(--slate-panel);
  border: 1px solid var(--slate-line);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.massif-tabs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 14px;
  background: rgba(8, 18, 25, 0.65);
  border-bottom: 1px solid var(--slate-line);
  font-family: var(--font-mono);
  font-size: 0.73rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #9abbc9;
}
.massif-tablist {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--slate-line);
  background: #0d1e29;
}
.massif-tab {
  border: 0;
  border-right: 1px solid var(--slate-line);
  background: transparent;
  color: #9abbc9;
  padding: 12px 14px;
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 700;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: background 0.15s ease, color 0.15s ease;
}
.massif-tab:last-child { border-right: 0; }
.massif-tab small {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 400;
  color: #6c93a6;
}
.massif-tab[aria-selected="true"] {
  background: #173345;
  color: #ffffff;
  box-shadow: inset 0 3px 0 #f59e0b;
}
.massif-tab[aria-selected="true"] small {
  color: #7dd3fc;
}
.massif-panel {
  padding: 18px 18px 16px;
}
.massif-telemetry-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 14px;
}
.telemetry-cell {
  background: rgba(11, 25, 34, 0.72);
  border: 1px solid var(--slate-line);
  padding: 9px 11px;
  border-radius: var(--radius-sm);
}
.telemetry-cell span {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #87aebf;
  margin-bottom: 3px;
}
.telemetry-cell strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.03rem;
  color: #ffffff;
}
.massif-canyons-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.massif-canyon-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}
.massif-canyon-item strong {
  color: #ffffff;
  font-weight: 600;
}
.massif-canyon-item code {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.14);
  padding: 2px 6px;
  border-radius: 3px;
  white-space: nowrap;
}
.massif-panel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--slate-line);
  font-size: 0.84rem;
}
.massif-panel-footer a {
  color: #7dd3fc;
  font-weight: 700;
  text-decoration: none;
}
.massif-panel-footer a:hover { color: #f59e0b; }

/* Right Column (45%): Framed Vertical Topographic Photography + V.A.E Gauge Overlay */
.hero-topo-right {
  display: flex;
  flex-direction: column;
}
.hero-photo-frame {
  position: relative;
  flex: 1;
  min-height: 490px;
  border: 1px solid var(--slate-line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #071117;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.hero-photo-frame img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
}
.hero-photo-frame::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(11, 25, 34, 0.55) 0%, rgba(11, 25, 34, 0.08) 38%, rgba(11, 25, 34, 0.92) 100%);
}
.frame-top-bar {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #e2f1f8;
  background: rgba(11, 25, 34, 0.65);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(6px);
}
.vae-gauge-overlay {
  position: relative;
  z-index: 2;
  margin: 14px;
  padding: 16px 18px;
  background: rgba(11, 25, 34, 0.92);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-left: 4px solid #f59e0b;
  border-radius: var(--radius-sm);
  backdrop-filter: blur(10px);
}
.vae-gauge-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.vae-gauge-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #7dd3fc;
}
.vae-gauge-code {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  color: #0b1922;
  background: #f59e0b;
  padding: 2px 9px;
  border-radius: 3px;
}
.vae-gauge-bars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.vae-bar-cell {
  background: rgba(255, 255, 255, 0.06);
  padding: 7px 9px;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.vae-bar-cell strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.98rem;
  color: #ffffff;
}
.vae-bar-cell span {
  display: block;
  font-size: 0.74rem;
  color: #b4d2e0;
  line-height: 1.3;
}
.vae-gauge-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.vae-gauge-actions a.gauge-calc-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #f59e0b;
  color: #0b1922 !important;
  font-weight: 700;
  font-size: 0.84rem;
  padding: 7px 13px;
  border-radius: 3px;
  text-decoration: none;
}
.vae-gauge-actions a.gauge-norm-link {
  font-size: 0.8rem;
  color: #7dd3fc;
  text-decoration: none;
  font-weight: 600;
}

/* ==========================================================================
   TABLE DES TOPOS & FICHES DE TERRAIN HORIZONTALES (6 GUIDES)
   ========================================================================== */
.section-block { padding-block: 52px; }
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}
.section-head h2 {
  font-size: clamp(1.85rem, 3vw, 2.65rem);
  margin-top: 4px;
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ochre);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.topo-marker {
  width: 8px;
  height: 8px;
  background: var(--teal);
  display: inline-block;
  transform: rotate(45deg);
}

.topo-fiches-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}
.topo-fiche-card {
  display: grid;
  grid-template-columns: 124px 1fr;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}
.topo-fiche-card:hover {
  border-color: var(--ochre);
  box-shadow: var(--shadow);
}
.topo-fiche-rail {
  background: var(--slate-hero);
  color: #edf5f8;
  padding: 16px 12px;
  border-right: 2px solid var(--ochre);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 12px;
}
.topo-fiche-code {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  color: #7dd3fc;
  letter-spacing: 0.06em;
}
.topo-fiche-cotation {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: #0b1922;
  background: #f59e0b;
  padding: 5px 8px;
  border-radius: 3px;
  line-height: 1.2;
  text-align: center;
}
.topo-fiche-read {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: #9abbc9;
  letter-spacing: 0.05em;
}
.topo-fiche-main {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.topo-fiche-header {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 14px;
  align-items: center;
}
.topo-fiche-thumb {
  display: block;
  aspect-ratio: 16 / 11;
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-alt);
}
.topo-fiche-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.topo-fiche-sector {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ochre);
  margin-bottom: 4px;
}
.topo-fiche-title {
  font-size: 1.28rem;
  line-height: 1.18;
}
.topo-fiche-title a { text-decoration: none; }
.topo-fiche-desc {
  font-size: 0.91rem;
  color: var(--muted);
  line-height: 1.58;
}
.topo-fiche-specs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 10px 12px;
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: 3px;
  font-size: 0.78rem;
}
.topo-fiche-specs dt {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-transform: uppercase;
  color: var(--muted);
  letter-spacing: 0.04em;
}
.topo-fiche-specs dd {
  margin: 2px 0 0;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}
.topo-fiche-footer {
  margin-top: auto;
  padding-top: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 0.82rem;
}
.topo-fiche-updated {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
}
.topo-fiche-link {
  font-weight: 700;
  color: var(--teal);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ==========================================================================
   ATLAS SECTORS MATRIX (3 COMPARTIMENTS TOPOGRAPHIQUES BORD À BORD)
   ========================================================================== */
.atlas-sectors-strip {
  padding-block: 44px 16px;
}
.atlas-sectors-matrix {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--line-strong);
  background: var(--surface);
}
.atlas-sector-cell {
  padding: 24px;
  border-right: 1px solid var(--line-strong);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.atlas-sector-cell:last-child { border-right: 0; }
.atlas-sector-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
}
.atlas-sector-cell h3 {
  font-size: 1.55rem;
}
.atlas-sector-cell h3 a { text-decoration: none; }
.atlas-sector-cell p {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.62;
}
.card-cta {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--teal);
  text-decoration: none;
}

/* ==========================================================================
   INTERACTIVE SELECTOR & CALCULATOR
   ========================================================================== */
.selector-shell {
  margin-block: 40px;
  background: var(--surface);
  border: 2px solid var(--teal);
  border-radius: var(--radius-sm);
  padding: 32px;
  box-shadow: var(--shadow);
}
.selector-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  flex-wrap: wrap;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 26px;
}
.selector-header h2 { font-size: clamp(1.8rem, 2.8vw, 2.45rem); margin-block: 6px 8px; }
.selector-sub { color: var(--muted); max-width: 72ch; font-size: 0.96rem; }
.vae-mini-legend { display: flex; flex-wrap: wrap; gap: 8px; }
.vae-tag {
  background: var(--badge-bg);
  color: var(--badge-ink);
  border: 1px solid var(--line);
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  font-weight: 600;
}
.selector-grid {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 30px;
  align-items: start;
}
.selector-controls {
  background: var(--surface-alt);
  padding: 22px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  display: grid;
  gap: 18px;
}
.control-group { display: grid; gap: 7px; }
.control-group label { font-size: 0.88rem; font-weight: 700; }
.control-group select {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  background: var(--surface);
  font-size: 0.92rem;
}
.control-group input[type="range"] {
  width: 100%;
  accent-color: var(--ochre);
}
.range-hints {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
}
.control-actions { display: grid; gap: 10px; padding-top: 4px; }
.btn-secondary, .btn-outline, .btn-primary {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  border: 1px solid var(--line-strong);
  background: var(--surface);
}
.btn-outline { border-color: var(--teal); color: var(--teal); }
.btn-primary {
  background: var(--ochre);
  color: #ffffff !important;
  border-color: var(--ochre);
}

.calc-cards-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}
.calc-output-card {
  padding: 18px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  border-left: 5px solid var(--teal);
  background: var(--surface-alt);
}
.calc-output-card.neoprene-card { border-left-color: var(--ochre); }
.calc-card-kicker {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 6px;
}
.calc-big-value {
  display: block;
  font-family: var(--font-display);
  font-size: 1.45rem;
  color: var(--ink);
  margin-bottom: 6px;
}
.calc-output-card p { font-size: 0.88rem; color: var(--muted); line-height: 1.55; }

.matched-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}
.matched-header h3 { font-size: 1.38rem; }
.matched-note { font-family: var(--font-mono); font-size: 0.76rem; color: var(--ochre); font-weight: 700; }
.matched-canyons-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.mini-canyon-card {
  background: var(--surface-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.mini-canyon-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.mini-sector { font-family: var(--font-mono); font-size: 0.72rem; font-weight: 700; color: var(--muted); text-transform: uppercase; }
.cotation-badge {
  background: var(--teal);
  color: #fff;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 2px 8px;
  border-radius: 3px;
}
:root[data-theme="dark"] .cotation-badge { color: #06151d; }
.mini-canyon-card h4 { font-size: 1.24rem; }
.mini-canyon-card > p { font-size: 0.88rem; color: var(--muted); line-height: 1.52; }
.mini-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding-block: 8px;
  border-block: 1px solid var(--line);
  font-size: 0.78rem;
}
.mini-metrics dt { color: var(--muted); font-size: 0.68rem; font-family: var(--font-mono); }
.mini-metrics dd { margin: 2px 0 0; font-weight: 700; }
.mini-vigilance { font-size: 0.8rem !important; color: var(--ink) !important; }

.safety-checklist-panel {
  background: var(--ochre-soft);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 20px 22px;
}
.safety-checklist-panel h3 { font-size: 1.25rem; margin-bottom: 12px; }
.safety-checks-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 18px;
}
.safety-checks-grid label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.86rem;
  line-height: 1.48;
  cursor: pointer;
}
.safety-checks-grid input {
  width: 17px;
  height: 17px;
  margin-top: 3px;
  accent-color: var(--teal);
  flex-shrink: 0;
}

/* ==========================================================================
   JOURNAL DISPATCH & ARTICLE / GUIDE LAYOUT
   ========================================================================== */
.journal-dispatch {
  display: grid;
  grid-template-columns: 380px 1fr;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.journal-dispatch-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.journal-dispatch-body {
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
}
.journal-dispatch-body h3 { font-size: 1.85rem; }
.journal-dispatch-body h3 a { text-decoration: none; }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding-top: 24px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted);
}
.breadcrumbs a { text-decoration: none; }
.article-header {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 36px;
  align-items: center;
  padding-block: 30px 40px;
  border-bottom: 2px solid var(--ink);
}
.article-header h1 { font-size: clamp(2.1rem, 3.8vw, 3.3rem); margin-block: 10px 16px; }
.article-lead { font-size: 1.1rem; color: var(--muted); line-height: 1.72; }
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted);
}
.article-hero-figure img {
  border-radius: var(--radius-sm);
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border: 1px solid var(--line-strong);
}
.article-hero-figure figcaption {
  font-family: var(--font-mono);
  font-size: 0.73rem;
  color: var(--muted);
  margin-top: 6px;
  text-align: right;
}

.article-grid {
  display: grid;
  grid-template-columns: 270px minmax(0, 760px);
  gap: 48px;
  justify-content: space-between;
  padding-block: 44px;
}
.toc-aside {
  position: sticky;
  top: 88px;
  align-self: start;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 20px;
}
.toc-aside nav { display: flex; flex-direction: column; margin-top: 10px; }
.toc-aside nav a {
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.86rem;
  text-decoration: none;
  line-height: 1.42;
  display: flex;
  gap: 10px;
}
.toc-aside nav a span { font-family: var(--font-mono); color: var(--ochre); font-weight: 700; }
.toc-aside .toc-cta {
  margin-top: 14px;
  display: block;
  text-align: center;
  background: var(--teal);
  color: #fff !important;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.84rem;
}
:root[data-theme="dark"] .toc-aside .toc-cta { color: #06151d !important; }

.article-prose { font-size: 1.03rem; line-height: 1.8; min-width: 0; }
.article-prose section { margin-top: 40px; scroll-margin-top: 84px; }
.article-prose h2 { font-size: clamp(1.6rem, 2.5vw, 2.1rem); margin-bottom: 16px; }
.article-prose p + p { margin-top: 16px; }
.article-prose ul { padding-left: 20px; margin-top: 16px; }
.article-prose li { margin-bottom: 9px; line-height: 1.72; }

.takeaway-box {
  background: var(--surface-alt);
  border: 1px solid var(--line-strong);
  border-left: 5px solid var(--teal);
  border-radius: var(--radius-sm);
  padding: 22px 24px;
}
.takeaway-box p:last-child { font-size: 1.02rem; font-weight: 500; margin-top: 8px; }

.table-wrap {
  overflow-x: auto;
  margin-top: 22px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
table { width: 100%; border-collapse: collapse; text-align: left; font-size: 0.9rem; }
th, td { padding: 12px 15px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th {
  background: var(--surface-alt);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }

.faq-section details {
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-bottom: 10px;
}
.faq-section summary { font-weight: 700; font-size: 1.02rem; cursor: pointer; }
.faq-section details p { margin-top: 10px; color: var(--muted); font-size: 0.96rem; }

.sources-box {
  margin-top: 44px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
}
.sources-box h2 { font-size: 1.4rem; margin-block: 6px 10px; }
.sources-box ul { margin-block: 12px; }
.sources-disclaimer {
  font-size: 0.84rem;
  color: var(--muted);
  background: var(--surface-alt);
  padding: 12px 15px;
  border-radius: var(--radius-sm);
  margin-top: 14px;
}

/* Newsletter Band */
.newsletter-band {
  margin-block: 52px;
  padding: 36px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-left: 6px solid var(--ochre);
  border-radius: var(--radius-sm);
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: center;
}
.nl-band-copy h2 { font-size: clamp(1.65rem, 2.6vw, 2.25rem); margin-block: 8px 12px; }
.nl-band-copy p { color: var(--muted); font-size: 0.95rem; }
.nl-band-form { display: grid; gap: 10px; }
.nl-band-form label { font-weight: 700; font-size: 0.88rem; }
.nl-input-row { display: flex; gap: 8px; }
.nl-input-row input[type="email"] {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg);
  font-size: 16px;
}
.nl-consent {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.78rem !important;
  font-weight: 400 !important;
  color: var(--muted);
}
.nl-consent input { margin-top: 4px; accent-color: var(--teal); }
.newsletter-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.filter-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.filter-pills a {
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  background: var(--surface);
}
.filter-pills a.selected {
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
}
:root[data-theme="dark"] .filter-pills a.selected { color: #06151d; }

/* Footer */
.site-footer {
  background: var(--surface);
  border-top: 2px solid var(--ink);
  padding-top: 48px;
  margin-top: 56px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.45fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 40px;
}
.footer-coords {
  margin-top: 12px;
  font-family: var(--font-mono);
  font-size: 0.73rem;
  color: var(--ochre);
  letter-spacing: 0.06em;
}
.footer-mission { margin-top: 10px; font-size: 0.91rem; color: var(--muted); max-width: 48ch; }
.footer-emergency {
  margin-top: 12px;
  font-size: 0.82rem;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface-alt);
}
.footer-heading {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ochre);
  margin-bottom: 14px;
}
.footer-links { list-style: none; padding: 0; display: grid; gap: 9px; font-size: 0.9rem; }
.footer-links a { text-decoration: none; }
.footer-consent-btn {
  background: none;
  border: 0;
  padding: 0;
  font-size: 0.9rem;
  color: var(--muted);
  text-decoration: underline;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  padding-block: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.82rem;
  color: var(--muted);
}

/* Theme Picker */
.theme-picker {
  border: 1px solid var(--line-strong);
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 3px;
  display: inline-flex;
  gap: 4px;
  margin: 0;
}
.theme-picker button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 5px 10px;
  border-radius: 3px;
  font-size: 0.78rem;
  font-weight: 600;
}
.theme-picker button svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}
.theme-picker button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--bg);
}

/* Consent Dialog */
dialog#analytics-consent {
  position: fixed;
  right: 20px;
  bottom: 20px;
  left: auto;
  top: auto;
  z-index: 200;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--teal);
  border-radius: var(--radius-sm);
  padding: 20px 22px;
  max-width: 410px;
  width: calc(100% - 32px);
  margin: 0;
  box-shadow: var(--shadow);
}
dialog#analytics-consent::backdrop { background: rgba(6, 16, 22, 0.58); }
dialog#analytics-consent h2 { font-size: 1.55rem; margin-block: 8px 10px; }
dialog#analytics-consent p { font-size: 0.9rem; color: var(--muted); line-height: 1.6; }
dialog#analytics-consent > a { display: inline-block; margin-top: 10px; font-size: 0.84rem; }
.dialog-close {
  position: absolute;
  top: 10px;
  right: 12px;
  border: 0;
  background: transparent;
  font-size: 1.4rem;
  color: var(--muted);
}
.choices { display: flex; gap: 10px; margin-top: 18px; }
.choices button {
  flex: 1;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.9rem;
  border: 1px solid var(--line-strong);
}
.btn-deny { background: var(--surface-alt); color: var(--ink); }
.btn-accept { background: var(--teal); color: #fff; border-color: var(--teal); }
:root[data-theme="dark"] .btn-accept { color: #06151d; }

/* Responsive (< 1024px clean hamburger transition) */
@media (max-width: 1023px) {
  .main-nav,
  .nav-cta {
    display: none;
  }
  .nav-burger {
    display: inline-flex;
  }
  .hero-split,
  .selector-grid,
  .article-header,
  .article-grid,
  .newsletter-band,
  .topo-fiches-grid,
  .journal-dispatch {
    grid-template-columns: 1fr;
  }
  .atlas-sectors-matrix {
    grid-template-columns: 1fr;
  }
  .atlas-sector-cell {
    border-right: 0;
    border-bottom: 1px solid var(--line-strong);
  }
  .atlas-sector-cell:last-child { border-bottom: 0; }
  .toc-aside { position: static; }
}

@media (max-width: 680px) {
  body { font-size: 16.5px; }
  .wrap { width: calc(100% - 28px); }
  .topo-fiche-card {
    grid-template-columns: 1fr;
  }
  .topo-fiche-rail {
    flex-direction: row;
    align-items: center;
    border-right: 0;
    border-bottom: 2px solid var(--ochre);
    padding: 10px 14px;
  }
  .topo-fiche-header {
    grid-template-columns: 1fr;
  }
  .topo-fiche-specs,
  .massif-telemetry-grid,
  .massif-canyons-list,
  .calc-cards-row,
  .matched-canyons-grid,
  .safety-checks-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .massif-tablist {
    grid-template-columns: 1fr;
  }
  .selector-shell, .newsletter-band { padding: 20px; }
  .nl-input-row { flex-direction: column; }
}
