.parsley-errors-list {
    color: #ff1b17 !important;
}

.picker:not(.picker--opened) {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
}

.picker--opened {
    display: block;
    z-index: 10000;
}

.datepicker {
    border-radius: 6px !important;
}

.picker__select--month,
.picker__select--year {
    height: 2.5em;
}

.badge-container {
    min-height: 38px;
    padding: 8px;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    background-color: #f8f9fa;
}

/* Prevent header text wrapping */
.custom-datatable th {
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* Ensure DataTables respects fixed widths */
.custom-datatable {
    table-layout: fixed !important;
    width: 100% !important;
}


/* To push user profile to right end. */
.navbar-nav {
    display: flex;
    flex-direction: row;
    width: 100%;
}

.navbar-user {
    margin-left: auto;
}

.navbar-user .dropdown-toggle::after {
    display: none !important;
}

.gritter-success {
    background: #001f3f !important;
    color: white !important;
}

.gritter-success .gritter-title {
    color: white !important;
}

.gritter-success p {
    color: white !important;
}

.gritter-success {
    color: white !important;
}

.gritter-error {
    background: #800020 !important;
    color: white !important;
}

.gritter-error .gritter-title {
    color: white !important;
}

.gritter-error p {
    color: white !important;
}

.gritter-close {
    color: white !important;
}

.form_wrapper {
    padding: 20px;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

.floating-btns-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column-reverse;
    /* Makes buttons stack vertically (new button on top) */
    gap: 15px;
    /* Space between buttons */
    z-index: 1000;
}

.floating-btn {
    width: 60px;
    height: 60px;
    background: linear-gradient(145deg, #007bff, #0056b3);
    color: white;
    border: none;
    border-radius: 50%;
    box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.2),
        -4px -4px 8px rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.floating-btn:hover {
    transform: translateY(-5px);
    box-shadow: 6px 6px 12px rgba(0, 0, 0, 0.3),
        -6px -6px 12px rgba(255, 255, 255, 0.2);
}

/* Optional: Different style for the second button */
.floating-btn.refresh {
    background: linear-gradient(145deg,
            rgba(var(--bs-warning-rgb), 1),
            /* Bootstrap warning/yellow color */
            rgba(var(--bs-warning-rgb), 0.8)
            /* Slightly darker variant */
        );
    color: #000;
    /* Black text for better contrast on yellow */
}

.floating-btn.back {
    background: linear-gradient(145deg, #adb5bd, #6c757d);
    /* light gray → darker gray */
    color: #fff;
    border: none;
}

.floating-btn.cancel {
    background: linear-gradient(145deg, #fd7e14, #dc6502);
    /* Bootstrap orange/warning color */
    color: #fff;
    border: none;
}

.floating-btn.delete {
    background: linear-gradient(145deg,
            rgba(220, 53, 69, 1),
            /* Bootstrap danger/red color */
            rgba(185, 28, 44, 0.8)
            /* Slightly darker red variant */
        );
    color: #fff;
    /* White text for better contrast on red */
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2);
    /* Optional: improves text readability */
}


/* Custom styles for DataTables */
.dataTables_wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
}

.datable-container-fluid {
    width: 100%;
    padding-left: 15px;
    padding-right: 15px;
}

/* Wrap table in a card-style container */
.dataTables_wrapper {
    padding: 20px;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

/* Row hover style */
table.dataTable tbody tr:hover {
    background-color: #f5f9ff;
    box-shadow: 0 0 0 1px #d0e4ff;
}

.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
    border-radius: 8px;
    padding: 6px 15px;
    border: 1px solid #ccc;
    font-size: 14px;
}

/* Add space between number and arrow in dropdown */
.dataTables_wrapper .dataTables_length select {
    padding-right: 30px !important;
}

/* Add space between dropdown and search field in responsive view */
.dataTables_wrapper .dataTables_length {
    margin-bottom: 10px;
    /* Adjust the value as needed */
}

/* For the actual arrow icons, which are often pseudo-elements */
.dataTables_wrapper .dataTable thead .sorting::before,
.dataTables_wrapper .dataTable thead .sorting::after,
.dataTables_wrapper .dataTable thead .sorting_asc::before,
.dataTables_wrapper .dataTable thead .sorting_asc::after,
.dataTables_wrapper .dataTable thead .sorting_desc::before,
.dataTables_wrapper .dataTable thead .sorting_desc::after {
    color: #007bff;
    right: 0.5em;
    /* Adjust this value to move the arrow closer */
}

.dataTables_wrapper .dataTable thead .sorting,
.dataTables_wrapper .dataTable thead .sorting_asc,
.dataTables_wrapper .dataTable thead .sorting_desc {
    padding-right: 0em !important;
    /* Adjust padding to make space for the arrow */
}

/* Add border between columns */
.dataTables_wrapper table.dataTable th,
.dataTables_wrapper table.dataTable td {
    border-right: 1px solid #dee2e6;
    /* Adjust color and thickness as needed */
}

/* Remove border from the last column */
.dataTables_wrapper table.dataTable th:last-child,
.dataTables_wrapper table.dataTable td:last-child {
    border-right: none;
}

/* Add top border to the table */
.dataTables_wrapper table.dataTable {
    border-top: 1px solid #dee2e6;
}

/* Adjust spacing between up and down arrows */
.dataTables_wrapper .dataTable thead .sorting::before,
.dataTables_wrapper .dataTable thead .sorting_asc::before {
    top: 0.5em;
    /* Adjust this value to move the up arrow */
}

.dataTables_wrapper .dataTable thead .sorting::after,
.dataTables_wrapper .dataTable thead .sorting_desc::after {
    bottom: 0.1em;
    /* Adjust this value to move the down arrow */
}

/* Custom styles for DataTables */


/* Custom styles for DataTable loader */
/* Disable spinner from Bootstrap theme and DataTables */
table.dataTable tbody tr.processing td::before,
.dataTables_processing::before,
.dataTables_processing::after {
    display: none !important;
    content: none !important;
    background: none !important;
    animation: none !important;
    border: none !important;
    box-shadow: none !important;
}

/* Center your custom loader */
.dataTables_processing {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0%);
    position: absolute !important;
    top: 0;
    left: 0;
    font-size: 16px;
    z-index: 9999 !important;
    /* Boost z-index */
    border: none !important;
    box-shadow: none !important;
    text-align: center;
    width: 100%;
    /* Ensure it takes full width to center content */
    height: 100%;
    /* Ensure it takes full height to center content */
}

.custom-loader {
    display: flex;
    flex-direction: column;
    /* Stack vertically */
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.custom-loader img {
    height: 70px;
    animation: blink 1.2s infinite;
    border: none !important;
    /* removes default image border */
    outline: none !important;
    /* removes any outline */
    box-shadow: none !important;
    /* removes any shadow that may look like a border */
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.3;
    }
}

/* Hide the default blue loader */
.dataTables_processing>div:not(.custom-loader) {
    display: none !important;
}

/* Custom styles for DataTable loader */

/* Custom styles for Tabs in Land Profile */
.nav-tabs-custom {
    border-bottom: 3px solid #e9ecef;
    margin-bottom: 1.5rem;
}

.nav-tabs-custom .nav-link {
    color: #6c757d;
    background-color: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    padding: 0.75rem 1.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-bottom: -3px;
}

.nav-tabs-custom .nav-link:hover {
    color: #0d6efd;
    border-bottom-color: #dee2e6;
    background-color: #f8f9fa;
}

.nav-tabs-custom .nav-link.active {
    color: #0d6efd;
    background-color: #fff;
    border-bottom-color: #0d6efd;
    font-weight: 600;
}

.nav-tabs-custom .nav-link i {
    font-size: 1rem;
}

/* Tab content styling */
.tab-content {
    padding-top: 0.5rem;
}

/* Smooth transitions */
.tab-pane {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive tabs */
@media (max-width: 576px) {
    .nav-tabs-custom .nav-link {
        padding: 0.5rem 1rem;
        font-size: 0.875rem;
    }

    .nav-tabs-custom .nav-link i {
        display: none;
    }
}

/* Custom styles for Tabs in Land Profile */

/* Ensure Parsley error messages are visible */
#returnExpectationError {
    display: block !important;
    min-height: 24px;
    /* Reserve space for error message to prevent layout shift */
    transition: none;
    /* Disable transitions to prevent animation jumpiness */
}

#returnExpectationError .parsley-errors-list {
    list-style: none;
    padding: 0;
    margin: 0.25rem 0 0 0;
    color: #dc3545;
    font-size: 0.875rem;
    line-height: 1.4;
}

