/* ═══════════════════════════════════════════════════════════════
   EV_aluate — Professional EV Intelligence Platform Styles
   Theme: Dark Quantum EV — Electric, Minimal, Futuristic
═══════════════════════════════════════════════════════════════ */

/* ─── Design Tokens ─────────────────────────────────────────── */
:root {
  --bg-void:       #030b14;
  --bg-deep:       #050f1c;
  --bg-surface:    #0a1628;
  --bg-elevated:   #0f1e35;
  --bg-glass:      rgba(10, 22, 40, 0.7);

  --cyan:          #00d4ff;
  --cyan-dim:      rgba(0, 212, 255, 0.15);
  --cyan-glow:     rgba(0, 212, 255, 0.35);
  --green:         #00ff88;
  --green-dim:     rgba(0, 255, 136, 0.15);
  --green-glow:    rgba(0, 255, 136, 0.3);
  --violet:        #7c3aed;
  --violet-dim:    rgba(124, 58, 237, 0.15);
  --amber:         #f59e0b;
  --red:           #ef4444;

  --text-primary:  #e2eaf5;
  --text-secondary:#8fa3be;
  --text-muted:    #4a6180;
  --text-accent:   #00d4ff;

  --border:        rgba(0, 212, 255, 0.12);
  --border-bright: rgba(0, 212, 255, 0.35);

  --nav-h:         70px;
  --radius:        14px;
  --radius-lg:     22px;
  --radius-full:   999px;

  --transition:    0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.15s ease;

  --shadow-glass:  0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px var(--border);
  --shadow-glow:   0 0 40px var(--cyan-glow);
}

/* ─── Reset & Base ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  font-family: 'Rajdhani', sans-serif;
  background: var(--bg-void);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--violet); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--cyan); }

/* ─── Typography ────────────────────────────────────────────── */
h1, h2, h3, h4, h5 {
  font-family: 'Orbitron', monospace;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

code {
  font-family: 'Space Mono', monospace;
  font-size: 0.85em;
  color: var(--cyan);
  background: var(--cyan-dim);
  padding: 2px 7px;
  border-radius: 4px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--cyan), var(--green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── Layout ────────────────────────────────────────────────── */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 48px);
}

.page-wrapper { padding-top: var(--nav-h); }

/* ─── Navigation ────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 1000;
  backdrop-filter: blur(20px) saturate(180%);
  background: rgba(3, 11, 20, 0.85);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.navbar.scrolled {
  background: rgba(3, 11, 20, 0.96);
  box-shadow: 0 4px 30px rgba(0,0,0,0.6);
}

.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
  height: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
  margin-right: auto; /* push everything else right */
}

.logo-icon {
  width: 38px; height: 38px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-bright);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition);
}

.nav-logo:hover .logo-icon {
  box-shadow: 0 0 20px var(--cyan-glow);
  border-color: var(--cyan);
}

.logo-text {
  font-family: 'Orbitron', monospace;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: 1px;
}

.logo-accent { color: var(--cyan); }

.nav-links {
  display: flex;
  list-style: none;
  gap: 4px;
  flex-shrink: 0;
  margin-right: 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: var(--transition);
  white-space: nowrap;
}

.nav-link i { font-size: 0.8rem; }

.nav-link:hover {
  color: var(--cyan);
  background: var(--cyan-dim);
}

.nav-link.active {
  color: var(--bg-void);
  background: linear-gradient(135deg, var(--cyan), var(--green));
  box-shadow: 0 4px 16px var(--cyan-glow);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* API Status */
.api-status {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: var(--transition);
  white-space: nowrap;
  flex-shrink: 0;
}

.status-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  animation: pulse-dot 2s infinite;
}

.api-status.connected .status-dot { background: var(--green); }
.api-status.connected .status-text { color: var(--green); }
.api-status.error .status-dot { background: var(--red); }
.api-status.error .status-text { color: var(--red); }

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(1.3); }
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 40px; height: 40px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  padding: 11px 9px;
  z-index: 1100;
  flex-shrink: 0;
  transition: var(--transition);
}

.hamburger:hover {
  border-color: var(--border-bright);
  background: var(--cyan-dim);
}

.hamburger span {
  display: block;
  width: 100%; height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  transform-origin: center;
}

.hamburger.active {
  border-color: var(--cyan);
  background: var(--cyan-dim);
}

.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); background: var(--cyan); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); background: var(--cyan); }

/* Mobile Menu Overlay */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(3, 11, 20, 0.85);
  backdrop-filter: blur(12px);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.mobile-menu-overlay.open {
  opacity: 1;
}

.mobile-menu {
  position: absolute;
  top: 0; right: 0;
  width: min(320px, 85vw);
  height: 100%;
  background: var(--bg-surface);
  border-left: 1px solid var(--border);
  padding: 90px 32px 40px;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}

.mobile-menu-overlay.open .mobile-menu {
  transform: translateX(0);
}

.mobile-menu-logo {
  font-family: 'Orbitron', monospace;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 40px;
}

.mobile-menu-logo span { color: var(--cyan); }

.mobile-nav-links { list-style: none; display: flex; flex-direction: column; gap: 4px; }

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 1.05rem;
  font-weight: 600;
  transition: var(--transition);
}

.mobile-nav-link:hover, .mobile-nav-link.active {
  color: var(--cyan);
  background: var(--cyan-dim);
}

