/* ═══════════════════════════════════════════════════════════════════
   Terreau Fertile · b · Plantes & artisanat
   Thème « plantes » de la charte : planche d'herbier, papier ancien, encre verte, prune et or.
   Rayons presque droits, filets fins, aucune ombre.
   ═══════════════════════════════════════════════════════════════════ */

@font-face { font-family: "Atkinson Next"; font-weight: 400; font-style: normal; font-display: swap; src: url("../assets/fonts/atkinson-next-400.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Next"; font-weight: 400; font-style: italic; font-display: swap; src: url("../assets/fonts/atkinson-next-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Next"; font-weight: 700; font-style: normal; font-display: swap; src: url("../assets/fonts/atkinson-next-700.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-weight: 600; font-style: normal; font-display: swap; src: url("../assets/fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-weight: 600; font-style: italic; font-display: swap; src: url("../assets/fonts/cormorant-garamond-latin-600-italic.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-weight: 500; font-style: italic; font-display: swap; src: url("../assets/fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); }

:root {
  --papier: #F7F3EA;          /* herbier-papier */
  --surface: #ECEDE1;
  --encre: #1F2E26;           /* herbier-encre */
  --gris: #5D6A60;            /* herbier-gris */
  --sauge: #8FA58A;
  --sauge-claire: #DFE6D6;
  --sauge-texte: #55704F;
  --sauge-sur-encre: #A9BBA4;
  --prune: #6B2236;
  --or: #B88A2A;
  --or-texte: #7D5F1A;
  --or-clair: #E8C77A;
  --filet: #CFC6B2;           /* filet-herbier */
  --alerte: #9A2F1E;

  --herbier: "Cormorant Garamond", Cormorant, Garamond, Georgia, serif;
  --texte: "Atkinson Next", "Atkinson Hyperlegible", Verdana, "Segoe UI", system-ui, sans-serif;
  --largeur: 70rem;
  --marge: clamp(1rem, 4vw, 2.5rem);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--papier); color: var(--encre); font-family: var(--texte); font-size: 1.0625rem; line-height: 1.6; }
img { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--herbier); font-weight: 600; line-height: 1.1; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); color: var(--prune); }
h3 { font-size: 1.4rem; }
p { margin: 0 0 1em; max-width: 64ch; }
a { color: var(--encre); text-decoration-color: var(--or); text-underline-offset: 0.18em; }
a:hover { color: var(--prune); }
:focus-visible { outline: 3px solid var(--prune); outline-offset: 3px; }
.enveloppe { max-width: var(--largeur); margin-inline: auto; padding-inline: var(--marge); }
.saut { position: absolute; left: -999rem; top: 0; z-index: 10; background: var(--encre); color: var(--papier); padding: 0.8rem 1rem; }
.saut:focus { left: 0; }
.travail { background: #F4E39A; color: #1E1813; text-align: center; font-size: 0.9rem; padding: 0.5rem 1rem; }
.a-rediger { background: #F4E39A; outline: 2px dashed #B8961C; outline-offset: 2px; }
.libelle { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase; color: var(--sauge-texte); margin: 0 0 0.6rem; }
.latin { font-family: var(--herbier); font-style: italic; font-weight: 600; }
.latin .cultivar { font-style: normal; }
.doux { color: var(--gris); }

/* ── En-tête ── */
.entete { border-bottom: 1px solid var(--filet); }
.entete__ligne { display: flex; align-items: center; gap: 1rem 2rem; flex-wrap: wrap; padding-block: 1rem; }
.entete__marque { margin-right: auto; display: block; }
.entete__marque img { height: 46px; width: auto; }
.entete nav ul { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; list-style: none; margin: 0; padding: 0; }
.entete nav a { text-decoration: none; font-weight: 700; font-size: 0.98rem; padding-block: 0.3rem; border-bottom: 2px solid transparent; }
.entete nav a:hover, .entete nav a[aria-current="page"] { border-bottom-color: var(--or); color: var(--encre); }
.entete nav .vers-coaching { font-weight: 400; color: var(--gris); }

/* ── Planche : double cadre fin ── */
.planche { border: 1px solid var(--filet); outline: 1px solid var(--filet); outline-offset: -7px; border-radius: 6px; padding: clamp(1.5rem, 4vw, 2.75rem); background: var(--papier); }
.planche__tete { display: flex; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--filet); padding-bottom: 0.6rem; margin-bottom: 1.6rem; }
.planche__tete .libelle { margin: 0; }

/* ── Ouverture ── */
.ouverture { padding-block: clamp(2rem, 5vw, 3.5rem); }
.ouverture .chapeau { font-size: 1.15rem; margin-top: 1rem; }
.etapes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; list-style: none; padding: 0; margin: 2rem 0 0; counter-reset: e; }
.etapes li { counter-increment: e; border-top: 1px dotted var(--filet); padding-top: 0.9rem; }
.etapes li::before { content: counter(e, decimal-leading-zero); display: block; font-family: var(--herbier); font-size: 1.6rem; color: var(--or-texte); line-height: 1; margin-bottom: 0.35rem; }
.etapes p { margin: 0; font-size: 0.98rem; }

