/* =====================================================
   HOME m2-drome.fr, refonte 2026
   Classes préfixées .home-* (ne touche pas aux autres pages)
   ===================================================== */

:root {
  --home-radius:   16px;
  --home-radius-sm:12px;
  --home-peach:    #FDEBDD;
  --home-peach-2:  #FBDFC9;
  --home-shadow:   0 18px 50px -18px rgba(28,28,30,0.28);
  --home-shadow-sm:0 8px 24px -12px rgba(28,28,30,0.22);
}

/* ── HERO ───────────────────────────────────────────── */
.home-hero {
  position: relative;
  background: #cdd6db url('/img/home-hero.jpg') center 35% / cover no-repeat;
  padding: 96px 0 150px;
}
.home-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(105deg, rgba(255,255,255,0.96) 0%, rgba(255,255,255,0.86) 30%, rgba(255,255,255,0.45) 52%, rgba(255,255,255,0) 70%),
    linear-gradient(to top, rgba(255,255,255,0.55), rgba(255,255,255,0) 35%);
}
.home-hero .container { position: relative; z-index: 2; }
.home-hero-texte { max-width: 560px; }
.home-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-dark);
  margin-bottom: 22px;
}
.home-eyebrow::before {
  content: '';
  width: 26px;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}
.home-hero h1 {
  font-size: clamp(2.3rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.05;
  color: var(--primary);
  margin-bottom: 20px;
}
.home-hero h1 .accent { color: var(--accent); }
.home-hero-texte p {
  font-size: 1.06rem;
  line-height: 1.6;
  color: #3f4651;
  max-width: 460px;
  margin-bottom: 30px;
}
.home-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.home-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s, color 0.15s;
}
.home-btn-primary { background: var(--primary); color: #fff; box-shadow: var(--home-shadow-sm); }
.home-btn-primary:hover { background: #000; transform: translateY(-2px); }
.home-btn-ghost { background: rgba(255,255,255,0.7); color: var(--primary); border: 1.5px solid rgba(28,28,30,0.18); }
.home-btn-ghost:hover { background: #fff; border-color: var(--primary); transform: translateY(-2px); }

/* ── CARTE STATS FLOTTANTE ──────────────────────────── */
.home-stats-wrap { position: relative; z-index: 5; margin-top: -88px; }
.home-stats-card {
  background: #fff;
  border-radius: var(--home-radius);
  box-shadow: var(--home-shadow);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  overflow: hidden;
}
.home-stat {
  padding: 28px 26px;
  border-right: 1px solid var(--border);
}
.home-stat:last-child { border-right: none; }
.home-stat-head {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-light);
  margin-bottom: 14px;
}
.home-stat-head svg { width: 18px; height: 18px; color: var(--accent); flex-shrink: 0; }
.home-stat-val {
  font-size: 1.95rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--primary);
  line-height: 1;
}
.home-stat-val small { font-size: 0.9rem; font-weight: 600; color: var(--text-light); }
.home-stat-foot { margin-top: 8px; font-size: 0.8rem; font-weight: 600; }
.home-stat-foot.hausse { color: #16A34A; }
.home-stat-foot.baisse { color: #DC2626; }
.home-stat-foot.neutre { color: var(--text-light); }

/* ── SECTIONS GÉNÉRIQUES ────────────────────────────── */
.home-section { padding: 72px 0; }
.home-section.alt { background: var(--bg-alt); }
.home-head-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 34px;
}
.home-h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--primary);
}
.home-sub { font-size: 0.95rem; color: var(--text-light); margin-top: 8px; max-width: 560px; }
.home-link-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 20px;
  border: 1.5px solid var(--accent);
  border-radius: 30px;
  font-size: 0.83rem;
  font-weight: 700;
  color: var(--accent);
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.home-link-pill:hover { background: var(--accent); color: #fff; }

/* ── VILLES QUI BOUGENT ─────────────────────────────── */
.home-villes-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}
.home-ville-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--home-radius);
  padding: 10px 10px 18px;
  transition: transform 0.18s, box-shadow 0.18s;
  display: block;
}
.home-ville-card:hover { transform: translateY(-4px); box-shadow: var(--home-shadow-sm); }
.home-ville-img {
  height: 120px;
  border-radius: var(--home-radius-sm);
  background-size: cover;
  background-position: center;
  margin-bottom: 14px;
}
.home-ville-card h3 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--primary);
  padding: 0 6px;
  margin-bottom: 6px;
}
.home-ville-prix {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 0 6px;
}
.home-ville-prix .v {
  font-size: 1.32rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--primary);
}
.home-ville-prix .v small { font-size: 0.7rem; font-weight: 600; color: var(--text-light); }
.home-evol-badge {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
}
.home-evol-badge.hausse { color: #15803D; background: #DCFCE7; }
.home-evol-badge.baisse { color: #B91C1C; background: #FEE2E2; }
.home-evol-badge.neutre { color: #6B7280; background: #F1F3F5; }
.home-ville-type { font-size: 0.76rem; color: var(--text-light); padding: 6px 6px 0; }

/* ── CARTE INTERACTIVE ──────────────────────────────── */
.home-map-shell {
  border-radius: var(--home-radius);
  overflow: hidden;
  box-shadow: var(--home-shadow-sm);
  border: 1px solid var(--border);
}
#carte-drome-principale {
  height: 520px;
  border: none;
  border-radius: 0;
  box-shadow: none;
}
.home-map-legende {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 16px;
  font-size: 0.78rem;
  color: var(--text-light);
}
.home-map-gradient {
  width: 130px; height: 10px; border-radius: 5px;
  background: linear-gradient(to right, #22C55E, #EAB308, #DC2626);
}

/* ── 4 MARCHÉS ──────────────────────────────────────── */
.home-zones-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
@media (max-width: 1080px) { .home-zones-grid { grid-template-columns: repeat(3, 1fr); } }
.home-zone-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--home-radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.18s, box-shadow 0.18s;
}
.home-zone-card:hover { transform: translateY(-4px); box-shadow: var(--home-shadow-sm); }
.home-zone-img { height: 150px; background-size: cover; background-position: center; }
.home-zone-body {
  padding: 18px 20px 20px;
  border-left: 4px solid var(--accent);
  flex: 1;
  display: flex;
  flex-direction: column;
}
.home-zone-body h3 { font-size: 1rem; font-weight: 700; color: var(--primary); margin-bottom: 6px; }
.home-zone-body p { font-size: 0.82rem; color: var(--text-light); line-height: 1.55; flex: 1; }
.home-zone-arrow {
  align-self: flex-end;
  margin-top: 14px;
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.home-zone-card:hover .home-zone-arrow { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ── BANDE DONNÉES (dark) ───────────────────────────── */
.home-data-band { background: var(--bg-dark); color: #fff; padding: 64px 0; }
.home-data-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 48px;
  align-items: center;
}
.home-data-band h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 16px;
}
.home-data-band > .container > .home-data-grid p {
  color: rgba(255,255,255,0.62);
  font-size: 0.92rem;
  line-height: 1.7;
}
.home-data-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.home-data-stat svg { width: 30px; height: 30px; color: var(--accent); margin-bottom: 14px; }
.home-data-stat .n {
  font-size: 1.9rem; font-weight: 800; letter-spacing: -0.03em; color: var(--accent); line-height: 1;
}
.home-data-stat .t { font-size: 0.92rem; font-weight: 700; color: #fff; margin: 6px 0 5px; }
.home-data-stat .s { font-size: 0.8rem; color: rgba(255,255,255,0.5); line-height: 1.5; }

/* ── ACCÈS ESSENTIEL ────────────────────────────────── */
.home-access-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.home-access-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--home-radius);
  padding: 28px 26px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
}
.home-access-card:hover { transform: translateY(-4px); box-shadow: var(--home-shadow-sm); border-color: rgba(249,115,22,0.5); }
.home-access-ico {
  width: 46px; height: 46px;
  border-radius: 12px;
  background: #FFF1E6;
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 6px;
}
.home-access-ico svg { width: 22px; height: 22px; }
.home-access-card h3 { font-size: 1.02rem; font-weight: 700; color: var(--primary); }
.home-access-card p { font-size: 0.86rem; color: var(--text-light); line-height: 1.6; flex: 1; }
.home-access-card .go { font-size: 0.85rem; font-weight: 700; color: var(--accent); display: inline-flex; align-items: center; gap: 6px; }

/* ── CTA PÊCHE ──────────────────────────────────────── */
.home-cta-band { padding: 0 0 72px; }
.home-cta {
  position: relative;
  overflow: hidden;
  background: linear-gradient(120deg, var(--home-peach) 0%, var(--home-peach-2) 100%);
  border-radius: 22px;
  padding: 48px 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.home-cta-text h2 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); font-weight: 800; letter-spacing: -0.03em; color: var(--primary); line-height: 1.15; margin-bottom: 10px; }
.home-cta-text p { font-size: 0.95rem; color: #6b4a33; max-width: 460px; }
.home-cta .home-btn-primary { background: var(--accent); }
.home-cta .home-btn-primary:hover { background: var(--accent-dark); }
.home-cta-deco {
  position: absolute;
  right: -10px; bottom: -20px;
  width: 230px;
  color: rgba(234,106,10,0.18);
  pointer-events: none;
}

/* ── BANDE SOURCES ──────────────────────────────────── */
.home-sources { padding: 0 0 64px; }
.home-sources-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px 34px;
  padding-top: 36px;
  border-top: 1px solid var(--border);
}
.home-sources-label { font-size: 0.78rem; color: var(--text-light); font-weight: 600; }
.home-sources-inner b {
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #9aa3ad;
}

/* ── RESPONSIVE ─────────────────────────────────────── */
@media (max-width: 1000px) {
  .home-villes-grid { grid-template-columns: repeat(3, 1fr); }
  .home-zones-grid  { grid-template-columns: repeat(2, 1fr); }
  .home-data-grid   { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 860px) {
  .home-stats-card { grid-template-columns: 1fr 1fr; }
  .home-stat:nth-child(2) { border-right: none; }
  .home-stat:nth-child(1), .home-stat:nth-child(2) { border-bottom: 1px solid var(--border); }
  .home-access-grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .home-hero { padding: 64px 0 130px; }
  .home-hero::before { background: linear-gradient(105deg, rgba(255,255,255,0.95) 0%, rgba(255,255,255,0.82) 55%, rgba(255,255,255,0.4) 100%); }
  .home-villes-grid { grid-template-columns: repeat(2, 1fr); }
  .home-zones-grid  { grid-template-columns: 1fr; }
  .home-data-stats  { grid-template-columns: 1fr; gap: 22px; }
  .home-section     { padding: 52px 0; }
  .home-cta         { padding: 36px 28px; }
}
@media (max-width: 460px) {
  .home-stats-card { grid-template-columns: 1fr; }
  .home-stat { border-right: none; border-bottom: 1px solid var(--border); }
  .home-stat:last-child { border-bottom: none; }
  .home-villes-grid { grid-template-columns: 1fr; }
}
