﻿
/* =========================================
   USERS PAGE STYLES
   ========================================= */

/* Users Container */
.usr-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0;
}

/* Header Section */
.usr-header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.usr-main-title {
    color: var(--secondary-color, #2c3e50);
    font-weight: 600;
    margin: 0;
    font-size: 24px;
}

/* Create Button */
.usr-create-btn {
    background: linear-gradient(135deg, #1F5A7A 0%, #2E6F95 50%, #4FA3D1 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 24px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

    .usr-create-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(31, 90, 122, 0.3);
        color: white;
        text-decoration: none;
    }

/* Alert Messages */
.usr-message-box {
    border-radius: 8px;
    padding: 15px 20px;
    margin-bottom: 20px;
    border: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
}

.usr-message-error {
    background-color: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    border-left: 4px solid #e74c3c;
}

.usr-message-success {
    background-color: rgba(39, 174, 96, 0.1);
    color: #27ae60;
    border-left: 4px solid #27ae60;
}

/* Table Container */
.usr-table-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    padding: 20px;
    overflow-x: auto;
}

/* Users Table Styling */
#user {
    width: 100% !important;
    border-collapse: separate;
    border-spacing: 0;
    border: none;
}

    #user thead th {
        background: linear-gradient(135deg, #E3F2FB 0%, #CFE8F6 100%);
        color: #1F5A7A;
        font-weight: 700;
        font-size: 13px;
        text-align: center;
        padding: 14px 12px;
        border-bottom: 2px solid #B8DDF1;
        white-space: nowrap;
    }

        #user thead th:hover {
            background: linear-gradient(135deg, #CFE8F6 0%, #B8DDF1 100%);
            cursor: pointer;
        }

        /* Sorting icons */
        #user thead th.sorting:after,
        #user thead th.sorting_asc:after,
        #user thead th.sorting_desc:after {
            position: absolute;
            right: 8px;
            top: 50%;
            transform: translateY(-50%);
            font-size: 11px;
            opacity: 0.6;
            color: #1F5A7A;
        }

    #user tbody td {
        padding: 12px;
        border-bottom: 1px solid #e9ecef;
        vertical-align: middle;
        font-size: 13px;
        text-align: center;
        color: #4a5568;
    }

    #user tbody tr {
        transition: all 0.2s ease;
    }

        #user tbody tr:hover {
            background-color: rgba(31, 90, 122, 0.05);
        }

        #user tbody tr:nth-child(even) {
            background-color: #f8fafc;
        }

            #user tbody tr:nth-child(even):hover {
                background-color: rgba(31, 90, 122, 0.05);
            }

/* Action Icons */
.usr-action-links {
    display: flex;
    gap: 8px;
    justify-content: center;
    align-items: center;
}

    .usr-action-links a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        border-radius: 6px;
        transition: all 0.2s ease;
        text-decoration: none;
    }

        .usr-action-links a:hover {
            background-color: #e9ecef;
            transform: translateY(-2px);
        }

    .usr-action-links img {
        width: 18px;
        height: 18px;
        transition: all 0.2s ease;
    }

    .usr-action-links a:hover img {
        transform: scale(1.1);
    }

.usr-reset-btn {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    transition: all 0.2s ease;
    background: none;
    border: none;
}

    .usr-reset-btn:hover {
        background-color: #e9ecef;
        transform: translateY(-2px);
    }

    .usr-reset-btn img {
        width: 18px;
        height: 18px;
        transition: all 0.2s ease;
    }

