/* ============================================================
   UID HANDLER PRO — GLOBAL CYBER BLACK THEME
   Black background · Neon Red accents · Glassmorphism
============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;600;700&display=swap');

/* ── Root Variables ──────────────────────────────────────── */
:root {
    /* Brand colors */
    --primary:        #ffffff;
    --primary-dim:    rgba(255,255,255,0.12);
    --primary-glow:   rgba(255,255,255,0.30);
    --primary-dark:   #cccccc;
    --primary-light:  #ffffff;

    --cyan:           #00e5ff;
    --cyan-dim:       rgba(0,229,255,0.10);
    --amber:          #ffb800;
    --amber-dim:      rgba(255,184,0,0.10);
    --success:        #00e676;
    --success-dim:    rgba(0,230,118,0.10);
    --error:          #ff1f4c;
    --warning:        #ffb800;
    --info:           #00e5ff;

    /* Backgrounds */
    --bg-primary:     #000000;
    --bg-secondary:   #070707;
    --bg-tertiary:    #0f0f0f;
    --bg-card:        rgba(10,10,10,0.85);
    --bg-glass:       rgba(255,255,255,0.025);

    /* Text */
    --text-primary:   #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted:     #4b5563;

    /* Borders */
    --border-color:   rgba(255,255,255,0.07);
    --border-red:     rgba(255,255,255,0.25);
    --border-cyan:    rgba(0,229,255,0.20);

    /* Shadows */
    --shadow-sm:  0 1px 2px rgba(0,0,0,0.4);
    --shadow-md:  0 4px 12px rgba(0,0,0,0.5);
    --shadow-lg:  0 10px 30px rgba(0,0,0,0.6);
    --shadow-xl:  0 20px 50px rgba(0,0,0,0.7);
    --shadow-red: 0 0 20px rgba(255,255,255,0.20);

    /* Shape */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;

    /* Typography */
    --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Courier New', monospace;

    /* Animation */
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Reset ───────────────────────────────────────────────── */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-sans);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Premium Cyber Grid Background inspired by the Vercel site */
body::before {
    content: '';
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 32px 32px;
    animation: gridPan 30s linear infinite;
    pointer-events: none;
    z-index: -2;
    -webkit-mask-image: radial-gradient(ellipse at 50% 50%, black 20%, transparent 80%);
    mask-image: radial-gradient(ellipse at 50% 50%, black 20%, transparent 80%);
}

/* Subtle Pulse Glow behind the grid */
body::after {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.02), transparent 50%);
    animation: pulseGlowBg 15s ease-in-out infinite alternate;
    pointer-events: none;
    z-index: -3;
}

@keyframes gridPan {
    0% { background-position: 0 0; }
    100% { background-position: 32px 32px; }
}

@keyframes pulseGlowBg {
    0% { transform: scale(1) translate(0, 0); }
    100% { transform: scale(1.1) translate(2%, 2%); }
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    outline: none;
}

input, select, textarea {
    font-family: inherit;
    outline: none;
}

::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: #000; }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-light); }

/* ── Utilities ───────────────────────────────────────────── */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Scanline overlay (subtle) ───────────────────────────── */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        rgba(0,0,0,0) 0px,
        rgba(0,0,0,0) 2px,
        rgba(0,0,0,0.03) 2px,
        rgba(0,0,0,0.03) 4px
    );
    pointer-events: none;
    z-index: 9999;
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.35rem;
    border-radius: var(--radius-md);
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.875rem;
    transition: var(--transition);
    white-space: nowrap;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--primary);
    color: #000000;
    font-weight: 700;
    box-shadow: 0 0 20px var(--primary-glow);
}
.btn-primary:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(255,255,255,0.5);
}

.btn-secondary {
    background: var(--bg-glass);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}
.btn-secondary:hover {
    background: var(--primary-dim);
    border-color: var(--border-red);
    color: var(--primary);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}
.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-dim);
}

.btn-large  { padding: 0.875rem 1.75rem; font-size: 1rem; }
.btn-block  { width: 100%; justify-content: center; }

