/* =========================================================
   WA PRO — Dark Hacker / Cyberpunk Theme
   Black + Neon Green (#00FF66) · Glassmorphism · Glow
   ========================================================= */

:root {
  --bg-primary: #000000;
  --bg-secondary: #050505;
  --bg-tertiary: #0b0b0b;
  --bg-elevated: #111111;
  --neon: #00ff66;
  --neon-mid: #00cc55;
  --neon-dark: #00aa44;
  --neon-dim: rgba(0, 255, 102, 0.12);
  --neon-glow: rgba(0, 255, 102, 0.35);
  --neon-glow-strong: rgba(0, 255, 102, 0.55);
  --glass-bg: rgba(11, 11, 11, 0.75);
  --glass-border: rgba(0, 255, 102, 0.15);
  --glass-border-hover: rgba(0, 255, 102, 0.35);
  --text: #f5f5f5;
  --text-secondary: #a3a3a3;
  --text-muted: #737373;
  --danger: #ff3366;
  --warning: #ffaa00;
  --success: #00ff66;
  --radius: 18px;
  --radius-sm: 12px;
  --sidebar-w: 260px;
  --header-h: 72px;
  --font-en: "Inter", system-ui, sans-serif;
  --font-ar: "Cairo", "Inter", system-ui, sans-serif;
  --shadow-glow: 0 0 20px rgba(0, 255, 102, 0.25);
  --shadow-glow-lg: 0 0 40px rgba(0, 255, 102, 0.35);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg-primary);
  color: var(--text);
  font-family: var(--font-en);
  min-height: 100vh;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

html[dir="rtl"] body { font-family: var(--font-ar); }

a { color: var(--neon); text-decoration: none; transition: color .2s, opacity .2s; }
a:hover { color: var(--neon-mid); }

img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }

/* Scrollbar */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--neon-dark); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--neon); }

::selection { background: var(--neon); color: #000; }

/* Matrix canvas */
#matrix-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.18;
}

/* =========================================================
   Utilities
   ========================================================= */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }
.w-full { width: 100%; }
.text-neon { color: var(--neon) !important; }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-gradient {
  background: linear-gradient(135deg, #fff 0%, var(--neon) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.flex { display: flex; align-items: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.gap { gap: 1rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
.mb-4 { margin-bottom: 1.5rem; }

@media (max-width: 768px) {
  .grid-2 { grid-template-columns: 1fr; }
}

/* =========================================================
   Glass / Glow
   ========================================================= */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
}

.glass-hover { transition: border-color .25s, box-shadow .25s, transform .25s; }
.glass-hover:hover {
  border-color: var(--glass-border-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
}

.glow-border {
  border: 1px solid var(--neon);
  box-shadow: 0 0 0 1px rgba(0, 255, 102, 0.1), var(--shadow-glow);
}

.glow-pulse { animation: glowPulse 2.4s ease-in-out infinite; }
@keyframes glowPulse {
  0%, 100% { box-shadow: 0 0 12px rgba(0, 255, 102, 0.2); }
  50% { box-shadow: 0 0 28px rgba(0, 255, 102, 0.45); }
}

.float { animation: floatY 4s ease-in-out infinite; }
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* =========================================================
   Buttons
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.35rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all .2s ease;
  white-space: nowrap;
  text-decoration: none;
  line-height: 1.2;
}
.btn i, .btn svg { width: 18px; height: 18px; flex-shrink: 0; }

.btn-neon {
  background: var(--neon);
  color: #000 !important;
  border-color: var(--neon);
  box-shadow: 0 0 18px rgba(0, 255, 102, 0.35);
}
.btn-neon:hover {
  background: var(--neon-mid);
  box-shadow: var(--shadow-glow-lg);
  transform: translateY(-1px);
  color: #000 !important;
}

.btn-outline {
  background: transparent;
  color: var(--neon) !important;
  border-color: var(--neon);
}
.btn-outline:hover {
  background: var(--neon-dim);
  box-shadow: var(--shadow-glow);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary) !important;
  border-color: rgba(255, 255, 255, 0.08);
}
.btn-ghost:hover {
  color: var(--neon) !important;
  border-color: var(--glass-border);
  background: var(--neon-dim);
}

