body {
    --tw-sidebar-width: 200px;
}
.layui-layout-admin .tw-app-header {
    display: flex;
    align-items: center;
    gap: 0;
    height: 50px;
    padding: 0;
    background: #303845 !important;
}
.layui-layout-admin .tw-app-header .tw-brand {
    position: static;
    display: flex;
    flex: 0 0 var(--tw-sidebar-width);
    align-items: center;
    gap: 10px;
    box-sizing: border-box;
    width: var(--tw-sidebar-width);
    min-width: 0;
    height: 50px;
    padding: 0 16px;
    overflow: hidden;
    border-right: 1px solid #ffffff0d;
    color: #f0f3f6 !important;
    font-size: 16px;
    font-weight: 400;
    line-height: 22px;
    white-space: nowrap;
}
.tw-app-header .tw-brand-mark {
    display: block;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    margin: 0 !important;
    border-radius: 6px;
    object-fit: contain;
}
.tw-app-header .tw-brand-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.tw-app-header .tw-menu-toggle {
    display: flex;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0 12px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #d8e0e8;
    cursor: pointer;
}
.tw-app-header .tw-menu-toggle:hover {
    background: #3d4755;
    color: #fff;
}
.tw-app-header .tw-menu-toggle > i {
    font-size: 18px;
    line-height: 1;
}
.tw-app-header .tw-header-page {
    flex: 1 1 auto;
    min-width: 0;
    margin: 0 16px 0 0;
    overflow: hidden;
    color: #b6c0cc;
    font-size: 13px;
    line-height: 22px;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.layui-layout-admin #tw-sidebar {
    display: flex !important;
    flex-direction: column;
    box-sizing: border-box;
    top: 50px;
    bottom: 0;
    width: var(--tw-sidebar-width);
    min-width: 0;
    min-height: 0;
    height: auto;
    overflow: hidden;
    background: #303845 !important;
}
#tw-sidebar .layui-side-scroll {
    position: static;
    flex: 1 1 auto;
    box-sizing: border-box;
    width: 100% !important;
    min-height: 0;
    height: auto;
    padding: 8px 0;
    overflow-x: hidden;
    overflow-y: auto;
    background: transparent !important;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #536072 transparent;
}
#tw-sidebar #nav,
#tw-sidebar .tw-help-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    box-sizing: border-box;
    width: 100% !important;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent !important;
    list-style: none;
}
#tw-sidebar .tw-help-nav {
    flex: 0 1 auto;
    min-height: 0;
    max-height: 147px;
    padding: 8px 0 4px;
    overflow-x: hidden;
    overflow-y: auto;
    border-top: 1px solid #ffffff14;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #536072 transparent;
}
#tw-sidebar .nav-item,
#tw-sidebar .nav-item.layui-this {
    display: block;
    flex: 0 0 42px;
    min-height: 42px;
    height: 42px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent !important;
    line-height: 42px;
}
#tw-sidebar .nav-item > a {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    box-sizing: border-box;
    height: 42px;
    margin: 0 8px;
    padding: 0 12px;
    overflow: hidden;
    border-radius: 6px;
    color: #dce2e9 !important;
    font-size: 14px;
    font-weight: 400;
    line-height: 42px;
    white-space: nowrap;
    transition: background-color .12s ease, color .12s ease;
}
#tw-sidebar .nav-item:not(.layui-this) > a:hover,
#tw-sidebar .nav-item:not(.layui-this) > a:focus-visible {
    background: #3d4755 !important;
    color: #fff !important;
}
#tw-sidebar .nav-item.layui-this > a,
#tw-sidebar .nav-item.layui-this > a:hover,
#tw-sidebar .nav-item.layui-this > a:focus-visible {
    background: #087f73 !important;
    color: #fff !important;
}
#tw-sidebar .nav-item > a > .nav-icon {
    display: block;
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    margin: 0 !important;
    color: inherit !important;
    font-size: 18px;
    line-height: 18px;
    text-align: center;
}
#tw-sidebar .tw-nav-label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
#tw-sidebar .layui-nav-bar,
#tw-sidebar .layui-this::after {
    display: none !important;
}
#tw-sidebar .tw-sidebar-footer {
    flex: 0 0 34px;
    box-sizing: border-box;
    min-height: 34px;
    padding: 7px 16px;
    overflow: hidden;
    color: #99a5b4;
    font-size: 11px;
    line-height: 20px;
    white-space: nowrap;
}
#tw-sidebar .tw-sidebar-version {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
}
.layui-layout-admin .layui-body,
.layui-layout-admin .layui-footer,
.tw-savebar {
    left: var(--tw-sidebar-width) !important;
}
.tw-app-header .tw-menu-toggle:focus-visible,
#tw-sidebar .nav-item > a:focus-visible {
    outline: 2px solid #afc1d4;
    outline-offset: -2px;
}
.tw-nav-tooltip {
    position: fixed;
    z-index: 1200;
    box-sizing: border-box;
    max-width: calc(100vw - 80px);
    padding: 8px 10px;
    border-radius: 6px;
    background: #26313f;
    color: #fff;
    box-shadow: 0 4px 14px #15202e33;
    font-size: 13px;
    line-height: 20px;
    white-space: nowrap;
    pointer-events: none;
}
.tw-nav-tooltip[hidden] {
    display: none;
}
@media (min-width: 751px) {
    body.tw-sidebar-collapsed {
        --tw-sidebar-width: 64px;
    }
    .tw-sidebar-collapsed .tw-app-header .tw-brand {
        justify-content: center;
        padding: 0;
    }
    .tw-sidebar-collapsed #tw-sidebar .nav-item > a {
        justify-content: center;
        gap: 0;
        padding: 0;
    }
    .tw-sidebar-collapsed .tw-brand-name,
    .tw-sidebar-collapsed #tw-sidebar .tw-nav-label {
        position: absolute;
        width: 1px;
        height: 1px;
        margin: -1px;
        padding: 0;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
    }
    .tw-sidebar-collapsed #tw-sidebar .tw-sidebar-footer {
        padding-right: 4px;
        padding-left: 4px;
        font-size: 10px;
        text-align: center;
    }
    .tw-menu-backdrop {
        display: none !important;
    }
}
@media (max-width: 750px) {
    body,
    body.tw-sidebar-collapsed {
        --tw-sidebar-width: 0px;
    }
    .layui-layout-admin .tw-app-header {
        gap: 0;
        padding: 0;
    }
    .layui-layout-admin .tw-app-header .tw-brand {
        flex: 0 1 auto;
        gap: 8px;
        width: auto;
        max-width: calc(100% - 100px);
        padding: 0 12px;
        border-right: 0;
        font-size: 15px;
    }
    .tw-app-header .tw-brand-mark {
        flex-basis: 26px;
        width: 26px;
        height: 26px;
    }
    .tw-app-header .tw-menu-toggle {
        flex-basis: 34px;
        width: 34px;
        height: 34px;
        margin: 0 6px;
    }
    .tw-app-header .tw-header-page {
        max-width: none;
        margin: 0 12px 0 2px;
        font-size: 12px;
        text-align: right;
    }
    .layui-layout-admin #tw-sidebar {
        z-index: 1101;
        width: 220px;
        visibility: hidden;
        transform: translateX(-100%);
    }
    .tw-menu-open .layui-layout-admin #tw-sidebar {
        visibility: visible;
        transform: translateX(0);
    }
    .tw-menu-backdrop:not([hidden]) {
        position: fixed;
        z-index: 1100;
        inset: 50px 0 0;
        display: block;
        width: 100%;
        border: 0;
        background: #15202e66;
    }
}
