

:root {
  
  --bg-primary: #0E0F10;
  --bg-secondary: #212427;
  --bg-tertiary: #181A1D;
  --bg-elevated: #2A2D31;
  
  --sidebar-bg: #0C0D0E; 
  --sidebar-width: 260px;
  
  
  --primary: #C3CFE2;
  --primary-light: #D4DEF0;
  --secondary: #B0C6EA;
  --accent: #99BEF9;
  --accent-bright: #A8C9FF;
  
  
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --info: #3B82F6;
  
  
  --gradient-primary: linear-gradient(135deg, #C3CFE2 0%, #99BEF9 100%);
  --gradient-card: linear-gradient(145deg, rgba(153, 190, 249, 0.05) 0%, transparent 50%);
  --gradient-glow: radial-gradient(circle, rgba(153, 190, 249, 0.12) 0%, transparent 70%);

  
  --text-primary: #F5F7FA;
  --text-secondary: #B0B8C4;
  --text-muted: #6B7280;
  --text-dark: #0E0F10;
  
  
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
  --shadow-glow: 0 0 40px rgba(153, 190, 249, 0.15);
  
  
  --border-color: rgba(255, 255, 255, 0.08);
  --border-light: rgba(255, 255, 255, 0.12);
  
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
}


.dash-bg {
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(153, 190, 249, 0.08) 0%, transparent 50%),
    var(--bg-primary);
  pointer-events: none;
  z-index: 0;
}

.dash-grid {
  position: fixed;
  inset: 0;
  background-image: 
    linear-gradient(rgba(153, 190, 249, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(153, 190, 249, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}


h1, h2, h3, h4 {
  font-family: 'Azeret Mono', monospace;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h1 { font-size: 1.75rem; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}


.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition-base);
}

.sidebar-header {
  padding: 24px 20px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.sidebar-logo .logo-icon {
  width: 28px;
  height: 28px;
  color: var(--primary);
}

.sidebar-logo .logo-text {
  font-family: 'Azeret Mono', monospace;
  font-weight: 700;
  font-size: 1rem;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.dash-badge {
  display: inline-block;
  font-family: 'Azeret Mono', monospace;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  padding: 4px 10px;
  background: rgba(153, 190, 249, 0.1);
  border: 1px solid rgba(153, 190, 249, 0.2);
  border-radius: 100px;
}

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.sidebar-link svg {
  flex-shrink: 0;
  opacity: 0.7;
  transition: opacity var(--transition-fast);
}

.sidebar-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.sidebar-link:hover svg {
  opacity: 1;
}

.sidebar-link.active {
  color: var(--accent);
  background: rgba(153, 190, 249, 0.1);
}

.sidebar-link.active svg {
  opacity: 1;
  stroke: var(--accent);
}

.sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid var(--border-color);
}

.sidebar-back {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  margin-bottom: 12px;
}

.sidebar-back:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.network-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  font-family: 'Azeret Mono', monospace;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--success);
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: var(--radius-md);
}

.network-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.15); }
}


.dash-main {
  position: relative;
  z-index: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  padding: 32px;
}

.dash-page {
  animation: pageIn 0.4s ease forwards;
}

@keyframes pageIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}


.page-header {
  margin-bottom: 32px;
}

.page-title {
  margin-bottom: 8px;
}

.page-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
}


.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  position: relative;
  overflow: hidden;
  transition: all var(--transition-fast);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--gradient-card);
  pointer-events: none;
}

.stat-card:hover {
  border-color: var(--border-light);
  transform: translateY(-2px);
}

.stat-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  font-size: 1.25rem;
}


.stat-icon.purple { background: rgba(153, 190, 249, 0.15); color: var(--accent); }
.stat-icon.green { background: rgba(16, 185, 129, 0.15); color: var(--success); }
.stat-icon.yellow { background: rgba(245, 158, 11, 0.15); color: var(--warning); }
.stat-icon.blue { background: rgba(59, 130, 246, 0.15); color: var(--info); }

.stat-value {
  font-family: 'Azeret Mono', monospace;
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.stat-change {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'Azeret Mono', monospace;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 8px;
  padding: 4px 8px;
  border-radius: 100px;
}

.stat-change.up {
  color: var(--success);
  background: rgba(16, 185, 129, 0.1);
}

.stat-change.down {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
}


.dash-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.dash-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
}

.dash-card-title {
  font-family: 'Azeret Mono', monospace;
  font-size: 0.95rem;
  font-weight: 600;
}

.dash-card-body {
  padding: 24px;
}


.dash-table {
  width: 100%;
  border-collapse: collapse;
}

.dash-table th,
.dash-table td {
  padding: 14px 20px;
  text-align: left;
}

.dash-table th {
  font-family: 'Azeret Mono', monospace;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border-color);
}

.dash-table td {
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border-color);
}

.dash-table tr:last-child td {
  border-bottom: none;
}

.dash-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}


.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: 'Azeret Mono', monospace;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 10px 20px;
  border-radius: 100px;
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.btn-sm { padding: 6px 14px; font-size: 0.8rem; }

.btn-primary {
  background: var(--gradient-primary);
  color: var(--text-dark);
  box-shadow: var(--shadow-md), 0 0 20px rgba(153, 190, 249, 0.15);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(153, 190, 249, 0.25);
}

.btn-secondary {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
}

.btn-secondary:hover {
  background: var(--bg-elevated);
  transform: translateY(-2px);
}


.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'Azeret Mono', monospace;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 100px;
}

.badge-success {
  color: var(--success);
  background: rgba(16, 185, 129, 0.12);
}

.badge-warning {
  color: var(--warning);
  background: rgba(245, 158, 11, 0.12);
}

