/* ---------------------------------------------------------------
   Kezak — services.kezak.ch
   La direction artistique de kezak.ch, reprise telle quelle :
   palette cyanotype (cinq valeurs d'un seul bleu, plus un réactif),
   Lineal pour les titres, Spectral pour le texte, Cutive Mono pour
   les étiquettes. Ne jamais introduire de couleur hors de cette liste.
   --------------------------------------------------------------- */

/* --- Polices (fichiers dans /fonts) ------------------------------ */
@font-face { font-family: 'Lineal'; src: url('/fonts/Lineal-Thin.woff2') format('woff2'); font-weight: 200; font-display: swap; }
@font-face { font-family: 'Lineal'; src: url('/fonts/Lineal-Light.woff2') format('woff2'); font-weight: 300; font-display: swap; }
@font-face { font-family: 'Lineal'; src: url('/fonts/Lineal-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Spectral'; src: url('/fonts/Spectral-Light.woff2') format('woff2'); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: 'Spectral'; src: url('/fonts/Spectral-LightItalic.woff2') format('woff2'); font-weight: 300; font-style: italic; font-display: swap; }
@font-face { font-family: 'Spectral'; src: url('/fonts/Spectral-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Cutive Mono'; src: url('/fonts/CutiveMono-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }

/* --- Jetons -------------------------------------------------------- */
:root {
  --abysse: #0a1428;
  --cuve: #16233c;
  --ardoise: #5c6b85;
  --brume: #aeb9d0;
  --papier: #e9edf2;
  --reactif: #8fe3c8;
  --reactif-profond: #0f6b55;
  --filet-nuit: #1e2c45;
  --filet-nuit-fort: #33456a;
  --filet-papier: #c3cbd8;
  --texte-papier-doux: #46566f;

  /* Rôles — mode nuit (défaut) */
  --fond: var(--abysse);
  --texte: var(--papier);
  --texte-doux: var(--brume);
  --filet: var(--filet-nuit);
  --filet-fort: var(--filet-nuit-fort);
  --filet-champ: var(--ardoise);
  --accent: var(--reactif);
  --accent-contraste: var(--abysse);

  --display: 'Lineal', 'Jost', ui-sans-serif, system-ui, sans-serif;
  --texte-famille: 'Spectral', Georgia, 'Times New Roman', serif;
  --mono: 'Cutive Mono', ui-monospace, 'Courier New', monospace;

  --t-100: clamp(0.78rem, 0.76rem + 0.1vw, 0.82rem);
  --t-200: clamp(0.94rem, 0.9rem + 0.2vw, 1rem);
  --t-300: clamp(1.06rem, 1rem + 0.3vw, 1.19rem);
  --t-400: clamp(1.2rem, 1.1rem + 0.5vw, 1.5rem);
  --t-500: clamp(1.4rem, 1.2rem + 1vw, 1.95rem);
  --t-600: clamp(1.7rem, 1.35rem + 1.75vw, 2.45rem);
  --t-700: clamp(2.1rem, 1.5rem + 3vw, 3.4rem);
  --t-800: clamp(2.6rem, 1.6rem + 5vw, 4.75rem);
  --t-900: clamp(2.9rem, 1.4rem + 7.4vw, 7rem);

  --interligne-texte: 1.7;
  --interligne-titre: 1.08;
  --mesure: 42rem;
  --ls-logo-petit: 0.18em;
  --ls-titre: 0.03em;
  --ls-etiquette: 0.18em;

  --e-1: clamp(0.25rem, 0.2rem + 0.2vw, 0.4rem);
  --e-2: clamp(0.5rem, 0.4rem + 0.3vw, 0.75rem);
  --e-3: clamp(0.75rem, 0.6rem + 0.5vw, 1.15rem);
  --e-4: clamp(1rem, 0.8rem + 0.9vw, 1.75rem);
  --e-5: clamp(1.5rem, 1.1rem + 1.6vw, 2.75rem);
  --e-6: clamp(2.25rem, 1.5rem + 3vw, 4.5rem);
  --e-7: clamp(3.5rem, 2rem + 5vw, 7rem);

  --gouttiere: clamp(1.25rem, 0.5rem + 3.4vw, 5rem);
  --largeur-planche: 76rem;
  --hauteur-bandeau: 3.875rem;

  --duree: 400ms;
  --duree-lente: 800ms;
  --courbe: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* Mode planche : les sections de lecture, sur fond papier. */
[data-mode='planche'] {
  --fond: var(--papier);
  --texte: var(--abysse);
  --texte-doux: var(--texte-papier-doux);
  --filet: var(--filet-papier);
  --filet-fort: var(--filet-papier);
  --filet-champ: var(--texte-papier-doux);
  --accent: var(--reactif-profond);
  --accent-contraste: var(--papier);
}

/* --- Socle ---------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  background: var(--abysse);
}

body {
  margin: 0;
  background: var(--fond);
  color: var(--texte);
  font-family: var(--texte-famille);
  font-weight: 300;
  font-size: var(--t-300);
  line-height: var(--interligne-texte);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 200;
  line-height: var(--interligne-titre);
  letter-spacing: var(--ls-titre);
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; max-width: var(--mesure); text-wrap: pretty; }
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--accent); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.evitement {
  position: absolute;
  left: var(--gouttiere);
  top: -100%;
  z-index: 100;
  background: var(--accent);
  color: var(--accent-contraste);
  padding: var(--e-3) var(--e-4);
  font-family: var(--mono);
  font-size: var(--t-100);
  letter-spacing: var(--ls-etiquette);
  text-transform: uppercase;
  text-decoration: none;
}
.evitement:focus { top: var(--e-3); }

/* « hidden » l'emporte toujours, même sur un « display: flex » de classe :
   sans cette règle, le champ « Nombre de personnes » restait affiché. */
[hidden] { display: none !important; }

.visuellement-cache {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* --- Éléments de la DA --------------------------------------------- */
.mono, .etiquette {
  font-family: var(--mono);
  font-size: var(--t-100);
  letter-spacing: var(--ls-etiquette);
  text-transform: uppercase;
  color: var(--texte-doux);
}
.etiquette--accent { color: var(--accent); }

.contenu { width: 100%; padding-inline: var(--gouttiere); }
.contenu--planche { max-width: calc(var(--largeur-planche) + 2 * var(--gouttiere)); margin-inline: auto; }

.coins { display: flex; justify-content: space-between; align-items: center; gap: var(--e-4); flex-wrap: wrap; }

/* Le bouton : un rectangle au trait qui s'inverse. Jamais d'arrondi. */
.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: var(--e-3) var(--e-5);
  border: 1px solid var(--accent);
  background: transparent;
  color: var(--accent);
  font-family: var(--mono);
  font-size: var(--t-100);
  letter-spacing: var(--ls-etiquette);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--duree) var(--courbe), color var(--duree) var(--courbe);
}
.bouton:hover, .bouton:focus-visible { background: var(--accent); color: var(--accent-contraste); }
.bouton--plein { background: var(--accent); color: var(--accent-contraste); }
.bouton--plein:hover, .bouton--plein:focus-visible { background: transparent; color: var(--accent); }

/* --- Bandeau -------------------------------------------------------- */
.bandeau {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  height: var(--hauteur-bandeau);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--e-4);
  padding-inline: var(--gouttiere);
  background: rgba(10, 20, 40, 0.82);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--filet-nuit);
}
.bandeau__marque { display: inline-flex; align-items: center; gap: var(--e-3); text-decoration: none; color: var(--papier); }
.monogramme {
  width: 1.4rem; height: 1.4rem;
  display: grid; place-items: center;
  border: 1px solid var(--reactif);
  color: var(--reactif);
  font-family: var(--display);
  font-weight: 400;
  font-size: 0.8rem;
  line-height: 1;
}
.bandeau__mot { font-family: var(--display); font-weight: 300; font-size: 1rem; letter-spacing: var(--ls-logo-petit); text-transform: uppercase; }
.bandeau__nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.5vw, 2rem);
  font-family: var(--mono);
  font-size: var(--t-100);
  letter-spacing: var(--ls-etiquette);
  text-transform: uppercase;
}
.bandeau__nav a { color: var(--papier); text-decoration: none; padding-block: 0.6rem; }
.bandeau__nav a:hover { color: var(--reactif); }
.bandeau__nav a.bouton { color: var(--reactif); padding: 0.7rem 1.1rem; }
.bandeau__nav a.bouton:hover { color: var(--abysse); }