.btn-icon {
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.btn-icon:hover { background: var(--primary-dim); border-color: var(--border-red); color: var(--primary); }
.btn-icon.danger:hover  { background: rgba(239,68,68,0.1); border-color: #ef4444; color: #ef4444; }
.btn-icon.warning:hover { background: rgba(255,184,0,0.1); border-color: var(--amber); color: var(--amber); }
.btn-icon.info:hover    { background: var(--cyan-dim); border-color: var(--border-cyan); color: var(--cyan); }

.btn.btn-danger {
    background: rgba(239,68,68,0.08);
    color: #ef4444;
    border: 1px solid rgba(239,68,68,0.2);
}
.btn.btn-danger:hover { background: rgba(239,68,68,0.18); border-color: #ef4444; }

.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.78rem; }

/* ── Flash Messages ──────────────────────────────────────── */
.flash-container {
    position: fixed;
    top: 1.5rem;
    right: 1.5rem;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    max-width: 380px;
}

.flash-message {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.125rem;
    background: rgba(5,5,5,0.95);
    border-left: 3px solid;
    border-radius: var(--radius-md);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-xl);
    animation: flashSlideIn 0.3s cubic-bezier(0.34,1.56,0.64,1);
    border-top: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

@keyframes flashSlideIn {
    from { transform: translateX(420px); opacity: 0; }
    to   { transform: translateX(0); opacity: 1; }
}

.flash-success { border-left-color: var(--success); }
.flash-success i { color: var(--success); }
.flash-error   { border-left-color: var(--error); }
.flash-error i { color: var(--error); }
.flash-info    { border-left-color: var(--info); }
.flash-info i  { color: var(--info); }
.flash-warning { border-left-color: var(--warning); }
.flash-warning i { color: var(--warning); }

.flash-message span { flex: 1; font-size: 0.875rem; color: var(--text-primary); }

.flash-close {
    margin-left: auto;
    background: transparent;
    color: var(--text-muted);
    padding: 0.2rem;
    transition: var(--transition);
    flex-shrink: 0;
}
.flash-close:hover { color: var(--primary); }

/* ── Form Controls (global) ──────────────────────────────── */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    margin-bottom: 1.25rem;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    font-size: 0.8rem;
    color: var(--text-secondary);
    letter-spacing: 0.3px;
}
.form-group label i { color: var(--primary); font-size: 0.8rem; }

.form-control {
    padding: 0.8rem 1rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.9rem;
    transition: var(--transition);
    width: 100%;
}
.form-control:focus {
    border-color: var(--border-red);
    background: rgba(255,255,255,0.04);
    box-shadow: 0 0 0 3px rgba(255,255,255,0.08);
}
.form-control::placeholder { color: var(--text-muted); font-size: 0.85rem; }

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%234b5563' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.875rem center;
    padding-right: 2.5rem;
}
select.form-control option { background: #111; color: var(--text-primary); }

textarea.form-control { resize: vertical; min-height: 120px; }

.form-hint { font-size: 0.72rem; color: var(--text-muted); margin-top: 0.2rem; }

/* Password toggle */
.password-input-wrapper { position: relative; }
.password-toggle {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    color: var(--text-muted);
    padding: 0.35rem;
    transition: var(--transition);
}
.password-toggle:hover { color: var(--primary); }

.password-strength { display: flex; align-items: center; gap: 1rem; }
.strength-bar { flex: 1; height: 3px; background: var(--bg-tertiary); border-radius: 2px; overflow: hidden; }
.strength-fill { height: 100%; width: 0; transition: var(--transition); }
.strength-text { font-size: 0.72rem; font-weight: 600; }

.form-options { display: flex; align-items: center; justify-content: space-between; }
.checkbox-label { display: flex; align-items: center; gap: 0.5rem; cursor: pointer; font-size: 0.875rem; color: var(--text-secondary); }
.forgot-link { color: var(--primary); font-size: 0.875rem; }
.forgot-link:hover { text-decoration: underline; }

.filter-select, .search-input {
    padding: 0.5rem 1rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.875rem;
    transition: var(--transition);
    font-family: var(--font-sans);
}
.filter-select:focus, .search-input:focus {
    border-color: var(--border-red);
    outline: none;
}

/* ── Auth Pages ──────────────────────────────────────────── */
.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    background: radial-gradient(ellipse at 20% 50%, rgba(255,255,255,0.06) 0%, transparent 60%),
                radial-gradient(ellipse at 80% 50%, rgba(0,229,255,0.04) 0%, transparent 60%),
                var(--bg-primary);
}

