:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --danger: #ef4444;
    --success: #22c55e;
    --warning: #f59e0b;
    --bg-dark: #0f172a;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(239, 68, 68, 0.1) 0px, transparent 50%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
}

.glass-container {
    background: var(--glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2.5rem;
    width: 100%;
    max-width: 900px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin: 1rem;
}

/* LOGIN SPECIFIC */
.login-container {
    max-width: 450px;
}

header {
    text-align: center;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

header h1 span {
    color: var(--primary);
}

.badge {
    display: inline-block;
    padding: 0.4rem 1rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge.connected { background: rgba(34, 197, 94, 0.2); color: var(--success); }
.badge.qr { background: rgba(245, 158, 11, 0.2); color: var(--warning); }
.badge.loading, .badge.reconnecting { background: rgba(99, 102, 241, 0.2); color: var(--primary); }
.badge.disconnected { background: rgba(239, 68, 68, 0.2); color: var(--danger); }

/* TAB SYSTEM */
.tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 0.5rem;
}

.tab-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    padding: 0.5rem 1rem;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
    font-size: 0.9rem;
}

.tab-btn.active {
    color: white;
    border-bottom: 2px solid var(--primary);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease-in-out;
}

/* CARDS & SECTIONS */
.qr-section {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    width: fit-content;
    margin: 0 auto 2rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2);
}

.stat-card {
    background: rgba(255, 255, 255, 0.03);
    padding: 1.5rem;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    margin-bottom: 1.5rem;
}

.stat-card h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
}

/* FORMS */
.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    padding: 0.8rem 1rem;
    border-radius: 12px;
    color: white;
    outline: none;
    transition: border-color 0.3s;
}

input:focus {
    border-color: var(--primary);
}

.btn {
    width: 100%;
    padding: 0.8rem;
    border-radius: 12px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
}

.btn.primary { background: var(--primary); color: white; }
.btn.primary:hover { background: var(--primary-dark); transform: translateY(-2px); }

.btn.secondary { background: rgba(255, 255, 255, 0.05); color: white; border: 1px solid var(--glass-border); }
.btn.secondary:hover { background: rgba(255, 255, 255, 0.1); }

.btn.danger { background: rgba(239, 68, 68, 0.1); color: var(--danger); border: 1px solid rgba(239, 68, 68, 0.2); }
.btn.danger:hover { background: rgba(239, 68, 68, 0.2); }

/* TABLES */
.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

th {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

td {
    font-size: 0.9rem;
}

.actions-row {
    display: flex;
    gap: 0.5rem;
}

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

@media (max-width: 640px) {
    .glass-container { padding: 1.5rem; }
    .tabs { flex-direction: column; gap: 0.2rem; }
}