.btn-danger {
  background: rgba(255, 51, 102, 0.15);
  color: var(--danger) !important;
  border-color: rgba(255, 51, 102, 0.4);
}
.btn-danger:hover { background: rgba(255, 51, 102, 0.28); }

.btn-sm { padding: 0.45rem 0.9rem; font-size: 0.85rem; border-radius: 10px; }
.btn-lg { padding: 0.95rem 1.85rem; font-size: 1.05rem; }
.btn-icon {
  width: 40px; height: 40px; padding: 0;
  border-radius: 12px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
}
.btn-icon:hover { background: rgba(0, 255, 102, 0.22); box-shadow: var(--shadow-glow); }

/* =========================================================
   Forms
   ========================================================= */
.form-group { margin-bottom: 1.15rem; }
.form-label {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  font-weight: 500;
}
.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text);
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--neon);
  box-shadow: 0 0 0 3px rgba(0, 255, 102, 0.15), var(--shadow-glow);
}
.form-input::placeholder,
.form-textarea::placeholder { color: var(--text-muted); }
.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2300FF66' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  padding-right: 2.5rem;
}
html[dir="rtl"] .form-select {
  background-position: left 0.9rem center;
  padding-right: 1rem;
  padding-left: 2.5rem;
}
.form-textarea { min-height: 110px; resize: vertical; }
.form-check {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  cursor: pointer;
}
.form-check input { accent-color: var(--neon); width: 16px; height: 16px; }

/* =========================================================
   Badges / Alerts / Empty
   ========================================================= */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid transparent;
}
.badge-success, .badge-connected {
  background: rgba(0, 255, 102, 0.12);
  color: var(--neon);
  border-color: rgba(0, 255, 102, 0.3);
}
.badge-danger, .badge-disconnected {
  background: rgba(255, 51, 102, 0.12);
  color: var(--danger);
  border-color: rgba(255, 51, 102, 0.3);
}
.badge-warning {
  background: rgba(255, 170, 0, 0.12);
  color: var(--warning);
  border-color: rgba(255, 170, 0, 0.3);
}
.badge-muted {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  border-color: rgba(255, 255, 255, 0.1);
}

.alert {
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  border: 1px solid transparent;
  font-size: 0.925rem;
}
.alert-success {
  background: rgba(0, 255, 102, 0.1);
  border-color: rgba(0, 255, 102, 0.3);
  color: var(--neon);
}
.alert-error {
  background: rgba(255, 51, 102, 0.1);
  border-color: rgba(255, 51, 102, 0.35);
  color: #ff6b8a;
}
.alert-info {
  background: rgba(0, 255, 102, 0.06);
  border-color: var(--glass-border);
  color: var(--text-secondary);
}

.flash {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1rem;
  border: 1px solid transparent;
  font-size: 0.925rem;
}
.flash i, .flash svg { width: 18px; height: 18px; flex-shrink: 0; }
.flash-success {
  background: rgba(0, 255, 102, 0.1);
  border-color: rgba(0, 255, 102, 0.3);
  color: var(--neon);
}
.flash-error {
  background: rgba(255, 51, 102, 0.1);
  border-color: rgba(255, 51, 102, 0.35);
  color: #ff6b8a;
}
.flash-info {
  background: rgba(0, 255, 102, 0.06);
  border-color: var(--glass-border);
  color: var(--text-secondary);
}

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  color: var(--text-muted);
}
.empty-state i, .empty-state svg {
  width: 48px; height: 48px;
  color: var(--neon);
  margin: 0 auto 1rem;
  opacity: 0.7;
}
.empty-state h3 { color: var(--text); margin-bottom: 0.5rem; }

/* =========================================================
   Tables
   ========================================================= */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--glass-border);
  background: var(--glass-bg);
}
.table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}
.table th, .table td {
  padding: 0.95rem 1.1rem;
  text-align: start;
  border-bottom: 1px solid rgba(0, 255, 102, 0.08);
}
.table th {
  color: var(--neon);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(0, 255, 102, 0.04);
  font-weight: 700;
}
.table tr:last-child td { border-bottom: none; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover { background: rgba(0, 255, 102, 0.04); }
.table .actions { display: flex; gap: 0.4rem; flex-wrap: wrap; }

.status-dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  margin-inline-end: 0.4rem;
}
.status-dot.on { background: var(--neon); box-shadow: 0 0 8px var(--neon); }
.status-dot.off { background: var(--danger); box-shadow: 0 0 8px var(--danger); }