.auth-background {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.15;
    animation: floatOrb 20s ease-in-out infinite;
}
.orb-1 { width: 600px; height: 600px; background: var(--primary); top: -20%; right: -15%; animation-delay: 0s; }
.orb-2 { width: 400px; height: 400px; background: var(--cyan); bottom: -15%; left: -10%; animation-delay: 7s; }
.orb-3 { width: 300px; height: 300px; background: var(--amber); top: 40%; left: 45%; animation-delay: 14s; }

@keyframes floatOrb {
    0%, 100% { transform: translate(0,0) scale(1); }
    33%       { transform: translate(25px,-25px) scale(1.08); }
    66%       { transform: translate(-15px,20px) scale(0.92); }
}

.auth-container {
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    max-width: 1000px;
    width: 100%;
}

.auth-card {
    background: rgba(8,8,8,0.9);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    backdrop-filter: blur(30px);
    box-shadow: var(--shadow-xl), 0 0 0 1px rgba(255,255,255,0.05);
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0.6;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.logo-large {
    width: 72px; height: 72px;
    margin: 0 auto 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-lg);
    font-size: 1.75rem;
    color: var(--primary);
    box-shadow: 0 0 30px var(--primary-glow);
}

.auth-header h1 {
    font-size: 1.75rem;
    font-weight: 800;
    margin-bottom: 0.4rem;
    color: var(--text-primary);
}

.auth-header p { color: var(--text-secondary); font-size: 0.9rem; }

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.auth-divider {
    position: relative;
    text-align: center;
    margin: 1.25rem 0;
}
.auth-divider::before {
    content: '';
    position: absolute;
    left: 0; top: 50%;
    width: 100%; height: 1px;
    background: var(--border-color);
}
.auth-divider span {
    position: relative;
    background: rgba(8,8,8,0.9);
    padding: 0 1rem;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.auth-footer { text-align: center; color: var(--text-secondary); font-size: 0.875rem; }
.auth-footer a { color: var(--primary); font-weight: 600; }
.auth-footer a:hover { text-decoration: underline; }

.back-home {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1.25rem;
    color: var(--text-muted);
    font-size: 0.82rem;
    transition: var(--transition);
}
.back-home:hover { color: var(--primary); }

.auth-info {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    justify-content: center;
}

.info-card {
    padding: 1.5rem;
    background: rgba(8,8,8,0.7);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(20px);
    transition: var(--transition);
}
.info-card:hover { border-color: var(--border-red); background: rgba(255,255,255,0.04); }
.info-card i { font-size: 1.75rem; color: var(--primary); margin-bottom: 0.75rem; display: block; }
.info-card h3 { font-size: 1rem; margin-bottom: 0.4rem; font-weight: 600; }
.info-card p { color: var(--text-secondary); font-size: 0.85rem; }

.welcome-bonus {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.875rem 1rem;
    background: rgba(0,230,118,0.06);
    border: 1px solid rgba(0,230,118,0.2);
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
}
.welcome-bonus i { font-size: 1.5rem; color: var(--success); flex-shrink: 0; }
.welcome-bonus strong { display: block; margin-bottom: 0.2rem; font-size: 0.9rem; }
.welcome-bonus span { font-size: 0.8rem; color: var(--text-secondary); }

/* ── Dashboard Layout ────────────────────────────────────── */
.dashboard-page {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 260px;
    min-height: 100vh;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    padding: 1.5rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    padding: 0.75rem 1.25rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: var(--transition);
    border-left: 2px solid transparent;
    position: relative;
}
.nav-item:hover { color: var(--text-primary); background: var(--bg-glass); }
.nav-item.active { color: var(--primary); background: var(--primary-dim); border-left-color: var(--primary); }
.nav-item i { width: 18px; font-size: 1rem; flex-shrink: 0; }

.badge {
    padding: 0.2rem 0.55rem;
    background: var(--primary);
    color: #000000;
    font-size: 0.65rem;
    font-weight: 800;
    border-radius: 50px;
    font-family: var(--font-mono);
    margin-left: auto;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 1.25rem;
    border-top: 1px solid var(--border-color);
}

.user-info { display: flex; align-items: center; gap: 0.85rem; }

.user-avatar {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary);
    flex-shrink: 0;
    box-shadow: 0 0 12px var(--primary-glow);
}
.user-avatar.admin { background: rgba(0,229,255,0.1); color: var(--cyan); border-color: var(--border-cyan); }

