
/* MoleHub theme overrides */

:root {
    --molehub-charcoal: #202832;
    --molehub-charcoal-light: #2c3642;
    --molehub-accent: #e9a23b;
}

/* Main header */
.header {
    background: #505969 !important;
    border-bottom: 1px solid #39434f;
}

.header .header-left {
    background: var(--molehub-charcoal) !important;
}

.header .header-user {
    margin-left: auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    height: 100%;
}

/* Sidebar */
.sidebar {
    background: #2c2c2c !important;
    border-right: 1px solid #39434f;
}

.sidebar .sidebar-inner,
.sidebar .sidebar-menu {
    background: transparent;
}

.sidebar .sidebar-menu .submenu-hdr {
    color: #8e9bab !important;
}

.sidebar .sidebar-menu ul li a {
    color: #c5ced8 !important;
}

.sidebar .sidebar-menu ul li div:hover,
.sidebar .sidebar-menu ul li div.active {
    background: var(--molehub-charcoal-light) !important;
    color: #ffffff !important;
}

.sidebar .sidebar-menu ul li a i {
    color: inherit;
}

/* Keep the main content light */
.page-wrapper {
    background: #f5f6f8;
}

.page-wrapper .card {
    background: #ffffff;
}


/* MoleHub sidebar navigation */
.sidebar .sidebar-menu ul li a,
.sidebar .sidebar-menu ul li a span,
.sidebar .sidebar-menu ul li a i {
    color: #c5ced8 !important;
}

.sidebar .sidebar-menu ul li a:hover,
.sidebar .sidebar-menu ul li a:hover span,
.sidebar .sidebar-menu ul li a:hover i {
    color: #ffffff !important;
}

.sidebar .sidebar-menu ul li a.active,
.sidebar .sidebar-menu ul li a.active span,
.sidebar .sidebar-menu ul li a.active i {
    color: #ffffff !important;
}

/* MoleHub text-based logo */
.header .header-left .logo {
    line-height: normal !important;
    display: flex;
    align-items: center;
    height: 100%;
}

.header .header-left .logo span {
    color: #ffffff !important;
    font-size: 21px;
    font-weight: 700;
    white-space: nowrap;
}

/* Header alignment */
.header {
    display: flex;
    align-items: center;
}

.header > .d-flex.ms-auto {
    margin-left: auto !important;
}

/* MoleHub expandable module navigation */
.sidebar .sidebar-menu .molehub-module-row {
    display: flex;
    align-items: center;
    width: 100%;
}

.sidebar .sidebar-menu .molehub-module-row .molehub-module-link {
    flex: 1;
    min-width: 0;
}

.sidebar .sidebar-menu .molehub-module-toggle {
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #c5ced8;
    cursor: pointer;
    margin-right: 10px;
}

/*
.sidebar .sidebar-menu .molehub-module-toggle:hover {
    background: #36414e;
    c */

.sidebar .sidebar-menu .molehub-module-toggle i {
    display: block;
    transition: transform 0.2s ease;
}

