/* ============================================
   SIKAS - CSS Variables & Reset
   ============================================ */
:root {
    --sidebar-width: 260px;
    --sidebar-bg: linear-gradient(
        180deg,
        #1e2a4a 0%,
        #16213e 40%,
        #0f1a35 100%
    );
    --sidebar-accent: #4e73df;
    --sidebar-hover: rgba(78, 115, 223, 0.15);
    --sidebar-active-bg: rgba(78, 115, 223, 0.22);
    --sidebar-active-border: #4e73df;
    --sidebar-text: rgba(255, 255, 255, 0.65);
    --sidebar-text-hover: #ffffff;
    --topbar-height: 60px;
    --bg-body: #f4f6f9;
    --card-radius: 10px;
    --card-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    --primary: #4e73df;
    --primary-dark: #3a5bc7;
    --success: #1cc88a;
    --info: #36b9cc;
    --warning: #f6c23e;
    --danger: #e74a3b;
    --text-dark: #2d3748;
    --text-muted: #858796;
    --transition: all 0.25s ease;
    --topbar-bg: #ffffff;
    --card-bg: #ffffff;
    --border-color: #e3e6f0;
    --table-hover: #fafbfd;
    --table-head-bg: #f8f9fc;
}

[data-theme="dark"] {
    --bg-body: #121212;
    --text-dark: #e0e0e0;
    --text-muted: #a0a0a0;
    --topbar-bg: #1e1e1e;
    --card-bg: #1e1e1e;
    --border-color: #333333;
    --card-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    --table-hover: #2a2a2a;
    --table-head-bg: #2d2d2d;
    --sidebar-bg: #0d1117;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Inter", "Poppins", sans-serif;
    background: var(--bg-body);
    color: var(--text-dark);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6,
.brand-text {
    font-family: "Poppins", sans-serif;
}
::-webkit-scrollbar {
    width: 5px;
}
::-webkit-scrollbar-thumb {
    background: rgba(78, 115, 223, 0.25);
    border-radius: 10px;
}
a {
    text-decoration: none;
}

/* ============================================
   SIDEBAR
   ============================================ */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--sidebar-bg);
    z-index: 1050;
    overflow-y: auto;
    overflow-x: hidden;
    transition: var(--transition);
}

.sidebar-brand {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1rem;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.sidebar-brand .brand-logo {
    width: 36px;
    height: 36px;
    object-fit: contain;
    flex-shrink: 0;
}

.sidebar-brand .brand-text {
    color: #fff;
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.sidebar-brand .brand-text span {
    color: var(--sidebar-accent);
}

.sidebar-heading {
    padding: 1rem 1.25rem 0.4rem;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: rgba(255, 255, 255, 0.28);
    font-weight: 700;
}

.sidebar-divider {
    border: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin: 0.6rem 1rem;
}

.sidebar-nav .nav-item {
    padding: 1px 0.65rem;
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    color: var(--sidebar-text);
    padding: 0.62rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: var(--transition);
    border-left: 3px solid transparent;
    position: relative;
}

.sidebar-nav .nav-link i.fa-icon {
    width: 22px;
    text-align: center;
    margin-right: 10px;
    font-size: 0.92rem;
}

.sidebar-nav .nav-link:hover {
    color: var(--sidebar-text-hover);
    background: var(--sidebar-hover);
    border-left-color: rgba(78, 115, 223, 0.5);
}

.sidebar-nav .nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-left-color: #0dcaf0;
    border-radius: 0 8px 8px 0;
    font-weight: 600;
}

/* Sidebar Collapsed */
.sidebar.collapsed {
    width: 80px;
}
.sidebar.collapsed .sidebar-brand {
    padding: 0;
    gap: 0;
}
.sidebar.collapsed .brand-text {
    display: none;
}
.sidebar.collapsed .brand-logo {
    width: 32px;
    height: 32px;
}
.sidebar.collapsed .sidebar-heading,
.sidebar.collapsed .sidebar-divider {
    display: none;
}
.sidebar.collapsed .sidebar-nav .nav-item {
    padding: 0.2rem 0.5rem;
}
.sidebar.collapsed .sidebar-nav .nav-link {
    justify-content: center;
    padding: 0.8rem 0;
    border-radius: 8px;
}
.sidebar.collapsed .sidebar-nav .nav-link.active {
    border-radius: 0 8px 8px 0;
}
.sidebar.collapsed .sidebar-nav .nav-link span,
.sidebar.collapsed .sidebar-nav .nav-link .collapse-arrow {
    display: none;
}
.sidebar.collapsed .sidebar-nav .nav-link i.fa-icon {
    margin-right: 0;
    font-size: 1.2rem;
}
.sidebar.collapsed .sidebar-submenu {
    display: none !important;
}

.sidebar-nav .nav-link .collapse-arrow {
    margin-left: auto;
    font-size: 0.65rem;
    transition: transform 0.3s ease;
}
.sidebar-nav .nav-link[aria-expanded="true"] .collapse-arrow {
    transform: rotate(90deg);
}

/* Submenu */
.sidebar-submenu .nav-link {
    padding: 0.4rem 1rem 0.4rem 2.85rem;
    font-size: 0.82rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.5);
    border-left: none;
}
.sidebar-submenu .nav-link::before {
    content: "";
    position: absolute;
    left: 2rem;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    transition: var(--transition);
}
.sidebar-submenu .nav-link:hover {
    color: #fff;
    background: transparent;
}
.sidebar-submenu .nav-link:hover::before {
    background: var(--sidebar-accent);
    box-shadow: 0 0 6px rgba(78, 115, 223, 0.5);
}

