/* Démo « Trouvez votre maison » — Engel & Völkers Saint-Sauveur.
   Tout ce qui est posé par-dessus la carte (branche « Parcours et panneaux ») :
   barre du haut, étapes de critères, panneau de critères, liste, fiche, feuilles du bas.
   Langage : colonnes blanches éditoriales, Inter fine, filets, boutons noirs, rouge en touche seulement.
   Les épingles, les noms de villes et le secteur vivent dans carte.css (branche « Carte »). */
:root {
  --ev-red: #e60000;
  --ev-red-dark: #b80000;
  --ink: #242323;
  --ink-2: #565251;
  --ink-3: #8c8886;
  --ink-4: #bdb8b4;
  --line: rgba(36, 35, 35, 0.09);
  --line-2: rgba(36, 35, 35, 0.16);
  --line-3: rgba(36, 35, 35, 0.32);
  --paper: #ffffff;
  --paper-2: #f8f6f3;
  --paper-3: #efebe6;
  --top: 72px;
  --col-wiz: 480px;
  --col-l: 380px;
  --col-r: 440px;
  --pad: 44px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-l: 1px 0 0 rgba(36, 35, 35, 0.07), 24px 0 60px -24px rgba(30, 26, 22, 0.22);
  --shadow-r: -1px 0 0 rgba(36, 35, 35, 0.07), -24px 0 60px -24px rgba(30, 26, 22, 0.22);
  --float: 0 1px 2px rgba(30, 26, 22, 0.08), 0 10px 30px rgba(30, 26, 22, 0.14);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; }
body {
  background: #f4f1ea;
  color: var(--ink);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
button, select, input { font: inherit; color: inherit; }
button { -webkit-tap-highlight-color: transparent; }
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
img { display: block; }

/* Carte */
#map { position: fixed; inset: 0; z-index: 1; }
.maplibregl-canvas { outline: none; }
.maplibregl-ctrl-bottom-right, .maplibregl-ctrl-bottom-left { transition: right 0.8s var(--ease), left 0.8s var(--ease), opacity 0.4s; }
.phase-wizard .maplibregl-ctrl-bottom-right .maplibregl-ctrl-group,
.phase-flight .maplibregl-ctrl-bottom-right .maplibregl-ctrl-group { opacity: 0; pointer-events: none; }
.phase-wizard .maplibregl-ctrl-bottom-left { left: var(--col-wiz); }
.phase-explore .maplibregl-ctrl-bottom-right, .phase-detail .maplibregl-ctrl-bottom-right { right: var(--col-r); }
.phase-explore .maplibregl-ctrl-bottom-left, .phase-detail .maplibregl-ctrl-bottom-left { left: var(--col-l); }

/* Petites capitales espacées, le titre courant des magazines immobiliers */
.eyebrow, .wiz-step, .section-title, .card-place, .detail-place, .group-title, .why h3, .facts dt, .feat-title {
  font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3);
}
.eyebrow { display: flex; align-items: center; gap: 14px; margin: 0; }
.eyebrow.is-accent::before { content: ""; width: 24px; height: 1.5px; background: var(--ev-red); flex: none; }