#returnExpectationError .parsley-errors-list li {
    padding: 0;
    margin: 0;
}

/* Style for fields with errors */
input.parsley-error,
select.parsley-error {
    border-color: #dc3545 !important;
}

/* Disable border color changes for textareas in all states */
textarea.form-control.parsley-error,
textarea.form-control.parsley-success,
textarea.form-control.parsley-error:focus,
textarea.form-control.parsley-success:focus,
textarea.form-control:focus.parsley-error,
textarea.form-control:focus.parsley-success,
textarea.parsley-error,
textarea.parsley-success,
textarea.parsley-error:focus,
textarea.parsley-success:focus,
textarea:focus.parsley-error,
textarea:focus.parsley-success {
    border-color: #dee2e6 !important;
    /* Bootstrap default border color */
}

/* Ultra-specific rule for no-validation-border class */
textarea.no-validation-border,
textarea.no-validation-border:focus,
textarea.no-validation-border.parsley-error,
textarea.no-validation-border.parsley-success,
textarea.no-validation-border.parsley-error:focus,
textarea.no-validation-border.parsley-success:focus,
textarea.no-validation-border.is-invalid,
textarea.no-validation-border.is-valid,
textarea.no-validation-border.is-invalid:focus,
textarea.no-validation-border.is-valid:focus {
    border-color: #dee2e6 !important;
    box-shadow: none !important;
}