.mobile-menu-footer {
  margin-top: auto;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ─── Pages ─────────────────────────────────────────────────── */
.page { min-height: 100vh; }
.page.hidden { display: none; }

/* ─── Hero ──────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: calc(100vh - var(--nav-h));
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  overflow: hidden;
  padding: 60px clamp(16px, 4vw, 80px);
  gap: 40px;
  max-width: 1400px;
  margin: 0 auto;
}

#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 0;
}

.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  background: var(--cyan-dim);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--cyan);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 28px;
}

.hero-title {
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  line-height: 1.05;
  margin-bottom: 20px;
}

.hero-title .line1 { color: var(--text-secondary); display: block; }
.hero-title .line2 { color: var(--text-primary); display: block; }
.hero-title .line3 { display: block; }

.hero-subtitle {
  font-family: 'Rajdhani', sans-serif;
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 36px;
  max-width: 520px;
}

.hero-subtitle strong { color: var(--cyan); font-weight: 600; }

.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-3d-container {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 420px;
}

#three-canvas {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
  background: radial-gradient(ellipse at center, rgba(0,212,255,0.06) 0%, transparent 70%);
}

.holo-rings {
  position: absolute;
  inset: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.holo-ring {
  position: absolute;
  border: 1px solid;
  border-radius: 50%;
  animation: holo-spin linear infinite;
}

.holo-ring.r1 {
  width: 280px; height: 280px;
  border-color: rgba(0, 212, 255, 0.2);
  animation-duration: 8s;
}

.holo-ring.r2 {
  width: 340px; height: 340px;
  border-color: rgba(0, 255, 136, 0.15);
  animation-duration: 12s;
  animation-direction: reverse;
  transform: rotateX(60deg);
}

.holo-ring.r3 {
  width: 400px; height: 400px;
  border-color: rgba(124, 58, 237, 0.12);
  animation-duration: 18s;
  transform: rotateX(30deg) rotateY(20deg);
}

@keyframes holo-spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.holo-label {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Space Mono', monospace;
  font-size: 0.65rem;
  color: var(--cyan);
  letter-spacing: 3px;
  opacity: 0.6;
}

.scan-line {
  position: absolute;
  left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0.4;
  animation: scan 3s linear infinite;
}

@keyframes scan {
  0%   { top: 10%; }
  100% { top: 90%; }
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.65rem;
  font-family: 'Space Mono', monospace;
  letter-spacing: 2px;
  z-index: 2;
  animation: float-up 2s ease-in-out infinite alternate;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, transparent, var(--cyan));
}

@keyframes float-up {
  from { transform: translateX(-50%) translateY(0); }
  to   { transform: translateX(-50%) translateY(-8px); }
}

/* ─── Stats Bar ─────────────────────────────────────────────── */
.stats-bar {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 28px clamp(16px, 4vw, 48px);
}

.stats-container {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 4vw, 60px);
  flex-wrap: wrap;
}

.stat-item {
  text-align: center;
  min-width: 120px;
}

.stat-item .stat-val {
  font-family: 'Orbitron', monospace;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  background: linear-gradient(135deg, var(--cyan), var(--green));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 6px;
}

.stat-item .stat-lbl {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ─── Sections ──────────────────────────────────────────────── */
.section {
  padding: clamp(48px, 8vw, 96px) 0;
}

.dark-section {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-header {
  text-align: center;
  margin-bottom: clamp(36px, 6vw, 64px);
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 16px;
  background: var(--violet-dim);
  border: 1px solid rgba(124, 58, 237, 0.3);
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  color: #a78bfa;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  color: var(--text-primary);
  margin-bottom: 12px;
}

.section-sub {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
}

/* ─── Buttons ───────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 28px;
  background: linear-gradient(135deg, var(--cyan), #0066ff);
  color: #fff;
  font-family: 'Orbitron', monospace;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 24px var(--cyan-glow);
  white-space: nowrap;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px var(--cyan-glow);
}

.btn-primary:active { transform: translateY(0); }

.btn-primary.btn-lg { padding: 15px 36px; font-size: 0.9rem; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 13px 26px;
  background: transparent;
  color: var(--cyan);
  font-family: 'Orbitron', monospace;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-ghost:hover {
  background: var(--cyan-dim);
  border-color: var(--cyan);
  transform: translateY(-2px);
}

.btn-ghost-sm {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  background: transparent;
  color: var(--text-muted);
  font-family: 'Rajdhani', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
}

.btn-ghost-sm:hover { color: var(--cyan); border-color: var(--border-bright); }

/* ─── Glass Cards ───────────────────────────────────────────── */
.glass-card {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 32px);
  box-shadow: var(--shadow-glass);
  transition: var(--transition);
}

.glass-card:hover {
  border-color: rgba(0, 212, 255, 0.22);
}

.card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.card-header-row h3 {
  font-size: 1rem;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 9px;
}

.card-header-row h3 i { color: var(--cyan); }
.card-header-row h4 { font-size: 0.9rem; color: var(--text-primary); display: flex; align-items: center; gap: 8px; }
.card-header-row h4 i { color: var(--cyan); }

.card-sub { font-size: 0.82rem; color: var(--text-muted); margin-top: 4px; }

/* ─── Features Grid ─────────────────────────────────────────── */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.5vw, 28px);
}

.feature-card {
  position: relative;
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 36px);
  transition: var(--transition);
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 60%, var(--cyan-dim) 100%);
  opacity: 0;
  transition: var(--transition);
  border-radius: var(--radius-lg);
}