.user-avatar-small {
    width: 30px; height: 30px;
    border-radius: 50%;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    display: flex; align-items: center; justify-content: center;
    font-weight: 600; font-size: 0.8rem; color: var(--primary);
    flex-shrink: 0;
}

.user-name { font-size: 0.875rem; font-weight: 600; color: var(--text-primary); }
.user-role { font-size: 0.7rem; color: var(--text-muted); font-family: var(--font-mono); }

/* Main content */
.main-content {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    min-width: 0;
}

/* Page header */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}
.page-header h1 {
    font-size: 1.6rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.page-header h1 i { color: var(--primary); font-size: 1.4rem; }

.content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}
.content-header h1 { font-size: 1.75rem; font-weight: 800; margin-bottom: 0.3rem; }
.content-header p { color: var(--text-secondary); font-size: 0.9rem; }
.header-actions { display: flex; gap: 0.75rem; }

/* ── Stats Grid ──────────────────────────────────────────── */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1.5rem;
    background: rgba(8,8,8,0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(20px);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--cyan));
    opacity: 0;
    transition: opacity 0.3s;
}
.stat-card:hover { transform: translateY(-3px); border-color: var(--border-red); box-shadow: var(--shadow-red); }
.stat-card:hover::before { opacity: 1; }

.stat-icon {
    width: 56px; height: 56px;
    display: flex; align-items: center; justify-content: center;
    border-radius: var(--radius-lg);
    font-size: 1.5rem;
    color: #000000;
    flex-shrink: 0;
}

.stat-content { flex: 1; min-width: 0; }
.stat-label   { font-size: 0.78rem; color: var(--text-muted); margin-bottom: 0.2rem; font-family: var(--font-mono); letter-spacing: 0.5px; }
.stat-value   { font-size: 1.75rem; font-weight: 800; color: var(--text-primary); margin-bottom: 0.15rem; }
.stat-sub     { font-size: 0.72rem; color: var(--text-muted); }

.stat-change  { display: flex; align-items: center; gap: 0.25rem; font-size: 0.75rem; color: var(--text-muted); margin-top: 0.2rem; }
.stat-change.positive { color: var(--success); }
.stat-change.negative { color: var(--error); }

/* ── Cards ───────────────────────────────────────────────── */
.content-card, .card {
    background: rgba(8,8,8,0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(20px);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    background: rgba(255,255,255,0.015);
}
.card-header h2, .card-header h3 {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: var(--font-mono);
    letter-spacing: 0.3px;
}
.card-header h2 i, .card-header h3 i { color: var(--primary); font-size: 0.85rem; }
.card-actions { display: flex; gap: 0.75rem; }
.card-body { padding: 1.5rem; }

/* ── Tables ──────────────────────────────────────────────── */
.table-responsive { overflow-x: auto; }

.data-table, .table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.data-table th, .table th {
    text-align: left;
    padding: 0.65rem 0.875rem;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}
.data-table td, .table td {
    padding: 0.875rem 0.875rem;
    border-bottom: 1px solid rgba(255,255,255,0.03);
    color: var(--text-primary);
    vertical-align: middle;
}
.data-table tbody tr:last-child td,
.table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr, .table tbody tr { transition: background 0.15s; }
.data-table tbody tr:hover, .table tbody tr:hover { background: var(--bg-glass); }

/* ── Badges ──────────────────────────────────────────────── */
.status-badge, .role-badge, .badge-sm {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.65rem;
    border-radius: 50px;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.status-active   { background: var(--success-dim); color: var(--success); border: 1px solid rgba(0,230,118,0.2); }
.status-inactive { background: rgba(239,68,68,0.1); color: #ef4444; border: 1px solid rgba(239,68,68,0.2); }
.status-pending  { background: var(--amber-dim); color: var(--amber); border: 1px solid rgba(255,184,0,0.2); }
.status-expired  { background: rgba(100,100,100,0.1); color: var(--text-muted); border: 1px solid var(--border-color); }

.role-badge.admin    { background: var(--primary-dim); color: var(--primary); border: 1px solid var(--border-red); }
.role-badge.user     { background: var(--cyan-dim); color: var(--cyan); border: 1px solid var(--border-cyan); }
.role-badge.reseller { background: var(--amber-dim); color: var(--amber); border: 1px solid rgba(255,184,0,0.25); }

.badge-success { background: var(--success-dim); color: var(--success); border: 1px solid rgba(0,230,118,0.2); }
.badge-primary { background: var(--primary-dim); color: var(--primary); border: 1px solid var(--border-red); }

/* ── UID code inline ─────────────────────────────────────── */
.uid-code {
    padding: 0.2rem 0.55rem;
    background: var(--cyan-dim);
    border: 1px solid var(--border-cyan);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--cyan);
    white-space: nowrap;
}

/* ── Action Buttons Row ──────────────────────────────────── */
.action-buttons { display: flex; gap: 0.4rem; }

.user-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* ── Empty State ─────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
}
.empty-state i { font-size: 2.5rem; color: var(--text-muted); opacity: 0.3; margin-bottom: 1rem; display: block; }
.empty-state h3 { font-size: 1.1rem; margin-bottom: 0.5rem; }
.empty-state p { color: var(--text-secondary); margin-bottom: 1.5rem; font-size: 0.9rem; }

/* ── Modal ───────────────────────────────────────────────── */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 2rem;
}
.modal.active { display: flex; }