/* ============================================
   MAIN WRAPPER
   ============================================ */
.main-wrapper {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    transition: var(--transition);
}
.main-wrapper.expanded {
    margin-left: 80px;
}

/* ============================================
   TOPBAR
   ============================================ */
.topbar {
    height: var(--topbar-height);
    background: var(--topbar-bg);
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1030;
    transition: background-color 0.3s ease;
}
.topbar-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.topbar-toggler {
    background: none;
    border: none;
    font-size: 1.2rem;
    color: var(--text-muted);
    cursor: pointer;
}
.topbar-title {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-dark);
}
.topbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.topbar-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    transition: var(--transition);
}
.topbar-icon:hover {
    background: var(--bg-body);
    color: var(--primary);
}

.topbar-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 18px;
    height: 18px;
    background: var(--danger);
    color: #fff;
    border-radius: 50%;
    font-size: 0.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(231, 74, 59, 0.4);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(231, 74, 59, 0);
    }
}

/* Notification Dropdown */
.notif-dropdown {
    width: 360px;
    border: none;
    border-radius: var(--card-radius);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.12);
    padding: 0;
    overflow: hidden;
}
.notif-dropdown-header {
    background: var(--primary);
    color: #fff;
    padding: 0.75rem 1rem;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 0.7rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    transition: var(--transition);
    color: var(--text-dark);
    cursor: pointer;
}
.notif-item:hover {
    background: #f8f9fc;
}
.notif-icon-sm {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    flex-shrink: 0;
}
.notif-item .notif-text {
    font-size: 0.82rem;
    line-height: 1.4;
}
.notif-item .notif-text strong {
    font-weight: 600;
}
.notif-item .notif-time {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 2px;
}
.notif-dropdown-footer {
    text-align: center;
    padding: 0.6rem;
    background: #fafafa;
}
.notif-dropdown-footer a {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
}

/* User Dropdown */
.user-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: 1px solid #e3e6f0;
    border-radius: 50px;
    padding: 4px 12px 4px 4px;
    cursor: pointer;
    transition: var(--transition);
}
.user-btn:hover {
    border-color: var(--primary);
}
.user-avatar-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
}
.user-btn .user-name {
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--text-dark);
}

/* ============================================
   PAGE CONTENT
   ============================================ */
.page-content {
    padding: 1.5rem;
}
.page-header {
    margin-bottom: 1.25rem;
}
.page-header h4 {
    font-weight: 700;
    color: var(--text-dark);
}
.page-header p {
    color: var(--text-muted);
    font-size: 0.88rem;
    margin: 0;
}

/* ============================================
   STAT CARDS
   ============================================ */
.info-box {
    background: var(--card-bg);
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: var(--transition);
    border-left: 4px solid transparent;
    position: relative;
    overflow: hidden;
}
.info-box:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}
.info-box.border-primary {
    border-left-color: var(--primary);
}
.info-box.border-success {
    border-left-color: var(--success);
}
.info-box.border-info {
    border-left-color: var(--info);
}
.info-box.border-danger {
    border-left-color: var(--danger);
}

