/**
 * Comparateur Energetique — Le Bois Qui Vous Chauffe
 * 4-step flow: House > Wood > Energy > Report
 * Only 2 wood types: Humide + Palette Ultra-Sec
 */

/* ================================================================
   VARIABLES
   ================================================================ */
:root {
  --sim-bg-deep: #f8f6f2;
  --sim-bg-warm: #f0ece4;
  --sim-bg-card: #ffffff;
  --sim-bg-card-hover: #faf8f5;
  --sim-surface: #e8e2d8;
  --sim-border: #ddd6ca;
  --sim-border-light: #cfc7ba;
  --sim-text-primary: #2c2418;
  --sim-text-secondary: #5c5040;
  --sim-text-muted: #8a7e6e;
  --sim-amber: #c48a28;
  --sim-amber-light: #b07820;
  --sim-amber-glow: rgba(196,138,40,0.10);
  --sim-copper: #a06828;
  --sim-fire: #d45a20;
  --sim-fire-deep: #b03a10;
  --sim-emerald: #2a8a58;
  --sim-emerald-light: #238a4e;
  --sim-emerald-glow: rgba(42,138,88,0.08);
  --sim-frost: #4a8cbb;
  --sim-danger: #c44a3a;
  --sim-danger-light: #d04030;
  --sim-orange-warn: #c47030;
  --sim-gold: #b08a30;
  --sim-gold-bright: #c49a20;
  --sim-radius-sm: 8px;
  --sim-radius-md: 14px;
  --sim-radius-lg: 22px;
  --sim-radius-xl: 32px;
  --sim-transition: 0.4s cubic-bezier(0.22,1,0.36,1);
  --sim-shadow-sm: 0 2px 8px rgba(44,36,24,0.06);
  --sim-shadow-md: 0 4px 16px rgba(44,36,24,0.08);
  --sim-shadow-lg: 0 8px 32px rgba(44,36,24,0.10);
  --sim-shadow-card: 0 2px 12px rgba(44,36,24,0.07);
}

/* ================================================================
   HIDE WORDPRESS SITE HEADER/FOOTER/TOPBAR
   ================================================================ */
body.page-template-template-simulator .lbq-topbar,
body.page-template-template-simulator .lbq-header,
body.page-template-template-simulator .lbq-mobile-menu,
body.page-template-template-simulator #banner_promo,
body.page-template-template-simulator .footer,
body.page-template-template-simulator .footer-top,
body.page-template-template-simulator .footer-bottoms,
body.page-template-template-simulator .copyright-menu,
body.page-template-template-simulator .woocommerce-breadcrumb,
body.page-template-template-simulator .breadcrumb-bar {
  display: none !important;
}

/* Hide chat widget and phone sticky button on simulator page */
body.page-template-template-simulator .phone-to-fix-mobile,
body.page-template-template-simulator #button[data-testid="widgetButton"],
body.page-template-template-simulator [data-testid="widgetButton"],
body.page-template-template-simulator #button#button,
body.page-template-template-simulator div[class*="bubbleAnimation"],
body.page-template-template-simulator div[class*="chat-closed"],
body.page-template-template-simulator div[class*="chat-open"],
body.page-template-template-simulator iframe[title*="chat" i],
body.page-template-template-simulator iframe[src*="chat" i],
body.page-template-template-simulator iframe[id*="chat" i] {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* ================================================================
   BODY OVERRIDES WHEN SIMULATOR ACTIVE
   ================================================================ */
body.page-template-template-simulator {
  background: var(--sim-bg-deep) !important;
  color: var(--sim-text-primary) !important;
  overflow: hidden;
  height: 100vh;
  margin: 0 !important;
  padding: 0 !important;
}
body.page-template-template-simulator .site-content,
body.page-template-template-simulator .ohio-content,
body.page-template-template-simulator #content,
body.page-template-template-simulator main {
  padding: 0 !important;
  margin: 0 !important;
  max-width: 100% !important;
}

body.results-active {
  overflow: auto !important;
  height: auto !important;
}
body.results-active #sim-root {
  height: auto !important;
  overflow: visible !important;
}

/* ================================================================
   ROOT & ATMOSPHERE
   ================================================================ */
#sim-root {
  position: relative;
  height: 100vh;
  overflow: hidden;
  font-family: 'DM Sans', sans-serif;
  color: var(--sim-text-primary);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}
#sim-root * { box-sizing: border-box; }

#sim-root::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(196,138,40,0.04) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 100%, rgba(210,100,40,0.03) 0%, transparent 50%);
}

.grain-overlay {
  position: fixed;
  inset: 0;
  opacity: 0.008;
  pointer-events: none;
  z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 200px;
}

/* ================================================================
   PARTICLES
   ================================================================ */
.particles-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.particle {
  position: absolute;
  border-radius: 50%;
  opacity: 0;
  animation: simParticleFloat linear infinite;
}
@keyframes simParticleFloat {
  0%   { transform: translateY(100vh) scale(0); opacity: 0; }
  10%  { opacity: .7; }
  90%  { opacity: .05; }
  100% { transform: translateY(-20vh) scale(1); opacity: 0; }
}

/* ================================================================
   CONFETTI
   ================================================================ */
.sim-confetti {
  position: fixed;
  z-index: 300;
  pointer-events: none;
  opacity: 0;
}
@keyframes simConfettiFall {
  0%   { transform: translateY(-10px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(100vh) rotate(720deg); opacity: 0; }
}

/* ================================================================
   STEP LAYOUT (FULLSCREEN)
   Steps 1-3: viewport height, content scrolls, nav pinned at bottom
   Step 4 (report): fully scrollable page
   ================================================================ */
.sim-step {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transform: translateX(60px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.22,1,0.36,1);
}
.sim-step.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}
.sim-step.exit-left {
  opacity: 0;
  transform: translateX(-60px);
  pointer-events: none;
}

/* Scrollable content area — takes all space except nav */
.sim-step-scroll {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 108px 20px 12px;
}

/* Nav bar pinned at bottom of step — always visible */
.sim-nav {
  flex-shrink: 0;
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
  padding: 14px 20px;
  width: 100%;
  background: var(--sim-bg-deep);
  border-top: 1px solid var(--sim-border);
  box-shadow: 0 -4px 16px rgba(44,36,24,0.06);
  z-index: 10;
}

/* Results step (step 4): fully scrollable page */
.sim-step.results-step {
  position: relative;
  height: auto;
  min-height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  padding-top: 30px;
  padding-bottom: 80px;
}
.sim-step.results-step.active {
  position: relative;
}
/* In results step, nav is inline in the scroll flow */
.sim-step.results-step .sim-nav {
  background: none;
  border-top: none;
  box-shadow: none;
  padding: 20px 0;
}

.sim-step-inner {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px;
}
.sim-step-inner.step1-inner {
  max-width: 760px;
}
.sim-step-inner.step2-inner {
  max-width: 840px;
}
.sim-step-inner.step3-inner {
  max-width: 880px;
}
.sim-step-inner.step4-inner {
  max-width: 920px;
}

/* ================================================================
   LOGO BAR (top left)
   ================================================================ */
.sim-logo-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 101;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 20px;
  background: var(--sim-bg-deep);
  border-bottom: 1px solid var(--sim-border);
}
.sim-logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.sim-logo-img {
  height: 32px;
  width: auto;
}
.sim-logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--sim-text-primary);
}
.sim-back-home {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--sim-text-muted);
  text-decoration: none;
  padding: 6px 12px;
  border-radius: 100px;
  border: 1px solid var(--sim-border);
  transition: all var(--sim-transition);
}
.sim-back-home:hover {
  color: var(--sim-text-primary);
  border-color: var(--sim-amber);
  background: var(--sim-amber-glow);
}

/* ================================================================
   PROGRESS BAR (below logo)
   ================================================================ */
.sim-topbar {
  position: fixed;
  top: 49px; left: 0; right: 0;
  z-index: 100;
  padding: 10px 20px 8px;
  background: linear-gradient(180deg, var(--sim-bg-deep) 70%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
}
.sim-prog-dot {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  color: var(--sim-text-muted);
  transition: all var(--sim-transition);
  flex-shrink: 0;
  position: relative;
  box-shadow: var(--sim-shadow-sm);
}
.sim-prog-dot.active {
  border-color: var(--sim-amber);
  color: var(--sim-amber);
  background: var(--sim-amber-glow);
  box-shadow: 0 0 12px rgba(196,138,40,0.2);
}
.sim-prog-dot.done {
  border-color: var(--sim-emerald);
  color: white;
  background: var(--sim-emerald);
  box-shadow: 0 0 12px rgba(42,138,88,0.2);
}
.sim-prog-dot.done::after {
  content: '\2713';
  position: absolute;
  font-size: 13px;
}
.sim-prog-dot.done span { opacity: 0; }
.sim-prog-line {
  width: 44px; height: 2px;
  background: var(--sim-border);
  transition: background var(--sim-transition);
}
.sim-prog-line.done { background: var(--sim-emerald); }

.sim-prog-labels {
  position: fixed;
  top: 94px; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  gap: 30px;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--sim-text-muted);
}
.sim-prog-labels span {
  transition: color var(--sim-transition);
  width: 60px;
  text-align: center;
}
.sim-prog-labels span.active { color: var(--sim-amber-light); }
.sim-prog-labels span.done   { color: var(--sim-emerald-light); }

/* ================================================================
   STEP HEADER
   ================================================================ */
