/* =========================================================== */
/* ========================== Base =========================== */
/* =========================================================== */

:root {
  --bg: #f7f8fb;
  --surface: #fff;
  --text: #333;
  --text-soft: #444;
  --heading: #202a44;
  --accent: #4863a0;
  --border: #eaeaea;
  --hover: #f3f6fa;
  --font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.55;
}

body.no-scroll {
  overflow: hidden;
}

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

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

h1,
h2 {
  color: var(--heading);
  line-height: 1.25;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 3000;
  padding: 0.6rem 1rem;
  background: var(--heading);
  color: #fff;
  border-radius: 6px;
}

.skip-link:focus {
  top: 1rem;
}

.button {
  display: inline-block;
  padding: 0.65rem 1.3rem;
  border: 2px solid var(--heading);
  border-radius: 6px;
  background: var(--heading);
  color: #fff;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.button:hover {
  background: var(--accent);
  border-color: var(--accent);
}

.button-secondary {
  background: transparent;
  color: var(--heading);
}

.button-secondary:hover {
  color: #fff;
}

/* =========================================================== */
/* ======================= Navigation ======================== */
/* =========================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 3px 12px #0001;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  max-width: 1300px;
  margin: 0 auto;
  padding: 0.6rem 1rem;
}

.brand {
  color: var(--heading);
  font-size: 1.15rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  flex: 1;
  justify-content: center;
  gap: 2rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-links a {
  display: block;
  padding: 0.25em 0.5em;
  border-radius: 6px;
  color: var(--heading);
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: var(--hover);
  color: #000;
}

.nav-links a[aria-current="page"] {
  box-shadow: inset 0 -3px 0 var(--accent);
}

/* menu des langues (fonctionne aussi sans JavaScript) */
.lang-menu {
  position: relative;
  font-weight: 600;
}

.lang-menu summary {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.7rem;
  border-radius: 6px;
  color: var(--heading);
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.lang-menu summary::-webkit-details-marker {
  display: none;
}

.lang-menu summary::after {
  content: "▾";
  font-size: 0.85em;
}

.lang-menu summary:hover {
  background: var(--hover);
}

.lang-menu ul {
  position: absolute;
  right: 0;
  min-width: 120px;
  margin: 0.4rem 0 0;
  padding: 0.3rem 0;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 6px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.14);
}

.lang-menu li a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 1rem;
  color: var(--heading);
  text-decoration: none;
}

.lang-menu li a:hover {
  background: var(--hover);
}

.lang-flag {
  width: 20px;
  height: 14px;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 0 0 1px #0002;
}

.hamburger {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0;
  border: 1px solid #dde1ea;
  border-radius: 6px;
  background: var(--surface);
  cursor: pointer;
}

.hamburger span {
  display: block;
  width: 1.3rem;
  height: 2px;
  background: var(--heading);
  transition: transform 0.2s, opacity 0.2s;
}

.main-nav.open .hamburger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.main-nav.open .hamburger span:nth-child(2) {
  opacity: 0;
}

.main-nav.open .hamburger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 1000px) {
  .nav-links {
    gap: 0.8rem;
  }

  .nav-links a {
    font-size: 1.1rem;
  }
}

/* mobile : menu replié derrière le bouton hamburger */
@media (max-width: 800px) {
  .main-nav {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .brand {
    margin-right: auto;
  }

  .hamburger {
    display: flex;
  }

  .nav-links {
    order: 10;
    flex-basis: 100%;
    flex-direction: column;
    gap: 0.2rem;
    padding: 0.3rem 0 0.5rem;
  }

  .js .nav-links {
    display: none;
  }

  .js .main-nav.open .nav-links {
    display: flex;
  }

  .nav-links a {
    padding: 0.6rem 0.5rem;
  }
}

/* =========================================================== */
/* ========================== Footer ========================= */
/* =========================================================== */

.site-footer {
  margin-top: auto;
  padding: 2rem 1rem;
  background: #222;
  color: #eee;
  text-align: center;
}

/* =========================================================== */
/* ========================== Accueil ======================== */
/* =========================================================== */

.hero-full-img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.home-text {
  max-width: 700px;
  margin: 0 auto 3rem;
  text-align: center;
  color: var(--text-soft);
}

.home-text h1 {
  margin: 0 0 1.5rem;
  font-size: 2rem;
}

.home-text p {
  margin: 1.1rem 0;
}

.home-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.8rem;
  padding-top: 0.8rem;
}

.villa {
  margin: 0 auto;
  max-width: 880px;
}

/* =========================================================== */
/* ====================== Diaporamas ========================= */
/* =========================================================== */

