/* EffaImmo — site public
   Un seul élément marquant : la recherche présentée comme une plaque de rue émaillée. Le reste reste sobre. */
:root {
  --slate: #14424A;
  --slate-deep: #0D2E34;
  --slate-soft: #E3ECEC;
  --stone: #EEF1EF;
  --paper: #FFFFFF;
  --ink: #1B2A2E;
  --muted: #5D6D71;
  --line: #D6DEDC;
  --brass: #B98A2E;
  --ok: #2E7A57; --warn: #9A6412; --bad: #AE3B2A; --info: #285E8E;
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: "Young Serif", Georgia, serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { font-size: 16px; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--paper); line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: var(--slate); }
img { max-width: 100%; }
:focus-visible { outline: 3px solid var(--brass); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--paper); padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; }
.wrap { width: min(1200px, 100% - 40px); margin-inline: auto; }
.muted { color: var(--muted); }
.hp { position: absolute; left: -5000px; }
h1, h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -.005em; line-height: 1.2; }
h2 { font-size: 1.55rem; margin: 0 0 16px; }

/* ---------- Plaque ---------- */
.plaque { display: inline-grid; place-items: center; width: 42px; height: 30px; background: var(--slate); color: #fff; font-family: var(--serif); font-size: 14px; border-radius: 7px; box-shadow: inset 0 0 0 2px var(--slate), inset 0 0 0 3.5px #fff; }

/* ---------- En-tête ---------- */
.site-head { border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 50; }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; flex-wrap: wrap; }
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); font-weight: 800; font-size: 1.1rem; }
.site-head nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.site-head nav a { padding: 8px 12px; border-radius: 8px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: 15px; }
.site-head nav a:hover, .site-head nav a[aria-current] { background: var(--stone); }
.site-head nav a[aria-current] { color: var(--slate); }
.site-head .account { border: 1px solid var(--line); margin-left: 6px; }
.site-head .account em { font-style: normal; background: var(--brass); color: #fff; font-size: 11px; border-radius: 999px; padding: 0 6px; margin-left: 2px; }

/* ---------- Boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; border-radius: 9px; border: 1px solid transparent; font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; text-decoration: none; line-height: 1.2; }
.btn.primary { background: var(--slate); color: #fff; }
.btn.primary:hover { background: var(--slate-deep); }
.btn.ghost { background: var(--paper); border-color: var(--line); color: var(--ink); }
.btn.ghost:hover { border-color: var(--slate); color: var(--slate); }
.btn.light { background: #fff; color: var(--slate-deep); }
.btn.small { padding: 7px 12px; font-size: 14px; }
.btn.block { width: 100%; }

.alert { padding: 12px 16px; border-radius: 9px; margin: 16px 0 0; border: 1px solid; }
.alert.success { background: #E3F2EA; border-color: #BFE0CD; color: #1D5A3E; }
.alert.error { background: #FBE6E2; border-color: #EFC3BA; color: #8A2A1C; }
.alert.info { background: #E3EEF8; border-color: #C3D8EC; color: #1F4B73; }

/* ---------- Héros : la plaque ---------- */
.hero { background: var(--stone); padding: 40px 0 48px; }
.plaque-hero { background: var(--slate); color: #fff; border-radius: 20px; padding: 44px 44px 34px; box-shadow: inset 0 0 0 6px var(--slate), inset 0 0 0 9px #F4F7F6; position: relative; }
.plaque-hero h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); margin: 0 0 28px; max-width: 24ch; color: #fff; }
.search { background: var(--paper); color: var(--ink); border-radius: 12px; padding: 14px; }
.modes { border: 0; margin: 0 0 12px; padding: 0; display: flex; gap: 6px; }
.modes label { cursor: pointer; }
.modes input { position: absolute; opacity: 0; }
.modes span { display: inline-block; padding: 7px 16px; border-radius: 999px; font-weight: 700; border: 1px solid var(--line); }
.modes input:checked + span { background: var(--slate); color: #fff; border-color: var(--slate); }
.modes input:focus-visible + span { outline: 3px solid var(--brass); outline-offset: 2px; }
.search-fields { display: grid; grid-template-columns: 2fr 1.2fr 1fr 1fr auto; gap: 10px; align-items: end; }
.search label > span { display: block; font-size: 13px; font-weight: 700; color: var(--muted); margin-bottom: 4px; }
.search input, .search select, .stack input, .stack select, .stack textarea, .results-tools select {
  width: 100%; padding: 11px 12px; border: 1px solid #C9D3D1; border-radius: 9px; font: inherit; background: var(--paper); color: var(--ink); }
.search input:focus, .search select:focus, .stack input:focus, .stack textarea:focus, .stack select:focus { border-color: var(--slate); outline: 2px solid rgba(20,66,74,.15); outline-offset: 0; }
.search .btn { height: 46px; }
.more { margin-top: 10px; }
.more summary { cursor: pointer; font-weight: 600; color: var(--slate); font-size: 14px; }
.search-more { display: flex; gap: 16px; align-items: end; margin-top: 10px; flex-wrap: wrap; }
.search-more label:first-child { width: 200px; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; cursor: pointer; }
.check input { width: 18px !important; height: 18px; accent-color: var(--slate); flex: none; }

/* ---------- Résultats ---------- */
.results { padding: 40px 0 56px; }
.results-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.results-head h2 { margin: 0; }
.results-tools { display: flex; gap: 8px; align-items: center; }
.results-tools form { margin: 0; }
.results-tools select { width: auto; padding: 8px 10px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 22px; }
.card { position: relative; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--paper); display: flex; flex-direction: column; }
.card-img { display: block; aspect-ratio: 4/3; background: var(--stone); position: relative; overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.card:hover .card-img img { transform: scale(1.03); }
.noimg { width: 100%; height: 100%; display: grid; place-items: center; color: #A8B6B3; font-size: 2rem; background: var(--stone); }
.noimg.big { aspect-ratio: 16/7; border-radius: 12px; font-size: 3rem; }
.mode { position: absolute; left: 12px; top: 12px; background: var(--paper); color: var(--slate-deep); font-weight: 700; font-size: 12.5px; padding: 3px 10px; border-radius: 999px; }
.fav { position: absolute; right: 10px; top: 10px; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255,255,255,.92); color: var(--slate-deep); cursor: pointer; font-size: 16px; }
.fav.on, .fav[aria-pressed=true] { color: var(--bad); }
.card-body { padding: 14px 16px 16px; position: relative; flex: 1; }
.card .price { font-weight: 800; font-size: 1.2rem; margin: 0 0 2px; font-variant-numeric: tabular-nums; }
.card h3 { font-size: 1rem; font-weight: 600; margin: 0 0 4px; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; }
.card .where { margin: 0; color: var(--muted); font-size: 14px; }
.dpe { position: absolute; right: 14px; top: 16px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 5px; color: #fff; font-weight: 800; font-size: 13px; }
.dpe-a { background: #009C6D; } .dpe-b { background: #52B153; } .dpe-c { background: #A3CC5B; color: #1b2a2e; } .dpe-d { background: #F2E31B; color: #1b2a2e; }
.dpe-e { background: #F0B40F; color: #1b2a2e; } .dpe-f { background: #EB8235; } .dpe-g { background: #D7221F; }
.map { height: 420px; border-radius: 12px; border: 1px solid var(--line); margin-bottom: 22px; z-index: 1; }
.map.small { height: 300px; }
.pager { display: flex; gap: 6px; justify-content: center; margin: 32px 0 0; flex-wrap: wrap; }
.pager a, .pager span { padding: 8px 13px; border-radius: 8px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.pager span[aria-current] { background: var(--slate); color: #fff; border-color: var(--slate); }
.empty { text-align: center; padding: 48px 20px; border: 1px dashed #C3CFCC; border-radius: 12px; }
.empty p { max-width: 560px; margin: 0 auto 18px; color: var(--muted); }

/* ---------- Bandeau propriétaires ---------- */
.owner-band { background: var(--slate-deep); color: #E4EEEE; padding: 48px 0; }
.owner-band .wrap { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.owner-band h2 { color: #fff; margin-bottom: 8px; }
.owner-band p { margin: 0; max-width: 62ch; }

/* ---------- Fiche annonce ---------- */
.listing { padding: 20px 0 56px; }
.crumbs { font-size: 14px; color: var(--muted); margin: 6px 0 14px; }
.crumbs a { color: var(--muted); }
.gallery { margin-bottom: 26px; }
.main-photo { margin: 0; border-radius: 14px; overflow: hidden; background: var(--stone); aspect-ratio: 16/8; }
.main-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumbs { list-style: none; padding: 0; margin: 10px 0 0; display: flex; gap: 8px; overflow-x: auto; }
.thumbs button { padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; width: 104px; height: 72px; cursor: pointer; background: none; flex: none; }
.thumbs button[aria-current=true] { border-color: var(--brass); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }
.listing-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 40px; align-items: start; }
.mode-line { margin: 0; color: var(--muted); font-weight: 600; font-size: 14px; }
.listing-head h1 { font-size: clamp(1.7rem, 3vw, 2.4rem); margin: 4px 0 6px; }
.listing-head .where { color: var(--muted); margin: 0 0 20px; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin: 0 0 32px; }
.facts div { background: var(--paper); padding: 12px 14px; }
.facts dt { font-size: 13px; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-weight: 700; font-size: 1.05rem; }
.listing-main section { margin-bottom: 36px; }
.prose { font-size: 1.05rem; line-height: 1.7; max-width: 70ch; }
.features { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; margin: 18px 0; }
.features i { color: var(--ok); margin-right: 4px; }
.scale-row { margin-bottom: 14px; }
.scale-row > p { margin: 0 0 6px; font-weight: 600; font-size: 14px; }
.scale { list-style: none; display: flex; gap: 3px; padding: 0; margin: 0; }
.scale li { flex: 1; max-width: 56px; text-align: center; padding: 5px 0; font-weight: 800; color: #fff; border-radius: 4px; opacity: .35; font-size: 13px; }
.scale li.on { opacity: 1; transform: scaleY(1.25); box-shadow: 0 0 0 2px var(--ink); }
.scale li:nth-child(1) { background: #009C6D; } .scale li:nth-child(2) { background: #52B153; } .scale li:nth-child(3) { background: #A3CC5B; }
.scale li:nth-child(4) { background: #F2E31B; color: #333; } .scale li:nth-child(5) { background: #F0B40F; color: #333; } .scale li:nth-child(6) { background: #EB8235; } .scale li:nth-child(7) { background: #D7221F; }
.scale.ges li:nth-child(1) { background: #F6EDFD; color: #333; } .scale.ges li:nth-child(2) { background: #E4C7FA; color: #333; } .scale.ges li:nth-child(3) { background: #D5AAF6; color: #333; }
.scale.ges li:nth-child(4) { background: #CB95F3; color: #333; } .scale.ges li:nth-child(5) { background: #BA72EF; } .scale.ges li:nth-child(6) { background: #A74DEB; } .scale.ges li:nth-child(7) { background: #8A19DF; }

.listing-side { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 16px; }
.price-box, .contact-box { border: 1px solid var(--line); border-radius: 14px; padding: 20px; background: var(--paper); }
.price-box .price { font-size: 1.75rem; font-weight: 800; margin: 0; font-variant-numeric: tabular-nums; }
.price-detail { color: var(--muted); font-size: 14px; margin: 4px 0 0; }
.badge-line { display: inline-block; margin: 10px 0 0; background: #FBF0DC; color: var(--warn); font-weight: 700; font-size: 13px; padding: 3px 10px; border-radius: 999px; }
.side-actions { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.side-actions .btn { flex: 1; font-size: 14px; padding: 9px 12px; }
.side-actions [aria-pressed=true] i { color: var(--bad); }
.agent { display: flex; gap: 12px; align-items: center; margin: 0 0 14px; }
.avatar { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--slate); color: #fff; font-weight: 700; flex: none; }
.tabs { display: flex; border-bottom: 1px solid var(--line); margin: 0 0 16px; gap: 2px; }
.tabs [role=tab] { flex: 1; text-align: center; padding: 10px 6px; border: 0; background: none; font: inherit; font-weight: 700; color: var(--muted); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -1px; text-decoration: none; font-size: 14.5px; }
.tabs [aria-selected=true] { color: var(--slate); border-bottom-color: var(--slate); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack label { font-weight: 600; font-size: 14px; display: flex; flex-direction: column; gap: 5px; }
.stack label.check { flex-direction: row; }
.stack small { font-weight: 400; color: var(--muted); }
.fine { font-size: 13px; color: var(--muted); margin: 4px 0 0; }
.similar { margin-top: 24px; padding-top: 32px; border-top: 1px solid var(--line); }

/* ---------- Pages compte / contact ---------- */
.narrow-page { max-width: 720px; padding: 40px 0 64px; }
.narrow-page h1, .account-page h1 { font-size: 2.3rem; margin: 0 0 8px; }
.lede { color: var(--muted); font-size: 1.1rem; margin: 0 0 24px; max-width: 60ch; }
.card-form { border: 1px solid var(--line); border-radius: 14px; padding: 24px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice { border: 0; padding: 0; margin: 0; display: flex; gap: 8px; flex-wrap: wrap; }
.choice legend { font-weight: 700; margin-bottom: 8px; font-size: 14px; }
.choice label { cursor: pointer; }
.choice input { position: absolute; opacity: 0; }
.choice span { display: inline-block; padding: 9px 16px; border: 1px solid var(--line); border-radius: 999px; font-weight: 600; }
.choice input:checked + span { background: var(--slate); color: #fff; border-color: var(--slate); }
.choice input:focus-visible + span { outline: 3px solid var(--brass); outline-offset: 2px; }
.auth-page { padding: 48px 0 72px; display: grid; place-items: center; }
.auth-card { width: 100%; max-width: 460px; border: 1px solid var(--line); border-radius: 16px; padding: 24px 26px; }
.account-page { padding: 36px 0 64px; }
.account-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.row-actions { display: flex; gap: 8px; }
.row-actions form { margin: 0; }
.account-page section { margin-bottom: 36px; }
.count { display: inline-block; font-family: var(--font); font-size: 14px; font-weight: 700; background: var(--slate-soft); color: var(--slate); border-radius: 999px; padding: 0 9px; vertical-align: 4px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.track { list-style: none; padding: 0; margin: 0; border: 1px solid var(--line); border-radius: 12px; }
.track li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); }
.track li:first-child { border-top: 0; }
.track li div { display: flex; flex-direction: column; }
.track li span { color: var(--muted); font-size: 14px; }
.state { font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 999px; white-space: nowrap; color: var(--ink) !important; background: #E7ECEB; }
.s-ok { background: #E3F2EA; color: var(--ok) !important; } .s-warn { background: #FBF0DC; color: var(--warn) !important; }
.s-bad { background: #FBE6E2; color: var(--bad) !important; } .s-info { background: #E3EEF8; color: var(--info) !important; }

/* ---------- Pied de page ---------- */
.site-foot { background: var(--stone); border-top: 1px solid var(--line); padding: 36px 0 28px; font-size: 14.5px; color: var(--muted); }
.site-foot .wrap { display: grid; grid-template-columns: 2fr 1.5fr 1fr; gap: 24px; }
.site-foot strong { color: var(--ink); }
.site-foot p { margin: 6px 0 0; }
.site-foot a { color: var(--muted); }
.site-foot .legal { grid-column: 1 / -1; font-size: 13px; border-top: 1px solid var(--line); padding-top: 16px; margin: 0; }

.leaflet-popup-content a { font-weight: 700; color: var(--slate); text-decoration: none; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .search-fields { grid-template-columns: 1fr 1fr; }
  .search-fields .f-city { grid-column: 1 / -1; }
  .search-fields .btn { grid-column: 1 / -1; }
  .listing-grid { grid-template-columns: 1fr; }
  .listing-side { position: static; }
  .two { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .wrap { width: calc(100% - 28px); }
  .hero { padding: 18px 0 28px; }
  .plaque-hero { padding: 28px 18px 18px; border-radius: 16px; box-shadow: inset 0 0 0 4px var(--slate), inset 0 0 0 6px #F4F7F6; }
  .plaque-hero h1 { margin-bottom: 18px; }
  .search-fields { grid-template-columns: 1fr; }
  .site-head nav a { padding: 6px 8px; font-size: 14px; }
  .main-photo { aspect-ratio: 4/3; }
  .row2 { grid-template-columns: 1fr; }
  .site-foot .wrap { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Messagerie client ---------- */
.nav-badge { font-style: normal; background: var(--brass); color: #fff; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 0 6px; margin-left: 2px; }
.chat-page { padding: 28px 0 48px; }
.chat-page h1 { font-size: 2rem; margin: 0 0 6px; }
.chat-page .lede { margin-bottom: 18px; }
.chat .btn.small { padding: 7px 12px; font-size: 14px; }
.icon-btn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 8px; border: 0; background: transparent; color: var(--ink); cursor: pointer; font-size: 16px; text-decoration: none; }
.icon-btn:hover { background: var(--stone); }
.btn-link { background: none; border: 0; padding: 0; font: inherit; color: var(--slate); font-weight: 600; cursor: pointer; }
.polls-box { list-style: none; padding: 0; margin: 0; border: 1px solid var(--line); border-radius: 12px; }
.polls-box li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; border-top: 1px solid var(--line); }
.polls-box li:first-child { border-top: 0; }
.vote-page { max-width: 640px; padding: 40px 0 64px; }
.vote-page h1 { font-size: 2rem; margin: 0 0 8px; }
.vote-card { border: 1px solid var(--line); border-radius: 14px; padding: 22px; }
.vote-opt { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; cursor: pointer; position: relative; overflow: hidden; }
.vote-opt:hover { border-color: var(--slate); }
.vote-opt input { width: 20px; height: 20px; accent-color: var(--slate); position: relative; z-index: 1; }
.vote-opt span { position: relative; z-index: 1; flex: 1; }
.vote-opt b { position: relative; z-index: 1; font-variant-numeric: tabular-nums; }
.vote-opt i { position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--slate-soft); }
.vote-opt.chosen { border-color: var(--brass); }
.site-head nav a.lang-switch { font-weight: 800; font-size: 13px; letter-spacing: .02em; color: var(--muted); }
