/**
 * app.css — HashVault Mining Platform
 * Ultra-modern dark glassmorphism financial UI
 * Uses CSS custom properties for consistent theming throughout.
 */

/* ═══════════════════════════════════════════════════════════════════════════
   CSS CUSTOM PROPERTIES (Design Tokens)
   ═══════════════════════════════════════════════════════════════════════════ */
:root {
  --bg-primary:    #0a0e1a;
  --bg-secondary:  #0f1629;
  --bg-card:       rgba(255, 255, 255, 0.05);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --accent-blue:   #4f8ef7;
  --accent-purple: #7c3aed;
  --accent-gold:   #f0b429;
  --accent-green:  #22c55e;
  --accent-red:    #ef4444;
  --text-primary:  #f1f5f9;
  --text-muted:    #94a3b8;
  --border:        rgba(255, 255, 255, 0.08);
  --border-hover:  rgba(79, 142, 247, 0.4);
  --glass:         rgba(15, 22, 41, 0.8);
  --glass-nav:     rgba(10, 14, 26, 0.85);
  --shadow-card:   0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-glow:   0 0 30px rgba(79, 142, 247, 0.2);
  --shadow-gold:   0 0 20px rgba(240, 180, 41, 0.25);
  --radius-card:   16px;
  --radius-btn:    10px;
  --transition:    all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-main:     'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESET & BASE
   ═══════════════════════════════════════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  /* Subtle grid background pattern */
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(79,142,247,0.12), transparent),
    linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
  background-size: auto, 60px 60px, 60px 60px;
  background-attachment: fixed;
}

/* Scrollbar styling */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: rgba(79,142,247,0.4); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-blue); }

/* Selection */
::selection { background: rgba(79,142,247,0.3); color: var(--text-primary); }

/* Typography helpers */
.fw-700 { font-weight: 700 !important; }
.fw-800 { font-weight: 800 !important; }
.fw-900 { font-weight: 900 !important; }
.text-accent-blue  { color: var(--accent-blue)   !important; }
.text-accent-gold  { color: var(--accent-gold)   !important; }
.text-accent-green { color: var(--accent-green)  !important; }
.text-accent-red   { color: var(--accent-red)    !important; }
.text-muted        { color: var(--text-muted)    !important; }

/* ═══════════════════════════════════════════════════════════════════════════
   IMPERSONATION BANNER
   ═══════════════════════════════════════════════════════════════════════════ */
#impersonation-banner {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 9999;
  background: linear-gradient(135deg, #d97706, #f0b429);
  color: #1a0a00;
  text-align: center;
  padding: 8px 16px;
  font-size: 0.875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 2px 20px rgba(240,180,41,0.5);
}

/* Push navbar down when banner is present */
body:has(#impersonation-banner) .hv-navbar { top: 42px; }
body:has(#impersonation-banner) .hv-main   { padding-top: 42px; }

/* ═══════════════════════════════════════════════════════════════════════════
   NAVBAR
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-navbar {
  background: var(--glass-nav) !important;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
  transition: var(--transition);
}

.hv-navbar.scrolled {
  background: rgba(10, 14, 26, 0.97) !important;
  box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.hv-brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--text-primary) !important;
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.hv-logo-img {
  height: 36px;
  width: auto;
  object-fit: contain;
}

.hv-logo-fallback {
  display: flex;
  align-items: center;
  color: var(--text-primary);
}

.hv-nav-link {
  color: var(--text-muted) !important;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 8px 14px !important;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
}

.hv-nav-link:hover,
.hv-nav-link.active {
  color: var(--text-primary) !important;
  background: rgba(79,142,247,0.1);
}

.hv-nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 2px; left: 50%;
  transform: translateX(-50%);
  width: 20px; height: 2px;
  background: var(--accent-blue);
  border-radius: 2px;
}

.hv-balance-pill {
  background: rgba(240,180,41,0.1);
  border: 1px solid rgba(240,180,41,0.3);
  color: var(--accent-gold);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  font-feature-settings: 'tnum';
}

/* ═══════════════════════════════════════════════════════════════════════════
   MAIN CONTENT
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-main {
  padding-top: 0; /* removed navbar height offset */
  flex: 1;
}

/* ═══════════════════════════════════════════════════════════════════════════
   GLASSMORPHISM CARDS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-card {
  background: var(--bg-card);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  transition: var(--transition);
  overflow: hidden;
}

.hv-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card), var(--shadow-glow);
  transform: translateY(-2px);
}

/* Gradient border cards */
.hv-card-gradient {
  position: relative;
  background: var(--bg-card);
  border-radius: var(--radius-card);
  overflow: hidden;
}

.hv-card-gradient::before {
  content: '';
  position: absolute;
  inset: 0;
  padding: 1px;
  background: linear-gradient(135deg, rgba(79,142,247,0.5), rgba(124,58,237,0.3), rgba(240,180,41,0.2));
  border-radius: inherit;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

/* Stat/Balance cards */
.hv-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 24px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.hv-stat-card::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  opacity: 0.06;
}

.hv-stat-card.blue::after  { background: var(--accent-blue);  }
.hv-stat-card.gold::after  { background: var(--accent-gold);  }
.hv-stat-card.green::after { background: var(--accent-green); }
.hv-stat-card.red::after   { background: var(--accent-red);   }

.hv-stat-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card), var(--shadow-glow);
}

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