/* ── Filtres et grille ── */
.catalogue { padding-block: 1rem clamp(3rem, 6vw, 5rem); }
.filtres { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.6rem; }
.filtres button { font: inherit; font-weight: 700; font-size: 0.95rem; background: none; color: var(--encre); border: 1px solid var(--filet); border-radius: 4px; padding: 0.45rem 1rem; cursor: pointer; }
.filtres button[aria-pressed="true"] { background: var(--encre); border-color: var(--encre); color: var(--papier); }
.grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.carte { position: relative; }
.carte a { text-decoration: none; color: inherit; display: block; }
.carte a:hover .carte__nom { color: var(--prune); }
.vignette { aspect-ratio: 4 / 5; background: var(--surface); border: 1px solid var(--filet); border-radius: 4px; overflow: hidden; position: relative; }
.vignette img { width: 100%; height: 100%; object-fit: cover; }
.vignette svg { position: absolute; inset: 18%; width: 64%; height: 64%; color: var(--sauge); }
.carte__code { font-size: 0.72rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--sauge-texte); margin: 0.8rem 0 0.2rem; }
.carte__nom { font-family: var(--herbier); font-size: 1.45rem; line-height: 1.15; margin: 0; }
.carte__commun { color: var(--prune); font-size: 0.98rem; margin: 0.15rem 0 0; }
.carte__bas { display: flex; align-items: baseline; justify-content: space-between; gap: 0.5rem; margin-top: 0.5rem; border-top: 1px dotted var(--filet); padding-top: 0.5rem; }
.prix { font-weight: 700; white-space: nowrap; }
.pastilles { display: flex; flex-wrap: wrap; gap: 0.35rem; position: absolute; top: 0.6rem; left: 0.6rem; }
.pastille { font-size: 0.75rem; font-weight: 700; background: var(--papier); color: var(--encre); border: 1px solid var(--filet); border-radius: 4px; padding: 0.15rem 0.5rem; }
.pastille--reserve { background: var(--or-clair); border-color: var(--or-clair); }
.pastille--vendu { background: var(--encre); border-color: var(--encre); color: var(--papier); }
.pastille--exemple { background: #F4E39A; border-color: #B8961C; }
.carte--vendu .vignette img { filter: grayscale(0.7); opacity: 0.75; }
.vide-catalogue, .erreur-catalogue { border: 1px dashed var(--filet); border-radius: 6px; padding: 2rem; text-align: center; }
.vide-catalogue p, .erreur-catalogue p { margin-inline: auto; }
.erreur-catalogue { border-color: var(--alerte); color: var(--alerte); }

/* ── Fiche article ── */
.retour-catalogue { display: inline-block; margin: 1.5rem 0 1rem; font-size: 0.95rem; }
.fiche { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; padding-bottom: clamp(3rem, 6vw, 5rem); }
.galerie__vignettes { display: flex; gap: 0.5rem; margin-top: 0.6rem; flex-wrap: wrap; }
.galerie__vignettes button { padding: 0; border: 1px solid var(--filet); border-radius: 4px; background: none; cursor: pointer; width: 4.5rem; aspect-ratio: 4 / 5; overflow: hidden; }
.galerie__vignettes button[aria-current="true"] { outline: 2px solid var(--prune); outline-offset: 2px; }
.galerie__vignettes img { width: 100%; height: 100%; object-fit: cover; }
.fiche h1 { font-size: clamp(2rem, 4vw, 3rem); }
.fiche__commun { color: var(--prune); font-size: 1.2rem; margin: 0.3rem 0 1rem; }
.fiche__prix { display: flex; align-items: center; gap: 0.8rem; font-size: 1.4rem; margin: 0 0 1.2rem; }
.fiche__prix .pastille { font-size: 0.85rem; }
.caracteristiques { display: grid; grid-template-columns: auto 1fr; gap: 0.4rem 1.2rem; margin: 1.4rem 0; padding: 1rem 0; border-block: 1px solid var(--filet); }
.caracteristiques dt { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--sauge-texte); padding-top: 0.2rem; }
.caracteristiques dd { margin: 0; }
.jauges { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: 0.8rem; list-style: none; padding: 0; margin: 0 0 1.4rem; }
.jauge { background: color-mix(in srgb, var(--sauge-claire) 45%, var(--papier)); border-radius: 4px; padding: 0.6rem 0.75rem; }
.jauge__tete { display: flex; align-items: center; gap: 0.4rem; font-size: 0.85rem; font-weight: 700; }
.jauge__tete svg { width: 1.2rem; height: 1.2rem; flex: none; }
.jauge__points { display: flex; gap: 0.25rem; margin-top: 0.35rem; }
.jauge__points span { width: 0.6rem; height: 0.6rem; border-radius: 50%; border: 1.5px solid var(--encre); }
.jauge__points span.plein { background: var(--encre); }
.jauge--toxicite .jauge__points span { border-color: var(--prune); }
.jauge--toxicite .jauge__points span.plein { background: var(--prune); }
.encadre-sombre { background: var(--encre); color: var(--sauge-sur-encre); border-radius: 6px; padding: 1.2rem 1.4rem; margin: 1.4rem 0; }
.encadre-sombre h2, .encadre-sombre h3 { color: var(--or-clair); font-size: 1.35rem; margin-bottom: 0.5rem; }
.encadre-sombre p:last-child { margin-bottom: 0; }
.encadre-sombre a { color: var(--papier); }