.info-box-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--card-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}
.info-box-icon.bg-primary-soft {
    background: rgba(78, 115, 223, 0.1);
    color: var(--primary);
}
.info-box-icon.bg-success-soft {
    background: rgba(28, 200, 138, 0.1);
    color: var(--success);
}
.info-box-icon.bg-info-soft {
    background: rgba(54, 185, 204, 0.1);
    color: var(--info);
}
.info-box-icon.bg-danger-soft {
    background: rgba(231, 74, 59, 0.1);
    color: var(--danger);
}

.info-box-content .info-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    font-weight: 700;
    margin-bottom: 4px;
}
.info-box-content .info-value {
    font-family: "Poppins", sans-serif;
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--text-dark);
}

/* ============================================
   CARDS
   ============================================ */
.card-custom {
    background: var(--card-bg);
    border-radius: var(--card-radius);
    box-shadow: var(--card-shadow);
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition:
        background-color 0.3s ease,
        border-color 0.3s ease;
}
.card-custom .card-header-custom {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--card-bg);
}
.card-custom .card-header-custom h6 {
    font-weight: 700;
    font-size: 0.9rem;
    margin: 0;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 8px;
}
.card-custom .card-body-custom {
    padding: 1.25rem;
}

/* ============================================
   TABLE
   ============================================ */
.table-custom {
    width: 100%;
    font-size: 0.85rem;
    color: var(--text-dark);
}
.table-custom thead th {
    background: var(--table-head-bg);
    color: var(--text-muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-weight: 700;
    padding: 0.75rem 1rem;
    border-bottom: 2px solid var(--border-color);
    white-space: nowrap;
}
.table-custom tbody td {
    padding: 0.7rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-dark);
}
.table-custom tbody tr:hover {
    background: var(--table-hover);
}
.table-custom tbody tr:last-child td {
    border-bottom: none;
}

/* Badges */
.badge-lunas {
    background: rgba(28, 200, 138, 0.12);
    color: #0e9f6e;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.73rem;
}
.badge-belum {
    background: rgba(231, 74, 59, 0.1);
    color: var(--danger);
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.73rem;
}
.badge-sebagian {
    background: rgba(246, 194, 62, 0.15);
    color: #c79100;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.73rem;
}

/* ============================================
   GRADIENT STAT CARDS
   ============================================ */
