@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Outfit:wght@400;500;600;700;800&display=swap');

/* ── CSS Variables ── */
:root {
  /* Dark Theme (Default) */
  --bg-primary: #06060f;
  --bg-secondary: #0d0d1a;
  --bg-card: rgba(16, 16, 32, 0.7);
  --bg-card-hover: rgba(22, 22, 44, 0.82);
  --bg-glass: rgba(255, 255, 255, 0.03);
  --bg-input: rgba(255, 255, 255, 0.05);

  /* Accents */
  --accent-purple: #8b5cf6;
  --accent-blue: #3b82f6;
  --accent-cyan: #06b6d4;
  --accent-green: #10b981;
  --accent-pink: #ec4899;
  --accent-orange: #f59e0b;
  --accent-red: #ef4444;

  /* Gradients */
  --gradient-hero: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 50%, #06b6d4 100%);
  --gradient-purple: linear-gradient(135deg, #8b5cf6, #6d28d9);
  --gradient-blue: linear-gradient(135deg, #3b82f6, #2563eb);
  --gradient-green: linear-gradient(135deg, #10b981, #059669);
  --gradient-card: linear-gradient(145deg, rgba(139, 92, 246, 0.08), rgba(59, 130, 246, 0.05));

  /* Text */
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-accent: #c4b5fd;

  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-glow: rgba(139, 92, 246, 0.3);

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(139, 92, 246, 0.15);

  /* Sizing */
  --sidebar-width: 260px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* ── Light Theme ── */
[data-theme="light"] {
  --bg-primary: #f1f5f9;
  --bg-secondary: #ffffff;
  --bg-card: rgba(255, 255, 255, 0.9);
  --bg-card-hover: rgba(255, 255, 255, 1);
  --bg-glass: rgba(0, 0, 0, 0.05);
  --bg-input: #e2e8f0;

  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-muted: #6b7280;
  --text-accent: #6d28d9;

  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-glow: rgba(139, 92, 246, 0.3);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.12);
}

/* ── Premium Auth Card ── */
.premium-auth-card {
  background: rgba(15, 15, 30, 0.45);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  padding: 40px;
  width: 100%;
  max-width: 460px;
  margin: 40px auto 0;
  box-shadow: 
    0 24px 80px rgba(0, 0, 0, 0.4),
    0 0 40px rgba(139, 92, 246, 0.15);
  animation: floatUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
  color: white; /* Always white text on premium card */
}

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

.premium-input {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  padding: 14px 18px;
  color: white;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  transition: all 0.3s ease;
  outline: none;
}

.premium-input:focus {
  background: rgba(0, 0, 0, 0.4);
  border-color: var(--accent-purple);
  box-shadow: 0 0 15px rgba(139, 92, 246, 0.25);
}

.premium-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.social-glass-btn {
  flex: 1;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  cursor: pointer;
  transition: all 0.25s ease;
  color: white;
}

.social-glass-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

.social-glass-btn.discord:hover { background: rgba(88, 101, 242, 0.25); border-color: #5865F2; }
.social-glass-btn.twitter:hover { background: rgba(255, 255, 255, 0.2); border-color: #ffffff; }
.social-glass-btn.google:hover { background: rgba(255, 255, 255, 0.2); border-color: #ffffff; }

.auth-divider-premium {
  display: flex;
  align-items: center;
  margin: 30px 0;
  gap: 15px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.auth-divider-premium::before,
.auth-divider-premium::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
}

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

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, .hero-title, .brand-name {
  font-family: 'Outfit', sans-serif;
}

/* ── Background Effects ── */
body::before {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(139, 92, 246, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(59, 130, 246, 0.04) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 50%, rgba(6, 182, 212, 0.03) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
  transition: opacity 0.5s ease;
}

[data-theme="light"] body::before {
  opacity: 0.4;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(139, 92, 246, 0.04) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(59, 130, 246, 0.03) 0%, transparent 50%);
}

/* ── Theme Toggle ── */
.theme-toggle {
  position: fixed;
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: var(--accent-purple);
  box-shadow: var(--shadow-md);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  position: absolute;
  top: 50%;
  left: 50%;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.sun-icon { opacity: 0; transform: translate(-50%, -50%) rotate(90deg) scale(0); }
.moon-icon { opacity: 1; transform: translate(-50%, -50%) rotate(0) scale(1); }


[data-theme="light"] .sun-icon { opacity: 1; transform: translate(-50%, -50%) rotate(0) scale(1); }
[data-theme="light"] .moon-icon { opacity: 0; transform: translate(-50%, -50%) rotate(-90deg) scale(0); }

/* ── Layout ── */
.app-layout {
  display: flex;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-subtle);
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  margin-bottom: 32px;
}

.brand-icon {
  width: 40px;
  height: 40px;
  background: var(--gradient-hero);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 0 20px rgba(139, 92, 246, 0.2);
}

.brand-name {
  font-size: 20px;
  font-weight: 800;
  background: var(--gradient-hero);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.nav-item:hover {
  background: var(--bg-glass);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(139, 92, 246, 0.08);
  color: var(--accent-purple);
  font-weight: 600;
}

.nav-item .nav-icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

/* ── Sidebar User Profile ── */
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--bg-glass);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
  border: 1px solid var(--border-subtle);
  transition: all 0.3s ease;
}

.sidebar-user:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-glow);
}

.user-avatar-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gradient-hero);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

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

.user-display-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.logout-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logout-btn:hover {
  background: rgba(239, 68, 68, 0.1);
  color: var(--accent-red);
}

.logout-icon {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

.sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid var(--border-subtle);
  margin-top: auto;
}

.network-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.network-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.4); }
  50% { transform: scale(1.02); opacity: 0.8; box-shadow: 0 0 0 10px rgba(34, 197, 94, 0); }
  100% { transform: scale(1); opacity: 1; box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

@keyframes pulse-yellow {
  0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(234, 179, 8, 0.4); }
  50% { transform: scale(1.02); box-shadow: 0 0 0 8px rgba(234, 179, 8, 0); }
  100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(234, 179, 8, 0); }
}

