/* ============================================================
   CALCULADORA DE ROI — LIMPEZA DE PLACAS SOLARES
   Premium Dark Theme | LoopSell Energia 2026
   ============================================================ */

:root {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: rgba(30, 41, 59, 0.7);
  --bg-card-hover: rgba(30, 41, 59, 0.9);
  --bg-input: rgba(15, 23, 42, 0.8);
  --border-subtle: rgba(148, 163, 184, 0.15);
  --border-focus: rgba(59, 130, 246, 0.5);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent-blue: #3b82f6;
  --accent-blue-glow: rgba(59, 130, 246, 0.25);
  --accent-green: #22c55e;
  --accent-green-glow: rgba(34, 197, 94, 0.2);
  --accent-red: #ef4444;
  --accent-red-glow: rgba(239, 68, 68, 0.2);
  --accent-amber: #f59e0b;
  --accent-amber-glow: rgba(245, 158, 11, 0.15);
  --accent-violet: #8b5cf6;
  --gradient-hero: linear-gradient(135deg, #0f172a 0%, #1a1500 50%, #0f172a 100%);
  --gradient-card: linear-gradient(145deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.6));
  --gradient-green: linear-gradient(135deg, #22c55e, #16a34a);
  --gradient-red: linear-gradient(135deg, #ef4444, #dc2626);
  --gradient-blue: linear-gradient(135deg, #3b82f6, #6366f1);
  --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
  --shadow-glow-blue: 0 0 40px rgba(59, 130, 246, 0.15);
  --shadow-glow-red: 0 0 40px rgba(239, 68, 68, 0.15);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--gradient-hero);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ─── LAYOUT ─── */
.calc-wrapper {
  max-width: 720px;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

/* ─── TOP BAR ─── */
.top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 0;
  margin-bottom: 1.5rem;
}

.logo-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.logo-icon {
  width: 32px;
  height: 32px;
  background: var(--gradient-blue);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 13px;
  color: #fff;
}

.logo-text {
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.5);
}

.top-cta {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-blue);
  text-decoration: none;
  padding: 0.4rem 0.75rem;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 8px;
  transition: var(--transition);
}

.top-cta:hover {
  background: rgba(59, 130, 246, 0.2);
  border-color: rgba(59, 130, 246, 0.4);
}

/* ─── MODE TOGGLE ─── */
.mode-toggle {
  display: flex;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 4px;
  margin-bottom: 1.5rem;
  backdrop-filter: blur(12px);
}

.mode-btn {
  flex: 1;
  padding: 0.6rem 1rem;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.mode-btn.active {
  background: var(--gradient-blue);
  color: #fff;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.mode-btn:not(.active):hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

/* ─── HEADER ─── */
.calc-header {
  text-align: center;
  margin-bottom: 2rem;
}

.calc-header h1 {
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #fff 0%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.calc-header .subtitle {
  font-size: 0.95rem;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto;
}

.highlight-red {
  color: var(--accent-red);
  font-weight: 700;
}

.highlight-blue {
  color: var(--accent-blue);
  font-weight: 700;
}

/* ─── AI STAT BANNER ─── */
.ai-stat-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(239, 68, 68, 0.08));
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
  animation: pulse-border 3s ease-in-out infinite;
}

@keyframes pulse-border {
  0%, 100% { border-color: rgba(245, 158, 11, 0.25); }
  50% { border-color: rgba(245, 158, 11, 0.5); }
}

.ai-stat-banner .ai-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.ai-stat-banner .ai-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.ai-stat-banner .ai-text strong {
  color: var(--accent-amber);
}

/* ─── FORM CARD ─── */
.form-card {
  background: var(--gradient-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.75rem;
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow-card);
  margin-bottom: 1.5rem;
}

.form-card-title {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group:last-child {
  margin-bottom: 0;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.form-group label .unit {
  font-weight: 400;
  color: var(--text-muted);
  font-size: 0.8rem;
}

.input-wrapper {
  position: relative;
}

.input-wrapper .prefix {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  pointer-events: none;
}

.input-wrapper .suffix {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.9rem;
  pointer-events: none;
}

input[type="number"],
input[type="text"] {
  width: 100%;
  padding: 0.85rem 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  color: var(--text-primary);
  font-family: var(--font);
  font-size: 1.1rem;
  font-weight: 600;
  transition: var(--transition);
  -moz-appearance: textfield;
}

input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type="number"]:focus,
input[type="text"]:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px var(--accent-blue-glow);
}

input.has-prefix {
  padding-left: 2.5rem;
}

input.has-suffix {
  padding-right: 2.5rem;
}

/* ─── DAYS SELECTOR ─── */
.days-selector {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.day-chip {
  position: relative;
}

.day-chip input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.day-chip label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 44px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 0;
}

.day-chip input:checked + label {
  background: rgba(59, 130, 246, 0.15);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.15);
}

