:root {
    /* GMASS Brand Colors - Màu đậm hơn, không chói mắt */
    --primary-color: #D4841A; /* Đậm hơn từ #F5A623 */
    --primary-color-dark: #B8741A;
    --primary-color-light: #E6941C;
    --accent-color: #B8741A; /* Đậm hơn, ít chói */
    --accent-color-dark: #A16518;
    --secondary-color: #475569; /* Đậm hơn từ #64748B */

    /* Success & Status Colors - Đậm và ít chói hơn */
    --success-color: #047857; /* Đậm hơn từ #059669 */
    --info-color: #0369A1; /* Đậm hơn từ #0284C7 */
    --warning-color: #B45309; /* Đậm hơn từ #D97706 */
    --danger-color: #B91C1C; /* Đậm hơn từ #DC2626 */

    /* Neutral Colors - Palette chuyên nghiệp đậm hơn */
    --sidebar-bg: #FFFFFF;
    --sidebar-text-color: #FFFFFF; /* Đậm hơn từ #374151 */
    --sidebar-icon-color: #FFFFFF; /* Đậm hơn từ #6B7280 */

    /*--sidebar-text-color: #1F2937; !* Đậm hơn từ #374151 *!
    --sidebar-icon-color: #4B5563; !* Đậm hơn từ #6B7280 *!*/
    --sidebar-active-bg: #FDE68A; /* Đậm hơn từ #FEF3E2 */
    --sidebar-active-text: #78350F; /* Đậm hơn từ #92400E */
    --sidebar-hover-bg: #FEF3E2;

    /* Background & Layout - Màu nền tối giản */
    --body-bg: #F5F5F5; /* Hơi đậm hơn từ #FAFAFA */
    --card-bg: #FFFFFF;
    --card-border-color: #D1D5DB; /* Đậm hơn từ #E5E7EB */
    /* Shadow đậm hơn một chút */
    --card-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12), 0 1px 2px 0 rgba(0, 0, 0, 0.08);
    --card-shadow-hover: 0 4px 6px -1px rgba(0, 0, 0, 0.12), 0 2px 4px -1px rgba(0, 0, 0, 0.08);

    /* Typography - Đậm hơn */
    --text-color: #0F172A; /* Đậm hơn từ #111827 */
    --text-muted-color: #475569; /* Đậm hơn từ #6B7280 */
    --text-light-color: #64748B; /* Đậm hơn từ #9CA3AF */

    /* Header */
    --header-bg: #FFFFFF;
    --header-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.12);

    /* Form Elements */
    --input-bg: #F8FAFC;
    --input-border: #CBD5E1; /* Đậm hơn từ #D1D5DB */
    --input-focus-border: var(--primary-color);
    --input-focus-shadow: 0 0 0 3px rgba(212, 132, 26, 0.15); /* Điều chỉnh theo màu primary mới */

    --vnwork-header:linear-gradient(90deg,rgb(0,23,68) 58%,rgb(0,90,255) 100%);

    --bg-color: #ecc754;
}