/* ── Main Content ── */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 32px;
  max-width: 1200px;
}

/* ── Hero Banner (Always Dark) ── */
.hero-banner {
  background: #06060f url('https://w0.peakpx.com/wallpaper/547/693/HD-wallpaper-purple-black-abstract-purple-vivid-gradient-colors-dark.jpg') center/cover no-repeat;
  background: var(--gradient-hero);
  color: white !important;
  border-radius: var(--radius-xl);
  padding: 48px 56px;
  margin-bottom: 32px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 1;
}

.hero-banner .hero-subtitle {
  color: rgba(255, 255, 255, 0.8) !important;
}

.hero-banner h1 {
  color: white !important;
}

.hero-banner::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 50%;
  background: radial-gradient(circle at 70% 50%, rgba(255, 255, 255, 0.1), transparent 70%);
  pointer-events: none;
}

.hero-title {
  font-size: 40px;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -1px;
}

.hero-subtitle {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.85);
  max-width: 600px;
  line-height: 1.5;
}

/* ── Hero Auth Panel ── */
.hero-auth-panel {
  margin-top: 32px;
  background: rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(12px);
  padding: 24px;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.1);
  max-width: 700px;
  animation: slideInUp 0.6s ease-out;
}

.auth-divider {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
}

.auth-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-auth-panel .btn-social {
  flex: 1;
  min-width: 140px;
  justify-content: center;
  padding: 12px 20px;
  font-size: 14px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
}

.hero-auth-panel .btn-social:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.btn-social.discord { background: #5865F2; color: white; }
.btn-social.twitter { background: #000000; color: white; border: 1px solid rgba(255,255,255,0.1) !important; }
.btn-social.google { background: #ffffff; color: #000; }

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

/* ── Dashboard Grid ── */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 24px;
  margin-bottom: 32px;
}

/* ── Cards ── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 28px;
  backdrop-filter: blur(20px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: visible !important; /* Cage Break: Stop clipping dropdowns */
}

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

/* ── Entry Animations ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.card {
  animation: fadeInUp 0.5s ease backwards;
}

.dashboard-grid > *:nth-child(1) { animation-delay: 0.1s; }
.dashboard-grid > *:nth-child(2) { animation-delay: 0.2s; }
.dashboard-grid > *:nth-child(3) { animation-delay: 0.3s; }
.dashboard-grid > *:nth-child(4) { animation-delay: 0.4s; }

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  overflow: visible !important; /* Cage Break: Stop clipping dropdowns */
}