.day-chip label:hover {
  border-color: rgba(148, 163, 184, 0.3);
  color: var(--text-secondary);
}

/* ─── SLIDER / RANGE ─── */
.range-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.range-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.range-value {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--accent-red);
}

input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  background: linear-gradient(90deg, var(--accent-green) 0%, var(--accent-amber) 50%, var(--accent-red) 100%);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  background: var(--text-primary);
  border: 3px solid var(--accent-blue);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: var(--transition);
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 2px 12px rgba(59, 130, 246, 0.4);
}

input[type="range"]::-moz-range-thumb {
  width: 22px;
  height: 22px;
  background: var(--text-primary);
  border: 3px solid var(--accent-blue);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* ─── RESULTS ─── */
.results-section {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  pointer-events: none;
}

.results-section.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.result-card {
  background: var(--gradient-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  backdrop-filter: blur(12px);
  transition: var(--transition);
}

.result-card:hover {
  border-color: rgba(148, 163, 184, 0.25);
  transform: translateY(-2px);
}

.result-card .label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.result-card .value {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--accent-green);
  line-height: 1;
}

.result-card .detail {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.result-card.green .value { color: var(--accent-green); }
.result-card.blue .value { color: var(--accent-blue); }

/* ─── LOSS ALERT ─── */
.loss-alert {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.12), rgba(220, 38, 38, 0.08));
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
  animation: shake-subtle 0.5s ease-in-out;
}

@keyframes shake-subtle {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-3px); }
  40% { transform: translateX(3px); }
  60% { transform: translateX(-2px); }
  80% { transform: translateX(2px); }
}

.loss-alert::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(239, 68, 68, 0.08) 0%, transparent 70%);
  animation: loss-pulse 4s ease-in-out infinite;
}

@keyframes loss-pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.loss-alert .alert-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.loss-alert .alert-icon {
  font-size: 1.5rem;
}

.loss-alert .alert-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--accent-red);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.loss-values {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.loss-item {
  text-align: center;
}

.loss-item .loss-period {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(239, 68, 68, 0.7);
  margin-bottom: 0.25rem;
}

.loss-item .loss-amount {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--accent-red);
  line-height: 1;
  text-shadow: 0 0 30px rgba(239, 68, 68, 0.3);
}

.loss-item .loss-detail {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.loss-message {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(239, 68, 68, 0.15);
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  position: relative;
  z-index: 1;
}

.loss-message strong {
  color: var(--accent-red);
}

/* ─── ROI SECTION ─── */
.roi-section {
  background: linear-gradient(145deg, rgba(34, 197, 94, 0.08), rgba(59, 130, 246, 0.06));
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
}

.roi-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.06) 0%, transparent 60%);
  pointer-events: none;
}

.roi-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 1;
}

.roi-icon {
  font-size: 1.5rem;
}

.roi-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--accent-green);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.roi-premise {
  position: relative;
  z-index: 1;
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  background: rgba(34, 197, 94, 0.08);
  border-radius: var(--radius-xs);
  border-left: 3px solid var(--accent-green);
}