.bandeau__bascule {
  display: none;
  width: 44px; height: 44px;
  background: none; border: 0;
  cursor: pointer;
  align-items: center; justify-content: center;
}
.bandeau__traits { display: grid; gap: 6px; width: 22px; }
.bandeau__traits i { display: block; height: 1px; background: var(--papier); transition: transform var(--duree) var(--courbe); }
.bandeau__bascule[aria-expanded='true'] .bandeau__traits i:first-child { transform: translateY(3.5px) rotate(45deg); }
.bandeau__bascule[aria-expanded='true'] .bandeau__traits i:last-child { transform: translateY(-3.5px) rotate(-45deg); }

@media (max-width: 47.99rem) {
  .bandeau__bascule { display: flex; }
  /* Sans script, le menu reste déplié dans le flux : la page garde une
     navigation. Avec, il devient un tiroir sous le bandeau. */
  .bandeau { height: auto; min-height: var(--hauteur-bandeau); flex-wrap: wrap; }
  .bandeau__nav { width: 100%; flex-direction: column; align-items: flex-start; gap: 0; padding-bottom: var(--e-4); }
  html.js-ok .bandeau { height: var(--hauteur-bandeau); flex-wrap: nowrap; }
  html.js-ok .bandeau__nav {
    display: none;
    position: absolute;
    inset: 100% 0 auto 0;
    width: auto;
    background: var(--abysse);
    border-bottom: 1px solid var(--filet-nuit);
    padding: var(--e-4) var(--gouttiere) var(--e-5);
  }
  html.js-ok .bandeau__nav.ouvert { display: flex; }
  .bandeau__nav a { width: 100%; padding-block: var(--e-4); border-bottom: 1px solid var(--filet-nuit); }
  .bandeau__nav a.bouton { margin-top: var(--e-4); width: auto; border-bottom: 1px solid var(--reactif); }
}

