:root {
    --gold: #D4AF37;
    --base-bg: #0f172a;
    --main-text: #0F172A;
    --menu-item-color: #9ca3af;
}

footer {
    margin-top: auto;
    padding: 24px 0;
}

.material-symbols-outlined {
    font-family: 'Material Symbols Outlined' !important;
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-feature-settings: 'liga';
    font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
}

.material-symbols-outlined.logo {
    font-size: 30px;
    color: var(--gold);
}

/* ===== Sidebar Layout ===== */
.sidebar {
    width: 240px;
    flex-shrink: 0;
    background: var(--base-bg);
    color: #fff;
    transition: all 0.3s ease;
    padding: 0!important;
    height: 100vh;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    left: 0;
    z-index: 100;
}

.sidebar.collapsed {
    width: 80px;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-left: 32px;
    position: relative;
    height: 6rem;
}

.sidebar.collapsed .sidebar-header {
    padding-left: 0 !important;
    justify-content: center;
}

.brand {
    font-weight: 700;
    color: #d4af37;
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 16px;
    line-height: 1.25;
    letter-spacing: 0.025em;
}

.sidebar .menu-item .menu-text {
    font-size: 14px;
}

/* ===== Menu ===== */
.sidebar-menu {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.menu-top {
    flex: 1;
}

.menu-bottom {
    padding: 16px 8px 8px;
    border-top: 1px solid #1f293780;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-left: 1rem;
    height: 2.5rem;
    color: var(--menu-item-color);
    border-radius: 10px;
    text-decoration: none;
    margin-bottom: 8px;
    font-weight: 500;
}

.sidebar.collapsed .menu-item {
    justify-content: center;
    padding-left: 0;
}

.menu-item i {
    width: 20px;
    text-align: center;
    color: var(--gold);
}

.menu-item:hover,
.menu-item.active {
    color: #d4af37;
    background-color: #ffffff1a;
}

.menu-item.active {
    border-left: 4px solid var(--gold);
}

/* ===== Collapsed Mode ===== */
.sidebar.collapsed .menu-text,
.sidebar.collapsed .brand-text {
    display: none;
}

.sidebar-divider {
    border-color: #e5e7eb;
    margin: 8px 24px;
    opacity: 0.1;
}

.btn-toggle {
    background-color: var(--gold);
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s ease;
    position: absolute;
    right: -12px;
    top: 40px;
    transform: translateY(-50%);
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1),
            0 4px 6px -4px rgb(0 0 0 / 0.1);
    z-index: 9999;
    border: 0.5px solid var(--main-text);
}

.btn-toggle:hover {
    background: #c5a028;
}

.material-symbols-outlined.toggle-icon {
    font-size: 16px;
    color: var(--main-text);
}

.sidebar.collapsed .btn-toggle i {
    transform: rotate(180deg);
    transition: transform 0.3s ease;
}

.menu-item.logout:hover {
    background-color: #1f293780;
}

.menu-item-tooltip {
    position: fixed;
    background: #222;
    color: #fff;
    font-size: 14px;
    padding: 4px 6px;
    border-radius: 2px;
    white-space: nowrap;
    pointer-events: none;
    z-index: 9999;
    border: 1px solid #eee;

    opacity: 0;
    transition: opacity 0.2s ease;
}

/* ===== Content ===== */
#main-content {
    background: #f8f9fa;
    color: #1f2937;
    /* padding: 32px; */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.page-title {
    margin-bottom: 20px;
}

.content-wrapper {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 32px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.04);
}

.content-wrapper .main-title {
    font-size: 16px;
    font-weight: bold;
}

/* custom-page-title */

.custom-page-title {
    font-size: 20px;
    font-family: Playfair Display, serif;
    color: #0a1128;
    text-align: left;
    font-weight: 700;
}

.text-sm {
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.custom-page-description {
    color: #6b7280;
    font-family: Inter, sans-serif;
}

/* md */
@media (min-width: 768px) {
    .custom-page-title {
        font-size: 24px;
    }

    .custom-page-description {
        font-size: 1rem;
        line-height: 1.5rem;
    }
}

.btn-gold-important {
    background: linear-gradient(to right, #E6D089, #D4AF37) !important;
    min-width: 140px;
}

.btn-gold-important:hover {
    background: linear-gradient(to right, #E6D089, #D4AF37);
    color: #3d2b1f !important;
    box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;
    opacity: 0.9 !important;
    border-color: #e5e7eb !important;
}

.required-item::after {
    content: '＊' !important;
    position: relative !important;
    color: #FF0000 !important;
    font-size: 10px !important;
    vertical-align: top !important;
    top: 2px !important;
    left: 1px !important;
    line-height: 15px !important;
}

/* new top-menu */

.top-menu-header {
    background: #ffffff;
    border-bottom: 1px solid #E5E7EB;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 50;
    box-sizing: border-box;
}

.top-menu-header .d-header-left{
    display: flex;
    align-items: center;
    gap: 15px;
}

.top-menu-header .d-header-back {
    padding: 8px;
    border-radius: 50%;
    background: none;
    border: none;
    cursor: pointer;
    color: #111827;
    font-size: 18px;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.top-menu-header .d-header-back:hover {
    background: #f3f4f6;
}

.top-menu-header .d-header-back .d-arrow-left {
    width: 20px;
    height: 17px;
    font-style: normal;
    font-weight: 900;
    line-height: 1;
    display: inline-block;
    background-color: #111827;
    -webkit-mask: url('/assets/image/icon/arrow-left.svg') no-repeat center;
    mask: url('/assets/image/icon/arrow-left.svg') no-repeat center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.top-menu-header .d-breadcrumb {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: #6c757d;
}


.top-menu-header .d-breadcrumb a {
    color: #6c757d;
    text-decoration: none;
    transition: color .2s;
}

.top-menu-header .d-breadcrumb a:hover {
    color: #c9a24a;
}

.top-menu-header .d-breadcrumb .sep {
    margin: 0 8px;
    color: #adb5bd;
}

.top-menu-header .d-breadcrumb .current {
    font-weight: 600;
    color: #212529;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: normal;
}

.top-menu-header .d-breadcrumb a + a::before,
.top-menu-header .d-breadcrumb a + span::before {
    content: "/";
    margin: 0 8px;
    color: #adb5bd;
}

.top-menu-header .d-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.top-menu-header .d-bell {
    position: relative;
    padding: 8px;
    border-radius: 50%;
    cursor: pointer;
    background: none;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.top-menu-header .d-bell:hover {
    background: #f3f4f6;
}

.top-menu-header .d-bell-icon {
    width: 24px;
    height: 22px;
    display: inline-block;
    background-color: #4b5563 ;
    -webkit-mask: url('/assets/image/icon/icon-notifications.svg') no-repeat center;
    mask: url('/assets/image/icon/icon-notifications.svg') no-repeat center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

.top-menu-header .d-bell-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 10px;
    height: 10px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid #fff;
}

.top-menu-header .d-divider-v {
    height: 24px;
    width: 1px;
    background: #E5E7EB;
}

.top-menu-header .d-user {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    text-decoration: none;
}

.top-menu-header .d-user-name {
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    display: inline-block;
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.top-menu-header .d-user-av {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #E5E7EB;
    object-fit: cover;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    flex-shrink: 0;
}

.top-menu-header .d-user-av img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.top-menu-header .d-user-av i {
    font-size: 14px;
    color: #9ca3af;
}

/* new top-menu */

.modal-backdrop.show,
.swal2-container.swal2-backdrop-show {
    opacity: 1;
    background-color: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    transition: backdrop-filter 0.2s ease, background-color 0.2s ease;
}
