/* ==========================================================================
   Access Node Web Dashboard CSS System
   Brand Palette: Deep Onyx Black (#050705) & Electric Neon Lime (#B4FE00)
   ========================================================================== */

:root {
  --bg-dark: #050705;
  --bg-card: rgba(12, 16, 12, 0.75);
  --border-color: rgba(180, 254, 0, 0.16);
  --border-glow: rgba(180, 254, 0, 0.4);
  
  --color-emerald: #b4fe00; /* Electric Lime Primary Accent */
  --color-emerald-glow: rgba(180, 254, 0, 0.35);
  --color-cyan: #06b6d4;
  --color-indigo: #8b5cf6;
  --color-amber: #f59e0b;
  --color-danger: #ef4444;

  --text-main: #ffffff;
  --text-muted: #94a3b8;
  --text-dim: #64748b;

  --font-family-base: 'Inter', -apple-system, sans-serif;
  --font-family-heading: 'Outfit', sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
}

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

body {
  font-family: var(--font-family-base);
  background-color: var(--bg-dark);
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Background Ambient Glows */
.app-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.bg-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.2;
  animation: floatGlow 14s infinite alternate ease-in-out;
}

.blob-1 {
  width: 450px;
  height: 450px;
  background: var(--color-emerald);
  top: -100px;
  left: -100px;
}

.blob-2 {
  width: 550px;
  height: 550px;
  background: #059669;
  bottom: -150px;
  right: -100px;
  animation-delay: -5s;
}

.blob-3 {
  width: 350px;
  height: 350px;
  background: #06b6d4;
  top: 40%;
  left: 40%;
  animation-delay: -9s;
}

@keyframes floatGlow {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 30px) scale(1.1); }
}

/* Layout Shell */
.app-container {
  display: flex;
  min-height: 100vh;
}

/* Glassmorphic Container */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.45);
  transition: border-color 0.25s ease;
}

.glass-card:hover {
  border-color: rgba(180, 254, 0, 0.35);
}

/* Sidebar */
.sidebar {
  width: 280px;
  background: rgba(5, 7, 5, 0.95);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  padding: 24px 16px;
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px solid var(--color-emerald);
  box-shadow: 0 0 15px var(--color-emerald-glow);
}