.card-title {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ── Credit Card Style Balance ── */
.credit-card-item {
  width: 100%;
  aspect-ratio: 1.586;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 24px;
  padding: 30px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 
    0 20px 40px rgba(0, 0, 0, 0.4),
    inset 0 0 0 1px rgba(255,255,255,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

[data-theme="light"] .credit-card-item {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(20, 20, 40, 0.9));
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.credit-card-item:hover {
  transform: translateY(-5px);
  box-shadow: 
    0 30px 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(139, 92, 246, 0.3);
  border-color: rgba(139, 92, 246, 0.5);
}

.credit-card-item::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 50% 0%, rgba(139, 92, 246, 0.2), transparent 50%);
  pointer-events: none;
}

.cc-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  z-index: 1;
}

.cc-chip {
  width: 48px;
  height: 36px;
  background: linear-gradient(135deg, #ffd700, #b8860b);
  border-radius: 6px;
  position: relative;
  overflow: hidden;
  opacity: 0.9;
  border: 1px solid rgba(0,0,0,0.2);
}
.cc-chip::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: 
    linear-gradient(90deg, transparent 40%, rgba(0,0,0,0.1) 40%, rgba(0,0,0,0.1) 60%, transparent 60%),
    linear-gradient(0deg, transparent 40%, rgba(0,0,0,0.1) 40%, rgba(0,0,0,0.1) 60%, transparent 60%);
}

.cc-brand {
  font-family: 'Outfit', sans-serif;
  color: #fff;
  font-weight: 800;
  font-size: 18px;
  text-align: right;
  line-height: 1.1;
  letter-spacing: 1px;
}

.cc-body {
  z-index: 1;
  margin-top: 10px;
}

.cc-balance-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 4px;
}

.cc-balance {
  font-family: 'Outfit', sans-serif;
  font-size: 46px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -1px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.cc-balance .currency {
  font-size: 20px;
  font-weight: 500;
  opacity: 0.7;
  letter-spacing: 0;
  margin-left: 6px;
}

.cc-assets {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 1;
  margin-top: 20px;
}

.cc-asset-list {
  display: flex;
  gap: 20px;
}

.cc-asset {
  display: flex;
  flex-direction: column;
}

.cc-asset span:first-child {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
}

.cc-asset span:last-child {
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
}

.cc-owner {
  display: flex;
  flex-direction: column;
  text-align: right;
}

.cc-owner span:first-child {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 1px;
}

.cc-owner span:last-child {
  font-size: 15px;
  font-weight: 600;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 2px;
}

@media (max-width: 600px) {
  .credit-card-item {
    padding: 20px;
  }
  .cc-balance {
    font-size: 34px;
  }
  .cc-chip {
    width: 40px;
    height: 28px;
  }
  .cc-brand {
    font-size: 14px;
  }
  .cc-assets {
    margin-top: 10px;
  }
  .cc-asset span:last-child {
    font-size: 13px;
  }
  .cc-owner span:last-child {
    font-size: 12px;
  }
}

/* ── Action Buttons Panel ── */
.actions-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.action-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(10px);
  text-align: left;
}

.action-btn:hover:not(:disabled) {
  transform: translateX(4px);
  border-color: var(--accent-purple);
  box-shadow: var(--shadow-md);
  background: var(--bg-card-hover);
}

.action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  filter: grayscale(0.8);
}

.action-btn .action-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.action-btn .action-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
}

.action-btn.create .action-icon {
  background: var(--gradient-purple);
  color: white;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.2);
}