body {
    font-family: 'Inter', 'Segoe UI', 'Roboto', sans-serif;
    background: var(--body-bg);
    color: var(--text-color);
    font-size: 0.85rem; /* Giảm từ 0.95rem */
    line-height: 1.5; /* Giảm từ 1.6 */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
[x-cloak] {
    display: none !important;
}
h1, .h1 {
    font-size: 1.2rem;
}

h2, .h2 {
    font-size: 1.1rem;
}

h3, .h3 {
    font-size: 1rem;
}

h4, .h4 {
    font-size: 0.95rem;
}

h5, .h5 {
    font-size: 0.9rem;
}

h6, .h6 {
    font-size: 0.85rem;
}

/*#app {
    display: flex;
    min-height: 100vh;
}*/

/* Enhanced Sidebar */
/*#sidebar {
    background: var(--sidebar-bg);
    width: 260px; !* Giảm từ 280px *!
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    transition: all 0.2s ease; !* Giảm thời gian transition *!
    z-index: 1000;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.08); !* Shadow đơn giản hơn *!
    border-right: 1px solid var(--card-border-color);
}

#sidebar::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
    opacity: 0.6;
}

#sidebar .sidebar-header {
    padding: 1.2rem; !* Giảm từ 1.5rem *!
    height: 70px; !* Giảm từ 85px *!
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--card-border-color); 
    background: linear-gradient(135deg, #FFFBF7 0%, #FFF8F0 100%);
    position: relative;
}

#sidebar .sidebar-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 2px;
}

#sidebar .sidebar-header .logo-text {
    font-size: 1.5rem; !* Giảm từ 1.75rem *!
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    transition: all 0.3s ease;
    letter-spacing: -0.5px;
}

#sidebar .sidebar-menu {
    padding: 5px 0 5px 5px;
    height: calc(100vh - 85px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color-light) transparent;
}

#sidebar .sidebar-menu::-webkit-scrollbar {
    width: 4px;
}

#sidebar .sidebar-menu::-webkit-scrollbar-thumb {
    background: var(--primary-color-light);
    border-radius: 2px;
}

#sidebar .sidebar-menu .nav-link {
    display: flex;
    align-items: center;
    padding: 0.7rem 0.9rem; !* Giảm từ 0.875rem 1rem *!
    margin-bottom: 0.15rem; !* Giảm từ 0.25rem *!
    font-size: 0.85rem; !* Giảm từ 0.95rem *!
    border-radius: 8px; !* Góc nhỏ hơn, ít rounded *!
    color: var(--sidebar-text-color);
    font-weight: 500;
    transition: all 0.2s ease; !* Transition nhanh hơn *!
    position: relative;
    overflow: hidden;
}

#sidebar .sidebar-menu .nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--sidebar-active-bg);
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
}

#sidebar .sidebar-menu .nav-link:hover {
    background: var(--sidebar-hover-bg);
    color: var(--sidebar-active-text);
    !*transform: translateX(8px);*!
}

#sidebar .sidebar-menu .nav-link:hover::before {
    left: 0;
}

#sidebar .sidebar-menu .nav-link.active {
    background: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
    box-shadow: none; !* Bỏ box-shadow fancy *!
    transform: none; !* Bỏ transform *!

}

#sidebar .sidebar-menu .nav-link.active::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 60%;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 2px 0 0 2px;
}

#sidebar .sidebar-menu .nav-link.active .sidebar-icon {
    color: var(--primary-color);
}

#sidebar .sidebar-menu .nav-link .sidebar-icon {
    font-size: 1.1rem; !* Giảm từ 1.2rem *!
    margin-right: 0.8rem; !* Giảm từ 1rem *!
    width: 24px; !* Giảm từ 28px *!
    color: var(--sidebar-icon-color); 
    transition: all 0.3s ease;
}

#sidebar .sidebar-menu .nav-link .sidebar-text {
    transition: all 0.2s ease;
    white-space: nowrap;
    font-weight: 500;
}*/

/* --- Main Content --- */
/* Enhanced Main Content */
#main-content {
    /*width: calc(100% - 260px); !* Điều chỉnh theo sidebar mới *!
    margin-left: 260px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    min-height: 100vh;*/

    width: 100%;
    margin-left: 0;
    min-height: 100vh;
    z-index: 1021;
}

#main-header {
    background: var(--vnwork-header);
    box-shadow: var(--header-shadow);
    height: 65px; /* Giảm từ 80px */
    padding: 0 1.5rem; /* Giảm từ 2rem */
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--card-border-color);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 100;
}