.brand-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-text h2 {
  font-family: var(--font-family-heading);
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.brand-text h2 span {
  color: var(--color-emerald);
}

.badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-emerald {
  background: rgba(180, 254, 0, 0.12);
  color: var(--color-emerald);
  border: 1px solid rgba(180, 254, 0, 0.3);
}

.badge-indigo {
  background: rgba(139, 92, 246, 0.15);
  color: var(--color-indigo);
  border: 1px solid rgba(139, 92, 246, 0.3);
}

.badge-amber {
  background: rgba(245, 158, 11, 0.15);
  color: var(--color-amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

/* Mode Switcher Segmented Control */
.mode-toggle-card {
  margin: 20px 0;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px;
}

.mode-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 6px;
  text-transform: uppercase;
  font-weight: 600;
}

.segmented-control {
  display: flex;
  background: rgba(0, 0, 0, 0.5);
  border-radius: var(--radius-sm);
  padding: 3px;
}

.seg-btn {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.seg-btn.active {
  background: var(--color-emerald);
  color: #000;
  box-shadow: 0 2px 10px var(--color-emerald-glow);
}

/* Navigation List */
.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
}

.nav-item:hover {
  background: rgba(180, 254, 0, 0.05);
  color: var(--text-main);
}

.nav-item.active {
  background: rgba(180, 254, 0, 0.1);
  color: var(--color-emerald);
  border: 1px solid rgba(180, 254, 0, 0.25);
  font-weight: 600;
}

/* Telegram Widget */
.sidebar-footer {
  margin-top: auto;
  padding-top: 16px;
}

.tg-bot-card {
  background: rgba(180, 254, 0, 0.06);
  border: 1px solid rgba(180, 254, 0, 0.2);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.tg-bot-card:hover {
  transform: translateY(-2px);
}

.tg-icon {
  font-size: 1.5rem;
  color: var(--color-emerald);
}

.tg-info { flex: 1; }
.tg-title { font-size: 0.85rem; font-weight: 700; }
.tg-sub { font-size: 0.7rem; color: var(--color-emerald); display: flex; align-items: center; gap: 4px; }

.pulse-dot {
  font-size: 0.4rem;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { opacity: 0.4; }
  50% { opacity: 1; }
  100% { opacity: 0.4; }
}

/* Main Content Area */
.main-content {
  flex: 1;
  padding: 32px 40px;
  overflow-y: auto;
  max-width: 1400px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
}

.topbar-title h1 {
  font-family: var(--font-family-heading);
  font-size: 1.8rem;
  font-weight: 800;
}

.topbar-title p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.network-badge {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.user-profile-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 6px 14px 6px 8px;
  border-radius: 30px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.user-profile-badge:hover {
  border-color: var(--color-emerald);
}

.user-avatar {
  width: 34px;
  height: 34px;
  background: var(--color-emerald);
  color: #000;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}

.user-details { display: flex; flex-direction: column; }
.user-name { font-size: 0.85rem; font-weight: 600; }
.user-id { font-size: 0.7rem; color: var(--text-muted); }

/* Tab Panes */
.tab-pane {
  display: none;
  animation: fadeIn 0.3s ease;
}

.tab-pane.active { display: block; }

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

/* Payout Banner */
.payout-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(135deg, rgba(180, 254, 0, 0.1), rgba(5, 7, 5, 0.8));
  border: 1px solid rgba(180, 254, 0, 0.25);
  margin-bottom: 24px;
}

.payout-info { display: flex; align-items: center; gap: 16px; }

.payout-icon {
  width: 48px;
  height: 48px;
  background: rgba(180, 254, 0, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-emerald);
  font-size: 1.4rem;
}

.payout-info h3 { font-size: 1.1rem; font-weight: 700; }
.payout-info p { font-size: 0.85rem; color: var(--text-muted); }

.timer-box {
  text-align: right;
  background: rgba(0, 0, 0, 0.4);
  padding: 10px 20px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.timer-value {
  font-family: var(--font-family-heading);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--color-emerald);
  display: block;
}

.timer-label { font-size: 0.65rem; color: var(--text-muted); letter-spacing: 0.5px; }

/* Stats Cards Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.stat-card { display: flex; flex-direction: column; }
.stat-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.stat-title { font-size: 0.85rem; color: var(--text-muted); font-weight: 500; }

.stat-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.icon-emerald { background: rgba(180, 254, 0, 0.15); color: var(--color-emerald); }
.icon-cyan { background: rgba(6, 182, 212, 0.15); color: var(--color-cyan); }
.icon-indigo { background: rgba(139, 92, 246, 0.15); color: var(--color-indigo); }
.icon-amber { background: rgba(245, 158, 11, 0.15); color: var(--color-amber); }

.stat-value {
  font-family: var(--font-family-heading);
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.stat-footer { font-size: 0.75rem; color: var(--text-muted); }
.stat-footer.positive { color: var(--color-emerald); }

/* Charts */
.charts-row { display: flex; gap: 20px; flex-wrap: wrap; }
.chart-card { display: flex; flex-direction: column; }
.flex-1 { flex: 1; min-width: 300px; }
.flex-2 { flex: 2; min-width: 450px; }

.card-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.card-header h3 { font-size: 1.1rem; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.chart-wrapper { position: relative; height: 280px; width: 100%; }

/* Wallet Page */
.wallet-box { display: flex; flex-direction: column; gap: 20px; margin-top: 16px; }
.wallet-field label { font-size: 0.85rem; color: var(--text-muted); display: block; margin-bottom: 6px; }
.input-with-copy { display: flex; gap: 10px; }

.input-with-copy input {
  flex: 1;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  color: var(--text-main);
  font-family: monospace;
  font-size: 16px !important;
}

/* Deposit Step Boxes & Selection Grids */
.deposit-step-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
}

.step-label {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  display: block;
  margin-bottom: 14px;
}

.chain-selector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

/* Standardized Option Buttons for Tiers & Chains */
.chain-btn {
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-family: var(--font-family-body);
  font-weight: 600;
  font-size: 0.9rem;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
}

.chain-btn:hover {
  background: rgba(180, 254, 0, 0.06);
  border-color: rgba(180, 254, 0, 0.4);
  transform: translateY(-2px);
}

.chain-btn.active {
  background: rgba(180, 254, 0, 0.12);
  color: var(--color-emerald);
  border: 1px solid var(--color-emerald);
  box-shadow: 0 4px 20px rgba(180, 254, 0, 0.15);
  font-weight: 700;
}

.tier-btn-name {
  font-weight: 700;
  font-size: 0.95rem;
}

.tier-btn-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.chain-btn.active .tier-btn-sub {
  color: rgba(180, 254, 0, 0.8);
}

/* Buttons */
.btn {
  padding: 10px 18px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary { background: var(--color-indigo); color: #fff; }
.btn-emerald { background: var(--color-emerald); color: #000; box-shadow: 0 4px 14px var(--color-emerald-glow); }
.btn-secondary { background: rgba(255, 255, 255, 0.08); color: var(--text-main); border: 1px solid var(--border-color); }
.btn-amber { background: var(--color-amber); color: #000; }
.btn-icon { background: rgba(255, 255, 255, 0.08); color: var(--text-muted); padding: 10px 12px; }

.btn:hover { transform: translateY(-1px); filter: brightness(1.1); }
.btn-block { width: 100%; }

/* Button Loading Animation */
.btn-loading {
  opacity: 0.75;
  pointer-events: none !important;
  cursor: wait !important;
}

.btn-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: btnSpinnerRotate 0.65s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}

@keyframes btnSpinnerRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Tier Plans */
.tier-plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 32px;
}

.tier-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.tier-card.featured {
  border-color: var(--color-emerald);
  background: linear-gradient(180deg, rgba(180, 254, 0, 0.08), rgba(12, 16, 12, 0.85));
}

.featured-tag {
  position: absolute;
  top: -12px;
  background: var(--color-emerald);
  color: #000;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 12px;
}

.tier-badge { font-size: 0.75rem; font-weight: 700; letter-spacing: 1px; margin-bottom: 12px; color: var(--color-emerald); }
.tier-card h2 { font-family: var(--font-family-heading); font-size: 2.2rem; font-weight: 800; }
.tier-card h2 span { font-size: 0.9rem; color: var(--text-muted); font-weight: 400; }
.tier-desc { font-size: 0.85rem; color: var(--text-muted); margin: 8px 0 20px; }

.tier-features {
  list-style: none;
  text-align: left;
  width: 100%;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.85rem;
}

/* Tables */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  font-size: 0.85rem;
}

.data-table th, .data-table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.data-table th { color: var(--text-muted); font-weight: 600; background: rgba(0, 0, 0, 0.3); }
.table-responsive { overflow-x: auto; }

.text-emerald { color: var(--color-emerald); }
.text-cyan { color: var(--color-cyan); }
.text-amber { color: var(--color-amber); }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 24px; }
.hidden { display: none !important; }

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; width: 100vw; height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-card {
  width: 90%;
  max-width: 480px;
  background: rgba(12, 16, 12, 0.95);
  border: 1px solid var(--border-glow);
}

.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.btn-close { background: transparent; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; }

.form-group { margin-bottom: 16px; }
.form-group label { font-size: 0.85rem; color: var(--text-muted); display: block; margin-bottom: 6px; }

/* Prevent iOS Safari & iOS Chrome Auto-Zoom on focus */
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="search"],
input[type="tel"],
input[type="url"],
select,
textarea,
.form-control,
.form-group input,
.input-with-copy input {
  font-size: 16px !important;
}

.form-group input, .form-control {
  width: 100%;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  color: var(--text-main);
  font-size: 16px !important;
}

.qrcode-wrapper {
  background: #fff;
  padding: 16px;
  border-radius: var(--radius-md);
  display: inline-block;
  margin: 16px 0;
}

/* Toast Notification System */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  min-width: 320px;
  max-width: 440px;
  background: rgba(12, 16, 12, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  animation: slideInRight 0.35s cubic-bezier(0.16, 1, 0.3, 1), fadeOut 0.4s ease 3.2s forwards;
}

.toast-icon {
  font-size: 1.25rem;
  color: var(--color-emerald);
}

.toast-error {
  border-color: rgba(239, 68, 68, 0.5);
}

.toast-error .toast-icon {
  color: var(--color-danger);
}

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

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

/* Admin Login View Centering (Global Desktop & Mobile) */
.admin-login-wrapper {
  min-height: 100vh;
  width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  z-index: 10;
  box-sizing: border-box;
}

.admin-login-card {
  width: 100%;
  max-width: 440px;
  padding: 36px 32px;
  margin: 0 auto;
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 30px rgba(180, 254, 0, 0.15);
  box-sizing: border-box;
}

/* ==========================================================================
   MOBILE & TABLET RESPONSIVENESS (320px - 992px)
   ========================================================================== */

/* Mobile Top Bar Navigation */
.mobile-topbar {
  display: none;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: rgba(5, 7, 5, 0.95);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  height: 48px;
  box-sizing: border-box;
}

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

.mobile-brand img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--color-emerald);
}

.mobile-brand span {
  font-family: var(--font-family-heading);
  font-weight: 800;
  font-size: 0.92rem;
  color: #fff;
  letter-spacing: 0.5px;
}

.mobile-brand span span {
  color: var(--color-emerald);
}

.mobile-menu-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--color-emerald);
  font-size: 0.95rem;
  padding: 5px 10px;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  z-index: 1001;
}