.modal-content {
    background: rgba(8,8,8,0.97);
    border: 1px solid var(--border-color);
    border-top: 1px solid var(--border-red);
    border-radius: var(--radius-xl);
    max-width: 520px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl), 0 0 40px var(--primary-glow);
    animation: modalIn 0.25s cubic-bezier(0.34,1.56,0.64,1);
}

@keyframes modalIn {
    from { transform: scale(0.92) translateY(20px); opacity: 0; }
    to   { transform: scale(1) translateY(0); opacity: 1; }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}
.modal-header h2 { font-size: 1.15rem; font-weight: 700; }
.modal-close { background: transparent; color: var(--text-muted); padding: 0.35rem; transition: var(--transition); }
.modal-close:hover { color: var(--primary); }
.modal-form { padding: 1.5rem; }
.modal-actions { display: flex; gap: 0.75rem; margin-top: 1.5rem; }

.cost-summary {
    padding: 1rem;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-md);
    margin: 1rem 0;
}
.cost-item { display: flex; justify-content: space-between; padding: 0.4rem 0; font-size: 0.875rem; }

/* ── Transaction list ────────────────────────────────────── */
.transaction-list { display: flex; flex-direction: column; gap: 0.75rem; }
.transaction-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: var(--transition);
}
.transaction-item:hover { border-color: var(--border-red); background: var(--primary-dim); }

.transaction-icon {
    width: 40px; height: 40px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}
.transaction-icon.credit { background: var(--success-dim); color: var(--success); }
.transaction-icon.debit  { background: rgba(239,68,68,0.1); color: #ef4444; }

.transaction-details { flex: 1; }
.transaction-description { font-weight: 500; font-size: 0.875rem; margin-bottom: 0.2rem; }
.transaction-date { font-size: 0.72rem; color: var(--text-muted); font-family: var(--font-mono); }
.transaction-amount { font-weight: 700; }
.transaction-amount.positive { color: var(--success); }
.transaction-amount.negative { color: #ef4444; }

.transaction-type {
    display: inline-flex; align-items: center; gap: 0.3rem;
    padding: 0.2rem 0.6rem; border-radius: 50px;
    font-size: 0.65rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.5px;
}
.transaction-type.credit { background: var(--success-dim); color: var(--success); }
.transaction-type.debit  { background: rgba(239,68,68,0.1); color: #ef4444; }

/* ── Credits Page ────────────────────────────────────────── */
.credit-banner {
    padding: 2.5rem;
    background: linear-gradient(135deg, rgba(255,255,255,0.12) 0%, rgba(0,0,0,0) 60%),
                rgba(8,8,8,0.9);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-xl);
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}
.credit-banner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--cyan));
}
.credit-banner-content { display: flex; align-items: center; justify-content: space-between; }
.credit-label { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 0.5rem; font-family: var(--font-mono); letter-spacing: 0.5px; text-transform: uppercase; }
.credit-amount { font-size: 3.5rem; font-weight: 800; color: var(--text-primary); }
.credit-amount span { font-size: 1.25rem; font-weight: 500; color: var(--text-muted); }
.credit-visual i { font-size: 5rem; color: var(--primary); opacity: 0.15; }