/* =========================================================
   Logo
   ========================================================= */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--text) !important;
  letter-spacing: 0.02em;
}
.logo-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  box-shadow: var(--shadow-glow);
}
.logo-icon i, .logo-icon svg { width: 18px; height: 18px; }

/* =========================================================
   Language switch
   ========================================================= */
.lang-switch {
  display: inline-flex;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.4);
}
.lang-switch a,
.lang-switch button {
  border: none;
  background: transparent;
  color: var(--text-muted);
  padding: 0.35rem 0.75rem;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
}
.lang-switch a.active,
.lang-switch button.active {
  background: var(--neon);
  color: #000;
}

/* =========================================================
   Public layout / Landing
   ========================================================= */
.page-wrap { position: relative; z-index: 1; min-height: 100vh; }

.public-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(18px);
  background: rgba(0, 0, 0, 0.7);
  border-bottom: 1px solid var(--glass-border);
}
.public-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 70px;
}
.nav-links {
  display: flex;
  list-style: none;
  gap: 1.5rem;
}
.nav-links a {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
}
.nav-links a:hover { color: var(--neon); }
.nav-actions { display: flex; align-items: center; gap: 0.75rem; }

.hero {
  position: relative;
  padding: 5.5rem 0 4rem;
  text-align: center;
  overflow: hidden;
}
.hero-content { position: relative; z-index: 2; max-width: 820px; margin: 0 auto; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--glass-border);
  background: var(--neon-dim);
  color: var(--neon);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}
.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 1.1rem;
}
.hero-desc {
  color: var(--text-secondary);
  font-size: 1.1rem;
  margin-bottom: 2rem;
  max-width: 620px;
  margin-inline: auto;
}
.hero-actions {
  display: flex;
  justify-content: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.hero-visual { max-width: 900px; margin: 0 auto; padding: 0 1rem; }
.preview-frame {
  padding: 1rem;
  text-align: start;
}
.preview-bar {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.preview-dot { width: 10px; height: 10px; border-radius: 50%; }
.preview-dot.red { background: #ff5f56; }
.preview-dot.yellow { background: #ffbd2e; }
.preview-dot.green { background: var(--neon); box-shadow: 0 0 8px var(--neon); }
.preview-body { padding: 0.5rem; }

.section { padding: 4.5rem 0; position: relative; z-index: 1; }
.section-header { text-align: center; margin-bottom: 2.5rem; }
.section-header h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 0.5rem;
}
.section-header p { color: var(--text-secondary); }

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}
.feature-card {
  padding: 1.5rem;
  height: 100%;
}
.feature-icon {
  width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 14px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  margin-bottom: 1rem;
  box-shadow: var(--shadow-glow);
}
.feature-icon i, .feature-icon svg { width: 22px; height: 22px; }
.feature-card h3 { margin-bottom: 0.5rem; font-size: 1.1rem; }
.feature-card p { color: var(--text-secondary); font-size: 0.925rem; }

.partners-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  opacity: 0.7;
}
.partner-chip {
  padding: 0.75rem 1.4rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-weight: 600;
}

.site-footer {
  border-top: 1px solid var(--glass-border);
  padding: 2.5rem 0 1.5rem;
  margin-top: 2rem;
  background: var(--bg-secondary);
  position: relative;
  z-index: 1;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.footer-col h4 { color: var(--neon); margin-bottom: 0.85rem; font-size: 0.95rem; }
.footer-col a, .footer-col p {
  display: block;
  color: var(--text-secondary);
  margin-bottom: 0.45rem;
  font-size: 0.9rem;
}
.footer-col a:hover { color: var(--neon); }
.footer-bottom {
  border-top: 1px solid rgba(0, 255, 102, 0.08);
  padding-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.footer-col ul { list-style: none; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* =========================================================
   Auth pages
   ========================================================= */
.auth-page-wrap { position: relative; min-height: 100vh; }
.auth-silhouette {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
  z-index: 0;
  opacity: 0.12;
}
.auth-silhouette svg { height: 70vh; max-width: 320px; filter: drop-shadow(0 0 30px rgba(0, 255, 102, 0.5)); }
.auth-page {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}
.auth-card {
  width: 100%;
  max-width: 440px;
  padding: 2rem;
}
.auth-header { text-align: center; margin-bottom: 1.75rem; }
.auth-header .logo { justify-content: center; margin-bottom: 1.25rem; }
.auth-header h2 { font-size: 1.6rem; margin-bottom: 0.4rem; }
.auth-header p { color: var(--text-secondary); font-size: 0.925rem; }
.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}
.auth-footer a { font-weight: 600; }

/* =========================================================
   Pricing
   ========================================================= */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1.25rem;
  margin-bottom: 3rem;
}
.pricing-card {
  padding: 1.75rem;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.pricing-card.featured {
  border-color: var(--neon);
  box-shadow: var(--shadow-glow-lg);
  transform: scale(1.02);
}
.pricing-badge {
  position: absolute;
  top: -12px;
  inset-inline-start: 50%;
  transform: translateX(-50%);
  background: var(--neon);
  color: #000;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.85rem;
  border-radius: 999px;
}
html[dir="rtl"] .pricing-badge { transform: translateX(50%); }
.pricing-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--neon);
  margin-bottom: 0.75rem;
}
.pricing-price {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.25rem;
}
.pricing-period { color: var(--text-muted); font-size: 0.85rem; margin-bottom: 1.25rem; }
.pricing-features {
  list-style: none;
  flex: 1;
  margin-bottom: 1.5rem;
}
.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.65rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}
.pricing-features li i,
.pricing-features li svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
.pricing-features .ok { color: var(--neon); }
.pricing-features .no { color: var(--danger); opacity: 0.8; }