.feature-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0,0,0,0.5), 0 0 0 1px var(--border-bright);
}

.feature-card:hover::before { opacity: 1; }

.feature-card.featured {
  border-color: rgba(0, 212, 255, 0.3);
  background: linear-gradient(135deg, rgba(0,212,255,0.06), rgba(124,58,237,0.06));
}

.feature-badge-top {
  position: absolute;
  top: -1px; right: 20px;
  background: linear-gradient(135deg, var(--cyan), #0066ff);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 0 0 8px 8px;
}

.feature-icon-wrap {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
  position: relative;
}

.co2-icon     { background: var(--green-dim); border: 1px solid rgba(0,255,136,0.25); }
.inno-icon    { background: var(--violet-dim); border: 1px solid rgba(124,58,237,0.25); }
.analytics-icon { background: rgba(245,158,11,0.12); border: 1px solid rgba(245,158,11,0.25); }

.feature-svg { width: 32px; height: 32px; }

.feature-card h3 {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 10px;
}

.feature-card p {
  font-size: 0.87rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 20px;
}

.feature-metric {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: auto;
}

.fm-val {
  font-family: 'Orbitron', monospace;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--cyan);
}

.fm-lbl {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* ─── Model Cards ───────────────────────────────────────────── */
.metrics-dual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 28px);
}

.model-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 3vw, 36px);
  position: relative;
  overflow: hidden;
  background: var(--bg-deep);
}

.model-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
}

.co2-card::before {
  background: linear-gradient(90deg, var(--green), var(--cyan));
}

.inno-card::before {
  background: linear-gradient(90deg, var(--violet), var(--cyan));
}

.model-card-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.model-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
}

.co2-card .model-icon { background: var(--green-dim); color: var(--green); }
.inno-card .model-icon { background: var(--violet-dim); color: #a78bfa; }

.model-name {
  font-family: 'Orbitron', monospace;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-primary);
}

.model-algo {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.model-accuracy {
  font-family: 'Orbitron', monospace;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  line-height: 1;
  margin-bottom: 24px;
}

.co2-card .model-accuracy { color: var(--green); }
.inno-card .model-accuracy { color: #a78bfa; }

.model-accuracy span { font-size: 0.4em; color: var(--text-muted); }

.model-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.mm-item {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  text-align: center;
}

.mm-val {
  font-family: 'Space Mono', monospace;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 3px;
}

.mm-lbl {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ─── Chart Glass ───────────────────────────────────────────── */
.chart-glass {
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 32px);
  box-shadow: var(--shadow-glass);
}

/* ─── CTA ───────────────────────────────────────────────────── */
.cta-section { background: var(--bg-surface); }

.cta-box {
  position: relative;
  text-align: center;
  padding: clamp(40px, 8vw, 80px);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: radial-gradient(ellipse at center, rgba(0,212,255,0.06) 0%, transparent 70%);
}

.cta-glow {
  position: absolute;
  top: -60px; left: 50%;
  transform: translateX(-50%);
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(0,212,255,0.15), transparent 70%);
  pointer-events: none;
}

.cta-box h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: 12px; }
.cta-box p { font-size: 1.05rem; color: var(--text-secondary); margin-bottom: 28px; }

/* ─── Page Hero (compact) ────────────────────────────────────── */
.page-hero.compact {
  padding: clamp(40px, 6vw, 70px) 0 clamp(30px, 5vw, 50px);
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg, var(--bg-surface), var(--bg-deep));
}

.page-hero-content { text-align: center; }

.page-title {
  font-size: clamp(2rem, 5vw, 3.6rem);
  margin: 12px 0;
}

.page-hero-content p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
}

/* ─── Predict Page ──────────────────────────────────────────── */
.predict-container { padding-top: 40px; padding-bottom: 60px; }

.currency-card {
  margin-bottom: 24px;
}

.currency-toggle-wrap {
  display: flex;
  align-items: center;
  gap: clamp(12px, 3vw, 24px);
  flex-wrap: wrap;
}

.currency-label {
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 7px;
}

.currency-label i { color: var(--amber); }

.currency-toggle {
  display: flex;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 3px;
}

.curr-btn {
  padding: 7px 20px;
  border: none;
  border-radius: var(--radius-full);
  font-family: 'Orbitron', monospace;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  background: transparent;
  color: var(--text-muted);
}

.curr-btn.active {
  background: linear-gradient(135deg, var(--cyan), #0066ff);
  color: #fff;
  box-shadow: 0 2px 12px var(--cyan-glow);
}

.currency-rate {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-muted);
  background: var(--bg-elevated);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  margin-left: auto;
}

.inputs-card { margin-bottom: 28px; }

.inputs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.5vw, 24px);
  margin-bottom: 32px;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.input-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 7px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-group label i { color: var(--cyan); font-size: 0.85rem; }

.unit-badge {
  margin-left: auto;
  background: var(--cyan-dim);
  color: var(--cyan);
  font-size: 0.7rem;
  font-weight: 700;
  font-family: 'Space Mono', monospace;
  padding: 2px 9px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0,212,255,0.2);
}

.input-wrap { display: flex; flex-direction: column; gap: 8px; }

.ev-input {
  width: 100%;
  padding: 11px 14px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text-primary);
  font-family: 'Space Mono', monospace;
  font-size: 1rem;
  font-weight: 700;
  transition: var(--transition);
  outline: none;
}

.ev-input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px var(--cyan-dim);
}

.ev-input::-webkit-inner-spin-button { opacity: 0.4; }