.roi-premise p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

.highlight-green {
  color: var(--accent-green);
  font-weight: 700;
}

.roi-investment {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-xs);
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 1;
}

.roi-invest-item {
  text-align: center;
}

.roi-invest-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.roi-invest-value {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-primary);
}

.roi-invest-period {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--text-muted);
}

.roi-invest-divider {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-muted);
}

.roi-results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1rem;
  position: relative;
  z-index: 1;
}

.roi-result-card {
  padding: 1rem;
  border-radius: var(--radius-xs);
  text-align: center;
}

.roi-result-card.recovery {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
}

.roi-result-card.profit {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.roi-result-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.roi-result-card.recovery .roi-result-value {
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--accent-green);
}

.roi-result-card.profit .roi-result-value {
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--accent-blue);
}

.roi-result-detail {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.roi-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  position: relative;
  z-index: 1;
}

.roi-hero-card {
  padding: 1.25rem 1rem;
  border-radius: var(--radius-sm);
  text-align: center;
  position: relative;
}

.roi-hero-card.payback {
  background: linear-gradient(145deg, rgba(245, 158, 11, 0.12), rgba(245, 158, 11, 0.06));
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.roi-hero-card.roi-pct {
  background: linear-gradient(145deg, rgba(139, 92, 246, 0.12), rgba(139, 92, 246, 0.06));
  border: 1px solid rgba(139, 92, 246, 0.25);
}

.roi-hero-emoji {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}

.roi-hero-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.roi-hero-card.payback .roi-hero-value {
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent-amber);
  line-height: 1;
}

.roi-hero-card.roi-pct .roi-hero-value {
  font-size: 2rem;
  font-weight: 900;
  color: var(--accent-violet);
  line-height: 1;
}

.roi-hero-unit {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.roi-annual-summary {
  position: relative;
  z-index: 1;
  margin-bottom: 1rem;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-xs);
}

.roi-annual-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.roi-annual-row:last-child {
  border-bottom: none;
}

.roi-annual-row.total {
  padding-top: 0.75rem;
  margin-top: 0.25rem;
  border-top: 1px solid rgba(34, 197, 94, 0.3);
  border-bottom: none;
}

.roi-annual-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.roi-annual-value {
  font-size: 0.9rem;
  font-weight: 700;
}

.roi-annual-value.green { color: var(--accent-green); }
.roi-annual-value.muted { color: var(--text-muted); }
.roi-annual-value.green-bold {
  color: var(--accent-green);
  font-size: 1.1rem;
  font-weight: 900;
  text-shadow: 0 0 20px rgba(34, 197, 94, 0.3);
}

.roi-verdict {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: var(--radius-xs);
  position: relative;
  z-index: 1;
}

.roi-verdict-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
}

.roi-verdict-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-green);
  line-height: 1.4;
}

/* ROI responsive */
@media (max-width: 480px) {
  .roi-results-grid,
  .roi-hero-grid {
    grid-template-columns: 1fr;
  }

  .roi-hero-card .roi-hero-value {
    font-size: 1.75rem;
  }

  .roi-investment {
    flex-direction: column;
    gap: 0.5rem;
  }

  .roi-invest-divider {
    display: none;
  }
}

/* ─── CTA SECTION ─── */
.cta-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.cta-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: var(--gradient-green);
  color: #fff;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.3);
}

.cta-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(34, 197, 94, 0.4);
}

.cta-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.25);
  color: var(--accent-blue);
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.cta-secondary:hover {
  background: rgba(59, 130, 246, 0.2);
  border-color: rgba(59, 130, 246, 0.4);
  transform: translateY(-1px);
}

/* ─── VIDEO SECTION ─── */
.video-section {
  background: var(--gradient-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.5rem;
  backdrop-filter: blur(12px);
  margin-bottom: 1.5rem;
  text-align: center;
}

.video-section .video-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-violet);
  margin-bottom: 0.75rem;
}