.hv-stat-icon.blue   { background: rgba(79,142,247,0.15);  color: var(--accent-blue);  }
.hv-stat-icon.gold   { background: rgba(240,180,41,0.15);  color: var(--accent-gold);  }
.hv-stat-icon.green  { background: rgba(34,197,94,0.15);   color: var(--accent-green); }
.hv-stat-icon.purple { background: rgba(124,58,237,0.15);  color: var(--accent-purple);}

.hv-stat-value {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  font-feature-settings: 'tnum';
}

.hv-stat-label {
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 4px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-hero {
  position: relative;
  padding: 100px 0 80px;
  overflow: hidden;
}

.hv-hero-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

/* Animated particle dots */
.hv-particle {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--accent-blue);
  opacity: 0;
  animation: particleFloat 8s infinite ease-in-out;
}

.hv-particle:nth-child(1)  { left: 10%;  top: 20%; animation-delay: 0s;    animation-duration: 7s;  }
.hv-particle:nth-child(2)  { left: 25%;  top: 60%; animation-delay: 1s;    animation-duration: 9s;  }
.hv-particle:nth-child(3)  { left: 40%;  top: 30%; animation-delay: 2s;    animation-duration: 6s;  }
.hv-particle:nth-child(4)  { left: 55%;  top: 70%; animation-delay: 0.5s;  animation-duration: 8s;  }
.hv-particle:nth-child(5)  { left: 70%;  top: 20%; animation-delay: 1.5s;  animation-duration: 10s; }
.hv-particle:nth-child(6)  { left: 85%;  top: 50%; animation-delay: 3s;    animation-duration: 7s;  }
.hv-particle:nth-child(7)  { left: 15%;  top: 80%; animation-delay: 2.5s;  animation-duration: 9s;  background: var(--accent-gold); }
.hv-particle:nth-child(8)  { left: 60%;  top: 10%; animation-delay: 0.8s;  animation-duration: 8s;  background: var(--accent-gold); }
.hv-particle:nth-child(9)  { left: 90%;  top: 75%; animation-delay: 1.8s;  animation-duration: 6s;  }
.hv-particle:nth-child(10) { left: 35%;  top: 90%; animation-delay: 4s;    animation-duration: 11s; background: var(--accent-purple); }
.hv-particle:nth-child(11) { left: 78%;  top: 40%; animation-delay: 2.2s;  animation-duration: 7s;  }
.hv-particle:nth-child(12) { left: 48%;  top: 55%; animation-delay: 3.5s;  animation-duration: 9s;  background: var(--accent-green); }

@keyframes particleFloat {
  0%   { opacity: 0;   transform: translate(0, 0)   scale(1); }
  20%  { opacity: 0.7; }
  80%  { opacity: 0.4; }
  100% { opacity: 0;   transform: translate(-20px, -60px) scale(0.5); }
}

/* Radial glow behind hero */
.hv-hero::before {
  content: '';
  position: absolute;
  top: -200px; left: 50%;
  transform: translateX(-50%);
  width: 900px; height: 600px;
  background: radial-gradient(ellipse, rgba(79,142,247,0.1) 0%, transparent 70%);
  pointer-events: none;
}

.hv-gradient-text {
  background: linear-gradient(135deg, #4f8ef7 0%, #7c3aed 50%, #f0b429 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hv-hero-title {
  font-size: clamp(2.4rem, 6vw, 5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1.05;
}

.hv-hero-sub {
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--text-muted);
  max-width: 600px;
  line-height: 1.7;
}

/* Ticker / live stats bar */
.hv-stats-ticker {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 24px;
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
  margin-top: 40px;
  backdrop-filter: blur(10px);
}

.hv-ticker-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hv-ticker-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 600;
}