/* Clean Professional Dropzone Styling - List View */
.dropzone {
    min-height: 60px !important;
    max-height: 200px !important;
    padding: 10px !important;
    border: 2px dashed #cbd5e1 !important;
    background: linear-gradient(135deg, #f1f5f9 0%, #f8fafc 100%) !important;
    transition: all 0.3s ease;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    border-radius: 8px;
}

.dropzone:hover {
    border-color: #3b82f6 !important;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.dropzone .dz-message {
    margin: 0.5em 0 !important;
    font-size: 0.75rem !important;
    color: #64748b !important;
    font-weight: 500;
}

.dropzone:hover .dz-message {
    color: #3b82f6 !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    font-weight: 700;
}

/* File Preview Cards - List Format */
.dropzone .dz-preview {
    width: 100% !important;
    height: auto !important;
    margin: 4px 0 !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    background: #ffffff !important;
    border-radius: 6px;
    border: 1px solid #e2e8f0 !important;
    padding: 8px !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    position: relative;
}

.dropzone .dz-preview:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    border-color: #cbd5e1 !important;
}

/* Icon Container */
.dropzone .dz-preview .dz-image {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    border-radius: 6px;
    background: #f8fafc !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    margin-right: 12px !important;
}

.dropzone .dz-preview .dz-image img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    border-radius: 6px;
}

/* File Icons */
.dropzone .dz-preview .dz-file-icon {
    font-size: 1.5rem !important;
    margin: 0 !important;
    color: #94a3b8 !important;
}

.dropzone .dz-preview .dz-file-icon.fa-file-pdf {
    color: #dc2626 !important;
}

.dropzone .dz-preview .dz-file-icon.fa-file-word {
    color: #2563eb !important;
}

.dropzone .dz-preview .dz-file-icon.fa-file-excel {
    color: #16a34a !important;
}

/* File Details - Full Width */
.dropzone .dz-preview .dz-details {
    flex: 1 !important;
    padding: 0 8px !important;
    overflow: hidden;
    position: static !important;
    background: transparent !important;
    opacity: 1 !important;
    min-width: 0;
}

.dropzone .dz-preview .dz-filename {
    font-size: 0.875rem !important;
    font-weight: 500;
    color: #1e293b !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
    display: block;
    max-width: 100%;
}