/* Custom Range Slider */
.ev-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 4px;
  background: var(--bg-elevated);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
  position: relative;
}

.ev-slider::-webkit-slider-track {
  height: 4px;
  background: linear-gradient(to right, var(--cyan) 0%, var(--cyan) var(--progress, 50%), var(--bg-elevated) var(--progress, 50%));
  border-radius: 2px;
}

.ev-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--cyan);
  border: 3px solid var(--bg-deep);
  box-shadow: 0 0 8px var(--cyan-glow);
  cursor: pointer;
  transition: box-shadow 0.2s;
}

.ev-slider::-webkit-slider-thumb:hover {
  box-shadow: 0 0 16px var(--cyan);
}

.ev-slider::-moz-range-thumb {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--cyan);
  border: 3px solid var(--bg-deep);
  cursor: pointer;
}

.input-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: 'Space Mono', monospace;
}

/* Predict Button */
.predict-btn-wrap { text-align: center; }

.btn-predict {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 48px;
  background: linear-gradient(135deg, var(--cyan), #0066ff, var(--violet));
  background-size: 200% 200%;
  color: #fff;
  font-family: 'Orbitron', monospace;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 2px;
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  overflow: hidden;
  transition: var(--transition);
  animation: gradient-shift 4s ease infinite;
}

.btn-predict:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 40px rgba(0,212,255,0.4);
}

.btn-predict.loading .btn-predict-icon i {
  animation: spin 0.8s linear infinite;
}

.btn-predict-glow {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,0.1) 50%, transparent 60%);
  animation: shimmer 2.5s infinite;
}

@keyframes shimmer {
  0%   { transform: translateX(-100%) skewX(-15deg); }
  100% { transform: translateX(200%) skewX(-15deg); }
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50%       { background-position: 100% 50%; }
}

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

/* Results Section */
.results-section { margin-top: 32px; }
.results-section.hidden { display: none; }

.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  flex-wrap: wrap;
  gap: 12px;
}

.results-header h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
}

.results-header h2 i { color: var(--cyan); margin-right: 10px; }

.results-timestamp {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.results-primary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 24px);
  margin-bottom: 24px;
}

.result-card {
  position: relative;
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 40px) clamp(20px, 3vw, 32px);
  text-align: center;
  overflow: hidden;
  border: 1px solid var(--border);
}

.result-card-bg {
  position: absolute;
  inset: 0;
  opacity: 0.08;
}

.co2-result .result-card-bg {
  background: radial-gradient(ellipse at center, var(--green), transparent 70%);
}

.inno-result .result-card-bg {
  background: radial-gradient(ellipse at center, var(--violet), transparent 70%);
}

.co2-result { background: linear-gradient(135deg, rgba(0,255,136,0.06), rgba(0,212,255,0.04)); }
.inno-result { background: linear-gradient(135deg, rgba(124,58,237,0.08), rgba(0,212,255,0.04)); }

.result-icon {
  font-size: 2rem;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
}

.co2-result .result-icon { color: var(--green); }
.inno-result .result-icon { color: #a78bfa; }

.result-label {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 10px;
  position: relative;
  z-index: 1;
}

.result-value {
  font-family: 'Orbitron', monospace;
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 900;
  line-height: 1;
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
}

.co2-result .result-value { color: var(--green); }
.inno-result .result-value { color: #a78bfa; }

.result-unit {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
  position: relative;
  z-index: 1;
}

.result-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  position: relative;
  z-index: 1;
}

/* Gauges */
.gauges-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 24px);
  margin-bottom: 24px;
}

.gauge-card { text-align: center; }
.gauge-card h4 { font-size: 0.9rem; margin-bottom: 16px; display: flex; align-items: center; justify-content: center; gap: 8px; }
.gauge-card h4 i { color: var(--cyan); }
.gauge-wrap { display: flex; justify-content: center; margin-bottom: 8px; }

.gauge-val {
  font-family: 'Orbitron', monospace;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--cyan);
}

/* Insights Row */
.insights-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 24px);
  margin-bottom: 24px;
}

.insight-card h4 { font-size: 0.92rem; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; }
.insight-card h4 i { color: var(--cyan); }

/* Breakdown Bars */
.breakdown-bars { display: flex; flex-direction: column; gap: 18px; }

.breakdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bd-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
  width: 160px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.bd-label i { color: var(--cyan); font-size: 0.75rem; }

.bd-bar-wrap {
  flex: 1;
  height: 8px;
  background: var(--bg-elevated);
  border-radius: 4px;
  overflow: hidden;
}