/* --- Héros ----------------------------------------------------------- */
.heros {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding-top: calc(var(--hauteur-bandeau) + var(--e-6));
  padding-bottom: var(--e-5);
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(ellipse at 18% 30%, rgba(22, 35, 60, 0.9), transparent 60%),
    var(--abysse);
}
.grain { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; opacity: 0.22; }
.heros__corps { display: flex; flex-direction: column; gap: var(--e-5); margin-block: auto; }
.heros h1 { font-size: var(--t-900); font-weight: 200; max-width: 13ch; }
.heros__et { color: var(--reactif); }
.heros__chapo { font-size: var(--t-500); font-weight: 300; line-height: 1.4; color: var(--texte-doux); max-width: 34rem; }
.heros__actions { display: flex; flex-wrap: wrap; gap: var(--e-3); }
.heros__pied { padding-top: var(--e-6); }
.heros__pied a { color: var(--texte-doux); text-decoration: none; display: inline-block; padding-block: 0.75rem; }
.heros__pied a:hover { color: var(--reactif); }

/* --- Sections -------------------------------------------------------- */
.planche, .nuit {
  background: var(--fond);
  color: var(--texte);
  padding-block: var(--e-7);
}
.nuit { border-top: 1px solid var(--filet-nuit); }

/* Une colonne de marge pour l'étiquette, une colonne de lecture. */
.grille { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--e-4); }
@media (min-width: 60rem) {
  .grille { grid-template-columns: 14rem minmax(0, 1fr); gap: var(--e-6); }
  .grille__marge { padding-top: 0.9rem; }
}
.grille__corps { display: flex; flex-direction: column; align-items: flex-start; gap: var(--e-5); min-width: 0; }

h2 { font-size: var(--t-800); }
.chapo { font-size: var(--t-400); line-height: 1.55; color: var(--texte-doux); }