.sim-header { text-align: center; margin-bottom: 12px; }
.sim-header-num {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 14px;
  border-radius: 100px;
  background: var(--sim-amber-glow);
  border: 1px solid rgba(212,160,67,0.2);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--sim-amber-light);
  margin-bottom: 8px;
}
.sim-header h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.3rem, 3.5vw, 1.8rem);
  font-weight: 900;
  line-height: 1.15;
  margin-bottom: 6px;
  color: var(--sim-text-primary);
}
.sim-header h2 em {
  font-style: italic;
  background: linear-gradient(135deg, var(--sim-amber), var(--sim-fire));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.sim-header p {
  font-size: clamp(0.8rem, 2vw, 0.9rem);
  color: var(--sim-text-secondary);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.5;
  font-weight: 300;
}
.sim-header p strong { color: var(--sim-amber-light); font-weight: 600; }

/* Report main header spacing */
.res-main-header {
  margin-top: 50px;
}

/* ================================================================
   GUIDE BOX
   ================================================================ */
.sim-guide {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  margin-bottom: 18px;
  width: 100%;
  background: rgba(212,160,67,0.06);
  border: 1px solid rgba(212,160,67,0.12);
  border-radius: var(--sim-radius-md);
  font-size: 13px;
  color: var(--sim-text-secondary);
  line-height: 1.6;
  box-shadow: var(--sim-shadow-sm);
}
.sim-guide-icon {
  width: 32px; height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--sim-amber-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--sim-amber-light);
}
.sim-guide strong { color: var(--sim-amber-light); font-weight: 600; }

/* ================================================================
   DESCRIPTIF DETAILLE (calculation explanation)
   ================================================================ */
.sim-descriptif {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px 18px;
  margin-top: 14px;
  width: 100%;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-left: 4px solid var(--sim-amber);
  border-radius: var(--sim-radius-md);
  font-size: 13px;
  color: var(--sim-text-secondary);
  line-height: 1.7;
  box-shadow: var(--sim-shadow-sm);
}
.sim-descriptif-icon {
  font-size: 22px;
  flex-shrink: 0;
  margin-top: 2px;
}
.sim-descriptif-text {
  flex: 1;
}
.sim-descriptif-text strong {
  color: var(--sim-text-primary);
  font-weight: 700;
}
.sim-descriptif-text .desc-green {
  color: var(--sim-emerald);
  font-weight: 700;
}
.sim-descriptif-text .desc-orange {
  color: var(--sim-orange-warn);
  font-weight: 600;
}
.sim-descriptif-text .desc-highlight {
  background: rgba(42,138,88,0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
  color: var(--sim-emerald);
}

/* ================================================================
   ASTUCE BOX (tips)
   ================================================================ */
.sim-astuce {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  margin-top: 16px;
  margin-bottom: 8px;
  width: 100%;
  background: rgba(58,158,110,0.06);
  border: 1px solid rgba(58,158,110,0.15);
  border-radius: var(--sim-radius-md);
  font-size: 12px;
  color: var(--sim-text-secondary);
  line-height: 1.6;
  box-shadow: var(--sim-shadow-sm);
}
.sim-astuce-icon {
  font-size: 20px;
  flex-shrink: 0;
  line-height: 1;
}
.sim-astuce-text strong {
  color: var(--sim-emerald-light);
  font-weight: 600;
}

/* ================================================================
   BOTTOM ROW: 3-column — kWh | Humide | Palette (winner)
   ================================================================ */
.sim-bottom-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
  width: 100%;
  margin-top: 16px;
}
.sim-bottom-card {
  padding: 16px 14px;
  border-radius: var(--sim-radius-md);
  text-align: center;
  box-shadow: var(--sim-shadow-card);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.sim-bottom-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-md);
}

/* Left card: kWh */
.sim-bottom-kwh {
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
}

/* Middle card: Humide (amber/orange accent) */
.sim-bottom-humide {
  background: var(--sim-bg-card);
  border: 2px solid rgba(196,112,48,0.3);
  position: relative;
}
.sim-bottom-humide::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--sim-orange-warn), #d4823a);
  border-radius: var(--sim-radius-md) var(--sim-radius-md) 0 0;
}
.sim-bottom-humide-icon {
  color: var(--sim-orange-warn) !important;
}
.sim-bottom-humide-val {
  color: var(--sim-orange-warn) !important;
}
.sim-bottom-humide .sim-bottom-card-sub strong {
  color: var(--sim-orange-warn) !important;
}

/* Right card: Palette winner (green accent) */
.sim-bottom-reco {
  background: linear-gradient(135deg, rgba(42,138,88,0.06), rgba(42,138,88,0.02));
  border: 2px solid rgba(42,138,88,0.35);
  position: relative;
}
.sim-bottom-reco::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--sim-emerald), var(--sim-emerald-light));
  border-radius: var(--sim-radius-md) var(--sim-radius-md) 0 0;
}
.sim-bottom-card-icon {
  margin-bottom: 6px;
  color: var(--sim-amber);
}
.sim-bottom-card-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--sim-text-muted);
  margin-bottom: 4px;
}
.sim-bottom-card-value {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  font-weight: 900;
  color: var(--sim-amber);
  line-height: 1.2;
  margin-bottom: 4px;
}
.sim-bottom-card-sub {
  font-size: 12px;
  color: var(--sim-text-muted);
}
.sim-bottom-card-sub strong {
  color: var(--sim-gold-bright);
  font-weight: 700;
}
.sim-bottom-reco-badge {
  display: inline-block;
  padding: 3px 10px;
  background: linear-gradient(135deg, var(--sim-emerald), #1e7a48);
  border-radius: 100px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: white;
  margin-bottom: 8px;
}
.sim-bottom-reco-title {
  color: var(--sim-emerald) !important;
  font-size: clamp(0.95rem, 2vw, 1.15rem) !important;
}

/* Savings line inside palette card */
.sim-bottom-savings {
  margin-top: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--sim-emerald-light);
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(42,138,88,0.08);
}
.sim-bottom-savings strong {
  color: var(--sim-emerald-light);
  font-weight: 800;
  font-size: 13px;
}
.sim-bottom-savings.savings-negative {
  color: var(--sim-orange-warn);
  background: rgba(196,112,48,0.08);
}
.sim-bottom-savings.savings-negative strong {
  color: var(--sim-orange-warn);
}

.sim-reco-detail strong {
  color: var(--sim-gold-bright);
  font-weight: 700;
  font-size: 15px;
}

/* ================================================================
   TOOLTIP SYSTEM (? icons)
   ================================================================ */
.sim-tooltip-trigger {
  position: relative;
  display: inline-flex;
  cursor: pointer;
}
.sim-tooltip-icon {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--sim-amber-glow);
  border: 1px solid rgba(212,160,67,0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  color: var(--sim-amber-light);
  transition: all 0.2s;
}
.sim-tooltip-icon:hover {
  background: rgba(212,160,67,0.25);
}
.sim-tooltip-popup {
  position: absolute;
  top: 30px;
  left: 50%;
  transform: translateX(-50%);
  width: 280px;
  padding: 12px 16px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border-light);
  border-radius: var(--sim-radius-sm);
  font-size: 12px;
  color: var(--sim-text-secondary);
  line-height: 1.6;
  box-shadow: 0 8px 32px rgba(44,36,24,0.15);
  z-index: 50;
  animation: simTooltipIn 0.2s ease;
}
@keyframes simTooltipIn {
  from { opacity:0; transform:translateX(-50%) translateY(-4px); }
  to   { opacity:1; transform:translateX(-50%) translateY(0); }
}

/* ================================================================
   FIELD BLOCKS (Step 1)
   ================================================================ */
.sim-field-block {
  width: 100%;
  margin-bottom: 12px;
}
.sim-field-label-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.sim-field-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--sim-text-muted);
}

/* ================================================================
   SURFACE SLIDER (Step 1)
   ================================================================ */
.sim-slider-display { text-align: center; margin-bottom: 4px; }
.sim-slider-number {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 2.8rem);
  font-weight: 900;
  color: var(--sim-amber);
  line-height: 1;
}
.sim-slider-unit {
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  font-weight: 400;
  color: var(--sim-text-muted);
  margin-left: 4px;
}
.sim-slider-track { position: relative; padding: 8px 0; width: 100%; }

#sim-root input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 8px;
  background: var(--sim-surface);
  border-radius: 4px;
  outline: none;
  cursor: pointer;
  margin: 0;
  padding: 0;
}
#sim-root input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sim-amber), var(--sim-copper));
  border: 4px solid var(--sim-bg-deep);
  box-shadow: 0 2px 16px rgba(212,160,67,0.5);
  cursor: grab;
  transition: transform 0.2s, box-shadow 0.2s;
}
#sim-root input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 2px 24px rgba(212,160,67,0.7);
}
#sim-root input[type="range"]::-moz-range-thumb {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--sim-amber), var(--sim-copper));
  border: 4px solid var(--sim-bg-deep);
  box-shadow: 0 2px 16px rgba(212,160,67,0.5);
  cursor: grab;
}
.sim-slider-hints {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--sim-text-muted);
  margin-top: 6px;
}

/* ================================================================
   INSULATION CARDS (Step 1)
   ================================================================ */