/* --- Collapsed Sidebar State (Desktop) --- */
/*body.sidebar-mini #sidebar {
    width: 70px; !* Giảm từ 80px *!
}

body.sidebar-mini #sidebar .sidebar-header .logo-text {
    opacity: 0;
    transform: scale(0.8);
    display: none;
}

body.sidebar-mini #sidebar .sidebar-menu .nav-link .sidebar-text {
    display: none;
}

body.sidebar-mini #main-content {
    width: calc(100% - 70px);
    margin-left: 70px;
}

body.sidebar-mini #sidebar .sidebar-menu .nav-link {
    justify-content: center;
    width: 55px; !* Giảm từ 60px *!
    padding: 0.8rem; !* Giảm từ 1rem *! 
}

body.sidebar-mini #sidebar .sidebar-menu .nav-link .sidebar-icon {
    margin-right: 0;
}*/


/* --- Mobile View --- */
/*@media (max-width: 992px) {
    #sidebar {
        left: -300px;
        z-index: 1031;
        width: 280px;
    }

    #main-content {
        width: 100%;
        margin-left: 0;
    }

    body.mobile-sidebar-open #sidebar {
        left: 0;
    }

    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        !* background: linear-gradient(135deg, rgba(245, 166, 35, 0.1) 0%, rgba(255, 140, 0, 0.1) 100%);
         backdrop-filter: blur(4px);*!
        background: rgba(0, 0, 0, 0.5); !* Solid overlay thay vì gradient *!
        z-index: 1030;
        display: none;
    }

    body.mobile-sidebar-open .sidebar-overlay {
        display: block;
    }

    !* Reset desktop mini-sidebar styles for mobile *!
    body.sidebar-mini #sidebar {
        width: 260px; !* Consistent với desktop *!
        left: -300px;
    }

    body.sidebar-mini #sidebar .sidebar-header .logo-text,
    body.sidebar-mini #sidebar .sidebar-menu .nav-link .sidebar-text {
        opacity: 1;
        transform: none;
    }

    body.sidebar-mini #main-content {
        width: 100%;
        margin-left: 0;
    }
}*/

/* Enhanced Cards */
.card {
    border-radius: 5px;
    border: 1px solid var(--card-border-color);
    box-shadow: var(--card-shadow);
    background: var(--card-bg);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-color) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: none;
}

.card:hover {
    box-shadow: var(--card-shadow-hover);
}

.card:hover::before {
    opacity: 1;
}

.card-header {
    background: #FAFBFC; /* Solid background nhẹ */
    border-bottom: 1px solid var(--card-border-color);
    font-weight: 600;
    padding: 1.2rem; /* Giảm từ 1.75rem */
    font-size: 1rem; /* Giảm từ 1.1rem */
    color: var(--text-color);
    display: flex;
    align-items: center;
}

.card-body {
    padding: 1.2rem; /* Giảm từ 1.75rem */
}

/* CẬP NHẬT: Thêm style cho Form & Button */
/* UPDATE: Add styles for Forms & Buttons */
.form-control, .form-select {
    border-radius: 6px;
    padding: 0.5rem 0.8rem; /* Giảm từ 0.75rem 1rem */
    font-size: 0.85rem; /* Giảm từ 0.95rem */
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    color: var(--text-color);
}

.form-control:focus, .form-select:focus {
    background: #FFFFFF;
    border-color: var(--input-focus-border);
    outline: 0;
    box-shadow: var(--input-focus-shadow);
}

.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label,
.form-floating > .form-select ~ label {
    color: var(--primary-color);
    font-weight: 500;
}

.input-group-lg > .form-control, .input-group-lg > .form-select {
    padding: 0.65rem 0.9rem; /* Giảm từ 0.75rem 1rem */
    font-size: 0.9rem; /* Giảm từ 1rem */
}
.input-group-fix > input:nth-child(4){
    border-top-right-radius: 6px!important;
    border-bottom-right-radius: 6px !important;
}
    /* Enhanced Buttons */
.btn:hover {
    border-color: var(--primary-color);
}

.btn-primary {
    background: var(--primary-color); /* Solid color thay vì gradient */
    color: #FFFFFF;
    box-shadow: 0 2px 4px rgba(245, 166, 35, 0.2); /* Shadow nhẹ hơn */
    border: 1px solid var(--primary-color);
}

