/* ============================================
   assets/css/style.css - Custom Styles
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
    --primary:       #2563eb;
    --primary-dark:  #1d4ed8;
    --primary-light: #dbeafe;
    --secondary:     #64748b;
    --success:       #16a34a;
    --warning:       #d97706;
    --danger:        #dc2626;
    --info:          #0891b2;
    --bg-main:       #f1f5f9;
    --bg-card:       #ffffff;
    --sidebar-bg:    #0f172a;
    --sidebar-text:  #94a3b8;
    --sidebar-hover: #1e293b;
    --sidebar-active:#2563eb;
    --text-main:     #1e293b;
    --text-muted:    #64748b;
    --border:        #e2e8f0;
    --radius:        12px;
    --shadow:        0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md:     0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg:     0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

* { box-sizing: border-box; }

body {
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: var(--bg-main);
    color: var(--text-main);
    font-size: 14px;
    min-height: 100vh;
}

/* ── SIDEBAR ──────────────────────────────── */
.sidebar {
    width: 260px;
    min-height: 100vh;
    background: var(--sidebar-bg);
    position: fixed;
    top: 0; left: 0;
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform .3s ease;
}

.sidebar-brand {
    padding: 24px 20px 20px;
    border-bottom: 1px solid #1e293b;
}

.sidebar-brand .brand-logo {
    width: 38px; height: 38px;
    background: var(--primary);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px; margin-bottom: 8px;
}

.sidebar-brand h5 {
    color: #fff;
    font-weight: 700;
    font-size: 16px;
    margin: 0;
    line-height: 1.2;
}

