:root {
  --primary: #1e3a8a;
  --primary-dark: #0f172a;
  --primary-light: #3b82f6;
  --accent: #10b981;
  --accent-hover: #059669;
  --gold: #f59e0b;
  --bg: #f8fafc;
  --surface: #ffffff;
  --surface-border: #e2e8f0;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 20px -2px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 30px -5px rgba(0,0,0,0.12);
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-display: 'Space Grotesk', var(--font);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font);
  background-color: var(--bg);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.top-nav {
  background: #ffffff;
  border-bottom: 1px solid var(--surface-border);
  padding: 14px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
}

.nav-container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.badge-flag {
  font-size: 24px;
  background: #fef3c7;
  padding: 6px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--primary-dark);
  display: block;
}

.brand-sub {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
  display: block;
}

.live-status {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #ecfdf5;
  color: #047857;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid #a7f3d0;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Hero */
.hero-section {
  padding: 40px 0 20px;
  text-align: center;
}

.hero-badge {
  display: inline-block;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 13px;
  font-weight: 700;
  padding: 6px 16px;
  border-radius: 999px;
  margin-bottom: 16px;
  letter-spacing: 0.3px;
}

.hero-title {
  font-size: 38px;
  font-weight: 800;
  color: var(--primary-dark);
  line-height: 1.2;
  margin-bottom: 14px;
  letter-spacing: -0.5px;
}

.gradient-text {
  background: linear-gradient(135deg, #1e3a8a 0%, #059669 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 680px;
  margin: 0 auto 28px;
}

.stats-ticker {
  display: inline-flex;
  background: #ffffff;
  border: 1px solid var(--surface-border);
  padding: 12px 24px;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  align-items: center;
  gap: 20px;
}

.ticker-item {
  display: flex;
  flex-direction: column;
}

.ticker-num {
  font-size: 15px;
  font-weight: 800;
  color: var(--primary-dark);
}

.ticker-label {
  font-size: 11px;
  color: var(--text-muted);
}

.ticker-divider {
  width: 1px;
  height: 28px;
  background: var(--surface-border);
}

/* Main Layout */
.main-content {
  padding: 30px 20px 60px;
}

.calc-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
  align-items: start;
}

/* Wizard */
.wizard-card {
  background: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--surface-border);
  padding: 36px;
  box-shadow: var(--shadow-md);
}

/* Steps Bar */
.steps-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 34px;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.step-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f1f5f9;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.2s ease;
}

.step-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.step-indicator.active .step-num {
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 0 0 4px rgba(30, 58, 138, 0.15);
}

.step-indicator.active .step-label {
  color: var(--primary);
}

.step-line {
  flex: 1;
  height: 2px;
  background: #e2e8f0;
  margin: 0 12px 20px;
}

/* Step Panes */
.step-pane {
  display: none;
}

.step-pane.active {
  display: block;
  animation: fadeIn 0.25s ease-out;
}

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