.sidebar .sidebar-menu .molehub-module-toggle[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.sidebar .sidebar-menu ul.molehub-module-submenu {
    display: block;
    margin: 2px 0 8px;
    padding: 0 0 0 28px;
    list-style: none;
}

.sidebar .sidebar-menu ul.molehub-module-submenu[hidden] {
    display: none !important;
}

.sidebar .sidebar-menu ul.molehub-module-submenu li {
    margin: 0;
}

.sidebar .sidebar-menu ul.molehub-module-submenu a,
.sidebar .sidebar-menu .molehub-module-placeholder {
    display: block;
    padding: 8px 10px;
    font-size: 13px;
    color: #aeb9c7;
}

.sidebar .sidebar-menu .molehub-module-placeholder {
    opacity: 0.55;
    cursor: default;
}

/* Active submenu page */
.sidebar .sidebar-menu ul.molehub-module-submenu a.molehub-submenu-link.active {
    color: #f2b45c !important;
    border-radius: 4px;
    font-weight: 600;
}
/*
.sidebar .sidebar-menu ul.molehub-module-submenu a.molehub-submenu-link.active:hover {
    background: rgba(233, 162, 59, 0.16) !important;
    color: #ffffff !important;
} */

/* Give submenu links a little breathing room */

.sidebar .sidebar-menu ul.molehub-module-submenu a.molehub-submenu-link {
    margin: 2px 0;
    padding: 8px 10px;
    transition: background 0.15s ease, color 0.15s ease;
}

/* Original-style circular chevron */

.sidebar .sidebar-menu .molehub-module-toggle {
    border-radius: 50%;
    width: 14px;
    height: 14px;
    flex-basis: 14px;
    top: 10px;
    right: 12px;
    background: #555555;
    color: #ffffff;
}

.sidebar .sidebar-menu .molehub-module-toggle[aria-expanded="true"] {
    background: #fe9f43;
    color: #ffffff;
}


/* DreamsPOS-style submenu indicators */

.sidebar .sidebar-menu ul.molehub-module-submenu {
    padding-left: 12px;
    margin-top: 4px;
}

.sidebar .sidebar-menu ul.molehub-module-submenu a,
.sidebar .sidebar-menu .molehub-module-placeholder {
    position: relative;
    padding: 8px 10px 8px 30px;
    font-size: 14px;
}

/* Circular indicator for every submenu entry */

.sidebar .sidebar-menu ul.molehub-module-submenu a::after,
.sidebar .sidebar-menu .molehub-module-placeholder::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    border: 2px solid #cccccc;
    border-radius: 50%;
    background: transparent;
}

/* Prevent disabled entries from looking interactive */

.sidebar .sidebar-menu .molehub-module-placeholder {
    cursor: default;
}

/* Align submenu markers without overlapping text */

.sidebar .sidebar-menu ul.molehub-module-submenu a.molehub-submenu-link,
.sidebar .sidebar-menu .molehub-module-placeholder {
    padding-left: 36px;
}

.sidebar .sidebar-menu ul.molehub-module-submenu a.molehub-submenu-link::after,
.sidebar .sidebar-menu .molehub-module-placeholder::after {
    left: 14px;
}


/* MoleHub sidebar branding */

.sidebar .molehub-sidebar-logo {
    height: 65px;
    min-height: 65px;
    padding: 0 14px 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #454545;
    background: #333333;
}

.sidebar .molehub-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
}

.sidebar .molehub-brand i {
    color: #FE9F43 !important;
    font-size: 25px;
}

