/* ==========================================================================
   Résultats — design moderne, animé, lisible
   ========================================================================== */

.results-modern {
  --rm-radius: 16px;
  --rm-radius-sm: 10px;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, color-mix(in srgb, var(--color-primary) 8%, transparent), transparent 55%),
    var(--color-white);
  padding-bottom: 2rem;
  overflow: hidden;
}

/* ---------- Header ---------- */

.rm-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.75rem;
  border-bottom: 1px solid var(--color-border);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.rm-address {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0;
  font-size: 0.84rem;
  color: var(--color-text-muted);
}

.rm-address .ui-icon { color: var(--color-primary); }

.rm-header-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* ---------- Intro titre + score ---------- */

.rm-intro {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.75rem 1.75rem 0.5rem;
}

.rm-title {
  margin: 0.65rem 0 0;
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--color-ink);
  animation: rmBadgeIn 0.65s var(--ease-out) 0.08s both;
}

.rm-score-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem 0.35rem 0.45rem;
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border: 1px solid #fcd34d;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #92400e;
  animation: rmBadgeIn 0.6s var(--ease-out) both;
}

.rm-score-badge .rm-score-ring {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

@keyframes rmBadgeIn {
  from { opacity: 0; transform: translateY(8px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ---------- Preview : carte + potentiel ---------- */

.rm-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  padding: 1rem 1.75rem 0;
}

.rm-card {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--rm-radius);
  padding: 1.15rem;
  box-shadow: 0 4px 20px rgba(14, 26, 43, 0.06);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
  animation: rmCardIn 0.55s var(--ease-out) both;
}

.rm-card--map { animation-delay: 0.05s; }
.rm-card--potential { animation-delay: 0.12s; }

.rm-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(14, 26, 43, 0.1);
}

@keyframes rmCardIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.rm-card-label {
  margin: 0 0 0.85rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
}

.rm-map {
  border-radius: var(--rm-radius-sm);
  overflow: hidden;
  background: #0f172a;
  min-height: 200px;
  position: relative;
}

.rm-map img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  display: block;
  transition: transform 0.6s var(--ease-out);
}

.rm-card--map:hover .rm-map img { transform: scale(1.04); }

.rm-map-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 210px;
  color: #64748b;
  font-size: 0.85rem;
}

/* Potentiel — grille 2×2 */
.rm-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.rm-metric {
  padding: 0.85rem;
  background: var(--color-surface);
  border-radius: var(--rm-radius-sm);
  border: 1px solid var(--color-border);
  transition: background var(--dur) var(--ease);
}

.rm-metric:hover { background: var(--color-primary-light); }

.rm-metric strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-ink);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.rm-metric span {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.72rem;
  color: var(--color-text-muted);
  line-height: 1.3;
}

/* ---------- Corps ---------- */

.rm-content {
  padding: 0 1.75rem 1rem;
}

/* Power tabs — segmented control */
/* Power tabs — reco banner */
.rm-content .reco-banner {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 1.25rem 0 0.65rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  background: var(--color-accent-light);
  border: 1px solid color-mix(in srgb, var(--color-accent) 30%, transparent);
  border-radius: 999px;
  color: var(--color-accent-dark);
  font-weight: 500;
  animation: rmCardIn 0.5s var(--ease-out) 0.2s both;
}

.rm-content .reco-banner strong { color: var(--color-accent-dark); font-weight: 700; }
.rm-content .reco-banner .ui-icon { color: var(--color-accent); }

/* Graphiques */
.chart-axis-label {
  font-size: 9px;
  fill: var(--color-text-subtle);
  font-family: var(--font);
}

.charts-duo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.charts-duo-kpi {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-primary);
}

.chart-bar-grow--peak { filter: drop-shadow(0 2px 4px rgba(5, 150, 105, 0.35)); }

.chart-line-grow--prod { filter: drop-shadow(0 1px 3px rgba(245, 158, 11, 0.4)); }

@media (max-width: 768px) {
  .rm-panel .charts-duo-grid { grid-template-columns: 1fr; }
}

.rm-content .power-tabs {
  display: inline-flex;
  padding: 4px;
  background: var(--color-surface-alt);
  border-radius: 999px;
  gap: 2px;
  margin-bottom: 1.25rem;
  animation: rmCardIn 0.5s var(--ease-out) 0.25s both;
}