.step-heading {
  font-size: 22px;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.step-desc {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 26px;
}

/* Form Controls */
.form-group {
  margin-bottom: 24px;
}

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.form-input, .form-select {
  width: 100%;
  padding: 13px 16px;
  border: 1.5px solid var(--surface-border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: inherit;
  color: var(--text-main);
  background: #ffffff;
  transition: border-color 0.15s ease;
}

.form-input:focus, .form-select:focus {
  outline: none;
  border-color: var(--primary-light);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.input-with-icon {
  position: relative;
}

.input-with-icon .icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 16px;
}

.input-with-icon input {
  padding-left: 44px;
}

.field-hint {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Choice Pills */
.pill-grid {
  display: grid;
  gap: 10px;
}

.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.choice-pill {
  background: #f8fafc;
  border: 1.5px solid var(--surface-border);
  padding: 14px;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.choice-pill:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}

.choice-pill.active {
  border-color: var(--primary);
  background: #eff6ff;
  color: var(--primary);
  font-weight: 700;
}

.pill-icon { font-size: 20px; }
.pill-text { font-size: 13px; font-weight: 600; }

/* EPC Selector */
.epc-bar {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  margin-bottom: 6px;
}

.epc-btn {
  padding: 12px 6px;
  border: none;
  border-radius: 6px;
  font-weight: 800;
  font-size: 15px;
  cursor: pointer;
  color: #ffffff;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.epc-btn:hover {
  transform: translateY(-2px);
}

.epc-a { background: #15803d; }
.epc-b { background: #84cc16; color: #14532d; }
.epc-c { background: #eab308; color: #713f12; }
.epc-d { background: #f97316; }
.epc-e { background: #ef4444; }
.epc-f { background: #991b1b; }
.epc-unknown { background: #64748b; font-size: 12px; }

.epc-btn.active {
  box-shadow: 0 0 0 3px #0f172a;
  transform: scale(1.05);
}

/* Measures List */
.measures-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 26px;
}

.measure-card {
  border: 1.5px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 18px;
  background: #ffffff;
  transition: all 0.2s ease;
}

.measure-card.active {
  border-color: #93c5fd;
  background: #f8fafc;
}

.measure-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.measure-info {
  flex: 1;
}

.measure-title {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: var(--primary-dark);
}

.measure-sub {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
}

.measure-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  background: #e0e7ff;
  color: #3730a3;
}

.measure-badge.green {
  background: #dcfce7;
  color: #15803d;
}

.measure-controls {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--surface-border);
}

.measure-controls.hidden {
  display: none;
}

.control-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
}

.val-display {
  color: var(--primary);
  font-weight: 700;
}

.range-slider {
  width: 100%;
  accent-color: var(--primary);
  height: 6px;
  border-radius: 4px;
  background: #e2e8f0;
}

.radio-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.radio-chip {
  position: relative;
  cursor: pointer;
}

.radio-chip input {
  position: absolute;
  opacity: 0;
}

.radio-chip span {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid var(--surface-border);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  background: #ffffff;
  transition: all 0.15s ease;
}

.radio-chip input:checked + span {
  border-color: var(--primary);
  background: #eff6ff;
  color: var(--primary);
}

.sub-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-muted);
  cursor: pointer;
}

/* Custom Checkbox */
.custom-checkbox {
  position: relative;
  display: inline-block;
  width: 22px;
  height: 22px;
}

.custom-checkbox input {
  opacity: 0;
  width: 0;
  height: 0;
}

.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 22px;
  width: 22px;
  background-color: #f1f5f9;
  border: 1.5px solid #cbd5e1;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.custom-checkbox:hover input ~ .checkmark {
  background-color: #e2e8f0;
}

.custom-checkbox input:checked ~ .checkmark {
  background-color: var(--primary);
  border-color: var(--primary);
}

.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

.custom-checkbox input:checked ~ .checkmark:after {
  display: block;
}

.custom-checkbox .checkmark:after {
  left: 7px;
  top: 3px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* Target EPC group */
.target-epc-box {
  background: #f8fafc;
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--surface-border);
  margin-bottom: 26px;
}

.target-pill-group {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 8px;
}

.target-pill {
  background: #ffffff;
  border: 1.5px solid var(--surface-border);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.target-pill.active {
  border-color: #0f172a;
  background: #f1f5f9;
  box-shadow: var(--shadow-sm);
}

.target-tag {
  font-size: 13px;
  font-weight: 800;
  padding: 2px 10px;
  border-radius: 4px;
}

.target-sub {
  font-size: 11px;
  font-weight: 700;
  color: #059669;
}

/* Income Slider */
.income-slider-wrap {
  background: #f8fafc;
  border: 1px solid var(--surface-border);
  padding: 18px;
  border-radius: var(--radius-sm);
}

.income-bracket-tag {
  background: #dcfce7;
  color: #15803d;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
}

.income-val {
  font-size: 17px;
  font-weight: 800;
  color: var(--primary-dark);
}

.income-ticks {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

/* Number Stepper */
.number-stepper {
  display: flex;
  align-items: center;
  gap: 14px;
}

.step-btn {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--surface-border);
  background: #ffffff;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.step-btn:hover { background: #f1f5f9; }

.step-val {
  font-size: 15px;
  font-weight: 700;
  min-width: 140px;
  text-align: center;
}

/* Step 4: Results & Lead Dossier */
.result-hero {
  text-align: center;
  padding: 24px;
  background: linear-gradient(135deg, #eff6ff 0%, #ecfdf5 100%);
  border-radius: var(--radius-md);
  border: 1px solid #bfdbfe;
  margin-bottom: 24px;
}

.celebrate-badge {
  display: inline-block;
  background: #10b981;
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.result-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary-dark);
}

.subsidy-big-number {
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 800;
  color: #047857;
  line-height: 1.1;
  margin: 8px 0;
}

.subsidy-big-number .currency {
  font-size: 34px;
  margin-right: 4px;
  vertical-align: super;
}

.result-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

/* Breakdown */
.breakdown-box {
  background: #ffffff;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 18px;
  margin-bottom: 20px;
}

.box-title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 12px;
}

.breakdown-items {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.breakdown-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: #f8fafc;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.breakdown-item-name {
  font-size: 14px;
  font-weight: 600;
}

.breakdown-item-note {
  font-size: 11px;
  color: var(--text-muted);
}

.breakdown-item-amount {
  font-size: 16px;
  font-weight: 800;
  color: #047857;
}

/* Impact Grid */
.impact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 28px;
}

.impact-card {
  background: #f8fafc;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.impact-icon {
  font-size: 24px;
}

.impact-val {
  font-size: 15px;
  font-weight: 800;
  color: var(--primary-dark);
  display: block;
}

.impact-label {
  font-size: 11px;
  color: var(--text-muted);
  display: block;
}

/* Lead Dossier Card */
.lead-dossier-card {
  background: #ffffff;
  border: 2px solid #3b82f6;
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.15);
}

.dossier-tag {
  display: inline-block;
  background: #dbeafe;
  color: #1e40af;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  margin-bottom: 6px;
}

.dossier-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--primary-dark);
}