/* bloc cliquable qui ouvre le diaporama */
.gallery-block {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #ddd;
  box-shadow: 0 0 16px rgba(0, 0, 0, 0.12);
  cursor: pointer;
  transition: transform 0.15s ease-out, box-shadow 0.15s ease-out;
}

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

.gallery-block:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
}

.gallery-hint {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  padding: 1.2rem 0.6rem 0.45rem;
  font: 0.85rem var(--font);
  text-align: center;
  color: #fff;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0));
}

/* ===== Lightbox ===== */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.9);
}

.lightbox[hidden] {
  display: none;
}

.lightbox-figure {
  margin: 0;
  text-align: center;
}

.lightbox-img {
  max-width: 92vw;
  max-height: 85vh;
  border-radius: 4px;
  box-shadow: 0 0 24px rgba(0, 0, 0, 0.6);
}

.lightbox-counter {
  margin-top: 0.6rem;
  color: #ddd;
  font-size: 0.9rem;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: absolute;
  z-index: 1;
  padding: 0.2em 0.6em;
  border: none;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 2rem;
  line-height: 1.2;
  cursor: pointer;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-close {
  top: 1rem;
  right: 1rem;
}

.lightbox-prev,
.lightbox-next {
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-prev {
  left: 1rem;
}

.lightbox-next {
  right: 1rem;
}

@media (max-width: 600px) {
  .lightbox-prev,
  .lightbox-next {
    top: auto;
    bottom: 1rem;
    transform: none;
  }
}

/* =========================================================== */
/* ========================= Intérieur ======================= */
/* =========================================================== */

.interior-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: start;
  margin-bottom: 3.5rem;
}

.interior-text h2 {
  margin: 0 0 1rem;
  font-size: 1.35rem;
}

.interior-text p {
  margin: 0;
}

.interior-images .gallery-block {
  max-width: 560px;
}

/* =========================================================== */
/* ========================= Extérieur ======================= */
/* =========================================================== */

.exterior-page {
  text-align: center;
}

.ext-section {
  margin-bottom: 3.5rem;
}

.ext-section h2 {
  margin: 0 0 1.5rem;
}

.ext-gallery-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
}

.ext-gallery-row .gallery-block {
  flex: 1 1 30%;
  max-width: 460px;
}

.ext-region-text {
  max-width: 720px;
  margin: 0 auto;
}

/* =========================================================== */
/* ====================== Contact & tarif ==================== */
/* =========================================================== */

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
  gap: 3rem;
  align-items: start;
  margin-bottom: 4rem;
}

.contact-section h2 {
  margin: 0;
  font-size: 1.8rem;
}

.contact-body > p:first-child {
  margin-top: 0;
}

.contact-owners {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--heading);
}

.contact-reveal {
  margin: 1rem 0 1.5rem;
  padding: 1.2rem 1.4rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.contact-privacy {
  margin: 0 0 1rem;
  font-size: 0.92rem;
  color: #666;
}

.turnstile-box {
  min-height: 65px;
}

.contact-status {
  margin: 0.6rem 0 0;
  color: #666;
}

.contact-error {
  margin: 0.6rem 0 0;
  color: #b3261e;
}

.contact-details {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.5rem 1rem;
  margin: 0;
}

.contact-details[hidden] {
  display: none;
}

.contact-details dt {
  font-weight: 600;
}

.contact-details dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.price-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--border);
}

.price-table caption {
  padding-bottom: 0.6rem;
  font-weight: 700;
  text-align: left;
  color: var(--heading);
}

.price-table th,
.price-table td {
  padding: 0.7rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.price-table th {
  background: var(--hover);
  color: var(--heading);
}

.price-table td:last-child,
.price-table th:last-child {
  text-align: right;
  white-space: nowrap;
}

.price-table tr:last-child td {
  border-bottom: 0;
}

/* =========================================================== */
/* ======================== Responsive ======================= */
/* =========================================================== */

@media (max-width: 900px) {
  .interior-section,
  .contact-section {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .interior-images .gallery-block {
    margin: 0 auto;
  }

  .ext-gallery-row .gallery-block {
    flex-basis: 45%;
  }

  .contact-section h2 {
    font-size: 1.5rem;
  }
}

@media (max-width: 800px) {
  .hero-full-img {
    height: 200px;
  }

  .container {
    padding: 2rem 1rem;
  }
}

@media (max-width: 600px) {
  html {
    font-size: 15px;
  }

  .hero-full-img {
    height: 160px;
  }

  .home-text h1 {
    font-size: 1.5rem;
  }

  .ext-gallery-row .gallery-block {
    flex-basis: 100%;
  }

  .price-table th,
  .price-table td {
    padding: 0.6rem 0.7rem;
  }
}