.bd-bar {
  height: 100%;
  border-radius: 4px;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.te-bar { background: linear-gradient(90deg, var(--cyan), #0066ff); }
.ei-bar { background: linear-gradient(90deg, var(--green), #00c070); }
.uv-bar { background: linear-gradient(90deg, #f59e0b, #ef4444); }

.bd-val {
  font-family: 'Space Mono', monospace;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--cyan);
  width: 44px;
  text-align: right;
}

/* Env Metrics */
.env-metrics { display: flex; flex-direction: column; gap: 16px; }

.env-metric {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px;
  background: var(--bg-elevated);
  border-radius: 10px;
  border: 1px solid var(--border);
}

.env-icon {
  width: 38px; height: 38px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.env-icon.trees  { background: var(--green-dim); color: var(--green); }
.env-icon.petrol { background: rgba(245,158,11,0.12); color: var(--amber); }
.env-icon.charge { background: var(--cyan-dim); color: var(--cyan); }
.env-icon.batt   { background: var(--violet-dim); color: #a78bfa; }

.env-val {
  font-family: 'Orbitron', monospace;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-primary);
}

.env-lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Chart legend inline */
.chart-legend-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.leg-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.leg-dot.purple { background: #9333ea; }
.leg-dot.red { background: #ef4444; }
.ml-8 { margin-left: 8px; }

/* ─── Analytics Page ────────────────────────────────────────── */
.analytics-container { padding-top: 40px; padding-bottom: 60px; }

.analytics-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(12px, 2vw, 20px);
  margin-bottom: 28px;
}

.a-stat-card {
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(16px, 2.5vw, 24px);
  text-align: center;
  transition: var(--transition);
}

.a-stat-card:hover {
  border-color: var(--border-bright);
  transform: translateY(-3px);
}

.a-stat-icon {
  font-size: 1.4rem;
  color: var(--cyan);
  margin-bottom: 10px;
}

.a-stat-val {
  font-family: 'Orbitron', monospace;
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.a-stat-lbl {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.analytics-chart-card { margin-bottom: 24px; }

/* Responsive canvas container — used for feature importance + heatmap */
.canvas-responsive-wrap {
  position: relative;
  width: 100%;
  min-height: 260px;
  max-height: 380px;
}

.canvas-responsive-wrap canvas {
  display: block;
  width: 100% !important;
  height: 100% !important;
}

.heatmap-wrap {
  min-height: 200px;
  max-height: 320px;
}

@media (max-width: 700px) {
  .canvas-responsive-wrap {
    min-height: 200px;
    max-height: 280px;
  }
  .heatmap-wrap {
    min-height: 180px;
    max-height: 240px;
  }
}

@media (max-width: 480px) {
  .canvas-responsive-wrap {
    min-height: 180px;
    max-height: 240px;
  }
  .heatmap-wrap {
    min-height: 160px;
    max-height: 210px;
  }
}

.chart-container-wrap {
  display: flex;
  justify-content: center;
  max-height: 400px;
}

.charts-two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.5vw, 24px);
  margin-bottom: 24px;
}

/* ─── About Page ────────────────────────────────────────────── */
.about-container { padding-top: 40px; padding-bottom: 60px; }

.about-overview {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
  margin-bottom: 0;
}

.overview-text h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); margin-bottom: 16px; }
.overview-text p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 12px;
}

.overview-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  min-width: 200px;
}

.ov-stat {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}

.ov-val {
  font-family: 'Orbitron', monospace;
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--cyan);
  margin-bottom: 4px;
}

.ov-lbl { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }

.mt-40 { margin-top: 40px; }
.mt-60 { margin-top: 60px; }

/* Pipeline Steps */
.pipeline-steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.pipeline-step {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 20px;
  position: relative;
  padding: 20px 0;
  align-items: start;
}

.pipeline-step:not(:last-child)::before {
  content: '';
  position: absolute;
  left: 29px;
  top: 60px;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--cyan-dim), transparent);
}

.step-num {
  width: 60px; height: 60px;
  flex-shrink: 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border-bright);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Orbitron', monospace;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--cyan);
  position: relative;
  z-index: 1;
  transition: var(--transition);
}

.pipeline-step:hover .step-num {
  background: var(--cyan-dim);
  box-shadow: 0 0 20px var(--cyan-glow);
}

.step-content { padding-top: 8px; }
.step-content h4 { font-size: 0.95rem; color: var(--text-primary); margin-bottom: 6px; }
.step-content p { font-size: 0.85rem; color: var(--text-secondary); line-height: 1.6; }
.step-content code { font-size: 0.78rem; }

/* Use Cases */
.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(16px, 2.5vw, 24px);
}

.use-case-card {
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 28px);
  transition: var(--transition);
}

.use-case-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-bright);
}

.uc-icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 16px;
}

.uc-mfr .uc-icon { background: var(--cyan-dim); color: var(--cyan); }
.uc-pol .uc-icon { background: var(--violet-dim); color: #a78bfa; }
.uc-con .uc-icon { background: var(--green-dim); color: var(--green); }

.use-case-card h3 { font-size: 1rem; color: var(--text-primary); margin-bottom: 14px; }

.use-case-card ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }

.use-case-card li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  padding-left: 14px;
  position: relative;
}

.use-case-card li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px; height: 5px;
  background: var(--cyan);
  border-radius: 50%;
}

/* Files Table */
.files-table-wrap { overflow-x: auto; }

.files-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.files-table th, .files-table td {
  padding: 12px 16px;
  text-align: left;
}

.files-table th {
  font-family: 'Orbitron', monospace;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  border-bottom: 1px solid var(--border);
}

.files-table th i { margin-right: 6px; color: var(--cyan); }

.files-table td {
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.files-table tr:last-child td { border-bottom: none; }

.files-table tr:hover td {
  background: var(--bg-elevated);
  color: var(--text-primary);
}

.badge-format {
  display: inline-block;
  padding: 3px 10px;
  background: var(--cyan-dim);
  color: var(--cyan);
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0,212,255,0.2);
}

/* Tech Stack */
.tech-stack-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.tech-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 20px 14px;
  background: var(--bg-glass);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  transition: var(--transition);
  cursor: default;
}

.tech-item:hover {
  border-color: var(--border-bright);
  transform: translateY(-3px);
  background: var(--cyan-dim);
}