.rm-content .power-tab {
  border: none;
  background: transparent;
  padding: 0.55rem 1.25rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all 0.25s var(--ease);
  position: relative;
}

.rm-content .power-tab:hover:not(.disabled):not(.active) {
  color: var(--color-ink);
  background: rgba(255, 255, 255, 0.6);
}

.rm-content .power-tab.active {
  background: var(--color-white);
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(14, 26, 43, 0.1);
}

.rm-content .power-tab--suggested::after {
  content: '';
  position: absolute;
  top: 6px;
  right: 8px;
  width: 6px;
  height: 6px;
  background: var(--color-accent);
  border-radius: 50%;
}

.rm-content .power-tab.disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

/* ---------- Hero économies ---------- */

.rm-savings-hero {
  position: relative;
  margin: 0 0 1.25rem;
  padding: 2rem 1.75rem;
  border-radius: var(--rm-radius);
  background: linear-gradient(135deg, #0f2744 0%, #1e3a5f 45%, #243b53 100%);
  color: #fff;
  overflow: hidden;
  animation: rmCardIn 0.6s var(--ease-out) 0.3s both;
}

.rm-savings-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 55%;
  height: 200%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.22) 0%, transparent 65%);
  animation: rmGlow 6s ease-in-out infinite;
  pointer-events: none;
}

.rm-savings-hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 40%;
  height: 120%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

@keyframes rmGlow {
  0%, 100% { opacity: 0.6; transform: translate(0, 0); }
  50%      { opacity: 1; transform: translate(-8px, -12px); }
}

.rm-savings-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
}

.rm-savings-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 0.35rem;
}

.rm-savings-amount {
  display: block;
  font-size: clamp(2.5rem, 7vw, 3.75rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
  background: linear-gradient(180deg, #fff 30%, #fde68a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.rm-savings-sub {
  display: block;
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
}

.rm-savings-sub strong { color: #fff; }

.rm-savings-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.rm-pill {
  padding: 0.65rem 1rem;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--rm-radius-sm);
  backdrop-filter: blur(8px);
  min-width: 7rem;
  animation: rmPillIn 0.5s var(--ease-out) both;
}

.rm-pill:nth-child(1) { animation-delay: 0.45s; }
.rm-pill:nth-child(2) { animation-delay: 0.55s; }
.rm-pill:nth-child(3) { animation-delay: 0.65s; }

@keyframes rmPillIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.rm-pill strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.15rem;
}

.rm-pill span {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.3;
}

/* ---------- Facture ---------- */

.rm-bill {
  margin-bottom: 1.25rem;
  padding: 1.35rem 1.5rem;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--rm-radius);
  box-shadow: 0 4px 20px rgba(14, 26, 43, 0.05);
  animation: rmCardIn 0.55s var(--ease-out) 0.4s both;
}

.rm-bill-title {
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

.rm-bill-note {
  margin: 0 0 1rem;
  font-size: 0.78rem;
  color: var(--color-text-subtle);
}

.rm-bill-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.rm-bill-box {
  padding: 1.25rem;
  border-radius: var(--rm-radius-sm);
  text-align: center;
  transition: transform 0.3s var(--ease);
}

.rm-bill-box--before {
  background: var(--color-surface);
  border: 1px dashed var(--color-border);
}

.rm-bill-box--after {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border: 1px solid #6ee7b7;
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.15);
}

.rm-bill-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  margin-bottom: 0.4rem;
}

.rm-bill-box--after .rm-bill-tag { color: #059669; }

.rm-bill-value {
  display: block;
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--color-ink);
}

