/* =====================================================================
   ITÉO — Styles
   Palette « argile & sauge » : crème, vert sauge profond, argile, ocre.
   ===================================================================== */
:root {
  --bg: #F6F1EA; --bg-2: #EEE6D9; --card: #FFFFFF;
  --ink: #1B1E1C; --ink-2: #3A403C; --muted: #6A716C; --line: #E3DACB; --line-2: #D2C7B4;
  --primary: #2F5D50; --primary-2: #234A3F; --primary-soft: #E2EEE8; --primary-ink: #173B31;
  --accent: #E07A3F; --accent-2: #C5642B; --accent-soft: #FBE8DC;
  --ochre: #F2C14E; --ochre-2: #D9A733; --ochre-soft: #FCF1D2;
  --bleu: #3B6FD8; --jaune: #D9A400; --violet: #7E4BC4; --rose: #E2577F;
  --ok: #2E8B57; --warn: #C97A1B; --danger: #C43D3D;
  --radius: 20px; --radius-sm: 12px; --radius-xs: 8px;
  --shadow: 0 10px 30px rgba(27,30,28,.08); --shadow-lg: 0 30px 70px rgba(27,30,28,.16);
  --font-display: 'Instrument Serif', Georgia, 'Times New Roman', serif;
  --font-body: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --header-h: 72px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 400; letter-spacing: -.01em; line-height: 1.08; margin: 0 0 .5em; }
h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: 1.45rem; }
p { margin: 0 0 1em; }
.container { width: min(1160px, 100% - 2.5rem); margin-inline: auto; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent-2); margin-bottom: .9rem; }
.lead { font-size: 1.15rem; color: var(--ink-2); max-width: 54ch; }
.section-head { max-width: 62ch; margin-bottom: 2.6rem; }
.section-head p:last-child { color: var(--muted); font-size: 1.05rem; }
section { scroll-margin-top: calc(var(--header-h) + 12px); }

