/* ============================================================
   Je Cherche Un Commerce — Design system 2027
   ============================================================ */

:root {
  --primary:   #0c70d2;
  --primary-d: #0a5aa8;
  --secondary: #ff6600;
  --secondary-d: #e65c00;
  --darkblue:  #174069;
  --dark:      #202020;
  --light:     #ebebeb;
  --gray:      #6b7280;
  --gray-l:    #f4f6f9;
  --border:    #e3e7ee;
  --white:     #ffffff;
  --radius:    14px;
  --radius-s:  10px;
  --shadow:    0 4px 20px rgba(23, 64, 105, .08);
  --shadow-h:  0 10px 34px rgba(23, 64, 105, .16);
  --maxw:      1180px;
  --font:      'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
/* Compense le header collant (82px) sur toute ancre interne, pour que le
   titre de la section ne soit pas masqué par le menu. */
:target { scroll-margin-top: 100px; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1 0 auto; }

img { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; color: var(--darkblue); margin: 0 0 .5em; }
h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 700; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }
.muted { color: var(--gray); }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: 40px; border: 0;
  font-weight: 700; font-size: 1rem; cursor: pointer;
  text-decoration: none; transition: transform .12s ease, box-shadow .2s ease, background .2s;
  line-height: 1;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary   { background: var(--primary);   color: #fff; }
.btn-primary:hover   { background: var(--primary-d); color: #fff; }
.btn-secondary { background: var(--secondary); color: #fff; }
.btn-secondary:hover { background: var(--secondary-d); color: #fff; }
/* Vert repris des alertes et du badge « En ligne » (#17703a) : le site n'a
   qu'un seul vert, autant le réutiliser plutôt que d'en introduire un autre. */
.btn-success   { background: #17703a; color: #fff; }
.btn-success:hover   { background: #115a2e; color: #fff; }
.btn-outline   { background: #fff; color: var(--primary); border: 2px solid var(--primary); }
.btn-outline:hover   { background: var(--primary); color: #fff; }
.btn-ghost     { background: rgba(255,255,255,.15); color:#fff; border:1px solid rgba(255,255,255,.5);}
.btn-lg { padding: 16px 34px; font-size: 1.08rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 82px; gap: 20px;
}
/* Dépôt d'annonce : la barre de progression remplace le filet gris sous le
   menu — les deux superposés feraient un double trait. */
.site-header.has-progress { border-bottom: 0; }
.depot-progress {
  height: 5px; background: var(--primary);
  box-shadow: 0 10px 12px -6px rgba(23, 64, 105, .3);
}
.depot-progress > span {
  display: block; height: 100%; background: var(--secondary);
  width: var(--pf-a, 0%);
  /* Part de l'avancement de l'étape précédente et rejoint le nouveau : le
     vendeur voit sa progression se faire, plutôt qu'un trait déjà en place. */
  animation: depot-remplir .9s cubic-bezier(.25, .8, .35, 1) both;
}
@keyframes depot-remplir {
  from { width: var(--pf-de, 0%); }
  to   { width: var(--pf-a, 0%); }
}
/* Respecte le réglage système « réduire les animations » */
@media (prefers-reduced-motion: reduce) {
  .depot-progress > span { animation: none; }
}
.site-header .logo { display: flex; align-items: center; }
.site-header .logo img { height: 40px; width: auto; display: block; }
.main-nav { display: flex; align-items: center; gap: 26px; }
.main-nav a { color: var(--dark); font-weight: 600; font-size: .96rem; }
.main-nav a:hover { color: var(--primary); text-decoration: none; }
.main-nav a.nav-login { background: #eef0f4; padding: 8px 14px; border-radius: 8px; }
.main-nav a.nav-login:hover { background: #e2e6ec; }
/* « Mon espace » : bouton bleu compact dans la barre (le .btn par défaut est trop grand) */
.main-nav a.nav-espace { padding: 8px 16px; font-size: .92rem; color: #fff; }
.main-nav a.nav-espace:hover { color: #fff; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.6rem; cursor: pointer; color: var(--darkblue); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: linear-gradient(135deg, var(--darkblue) 0%, var(--primary) 100%);
  color: #fff;
  padding: 70px 0 90px;
  /* Pas d'overflow:hidden ici : il rognerait le menu déroulant de la
     recherche. Le cercle décoratif est contenu par son propre calque. */
}
/* Calque décoratif : occupe tout le hero et rogne le cercle qu'il contient,
   sans toucher au reste (les panneaux de recherche débordent librement). */
.hero-deco { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.hero-deco::after {
  content: ''; position: absolute; right: -80px; bottom: -80px;
  width: 340px; height: 340px; border-radius: 50%;
  background: rgba(255,255,255,.06);
}
/* Contenu au-dessus du décor ; z-index positif -> passe aussi au-dessus de la
   section suivante, pour que le menu déroulant la recouvre. */
.hero .container { text-align: center; position: relative; z-index: 1; }
.hero h1 { color: #fff; max-width: 720px; margin-left: auto; margin-right: auto; margin-top: -15px; margin-bottom: calc(.5em + 15px); font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
.hero p.lead { font-size: calc(1.2rem - 2pt); opacity: .95; max-width: 620px; margin: 15px auto 30px; }
.hero .searchbar, .hero .searchbox { margin-left: auto; margin-right: auto; }
.hero .stats { display: flex; gap: 32px; margin-top: 34px; flex-wrap: wrap; justify-content: center; }
/* Largeur bornée : la phrase se répartit dans la card (comme avec l'ancien
   <br>), les 3 cards restent sur une seule ligne. */
.hero .stats > div { border: 1px solid rgba(255,255,255,.35); border-radius: 12px; padding: 18px 20px; flex: 0 1 240px; max-width: 240px; }
.hero .stats > div span { display: block; }
.hero .stats b { font-size: 1.7rem; display: block; }
.hero .stats span { opacity: .85; font-size: .9rem; }

/* ---------- Search box ---------- */
.searchbar {
  background: #fff; border-radius: var(--radius);
  box-shadow: var(--shadow-h); padding: 14px;
  display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 12px;
  max-width: 900px;
}
.searchbar .field { display: flex; flex-direction: column; text-align: left; }
.searchbar label { font-size: .72rem; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: .04em; margin: 4px 0 0 12px;}
.searchbar select, .searchbar input {
  border: 0; padding: 8px 12px; font-size: 1rem; background: transparent; color: var(--dark);
  font-family: inherit;
}
.searchbar select:focus, .searchbar input:focus { outline: none; }

/* ---------- Nouvelle barre de recherche (searchbox) ---------- */
.searchbox {
  background: #fff; border-radius: var(--radius);
  box-shadow: var(--shadow-h); padding: 12px 14px;
  max-width: 880px; text-align: left;
}
.searchbox-top { display: flex; align-items: center; gap: 10px; padding-top: 5px; }
/* Micro vocal */
.sb-mic {
  flex-shrink: 0; width: 42px; height: 42px; border-radius: 50%;
  border: 0; background: transparent; color: var(--darkblue);
  display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
  transition: background .15s, color .15s;
}
.sb-mic svg { width: 26px; height: 26px; }
.sb-mic:hover { background: #eef4fc; color: var(--primary); }
.sb-mic.listening { background: #ffe3e3; color: #e11; animation: pulse 1s infinite; }
@keyframes pulse { 0%,100%{ box-shadow:0 0 0 0 rgba(238,17,17,.4);} 50%{ box-shadow:0 0 0 8px rgba(238,17,17,0);} }
/* Champ */
.sb-inputwrap { position: relative; flex: 1; }
.sb-input {
  width: 100%; background: #f3f5fe; border: 1px solid #99abfd; border-radius: 40px;
  padding: 13px 44px 13px 18px; font-size: 1.02rem; color: var(--dark);
}
.sb-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(12,112,210,.15); }
.sb-input::-webkit-search-cancel-button { display: none; }
.sb-clear {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  width: 28px; height: 28px; border-radius: 50%; border: 0; cursor: pointer;
  background: #d9def0; color: #56607e; display: inline-flex; align-items: center; justify-content: center;
}
.sb-clear:hover { background: #c7cde6; color: var(--dark); }
.sb-clear[hidden] { display: none; }   /* n'affiche la croix que si du texte est saisi */

/* Suggestions sous le champ de recherche */
.sb-suggest {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 60;
  margin: 0; padding: 6px; list-style: none;
  background: #fff; border: 1px solid #d7defb; border-radius: 14px;
  box-shadow: 0 12px 30px rgba(23, 64, 105, .18);
  max-height: 340px; overflow-y: auto;
}
.sb-suggest[hidden] { display: none; }
.sb-suggest-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 9px; cursor: pointer;
}
.sb-suggest-item.is-actif { background: #eef4fc; }
/* Sépare l'action « autour de moi » des exemples d'annonces. Le trait reste
   dans le flux de l'élément : le fond arrondi du survol n'est pas déformé. */
.sb-suggest-item.is-sep { border-top: 1px solid #d7defb; margin-top: 5px; padding-top: 12px; }
/* Intitulé de section : annonce les exemples qui suivent. Pas d'icône, donc
   pas de colonne à réserver — le texte démarre au bord du menu. */
.sb-suggest-titre {
  cursor: default; color: #c2c2c2; font-size: .92rem;
  padding-bottom: 2px;
}
/* Ligne d'information (localisation en cours, refus…) : pas cliquable */
.sb-suggest-msg { cursor: default; color: var(--gray); font-size: .9rem; }

/* Recherche sans résultat : annonce les plus proches proposées à la place.
   Le constat reste en graisse normale, la solution proposée passe en gras. */
.fallback-note {
  color: var(--secondary); font-weight: 400; text-align: center;
  line-height: 1.45; margin: 0 auto 18px;
}
.fallback-note strong { font-weight: 700; }
/* Résultats exacts en bleu, complément proposé en gris foncé : la couleur
   distingue au premier coup d'œil ce qui répond à la recherche de ce qui a
   été ajouté autour. */
.fallback-note .fn-exact { color: var(--primary); }
.fallback-note .fn-plus  { color: #404040; }
/* Largeur fixe : l'image du pin et l'emoji étiquette n'ont pas la même
   largeur, sans ça les libellés ne s'aligneraient pas d'une ligne à l'autre. */
.sb-suggest-ic  { flex-shrink: 0; font-size: .95rem; width: 16px; display: inline-flex; align-items: center; justify-content: center; }
.sb-suggest-ic .ico-loc { height: 1.05em; }
.sb-suggest-lbl { flex: 1; color: var(--dark); font-size: .95rem; }
.sb-suggest-nb  { flex-shrink: 0; color: var(--gray); font-size: .8rem; white-space: nowrap; }
/* Bouton loupe */
.sb-search {
  flex-shrink: 0; width: 52px; height: 46px; border-radius: 10px; border: 0; cursor: pointer;
  background: var(--primary); display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.sb-search:hover { background: var(--primary-d); }
/* Ligne du bas */
.searchbox-bottom {
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  margin-top: 12px; padding: 6px 6px 2px 12px;
}
.sb-select { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.sb-select > span { font-size: .74rem; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: .04em; }
.sb-select select {
  width: auto; border: 0; background: transparent; padding: 4px 4px; font-weight: 600;
  color: var(--darkblue); cursor: pointer; font-size: .92rem;
}
.sb-select select:focus { outline: none; box-shadow: none; }
/* Réglette rayon */
.sb-radius { display: inline-flex; align-items: center; gap: 12px; flex: 1; min-width: 220px; }
.sb-radius-label { font-size: .74rem; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.sb-radius-val { font-size: .82rem; font-weight: 700; color: var(--primary); white-space: nowrap; min-width: 48px; text-align: right; }
input[type=range].js-radius {
  -webkit-appearance: none; appearance: none; flex: 1; height: 6px; border-radius: 6px; padding: 0; border: 0;
  background: linear-gradient(to right, var(--primary) 0%, var(--primary) var(--pct,0%), #d9def0 var(--pct,0%), #d9def0 100%);
  cursor: pointer;
}
input[type=range].js-radius:focus { outline: none; box-shadow: none; }
input[type=range].js-radius::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 18px; height: 18px; border-radius: 50%;
  background: var(--primary); border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.3); cursor: pointer;
}
input[type=range].js-radius::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%; background: var(--primary); border: 3px solid #fff; cursor: pointer;
}
input[type=range].js-radius::-moz-range-track { background: transparent; }
@media (max-width: 620px) {
  .searchbox-bottom { flex-direction: column; align-items: stretch; gap: 14px; padding-left: 6px; }
  .sb-select { justify-content: space-between; }
  .sb-radius { width: 100%; }
}

/* ======================================================================
   Barre de recherche à deux champs (.jsb) — hero et colonne de filtres
   ====================================================================== */
.jsb { position: relative; }

/* --- Variante hero : pilule blanche horizontale --- */
.jsb-hero {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border-radius: 16px; box-shadow: var(--shadow-h);
  padding: 12px 14px; max-width: 980px; margin: 0 auto; text-align: left;
}
.jsb-field { position: relative; flex: 1; min-width: 0; }
.jsb-input {
  width: 100%; background: #f3f5fe; border: 1px solid #99abfd; border-radius: 40px;
  padding: 13px 42px 13px 18px; font-size: 1rem; color: var(--dark);
}
/* Micro dans le champ (variante hero) : à gauche, en miroir de la croix. Le
   texte reçoit alors une marge à gauche pour ne pas passer dessous. */
.jsb-avec-mic .jsb-input { padding-left: 44px; }
.jsb-micin {
  position: absolute; top: 50%; left: 8px; transform: translateY(-50%);
  width: 32px; height: 32px; border-radius: 50%; border: 0; padding: 0; cursor: pointer; z-index: 2;
  background: transparent; color: var(--darkblue);
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s;
}
.jsb-micin:hover { background: #e6edfb; color: var(--primary); }
.jsb-micin.listening { background: #ffe3e3; color: #e11; animation: pulse 1s infinite; }
.jsb-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(12,112,210,.15); }
/* On masque la croix native (webkit) au profit de notre bouton, identique
   partout et déclenchable au clavier. */
.jsb-input::-webkit-search-cancel-button { display: none; }
.jsb-clear {
  position: absolute; top: 50%; right: 12px; transform: translateY(-50%);
  width: 24px; height: 24px; border-radius: 50%; border: 0; cursor: pointer; padding: 0; z-index: 2;
  background: #dfe3ee; color: #5b6478;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, color .15s;
}
.jsb-clear[hidden] { display: none; }
.jsb-clear:hover { background: #cfd5e6; color: #2a2f3d; }

.jsb-search {
  flex-shrink: 0; height: 46px; padding: 0 22px; border-radius: 10px; border: 0; cursor: pointer;
  background: var(--primary); color: #fff; font-weight: 800; font-size: .9rem;
  letter-spacing: .04em; text-transform: uppercase; white-space: nowrap;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: background .15s;
}
.jsb-search svg { flex-shrink: 0; }
.jsb-search:hover { background: var(--primary-d); color: #fff; }

/* --- Panneaux déroulants (communs aux deux variantes) --- */
.jsb-panel {
  position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 70;
  background: #fff; border: 1px solid #d7defb; border-radius: 14px;
  box-shadow: 0 14px 34px rgba(23,64,105,.18);
  padding: 8px; max-height: 400px; overflow-y: auto; text-align: left;
}
.jsb-panel[hidden] { display: none; }
.jsb-titre {
  font-size: .95rem; font-weight: 800; color: var(--darkblue);
  padding: 10px 10px 6px;
}
.jsb-item {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 9px 10px; border: 0; background: none; border-radius: 9px;
  font-size: .96rem; color: var(--dark); text-align: left; cursor: pointer;
}
.jsb-item:hover, .jsb-item.is-actif { background: #eef4fc; }
.jsb-ic {
  flex-shrink: 0; width: 22px; display: inline-flex; align-items: center; justify-content: center;
  color: var(--primary);
}
.jsb-ic.jsb-emoji, .jsb-ic.jsb-ic-tag { font-size: 1.05rem; }
.jsb-lbl { flex: 1; }
.jsb-nb { flex-shrink: 0; color: var(--gray); font-size: .8rem; white-space: nowrap; }
.jsb-geoloc { background: #f4f8ff; }
.jsb-geoloc .jsb-lbl { font-weight: 700; color: var(--darkblue); }
.jsb-msg { padding: 12px 10px; color: var(--gray); font-size: .9rem; }

/* --- Variante colonne de filtres : les deux champs empilés (pas de micro) --- */
.jsb-sidebar { display: flex; flex-direction: column; gap: 10px; }
.jsb-sidebar .jsb-field { flex: none; }
.jsb-sidebar .jsb-search { width: 100%; height: 46px; border-radius: 40px; }
.jsb-sidebar .jsb-panel { max-height: 320px; }

@media (max-width: 720px) {
  /* Le micro étant désormais DANS chaque champ, plus de bouton externe à
     repositionner : les deux champs et le bouton s'empilent simplement. */
  .jsb-hero { flex-wrap: wrap; }
  .jsb-hero .jsb-field { flex: 1 1 100%; }
  .jsb-hero .jsb-search { flex: 1 1 100%; width: 100%; }
}

/* ---------- Form fields (charte imposée) ---------- */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--darkblue); font-size: .95rem; }
input[type=text], input[type=email], input[type=tel], input[type=number],
input[type=password], input[type=search], select, textarea {
  width: 100%;
  background: #f3f5fe;
  border: 1px solid #99abfd;
  border-radius: var(--radius-s);
  padding: 12px 14px;
  font-size: 1rem;
  font-family: inherit;
  color: var(--dark);
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(12,112,210,.15);
}
textarea { resize: vertical; min-height: 120px; }

/* Palette formulaires frontend : inputs fond #f0f7fe, cards fond blanc, bordure #89b7fd */
main input[type=text], main input[type=email], main input[type=tel], main input[type=number],
main input[type=password], main input[type=search], main select, main textarea,
main .cat-radio-list {
  background: #f0f7fe;
  border-color: #89b7fd;
}
main form.panel, main .panel:has(form) {
  background: #fff;
  border-color: #89b7fd;
}

.form-hint { font-size: .82rem; color: var(--gray); margin-top: 4px; }
.form-row { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.form-row-3 { display: grid; gap: 16px; grid-template-columns: 1fr 1fr 1fr; }
/* Points forts : 10 cases sur 2 colonnes, empilées sur mobile où deux
   champs côte à côte seraient trop étroits pour être lisibles. */
.pf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
@media (max-width: 640px) { .pf-grid { grid-template-columns: 1fr; } }

/* ---------- Gestionnaire de photos (dropzone + miniatures) ---------- */
.photo-manager.pm-filedrag { outline: 2px dashed var(--primary); outline-offset: 6px; border-radius: 12px; }
.pm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.pm-drop {
  aspect-ratio: 4/3; border: 2px dashed #b9c3d6; border-radius: 10px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer; color: var(--gray); background: #f5f6f8; text-align: center; transition: .15s; padding: 8px;
}
.pm-drop:hover { border-color: var(--primary); color: var(--primary); background: #eef4fc; }
.pm-ico { display: flex; align-items: center; justify-content: center; }
.pm-ico svg { display: block; }
.pm-drop-txt { font-size: .86rem; font-weight: 600; line-height: calc(1.4em - 6px); }
.pm-item {
  position: relative; aspect-ratio: 4/3; border-radius: 10px; overflow: hidden;
  border: 1px solid var(--border); cursor: grab; background: var(--light);
}
.pm-item:active { cursor: grabbing; }
.pm-item img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.pm-item.pm-dragging { opacity: .4; }
.pm-item.pm-over { outline: 3px solid var(--primary); outline-offset: -3px; }
.pm-main {
  position: absolute; top: 8px; left: 8px; z-index: 2;
  background: var(--primary); color: #fff; font-size: .72rem; font-weight: 700;
  padding: 3px 9px; border-radius: 20px;
}
.pm-del {
  position: absolute; top: 6px; right: 6px; z-index: 2;
  width: 26px; height: 26px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(0, 0, 0, .6); color: #fff; font-size: 1.15rem; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.pm-del:hover { background: #e11; }
/* Recadrer en 16:9 — même pastille que la suppression, en bas à droite */
.pm-crop {
  position: absolute; bottom: 6px; right: 6px; z-index: 2;
  width: 26px; height: 26px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(0, 0, 0, .6); color: #fff;
  display: flex; align-items: center; justify-content: center;
}
.pm-crop:hover { background: var(--primary); }
/* Repère « photo déjà au format 16:9 » (bas à gauche, face au bouton recadrer) */
.pm-ratio-ok {
  position: absolute; bottom: 6px; left: 6px; z-index: 2;
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 20px;
  background: #17703a; color: #fff;
  font-size: .68rem; font-weight: 300; letter-spacing: .02em;
  pointer-events: none;   /* ne gêne pas le glisser-déposer de la miniature */
}

/* ---------- Modal de réponse (messages admin) ---------- */
.reply-modal { position: fixed; inset: 0; z-index: 1100; display: flex; align-items: center; justify-content: center; padding: 20px; }
.reply-modal[hidden] { display: none; }
.reply-backdrop { position: absolute; inset: 0; background: rgba(23, 64, 105, .55); }
.reply-box { position: relative; background: #fff; border-radius: 14px; overflow: hidden; width: 100%; max-width: 620px; box-shadow: var(--shadow-h); }
.reply-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border); font-weight: 700; color: var(--darkblue); }
.reply-head button { background: none; border: 0; font-size: 1.6rem; line-height: 1; cursor: pointer; color: var(--gray); }
.reply-body { padding: 18px; }

/* ---------- Modal de recadrage 16:9 ---------- */
.cropper-modal {
  position: fixed; inset: 0; z-index: 1200; display: flex; align-items: center; justify-content: center;
  background: rgba(23, 64, 105, .6); padding: 20px;
}
.cropper-modal[hidden] { display: none; }
.cropper-box { background: #fff; border-radius: 14px; overflow: hidden; max-width: 820px; width: 100%; box-shadow: var(--shadow-h); }
.cropper-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border); font-weight: 700; color: var(--darkblue); }
.cropper-x { background: none; border: 0; font-size: 1.7rem; line-height: 1; cursor: pointer; color: var(--gray); }
.cropper-x:hover { color: var(--dark); }
.cropper-stage { position: relative; margin: 18px auto; overflow: hidden; background: #1c1c1c; user-select: none; touch-action: none; max-width: 100%; }
.cropper-img { display: block; width: 100%; height: 100%; pointer-events: none; }
.cropper-crop {
  position: absolute; box-sizing: border-box; border: 2px solid #fff; cursor: move;
  box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .5);
}
.cropper-crop::before {
  content: ''; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.4) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.4) 1px, transparent 1px);
  background-size: 33.33% 33.33%; background-position: 0 0; pointer-events: none;
}
.cropper-handle {
  position: absolute; right: -9px; bottom: -9px; width: 20px; height: 20px;
  background: var(--primary); border: 2px solid #fff; border-radius: 50%; cursor: nwse-resize;
}
.cropper-hint { text-align: center; color: var(--gray); font-size: .85rem; margin: 0 18px 4px; }
.cropper-actions { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 18px; border-top: 1px solid var(--border); }

/* ---------- Éditeur de textes (admin) ---------- */
.wys { border: 1px solid #99abfd; border-radius: var(--radius-s); overflow: hidden; background: #fff; }
.wys-tb { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 6px 8px; background: #f3f5fe; border-bottom: 1px solid #d7defb; }
.wys-tb button { min-width: 30px; height: 30px; border: 1px solid var(--border); background: #fff; border-radius: 6px; cursor: pointer; font-size: .95rem; line-height: 1; padding: 0 7px; color: var(--dark); }
.wys-tb button:hover { background: #eef4fc; border-color: var(--primary); }
.wys-tb .wys-color { width: 24px; min-width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--border); padding: 0; }
.wys-tb .wys-size { height: 30px; border: 1px solid var(--border); border-radius: 6px; background: #fff; padding: 0 4px; font-size: .85rem; cursor: pointer; width: auto; }
.wys-sep { width: 1px; height: 22px; background: var(--border); margin: 0 4px; }
.wys-ed { min-height: 90px; padding: 12px 14px; font-size: 1rem; line-height: 1.55; outline: none; }
.wys-ed:focus { box-shadow: inset 0 0 0 2px rgba(12,112,210,.15); }
.wys-ed a { color: var(--primary); }

/* ---------- Liste de catégories en boutons radio (dépôt étape 1) ---------- */
.cat-radio-list {
  display: flex; flex-direction: column; gap: 16px;
  background: #f3f5fe; border: 1px solid #99abfd; border-radius: var(--radius-s); padding: 16px 18px;
}
.cat-radio-list .cat-radio { display: flex; gap: 11px; align-items: flex-start; cursor: pointer; margin: 0; font-weight: 400; }
.cat-radio input[type=radio] { width: auto; margin: 5px 0 0; flex-shrink: 0; accent-color: var(--primary); }
.cat-radio-body { display: block; }
.cat-radio-nom { display: block; font-weight: 700; color: var(--dark); text-transform: uppercase; font-size: .95rem; }
.cat-radio-desc { display: block; color: #8a9ac9; font-size: .84rem; line-height: 1.45; margin-top: -2px; }

/* ---------- Stepper (dépôt en plusieurs étapes) ---------- */
.stepper { display: flex; gap: 4px; max-width: 820px; margin: 0 auto 24px; }
.stepper .step-item { flex: 1; text-align: center; position: relative; padding-top: 34px; font-size: .78rem; color: var(--gray); }
.stepper .step-item .step-num {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 30px; height: 30px; border-radius: 50%; background: #fff; border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--gray); z-index: 2;
}
.stepper .step-item::before {
  content: ''; position: absolute; top: 14px; left: -50%; width: 100%; height: 2px; background: var(--border); z-index: 1;
}
.stepper .step-item:first-child::before { display: none; }
.stepper .step-item.current .step-num { border-color: var(--primary); color: var(--primary); }
.stepper .step-item.current { color: var(--primary); font-weight: 700; }
.stepper .step-item.done .step-num { background: var(--primary); border-color: var(--primary); color: #fff; }
.stepper .step-item.done::before { background: var(--primary); }
.stepper .step-item.done { color: var(--darkblue); }
@media (max-width: 640px) { .stepper .step-lbl { display: none; } .stepper .step-item { padding-top: 30px; } }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 44px; }
.section-head p { color: var(--gray); font-size: 1.05rem; }
.bg-light { background: var(--gray-l); }

/* ---------- Grille de catégories ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 18px; text-align: center; transition: .2s;
  display: flex; flex-direction: column; align-items: center; gap: 10px; color: var(--dark);
}
.cat-card:hover { box-shadow: var(--shadow-h); transform: translateY(-3px); text-decoration: none; border-color: var(--primary); }
.cat-card .cat-ico { font-size: 2.2rem; }
.cat-card b { color: var(--darkblue); font-size: 1rem; }
.cat-card span { font-size: .82rem; color: var(--gray); }

/* ---------- Grille d'annonces ---------- */
.annonces-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.annonce-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: .2s; display: flex; flex-direction: column;
}
.annonce-card:hover { box-shadow: var(--shadow-h); transform: translateY(-4px); text-decoration: none; }
.annonce-card .thumb { position: relative; aspect-ratio: 4/3; background: var(--light); overflow: hidden; }
.annonce-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
/* Calque noir sur les annonces vendues, désactivé au survol */
.annonce-card .thumb.vendue::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: rgba(0, 0, 0, .5); transition: opacity .25s ease;
}
.annonce-card:hover .thumb.vendue::after { opacity: 0; }
.annonce-card .badge {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  background: var(--secondary); color: #fff; font-size: .74rem; font-weight: 700;
  padding: 5px 11px; border-radius: 30px;
}
.annonce-card .badge.vendue { background: var(--primary); font-size: .92rem; padding: 7px 15px; }
/* Badge de distance (haut droite), affiché en recherche par rayon */
.annonce-card .badge-distance {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  background: #fff; color: #303030; font-size: .78rem; font-weight: 700;
  padding: 5px 11px; border-radius: 30px;
  box-shadow: 0 1px 5px rgba(0, 0, 0, .25);   /* détache le badge des photos claires */
}
.annonce-card .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.annonce-card .cat-tag { font-size: .74rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: .03em; }
.annonce-card h3 { font-size: 1.12rem; margin: 0; color: var(--dark); }
.annonce-card .activite { font-size: .84rem; color: var(--gray); margin-top: -2px; }
.annonce-card .loc { font-size: .9rem; color: #303030; display: flex; align-items: center; gap: 5px; }
/* Icône de localisation : hauteur en em -> suit la taille du texte du contexte
   (carte, fiche…). vertical-align sert aux contextes non-flex. */
.ico-loc { height: 1em; width: auto; display: inline-block; vertical-align: -.14em; flex-shrink: 0; }
.annonce-card .price { font-size: 1.3rem; font-weight: 800; color: var(--secondary); }

/* Prix à gauche, bouton carte à droite, sur la même ligne */
.annonce-card .card-bas {
  margin-top: auto; padding-top: 10px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; flex-wrap: wrap;
}

/* Bouton "Voir les résultats sur la Carte" (au-dessus de la liste) */
.btn-carte { padding: 9px 18px; font-size: .92rem; }
/* Leaflet a besoin d'une hauteur explicite, sinon la carte ne s'affiche pas */
#mapAll { min-height: 380px; }
.map-modal-body #mapAll,
.map-modal-body #mapOne { height: 100%; }
.map-modal-body #mapOne .jsb-msg,
.map-modal-body #mapOne .map-vide { padding: 24px; text-align: center; color: var(--gray); }
/* Les repères doivent passer au-dessus du fond de carte dans la modale */
.leaflet-container { z-index: 1; }

/* Carte posée en bas de la fiche annonce (même moteur que la modale). */
.carte-fiche {
  height: 360px; margin-top: 14px; border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; background: var(--light);
}
.carte-fiche .map-vide {
  padding: 24px; text-align: center; color: var(--gray); margin: 0;
  display: flex; align-items: center; justify-content: center; height: 100%;
}
@media (max-width: 760px) { .carte-fiche { height: 260px; } }

/* Bouton "Voir sur Google Maps" */
.btn-map {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 30px;
  background: #eef4fc; color: var(--primary); border: 1px solid #cfe0f5;
  font-size: calc(.8rem - 1pt); font-weight: 700; cursor: pointer; transition: .15s;
}
.btn-map:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-map svg { flex-shrink: 0; }

/* Variante « lieu » : le bouton remplace la ligne ville + code postal. Il ne
   prend que sa largeur de contenu, sinon la colonne flex de la carte
   l'étirerait sur toute la largeur. */
.btn-map-loc { align-self: flex-start; font-size: .86rem; font-weight: 600; }
/* Hauteur en em : le pin suit la taille du texte du bouton */
.btn-map-loc .ico-pin { height: 1.05em; width: auto; flex-shrink: 0; }

/* Fiche annonce : lieu et bouton carte sur la même ligne. flex-wrap laisse le
   bouton passer dessous quand la ligne devient trop longue (mobile). */
.loc-ligne { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.loc-ligne .btn-map { margin-left: 4px; }

/* Bouton « Voir l'annonce » : simple repère visuel, la carte entière est le
   lien. C'est donc son survol à elle qui l'anime. */
.annonce-card .btn-annonce {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 9px 20px; border-radius: 30px;
  background: var(--secondary); color: #fff;
  font-size: .88rem; font-weight: 700; white-space: nowrap;
  transition: background .15s;
}
.annonce-card:hover .btn-annonce { background: var(--secondary-d); }

/* Annonce vendue : la carte n'est plus un lien. Le bouton devient un simple
   libellé orange « VENDU ! » (la fiche renvoie 404 côté serveur). */
.annonce-card-vendue { cursor: default; }
.annonce-card .btn-vendu {
  color: var(--secondary); font-weight: 800; font-size: 1rem;
  letter-spacing: .02em; white-space: nowrap;
}

/* Modal carte */
.map-modal { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 20px; }
.map-modal[hidden] { display: none; }
.map-modal-backdrop { position: absolute; inset: 0; background: rgba(23,64,105,.55); backdrop-filter: blur(2px); }
.map-modal-box {
  position: relative; background: #fff; border-radius: var(--radius); overflow: hidden;
  width: 100%; max-width: 820px; box-shadow: var(--shadow-h); display: flex; flex-direction: column;
}
.map-modal-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px; border-bottom: 1px solid var(--border);
}
.map-modal-head span { font-weight: 700; color: var(--darkblue); font-size: 1.05rem; }
.map-modal-close { background: none; border: 0; font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--gray); }
.map-modal-close:hover { color: var(--dark); }
.map-modal-body { width: 100%; height: min(60vh, 480px); }

/* ---------- Layout liste (filtres + résultats) ---------- */
.list-layout { display: grid; grid-template-columns: 260px 1fr; gap: 30px; align-items: start; }
.filters {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px; position: sticky; top: 92px;
}
.filters h3 { font-size: 1.05rem; margin-bottom: 14px; }
.filters .form-group { margin-bottom: 14px; }

/* ---------- Page annonce (détail) ---------- */
.detail-gallery { display: grid; grid-template-columns: 2fr 1fr; gap: 10px; border-radius: var(--radius); overflow: hidden; }
.detail-gallery .main-img { aspect-ratio: 16/10; background: var(--light); }
.detail-gallery .main-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Vignettes de droite à RATIO FIXE (16/10) : leur hauteur découle de leur
   largeur, jamais de l'orientation des photos. Deux portraits ne peuvent donc
   plus étirer la colonne (c'était le bug : les lignes 1fr se calaient sur la
   hauteur des images). object-fit:cover rogne les portraits pour remplir leur
   cadre, et la colonne reste alignée sur l'image principale. */
.detail-gallery .thumbs { display: grid; gap: 10px; align-content: start; }
.detail-gallery .thumbs .t { aspect-ratio: 16/10; background: var(--light); border-radius: 8px; overflow: hidden; }
.detail-gallery .thumbs img { width: 100%; height: 100%; object-fit: cover; display: block; }
.detail-grid { display: grid; grid-template-columns: 1fr 340px; gap: 34px; margin-top: 34px; align-items: start; }
.detail-specs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 20px 0; }
.spec {
  background: var(--gray-l); border-radius: var(--radius-s); padding: 14px 16px;
}
.spec .lbl { font-size: .78rem; color: var(--gray); text-transform: uppercase; letter-spacing: .03em; }
.spec .val { font-weight: 700; color: var(--darkblue); font-size: 1.05rem; }
.detail-aside {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 24px; position: sticky; top: 92px;
}
.detail-price { font-size: 2rem; font-weight: 800; color: var(--secondary); }

/* ---------- Bandeau CTA ---------- */
.cta-band {
  background: linear-gradient(135deg, var(--secondary) 0%, #ff8c33 100%);
  color: #fff; border-radius: var(--radius); padding: 48px; text-align: center;
}
.cta-band h2 { color: #fff; }
.cta-band p { opacity: .95; font-size: 1.1rem; max-width: 560px; margin: 0 auto 24px; }

/* ---------- Étapes (comment ça marche) ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; }
.step { text-align: center; padding: 10px; }
.step .num {
  width: 56px; height: 56px; border-radius: 50%; background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1.5rem; font-weight: 800;
  margin: 0 auto 14px;
}
.step:nth-child(2) .num { background: var(--secondary); }
.step:nth-child(3) .num { background: var(--darkblue); }

/* ---------- Cartes / panneaux génériques ---------- */
.panel {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 30px;
}
.narrow { max-width: 560px; margin: 0 auto; }
.login-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 900px; margin: 0 auto; align-items: start; }
@media (max-width: 760px) { .login-grid { grid-template-columns: 1fr; } }

/* ---------- Alertes ---------- */
.alert { padding: 14px 18px; border-radius: var(--radius-s); margin-bottom: 20px; font-weight: 500; }
.alert-success { background: #e6f7ec; color: #17703a; border: 1px solid #b6e6c6; }
.alert-error   { background: #fdeaea; color: #b3261e; border: 1px solid #f5c2c0; }
.alert-info    { background: #e8f1fc; color: #0a5aa8; border: 1px solid #bcd8f5; }
.alert-warning { background: #fff2e8; color: #c74e00; border: 1px solid #ffc599; }

/* ---------- Badges statut ---------- */
.tag { display: inline-block; padding: 4px 12px; border-radius: 30px; font-size: .78rem; font-weight: 700; }
.tag-active { background: #e6f7ec; color: #17703a; }
.tag-attente { background: #fff4e5; color: #b25c00; }
.tag-vendue { background: #eee; color: #444; }
.tag-off { background: #fdeaea; color: #b3261e; }

/* ---------- Tables admin ---------- */
.table-wrap { overflow-x: auto; background:#fff; border:1px solid var(--border); border-radius: var(--radius); }
table.data { width: 100%; border-collapse: collapse; min-width: 720px; }
table.data th, table.data td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--border); font-size: .92rem; }
table.data th { background: var(--gray-l); color: var(--darkblue); font-weight: 700; }
table.data tr:hover td { background: #fafbfd; }

/* ---------- Footer ---------- */
.site-footer { background: var(--darkblue); color: #d5e2f0; padding: 54px 0 24px; margin-top: 60px; }
.site-footer a { color: #d5e2f0; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 34px; }
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; font-size: .92rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 34px; padding-top: 18px; font-size: .85rem; opacity: .8; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;}

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 40px; flex-wrap: wrap; }
.pagination a, .pagination span {
  padding: 9px 15px; border-radius: 8px; border: 1px solid var(--border);
  color: var(--dark); font-weight: 600; background: #fff;
}
.pagination a:hover { border-color: var(--primary); text-decoration: none; }
.pagination .current { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Badge « Annonce non-validée ! » (aperçu administrateur uniquement) */
.badge-non-valide {
  display: inline-block; margin-left: 10px; padding: 4px 12px; border-radius: 30px;
  background: #d32f2f; color: #fff; font-size: .74rem; font-weight: 800;
  letter-spacing: .03em; vertical-align: middle;
  animation: clignote 1s steps(1, end) infinite;
}
@keyframes clignote { 0%, 60% { opacity: 1; } 61%, 100% { opacity: .25; } }
/* Respecte le réglage système « réduire les animations » */
@media (prefers-reduced-motion: reduce) {
  .badge-non-valide { animation: none; }
}

/* Texte réservé aux lecteurs d'écran (icônes seules) */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- Utilitaires ---------- */
.mt-1{margin-top:8px}.mt-2{margin-top:16px}.mt-3{margin-top:24px}.mt-4{margin-top:40px}
.mb-1{margin-bottom:8px}.mb-2{margin-bottom:16px}.mb-3{margin-bottom:24px}.mb-4{margin-bottom:40px}
.flex{display:flex}.between{justify-content:space-between}.items-center{align-items:center}.gap{gap:16px}.wrap{flex-wrap:wrap}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .main-nav { display: none; }
  .main-nav.open {
    display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
    position: absolute; top: 82px; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    padding: 14px 20px; box-shadow: var(--shadow);
  }
  .main-nav.open a { padding: 8px 0; width: 100%; }
  .nav-toggle { display: block; }
  .searchbar { grid-template-columns: 1fr; }
  .list-layout { grid-template-columns: 1fr; }
  .filters { position: static; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-aside { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-row, .form-row-3 { grid-template-columns: 1fr; }
  .detail-gallery { grid-template-columns: 1fr; }
  .detail-gallery .thumbs { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 760px) {
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
  .detail-specs { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   Options « Boost » (étape 5 du dépôt + espace vendeur)
   ============================================================ */
.boost-wrap { margin-top: 4px; }

.boost-card {
  position: relative; background: #fff; border: 1px solid #8798b6;
  border-radius: 14px; padding: 26px 24px 24px; text-align: center;
  display: flex; flex-direction: column;
  box-shadow: 0 3px 14px rgba(23, 64, 105, .07);   /* ombre très légère */
}
/* Carte 1 (Alerte Acheteurs) : bordure orange, accordée à son badge */
.boost-card-alerte { border-color: #ff6600; }

.boost-card-titre { font-size: 1.12rem; font-weight: 700; color: var(--darkblue); margin: 0 0 8px; }
.boost-card-desc { font-size: .9rem; color: var(--gray); margin: 0 0 8px; line-height: 1.45; }

.boost-plus {
  background: none; border: 0; padding: 0; margin: 0 0 16px;
  font-size: .9rem; font-weight: 600; color: var(--darkblue);
  text-decoration: underline; cursor: pointer; font-family: inherit;
}
.boost-plus:hover { color: var(--primary); }
/* Carte 1 : lien orange, accordé à sa bordure et à son badge */
.boost-card-alerte .boost-plus { color: #ff6600; }
.boost-card-alerte .boost-plus:hover { color: #e65c00; }

/* Pastille numérotée, à cheval sur l'angle supérieur gauche de la carte */
.boost-num {
  position: absolute; top: -18px; left: -18px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--darkblue); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem; font-weight: 800; line-height: 1;
  box-shadow: 0 2px 8px rgba(23, 64, 105, .25);
}

/* Badge libre (« Indispensable ! », « Recommandé »…) */
.boost-reco {
  /* Centré sur la ligne de bordure : reste aligné quelle que soit sa taille */
  position: absolute; top: 0; left: 50%; transform: translate(-50%, -50%);
  background: var(--darkblue); color: #fff; font-size: .74rem; font-weight: 700;
  padding: 5px 14px; border-radius: 30px; white-space: nowrap;
  box-shadow: 0 2px 8px rgba(23, 64, 105, .2);
}
/* Badges mis en avant : « Indispensable ! » +2pt, « Recommandé » +1pt */
.boost-card-alerte  .boost-reco { font-size: calc(.74rem + 2pt); }
.boost-card-remonte .boost-reco { font-size: calc(.74rem + 1pt); }

/* Grille 2 x 2 : 90px entre les colonnes, 70px entre les lignes */
.boost-grid {
  --boost-row-gap: 70px;
  display: grid; grid-template-columns: repeat(2, 1fr);
  column-gap: 90px; row-gap: var(--boost-row-gap); align-items: start;
}
/* Texte intercalé entre deux lignes de cartes : il occupe toute la largeur.
   La grille espace déjà ses lignes (70px, 56px sur mobile) : les marges sont
   calculées en retranchant ce gap, pour que l'écart VISIBLE vaille exactement
   45px au-dessus et 65px en dessous, quelle que soit la taille d'écran. */
.boost-intercalaire {
  grid-column: 1 / -1;
  margin-top: calc(45px - var(--boost-row-gap));
  margin-bottom: calc(65px - var(--boost-row-gap));
  text-align: center; color: #202020; font-size: 1.02rem; line-height: 1.6;
}
.boost-intercalaire p { margin: 0; }
/* Marge haute : les pastilles numérotées dépassent au-dessus des cartes */
.boost-wrap { margin-top: 26px; }

/* Espacement entre la grille et un éventuel bloc pleine largeur */
.boost-grid + .boost-card-full,
.boost-card-full + .boost-grid { margin-top: 70px; }

/* Sous-titres « 1. Choisissez votre bandeau » / « 2. Choisissez la durée » */
.boost-sous-titre {
  text-align: left; font-size: .78rem; font-weight: 800; color: var(--darkblue);
  text-transform: uppercase; letter-spacing: .04em; margin: 14px 0 8px;
}

/* Liste déroulante des bandeaux — même allure que les lignes d'option */
.boost-select {
  width: 100%; background: #f4f5f7; border: 1px solid transparent;
  border-radius: 10px; padding: 13px 14px; font-size: .92rem;
  color: var(--dark); font-family: inherit; cursor: pointer;
}
.boost-select:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(12,112,210,.15);
}

.boost-choix { display: flex; flex-direction: column; gap: 10px; margin-top: auto; }
.boost-choix-row { flex-direction: row; justify-content: center; flex-wrap: wrap; }
.boost-choix-row .boost-opt { flex: 0 1 280px; }

/* Une option sélectionnable */
.boost-opt {
  display: flex; align-items: center; gap: 10px;
  background: #f4f5f7; border: 2px solid transparent; border-radius: 10px;
  padding: 12px 14px; cursor: pointer; margin: 0; font-weight: 400;
  text-align: left; transition: border-color .15s, background .15s;
}
.boost-opt:hover { background: #eef2f8; }
.boost-opt.is-on { background: #eaf3fd; border-color: var(--primary); }

/* Carte 1 : options teintées orange, accordées à la bordure et au badge.
   L'état sélectionné est redéclaré ici : à spécificité égale, la dernière
   règle l'emporterait et l'option cochée perdrait son surlignage. */
.boost-card-alerte .boost-opt { background: #fdf3ef; }
.boost-card-alerte .boost-opt:hover { background: #fef0ec; }
.boost-card-alerte .boost-opt.is-on { background: #eaf3fd; }
.boost-opt input[type=radio] { position: absolute; opacity: 0; width: 0; height: 0; }

.boost-opt-box {
  flex-shrink: 0; width: 20px; height: 20px; border-radius: 5px;
  background: #fff; border: 1px solid #c3ccd9; position: relative;
}
.boost-opt.is-on .boost-opt-box { background: var(--primary); border-color: var(--primary); }
.boost-opt.is-on .boost-opt-box::after {
  content: ''; position: absolute; left: 6px; top: 2px; width: 5px; height: 10px;
  border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.boost-opt-lbl { flex: 1; font-size: .92rem; color: var(--dark); line-height: 1.3; }
.boost-opt-prix { font-weight: 700; color: var(--dark); white-space: nowrap; font-size: .92rem; }

/* Barre de total — collée en bas de l'écran pendant le défilement, puis
   reprise dans le flux quand on atteint sa place réelle (voir main.js). */
.boost-bar-slot { margin-top: 40px; }
.boost-bar-inner {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 14px;
}
.boost-bar-left { display: flex; align-items: center; gap: 14px; }
.boost-total { font-size: 1.05rem; font-weight: 700; color: var(--secondary); }
/* Case « Utiliser mes récompenses » dans la barre de total */
.boost-recompenses {
  display: inline-flex; align-items: center; gap: 8px; margin: 0;
  font-weight: 600; color: var(--dark); font-size: .92rem; cursor: pointer;
}
.boost-recompenses input { width: auto; }
.boost-recompenses-note { color: var(--gray); font-weight: 400; font-size: .82rem; }
/* Les deux boutons de la barre ont exactement la même taille */
.boost-detail-btn, .boost-submit-btn { padding: 10px 18px; font-size: 1rem; }

.boost-bar.is-flottante {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
  background: #fff; border-top: 1px solid var(--border);
  box-shadow: 0 -4px 18px rgba(23, 64, 105, .13);
  padding: 12px 20px;
}
/* Aligne le contenu de la barre flottante sur la largeur de la page */
.boost-bar.is-flottante .boost-bar-inner { max-width: 1100px; margin: 0 auto; }

/* ---- Responsive : les 4 cartes s'empilent, la barre se centre ---- */
@media (max-width: 900px) {
  .boost-grid { --boost-row-gap: 56px; grid-template-columns: 1fr; column-gap: 0; }
  /* La pastille numérotée revient dans la carte : hors écran à gauche sinon */
  .boost-num { left: -10px; top: -16px; width: 36px; height: 36px; font-size: 1.05rem; }

  /* Montant + « Voir le détail » centrés, puis le bouton de soumission
     sur sa propre ligne, centré lui aussi. */
  .boost-bar-inner { flex-direction: column; align-items: stretch; gap: 14px; }
  .boost-bar-left { justify-content: center; }
  .boost-bar-right { display: flex; justify-content: center; }
  .boost-bar-right .btn { width: 100%; max-width: 340px; }
  .boost-bar.is-flottante { padding: 10px 16px; }
}

/* Modales boost */
.boost-modal { position: fixed; inset: 0; z-index: 120; display: flex; align-items: center; justify-content: center; padding: 20px; }
.boost-modal[hidden] { display: none; }
.boost-backdrop { position: absolute; inset: 0; background: rgba(23,64,105,.55); }
.boost-box {
  position: relative; background: #fff; border-radius: 14px; width: 100%; max-width: 520px;
  max-height: 85vh; overflow: auto; box-shadow: 0 20px 50px rgba(0,0,0,.3);
}
.boost-box-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--border); font-weight: 700; color: var(--darkblue);
}
.boost-box-head button { background: none; border: 0; font-size: 1.6rem; line-height: 1; cursor: pointer; color: var(--gray); }
.boost-box-body { padding: 20px; }
.boost-box-body p { margin: 0; line-height: 1.55; color: var(--dark); }

.boost-panier-liste { list-style: none; margin: 0 0 14px; padding: 0; }
.boost-panier-liste li {
  display: flex; justify-content: space-between; gap: 14px;
  padding: 10px 0; border-bottom: 1px solid var(--border); font-size: .92rem;
}
.boost-panier-total {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 12px; font-size: 1.05rem;
}
.boost-panier-total strong { color: var(--secondary); font-size: 1.2rem; }

/* Bandeau diagonal sur les photos (options « bandeau ») */
.photo-bandeau { position: absolute; top: 0; left: 0; width: 110px; height: 110px; overflow: hidden; pointer-events: none; z-index: 3; }
.photo-bandeau span {
  /* Ruban volontairement plus long que la diagonale du cadre (110px) : ses
     deux extrémités doivent sortir du cadre pour être coupées net par
     overflow:hidden. À 160px, le bout bas-gauche s'arrêtait ~1px avant le
     bord et laissait un décroché visible. Le centre reste à x=48
     (-52 + 200/2), donc le texte ne bouge pas. */
  position: absolute; top: 22px; left: -52px; width: 200px;
  transform: rotate(-45deg); text-align: center;
  color: #fff; font-size: .66rem; font-weight: 800; letter-spacing: .04em;
  padding: 5px 0; box-shadow: 0 2px 6px rgba(0,0,0,.3);
}
/* Bandeau « VENDU » : remplace l'ancienne pastille, au-dessus du voile
   sombre des annonces vendues (d'où un z-index supérieur au ::after). */
.photo-bandeau-vendu span {
  background-color: var(--secondary); font-size: calc(.72rem + 1pt); padding: 6px 0;
}

/* Carte « À la une » (option Boost) : plus de badge, la carte entière est
   distinguée — bordure dorée, fond crème, ombre portée. */
.annonce-card-une {
  border: 2px solid var(--secondary);
  background: #fef7f2;
  box-shadow: 0 6px 20px rgba(0,0,0,.12);
}
.annonce-card-une:hover { box-shadow: 0 12px 30px rgba(0,0,0,.18); }
/* Le bouton « Voir l'annonce » reste orange (style par défaut) ; on ajoute
   juste l'espace pour la médaille « à la une ». */
.annonce-card-une .btn-annonce { gap: 6px; }
.annonce-card-une .btn-annonce svg { flex-shrink: 0; }
/* La galerie de la fiche doit rogner le bandeau diagonal */
.detail-gallery .main-img { position: relative; overflow: hidden; }

/* ============================================================
   Espace vendeur — cartes profil / porte-monnaie
   ============================================================ */
/* Bouton « Se déconnecter » : sur mobile, icône seule pour rester sur la
   ligne du titre « Mon espace vendeur ». */
.btn-deconnexion-ic { margin-right: 5px; }
@media (max-width: 560px) {
  .btn-deconnexion .btn-deconnexion-txt { display: none; }
  .btn-deconnexion .btn-deconnexion-ic { margin-right: 0; }
  .btn-deconnexion { padding-left: 14px; padding-right: 14px; }
}

.compte-cartes {
  display: grid; grid-template-columns: 1.5fr 1fr; gap: 24px; align-items: stretch;
}
@media (max-width: 760px) { .compte-cartes { grid-template-columns: 1fr; } }

/* Carte profil */
.carte-profil { display: flex; align-items: center; gap: 18px; }
.avatar-init {
  flex-shrink: 0; width: 74px; height: 74px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #33c3ff);
  color: #fff; font-size: 1.5rem; font-weight: 800; letter-spacing: .02em;
  display: flex; align-items: center; justify-content: center;
}
.avatar-init svg { display: block; }
.carte-profil-info { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.carte-profil-nom { font-size: 1.15rem; color: var(--dark); text-transform: uppercase; }
.carte-profil-info .muted { overflow: hidden; text-overflow: ellipsis; }
.carte-profil-btn { flex-shrink: 0; padding: 8px 16px; }

/* Carte porte-monnaie */
.carte-wallet {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: flex-end; text-align: right;
}
/* Décor géométrique bleu à gauche, façon "portefeuille" */
.carte-wallet-deco {
  position: absolute; top: 0; left: 0; bottom: 0; width: 90px;
  background:
    linear-gradient(135deg, var(--darkblue) 0%, var(--darkblue) 45%, transparent 45%),
    linear-gradient(225deg, var(--primary) 0%, var(--primary) 40%, transparent 40%);
  background-color: #cfe0f5;
}
/* Trophée doré, dans la zone gauche de la carte (après le décor bleu) */
.carte-wallet-trophy {
  position: absolute; left: 100px; top: 50%; transform: translateY(-50%);
  color: #f5c518; z-index: 1;
}
.carte-wallet-trophy svg { display: block; filter: drop-shadow(0 2px 3px rgba(0,0,0,.2)); }
.carte-wallet-info { display: flex; flex-direction: column; gap: 2px; position: relative; z-index: 1; }
.carte-wallet-titre { color: var(--gray); font-weight: 600; }
.carte-wallet-solde { font-size: 1.9rem; font-weight: 800; color: var(--dark); line-height: 1.1; }

/* Modale profil (réutilise la trame des autres modales) */
.cmpt-modal { position: fixed; inset: 0; z-index: 120; display: flex; align-items: center; justify-content: center; padding: 20px; }
.cmpt-modal[hidden] { display: none; }
.cmpt-backdrop { position: absolute; inset: 0; background: rgba(23,64,105,.55); }
.cmpt-box {
  position: relative; background: #fff; border-radius: 14px; width: 100%; max-width: 480px;
  box-shadow: 0 20px 50px rgba(0,0,0,.3); overflow: hidden;
}
.cmpt-box-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 20px; border-bottom: 1px solid var(--border); font-weight: 700; color: var(--darkblue);
}
.cmpt-box-head button { background: none; border: 0; font-size: 1.6rem; line-height: 1; cursor: pointer; color: var(--gray); }
.cmpt-box-body { padding: 20px; }

/* Bouton « Annonces archivées » (jaune) */
.btn-archives { background: #f5b301; color: #202020; padding: 8px 15px; font-size: .85rem; }
.btn-archives:hover { background: #e0a400; color: #202020; }

/* Choix radio de la modale d'archivage */
.archive-choix { display: flex; flex-direction: column; gap: 10px; }
.archive-opt {
  display: flex; align-items: flex-start; gap: 11px; margin: 0; cursor: pointer;
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px;
  font-weight: 400; transition: border-color .15s, background .15s;
}
.archive-opt:hover { background: #f7f9fc; }
.archive-opt input { width: auto; margin-top: 3px; flex-shrink: 0; accent-color: var(--primary); }