.currency-toggle {
  display: inline-flex;
  margin: 0 auto 2rem;
  border: 1px solid var(--glass-border);
  border-radius: 999px;
  overflow: hidden;
}
.currency-toggle button {
  border: none;
  background: transparent;
  color: var(--text-muted);
  padding: 0.5rem 1.1rem;
  cursor: pointer;
  font-weight: 600;
}
.currency-toggle button.active {
  background: var(--neon);
  color: #000;
}

.compare-table .check { color: var(--neon); }
.compare-table .cross { color: var(--danger); }

/* =========================================================
   Dashboard layout
   ========================================================= */
.dashboard-layout {
  display: flex;
  min-height: 100vh;
  background:
    radial-gradient(ellipse at top left, rgba(0, 255, 102, 0.06), transparent 45%),
    radial-gradient(ellipse at bottom right, rgba(0, 255, 102, 0.04), transparent 40%),
    var(--bg-primary);
}

.sidebar {
  width: var(--sidebar-w);
  background: rgba(5, 5, 5, 0.95);
  border-inline-end: 1px solid var(--glass-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset-block: 0;
  inset-inline-start: 0;
  z-index: 40;
  transition: transform .3s ease;
}
.sidebar-header {
  padding: 1.25rem 1.15rem;
  border-bottom: 1px solid var(--glass-border);
}
.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 0.75rem;
}
.sidebar-section {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 0.85rem 0.85rem 0.45rem;
  font-weight: 700;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.7rem 0.85rem;
  border-radius: 12px;
  color: var(--text-secondary) !important;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.2rem;
  border: 1px solid transparent;
  transition: all .2s;
}
.sidebar-link i, .sidebar-link svg { width: 18px; height: 18px; color: var(--neon); opacity: 0.7; }
.sidebar-link:hover {
  background: var(--neon-dim);
  color: var(--text) !important;
  border-color: var(--glass-border);
}
.sidebar-link.active {
  background: rgba(0, 255, 102, 0.12);
  color: var(--neon) !important;
  border-color: rgba(0, 255, 102, 0.25);
  box-shadow: inset 0 0 20px rgba(0, 255, 102, 0.05);
}
.sidebar-link.active i, .sidebar-link.active svg,
.sidebar-link:hover i, .sidebar-link:hover svg { opacity: 1; }