.pricing-grid-dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 1.25rem;
}

.pricing-card-dashboard {
    position: relative;
    padding: 1.5rem;
    background: rgba(8,8,8,0.85);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    transition: var(--transition);
    cursor: pointer;
}
.pricing-card-dashboard:hover {
    transform: translateY(-4px);
    border-color: var(--border-red);
    box-shadow: var(--shadow-red);
}
.pricing-card-dashboard.featured {
    border-color: var(--border-red);
    box-shadow: var(--shadow-red);
}

.popular-badge-small {
    position: absolute;
    top: -10px; right: 1rem;
    background: var(--primary);
    color: #000000;
    padding: 0.2rem 0.65rem;
    border-radius: var(--radius-md);
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    box-shadow: 0 0 10px var(--primary-glow);
}

.package-header { text-align: center; margin-bottom: 1rem; }
.package-header h3 { font-size: 1rem; margin-bottom: 0.5rem; font-weight: 700; }

.package-price {
    display: flex; align-items: flex-start; justify-content: center; gap: 0.15rem;
}
.package-price .currency { font-size: 1rem; color: var(--text-muted); margin-top: 0.3rem; }
.package-price .amount { font-size: 2.25rem; font-weight: 800; color: var(--text-primary); line-height: 1; }

.package-credits, .package-duration {
    display: flex; align-items: center; justify-content: center;
    gap: 0.4rem; padding: 0.4rem;
    font-size: 0.8rem; color: var(--text-secondary);
}

.package-value {
    text-align: center;
    padding: 0.6rem;
    margin: 0.75rem 0;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-md);
    font-size: 0.72rem;
    color: var(--primary);
    font-family: var(--font-mono);
}

/* ── Info grid ───────────────────────────────────────────── */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem;
}
.info-card-small {
    display: flex; align-items: center; gap: 1rem;
    padding: 1.1rem;
    background: var(--bg-glass);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    backdrop-filter: blur(20px);
    transition: var(--transition);
}
.info-card-small:hover { border-color: var(--border-red); background: var(--primary-dim); }
.info-card-small i { font-size: 1.75rem; color: var(--primary); flex-shrink: 0; }
.info-card-small strong { display: block; margin-bottom: 0.2rem; font-size: 0.9rem; }
.info-card-small p { font-size: 0.8rem; color: var(--text-secondary); }

/* ── Logo (navbar) ───────────────────────────────────────── */
.logo {
    display: flex; align-items: center; gap: 0.75rem;
    font-size: 1.2rem; font-weight: 800;
}
.logo i { color: var(--primary); font-size: 1.3rem; }
.pro-badge {
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    padding: 0.1rem 0.45rem;
    border-radius: var(--radius-sm);
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--primary);
    font-family: var(--font-mono);
}

/* ── Landing page (navbar, hero, features, pricing, footer) ─ */
.landing-page { min-height: 100vh; }

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.hero-background { position: absolute; inset: 0; z-index: 0; }

.navbar { position: relative; z-index: 10; padding: 1.5rem 0; }
.nav-content { display: flex; align-items: center; justify-content: space-between; }
.nav-links { display: flex; align-items: center; gap: 2rem; }
.nav-link { color: var(--text-muted); font-weight: 500; transition: var(--transition); font-size: 0.9rem; }
.nav-link:hover { color: var(--primary); }

.hero-content {
    position: relative; z-index: 10;
    flex: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    padding: 4rem 0;
}
.hero-title { font-size: 3.5rem; font-weight: 800; line-height: 1.1; margin-bottom: 1.5rem; }
.hero-subtitle { font-size: 1.15rem; color: var(--text-secondary); margin-bottom: 2rem; line-height: 1.7; }
.hero-cta { display: flex; gap: 1rem; margin-bottom: 3rem; }
.hero-stats { display: flex; gap: 3rem; }
.stat-item { text-align: center; }
.stat-value { font-size: 2rem; font-weight: 700; color: var(--primary); }
.stat-label { font-size: 0.8rem; color: var(--text-muted); }