/* ── Formulaire de réservation ── */
.reservation { border: 1px solid var(--filet); border-radius: 6px; padding: clamp(1.1rem, 3vw, 1.6rem); display: grid; gap: 1rem; margin-top: 1.6rem; }
.reservation h2 { font-size: 1.6rem; }
.champ { display: grid; gap: 0.3rem; }
.champ label, .reservation legend { font-weight: 700; font-size: 0.98rem; }
.aide { font-weight: 400; color: var(--gris); font-size: 0.92rem; }
.champ input, .champ textarea { font: inherit; color: var(--encre); background: #FFFDF8; border: 1px solid var(--filet); border-radius: 4px; padding: 0.6rem 0.75rem; width: 100%; }
.champ textarea { min-height: 6rem; resize: vertical; }
.deux { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.reservation fieldset { border: 0; padding: 0; margin: 0; min-width: 0; display: grid; gap: 0.45rem; }
.choix { display: grid; grid-template-columns: auto 1fr; gap: 0.6rem; align-items: start; font-size: 0.98rem; }
.choix input { width: 1.15rem; height: 1.15rem; margin-top: 0.2rem; accent-color: var(--prune); }
.piege { position: absolute; left: -999rem; }
.bouton { font: inherit; font-weight: 700; background: var(--prune); color: var(--papier); border: 0; border-radius: 4px; padding: 0.8rem 1.4rem; cursor: pointer; justify-self: start; text-decoration: none; display: inline-block; }
.bouton:hover { background: #561B2B; color: var(--papier); }
.bouton[disabled] { opacity: 0.6; cursor: wait; }
.retour { margin: 0; padding: 0.8rem 1rem; border-radius: 4px; }
.retour--ok { background: var(--sauge-claire); }
.retour--erreur { background: #F6DCD6; color: var(--alerte); }

/* ── Texte long (conditions) ── */
.texte-long { padding-block: clamp(2rem, 5vw, 3.5rem) clamp(3rem, 6vw, 5rem); }
.texte-long h2 { margin: 2.2rem 0 0.6rem; font-size: 1.6rem; }
.texte-long ul { padding-left: 1.2em; }
.texte-long li { margin-bottom: 0.35rem; max-width: 64ch; }

/* ── Pied ── */
.pied { background: var(--encre); color: var(--sauge-sur-encre); padding-block: 2.5rem; font-size: 0.95rem; }
.pied__grille { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem 3rem; }
.pied a { color: #F1EDE2; text-decoration: none; }
.pied a:hover { color: var(--or-clair); text-decoration: underline; }
.pied ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.35rem; }
.pied__nom { font-family: var(--herbier); font-size: 1.5rem; color: var(--or-clair); margin: 0 0 0.3rem; }
.pied p { margin: 0 0 0.3rem; }

.question { margin: 2rem 0 0; color: var(--gris); }
.comment { border-top: 1px solid var(--filet); padding-block: clamp(2.5rem, 5vw, 3.5rem); }
.comment .etapes { margin-top: 1.2rem; }
.fiche__reserver { margin: -0.4rem 0 1.4rem; }

@media (max-width: 48rem) {
  .etapes, .fiche, .deux { grid-template-columns: minmax(0, 1fr); }
  .entete__ligne { flex-wrap: nowrap; padding-block: 0.8rem; }
  .entete__marque img { height: 32px; }
  .entete .hors-mobile { display: none; }
  .ouverture { padding-block: 1.25rem 0.5rem; }
  .planche { padding: 1.25rem; }
  .planche__tete { margin-bottom: 1rem; }
}
@media print {
  .entete nav, .filtres, .reservation, .pied, .travail { display: none !important; }
}