.sidebar-footer {
  padding: 1rem;
  border-top: 1px solid var(--glass-border);
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.sidebar-avatar {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--neon);
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  box-shadow: var(--shadow-glow);
}
.sidebar-user-name { font-weight: 600; font-size: 0.9rem; }
.sidebar-user-plan { font-size: 0.75rem; color: var(--neon); }

.dashboard-main {
  flex: 1;
  margin-inline-start: var(--sidebar-w);
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.dashboard-header-bar {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 30;
}
.dashboard-header-bar h2 {
  font-size: 1.05rem;
  font-weight: 600;
}
.header-actions { display: flex; align-items: center; gap: 0.65rem; }
.notif-btn {
  position: relative;
  width: 40px; height: 40px;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  background: var(--neon-dim);
  color: var(--neon);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.notif-btn .dot {
  position: absolute;
  top: 8px; right: 8px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--danger);
  box-shadow: 0 0 8px var(--danger);
}

.dashboard-content {
  padding: 1.5rem;
  flex: 1;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.page-header h1 {
  font-size: 1.55rem;
  font-weight: 800;
  margin-bottom: 0.25rem;
}
.page-header p { color: var(--text-secondary); font-size: 0.95rem; }
.page-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; }

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.stat-card {
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: "";
  position: absolute;
  inset-inline-end: -20px;
  top: -20px;
  width: 80px; height: 80px;
  background: radial-gradient(circle, rgba(0, 255, 102, 0.15), transparent 70%);
  pointer-events: none;
}
.stat-icon {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  margin-bottom: 0.85rem;
  box-shadow: var(--shadow-glow);
}
.stat-icon i, .stat-icon svg { width: 20px; height: 20px; }
.stat-value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--neon);
  text-shadow: 0 0 20px rgba(0, 255, 102, 0.35);
  line-height: 1.1;
  margin-bottom: 0.25rem;
}
.stat-label { color: var(--text-secondary); font-size: 0.85rem; }
.stat-change {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  margin-top: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
}
.stat-change.up { color: var(--neon); }
.stat-change.down { color: var(--danger); }
.stat-change i, .stat-change svg { width: 14px; height: 14px; }

.chart-card, .panel-card {
  padding: 1.35rem;
  margin-bottom: 1.25rem;
}
.chart-card h3, .panel-card h3 {
  font-size: 1rem;
  margin-bottom: 1rem;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.chart-container {
  position: relative;
  height: 260px;
  width: 100%;
}
.chart-container canvas { max-height: 100%; }

/* Cards alias */
.card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

/* QR / Accounts */
.qr-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 2rem;
  min-height: 280px;
  text-align: center;
}
.qr-box img {
  width: 220px;
  height: 220px;
  border-radius: 12px;
  border: 2px solid var(--neon);
  box-shadow: var(--shadow-glow);
  background: #fff;
  padding: 8px;
}
.phone-preview {
  width: 280px;
  max-width: 100%;
  margin: 0 auto;
  border: 2px solid var(--glass-border);
  border-radius: 28px;
  padding: 0.75rem;
  background: #0a0a0a;
  box-shadow: var(--shadow-glow);
}
.phone-preview-screen {
  background: #0e1610;
  border-radius: 20px;
  min-height: 360px;
  padding: 1rem;
}
.wa-bubble {
  background: #005c4b;
  color: #fff;
  padding: 0.65rem 0.85rem;
  border-radius: 10px;
  max-width: 85%;
  margin-inline-start: auto;
  font-size: 0.9rem;
  white-space: pre-wrap;
  word-break: break-word;
}

/* Marketplace */
.marketplace-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.15rem;
}
.country-card {
  padding: 1.35rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.country-flag { font-size: 2.5rem; line-height: 1; margin-bottom: 0.25rem; }
.country-name { font-weight: 700; font-size: 1.1rem; }
.country-meta {
  color: var(--text-secondary);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}
.country-price {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--neon);
  text-shadow: 0 0 16px rgba(0, 255, 102, 0.35);
  margin: 0.35rem 0 0.75rem;
}

/* Templates grid */
.templates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}
.template-card {
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.template-thumb {
  height: 120px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(0, 255, 102, 0.15), rgba(0, 0, 0, 0.6));
  border: 1px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--neon);
}
.template-thumb i, .template-thumb svg { width: 32px; height: 32px; }