.video-section h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.video-section p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.video-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.25rem;
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid rgba(139, 92, 246, 0.25);
  color: var(--accent-violet);
  font-family: var(--font);
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: var(--radius-xs);
  text-decoration: none;
  transition: var(--transition);
}

.video-link:hover {
  background: rgba(139, 92, 246, 0.2);
  border-color: rgba(139, 92, 246, 0.4);
}

/* ─── FOOTER ─── */
.calc-footer {
  text-align: center;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border-subtle);
}

.calc-footer p {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.calc-footer a {
  color: var(--accent-blue);
  text-decoration: none;
}

/* ─── ANIMATED COUNTER ─── */
.animated-value {
  transition: all 0.4s ease-out;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 480px) {
  .calc-wrapper {
    padding: 1rem 0.75rem 2rem;
  }

  .calc-header h1 {
    font-size: 1.4rem;
  }

  .results-grid {
    grid-template-columns: 1fr;
  }

  .loss-values {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .loss-item .loss-amount {
    font-size: 1.5rem;
  }

  .mode-btn {
    font-size: 0.78rem;
    padding: 0.5rem 0.5rem;
  }

  .day-chip label {
    width: 42px;
    height: 40px;
    font-size: 0.75rem;
  }

  .result-card .value {
    font-size: 1.2rem;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .calc-header h1 {
    font-size: 1.5rem;
  }
}

/* ─── SPARKLE / PARTICLES (decorative background) ─── */
.bg-decoration {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.bg-decoration .orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.3;
  animation: float 20s ease-in-out infinite;
}

.bg-decoration .orb-1 {
  width: 300px;
  height: 300px;
  background: rgba(245, 158, 11, 0.18);
  top: -100px;
  right: -100px;
}

.bg-decoration .orb-2 {
  width: 250px;
  height: 250px;
  background: rgba(234, 179, 8, 0.12);
  bottom: 10%;
  left: -80px;
  animation-delay: -7s;
}

.bg-decoration .orb-3 {
  width: 200px;
  height: 200px;
  background: rgba(249, 115, 22, 0.1);
  top: 40%;
  right: -60px;
  animation-delay: -14s;
}

/* ─── SOLAR-SPECIFIC COMPONENTS ─── */

.logo-segment {
  color: var(--accent-amber);
  font-weight: 800;
}

.form-hint {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  font-style: italic;
}

.calc-result-inline {
  padding: 0.75rem 1rem;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-xs);
}

.inline-result {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

.result-big {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--accent-amber);
}

.result-unit {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.range-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* Location Selector */
.location-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.loc-chip {
  padding: 0.7rem 0.5rem;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  line-height: 1.3;
}

.loc-chip small {
  font-weight: 400;
  font-size: 0.68rem;
  color: var(--text-muted);
}

.loc-chip.active {
  background: rgba(245, 158, 11, 0.15);
  border-color: var(--accent-amber);
  color: var(--accent-amber);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.15);
}

.loc-chip:not(.active):hover {
  border-color: rgba(148, 163, 184, 0.3);
  color: var(--text-primary);
}

.location-info {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-xs);
  border-left: 3px solid var(--accent-amber);
}

/* Solar Result Cards */
.result-card.solar {
  border-color: rgba(34, 197, 94, 0.25);
  background: linear-gradient(145deg, rgba(34, 197, 94, 0.08), rgba(15, 23, 42, 0.6));
}
.result-card.solar .value { color: var(--accent-green); }

.result-card.dirty {
  border-color: rgba(239, 68, 68, 0.25);
  background: linear-gradient(145deg, rgba(239, 68, 68, 0.08), rgba(15, 23, 42, 0.6));
}
.result-card.dirty .value { color: var(--accent-red); }

/* Cleaning Schedule */
.cleaning-schedule {
  position: relative;
  z-index: 1;
  margin-bottom: 1.25rem;
  padding: 1rem;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-sm);
}