.sim-insul-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  width: 100%;
}
.sim-insul-card {
  position: relative;
  padding: 16px 10px 14px;
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  transition: all var(--sim-transition);
  text-align: center;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  box-shadow: var(--sim-shadow-card);
}
.sim-insul-card:hover {
  background: var(--sim-bg-card-hover);
  border-color: var(--sim-border-light);
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-md);
}
.sim-insul-card.selected {
  border-color: var(--sim-amber);
  background: rgba(196,138,40,0.06);
  box-shadow: 0 4px 20px rgba(196,138,40,0.12);
}
.sim-insul-card.selected .sim-opt-check {
  opacity: 1;
  transform: scale(1);
}
.sim-insul-card .sim-opt-check,
.sim-region-card .sim-opt-check {
  position: absolute;
  top: 6px; right: 6px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--sim-amber);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--sim-bg-deep);
  font-weight: 900;
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
}
.sim-insul-emoji {
  font-size: 24px;
  line-height: 1;
  margin-bottom: 2px;
}
.sim-insul-name {
  font-weight: 700;
  font-size: 13px;
  color: var(--sim-text-primary);
}
.sim-insul-date {
  font-size: 10px;
  font-weight: 600;
  color: var(--sim-amber-light);
  letter-spacing: 0.5px;
}
.sim-insul-desc {
  font-size: 10px;
  color: var(--sim-text-muted);
  line-height: 1.3;
  min-height: 26px;
}

/* ================================================================
   REGION CARDS (Step 1)
   ================================================================ */
.sim-region-cards {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  width: 100%;
}
.sim-region-card {
  position: relative;
  padding: 14px 8px 12px;
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  transition: all var(--sim-transition);
  text-align: center;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  box-shadow: var(--sim-shadow-card);
}
.sim-region-card:hover {
  background: var(--sim-bg-card-hover);
  border-color: var(--sim-border-light);
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-md);
}
.sim-region-card.selected {
  border-color: var(--sim-amber);
  background: rgba(196,138,40,0.06);
  box-shadow: 0 0 24px rgba(212,160,67,0.15);
}
.sim-region-card.selected .sim-opt-check {
  opacity: 1;
  transform: scale(1);
}
.sim-region-name {
  font-weight: 700;
  font-size: 13px;
  color: var(--sim-text-primary);
}
.sim-region-desc {
  font-size: 9px;
  color: var(--sim-text-muted);
  line-height: 1.3;
  min-height: 22px;
}
.sim-region-months {
  font-size: 10px;
  font-weight: 600;
  color: var(--sim-amber-light);
}

/* ================================================================
   LIVE PREVIEW (Step 1) — legacy classes kept for compatibility
   ================================================================ */
.sim-live-preview {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  width: 100%;
  background: linear-gradient(135deg, rgba(212,160,67,0.06), rgba(232,93,42,0.04));
  border: 1px solid rgba(212,160,67,0.15);
  border-radius: var(--sim-radius-lg);
  margin-top: 10px;
}
.sim-live-preview-icon {
  width: 36px; height: 36px;
  flex-shrink: 0;
  color: var(--sim-amber-light);
}
.sim-live-preview-icon svg { width: 100%; height: 100%; }
.sim-live-preview-text {
  display: flex;
  flex-direction: column;
}
.sim-live-preview-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.sim-live-preview-value {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  font-weight: 900;
  color: var(--sim-amber-light);
  line-height: 1.2;
}
.sim-live-preview-sub {
  font-size: 12px;
  color: var(--sim-text-secondary);
}

/* ================================================================
   SIZE PILLS (Step 1)
   ================================================================ */
.sim-size-pills {
  display: flex;
  gap: 12px;
  width: 100%;
}
.sim-size-pill {
  flex: 1;
  position: relative;
  padding: 16px 12px;
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  cursor: pointer;
  transition: all var(--sim-transition);
  text-align: center;
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  box-shadow: var(--sim-shadow-card);
}
.sim-size-pill:hover {
  background: var(--sim-bg-card-hover);
  border-color: var(--sim-border-light);
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-md);
}
.sim-size-pill.selected {
  border-color: var(--sim-amber);
  background: var(--sim-amber-glow);
  box-shadow: 0 0 24px rgba(212,160,67,0.15);
}
.sim-size-pill.selected .sim-pill-check {
  opacity: 1;
  transform: scale(1);
}
.sim-pill-check {
  position: absolute;
  top: 6px; right: 6px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--sim-amber);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--sim-bg-deep);
  font-weight: 900;
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.3s cubic-bezier(0.34,1.56,0.64,1);
}
.sim-pill-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--sim-amber);
  line-height: 1;
}
.sim-pill-label {
  font-size: 11px;
  color: var(--sim-text-muted);
  font-weight: 600;
}
.sim-pill-popular {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  background: linear-gradient(135deg, var(--sim-amber), var(--sim-copper));
  font-size: 9px;
  font-weight: 800;
  color: var(--sim-bg-deep);
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-top: 2px;
}

/* ================================================================
   WOOD COMPARISON (Step 2) — Side by side
   ================================================================ */
.sim-wood-compare {
  display: flex;
  gap: 16px;
  width: 100%;
  align-items: stretch;
  margin-bottom: 16px;
}

.sim-wc-card {
  flex: 1;
  background: var(--sim-bg-card);
  border: 2px solid var(--sim-border);
  border-radius: var(--sim-radius-lg);
  padding: 20px 16px 16px;
  position: relative;
  transition: all var(--sim-transition);
  box-shadow: var(--sim-shadow-card);
}
.sim-wc-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-lg);
}

/* Winner card glow */
.sim-wc-card.winner-glow {
  border-color: var(--sim-emerald);
  background: rgba(58,158,110,0.04);
  box-shadow: 0 0 30px rgba(58,158,110,0.12);
  animation: simWinnerPulse 3s ease-in-out infinite;
}
@keyframes simWinnerPulse {
  0%,100% { box-shadow: 0 0 30px rgba(58,158,110,0.12); }
  50%     { box-shadow: 0 0 40px rgba(58,158,110,0.25); }
}

.sim-wc-winner-badge {
  position: absolute;
  top: -10px; left: 50%;
  transform: translateX(-50%);
  padding: 4px 14px;
  background: linear-gradient(135deg, var(--sim-emerald), #2d8a5e);
  border-radius: 100px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: white;
  white-space: nowrap;
}

/* VS separator */
.sim-wc-vs {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sim-wc-vs-circle {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--sim-surface);
  border: 2px solid var(--sim-border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 13px;
  color: var(--sim-text-muted);
  letter-spacing: 1px;
  box-shadow: var(--sim-shadow-sm);
}

.sim-wc-header {
  text-align: center;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--sim-border);
}
.sim-wc-icon {
  font-size: 28px;
  line-height: 1;
  margin-bottom: 6px;
}
.sim-wc-name {
  font-weight: 800;
  font-size: 15px;
  color: var(--sim-text-primary);
  margin-bottom: 2px;
}
.sim-wc-subtitle {
  font-size: 10px;
  color: var(--sim-text-muted);
}

.sim-wc-stat {
  margin-bottom: 10px;
}
.sim-wc-stat-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Gauge bars */
.sim-gauge-bar {
  width: 100%;
  height: 22px;
  background: var(--sim-surface);
  border-radius: 11px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(44,36,24,0.08);
}
.sim-gauge-fill {
  height: 100%;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  color: white;
  transition: width 1s cubic-bezier(0.22,1,0.36,1);
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
  min-width: 40px;
}
.gauge-bad      { background: linear-gradient(90deg, #c44a3a, #e06050); }
.gauge-great    { background: linear-gradient(90deg, #3a9e6e, #4ec48a); }
.gauge-eff-low  { background: linear-gradient(90deg, #d4823a, #e8a050); }
.gauge-eff-great{ background: linear-gradient(90deg, #3a9e6e, #4ec48a); }

.sim-wc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 0;
  border-bottom: 1px solid var(--sim-border);
  gap: 6px;
}
.sim-wc-row:last-of-type {
  border-bottom: none;
}
.sim-wc-row-label {
  font-size: 11px;
  color: var(--sim-text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}
.sim-wc-row-label small {
  font-size: 9px;
  opacity: 0.7;
}
.sim-wc-row-val {
  font-size: 14px;
  font-weight: 700;
  color: var(--sim-text-primary);
  text-align: right;
}
.sim-wc-row-val.val-bad  { color: var(--sim-danger-light); }
.sim-wc-row-val.val-great { color: var(--sim-emerald-light); }

/* Warning box (humide) */
.sim-wc-warning {
  margin-top: 10px;
  padding: 10px 12px;
  background: rgba(196,74,58,0.06);
  border: 1px solid rgba(196,74,58,0.18);
  border-radius: var(--sim-radius-sm);
  font-size: 11px;
  color: var(--sim-danger-light);
  line-height: 1.5;
}
.sim-wc-warning strong { font-weight: 700; }

/* Success box (palette) */
.sim-wc-success {
  margin-top: 10px;
  padding: 10px 12px;
  background: rgba(42,138,88,0.06);
  border: 1px solid rgba(42,138,88,0.18);
  border-radius: var(--sim-radius-sm);
  font-size: 11px;
  color: var(--sim-emerald);
  line-height: 1.5;
}
.sim-wc-success strong { font-weight: 700; }

.sim-wc-total {
  margin-top: 12px;
  padding: 12px;
  background: rgba(44,36,24,0.04);
  border-radius: var(--sim-radius-sm);
  text-align: center;
}
.sim-wc-total.winner-total {
  background: rgba(58,158,110,0.08);
  border: 1px solid rgba(58,158,110,0.2);
}
.sim-wc-total-label {
  display: block;
  font-size: 10px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}
.sim-wc-total-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--sim-text-primary);
}
.sim-wc-card.winner-glow .sim-wc-total-val {
  color: var(--sim-emerald-light);
}

/* Wood savings banner */
.sim-wood-savings {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  width: 100%;
  background: rgba(58,158,110,0.08);
  border: 1px solid rgba(58,158,110,0.2);
  border-radius: var(--sim-radius-lg);
  box-shadow: var(--sim-shadow-sm);
}
.sim-wood-savings-icon {
  font-size: 24px;
  flex-shrink: 0;
}
.sim-wood-savings-text {
  display: flex;
  flex-direction: column;
}
.sim-wood-savings-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.sim-wood-savings-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--sim-emerald-light);
  line-height: 1.2;
}
.sim-wood-savings-val.savings-negative {
  color: var(--sim-orange-warn);
}

/* ================================================================
   ENERGY SECTION (Step 3)
   ================================================================ */
.sim-energy-section {
  width: 100%;
  margin-bottom: 24px;
}
.sim-energy-section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.1rem, 3vw, 1.4rem);
  font-weight: 800;
  color: var(--sim-text-primary);
  text-align: center;
  margin-bottom: 6px;
}
.sim-energy-section-sub {
  font-size: 12px;
  color: var(--sim-text-muted);
  text-align: center;
  margin-bottom: 16px;
  line-height: 1.5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}
.sim-energy-section-sub strong {
  color: var(--sim-amber-light);
}

/* Energy savings hero (Step 3) */
.sim-energy-savings-hero {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  width: 100%;
  background: rgba(58,158,110,0.08);
  border: 1px solid rgba(58,158,110,0.2);
  border-radius: var(--sim-radius-lg);
  margin-bottom: 16px;
  box-shadow: var(--sim-shadow-sm);
}
.sim-energy-savings-icon {
  width: 40px; height: 40px;
  flex-shrink: 0;
}
.sim-energy-savings-icon svg { width: 100%; height: 100%; }
.sim-energy-savings-text {
  display: flex;
  flex-direction: column;
}
.sim-energy-savings-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.sim-energy-savings-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--sim-emerald-light);
  line-height: 1.2;
}

/* ================================================================
   ENERGY BAR CHART (shared Step 3 + Step 4)
   ================================================================ */
.sim-energy-chart,
.res-energy-chart {
  width: 100%;
  margin-bottom: 20px;
}
.res-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  transition: all 0.3s ease;
}
.res-bar-row:hover {
  transform: translateX(2px);
}
.res-bar-row.bar-winner {
  position: relative;
}
.res-bar-row.bar-winner .res-bar-label {
  color: var(--sim-emerald-light);
  font-weight: 700;
}
.res-bar-label {
  width: 130px;
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--sim-text-secondary);
  text-align: right;
}
/* Short/full label toggling for responsive */
.res-bar-label-short {
  display: none;
}
.res-bar-track {
  flex: 1;
  height: 32px;
  background: var(--sim-surface);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}