/* Payment methods */
.pay-methods {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.pay-method {
  padding: 1rem;
  text-align: center;
  cursor: pointer;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.4);
  transition: all .2s;
}
.pay-method:hover, .pay-method.active {
  border-color: var(--neon);
  box-shadow: var(--shadow-glow);
  background: var(--neon-dim);
}
.pay-details {
  padding: 1.25rem;
  border: 1px dashed var(--neon);
  border-radius: var(--radius-sm);
  background: rgba(0, 255, 102, 0.05);
  margin-bottom: 1.25rem;
  text-align: center;
}
.pay-details .big-number {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--neon);
  letter-spacing: 0.04em;
  margin: 0.5rem 0;
  text-shadow: 0 0 16px rgba(0, 255, 102, 0.4);
}

/* Search bar */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  align-items: center;
}
.search-input {
  flex: 1;
  min-width: 200px;
  max-width: 360px;
}

/* Tags */
.tag {
  display: inline-flex;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  font-size: 0.75rem;
  font-weight: 600;
}

/* Sidebar overlay mobile */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 35;
}
.sidebar-overlay.show { display: block; }
#sidebar-toggle {
  display: none;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  width: 40px; height: 40px;
  border-radius: 12px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

@media (max-width: 1024px) {
  .sidebar { transform: translateX(-105%); }
  html[dir="rtl"] .sidebar { transform: translateX(105%); }
  .sidebar.open { transform: translateX(0); }
  .dashboard-main { margin-inline-start: 0; }
  #sidebar-toggle { display: inline-flex; }
}

/* Toast */
.toast-container {
  position: fixed;
  bottom: 1.25rem;
  inset-inline-end: 1.25rem;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.toast {
  padding: 0.85rem 1.1rem;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-glow);
  min-width: 240px;
  animation: slideIn .25s ease;
}
@keyframes slideIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hidden utility */
.hidden { display: none !important; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mb-2 { margin-bottom: 1rem; }
.text-end { text-align: end; }

/* File upload */
.file-upload {
  border: 1px dashed var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  position: relative;
}
.file-upload:hover { border-color: var(--neon); background: var(--neon-dim); }
.file-upload input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.file-preview img {
  max-width: 180px;
  margin-top: 0.75rem;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
}

/* QR section */
.qr-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}
.qr-placeholder {
  width: 220px;
  height: 220px;
  margin: 1rem auto;
  border: 2px dashed var(--glass-border);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--neon);
  background: rgba(0,0,0,.4);
}
.qr-placeholder img { width: 100%; height: 100%; object-fit: contain; border-radius: 12px; }
.empty-icon {
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 18px;
  background: var(--neon-dim);
  border: 1px solid var(--glass-border);
  color: var(--neon);
  margin: 0 auto 1rem;
}
.empty-icon i, .empty-icon svg { width: 28px; height: 28px; }
.table-actions { display: flex; gap: 0.4rem; flex-wrap: wrap; }