/* Le matériel */
.materiel {
  list-style: none;
  margin: 0;
  padding: 0;
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--texte);
}
@media (min-width: 48rem) { .materiel { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.materiel li {
  display: flex;
  align-items: baseline;
  gap: var(--e-3);
  padding: var(--e-4) var(--e-3) var(--e-4) 0;
  border-bottom: 1px solid var(--filet);
  font-family: var(--display);
  font-weight: 400;
  font-size: var(--t-400);
  line-height: 1.2;
}
.materiel li span:last-child { display: flex; flex-direction: column; gap: 0.2em; }
.materiel small { font-family: var(--texte-famille); font-weight: 300; font-size: var(--t-200); color: var(--texte-doux); }
.materiel__nb { font-weight: 200; font-size: var(--t-700); line-height: 1; color: var(--accent); min-width: 0.7em; }

/* Les prix du studio */
.prix { display: flex; flex-wrap: wrap; gap: var(--e-5) var(--e-6); }
.prix__bloc { display: flex; flex-direction: column; gap: var(--e-2); }
.prix__montant {
  font-family: var(--display);
  font-weight: 200;
  font-size: var(--t-900);
  line-height: 0.9;
  color: var(--accent);
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0 var(--e-3);
}
.prix__montant span { font-weight: 300; font-size: var(--t-400); color: var(--texte); }
.prix__texte { font-family: var(--display); font-weight: 300; font-size: var(--t-600); line-height: 1.1; }

/* Le programme des cours */
.programme { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr); border-top: 1px solid var(--texte); }
@media (min-width: 48rem) { .programme { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--e-5); border-top: 0; } }
.programme__point { display: flex; flex-direction: column; gap: var(--e-2); padding-block: var(--e-4); border-bottom: 1px solid var(--filet-fort); }
@media (min-width: 48rem) { .programme__point { border-bottom: 0; border-top: 1px solid var(--texte); } }
.programme h3 { font-size: var(--t-500); font-weight: 300; }
.programme p { color: var(--texte-doux); }

/* Le tableau des tarifs */
.tableau { width: 100%; display: flex; flex-direction: column; gap: var(--e-3); }
.tableau table { width: 100%; border-collapse: collapse; font-family: var(--display); }
.tableau caption { text-align: left; padding-bottom: var(--e-3); }
.tableau th, .tableau td { text-align: left; vertical-align: baseline; padding: var(--e-3) var(--e-3) var(--e-3) 0; }
.tableau thead th { font-family: var(--mono); font-weight: 400; font-size: var(--t-100); letter-spacing: var(--ls-etiquette); text-transform: uppercase; color: var(--texte-doux); border-bottom: 1px solid var(--texte); }
.tableau tbody th { font-weight: 300; font-size: var(--t-400); }
.tableau tbody td { font-weight: 300; font-size: var(--t-200); color: var(--texte-doux); }
.tableau tbody tr { border-bottom: 1px solid var(--filet-fort); }
.tableau tbody tr:last-child { border-bottom-color: var(--texte); }
.tableau .nombre { text-align: right; padding-right: 0; white-space: nowrap; }
.tableau tbody .nombre { font-weight: 200; font-size: var(--t-700); line-height: 1; color: var(--accent); }
.tableau sup { font-size: 0.6em; }
.tableau__note { font-size: var(--t-200); color: var(--texte-doux); }
/* Sur un téléphone, le lieu passe sous la formule : trois colonnes ne
   tiennent pas dans 320 px sans couper les prix. */
@media (max-width: 37.99rem) {
  .tableau thead th:nth-child(2) { display: none; }
  .tableau tbody td:not(.nombre) { display: block; padding-top: 0; }
  .tableau tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
  .tableau tbody th { padding-bottom: 0.2rem; }
  .tableau tbody td:not(.nombre) { grid-column: 1; grid-row: 2; }
  .tableau tbody .nombre { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .tableau thead tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
}

/* La FAQ */
.faq { width: 100%; border-top: 1px solid var(--texte); }
.faq details { border-bottom: 1px solid var(--filet); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--e-4);
  padding-block: var(--e-4);
  font-family: var(--display);
  font-weight: 300;
  font-size: var(--t-400);
  line-height: 1.25;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-weight: 200; font-size: 1.4em; line-height: 1; color: var(--accent); transition: transform var(--duree) var(--courbe); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding-bottom: var(--e-4); color: var(--texte-doux); }

