/* ============================================
   Studio.Réflec — site public
   Reprend les variables et composants de l'outil de gestion
   (cartes, boutons, champs, filtres, fiche) pour un rendu identique.
   Typo : DM Sans + DM Mono
   ============================================ */

/* --- Variables & Reset (identiques à l'outil) --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #f7f7f7;
  --bg-card: #ffffff;
  --ink: #1a1a1a;
  --ink-muted: #333333;
  --ink-subtle: #424242;
  --border: #e2e2e2;
  --border-focus: rgb(233 233 233 / 50%);
  --accent: #e1e1e1;
  --accent-hover: #282828;
  --danger: #c0392b;
  --success: #27ae60;
  --font-sans: 'DM Sans', sans-serif;
  --font-mono: 'DM Mono', monospace;
  --radius: 6px;
  --radius-lg: 10px;
  --shadow: 0 1px 3px rgba(26, 26, 26, 0.08), 0 4px 12px rgba(26, 26, 26, 0.05);
  --shadow-sm: 0 1px 2px rgba(26, 26, 26, 0.06);
  --transition: 150ms ease;
  --header-h: 64px;
}

html, body {
  min-height: 100%;
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

body { display: flex; flex-direction: column; min-height: 100vh; }

/* ── En-tête du site : blanc, logo à gauche, menu à droite ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: #fff;
  box-shadow: var(--shadow);
}

.site-header-inner {
  max-width: var(--page-w, 1240px);
  margin: 0 auto;
  height: var(--header-h);
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-logo {
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 18px;
  letter-spacing: -0.2px;
  color: #000;
  text-decoration: none;
  white-space: nowrap;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 14px;
}

.site-nav a {
  color: var(--ink);
  font-size: 16px;
  text-decoration: none;
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}
.site-nav a:hover,
.site-nav a.is-active { border-bottom-color: #000; }

.site-nav .nav-sep { color: var(--ink); user-select: none; }
.site-nav .nav-mail { display: none; }   /* affiché seulement dans le menu mobile */

/* Bouton « Espace membre » (vers l'outil de gestion) : .btn-primary, sans le soulignement des liens */
.site-nav .nav-membre {
  margin-left: 10px; padding: 9px 18px;
  font-size: 14px; color: #fff;
  border: 1px solid var(--ink);
}
.site-nav .nav-membre:hover { border-color: var(--accent-hover); }

/* Bouton « Menu » (mobile) : deux traits qui se croisent à l'ouverture */
.nav-burger {
  display: none; align-items: center; gap: 10px;
  background: none; border: none; padding: 8px 0; cursor: pointer;
  font-family: var(--font-sans); font-size: 15px; color: var(--ink);
}
.nav-burger-icon { position: relative; width: 22px; height: 10px; }
.nav-burger-icon i {
  position: absolute; left: 0; width: 100%; height: 1.5px; background: currentColor;
  transition: transform var(--transition), top var(--transition);
}
.nav-burger-icon i:first-child { top: 0; }
.nav-burger-icon i:last-child  { top: 8.5px; }

/* ── Contenu ── */
.site-main { flex: 1; }

.page-container {
  max-width: var(--page-w, 1240px);
  margin: 0 auto;
  padding: 48px 40px;
}

.site-footer { background: var(--ink); }
.site-footer-inner {
  max-width: var(--page-w, 1240px);
  margin: 0 auto;
  padding: 20px 40px;
  font-size: 12px;
  color: #fff;
  text-align: center;
}

/* --- Page header --- */
.page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 36px;
}
.page-header-left { padding-right: 24px; }

.page-eyebrow {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 6px;
}

.page-title {
  font-size: 26px;
  font-weight: 300;
  letter-spacing: -0.5px;
  color: var(--ink);
  line-height: 1.2;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), color var(--transition), border-color var(--transition);
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary { min-height: 40px; background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--border); }
.btn-ghost:hover { background: rgba(26,26,26,0.05); border-color: var(--border-focus); }
.btn-sm { padding: 6px 13px; font-size: 12.5px; }

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--bg-card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.card-body { padding: 28px; }

/* --- Forms --- */
input[type="text"], select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  font-family: var(--font-sans);
  font-size: 13.5px;
  color: var(--ink);
  outline: none;
  transition: border-color var(--transition);
  appearance: none;
}
input:focus, select:focus { border-color: var(--border-focus); }

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%231a1a1a' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