.sidebar-brand span {
    color: var(--sidebar-text);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.sidebar-nav { padding: 12px 0; flex: 1; }

.nav-label {
    color: #475569;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    padding: 12px 20px 4px;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--sidebar-text);
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 8px;
    margin: 2px 8px;
    font-weight: 500;
    font-size: 13.5px;
    transition: all .2s;
}

.sidebar-nav a i { width: 18px; font-size: 15px; }

.sidebar-nav a:hover {
    background: var(--sidebar-hover);
    color: #fff;
}

.sidebar-nav a.active {
    background: var(--primary);
    color: #fff;
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid #1e293b;
}

.sidebar-footer .user-info {
    display: flex; align-items: center; gap: 10px;
    padding: 10px 12px;
    background: #1e293b;
    border-radius: 10px;
    margin-bottom: 8px;
}

.sidebar-footer .avatar {
    width: 32px; height: 32px;
    background: var(--primary);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 700; font-size: 13px;
}

.sidebar-footer .user-name { color: #fff; font-weight: 600; font-size: 13px; }
.sidebar-footer .user-role { color: var(--sidebar-text); font-size: 11px; }

.sidebar-footer a.logout-btn {
    display: flex; align-items: center; gap: 8px;
    color: #f87171;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    transition: background .2s;
}

.sidebar-footer a.logout-btn:hover { background: #7f1d1d22; }

/* ── MAIN CONTENT ─────────────────────────── */
.main-content {
    margin-left: 260px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.topbar {
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky; top: 0; z-index: 50;
}

.topbar-title h4 {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    color: var(--text-main);
}

.topbar-title p {
    font-size: 12px;
    color: var(--text-muted);
    margin: 0;
}

.content-area { padding: 28px; flex: 1; }

/* ── CARDS ────────────────────────────────── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-header h6 {
    font-weight: 700;
    font-size: 14px;
    color: var(--text-main);
    margin: 0;
}

.card-body { padding: 20px; }

/* ── STAT CARDS ───────────────────────────── */
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow);
    transition: box-shadow .2s, transform .2s;
}

.stat-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.stat-icon {
    width: 52px; height: 52px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px; flex-shrink: 0;
}

.stat-icon.blue   { background: #dbeafe; color: #2563eb; }
.stat-icon.green  { background: #dcfce7; color: #16a34a; }
.stat-icon.yellow { background: #fef3c7; color: #d97706; }
.stat-icon.red    { background: #fee2e2; color: #dc2626; }
.stat-icon.cyan   { background: #cffafe; color: #0891b2; }
.stat-icon.purple { background: #ede9fe; color: #7c3aed; }

.stat-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.stat-value {
    font-size: 28px;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
    margin-top: 4px;
}

/* ── BADGES ───────────────────────────────── */
.badge-status {
    display: inline-flex; align-items: center;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 600;
    gap: 5px;
}

.badge-status::before {
    content: '';
    width: 6px; height: 6px;
    border-radius: 50%;
    background: currentColor;
    display: inline-block;
}

.badge-pending   { background: #fef3c7; color: #92400e; }
.badge-approved  { background: #dcfce7; color: #14532d; }
.badge-selesai   { background: #e0e7ff; color: #3730a3; }
.badge-ditolak   { background: #fee2e2; color: #991b1b; }
.badge-tersedia  { background: #dcfce7; color: #14532d; }
.badge-dipakai   { background: #fef3c7; color: #92400e; }
.badge-maintenance { background: #fee2e2; color: #991b1b; }
.badge-reguler   { background: #e0e7ff; color: #3730a3; }
.badge-vip       { background: #fef3c7; color: #92400e; }

/* ── BUTTONS ──────────────────────────────── */
.btn {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-weight: 600;
    border-radius: 8px;
    font-size: 13.5px;
    padding: 8px 16px;
    transition: all .2s;
}

.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

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

.btn-sm { padding: 5px 11px; font-size: 12px; }

/* ── TABLES ───────────────────────────────── */
.table { font-size: 13.5px; }
.table th {
    font-weight: 700;
    font-size: 11.5px;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: var(--text-muted);
    border-bottom: 2px solid var(--border);
    background: #f8fafc;
    padding: 12px 16px;
}
.table td { padding: 12px 16px; vertical-align: middle; }
.table tbody tr:hover { background: #f8fafc; }

/* ── FORMS ────────────────────────────────── */
.form-control, .form-select {
    border-radius: 8px;
    border: 1.5px solid var(--border);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 14px;
    padding: 10px 14px;
    transition: border-color .2s, box-shadow .2s;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .15);
}

.form-label {
    font-weight: 600;
    font-size: 13px;
    color: var(--text-main);
    margin-bottom: 6px;
}

/* ── AUTH PAGES ───────────────────────────── */
.auth-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #0f172a 100%);
    display: flex; align-items: center; justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.auth-wrapper::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(ellipse at 20% 50%, rgba(37,99,235,.15) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 20%, rgba(99,102,241,.1) 0%, transparent 40%);
}

.auth-card {
    background: #fff;
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 420px;
    position: relative;
    z-index: 1;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,.4);
}

.auth-logo {
    width: 52px; height: 52px;
    background: var(--primary);
    border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px;
    color: #fff;
    margin: 0 auto 16px;
}

.auth-kick {


    padding: 5px 10px;
    border-radius: 999px;
    display: flex;  
    justify-content: center;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.admin-auth-card {
    border-top: 4px solid var(--primary);
}

.admin-auth-logo {
    background: #0f172a;
    box-shadow: 0 10px 22px rgba(15, 23, 42, .22);
}


.auth-card h3 {
    font-size: 22px;
    font-weight: 800;
    color: var(--text-main);
    text-align: center;
    margin-bottom: 4px;
}

.auth-card .sub {
    text-align: center;
    color: var(--text-muted);
    font-size: 13.5px;
    margin-bottom: 28px;
}

/* ── PC GRID ──────────────────────────────── */
.pc-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 12px;
}

.pc-card {
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 16px 12px;
    text-align: center;
    cursor: pointer;
    transition: all .2s;
    background: #fff;
}

.pc-card:hover:not(.disabled) {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37,99,235,.1);
    transform: translateY(-2px);
}

.pc-card.selected {
    border-color: var(--primary);
    background: var(--primary-light);
}

.pc-card.disabled {
    opacity: .6;
    cursor: not-allowed;
    background: #f1f5f9;
}

.pc-card.booked-slot {
    border-color: #f59e0b;
    background: #fffbeb;
    opacity: 1;
}

.pc-card.booked-slot i,
.pc-card.booked-slot .pc-kategori {
    color: #b45309;
}

.pc-card i { font-size: 28px; margin-bottom: 8px; display: block; }
.pc-card.reguler i { color: #2563eb; }
.pc-card.vip i { color: #d97706; }
.pc-card.maintenance i { color: #94a3b8; }

.pc-name { font-weight: 700; font-size: 13px; color: var(--text-main); }
.pc-kategori { font-size: 11px; color: var(--text-muted); margin-top: 2px; }

/* ── USER NAVBAR ──────────────────────────── */
.user-navbar {
    background: var(--sidebar-bg);
    border-bottom: none;
    padding: 0 28px;
}

.user-navbar .navbar-brand {
    color: #fff !important;
    font-weight: 800;
    font-size: 17px;
    display: flex; align-items: center; gap: 10px;
}

.user-navbar .navbar-brand .brand-icon {
    width: 32px; height: 32px;
    background: var(--primary);
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 15px;
}

.user-navbar .nav-link {
    color: var(--sidebar-text) !important;
    font-weight: 500;
    font-size: 14px;
    padding: 20px 14px !important;
    border-bottom: 3px solid transparent;
    transition: all .2s;
}

.user-navbar .nav-link:hover,
.user-navbar .nav-link.active {
    color: #fff !important;
    border-bottom-color: var(--primary);
}

.user-main { padding: 32px 28px; }

/* ── MOBILE TOGGLE ────────────────────────── */
.sidebar-toggle {
    display: none;
    background: none; border: none;
    color: var(--text-main);
    font-size: 22px;
    cursor: pointer;
}

/* ── MISC ─────────────────────────────────── */
.mono { font-family: 'JetBrains Mono', monospace; }

.empty-state {
    text-align: center;
    padding: 48px 20px;
    color: var(--text-muted);
}

.empty-state i { font-size: 48px; margin-bottom: 12px; display: block; opacity: .4; }
.empty-state p { font-size: 15px; }

/* ── RESPONSIVE ───────────────────────────── */
@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.open { transform: translateX(0); }
    .main-content { margin-left: 0; }
    .sidebar-toggle { display: block; }
    .content-area { padding: 16px; }
    .user-main { padding: 20px 16px; }
}

/* ── SCROLLBAR ────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