.stat-gradient {
    border-radius: var(--card-radius);
    padding: 1.1rem 1.25rem;
    color: #fff;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    min-height: 120px;
}
.stat-gradient:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}
.stat-gradient.bg-blue {
    background: linear-gradient(135deg, #4e73df 0%, #3a5bc7 100%);
}
.stat-gradient.bg-green {
    background: linear-gradient(135deg, #1cc88a 0%, #17a673 100%);
}
.stat-gradient.bg-orange {
    background: linear-gradient(135deg, #f6993f 0%, #e67e22 100%);
}
.stat-gradient.bg-red {
    background: linear-gradient(135deg, #e74a3b 0%, #c0392b 100%);
}

.stat-gradient .stat-g-value {
    font-family: "Poppins", sans-serif;
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
}
.stat-gradient .stat-g-label {
    font-size: 0.82rem;
    font-weight: 600;
    opacity: 0.95;
}
.stat-gradient .stat-g-sub {
    font-size: 0.75rem;
    opacity: 0.8;
    margin-top: 0.4rem;
}
.stat-gradient .stat-g-icon {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}
.stat-gradient .stat-g-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.6rem;
    font-size: 0.73rem;
    opacity: 0.85;
}

/* ============================================
   DATA TABLE TOOLBAR
   ============================================ */
.datatable-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.8rem 1rem;
    border-bottom: 1px solid #e3e6f0;
}
.datatable-toolbar .dt-filter {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.datatable-toolbar .dt-search {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.datatable-toolbar .dt-search input {
    padding: 5px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 0.82rem;
    outline: none;
    transition: var(--transition);
}
.datatable-toolbar .dt-search input:focus {
    border-color: var(--primary);
}

.dt-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.6rem 1rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    border-top: 1px solid #e3e6f0;
}
.dt-pagination .dt-pages {
    display: flex;
    gap: 3px;
}
.dt-pagination .dt-pages a,
.dt-pagination .dt-pages span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 30px;
    min-width: 30px;
    padding: 0 8px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-dark);
}
.dt-pagination .dt-pages a:hover {
    background: #e3e6f0;
}
.dt-pagination .dt-pages span.active-page {
    background: var(--primary);
    color: #fff;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-xlsx {
    background: #217346;
    color: #fff;
    border: none;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-xlsx:hover {
    background: #185c37;
}

.btn-edit {
    background: var(--success);
    color: #fff;
    border: none;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-edit:hover {
    background: #17a673;
}

.btn-delete {
    background: var(--danger);
    color: #fff;
    border: none;
    padding: 4px 10px;
    border-radius: 5px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-delete:hover {
    background: #c0392b;
}

.btn-act {
    height: 30px;
    padding: 0 8px;
    border-radius: 6px;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    color: #fff;
    cursor: pointer;
    transition: var(--transition);
}
.btn-act:hover {
    opacity: 0.85;
    transform: scale(1.05);
}
.btn-act.bg-print {
    background: #3498db;
}
.btn-act.bg-pdf {
    background: #e74a3b;
}
.btn-act.bg-edit-a {
    background: #1cc88a;
}
.btn-act.bg-del {
    background: #e74a3b;
}

.btn-add {
    background: var(--success);
    color: #fff;
    border: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-add:hover {
    background: #17a673;
    color: #fff;
}

.btn-danger-sm {
    background: var(--danger);
    color: #fff;
    border: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-danger-sm:hover {
    background: #c0392b;
    color: #fff;
}

.btn-upload {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}
.btn-upload:hover {
    background: #3a5bc7;
    color: #fff;
}

.page-card-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-dark);
    padding: 1rem 1.25rem;
    border-bottom: 1px solid #e3e6f0;
}

.filter-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.8rem 1rem;
}
.filter-bar label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-dark);
}
.filter-bar .form-control-sm,
.filter-bar .form-select-sm {
    font-size: 0.82rem;
}

/* Modal */
.modal-content {
    border-radius: 12px;
    border: none;
}
.modal-header {
    border-bottom: 1px solid #e3e6f0;
}
.modal-header .modal-title {
    font-weight: 700;
    font-size: 1rem;
}
.modal-footer {
    border-top: 1px solid #e3e6f0;
}

.btn-void-approve {
    background: var(--danger);
    color: #fff;
    border: none;
    padding: 5px 14px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    transition: var(--transition);
}
.btn-void-approve:hover { background: #c0392b; color: #fff; }

.btn-void-reject {
    background: #858796;
    color: #fff;
    border: none;
    padding: 5px 14px;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    transition: var(--transition);
}
.btn-void-reject:hover { background: #6c757d; color: #fff; }

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.fade-up {
    animation: fadeUp 0.4s ease forwards;
}
.delay-1 {
    animation-delay: 0.05s;
    opacity: 0;
}
.delay-2 {
    animation-delay: 0.1s;
    opacity: 0;
}
.delay-3 {
    animation-delay: 0.15s;
    opacity: 0;
}
.delay-4 {
    animation-delay: 0.2s;
    opacity: 0;
}

/* Donut */
.donut-placeholder {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    margin: 1rem auto;
    position: relative;
}
.donut-placeholder .donut-ring {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(#b8c6db 0deg 195deg, #a8d8b9 195deg 360deg);
    position: relative;
}
.donut-placeholder .donut-ring::after {
    content: "";
    position: absolute;
    top: 25%;
    left: 25%;
    width: 50%;
    height: 50%;
    border-radius: 50%;
    background: #fff;
}
.donut-legend {
    display: flex;
    justify-content: center;
    gap: 1rem;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}
.donut-legend span::before {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    margin-right: 5px;
    vertical-align: middle;
}
.donut-legend .leg-p::before {
    background: #a8d8b9;
}
.donut-legend .leg-l::before {
    background: #b8c6db;
}

.summary-badges {
    display: flex;
    gap: 6px;
    margin-top: 0.5rem;
}
.summary-badges .s-badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    color: #fff;
}
.s-badge.bg-l {
    background: var(--success);
}
.s-badge.bg-p {
    background: var(--primary);
}
.s-badge.bg-t {
    background: var(--danger);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 991.98px) {
    .sidebar {
        transform: translateX(-100%);
    }
    .sidebar.show {
        transform: translateX(0);
    }
    .main-wrapper {
        margin-left: 0;
    }
    .topbar-toggler {
        display: flex;
    }
    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.45);
        z-index: 1040;
    }
    .sidebar-overlay.show {
        display: block;
    }
}

/* ============================================
   LOGIN PAGE — Split Screen
   ============================================ */
.login-page {
    display: flex;
    min-height: 100vh;
    font-family: "Inter", "Poppins", sans-serif;
}

/* ----- Left Branding Panel ----- */
.login-brand-panel {
    flex: 0 0 45%;
    background: linear-gradient(160deg, #1e2a4a 0%, #16213e 45%, #0f1a35 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 3rem 2rem;
}

/* Floating geometric shapes */
.login-shapes .shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.07;
    background: #fff;
    animation: floatShape 18s ease-in-out infinite;
}
.shape-1 { width: 280px; height: 280px; top: -60px; left: -80px; animation-delay: 0s; }
.shape-2 { width: 180px; height: 180px; bottom: 10%; right: -40px; animation-delay: -4s; border-radius: 30%; }
.shape-3 { width: 120px; height: 120px; top: 35%; right: 15%; animation-delay: -8s; }
.shape-4 { width: 90px; height: 90px; bottom: 18%; left: 12%; animation-delay: -2s; border-radius: 35%; }
.shape-5 { width: 60px; height: 60px; top: 18%; left: 55%; animation-delay: -6s; }
.shape-6 { width: 200px; height: 200px; bottom: -50px; left: 35%; animation-delay: -10s; border-radius: 40%; opacity: 0.04; }

@keyframes floatShape {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25%      { transform: translateY(-18px) rotate(5deg); }
    50%      { transform: translateY(8px) rotate(-3deg); }
    75%      { transform: translateY(-10px) rotate(2deg); }
}

/* Branding content */
.login-brand-content {
    position: relative;
    z-index: 2;
    text-align: center;
    animation: fadeUp 0.8s ease forwards;
}
.brand-logo-wrapper {
    width: 110px;
    height: 110px;
    margin: 0 auto 1.5rem;
    background: rgba(255,255,255,0.12);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    border: 2px solid rgba(255,255,255,0.15);
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
}
.brand-logo-lg {
    width: 78px;
    height: 78px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.2));
}
.brand-title {
    font-family: "Poppins", sans-serif;
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: 6px;
    color: #ffffff;
    margin-bottom: 0.3rem;
    text-shadow: 0 2px 15px rgba(0,0,0,0.3);
}
.brand-title span {
    color: #6f9cff;
}
.brand-subtitle {
    color: rgba(255,255,255,0.65);
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}
.brand-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 50px;
    color: rgba(255,255,255,0.7);
    font-size: 0.78rem;
    font-weight: 500;
    backdrop-filter: blur(6px);
}
.brand-badge i {
    color: #6f9cff;
}
/* Scrolling Ticker */
.login-ticker {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    overflow: hidden;
    background: rgba(255,255,255,0.05);
    border-top: 1px solid rgba(255,255,255,0.08);
    border-bottom: 1px solid rgba(255,255,255,0.08);
    padding: 10px 0;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%);
}
.ticker-track {
    display: flex;
    align-items: center;
    white-space: nowrap;
    animation: tickerScroll 35s linear infinite;
    gap: 0;
}
.login-ticker:hover .ticker-track {
    animation-play-state: paused;
}
.ticker-item {
    color: rgba(255,255,255,0.75);
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.3px;
    padding: 0 1.5rem;
    flex-shrink: 0;
}
.ticker-item i {
    color: #6f9cff;
    margin-right: 6px;
    font-size: 0.72rem;
}
.ticker-separator {
    color: rgba(111,156,255,0.4);
    font-size: 0.6rem;
    flex-shrink: 0;
}
@keyframes tickerScroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.brand-bottom-decor {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
}
.decor-line {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(111,156,255,0.5), transparent);
    border-radius: 2px;
}