.tech-icon { font-size: 1.6rem; color: var(--cyan); }
.tech-name { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); }

/* Roadmap */
.roadmap-list { display: flex; flex-direction: column; gap: 0; }

.roadmap-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.roadmap-item:last-child { border-bottom: none; }

.roadmap-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--text-muted);
  margin-top: 4px;
  flex-shrink: 0;
  transition: var(--transition);
}

.roadmap-dot.active {
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 0 10px var(--green-glow);
}

.roadmap-item:hover .roadmap-dot { border-color: var(--cyan); }

.roadmap-title { font-size: 0.92rem; font-weight: 700; color: var(--text-primary); margin-bottom: 4px; }
.roadmap-desc  { font-size: 0.82rem; color: var(--text-secondary); }
.roadmap-content { flex: 1; }

.roadmap-date {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  color: var(--cyan);
  white-space: nowrap;
  background: var(--cyan-dim);
  padding: 4px 12px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(0,212,255,0.2);
  height: fit-content;
}

/* About Footer */
.about-footer {
  margin-top: 60px;
  padding: 40px;
  text-align: center;
  border-top: 1px solid var(--border);
}

.about-footer-logo {
  font-family: 'Orbitron', monospace;
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.about-footer-logo span { color: var(--cyan); }

.about-footer p {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.footer-copy { font-size: 0.78rem; color: #2a4060; margin-top: 16px; }

/* ─── Toast ─────────────────────────────────────────────────── */
#toast-container {
  position: fixed;
  top: calc(var(--nav-h) + 12px);
  right: 16px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  min-width: 280px;
  max-width: 380px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  pointer-events: all;
  transform: translateX(120%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(20px);
}

.toast.show { transform: translateX(0); }
.toast.hide { transform: translateX(120%); opacity: 0; }

.toast-icon { font-size: 1.2rem; flex-shrink: 0; }
.toast-body { flex: 1; }
.toast-title { font-family: 'Orbitron', monospace; font-size: 0.78rem; font-weight: 700; margin-bottom: 2px; }
.toast-msg   { font-size: 0.8rem; color: var(--text-muted); }

.toast.success { border-color: rgba(0,255,136,0.3); }
.toast.success .toast-icon { color: var(--green); }
.toast.success .toast-title { color: var(--green); }

.toast.error { border-color: rgba(239,68,68,0.3); }
.toast.error .toast-icon { color: var(--red); }
.toast.error .toast-title { color: var(--red); }

.toast.info { border-color: rgba(0,212,255,0.3); }
.toast.info .toast-icon { color: var(--cyan); }
.toast.info .toast-title { color: var(--cyan); }

.toast.warning { border-color: rgba(245,158,11,0.3); }
.toast.warning .toast-icon { color: var(--amber); }
.toast.warning .toast-title { color: var(--amber); }

/* ─── Loading Overlay ────────────────────────────────────────── */
.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 9990;
  background: var(--bg-void);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  opacity: 1;
  transition: opacity 0.5s ease;
}

.loading-overlay.hidden { opacity: 0; pointer-events: none; }

.loader-logo {
  font-family: 'Orbitron', monospace;
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
}

.loader-logo span { color: var(--cyan); }

.loader-bar-wrap {
  width: 200px;
  height: 3px;
  background: var(--bg-elevated);
  border-radius: 2px;
  overflow: hidden;
}

.loader-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--cyan), var(--green));
  animation: loader-fill 1.5s ease forwards;
  transform-origin: left;
}

@keyframes loader-fill {
  from { width: 0; }
  to   { width: 100%; }
}

/* ─── Animations ─────────────────────────────────────────────── */
@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes glow-pulse {
  0%, 100% { box-shadow: 0 0 20px var(--cyan-glow); }
  50%       { box-shadow: 0 0 40px var(--cyan-glow), 0 0 80px rgba(0,212,255,0.1); }
}

.animate-fade-up   { animation: fade-in-up 0.6s ease forwards; }
.animate-fade      { animation: fade-in 0.6s ease forwards; }
.animation-delay-1 { animation-delay: 0.1s; }
.animation-delay-2 { animation-delay: 0.2s; }
.animation-delay-3 { animation-delay: 0.3s; }

/* Moving gradient on feature SVG icons */
@keyframes gradient-rotate {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.feature-icon-wrap::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--cyan), var(--green), var(--violet), var(--cyan));
  background-size: 300% 300%;
  animation: gradient-rotate 4s ease infinite;
  opacity: 0;
  z-index: -1;
  transition: opacity 0.3s;
}

.feature-card:hover .feature-icon-wrap::after { opacity: 0.5; }

/* ─── Rating Card ────────────────────────────────────────────── */
.mb-24 { margin-bottom: 24px; }

.rating-card { margin-bottom: 0; }

.rating-grade-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-bright);
  background: var(--bg-elevated);
  transition: var(--transition);
}

.rg-letter {
  font-family: 'Orbitron', monospace;
  font-size: 1.5rem;
  font-weight: 900;
  line-height: 1;
}

.rg-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