.res-bar-fill {
  height: 100%;
  border-radius: 6px;
  width: 0%;
  transition: width 1.2s cubic-bezier(0.22,1,0.36,1);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 10px;
  min-width: 0;
}
.res-bar-amount {
  font-size: 11px;
  font-weight: 800;
  color: white;
  white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.res-bar-savings {
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  width: 80px;
}
.res-bar-savings.savings-over {
  color: var(--sim-danger-light);
}
.res-bar-savings.savings-under {
  color: var(--sim-emerald-light);
}

/* ================================================================
   ENERGY DETAIL TABLE (shared Step 3 + Step 4)
   ================================================================ */
.sim-energy-table,
.res-energy-table {
  width: 100%;
  margin-bottom: 20px;
}

/* Scroll wrapper for tables on mobile */
.res-table-scroll-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.res-et-header, .res-et-row {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.7fr 0.7fr 0.9fr 0.7fr 0.8fr;
  gap: 4px;
  padding: 10px 12px;
  align-items: center;
  min-width: 600px;
}
.res-et-header {
  background: var(--sim-surface);
  border-radius: var(--sim-radius-sm) var(--sim-radius-sm) 0 0;
  font-size: 10px;
  font-weight: 700;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.res-et-row {
  border-bottom: 1px solid var(--sim-border);
  font-size: 12px;
  color: var(--sim-text-secondary);
  transition: background 0.2s;
}
.res-et-row:hover {
  background: rgba(196,138,40,0.04);
}
.res-et-row.et-winner {
  background: rgba(58,158,110,0.06);
  border: 1px solid rgba(58,158,110,0.15);
  border-radius: var(--sim-radius-sm);
  margin-bottom: 4px;
}
.res-et-row.et-winner .et-source {
  color: var(--sim-emerald-light);
  font-weight: 700;
}
.et-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 100px;
  background: var(--sim-emerald);
  color: white;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 1px;
  margin-right: 6px;
  vertical-align: middle;
}
.et-diff-pos { color: var(--sim-danger-light); font-weight: 700; }
.et-diff-neg { color: var(--sim-emerald-light); font-weight: 700; }

/* ================================================================
   FEEDBACK TOAST
   ================================================================ */
.sim-feedback {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  padding: 10px 24px;
  border-radius: 100px;
  background: var(--sim-emerald);
  color: white;
  font-weight: 600;
  font-size: 14px;
  opacity: 0;
  transition: all 0.4s ease;
  z-index: 200;
  pointer-events: none;
  box-shadow: 0 4px 20px rgba(58,158,110,0.4);
  font-family: 'DM Sans', sans-serif;
}
.sim-feedback.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ================================================================
   BUTTONS
   ================================================================ */
.sim-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 36px;
  border: none;
  border-radius: var(--sim-radius-xl);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--sim-transition);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  line-height: 1.4;
}
.sim-btn svg { width: 18px; height: 18px; }
.sim-btn-primary {
  background: linear-gradient(135deg, var(--sim-amber), var(--sim-copper));
  color: var(--sim-bg-deep);
  box-shadow: 0 4px 20px rgba(212,160,67,0.3);
  min-width: 200px;
  font-size: 15px;
}
.sim-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(212,160,67,0.45);
  color: var(--sim-bg-deep);
}
.sim-btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 2px 12px rgba(212,160,67,0.3);
}
.sim-btn-primary::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: inherit;
  border: 2px solid var(--sim-amber);
  opacity: 0;
  animation: simBtnPulse 2s ease-in-out infinite 1s;
}
@keyframes simBtnPulse {
  0%,100% { opacity:0; transform:scale(1); }
  50%     { opacity:.3; transform:scale(1.04); }
}

.sim-btn-results {
  background: linear-gradient(135deg, var(--sim-emerald), #2d8a5e);
  box-shadow: 0 4px 20px rgba(58,158,110,0.3);
}
.sim-btn-results:hover {
  box-shadow: 0 8px 30px rgba(58,158,110,0.45);
}
.sim-btn-results:active {
  transform: translateY(0);
  box-shadow: 0 2px 12px rgba(58,158,110,0.3);
}
.sim-btn-results::after {
  border-color: var(--sim-emerald);
}

.sim-btn-back {
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  color: var(--sim-text-secondary);
  padding: 14px 24px;
  box-shadow: var(--sim-shadow-sm);
}
.sim-btn-back:hover {
  background: var(--sim-bg-card-hover);
  color: var(--sim-text-primary);
  box-shadow: var(--sim-shadow-md);
}
.sim-btn-back:active {
  transform: translateY(0);
  box-shadow: var(--sim-shadow-sm);
}
.sim-btn-cta {
  background: linear-gradient(135deg, var(--sim-emerald), #2d8a5e);
  color: white;
  box-shadow: 0 4px 24px rgba(58,158,110,0.3);
  padding: 20px 50px;
  font-size: 17px;
  border-radius: var(--sim-radius-xl);
}
.sim-btn-cta:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 40px rgba(58,158,110,0.45);
  color: white;
}
.sim-btn-cta:active {
  transform: translateY(0);
  box-shadow: 0 2px 16px rgba(58,158,110,0.3);
}

/* ================================================================
   RESULTS PAGE — GENERIC SECTION
   ================================================================ */
.res-section {
  width: 100%;
  margin-bottom: 48px;
  padding-bottom: 8px;
}
.res-section + .res-section {
  border-top: 1px solid var(--sim-border);
  padding-top: 40px;
}
.res-section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  font-weight: 800;
  color: var(--sim-text-primary);
  text-align: center;
  margin-bottom: 8px;
}
.res-section-sub {
  font-size: 13px;
  color: var(--sim-text-muted);
  text-align: center;
  margin-bottom: 20px;
  line-height: 1.5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}
.res-section-sub strong {
  color: var(--sim-amber-light);
}

/* ================================================================
   SECTION A: ENERGY PROFILE
   ================================================================ */