/* DataTables Custom Styling */
.dataTables_wrapper {
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

.dataTables_filter input {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    transition: all 0.2s ease;
}

    .dataTables_filter input:focus {
        border-color: #1F5A7A;
        box-shadow: 0 0 0 3px rgba(31, 90, 122, 0.1);
        outline: none;
    }

.dataTables_length select {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    transition: all 0.2s ease;
}

    .dataTables_length select:focus {
        border-color: #1F5A7A;
        box-shadow: 0 0 0 3px rgba(31, 90, 122, 0.1);
        outline: none;
    }

.dataTables_paginate .paginate_button {
    border: 1px solid #e9ecef !important;
    border-radius: 6px !important;
    padding: 6px 12px !important;
    margin: 0 2px !important;
    transition: all 0.2s ease !important;
    background: white !important;
    color: #4a5568 !important;
}

    .dataTables_paginate .paginate_button:hover {
        background: linear-gradient(135deg, #1F5A7A 0%, #2E6F95 100%) !important;
        color: white !important;
        border-color: #1F5A7A !important;
    }

    .dataTables_paginate .paginate_button.current {
        background: linear-gradient(135deg, #1F5A7A 0%, #2E6F95 100%) !important;
        color: white !important;
        border-color: #1F5A7A !important;
    }

.dataTables_info {
    color: #6c757d;
    font-size: 13px;
    padding-top: 10px;
}

/* Breadcrumb Styling for Users Page */
.usr-breadcrumb-wrapper {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 12px 20px;
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

    .usr-breadcrumb-wrapper .breadcrumb {
        margin: 0;
        background: transparent;
        padding: 0;
    }

    .usr-breadcrumb-wrapper .breadcrumb-item a {
        color: #1F5A7A;
        text-decoration: none;
        font-weight: 500;
        transition: all 0.2s ease;
    }

        .usr-breadcrumb-wrapper .breadcrumb-item a:hover {
            color: #4FA3D1;
            text-decoration: none;
        }

    .usr-breadcrumb-wrapper .breadcrumb-item.active {
        color: #6c757d;
        font-weight: 600;
    }

/* Responsive Design */
@media (max-width: 768px) {
    .usr-header-section {
        flex-direction: column;
        align-items: flex-start;
    }

    .usr-create-btn {
        width: 100%;
        justify-content: center;
    }

    .usr-table-container {
        padding: 15px 10px;
    }

    #user {
        min-width: 800px;
    }

    .usr-action-links {
        gap: 4px;
    }

        .usr-action-links a,
        .usr-reset-btn {
            width: 28px;
            height: 28px;
        }

            .usr-action-links img,
            .usr-reset-btn img {
                width: 14px;
                height: 14px;
            }

    .content-area {
        padding: 20px 16px;
    }
}

/* Dark Theme Support */
body[data-theme="dark"] .usr-table-container {
    background: rgba(30, 35, 45, 0.95);
}

body[data-theme="dark"] #user thead th {
    background: linear-gradient(135deg, #1a252f 0%, #2d3748 100%);
    color: #e2e8f0;
    border-bottom-color: #4a5568;
}

body[data-theme="dark"] #user tbody td {
    color: #cbd5e0;
    border-bottom-color: #2d3748;
}

body[data-theme="dark"] #user tbody tr:nth-child(even) {
    background-color: #1a202c;
}

body[data-theme="dark"] #user tbody tr:hover {
    background-color: rgba(79, 163, 209, 0.1);
}

body[data-theme="dark"] .dataTables_filter input,
body[data-theme="dark"] .dataTables_length select {
    background: #2d3748;
    border-color: #4a5568;
    color: #e2e8f0;
}

body[data-theme="dark"] .dataTables_info {
    color: #a0aec0;
}

body[data-theme="dark"] .dataTables_paginate .paginate_button {
    background: #2d3748 !important;
    color: #e2e8f0 !important;
    border-color: #4a5568 !important;
}

body[data-theme="dark"] .usr-breadcrumb-wrapper {
    background: rgba(26, 32, 44, 0.8);
    border-color: rgba(255, 255, 255, 0.05);
}

    body[data-theme="dark"] .usr-breadcrumb-wrapper .breadcrumb-item a {
        color: #4FA3D1;
    }

body[data-theme="dark"] .usr-message-success {
    background-color: rgba(39, 174, 96, 0.15);
}

body[data-theme="dark"] .usr-message-error {
    background-color: rgba(231, 76, 60, 0.15);
}



/* Add these styles to your existing site.css file */

/* =========================================
   FORM STYLES - CREATE/EDIT USERS
   ========================================= */

/* Form Container */
.form-modern {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
}

