:root {
  --vert: #2f5d3a;
  --vert-fonce: #234729;
  --creme: #faf7f0;
  --sable: #efe9dc;
  --texte: #2b2b26;
  --muted: #7a766b;
  --accent: #c78d4e;
  --rouge: #b3402f;
  --rayon: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Segoe UI', system-ui, -apple-system, Roboto, sans-serif;
  color: var(--texte);
  background: var(--creme);
  line-height: 1.6;
}
h1, h2, h3 { font-family: Georgia, 'Times New Roman', serif; line-height: 1.2; }
h2 { font-size: 2rem; margin: 0 0 1.2rem; }
h2::after { content: ""; display: block; width: 56px; height: 3px; background: var(--accent); margin-top: .5rem; border-radius: 2px; }
img { max-width: 100%; display: block; }
a { color: var(--vert); }
.muted { color: var(--muted); font-size: .95rem; }
.note { font-size: .9rem; color: var(--muted); }

/* ---------- header ---------- */
.header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: .7rem 1.4rem;
  background: rgba(250, 247, 240, .92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--sable);
}
.brand {
  font-family: Georgia, serif; font-size: 1.25rem; font-weight: bold;
  color: var(--vert-fonce); text-decoration: none;
}
.brand span { color: var(--accent); }
.nav { display: flex; align-items: center; gap: 1.2rem; }
.nav a:not(.btn) { text-decoration: none; color: var(--texte); font-size: .95rem; }
.nav a:not(.btn):hover { color: var(--vert); }

.btn {
  display: inline-block; border: 0; cursor: pointer; text-decoration: none;
  border-radius: 999px; font-size: 1rem; padding: .7rem 1.5rem;
  transition: transform .1s ease, box-shadow .1s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.btn-primary { background: var(--vert); color: #fff; }
.btn-primary:hover { background: var(--vert-fonce); }
.btn-nav { padding: .45rem 1.1rem; font-size: .9rem; }
.btn-wide { width: 100%; font-size: 1.05rem; padding: .85rem; margin-top: .4rem; }
.btn[disabled] { opacity: .6; cursor: wait; }

/* ---------- hero ---------- */
.hero { position: relative; min-height: 72vh; display: flex; flex-direction: column; justify-content: flex-end; }
.hero-img { position: absolute; inset: 0; overflow: hidden; }
.hero-img img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.hero-img::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.55) 75%);
}
.hero-content { position: relative; color: #fff; padding: 3rem 1.4rem 1.2rem; max-width: 900px; }
.hero-eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; margin: 0 0 .4rem; opacity: .9; }
.hero h1 { font-size: clamp(2.2rem, 6vw, 4rem); margin: 0 0 .6rem; }
.hero-sub { font-size: 1.15rem; max-width: 620px; margin: 0 0 1.4rem; }
.hero-cta { display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; }
.hero-price { background: rgba(0,0,0,.35); padding: .5rem 1rem; border-radius: 10px; }
.hero-facts {
  position: relative; display: flex; gap: 1.6rem; flex-wrap: wrap;
  padding: 1rem 1.6rem; background: var(--creme); color: var(--texte);
  font-size: .95rem; border-top: 1px solid var(--sable);
}

/* ---------- sections ---------- */
main { max-width: 1100px; margin: 0 auto; padding: 0 1.4rem; }
.section { padding: 3.2rem 0; }
.section-alt { padding-left: 1.4rem; padding-right: 1.4rem; margin-left: -1.4rem; margin-right: -1.4rem; background: var(--sable); }
@media (min-width: 1128px) {
  .section-alt { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); }
}

/* ---------- le gîte ---------- */
.gite-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; }
@media (min-width: 800px) { .gite-grid { grid-template-columns: 1.1fr .9fr; } }
.gite-text p { margin-top: 0; }
.gite-collage { display: grid; gap: .8rem; grid-template-columns: 1fr 1fr; }
.gite-collage img { border-radius: var(--rayon); height: 100%; object-fit: cover; }
.gite-collage img:first-child { grid-row: span 2; }