.res-profile-box {
  padding: 28px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-lg);
  width: 100%;
  box-shadow: var(--sim-shadow-card);
}
.res-profile-main {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 20px;
}
.res-profile-kwh-wrap { text-align: center; flex-shrink: 0; }
.res-profile-kwh {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 900;
  color: var(--sim-amber);
  line-height: 1;
}
.res-profile-kwh-label {
  font-size: 12px;
  color: var(--sim-text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.res-profile-meter {
  flex: 1;
}
.res-profile-meter-bar {
  height: 16px;
  border-radius: 8px;
  background: var(--sim-surface);
  overflow: hidden;
  position: relative;
  width: 0%;
  transition: width 1.5s cubic-bezier(0.22,1,0.36,1);
  background: linear-gradient(90deg, #3a9e6e, #d4a043);
}
.res-profile-meter-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--sim-text-muted);
  margin-top: 4px;
}
.res-profile-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--sim-border);
}
.res-profile-detail { text-align: center; }
.res-profile-detail-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--sim-amber-light);
  line-height: 1;
  display: block;
  margin-bottom: 4px;
}
.res-profile-detail-lbl {
  font-size: 10px;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ================================================================
   SECTION B: SAVINGS HERO
   ================================================================ */
.res-savings-hero {
  text-align: center;
  padding: 32px 24px;
  background: linear-gradient(135deg, rgba(58,158,110,0.08), rgba(78,196,138,0.05));
  border: 1px solid rgba(58,158,110,0.2);
  border-radius: var(--sim-radius-lg);
  margin-bottom: 20px;
  width: 100%;
  animation: savingsGlow 3s ease-in-out infinite;
  box-shadow: var(--sim-shadow-card);
}
@keyframes savingsGlow {
  0%,100% { box-shadow: 0 0 20px rgba(58,158,110,0.1); }
  50%     { box-shadow: 0 0 40px rgba(58,158,110,0.2); }
}
.res-savings-hero-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.res-savings-hero-amount {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.2rem, 6vw, 3.5rem);
  font-weight: 900;
  color: var(--sim-emerald-light);
  line-height: 1;
  margin-bottom: 6px;
}
.res-savings-hero-sub {
  font-size: 13px;
  color: var(--sim-text-secondary);
}

.res-savings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: 100%;
}
.res-savings-item {
  padding: 14px 12px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: var(--sim-shadow-sm);
}
.res-savings-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--sim-shadow-md);
}
.res-savings-item-label {
  font-size: 10px;
  color: var(--sim-text-muted);
  font-weight: 600;
  margin-bottom: 4px;
}
.res-savings-item-val {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-weight: 800;
}
.res-savings-item.positive .res-savings-item-val {
  color: var(--sim-emerald-light);
}
.res-savings-item.negative .res-savings-item-val {
  color: var(--sim-orange-warn);
}

/* ================================================================
   SECTION C: WOOD DETAIL TABLE (Step 4)
   ================================================================ */
.res-humidity-compare {
  width: 100%;
  padding: 20px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-lg);
  margin-bottom: 20px;
  box-shadow: var(--sim-shadow-card);
}
.res-humidity-compare-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--sim-text-primary);
  text-align: center;
  margin-bottom: 14px;
}
.res-humidity-compare-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.res-hc-item {
  display: flex;
  align-items: center;
  gap: 12px;
}
.res-hc-item.highlight .res-hc-label {
  color: var(--sim-emerald-light);
}
.res-hc-label {
  width: 120px;
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--sim-text-secondary);
  text-align: right;
}
.res-hc-bar {
  flex: 1;
  height: 24px;
  background: var(--sim-surface);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(44,36,24,0.08);
}
.res-hc-fill {
  height: 100%;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  color: white;
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
  min-width: 40px;
}
.hc-bad  { background: linear-gradient(90deg, #c44a3a, #e06050); }
.hc-great { background: linear-gradient(90deg, #3a9e6e, #4ec48a); }

.res-humidity-compare-legend {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 12px;
  font-size: 11px;
}
.hc-legend-bad  { color: var(--sim-danger-light); }
.hc-legend-great { color: var(--sim-emerald-light); }

/* Wood detail comparison table */
.res-wood-detail-table {
  width: 100%;
  min-width: 500px;
}
.res-wd-header, .res-wd-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 0.8fr;
  gap: 4px;
  padding: 10px 14px;
  align-items: center;
}
.res-wd-header {
  background: var(--sim-surface);
  border-radius: var(--sim-radius-sm) var(--sim-radius-sm) 0 0;
  font-size: 10px;
  font-weight: 700;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.res-wd-row {
  border-bottom: 1px solid var(--sim-border);
  font-size: 13px;
  color: var(--sim-text-secondary);
  transition: background 0.2s;
}
.res-wd-row:hover {
  background: rgba(196,138,40,0.04);
}
.res-wd-row.wd-total-row {
  background: rgba(58,158,110,0.06);
  border: 1px solid rgba(58,158,110,0.15);
  border-radius: 0 0 var(--sim-radius-sm) var(--sim-radius-sm);
  font-weight: 700;
  font-size: 14px;
}
.wd-palette {
  color: var(--sim-emerald-light);
  font-weight: 700;
}
.diff-great  { color: var(--sim-emerald-light); font-weight: 700; font-size: 12px; }
.diff-warn   { color: var(--sim-orange-warn); font-weight: 700; font-size: 12px; }
.diff-neutral { color: var(--sim-text-secondary); font-weight: 700; font-size: 12px; }

/* ================================================================
   SECTION E: 10-YEAR PROJECTION
   ================================================================ */
.res-proj-chart {
  width: 100%;
  margin-bottom: 16px;
}
.res-proj-bars {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.res-proj-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.res-proj-bar-row.proj-winner .res-proj-bar-label {
  color: var(--sim-emerald-light);
  font-weight: 700;
}
.res-proj-bar-label {
  width: 180px;
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--sim-text-secondary);
  text-align: right;
}
/* Short/full label toggling for responsive */
.res-proj-label-short {
  display: none;
}
.res-proj-bar-track {
  flex: 1;
  height: 36px;
  background: var(--sim-surface);
  border-radius: 8px;
  overflow: hidden;
}
.res-proj-bar-fill {
  height: 100%;
  border-radius: 8px;
  width: 0%;
  transition: width 1.5s cubic-bezier(0.22,1,0.36,1);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 12px;
  font-size: 12px;
  font-weight: 800;
  color: white;
  text-shadow: 0 1px 3px rgba(0,0,0,0.3);
  white-space: nowrap;
}

.res-proj-total-savings {
  text-align: center;
  padding: 20px;
  background: rgba(58,158,110,0.08);
  border: 1px solid rgba(58,158,110,0.15);
  border-radius: var(--sim-radius-md);
  font-size: 14px;
  color: var(--sim-text-secondary);
  box-shadow: var(--sim-shadow-sm);
}
.res-proj-total-savings strong {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: var(--sim-emerald-light);
  display: block;
  margin: 6px 0;
}

/* ================================================================
   SECTION F: REAL PRICE TABLE (Palette PROMO)
   ================================================================ */
.res-real-table {
  width: 100%;
  min-width: 480px;
  margin-bottom: 24px;
}
.res-rt-header, .res-rt-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr 0.8fr;
  gap: 4px;
  padding: 10px 14px;
  align-items: center;
}
.res-rt-header {
  background: var(--sim-surface);
  border-radius: var(--sim-radius-sm) var(--sim-radius-sm) 0 0;
  font-size: 10px;
  font-weight: 700;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.res-rt-row {
  border-bottom: 1px solid var(--sim-border);
  font-size: 13px;
  color: var(--sim-text-secondary);
  transition: background 0.2s;
}
.res-rt-row:hover {
  background: rgba(196,138,40,0.04);
}
.res-rt-row.rt-selected {
  background: rgba(58,158,110,0.06);
  border: 1px solid rgba(58,158,110,0.2);
  border-radius: var(--sim-radius-sm);
}
.rt-strikethrough {
  text-decoration: line-through;
  color: var(--sim-text-muted);
}
.rt-eco-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 100px;
  background: rgba(58,158,110,0.15);
  color: var(--sim-emerald-light);
  font-size: 11px;
  font-weight: 700;
}

/* Humide comparison table */
.res-humide-compare-table {
  width: 100%;
}
.res-humide-compare-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--sim-text-muted);
  text-align: center;
  margin-bottom: 10px;
}
.res-humide-table {
  width: 100%;
  min-width: 300px;
}
.res-ht-header, .res-ht-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 4px;
  padding: 8px 14px;
  align-items: center;
}
.res-ht-header {
  background: rgba(139,106,66,0.1);
  border-radius: var(--sim-radius-sm) var(--sim-radius-sm) 0 0;
  font-size: 10px;
  font-weight: 700;
  color: var(--sim-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.res-ht-row {
  border-bottom: 1px solid var(--sim-border);
  font-size: 12px;
  color: var(--sim-text-muted);
}

/* ================================================================
   SECTION G: WHY PALETTE
   ================================================================ */
.res-why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  width: 100%;
  margin-bottom: 24px;
}
.res-why-card {
  padding: 20px 16px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-lg);
  text-align: center;
  transition: all var(--sim-transition);
  box-shadow: var(--sim-shadow-card);
}
.res-why-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--sim-shadow-lg);
  border-color: rgba(58,158,110,0.3);
}
.res-why-icon {
  width: 40px; height: 40px;
  margin: 0 auto 10px;
}
.res-why-icon svg { width: 100%; height: 100%; }
.res-why-title {
  font-weight: 800;
  font-size: 14px;
  color: var(--sim-text-primary);
  margin-bottom: 6px;
}
.res-why-desc {
  font-size: 12px;
  color: var(--sim-text-muted);
  line-height: 1.5;
}

/* ================================================================
   SECTION H: SOCIAL PROOF + CTA
   ================================================================ */
