/* La carte de réservation flottante, le sélecteur de dates et la page Réserver. */

/* ---------- la carte flottante ---------- */
.flottante-bouton { position: fixed; left: var(--marge); right: var(--marge); bottom: 14px; z-index: 150; padding: 16px 22px; border: 0; border-radius: 999px; background: var(--cuivre); color: var(--encre); font: 600 15px/1 var(--sans); cursor: pointer; box-shadow: 0 16px 40px -16px rgba(20, 20, 20, 0.6); transition: transform 200ms var(--sortie), background 200ms; }
.flottante-bouton:hover { background: var(--encre); color: var(--creme); }
.flottante { position: fixed; left: 0; right: 0; bottom: 0; z-index: 160; background: var(--nuit); color: var(--creme); border-radius: 24px 24px 0 0; padding: 18px var(--marge) calc(18px + env(safe-area-inset-bottom)); display: grid; gap: 12px; box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.35); max-height: 92svh; overflow: visible; }
.flottante-tete { display: flex; align-items: center; justify-content: space-between; }
.flottante-tete .surtitre { margin: 0; color: var(--cuivre); }
.flottante-fermer { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--ligne-claire); background: transparent; color: var(--creme); font-size: 20px; cursor: pointer; }
.flottante-note { font-size: 12px; color: rgba(246, 244, 239, 0.6); margin: 0; }
body.flottante-ouverte .flottante-bouton { display: none; }