.sidebar-overlay.active {
  display: block;
}

@media (max-width: 992px) {
  html {
    font-size: 13.5px;
  }

  h1 { font-size: 1.45rem !important; }
  h2 { font-size: 1.2rem !important; }
  h3 { font-size: 1.05rem !important; }
  h4 { font-size: 0.88rem !important; }

  .page-header h2 {
    font-size: 1.18rem !important;
  }

  .page-header p {
    font-size: 0.78rem !important;
  }

  .stat-value {
    font-size: 1.28rem !important;
  }

  .stat-label {
    font-size: 0.72rem !important;
  }

  .btn {
    padding: 8px 12px;
    font-size: 0.78rem;
  }

  .form-control, input, select, textarea {
    padding: 10px 12px;
    font-size: 16px !important; /* Prevents iOS Safari & Chrome from auto-zooming on focus */
  }

  .data-table th, .data-table td {
    padding: 8px 10px;
    font-size: 0.75rem;
  }

  .app-container {
    grid-template-columns: 1fr;
  }

  .mobile-topbar {
    display: flex;
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 250px;
    z-index: 1002;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.85);
  }

  .nav-item {
    padding: 10px 14px;
    font-size: 0.82rem;
  }

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

  .main-content {
    padding: 12px 10px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding-bottom: 12px;
  }

  .topbar-actions {
    width: 100%;
    justify-content: space-between;
  }

  .payout-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
  }

  .timer-box {
    width: 100%;
    text-align: left;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .charts-row {
    flex-direction: column;
  }

  .flex-1, .flex-2 {
    min-width: 100%;
  }

  .chain-selector-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    flex-direction: column;
  }

  .input-with-copy {
    flex-direction: column;
  }

  .input-with-copy button {
    width: 100%;
  }

  .toast-container {
    right: 12px;
    left: 12px;
    top: 12px;
  }

  .toast {
    min-width: 100%;
    max-width: 100%;
    font-size: 0.8rem;
    padding: 10px 14px;
  }

  .admin-login-wrapper {
    padding: 12px;
  }

  .admin-login-card {
    padding: 22px 14px;
  }

  /* iOS Mobile Keyboard & Modal Alignment Fix */
  .modal-overlay {
    align-items: flex-start !important;
    justify-content: center !important;
    padding: 75px 12px 24px !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    box-sizing: border-box;
  }

  .modal-card {
    width: 100% !important;
    max-width: 440px !important;
    margin: 0 auto !important;
    max-height: calc(100vh - 85px) !important;
    overflow-y: auto !important;
    border-radius: var(--radius-lg);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.95);
  }
}

@media (max-width: 576px) {
  html {
    font-size: 13px;
  }

  .main-content {
    padding: 10px 8px;
  }

  .glass-card {
    padding: 14px 12px;
  }
}
