@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --bg-main: #050505;
    --bg-sidebar: rgba(10, 10, 10, 0.8);
    --bg-card: rgba(18, 18, 18, 0.7);
    --bg-card-hover: rgba(25, 25, 25, 0.8);
    --border-color: rgba(255, 255, 255, 0.05);
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --primary-glow: rgba(99, 102, 241, 0.2);
    --text-main: #ffffff;
    --text-muted: #8e9196;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --sidebar-width: 280px;
    --header-height: 80px;
    --radius: 16px;
    --glass-bg: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.05);
}

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

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(99, 102, 241, 0.03) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(168, 85, 247, 0.03) 0%, transparent 40%);
    background-attachment: fixed;
}

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

/* Sidebar */
aside.sidebar {
    width: var(--sidebar-width);
    background-color: var(--bg-sidebar);
    backdrop-filter: blur(20px);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    padding: 32px 20px;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 48px;
    padding: 0 12px;
    letter-spacing: -0.5px;
}

.logo i {
    color: var(--primary);
    filter: drop-shadow(0 0 8px var(--primary-glow));
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    text-decoration: none;
    color: var(--text-muted);
    border-radius: var(--radius);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    margin-bottom: 4px;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.03);
    color: #fff;
    transform: translateX(4px);
}

.nav-link.active {
    background-color: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    box-shadow: inset 0 0 0 1px rgba(99, 102, 241, 0.2);
}

/* Main Content */
main.content {
    flex-grow: 1;
    margin-left: var(--sidebar-width);
    padding: 32px;
}

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

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), #a855f7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

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

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    padding: 24px;
    border-radius: var(--radius);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, transparent 100%);
    pointer-events: none;
}

.stat-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.15);
    background: var(--bg-card-hover);
    box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.5);
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
}

/* Tables & Cards */
.card {
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.2);
}

th {
    text-align: left;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 16px;
    border-bottom: 1px solid var(--border-color);
}

td {
    padding: 20px 16px;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.9);
}

tr:hover td {
    background: rgba(255, 255, 255, 0.01);
}

tr:last-child td {
    border-bottom: none;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-active { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.status-expired { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.status-banned { background: rgba(244, 63, 94, 0.1); color: var(--danger); }

/* Buttons */
.btn {
    padding: 10px 20px;
    border-radius: var(--radius);
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-hover);
}

.btn-outline {
    background-color: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-main);
}

.btn-outline:hover {
    background-color: var(--bg-card-hover);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8125rem;
}

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

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    width: 100%;
    max-width: 500px;
    border-radius: var(--radius);
    padding: 32px;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

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

input, select {
    width: 100%;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    padding: 12px 16px;
    border-radius: var(--radius);
    color: var(--text-main);
    outline: none;
}

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

/* Charts Placeholder */
.chart-container {
    height: 300px;
    display: flex;
    align-items: flex-end;
    gap: 12px;
    padding: 20px;
}

.bar {
    flex: 1;
    background: linear-gradient(to top, var(--primary), #a855f7);
    border-radius: 4px 4px 0 0;
    min-height: 20px;
}

/* Login Page - Modern Split Layout */
.login-split-container {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

.login-onboarding {
    flex: 1.2;
    background: radial-gradient(circle at top left, #1a1a2e, #0a0a0a);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 80px;
    position: relative;
    overflow: hidden;
}

.login-onboarding::before {
    content: '';
    position: absolute;
    top: -10%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    filter: blur(40px);
}

.onboarding-content {
    position: relative;
    z-index: 10;
    max-width: 500px;
}

.onboarding-title {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 24px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.feature-list {
    list-style: none;
    margin-top: 40px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    color: var(--text-muted);
}

.feature-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.login-form-side {
    flex: 1;
    background: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.login-card-modern {
    width: 100%;
    max-width: 420px;
}

.input-modern {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    padding: 14px 18px;
    border-radius: 12px;
    width: 100%;
    color: #fff;
    transition: all 0.2s;
}

.input-modern:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.btn-login {
    background: var(--primary);
    color: white;
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-login:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -10px rgba(99, 102, 241, 0.5);
}

@media (max-width: 900px) {
    .login-onboarding {
        display: none;
    }
}

/* Layout & Typography */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1.8fr 1.2fr;
    gap: 24px;
}

.page-title {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    margin-bottom: 4px;
}

.page-subtitle {
    color: var(--text-muted);
    font-size: 0.9375rem;
}


/* Responsive */
@media (max-width: 1024px) {
    aside.sidebar {
        width: 80px;
        padding: 16px;
    }
    .logo span, .nav-link span {
        display: none;
    }
    main.content {
        margin-left: 80px;
    }
}
