/* NitroFiveM Dashboard - Mobile First */
* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --bg-dark: #0f0f0f;
    --bg-card: #1a1a1a;
    --bg-card-hover: #222;
    --text-primary: #ffffff;
    --text-secondary: #888;
    --blue: #3b82f6;
    --green: #10b981;
    --purple: #8b5cf6;
    --orange: #f59e0b;
    --pink: #ec4899;
    --teal: #14b8a6;
    --red: #ef4444;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    padding-top: 60px;
}

/* Mobile Header */
.mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: var(--bg-card);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    z-index: 1000;
    border-bottom: 1px solid #333;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--blue);
}

.menu-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 8px;
}

/* Mobile Nav */
.mobile-nav {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--bg-card);
    display: none;
    flex-direction: column;
    z-index: 999;
    border-bottom: 1px solid #333;
}

.mobile-nav.open { display: flex; }

.mobile-nav a {
    padding: 16px 20px;
    color: var(--text-primary);
    text-decoration: none;
    border-bottom: 1px solid #222;
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-nav a:hover { background: var(--bg-card-hover); }

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 16px;
}

/* Section */
.section {
    margin-bottom: 32px;
}

.section-title {
    font-size: 1.25rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-primary);
}

.section-header {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
}

.stat-icon {
    font-size: 1.5rem;
    margin-bottom: 8px;
}

.stat-card.blue .stat-icon { color: var(--blue); }
.stat-card.green .stat-icon { color: var(--green); }
.stat-card.purple .stat-icon { color: var(--purple); }
.stat-card.orange .stat-icon { color: var(--orange); }
.stat-card.pink .stat-icon { color: var(--pink); }
.stat-card.teal .stat-icon { color: var(--teal); }

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

.stat-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Charts Grid */
.charts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.chart-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
}

.chart-card h3 {
    font-size: 0.9rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

/* Search Box */
.search-box {
    position: relative;
    width: 100%;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

.search-box input {
    width: 100%;
    padding: 12px 12px 12px 40px;
    background: var(--bg-card);
    border: 1px solid #333;
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
}

.search-box input:focus {
    outline: none;
    border-color: var(--blue);
}

/* Users Grid */
.users-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

/* User Card */
.user-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 16px;
    overflow: hidden;
}

.user-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid #333;
}

.user-id {
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--blue);
    display: flex;
    align-items: center;
    gap: 6px;
}

.user-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.vpn-badge {
    background: var(--purple);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

.sessions-badge {
    background: var(--green);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
}

.delete-btn {
    background: var(--red);
    border: none;
    color: white;
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
}

.delete-btn:hover { opacity: 0.8; }

/* User Info Grid */
.user-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 12px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    padding: 6px 0;
    color: var(--text-secondary);
}

.info-item i {
    color: var(--blue);
    width: 16px;
    text-align: center;
}

.info-item span {
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.info-item.full-width {
    grid-column: span 2;
}

/* Disks Section */
.disks-section {
    background: #111;
    border-radius: 8px;
    padding: 12px;
    margin-top: 12px;
}

.disks-title {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.disks-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.disk-item {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0.75rem;
    padding: 6px;
    background: var(--bg-card);
    border-radius: 4px;
}

.disk-name {
    color: var(--text-primary);
    font-weight: 500;
}

.disk-type {
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 600;
}

.disk-type.ssd { background: var(--green); color: white; }
.disk-type.hdd { background: var(--orange); color: white; }
.disk-type.nvme { background: var(--blue); color: white; }

.disk-size { color: var(--text-secondary); }
.disk-free { color: var(--green); }

/* User Footer */
.user-footer {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #333;
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* Admin */
.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn {
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

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

.btn-danger:hover { opacity: 0.8; }

/* Footer */
.footer {
    text-align: center;
    padding: 24px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Loading */
.loading {
    text-align: center;
    padding: 32px;
    color: var(--text-secondary);
}

/* Toast */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--bg-card);
    padding: 12px 24px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 9999;
    transition: transform 0.3s;
    border: 1px solid #333;
}

.toast.show { transform: translateX(-50%) translateY(0); }
.toast.success { border-color: var(--green); }
.toast.success i { color: var(--green); }
.toast.error { border-color: var(--red); }
.toast.error i { color: var(--red); }

/* Tablet */
@media (min-width: 640px) {
    .stats-grid { grid-template-columns: repeat(3, 1fr); }
    .charts-grid { grid-template-columns: repeat(2, 1fr); }
    .users-grid { grid-template-columns: repeat(2, 1fr); }
    .section-header { flex-direction: row; justify-content: space-between; align-items: center; }
    .search-box { width: 300px; }
}

/* Desktop */
@media (min-width: 1024px) {
    body { padding-top: 0; }
    
    .mobile-header { display: none; }
    .mobile-nav {
        display: flex !important;
        position: static;
        flex-direction: row;
        justify-content: center;
        padding: 16px;
        border-bottom: 1px solid #333;
        gap: 24px;
    }
    .mobile-nav a {
        padding: 8px 16px;
        border: none;
        border-radius: 8px;
    }
    .mobile-nav a:hover { background: var(--blue); }
    
    .container { padding: 24px; }
    .stats-grid { grid-template-columns: repeat(6, 1fr); }
    .charts-grid { grid-template-columns: repeat(3, 1fr); }
    .users-grid { grid-template-columns: repeat(3, 1fr); }
    
    .stat-card { padding: 20px; }
    .stat-value { font-size: 2rem; }
    .stat-label { font-size: 0.85rem; }
}

@media (min-width: 1280px) {
    .users-grid { grid-template-columns: repeat(4, 1fr); }
}
