/* =====================================================================
   Page « Chambres & tarifs »
   En-tête orange (comme la page Menu), fond crème, titres en Rancho avec la fleur de
   safran, violet pour ce que l'on choisit, brun pour les actions.
   ===================================================================== */

.chambres-espace-entete { height: var(--hauteur-entete, 112px); background: #e7a45c; }

.page-chambres {
    --ch-fond: #fffaf3;
    --ch-orange: #e7a45c;
    --ch-encre: #3d2614;
    --ch-titre: #4a260b;
    --ch-texte: #5a4232;
    --ch-doux: #6e5340;
    --ch-brun: #7a4612;
    --ch-action: #a2631d;
    --ch-violet: #6f2a86;
    --ch-violet-fonce: #4f1a63;
    --ch-filet: #f0dfc9;
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
    display: block;
    background: var(--ch-fond);
    color: var(--ch-encre);
}
.page-chambres ::selection { background: var(--ch-violet); color: #fff; }
.page-chambres .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.page-chambres h1, .page-chambres h2 { font-family: 'Rancho', cursive; font-weight: 400; letter-spacing: 0; color: var(--ch-titre); }
.page-chambres h1 span, .page-chambres h2 span { font-family: inherit; }
.page-chambres h2 { display: flex; align-items: center; gap: .3em; font-size: clamp(2.3rem, 7vw, 3.1rem); line-height: 1; }

/* ---------- En-tête : l'offre et le choix du nombre de voyageurs ---------- */
.ch-tete {
    display: grid; gap: 28px; align-items: center;
    padding: 18px 16px 40px; background: var(--ch-orange);
}
.ch-tete > * { min-width: 0; }
.ch-tete h1 { display: flex; align-items: center; gap: .2em; font-size: clamp(3rem, 12vw, 5.2rem); line-height: .95; }
.ch-accroche { max-width: 40ch; margin-top: 14px; font-size: 1.08rem; line-height: 1.6; color: #4f2c10; }
.ch-accroche strong { color: var(--ch-encre); font-weight: 600; }
.ch-prix-depuis {
    display: inline-block; margin-top: 18px; padding: 10px 16px; border-radius: 14px;
    background: rgba(255, 250, 243, .7); font-size: .95rem; line-height: 1.45; color: #4f2c10;
}
.ch-prix-depuis strong { font-size: 1.55rem; font-weight: 700; color: var(--ch-encre); font-variant-numeric: tabular-nums; }
.ch-prix-depuis span { font-weight: 600; color: var(--ch-brun); }
.ch-prix-depuis p { margin: 0; }
.ch-prix-depuis .ch-saison-basse { margin-top: 6px; padding-top: 6px; border-top: 1px solid rgba(122, 70, 18, .18); font-size: .9rem; color: var(--ch-violet-fonce); font-weight: 600; }

.ch-voyageurs { margin-top: 26px; }
.ch-voyageurs-titre { font-size: 1.05rem; font-weight: 600; color: var(--ch-encre); }
.ch-voyageurs-choix { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.page-chambres .ch-voyageurs-choix button {
    min-width: 48px; height: 48px; padding: 0 14px; border: 0; border-radius: 999px; cursor: pointer;
    background: var(--ch-fond); color: var(--ch-brun); font: 600 1.05rem/1 'Poppins', sans-serif;
    box-shadow: 0 6px 14px -10px rgba(74, 38, 11, .7);
    transition: background-color .2s ease, color .2s ease, transform .16s var(--ease-out);
}
.page-chambres .ch-voyageurs-choix button:active { transform: scale(.95); }
.page-chambres .ch-voyageurs-choix button[aria-pressed="true"] { background: var(--ch-violet); color: #fff; }
@media (hover: hover) and (pointer: fine) {
    .page-chambres .ch-voyageurs-choix button:hover { background: #fff; }
    .page-chambres .ch-voyageurs-choix button[aria-pressed="true"]:hover { background: var(--ch-violet-fonce); }
}
.ch-voyageurs-aide { margin-top: 10px; font-size: .9rem; color: #5a3414; min-height: 1.4em; }
html:not(.js) .ch-voyageurs { display: none; } /* sans JavaScript, le choix ne ferait rien */

/* Trois photos en « polaroïds » */
.ch-tete-photos { display: grid; grid-template-columns: 1.35fr 1fr; grid-template-rows: 1fr 1fr; gap: 12px; aspect-ratio: 16 / 10; }
.ch-tete-photos img {
    width: 100%; height: 100%; max-height: none; object-fit: cover; border: 6px solid #fff; border-radius: 6px;
    box-shadow: 0 16px 30px -18px rgba(74, 38, 11, .8);
}
.ch-photo-a { grid-row: 1 / 3; --pente: -1.4deg; }
.ch-photo-b { --pente: 1.8deg; --delai: 80ms; }
.ch-photo-c { --pente: -.8deg; --delai: 160ms; }
.ch-tete-photos img { transform: rotate(var(--pente)); animation: ch-poser .6s var(--ease-out) var(--delai, 0ms) both; }
@keyframes ch-poser { from { opacity: 0; transform: translateY(14px) rotate(0deg) scale(.97); } }
/* Sur téléphone, les chambres passent avant les photos d'ambiance */
@media (max-width: 639px) {
    .ch-tete-photos { display: none; }
    .ch-voyageurs-choix { gap: 6px; }
    .page-chambres .ch-voyageurs-choix button { min-width: 44px; height: 44px; padding: 0 12px; }
}

@media (min-width: 900px) {
    .ch-tete { grid-template-columns: 1.05fr .95fr; gap: 56px; padding: 40px max(32px, calc((100% - 1180px) / 2)) 64px; }
}

/* ---------- Les chambres ---------- */
.ch-liste { max-width: 1180px; margin: 0 auto; padding: 36px 16px 20px; }
.ch-cartes { display: grid; gap: 22px; }
@media (min-width: 820px) { .ch-cartes { grid-template-columns: 1fr 1fr; gap: 28px; } }
.ch-carte {
    display: flex; flex-direction: column; min-width: 0; overflow: hidden; border-radius: 22px; background: #fff;
    box-shadow: 0 1px 0 rgba(122, 70, 18, .06), 0 20px 40px -28px rgba(74, 38, 11, .6);
    transition: opacity .24s ease;
    scroll-margin-top: calc(var(--entete-compacte, 0px) + 16px);
}
.ch-carte.est-trop-petite { opacity: .55; }
.ch-separateur {
    grid-column: 1 / -1; margin: 8px 0 -6px; font-size: .95rem; font-weight: 600; color: var(--ch-doux);
    transition: opacity .24s var(--ease-out) .14s, transform .24s var(--ease-out) .14s; /* après le début du glissement des cartes */
}

/* Galerie de photos : on fait glisser (ou flèches sur ordinateur) */
.ch-galerie { position: relative; background: #f3e4d0; }
.ch-galerie-piste {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    aspect-ratio: 16 / 9; scroll-behavior: smooth; overscroll-behavior-x: contain;
}
.ch-galerie-piste::-webkit-scrollbar { display: none; }
.ch-galerie-piste:focus-visible { outline: 3px solid var(--ch-violet); outline-offset: -3px; }
.ch-galerie-piste img { flex: 0 0 100%; width: 100%; height: 100%; max-height: none; max-width: none; object-fit: cover; scroll-snap-align: start; }
.page-chambres .ch-galerie-bouton {
    position: absolute; top: 50%; display: grid; place-items: center; width: 40px; height: 40px; margin-top: -20px;
    border: 0; border-radius: 50%; background: rgba(255, 250, 243, .92); color: var(--ch-titre); cursor: pointer;
    box-shadow: 0 6px 16px -8px rgba(43, 23, 9, .6); transition: opacity .2s ease, transform .16s var(--ease-out);
}
.ch-galerie-bouton[hidden] { display: none; }
.ch-galerie-bouton:active { transform: scale(.96); }
.ch-galerie-bouton:disabled { opacity: 0; pointer-events: none; }
.ch-galerie-bouton svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.ch-galerie-precedent { left: 10px; }
.ch-galerie-suivant { right: 10px; }
@media (hover: none) { .page-chambres .ch-galerie-bouton { display: none; } }
.ch-galerie-compteur {
    position: absolute; right: 10px; bottom: 10px; padding: 3px 9px; border-radius: 999px;
    background: rgba(43, 23, 9, .62); color: #fff; font-size: .78rem; font-weight: 500; font-variant-numeric: tabular-nums;
}
.ch-convient {
    position: absolute; left: 10px; top: 10px; padding: 5px 11px; border-radius: 999px;
    background: var(--ch-violet); color: #fff; font-size: .82rem; font-weight: 600;
    box-shadow: 0 6px 14px -8px rgba(47, 12, 60, .8);
    transform-origin: 0 50%; transition: opacity .2s var(--ease-out), transform .2s var(--ease-out);
}
.ch-convient[hidden] { display: none; }

.ch-carte-corps { display: flex; flex-direction: column; flex: 1; padding: 18px 20px 20px; }
.ch-carte h3 { font-family: 'Rancho', cursive; font-weight: 400; font-size: 2.1rem; line-height: 1; color: var(--ch-titre); letter-spacing: 0; }
.ch-faits { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 10px 0 0; padding: 0; list-style: none; font-size: .9rem; color: var(--ch-doux); }
.ch-faits li { display: inline-flex; align-items: center; gap: 6px; list-style: none; }
.ch-icone { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--ch-violet); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ch-texte { margin-top: 10px; font-size: .97rem; line-height: 1.55; color: var(--ch-texte); }

.ch-prix-ligne {
    display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px;
    margin-top: auto; padding-top: 16px; border-top: 1px solid var(--ch-filet);
}
.ch-carte-corps > .ch-texte + .ch-prix-ligne, .ch-carte-corps > .ch-faits + .ch-prix-ligne { margin-top: 16px; }
.ch-prix { margin: 0; flex: 1 1 200px; line-height: 1.3; }
.ch-prix p { margin: 0; }
.ch-prix strong { font-size: 1.75rem; font-weight: 700; color: var(--ch-encre); font-variant-numeric: tabular-nums; }
.ch-prix-dh { margin-left: 4px; font-size: .95rem; font-weight: 600; color: var(--ch-brun); }
.ch-prix-unite, .ch-prix-precision { margin-top: 2px !important; font-size: .82rem; color: var(--ch-doux); }
.ch-prix-unite span { display: block; }
/* Deux saisons : deux lignes alignées */
.ch-prix-saisons { display: grid; gap: 2px; margin: 0 0 4px; }
.ch-prix-saisons > div { display: flex; align-items: baseline; gap: 10px; }
.ch-prix-saisons dt { min-width: 7.2em; font-size: .82rem; font-weight: 600; color: var(--ch-brun); }
.ch-prix-saisons .basse dt { color: var(--ch-violet); }
.ch-prix-saisons dd { margin: 0; }
.ch-prix-saisons strong { font-size: 1.35rem; }
.ch-prix-demande { font-size: 1.2rem !important; }
.page-chambres .ch-reserver {
    display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 12px;
    background: var(--ch-action); color: #fff; font-weight: 600; font-size: 1rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 8px 18px -10px rgba(122, 70, 18, .95);
    transition: background-color .2s ease, transform .16s var(--ease-out);
}
.page-chambres .ch-reserver svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .2s var(--ease-out); }
.page-chambres .ch-reserver:active { transform: scale(.97); }
@media (hover: hover) and (pointer: fine) {
    .page-chambres .ch-reserver:hover { background: var(--ch-brun); }
    .page-chambres .ch-reserver:hover svg { transform: translateX(3px); }
}

/* Carte « Vous hésitez ? » : toujours la dernière de la grille */
.ch-conseil {
    display: flex; flex-direction: column; gap: 12px; min-width: 0;
    padding: 26px 24px 24px; border-radius: 22px; background: #f6e9fa; color: var(--ch-violet-fonce);
}
.page-chambres .ch-conseil h3 { font-family: 'Rancho', cursive; font-weight: 400; font-size: 2.3rem; line-height: 1; color: var(--ch-violet-fonce); }
.ch-conseil > p { font-size: 1.02rem; line-height: 1.55; }
.ch-rassurance { display: grid; gap: 8px; margin: 2px 0 0; padding: 0; list-style: none; }
.ch-rassurance li {
    position: relative; padding-left: 28px; list-style: none; font-weight: 600; font-size: .95rem;
}
.ch-rassurance li::before {
    content: ''; position: absolute; left: 0; top: .15em; width: 18px; height: 18px; border-radius: 50%;
    background: var(--ch-violet) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.ch-conseil-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 8px; }
.page-chambres .ch-conseil-whatsapp, .page-chambres .ch-conseil-demande {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px;
    border-radius: 12px; font-weight: 600; transition: background-color .2s ease, transform .16s var(--ease-out);
}
.page-chambres .ch-conseil-whatsapp { background: #0e7a3e; color: #fff; }
.page-chambres .ch-conseil-whatsapp svg { width: 20px; height: 20px; }
.page-chambres .ch-conseil-demande { background: #fff; color: var(--ch-violet-fonce); box-shadow: inset 0 0 0 1.5px rgba(79, 26, 99, .25); }
.page-chambres .ch-conseil-whatsapp:active, .page-chambres .ch-conseil-demande:active { transform: scale(.97); }
@media (hover: hover) and (pointer: fine) {
    .page-chambres .ch-conseil-whatsapp:hover { background: #0b6532; }
    .page-chambres .ch-conseil-demande:hover { background: #fdf8ff; }
}

.ch-groupe {
    margin: 22px 0 0; padding: 14px 18px; border-radius: 14px; background: #f6e9fa; color: var(--ch-violet-fonce);
    transition: opacity .24s var(--ease-out), transform .24s var(--ease-out);
}
/* Point de départ des entrées ci-dessus (navigateurs récents ; ailleurs, simple apparition) */
@starting-style {
    .ch-convient { opacity: 0; transform: scale(.95); }
    .ch-separateur, .ch-groupe { opacity: 0; transform: translateY(6px); }
}
.ch-groupe[hidden] { display: none; }
.ch-groupe a { color: var(--ch-violet-fonce); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Compris dans le séjour ---------- */
.ch-inclus { display: grid; gap: 28px; max-width: 1180px; margin: 0 auto; padding: 40px 16px; }
.ch-inclus > * { min-width: 0; }
.ch-inclus-repas {
    display: grid; gap: 14px; align-content: start; padding: 26px 22px; border-radius: 24px;
    background: var(--ch-violet-fonce); color: #f0e1f5;
}
.page-chambres .ch-inclus-repas h2 { color: #fff; }
.ch-inclus-promesse { font-size: 1.08rem; line-height: 1.6; }
.ch-inclus-promesse strong { color: #fff; }
.ch-inclus-legende { margin: 0; font-size: .95rem; line-height: 1.55; color: rgba(255, 255, 255, .88); }
.ch-inclus-legende strong { color: #fff; }
.ch-inclus-photo { margin: 4px 0 0; overflow: hidden; border-radius: 16px; aspect-ratio: 16 / 9; }
.ch-inclus-photo picture { display: block; width: 100%; height: 100%; }
.ch-inclus-photo img { width: 100%; height: 100%; max-height: none; object-fit: cover; }
.page-chambres .ch-lien-fleche { display: inline-flex; align-items: center; gap: 8px; justify-self: start; font-weight: 600; color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.page-chambres .ch-lien-fleche svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.ch-inclus-equipements h3 { font-size: 1.15rem; font-weight: 600; color: var(--ch-encre); }
.ch-equipements { display: grid; gap: 4px; margin: 12px 0 0; padding: 0; list-style: none; }
.ch-equipements li { display: flex; align-items: center; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--ch-filet); list-style: none; color: var(--ch-texte); }
.ch-equipements strong { color: var(--ch-encre); font-weight: 600; }
.ch-equipements svg { width: 26px; height: 26px; flex: none; fill: none; stroke: var(--ch-violet); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.ch-ferme { margin-top: 22px; }
.ch-ferme-photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ch-ferme-photos img { width: 100%; aspect-ratio: 1; height: auto; max-height: none; object-fit: cover; border-radius: 12px; }
.ch-ferme p { margin-top: 10px; font-size: .95rem; color: var(--ch-texte); }
.ch-ferme strong { color: var(--ch-encre); }
@media (min-width: 900px) {
    .ch-inclus { grid-template-columns: 1.1fr .9fr; gap: 48px; padding: 56px 32px; }
    .ch-inclus-repas { padding: 34px 32px; }
}

/* ---------- Bon à savoir ---------- */
.ch-questions { max-width: 860px; margin: 0 auto; padding: 24px 16px 40px; }
.ch-questions-liste { display: grid; gap: 10px; margin-top: 18px; }
.ch-questions details { border-radius: 16px; background: #fff; box-shadow: 0 1px 0 rgba(122, 70, 18, .06), 0 12px 26px -22px rgba(74, 38, 11, .6); }
.ch-questions summary {
    display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 14px 18px;
    font-weight: 600; font-size: 1.02rem; color: var(--ch-encre); cursor: pointer; list-style: none;
}
.ch-questions summary::-webkit-details-marker { display: none; }
.ch-questions summary::after {
    content: ''; flex: none; width: 10px; height: 10px; margin-right: 4px;
    border-right: 2px solid var(--ch-violet); border-bottom: 2px solid var(--ch-violet);
    transform: rotate(45deg) translate(-2px, -2px); transition: transform .2s var(--ease-out);
}
.ch-questions details[open] summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
.ch-questions details p { padding: 0 18px 14px; line-height: 1.6; color: var(--ch-texte); }
.ch-questions details[open] > :not(summary) { animation: ch-reponse .22s var(--ease-out); }
@keyframes ch-reponse { from { opacity: 0; transform: translateY(-4px); } }
@keyframes ch-fondu { from { opacity: 0; } }
.ch-questions details p + p { margin-top: -4px; }
.page-chambres .ch-questions a { color: var(--ch-violet); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
    .ch-galerie-piste { scroll-behavior: auto; }
    .page-chambres .ch-voyageurs-choix button, .page-chambres .ch-reserver, .page-chambres .ch-galerie-bouton,
    .page-chambres .ch-conseil-whatsapp, .page-chambres .ch-conseil-demande { transition: background-color .2s ease, color .2s ease, opacity .2s ease; }
    .page-chambres .ch-voyageurs-choix button:active, .page-chambres .ch-reserver:active, .page-chambres .ch-galerie-bouton:active,
    .page-chambres .ch-conseil-whatsapp:active, .page-chambres .ch-conseil-demande:active { transform: none; }
    .ch-convient, .ch-separateur, .ch-groupe { transition: opacity .2s ease; transform: none; }
    .ch-tete-photos img, .ch-questions details[open] > :not(summary) { animation: ch-fondu .3s ease both; }
}

/* Les photos passent par image() (controller/seo.php) qui les entoure d'un <picture> pour servir le WebP :
   le <picture> s'efface de la mise en page, l'image reste l'élément de la galerie ou de la grille. */
.page-chambres picture { display: contents; }
.page-chambres picture source { display: none; } /* sinon les <source> prennent une case de la grille */