/* ----- Right Form Panel ----- */
.login-form-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f7f9fc;
    padding: 2rem;
    position: relative;
}
.login-form-wrapper {
    width: 100%;
    max-width: 420px;
    animation: fadeUp 0.6s ease forwards;
}

/* Mobile logo (hidden on desktop) */
.mobile-logo { display: none; }

/* Greeting */
.login-greeting {
    margin-bottom: 1.75rem;
}
.login-greeting h2 {
    font-family: "Poppins", sans-serif;
    font-size: 1.65rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 0.3rem;
}
.login-greeting p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* Alert Messages */
.login-alert {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0.7rem 1rem;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 1.25rem;
}
.login-alert-danger {
    background: rgba(231,74,59,0.08);
    color: #c0392b;
    border: 1px solid rgba(231,74,59,0.15);
}
.login-alert-success {
    background: rgba(28,200,138,0.08);
    color: #0e9f6e;
    border: 1px solid rgba(28,200,138,0.15);
}
.login-alert-icon {
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* Form Fields */
.login-field {
    margin-bottom: 1.25rem;
}
.login-label {
    display: block;
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--text-dark);
    margin-bottom: 0.4rem;
}
.login-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}
.login-input-icon {
    position: absolute;
    left: 14px;
    color: #b0b7c3;
    font-size: 0.9rem;
    pointer-events: none;
    transition: color 0.25s ease;
    z-index: 2;
}
.login-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.75rem;
    border: 1.5px solid #e0e5ec;
    border-radius: 10px;
    font-size: 0.9rem;
    font-family: "Inter", sans-serif;
    color: var(--text-dark);
    background: #fff;
    transition: all 0.25s ease;
    outline: none;
}
.login-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(78,115,223,0.12);
}
.login-input:focus ~ .login-input-icon,
.login-input-wrap:focus-within .login-input-icon {
    color: var(--primary);
}
.login-input::placeholder {
    color: #c4cad4;
}