.schedule-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.schedule-icon { font-size: 1.25rem; }

.schedule-title {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent-amber);
}

.schedule-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.schedule-card {
  padding: 0.75rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-xs);
  text-align: center;
  border: 1px solid rgba(245, 158, 11, 0.15);
}

.schedule-card.monitor {
  border-color: rgba(59, 130, 246, 0.2);
  background: rgba(59, 130, 246, 0.06);
}

.schedule-freq {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--accent-amber);
  margin-bottom: 0.25rem;
}

.schedule-card.monitor .schedule-freq {
  color: var(--accent-blue);
  font-size: 0.8rem;
}

.schedule-detail {
  font-size: 0.72rem;
  color: var(--text-muted);
}

@media (max-width: 480px) {
  .location-selector { grid-template-columns: 1fr 1fr; }
  .schedule-grid { grid-template-columns: 1fr; }
  .upgrade-comparison { flex-direction: column; }
  .upgrade-arrow { transform: rotate(90deg); }
}

/* ─── UPGRADE SECTION ─── */
.upgrade-section {
  background: linear-gradient(145deg, rgba(59, 130, 246, 0.08), rgba(139, 92, 246, 0.06));
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-radius: var(--radius);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}

.upgrade-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.upgrade-icon { font-size: 1.5rem; }

.upgrade-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--accent-blue);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.upgrade-premise {
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  background: rgba(59, 130, 246, 0.08);
  border-radius: var(--radius-xs);
  border-left: 3px solid var(--accent-blue);
}

.upgrade-premise p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

.upgrade-form {
  margin-bottom: 1.25rem;
  border-color: rgba(59, 130, 246, 0.2);
}

.upgrade-comparison {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.upgrade-card {
  flex: 1;
  padding: 1.25rem 1rem;
  border-radius: var(--radius-sm);
  text-align: center;
  position: relative;
}

.upgrade-card.current {
  background: rgba(148, 163, 184, 0.08);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.upgrade-card.new {
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.upgrade-card-badge {
  font-size: 0.6rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  display: inline-block;
}

.upgrade-card.current .upgrade-card-badge {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-muted);
}

.upgrade-card.new .upgrade-card-badge {
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent-green);
}

.upgrade-card-power {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.upgrade-card-kwp {
  font-size: 1.3rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.upgrade-card.current .upgrade-card-kwp { color: var(--text-secondary); }
.upgrade-card.new .upgrade-card-kwp { color: var(--accent-green); }

.upgrade-card-gen {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}

.upgrade-card-money {
  font-size: 0.9rem;
  font-weight: 700;
}

.upgrade-card.current .upgrade-card-money { color: var(--text-secondary); }
.upgrade-card.new .upgrade-card-money { color: var(--accent-green); }

.upgrade-arrow {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--accent-blue);
  flex-shrink: 0;
}

.upgrade-gain {
  padding: 1rem;
  background: rgba(15, 23, 42, 0.5);
  border-radius: var(--radius-xs);
  margin-bottom: 1rem;
}

.upgrade-gain-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.upgrade-gain-row:last-child { border-bottom: none; }

.upgrade-gain-row.total {
  padding-top: 0.75rem;
  margin-top: 0.25rem;
  border-top: 1px solid rgba(34, 197, 94, 0.3);
  border-bottom: none;
}

.upgrade-gain-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.upgrade-gain-value {
  font-size: 0.9rem;
  font-weight: 700;
}

.upgrade-gain-value.green { color: var(--accent-green); }
.upgrade-gain-value.green-bold {
  color: var(--accent-green);
  font-size: 1.1rem;
  font-weight: 900;
  text-shadow: 0 0 20px rgba(34, 197, 94, 0.3);
}

@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  33% { transform: translate(30px, -20px); }
  66% { transform: translate(-20px, 15px); }
}

/* All content above the bg */
.calc-wrapper {
  position: relative;
  z-index: 1;
}