/* Barre du haut */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; height: var(--top); z-index: 30;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 0 28px 0 var(--pad);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 18px; text-decoration: none; color: var(--ink); min-width: 0; }
.brand img { height: 19px; width: auto; }
.brand-office { font-size: 10.5px; font-weight: 500; letter-spacing: 0.24em; text-transform: uppercase; color: var(--ink-2); padding-left: 18px; border-left: 1px solid var(--line-2); line-height: 22px; white-space: nowrap; }
.topbar-actions { display: flex; align-items: center; gap: 28px; }
.demo-pill { display: inline-flex; align-items: center; gap: 10px; font-size: 10.5px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap; }
.demo-pill i { width: 5px; height: 5px; border-radius: 50%; background: var(--ev-red); }
/* Bouton de langue FR / EN */
.lang { display: inline-flex; border: 1px solid var(--line-2); border-radius: 2px; overflow: hidden; }
.lang button {
  height: 32px; min-width: 38px; padding: 0 10px; border: 0; background: var(--paper); cursor: pointer;
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.16em; color: var(--ink-3); transition: background 0.25s, color 0.25s;
}
.lang button + button { border-left: 1px solid var(--line-2); }
.lang button:hover { color: var(--ink); }
.lang button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.ghost-btn {
  display: inline-flex; align-items: center; gap: 10px; height: 40px; padding: 0 16px;
  background: var(--paper); border: 1px solid var(--line-3); border-radius: 2px; cursor: pointer;
  font-size: 10.5px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; white-space: nowrap;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.ghost-btn:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.ghost-btn svg { width: 15px; height: 15px; }
.phase-wizard #replay { display: none; }

/* Boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 52px; padding: 0 26px; border: 0; border-radius: 2px; cursor: pointer; white-space: nowrap;
  font-size: 11.5px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase;
  transition: background 0.25s, color 0.25s, border-color 0.25s, opacity 0.25s;
}
.btn svg { width: 16px; height: 16px; transition: transform 0.4s var(--ease); }
.btn:hover:not(:disabled) svg { transform: translateX(3px); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover:not(:disabled) { background: #000; }
.btn-ink:disabled { background: var(--paper-3); color: var(--ink-3); cursor: not-allowed; }
.btn-quiet { background: none; color: var(--ink-2); padding: 0 14px; }
.btn-quiet:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
.btn-line { background: var(--paper); color: var(--ink); border: 1px solid var(--line-3); }
.btn-line:hover { border-color: var(--ink); }
.btn-square { width: 52px; padding: 0; }
.btn-square:hover svg { transform: none; }

/* Coche ronde des choix */
.tick { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line-3); flex: none; transition: background 0.25s, border-color 0.25s; }
.tick svg { width: 12px; height: 12px; stroke: #fff; stroke-width: 2.2; opacity: 0; transform: scale(0.5); transition: opacity 0.2s, transform 0.35s var(--ease); }
[aria-pressed="true"] > .tick { background: var(--ink); border-color: var(--ink); }
[aria-pressed="true"] > .tick svg { opacity: 1; transform: none; }

/* Parcours : colonne éditoriale à gauche */
.wizard {
  position: fixed; z-index: 16; left: 0; top: var(--top); bottom: 0; width: var(--col-wiz);
  display: flex; flex-direction: column;
  background: var(--paper); box-shadow: var(--shadow-l);
  transition: transform 0.9s var(--ease), opacity 0.6s;
}
body:not(.phase-wizard) .wizard { transform: translateX(-104%); opacity: 0; pointer-events: none; }
.wiz-head { padding: 34px var(--pad) 0; }
.wiz-progress { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 26px; }
.wiz-progress span { height: 2px; background: var(--line-2); transition: background 0.5s; }
.wiz-progress span.done { background: var(--ink); }
.wiz-progress span.now { background: var(--ev-red); }
.wiz-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; min-height: 22px; }
.wiz-step { margin: 0; font-variant-numeric: tabular-nums; }
.wiz-step b { color: var(--ink); font-weight: 600; }
.wiz-back { display: inline-flex; align-items: center; gap: 8px; padding: 4px 0; border: 0; background: none; cursor: pointer; font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-2); }
.wiz-back svg { width: 14px; height: 14px; transition: transform 0.4s var(--ease); }
.wiz-back:hover { color: var(--ink); }
.wiz-back:hover svg { transform: translateX(-3px); }
.wiz-back[hidden] { display: none; }
.wiz-head h1 { margin: 12px 0 0; font-size: 38px; line-height: 1.08; font-weight: 300; letter-spacing: -0.035em; color: var(--ink); }
.wiz-help { margin: 12px 0 0; font-size: 14.5px; line-height: 1.6; color: var(--ink-2); max-width: 44ch; }
.wiz-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 24px var(--pad) 28px; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.wiz-body.enter > * { animation: rise 0.6s var(--ease) both; }
.wiz-body.enter > *:nth-child(2) { animation-delay: 0.05s; }
.wiz-body.enter > *:nth-child(3) { animation-delay: 0.1s; }
.wiz-body.enter > *:nth-child(4) { animation-delay: 0.15s; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.wiz-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px var(--pad); border-top: 1px solid var(--line); }
.wiz-count { margin: 0; display: flex; align-items: center; gap: 14px; font-size: 10.5px; font-weight: 500; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3); line-height: 1.5; }
.wiz-count b { font-size: 46px; font-weight: 300; letter-spacing: -0.04em; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; min-width: 1.1ch; }
.wiz-count span { max-width: 12ch; }
.wiz-foot .btn-ink { flex: none; }
.wizard.is-last .wiz-count { display: none; }
.wizard.is-last .wiz-foot .btn-ink { flex: 1; }
.intro-note { margin: 0; padding: 0 var(--pad) 18px; font-size: 11.5px; color: var(--ink-3); }

