/* ==========================================================================
   SMM Panel — Global Dark Purple Theme Layer (v2.0 — 1xPanel style)
   Loaded AFTER the legacy stylesheets (style.min.css / smmscripts.css /
   admin.css). Unifies every guest page, auth page and the admin area with
   the homepage identity while preserving all script features.
   Strategy: remap legacy CSS variables, then targeted surface overrides.
   Palette: bg #1a1a1d / #202024 / #131313 · accent #28cb69 + #0fac4e
   ========================================================================== */

:root {
  /* ---- style.min.css (Obsidian) system ---- */
  --bg-base: #1a1a1d;
  --bg-surface: #202024;
  --bg-surface-elevated: #1c2434;
  --bg-input: #131313;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(40, 203, 105, 0.45);
  --primary: #28cb69;
  --primary-hover: #0fac4e;
  --primary-glow: rgba(40, 203, 105, 0.38);
  --primary-text: #ffffff;
  --text-primary: #ffffff;
  --text-secondary: #c3c9d6;
  --text-muted: #8b93a7;
  --text-dim: #6f7789;
  --shadow-card: 0 20px 50px rgba(0, 0, 0, 0.45);

  /* ---- smmscripts.css system ---- */
  --primary-rgb: 40, 203, 105;
  --bg-dark: #131313;
  --bg-card-dark: #202024;
  --bg-input-dark: #131313;
  --border-dark: rgba(255, 255, 255, 0.08);
  --text-dark: #ffffff;
  --text-light: #ffffff;
  --text-gray: #8b93a7;
  --bg-light: #1a1a1d;
  --bg-card-light: #202024;
  --bg-input-light: #131313;
  --border-light: rgba(255, 255, 255, 0.08);

  /* ---- admin.css system ---- */
  --admin-yellow: #28cb69;
  --admin-yellow-hover: #0fac4e;
  --admin-yellow-dark: #0fac4e;
  --admin-yellow-light: rgba(40, 203, 105, 0.12);
  --admin-yellow-glow: rgba(40, 203, 105, 0.38);
  --admin-primary: #28cb69;
  --admin-primary-hover: #0fac4e;
  --admin-primary-text: #ffffff;

  /* ---- shared tokens ---- */
  --dp-bg-1: #202024;
  --dp-bg-2: #1a1a1d;
  --dp-bg-3: #131313;
  --dp-bg-4: #1c2434;
  --dp-line: rgba(255, 255, 255, 0.08);
  --dp-accent: #28cb69;
  --dp-accent-2: #0fac4e;
  --dp-accent-soft: rgba(40, 203, 105, 0.12);
  --dp-text: #ffffff;
  --dp-text-2: #c3c9d6;
  --dp-muted: #8b93a7;
  --dp-green: #2fcd94;
  --dp-red: #e93e3e;
  --dp-radius: 15px;
}

/* ============ base surfaces ============ */
body,
body.guest,
body.user-panel-body {
  background-color: #1a1a1d !important;
  color: #c3c9d6 !important;
}
body h1, body h2, body h3, body h4, body h5, body h6 { color: #FFFFFF !important; }
body p, body span, body li, body label, body div { border-color: rgba(255,255,255,.08); }
body a { color: inherit; }

/* ambient purple glow behind everything */
body.guest::before,
body:not(.user-panel-body):not(.guest)::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(760px 420px at 80% -8%, rgba(40, 203, 105, 0.16), transparent 70%),
    radial-gradient(700px 400px at 10% 2%, rgba(135, 86, 255, 0.12), transparent 72%);
}
/* Lift page content above the glow layer.
   IMPORTANT: never blanket-apply `position: relative` here — it would override
   `position: fixed` on off-canvas overlays (mobile drawer, backdrop, ambient
   spheres, floating buttons) and drag them into the normal flow, adding their
   full height below the footer as dead space. Exclude fixed/absolute/sticky
   elements, and use :not() guards for the known JS-toggled overlays. */
body.guest > *:not(.mobile-drawer):not(.mobile-drawer-backdrop):not(.ambient-glow-sphere):not(.mobile-bottom-nav):not([style*="position: fixed"]),
body:not(.user-panel-body):not(.guest) > *:not(.mobile-drawer):not(.mobile-drawer-backdrop):not(.ambient-glow-sphere):not(.mobile-bottom-nav):not([style*="position: fixed"]) {
  z-index: 1;
}
/* Raise only genuine flow content — set position without clobbering fixed/absolute */
body.guest > *:not(.mobile-drawer):not(.mobile-drawer-backdrop):not(.ambient-glow-sphere):not(.mobile-bottom-nav):not([style*="position: fixed"]):not(script):not(style),
body:not(.user-panel-body):not(.guest) > *:not(.mobile-drawer):not(.mobile-drawer-backdrop):not(.ambient-glow-sphere):not(.mobile-bottom-nav):not([style*="position: fixed"]):not(script):not(style) {
  position: relative;
}

/* scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #131313; }
::-webkit-scrollbar-thumb { background: #2a3346; border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #0fac4e; }

/* ============ headers -> dark glass ============ */
.site-header,
.guest .header-wrapper,
header.header,
.navbar {
  background: rgba(23, 31, 46, 0.9) !important;
  background-color: rgba(23, 31, 46, 0.9) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35) !important;
  backdrop-filter: blur(14px) !important;
  -webkit-backdrop-filter: blur(14px) !important;
  border-radius: 0 !important;
}
.brand-logo, .guest .navbar-brand { color: #FFFFFF !important; }
.brand-logo > span:first-child {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 20px rgba(40, 203, 105, 0.4) !important;
}
.brand-logo span span, .brand-logo div span { color: #7bf0a8 !important; }
.nav-link, .guest .navbar-nav > li > a { color: #c3c9d6 !important; }
.nav-link:hover, .nav-link.active,
.guest .navbar-nav > li > a:hover,
.guest .navbar-nav > li.active > a {
  color: #FFFFFF !important;
  background: rgba(40, 203, 105, 0.12) !important;
  border-radius: 10px !important;
}

/* ============ buttons -> purple ============ */
.btn-primary,
.btn-gold,
.btn-signin-pill,
.guest .nav-signup a,
.guest .navbar-nav > li.btn-signup-link > a,
.guest .navbar-nav > li.nav-signup > a,
button[type="submit"].btn-primary {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  box-shadow: 0 10px 28px rgba(40, 203, 105, 0.38) !important;
  border: none !important;
  border-radius: 10px !important;
}
.btn-primary:hover,
.btn-gold:hover,
.btn-signin-pill:hover,
.guest .navbar-nav > li.btn-signup-link > a:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(40, 203, 105, 0.5) !important;
  color: #FFFFFF !important;
  text-shadow: none !important;
}
.btn-secondary {
  background: #131313 !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 10px !important;
}
.btn-outline {
  background: transparent !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  color: #FFFFFF !important;
  border-radius: 10px !important;
}
.btn-outline:hover {
  border-color: #28cb69 !important;
  color: #7bf0a8 !important;
  background: rgba(40, 203, 105, 0.1) !important;
}
.btn-danger, .btn-red { background: #e93e3e !important; color: #fff !important; border-radius: 10px !important; }
.btn-success { background: #2fcd94 !important; color: #06251a !important; border-radius: 10px !important; }

/* ============ cards / panels / forms -> dark ============ */
.card, .card-border, .panel, .box, .widget, .stat-card, .metric-card {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4) !important;
  border-radius: 15px !important;
  color: #c3c9d6 !important;
}
.card-header, .card-footer, .panel-heading, .panel-footer {
  background: #131313 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: #FFFFFF !important;
}
input, select, textarea, .form-control {
  background-color: #131313 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  color: #FFFFFF !important;
  border-radius: 10px !important;
}
input::placeholder, textarea::placeholder { color: #6f7789 !important; }
input:focus, select:focus, textarea:focus, .form-control:focus {
  border-color: #28cb69 !important;
  box-shadow: 0 0 0 3px rgba(40, 203, 105, 0.18) !important;
  background-color: #131313 !important;
  color: #FFFFFF !important;
}
select option { background: #131313; color: #FFFFFF; }
hr, .divider { border-color: rgba(255, 255, 255, 0.08) !important; }
.table { color: #c3c9d6 !important; }
.table thead th { background: #131313 !important; color: #FFFFFF !important; border-color: rgba(255,255,255,.08) !important; }
.table td, .table th { border-color: rgba(255, 255, 255, 0.08) !important; }
.table tbody tr:hover { background: rgba(40, 203, 105, 0.06) !important; }
.dropdown-menu, .modal-content, .popover {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: #c3c9d6 !important;
  border-radius: 14px !important;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55) !important;
}
.dropdown-menu a, .dropdown-item { color: #c3c9d6 !important; }
.dropdown-menu a:hover, .dropdown-item:hover { background: rgba(40, 203, 105, 0.12) !important; color: #FFFFFF !important; }

/* alerts */
.alert { border-radius: 12px !important; border-width: 1px !important; }
.alert-success { background: rgba(47,205,148,.12) !important; border-color: rgba(47,205,148,.4) !important; color: #6ff0be !important; }
.alert-danger, .alert-error { background: rgba(233,62,62,.12) !important; border-color: rgba(233,62,62,.4) !important; color: #ff9c9c !important; }
.alert-warning { background: rgba(247,158,27,.12) !important; border-color: rgba(247,158,27,.4) !important; color: #ffc97a !important; }
.alert-info { background: rgba(40, 203, 105,.12) !important; border-color: rgba(40, 203, 105,.4) !important; color: #d9b8ff !important; }

/* badges / pills */
.badge, .pill, .tag, .label {
  background: rgba(40, 203, 105, 0.14) !important;
  color: #7bf0a8 !important;
  border: 1px solid rgba(40, 203, 105, 0.28) !important;
  border-radius: 999px !important;
}
.badge-yellow, .badge-gold, .pill-yellow { background: rgba(40, 203, 105,.14) !important; color: #7bf0a8 !important; }
.badge-success, .badge-green { background: rgba(47,205,148,.14) !important; color: #6ff0be !important; border-color: rgba(47,205,148,.3) !important; }
.badge-danger, .badge-red { background: rgba(233,62,62,.14) !important; color: #ff9c9c !important; border-color: rgba(233,62,62,.3) !important; }

/* ============ guest footer -> dark ============ */
/* NOTE: scoped away from the admin footer — a bare `footer` selector with
   !important was repainting `.admin-footer-credit` dark in BOTH themes. */
.guest footer,
footer:not(.admin-footer-credit) {
  background-color: #131313 !important;
  color: #8b93a7 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}
footer:not(.admin-footer-credit) h5,
footer:not(.admin-footer-credit) h4,
footer:not(.admin-footer-credit) .footer-title { color: #FFFFFF !important; }
footer:not(.admin-footer-credit) a { color: #c3c9d6 !important; }
footer:not(.admin-footer-credit) a:hover { color: #7bf0a8 !important; }
.guest .footer-banner, .footer-banner {
  background: linear-gradient(135deg, #0fac4e, #28cb69) !important;
  color: #FFFFFF !important;
  box-shadow: 0 25px 60px rgba(40, 203, 105, 0.35) !important;
  border-radius: 15px !important;
}
.guest .footer-banner h5, .footer-banner h5,
.guest .footer-banner a, .footer-banner a { color: #FFFFFF !important; }
footer .navbar-brand > span[style*="background"] {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
}
footer .navbar-brand > span:not([style*="background"]) { color: #FFFFFF !important; }
footer .social-links a {
  background: #202024 !important;
  color: #7bf0a8 !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
footer .social-links a:hover { background: #28cb69 !important; color: #FFFFFF !important; }

/* ============ error pages (403 / 404 / 500) ============ */
body .error-card {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45) !important;
  border-radius: 15px !important;
}
body .error-code, body .error-title { color: #FFFFFF !important; }
body .error-text { color: #8b93a7 !important; }

/* ============ auth-card pages (login / register / forgot / reset / verify) ============ */
body .auth-card {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45) !important;
  border-radius: 15px !important;
}
body .auth-card::before { background: linear-gradient(90deg, #0fac4e, #28cb69, #7bf0a8) !important; }
body .auth-logo i, body .auth-logo span { color: #7bf0a8 !important; }
body .auth-header h1, body .auth-header h2, body .auth-header h3 { color: #FFFFFF !important; }
body .auth-header p, body .auth-footer { color: #8b93a7 !important; }
body .auth-footer a, body .auth-link { color: #7bf0a8 !important; }
body .form-group label { color: #c3c9d6 !important; }
body .btn-submit {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  box-shadow: 0 10px 28px rgba(40, 203, 105, 0.4) !important;
  border-radius: 10px !important;
}
body .btn-submit:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(40, 203, 105, 0.5) !important; }

/* ============ admin accents ============ */
.admin-sidebar,
.admin-layout .admin-sidebar {
  background: #131313 !important;
  border-inline-end: 1px solid rgba(255, 255, 255, 0.08) !important;
}
.admin-sidebar .nav-item.active,
.admin-nav-item.active,
.admin-menu-item.active,
.admin-sidebar .nav-item.active a,
.admin-nav-item.active a,
.admin-menu-item.active a {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  font-weight: 800 !important;
  border-inline-start: 3px solid #7bf0a8 !important;
  box-shadow: 0 6px 18px rgba(40, 203, 105, 0.4) !important;
  border-radius: 10px !important;
}
.admin-sidebar .nav-item.active a i,
.admin-nav-item.active a i,
.admin-menu-item.active a i { color: #FFFFFF !important; }
.admin-sidebar .nav-item a,
.admin-nav-item a,
.admin-menu-item a { color: #c3c9d6 !important; }
.admin-sidebar .nav-item a:hover,
.admin-nav-item a:hover,
.admin-menu-item a:hover { background: rgba(40, 203, 105, 0.12) !important; color: #FFFFFF !important; border-radius: 10px !important; }

.admin-layout .btn-primary,
.admin-layout button.btn-primary,
.admin-layout a.btn-primary,
.admin-btn-primary, .btn-admin-primary,
.admin-sidebar .logout-btn {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  border: 1px solid #28cb69 !important;
  box-shadow: 0 6px 18px rgba(40, 203, 105, 0.35) !important;
  border-radius: 10px !important;
}
.admin-layout .btn-primary:hover,
.admin-layout button.btn-primary:hover,
.admin-layout a.btn-primary:hover {
  background: linear-gradient(135deg, #0fac4e, #28cb69) !important;
  color: #FFFFFF !important;
  box-shadow: 0 8px 24px rgba(40, 203, 105, 0.45) !important;
}
.admin-layout .badge-role {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  border: 1px solid #28cb69 !important;
}
.admin-layout .admin-sidebar-user-avatar {
  background: linear-gradient(135deg, #28cb69, #7bf0a8) !important;
  color: #FFFFFF !important;
}
.admin-layout .admin-sidebar-user-role { color: #7bf0a8 !important; }
.admin-layout .profit-card::after { background: linear-gradient(90deg, #28cb69, #7bf0a8) !important; }
.admin-brand-logo {
  background: linear-gradient(135deg, #28cb69, #7bf0a8) !important;
  color: #FFFFFF !important;
}
.admin-brand-accent { color: #7bf0a8 !important; }
.admin-header, .admin-topbar {
  background: rgba(23, 31, 46, 0.92) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  color: #FFFFFF !important;
}
.admin-content, .admin-main { background: var(--admin-bg-base, #1a1a1d) !important; }
.admin-layout .table thead th { background: #131313 !important; color: #FFFFFF !important; }

/* ============ login / register page-level styles ============ */
#login-sec .btn-login-submit, #signup-sec .btn-register-submit {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  box-shadow: 0 12px 32px rgba(40, 203, 105, 0.42) !important;
  border-radius: 10px !important;
}
#login-sec .btn-login-submit:hover, #signup-sec .btn-register-submit:hover {
  background: linear-gradient(135deg, #0fac4e, #28cb69) !important;
  transform: translateY(-2px);
}
#login-sec .input-icon, #signup-sec .input-icon {
  background-color: #131313 !important;
  color: #7bf0a8 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
}
#login-sec .input-icon i, #signup-sec .input-icon i { color: #7bf0a8 !important; }
#login-sec .input-icon svg path, #signup-sec .input-icon svg path { fill: #7bf0a8 !important; }
#login-sec .form-group.v2 .form-control:focus, #signup-sec .form-group.v2 .form-control:focus {
  border-color: #28cb69 !important;
  box-shadow: 0 0 0 3px rgba(40, 203, 105, 0.18) !important;
}
#login-sec nav a[href="register.php"], #signup-sec nav a[href="login.php"] { color: #7bf0a8 !important; }

/* ============ smmscripts guest header (login/register/terms/...) ============ */
.guest .lang-button, #login-sec .lang-button, #signup-sec .lang-button {
  background: #202024 !important;
  color: #c3c9d6 !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 999px !important;
}
.guest .lang-button:hover { background: rgba(40, 203, 105,.14) !important; color: #7bf0a8 !important; border-color: #28cb69 !important; }
.guest .navbar-brand { color: #FFFFFF !important; }
.guest .navbar-brand span.brand-logo-icon {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
}
.guest .navbar-brand span.highlight { color: #7bf0a8 !important; }
.guest .dropdown-menu-lang {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 12px !important;
}
.guest .dropdown-menu-lang a { color: #c3c9d6 !important; }
.guest .dropdown-menu-lang a:hover { background: rgba(40, 203, 105,.12) !important; color: #FFFFFF !important; }

/* ============ PWA install banner ============ */
#smmPwaBanner {
  background: linear-gradient(135deg, #1c2434, #202024) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-top: 3px solid #28cb69 !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5) !important;
  border-radius: 14px !important;
}
#smmPwaBanner [style*="color: #FFF"] { color: #FFFFFF !important; }
#smmPwaBanner [style*="color: #9CA3AF"] { color: #8b93a7 !important; }
#smmPwaBanner [style*="background: #000"] {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  border-color: transparent !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(40, 203, 105, 0.35) !important;
}
#smmPwaInstallBtn {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(40, 203, 105, 0.35) !important;
}
#smmPwaDismissBtn { background: #131313 !important; color: #8b93a7 !important; }

/* ============ blog / faq / legal pages ============ */
.blog-hero {
  background: linear-gradient(135deg, rgba(40, 203, 105, 0.16), rgba(40, 203, 105, 0.04)) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 15px !important;
}
.site-header select { background: #131313 !important; color: #FFFFFF !important; border-color: rgba(255,255,255,.12) !important; }
.pill-active {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
  border-color: transparent !important;
}
.blog-card {
  background: #202024 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 15px !important;
  transition: .22s;
}
.blog-card:hover { border-color: rgba(40, 203, 105, 0.45) !important; transform: translateY(-4px); }
.blog-card a { color: #FFFFFF !important; }
.blog-card p, .blog-card .excerpt { color: #8b93a7 !important; }
.blog-meta, .blog-date { color: #6f7789 !important; }
.legal-page, .terms-page, .privacy-page, .faq-page { background: transparent !important; color: #c3c9d6 !important; }
.legal-page h1, .legal-page h2, .legal-page h3,
.terms-page h1, .terms-page h2, .terms-page h3,
.privacy-page h1, .privacy-page h2, .privacy-page h3 { color: #FFFFFF !important; }
.accordion-item, .faq-item { background: #202024 !important; border-color: rgba(255,255,255,.08) !important; border-radius: 14px !important; }
.accordion-button { background: #202024 !important; color: #FFFFFF !important; }
.accordion-button:not(.collapsed) { background: rgba(40, 203, 105,.12) !important; color: #FFFFFF !important; }
.accordion-body { background: #202024 !important; color: #8b93a7 !important; }

/* ============ misc legacy helpers ============ */
.bg-white, .bg-light { background-color: #202024 !important; }
.text-dark, .text-black { color: #FFFFFF !important; }
.text-muted, .muted { color: #8b93a7 !important; }
.text-primary { color: #7bf0a8 !important; }
.border { border-color: rgba(255, 255, 255, 0.08) !important; }
.shadow, .shadow-sm { box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45) !important; }
.page-title, .section-title, .heading { color: #FFFFFF !important; }
.empty-state { color: #8b93a7 !important; }
.empty-state i { color: rgba(40, 203, 105, 0.5) !important; }

/* selection */
::selection { background: #28cb69; color: #FFFFFF; }

/* ==========================================================================
   NEUTRALISE HARDCODED LIGHT INLINE STYLES
   Guest / auth / blog / legal templates carry inline light colours. These
   attribute selectors (with !important) outrank inline non-important
   declarations so the dark theme wins without touching the PHP templates.
   ========================================================================== */

/* --- light surfaces -> dark --- */
[style*="background: #FFFFFF"], [style*="background:#FFFFFF"],
[style*="background: #FFFFFF"], [style*="background:#FFFFFF"],
[style*="background: #FFF;"], [style*="background:#FFF;"],
[style*="background: #FFF "], [style*="background: white"],
[style*="background-color: #FFFFFF"], [style*="background-color:#FFFFFF"],
[style*="background: #FFFFFF"], [style*="background:#FFFFFF"],
[style*="background-color: #FFFFFF"],
[style*="background: #1a1a1d"], [style*="background:#1a1a1d"],
[style*="background: #F3F4F6"], [style*="background:#F3F4F6"],
[style*="background-color: #F3F4F6"],
[style*="background: rgba(255,255,255,.06)"], [style*="background:rgba(255,255,255,.06)"],
[style*="background: #FBFDFE"], [style*="background:#FBFDFE"],
[style*="background: #F5F3FF"], [style*="background:#F5F3FF"],
[style*="background: #EFF6FF"], [style*="background:#EFF6FF"],
[style*="background: rgba(255,255,255,.10)"], [style*="background:rgba(255,255,255,.10)"],
[style*="background: #202024"], [style*="background:#202024"] {
    background-color: #202024 !important;
    background-image: none !important;
}

/* --- light amber / green info boxes -> dark tinted --- */
[style*="background: #FFFBE6"], [style*="background:#FFFBE6"],
[style*="background-color: rgba(247,158,27,.12)"],
[style*="background: #FEF08A"], [style*="background:#FEF08A"] {
    background-color: rgba(247, 158, 27, 0.12) !important;
    background-image: none !important;
}
[style*="background: #ECFDF5"], [style*="background:#ECFDF5"] {
    background-color: rgba(47, 205, 148, 0.12) !important;
    background-image: none !important;
}

/* --- legacy cyber-yellow accents -> purple --- */
[style*="background: #FFE600"], [style*="background:#FFE600"],
[style*="background: #FFE600"], [style*="background:#FFE600"],
[style*="background: #FFE600"], [style*="background:#FFE600"],
[style*="background: #FDF001 !important"] {
    background-color: #28cb69 !important;
    background-image: linear-gradient(135deg, #28cb69, #0fac4e) !important;
    color: #FFFFFF !important;
}
[style*="color: #28cb69"], [style*="color:#28cb69"],
[style*="color: #28cb69"], [style*="color:#28cb69"] {
    color: #7bf0a8 !important;
}

/* --- dark text on light surfaces -> light text --- */
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #4B5563"], [style*="color:#4B5563"],
[style*="color: #4B5563"], [style*="color:#4B5563"],
[style*="color: #555;"], [style*="color:#555;"],
[style*="color: #555 "], [style*="color: #333;"], [style*="color:#333;"],
[style*="color: #666;"], [style*="color:#666;"],
[style*="color: #9CA3AF"], [style*="color:#9CA3AF"],
[style*="color: #000000"], [style*="color:#000000"],
[style*="color: #000;"], [style*="color:#000;"],
[style*="color: black"] {
    color: #FFFFFF !important;
}
[style*="color: #9CA3AF"], [style*="color:#9CA3AF"],
[style*="color: #9CA3AF"], [style*="color:#9CA3AF"],
[style*="color: #9CA3AF"], [style*="color:#9CA3AF"] {
    color: #8b93a7 !important;
}
[style*="color: #92400E"], [style*="color:#92400E"],
[style*="color: #D97706"], [style*="color:#D97706"],
[style*="color: #B45309"], [style*="color:#B45309"] {
    color: #ffc97a !important;
}

/* --- light borders -> subtle dark borders --- */
[style*="border: 1px solid rgba(255,255,255,.10)"], [style*="border: 1.5px solid rgba(255,255,255,.10)"],
[style*="border: 1px solid rgba(255,255,255,.08)"], [style*="border: 1.5px solid rgba(255,255,255,.08)"],
[style*="border: 1px solid rgba(255,255,255,.08)"], [style*="border: 1.5px solid rgba(255,255,255,.08)"],
[style*="border: 1px solid #F3F4F6"], [style*="border: 1.5px solid #F3F4F6"],
[style*="border-color: rgba(255,255,255,.10)"], [style*="border-color:rgba(255,255,255,.10)"],
[style*="border: 1px solid rgba(247,158,27,.25)"], [style*="border: 1.5px solid rgba(247,158,27,.25)"] {
    border-color: rgba(255, 255, 255, 0.10) !important;
}

/* --- 3-digit short hex variants (#fff / #FFF) --- */
[style*="background: #FFF;"], [style*="background:#FFF;"],
[style*="background: #fff;"], [style*="background:#fff;"],
[style*="background: #FFF "], [style*="background:#FFF "],
[style*="background: #fff "], [style*="background:#fff "],
[style*="background-color: #FFF;"], [style*="background-color:#FFF;"],
[style*="background-color: #fff;"], [style*="background-color:#fff;"] {
    background-color: #202024 !important;
    background-image: none !important;
}

/* ==========================================================================
   ADMIN — dark theme (default) re-tinted to the purple palette
   admin.css ships a [data-admin-theme="dark"] variant using a blue accent;
   these rules map it onto the site identity (#1a1a1d / #202024 / #28cb69).
   ========================================================================== */
[data-admin-theme="dark"] .admin-layout { background-color: #1a1a1d !important; color: #c3c9d6 !important; }
[data-admin-theme="dark"] .admin-sidebar,
[data-admin-theme="dark"] .admin-brand { background: #131313 !important; border-color: rgba(255,255,255,.08) !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-header { background: rgba(23,31,46,.92) !important; border-color: rgba(255,255,255,.08) !important; }
[data-admin-theme="dark"] .admin-lang-select,
[data-admin-theme="dark"] #adminThemeToggle,
[data-admin-theme="dark"] .admin-mobile-toggle { background: #202024 !important; border-color: rgba(255,255,255,.1) !important; color: #c3c9d6 !important; }

/* surfaces */
[data-admin-theme="dark"] .admin-layout .card,
[data-admin-theme="dark"] .stat-card,
[data-admin-theme="dark"] .profit-card { background: #202024 !important; border-color: rgba(255,255,255,.07) !important; color: #c3c9d6 !important; }
[data-admin-theme="dark"] .admin-layout .card-header { background: #131313 !important; border-color: rgba(255,255,255,.07) !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-layout .card-footer { background: #131313 !important; border-color: rgba(255,255,255,.07) !important; }
[data-admin-theme="dark"] .admin-layout .table th { background: #131313 !important; color: #FFFFFF !important; border-color: rgba(255,255,255,.08) !important; }
[data-admin-theme="dark"] .admin-layout .table td { background: #202024 !important; color: #c3c9d6 !important; border-color: rgba(255,255,255,.06) !important; }
[data-admin-theme="dark"] .admin-layout .table tr:hover td { background: rgba(40, 203, 105,.07) !important; }
[data-admin-theme="dark"] .admin-layout input,
[data-admin-theme="dark"] .admin-layout select,
[data-admin-theme="dark"] .admin-layout textarea { background: #131313 !important; border-color: rgba(255,255,255,.1) !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-layout .modal-content,
[data-admin-theme="dark"] .admin-layout .modal-card { background: #202024 !important; border-color: rgba(255,255,255,.1) !important; color: #c3c9d6 !important; }
[data-admin-theme="dark"] .admin-layout .btn-outline { background: #202024 !important; border-color: rgba(255,255,255,.12) !important; color: #c3c9d6 !important; }
[data-admin-theme="dark"] .admin-layout .btn-outline:hover { background: rgba(40, 203, 105,.14) !important; border-color: #28cb69 !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-layout .btn-secondary { background: #202024 !important; border-color: rgba(255,255,255,.1) !important; color: #c3c9d6 !important; }
[data-admin-theme="dark"] .admin-layout .btn-secondary:hover { background: rgba(40, 203, 105,.14) !important; border-color: #28cb69 !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-nav-item:not(.active) a:hover { background: rgba(40, 203, 105,.12) !important; color: #FFFFFF !important; }

/* accents: blue -> purple */
[data-admin-theme="dark"] .profit-card::after { background: linear-gradient(90deg, #0fac4e, #28cb69) !important; }
[data-admin-theme="dark"] .admin-nav-item.active a,
[data-admin-theme="dark"] .admin-nav-item.active { background: linear-gradient(135deg, #28cb69, #0fac4e) !important; color: #FFFFFF !important; }
[data-admin-theme="dark"] .stat-card .stat-icon,
[data-admin-theme="dark"] .stat-card.blue .stat-icon { background: rgba(40, 203, 105,.14) !important; color: #7bf0a8 !important; border-color: rgba(40, 203, 105,.3) !important; }
[data-admin-theme="dark"] .stat-card.green .stat-icon { background: rgba(47,205,148,.14) !important; color: #6ff0be !important; border-color: rgba(47,205,148,.3) !important; }
[data-admin-theme="dark"] .stat-card .stat-label { color: #8b93a7 !important; }
[data-admin-theme="dark"] .stat-card .stat-value { color: #FFFFFF !important; }
[data-admin-theme="dark"] .admin-brand-accent { color: #7bf0a8 !important; }
[data-admin-theme="dark"] .admin-layout .badge-role { background: linear-gradient(135deg,#28cb69,#0fac4e) !important; color: #fff !important; border-color: transparent !important; }
[data-admin-theme="dark"] .admin-layout .alert-info { background: rgba(40, 203, 105,.12) !important; border-color: rgba(40, 203, 105,.4) !important; color: #d9b8ff !important; }

/* light theme accents
   ---------------------------------------------------------------------------
   NOTE: the `[data-admin-theme="light"]` surface rules that used to live here
   painted DARK colours (#1a1a1d / #202024), which is why switching to light
   mode appeared to do nothing. The complete light theme now lives in
   assets/css/admin-theme.css (loaded last). Only the accent is kept here. */
[data-admin-theme="light"] .profit-card::after { background: linear-gradient(90deg, #0fac4e, #28cb69) !important; }

/* ============ brand gradient text + logo mark -> purple ============ */
.brand-logo span,
.dragon-gradient-text,
.text-gradient-primary {
  background: linear-gradient(135deg, #ffffff 0%, #d9b8ff 40%, #28cb69 75%, #0fac4e 100%) !important;
  background-size: 200% auto !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  color: #28cb69 !important;
}
.brand-logo i {
  background: linear-gradient(135deg, rgba(40, 203, 105, .28), rgba(135, 86, 255, .22)) !important;
  border-color: rgba(40, 203, 105, .45) !important;
  color: #7bf0a8 !important;
  box-shadow: none !important;
}
.brand-logo:hover i {
  border-color: #28cb69 !important;
  color: #FFFFFF !important;
  box-shadow: 0 0 25px rgba(40, 203, 105, .6) !important;
}
.guest .navbar-brand span.brand-logo-icon {
  background: linear-gradient(135deg, #28cb69, #0fac4e) !important;
  color: #FFFFFF !important;
}


/* ==========================================================================
   INLINE-STYLE NEUTRALISER (rebuilt — complete form coverage)
   PHP templates carry hard-coded light colours inline. `!important` in a
   stylesheet beats a NON-important inline style, so matching on the raw
   inline string neutralises them without touching the templates.
   Covers: #FFF / #fff / #FFFFFF / #ffffff · background: and background-color:
   · with and without a space after the colon · solid and dashed borders.
   ========================================================================== */

/* --- light surfaces -> dark (whites) ------------------------------------- */
[style*="background: #FFF"], [style*="background:#FFF"],
[style*="background: #fff"], [style*="background:#fff"],
[style*="background: #FFFFFF"], [style*="background:#FFFFFF"],
[style*="background: #ffffff"], [style*="background:#ffffff"],
[style*="background-color: #FFF"], [style*="background-color:#FFF"],
[style*="background-color: #fff"], [style*="background-color:#fff"],
[style*="background-color: #FFFFFF"], [style*="background-color:#FFFFFF"],
[style*="background-color: #ffffff"], [style*="background-color:#ffffff"],
[style*="background: white"], [style*="background:white"],
[style*="background: #FAFAFA"], [style*="background:#FAFAFA"],
[style*="background: #F9FAFB"], [style*="background:#F9FAFB"],
[style*="background: #F8FAFC"], [style*="background:#F8FAFC"],
[style*="background: #F8F9FA"], [style*="background:#F8F9FA"],
[style*="background: #F3F4F6"], [style*="background:#F3F4F6"],
[style*="background: #F1F5F9"], [style*="background:#F1F5F9"],
[style*="background: #FBFDFE"], [style*="background:#FBFDFE"],
[style*="background: #F5F3FF"], [style*="background:#F5F3FF"],
[style*="background: #EFF6FF"], [style*="background:#EFF6FF"],
[style*="background: #202024"], [style*="background:#202024"],
[style*="background: #E5E7EB"], [style*="background:#E5E7EB"],
[style*="background: #202024"], [style*="background:#202024"],
[style*="background-color: #F9FAFB"], [style*="background-color:#F9FAFB"],
[style*="background-color: #F8FAFC"], [style*="background-color:#F8FAFC"],
[style*="background-color: #F3F4F6"], [style*="background-color:#F3F4F6"],
[style*="background-color: #F5F3FF"], [style*="background-color:#F5F3FF"],
[style*="background-color: #EFF6FF"], [style*="background-color:#EFF6FF"],
[style*="background-color: #FBFDFE"], [style*="background-color:#FBFDFE"],
[style*="background-color: #FFFBE6"], [style*="background-color:#FFFBE6"],
[style*="background: #FFFFFF !important"], [style*="background:#FFFFFF !important"],
[style*="background: #FFF !important"], [style*="background:#FFF !important"],
[style*="background-color: #FFFFFF !important"], [style*="background-color:#FFFFFF !important"],
[style*="background-color: #FFF !important"], [style*="background-color:#FFF !important"] {
    background-color: #202024 !important;
    background-image: none !important;
}

/* --- amber / green info panels -> dark tints (must follow the whites) ---- */
[style*="background: #FFFBE6"], [style*="background:#FFFBE6"],
[style*="background-color: #FFFBE6"], [style*="background-color:#FFFBE6"],
[style*="background: #FEF08A"], [style*="background:#FEF08A"],
[style*="background: #FEF3C7"], [style*="background:#FEF3C7"],
[style*="background: #FFFBEB"], [style*="background:#FFFBEB"] {
    background-color: rgba(247, 158, 27, .12) !important;
    background-image: none !important;
}
[style*="background: #ECFDF5"], [style*="background:#ECFDF5"],
[style*="background: #D1FAE5"], [style*="background:#D1FAE5"] {
    background-color: rgba(47, 205, 148, .12) !important;
    background-image: none !important;
}
[style*="background: #EFF6FF"], [style*="background:#EFF6FF"],
[style*="background: #DBEAFE"], [style*="background:#DBEAFE"],
[style*="background: #E0F2FE"], [style*="background:#E0F2FE"] {
    background-color: rgba(40, 203, 105, .12) !important;
    background-image: none !important;
}
[style*="background: #FEE2E2"], [style*="background:#FEE2E2"],
[style*="background: #FEF2F2"], [style*="background:#FEF2F2"] {
    background-color: rgba(233, 62, 62, .12) !important;
    background-image: none !important;
}

/* --- dark text on light surfaces -> light text --------------------------- */
[style*="color: #131313"], [style*="color:#131313"],
[style*="color: #1F2937"], [style*="color:#1F2937"],
[style*="color: #0F172A"], [style*="color:#0F172A"],
[style*="color: #0f2b46"], [style*="color:#0f2b46"],
[style*="color: #102a43"], [style*="color:#102a43"],
[style*="color: #374151"], [style*="color:#374151"],
[style*="color: #4B5563"], [style*="color:#4B5563"],
[style*="color: #555"], [style*="color:#555"],
[style*="color: #333"], [style*="color:#333"],
[style*="color: #666"], [style*="color:#666"],
[style*="color: #000000"], [style*="color:#000000"],
[style*="color: #000;"], [style*="color:#000;"],
[style*="color: black"], [style*="color:black"] {
    color: #ffffff !important;
}
[style*="color: #6B7280"], [style*="color:#6B7280"],
[style*="color: #64748B"], [style*="color:#64748B"],
[style*="color: #7B90A7"], [style*="color:#7B90A7"],
[style*="color: #94A3B8"], [style*="color:#94A3B8"] {
    color: #8b93a7 !important;
}
[style*="color: #9CA3AF"], [style*="color:#9CA3AF"],
[style*="color: #CBD5E1"], [style*="color:#CBD5E1"] {
    color: #c3c9d6 !important;
}
[style*="color: #92400E"], [style*="color:#92400E"],
[style*="color: #B45309"], [style*="color:#B45309"],
[style*="color: #D97706"], [style*="color:#D97706"] {
    color: #ffc97a !important;
}

/* --- light borders (solid + dashed) -> subtle dark ----------------------- */
[style*="solid #E5E7EB"], [style*="solid#E5E7EB"],
[style*="solid #e5e7eb"], [style*="solid#e5e7eb"],
[style*="solid #E7EFF6"], [style*="solid #e7eff6"],
[style*="solid #EEF4FA"], [style*="solid #eef4fa"],
[style*="solid #F3F4F6"], [style*="solid #f3f4f6"],
[style*="solid #FDE68A"], [style*="solid #fde68a"],
[style*="dashed #E7EFF6"], [style*="dashed #e7eff6"],
[style*="dashed #E5E7EB"], [style*="dashed #e5e7eb"],
[style*="dashed #D1D5DB"], [style*="dashed #d1d5db"],
[style*="dashed #CBD5E1"], [style*="dashed #cbd5e1"],
[style*="border-color: rgba(255,255,255,.10)"], [style*="border-color:rgba(255,255,255,.10)"],
[style*="border-color: rgba(255,255,255,.10)"], [style*="border-color:rgba(255,255,255,.10)"],
[style*="border-color: rgba(255,255,255,.08)"], [style*="border-color:rgba(255,255,255,.08)"] {
    border-color: rgba(255, 255, 255, .10) !important;
}

/* --- keep light surfaces that are functionally required ------------------ */
#binanceQrWrapper, [id$="QrWrapper"], [id*="QrBox"], [id*="qrBox"],
.twofa-qr-container, [class*="qr-code"], [class*="qrCode"] {
    background-color: #FFFFFF !important;
}