.dossier-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
  margin-bottom: 20px;
}

.lead-form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 16px 0 20px;
}

.consent-text {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
}

.btn-submit {
  width: 100%;
  padding: 16px;
  font-size: 16px;
  font-weight: 800;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
  transition: all 0.2s ease;
}

.btn-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
}

.lead-feedback {
  margin-top: 16px;
  padding: 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
}

.lead-feedback.success {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.lead-feedback.error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.trust-footer {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 18px;
  font-size: 11px;
  color: var(--text-muted);
}

/* Buttons */
.btn-row {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.btn {
  padding: 14px 24px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  font-family: inherit;
}

.btn-primary {
  background: var(--primary);
  color: #ffffff;
  flex: 1;
}

.btn-primary:hover {
  background: #1d4ed8;
}

.btn-secondary {
  background: #f1f5f9;
  color: var(--text-main);
  border: 1px solid var(--surface-border);
}

.btn-secondary:hover {
  background: #e2e8f0;
}

.btn-accent {
  background: var(--accent);
  color: #ffffff;
  flex: 1;
}

.btn-accent:hover {
  background: var(--accent-hover);
}

/* Sidebar */
.sidebar-summary {
  position: sticky;
  top: 90px;
}

.summary-card {
  background: #ffffff;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-md);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}

.summary-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.summary-tag {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--primary-light);
  letter-spacing: 0.5px;
}

.epc-chip {
  background: #fef08a;
  color: #854d0e;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
}

.summary-price-box {
  background: #f8fafc;
  border-radius: 10px;
  padding: 14px;
  text-align: center;
  margin-bottom: 16px;
  border: 1px solid #e2e8f0;
}

.summary-label {
  font-size: 12px;
  color: var(--text-muted);
}

.summary-val {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 800;
  color: #047857;
  line-height: 1.1;
  margin-top: 4px;
}

.summary-val .sym {
  font-size: 22px;
  vertical-align: super;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 6px 0;
  border-bottom: 1px dashed #f1f5f9;
}

.summary-row strong {
  color: var(--primary-dark);
}

.summary-divider {
  height: 1px;
  background: var(--surface-border);
  margin: 14px 0;
}

.summary-help {
  display: flex;
  gap: 10px;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* FAQ */
.faq-section {
  padding: 40px 20px;
}

.section-title {
  text-align: center;
  font-size: 26px;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 30px;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.faq-item {
  background: #ffffff;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.faq-item h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 8px;
}

.faq-item p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Footer */
.site-footer {
  background: #ffffff;
  border-top: 1px solid var(--surface-border);
  padding: 30px 0;
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

.footer-sub {
  font-size: 11px;
  margin-top: 4px;
  color: #94a3b8;
}

/* Mobile Responsiveness */
@media (max-width: 900px) {
  .calc-layout {
    grid-template-columns: 1fr;
  }
  .sidebar-summary {
    position: static;
  }
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .lead-form-grid {
    grid-template-columns: 1fr;
  }
  .impact-grid {
    grid-template-columns: 1fr;
  }
  .faq-grid {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 28px;
  }
  .wizard-card {
    padding: 20px;
  }
}