/* --- Search & filters bar --- */
.filters-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.search-input-wrap { position: relative; flex: 1; max-width: 340px; }
.search-input-wrap svg {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: var(--ink-muted); pointer-events: none;
}
.search-input-wrap input { padding-left: 36px; }

/* --- Fiche (mêmes éléments que l'outil) --- */
.client-meta-label {
  font-size: 10.5px; font-weight: 500; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--ink-muted); margin-bottom: 2px;
}
.client-meta-value { font-size: 14px; color: var(--ink); }
.td-mono { font-family: var(--font-mono); font-size: 12.5px; }

.section-title {
  font-size: 11px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-muted); margin-bottom: 16px; margin-top: 36px;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}

.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: 12.5px; color: var(--ink-muted); margin-bottom: 28px;
}
.breadcrumb a { color: var(--ink-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb-sep { font-size: 10px; opacity: 0.5; }

.empty-state { text-align: center; color: var(--ink-muted); }
.empty-state-icon { margin-bottom: 16px; opacity: 0.3; }
.empty-state p { font-size: 14px; }

/* --- Scrollbar subtle --- */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(26,26,26,0.15); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(26,26,26,0.28); }

/* ============================================
   Page Matériel : colonne de catégories + cartes
   ============================================ */
.shop { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 40px; align-items: start; }
.shop-main { min-width: 0; }


/* Catégories (style boutique) : colonne collante qui suit le défilement */
.shop-side {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  max-height: calc(100vh - var(--header-h) - 48px);
  overflow-y: auto;
}
.cat-nav ul { list-style: none; }
.cat-nav a {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 7px 12px; border-radius: var(--radius);
  font-size: 13.5px; color: var(--ink); text-decoration: none;
  transition: background var(--transition), color var(--transition);
}
.cat-nav a:hover { background: rgba(26,26,26,0.05); }
.cat-nav a.is-active { background: var(--ink); color: #fff; }
.cat-nav .cat-count { font-family: var(--font-mono); font-size: 11px; opacity: .55; }
.cat-nav ul ul {
  display: none; margin: 2px 0 6px 12px; padding-left: 10px;
  border-left: 1px solid var(--border);
}
.cat-nav li.is-open > ul { display: block; }
.cat-nav .cat-title { margin-top: 0; }

/* Catégorie parente : lien + chevron qui affiche les sous-catégories sans filtrer */
.cat-row { display: flex; align-items: center; gap: 2px; }
.cat-row > a { flex: 1; min-width: 0; }
.cat-expand {
  flex-shrink: 0; width: 30px; height: 30px;
  display: inline-flex; align-items: center; justify-content: center;
  background: none; border: none; border-radius: var(--radius);
  color: var(--ink-muted); cursor: pointer;
  transition: background var(--transition);
}
.cat-expand:hover { background: rgba(26,26,26,0.05); }
.cat-chevron { transition: transform var(--transition); }
.cat-nav li.is-open > .cat-row .cat-chevron,
.cat-nav.is-expanded .cat-toggle .cat-chevron { transform: rotate(180deg); }

/* Barre « Catégorie : … ▾ » : mobile seulement */
.cat-toggle { display: none; }

/* Retour en haut des résultats (catégorie, pagination) : pas sous l'en-tête collant */
#mat-list { scroll-margin-top: calc(var(--header-h) + 24px); }

/* Cartes (identiques à l'outil) */
.mat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }

.mat-card { display: block; min-width: 0; text-decoration: none; color: inherit; }
.mat-card .card { overflow: hidden; cursor: pointer; transition: box-shadow .15s; height: 100%; }
.mat-card:hover .card { box-shadow: 0 2px 12px rgba(0,0,0,0.10); }

.mat-card-img {
  position: relative; aspect-ratio: 1; background: var(--bg);
  overflow: hidden; border-bottom: 1px solid var(--border);
}
.mat-card-img .mat-ph { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); opacity: .2; }
.mat-card-img img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; background: var(--bg); transition: opacity .25s ease;
}
/* Survol : l'image du contenu recouvre la couverture */
.mat-img-content { opacity: 0; }
.mat-card:hover .mat-img-content { opacity: 1; }

