@font-face {
  font-family: "Source Serif 4";
  src: url("../volige-lettres/source-serif-4.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("../volige-lettres/source-serif-4-italic.woff2") format("woff2");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Outfit";
  src: url("../volige-lettres/outfit.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --pin: #d4a574;
  --resine: #5c3a1e;
  --neige: #f7f2ea;
  --nuit: #1a211c;
  --mousse: #3e5340;
  --pin-clair: #e8c9a4;
  --neige-ombre: #ebe4d6;
  --resine-douce: #7a5233;
  --serif: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --sans: "Outfit", "Avenir Next", "Segoe UI", sans-serif;
  --cadre: min(1180px, calc(100% - 2rem));
  --futaie-h: 4.5rem;
}

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

html {
  overflow-x: clip;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--neige);
  color: var(--nuit);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.6;
  font-weight: 400;
}

body.nappes-ouvertes {
  overflow: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--resine);
}

h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

p {
  margin: 0 0 1rem;
}

.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.saut {
  position: absolute;
  left: 0.75rem;
  top: -4rem;
  z-index: 80;
  background: var(--pin);
  color: var(--nuit);
  padding: 0.7rem 1rem;
  min-height: 44px;
  font-weight: 600;
  text-decoration: none;
}

.saut:focus {
  top: 0.75rem;
}

.cadre {
  width: var(--cadre);
  margin-inline: auto;
}

/* Dark timber header — stacked boards */
.futaie {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--nuit);
  color: var(--neige);
  min-height: var(--futaie-h);
  box-shadow: inset 0 -3px 0 var(--resine), 0 8px 24px rgba(26, 33, 28, 0.28);
}

.futaie__veine {
  height: 7px;
  background:
    repeating-linear-gradient(
      180deg,
      #24302a 0 2px,
      #141a16 2px 3px,
      #2c2418 3px 5px,
      #1a211c 5px 7px
    );
}

.futaie__barre {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: calc(var(--futaie-h) - 7px);
  padding-block: 0.35rem;
}

.sceau {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: inherit;
  text-decoration: none;
  min-height: 44px;
}

.sceau svg {
  width: 38px;
  height: 38px;
  flex: none;
}

.sceau b {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}

.sceau small {
  display: block;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pin);
}

.levier {
  margin-left: auto;
  width: 44px;
  height: 44px;
  border: 1px solid var(--pin);
  background: transparent;
  color: var(--pin);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  padding: 0;
}

.levier i {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
}

.levier[aria-expanded="true"] i:first-of-type {
  transform: translateY(3.5px) rotate(40deg);
}

.levier[aria-expanded="true"] i:last-of-type {
  transform: translateY(-3.5px) rotate(-40deg);
}

.nappes {
  display: none;
}

.nappes.is-open {
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: var(--futaie-h) 0 0;
  background: var(--nuit);
  padding: 1rem 1.25rem 2rem;
  gap: 0;
  overflow: auto;
}

.nappes a {
  color: var(--neige);
  text-decoration: none;
  min-height: 44px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid #2a332e;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.nappes a[aria-current="page"] {
  color: var(--pin);
}

.nappes .clou {
  margin-top: 1.25rem;
  justify-content: center;
  border: 0;
}

.clou {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 44px;
  padding: 0.7rem 1.15rem;
  background: var(--pin);
  color: var(--nuit);
  text-decoration: none;
  font-weight: 600;
  border: 0;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 0.95rem;
}

.clou:hover,
.clou:focus-visible {
  background: var(--pin-clair);
}

.clou--nuit {
  background: var(--neige);
  color: var(--nuit);
}

.clou--fil {
  background: transparent;
  color: var(--pin);
  box-shadow: inset 0 0 0 1.5px var(--pin);
}

.clou--fil:hover {
  background: rgba(212, 165, 116, 0.12);
}

.gestes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

/* Stacked roof chapters */
.strates {
  position: relative;
}

.strate {
  position: relative;
  border-bottom: 3px solid var(--resine);
}

.strate--nuit {
  background: var(--nuit);
  color: var(--neige);
}

.strate--resine {
  background: var(--resine);
  color: var(--neige);
}

.strate--mousse {
  background: var(--mousse);
  color: var(--neige);
}

.strate--neige {
  background: var(--neige);
  color: var(--nuit);
}