.btn-primary:hover {
    background: var(--primary-color-dark);
    box-shadow: 0 4px 12px rgba(245, 166, 35, 0.25);
}

.btn-outline-primary {
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: #FFFFFF;
    border-color: var(--primary-color);
}

.btn-outline-secondary {
    border: 1px solid var(--secondary-color);
    color: var(--secondary-color);
    background: transparent;
}

.btn-outline-info {
    border: 1px solid var(--info-color);
    color: var(--info-color);
    background: transparent;
}

.btn-outline-success {
    border: 1px solid var(--success-color);
    color: var(--success-color);
    background: transparent;
}

.btn-outline-warning {
    border: 1px solid var(--warning-color);
    color: var(--warning-color);
    background: transparent;
}

.btn-outline-danger {
    border: 1px solid var(--danger-color);
    color: var(--danger-color);
    background: transparent;
}

.btn-sm {
    padding: 0.35rem 0.7rem;
    font-size: 0.8rem;
}

.btn-lg {
    padding: 0.65rem 1.2rem;
    font-size: 0.95rem;
}

/* Enhanced Dashboard Cards */
.card .border-left-primary {
    border-left: 4px solid var(--primary-color) !important;
    position: relative;
}

.card .border-left-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
    display: none;
}

.card .border-left-success {
    border-left: 4px solid var(--success-color) !important;
}

.card .border-left-info {
    border-left: 4px solid var(--info-color) !important;
}

.card .border-left-warning {
    border-left: 4px solid var(--warning-color) !important;
}

/* Enhanced Text Utilities */
.text-xs {
    font-size: 0.7rem; /* Giảm từ 0.8rem */
    font-weight: 500;
}

.text-gray-300 {
    color: var(--text-light-color) !important;
}

/* Custom GMASS Components */
.gmass-badge {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    color: white;
    padding: 0.35rem 0.8rem; /* Giảm từ 0.5rem 1rem */
    font-size: 0.75rem; /* Giảm từ 0.85rem */
    border-radius: 20px;
    font-weight: 600;
    display: inline-block;
}

.gmass-alert {
    border-radius: 12px;
    border: none;
    padding: 1rem; /* Giảm từ 1.25rem */
    position: relative;
    overflow: hidden;
}

.gmass-alert::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-color);
}

.gmass-progress {
    height: 8px;
    border-radius: 4px;
    background: #f0f0f0;
    overflow: hidden;
}

.gmass-progress .progress-bar {
    background: linear-gradient(90deg, var(--primary-color) 0%, var(--accent-color) 100%);
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s ease;
}

/*

!* Styling cho TomSelect tree structure *!
.ts-dropdown .ts-dropdown-content .option-item {
    padding: 0 !important;
    border: none !important;
    background: none !important;
}

.ts-dropdown .ts-dropdown-content .option-item:hover {
    background-color: #f8f9fa !important;
}

.ts-dropdown .ts-dropdown-content .option-item .form-check {
    display: flex !important;
    align-items: center !important;
    width: 100% !important;
}

.ts-dropdown .ts-dropdown-content .option-item .form-check-input {
    margin-top: 0 !important;
    margin-right: 8px !important;
}

.ts-dropdown .ts-dropdown-content .option-item .form-check-label {
    margin-bottom: 0 !important;
    flex: 1 !important;
}

!* Chevron icons *!
.ts-dropdown .ts-dropdown-content .option-item .bi {
    color: #6c757d !important;
    font-size: 12px !important;
    min-width: 16px !important;
    cursor: pointer !important;
}

!* Selected items styling *!
.ts-control .item {
    background-color: #007bff !important;
    color: white !important;
    border: 1px solid #007bff !important;
    border-radius: 4px !important;
    padding: 4px 8px !important;
    margin: 2px !important;
    display: inline-flex !important;
    align-items: center !important;
}

.ts-control .item .remove {
    margin-left: 8px !important;
    cursor: pointer !important;
    font-weight: bold !important;
}

!* Dropdown max height và scroll *!
.ts-dropdown .ts-dropdown-content {
    max-height: 300px !important;
    overflow-y: auto !important;
}

!* Search input styling *!
.ts-dropdown-content .ts-dropdown-input {
    border-bottom: 1px solid #dee2e6 !important;
    padding: 8px 12px !important;
    margin-bottom: 4px !important;
} */
/* Custom Tom Select styles */
.ts-control {
    min-height: 35px !important; /* Giảm từ 40px */
    border-radius: 10px !important;
    border: 1px solid var(--input-border) !important;
    background: var(--input-bg) !important;
}