.mat-card-body { padding: 12px 14px; }
.mat-card-body p { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mat-cat   { font-size: 11px; color: var(--ink-muted); margin-bottom: 4px !important; }
.mat-title { font-size: 14px; font-weight: 500; margin-bottom: 2px !important; }
.mat-ident { font-size: 11px; font-family: var(--font-mono); color: var(--ink-muted); }

#mat-list { min-height: 120px; }
.mat-footer { margin-top: 20px; }

/* ============================================
   Fiche : blocs égaux, galerie, calendrier
   ============================================ */
.mat-top { display: flex; align-items: stretch; gap: 40px; margin-bottom: 24px; }

#gallery-caption {
  position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%);
  background: rgba(0,0,0,0.5); color: #fff; font-size: 11.5px;
  padding: 3px 10px; border-radius: 999px; white-space: nowrap; pointer-events: none;
}
#gallery-caption:empty { display: none; }
.gallery-container, #fc-dispo { touch-action: pan-y; }   /* glisser horizontal = image / mois suivant (materiel_detail.php), vertical = défiler la page */

#fc-dispo { font-family: var(--font-sans); font-size: 13px; }
.fc .fc-toolbar { flex-wrap: wrap; gap: 8px; }
.fc .fc-toolbar-title { font-size: 15px; font-weight: 500; color: var(--ink); text-transform: capitalize; }
.fc .fc-button {
  background: transparent; border: 1px solid var(--border); color: var(--ink);
  font-family: var(--font-sans); font-size: 12.5px; padding: 5px 12px;
  border-radius: var(--radius); box-shadow: none; text-transform: none; transition: background 0.15s;
}
.fc .fc-button:hover, .fc .fc-button:focus { background: rgba(0,0,0,0.05); box-shadow: none; }
.fc .fc-button-primary:not(.fc-button-active) { background: transparent; border-color: var(--border); color: var(--ink); }
.fc .fc-col-header-cell-cushion, .fc .fc-daygrid-day-number { color: var(--ink-muted); font-size: 12px; text-decoration: none; }
.fc .fc-day-today .fc-daygrid-day-number { color: var(--ink); font-weight: 700; }
.fc .fc-scrollgrid, .fc .fc-scrollgrid td, .fc .fc-scrollgrid th { border-color: var(--border); }

/* Jours : vert = disponible, rouge = réservé, gris = passé */
.fc .fc-daygrid-day.fc-day-dispo   { background: rgba(34,160,90,0.14); }
.fc .fc-daygrid-day.fc-day-indispo { background: rgba(220,60,60,0.16); }
.fc .fc-daygrid-day.fc-day-passe   { background: rgba(26,26,26,0.06); }
.fc .fc-day-passe .fc-daygrid-day-number { opacity: .5; }

.dispo-legend { display: flex; gap: 16px; font-size: 12px; color: var(--ink-muted); }
.dispo-legend span { display: inline-flex; align-items: center; gap: 6px; }
.dispo-legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* ============================================
   Page d'accueil : « manifeste » typographique
   (index.php, sans .page-container : sections pleine largeur)
   ============================================ */
.home-wrap { max-width: var(--page-w, 1240px); margin: 0 auto; padding: 0 40px; position: relative; }

.home-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 28px;
}

/* Ouverture */
.home-hero { position: relative; overflow: hidden; padding: 120px 0 128px; }
.home-hero-mark {
  position: absolute;
  right: -0.06em;
  top: 50%;
  transform: translateY(-50%);
  font-size: clamp(200px, 34vw, 560px);
  font-weight: 300;
  letter-spacing: -0.06em;
  line-height: 1;
  color: #ebebeb;
  pointer-events: none;
  user-select: none;
  z-index: 0;
}
.home-hero > .home-wrap > :not(.home-hero-mark) { position: relative; z-index: 1; }