.res-social {
  padding: 20px 24px;
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-lg);
  margin-bottom: 16px;
  width: 100%;
  box-shadow: var(--sim-shadow-card);
}
.res-social-stars {
  font-size: 20px;
  color: var(--sim-gold-bright);
  margin-bottom: 8px;
}
.res-social-text {
  font-size: 14px;
  color: var(--sim-text-secondary);
  line-height: 1.6;
  font-style: italic;
}
.res-social-text strong {
  color: var(--sim-emerald-light);
  font-style: normal;
}

.res-cta {
  text-align: center;
  padding: 32px 24px;
  background: linear-gradient(135deg, rgba(58,158,110,0.08), rgba(78,196,138,0.04));
  border: 1px solid rgba(58,158,110,0.2);
  border-radius: var(--sim-radius-lg);
  margin-bottom: 20px;
  width: 100%;
  box-shadow: var(--sim-shadow-card);
}
.res-cta h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--sim-text-primary);
  margin-bottom: 8px;
}
.res-cta p {
  font-size: 14px;
  color: var(--sim-text-secondary);
  margin-bottom: 20px;
  line-height: 1.5;
}

/* Sources section */
.res-sources-content {
  background: var(--sim-bg-card);
  border: 1px solid var(--sim-border);
  border-radius: var(--sim-radius-md);
  padding: 20px;
  box-shadow: var(--sim-shadow-sm);
}
.res-sources-intro {
  font-size: 13px;
  color: var(--sim-text-secondary);
  margin-bottom: 16px;
  line-height: 1.6;
}
.res-sources-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
@media (max-width: 600px) { .res-sources-grid { grid-template-columns: 1fr; } }
.res-source-item {
  padding: 12px;
  background: rgba(44,36,24,0.02);
  border-radius: var(--sim-radius-sm);
  border-left: 3px solid var(--sim-amber);
}
.res-source-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--sim-text-primary);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.res-source-detail {
  font-size: 12px;
  color: var(--sim-text-muted);
  line-height: 1.6;
}
.res-source-detail strong {
  color: var(--sim-text-secondary);
  font-weight: 600;
}

.res-restart {
  text-align: center;
  width: 100%;
  display: flex;
  justify-content: center;
}

/* ================================================================
   STICKY CTA BAR (bottom of report step)
   ================================================================ */
.sim-sticky-cta {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  display: none; /* shown by JS when step 4 active */
  justify-content: center;
  align-items: center;
  padding: 12px 20px;
  background: var(--sim-bg-deep);
  border-top: 1px solid var(--sim-border);
  box-shadow: 0 -4px 20px rgba(44,36,24,0.08);
}
.sim-sticky-cta.visible {
  display: flex;
}
.sim-sticky-cta-btn {
  max-width: 500px;
  width: 100%;
  text-align: center;
  padding: 16px 32px !important;
  font-size: 15px !important;
}

/* ================================================================
   RESPONSIVE — TABLET (768px - 1024px)
   ================================================================ */
@media (max-width: 1024px) {
  .sim-step-inner {
    max-width: 100%;
  }
  .res-bar-label {
    width: 110px;
  }
  .res-proj-bar-label {
    width: 150px;
  }

  /* Logo bar tablet */
  .sim-logo-bar {
    padding: 6px 16px;
  }
  .sim-logo-img {
    height: 28px;
  }

  /* Slight progress bar reduction */
  .sim-prog-dot {
    width: 30px;
    height: 30px;
    font-size: 11px;
  }
  .sim-prog-line {
    width: 36px;
  }
}

/* ================================================================
   RESPONSIVE — MOBILE (<768px)
   Major layout overhaul: app-like experience with fixed bottom nav
   ================================================================ */