/* Password toggle */
.login-toggle-pw {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: #b0b7c3;
    font-size: 0.95rem;
    cursor: pointer;
    padding: 4px;
    z-index: 2;
    transition: color 0.2s;
}
.login-toggle-pw:hover {
    color: var(--primary);
}

/* Submit Button */
.login-btn {
    width: 100%;
    padding: 0.8rem;
    background: linear-gradient(135deg, #4e73df 0%, #3a5bc7 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-family: "Poppins", sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(78,115,223,0.35);
    margin-top: 0.5rem;
}
.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 22px rgba(78,115,223,0.45);
    background: linear-gradient(135deg, #3a5bc7 0%, #2e4db3 100%);
}
.login-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(78,115,223,0.3);
}
.login-btn:disabled {
    opacity: 0.75;
    cursor: not-allowed;
    transform: none;
}
.login-btn-text,
.login-btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Demo Credentials */
.login-demo-info {
    margin-top: 1.75rem;
    padding: 1rem;
    background: #fff;
    border-radius: 10px;
    border: 1px solid #e8ecf1;
    text-align: center;
}
.demo-title {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.6rem;
}
.demo-title i { margin-right: 4px; }
.demo-accounts {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin-bottom: 0.5rem;
}
.demo-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: rgba(78,115,223,0.06);
    border: 1px solid rgba(78,115,223,0.12);
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    color: #4e73df;
}
.demo-badge i { font-size: 0.65rem; opacity: 0.7; }
.demo-pw {
    font-size: 0.78rem;
    color: var(--text-muted);
}
.demo-pw code {
    background: #f0f2f5;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.78rem;
    color: var(--text-dark);
    font-weight: 600;
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.72rem;
    color: var(--text-muted);
    letter-spacing: 0.3px;
}

/* ============================================
   LOGIN — Responsive
   ============================================ */
@media (max-width: 991.98px) {
    .login-page {
        flex-direction: column;
    }
    .login-brand-panel {
        flex: none;
        padding: 2rem 1.5rem 1.5rem;
        min-height: auto;
    }
    .brand-logo-wrapper {
        width: 80px;
        height: 80px;
        margin-bottom: 1rem;
    }
    .brand-logo-lg {
        width: 56px;
        height: 56px;
    }
    .brand-title {
        font-size: 2rem;
        letter-spacing: 4px;
    }
    .brand-subtitle {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }
    .brand-bottom-decor { display: none; }
    .login-form-panel {
        padding: 1.5rem;
    }
    .login-greeting h2 {
        font-size: 1.35rem;
    }
}

@media (max-width: 575.98px) {
    .login-brand-panel {
        padding: 1.5rem 1rem 1.2rem;
    }
    .brand-logo-wrapper {
        width: 65px;
        height: 65px;
    }
    .brand-logo-lg {
        width: 45px;
        height: 45px;
    }
    .brand-title {
        font-size: 1.6rem;
        letter-spacing: 3px;
    }
    .brand-subtitle {
        font-size: 0.78rem;
    }
    .brand-badge {
        font-size: 0.68rem;
        padding: 6px 14px;
    }
    .login-form-panel {
        padding: 1.25rem;
    }
    .login-form-wrapper {
        max-width: 100%;
    }
    .login-greeting h2 {
        font-size: 1.2rem;
    }
    .login-btn {
        padding: 0.7rem;
        font-size: 0.88rem;
    }
    .demo-accounts {
        flex-direction: column;
        align-items: center;
    }
}