.hv-ticker-value {
  font-size: 1.1rem;
  font-weight: 700;
  font-feature-settings: 'tnum';
}

/* ═══════════════════════════════════════════════════════════════════════════
   MINER CARDS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-miner-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  overflow: hidden;
  transition: var(--transition);
  position: relative;
  cursor: pointer;
}

.hv-miner-card:hover {
  transform: translateY(-6px);
  border-color: rgba(79,142,247,0.5);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 40px rgba(79,142,247,0.15);
}

.hv-miner-card.popular {
  border-color: rgba(240,180,41,0.4);
}

.hv-miner-card.popular:hover {
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), var(--shadow-gold);
}

/* Card image area with gradient overlay */
.hv-miner-image {
  position: relative;
  height: 200px;
  background: linear-gradient(135deg, #0d1535, #1a2550);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hv-miner-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.85;
  transition: transform 0.5s ease;
}

.hv-miner-card:hover .hv-miner-image img {
  transform: scale(1.05);
}

/* Gradient overlay on image */
.hv-miner-image::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 80px;
  background: linear-gradient(transparent, var(--bg-secondary));
}

.hv-miner-img-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: rgba(79,142,247,0.5);
  font-size: 3rem;
}

/* Badge overlays on miner card image */
.hv-miner-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hv-miner-badge.popular-badge {
  right: 12px;
  background: linear-gradient(135deg, var(--accent-gold), #d97706);
  color: #1a0a00;
}

.hv-miner-badge.free-badge {
  left: 12px;
  background: linear-gradient(135deg, var(--accent-green), #16a34a);
  color: white;
}

.hv-miner-body {
  padding: 20px;
}

.hv-miner-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.hv-miner-specs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.hv-spec-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.hv-miner-profit {
  background: rgba(34,197,94,0.08);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 16px;
  text-align: center;
}

.hv-profit-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.hv-profit-value {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--accent-green);
  font-feature-settings: 'tnum';
}

.hv-miner-price {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-primary);
  font-feature-settings: 'tnum';
}

.hv-miner-price-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-btn-primary {
  background: linear-gradient(135deg, var(--accent-blue) 0%, var(--accent-purple) 100%);
  border: none;
  color: #fff !important;
  font-weight: 600;
  border-radius: var(--radius-btn);
  padding: 10px 22px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hv-btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.15), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.hv-btn-primary:hover::before { opacity: 1; }
.hv-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(79,142,247,0.4);
}

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

.hv-btn-secondary {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-primary) !important;
  font-weight: 600;
  border-radius: var(--radius-btn);
  padding: 10px 22px;
  transition: var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hv-btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-blue);
  transform: translateY(-1px);
}

.hv-btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted) !important;
  font-weight: 500;
  border-radius: var(--radius-btn);
  padding: 8px 18px;
  transition: var(--transition);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hv-btn-ghost:hover {
  border-color: var(--border-hover);
  color: var(--text-primary) !important;
  background: rgba(79,142,247,0.05);
}