.rm-bill-box--after .rm-bill-value { color: #059669; }

.rm-bill-save {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
  color: #059669;
  font-weight: 600;
}

.rm-bill-arrow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.rm-bill-arrow-icon {
  font-size: 1.5rem;
  color: var(--color-primary);
  animation: rmArrow 2s ease-in-out infinite;
}

@keyframes rmArrow {
  0%, 100% { transform: translateX(0); }
  50%      { transform: translateX(5px); }
}

.rm-bill-badge {
  padding: 0.2rem 0.6rem;
  background: #dcfce7;
  color: #15803d;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

/* ---------- Grille détail ---------- */

.rm-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.rm-panel {
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--rm-radius);
  padding: 1.35rem 1.5rem;
  box-shadow: 0 4px 20px rgba(14, 26, 43, 0.05);
  animation: rmCardIn 0.55s var(--ease-out) both;
}

.rm-panel--prod { animation-delay: 0.45s; }
.rm-panel--charts { animation-delay: 0.52s; }

.rm-panel-title {
  margin: 0 0 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
}

.rm-prod-lead {
  margin: 0 0 1.25rem;
  font-size: 0.92rem;
  color: var(--color-text-muted);
}

.rm-prod-lead strong { color: var(--color-ink); font-weight: 700; }

.rm-bar-row { margin-bottom: 1rem; }
.rm-bar-row:last-child { margin-bottom: 0; }

.rm-bar-head {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  margin-bottom: 0.45rem;
}

.rm-bar-head span { color: var(--color-text-muted); }
.rm-bar-head strong { color: var(--color-ink); font-weight: 600; }

.rm-bar-track {
  height: 12px;
  background: var(--color-surface-alt);
  border-radius: 999px;
  overflow: hidden;
}

.rm-bar-fill {
  height: 100%;
  border-radius: 999px;
  width: 0;
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.rm-bar-fill--home {
  background: linear-gradient(90deg, var(--color-primary), #3b82f6);
  box-shadow: 0 0 12px rgba(30, 58, 95, 0.35);
}

.rm-bar-fill--grid { background: #94a3b8; }

.rm-prod-foot {
  margin: 1rem 0 0;
  padding-top: 0.85rem;
  border-top: 1px solid var(--color-border);
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* Charts dans panel */
.rm-panel .charts-duo { padding: 0; }

.rm-panel .charts-duo-grid {
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.rm-panel .charts-duo-panel {
  border: none;
  box-shadow: none;
  padding: 0;
  background: transparent;
}

.rm-panel .charts-duo-svg { height: 150px; }

.rm-panel .charts-duo-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-ink);
}

/* ---------- Bas : cumul + env ---------- */

.rm-bottom-row {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.rm-cumul-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 0.65rem;
}

.rm-cumul-list li {
  flex: 1;
  padding: 1rem 0.85rem;
  text-align: center;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--rm-radius-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
  animation: rmPillIn 0.5s var(--ease-out) both;
}

.rm-cumul-list li:nth-child(1) { animation-delay: 0.55s; }
.rm-cumul-list li:nth-child(2) { animation-delay: 0.62s; }
.rm-cumul-list li:nth-child(3) { animation-delay: 0.69s; }

.rm-cumul-list li:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(14, 26, 43, 0.08);
}

.rm-cumul-years {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-muted);
  margin-bottom: 0.35rem;
}

.rm-cumul-amount {
  display: block;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--color-primary-dark);
  letter-spacing: -0.02em;
}

.rm-env {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0;
}

.rm-env-icon {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: var(--rm-radius-sm);
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  animation: rmGlow 4s ease-in-out infinite;
}

.rm-env-icon .ui-icon,
.rm-env-icon svg {
  width: 1.5rem;
  height: 1.5rem;
}

.rm-env-value {
  display: block;
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--color-ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.rm-env-label {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

/* ---------- Histoire client : énergie & profil ---------- */

.ce-story {
  margin-bottom: 1.25rem;
  border-radius: var(--rm-radius);
  overflow: hidden;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 32px rgba(14, 26, 43, 0.08);
  animation: rmCardIn 0.6s var(--ease-out) 0.38s both;
}

.ce-hero {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 0;
  background: linear-gradient(135deg, #0f2744 0%, #1e3a5f 50%, #1e4976 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.ce-hero::before {
  content: '';
  position: absolute;
  top: -40%;
  right: -15%;
  width: 50%;
  height: 180%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.2) 0%, transparent 65%);
  animation: rmGlow 7s ease-in-out infinite;
  pointer-events: none;
}

.ce-hero-copy {
  position: relative;
  z-index: 1;
  padding: 2rem 1.75rem;
}

.ce-badge {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 0.85rem;
}

.ce-headline {
  margin: 0 0 0.85rem;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.ce-headline span {
  font-size: clamp(2rem, 5vw, 2.75rem);
  background: linear-gradient(180deg, #fff 20%, #fde68a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.ce-headline em {
  display: block;
  font-style: normal;
  font-size: 0.72em;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.8);
  margin-top: 0.25rem;
}

.ce-lead {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
  max-width: 28rem;
}

.ce-lead strong { color: #fff; font-weight: 700; }

.ce-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.25rem 1rem 0;
  min-height: 220px;
}

.ce-house-svg {
  width: 100%;
  max-width: 280px;
  height: auto;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.2));
}

.ce-sun-halo { animation: ceSunPulse 3s ease-in-out infinite; }
.ce-sun-rays { animation: ceSunSpin 12s linear infinite; transform-origin: 220px 44px; }
.ce-window { animation: ceWindowGlow 2.5s ease-in-out infinite alternate; }
.ce-window--2 { animation-delay: 0.4s; }
.ce-window--3 { animation-delay: 0.8s; }
.ce-panel { animation: cePanelShine 3s ease-in-out infinite; }
.ce-panel:nth-child(2) { animation-delay: 0.2s; }
.ce-panel:nth-child(3) { animation-delay: 0.4s; }
.ce-panel:nth-child(4) { animation-delay: 0.6s; }
.ce-panel:nth-child(5) { animation-delay: 0.8s; }

@keyframes ceSunPulse {
  0%, 100% { transform: scale(1); opacity: 0.2; }
  50%      { transform: scale(1.15); opacity: 0.35; }
}

@keyframes ceSunSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes ceWindowGlow {
  from { fill: #dbeafe; }
  to   { fill: #fef08a; }
}

@keyframes cePanelShine {
  0%, 100% { opacity: 0.85; }
  50%      { opacity: 1; filter: brightness(1.15); }
}

.ce-ring {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  width: 88px;
  height: 88px;
}

.ce-ring-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ce-ring-label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}

.ce-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-top: 1px solid var(--color-border);
}

.ce-split-card {
  display: flex;
  gap: 1rem;
  padding: 1.35rem 1.5rem;
  align-items: flex-start;
  transition: background 0.25s var(--ease);
}

.ce-split-card--home {
  background: linear-gradient(180deg, #f0fdf4, #fff);
  border-right: 1px solid var(--color-border);
}

.ce-split-card--grid { background: #fff; }

.ce-split-card:hover { background: var(--color-surface); }

.ce-split-icon {
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  box-shadow: 0 2px 8px rgba(14, 26, 43, 0.06);
}

.ce-split-card--home .ce-split-icon {
  color: #059669;
  background: #ecfdf5;
  border-color: #a7f3d0;
}

.ce-split-card--grid .ce-split-icon { color: #64748b; }

.ce-split-icon svg { width: 1.35rem; height: 1.35rem; }

.ce-split-body strong {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-ink);
  margin-bottom: 0.15rem;
}

.ce-split-body > span {
  display: block;
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin-bottom: 0.65rem;
}

.ce-split-body em {
  display: block;
  font-style: normal;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-top: 0.45rem;
}

.ce-meter {
  height: 8px;
  background: var(--color-surface-alt);
  border-radius: 999px;
  overflow: hidden;
}

.ce-meter-fill {
  height: 100%;
  border-radius: 999px;
  width: 0;
  transition: width 1.1s cubic-bezier(0.22, 1, 0.36, 1);
}

.ce-meter-fill--home {
  background: linear-gradient(90deg, #059669, #34d399);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}

.ce-meter-fill--grid { background: #94a3b8; }

.ce-coverage {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 1.5rem;
  align-items: center;
  padding: 1.35rem 1.5rem;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

.ce-coverage-pct {
  display: block;
  font-size: clamp(1.75rem, 4vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--color-primary);
  line-height: 1;
  margin-bottom: 0.35rem;
}

.ce-coverage-copy p {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--color-text-muted);
}

.ce-coverage-track {
  height: 14px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 0.65rem;
  box-shadow: inset 0 1px 2px rgba(14, 26, 43, 0.06);
}

.ce-coverage-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--color-primary), #38bdf8);
  box-shadow: 0 0 12px rgba(30, 58, 95, 0.3);
  transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.ce-coverage-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.ce-coverage-meta strong { color: var(--color-ink); font-weight: 700; }

/* Profil client — texte narratif */

.cp-profile {
  margin-bottom: 1.25rem;
  padding: 1.5rem 1.65rem;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-radius: var(--rm-radius);
  box-shadow: 0 4px 20px rgba(14, 26, 43, 0.05);
  animation: rmCardIn 0.55s var(--ease-out) 0.48s both;
}

.cp-title {
  margin: 0 0 1.25rem;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-ink);
}

.cp-block {
  display: flex;
  gap: 1rem;
  padding: 1.15rem 0;
  border-top: 1px solid var(--color-border);
  animation: rmPillIn 0.5s var(--ease-out) both;
}

.cp-block:first-of-type { border-top: none; padding-top: 0; }
.cp-block:nth-of-type(1) { animation-delay: 0.52s; }
.cp-block:nth-of-type(2) { animation-delay: 0.6s; }
.cp-block:nth-of-type(3) { animation-delay: 0.68s; }

.cp-block-icon {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-primary-light);
  color: var(--color-primary);
}

.cp-block--surplus .cp-block-icon {
  background: #ecfdf5;
  color: #059669;
}

.cp-block-icon svg { width: 1.25rem; height: 1.25rem; }

.cp-block-body h4 {
  margin: 0 0 0.4rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
}

.cp-block-body p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--color-text);
}

.cp-block-body strong { color: var(--color-ink); font-weight: 700; }

.cp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.75rem;
}