/* Parent item styles */
.ts-dropdown .parent-option {
    background: #f8f9fa !important;
    font-weight: bold !important;
    cursor: pointer !important;
    position: relative !important;
    font-size: 0.85rem;
    padding: 6px 10px !important; /* Giảm từ 8px 12px */
    border-bottom: 1px solid #dee2e6 !important;
    border-left: 3px solid #007bff !important;
}

.ts-dropdown .parent-option:hover {
    background: #e9ecef !important;
}

.ts-dropdown .parent-option::before {
    content: '📁 ';
    margin-right: 5px;
}

/* Child item styles */
.ts-dropdown .child-option {
    padding-left: 25px !important; /* Giảm từ 35px */
    font-size: 0.8rem;
    position: relative !important;
}

.ts-dropdown .child-option::before {
    content: '└─ ';
    margin-right: 5px;
    color: #6c757d;
    position: absolute;
    left: 0px;
}

/* Checkbox styles */
.parent-checkbox, .child-checkbox {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
}

.parent-checkbox:indeterminate {
    opacity: 0.6;
}

.ts-dropdown .option.selected {
    background-color: var(--primary-color) !important;
    color: white !important;
}


.ts-control.focus {
    border-color: var(--primary-color) !important;
    box-shadow: var(--input-focus-shadow) !important;
}

.ts-dropdown .option.parent-option {
    background: linear-gradient(135deg, #FFF5E6 0%, #FFEBCC 100%) !important;
    font-weight: 600 !important;
    border-left: 3px solid var(--primary-color) !important;
}

.ts-dropdown .option.child-option {
    padding-left: 2.5rem !important;
    position: relative !important;
}

.ts-dropdown .option.selected {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%) !important;
    color: white !important;
}

/* Timeline styles */
.timeline {
    list-style: none;
    padding: 15px 0 15px; /* Giảm từ 20px 0 20px */
    position: relative;
}

.timeline:before {
    top: 0;
    bottom: 0;
    position: absolute;
    content: " ";
    background: var(--primary-color); /* Solid thay vì gradient */
    left: 25px;
    margin-left: -2px;
    width: 4px;
}

.timeline > li {
    margin-bottom: 15px; /* Giảm từ 20px */
    position: relative;
}

.timeline > li:before, .timeline > li:after {
    content: " ";
    display: table;
}

.timeline > li:after {
    clear: both;
}

.timeline > li > .timeline-panel {
    width: calc(100% - 75px);
    float: right;
    border: 1px solid #d4d4d4;
    border-radius: 0.5rem;
    padding: 15px; /* Giảm từ 20px */
    position: relative;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
}

.timeline > li > .timeline-panel:before {
    position: absolute;
    top: 15px;
    left: -15px;
    display: inline-block;
    border-top: 15px solid transparent;
    border-right: 15px solid #ccc;
    border-left: 0 solid #ccc;
    border-bottom: 15px solid transparent;
    content: " ";
}

.timeline > li > .timeline-panel:after {
    position: absolute;
    top: 16px;
    left: -14px;
    display: inline-block;
    border-top: 14px solid transparent;
    border-right: 14px solid #fff;
    border-left: 0 solid #fff;
    border-bottom: 14px solid transparent;
    content: " ";
}