@media (max-width: 768px) {

  /* ---------------------------------------------------------------
     LOGO BAR — compact on mobile
     --------------------------------------------------------------- */
  .sim-logo-bar {
    padding: 6px 12px;
  }
  .sim-logo-img {
    height: 24px;
  }
  .sim-logo-text {
    font-size: 12px;
  }
  .sim-back-home {
    font-size: 10px;
    padding: 4px 10px;
    gap: 4px;
  }
  .sim-back-home svg {
    width: 12px;
    height: 12px;
  }

  /* ---------------------------------------------------------------
     PROGRESS BAR — smaller dots, shorter lines
     --------------------------------------------------------------- */
  .sim-topbar {
    top: 41px;
    padding: 8px 12px 6px;
  }
  .sim-prog-dot {
    width: 28px;
    height: 28px;
    font-size: 10px;
  }
  .sim-prog-dot.done::after {
    font-size: 11px;
  }
  .sim-prog-line {
    width: 16px;
  }
  .sim-prog-labels {
    top: 78px;
    gap: 12px;
    font-size: 8px;
    letter-spacing: 0.8px;
  }
  .sim-prog-labels span {
    width: 50px;
  }

  /* ---------------------------------------------------------------
     STEP LAYOUT — flexbox column, nav always at bottom
     .sim-step-scroll: flex:1, scrolls, accounts for logo+progress
     .sim-nav: sits at bottom, never scrolls
     --------------------------------------------------------------- */
  .sim-step-scroll {
    /* top padding = logo bar (~41px) + progress bar (~36px) + labels (~20px) + gap */
    padding: 100px 14px 8px;
  }
  .sim-step-inner {
    max-width: 100%;
    padding: 0 2px;
  }

  /* ---------------------------------------------------------------
     NAVIGATION BAR — moved to body by JS on mobile, position:fixed
     --------------------------------------------------------------- */
  .sim-mobile-nav,
  .sim-nav {
    position: fixed !important;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 95;
    flex-direction: column;
    align-items: stretch;
    padding: 10px 16px;
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    background: var(--sim-bg-deep);
    border-top: 2px solid var(--sim-border);
    box-shadow: 0 -6px 24px rgba(44,36,24,0.15);
    gap: 8px;
  }
  /* Space at bottom of scroll so content not hidden behind fixed nav */
  .sim-step-scroll {
    padding-bottom: 130px !important;
  }
  /* In results step, nav stays inline */
  .sim-step.results-step .sim-nav {
    position: static !important;
    border-top: none;
    box-shadow: none;
    background: none;
    padding: 16px 0;
  }
  .sim-nav .sim-btn {
    width: 100%;
    min-width: unset;
    justify-content: center;
    padding: 16px 20px;
    font-size: 15px;
    min-height: 48px;
    border-radius: var(--sim-radius-md);
  }
  .sim-nav .sim-btn-primary {
    order: -1;
  }
  .sim-nav .sim-btn-back {
    padding: 12px 20px;
    font-size: 14px;
  }

  /* ---------------------------------------------------------------
     STEP HEADER — reduced spacing
     --------------------------------------------------------------- */
  .sim-header {
    margin-bottom: 10px;
  }
  .sim-header-num {
    font-size: 9px;
    padding: 3px 12px;
    margin-bottom: 6px;
  }
  .sim-header h2 {
    font-size: clamp(1.15rem, 4.5vw, 1.5rem);
    margin-bottom: 4px;
  }
  .sim-header p {
    font-size: clamp(0.78rem, 2.5vw, 0.88rem);
  }

  /* ---------------------------------------------------------------
     GUIDE / ASTUCE — compact
     --------------------------------------------------------------- */
  .sim-guide {
    font-size: 12px;
    padding: 10px 12px;
    margin-bottom: 12px;
    gap: 10px;
  }
  .sim-guide-icon {
    width: 28px;
    height: 28px;
    font-size: 14px;
  }
  .sim-astuce {
    font-size: 11px;
    padding: 10px 12px;
    margin-top: 12px;
  }
  .sim-descriptif {
    padding: 12px 14px;
    margin-top: 10px;
    font-size: 12px;
  }

  /* ---------------------------------------------------------------
     FIELD BLOCKS — tighter
     --------------------------------------------------------------- */
  .sim-field-block {
    margin-bottom: 10px;
  }
  .sim-field-label {
    font-size: 10px;
    letter-spacing: 1.2px;
  }

  /* ---------------------------------------------------------------
     SURFACE SLIDER — bigger thumb for touch
     --------------------------------------------------------------- */
  .sim-slider-number {
    font-size: clamp(1.8rem, 7vw, 2.4rem);
  }
  #sim-root input[type="range"] {
    height: 10px;
  }
  #sim-root input[type="range"]::-webkit-slider-thumb {
    width: 44px;
    height: 44px;
    border-width: 4px;
  }
  #sim-root input[type="range"]::-moz-range-thumb {
    width: 44px;
    height: 44px;
    border-width: 4px;
  }
  .sim-slider-hints {
    font-size: 11px;
  }

  /* ---------------------------------------------------------------
     INSULATION CARDS — 2x2 grid, full-width
     --------------------------------------------------------------- */
  .sim-insul-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .sim-insul-card {
    padding: 12px 8px 10px;
    min-height: 44px;
  }
  .sim-insul-emoji {
    font-size: 20px;
  }
  .sim-insul-name {
    font-size: 12px;
  }
  .sim-insul-date {
    font-size: 9px;
  }
  .sim-insul-desc {
    font-size: 9px;
    min-height: 20px;
  }

  /* ---------------------------------------------------------------
     REGION CARDS — 2 per row (+ 1 centered)
     --------------------------------------------------------------- */
  .sim-region-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .sim-region-card {
    padding: 10px 6px 8px;
    min-height: 44px;
  }
  .sim-region-name {
    font-size: 12px;
  }
  .sim-region-desc {
    font-size: 8px;
    min-height: 18px;
  }
  .sim-region-months {
    font-size: 9px;
  }

  /* ---------------------------------------------------------------
     SIZE PILLS — stack vertically, full width
     --------------------------------------------------------------- */
  .sim-size-pills {
    flex-direction: column;
    gap: 8px;
  }
  .sim-size-pill {
    padding: 14px 12px;
    flex-direction: row;
    justify-content: center;
    gap: 12px;
    min-height: 44px;
  }
  .sim-pill-val {
    font-size: 1.1rem;
  }
  .sim-pill-label {
    font-size: 12px;
  }

  /* ---------------------------------------------------------------
     BOTTOM ROW (3 cards) — stack vertically
     --------------------------------------------------------------- */
  .sim-bottom-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .sim-bottom-card {
    padding: 14px 12px;
  }
  .sim-bottom-card-value {
    font-size: clamp(0.95rem, 4vw, 1.2rem);
  }
  .sim-bottom-card-label {
    font-size: 10px;
  }
  .sim-bottom-card-sub {
    font-size: 11px;
  }
  .sim-bottom-savings {
    font-size: 10px;
  }
  .sim-bottom-savings strong {
    font-size: 12px;
  }

  /* ---------------------------------------------------------------
     LIVE PREVIEW — compact
     --------------------------------------------------------------- */
  .sim-live-preview {
    padding: 12px 14px;
    gap: 10px;
    margin-top: 8px;
  }
  .sim-live-preview-icon {
    width: 28px;
    height: 28px;
  }
  .sim-live-preview-value {
    font-size: 1.2rem;
  }
  .sim-live-preview-label {
    font-size: 10px;
  }

  /* ---------------------------------------------------------------
     WOOD COMPARISON (Step 2) — stack vertically, humide on top
     --------------------------------------------------------------- */
  .sim-wood-compare {
    flex-direction: column;
    gap: 12px;
  }
  .sim-wc-vs {
    padding: 6px 0;
  }
  .sim-wc-vs-circle {
    width: 36px;
    height: 36px;
    font-size: 11px;
  }
  .sim-wc-card {
    padding: 16px 14px 14px;
  }
  .sim-wc-name {
    font-size: 14px;
  }
  .sim-wc-icon {
    font-size: 24px;
  }
  .sim-wc-subtitle {
    font-size: 9px;
  }
  .sim-wc-stat-label {
    font-size: 9px;
  }
  .sim-wc-row {
    padding: 6px 0;
  }
  .sim-wc-row-label {
    font-size: 10px;
  }
  .sim-wc-row-val {
    font-size: 13px;
  }
  .sim-wc-total-val {
    font-size: 1.3rem;
  }
  .sim-wc-warning,
  .sim-wc-success {
    font-size: 10px;
    padding: 8px 10px;
  }
  .sim-gauge-bar {
    height: 20px;
  }
  .sim-gauge-fill {
    font-size: 10px;
  }

  /* Wood savings banner */
  .sim-wood-savings {
    flex-direction: column;
    text-align: center;
    padding: 12px;
    gap: 8px;
  }
  .sim-wood-savings-val {
    font-size: 1.3rem;
  }
  .sim-wood-savings-label {
    font-size: 10px;
  }

  /* ---------------------------------------------------------------
     ENERGY SECTION (Step 3)
     --------------------------------------------------------------- */
  .sim-energy-section {
    margin-bottom: 16px;
  }
  .sim-energy-section-title {
    font-size: clamp(1rem, 3.5vw, 1.25rem);
    margin-bottom: 4px;
  }
  .sim-energy-section-sub {
    font-size: 11px;
    margin-bottom: 12px;
  }
  .sim-energy-savings-hero {
    padding: 14px;
    flex-direction: column;
    text-align: center;
    gap: 8px;
    margin-bottom: 12px;
  }
  .sim-energy-savings-icon {
    width: 32px;
    height: 32px;
  }
  .sim-energy-savings-val {
    font-size: 1.5rem;
  }
  .sim-energy-savings-label {
    font-size: 10px;
  }

  /* ---------------------------------------------------------------
     BAR CHART — show short labels, hide full
     --------------------------------------------------------------- */
  .res-bar-label-full {
    display: none;
  }
  .res-bar-label-short {
    display: inline;
  }
  .res-bar-label {
    width: 70px;
    font-size: 11px;
  }
  .res-bar-track {
    height: 28px;
  }
  .res-bar-amount {
    font-size: 10px;
  }
  .res-bar-savings {
    width: 65px;
    font-size: 10px;
  }

  /* Projection labels: show short, hide full */
  .res-proj-label-full {
    display: none;
  }
  .res-proj-label-short {
    display: inline;
  }
  .res-proj-bar-label {
    width: 85px;
    font-size: 11px;
  }
  .res-proj-bar-track {
    height: 30px;
  }
  .res-proj-bar-fill {
    font-size: 11px;
    padding-right: 8px;
  }

  /* ---------------------------------------------------------------
     ENERGY TABLE — keep scrollable via wrapper
     --------------------------------------------------------------- */
  .res-et-header, .res-et-row {
    min-width: 600px;
  }

  /* ---------------------------------------------------------------
     TOOLTIP — mobile friendly positioning
     --------------------------------------------------------------- */
  .sim-tooltip-popup {
    width: 240px;
    font-size: 11px;
    padding: 10px 12px;
  }

  /* ---------------------------------------------------------------
     BUTTONS — all touch targets min 44px
     --------------------------------------------------------------- */
  .sim-btn {
    width: 100%;
    min-width: unset;
    justify-content: center;
    min-height: 44px;
  }
  .sim-btn-cta {
    padding: 16px 24px;
    font-size: 15px;
    min-height: 52px;
  }

  /* ---------------------------------------------------------------
     RESULTS STEP (Step 4) — stack everything
     --------------------------------------------------------------- */
  .sim-step.results-step {
    padding-top: 20px;
    padding-bottom: 100px; /* room for sticky CTA */
  }
  .res-main-header {
    margin-top: 40px;
  }

  /* Sections spacing */
  .res-section {
    margin-bottom: 32px;
  }
  .res-section + .res-section {
    padding-top: 28px;
  }
  .res-section-title {
    font-size: clamp(1.1rem, 4vw, 1.4rem);
    margin-bottom: 6px;
  }
  .res-section-sub {
    font-size: 12px;
    margin-bottom: 14px;
  }

  /* Profile box */
  .res-profile-box {
    padding: 20px 14px;
  }
  .res-profile-main {
    flex-direction: column;
    text-align: center;
    gap: 16px;
  }
  .res-profile-meter {
    width: 100%;
  }
  .res-profile-kwh {
    font-size: clamp(1.8rem, 7vw, 2.5rem);
  }
  .res-profile-details {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  /* Savings hero */
  .res-savings-hero {
    padding: 24px 16px;
  }
  .res-savings-hero-amount {
    font-size: clamp(2rem, 7vw, 3rem);
  }
  .res-savings-hero-sub {
    font-size: 12px;
  }

  /* Savings grid */
  .res-savings-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .res-savings-item {
    padding: 12px 10px;
  }
  .res-savings-item-val {
    font-size: 1rem;
  }

  /* Humidity compare */
  .res-hc-label {
    width: 80px;
    font-size: 10px;
  }
  .res-hc-bar {
    height: 22px;
  }

  /* Why grid — single column */
  .res-why-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .res-why-card {
    padding: 16px 14px;
  }
  .res-why-title {
    font-size: 13px;
  }
  .res-why-desc {
    font-size: 11px;
  }

  /* Social proof */
  .res-social {
    padding: 16px;
  }
  .res-social-text {
    font-size: 13px;
  }
  .res-social-stars {
    font-size: 18px;
  }

  /* CTA section */
  .res-cta {
    padding: 24px 16px;
  }
  .res-cta h3 {
    font-size: 1.3rem;
  }
  .res-cta p {
    font-size: 13px;
    margin-bottom: 16px;
  }

  /* Projection savings */
  .res-proj-total-savings {
    padding: 16px 12px;
    font-size: 13px;
  }
  .res-proj-total-savings strong {
    font-size: 1.5rem;
  }

  /* Sources grid — single column on mobile */
  .res-sources-grid {
    grid-template-columns: 1fr;
  }
  .res-sources-content {
    padding: 14px;
  }
  .res-sources-intro {
    font-size: 12px;
  }

  /* ---------------------------------------------------------------
     STICKY CTA BAR — full width, no offset needed (widgets hidden)
     --------------------------------------------------------------- */
  .sim-sticky-cta {
    bottom: 0;
    padding: 12px 16px;
    padding-bottom: max(12px, env(safe-area-inset-bottom));
  }
  .sim-sticky-cta-btn {
    max-width: 100%;
    padding: 16px 24px !important;
    font-size: 15px !important;
    min-height: 52px;
  }

  /* ---------------------------------------------------------------
     FEEDBACK TOAST — above nav bar
     --------------------------------------------------------------- */
  .sim-feedback {
    bottom: 120px;
    font-size: 13px;
    padding: 8px 20px;
  }

  /* ---------------------------------------------------------------
     CONFETTI — smaller on mobile
     --------------------------------------------------------------- */
  .sim-confetti {
    max-width: 8px;
    max-height: 8px;
  }
}

/* ================================================================
   RESPONSIVE — SMALL MOBILE (<480px)
   Ultra-compact for small devices
   ================================================================ */