@media (max-width: 768px) {
  .qr-section { grid-template-columns: 1fr; }
}
.dash-main { flex: 1; padding: 1.5rem; }
.site-header { background: var(--bg-secondary); padding: 1rem 0; border-bottom: 1px solid var(--glass-border); }
.btn-primary { background: var(--neon); color: #000; border-color: var(--neon); }
.price { font-size: 1.5rem; color: var(--neon); margin: 0.5rem 0; }
.empty { color: var(--text-muted); padding: 2rem; text-align: center; }
.auth-form { max-width: 400px; margin: 2rem auto; }
.auth-form label { display: block; margin-bottom: 1rem; }
.auth-form input, .auth-form select, .auth-form textarea {
  width: 100%; padding: 0.8rem 1rem; margin-top: 0.25rem;
  border-radius: var(--radius-sm); border: 1px solid var(--glass-border);
  background: rgba(0,0,0,.55); color: var(--text);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}
@media (max-width: 560px) {
  .form-row { grid-template-columns: 1fr; }
}
.phone-field {
  display: grid;
  grid-template-columns: minmax(150px, 42%) 1fr;
  gap: 0.6rem;
  align-items: start;
}
.phone-field .phone-local { min-width: 0; }
@media (max-width: 480px) {
  .phone-field { grid-template-columns: 1fr; }
}

/* -- Dial picker (neon custom dropdown) -- */
.dial-picker {
  position: relative;
  z-index: 20;
}
.dial-picker-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.72rem 0.8rem;
  background: rgba(0, 0, 0, 0.7);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text);
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s, background .2s;
  text-align: start;
  min-height: 48px;
}
.dial-picker-btn:hover,
.dial-picker.open .dial-picker-btn {
  border-color: var(--neon);
  box-shadow: 0 0 0 3px rgba(0, 255, 102, 0.12), var(--shadow-glow);
  background: rgba(0, 255, 102, 0.05);
}
.dial-picker-flag {
  font-size: 1.35rem;
  line-height: 1;
  flex-shrink: 0;
}
.dial-picker-meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
  flex: 1;
}
.dial-picker-code {
  font-weight: 700;
  color: var(--neon);
  font-size: 0.92rem;
  letter-spacing: 0.02em;
}
.dial-picker-name {
  font-size: 0.72rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dial-picker-chevron {
  color: var(--neon);
  display: inline-flex;
  transition: transform .2s;
}
.dial-picker-chevron i,
.dial-picker-chevron svg {
  width: 16px;
  height: 16px;
}
.dial-picker.open .dial-picker-chevron {
  transform: rotate(180deg);
}

.dial-picker-menu {
  position: absolute;
  inset-inline: 0;
  top: calc(100% + 6px);
  background: #0b0b0b;
  border: 1px solid rgba(0, 255, 102, 0.35);
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.65), 0 0 24px rgba(0, 255, 102, 0.15);
  overflow: hidden;
  min-width: 260px;
  z-index: 50;
}
.dial-picker-menu[hidden] { display: none !important; }

.dial-picker-search-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid rgba(0, 255, 102, 0.12);
  color: var(--neon);
}
.dial-picker-search-wrap i,
.dial-picker-search-wrap svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.dial-picker-search {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: var(--text);
  font-size: 0.9rem;
}
.dial-picker-search::placeholder { color: var(--text-muted); }

.dial-picker-list {
  list-style: none;
  margin: 0;
  padding: 0.35rem;
  max-height: 240px;
  overflow-y: auto;
}
.dial-picker-option {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-align: start;
  transition: background .15s, border-color .15s;
}
.dial-picker-option:hover {
  background: rgba(0, 255, 102, 0.08);
  border-color: rgba(0, 255, 102, 0.18);
}
.dial-picker-option.active {
  background: rgba(0, 255, 102, 0.14);
  border-color: rgba(0, 255, 102, 0.35);
  box-shadow: inset 0 0 16px rgba(0, 255, 102, 0.08);
}
.dial-picker-option-text {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  flex: 1;
  min-width: 0;
}
.dial-picker-option-text strong {
  font-size: 0.9rem;
  font-weight: 600;
}
.dial-picker-option-text span {
  font-size: 0.75rem;
  color: var(--text-muted);
}
.dial-picker-check {
  width: 16px;
  height: 16px;
  color: var(--neon);
  flex-shrink: 0;
  opacity: 0;
  transition: opacity .15s;
}
.dial-picker-option.active .dial-picker-check {
  opacity: 1;
}
.dial-picker-option.hidden-opt { display: none; }

/* -- Login mode: username OR phone -- */
.login-mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  padding: 0.35rem;
  margin-bottom: 1.1rem;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(0, 255, 102, 0.2);
  border-radius: 12px;
}
.login-mode-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background .15s, color .15s, border-color .15s, box-shadow .15s;
}
.login-mode-btn i,
.login-mode-btn svg {
  width: 16px;
  height: 16px;
}
.login-mode-btn:hover {
  color: var(--text);
  background: rgba(0, 255, 102, 0.06);
}
.login-mode-btn.active {
  color: #04140a;
  background: var(--neon);
  border-color: var(--neon);
  box-shadow: 0 0 18px rgba(0, 255, 102, 0.35);
}
.login-panel { display: none; }
.login-panel.is-active { display: block; }