/* Form Header */
.form-header-modern {
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

    .form-header-modern h3 {
        color: #1F5A7A;
        font-weight: 700;
        font-size: 20px;
        margin: 0;
    }

/* Form Groups */
.form-group-modern {
    margin-bottom: 25px;
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
}

.form-label-modern {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
    width: 100%;
    font-size: 14px;
}

    .form-label-modern .required-star {
        color: #e74c3c;
        font-weight: bold;
        margin-left: 2px;
    }

.form-control-modern {
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 10px 15px;
    font-size: 14px;
    transition: all 0.2s ease;
    width: 100%;
    box-sizing: border-box;
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

    .form-control-modern:focus {
        border-color: #1F5A7A;
        box-shadow: 0 0 0 3px rgba(31, 90, 122, 0.1);
        outline: none;
    }

select.form-control-modern {
    background: white url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23333' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E") no-repeat right 15px center;
    background-size: 12px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

textarea.form-control-modern {
    resize: vertical;
    min-height: 100px;
    font-family: 'Inter', 'Segoe UI', sans-serif;
}

/* Validation Messages */
.field-validation-error {
    color: #7c1107;
    font-size: 12px;
    margin-top: 5px;
    display: block;
    font-weight:600;
}

.validation-summary-errors {
    background-color: rgba(231, 76, 60, 0.1);
    border-left: 4px solid #e74c3c;
    border-radius: 8px;
    padding: 12px 20px;
    margin-bottom: 20px;
}

    .validation-summary-errors ul {
        margin: 0;
        padding-left: 20px;
    }

    .validation-summary-errors li {
        color: #e74c3c;
        font-size: 13px;
    }

/* Form Action Buttons */
.form-actions-modern {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.btn-back-modern {
    background: #f8f9fa;
    color: #6c757d;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 10px 24px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

    .btn-back-modern:hover {
        background: #e9ecef;
        color: #495057;
        text-decoration: none;
        transform: translateY(-1px);
    }

.btn-submit-modern {
    background: linear-gradient(135deg, #1F5A7A 0%, #2E6F95 50%, #4FA3D1 100%);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 10px 28px;
    font-weight: 600;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

    .btn-submit-modern:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(31, 90, 122, 0.3);
    }

/* Responsive Form Layout */
@media (min-width: 768px) {
    .form-label-modern {
        width: 200px;
        text-align: right;
        padding-right: 20px;
        margin-bottom: 0;
    }

    .form-control-wrapper {
        flex: 1;
        max-width: 400px;
    }

    .form-group-modern {
        align-items: center;
    }
}

@media (max-width: 767px) {
    .form-modern {
        padding: 20px 15px;
    }

    .form-actions-modern {
        flex-direction: column;
    }

    .btn-back-modern,
    .btn-submit-modern {
        width: 100%;
        justify-content: center;
    }

    .form-control-wrapper {
        width: 100%;
    }
}

/* Dark Theme Support for Forms */
body[data-theme="dark"] .form-modern {
    background: rgba(30, 35, 45, 0.95);
}

body[data-theme="dark"] .form-header-modern {
    border-bottom-color: #2d3748;
}

    body[data-theme="dark"] .form-header-modern h3 {
        color: #e2e8f0;
    }

body[data-theme="dark"] .form-label-modern {
    color: #cbd5e0;
}

body[data-theme="dark"] .form-control-modern {
    background: #2d3748;
    border-color: #4a5568;
    color: #e2e8f0;
}

    body[data-theme="dark"] .form-control-modern:focus {
        border-color: #4FA3D1;
        box-shadow: 0 0 0 3px rgba(79, 163, 209, 0.2);
    }

body[data-theme="dark"] select.form-control-modern {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23e2e8f0' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
}

body[data-theme="dark"] .btn-back-modern {
    background: #2d3748;
    border-color: #4a5568;
    color: #cbd5e0;
}

    body[data-theme="dark"] .btn-back-modern:hover {
        background: #374151;
        color: #e2e8f0;
    }

body[data-theme="dark"] .form-actions-modern {
    border-top-color: #2d3748;
}

/* Breadcrumb for Form Pages */
.form-breadcrumb-wrapper {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 12px 20px;
    margin-bottom: 25px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

body[data-theme="dark"] .form-breadcrumb-wrapper {
    background: rgba(26, 32, 44, 0.8);
    border-color: rgba(255, 255, 255, 0.05);
}

/* Info Text Styling */
.form-info-text {
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
}

body[data-theme="dark"] .form-info-text {
    color: #a0aec0;
}

/* Select2 Override for Forms */
.select2-container--default .select2-selection--single {
    border: 2px solid #e9ecef !important;
    border-radius: 10px !important;
    height: 42px !important;
    padding: 5px 10px !important;
}

    .select2-container--default .select2-selection--single .select2-selection__arrow {
        height: 38px !important;
        right: 8px !important;
    }

body[data-theme="dark"] .select2-container--default .select2-selection--single {
    background: #2d3748 !important;
    border-color: #4a5568 !important;
}

    body[data-theme="dark"] .select2-container--default .select2-selection--single .select2-selection__rendered {
        color: #e2e8f0 !important;
    }


/* =========================================
   2x2 GRID LAYOUT FOR FORMS
   ========================================= */

.form-grid-2x2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 30px;
    margin-bottom: 20px;
}

    .form-grid-2x2 .form-group-modern {
        margin-bottom: 0;
    }

    .form-grid-2x2 .form-group-full-width {
        grid-column: 1 / -1;
    }

/* Responsive: Stack on mobile */
@media (max-width: 768px) {
    .form-grid-2x2 {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* Adjust label alignment for grid layout */
.form-grid-2x2 .form-label-modern {
    width: 100%;
    text-align: left;
    margin-bottom: 8px;
}

.form-grid-2x2 .form-control-wrapper {
    width: 100%;
    max-width: 100%;
}

/* Desktop label alignment */
@media (min-width: 769px) {
    .form-grid-2x2 .form-group-modern {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .form-grid-2x2 .form-label-modern {
        width: auto;
        text-align: left;
        padding-right: 0;
        margin-bottom: 8px;
    }

    .form-grid-2x2 .form-control-wrapper {
        width: 100%;
    }
}



/*CHECK THIS */

/* =========================================
   SELECT2 DROPDOWN HEIGHT FIX
   ========================================= */

/* Make Select2 dropdown same height as textbox */
.select2-container--modern .select2-selection--single {
    height: 42px !important;
    border: 2px solid #e9ecef !important;
    border-radius: 10px !important;
    background: white !important;
}

    .select2-container--modern .select2-selection--single .select2-selection__rendered {
        line-height: 38px !important;
        padding-left: 15px !important;
        color: #495057 !important;
        font-size: 14px !important;
    }

    .select2-container--modern .select2-selection--single .select2-selection__arrow {
        height: 38px !important;
        right: 10px !important;
    }

        .select2-container--modern .select2-selection--single .select2-selection__arrow b {
            border-color: #6c757d transparent transparent transparent !important;
            border-width: 5px 4px 0 4px !important;
        }

.select2-container--modern.select2-container--open .select2-selection--single .select2-selection__arrow b {
    border-color: transparent transparent #6c757d transparent !important;
    border-width: 0 4px 5px 4px !important;
}

/* Focus state */
.select2-container--modern .select2-selection--single:focus,
.select2-container--modern.select2-container--focus .select2-selection--single {
    border-color: #1F5A7A !important;
    box-shadow: 0 0 0 3px rgba(31, 90, 122, 0.1) !important;
    outline: none !important;
}

/* Dropdown menu styling */
.select2-dropdown--modern {
    border: 2px solid #e9ecef !important;
    border-radius: 10px !important;
    overflow: hidden !important;
}

.select2-results__option {
    padding: 8px 15px !important;
    font-size: 14px !important;
}

.select2-results__option--highlighted {
    background: linear-gradient(135deg, #1F5A7A 0%, #2E6F95 100%) !important;
}

/* Dark theme support */
body[data-theme="dark"] .select2-container--modern .select2-selection--single {
    background: #2d3748 !important;
    border-color: #4a5568 !important;
}

    body[data-theme="dark"] .select2-container--modern .select2-selection--single .select2-selection__rendered {
        color: #e2e8f0 !important;
    }

body[data-theme="dark"] .select2-dropdown--modern {
    background: #2d3748 !important;
    border-color: #4a5568 !important;
}

body[data-theme="dark"] .select2-results__option {
    color: #e2e8f0 !important;
}

/* Ensure all form controls have consistent height */
.form-control-modern,
select.form-control-modern,
input.form-control-modern,
textarea.form-control-modern {
    height: 42px;
    line-height: 1.5;
}

textarea.form-control-modern {
    height: auto;
    min-height: 100px;
}

/* Fix for Select2 container width */
.form-control-wrapper .select2-container--modern {
    width: 100% !important;
}

/* =========================================
   BREADCRUMB FIX - PREVENT BOTSTRAP OVERRIDE
   ========================================= */

/* Ensure breadcrumb styling doesn't get overridden by Bootstrap */
.form-breadcrumb-wrapper .breadcrumb {
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    flex-wrap: wrap !important;
}

.form-breadcrumb-wrapper .breadcrumb-item {
    display: inline-flex !important;
    align-items: center !important;
}

    .form-breadcrumb-wrapper .breadcrumb-item + .breadcrumb-item::before {
        content: "/" !important;
        padding: 0 8px !important;
        color: #6c757d !important;
    }

    .form-breadcrumb-wrapper .breadcrumb-item a {
        color: #1F5A7A !important;
        text-decoration: none !important;
        font-weight: 500 !important;
    }

        .form-breadcrumb-wrapper .breadcrumb-item a:hover {
            color: #4FA3D1 !important;
            text-decoration: none !important;
        }

    .form-breadcrumb-wrapper .breadcrumb-item.active {
        color: #6c757d !important;
        font-weight: 600 !important;
    }

/* Dark theme breadcrumb */
body[data-theme="dark"] .form-breadcrumb-wrapper .breadcrumb-item a {
    color: #4FA3D1 !important;
}

body[data-theme="dark"] .form-breadcrumb-wrapper .breadcrumb-item.active {
    color: #a0aec0 !important;
}

body[data-theme="dark"] .form-breadcrumb-wrapper .breadcrumb-item + .breadcrumb-item::before {
    color: #a0aec0 !important;
}

/* =========================================
   RESPONSIVE ADJUSTMENTS
   ========================================= */

@media (max-width: 768px) {
    .form-control-modern,
    select.form-control-modern,
    input.form-control-modern,
    .select2-container--modern .select2-selection--single {
        height: 38px !important;
    }

        .select2-container--modern .select2-selection--single .select2-selection__rendered {
            line-height: 34px !important;
        }

        .select2-container--modern .select2-selection--single .select2-selection__arrow {
            height: 34px !important;
        }
}


/* =========================================
   PASSWORD RESET PAGE STYLES
   ========================================= */

/* Password field wrapper */
.password-wrapper {
    position: relative;
    width: 100%;
}

.password-input {
    padding-right: 45px !important;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6c757d;
    transition: all 0.2s ease;
    z-index: 2;
    background: transparent;
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .password-toggle:hover {
        color: #1F5A7A;
        background: rgba(31, 90, 122, 0.1);
    }

    .password-toggle i {
        font-size: 16px;
    }

/* Password requirements text */
.password-requirements {
    margin-top: 8px;
    font-size: 12px;
    color: #6c757d;
}

    .password-requirements small {
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .password-requirements i {
        font-size: 12px;
        color: #4FA3D1;
    }

/* Input error state */
.form-control-modern.input-error {
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1) !important;
}

.field-validation-error {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
    display: block;
}

/* Validation summary */
.validation-summary-errors {
    background-color: rgba(231, 76, 60, 0.1);
    border-left: 4px solid #e74c3c;
    border-radius: 8px;
    padding: 12px 20px;
    margin-bottom: 20px;
}

    .validation-summary-errors ul {
        margin: 0;
        padding-left: 20px;
    }

    .validation-summary-errors li {
        color: #e74c3c;
        font-size: 13px;
    }

/* Dark theme support for password page */
body[data-theme="dark"] .password-toggle {
    color: #a0aec0;
}

    body[data-theme="dark"] .password-toggle:hover {
        color: #4FA3D1;
        background: rgba(79, 163, 209, 0.1);
    }

body[data-theme="dark"] .password-requirements {
    color: #a0aec0;
}

    body[data-theme="dark"] .password-requirements i {
        color: #4FA3D1;
    }

body[data-theme="dark"] .validation-summary-errors {
    background-color: rgba(231, 76, 60, 0.15);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .password-toggle {
        right: 10px;
        padding: 6px;
    }

        .password-toggle i {
            font-size: 14px;
        }

    .password-requirements {
        font-size: 11px;
    }
}




/* 3-Column Grid Layout */
.form-grid-3col {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

/* Action Buttons Styling */
.action-buttons-center {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 250px;
}

.action-buttons-wrapper {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.btn-action-modern {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

    .btn-action-modern i {
        font-size: 12px;
    }

.btn-add {
    background-color: #28a745;
    color: white;
}

    .btn-add:hover {
        background-color: #218838;
        transform: translateY(-1px);
    }

.btn-remove {
    background-color: #dc3545;
    color: white;
}

    .btn-remove:hover {
        background-color: #c82333;
        transform: translateY(-1px);
    }

/* Section Title */
.form-section-title {
    margin: 25px 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #e9ecef;
}

    .form-section-title h4 {
        font-size: 18px;
        font-weight: 600;
        color: #2c3e50;
        margin: 0;
    }

        .form-section-title h4 i {
            margin-right: 10px;
            color: #1a659f;
        }

/* Multi-select list styling */
.multi-select-list {
    font-size: 14px;
    font-family: inherit;
}

    .multi-select-list option {
        padding: 8px;
        border-bottom: 1px solid #f0f0f0;
    }

        .multi-select-list option:checked {
            background-color: #1a659f;
            color: white;
        }

/* Responsive adjustments */
@media (max-width: 992px) {
    .form-grid-3col {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .action-buttons-center {
        min-height: auto;
        padding: 10px 0;
    }

    .action-buttons-wrapper {
        flex-direction: row;
        justify-content: center;
    }
}

/* jQuery UI Autocomplete Overrides for Modern Theme */
.ui-autocomplete {
    max-height: 200px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0;
    margin: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    z-index: 9999;
}

    .ui-autocomplete li {
        list-style: none;
        border-bottom: 1px solid #f0f0f0;
    }

        .ui-autocomplete li:last-child {
            border-bottom: none;
        }

    .ui-autocomplete .ui-menu-item {
        padding: 0;
    }

    .ui-autocomplete .ui-menu-item-wrapper {
        padding: 10px 15px;
        font-size: 14px;
        transition: all 0.2s ease;
    }

        .ui-autocomplete .ui-menu-item-wrapper.ui-state-active {
            background: #1a659f;
            color: white;
            margin: 0;
            border: none;
        }

/* Autocomplete input wrapper */
.autocomplete-wrapper {
    position: relative;
    width: 100%;
}

/* Make sure the search input matches form styling */
#txtCG_CompanyName {
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 8px 12px;   
}

    #txtCG_CompanyName:focus {
        outline: none;
        border-color: #1a659f;
        box-shadow: 0 0 0 2px rgba(26,101,159,0.1);
    }
.form-label-modern {
    font-size: 1.2rem !important;
}

.form-control-modern, .select2-container--default .select2-selection--single {
    font-size: 1.2rem !important;
}
.input-field-modern label {
    font-size: 1.2rem !important;
}
.input-field-modern input {
    font-size: 1.2rem !important;
}



fixed-top-section {
    position: sticky;
    top: 0;
    z-index: 999;
    padding-bottom: 10px;
}

/* Scroll only below section */
.page-scroll-content-showpage {
    height: calc(100vh - 350px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 20px;
}

.page-scroll-content-createedit {
    height: calc(90vh - 150px);
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 20px;
}

/* DataTable wrapper */
.dataTables_wrapper {
    width: 100%;
}

/* Scroll body */
.dataTables_scrollBody {
    max-height: 500px !important;
    overflow-y: auto !important;
    overflow-x: auto !important;
}
table.dataTable thead {
    background: var(--gradient-brand) !important;
}
/* Freeze Header */
table.dataTable thead th {
    position: sticky !important;
    top: 0;
    z-index: 1000;
    color: #fff !important;
    border-bottom: 1px solid #ccc;
    font-size:1.2rem !important;
}

/* Freeze Footer */
table.dataTable tfoot th {
    position: sticky !important;
    bottom: 0;
    z-index: 1000;
    background: #f5f5f5 !important;
    border-top: 1px solid #ccc;
}

/* Prevent overlap */
table.dataTable {
    border-spacing: 0;
    width: 100% !important;
}

    table.dataTable tbody td,
    table.dataTable thead th {
        text-align: left !important;
    }
/* Loader */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(4px);
}

.loader-spinner {
    width: 48px;
    height: 48px;
    border: 3px solid #e2e8f0;
    border-top-color: #1F5A7A;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}