.cp-tag {
  padding: 0.3rem 0.65rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.cp-tag--green {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}

.cp-foot {
  margin: 1.15rem 0 0;
  padding-top: 1rem;
  border-top: 1px dashed var(--color-border);
  font-size: 0.72rem;
  color: var(--color-text-subtle);
  text-align: center;
  line-height: 1.5;
}

/* ---------- Zone verrouillée (aperçu + détail flouté) ---------- */

.results-gated-wrap {
  position: relative;
  margin-top: 0.5rem;
}

.results-gated-content {
  transition: filter 0.45s var(--ease-out);
  min-height: 280px;
}

.results-panel--locked .results-gated-content {
  filter: blur(9px);
  pointer-events: none;
  user-select: none;
}

.results-blur-hint {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 2.5rem 1.5rem;
  z-index: 5;
  text-align: center;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.75) 25%,
    rgba(248, 250, 252, 0.92) 55%,
    var(--color-bg, #f8fafc) 85%
  );
}

.results-panel--unlocked .results-blur-hint { display: none; }

.results-blur-hint p {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-ink);
}

.results-blur-sub {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  max-width: 22rem;
  line-height: 1.45;
}

.results-blur-hint .btn { margin-top: 0.35rem; }

/* ---------- Comparatif batterie (showcase animé) ---------- */