/* --- Formulaire ------------------------------------------------------ */
.formulaire { width: 100%; max-width: 46rem; display: flex; flex-direction: column; gap: var(--e-4); }
.champs-duo { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--e-4); }
@media (min-width: 40rem) { .champs-duo { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.champ { display: flex; flex-direction: column; gap: var(--e-2); }
.champ label { font-family: var(--mono); font-size: var(--t-100); letter-spacing: var(--ls-etiquette); text-transform: uppercase; color: var(--texte-doux); }
.facultatif { text-transform: none; letter-spacing: 0; color: var(--ardoise); }
.champ input, .champ select, .champ textarea {
  width: 100%;
  min-height: 48px;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--filet-champ);
  border-radius: 0;
  background: var(--cuve);
  color: var(--papier);
  font-family: var(--texte-famille);
  font-size: 1.0625rem; /* ≥ 16 px : iOS ne zoome pas au focus */
  font-weight: 300;
  line-height: 1.5;
}
.champ select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--reactif) 50%), linear-gradient(135deg, var(--reactif) 50%, transparent 50%);
  background-position: calc(100% - 1.15rem) 55%, calc(100% - 0.8rem) 55%;
  background-size: 0.35rem 0.35rem;
  background-repeat: no-repeat;
  padding-right: 2.5rem;
}
.champ textarea { resize: vertical; min-height: 8rem; }
.champ input::placeholder { color: var(--ardoise); }
.champ input:focus-visible, .champ select:focus-visible, .champ textarea:focus-visible { outline: 2px solid var(--reactif); outline-offset: 0; border-color: var(--reactif); }
.champ [aria-invalid='true'] { border-color: var(--reactif); }
.formulaire__erreur { color: var(--reactif); font-family: var(--mono); font-size: var(--t-100); letter-spacing: 0.06em; }
.formulaire__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--e-3) var(--e-4); }
.formulaire__alternative { font-size: var(--t-200); color: var(--texte-doux); }
.formulaire__aide { font-size: var(--t-200); color: var(--texte-doux); }
.formulaire__aide:empty { display: none; }

/* --- Pied ------------------------------------------------------------- */
.pied { background: var(--abysse); border-top: 1px solid var(--filet-nuit); padding-block: var(--e-6) var(--e-5); }
.pied__grille { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--e-5); }
@media (min-width: 48rem) { .pied__grille { grid-template-columns: minmax(0, 1fr) auto; align-items: end; } }
.pied__nom { font-family: var(--display); font-weight: 300; font-size: var(--t-500); letter-spacing: var(--ls-logo-petit); text-transform: uppercase; }
.pied__signature { display: flex; flex-direction: column; gap: var(--e-2); }
.pied__liens { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--e-2) var(--e-4); font-family: var(--mono); font-size: var(--t-100); letter-spacing: var(--ls-etiquette); text-transform: uppercase; }
.pied__liens a { color: var(--papier); text-decoration: none; display: inline-block; padding-block: 0.6rem; }
.pied__liens a:hover { color: var(--reactif); }
.pied__mentions { grid-column: 1 / -1; font-size: var(--t-100); color: var(--ardoise); max-width: none; border-top: 1px solid var(--filet-nuit); padding-top: var(--e-4); }

/* --- Fondu à l'entrée -------------------------------------------------
   Visible par défaut. Masqué seulement là où un script existe pour le
   révéler — et rendu visible au bout de 2,5 s quoi qu'il arrive, si le
   script ne se charge pas. */
@keyframes secours-visible { to { opacity: 1; transform: none; } }
@media (scripting: enabled) and (prefers-reduced-motion: no-preference) {
  .entree {
    opacity: 0;
    transform: translateY(1.25rem);
    transition: opacity var(--duree-lente) var(--courbe), transform var(--duree-lente) var(--courbe);
    animation: secours-visible 1ms linear 2.5s forwards;
  }
  html.js-ok .entree { animation: none; }
  .entree.vu { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* Les ancres ne passent pas sous le bandeau fixe. */
[id] { scroll-margin-top: var(--hauteur-bandeau); }