.home-title {
  font-size: clamp(44px, 7.6vw, 104px);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.035em;
  max-width: 12ch;
  margin-bottom: 36px;
}
.home-lead {
  font-size: clamp(16px, 1.5vw, 19px);
  line-height: 1.6;
  max-width: 34em;
  color: var(--ink-muted);
  margin-bottom: 40px;
}
.home-actions { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.home-btn { min-height: 48px; padding: 12px 24px; font-size: 14px; }

/* Lien texte souligné + flèche qui glisse au survol */
.home-link {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}
.home-arrow { display: inline-block; transition: transform var(--transition); }
.home-btn:hover .home-arrow,
.home-link:hover .home-arrow,
.home-catalogue:hover .home-arrow { transform: translateX(4px); }

/* Sections */
.home-section { padding: 96px 0; border-top: 1px solid var(--border); }
.home-h2 {
  font-size: clamp(28px, 3.6vw, 48px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.025em;
  max-width: 18ch;
  margin-bottom: 64px;
}

/* Le concept : 3 étapes numérotées */
.home-steps { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px; }
.home-steps li { border-top: 1px solid var(--ink); padding-top: 20px; }
.home-num {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(40px, 4.4vw, 64px);
  font-weight: 300;
  line-height: 1;
  margin-bottom: 28px;
}
.home-steps h3, .home-avantages h3 { font-size: 20px; font-weight: 500; letter-spacing: -0.01em; margin-bottom: 10px; }
.home-steps p,  .home-avantages p  { font-size: 15px; line-height: 1.6; color: var(--ink-muted); }

/* Pourquoi mutualiser : grandes lignes séparées par des filets */
.home-avantages { list-style: none; }
.home-avantages li {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 40px;
  align-items: baseline;
  padding: 28px 0;
  border-bottom: 1px solid var(--border);
}
.home-avantages li:first-child { border-top: 1px solid var(--border); }
.home-avantages h3 { font-size: clamp(22px, 2.6vw, 34px); font-weight: 300; letter-spacing: -0.02em; margin: 0; }

/* Le catalogue : grand chiffre */
.home-catalogue { display: flex; align-items: flex-end; gap: 32px; flex-wrap: wrap; color: var(--ink); text-decoration: none; }
.home-catalogue-nb {
  font-size: clamp(96px, 16vw, 220px);
  font-weight: 300;
  line-height: 0.82;
  letter-spacing: -0.05em;
}
.home-catalogue-txt {
  display: flex; flex-direction: column; align-items: flex-start; gap: 16px;
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 300;
  padding-bottom: 6px;
}

/* Rejoindre : bandeau inversé */
.home-contact { background: var(--ink); color: #fff; padding: 112px 0; scroll-margin-top: var(--header-h); }
.home-contact .home-eyebrow,
.home-contact .home-lead { color: rgba(255, 255, 255, 0.72); }
.home-contact .home-link { color: #fff; }
.home-contact .home-h2 { margin-bottom: 28px; }
.home-btn-light { background: #fff; color: var(--ink); border-color: #fff; }

/* Page Contact (contact.php) : mêmes sections que l'accueil */
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; }
.contact-grid > div { border-top: 1px solid var(--ink); padding-top: 20px; }
.contact-big {
  display: block;
  font-size: clamp(22px, 2.8vw, 36px);
  font-weight: 300;
  font-style: normal;
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: var(--ink);
  overflow-wrap: anywhere;
}
.contact-mail { display: inline; text-decoration: none; border-bottom: 1px solid currentColor; }
.contact-mail:hover { border-bottom-width: 2px; }
.home-btn-light:hover { background: #e9e9e9; border-color: #e9e9e9; }

@media (prefers-reduced-motion: reduce) {
  .home-arrow { transition: none; }
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1100px) {
  .mat-top { flex-direction: column; }
}

@media (max-width: 860px) {
  .shop { grid-template-columns: minmax(0, 1fr); gap: 0; }

  /* Catégories sous le titre : .shop-main « s'efface » pour que ses enfants et la colonne partagent la même grille */
  .shop-main { display: contents; }
  .shop-main > .page-header { order: 1; margin-bottom: 20px; }
  .shop-side { order: 2; max-height: none; overflow: visible; }
  .shop-main > :not(.page-header) { order: 3; }

  /* Barre « Catégorie » + recherche : collées sous l'en-tête au défilement (pleine largeur : les cartes
     ne se voient pas sur les côtés). Hauteurs fixes pour empiler les deux : --cat-bar-h = 8 + 48 + 8. */
  .shop { --cat-bar-h: 64px; }
  .shop-side, .shop-main > .filters-bar {
    position: sticky; background: var(--bg);
    margin-left: -20px; margin-right: -20px; padding-left: 20px; padding-right: 20px;
  }
  .shop-side { top: var(--header-h); z-index: 30; padding-top: 8px; padding-bottom: 8px; }
  .shop-main > .filters-bar { top: calc(var(--header-h) + var(--cat-bar-h)); z-index: 29; padding-bottom: 12px; }
  #mat-list { scroll-margin-top: calc(var(--header-h) + var(--cat-bar-h) + 64px); }   /* AjaxList remonte ici : pas sous les barres */

  /* Barre repliable (style boutique) : montre la catégorie choisie, déplie la même liste qu'en desktop */
  .cat-nav .cat-title { display: none; }
  .cat-toggle {
    display: flex; align-items: center; gap: 10px; width: 100%; height: 48px;
    padding: 0 14px; background: var(--bg-card); color: var(--ink);
    border: 1px solid var(--border); border-radius: var(--radius-lg);
    font-family: var(--font-sans); font-size: 14px; text-align: left; cursor: pointer;
  }
  .cat-toggle-label { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-muted); }
  .cat-toggle-current { flex: 1; min-width: 0; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .cat-nav.is-expanded .cat-toggle { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }

  /* Liste dépliée : par-dessus les cartes (menu déroulant), défilante si elle dépasse l'écran */
  .cat-nav { position: relative; }
  .cat-nav > ul {
    display: none; padding: 6px;
    position: absolute; top: 100%; left: 0; right: 0; z-index: 31;
    max-height: calc(100vh - var(--header-h) - var(--cat-bar-h) - 24px); overflow-y: auto;
    background: var(--bg-card); border: 1px solid var(--border); border-top: none;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    box-shadow: var(--shadow);
  }
  .cat-nav.is-expanded > ul { display: block; }
  .cat-nav a { padding: 11px 12px; font-size: 15px; }   /* zones tactiles confortables */
  .cat-expand { width: 44px; height: 44px; }
  .mat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-header-inner, .page-container, .site-footer-inner, .home-wrap { padding-left: 20px; padding-right: 20px; }
  .home-hero { padding: 72px 0 80px; }
  .home-section { padding: 64px 0; }
  .home-contact { padding: 72px 0; }
  .home-h2 { margin-bottom: 40px; }
  .home-steps { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .home-avantages li { grid-template-columns: minmax(0, 1fr); gap: 8px; padding: 22px 0; }
  .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .page-container { padding-top: 32px; padding-bottom: 32px; }
}

/* Menu mobile : bouton « Menu » + navigation plein écran, fond noir, liens en très grand.
   Dès 860 px : logo + liens + bouton « Espace membre » demandent ≈ 650 px, trop serré en dessous. */
@media (max-width: 860px) {
  .nav-burger { display: inline-flex; }
  .site-header { transition: background var(--transition); }

  .site-nav {
    display: none;
    position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0; z-index: 199;
    flex-direction: column; align-items: flex-start; gap: 0;
    padding: 36px 20px 40px; overflow-y: auto;
    background: var(--ink);
    counter-reset: nav;
  }
  .site-nav .nav-sep { display: none; }
  .site-nav a:not(.nav-mail, .nav-membre) {
    counter-increment: nav;
    color: #fff; border-bottom: none; padding: 14px 0;
    font-size: clamp(40px, 12vw, 56px); font-weight: 300; line-height: 1.05; letter-spacing: -0.03em;
  }
  .site-nav a:not(.nav-mail, .nav-membre)::before {
    content: '/// 0' counter(nav);
    display: block; margin-bottom: 6px;
    font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; line-height: 1;
    color: rgba(255, 255, 255, 0.55);
  }
  .site-nav a.is-active { color: rgba(255, 255, 255, 0.55); }
  .site-nav .nav-membre {   /* bouton inversé (blanc sur noir) sous les liens */
    margin: 32px 0 0; padding: 14px 24px; font-size: 15px;
    background: #fff; color: var(--ink); border-color: #fff;
  }
  .site-nav .nav-membre:hover { background: var(--accent); border-color: var(--accent); }
  .site-nav .nav-mail {
    display: block; margin-top: auto; padding-top: 40px;
    font-size: 15px; color: #fff; border-bottom: none; text-decoration: underline; text-underline-offset: 4px;
  }

  /* Menu ouvert : en-tête noir, page figée */
  body.menu-open { overflow: hidden; }
  body.menu-open .site-nav { display: flex; }
  body.menu-open .site-header { background: var(--ink); box-shadow: none; }
  body.menu-open .site-logo,
  body.menu-open .nav-burger { color: #fff; }
  body.menu-open .nav-burger-icon i:first-child { top: 4.25px; transform: rotate(45deg); }
  body.menu-open .nav-burger-icon i:last-child  { top: 4.25px; transform: rotate(-45deg); }
}

@media (max-width: 520px) {
  .mat-grid { grid-template-columns: minmax(0, 1fr); }
  .site-logo { font-size: 16px; }
}
