/* ==========================================================================
   App custom styles (layered on top of sb-admin-2)
   ========================================================================== */

/* --- Modern scrollbar (global) ------------------------------------------- */
/* sb-admin-2 primary palette: #4e73df / hover #2e59d9 */

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: #b7c0e0 transparent;
}

/* WebKit (Chrome / Edge / Safari) */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: #c2cae6;
    border-radius: 10px;
    border: 2px solid transparent;
    background-clip: content-box;
    transition: background-color 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #4e73df;
}

::-webkit-scrollbar-thumb:active {
    background-color: #2e59d9;
}

::-webkit-scrollbar-corner {
    background: transparent;
}

/* --- Settings page ------------------------------------------------------- */
.settings-content {
    padding-right: 0.75rem;
}

/* Slightly accent the scroll area on the dark sidebar where it appears */
.sidebar::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.35);
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background-color: rgba(255, 255, 255, 0.6);
}

/* --- Bootstrap nav-tabs: neutral (non-blue) inactive tabs ---------------- */
.nav-tabs .nav-link {
    color: #858796;
}

.nav-tabs .nav-link:hover {
    color: #5a5c69;
}

.nav-tabs .nav-link.active {
    color: #5a5c69;
    font-weight: 600;
}

/* --- Sidebar width & text wrapping --------------------------------------- */
/* sb-admin-2 default is 14rem — bumped to 16rem for longer menu labels */
@media (min-width: 768px) {
    .sidebar {
        width: 18rem !important;
    }
    /* nav-link inside sidebar has an explicit width:14rem in sb-admin-2;
       reset to 100% so it fills whatever sidebar width is set */
    .sidebar .nav-item .nav-link {
        width: 100% !important;
    }
}

/* Separate icon from text so icon stays vertically centered when text wraps */
.collapse-item {
    display: flex !important;
    align-items: center;
    white-space: normal !important;
}

.collapse-item i {
    flex-shrink: 0;
}

/* Left settings nav active/hover polish */
#settings-nav .nav-link {
    color: #5a5c69;
    border-radius: 0.35rem;
    margin-bottom: 0.25rem;
    transition: background-color 0.15s ease, color 0.15s ease;
}

#settings-nav .nav-link:hover {
    background-color: #eaecf4;
    color: #4e73df;
}

#settings-nav .nav-link.active {
    background-color: #4e73df;
    color: #fff;
    box-shadow: 0 0.125rem 0.25rem rgba(78, 115, 223, 0.4);
}