.timeline > li > .timeline-badge {
    color: #fff;
    width: 40px; /* Giảm từ 50px */
    height: 40px;
    line-height: 40px;
    font-size: 1.2em; /* Giảm từ 1.4em */
    top: 12px; /* Điều chỉnh vị trí */
    text-align: center;
    position: absolute;
    left: 5px;
    margin-right: -25px;
    z-index: 1;
    border-radius: 50%;
    background: var(--primary-color); /* Solid thay vì gradient */
    border: 3px solid white;
    box-shadow: 0 2px 8px rgba(245, 166, 35, 0.2);

}

/* Add this CSS to your site stylesheet or in a <style> block */

.pagination {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
    display: flex;
    gap: 0.5rem;
}

.page-item {
    display: inline-block;
}

.page-link {
    display: inline-block;
    padding: 0.3rem 0.6rem; /* Giảm từ 0.4rem 0.75rem */
    font-size: 0.8rem;
    text-decoration: none;
    cursor: pointer;
    user-select: none;
    border-radius: 8px !important;
    margin: 0 2px;
    border: 1px solid var(--input-border);
    color: var(--text-color);
    transition: all 0.3s ease;

}

.page-link svg {
    width: 1rem;
    height: 1rem;
}

.page-link:hover:not(.disabled):not(.btn-active) {
    background: var(--sidebar-hover-bg);
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.page-item.disabled .page-link,
.page-link.disabled {
    color: #6c757d;
    pointer-events: none;
    background-color: #fff;
    border-color: #dee2e6;
    cursor: default;
}

.page-item.active .page-link,
.page-link.btn-active {
    z-index: 1;
    color: #fff;
    cursor: default;
    background: var(--primary-color); /* Solid thay vì gradient */
    border-color: var(--primary-color);
    box-shadow: 0 2px 4px rgba(245, 166, 35, 0.2); /* Shadow nhẹ hơn */
}

.page-link.btn {
    padding: 0.2rem 0.4rem; /* Giảm từ 0.25rem 0.5rem */
    font-size: 0.75rem; /* Giảm từ 0.875rem */
}

.join {
    margin-top: 1rem;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--primary-color) 0%, var(--accent-color) 100%);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--primary-color-dark) 0%, var(--accent-color-dark) 100%);
}

/* Loading States */
@keyframes gmass-pulse {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
    100% {
        opacity: 1;
    }
}