/* Dashboard Preview card */
.dashboard-preview {
    background: rgba(8,8,8,0.85);
    border: 1px solid var(--border-color);
    border-top: 1px solid var(--border-red);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-xl);
}
.preview-header { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1.5rem; }
.preview-dots { display: flex; gap: 0.5rem; }
.preview-dots span { width: 11px; height: 11px; border-radius: 50%; background: var(--bg-tertiary); }
.preview-dots span:first-child { background: #ef4444; }
.preview-dots span:nth-child(2) { background: var(--amber); }
.preview-dots span:last-child { background: var(--success); }
.preview-content { display: flex; flex-direction: column; gap: 0.75rem; }
.preview-card {
    display: flex; align-items: center; gap: 1rem; padding: 0.875rem 1rem;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-md);
    transition: var(--transition);
}
.preview-card:hover { background: rgba(255,255,255,0.1); }
.preview-card i { font-size: 1.25rem; color: var(--primary); flex-shrink: 0; }
.preview-text { display: flex; flex-direction: column; gap: 0.15rem; }
.preview-text strong { font-weight: 600; font-size: 0.9rem; }
.preview-text span { font-size: 0.72rem; color: var(--text-muted); }

.preview-footer { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border-color); }
.activity-indicator { display: flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; color: var(--text-secondary); }
.activity-dot { width: 6px; height: 6px; background: var(--success); border-radius: 50%; animation: blink 2s ease-in-out infinite; }
@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }
.activity-text { font-weight: 500; }

/* Features Section */
.features-section { padding: 8rem 0; position: relative; }
.section-header { text-align: center; margin-bottom: 4rem; }
.section-title { font-size: 2.5rem; font-weight: 800; margin-bottom: 1rem; }
.section-subtitle { font-size: 1.1rem; color: var(--text-secondary); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.feature-card {
    padding: 2rem;
    background: rgba(8,8,8,0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(20px);
    transition: var(--transition);
}
.feature-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-red);
    box-shadow: var(--shadow-red);
}
.feature-icon {
    width: 56px; height: 56px;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: var(--radius-lg);
    font-size: 1.4rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    box-shadow: 0 0 20px var(--primary-glow);
}
.feature-title { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.75rem; }
.feature-description { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.7; }

/* Pricing Section */
.pricing-section { padding: 8rem 0; background: var(--bg-secondary); }
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.pricing-card {
    position: relative; padding: 2.5rem;
    background: rgba(8,8,8,0.9);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(20px);
    transition: var(--transition);
}
.pricing-card.featured { border-color: var(--border-red); box-shadow: var(--shadow-red); transform: scale(1.03); }
.pricing-card:hover { transform: translateY(-6px) scale(1.01); box-shadow: var(--shadow-red); }
.popular-badge {
    position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
    background: var(--primary); color: #000000;
    padding: 0.3rem 1rem; border-radius: var(--radius-md);
    font-size: 0.7rem; font-weight: 800; letter-spacing: 0.5px;
    box-shadow: 0 0 15px var(--primary-glow);
}
.pricing-header { text-align: center; margin-bottom: 2rem; }
.pricing-name { font-size: 1.4rem; font-weight: 800; margin-bottom: 1rem; }
.pricing-price { display: flex; align-items: flex-start; justify-content: center; gap: 0.2rem; margin-bottom: 0.4rem; }
.currency { font-size: 1.4rem; font-weight: 600; color: var(--text-muted); margin-top: 0.4rem; }
.amount { font-size: 3.25rem; font-weight: 800; line-height: 1; }
.pricing-credits { color: var(--primary); font-weight: 700; font-size: 0.9rem; }
.pricing-features { list-style: none; margin-bottom: 2rem; }
.pricing-features li {
    display: flex; align-items: center; gap: 0.75rem;
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}
.pricing-features li:last-child { border-bottom: none; }
.pricing-features i { color: var(--success); font-size: 0.85rem; }

/* Footer */
.footer {
    padding: 4rem 0 2rem;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}
.footer-content { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 4rem; margin-bottom: 3rem; }
.footer-brand p { color: var(--text-secondary); margin-top: 1rem; font-size: 0.9rem; }
.footer-column h4 { margin-bottom: 1rem; font-size: 0.95rem; font-weight: 700; }
.footer-column a { display: block; color: var(--text-secondary); margin-bottom: 0.65rem; font-size: 0.875rem; transition: var(--transition); }
.footer-column a:hover { color: var(--primary); }
.footer-bottom {
    text-align: center; padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted); font-size: 0.85rem;
}