/* ---------- Boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55rem; padding: .85rem 1.45rem; border-radius: 999px; border: 1.5px solid transparent; font-weight: 700; font-size: .98rem; line-height: 1; transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s; white-space: nowrap; }
.btn svg { width: 18px; height: 18px; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 8px 20px rgba(47,93,80,.28); }
.btn-primary:hover { background: var(--primary-2); box-shadow: 0 10px 26px rgba(47,93,80,.36); }
.btn-accent { background: var(--accent); color: #fff; box-shadow: 0 8px 20px rgba(224,122,63,.32); }
.btn-accent:hover { background: var(--accent-2); }
.btn-ghost { background: transparent; border-color: var(--line-2); color: var(--ink-2); }
.btn-ghost:hover { background: #fff; border-color: var(--ink-2); }
.btn-light { background: #fff; color: var(--primary-ink); }
.btn-light:hover { background: var(--ochre-soft); }
.btn-lg { padding: 1.05rem 1.8rem; font-size: 1.05rem; }
.btn-sm { padding: .65rem 1.1rem; font-size: .9rem; }
.btn-xs { padding: .45rem .8rem; font-size: .8rem; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(246,241,234,.86); backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px); border-bottom: 1px solid rgba(227,218,203,.7); }
.nav { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.logo { display: inline-flex; align-items: center; gap: .65rem; font-weight: 800; letter-spacing: .02em; }
.logo-mark { width: 38px; height: 38px; flex: 0 0 auto; }
.logo-text { display: flex; flex-direction: column; line-height: 1; font-size: 1.25rem; }
.logo-text small { font-size: .62rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin-top: .25rem; }
.nav-links { display: flex; gap: 1.8rem; font-weight: 600; font-size: .95rem; color: var(--ink-2); }
.nav-links a:hover { color: var(--primary); }
@media (max-width: 820px) { .nav-links { display: none; } }

/* ---------- Hero ---------- */
.hero { padding: clamp(3rem, 7vw, 6rem) 0 clamp(3rem, 6vw, 5rem); position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: auto -10% -40% auto; width: 60vw; height: 60vw; max-width: 760px; max-height: 760px; background: radial-gradient(closest-side, rgba(242,193,78,.28), transparent 70%); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center; position: relative; }
.hero h1 em { font-style: italic; color: var(--primary); }
.hero-cta { display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; margin: 1.8rem 0 2.2rem; }
.hero-note { font-size: .9rem; color: var(--muted); font-weight: 600; }
.trust { list-style: none; padding: 0; margin: 0; display: flex; gap: 2.2rem; flex-wrap: wrap; }
.trust li { display: flex; flex-direction: column; line-height: 1.2; }
.trust strong { font-family: var(--font-display); font-size: 1.7rem; color: var(--primary-ink); }
.trust span { font-size: .85rem; color: var(--muted); font-weight: 600; }
.hero-visual { position: relative; }
.hero-card { background: var(--card); border-radius: 28px; padding: 1.4rem; box-shadow: var(--shadow-lg); border: 1px solid #fff; position: relative; }
.hero-house { background: linear-gradient(180deg, #EAF2FF 0%, #F6F1EA 100%); border-radius: 18px; padding: .6rem; }
.hero-ticker { display: flex; flex-direction: column; padding: 1rem 1rem .4rem; }
.hero-ticker-label { font-size: .8rem; color: var(--muted); font-weight: 600; }
.hero-ticker strong { font-family: var(--font-display); font-size: 2.3rem; color: var(--primary-ink); line-height: 1.1; margin-top: .15rem; }
.hero-ticker-sub { font-size: .85rem; color: var(--ink-2); }
.hero-badge { position: absolute; background: #fff; border-radius: 999px; padding: .5rem .9rem; font-size: .8rem; font-weight: 800; box-shadow: var(--shadow); border: 1px solid var(--line); animation: float 6s ease-in-out infinite; }
.hero-badge-a { top: -14px; left: -18px; color: var(--primary); }
.hero-badge-b { top: 30%; right: -22px; color: var(--ochre-2); animation-delay: -2s; }
.hero-badge-c { bottom: -14px; left: 28px; color: var(--accent-2); animation-delay: -4s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } .hero-visual { max-width: 460px; margin: 1rem auto 0; } .hero-badge-a { left: 6px; } .hero-badge-c { left: 0; } .hero-badge-b { right: 0; } }

/* ---------- Simulateur ---------- */
.sim { padding: clamp(3rem, 6vw, 5rem) 0; background: linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%); }
.sim-head { text-align: center; max-width: 60ch; margin: 0 auto 2.4rem; }
.sim-head p:last-child { color: var(--muted); }
.wizard { display: grid; grid-template-columns: 300px 1fr; gap: 1.6rem; align-items: start; }
.wizard-side { position: sticky; top: calc(var(--header-h) + 16px); display: flex; flex-direction: column; gap: 1.2rem; }
.wizard-main { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid #fff; padding: clamp(1.3rem, 3vw, 2.4rem); min-height: 520px; }
.stepper { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .35rem; background: var(--card); border-radius: var(--radius); padding: .9rem; box-shadow: var(--shadow); }
.stepper li { display: flex; align-items: center; gap: .8rem; padding: .6rem .7rem; border-radius: var(--radius-sm); color: var(--muted); font-weight: 600; font-size: .95rem; transition: background .2s, color .2s; }
.stepper-n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-2); font-size: .85rem; font-weight: 800; flex: 0 0 auto; transition: background .2s, color .2s; }
.stepper li.is-active { background: var(--primary-soft); color: var(--primary-ink); }
.stepper li.is-active .stepper-n { background: var(--primary); color: #fff; }
.stepper li.is-done { color: var(--ink-2); }
.stepper li.is-done .stepper-n { background: var(--ok); color: #fff; }
.house-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1rem; }
.house-preview { background: linear-gradient(180deg, #EAF2FF 0%, #F6F1EA 100%); border-radius: 14px; padding: .4rem; margin-bottom: .8rem; }
.live { margin: 0; display: grid; gap: .5rem; }
.live div { display: flex; justify-content: space-between; align-items: baseline; gap: .6rem; border-top: 1px dashed var(--line); padding-top: .5rem; }
.live dt { font-size: .8rem; color: var(--muted); font-weight: 600; }
.live dd { margin: 0; font-weight: 800; font-size: .95rem; text-align: right; }
@media (max-width: 900px) {
  .wizard { grid-template-columns: 1fr; }
  .wizard-side { position: static; }
  .stepper { flex-direction: row; overflow-x: auto; }
  .stepper li { flex: 1 0 auto; }
  .stepper-t { display: none; }
  .stepper li.is-active .stepper-t { display: inline; }
  .house-card { display: grid; grid-template-columns: 150px 1fr; gap: 1rem; align-items: center; }
  .house-preview { margin: 0; }
}

/* ---------- Étapes et champs ---------- */
.step-title { margin-bottom: 1.6rem; font-size: 1.9rem; }
.field { margin-bottom: 1.6rem; position: relative; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
@media (max-width: 640px) { .field-row { grid-template-columns: 1fr; } }
.field-label { display: block; font-weight: 700; font-size: .95rem; margin-bottom: .55rem; color: var(--ink); }
.field-label small { color: var(--muted); font-weight: 500; }
.hint { font-size: .82rem; color: var(--muted); margin: .5rem 0 0; }
.error { font-size: .82rem; color: var(--danger); font-weight: 600; margin: .45rem 0 0; }
.field.has-error input[type="text"], .field.has-error input[type="number"], .field.has-error .input-unit { border-color: var(--danger); }
input[type="text"], input[type="number"], input[type="email"], input[type="tel"], select, textarea { width: 100%; padding: .8rem .95rem; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); background: #fff; outline: none; transition: border-color .15s, box-shadow .15s; font-size: 1rem; }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(47,93,80,.12); }
input[type="number"] { -moz-appearance: textfield; }
input[type="number"]::-webkit-inner-spin-button, input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; }
.input-unit { display: flex; align-items: center; border: 1.5px solid var(--line-2); border-radius: var(--radius-sm); background: #fff; overflow: hidden; transition: border-color .15s, box-shadow .15s; }
.input-unit:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(47,93,80,.12); }
.input-unit input { border: none; box-shadow: none !important; flex: 1; min-width: 0; }
.input-unit span { padding: 0 .95rem; color: var(--muted); font-weight: 700; font-size: .9rem; white-space: nowrap; border-left: 1px solid var(--line); align-self: stretch; display: flex; align-items: center; background: #FBF9F5; }
.input-with-action .btn { margin: 0 .4rem; }
.subfield { margin-top: .9rem; padding: 1rem; background: #FBF9F5; border-radius: var(--radius-sm); border: 1px dashed var(--line-2); }

/* cartes de choix */
.choice-grid { display: grid; gap: .8rem; }
.choice-grid.cols-2 { grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .choice-grid.cols-2 { grid-template-columns: 1fr; } }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; pointer-events: none; }
.choice-body { display: flex; flex-direction: column; gap: .2rem; padding: 1rem 1.05rem; border: 1.5px solid var(--line-2); border-radius: 14px; background: #fff; transition: border-color .15s, box-shadow .15s, background .15s; height: 100%; }
.choice-ico { width: 34px; height: 34px; color: var(--primary); margin-bottom: .35rem; }
.choice-t { font-weight: 800; font-size: .98rem; }
.choice-d { font-size: .82rem; color: var(--muted); }
.choice-price { margin-top: .5rem; font-size: .8rem; font-weight: 700; color: var(--accent-2); }
.choice-price b { font-size: .95rem; }
.choice:hover .choice-body { border-color: var(--primary); }
.choice input:checked + .choice-body { border-color: var(--primary); background: var(--primary-soft); box-shadow: 0 0 0 3px rgba(47,93,80,.14) inset; }
.choice input:focus-visible + .choice-body { box-shadow: 0 0 0 4px rgba(47,93,80,.25); }

/* segmented */
.seg { display: inline-flex; background: #fff; border: 1.5px solid var(--line-2); border-radius: 999px; padding: 4px; gap: 2px; max-width: 100%; }
.seg.seg-wrap { flex-wrap: wrap; border-radius: 18px; }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; inset: 0; pointer-events: none; }
.seg span { display: inline-block; padding: .55rem 1rem; border-radius: 999px; font-weight: 700; font-size: .9rem; color: var(--ink-2); transition: background .15s, color .15s; white-space: nowrap; }
.seg input:checked + span { background: var(--primary); color: #fff; }
.seg input:focus-visible + span { box-shadow: 0 0 0 3px rgba(47,93,80,.3); }
@media (max-width: 520px) { .seg { flex-wrap: wrap; border-radius: 18px; } }

/* DPE */
.dpe { display: flex; flex-wrap: wrap; gap: .4rem; }
.dpe label { position: relative; cursor: pointer; }
.dpe input { position: absolute; opacity: 0; inset: 0; pointer-events: none; }
.dpe span { display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 .8rem; border-radius: 10px; font-weight: 800; color: #fff; opacity: .5; transition: opacity .15s, transform .15s, box-shadow .15s; }
.dpe input:checked + span { opacity: 1; transform: translateY(-2px); box-shadow: 0 6px 14px rgba(0,0,0,.18); }
.dpe-A { background: #1F9D55; } .dpe-B { background: #52B043; } .dpe-C { background: #A8C93A; color: #1B1E1C !important; } .dpe-D { background: #F2D33A; color: #1B1E1C !important; } .dpe-E { background: #F0A63A; } .dpe-F { background: #E86A2A; } .dpe-G { background: #D62E2E; } .dpe-X { background: var(--ink-2); font-size: .85rem; }

/* switch */
.switch { display: inline-flex; align-items: center; gap: .75rem; cursor: pointer; font-weight: 700; font-size: .95rem; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch-track { width: 46px; height: 26px; border-radius: 999px; background: var(--line-2); position: relative; transition: background .2s; flex: 0 0 auto; }
.switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 2px 5px rgba(0,0,0,.2); }
.switch input:checked + .switch-track { background: var(--primary); }
.switch input:checked + .switch-track::after { transform: translateX(20px); }
.switch input:focus-visible + .switch-track { box-shadow: 0 0 0 4px rgba(47,93,80,.25); }

/* range */
.range-row { display: flex; align-items: center; gap: 1rem; }
.range-out { font-family: var(--font-display); font-size: 1.7rem; min-width: 4ch; text-align: right; color: var(--primary-ink); }
input[type="range"] { flex: 1; -webkit-appearance: none; appearance: none; height: 6px; border-radius: 999px; background: linear-gradient(90deg, var(--primary) var(--pct, 50%), var(--line-2) var(--pct, 50%)); outline: none; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); box-shadow: 0 2px 8px rgba(0,0,0,.2); cursor: grab; }
input[type="range"]::-moz-range-thumb { width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); box-shadow: 0 2px 8px rgba(0,0,0,.2); cursor: grab; }

/* counter */
.counter { display: inline-flex; align-items: center; border: 1.5px solid var(--line-2); border-radius: 999px; background: #fff; overflow: hidden; }
.counter input { width: 64px; text-align: center; border: none; padding: .7rem 0; font-weight: 800; font-size: 1.1rem; box-shadow: none !important; }
.counter-btn { width: 44px; height: 44px; border: none; background: transparent; font-size: 1.3rem; font-weight: 700; color: var(--primary); }
.counter-btn:hover { background: var(--primary-soft); }
.help { width: 20px; height: 20px; border-radius: 50%; border: none; background: var(--primary-soft); color: var(--primary); font-size: .75rem; font-weight: 800; vertical-align: middle; margin-left: .3rem; }
.seuils-card { background: #FBF9F5; border: 1px dashed var(--line-2); border-radius: var(--radius-sm); padding: 1rem 1.1rem; font-size: .88rem; margin-bottom: 1.4rem; }
.seuils-card .seuils-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: .5rem; margin-top: .6rem; }
.seuils-card .seuil { border-radius: 10px; padding: .55rem .6rem; color: #fff; font-weight: 700; line-height: 1.25; opacity: .55; }
.seuils-card .seuil.is-on { opacity: 1; box-shadow: 0 6px 14px rgba(0,0,0,.15); }
.seuils-card .seuil small { display: block; font-weight: 600; font-size: .72rem; opacity: .9; }
@media (max-width: 560px) { .seuils-card .seuils-row { grid-template-columns: 1fr 1fr; } }
.step-nav { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: 2rem; padding-top: 1.4rem; border-top: 1px solid var(--line); }

/* ---------- Résultat ---------- */
.step-result { animation: fadeUp .5s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.result-hero { display: grid; grid-template-columns: 1.2fr 1fr; gap: 1.6rem; align-items: stretch; margin-bottom: 1.4rem; }
@media (max-width: 760px) { .result-hero { grid-template-columns: 1fr; } }
.result-title { font-size: clamp(1.6rem, 3vw, 2.2rem); margin: .3rem 0 .6rem; }
.result-title .big { display: block; font-size: clamp(2.8rem, 6vw, 4.2rem); color: var(--primary-ink); line-height: 1; margin: .2rem 0 .3rem; }
.result-intro { color: var(--ink-2); font-size: 1.02rem; }
.badge { display: inline-flex; align-items: center; gap: .5rem; padding: .45rem .9rem; border-radius: 999px; font-size: .82rem; font-weight: 800; color: #fff; }
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #fff; opacity: .85; }
.badge-bleu { background: var(--bleu); } .badge-jaune { background: var(--jaune); } .badge-violet { background: var(--violet); } .badge-rose { background: var(--rose); }
.result-kpis { display: grid; gap: .7rem; }
.kpi { background: #FBF9F5; border: 1px solid var(--line); border-radius: 14px; padding: .9rem 1.1rem; display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.kpi span { font-size: .85rem; color: var(--muted); font-weight: 600; }
.kpi strong { font-family: var(--font-display); font-size: 1.6rem; white-space: nowrap; }
.kpi-total { background: var(--primary-soft); border-color: transparent; }
.kpi-total strong { color: var(--primary-ink); }
.kpi-reste { background: var(--accent-soft); border-color: transparent; }
.kpi-reste strong { color: var(--accent-2); }
.stackbar { margin: .4rem 0 1.6rem; }
.stackbar-bar { display: flex; height: 22px; border-radius: 999px; overflow: hidden; background: var(--bg-2); }
.stackbar-bar i { display: block; height: 100%; transition: width 1s cubic-bezier(.2,.8,.2,1); width: 0; }
.stackbar-legend { display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; margin-top: .6rem; font-size: .84rem; font-weight: 600; color: var(--ink-2); }
.stackbar-legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--c); margin-right: .45rem; vertical-align: -1px; }
.aid-list { display: grid; gap: .7rem; margin-bottom: 1.6rem; }
.aid { display: grid; grid-template-columns: 44px 1fr auto; gap: .9rem; align-items: center; padding: .95rem 1.1rem; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.aid.is-off { opacity: .75; background: #FBF9F5; }
.aid-ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; font-size: .72rem; color: #fff; letter-spacing: .03em; text-align: center; line-height: 1; }
.ico-mpr { background: var(--primary); } .ico-cee { background: var(--ochre-2); } .ico-tva { background: var(--accent); } .ico-ptz { background: var(--ink-2); } .ico-loc { background: var(--violet); }
.aid-t { font-weight: 800; }
.aid-d { font-size: .82rem; color: var(--muted); margin: .15rem 0 0; }
.aid-amount { font-family: var(--font-display); font-size: 1.45rem; white-space: nowrap; text-align: right; }
.aid-amount small { display: block; font-family: var(--font-body); font-size: .72rem; color: var(--muted); font-weight: 600; }
.aid.is-off .aid-amount { color: var(--muted); font-size: .95rem; font-family: var(--font-body); font-weight: 700; }
@media (max-width: 560px) { .aid { grid-template-columns: 40px 1fr; } .aid-amount { grid-column: 2; text-align: left; } }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1.2rem; }
@media (max-width: 700px) { .grid-2 { grid-template-columns: 1fr; } }
.card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.2rem 1.3rem; }
.card h4 { margin: 0 0 .8rem; font-size: 1rem; font-weight: 800; display: flex; align-items: center; gap: .5rem; }
.card h4 svg { width: 20px; height: 20px; color: var(--primary); }
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; margin: 0; }
.stats div { display: flex; flex-direction: column; }
.stats dt { font-size: .78rem; color: var(--muted); font-weight: 600; }
.stats dd { margin: 0; font-family: var(--font-display); font-size: 1.5rem; color: var(--ink); }
.stats dd small { font-family: var(--font-body); font-size: .8rem; color: var(--muted); font-weight: 600; }
.card-soft { background: var(--ochre-soft); border-color: transparent; }
.card-ampleur { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-2) 100%); color: #fff; border: none; display: grid; grid-template-columns: 1fr auto; gap: 1rem; align-items: center; margin-bottom: 1.2rem; }
.card-ampleur h4 { color: #fff; }
.card-ampleur p { margin: 0; font-size: .9rem; opacity: .92; }
.card-ampleur strong { font-family: var(--font-display); font-size: 2rem; white-space: nowrap; }
@media (max-width: 600px) { .card-ampleur { grid-template-columns: 1fr; } }
.messages { display: grid; gap: .6rem; margin-bottom: 1.4rem; }
.msg { display: flex; gap: .7rem; padding: .85rem 1rem; border-radius: 12px; font-size: .9rem; border: 1px solid; }
.msg::before { content: ""; width: 8px; height: 8px; border-radius: 50%; margin-top: .45rem; flex: 0 0 auto; background: currentColor; }
.msg-info { background: #F3F7FB; border-color: #D5E2EE; color: #2D4B66; }
.msg-warn { background: #FFF6E8; border-color: #F3DDB8; color: #7A4B0B; }
.msg-ok { background: #EEF7F1; border-color: #CFE6D7; color: #1F5F3A; }
.calc-detail { border: 1px solid var(--line); border-radius: 14px; margin-bottom: 1.4rem; background: #FBF9F5; }
.calc-detail summary { cursor: pointer; padding: .95rem 1.1rem; font-weight: 800; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.calc-detail summary::-webkit-details-marker { display: none; }
.calc-detail summary::after { content: "+"; font-size: 1.3rem; color: var(--primary); }
.calc-detail[open] summary::after { content: "−"; }
.calc-table { width: 100%; border-collapse: collapse; font-size: .86rem; }
.calc-table th, .calc-table td { text-align: left; padding: .6rem 1.1rem; border-top: 1px solid var(--line); vertical-align: top; }
.calc-table th { width: 32%; color: var(--muted); font-weight: 700; white-space: nowrap; }
.table-wrap { overflow-x: auto; }
.result-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1.8rem; }

/* lead */
.lead-card { background: linear-gradient(180deg, #fff 0%, #FBF9F5 100%); border: 1.5px solid var(--primary); border-radius: 18px; padding: clamp(1.2rem, 3vw, 1.8rem); box-shadow: 0 16px 40px rgba(47,93,80,.14); }
.lead-card h3 { font-size: 1.6rem; margin-bottom: .3rem; }
.lead-card > p { color: var(--ink-2); margin-bottom: 1.2rem; }
.lead-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .lead-grid { grid-template-columns: 1fr; } }
.lead-grid .full { grid-column: 1 / -1; }
.consent { display: flex; gap: .7rem; align-items: flex-start; font-size: .82rem; color: var(--muted); }
.consent input { margin-top: .25rem; width: 18px; height: 18px; accent-color: var(--primary); flex: 0 0 auto; }
.lead-ok { text-align: center; padding: 1.5rem 1rem; }
.lead-ok .check { width: 64px; height: 64px; border-radius: 50%; background: var(--ok); color: #fff; display: grid; place-items: center; margin: 0 auto 1rem; font-size: 2rem; }
.disclaimer { font-size: .78rem; color: var(--muted); margin-top: 1.6rem; }

/* ---------- Comment ça marche ---------- */
.how { padding: clamp(3rem, 6vw, 5.5rem) 0; }
.how-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.how-grid li { background: var(--card); border-radius: var(--radius); padding: 1.8rem; box-shadow: var(--shadow); border: 1px solid #fff; }
.how-n { font-family: var(--font-display); font-size: 2.4rem; color: var(--accent); display: block; margin-bottom: .6rem; }
.how-grid h3 { font-size: 1.35rem; }
.how-grid p { color: var(--muted); margin: 0; font-size: .95rem; }
@media (max-width: 800px) { .how-grid { grid-template-columns: 1fr; } }

/* ---------- Aides ---------- */
.aides { padding: clamp(3rem, 6vw, 5.5rem) 0; background: var(--primary-ink); color: #fff; }
.aides .eyebrow { color: var(--ochre); }
.aides .section-head p:last-child { color: rgba(255,255,255,.75); }
.aides-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.aide-card { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: 18px; padding: 1.5rem; }
.aide-card h3 { font-size: 1.35rem; margin: .8rem 0 .6rem; }
.aide-card p { color: rgba(255,255,255,.78); font-size: .9rem; margin: 0; }
.aide-card b { color: #fff; }
.aide-tag { display: inline-block; padding: .35rem .75rem; border-radius: 999px; font-size: .74rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.tag-mpr { background: var(--primary-soft); color: var(--primary-ink); } .tag-cee { background: var(--ochre); color: #3A2A00; } .tag-tva { background: var(--accent-soft); color: var(--accent-2); } .tag-ptz { background: #fff; color: var(--ink); }
@media (max-width: 1000px) { .aides-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .aides-grid { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq { padding: clamp(3rem, 6vw, 5.5rem) 0; }
.faq-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 3rem; }
@media (max-width: 860px) { .faq-grid { grid-template-columns: 1fr; gap: 1rem; } }
.faq-list details { background: var(--card); border-radius: 14px; border: 1px solid var(--line); margin-bottom: .6rem; }
.faq-list summary { cursor: pointer; padding: 1rem 1.2rem; font-weight: 800; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-size: 1.4rem; color: var(--primary); flex: 0 0 auto; }
.faq-list details[open] summary::after { content: "−"; }
.faq-list p { padding: 0 1.2rem 1.1rem; margin: 0; color: var(--ink-2); font-size: .95rem; }

/* ---------- CTA + footer ---------- */
.cta { padding: 0 0 clamp(3rem, 6vw, 5.5rem); }
.cta-box { background: linear-gradient(135deg, var(--accent) 0%, #C95E24 100%); color: #fff; border-radius: 28px; padding: clamp(1.8rem, 4vw, 3rem); display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; box-shadow: 0 24px 60px rgba(224,122,63,.3); }
.cta-box h2 { margin-bottom: .4rem; }
.cta-box p { margin: 0; opacity: .92; }
.cta-actions { display: flex; flex-direction: column; align-items: flex-end; gap: .8rem; }
.cta-phone { font-family: var(--font-display); font-size: 2rem; }
@media (max-width: 800px) { .cta-box { grid-template-columns: 1fr; } .cta-actions { align-items: flex-start; } }
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0 1.5rem; font-size: .9rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; }
.footer-disclaimer { color: var(--muted); font-size: .82rem; margin-top: 1rem; max-width: 60ch; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; align-content: start; justify-content: flex-end; font-weight: 600; color: var(--ink-2); }
.footer-links a:hover { color: var(--primary); }
.footer-bottom { margin-top: 1.8rem; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .8rem; }
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } .footer-links { justify-content: flex-start; } }

/* ---------- Admin ---------- */
body.is-admin main, body.is-admin .site-footer { display: none; }
.admin { padding: 2.5rem 0 4rem; }
.admin-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: .6rem; }
.admin-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.pill { display: inline-block; background: var(--primary); color: #fff; border-radius: 999px; font-size: .9rem; padding: .15rem .7rem; vertical-align: middle; font-family: var(--font-body); font-weight: 800; }
.admin-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 14px; overflow: hidden; font-size: .85rem; margin-top: 1rem; box-shadow: var(--shadow); }
.admin-table th, .admin-table td { padding: .7rem .8rem; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.admin-table th { background: var(--primary-soft); font-weight: 800; }
.admin-table td.empty { text-align: center; color: var(--muted); padding: 2rem; white-space: normal; }
code { background: var(--bg-2); padding: .1rem .35rem; border-radius: 5px; font-size: .85em; }

/* ---------- Modal + toast ---------- */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 1rem; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(27,30,28,.55); backdrop-filter: blur(3px); }
.modal-box { position: relative; background: #fff; border-radius: 20px; padding: 2rem; max-width: 640px; width: 100%; max-height: 85vh; overflow: auto; box-shadow: var(--shadow-lg); animation: fadeUp .3s ease; }
.modal-box h3 { padding-right: 2rem; }
.modal-box p, .modal-box li { font-size: .93rem; color: var(--ink-2); }
.modal-close { position: absolute; top: .8rem; right: .9rem; width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--bg-2); font-size: 1.4rem; line-height: 1; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: .8rem 1.2rem; border-radius: 999px; font-weight: 700; font-size: .9rem; z-index: 200; box-shadow: var(--shadow-lg); animation: fadeUp .3s ease; }

/* ---------- House SVG ---------- */
.house-svg .ite-band { animation: bandIn 1s ease both; transform-origin: center bottom; }
@keyframes bandIn { from { opacity: 0; transform: scaleY(0); } to { opacity: 1; transform: scaleY(1); } }

/* ---------- Print ---------- */
@media print {
  .site-header, .hero, .how, .aides, .faq, .cta, .site-footer, .wizard-side, .result-actions, .lead-card, .toast, .modal { display: none !important; }
  body { background: #fff; }
  .sim { padding: 0; background: #fff; }
  .wizard { grid-template-columns: 1fr; }
  .wizard-main { box-shadow: none; border: none; padding: 0; }
  .calc-detail { display: block; } .calc-detail summary::after { display: none; }
  .calc-detail:not([open]) .calc-table { display: table; }
}

/* ---------- Ajuster / comparatif / frise (améliorations) ---------- */
.adjust { margin-bottom: 1.4rem; background: linear-gradient(180deg, #fff 0%, #FBF7F0 100%); border-color: var(--line-2); }
.adjust-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 1.2rem; align-items: start; }
@media (max-width: 760px) { .adjust-grid { grid-template-columns: 1fr; } }
.adjust-item .field-label { display: flex; justify-content: space-between; align-items: baseline; gap: .6rem; }
.adjust-item output { font-family: var(--font-display); font-size: 1.35rem; color: var(--primary-ink); }
.adjust-item input[type="range"] { width: 100%; margin-top: .6rem; }
.adjust .seg span { font-size: .82rem; padding: .5rem .8rem; }
.compare { margin-bottom: 1.2rem; }
.compare-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.compare-table th, .compare-table td { text-align: left; padding: .7rem .8rem; border-top: 1px solid var(--line); vertical-align: middle; white-space: nowrap; }
.compare-table th { font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-top: none; }
.compare-table td small { display: block; font-size: .74rem; color: var(--muted); font-weight: 500; white-space: normal; }
.compare-table tbody tr { cursor: pointer; transition: background .15s; }
.compare-table tbody tr:hover { background: #FBF7F0; }
.compare-table tr.is-on { background: var(--primary-soft); }
.compare-table tr.is-on td:first-child { box-shadow: inset 4px 0 0 var(--primary); }
.timeline-card { margin-bottom: 1.4rem; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; position: relative; }
.timeline::before { content: ""; position: absolute; left: 14px; right: 14px; top: 15px; height: 2px; background: var(--line-2); }
.timeline li { position: relative; padding-top: 44px; }
.tl-dot { position: absolute; top: 0; left: 0; width: 32px; height: 32px; border-radius: 50%; background: var(--primary); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: .85rem; box-shadow: 0 0 0 4px #fff; }
.timeline b { display: block; font-size: .95rem; margin-bottom: .3rem; }
.timeline p { font-size: .82rem; color: var(--muted); margin: 0 0 .4rem; }
.timeline small { font-size: .74rem; font-weight: 800; color: var(--accent-2); text-transform: uppercase; letter-spacing: .05em; }
@media (max-width: 760px) { .timeline { grid-template-columns: 1fr; gap: 1.2rem; } .timeline::before { left: 15px; right: auto; top: 0; bottom: 0; width: 2px; height: auto; } .timeline li { padding: 0 0 0 48px; min-height: 36px; } }

/* ---------- Anti-débordement mobile (enfants de grilles) ---------- */
.wizard > *, .hero-grid > *, .result-hero > *, .grid-2 > *, .adjust-grid > *, .lead-grid > *, .house-card > *, .how-grid > li, .aides-grid > *, .faq-grid > *, .footer-grid > *, .cta-box > *, .field-row > * { min-width: 0; }
.live div { flex-wrap: wrap; }
@media (max-width: 900px) { .wizard { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 480px) { .house-card { grid-template-columns: 1fr; } .house-preview { max-width: 220px; margin: 0 auto .6rem; } .result-title .big { font-size: 2.6rem; } .kpi strong { font-size: 1.35rem; } }
.house-svg { width: 100%; height: auto; display: block; }
@media (max-width: 480px) { .house-preview { width: 100%; max-width: 220px; } }