.hv-btn-danger {
  background: linear-gradient(135deg, var(--accent-red), #b91c1c);
  border: none;
  color: #fff !important;
  font-weight: 600;
  border-radius: var(--radius-btn);
  padding: 10px 22px;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hv-btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(239,68,68,0.4);
}

.hv-btn-gold {
  background: linear-gradient(135deg, var(--accent-gold), #d97706);
  border: none;
  color: #1a0a00 !important;
  font-weight: 700;
  border-radius: var(--radius-btn);
  padding: 10px 22px;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.hv-btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

/* ═══════════════════════════════════════════════════════════════════════════
   FORMS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-input,
.form-control,
.form-select {
  background: rgba(255,255,255,0.04) !important;
  border: 1px solid var(--border) !important;
  color: var(--text-primary) !important;
  border-radius: 10px !important;
  padding: 12px 16px !important;
  transition: var(--transition);
  font-size: 0.9rem;
}

.hv-input:focus,
.form-control:focus,
.form-select:focus {
  background: rgba(255,255,255,0.06) !important;
  border-color: var(--accent-blue) !important;
  box-shadow: 0 0 0 3px rgba(79,142,247,0.15) !important;
  outline: none;
}

.hv-input::placeholder,
.form-control::placeholder {
  color: rgba(148,163,184,0.5) !important;
}

.form-label {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 6px;
}

.form-select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.input-group-text {
  background: rgba(255,255,255,0.05) !important;
  border: 1px solid var(--border) !important;
  color: var(--text-muted) !important;
  border-radius: 10px !important;
}

/* ═══════════════════════════════════════════════════════════════════════════
   TABLES
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-table {
  color: var(--text-primary);
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
}

.hv-table thead th {
  background: rgba(255,255,255,0.04);
  color: var(--text-muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.hv-table tbody tr {
  transition: background 0.2s;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

.hv-table tbody tr:hover {
  background: rgba(79,142,247,0.05);
}

.hv-table tbody td {
  padding: 14px 16px;
  font-size: 0.875rem;
  vertical-align: middle;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

/* Striped variant */
.hv-table.striped tbody tr:nth-child(even) {
  background: rgba(255,255,255,0.02);
}

/* ═══════════════════════════════════════════════════════════════════════════
   MINER ANIMATION COMPONENTS
   ═══════════════════════════════════════════════════════════════════════════ */

/* Fan rotation */
.hv-fan {
  transform-origin: center;
  animation: spinFan 1.2s linear infinite;
  filter: drop-shadow(0 0 6px rgba(79,142,247,0.6));
}

.hv-fan.slow  { animation-duration: 3s;   }
.hv-fan.fast  { animation-duration: 0.5s; }
.hv-fan.idle  { animation: none;          }

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

/* Status LED */
.hv-status-led {
  width: 10px; height: 10px;
  border-radius: 50%;
  display: inline-block;
  position: relative;
}

.hv-status-led.active {
  background: var(--accent-green);
  animation: pulseLED 2s ease-in-out infinite;
  box-shadow: 0 0 6px var(--accent-green);
}

.hv-status-led.inactive {
  background: var(--text-muted);
}

.hv-status-led.warning {
  background: var(--accent-gold);
  animation: pulseLED 1s ease-in-out infinite;
}

@keyframes pulseLED {
  0%, 100% { opacity: 1;   box-shadow: 0 0 4px currentColor; }
  50%       { opacity: 0.5; box-shadow: 0 0 12px currentColor; }
}

/* Active waveform (audio-visualizer style bars) */
.hv-waveform {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 24px;
}

.hv-wave-bar {
  width: 4px;
  background: var(--accent-blue);
  border-radius: 2px;
  animation: waveBar 1.2s ease-in-out infinite;
}

.hv-wave-bar:nth-child(1) { animation-delay: 0s;    height: 60%; }
.hv-wave-bar:nth-child(2) { animation-delay: 0.15s; height: 100%; }
.hv-wave-bar:nth-child(3) { animation-delay: 0.3s;  height: 40%; }
.hv-wave-bar:nth-child(4) { animation-delay: 0.45s; height: 80%; }
.hv-wave-bar:nth-child(5) { animation-delay: 0.6s;  height: 30%; }
.hv-wave-bar:nth-child(6) { animation-delay: 0.75s; height: 70%; }

@keyframes waveBar {
  0%, 100% { transform: scaleY(0.4); opacity: 0.6; }
  50%       { transform: scaleY(1);   opacity: 1;   }
}

/* Miner status panel */
.hv-miner-status-panel {
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.8rem;
  font-family: 'Courier New', monospace;
  color: var(--accent-green);
}

.hv-miner-balance-counter {
  font-size: 1.4rem;
  font-weight: 800;
  font-feature-settings: 'tnum';
  color: var(--accent-gold);
  letter-spacing: -0.02em;
  font-family: 'Courier New', monospace;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PROGRESS BARS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-progress {
  background: rgba(255,255,255,0.06);
  border-radius: 99px;
  height: 8px;
  overflow: hidden;
}

.hv-progress-bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-purple));
  position: relative;
  transition: width 0.8s ease;
}

.hv-progress-bar::after {
  content: '';
  position: absolute;
  top: 0; left: -100%; right: 0; bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmerBar 2s infinite;
}

@keyframes shimmerBar {
  0%   { left: -100%; }
  100% { left: 200%;  }
}

/* Gold progress variant */
.hv-progress-bar.gold {
  background: linear-gradient(90deg, var(--accent-gold), #f59e0b);
}

.hv-progress-bar.green {
  background: linear-gradient(90deg, var(--accent-green), #16a34a);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BADGES / PILLS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hv-badge.blue   { background: rgba(79,142,247,0.15);  color: var(--accent-blue);   border: 1px solid rgba(79,142,247,0.3);  }
.hv-badge.green  { background: rgba(34,197,94,0.15);   color: var(--accent-green);  border: 1px solid rgba(34,197,94,0.3);   }
.hv-badge.gold   { background: rgba(240,180,41,0.15);  color: var(--accent-gold);   border: 1px solid rgba(240,180,41,0.3);  }
.hv-badge.red    { background: rgba(239,68,68,0.15);   color: var(--accent-red);    border: 1px solid rgba(239,68,68,0.3);   }
.hv-badge.purple { background: rgba(124,58,237,0.15);  color: var(--accent-purple); border: 1px solid rgba(124,58,237,0.3); }

/* ═══════════════════════════════════════════════════════════════════════════
   CHARTS CONTAINER
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-chart-container {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 24px;
  backdrop-filter: blur(20px);
}

.hv-chart-container canvas {
  max-height: 300px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   REFERRAL TREE / NODES
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-ref-tree {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 20px;
}

.hv-ref-level {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hv-ref-level-label {
  width: 60px;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

.hv-ref-nodes {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.hv-ref-node {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(79,142,247,0.15);
  border: 2px solid rgba(79,142,247,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-blue);
  position: relative;
  transition: var(--transition);
}

.hv-ref-node:hover {
  background: rgba(79,142,247,0.3);
  transform: scale(1.1);
}

/* Connector line */
.hv-ref-connector {
  width: 2px;
  background: linear-gradient(var(--accent-blue), transparent);
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════════════════════
   TOAST NOTIFICATIONS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-toast {
  background: var(--glass) !important;
  border: 1px solid var(--border) !important;
  backdrop-filter: blur(20px) !important;
  color: var(--text-primary) !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4) !important;
  min-width: 300px;
  animation: toastSlideIn 0.3s ease;
}

.hv-toast.success { border-color: rgba(34,197,94,0.4) !important; }
.hv-toast.error   { border-color: rgba(239,68,68,0.4) !important; }
.hv-toast.warning { border-color: rgba(240,180,41,0.4) !important; }
.hv-toast.info    { border-color: rgba(79,142,247,0.4) !important; }

.hv-toast .toast-header {
  background: transparent !important;
  border-bottom: 1px solid var(--border) !important;
  color: var(--text-primary) !important;
}

.hv-toast .btn-close {
  filter: invert(1);
}

@keyframes toastSlideIn {
  from { transform: translateX(100px); opacity: 0; }
  to   { transform: translateX(0);     opacity: 1; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   BOOTSTRAP MODAL — DARK THEME OVERRIDES
   ═══════════════════════════════════════════════════════════════════════════ */
.modal-content {
  background: var(--bg-secondary) !important;
  border: 1px solid var(--border) !important;
  border-radius: 20px !important;
  backdrop-filter: blur(30px);
  color: var(--text-primary) !important;
  box-shadow: 0 25px 80px rgba(0,0,0,0.6) !important;
}

.modal-header {
  border-bottom: 1px solid var(--border) !important;
  padding: 20px 24px !important;
}

.modal-footer {
  border-top: 1px solid var(--border) !important;
  padding: 16px 24px !important;
}

.modal-title { font-weight: 700; }

.modal-backdrop.show { backdrop-filter: blur(4px); }

.btn-close { filter: invert(1) !important; }

/* ═══════════════════════════════════════════════════════════════════════════
   ACCORDION (Bootstrap override)
   ═══════════════════════════════════════════════════════════════════════════ */
.accordion-item {
  background: var(--bg-card) !important;
  border: 1px solid var(--border) !important;
  border-radius: 12px !important;
  margin-bottom: 8px;
  overflow: hidden;
}

.accordion-button {
  background: transparent !important;
  color: var(--text-primary) !important;
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: none !important;
}

.accordion-button:not(.collapsed) {
  background: rgba(79,142,247,0.08) !important;
  color: var(--accent-blue) !important;
}

.accordion-button::after {
  filter: invert(1) brightness(0.7);
}

.accordion-body {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
  padding: 16px 20px !important;
}

/* ═══════════════════════════════════════════════════════════════════════════
   TABS (Bootstrap override)
   ═══════════════════════════════════════════════════════════════════════════ */
.nav-tabs {
  border-bottom: 1px solid var(--border) !important;
  gap: 4px;
}

.nav-tabs .nav-link {
  background: transparent !important;
  border: 1px solid transparent !important;
  color: var(--text-muted) !important;
  border-radius: 8px 8px 0 0 !important;
  font-weight: 500;
  transition: var(--transition);
}

.nav-tabs .nav-link:hover {
  color: var(--text-primary) !important;
  border-color: var(--border) var(--border) transparent !important;
}

.nav-tabs .nav-link.active {
  background: rgba(79,142,247,0.1) !important;
  border-color: var(--border) var(--border) var(--bg-primary) !important;
  color: var(--accent-blue) !important;
}

.tab-content { padding-top: 24px; }

/* Filter pills (miner tabs) */
.hv-filter-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.hv-filter-pill {
  padding: 8px 20px;
  border-radius: 99px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.hv-filter-pill:hover,
.hv-filter-pill.active {
  background: rgba(79,142,247,0.15);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}

/* ═══════════════════════════════════════════════════════════════════════════
   SECTION HEADERS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-section {
  padding: 80px 0;
}

.hv-section-header {
  text-align: center;
  margin-bottom: 60px;
}

.hv-section-eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-blue);
  background: rgba(79,142,247,0.1);
  border: 1px solid rgba(79,142,247,0.3);
  padding: 4px 14px;
  border-radius: 99px;
  margin-bottom: 16px;
}

.hv-section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 16px;
}

.hv-section-sub {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FEATURE CARDS (How It Works, Why HashVault)
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 32px 24px;
  text-align: center;
  transition: var(--transition);
  height: 100%;
}

.hv-feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-card), var(--shadow-glow);
}

.hv-feature-icon {
  width: 64px; height: 64px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin: 0 auto 20px;
}

.hv-step-number {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  margin: 0 auto 16px;
  box-shadow: 0 4px 20px rgba(79,142,247,0.3);
}

/* ═══════════════════════════════════════════════════════════════════════════
   TESTIMONIAL CARDS
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 28px;
  transition: var(--transition);
  position: relative;
}

.hv-testimonial-card::before {
  content: '\201C';
  position: absolute;
  top: 16px; right: 20px;
  font-size: 4rem;
  color: rgba(79,142,247,0.15);
  font-family: Georgia, serif;
  line-height: 1;
}

.hv-testimonial-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

.hv-testimonial-stars {
  color: var(--accent-gold);
  font-size: 0.9rem;
  margin-bottom: 12px;
}

.hv-testimonial-text {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 20px;
  font-style: italic;
}

.hv-testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.hv-testimonial-avatar {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: white;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   CTA BANNER
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-cta-section {
  background: linear-gradient(135deg,
    rgba(79,142,247,0.12) 0%,
    rgba(124,58,237,0.08) 50%,
    rgba(240,180,41,0.06) 100%);
  border: 1px solid rgba(79,142,247,0.2);
  border-radius: 24px;
  padding: 60px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hv-cta-section::before {
  content: '';
  position: absolute;
  top: -100px; left: 50%;
  transform: translateX(-50%);
  width: 600px; height: 300px;
  background: radial-gradient(ellipse, rgba(79,142,247,0.1), transparent 70%);
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   LOADING OVERLAY
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-loader-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 14, 26, 0.9);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.hv-loader-spinner {
  text-align: center;
}

/* Inline shimmer loading for cards */
.hv-shimmer {
  background: linear-gradient(
    90deg,
    rgba(255,255,255,0.03) 25%,
    rgba(255,255,255,0.08) 50%,
    rgba(255,255,255,0.03) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 8px;
}

@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 60px 0 30px;
  margin-top: auto;
}

.hv-footer-brand {
  display: flex;
  align-items: center;
}

.hv-footer-heading {
  color: var(--text-primary);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}

.hv-footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.hv-footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.hv-footer-links a:hover {
  color: var(--accent-blue);
}

.hv-footer-divider {
  border-color: var(--border);
  margin: 30px 0 20px;
}

.hv-social-links {
  display: flex;
  gap: 10px;
}

.hv-social-link {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
  font-size: 1rem;
}

.hv-social-link:hover {
  background: rgba(79,142,247,0.15);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  transform: translateY(-2px);
}

/* ═══════════════════════════════════════════════════════════════════════════
   POOL PAGE SPECIFIC
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-pool-header {
  background: linear-gradient(135deg, rgba(79,142,247,0.08), rgba(124,58,237,0.05));
  border: 1px solid rgba(79,142,247,0.15);
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 40px;
}

.hv-hashrate-counter {
  font-size: 2.5rem;
  font-weight: 900;
  font-feature-settings: 'tnum';
  letter-spacing: -0.04em;
  color: var(--accent-blue);
  font-family: 'Courier New', monospace;
}

.hv-stratum-box {
  background: rgba(0,0,0,0.4);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 18px;
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  color: var(--accent-green);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   DASHBOARD SPECIFIC
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-dashboard-header {
  padding: 40px 0 20px;
}

.hv-greeting {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* Active miner row in dashboard */
.hv-active-miner-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 12px;
  transition: var(--transition);
}

.hv-active-miner-row:hover {
  background: rgba(79,142,247,0.05);
  border-color: var(--border-hover);
}

/* ═══════════════════════════════════════════════════════════════════════════
   PAGE TRANSITIONS
   ═══════════════════════════════════════════════════════════════════════════ */
#main-content {
  animation: pageFadeIn 0.3s ease;
}

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

/* ═══════════════════════════════════════════════════════════════════════════
   TEAM CARD (About page)
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-team-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 32px 24px;
  text-align: center;
  transition: var(--transition);
}

.hv-team-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
}

.hv-team-avatar {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 2rem;
  color: white;
}

.hv-partner-logo {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  height: 80px;
}

.hv-partner-logo:hover {
  border-color: var(--border-hover);
  background: rgba(79,142,247,0.05);
}

/* ═══════════════════════════════════════════════════════════════════════════
   SEARCH BAR (Help page)
   ═══════════════════════════════════════════════════════════════════════════ */
.hv-search-bar {
  position: relative;
  max-width: 600px;
  margin: 0 auto;
}

.hv-search-bar input {
  padding-left: 50px !important;
  font-size: 1rem !important;
  height: 56px;
}

.hv-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1.2rem;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE BREAKPOINTS
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 991.98px) {
  .hv-navbar { padding: 8px 0; }

  .navbar-collapse {
    background: var(--glass-nav);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 16px;
    margin-top: 8px;
  }

  .hv-hero { padding: 60px 0 50px; }

  .hv-stats-ticker {
    gap: 20px;
    padding: 16px;
  }

  .hv-section { padding: 60px 0; }

  .hv-cta-section { padding: 40px 24px; }

  .hv-pool-header { padding: 24px; }
}

@media (max-width: 575.98px) {
  .hv-hero { padding: 40px 0 30px; }
  .hv-section { padding: 40px 0; }
  .hv-stat-value { font-size: 1.3rem; }
  .hv-hashrate-counter { font-size: 1.8rem; }
  .hv-ticker-item { min-width: calc(50% - 10px); }
}

/* ═══════════════════════════════════════════════════════════════════════════
   UTILITY OVERRIDES
   ═══════════════════════════════════════════════════════════════════════════ */

/* Ensure section containers have proper spacing */
.container-xl { max-width: 1280px; }

/* Divider */
.hv-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  margin: 40px 0;
}

/* Copy button */
.hv-copy-btn {
  background: rgba(79,142,247,0.1);
  border: 1px solid rgba(79,142,247,0.3);
  color: var(--accent-blue);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: var(--transition);
}

.hv-copy-btn:hover {
  background: rgba(79,142,247,0.2);
}

.hv-copy-btn.copied {
  color: var(--accent-green);
  border-color: rgba(34,197,94,0.3);
  background: rgba(34,197,94,0.1);
}

/* Alert overrides */
.alert {
  border-radius: 12px !important;
  border-width: 1px !important;
  font-size: 0.9rem;
}

.alert-success {
  background: rgba(34,197,94,0.1) !important;
  border-color: rgba(34,197,94,0.3) !important;
  color: var(--accent-green) !important;
}

.alert-danger {
  background: rgba(239,68,68,0.1) !important;
  border-color: rgba(239,68,68,0.3) !important;
  color: var(--accent-red) !important;
}

.alert-warning {
  background: rgba(240,180,41,0.1) !important;
  border-color: rgba(240,180,41,0.3) !important;
  color: var(--accent-gold) !important;
}

.alert-info {
  background: rgba(79,142,247,0.1) !important;
  border-color: rgba(79,142,247,0.3) !important;
  color: var(--accent-blue) !important;
}

/* ROI Calculator result */
.hv-roi-result {
  background: rgba(34,197,94,0.08);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.85rem;
  margin-top: 12px;
  display: none;
}

.hv-roi-result.visible { display: block; }

/* ═══════════════════════════════════════════════════════════════════════════
   LIGHT MODE THEME
   Apply via: document.documentElement.setAttribute("data-theme","light")
   ═══════════════════════════════════════════════════════════════════════════ */
[data-theme="light"] {
  --bg-primary:    #f4f7fb;
  --bg-secondary:  #eaf0f8;
  --bg-card:       rgba(255, 255, 255, 0.92);
  --bg-card-hover: rgba(255, 255, 255, 1);
  --text-primary:  #0f172a;
  --text-muted:    #5a7189;
  --border:        rgba(0, 0, 0, 0.09);
  --border-hover:  rgba(79, 142, 247, 0.45);
  --glass:         rgba(244, 247, 251, 0.92);
  --glass-nav:     rgba(244, 247, 251, 0.97);
  --shadow-card:   0 2px 20px rgba(0, 0, 0, 0.08);
  --shadow-glow:   0 0 30px rgba(79, 142, 247, 0.10);
  --shadow-gold:   0 0 20px rgba(240, 180, 41, 0.15);
}

[data-theme="light"] body {
  background-color: var(--bg-primary);
  background-image: none;
}

[data-theme="light"] .hv-navbar {
  background: #0f172a !important;
  border-bottom: 1px solid rgba(255,255,255,0.1) !important;
  box-shadow: 0 1px 12px rgba(0,0,0,0.06) !important;
}

[data-theme="light"] .navbar-collapse {
  background: #0f172a !important;
}

[data-theme="light"] .hv-nav-link { color: #ffffff !important; }
[data-theme="light"] .hv-nav-link:hover,
[data-theme="light"] .hv-nav-link.active { color: var(--accent-blue) !important; }

[data-theme="light"] .hv-theme-toggle {
  color: #ffffff !important;
}

[data-theme="light"] .hv-navbar.scrolled {
  background: #0f172a !important;
  box-shadow: 0 4px 30px rgba(0,0,0,0.1) !important;
}

[data-theme="light"] .hv-card {
  background: var(--bg-card);
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: var(--shadow-card);
  color: var(--text-primary);
}

[data-theme="light"] .hv-input {
  background: #ffffff;
  border-color: rgba(0,0,0,0.14);
  color: var(--text-primary);
}
[data-theme="light"] .hv-input:focus {
  background: #ffffff;
  border-color: var(--accent-blue);
  color: var(--text-primary);
}
[data-theme="light"] .hv-input-group-text {
  background: #f1f5f9;
  border-color: rgba(0,0,0,0.14);
  color: var(--text-primary);
}

[data-theme="light"] .hv-balance-pill {
  background: rgba(240,180,41,0.1);
  color: var(--accent-gold);
  border-color: rgba(240,180,41,0.3);
}

[data-theme="light"] .modal-content {
  background: #ffffff;
  border-color: rgba(0,0,0,0.1);
  color: var(--text-primary);
}
[data-theme="light"] .modal-header,
[data-theme="light"] .modal-footer { border-color: rgba(0,0,0,0.08); }

[data-theme="light"] .hv-table thead th {
  background: rgba(0,0,0,0.04);
  color: var(--text-primary);
  border-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .hv-table tbody tr { border-color: rgba(0,0,0,0.05); }
[data-theme="light"] .hv-table tbody tr:hover { background: rgba(79,142,247,0.04); }

[data-theme="light"] .hv-footer { background: #0f172a; }

[data-theme="light"] .hv-section-hero {
  background: linear-gradient(180deg,rgba(244,247,251,0.95),var(--bg-primary));
}

[data-theme="light"] .accordion-button {
  background: var(--bg-card);
  color: var(--text-primary);
}
[data-theme="light"] .accordion-button:not(.collapsed) {
  background: rgba(79,142,247,0.07);
  color: var(--accent-blue);
}
[data-theme="light"] .accordion-body { background: var(--bg-card); }

[data-theme="light"] .form-select {
  background-color: #ffffff;
  border-color: rgba(0,0,0,0.14);
  color: var(--text-primary);
}

[data-theme="light"] .hv-miner-active-card { border-color: rgba(0,0,0,0.08); }
[data-theme="light"] .hv-wave-bar { background: rgba(79,142,247,0.5); }

[data-theme="light"] .hv-page-section {
  background: #ffffff !important;
}

/* Theme toggle button */
.theme-toggle-btn {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-btn);
  color: var(--text-primary);
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  flex-shrink: 0;
  padding: 0;
  line-height: 1;
}
.theme-toggle-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-blue);
  color: var(--accent-blue);
}
