/* ═══════════════════════════════════════════
   WattMatch — Onboarding Funnel Styles
   ═══════════════════════════════════════════ */

* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Inter', sans-serif;
  color: #1C1917;
  background: #FAFAF9;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5, h6 { font-family: 'Suisse Screen', sans-serif; }

/* ── Progress bar (top, 3px) ─────────────── */
.funnel-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: #E7E5E4;
  z-index: 1000;
}
.funnel-progress-fill {
  height: 100%;
  background: #F87171;
  width: 0%;
  transition: width 0.4s ease-out;
}

/* ── Container ───────────────────────────── */
.funnel-container {
  min-height: 100vh;
  position: relative;
}

.funnel-logo {
  position: fixed;
  top: 1.25rem;
  left: 1.5rem;
  font-family: 'Suisse Screen WM', 'Suisse Screen', sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  color: #1C1917;
  text-decoration: none;
  z-index: 100;
}
.funnel-logo span { color: #15803D; }

/* ── Steps ───────────────────────────────── */
.funnel-step {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 1.5rem 3rem;
  animation: fadeInUp 0.35s ease-out forwards;
}
.funnel-step.hidden { display: none !important; }

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

.step-content {
  width: 100%;
  max-width: 640px;
}
.step-center { text-align: center; }
.step-narrow { max-width: 520px; }
.step-wide { max-width: 960px; }

/* ── Typography ──────────────────────────── */
.funnel-title {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 0.75rem;
  color: #1C1917;
}
.funnel-subtitle {
  font-size: 1.0625rem;
  color: #78716C;
  margin-bottom: 2rem;
  line-height: 1.5;
}
.funnel-hint {
  font-size: 0.8125rem;
  color: #78716C;
  line-height: 1.5;
  margin-top: 0.5rem;
}

/* ── Accent colors ───────────────────────── */
.text-accent { color: #F87171; }
.text-success { color: #15803D; }

/* ── CTA Buttons ─────────────────────────── */
.funnel-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: linear-gradient(135deg, #15803D 0%, #166534 100%);
  color: white;
  font-weight: 700;
  font-size: 1rem;
  border: none;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Inter', sans-serif;
  min-width: 280px;
}
.funnel-cta:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(34, 197, 94, 0.35);
}
.funnel-cta:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}
.funnel-cta-large {
  width: 100%;
  padding: 1rem 2rem;
  font-size: 1.0625rem;
  margin-top: 1.5rem;
}

.funnel-link {
  background: none;
  border: none;
  color: #78716C;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-family: 'Inter', sans-serif;
  margin-top: 1rem;
  display: inline-block;
}
.funnel-link:hover { color: #1C1917; }
.funnel-link-inline {
  color: #15803D;
  text-decoration: underline;
}

/* ── Inputs ──────────────────────────────── */
.funnel-input {
  width: 100%;
  border: 2px solid #E5E5E5;
  border-radius: 0.75rem;
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  font-family: 'Inter', sans-serif;
  transition: border-color 0.2s;
  background: white;
  color: #1C1917;
}
.funnel-input:focus {
  outline: none;
  border-color: #15803D;
}
.funnel-input::placeholder { color: #78716C; }
.funnel-input.error { border-color: #EF4444; }

/* ═══════════════════════════════════════════
   STEP 1 — Loss cards
   ═══════════════════════════════════════════ */
.loss-cards-hint {
  font-size: 0.85rem;
  color: #78716C;
  text-align: center;
  margin-bottom: 1rem;
}
.loss-cards {
  display: flex;
  gap: 1.25rem;
  justify-content: center;
  margin-bottom: 1rem;
}
/* Answers the objection the two cards themselves create ("neither one is
   me, I rent and I have no panels"). Placed after them, not before: the
   doubt has to exist before a reply reads as a reply. Same green pair as
   the hero eligibility pills, 6.8:1 here too. */
.loss-cards-reassure {
  font-size: 0.85rem;
  line-height: 1.55;
  color: #166534;
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  text-align: center;
  max-width: 34rem;
  margin: 0 auto 1.25rem;
}

.loss-card {
  background: white;
  border: 2px solid #F5F5F4;
  border-radius: 1rem;
  padding: 1.75rem 2rem;
  flex: 1;
  max-width: 260px;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.15s, background 0.15s;
  cursor: pointer;
  position: relative;
}
.loss-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  border-color: #E7E5E4;
}
.loss-card.selected {
  border-color: #15803D;
  background: #F0FDF4;
  box-shadow: 0 4px 12px rgba(34,197,94,0.12);
}
.loss-card[data-role="producer"].selected {
  border-color: #F59E0B;
  background: #FFFBEB;
  box-shadow: 0 4px 12px rgba(245,158,11,0.12);
}
.loss-card-check {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 999px;
  background: #15803D;
  color: white;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
}
.loss-card.selected .loss-card-check { display: inline-flex; }
.loss-card[data-role="producer"].selected .loss-card-check { background: #F59E0B; }
.loss-card-icon { margin-bottom: 0.5rem; display: flex; align-items: center; justify-content: center; }
.loss-card-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #78716C;
  margin-bottom: 0.75rem;
}
.loss-card-amount { margin-bottom: 0.25rem; }
.loss-chf {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 1.625rem;
  font-weight: 800;
  /* #F87171 (3.05:1 on white) failed AA on the loss-priming step.
     #DC2626 (4.83:1) keeps the alarm-red association while passing. */
  color: #DC2626;
}
.loss-chf-small {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #DC2626;
}

/* ═══════════════════════════════════════════
   STEP 2 — Structured address inputs
   ═══════════════════════════════════════════ */
.address-structured {
  max-width: 520px;
  margin: 0 auto 0.5rem;
  text-align: left;
}
.address-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.address-group {
  flex: 1;
  position: relative;
}
.address-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: #57534E;
  margin-bottom: 0.25rem;
}
.address-group-npa { flex: 0 0 110px; }
.address-group-number { flex: 0 0 80px; }
.address-suggestions {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: white;
  border: 2px solid #E5E5E5;
  border-radius: 0.75rem;
  max-height: 200px;
  overflow-y: auto;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.address-sug-item {
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  cursor: pointer;
  border-bottom: 1px solid #F5F5F4;
  transition: background 0.15s;
}
.address-sug-item:last-child { border-bottom: none; }
.address-sug-item:hover { background: #F0FDF4; }

/* ═══════════════════════════════════════════
   STEP 3 — Map layout
   ═══════════════════════════════════════════ */
.map-layout {
  display: flex;
  gap: 1.5rem;
  align-items: stretch;
}
.map-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 0;
}
.map-container {
  min-height: 400px;
  border-radius: 1rem;
  overflow: hidden;
  border: 2px solid #E7E5E4;
}
#celMap, #welcomeMap {
  width: 100%;
  height: 100%;
  min-height: 400px;
}
.map-legend {
  background: #F9FAFB;
  border: 1px solid #E7E5E4;
  border-radius: 0.75rem;
  padding: 0.875rem 1rem;
  font-size: 0.8125rem;
  color: #57534E;
  line-height: 1.5;
}
.map-legend-desc {
  display: block;
  margin: 0 0 0.625rem 0;
  color: #1C1917;
  font-size: 0.875rem;
}
.map-legend-desc strong { color: #1C1917; font-weight: 700; }
.map-legend-items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem 1.25rem;
}
.map-legend-item {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  color: #57534E;
}
.map-panel {
  width: 280px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.map-panel-zone {
  font-size: 1.375rem;
  font-weight: 800;
  color: #1C1917;
  margin-bottom: 1rem;
}
.map-panel-stat {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}
.map-panel-stat-number {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  color: #15803D;
}
.map-panel-stat-label {
  font-size: 0.9375rem;
  color: #78716C;
  font-weight: 500;
}
.map-panel-message {
  font-size: 0.9375rem;
  color: #57534E;
  line-height: 1.5;
  margin-bottom: 1.5rem;
}

/* Pulsing user marker */
.user-marker-pulse {
  width: 24px;
  height: 24px;
  position: relative;
}
.user-marker-pulse .pin {
  width: 24px;
  height: 24px;
  background: #F87171;
  border: 3px solid white;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  position: relative;
  z-index: 2;
}
.user-marker-pulse .pulse {
  position: absolute;
  top: 50%; left: 50%;
  width: 40px; height: 40px;
  margin: -20px 0 0 -20px;
  background: rgba(248,113,113,0.3);
  border-radius: 50%;
  animation: pulse-ring 2s ease-out infinite;
  z-index: 1;
}
@keyframes pulse-ring {
  0% { transform: scale(0.5); opacity: 1; }
  100% { transform: scale(2.2); opacity: 0; }
}

/* Member markers */
.member-dot {
  width: 10px;
  height: 10px;
  background: #22C55E;
  border-radius: 50%;
  opacity: 0.6;
  border: 1.5px solid white;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* ═══════════════════════════════════════════
   STEP 4 — Wizard
   ═══════════════════════════════════════════ */
.wizard-progress {
  height: 4px;
  background: #E7E5E4;
  border-radius: 2px;
  margin: 1.5rem 0 2rem;
  overflow: hidden;
}
.wizard-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #F87171, #EF4444);
  width: 0%;
  transition: width 0.4s ease-out;
  border-radius: 2px;
}

.wizard-container {
  min-height: 300px;
}

.wizard-question {
  animation: slideUp 0.25s ease-out forwards;
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.wizard-question-title {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 1.375rem;
  font-weight: 700;
  color: #1C1917;
  margin-bottom: 1.25rem;
}

.wizard-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.wizard-option {
  background: white;
  border: 2px solid #E7E5E4;
  border-radius: 0.875rem;
  padding: 1rem 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-align: left;
  min-height: 64px;
  font-family: 'Inter', sans-serif;
  font-size: 0.9375rem;
  font-weight: 500;
  color: #1C1917;
}
.wizard-option:hover {
  border-color: #15803D;
  background: #F0FDF4;
  transform: translateY(-1px);
}
.wizard-option:active {
  transform: scale(0.98);
}
.wizard-option.selected {
  border-color: #15803D;
  background: #F0FDF4;
  box-shadow: 0 0 0 3px rgba(34,197,94,0.15);
}
.wizard-option-icon {
  flex-shrink: 0;
  width: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #15803D;
}
.wizard-option-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

/* kWh input inside wizard */
.wizard-kwh-group {
  display: flex;
  gap: 0.75rem;
  align-items: flex-end;
  margin-top: 1rem;
}
.wizard-kwh-group .funnel-input {
  flex: 1;
}
.wizard-kwh-unit {
  font-size: 0.875rem;
  color: #78716C;
  padding-bottom: 0.85rem;
  flex-shrink: 0;
}
.wizard-kwh-submit {
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, #15803D 0%, #166534 100%);
  color: white;
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  border-radius: 0.75rem;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  transition: opacity 0.2s;
  flex-shrink: 0;
}
.wizard-kwh-submit:hover { opacity: 0.9; }

.wizard-info-message {
  background: #FEF3C7;
  border: 1px solid #FDE68A;
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  font-size: 0.8125rem;
  color: #92400E;
  margin-top: 0.75rem;
  line-height: 1.5;
}

/* PV BFE lookup (producer wizard) */
.wizard-pv-result {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 0.75rem;
  padding: 1rem 1.25rem;
  margin-bottom: 1rem;
}
.wizard-pv-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
  margin-bottom: 0.75rem;
}
.wizard-pv-badge--ok {
  background: #DCFCE7;
  color: #166534;
}
.wizard-pv-badge--warn {
  background: #FEF3C7;
  color: #92400E;
}
.wizard-pv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}
.wizard-pv-grid > div {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.wizard-pv-label {
  font-size: 0.75rem;
  color: #78716C;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.wizard-pv-value {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1C1917;
}
.wizard-pv-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.wizard-pv-checkrow {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.wizard-pv-checkrow:hover {
  border-color: #BBF7D0;
  background: #F0FDF4;
}
.wizard-pv-checkrow input[type="checkbox"] {
  margin-top: 0.25rem;
  width: 1.125rem;
  height: 1.125rem;
  accent-color: #15803D;
  flex-shrink: 0;
}
.wizard-pv-checktext {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}
.wizard-pv-checktitle {
  font-weight: 600;
  font-size: 0.9375rem;
  color: #1C1917;
}
.wizard-pv-checksub {
  font-size: 0.8125rem;
  color: #78716C;
}
@media (max-width: 480px) {
  .wizard-pv-grid {
    grid-template-columns: 1fr;
  }
}

/* ═══════════════════════════════════════════
   STEP 5 — Loss hero
   ═══════════════════════════════════════════ */
.loss-hero {
  margin: 2rem 0 1.5rem;
}
.loss-hero-amount {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 4rem;
  font-weight: 800;
  color: #F87171;
  line-height: 1.1;
  display: block;
}
.loss-hero-monthly {
  font-size: 1.0625rem;
  color: #78716C;
  margin-top: 0.5rem;
}

.elcom-badge {
  display: inline-block;
  background: #F5F5F4;
  border: 1px solid #E7E5E4;
  border-radius: 0.5rem;
  padding: 0.375rem 0.875rem;
  font-size: 0.8125rem;
  color: #78716C;
  margin-bottom: 2rem;
}

/* Savings comparison bar */
.savings-bar-container {
  max-width: 400px;
  margin: 0 auto 1rem;
  text-align: left;
}
.savings-bar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.25rem;
}
.savings-bar-label {
  font-size: 0.8125rem;
  color: #78716C;
}
.savings-bar-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: #1C1917;
}
.savings-bar-label-gain { color: #15803D; font-weight: 600; }
.savings-bar-value-gain { color: #15803D; }
.savings-bar {
  display: flex;
  height: 12px;
  border-radius: 6px;
  overflow: hidden;
  margin-top: 0.5rem;
  background: #E7E5E4;
}
.savings-bar-cost {
  background: #F87171;
  transition: width 0.6s ease-out;
}
.savings-bar-gain {
  background: #22C55E;
  transition: width 0.6s ease-out;
}

/* ═══════════════════════════════════════════
   STEP 6 — Contract
   ═══════════════════════════════════════════ */
.contract-summary {
  background: #F0FDF4;
  border: 2px solid #BBF7D0;
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  margin: 1.5rem 0;
  text-align: left;
}
.contract-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0;
  font-size: 0.9375rem;
  color: #57534E;
}
.contract-check {
  color: #15803D;
  font-weight: 700;
  font-size: 1.125rem;
}

.full-contract {
  background: #FAFAF9;
  border: 1px solid #E7E5E4;
  border-radius: 0.75rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  text-align: left;
  font-size: 0.8125rem;
  color: #57534E;
  line-height: 1.6;
  max-height: 300px;
  overflow-y: auto;
}
.full-contract h4 {
  font-size: 0.9375rem;
  color: #1C1917;
  margin-bottom: 0.75rem;
}
.full-contract p { margin-bottom: 0.75rem; }

.contract-form {
  text-align: left;
  margin-top: 1.5rem;
}
.form-row {
  display: flex;
  gap: 1rem;
}
.form-group {
  margin-bottom: 1rem;
  flex: 1;
}
.form-group label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #57534E;
  margin-bottom: 0.25rem;
}
.form-optional {
  font-weight: 400;
  color: #78716C;
}
.form-checkboxes {
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}
.next-steps-hint {
  margin: 1rem 0 0.75rem;
  padding: 0.875rem 1rem;
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  border-radius: 0.75rem;
  text-align: left;
}
/* Eligibility notice under the identity fields. Amber rather than the
   green of .next-steps-hint: this one is a condition, not a recap. */
.funnel-notice {
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  background: #FFFBEB;
  border: 1px solid #FDE68A;
  border-radius: 0.75rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: #92400E;
  text-align: left;
}
.next-steps-hint-title {
  margin: 0 0 0.375rem 0;
  font-size: 0.8125rem;
  font-weight: 700;
  color: #166534;
}
.next-steps-hint-list {
  margin: 0;
  padding-left: 1.25rem;
  font-size: 0.8125rem;
  color: #1C1917;
  line-height: 1.5;
}
.next-steps-hint-list li { margin-top: 0.125rem; }
.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.8125rem;
  color: #57534E;
  cursor: pointer;
  line-height: 1.4;
}
.checkbox-label input[type="checkbox"] {
  margin-top: 2px;
  accent-color: #15803D;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Spinner */
.spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════════════════════════════════════
   STEP 7 — Welcome / Dashboard
   ═══════════════════════════════════════════ */
.welcome-check {
  margin-bottom: 1.5rem;
}
.check-circle {
  stroke-dasharray: 226;
  stroke-dashoffset: 226;
  animation: drawCircle 0.6s ease-out 0.2s forwards;
}
.check-path {
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation: drawCheck 0.4s ease-out 0.7s forwards;
}
@keyframes drawCircle {
  to { stroke-dashoffset: 0; }
}
@keyframes drawCheck {
  to { stroke-dashoffset: 0; }
}

.welcome-title {
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
}
.welcome-map-container {
  border-radius: 1rem;
  overflow: hidden;
  border: 2px solid #E7E5E4;
  height: 250px;
  margin-bottom: 1.5rem;
}
.welcome-savings-block {
  background: linear-gradient(135deg, #F0FDF4, #DCFCE7);
  border: 2px solid #BBF7D0;
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 1rem;
}
.welcome-savings-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #166534;
  margin-bottom: 0.25rem;
}
.welcome-savings-amount {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  color: #15803D;
  display: block;
}
.welcome-neighbours-breakdown {
  margin-top: 0.75rem;
  margin-bottom: 0;
  font-size: 0.8125rem;
  line-height: 1.5;
  color: #166534;
}
.welcome-neighbours-breakdown strong {
  color: #14532D;
  font-weight: 700;
}

.welcome-contribution {
  font-size: 1rem;
  color: #57534E;
  margin-bottom: 1rem;
}
.welcome-contribution strong {
  font-size: 1.125rem;
}

.welcome-divider {
  border: none;
  border-top: 2px solid #E7E5E4;
  margin: 1.5rem 0;
}

/* Share section */
.share-section { text-align: center; }
.share-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1C1917;
  margin-bottom: 0.25rem;
}
.share-subtitle {
  font-size: 0.9375rem;
  color: #78716C;
  margin-bottom: 1rem;
}
.share-buttons {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.625rem 1.25rem;
  border-radius: 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: 2px solid transparent;
  font-family: 'Inter', sans-serif;
}
.share-whatsapp {
  background: #25D366;
  color: white;
}
.share-whatsapp:hover { background: #1DA851; }
.share-email {
  background: white;
  border-color: #E7E5E4;
  color: #1C1917;
}
.share-email:hover { border-color: #15803D; background: #F0FDF4; }
.share-link {
  background: white;
  border-color: #E7E5E4;
  color: #1C1917;
}
.share-link:hover { border-color: #15803D; background: #F0FDF4; }
.link-copied {
  font-size: 0.8125rem;
  color: #15803D;
  font-weight: 600;
  margin-top: 0.5rem;
}

/* Next steps */
.next-steps {
  text-align: left;
}
.next-steps h3 {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.next-step-link {
  display: block;
  padding: 0.625rem 0;
  font-size: 0.9375rem;
  color: #15803D;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s;
  border-bottom: 1px solid #F5F5F4;
}
.next-step-link:hover { color: #15803D; }

/* ═══════════════════════════════════════════
   MODAL
   ═══════════════════════════════════════════ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 1.5rem;
}
.modal-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}
.modal-content {
  background: white;
  border-radius: 1rem;
  padding: 2rem;
  max-width: 520px;
  width: 100%;
  position: relative;
  transform: translateY(20px) scale(0.97);
  opacity: 0;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  text-align: left;
}
.modal-backdrop.open .modal-content {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.modal-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
}
.modal-content p {
  font-size: 0.875rem;
  color: #57534E;
  line-height: 1.6;
  margin-bottom: 0.75rem;
}
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: #78716C;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}
.modal-close:hover { background: #F5F5F4; }

/* aria-hidden based modal toggling (for legal modals) */
.modal-backdrop[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}
.modal-backdrop[aria-hidden="false"] .modal-content {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.modal-legal {
  max-width: 640px;
  max-height: 80vh;
  overflow-y: auto;
}
.modal-legal h2 {
  font-family: 'Suisse Screen', sans-serif;
  font-size: 1.375rem;
  font-weight: 700;
  margin-bottom: 1rem;
}
.modal-legal h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

/* ═══════════════════════════════════════════
   UTILITY
   ═══════════════════════════════════════════ */
.hidden { display: none !important; }

/* ═══════════════════════════════════════════
   RESPONSIVE — Mobile < 640px
   ═══════════════════════════════════════════ */
@media (max-width: 640px) {
  .funnel-step { padding: 3.5rem 1rem 2rem; align-items: flex-start; }
  .funnel-title { font-size: 1.5rem; }
  .funnel-subtitle { font-size: 0.9375rem; }

  /* Step 1 — Stack cards */
  .loss-cards {
    flex-direction: column;
    align-items: center;
  }
  .loss-card { max-width: 100%; }

  /* Step 3 — Stack map */
  .map-layout {
    flex-direction: column;
  }
  .map-panel {
    width: 100%;
  }
  .map-container { min-height: 280px; }

  /* Step 4 — Wizard full-width cards */
  .wizard-options {
    grid-template-columns: 1fr;
  }
  .wizard-option {
    min-height: 56px;
  }

  /* Step 5 — Smaller hero */
  .loss-hero-amount { font-size: 2.75rem; }

  /* Step 6 — Stack form */
  .form-row { flex-direction: column; gap: 0; }

  /* Step 7 — Stack share buttons */
  .share-buttons { flex-direction: column; }
  .share-btn { justify-content: center; }
  .welcome-savings-amount { font-size: 2rem; }

  .funnel-cta { min-width: auto; width: 100%; }
}

/* ═══════════════════════════════════════════
   RESPONSIVE — Tablet 641-960px
   ═══════════════════════════════════════════ */
@media (min-width: 641px) and (max-width: 960px) {
  .map-layout {
    flex-direction: column;
  }
  .map-panel { width: 100%; }
}

/* ═══════════════════════════════════════════
   DISCOVER MAP INTEGRATION (Step 3)
   ═══════════════════════════════════════════ */

/* SVG marker styles */
.wm-svg-marker { background: none !important; border: none !important; }

/* Discover message badge */
.discover-msg-badge {
  background: #F9FAFB;
  border-radius: 0.75rem;
  padding: 0.875rem 1rem;
  margin-bottom: 1rem;
}
.discover-msg-badge p {
  font-size: 0.875rem;
  line-height: 1.5;
  color: #1C1917;
  margin: 0;
}

/* GRD info panel */
.grd-info-panel {
  margin-bottom: 0.75rem;
  padding: 0.5rem 0;
}

/* CEL section labels */
.cel-section-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0.75rem 0 0.375rem 0;
}

/* CEL cards in funnel */
.funnel-cel-card {
  background: white;
  border: 1px solid #E7E5E4;
  border-radius: 0.75rem;
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  cursor: default;
  transition: border-color 0.2s;
}
.funnel-cel-card:hover { border-color: #15803D; }
.cel-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.25rem;
}
.cel-card-top strong { font-size: 0.8125rem; color: #1C1917; }
.cel-card-bottom {
  font-size: 0.75rem;
  color: #78716C;
}

/* Rebate badges */
.rebate-badge {
  display: inline-block;
  font-size: 0.625rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 999px;
  vertical-align: middle;
}
.rebate-badge-40 { background: #DBEAFE; color: #1E40AF; }
.rebate-badge-20 { background: #FEF3C7; color: #92400E; }

/* Gathering badge */
.gathering-badge {
  font-size: 0.625rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
  background: #FEF3C7;
  color: #92400E;
}

/* NPA mini stats */
.npa-mini-stats {
  display: flex;
  gap: 1rem;
  font-size: 0.75rem;
  color: #78716C;
  padding: 0.5rem 0;
}

/* User "vous êtes ici" marker */
.user-marker-pulse {
  position: relative;
  width: 24px;
  height: 24px;
}
.user-marker-pulse .pin {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 12px;
  height: 12px;
  background: #22C55E;
  border: 2px solid white;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  z-index: 2;
}
.user-marker-pulse .pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  background: rgba(34, 197, 94, 0.3);
  border-radius: 50%;
  animation: pulse-ring 2s ease-out infinite;
  z-index: 1;
}
@keyframes pulse-ring {
  0% { transform: translate(-50%, -50%) scale(0.5); opacity: 1; }
  100% { transform: translate(-50%, -50%) scale(2); opacity: 0; }
}

/* ═══════════════════════════════════════════
   STEP 5 — GRD SIMULATION RESULTS
   ═══════════════════════════════════════════ */

.sim-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin: 1.25rem 0;
}
.sim-detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #F9FAFB;
  border-radius: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
}
.sim-detail-item span { color: #78716C; }
.sim-detail-item strong { color: #1C1917; }

@media (max-width: 640px) {
  .sim-details-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════
   Tooltip (CSS-only, hover + focus) — shared with /carte
   ═══════════════════════════════════════════ */
.wm-tooltip {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: help;
  color: #78716C;
  vertical-align: middle;
  margin-left: 0.25rem;
}
.wm-tooltip:hover,
.wm-tooltip:focus { outline: none; color: #15803D; }
.wm-tooltip-icon { flex-shrink: 0; }
.wm-tooltip-content {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  min-width: 220px;
  max-width: 280px;
  background: #1C1917;
  color: white;
  font-size: 0.7rem;
  font-weight: 400;
  line-height: 1.45;
  padding: 0.5rem 0.625rem;
  border-radius: 0.5rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.18);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s, visibility 0.15s;
  z-index: 1100;
  text-align: left;
  pointer-events: none;
  white-space: normal;
}
.wm-tooltip-content::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: #1C1917;
}
.wm-tooltip-content strong {
  display: block;
  font-weight: 700;
  margin-bottom: 0.25rem;
  color: #FACC15;
}
.wm-tooltip-content b { color: #A7F3D0; font-weight: 600; }
.wm-tooltip:hover .wm-tooltip-content,
.wm-tooltip:focus .wm-tooltip-content,
.wm-tooltip:focus-within .wm-tooltip-content { opacity: 1; visibility: visible; }

@media (max-width: 768px) {
  .wm-tooltip-content {
    left: 0;
    transform: none;
    min-width: 200px;
  }
  .wm-tooltip-content::after { left: 14px; transform: none; }
}