.gmass-loading {
    animation: gmass-pulse 1.5s ease-in-out infinite;
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .card-body {
        padding: 1rem; /* Giảm từ 1.25rem */
    }

    .btn {
        padding: 0.5rem 1rem; /* Giảm từ 0.65rem 1.25rem */
        font-size: 0.8rem; /* Giảm từ 0.9rem */
    }

    #main-header {
        padding: 0 1rem;
        height: 60px; /* Giảm từ 70px */
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    :root {
        --sidebar-bg: #1a1a1a;
        --card-bg: #2d2d2d;
        --text-color: #e0e0e0;
        --body-bg: linear-gradient(135deg, #0f0f0f 0%, #1a1a1a 100%);
    }
}

.pipeline-container {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding: 16px 0;
    min-height: 500px;
}

.pipeline-column {
    min-width: 280px;
    max-width: 300px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.pipeline-header {
    padding: 12px 16px;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 12px 12px 0 0;
    border-bottom: 1px solid #e9ecef;
    font-weight: 600;
    font-size: 14px;
    color: #495057;
    display: flex;
    align-items: center;
}

.pipeline-body {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.candidate-card {
    background: white;
    border-radius: 8px;
    padding: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.candidate-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-color: #dee2e6;
}

.candidate-card-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #212529;
    line-height: 1.3;
}

.candidate-card-position {
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 8px;
    line-height: 1.3;
}

.candidate-card-footer {
    font-size: 11px;
    color: #868e96;
}

.candidate-card img {
    width: 36px;
    height: 36px;
}

/* Custom toggle buttons cho status filter */
.status-toggle {
    display: inline-block;
    margin: 4px;
}

.status-toggle input[type="checkbox"] {
    display: none;
}

.status-toggle-label {
    display: inline-block;
    padding: 6px 12px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
    font-weight: 500;
    color: #495057;
    user-select: none;
}

.status-toggle-label:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.status-toggle input[type="checkbox"]:checked + .status-toggle-label {
    background: var(--status-color, #007bff);
    border-color: var(--status-color, #007bff);
    color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Time filter buttons */
.time-filter-btn {
    font-size: 13px;
    padding: 6px 12px;
    border-radius: 20px;
}

/* Header improvements */
.page-header {
    margin-bottom: 20px;
}

.page-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #212529;
    margin: 0;
}

/* Filter card improvements */
.filter-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.filter-card-body {
    padding: 16px;
}

.filter-label {
    font-size: 14px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 12px;
}

.apply-filter-btn {
    font-size: 13px;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .pipeline-container {
        gap: 12px;
    }

    .pipeline-column {
        min-width: 250px;
        max-width: 270px;
    }

    .page-title {
        font-size: 20px;
    }

    .time-filter-btn {
        font-size: 12px;
        padding: 4px 8px;
    }
}

.form-label-required {
    position: relative;
    display: inline-block;
}

.form-label-required::after {
    content: "*";
    color: #dc3545; /* Bootstrap danger color */
    margin-left: 4px;
    font-weight: bold;
}

/* 15. TABLE SPACING - Thu gọn tables */
.table th,
.table td {
    padding: 0.6rem; /* Giảm default Bootstrap padding */
    font-size: 0.85rem;
}

.table-sm th,
.table-sm td {
    padding: 0.4rem;
    font-size: 0.8rem;
}

.swal-wide {
    width: 600px !important;
}

.swal2-popup .swal2-html-container {
    white-space: pre-line; 
}

/* --- LOẠI BỎ MARGIN CHO MAIN CONTENT --- */


/* --- MAIN HEADER & TOP NAVBAR STYLING --- */
/*#main-header {
    background: var(--header-bg);
    box-shadow: var(--header-shadow);
    padding: 0; !* Remove padding to allow navbar to fill *!
    border-bottom: 1px solid var(--card-border-color);
    position: sticky;
    top: 0;
    z-index: 1020;
}*/

#main-header .navbar {
    padding: 0.5rem 1rem;
    width: 100%;
    min-height: 60px;
}

#main-header .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#main-header .logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- NAVBAR LINKS & DROPDOWNS --- */
.navbar-nav .nav-link {
    color: var(--sidebar-text-color);
    font-weight: 500;
    font-size: 0.85rem;
    padding: 0.5rem 0.8rem;
    border-radius: 6px;
    transition: all 0.2s ease;
}
.navbar-nav > .nav-item{
    margin-left: 4px;
    margin-right: 4px;
}
.navbar-nav > .nav-item > .nav-link {
    display: flex;
    align-items: center;
    border-radius: 50px; /* Bo tròn thành hình viên thuốc (pill shape) */
    background: transparent;
    color: var(--sidebar-text-color);
    font-weight: 500;
    gap: 0.5rem; /* Mặc định không có khoảng cách giữa icon và text ẩn */
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); /* Animation chính */
}

.navbar-nav > .nav-item > .nav-link > .bi {
    font-size: 0.85rem; /* Kích thước icon */
    transition: all 0.2s ease;
}

/*
.navbar-nav > .nav-item:not(.dropdown) > .nav-link > span {
    white-space: nowrap; !* Ngăn text xuống dòng *!
    overflow: hidden; !* Ẩn phần text thừa *!
    width: 0; !* Chiều rộng bằng 0 để ẩn *!
    opacity: 0; !* Hoàn toàn trong suốt *!
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.2s ease-out;
}
*/

.navbar-nav > .nav-item:not(.dropdown):hover > .nav-link,
.navbar-nav > .nav-item:not(.dropdown) > .nav-link:focus {
    background: var(--sidebar-hover-bg);
    color: var(--sidebar-active-text);
    /*gap: 0.75rem; !* Tạo khoảng cách khi text hiện ra *!*/
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08); /* Đổ bóng nhẹ nhàng */
}
/*
.navbar-nav > .nav-item:not(.dropdown):hover > .nav-link > span,
.navbar-nav > .nav-item:not(.dropdown) > .nav-link:focus > span {
    width: auto; !* Cho phép width tự động mở rộng theo nội dung *!
    opacity: 1; !* Hiện text *!
}*/

.navbar-nav > .nav-item.dropdown > .nav-link {
    gap: 0.5rem; /* Luôn có khoảng cách cho icon và text */
}

.navbar-nav > .nav-item.dropdown > .nav-link:hover,
.navbar-nav > .nav-item.dropdown > .nav-link.show {
    color: var(--primary-color);
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    background-color: var(--sidebar-hover-bg);
    color: var(--sidebar-active-text);
}

.navbar-nav .nav-link.active {
    font-weight: 600;
    color: var(--primary-color);
}

.dropdown-menu {
    border-radius: 8px;
    border: 1px solid var(--card-border-color);
    box-shadow: var(--card-shadow);
    font-size: 0.875rem;
    padding: 0.5rem 0;
}

.dropdown-item {
    padding: 0.5rem 1rem;
    font-weight: 500;
    display: flex;
    align-items: center;
}

.dropdown-item:hover, .dropdown-item:focus {
    background-color: var(--sidebar-hover-bg);
    color: var(--sidebar-active-text);
}

.dropdown-item.active {
    background-color: var(--sidebar-active-bg);
    color: var(--sidebar-active-text);
}


/* --- HOVER EFFECT FOR DESKTOP DROPDOWNS --- */
@media (min-width: 992px) {
    .navbar-nav .dropdown:hover > .dropdown-menu {
        display: block;
        margin-top: 0; /* Ensures menu appears directly below toggle */
    }
}

/* --- MOBILE NAVBAR --- */
@media (max-width: 991.98px) {
    #main-header .navbar-collapse {
        margin-top: 0.5rem;
        border-top: 1px solid var(--card-border-color);
        padding-top: 0.5rem;
    }

    .navbar-nav .nav-item {
        width: 100%;
    }

    #main-header .ms-auto {
        margin-top: 0.5rem;
    }
}