/* grade colours applied by JS */
.grade-sp { color: #ff6b35; border-color: rgba(255,107,53,0.5); }
.grade-sp .rg-letter { color: #ff6b35; }
.grade-a  { color: var(--cyan);  border-color: var(--border-bright); }
.grade-a  .rg-letter { color: var(--cyan); }
.grade-b  { color: var(--green); border-color: rgba(0,255,136,0.4); }
.grade-b  .rg-letter { color: var(--green); }
.grade-c  { color: var(--amber); border-color: rgba(245,158,11,0.4); }
.grade-c  .rg-letter { color: var(--amber); }
.grade-d  { color: var(--red);   border-color: rgba(239,68,68,0.4); }
.grade-d  .rg-letter { color: var(--red); }

.rating-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 3vw, 40px);
  align-items: start;
  margin-bottom: 28px;
}

.rating-radar-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
}

.rating-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

/* Overall ring */
.overall-ring-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 160px;
  height: 160px;
  flex-shrink: 0;
}

.overall-ring-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.or-score {
  font-family: 'Orbitron', monospace;
  font-size: 2rem;
  font-weight: 900;
  color: var(--cyan);
  line-height: 1;
}

.or-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 3px;
}

/* Star row */
.star-row {
  display: flex;
  gap: 6px;
  font-size: 1.3rem;
}