.strate--pin {
  background: var(--pin);
  color: var(--nuit);
}

.strate__cran {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0 0;
  font-family: var(--sans);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 600;
}

.strate--nuit .strate__cran,
.strate--resine .strate__cran,
.strate--mousse .strate__cran {
  color: var(--pin);
}

.strate__cran b {
  font-variant-numeric: tabular-nums;
}

.strate__corps {
  padding: 1.4rem 0 2.4rem;
}

.strate h1 {
  font-size: clamp(2.1rem, 7vw, 4.4rem);
  margin: 0.2rem 0 1rem;
}

.strate h1 em,
.strate h2 em {
  font-style: italic;
  font-weight: 500;
}

.strate h2 {
  font-size: clamp(1.7rem, 4vw, 2.7rem);
  margin: 0 0 0.8rem;
}

.strate h3 {
  font-size: 1.35rem;
  margin: 0 0 0.45rem;
}

.strate .chapeau {
  font-size: 1.12rem;
  max-width: 38rem;
}

.strate--nuit a:not(.clou),
.strate--resine a:not(.clou),
.strate--mousse a:not(.clou) {
  color: var(--pin);
}

.liteau {
  height: 8px;
  background:
    repeating-linear-gradient(
      90deg,
      var(--resine) 0 42px,
      var(--nuit) 42px 46px,
      var(--resine-douce) 46px 88px,
      var(--nuit) 88px 92px
    );
}

.volige-bande {
  height: 14px;
  background:
    repeating-linear-gradient(
      180deg,
      #c4925e 0 4px,
      #d4a574 4px 7px,
      #b8844c 7px 10px,
      #e0b88a 10px 14px
    );
}

.couverture-bande {
  height: 18px;
  background:
    repeating-linear-gradient(
      90deg,
      #324336 0 28px,
      #3e5340 28px 30px,
      #2a382c 30px 56px
    );
}

.figure-strate {
  margin: 1.2rem 0 0;
}

.figure-strate figcaption {
  font-size: 0.82rem;
  margin-top: 0.45rem;
  opacity: 0.8;
}

.figure-strate img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  filter: saturate(0.88) contrast(1.04);
}

.strate--nuit .figure-strate img,
.strate--resine .figure-strate img,
.strate--mousse .figure-strate img {
  box-shadow: 0 0 0 1px rgba(247, 242, 234, 0.12);
}

.paire {
  display: grid;
  gap: 1.25rem;
}

.nasse {
  display: grid;
  gap: 1rem;
}

.tuile-couche {
  background: var(--neige);
  color: var(--nuit);
  padding: 1.1rem 1.1rem 1.2rem;
  text-decoration: none;
  display: block;
  min-height: 44px;
  border-left: 6px solid var(--pin);
}

.tuile-couche strong {
  display: block;
  font-family: var(--serif);
  font-size: 1.25rem;
  margin-bottom: 0.3rem;
}

.tuile-couche span {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--resine);
  margin-bottom: 0.4rem;
}

.strate--neige .tuile-couche {
  background: #fffdf8;
  box-shadow: 0 0 0 1px var(--neige-ombre);
}

.liste-cran {
  list-style: none;
  margin: 0;
  padding: 0;
}

.liste-cran li {
  display: grid;
  grid-template-columns: 2.4rem 1fr;
  gap: 0.6rem;
  padding: 0.75rem 0;
  border-top: 1px solid currentColor;
  border-color: color-mix(in srgb, currentColor 18%, transparent);
}

.liste-cran b {
  font-variant-numeric: tabular-nums;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
}

.machine-svg {
  width: min(100%, 420px);
  height: auto;
}

.repere {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--mousse);
}

.strate--nuit .repere,
.strate--resine .repere,
.strate--mousse .repere {
  color: var(--pin);
}

.demo {
  font-size: 0.85rem;
  opacity: 0.8;
}

.galerie-strates {
  display: grid;
  gap: 0.75rem;
}

.galerie-strates a,
.galerie-strates figure {
  margin: 0;
}

.galerie-strates img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.galerie-strates figcaption {
  font-size: 0.8rem;
  padding: 0.45rem 0 0;
}

.guide-carte {
  padding: 1.2rem 0;
  border-top: 1px solid var(--neige-ombre);
}