.rm-battery-wrap {
  padding: 0 1.75rem;
  margin-top: 0.25rem;
}

.bat-showcase {
  margin-bottom: 1.25rem;
  border-radius: var(--rm-radius);
  overflow: hidden;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 32px rgba(14, 26, 43, 0.08);
  animation: rmCardIn 0.6s var(--ease-out) 0.18s both;
}

.bat-showcase-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 1.5rem 1rem;
  background: linear-gradient(135deg, #fffbeb 0%, #fff 55%);
  border-bottom: 1px solid var(--color-border);
}

.bat-kicker {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #b45309;
  margin-bottom: 0.35rem;
}

.bat-title {
  margin: 0 0 0.4rem;
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-ink);
}

.bat-lead {
  margin: 0;
  max-width: 36rem;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--color-text-muted);
}

.bat-tabs {
  display: inline-flex;
  padding: 4px;
  background: var(--color-surface-alt);
  border-radius: 999px;
  gap: 2px;
  flex-shrink: 0;
}

.bat-tab {
  border: none;
  background: transparent;
  padding: 0.55rem 1.1rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all 0.3s var(--ease);
}

.bat-tab:hover:not(.active) { color: var(--color-ink); background: rgba(255,255,255,0.6); }

.bat-tab.active {
  background: #fff;
  color: var(--color-primary);
  box-shadow: 0 2px 10px rgba(14, 26, 43, 0.1);
}

.bat-duo {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 0;
  align-items: stretch;
}

.bat-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  text-align: left;
  padding: 1.25rem 1.15rem 1.15rem;
  border: none;
  background: var(--color-surface);
  cursor: pointer;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), background 0.35s var(--ease);
  font: inherit;
  color: inherit;
  position: relative;
}

