/* ============================================================
   SIDIK — Custom CSS
   Sistem Informasi Kedisiplinan & Perizinan Santri
   ============================================================ */

:root {
    --sidik-teal:   #1D9E75;
    --sidik-putra:  #185FA5;
    --sidik-putri:  #993556;
    --sidik-dark:   #1a1a2e;
    --sidik-light:  #f8f9fa;
}

/* ============================================================
   GLOBAL
   ============================================================ */
body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background-color: #f0f2f5;
    color: #333;
}

a {
    text-decoration: none;
}

/* ============================================================
   SIDEBAR
   ============================================================ */
.sidik-sidebar {
    width: 250px;
    min-height: 100vh;
    background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    transition: transform 0.3s ease;
    overflow-y: auto;
}

.sidik-sidebar .sidebar-brand {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidik-sidebar .sidebar-brand h5 {
    color: var(--sidik-teal);
    font-weight: 700;
    font-size: 1.1rem;
    margin: 0;
}

.sidik-sidebar .sidebar-brand small {
    color: rgba(255,255,255,0.5);
    font-size: 0.7rem;
}

.sidik-sidebar .nav-link {
    color: rgba(255,255,255,0.7);
    padding: 0.65rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    border-radius: 0;
    transition: all 0.2s;
}

.sidik-sidebar .nav-link:hover,
.sidik-sidebar .nav-link.active {
    color: #fff;
    background: rgba(29, 158, 117, 0.2);
    border-left: 3px solid var(--sidik-teal);
}

.sidik-sidebar .nav-section {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.35);
    padding: 1rem 1.5rem 0.25rem;
    font-weight: 600;
}

.sidik-sidebar .nav-link i {
    font-size: 1.1rem;
    width: 1.2rem;
    flex-shrink: 0;
}

/* ============================================================
   TOPBAR
   ============================================================ */
.sidik-topbar {
    height: 60px;
    background: #fff;
    border-bottom: 1px solid #e9ecef;
    position: fixed;
    top: 0;
    left: 250px;
    right: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

/* ============================================================
   MAIN CONTENT
   ============================================================ */
.sidik-content {
    margin-left: 250px;
    margin-top: 60px;
    padding: 1.5rem;
    min-height: calc(100vh - 60px);
}

/* ============================================================
   BOTTOM NAV (Mobile)
   ============================================================ */
.sidik-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid #e9ecef;
    z-index: 1001;
    height: 60px;
}

.sidik-bottom-nav .nav-item {
    flex: 1;
    text-align: center;
}

.sidik-bottom-nav .nav-link {
    color: #6c757d;
    font-size: 0.7rem;
    padding: 0.5rem 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.sidik-bottom-nav .nav-link i {
    font-size: 1.3rem;
}

.sidik-bottom-nav .nav-link.active {
    color: var(--sidik-teal);
}

/* ============================================================
   KARTU IDENTITAS USER
   ============================================================ */
.sidik-user-card {
    background: linear-gradient(135deg, var(--sidik-teal), #157a5a);
    border-radius: 12px;
    color: #fff;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
}

.sidik-user-card.putra {
    background: linear-gradient(135deg, var(--sidik-putra), #0f4280);
}

.sidik-user-card.putri {
    background: linear-gradient(135deg, var(--sidik-putri), #6e2340);
}

/* ============================================================
   STAT CARDS
   ============================================================ */
.stat-card {
    border: none;
    border-radius: 12px;
    padding: 1.25rem;
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
}

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

/* ============================================================
   BADGE STATUS POIN
   ============================================================ */
.badge-hijau  { background: var(--sidik-teal) !important; }
.badge-kuning { background: #ffc107 !important; color: #000 !important; }
.badge-merah  { background: #dc3545 !important; }
.badge-hitam  { background: #212529 !important; }

/* ============================================================
   TABLE
   ============================================================ */
.table-sidik th {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6c757d;
    border-top: none;
    background: #f8f9fa;
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */
.login-wrapper {
    min-height: 100vh;
    background: linear-gradient(135deg, #1a1a2e 0%, var(--sidik-teal) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.login-card {
    background: #fff;
    border-radius: 20px;
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.login-logo {
    font-size: 3rem;
    color: var(--sidik-teal);
}

/* ============================================================
   RESPONSIVE — Mobile
   ============================================================ */
@media (max-width: 768px) {
    .sidik-sidebar {
        transform: translateX(-100%);
    }

    .sidik-sidebar.show {
        transform: translateX(0);
    }

    .sidik-topbar {
        left: 0;
    }

    .sidik-content {
        margin-left: 0;
        padding: 1rem;
        padding-bottom: 4.5rem; /* buat bottom nav */
    }

    .sidik-bottom-nav {
        display: flex;
    }
}

/* ============================================================
   OVERLAY (untuk mobile sidebar)
   ============================================================ */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

.sidebar-overlay.show {
    display: block;
}

/* ============================================================
   UTILITIES
   ============================================================ */
.rounded-xl { border-radius: 12px !important; }
.rounded-2xl { border-radius: 16px !important; }
.text-teal { color: var(--sidik-teal) !important; }
.bg-teal { background-color: var(--sidik-teal) !important; }
.border-teal { border-color: var(--sidik-teal) !important; }

/* Button teal */
.btn-teal {
    background-color: var(--sidik-teal);
    border-color: var(--sidik-teal);
    color: #fff;
}
.btn-teal:hover, .btn-teal:focus {
    background-color: #17805e;
    border-color: #17805e;
    color: #fff;
}
.btn-outline-teal {
    border-color: var(--sidik-teal);
    color: var(--sidik-teal);
}
.btn-outline-teal:hover {
    background-color: var(--sidik-teal);
    color: #fff;
}

/* Table header teal */
.table-teal th {
    background-color: var(--sidik-teal);
    color: #fff;
    border-color: #17805e;
}

/* Card hover effect */
.card-hover {
    transition: transform 0.2s, box-shadow 0.2s;
}
.card-hover:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12) !important;
}

/* Min width 0 for flex truncate */
.min-width-0 { min-width: 0; }