@media (max-width: 480px) {

  /* Scroll area — tighter padding, accounts for smaller bars */
  .sim-step-scroll {
    padding: 92px 10px 6px;
  }
  .sim-step-inner {
    padding: 0;
  }

  /* Logo bar — minimal */
  .sim-logo-bar {
    padding: 4px 10px;
  }
  .sim-logo-img {
    height: 20px;
  }
  .sim-logo-text {
    font-size: 11px;
  }
  .sim-back-home {
    font-size: 9px;
    padding: 3px 8px;
  }

  /* Progress bar — ultra compact */
  .sim-topbar {
    top: 37px;
    padding: 6px 8px 4px;
  }
  .sim-prog-dot {
    width: 24px;
    height: 24px;
    font-size: 9px;
  }
  .sim-prog-dot.done::after {
    font-size: 10px;
  }
  .sim-prog-line {
    width: 12px;
  }
  .sim-prog-labels {
    top: 68px;
    gap: 6px;
    font-size: 7px;
    letter-spacing: 0.5px;
  }
  .sim-prog-labels span {
    width: 44px;
  }

  /* Step header — tighter */
  .sim-header {
    margin-bottom: 8px;
  }
  .sim-header-num {
    font-size: 8px;
    padding: 2px 10px;
    margin-bottom: 4px;
  }
  .sim-header h2 {
    font-size: clamp(1.1rem, 5vw, 1.4rem);
  }
  .sim-header p {
    font-size: 0.8rem;
  }

  /* Guide / astuce — tighter */
  .sim-guide {
    padding: 8px 10px;
    font-size: 11px;
    gap: 8px;
    margin-bottom: 10px;
  }
  .sim-guide-icon {
    width: 24px;
    height: 24px;
    font-size: 12px;
  }
  .sim-astuce {
    padding: 8px 10px;
    font-size: 10px;
    margin-top: 8px;
  }
  .sim-descriptif {
    padding: 10px 12px;
    font-size: 11px;
  }

  /* Nav bar — minimal padding */
  .sim-nav {
    padding: 10px 12px;
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    gap: 6px;
  }
  .sim-nav .sim-btn {
    padding: 14px 16px;
    font-size: 14px;
  }
  .sim-nav .sim-btn-back {
    padding: 10px 16px;
    font-size: 13px;
  }

  /* Buttons */
  .sim-btn {
    padding: 14px 20px;
    font-size: 13px;
    min-height: 44px;
  }
  .sim-btn-cta {
    padding: 14px 20px;
    font-size: 14px;
    min-height: 48px;
  }

  /* Slider — still big thumb for touch */
  .sim-slider-number {
    font-size: clamp(1.6rem, 8vw, 2rem);
  }

  /* Insulation / region: 2 columns */
  .sim-insul-cards {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
  .sim-insul-card {
    padding: 10px 6px 8px;
  }
  .sim-insul-emoji {
    font-size: 18px;
  }
  .sim-insul-name {
    font-size: 11px;
  }
  .sim-insul-desc {
    font-size: 8px;
    min-height: 16px;
  }
  .sim-region-cards {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
  .sim-region-card {
    padding: 8px 4px 6px;
  }
  .sim-region-name {
    font-size: 11px;
  }
  .sim-region-desc {
    font-size: 7px;
    min-height: 14px;
  }

  /* Size pills */
  .sim-size-pill {
    padding: 12px 10px;
  }
  .sim-pill-val {
    font-size: 1rem;
  }
  .sim-pill-label {
    font-size: 11px;
  }
  .sim-pill-popular {
    font-size: 8px;
    padding: 1px 8px;
  }

  /* Bottom row */
  .sim-bottom-card {
    padding: 12px 10px;
  }
  .sim-bottom-card-value {
    font-size: clamp(0.85rem, 4vw, 1.05rem);
  }
  .sim-bottom-card-label {
    font-size: 9px;
    letter-spacing: 0.5px;
  }
  .sim-bottom-card-sub {
    font-size: 10px;
  }
  .sim-bottom-savings {
    font-size: 9px;
  }
  .sim-bottom-savings strong {
    font-size: 10px;
  }

  /* Wood comparison */
  .sim-wc-card {
    padding: 14px 10px 12px;
  }
  .sim-wc-name {
    font-size: 13px;
  }
  .sim-wc-icon {
    font-size: 22px;
  }
  .sim-wc-total-val {
    font-size: 1.2rem;
  }
  .sim-wc-row-label {
    font-size: 9px;
  }
  .sim-wc-row-val {
    font-size: 12px;
  }
  .sim-wc-warning,
  .sim-wc-success {
    font-size: 9px;
  }

  /* Wood savings */
  .sim-wood-savings {
    padding: 10px;
  }
  .sim-wood-savings-val {
    font-size: 1.15rem;
  }

  /* Energy savings */
  .sim-energy-savings-hero {
    padding: 12px;
  }
  .sim-energy-savings-val {
    font-size: 1.3rem;
  }

  /* Bar charts */
  .res-bar-label {
    width: 55px;
    font-size: 10px;
  }
  .res-bar-track {
    height: 26px;
  }
  .res-bar-amount {
    font-size: 9px;
  }
  .res-bar-savings {
    display: none;
  }

  /* Projection bars */
  .res-proj-bar-label {
    width: 65px;
    font-size: 9px;
  }
  .res-proj-bar-track {
    height: 28px;
  }
  .res-proj-bar-fill {
    font-size: 10px;
    padding-right: 6px;
  }

  /* Results step */
  .sim-step.results-step {
    padding-top: 16px;
    padding-bottom: 90px;
  }
  .res-main-header {
    margin-top: 30px;
  }

  /* Section spacing */
  .res-section {
    margin-bottom: 24px;
  }
  .res-section + .res-section {
    padding-top: 20px;
  }
  .res-section-title {
    font-size: clamp(1rem, 4.5vw, 1.25rem);
  }
  .res-section-sub {
    font-size: 11px;
    margin-bottom: 10px;
  }

  /* Profile box */
  .res-profile-box {
    padding: 16px 12px;
  }
  .res-profile-kwh {
    font-size: clamp(1.6rem, 8vw, 2.2rem);
  }
  .res-profile-details {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .res-profile-detail-val {
    font-size: 1.2rem;
  }

  /* Savings hero */
  .res-savings-hero {
    padding: 20px 14px;
  }
  .res-savings-hero-amount {
    font-size: clamp(1.6rem, 8vw, 2.2rem);
  }
  .res-savings-hero-label {
    font-size: 10px;
  }

  /* Savings grid: single column */
  .res-savings-grid {
    grid-template-columns: 1fr;
    gap: 6px;
  }
  .res-savings-item {
    padding: 10px 8px;
  }
  .res-savings-item-val {
    font-size: 0.95rem;
  }

  /* Humidity compare */
  .res-hc-label {
    width: 65px;
    font-size: 9px;
  }
  .res-hc-bar {
    height: 20px;
  }
  .res-hc-fill {
    font-size: 9px;
  }
  .res-humidity-compare {
    padding: 14px;
  }

  /* Why cards */
  .res-why-card {
    padding: 14px 12px;
  }
  .res-why-title {
    font-size: 12px;
  }
  .res-why-desc {
    font-size: 10px;
  }
  .res-why-icon {
    width: 32px;
    height: 32px;
  }

  /* Social proof */
  .res-social {
    padding: 14px 12px;
  }
  .res-social-text {
    font-size: 12px;
  }
  .res-social-stars {
    font-size: 16px;
  }

  /* CTA */
  .res-cta {
    padding: 20px 12px;
  }
  .res-cta h3 {
    font-size: 1.15rem;
  }
  .res-cta p {
    font-size: 12px;
  }

  /* Projection savings */
  .res-proj-total-savings {
    padding: 14px 10px;
    font-size: 12px;
  }
  .res-proj-total-savings strong {
    font-size: 1.3rem;
  }

  /* Sources */
  .res-sources-content {
    padding: 12px;
  }
  .res-sources-intro {
    font-size: 11px;
  }
  .res-source-item {
    padding: 10px;
  }
  .res-source-label {
    font-size: 11px;
  }
  .res-source-detail {
    font-size: 11px;
  }

  /* Sticky CTA */
  .sim-sticky-cta {
    padding: 10px 12px;
    padding-bottom: max(10px, env(safe-area-inset-bottom));
  }
  .sim-sticky-cta-btn {
    padding: 14px 20px !important;
    font-size: 14px !important;
    min-height: 48px;
  }

  /* Feedback toast */
  .sim-feedback {
    bottom: 110px;
    font-size: 12px;
    padding: 6px 16px;
  }

  /* Tooltip */
  .sim-tooltip-popup {
    width: 200px;
    font-size: 10px;
    padding: 8px 10px;
  }
}

/* ================================================================
   RESPONSIVE — VERY SMALL MOBILE (<400px)
   Labels hidden, ultra-tight spacing
   ================================================================ */
@media (max-width: 400px) {
  /* Hide progress labels on very small screens */
  .sim-prog-labels {
    display: none;
  }

  /* Reclaim the space from hidden labels */
  .sim-step-scroll {
    padding-top: 78px;
  }

  /* Even smaller dots */
  .sim-prog-dot {
    width: 22px;
    height: 22px;
    font-size: 8px;
  }
  .sim-prog-line {
    width: 10px;
  }

  /* Tighter cards */
  .sim-insul-card {
    padding: 8px 4px 6px;
  }
  .sim-region-card {
    padding: 6px 3px 5px;
  }

  /* Even smaller text */
  .sim-header h2 {
    font-size: 1.05rem;
  }
  .sim-header p {
    font-size: 0.75rem;
  }
}