.bat-card--no {
  border-right: 1px solid var(--color-border);
  opacity: 0.88;
}

.bat-card--yes {
  background: linear-gradient(180deg, #f0fdf4, #fff);
}

.bat-card--selected {
  opacity: 1;
  z-index: 1;
}

.bat-card--no.bat-card--selected {
  background: #fff;
  box-shadow: inset 0 0 0 2px var(--color-primary);
}

.bat-card--yes.bat-card--selected {
  box-shadow: inset 0 0 0 2px #059669, 0 8px 24px rgba(16, 185, 129, 0.15);
  transform: scale(1.02);
}

.bat-card:not(.bat-card--selected):hover {
  opacity: 1;
  background: #fff;
}

.bat-card-tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-bottom: 0.65rem;
}

.bat-card-tag--win { color: #059669; }

.bat-card-reco {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  padding: 0.2rem 0.55rem;
  background: #059669;
  color: #fff;
  border-radius: 999px;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  animation: rmBadgeIn 0.6s var(--ease-out) 0.4s both;
}

.bat-flow-svg {
  width: 100%;
  max-width: 240px;
  height: auto;
  margin: 0 auto 0.75rem;
  display: block;
}

.bat-sun { animation: ceSunPulse 2.5s ease-in-out infinite; }

.bat-energy-line {
  animation: batDash 1.5s linear infinite;
}

.bat-energy-line--2 { animation-delay: 0.5s; }

@keyframes batDash {
  to { stroke-dashoffset: -16; }
}

.bat-scene-label {
  font-size: 7px;
  fill: var(--color-text-muted);
  font-family: var(--font);
}

.bat-battery-charge {
  animation: batChargePulse 2s ease-in-out infinite;
}

@keyframes batChargePulse {
  0%, 100% { opacity: 0.75; }
  50%      { opacity: 1; filter: brightness(1.2); }
}

.bat-card-meter {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 0.75rem;
}

.bat-meter-svg {
  width: 72px;
  height: auto;
  flex-shrink: 0;
}

.bat-meter-pct {
  font-size: 13px;
  font-weight: 800;
  fill: var(--color-ink);
  font-family: var(--font);
}

.bat-meter-sub {
  font-size: 6px;
  fill: var(--color-text-muted);
  font-family: var(--font);
}

.bat-meter-fill {
  transform-box: fill-box;
  transform-origin: center bottom;
  transform: scaleY(0);
}

.reveal-on-load.is-visible .bat-meter-fill {
  animation: batFillUp 1.3s cubic-bezier(0.22, 1, 0.36, 1) 0.35s forwards;
}

.bat-card--yes .bat-meter-fill { animation-delay: 0.55s; }

@keyframes batFillUp {
  from { transform: scaleY(0); }
  to   { transform: scaleY(1); }
}

.bat-meter-pulse {
  animation: batMeterPulse 2s ease-in-out infinite;
  transform-origin: 44px 44px;
}

@keyframes batMeterPulse {
  0%, 100% { transform: scale(1); opacity: 0.35; }
  50%      { transform: scale(1.08); opacity: 0.55; }
}

.bat-card-stats strong {
  display: block;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--color-ink);
  line-height: 1.1;
}