.sortable-ghost {
    opacity: 0.4;
    background-color: #e3f2fd;
}
 
.ts-dropdown {
    z-index: 10000000 !important;
}

.bg-gradient-header {
    /*background: linear-gradient(90deg, rgb(0 43 123) 58%, rgb(4 77 210) 100%);*/
    background: var(--bg-color)!important;
    color: #000;
    height: 45px;
}

.bg-gradient-header th{
    background: var(--bg-color)!important;
    color: #000;
}

.table-jobs th, .table-jobs td {
    padding: 0.1rem;
}

.closed-job-row td {
    background-color: #ffe6e6;
}
.table-jobs .sticky-top {
    background-color: var(--bg-color)!important;
    position: sticky;
    top: 65px;
    box-shadow: 0 2px 2px -1px rgba(0, 0, 0, 0.4);
    z-index: 1;
}
.table-jobs .sticky-top th,.table-jobs .sticky-top td{
    background-color: var(--bg-color)!important;
}

.table-jobs .sticky-top th {
    box-shadow: 0 2px 2px -1px rgba(0, 0, 0, 0.4);
}

.break-line {
    word-wrap: break-word;
    word-break: break-word;
}
.job-table-header{
    height: 45px;
    vertical-align: middle;
}
.description-preview{
    max-height: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
}
.company-header-row td {
    height: 30px!important;
}