.dropzone .dz-preview .dz-filename:hover {
    overflow: visible;
    white-space: normal;
    word-break: break-all;
}

.dropzone .dz-preview .dz-size {
    font-size: 0.75rem !important;
    color: #64748b !important;
    display: block !important;
    margin: 0 !important;
}

/* Ensure Filename is visible and not overlapped */
.dropzone .dz-preview .dz-details .dz-filename {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-bottom: 5px;
}

/* Progress Bar */
.dropzone .dz-preview .dz-progress {
    opacity: 1;
    z-index: 10;
    pointer-events: none;
    position: absolute;
    height: 4px;
    left: 0;
    right: 0;
    bottom: 0;
    top: auto;
    /* Override previous centering */
    width: 100%;
    /* Full width */
    margin: 0;
    background: #f0f0f0;
    border-radius: 0 0 4px 4px;
    /* Round bottom corners */
    overflow: hidden;
    border: none;
}

.dropzone .dz-preview.dz-processing .dz-progress {
    opacity: 1;
}

.dropzone .dz-preview .dz-progress .dz-upload {
    background: #00acac;
    /* Teal/Green color matching theme usually, or use primary blue */
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 0;
    transition: width 300ms ease-in-out;
}

/* Remove Button */
.dropzone .dz-preview .dz-remove {
    font-size: 0.75rem !important;
    padding: 4px 8px !important;
    margin: 0 !important;
    background: #ef4444 !important;
    color: white !important;
    border-radius: 4px;
    border: none !important;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    display: inline-block !important;
    text-decoration: none !important;
    opacity: 1 !important;
}

.dropzone .dz-preview .dz-remove:hover {
    background: #dc2626 !important;
    transform: scale(1.05);
    text-decoration: none !important;
}

.dropzone .dz-preview .dz-remove i {
    font-size: 0.875rem;
}

/* Success State */
.dropzone .dz-preview.dz-success {
    border-color: #22c55e !important;
    background: #f0fdf4 !important;
}

.dropzone .dz-preview.dz-success .dz-image {
    background: #dcfce7 !important;
}

/* Hide progress bar when upload is successful */
.dropzone .dz-preview.dz-success .dz-progress {
    display: none;
    opacity: 0;
    transition: opacity 0.3s linear;
}

/* Error State */
.dropzone .dz-preview.dz-error {
    border-color: #ef4444 !important;
    background: #fef2f2 !important;
}

.dropzone .dz-preview.dz-error .dz-image {
    background: #fee2e2 !important;
}

.dropzone .dz-preview.dz-error .dz-progress {
    display: none;
}

/* Error Message */
.dropzone .dz-preview .dz-error-message {
    position: static !important;
    background: #fef2f2 !important;
    color: #dc2626 !important;
    padding: 4px 8px !important;
    border-radius: 4px;
    font-size: 0.75rem !important;
    margin-top: 4px;
    display: block !important;
}

/* Custom Scrollbar */
.dropzone::-webkit-scrollbar {
    width: 6px;
}

.dropzone::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

.dropzone::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.dropzone::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Form Group Styling */
.form-group.row.mb-4 {
    margin-bottom: 1rem !important;
}

.form-group.row.mb-4 label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #374151;
}

.form-group.row.mb-4 small {
    font-size: 0.75rem;
    color: #6b7280;
}

/* File count badge */
.dropzone-file-count {
    display: inline-block;
    background: #3b82f6;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 8px;
}

/* Fix SweetAlert2 button overlap - Cancel button not clickable on right side */
.swal2-actions {
    display: flex !important;
    gap: 15px !important;
    justify-content: center !important;
    width: 100% !important;
    margin: 1.25em auto 0 !important;
}

.swal2-styled.swal2-confirm,
.swal2-styled.swal2-cancel {
    margin: 0 !important;
    padding: 0.625em 1.1em !important;
    pointer-events: auto !important;
    cursor: pointer !important;
    flex-shrink: 0 !important;
    min-width: 80px !important;
}

.swal2-styled.swal2-cancel {
    order: 1 !important;
    margin-right: 0 !important;
}

.swal2-styled.swal2-confirm {
    order: 2 !important;
    margin-left: 0 !important;
}