.guide-carte h3 {
  margin-top: 0;
}

.faq details {
  border-bottom: 1px solid var(--neige-ombre);
}

.faq summary {
  min-height: 44px;
  display: flex;
  align-items: center;
  cursor: pointer;
  font-weight: 600;
  padding: 0.7rem 0;
}

.faq details p {
  padding-bottom: 0.9rem;
}

.feuille {
  display: grid;
  gap: 0.85rem;
  max-width: 34rem;
}

.feuille label {
  display: grid;
  gap: 0.3rem;
  font-weight: 600;
  font-size: 0.92rem;
}

.feuille input,
.feuille select,
.feuille textarea {
  min-height: 44px;
  border: 1px solid var(--resine);
  background: #fffdf8;
  color: var(--nuit);
  font: inherit;
  padding: 0.55rem 0.7rem;
}

.feuille textarea {
  min-height: 8rem;
  resize: vertical;
}

.avis {
  padding: 0.85rem 1rem;
  background: var(--pin);
  color: var(--nuit);
  font-weight: 600;
}

.avis[hidden] {
  display: none;
}

.pied {
  background: var(--nuit);
  color: var(--neige);
  padding: 2.4rem 0 1.4rem;
}

.pied a {
  color: var(--pin);
  text-decoration: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.pied h2 {
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pin);
  font-family: var(--sans);
  margin: 0 0 0.4rem;
}

.pied nav {
  display: grid;
}

.pied__grille {
  display: grid;
  gap: 1.5rem;
}

.pied__base {
  margin-top: 1.8rem;
  padding-top: 1rem;
  border-top: 1px solid #2a332e;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.2rem;
  font-size: 0.86rem;
}

.pied button {
  background: none;
  border: 0;
  color: var(--pin);
  font: inherit;
  cursor: pointer;
  min-height: 44px;
  padding: 0;
  text-align: left;
}

.eorce {
  position: fixed;
  z-index: 60;
  inset-inline: 0;
  bottom: 0;
  background: var(--neige);
  color: var(--nuit);
  border-top: 4px solid var(--pin);
  padding: 1rem;
  display: grid;
  gap: 0.8rem;
  box-shadow: 0 -12px 40px rgba(26, 33, 28, 0.2);
}

.eorce[hidden] {
  display: none;
}

.eorce__gestes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.eorce a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  font-weight: 600;
}

.page-intro {
  padding-top: 0.4rem;
}

.legal p,
.legal li {
  max-width: 42rem;
}

@media (min-width: 820px) {
  .levier {
    display: none;
  }

  .nappes,
  .nappes.is-open {
    display: flex;
    flex-direction: row;
    position: static;
    inset: auto;
    background: transparent;
    padding: 0;
    margin-left: auto;
    gap: 0.15rem 1rem;
    align-items: center;
    overflow: visible;
  }

  .nappes a {
    border: 0;
    font-size: 0.92rem;
    color: var(--neige);
  }

  .nappes .clou {
    margin-top: 0;
    margin-left: 0.4rem;
  }

  .paire {
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 2rem;
  }

  .paire--inverse {
    grid-template-columns: 0.9fr 1.1fr;
  }

  .paire--inverse .figure-strate {
    order: -1;
  }

  .nasse {
    grid-template-columns: repeat(3, 1fr);
  }

  .galerie-strates {
    grid-template-columns: repeat(2, 1fr);
  }

  .galerie-strates.trois {
    grid-template-columns: repeat(3, 1fr);
  }

  .pied__grille {
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
  }

  .eorce {
    left: 1.2rem;
    right: auto;
    bottom: 1.2rem;
    width: min(34rem, calc(100% - 2.4rem));
    inset-inline: auto;
  }

  .strate__corps {
    padding: 2rem 0 3rem;
  }
}

@media (min-width: 1100px) {
  .strates {
    padding-left: 4.5rem;
  }

  .coupe-rail {
    position: fixed;
    top: var(--futaie-h);
    left: 0;
    width: 4.5rem;
    bottom: 0;
    background: var(--nuit);
    color: var(--pin);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1.2rem 0.45rem 1.4rem;
    font-size: 0.62rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    z-index: 20;
    border-right: 1px solid #2a332e;
  }
}

.coupe-rail {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