.bat-card-amount--win {
  color: #059669;
  background: linear-gradient(180deg, #059669, #10b981);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.bat-card-stats > span {
  display: block;
  font-size: 0.78rem;
  color: var(--color-text-muted);
  margin-top: 0.15rem;
}

.bat-card-stats em {
  display: block;
  font-style: normal;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-top: 0.25rem;
}

.bat-bar-track {
  height: 8px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 0.65rem;
}

.bat-bar-track--win { background: #d1fae5; }

.bat-bar-fill {
  height: 100%;
  border-radius: 999px;
  width: 0;
  transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.bat-bar-fill--no { background: #94a3b8; }
.bat-bar-fill--yes {
  background: linear-gradient(90deg, #059669, #34d399);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.45);
}

.bat-card-foot {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: var(--color-text-muted);
}

.bat-card-foot--win { color: #047857; font-weight: 500; }

.bat-delta {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 0.65rem;
  background: linear-gradient(180deg, #fef3c7, #fff);
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  min-width: 5.5rem;
  text-align: center;
}

.bat-delta-badge {
  padding: 0.65rem 0.75rem;
  background: #fff;
  border: 2px solid #fcd34d;
  border-radius: var(--rm-radius-sm);
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.2);
  animation: batDeltaPop 0.7s cubic-bezier(0.22, 1, 0.36, 1) 0.5s both;
}

@keyframes batDeltaPop {
  from { opacity: 0; transform: scale(0.85); }
  to   { opacity: 1; transform: scale(1); }
}

.bat-delta-label {
  display: block;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #b45309;
  margin-bottom: 0.2rem;
}

.bat-delta-value {
  display: block;
  font-size: 1.15rem;
  font-weight: 800;
  color: #059669;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.bat-delta-unit {
  font-size: 0.72rem;
  color: var(--color-text-muted);
}

.bat-delta-meta {
  margin: 0.5rem 0 0;
  font-size: 0.65rem;
  line-height: 1.4;
  color: var(--color-text-muted);
  max-width: 5rem;
}

.bat-delta-arrow {
  margin-top: 0.65rem;
  font-size: 1.25rem;
  color: #059669;
  animation: rmArrow 2s ease-in-out infinite;
}

/* Legacy bandeau */

.rm-battery {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-radius: var(--rm-radius-sm);
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
  border: 1px solid #fcd34d;
  animation: rmCardIn 0.5s var(--ease-out) 0.7s both;
}

.rm-battery--active {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border-color: #6ee7b7;
}

.rm-battery p {
  margin: 0;
  flex: 1;
  min-width: 200px;
  font-size: 0.9rem;
  line-height: 1.5;
}

.rm-battery-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* ---------- Notes ---------- */

.rm-content .assumptions-note {
  margin-top: 1.25rem;
  padding: 0.85rem 1rem;
  background: var(--color-surface);
  border-radius: var(--rm-radius-sm);
  border: 1px solid var(--color-border);
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.rm-content .results-disclaimer {
  margin-top: 1rem;
  font-size: 0.75rem;
  color: var(--color-text-subtle);
  text-align: center;
}

/* ---------- Animations graphiques ---------- */

.chart-bar-grow {
  transform: scaleY(0);
  transform-box: fill-box;
  transform-origin: center bottom;
  transition: transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.chart-bar-grow.is-grown { transform: scaleY(1); }

.chart-line-grow,
.chart-area-grow {
  opacity: 0;
  transition: opacity 0.7s ease;
}

.chart-line-grow.is-drawn,
.chart-area-grow.is-drawn { opacity: 1; }

.reveal-on-load {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
}

.reveal-on-load.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */

@media (max-width: 768px) {
  .rm-preview,
  .rm-detail-grid,
  .rm-bottom-row {
    grid-template-columns: 1fr;
  }

  .ce-hero,
  .ce-split,
  .ce-coverage {
    grid-template-columns: 1fr;
  }

  .ce-visual { padding: 0 1rem 1.25rem; min-height: 180px; }
  .ce-ring { right: 0.75rem; bottom: 0.75rem; }

  .cp-block { flex-direction: column; gap: 0.65rem; }

  .bat-duo {
    grid-template-columns: 1fr;
  }

  .bat-delta {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 1rem;
    border: none;
    border-top: 1px dashed #fcd34d;
    border-bottom: 1px dashed #fcd34d;
    padding: 0.85rem 1rem;
  }

  .bat-delta-arrow { display: none; }

  .bat-delta-meta { max-width: none; }

  .bat-card--no { border-right: none; border-bottom: 1px solid var(--color-border); }

  .bat-showcase-head { flex-direction: column; align-items: stretch; }

  .bat-tabs { width: 100%; justify-content: center; }

  .rm-bill-row {
    grid-template-columns: 1fr;
    gap: 0.65rem;
  }

  .rm-bill-arrow { transform: rotate(90deg); }

  .rm-cumul-list { flex-direction: column; }

  .rm-intro,
  .rm-preview,
  .rm-content,
  .rm-battery-wrap { padding-left: 1.15rem; padding-right: 1.15rem; }

  .rm-header { padding: 0.85rem 1.15rem; }

  .rm-savings-pills { width: 100%; }
  .rm-pill { flex: 1; min-width: 0; }
}