/* ---------- le formulaire de recherche ---------- */
.recherche { position: relative; }
.recherche-champs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.recherche-champ { display: grid; gap: 2px; text-align: left; padding: 10px 12px; border: 1px solid var(--ligne-claire); border-radius: 12px; background: rgba(255, 255, 255, 0.06); color: inherit; font: inherit; cursor: pointer; min-height: 56px; transition: border-color 200ms, background 200ms; }
.recherche-champ:hover, .recherche-champ[aria-expanded="true"] { border-color: var(--cuivre); }
.recherche-etiquette { font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; font-weight: 700; color: var(--cuivre); }
.recherche-champ strong { font-family: var(--serif); font-size: 16px; font-weight: 700; line-height: 1.1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recherche-champ strong.vide { color: rgba(246, 244, 239, 0.5); font-weight: 400; font-family: var(--sans); }
.recherche-voyageurs, .recherche-nombre { cursor: default; }
.compteurs { display: flex; gap: 14px; flex-wrap: wrap; }
.compteur { display: inline-flex; align-items: center; gap: 6px; font-family: var(--serif); font-weight: 700; font-size: 16px; }
.compteur small { font-family: var(--sans); font-size: 11px; color: rgba(246, 244, 239, 0.6); font-weight: 400; }
.compteur-bouton { width: 24px; height: 24px; border: 1px solid currentColor; background: transparent; color: inherit; border-radius: 50%; cursor: pointer; font-size: 14px; line-height: 1; display: grid; place-items: center; opacity: 0.85; }
.compteur-bouton:hover { opacity: 1; border-color: var(--cuivre); color: var(--cuivre); }
.compteur-bouton[disabled] { opacity: 0.25; pointer-events: none; }
.recherche-bouton { grid-column: 1 / -1; --fond: var(--cuivre); --texte: var(--encre); --bord: var(--cuivre); }
.recherche-bouton:hover { background: var(--creme); border-color: var(--creme); color: var(--encre); }

/* sur fond clair (page Réserver) */
.recherche-grande { color: var(--encre); }
.recherche-grande .recherche-champ { background: var(--blanc); border-color: var(--ligne); min-height: 64px; padding: 10px 16px; }
.recherche-grande .recherche-champ strong { font-size: 20px; }
.recherche-grande .recherche-champ strong.vide { color: var(--gris); }
.recherche-grande .recherche-etiquette { color: var(--cuivre-fonce); }
.recherche-grande .compteur small { color: var(--gris); }
.recherche-grande .recherche-bouton { --fond: var(--encre); --texte: var(--creme); --bord: var(--encre); }
.recherche-grande .recherche-bouton:hover { background: var(--cuivre); border-color: var(--cuivre); color: var(--encre); }

/* ---------- calendrier flottant ---------- */
.calendrier-popover { position: absolute; left: 0; right: 0; bottom: calc(100% + 10px); z-index: 170; background: var(--blanc); color: var(--encre); border-radius: var(--rayon); padding: 16px; display: grid; gap: 12px; box-shadow: 0 30px 60px -20px rgba(20, 20, 20, 0.45); border: 1px solid var(--ligne); }
.recherche-grande .calendrier-popover { bottom: auto; top: calc(100% + 8px); max-width: 720px; }
.calendrier-popover-tete { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-family: var(--serif); font-weight: 700; font-size: 15px; }
.calendrier-nav { width: 36px; height: 36px; border: 1px solid var(--ligne); background: transparent; cursor: pointer; border-radius: 50%; }
.calendrier-nav:hover { border-color: var(--encre); }
.calendrier-nav[disabled] { opacity: 0.3; pointer-events: none; }
.calendrier-mois { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
.mois { display: grid; gap: 8px; min-width: 0; }
.mois-titre { text-align: center; font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; font-weight: 700; }
.mois-grille { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; }
.mois-grille > span { text-align: center; font-size: 10px; color: var(--gris); letter-spacing: 0.1em; padding-bottom: 4px; }
.nuit { position: relative; min-width: 0; aspect-ratio: 1; border: 0; background: transparent; font: inherit; cursor: pointer; display: grid; place-items: center; align-content: center; border-radius: 10px; transition: background 150ms, color 150ms; }
.nuit b { font-weight: 600; font-size: 14px; font-variant-numeric: tabular-nums; line-height: 1; }
.nuit small { font-size: 9px; color: var(--gris); line-height: 1; margin-top: 3px; }
.nuit.vide { visibility: hidden; }
.nuit.libre:hover, .nuit.derniere:hover { background: var(--sable); }
.nuit.derniere small { color: var(--cuivre-fonce); font-weight: 700; }
.nuit.complet, .nuit.passe, .nuit.hors_horizon { color: var(--gris); cursor: not-allowed; }
.nuit.complet b { text-decoration: line-through; }
.nuit.passe, .nuit.hors_horizon { opacity: 0.4; }
.nuit.chargement { opacity: 0.4; }
.nuit.aujourd-hui b { text-decoration: underline; text-underline-offset: 3px; }
.nuit.selection-debut, .nuit.selection-fin { background: var(--encre); color: var(--creme); }
.nuit.selection-debut small, .nuit.selection-fin small { color: var(--cuivre); }
.nuit.selection-entre { background: var(--cuivre-clair); }
.calendrier-legende { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; font-size: 11px; color: var(--gris); }
.calendrier-legende span::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; background: #3fa66b; }
.calendrier-legende .legende-derniere::before { background: var(--cuivre); }
.calendrier-legende .legende-complet::before { background: var(--gris); }
.calendrier-legende .calendrier-note::before { display: none; }
.calendrier-note { color: var(--cuivre-fonce); font-weight: 600; }
.calendrier-legende .lien-souligne { margin-left: auto; background: none; border-top: 0; border-left: 0; border-right: 0; cursor: pointer; font: inherit; font-size: 11px; }
.calendrier-chambre { background: var(--blanc); border-radius: var(--rayon); border: 1px solid var(--ligne); padding: clamp(16px, 3vw, 28px); display: grid; gap: 16px; }
.calendrier-mois-large .nuit b { font-size: 15px; }
.calendrier-action { display: flex; justify-content: flex-end; }

/* ---------- page réserver ---------- */
.reservation { display: grid; gap: 28px; }
.reservation-recherche { background: var(--sable); border-radius: var(--rayon); padding: 14px; }
.reservation-vide { font-size: 18px; color: var(--gris); }
.reservation-resultats { display: grid; gap: 18px; }
.resultat-tete h2 { font-family: var(--serif); font-weight: 800; font-size: clamp(24px, 3vw, 34px); letter-spacing: -0.03em; }
.resultat-tete em { font-style: normal; font-family: var(--sans); font-weight: 400; color: var(--gris); font-size: 0.55em; display: block; margin-top: 4px; }
.resultats-liste { display: grid; gap: 14px; }
.resultat { display: grid; background: var(--blanc); border-radius: var(--rayon); border: 1px solid var(--ligne); overflow: hidden; }
.resultat.indisponible { opacity: 0.65; }
.resultat-image { aspect-ratio: 16 / 9; overflow: hidden; background: var(--sable-2); }
.resultat-image img { width: 100%; height: 100%; object-fit: cover; }
.resultat-texte { padding: 18px; display: grid; gap: 6px; align-content: start; }
.resultat-nom { font-family: var(--serif); font-weight: 800; font-size: 24px; letter-spacing: -0.03em; line-height: 1.05; }
.resultat-sous { color: var(--gris); font-size: 14px; }
.resultat-specs { font-size: 13px; color: var(--gris); }
.resultat-libres { font-size: 12px; font-weight: 700; color: var(--cuivre-fonce); }
.resultat-raison { color: var(--cuivre-fonce); font-size: 14px; }
.resultat-prochaine { font-size: 14px; padding-top: 8px; border-top: 1px solid var(--ligne); }
.resultat-formules { padding: 0 18px 18px; display: grid; gap: 8px; }
.formule-choix { display: grid; grid-template-columns: 1fr auto; gap: 4px 14px; align-items: center; padding: 12px 14px; border: 1.5px solid var(--ligne); border-radius: 12px; background: var(--creme); cursor: pointer; text-align: left; font: inherit; color: inherit; transition: border-color 200ms, background 200ms; }
.formule-choix:hover { border-color: var(--encre); }
.formule-choix strong { grid-column: 1; grid-row: 1; font-family: var(--serif); font-weight: 700; font-size: 15px; }
.formule-choix small { grid-column: 1; grid-row: 2; font-size: 12px; color: var(--gris); }
.formule-choix .formule-choix-prix { grid-column: 2; grid-row: 1 / span 2; font-family: var(--serif); font-weight: 800; font-size: 19px; letter-spacing: -0.02em; text-align: right; white-space: nowrap; }
.formule-choix .formule-choix-prix small { display: block; font-family: var(--sans); font-weight: 400; font-size: 11px; color: var(--gris); }
.formule-choix.remise { border-color: var(--cuivre); }
.propositions { display: grid; gap: 10px; }
.propositions-liste { display: grid; gap: 8px; }
.propositions-liste a { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; padding: 14px 18px; background: var(--blanc); border: 1px solid var(--ligne); border-radius: 12px; text-decoration: none; transition: border-color 200ms; }
.propositions-liste a:hover { border-color: var(--encre); }
.propositions-liste strong { font-family: var(--serif); font-size: 17px; font-weight: 700; }
.propositions-liste span { color: var(--gris); font-size: 14px; }
.reservation-detail-grille { display: grid; gap: 28px; }
.options-choix { display: grid; gap: 8px; margin: 20px 0; }
.option-choix { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1.5px solid var(--ligne); border-radius: 12px; background: var(--blanc); cursor: pointer; }
.option-choix input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--encre); flex: none; }
.option-choix-texte { flex: 1; display: grid; gap: 2px; }
.option-choix-texte small { color: var(--gris); font-size: 13px; }
.option-choix-prix { font-family: var(--serif); font-weight: 800; white-space: nowrap; }
.formulaire-reservation { grid-template-columns: 1fr 1fr; gap: 12px; }
.formulaire-reservation .titre-bloc { grid-column: 1 / -1; margin-top: 8px; }
.formulaire-reservation .champ-large { grid-column: 1 / -1; }
.erreur-formulaire { grid-column: 1 / -1; background: #f0d9d3; color: #6e2b1f; padding: 10px 12px; border-radius: 10px; font-size: 14px; }
.recap-sejour { background: var(--nuit); color: var(--creme); border-radius: var(--rayon); padding: clamp(20px, 3vw, 28px); display: grid; gap: 12px; align-content: start; align-self: start; }
.recap-sejour .surtitre { color: var(--cuivre); margin: 0; }
.recap-sejour h3 { font-family: var(--serif); font-weight: 800; font-size: 26px; letter-spacing: -0.03em; line-height: 1.05; }
.recap-sejour ul { display: grid; }
.recap-sejour li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--ligne-claire); font-size: 14px; }
.recap-sejour li.total { font-family: var(--serif); font-weight: 800; font-size: 20px; border-bottom: 0; padding-top: 12px; }
.recap-sejour .texte-doux { color: rgba(246, 244, 239, 0.66); font-size: 12px; }
.reservation-merci { display: grid; gap: 16px; max-width: 720px; }

@media (min-width: 760px) {
    .flottante-bouton { left: auto; right: 24px; bottom: 24px; padding: 18px 26px; }
    .flottante { left: auto; right: 24px; bottom: 24px; width: 400px; border-radius: 20px; padding: 20px; }
    .recherche-champs { grid-template-columns: 1fr 1fr; }
    .recherche-grande .recherche-champs { grid-template-columns: 1fr 1fr 1.4fr 1fr auto; gap: 8px; }
    .recherche-grande .recherche-bouton { grid-column: auto; }
    .calendrier-mois { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
    .flottante .calendrier-popover { left: auto; right: 0; width: 560px; }
    .calendrier-mois-large { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .resultat { grid-template-columns: 240px 1fr 340px; align-items: start; }
    .resultat-image { aspect-ratio: auto; height: 100%; min-height: 200px; }
    .resultat-formules { padding: 18px 18px 18px 0; }
    .reservation-detail-grille { grid-template-columns: 1.4fr 1fr; gap: 48px; }
    .recap-sejour { position: sticky; top: calc(var(--entete) + 24px); }
}
@media (prefers-reduced-motion: reduce) { .flottante, .flottante-bouton { transition: none; } }