.amenities {
  list-style: none; padding: 0; margin: 1rem 0 0;
  display: grid; gap: .7rem 1.4rem; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.amenities li { background: #fff; border: 1px solid var(--sable); border-radius: 10px; padding: .6rem .9rem; }

/* ---------- galerie ---------- */
.gallery { display: grid; gap: .7rem; grid-template-columns: repeat(6, 1fr); grid-auto-rows: 180px; }
.gallery img {
  width: 100%; height: 100%; object-fit: cover; border-radius: 10px; cursor: zoom-in;
  transition: transform .15s ease;
}
.gallery img:hover { transform: scale(1.015); }
.gallery img:nth-child(1) { grid-column: span 3; grid-row: span 2; }
.gallery img:nth-child(2) { grid-column: span 3; }
.gallery img:nth-child(3) { grid-column: span 2; }
.gallery img:nth-child(4) { grid-column: span 2; }
.gallery img:nth-child(5) { grid-column: span 2; }
.gallery img:nth-child(6) { grid-column: span 3; }
.gallery img:nth-child(7) { grid-column: span 2; }
.gallery img:nth-child(8) { grid-column: span 2; }
@media (max-width: 700px) {
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 130px; }
  .gallery img { grid-column: span 2 !important; grid-row: span 1 !important; }
  .gallery img:nth-child(1) { grid-row: span 2 !important; }
}

/* lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 100; background: rgba(15,15,12,.92);
  display: flex; align-items: center; justify-content: center; padding: 2rem;
}
.lightbox[hidden] { display: none; }
.lightbox img { max-height: 90vh; max-width: 90vw; border-radius: 8px; }
.lightbox button {
  position: absolute; background: none; border: 0; color: #fff; font-size: 2.4rem;
  cursor: pointer; padding: .6rem; opacity: .8;
}
.lightbox button:hover { opacity: 1; }
.lb-close { top: 6px; right: 16px; }
.lb-prev { left: 8px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 8px; top: 50%; transform: translateY(-50%); }

/* ---------- région ---------- */
.region-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.region-card {
  background: #fff; border: 1px solid var(--sable); border-radius: var(--rayon);
  padding: 1.2rem 1.3rem;
}
.region-card h3 { margin-top: 0; font-size: 1.15rem; }
.region-card p { margin-bottom: 0; font-size: .95rem; }
.map-wrap { margin-top: 1.2rem; border-radius: var(--rayon); overflow: hidden; border: 1px solid var(--sable); }
.map-wrap iframe { width: 100%; height: 320px; border: 0; }

/* ---------- hôte ---------- */
.host-grid { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); align-items: start; }
.host-card { display: flex; gap: 1rem; background: #fff; border: 1px solid var(--sable); border-radius: var(--rayon); padding: 1.2rem; }
.host-avatar {
  width: 64px; height: 64px; border-radius: 50%; flex: none;
  background: var(--vert); color: #fff; font-family: Georgia, serif; font-size: 1.8rem;
  display: flex; align-items: center; justify-content: center;
}
.host-card h3 { margin: 0 0 .2rem; }
.host-card p { margin: 0; }
.host-infos { list-style: none; padding: 1.2rem; margin: 0; background: #fff; border: 1px solid var(--sable); border-radius: var(--rayon); }
.host-infos li { padding: .3rem 0; }

/* ---------- réservation ---------- */
.booking-grid { display: grid; gap: 2rem; grid-template-columns: 1fr; }
@media (min-width: 900px) { .booking-grid { grid-template-columns: 1fr 1fr; } }
.booking-calendar, .booking-form-wrap {
  background: #fff; border: 1px solid var(--sable); border-radius: var(--rayon);
  padding: 1.2rem;
}
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: .6rem; }
.cal-head button {
  background: none; border: 1px solid var(--sable); border-radius: 8px;
  font-size: 1.3rem; width: 2.2rem; height: 2.2rem; cursor: pointer; color: var(--vert);
}
.cal-head button:disabled { opacity: .35; cursor: default; }
.cal-months { font-weight: 600; }
.calendars { display: grid; gap: 1.4rem; grid-template-columns: 1fr; }
@media (min-width: 560px) { .calendars { grid-template-columns: 1fr 1fr; } }
.cal-month h4 { margin: .3rem 0 .5rem; text-align: center; font-size: .95rem; color: var(--vert-fonce); }
.cal-table { width: 100%; border-collapse: collapse; font-size: .82rem; }
.cal-table th { color: var(--muted); font-weight: 500; padding: .25rem 0; }
.cal-table td { text-align: center; padding: 0; }
.cal-day {
  width: 100%; aspect-ratio: 1; border: 0; background: none; border-radius: 8px;
  cursor: pointer; font: inherit; color: var(--texte);
}
.cal-day:hover:not([disabled]) { background: var(--sable); }
.cal-day[disabled] { color: #ccc; cursor: not-allowed; text-decoration: line-through; text-decoration-color: rgba(179,64,47,.55); }
.cal-day.in-range { background: rgba(47,93,58,.16); border-radius: 0; }
.cal-day.sel-start, .cal-day.sel-end { background: var(--vert); color: #fff; font-weight: 600; }
.busy-legend { background: rgba(179,64,47,.14); padding: 0 .4rem; border-radius: 6px; color: var(--rouge); }

.summary { padding: .8rem 1rem; background: var(--creme); border: 1px solid var(--sable); border-radius: 10px; margin-bottom: 1rem; }
.summary .total { font-weight: 700; color: var(--vert-fonce); }

form label { display: block; margin-bottom: .8rem; font-weight: 600; font-size: .92rem; }
form input, form select, form textarea {
  width: 100%; margin-top: .3rem; padding: .65rem .8rem; font: inherit;
  border: 1px solid #d8d2c4; border-radius: 10px; background: #fff; color: var(--texte);
}
form input:focus, form select:focus, form textarea:focus {
  outline: 2px solid rgba(47,93,58,.4); border-color: var(--vert);
}
.pay-choices { display: grid; gap: .6rem; margin: 1rem 0; }
.pay-choice { display: block; }
.pay-choice input { width: auto; margin-right: .5rem; }
.pay-choice span { font-weight: 600; font-size: .95rem; }
.pay-choice small { display: block; font-weight: 400; color: var(--muted); }
#form-error { color: var(--rouge); font-weight: 600; min-height: 1.2em; margin: .6rem 0 0; }

.reserve-result { margin-top: 1rem; padding: 1.1rem; border-radius: var(--rayon); border: 1px solid var(--vert); background: #eef5ee; }
.reserve-result h3 { margin: 0 0 .5rem; color: var(--vert-fonce); }
.reserve-result .iban-box {
  font-family: ui-monospace, monospace; background: #fff; border: 1px solid var(--sable);
  border-radius: 8px; padding: .7rem .9rem; margin: .6rem 0; word-break: break-all;
}
.reserve-result .copy-btn { font-size: .8rem; background: var(--sable); border: 1px solid #d8d2c4; border-radius: 6px; padding: .15rem .55rem; cursor: pointer; }

/* ---------- à savoir ---------- */
.know-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.know-grid div { background: #fff; border: 1px solid var(--sable); border-radius: var(--rayon); padding: 1.1rem 1.2rem; }
.know-grid h3 { margin: 0 0 .4rem; font-size: 1.1rem; }
.know-grid p { margin: 0; font-size: .95rem; }

/* ---------- footer ---------- */
.footer {
  margin-top: 2rem; padding: 2rem 1.4rem; background: var(--vert-fonce); color: #e8efe8;
  font-size: .9rem;
}

@media (max-width: 640px) {
  .nav a:not(.btn) { display: none; }
  .hero { min-height: 60vh; }
  .section { padding: 2.2rem 0; }
}