/* Étape 1 : où */
.place-all {
  width: 100%; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px;
  padding: 16px 18px; border: 1px solid var(--line-2); border-radius: 2px; background: var(--paper);
  text-align: left; cursor: pointer; transition: border-color 0.25s, box-shadow 0.25s;
}
.place-all:hover { border-color: var(--line-3); }
.place-all[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.place-all > svg { width: 22px; height: 22px; color: var(--ink-2); }
.place-all b { display: block; font-size: 15px; font-weight: 500; }
.place-all small { display: block; margin-top: 2px; font-size: 12.5px; color: var(--ink-3); }
.place-grid { display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; margin-top: 18px; }
.place {
  display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 10px;
  padding: 12px 0; border: 0; border-bottom: 1px solid var(--line); background: none; text-align: left; cursor: pointer;
}
.place-name { font-size: 15px; line-height: 1.3; color: var(--ink); }
.place-n { grid-row: 2; font-size: 12px; color: var(--ink-3); margin-top: 3px; }
.place .tick { grid-column: 2; grid-row: 1 / span 2; }
.place:hover .place-name { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.place[aria-pressed="true"] .place-name { font-weight: 500; }

/* Étape 2 : type, en photos */
.type-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.type-photo {
  position: relative; display: block; aspect-ratio: 4 / 3.25; padding: 0; border: 0; border-radius: 2px; overflow: hidden;
  background: var(--paper-3); color: #fff; text-align: left; cursor: pointer; transition: box-shadow 0.3s;
}
.type-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s var(--ease); }
.type-photo:hover img { transform: scale(1.06); }
.type-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 18, 16, 0) 38%, rgba(20, 18, 16, 0.74)); }
.type-photo-label { position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 1; }
.type-photo-label b { display: block; font-size: 19px; font-weight: 400; letter-spacing: -0.01em; }
.type-photo-label small { display: block; font-size: 12px; opacity: 0.82; }
.type-photo .tick { position: absolute; top: 12px; right: 12px; z-index: 1; border-color: rgba(255, 255, 255, 0.85); background: rgba(20, 18, 16, 0.18); }
.type-photo[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--paper), 0 0 0 3.5px var(--ink); }
.type-photo[aria-pressed="true"] > .tick { background: #fff; border-color: #fff; }
.type-photo[aria-pressed="true"] > .tick svg { stroke: var(--ink); }

/* Étape 3 : budget */
.budget-value { margin: 0; font-size: 36px; font-weight: 300; letter-spacing: -0.035em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.budget-sub { margin: 8px 0 28px; font-size: 12.5px; color: var(--ink-3); }
.hist { display: flex; align-items: flex-end; gap: 4px; height: 96px; margin: 0 11px; }
.hist i { flex: 1; background: var(--line-2); min-height: 2px; transition: background 0.3s, height 0.6s var(--ease); }
.hist i.on { background: var(--ink); }
.range { position: relative; height: 34px; }
.range-track { position: absolute; left: 11px; right: 11px; top: 16px; height: 1px; background: var(--line-3); }
.range-fill { position: absolute; top: 15px; height: 3px; background: var(--ink); }
.range input { position: absolute; inset: 0; width: 100%; height: 34px; margin: 0; background: none; pointer-events: none; -webkit-appearance: none; appearance: none; }
.range input::-webkit-slider-thumb { -webkit-appearance: none; pointer-events: auto; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 1px solid var(--ink); box-shadow: 0 2px 8px rgba(30, 26, 22, 0.18); cursor: grab; }
.range input::-moz-range-thumb { pointer-events: auto; width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 1px solid var(--ink); cursor: grab; }
.range input::-webkit-slider-runnable-track { background: none; }
.range input::-moz-range-track { background: none; }
.range-labels { display: flex; justify-content: space-between; margin-top: 4px; font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.single-range { width: 100%; height: 34px; margin: 0; background: none; -webkit-appearance: none; appearance: none; cursor: pointer; }
.single-range::-webkit-slider-runnable-track { height: 1px; background: var(--line-3); }
.single-range::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; margin-top: -11px; border-radius: 50%; background: #fff; border: 1px solid var(--ink); box-shadow: 0 2px 8px rgba(30, 26, 22, 0.18); }
.single-range::-moz-range-track { height: 1px; background: var(--line-3); }
.single-range::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 1px solid var(--ink); }

/* Étape 4 : chambres et salles de bain */
.wiz-label { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 30px 0 12px; font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3); }
.wiz-label:first-child { margin-top: 0; }
.wiz-label span { font-size: 13px; letter-spacing: 0; text-transform: none; color: var(--ink); font-variant-numeric: tabular-nums; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; border: 1px solid var(--line-2); border-radius: 2px; overflow: hidden; }
.seg button { height: 48px; border: 0; border-left: 1px solid var(--line-2); background: var(--paper); font-size: 14px; color: var(--ink-2); cursor: pointer; font-variant-numeric: tabular-nums; transition: background 0.25s, color 0.25s; }
.seg button:first-child { border-left: 0; }
.seg button:hover { background: var(--paper-2); color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: #fff; }

/* Étape 5 : style de vie */
.feat-grid { display: grid; grid-template-columns: 1fr 1fr; column-gap: 24px; }
.feat {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px;
  padding: 13px 0; border: 0; border-bottom: 1px solid var(--line); background: none; text-align: left; cursor: pointer;
}
.feat > svg { width: 20px; height: 20px; color: var(--ink-2); }
.feat span { font-size: 14px; line-height: 1.3; }
.feat:hover span { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.feat[aria-pressed="true"] span { font-weight: 500; }
.feat[aria-pressed="true"] > svg { color: var(--ink); }

/* Pendant le vol */
.hud {
  position: fixed; z-index: 12; left: 50%; bottom: 40px; transform: translateX(-50%) translateY(20px);
  display: flex; align-items: center; gap: 14px; padding: 14px 22px; border-radius: 2px;
  background: var(--paper); color: var(--ink); box-shadow: var(--float);
  font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity 0.5s, transform 0.7s var(--ease);
}
.phase-flight .hud { opacity: 1; transform: translateX(-50%); }
.hud-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--ev-red); animation: pulse 1.6s infinite; }
.hud-meta { color: var(--ink-3); letter-spacing: 0.08em; text-transform: none; font-variant-numeric: tabular-nums; padding-left: 14px; border-left: 1px solid var(--line-2); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(230, 0, 0, 0.5); } 70% { box-shadow: 0 0 0 9px rgba(230, 0, 0, 0); } 100% { box-shadow: 0 0 0 0 rgba(230, 0, 0, 0); } }