.action-btn.send .action-icon {
  background: var(--gradient-blue);
  color: white;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.action-btn.topup .action-icon {
  background: var(--gradient-green);
  color: white;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.action-btn.withdraw .action-icon {
  background: rgba(239, 68, 68, 0.1);
  color: var(--accent-red);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.action-btn-text {
  display: flex;
  flex-direction: column;
  font-family: 'Outfit', sans-serif;
}

.action-btn-sub {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ── Transactions ── */
.tx-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tx-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
  background: var(--bg-glass);
  border: 1px solid transparent;
}

.tx-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-subtle);
  transform: scale(1.01);
}

.tx-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
}

.tx-icon.send { color: var(--accent-blue); background: rgba(59, 130, 246, 0.1); }
.tx-icon.receive { color: var(--accent-green); background: rgba(16, 185, 129, 0.1); }
.tx-icon.topup { color: var(--accent-orange); background: rgba(245, 158, 11, 0.1); }
.tx-icon.fee { color: var(--accent-pink); background: rgba(236, 72, 153, 0.1); }

.tx-details {
  flex: 1;
  min-width: 0;
}

.tx-title {
  font-family: 'Outfit', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.tx-address {
  font-size: 12px;
  color: var(--text-muted);
  font-family: 'Inter', monospace;
  letter-spacing: -0.2px;
}

.tx-amount-group {
  text-align: right;
}

.tx-amount {
  font-family: 'Outfit', sans-serif;
  font-size: 16px;
  font-weight: 700;
}

.tx-amount.positive { color: var(--accent-green); }
.tx-amount.negative { color: var(--accent-red); }

.tx-status {
  font-size: 10px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-top: 4px;
  display: inline-block;
}

.tx-status.confirmed {
  background: rgba(16, 185, 129, 0.1);
  color: var(--accent-green);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.tx-status.pending {
  background: rgba(245, 158, 11, 0.1);
  color: var(--accent-orange);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

/* ── Spending Progress ── */
@keyframes pulse-glow {
  0% { box-shadow: 0 0 10px rgba(139, 92, 246, 0.2); }
  50% { box-shadow: 0 0 25px rgba(139, 92, 246, 0.5); }
  100% { box-shadow: 0 0 10px rgba(139, 92, 246, 0.2); }
}

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

@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes scale-up {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* 2. Interactive Polish */
.card {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg), 0 0 20px rgba(139, 92, 246, 0.1);
}

.balance-total {
  animation: fade-in-up 0.6s ease-out;
}

#balance-card.highlight {
  animation: pulse-glow 2s infinite;
  border-color: var(--accent-purple);
}

/* 3. Onboarding Modal Styles */
.onboarding-content {
  animation: scale-up 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  border: 1px solid rgba(139, 92, 246, 0.3);
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.8), 0 0 40px rgba(139, 92, 246, 0.1);
}

.onboarding-step {
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  transition: transform 0.2s ease;
}

.onboarding-step:hover {
  transform: scale(1.02);
  background: rgba(255, 255, 255, 0.06);
}

/* 4. Faucet Card Enhancements */
.faucet-card {
  animation: fade-in-up 0.8s ease-out;
  position: relative;
  overflow: hidden;
}

.faucet-card::after {
  content: "";
  position: absolute;
  top: 0; left: 0; width: 200%; height: 100%;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.05), transparent);
  animation: shimmer 4s infinite linear;
  pointer-events: none;
}

