:root {
    --bg-main: #0f2529;
    --bg-card: #19383e;
    --bg-card-hover: #214850;
    --text-primary: #ffffff;
    --text-muted: #b7cdd1;
    --card-green: #146c4c;
    --card-blue: #225c86;
    --card-purple: #6b4b9e;
    --card-brown: #9d5e1c;
    --accent-teal: #1fb881;
    --border-subtle: rgba(255, 255, 255, 0.08);
}

* {
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    margin: 0;
    padding-bottom: 85px;
}

@media (min-width: 992px) {
    body {
        padding-bottom: 30px;
        padding-left: 250px;
    }
}

/* Perbaikan kontras teks sekunder di tema gelap */
.text-muted,
small.text-muted,
.table-dark-custom .text-muted,
.panel-box .text-muted {
    color: var(--text-muted) !important;
    opacity: 1 !important;
}

/* Sidebar Desktop */
.desktop-sidebar {
    display: none;
}

@media (min-width: 992px) {
    .desktop-sidebar {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        width: 250px;
        height: 100vh;
        background-color: #0b1c1f;
        border-right: 1px solid var(--border-subtle);
        padding: 24px 16px;
        z-index: 1000;
    }
}

.sidebar-brand {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #fff;
    padding: 0 12px 24px;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 12px;
    margin-bottom: 6px;
    font-weight: 500;
    transition: all 0.2s;
}

.sidebar-link:hover,
.sidebar-link.active {
    background-color: var(--bg-card);
    color: #fff;
}

/* Main Container */
.app-container {
    max-width: 1140px;
    margin: 0 auto;
    padding: 20px 18px;
}

/* Header */
.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}

.app-title {
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    margin: 0;
    text-transform: uppercase;
}

.app-subtitle {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin: 2px 0 0;
}

.profile-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    background: transparent;
    transition: 0.2s;
    flex-shrink: 0;
}

.profile-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* Hero Summary Card */
.hero-card {
    background-color: var(--bg-card);
    border-radius: 18px;
    padding: 22px 24px;
    margin-bottom: 20px;
    border: 1px solid var(--border-subtle);
}

.hero-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 8px;
}

.hero-amount {
    font-size: clamp(1.85rem, 4vw, 2.5rem);
    font-weight: 800;
    margin: 0 0 6px;
    color: #ffffff;
}

.hero-subtext {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin: 0;
}

/* 4 Menu Cards Grid */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-bottom: 22px;
}

@media (min-width: 768px) {
    .menu-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 18px;
    }
}

.menu-card {
    border-radius: 18px;
    padding: 20px 18px;
    text-decoration: none;
    color: #ffffff !important;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 132px;
    transition: transform 0.2s ease, filter 0.2s ease;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}

.menu-card:hover {
    transform: translateY(-3px);
    filter: brightness(1.07);
}

.card-green { background-color: var(--card-green); }
.card-blue { background-color: var(--card-blue); }
.card-purple { background-color: var(--card-purple); }
.card-brown { background-color: var(--card-brown); }

.menu-icon {
    font-size: 1.65rem;
    margin-bottom: 14px;
    opacity: 0.95;
}

.menu-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0 0 4px;
}

.menu-desc {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.88);
    margin: 0;
}

/* Notification Box */
.notif-card {
    background-color: var(--bg-card);
    border-radius: 18px;
    padding: 20px 22px;
    border: 1px solid var(--border-subtle);
}

.notif-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.notif-title {
    font-size: 1.12rem;
    font-weight: 700;
    margin: 0;
}

.badge-count {
    background-color: rgba(31, 184, 129, 0.16);
    color: #2ce09e;
    font-weight: 600;
    font-size: 0.82rem;
    padding: 5px 12px;
    border-radius: 20px;
}

.notif-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-subtle);
    gap: 10px;
    flex-wrap: wrap;
}

.notif-item:last-of-type {
    border-bottom: none;
}

/* Panel & Tables */
.panel-box {
    background-color: var(--bg-card);
    border-radius: 18px;
    padding: 20px;
    border: 1px solid var(--border-subtle);
    margin-bottom: 20px;
}

.table-dark-custom {
    width: 100%;
    color: #fff;
    border-collapse: collapse;
}

.table-dark-custom th {
    background-color: #122b30;
    color: var(--text-muted);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border-subtle);
}

.table-dark-custom td {
    padding: 13px 14px;
    border-bottom: 1px solid var(--border-subtle);
    vertical-align: middle;
    font-size: 0.92rem;
}

.form-control-dark,
.form-select-dark {
    background-color: #10262a !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #fff !important;
    border-radius: 10px;
    padding: 10px 14px;
}

.form-control-dark::placeholder {
    color: #8aa7ad !important;
    opacity: 1;
}

.form-control-dark:focus,
.form-select-dark:focus {
    border-color: var(--accent-teal) !important;
    box-shadow: 0 0 0 0.2rem rgba(31, 184, 129, 0.2) !important;
}

/* Mobile Bottom Nav */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 68px;
    background-color: #0b1c1f;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 1050;
}

@media (min-width: 992px) {
    .mobile-bottom-nav {
        display: none;
    }
}

.bottom-nav-item {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 1.35rem;
    padding: 8px 16px;
    border-radius: 12px;
    transition: 0.2s;
}

.bottom-nav-item.active,
.bottom-nav-item:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.08);
}

/* Dropdown Menu */
.dropdown-menu-dark-custom {
    background-color: #122b30;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.dropdown-menu-dark-custom .dropdown-item {
    color: #e2ecef;
    border-radius: 8px;
    padding: 9px 14px;
    font-size: 0.9rem;
}

.dropdown-menu-dark-custom .dropdown-item:hover {
    background-color: var(--bg-card-hover);
    color: #fff;
}
