/* Villa Marne — site vitrine public */
:root {
  --nuit: #1f3a4d;
  --nuit-fonce: #152a38;
  --or: #a8874f;
  --or-clair: #e9dcc4;
  --creme: #f7f3ec;
  --encre: #22313a;
  --gris: #5d6a72;
  --blanc: #fff;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; overflow-x: hidden; font-family: var(--sans); color: var(--encre); background: var(--blanc); line-height: 1.65; font-size: 17px; }
img { max-width: 100%; display: block; }
a { color: var(--nuit); }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; color: var(--nuit); line-height: 1.15; margin: 0 0 .6em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
h3 { font-size: 1.35rem; }
.largeur { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.section { padding: 64px 20px; }
.etroit { max-width: 760px; }
.centre { text-align: center; }
.surtitre { text-transform: uppercase; letter-spacing: .18em; font-size: .78rem; color: var(--or); font-weight: 600; margin: 0 0 .6em; }
.fond-creme { background: var(--creme); }

/* Boutons */
.bouton { display: inline-block; background: var(--nuit); color: var(--blanc); text-decoration: none; padding: 12px 24px;
  border-radius: 999px; font-weight: 600; font-size: .95rem; border: 1px solid var(--nuit); cursor: pointer; font-family: var(--sans); }
.bouton:hover { background: var(--nuit-fonce); }
.bouton.clair { background: var(--blanc); color: var(--nuit); border-color: var(--blanc); }
.bouton.clair:hover { background: var(--or-clair); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* En-tête */
.haut { position: sticky; top: 0; z-index: 10; background: rgba(255, 255, 255, .96); border-bottom: 1px solid #ece6db; }
.haut-contenu { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 70px; }
.marque { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--serif); font-size: 1.5rem; color: var(--nuit); }
.haut nav { display: flex; align-items: center; gap: 22px; }
.haut nav a:not(.bouton) { text-decoration: none; color: var(--encre); font-size: .95rem; }
.haut nav a:not(.bouton):hover { color: var(--or); }
.haut nav .bouton { padding: 9px 18px; }

/* Bandeau d'accueil */
.hero { position: relative; min-height: min(78vh, 680px); display: flex; align-items: flex-end; color: var(--blanc); background: var(--nuit); overflow: hidden; }
.hero-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(21, 42, 56, .05) 30%, rgba(21, 42, 56, .78)); }
.hero-texte { position: relative; z-index: 1; padding-top: 80px; padding-bottom: 64px; width: 100%; }
.hero h1 { color: var(--blanc); margin-bottom: .2em; }
.hero .surtitre { color: var(--or-clair); }
.hero .accroche { font-size: 1.25rem; max-width: 560px; margin: 0 0 1.4em; }
.hero.sans-photo { min-height: 420px; }

/* La maison */
.deux { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.espaces { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.espaces li { border: 1px solid var(--or-clair); background: var(--creme); padding: 8px 16px; border-radius: 999px; font-size: .95rem; }
.galerie { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 40px; }
.galerie img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; transition: opacity .2s; }
.galerie a:hover img { opacity: .88; }

/* Cartes des studios */
.cartes { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 24px; margin-top: 28px; }
.carte-studio { display: flex; flex-direction: column; background: var(--blanc); border-radius: 10px; overflow: hidden; text-decoration: none;
  color: var(--encre); box-shadow: 0 1px 3px rgba(31, 58, 77, .08), 0 8px 24px rgba(31, 58, 77, .06); transition: transform .2s, box-shadow .2s; }
.carte-studio:hover { transform: translateY(-3px); box-shadow: 0 2px 6px rgba(31, 58, 77, .1), 0 14px 32px rgba(31, 58, 77, .1); }
.carte-studio img, .sans-image { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--or-clair); }
.carte-texte { padding: 18px 20px 20px; }
.carte-titre { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.carte-titre h3 { margin: 0; }
.details { color: var(--gris); margin: 4px 0 8px; font-size: .95rem; }
.prix { font-size: 1.25rem; font-weight: 600; color: var(--nuit); margin: 0 0 8px; }
.prix span { font-size: .85rem; font-weight: 400; color: var(--gris); }
.dispo { display: inline-block; font-size: .85rem; font-weight: 600; color: #1f6b45; background: #e6f4ec; padding: 3px 12px; border-radius: 999px; margin: 0; }
.dispo.loue { color: var(--gris); background: #eef0f1; }

/* Étiquettes DPE (couleurs officielles de l'échelle) */
.dpe { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 4px;
  font-weight: 700; color: var(--blanc); font-family: var(--sans); font-size: .95rem; }
.dpe-a { background: #009c6d; } .dpe-b { background: #52b153; } .dpe-c { background: #a5cc74; color: var(--encre); }
.dpe-d { background: #f4e70f; color: var(--encre); } .dpe-e { background: #f0b40f; color: var(--encre); }
.dpe-f { background: #eb8235; } .dpe-g { background: #d7221f; }
[class*="ges-"] { background: #8f6fae; }

/* Page logement */
.entete-logement { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 24px; }
.entete-logement h1 { margin-bottom: .2em; }
.photos-logement { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: clamp(110px, 15vw, 200px); gap: 10px; margin-bottom: 40px; }
.photos-logement a { display: block; }
.photos-logement img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }
.photos-logement .principale { grid-column: span 2; grid-row: span 2; }
.infos { width: 100%; border-collapse: collapse; background: var(--creme); border-radius: 10px; overflow: hidden; }
.infos th, .infos td { padding: 12px 18px; text-align: left; border-bottom: 1px solid #ebe3d4; }
.infos th { font-weight: 500; color: var(--gris); }
.infos td { font-weight: 600; color: var(--nuit); }
.mentions { font-size: .85rem; color: var(--gris); margin-top: 16px; }

/* Formulaire */
.formulaire { display: flex; flex-direction: column; gap: 18px; margin-top: 24px; }
.champ { display: flex; flex-direction: column; gap: 6px; }
.champ label { font-weight: 600; font-size: .95rem; }
.champ small, .petit { color: var(--gris); font-size: .85rem; }
.formulaire input[type=text], .formulaire input[type=email], .formulaire input[type=date], .formulaire select, .formulaire textarea {
  font: inherit; padding: 12px 14px; border: 1px solid #d9d2c5; border-radius: 8px; background: var(--blanc); width: 100%; }
.formulaire input:focus, .formulaire select:focus, .formulaire textarea:focus { outline: 2px solid var(--or); outline-offset: 1px; border-color: var(--or); }
.formulaire input[type=file] { font: inherit; padding: 10px; border: 1px dashed #cfc5b3; border-radius: 8px; background: var(--creme); width: 100%; }
.case { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; }
.case input { margin-top: 5px; width: 18px; height: 18px; flex: none; }
.formulaire .bouton { align-self: flex-start; }
.erreur { color: #b42318; font-size: .92rem; margin: 0; }
.encadre { background: var(--creme); border-left: 3px solid var(--or); padding: 14px 18px; border-radius: 4px; margin: 20px 0; }
.encadre p:last-child { margin-bottom: 0; }
.piege { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.texte h2 { font-size: 1.5rem; margin-top: 1.6em; }

/* Appel à candidater */
.appel { background: var(--nuit); color: var(--blanc); text-align: center; padding: 72px 20px; }
.appel h2 { color: var(--blanc); }
.appel p { color: #d5dde2; margin: 0 0 1.6em; }

/* Pied de page */
.pied { background: var(--nuit-fonce); color: #c9d3d9; padding: 48px 0; font-size: .95rem; }
.pied a { color: var(--blanc); }
.pied-contenu { display: grid; grid-template-columns: auto 1fr 1fr; gap: 40px; align-items: start; }
.logo-pied { filter: brightness(0) invert(1); opacity: .9; }

/* Téléphone */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .section { padding: 44px 16px; }
  .largeur { padding: 0 16px; }
  .haut nav { gap: 14px; }
  .haut nav a:not(.bouton):first-child { display: none; }
  .marque span { font-size: 1.25rem; }
  .deux { grid-template-columns: 1fr; gap: 28px; }
  .galerie { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .photos-logement { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 34vw; }
  .pied-contenu { grid-template-columns: 1fr; gap: 20px; }
  .hero-texte { padding-bottom: 40px; }
  .bouton { padding: 12px 20px; }
}
@media (max-width: 420px) {
  .haut nav a:not(.bouton) { display: none; }
}
.galerie-suite { grid-template-columns: repeat(4, minmax(0, 1fr)); margin: -30px 0 40px; }
@media (max-width: 760px) { .galerie-suite { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Compteurs (studios loués / disponibles) */
.compteurs { background: var(--creme); border-bottom: 1px solid #ebe3d4; }
.compteurs-contenu { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 40px; padding-top: 22px; padding-bottom: 22px; }
.compteurs-contenu div { font-size: 1rem; color: var(--gris); }
.compteurs-contenu strong { font-family: var(--serif); font-size: 2rem; font-weight: 500; color: var(--nuit); margin-right: 6px; }
.compteurs-contenu p { margin: 0; flex: 1 1 320px; color: var(--encre); }

/* Studio sans photo */
.sans-image { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--creme), var(--or-clair)); }
.sans-image span { font-family: var(--serif); font-size: 1.3rem; color: var(--nuit); letter-spacing: .04em; }
.photos-a-venir { aspect-ratio: 21 / 8; border-radius: 10px; margin-bottom: 40px; }

/* Sous-titre de l'accueil et questions fréquentes (référencement) */
.hero .sous-titre { font-size: 1.05rem; margin: 0 0 .8em; opacity: .92; }
.question { border-bottom: 1px solid #ebe3d4; padding: 14px 0; }
.question summary { cursor: pointer; font-family: var(--serif); font-size: 1.3rem; color: var(--nuit); list-style: none; }
.question summary::-webkit-details-marker { display: none; }
.question summary::after { content: "+"; float: right; color: var(--or); font-family: var(--sans); }
.question[open] summary::after { content: "–"; }
.question p { margin: .6em 0 0; color: var(--encre); }