/* 5. Skeleton Loader (Shimmer) */
.shimmer-loading {
  background: linear-gradient(90deg, 
    var(--bg-input) 25%, 
    rgba(255, 255, 255, 0.08) 50%, 
    var(--bg-input) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 4px;
}

/* Shorthand for usage in JS */
.invisible-until-load {
  opacity: 0;
  transition: opacity 0.5s ease;
}

.visible-now {
  opacity: 1;
}

/* ── Spending Progress ── */
.spending-card-content {
  padding: 16px;
  background: var(--bg-glass);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
}

.spending-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.spending-value {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

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

/* ── Virtual Cards (3D) ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.virtual-card-wrapper {
  perspective: 1000px;
  height: 200px;
  cursor: pointer;
}

.virtual-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: left;
  transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

.virtual-card-wrapper:hover .virtual-card-inner {
  transform: rotateY(180deg);
}

.card-face {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 16px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.card-face.front {
  background: linear-gradient(135deg, #1e293b, #0f172a);
  z-index: 2;
}

.card-face.back {
  background: linear-gradient(135deg, #0f172a, #1e293b);
  transform: rotateY(180deg);
}

.v-card-chip {
  width: 40px;
  height: 30px;
  background: linear-gradient(135deg, #ffd700, #daa520);
  border-radius: 4px;
  margin-bottom: 10px;
}

.v-card-number {
  font-family: 'Outfit', monospace;
  font-size: 20px;
  letter-spacing: 2px;
  color: white;
  margin: 10px 0;
}

.v-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.v-card-info label {
  display: block;
  font-size: 9px;
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
  margin-bottom: 2px;
}

.v-card-info span {
  font-size: 14px;
  font-weight: 600;
  color: white;
}

.v-card-balance {
  text-align: right;
}

.v-card-balance .amt {
  display: block;
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-green);
}

.v-card-brand {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-style: italic;
  font-size: 18px;
  color: rgba(255, 255, 255, 0.8);
}

.v-card-magstrip {
  width: 100%;
  height: 40px;
  background: #000;
  margin: 0 -24px;
  margin-top: 10px;
}

.card-loading-placeholder {
  grid-column: 1 / -1;
  padding: 40px;
  text-align: center;
  color: var(--text-muted);
  background: var(--bg-glass);
  border-radius: 16px;
  border: 1px dashed var(--border-subtle);
}

/* ── Progress Indicators ── */
.progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  overflow: hidden;
  margin-top: 12px;
}

.progress-bar {
  height: 100%;
  background: var(--gradient-purple);
  border-radius: 10px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.pending-item {
  animation: pulse-yellow 3s infinite ease-in-out;
  border-color: rgba(234, 179, 8, 0.2) !important;
}

/* ── Modal ── */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 40px;
  width: 90%;
  max-width: 480px;
  backdrop-filter: blur(40px);
  box-shadow: var(--shadow-lg), 0 0 40px rgba(139, 92, 246, 0.1);
  position: relative;
  transform: scale(0.95) translateY(10px);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal {
  transform: scale(1) translateY(0);
}

@keyframes modalScaleUp {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  margin-bottom: 32px;
}

.modal-title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.modal-close {
  position: absolute;
  top: 24px;
  right: 24px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
}

.modal-close:hover {
  background: rgba(239, 68, 68, 0.1);
  color: var(--accent-red);
  border-color: rgba(239, 68, 68, 0.2);
  transform: scale(1.05);
}

.modal-close svg {
  stroke: currentColor;
}

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

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.form-input {
  width: 100%;
  padding: 16px 20px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 500;
  outline: none;
  transition: all 0.3s ease;
}

.form-input:focus {
  border-color: var(--accent-purple);
  background: var(--bg-secondary);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-hint {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

.btn-primary {
  width: 100%;
  padding: 14px 24px;
  background: var(--gradient-purple);
  border: none;
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(139, 92, 246, 0.4);
}

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

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-primary.green {
  background: var(--gradient-green);
}
.btn-primary.green:hover {
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.4);
}

.btn-primary.blue {
  background: var(--gradient-blue);
}
.btn-primary.blue:hover {
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
  width: 100%;
  padding: 14px 24px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-secondary:hover {
  background: var(--bg-input);
  border-color: rgba(139, 92, 246, 0.4);
}
.btn-secondary:active {
  transform: translateY(0);
}

.btn-sm {
  width: auto;
  padding: 6px 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
}

/* ── Fee Preview ── */
.fee-preview {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 20px;
}

.fee-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 4px 0;
}

.fee-row .label { color: var(--text-muted); }
.fee-row .value { color: var(--text-primary); font-weight: 500; }
.fee-row.total { border-top: 1px solid var(--border-subtle); padding-top: 8px; margin-top: 4px; }
.fee-row.total .value { color: var(--accent-purple); font-weight: 700; }

/* ── Toast Notifications ── */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  box-shadow: var(--shadow-md);
  animation: slideIn 0.3s ease, fadeOut 0.3s ease 4s forwards;
  max-width: 380px;
}

.toast.success { border-left: 3px solid var(--accent-green); }
.toast.error { border-left: 3px solid var(--accent-red); }
.toast.info { border-left: 3px solid var(--accent-blue); }

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

@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* ── Wallet Address Display ── */
.wallet-address-display {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.wallet-address-text {
  font-family: 'Inter', monospace;
  font-size: 13px;
  color: var(--text-accent);
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.copy-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 16px;
  padding: 4px;
  transition: color 0.2s;
}

.copy-btn:hover { color: var(--accent-purple); }

/* ── Loading Spinner ── */
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  margin-right: 8px;
}

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

/* ── No Wallet State ── */
.no-wallet-state {
  text-align: center;
  padding: 60px 24px;
}

.no-wallet-icon {
  font-size: 64px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.no-wallet-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.no-wallet-text {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* ── Wallet Section (visible after creation) ── */
.wallet-info-bar {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.wallet-info-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

.wallet-info-address {
  font-family: 'Inter', monospace;
  font-size: 13px;
  color: var(--accent-purple);
  flex: 1;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Mobile Styles ── */
.mobile-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-subtle);
  display: none;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 200;
  backdrop-filter: blur(10px);
}

.mobile-top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.menu-toggle {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.mobile-logout-btn {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  color: var(--accent-red);
  padding: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 2400; /* High z-index but below open sidebar */
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (max-width: 768px) {
  .mobile-header {
    display: flex;
  }
  /* Unify theme toggle into the header slot */
  .theme-toggle {
    position: absolute;
    top: 50%;
    right: 60px; /* Space for logout btn */
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    background: transparent;
    border: none;
    z-index: 201;
  }
  /* If not logged in, move toggle to far right */
  body.auth-hidden .theme-toggle {
    right: 16px;
  }
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 20px 0 60px rgba(0,0,0,0.6);
    z-index: 2500; /* Absolute top priority */
  }
  .sidebar-overlay.open {
    display: block;
  }
  .main-content {
    margin-left: 0;
    padding: 20px;
    padding-top: 84px; /* Space for mobile header */
  }
  .sidebar-overlay.open {
    display: block;
  }
  .hero-banner {
    padding: 24px 20px;
  }
  .hero-title {
    font-size: 24px;
    letter-spacing: -0.5px;
  }
  .balance-total {
    font-size: 32px;
  }
  .balance-row {
    flex-direction: column;
    gap: 12px;
  }
  .mobile-menu-btn {
    display: none !important; /* Hide redundant button */
  }
  .dashboard-grid {
    gap: 16px;
  }
}

@media (max-width: 480px) {
  .hero-banner {
    border-radius: var(--radius-lg);
    padding: 20px;
  }
  .card {
    padding: 20px;
  }
  .balance-total {
    font-size: 28px;
  }
}

.mobile-menu-btn {
  display: none;
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 101;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  font-size: 20px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* ── Secure Linking Buttons ── */
.secure-link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.btn-social {
  width: 100% !important;
  padding: 12px 16px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  font-weight: 600;
  font-size: 13px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  background-image: none !important; /* Kill the default gradient */
}

.btn-social.discord { background-color: #5865F2 !important; color: #fff !important; }
.btn-social.twitter { background-color: #000000 !important; color: #fff !important; border: 1px solid rgba(255,255,255,0.2) !important; }
.btn-social.google { background-color: #ffffff !important; color: #000 !important; }

.btn-social:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

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

#link-status-msg a:hover {
  text-decoration: underline !important;
}

/* ── Auth/Landing State ── */
body.auth-hidden .sidebar,
body.auth-hidden .mobile-header,
body.auth-hidden .mobile-menu-btn,
body.auth-hidden #page-dashboard,
body.auth-hidden #page-wallet,
body.auth-hidden #page-payments,
body.auth-hidden #page-topup,
body.auth-hidden #page-settings,
body.auth-hidden .actions-panel,
body.auth-hidden .card {
  display: none !important;
}

body.auth-hidden .main-content {
  margin-left: 0 !important;
  width: 100vw !important;
  max-width: 100% !important;
  padding: 40px 20px !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  min-height: 80vh !important;
}

body.auth-hidden .hero-banner {
  max-width: 800px;
  width: 100%;
  margin: 0 auto;
  text-align: center;
}

body.auth-hidden .hero-subtitle {
  margin: 0 auto;
}

/* ── New Refresh Button Glass Style ── */
.refresh-btn-glass {
  background: var(--bg-glass);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.refresh-btn-glass:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--accent-purple);
  border-color: var(--accent-purple);
}

.refresh-btn-glass.spinning svg {
  animation: spin-once 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.refresh-btn-glass svg {
  stroke: currentColor;
}

/* ── Transaction Filters ── */
.tx-filters {
  display: flex;
  gap: 8px;
  overflow: visible !important; /* Cage Break: Stop clipping dropdowns */
  padding-bottom: 4px;
}

.tx-filters::-webkit-scrollbar {
  display: none;
}

.filter-btn {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-btn:hover {
  background: var(--bg-glass);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
}

.filter-btn.active {
  background: var(--accent-purple);
  color: white;
  border-color: var(--accent-purple);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

/* ── Rejected Transaction State ── */
.tx-item.rejected {
  opacity: 0.7;
}

.tx-amount.rejected-amt {
  color: var(--accent-red);
  text-decoration: line-through;
  opacity: 0.8;
}

.tx-status.rejected {
  color: var(--accent-red);
  background: rgba(239, 68, 68, 0.1);
  padding: 2px 8px;
  border-radius: 4px;
}

/* ── Improved Filter Visibility ── */
.card-header {
  flex-wrap: wrap;
  gap: 16px;
}

@media (max-width: 600px) {
  .card-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .tx-filters {
    width: 100%;
    margin-top: -8px;
  }
}

.tx-empty {
  padding: 40px 20px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  margin: 10px 0;
}

/* ── Advanced Filter Dropdown ── */
.tx-filters {
  position: relative;
  overflow: visible !important;
}

.btn-filter {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.btn-filter:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-filter.filtering {
  background: rgba(139, 92, 246, 0.2);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 260px;
  padding: 16px;
  z-index: 2000;
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  animation: fadeInDown 0.2s ease-out;
}

.dropdown-content.show {
  display: block !important;
}

.btn-filter svg, 
.btn-filter use {
  pointer-events: none;
}

.filter-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.filter-section label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-options {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-option {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-option:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.filter-option.active {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: white;
  font-weight: 600;
}

.filter-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 12px 0;
}

.icon-inline {
  width: 1.2em;
  height: 1.2em;
  vertical-align: middle;
  flex-shrink: 0;
}

.icon-hero {
  width: 48px;
  height: 48px;
  stroke-width: 1.5;
  opacity: 0.8;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Gasless Badge ── */
.gasless-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(6, 182, 212, 0.12));
  color: var(--accent-green);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(16, 185, 129, 0.25);
  white-space: nowrap;
  animation: gaslessPulse 3s ease-in-out infinite;
}

.gasless-badge .gasless-icon {
  font-size: 11px;
  line-height: 1;
}

@keyframes gaslessPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
  50% { box-shadow: 0 0 8px 2px rgba(16, 185, 129, 0.15); }
}

/* ── Gas Sponsored Fee Row ── */
.fee-row.gas-sponsored {
  color: var(--accent-green);
}

.fee-row.gas-sponsored .label {
  color: var(--accent-green);
  font-weight: 600;
}

.fee-row.gas-sponsored .value {
  color: var(--accent-green);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.fee-row.gas-sponsored .value::after {
  content: '⚡';
  font-size: 12px;
}

/* ── Smart Wallet Indicator ── */
.smart-wallet-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(139, 92, 246, 0.1);
  color: var(--accent-purple);
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(139, 92, 246, 0.2);
  margin-left: 8px;
}

.smart-wallet-badge .sw-icon {
  font-size: 13px;
}

/* ── Action Button Gasless Sub-label ── */
.action-btn-sub .gasless-hint {
  color: var(--accent-green);
  font-weight: 600;
}

/* ── Wallet Type Label in Credit Card ── */
.cc-wallet-type {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 700;
  z-index: 2;
}

.cc-wallet-type.smart {
  color: rgba(16, 185, 129, 0.8);
}