.sidebar .molehub-brand span {
    color: #ffffff !important;
    font-size: 21px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.sidebar .molehub-sidebar-collapse {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
    border: 0;
    border-radius: 50%;
    background: #FE9F43;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.sidebar .molehub-sidebar-collapse:hover {
    background: #e88a2c;
}

.sidebar .molehub-sidebar-collapse i {
    font-size: 15px;
}

.sidebar .molehub-brand i {
    font-size: 28px;
    width: 28px;
    text-align: center;
    line-height: 1;
}

/* MoleHub mobile header */
@media (max-width: 991.96px) {

    /* Make the header our positioning reference */
    .header {
        position: fixed;
        width: 100%;
    }

    /* Centre the MoleHub branding */
    .header .header-left {
        position: absolute;
        left: 50%;
        top: 0;
        transform: translateX(-50%);
        width: auto !important;
        height: 65px;
        padding: 0 !important;
        background: transparent !important;
        float: none;
        z-index: 1;
    }

    /* Keep the hamburger on the left */
    .header .mobile_btn {
        position: absolute;
        left: 20px;
        top: 0;
        z-index: 2;
    }

    /* Hide desktop-only header content */
    .header .molehub-desktop-actions {
        display: none !important;
    }

    /* Position account icon on the far right */
    .header .molehub-header-actions {
        position: absolute;
        right: 20px;
        top: 0;
        height: 65px;
        margin: 0 !important;
        z-index: 2;
    }

    /* Keep the account icon visible */
    .header .molehub-account-button {
        flex-shrink: 0;
    }

}

/* MoleHub authentication pages */

.login-body .login-wrapper.login-new {
    min-height: 100vh;
    height: auto;
    overflow: visible;
    background-position: bottom center;
    background-size: 100% 500px;
}

.login-body .login-wrapper.login-new > .row {
    justify-content: center;
    margin: 0;
}

.login-body .login-wrapper.login-new > .row > .col-lg-5 {
    width: 100%;
    max-width: 620px;
    flex: 0 0 auto;
}

.login-body .login-content.user-login {
    width: 100%;
    height: auto;
    min-height: 0;
    overflow: visible;
}

.login-body .login-content.user-login form {
    width: 100%;
}

.login-body .login-content.user-login .card {
    width: 100%;
}

.login-body .login-content.user-login .form-login input[type="checkbox"] {
    width: 16px;
    height: 16px;
    padding: 0;
}

@media (max-width: 575px) {
    .login-body .login-wrapper.login-new {
        background-size: auto 300px;
    }

    .login-body .login-content.user-login {
        padding: 15px;
    }

    .login-body .login-content.user-login .card-body {
        padding: 25px !important;
    }
}

/* Keep authentication content above the outer page wrapper */

.login-body .login-wrapper.login-new {
    position: relative;
    z-index: 1;
}

/* Full-width authentication background */

.login-body .login-wrapper.login-new {
    width: 100%;
    min-height: 100vh;
    background-size: 100% 500px;
    background-position: center bottom;
}

/* Authentication page: full-width outer layout */

.main-wrapper.login-body {
    width: 100%;
    max-width: none;
    min-height: 100vh;
    display: block;
}

.main-wrapper.login-body .account-content {
    width: 100%;
}

.main-wrapper.login-body .login-wrapper.login-new {
    width: 100%;
}

/* MoleHub login: full-width background and centred form */

.main-wrapper.login-body .account-content > .login-wrapper.login-new {
    width: 100%;
    max-width: none;
    min-height: 100vh;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-wrapper.login-body {
    background-image: url(../img/login/background.jpg);
    background-size: 100% auto;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    width: 100%;
}

@media (max-width: 767px) {
    .main-wrapper.login-body {
        background-size: cover;
        background-position: center;
    }
}

.login-body .authentication-check a {
    white-space: nowrap;
}

/* MoleHub DataTables */

.dt-container .dt-layout-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    margin: 0;
    padding: 15px 20px;
}

.dt-container .dt-layout-cell {
    display: flex;
    align-items: center;
    gap: 15px;
}

.dt-container .dt-layout-table {
    padding: 0;
}

.dt-container .dt-length select {
    border: 1px solid #e8e8e8;
    border-radius: 5px;
    padding: 6px 10px;
    background: transparent;
    color: inherit;
}

.dt-container .dt-paging {
    display: flex;
    align-items: center;
    gap: 5px;
}

.dt-container .dt-paging .dt-paging-button {
    border: 1px solid #e8e8e8;
    border-radius: 5px;
    padding: 6px 11px;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.dt-container .dt-paging .dt-paging-button.current {
    background: #fff4e6;
    border-color: #ff9f43;
    color: #ff9f43;
}

.dt-container .dt-paging .dt-paging-button.disabled {
    opacity: 0.4;
    cursor: default;
}

@media (max-width: 767px) {
    .dt-container .dt-layout-row:not(.dt-layout-table) {
        flex-direction: column;
        align-items: stretch;
    }

    .dt-container .dt-layout-cell {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* DataTables: allow the table to occupy the full width */
.dt-container .dt-layout-table .dt-layout-cell {
    display: block;
    width: 100%;
}

/* Ensure the table itself fills the available space */
.dt-container .dt-layout-table table.dataTable {
    width: 100% !important;
}

/* MoleHub custom DataTables search */

.search-set .search-input {
    position: relative;
    width: 260px;
}

.search-set .search-input input {
    width: 100%;
    padding: 9px 12px 9px 38px;
    border: 1px solid #e8e8e8;
    border-radius: 5px;
    font-size: 13px;
    background: #fff;
}

.search-set .search-input .btn-searchset {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: #6c757d;
}

.search-set .search-input input:focus {
    outline: none;
    border-color: #ff9f43;
    box-shadow: 0 0 0 2px rgba(255, 159, 67, 0.1);
}

/* MoleHub Users Page */
.molehub-user-action {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        padding: 0;
        border: 1px solid #e8e8e8;
        border-radius: 5px;
        background: transparent;
        cursor: pointer;
    }

    .molehub-user-action:hover {
        background: #f5f5f5;
    }
/* The theme authentication overlay is decorative and must not intercept form clicks. */
.main-wrapper.login-body::after {
    pointer-events: none;
}