.sr-star { color: var(--text-muted); transition: var(--transition); }
.sr-star.filled { color: #f59e0b; }
.sr-star.half   { color: #f59e0b; }

.star-label {
  font-family: 'Space Mono', monospace;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: -4px;
}

/* Category bars */
.rating-cats {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rc-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.rc-icon {
  width: 30px; height: 30px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.rc-icon.range      { background: rgba(0,212,255,0.12); color: var(--cyan); }
.rc-icon.efficiency { background: rgba(0,255,136,0.12); color: var(--green); }
.rc-icon.charging   { background: rgba(245,158,11,0.12); color: var(--amber); }
.rc-icon.value      { background: rgba(239,68,68,0.12); color: var(--red); }
.rc-icon.innovation { background: rgba(124,58,237,0.12); color: #a78bfa; }
.rc-icon.eco        { background: rgba(0,255,136,0.12); color: var(--green); }

.rc-info { flex: 1; min-width: 0; }

.rc-name {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rc-bar-wrap {
  height: 5px;
  background: var(--bg-elevated);
  border-radius: 3px;
  overflow: hidden;
}

.rc-bar {
  height: 100%;
  border-radius: 3px;
  width: 0%;
  transition: width 1.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.rng-bar { background: linear-gradient(90deg, var(--cyan), #0066ff); }
.eff-bar { background: linear-gradient(90deg, var(--green), #00c880); }
.chg-bar { background: linear-gradient(90deg, var(--amber), #f97316); }
.val-bar { background: linear-gradient(90deg, var(--red), #ec4899); }
.inn-bar { background: linear-gradient(90deg, #7c3aed, var(--cyan)); }
.eco-bar { background: linear-gradient(90deg, var(--green), var(--cyan)); }

.rc-score {
  font-family: 'Space Mono', monospace;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-primary);
  width: 36px;
  text-align: right;
  flex-shrink: 0;
}

/* Tier legend */
.rating-tiers {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.tier-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 5px 12px;
  background: var(--bg-elevated);
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

.tier-item span {
  font-family: 'Orbitron', monospace;
  font-size: 0.7rem;
  font-weight: 800;
}

.tier-s span { color: #ff6b35; }
.tier-a span { color: var(--cyan); }
.tier-b span { color: var(--green); }
.tier-c span { color: var(--amber); }
.tier-d span { color: var(--red); }

/* ─── Responsive ─────────────────────────────────────────────── */

/* ── 1100px – large tablet ── */
@media (max-width: 1100px) {
  .tech-stack-grid { grid-template-columns: repeat(4, 1fr); }
  .hero { padding: 40px clamp(16px, 3vw, 48px); }
  .hero-3d-container { height: 380px; }
}

/* ── 960px – tablet / small laptop ── */
@media (max-width: 960px) {

  /* Nav */
  .nav-links { display: none; }
  .hamburger { display: flex; }
  .api-status { padding: 6px 10px; }

  /* Hero – stack vertically */
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 24px 20px 36px;
    gap: 0;
    min-height: auto;
    align-content: start;
  }

  .hero-content {
    order: 2;
    margin-top: 16px;
    padding: 0 4px;
  }

  .hero-3d-container {
    order: 1;
    height: clamp(200px, 40vw, 300px);
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
  }

  .holo-ring.r1 { width: 180px; height: 180px; }
  .holo-ring.r2 { width: 230px; height: 230px; }
  .holo-ring.r3 { width: 280px; height: 280px; }

  .hero-title    { font-size: clamp(2.4rem, 7vw, 3.6rem); margin-bottom: 14px; }
  .hero-badge    { margin-bottom: 18px; }
  .hero-subtitle { margin: 0 auto 24px; font-size: 1rem; }
  .hero-cta      { justify-content: center; gap: 10px; }
  .hero-scroll-indicator { display: none; }

  .features-grid       { grid-template-columns: 1fr; }
  .metrics-dual        { grid-template-columns: 1fr; }
  .results-primary     { grid-template-columns: 1fr; }
  .gauges-row          { grid-template-columns: 1fr; }
  .insights-row        { grid-template-columns: 1fr; }
  .analytics-stats-row { grid-template-columns: repeat(2, 1fr); }
  .charts-two-col      { grid-template-columns: 1fr; }
  .use-cases-grid      { grid-template-columns: 1fr; }
  .tech-stack-grid     { grid-template-columns: repeat(3, 1fr); }
  .about-overview      { grid-template-columns: 1fr; }

  .rating-layout       { grid-template-columns: 1fr; }
  .rating-radar-wrap   { max-height: 300px; }
  .overall-ring-wrap   { width: 130px; height: 130px; }
  .or-score            { font-size: 1.6rem; }
  .model-metrics-grid  { grid-template-columns: repeat(3, 1fr); }
  .pipeline-step       { grid-template-columns: 50px 1fr; gap: 14px; }
}

/* ── 700px – mobile landscape / large phone ── */
@media (max-width: 700px) {

  .hero { padding: 16px 16px 28px; }

  .hero-3d-container { height: clamp(170px, 52vw, 240px); }

  .holo-ring.r2,
  .holo-ring.r3 { display: none; }
  .holo-ring.r1 { width: 150px; height: 150px; }
  .holo-label   { font-size: 0.52rem; letter-spacing: 2px; }
  .scan-line    { display: none; }

  .stat-divider   { display: none; }
  .stats-container{ gap: 12px; justify-content: space-around; }
  .stat-item      { min-width: 80px; }
  .stat-item .stat-val { font-size: 1.3rem; }
  .stat-item .stat-lbl { font-size: 0.68rem; }

  .inputs-grid    { grid-template-columns: 1fr 1fr; }
  .currency-toggle-wrap { flex-wrap: wrap; gap: 8px; }
  .currency-rate  { margin-left: 0; font-size: 0.72rem; }

  .mobile-menu-overlay  { display: block; }
  .analytics-stats-row  { grid-template-columns: 1fr 1fr; }
  .tech-stack-grid      { grid-template-columns: repeat(3, 1fr); }
  .overview-stats       { grid-template-columns: 1fr 1fr; }

  .gauge-card        { padding: 16px; }
  .gauge-wrap canvas { width: 160px !important; height: 96px !important; }

  .rating-cats  { gap: 8px; }
  .rc-name      { font-size: 0.68rem; }
  .rating-tiers { gap: 6px; }
  .tier-item    { font-size: 0.68rem; padding: 4px 10px; }

  .feature-card   { padding: 20px; }
  .section        { padding: 36px 0; }
  .page-hero.compact { padding: 28px 0 24px; }
  .use-case-card  { padding: 18px; }
  .pipeline-step  { padding: 14px 0; }
  .step-num       { width: 48px; height: 48px; font-size: 0.72rem; }
}

/* ── 480px – small phone portrait ── */
@media (max-width: 480px) {

  .logo-text               { font-size: 1.05rem; }
  .logo-icon               { width: 32px; height: 32px; }
  .api-status .status-text { display: none; }
  .api-status              { padding: 5px 7px; }
  .hamburger               { width: 36px; height: 36px; padding: 9px 8px; }

  .hero                    { padding: 12px 14px 24px; }
  .hero-3d-container       { height: clamp(155px, 56vw, 210px); }
  .holo-ring.r1            { width: 130px; height: 130px; }
  .hero-title              { font-size: clamp(2rem, 10vw, 2.6rem); line-height: 1.08; margin-bottom: 12px; }
  .hero-badge              { font-size: 0.68rem; padding: 5px 11px; margin-bottom: 14px; }
  .hero-subtitle           { font-size: 0.88rem; line-height: 1.7; margin-bottom: 20px; }
  .btn-primary,
  .btn-ghost               { padding: 10px 18px; font-size: 0.74rem; gap: 7px; }
  .hero-cta                { gap: 8px; flex-wrap: nowrap; }

  .inputs-grid             { grid-template-columns: 1fr; }
  .currency-toggle-wrap    { flex-direction: column; align-items: flex-start; }

  .result-value            { font-size: 2.8rem; }
  .results-header h2       { font-size: 1.2rem; }
  .results-primary         { gap: 12px; }
  .result-card             { padding: 20px 16px; }

  .rating-layout           { gap: 14px; }
  .overall-ring-wrap       { width: 110px; height: 110px; }
  .or-score                { font-size: 1.3rem; }
  .rg-letter               { font-size: 1.2rem; }
  .star-row                { font-size: 1rem; gap: 4px; }
  .card-header-row         { flex-direction: column; align-items: flex-start; gap: 8px; }

  .chart-container-wrap    { max-height: 260px; }
  .a-stat-card             { padding: 14px 10px; }
  .a-stat-val              { font-size: 1.1rem; }
  .a-stat-lbl              { font-size: 0.65rem; }

  .glass-card              { padding: 16px; }
  .section-title           { font-size: 1.6rem; }
  .page-title              { font-size: 1.8rem; }
  .tech-stack-grid         { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .overview-stats          { grid-template-columns: 1fr 1fr; gap: 10px; }
  .roadmap-item            { flex-wrap: wrap; gap: 10px; }
  .roadmap-date            { margin-left: 28px; }
  .model-metrics-grid      { grid-template-columns: repeat(2, 1fr); }
  .predict-btn-wrap .btn-predict { padding: 14px 32px; font-size: 0.88rem; }
  .section                 { padding: 28px 0; }
  .page-hero.compact       { padding: 20px 0 18px; }
}

/* ── 360px – very small phones ── */
@media (max-width: 360px) {
  .hero-title     { font-size: 1.8rem; }
  .hero-cta       { flex-direction: column; align-items: center; }
  .btn-primary,
  .btn-ghost      { width: 100%; justify-content: center; }
  .hero-3d-container { height: 150px; }
  .holo-ring.r1   { width: 110px; height: 110px; }
  .analytics-stats-row { grid-template-columns: 1fr 1fr; }
}