.badge-danger {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.12);
}

.badge-info {
  color: var(--info);
  background: rgba(59, 130, 246, 0.12);
}


.dash-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}


.dash-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  text-align: center;
}

.dash-error-icon {
  font-size: 4rem;
  margin-bottom: 24px;
}

.dash-error h2 {
  margin-bottom: 12px;
}

.dash-error p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}


.dash-mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  padding: 0 16px;
  background: var(--sidebar-bg);
  border-bottom: 1px solid var(--border-color);
  align-items: center;
  justify-content: space-between;
  z-index: 101;
}

.dash-mobile-logo img {
  height: 28px;
}

.dash-mobile-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.dash-mobile-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-fast);
}

.dash-mobile-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.dash-mobile-toggle.active span:nth-child(2) { opacity: 0; }
.dash-mobile-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }


.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  text-align: center;
}

.empty-state-icon {
  font-size: 3rem;
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-state h3 {
  margin-bottom: 8px;
  color: var(--text-primary);
}

.empty-state p {
  color: var(--text-muted);
  max-width: 320px;
}


@media (max-width: 1024px) {
  .dash-grid-2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }
  
  .sidebar.mobile-open {
    transform: translateX(0);
  }
  
  .dash-mobile-header {
    display: flex;
  }
  
  .dash-main {
    margin-left: 0;
    padding: 80px 16px 24px;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
}



.wallet-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.wallet-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.wallet-overlay-bg {
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(ellipse 100% 80% at 50% -30%, rgba(153, 190, 249, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse 80% 60% at 80% 100%, rgba(153, 190, 249, 0.1) 0%, transparent 50%),
    var(--bg-primary);
}

.wallet-overlay-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(153, 190, 249, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(153, 190, 249, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black 20%, transparent 70%);
}

.wallet-overlay-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
  padding: 24px;
  animation: walletFadeIn 0.6s ease forwards;
}

@keyframes walletFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}


.wallet-card {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 
    0 0 0 1px rgba(153, 190, 249, 0.1),
    0 20px 50px -15px rgba(0, 0, 0, 0.5),
    0 0 100px -20px rgba(153, 190, 249, 0.2);
}

.wallet-card-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 300px;
  height: 200px;
  background: radial-gradient(ellipse, rgba(153, 190, 249, 0.25) 0%, transparent 70%);
  pointer-events: none;
  filter: blur(40px);
}

.wallet-card-header {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 32px 24px;
  text-align: center;
  border-bottom: 1px solid var(--border-color);
  background: linear-gradient(180deg, rgba(153, 190, 249, 0.05) 0%, transparent 100%);
}

.wallet-logo {
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  filter: drop-shadow(0 0 20px rgba(153, 190, 249, 0.4));
  color: var(--primary);
}

.wallet-title {
  font-family: 'Azeret Mono', monospace;
  font-size: 1.5rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.wallet-subtitle {
  font-family: 'Azeret Mono', monospace;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 100px;
}

.wallet-card-body {
  padding: 32px;
}

.wallet-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  background: linear-gradient(135deg, rgba(153, 190, 249, 0.15) 0%, rgba(176, 198, 234, 0.1) 100%);
  border: 1px solid rgba(153, 190, 249, 0.2);
  border-radius: 20px;
  color: var(--accent);
  animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.wallet-heading {
  font-size: 1.25rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 12px;
}

.wallet-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
  margin-bottom: 28px;
}


.wallet-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.wallet-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px 18px;
  background: var(--bg-tertiary);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.wallet-btn:hover {
  background: var(--bg-elevated);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.4);
}

.wallet-btn:active {
  transform: translateY(0);
}

.wallet-btn.loading {
  pointer-events: none;
  opacity: 0.7;
}

.wallet-btn.loading .wallet-btn-icon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.wallet-btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  overflow: hidden;
}

.wallet-btn-icon.phantom {
  background: transparent;
}

.wallet-btn-icon img {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.wallet-btn-icon svg {
  width: 24px;
  height: 24px;
}

.wallet-btn-name {
  flex: 1;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  text-align: left;
}

.wallet-btn-tag {
  font-family: 'Azeret Mono', monospace;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  padding: 4px 8px;
  background: rgba(153, 190, 249, 0.15);
  border-radius: 100px;
}


.wallet-card-footer {
  padding: 16px 32px;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid var(--border-color);
  text-align: center;
}

.wallet-card-footer p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.wallet-card-footer a {
  color: var(--accent);
  font-weight: 500;
  transition: color var(--transition-fast);
}

.wallet-card-footer a:hover {
  color: var(--accent-bright);
}


.wallet-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text-muted);
  padding: 10px 20px;
  border-radius: 100px;
  transition: all var(--transition-fast);
}

.wallet-back-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}


.connected-wallet {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  margin-bottom: 12px;
  background: rgba(153, 190, 249, 0.1);
  border: 1px solid rgba(153, 190, 249, 0.2);
  border-radius: var(--radius-md);
}

.connected-wallet-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.connected-wallet-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

.connected-wallet-addr {
  font-family: 'Azeret Mono', monospace;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

.connected-wallet-disconnect {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.connected-wallet-disconnect:hover {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
}


@media (max-width: 480px) {
  .wallet-overlay-content {
    padding: 16px;
  }
  
  .wallet-card {
    border-radius: var(--radius-lg);
  }
  
  .wallet-card-header {
    padding: 32px 24px 20px;
  }
  
  .wallet-card-body {
    padding: 24px;
  }
  
  .wallet-card-footer {
    padding: 14px 24px;
  }
  
  .wallet-logo {
    width: 40px;
    height: 40px;
  }
  
  .wallet-title {
    font-size: 1.25rem;
  }
}