/* ── Live Badges ─────────────────────────────────────────── */
.live-badge {
    display: flex; align-items: center; gap: 0.5rem;
    padding: 0.3rem 0.75rem;
    background: var(--success-dim);
    border: 1px solid rgba(0,230,118,0.3);
    border-radius: 50px;
    font-size: 0.65rem; font-weight: 700; letter-spacing: 0.5px;
    color: var(--success);
    font-family: var(--font-mono);
}
.pulse-dot, .activity-dot {
    width: 6px; height: 6px;
    background: var(--success);
    border-radius: 50%;
    animation: pulseDot 2s ease-in-out infinite;
}
@keyframes pulseDot {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0,230,118,0.7); }
    50%       { box-shadow: 0 0 0 5px rgba(0,230,118,0); }
}

/* Stat icon small */
.stat-icon-small {
    width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
    background: var(--primary-dim);
    border: 1px solid var(--border-red);
    border-radius: 50%;
    font-size: 0.875rem;
    color: var(--primary);
    margin: 0 auto 0.5rem;
}
.stat-icon-small.live-indicator {
    background: var(--success);
    border-color: var(--success);
    color: black;
    box-shadow: 0 0 12px rgba(0,230,118,0.4);
    animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.1); opacity: 0.8; } }

/* ── Mobile header ───────────────────────────────────────── */
.mobile-header {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 0.875rem 1.25rem;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 999;
}
.menu-toggle {
    background: transparent; color: var(--text-primary);
    font-size: 1.25rem; padding: 0.5rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.menu-toggle:hover { background: var(--primary-dim); color: var(--primary); }

.sidebar-overlay {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    z-index: 900; opacity: 0;
    transition: opacity 0.3s ease;
}
.sidebar-overlay.active { display: block; opacity: 1; z-index: 999; }

body.sidebar-open { overflow: hidden; position: fixed; width: 100%; }

/* ── Dropdown / select theme ─────────────────────────────── */
select option { background: #111; color: var(--text-primary); }

/* ── Ticket & page-specific cards ───────────────────────── */
.tier-banner {
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    display: flex; align-items: center; justify-content: space-between; gap: 1rem;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--primary-dim) 0%, rgba(0,229,255,0.04) 100%);
    border: 1px solid var(--border-red);
    position: relative; overflow: hidden;
}
.tier-banner::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, var(--primary), var(--cyan));
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 1100px) {
    .content-grid { grid-template-columns: 1fr; }
}

@media (max-width: 1024px) {
    .hero-content { grid-template-columns: 1fr; }
    .hero-visual { display: none; }
    .auth-container { grid-template-columns: 1fr; }
    .auth-info { display: none; }
    .footer-content { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

@media (max-width: 768px) {
    .container { padding: 0 1rem; }

    .flash-container { top: 1rem; right: 1rem; left: 1rem; max-width: none; }
    .flash-message { min-width: auto; width: 100%; }

    .hero-content { grid-template-columns: 1fr; gap: 2rem; padding: 2rem 0; }
    .hero-title { font-size: 2.25rem; }
    .hero-subtitle { font-size: 1rem; }
    .hero-cta { flex-direction: column; }
    .hero-stats { gap: 1.5rem; }

    .auth-container { grid-template-columns: 1fr; gap: 1.5rem; }
    .auth-info { display: none; }
    .auth-card { padding: 1.75rem 1.25rem; }

    .dashboard-page { flex-direction: column; }
    .sidebar {
        position: fixed;
        left: -280px; top: 0;
        height: 100vh; width: 270px;
        transition: left 0.3s ease;
        z-index: 1000;
    }
    .sidebar.active { left: 0; z-index: 1001; }
    .main-content { margin-left: 0; width: 100%; padding: 1rem; margin-top: 60px; }
    .mobile-header { display: flex !important; }

    .stats-grid { grid-template-columns: 1fr 1fr; gap: 0.75rem; }
    .content-grid, .pricing-grid, .pricing-grid-dashboard { grid-template-columns: 1fr; }
    .pricing-card.featured { transform: scale(1); }
    .features-grid { grid-template-columns: 1fr; }
    .footer-content { grid-template-columns: 1fr; gap: 1.5rem; }
    .nav-links { display: none; }
    .data-table { min-width: 600px; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 1.9rem; }
    .amount { font-size: 2.5rem; }
    .stats-grid { grid-template-columns: 1fr; }
}