/* Colonnes après le vol : critères à gauche, liste et fiche à droite */
.panel {
  position: fixed; z-index: 15; top: var(--top); bottom: 0;
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--paper);
  transition: transform 0.9s var(--ease), opacity 0.6s;
}
.criteria { left: 0; width: var(--col-l); box-shadow: var(--shadow-l); }
.results, .detail { right: 0; width: var(--col-r); box-shadow: var(--shadow-r); }
.phase-wizard .criteria, .phase-flight .criteria { transform: translateX(-104%); opacity: 0; pointer-events: none; }
.phase-wizard .results, .phase-flight .results, .phase-detail .results { transform: translateX(104%); opacity: 0; pointer-events: none; }
.detail { transform: translateX(104%); opacity: 0; }
.phase-detail .detail { transform: none; opacity: 1; }
.phase-explore .results { transition-delay: 0.12s; }
.panel-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.panel-head { padding: 28px 32px 22px; border-bottom: 1px solid var(--line); }
.panel-head-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; }
.panel-head-row .eyebrow { margin-right: auto; }
.link-btn { display: inline-flex; align-items: center; gap: 8px; padding: 6px 0; border: 0; background: none; cursor: pointer; font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-2); }
.link-btn:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
.panel-foot { display: flex; align-items: center; gap: 10px; padding: 16px 32px; border-top: 1px solid var(--line); background: var(--paper); }
.panel-foot .btn-ink { flex: 1; }

/* Panneau de critères */
.summary { display: flex; align-items: center; gap: 16px; margin-top: 18px; }
.summary-num { font-size: 56px; font-weight: 300; line-height: 0.95; letter-spacing: -0.045em; color: var(--ink); font-variant-numeric: tabular-nums; min-width: 1.1ch; }
.summary-text { font-size: 13px; color: var(--ink-3); line-height: 1.45; }
.summary-text strong { display: block; color: var(--ink); font-weight: 500; font-size: 14px; }
.section { padding: 22px 32px 24px; border-bottom: 1px solid var(--line); }
.section:last-child { border-bottom: 0; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 0 0 14px; }
.section-title .value { font-size: 13px; font-weight: 400; letter-spacing: 0; text-transform: none; color: var(--ink); font-variant-numeric: tabular-nums; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 13px;
  border: 1px solid var(--line-2); border-radius: 2px; background: var(--paper); cursor: pointer;
  font-size: 13px; color: var(--ink); white-space: nowrap; transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.chip svg { width: 15px; height: 15px; color: var(--ink-2); }
.chip:hover { border-color: var(--line-3); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip[aria-pressed="true"] svg { color: #fff; }
.chip-n { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.chip[aria-pressed="true"] .chip-n { color: rgba(255, 255, 255, 0.6); }
.type-grid { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line-2); border-radius: 2px; overflow: hidden; }
.type-tile {
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 4px 12px;
  border: 0; border-left: 1px solid var(--line-2); background: var(--paper); cursor: pointer;
  font-size: 12.5px; transition: background 0.25s, color 0.25s;
}
.type-tile:first-child { border-left: 0; }
.type-tile svg { width: 22px; height: 22px; stroke-width: 1.3; }
.type-tile .n { font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.type-tile:hover { background: var(--paper-2); }
.type-tile[aria-pressed="true"] { background: var(--ink); color: #fff; }
.type-tile[aria-pressed="true"] .n { color: rgba(255, 255, 255, 0.6); }
.criteria .hist { height: 52px; }
.criteria .seg button { height: 40px; font-size: 13px; }

/* Liste des propriétés */
.results-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-top: 14px; }
.results-head h2 { margin: 0; font-size: 30px; font-weight: 300; letter-spacing: -0.035em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.results-head p { margin: 6px 0 0; font-size: 13px; color: var(--ink-3); }
.sort {
  height: 34px; padding: 0 22px 0 0; border: 0; border-bottom: 1px solid var(--line-3); border-radius: 0;
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23242323' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right center / 14px no-repeat;
  -webkit-appearance: none; appearance: none; cursor: pointer;
  font-size: 10.5px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink);
}
.cards { display: grid; padding: 0 32px; }
.card {
  display: block; width: 100%; padding: 26px 0 24px; border: 0; border-bottom: 1px solid var(--line);
  background: none; text-align: left; cursor: pointer;
}
.card-media { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 2px; background: var(--paper-3); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.4s var(--ease); }
.card:hover .card-media img, .card.is-hover .card-media img { transform: scale(1.045); }
.badge { position: absolute; top: 12px; left: 12px; padding: 6px 9px; border-radius: 2px; background: var(--paper); color: var(--ink); font-size: 9.5px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; }
.card-type { position: absolute; right: 12px; bottom: 12px; padding: 5px 9px; border-radius: 2px; background: rgba(20, 18, 16, 0.5); backdrop-filter: blur(6px); color: #fff; font-size: 9.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; }
.card-body { display: block; padding-top: 16px; }
.card-place { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-title { display: block; margin-top: 8px; font-size: 17px; font-weight: 400; line-height: 1.35; letter-spacing: -0.01em; color: var(--ink); }
.card:hover .card-title, .card.is-hover .card-title { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.card-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 12px; }
.card-price { font-size: 19px; font-weight: 500; letter-spacing: -0.015em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.card-specs { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.card-tags { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 12px; font-size: 12px; color: var(--ink-2); }
.card-tags span { display: inline-flex; align-items: center; gap: 6px; }
.card-tags svg { width: 13px; height: 13px; stroke-width: 2; color: var(--ink); }
.card-miss { display: block; margin-top: 12px; font-size: 12.5px; color: var(--ink-3); }
.card-miss b { color: var(--ink); font-weight: 500; }
.card.is-near .card-media img { filter: saturate(0.7); }
.group-head { padding: 34px 32px 0; }
.group-title { display: flex; align-items: center; gap: 14px; margin: 0; }
.group-title::before { content: ""; width: 24px; height: 1px; background: var(--ink-3); }
.group-sub { margin: 8px 0 0; font-size: 13px; color: var(--ink-3); }
.empty { padding: 34px 32px 6px; color: var(--ink-2); font-size: 14px; line-height: 1.6; }
.empty strong { display: block; color: var(--ink); font-size: 20px; font-weight: 300; letter-spacing: -0.02em; margin-bottom: 8px; }
.fine { margin: 0; padding: 22px 32px 30px; font-size: 11.5px; color: var(--ink-3); line-height: 1.6; }

/* Fiche d'une propriété */
.gallery { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--paper-3); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: opacity 0.45s; }
.gallery img.is-loading { opacity: 0.35; }
.gallery::after { content: ""; position: absolute; inset: auto 0 0; height: 40%; background: linear-gradient(180deg, rgba(20, 18, 16, 0), rgba(20, 18, 16, 0.38)); pointer-events: none; }
.round-btn {
  position: absolute; z-index: 2; width: 42px; height: 42px; border: 0; border-radius: 50%;
  display: grid; place-items: center; background: rgba(255, 255, 255, 0.94); color: var(--ink);
  box-shadow: 0 2px 10px rgba(20, 18, 16, 0.18); cursor: pointer; transition: background 0.25s, transform 0.3s var(--ease);
}
.round-btn:hover { background: #fff; transform: scale(1.06); }
.round-btn svg { width: 17px; height: 17px; }
.back-pill {
  position: absolute; z-index: 2; top: 16px; left: 16px; display: inline-flex; align-items: center; gap: 8px;
  height: 38px; padding: 0 14px 0 12px; border: 0; border-radius: 2px; background: var(--paper); color: var(--ink); cursor: pointer;
  box-shadow: 0 2px 10px rgba(20, 18, 16, 0.16); font-size: 10.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase;
}
.back-pill svg { width: 15px; height: 15px; transition: transform 0.4s var(--ease); }
.back-pill:hover svg { transform: translateX(-3px); }
.round-btn.prev { top: 50%; left: 16px; margin-top: -21px; }
.round-btn.next { top: 50%; right: 16px; margin-top: -21px; }
.gal-tag { position: absolute; z-index: 2; bottom: 16px; padding: 6px 10px; border-radius: 2px; font-size: 9.5px; font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; }
.gal-tag.type { left: 16px; background: var(--paper); color: var(--ink); }
.gal-tag.count { right: 16px; background: rgba(20, 18, 16, 0.5); color: #fff; backdrop-filter: blur(6px); font-variant-numeric: tabular-nums; }
.detail-body { padding: 30px 32px 8px; }
.detail-place { margin: 0; }
.detail-title { margin: 12px 0 0; font-size: 28px; font-weight: 300; line-height: 1.18; letter-spacing: -0.03em; }
.detail-price { margin: 14px 0 0; font-size: 22px; font-weight: 500; letter-spacing: -0.015em; font-variant-numeric: tabular-nums; }
.detail-approx { display: flex; align-items: center; gap: 7px; margin: 8px 0 0; font-size: 12.5px; color: var(--ink-3); }
.detail-approx svg { width: 14px; height: 14px; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); margin: 26px 0 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts div { display: flex; flex-direction: column-reverse; justify-content: flex-end; gap: 6px; padding: 16px 0 16px 14px; border-left: 1px solid var(--line); min-width: 0; }
.facts div:first-child { border-left: 0; padding-left: 0; }
.facts dd { margin: 0; font-size: 22px; font-weight: 300; letter-spacing: -0.02em; line-height: 1; font-variant-numeric: tabular-nums; }
.facts dt { font-size: 9.5px; letter-spacing: 0.16em; line-height: 1.35; }
.why { margin-top: 30px; }
.why h3, .feat-title { display: flex; align-items: center; gap: 14px; margin: 0 0 12px; }
.why h3::before { content: ""; width: 24px; height: 1.5px; background: var(--ev-red); }
.feat-title::before { content: ""; width: 24px; height: 1px; background: var(--ink-3); }
.why ul { list-style: none; margin: 0; padding: 0; }
.why li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.why li svg { width: 16px; height: 16px; margin-top: 2px; stroke-width: 2; color: var(--ink); }
.why li.miss { color: var(--ink-3); }
.why li.miss svg { color: var(--ink-4); }
.dist { display: grid; grid-template-columns: 1fr 1fr; margin-top: 26px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dist div { display: flex; gap: 12px; align-items: center; padding: 16px 0; font-size: 12.5px; color: var(--ink-3); }
.dist div + div { padding-left: 16px; border-left: 1px solid var(--line); }
.dist svg { width: 20px; height: 20px; color: var(--ink-2); }
.dist b { display: block; font-size: 15px; font-weight: 500; color: var(--ink); }
.detail-desc { margin: 26px 0 0; font-size: 15px; line-height: 1.75; color: var(--ink-2); }
.feat-block { margin-top: 30px; }
.feat-list { display: grid; grid-template-columns: 1fr 1fr; column-gap: 20px; margin: 0 0 8px; padding: 0; list-style: none; }
.feat-list li { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.feat-list svg { width: 17px; height: 17px; color: var(--ink-2); }

/* Bulle de décompte, outils de la carte, message */
.count-chip {
  position: fixed; z-index: 14; bottom: 34px;
  left: calc(var(--col-l) + (100vw - var(--col-l) - var(--col-r)) / 2);
  transform: translateX(-50%) translateY(16px); opacity: 0; pointer-events: none;
  padding: 13px 20px; border-radius: 2px; background: var(--paper); box-shadow: var(--float);
  font-size: 10.5px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); white-space: nowrap;
  transition: opacity 0.5s, transform 0.6s var(--ease);
}
.count-chip b { color: var(--ink); font-weight: 600; }
.phase-explore .count-chip { opacity: 1; transform: translateX(-50%); }
.map-tools {
  position: fixed; z-index: 14; top: calc(var(--top) + 20px); right: calc(var(--col-r) + 20px);
  display: flex; flex-direction: column; border-radius: 2px; overflow: hidden; box-shadow: var(--float);
  opacity: 0; pointer-events: none; transition: opacity 0.4s;
}
.phase-explore .map-tools, .phase-detail .map-tools { opacity: 1; pointer-events: auto; }
.tool-btn { display: grid; place-items: center; width: 44px; height: 44px; border: 0; background: var(--paper); cursor: pointer; font-size: 10.5px; font-weight: 600; letter-spacing: 0.12em; transition: background 0.25s, color 0.25s; }
.tool-btn + .tool-btn { border-top: 1px solid var(--line); }
.tool-btn:hover { background: var(--paper-2); }
.tool-btn[aria-pressed="false"] { color: var(--ink-4); }
.tool-btn svg { width: 17px; height: 17px; }
.toast {
  position: fixed; z-index: 40; left: 50%; top: calc(var(--top) + 18px); transform: translateX(-50%) translateY(-12px);
  max-width: min(460px, calc(100vw - 32px)); padding: 14px 20px; border-radius: 2px;
  background: var(--ink); color: #fff; box-shadow: var(--float); font-size: 13.5px; line-height: 1.5;
  opacity: 0; pointer-events: none; transition: opacity 0.3s, transform 0.5s var(--ease);
}
.toast.show { opacity: 1; transform: translateX(-50%); }
.mobile-bar { display: none; }
.sheet-close { display: none; place-items: center; width: 36px; height: 36px; border: 1px solid var(--line-2); border-radius: 50%; background: var(--paper); cursor: pointer; flex: none; }
.sheet-close svg { width: 16px; height: 16px; }

/* Écrans d'ordinateur plus étroits */
@media (max-width: 1180px) and (min-width: 761px) {
  :root { --col-wiz: 440px; --col-l: 330px; --col-r: 380px; --pad: 34px; }
  .panel-head, .section, .panel-foot, .detail-body, .fine, .group-head, .empty { padding-left: 26px; padding-right: 26px; }
  .cards { padding: 0 26px; }
  .demo-pill { display: none; }
}

/* Téléphone : feuilles du bas */
@media (max-width: 760px) {
  :root { --top: 56px; --pad: 22px; }
  .topbar { padding: 0 12px 0 18px; }
  .brand img { height: 15px; }
  .brand-office, .demo-pill { display: none; }
  #replay { width: 40px; padding: 0; justify-content: center; }
  .topbar-actions { gap: 10px; }
  .lang button { height: 34px; min-width: 36px; padding: 0 8px; }
  #replay span { display: none; }

  .wizard, .panel {
    left: 0; right: 0; width: auto; top: auto; bottom: 0;
    border-radius: 16px 16px 0 0; box-shadow: 0 -1px 0 rgba(36, 35, 35, 0.06), 0 -16px 44px rgba(30, 26, 22, 0.18);
  }
  .wizard::before, .panel::before { content: ""; position: absolute; top: 8px; left: 50%; width: 36px; height: 4px; margin-left: -18px; border-radius: 4px; background: var(--line-2); z-index: 3; }
  .wizard { max-height: 66vh; }
  body:not(.phase-wizard) .wizard { transform: translateY(104%); }
  .wiz-head { padding: 22px var(--pad) 0; }
  .wiz-head .eyebrow { display: none; }
  .wiz-progress { margin-top: 6px; }
  .wiz-step { margin-top: 14px; }
  .wiz-head h1 { margin-top: 8px; font-size: 27px; }
  .wiz-help { margin-top: 8px; font-size: 13.5px; }
  .wiz-body { padding: 18px var(--pad) 18px; }
  .wiz-foot { padding: 12px var(--pad) 12px; gap: 10px; }
  .wiz-count { gap: 10px; }
  .wiz-count b { font-size: 34px; }
  .wiz-count span { font-size: 9.5px; }
  .btn { height: 46px; padding: 0 18px; letter-spacing: 0.14em; }
  .btn-quiet { padding: 0 10px; }
  .btn-square { width: 46px; padding: 0; }
  .intro-note { padding: 0 var(--pad) calc(10px + env(safe-area-inset-bottom)); font-size: 11px; }
  .place-grid { column-gap: 18px; margin-top: 12px; }
  .place { padding: 11px 0; }
  .place-name { font-size: 14px; }
  .place-all { padding: 13px 14px; }
  .type-photo { aspect-ratio: 4 / 3; }
  .type-photo-label b { font-size: 16px; }
  .budget-value { font-size: 28px; }
  .budget-sub { margin-bottom: 18px; }
  .hist { height: 64px; }
  .feat-grid { column-gap: 16px; }
  .feat { padding: 11px 0; gap: 10px; }
  .feat span { font-size: 13px; }
  .hud { bottom: 28px; padding: 12px 18px; }
  .hud-meta { display: none; }

  .panel { height: min(76vh, 680px); transform: translateY(104%); opacity: 1; }
  .phase-wizard .criteria, .phase-flight .criteria, .phase-explore .criteria, .phase-detail .criteria,
  .phase-wizard .results, .phase-flight .results, .phase-explore .results, .phase-detail .results { transform: translateY(104%); }
  .criteria.is-open, .results.is-open { transform: none !important; opacity: 1 !important; pointer-events: auto !important; }
  .phase-detail .detail { transform: none; height: 86vh; }
  .panel-head { padding: 24px var(--pad) 16px; }
  .results-head { margin-top: 0; }
  .results-head h2 { font-size: 26px; }
  .section { padding: 18px var(--pad) 20px; }
  .panel-foot { padding: 12px var(--pad) calc(12px + env(safe-area-inset-bottom)); }
  .cards { padding: 0 var(--pad); }
  .card { padding: 20px 0; }
  .group-head, .empty, .fine { padding-left: var(--pad); padding-right: var(--pad); }
  .detail-body { padding: 24px var(--pad) 8px; }
  .detail-title { font-size: 24px; }
  .gallery { aspect-ratio: 16 / 10; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .facts div:nth-child(3) { border-left: 0; padding-left: 0; }
  .facts div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .sheet-close { display: grid; }
  .summary-num { font-size: 46px; }

  .mobile-bar {
    position: fixed; z-index: 16; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom));
    display: flex; border-radius: 2px; overflow: hidden; background: var(--paper); box-shadow: var(--float);
    transform: translateX(-50%) translateY(100px); transition: transform 0.6s var(--ease);
  }
  .phase-explore:not(.sheet-open) .mobile-bar { transform: translateX(-50%); }
  .mobile-bar button {
    display: inline-flex; align-items: center; gap: 10px; height: 50px; padding: 0 20px; border: 0; background: none; cursor: pointer; white-space: nowrap;
    font-size: 10.5px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase;
  }
  .mobile-bar button svg { width: 16px; height: 16px; }
  .mobile-bar button + button { background: var(--ink); color: #fff; }
  .count-chip { left: 50%; top: calc(var(--top) + 12px); bottom: auto; padding: 10px 16px; font-size: 9.5px; }
  .chip-near { display: none; }
  .phase-explore .maplibregl-ctrl-bottom-right { bottom: 80px; }
  .phase-explore.sheet-open .count-chip { opacity: 0; }
  .map-tools { top: calc(var(--top) + 62px); right: 12px; }
  .maplibregl-ctrl-bottom-right .maplibregl-ctrl-group { display: none; }
  .phase-explore .maplibregl-ctrl-bottom-right, .phase-detail .maplibregl-ctrl-bottom-right { right: 0; }
  .phase-explore .maplibregl-ctrl-bottom-left, .phase-detail .maplibregl-ctrl-bottom-left { left: 0; bottom: 84px; }
  .phase-wizard .maplibregl-ctrl-bottom-left { left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
