:root {
    --label-color: #99A1B7;
    --border-color: #F1F1F4;
    --sales-bar-lines: #1B84FF;
    --rides-bar-lines: #F8AD44;
}

form span.error {
    width: 100%;
    font-size: 0.857rem;
}

body {
    font-family: "Poppins", sans-serif !important;
}

form .error:not(input) {
    color: #FF5B5C !important;
}

form input.error,
form input.error:focus {
    border-color: #FF5B5C !important;
}

form textarea.error {
    border-color: #FF5B5C !important;
}

form .select2.error + .select2-container--classic .select2-selection--single,
form .select2.error + .select2-container--default .select2-selection--single,
form .select2.error + .select2-container--classic .select2-selection--multiple,
form .select2.error + .select2-container--default .select2-selection--multiple {
    border-color: #FF5B5C !important;
}

.form-check-input {
    cursor: pointer;
}

.form-check-label {
    color: #000000;
}

table {
    width: 100% !important;
    table-layout: auto;
    font-size: 0.875rem;
}

.btn-success-dark,
.btn-success-dark:active {
    background-color: #1d943b !important;
    color: #fff !important;
    border-color: #1d943b !important;
}

.btn-success-dark:hover {
    background-color: #35aa47 !important;
    border-color: #35aa47 !important;
}

.menu-sub-indention .menu-item .menu-item .menu-link.active {
    margin-right: 0;
}

.cursor-pointer {
    cursor: pointer;
}

.hide-show-pass-position {
    position: absolute;
    right: 2%;
    top: 27%;
    cursor: pointer;
    z-index: 9999999;
}

.body-bg-color {
    background-color: #f5f5f5;
}

.login-form {
    padding-bottom: 0rem !important;
    margin-top: -13px;
}

.forgot-pass-form {
    padding-bottom: 2.5rem !important;
}

.fixed-wrapper {
    padding-bottom: 11rem !important;
}

.table-header {
    white-space: nowrap;
}

.link-primary {
    color: #2a6496 !important;
}

.dt-orderable-none {
    position: relative !important;
    padding-right: 30px !important;
}

.dt-type-numeric {
    text-align: justify !important;
}

.text-availability {
    text-align: center !important;
}

.heading-text {
    font-weight: unset !important;
}

.form-btn {
    font-size: 18px !important;
}

.photo-label {
    display: block;
}

.alert-danger {
    background-color: white !important;
}

.btn.btn-success {
    background-color: #41CD0A !important;
}

.menu-link.active {
    color: #2196F3 !important;
}

.btn.btn-success:not(.btn-active):hover {
    background-color: #36B809 !important;
}

.btn.btn-success:not(.btn-active):active {
    background-color: #2E9A07 !important;
}

.btn.btn-success:not(.btn-active):disabled {
    background-color: #A8E48A !important;
}

.toastr-success {
    background-color: #41CD0A !important;
}

.totalrides, .totalsales {
    color: #41CD0A !important;
}

.search-parent, .pagination-parent {
    width: max-content;
}

.user-profile {
    width: 22rem !important;
}


.file-multiple-upload {
    border: 1px solid var(--bs-gray-300);
    border-radius: 0.475rem;
}


.multiple-file-input {
    opacity: 0;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    border: 1px solid var(--bs-gray-300);
    border-radius: 0.475rem;
}


.list-item-bordered {
    border-bottom: 1px solid #dee2e6;
}


.list-icon-large {
    font-size: 1.2rem;
}


.list-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: .25rem;
    padding: .25rem 0;
}


/* Make all videos inside modals responsive */
.modal video {
    width: 100%;
    max-height: 700px;
    height: auto;
    display: block;
    margin: 0 auto;
    object-fit: contain;
}


/* Tablet (max width 1024px) */
@media (max-width: 1024px) {
    .modal video {
        max-height: 500px;
    }
}


/* Mobile (max width 768px) */
@media (max-width: 768px) {
    .modal video {
        max-height: 300px;
    }
}

.daterangepicker .ranges ul {
    overflow: visible !important;
    max-height: none !important;
}

.sales-icon {
    font-size: 3em;
    margin-left: 9em;
}

/* Inline filter compact layout */
.inline-filter {
    display: flex;
    align-items: center;
    gap: .5rem;
}

.inline-filter .filter-label {
    margin-bottom: 0;
    font-size: .95rem;
    white-space: nowrap;
}

.inline-filter .filter-select {
    width: auto !important;
    min-width: 7.5rem;
    max-width: 12rem;
    padding-top: .25rem;
    padding-bottom: .25rem;
}

/* Responsive: stack on small screens */
@media (max-width: 576px) {
    .inline-filter {
        flex-direction: column;
        align-items: stretch;
        gap: .25rem;
    }

    .inline-filter .filter-label {
        white-space: normal;
    }

    .inline-filter .filter-select {
        width: 100% !important;
    }
}

/* Constrain Select2 dropdown appearance only for the FilterGraph instance */
.select2-filtergraph-dropdown.select2-dropdown {
    max-width: 14rem !important; /* don't allow very wide dropdowns */
    width: auto !important;
}


.select2-filtergraph-container.select2-container--default .select2-results__options,
.select2-filtergraph-dropdown .select2-results__options {
    max-height: 12rem !important; /* make results scrollable */
    overflow-y: auto !important;
}


.filtergraph-select {
    min-width: 10rem; /* ensure the control itself has room for the selected text */
    max-width: 14rem;
}


.select2-filtergraph-container {
    display: inline-block; /* let the control size itself instead of full width */
}


.select2-filtergraph-dropdown.select2-dropdown {
    min-width: 10rem !important;
    max-width: 22rem !important; /* allow larger dropdown so options don't wrap awkwardly */
}


.select2-filtergraph-dropdown {
    width: 100% !important;
}


.select2-filtergraph-container.select2-container--default .select2-selection--single {
    height: 34px;
    padding: 4px 8px;
}

.select2-filtergraph-dropdown {
    width: 623.672px !important;
}


/* Allow full width on very small screens for FilterGraph only */
@media (max-width: 420px) {
    .select2-filtergraph-dropdown.select2-dropdown {
        max-width: 100% !important;
        left: 0 !important;
        right: 0 !important;
    }
}

/* Chart no-data placeholder */
.chart-no-data {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    color: #6b7280; /* muted */
    pointer-events: none;
}

/* Product pie wrapper: stable sizing for ApexCharts and connector calculations */
.product-pie-wrapper {
    position: relative;
}

.product-pie {
    overflow: visible;
}

/* Chart loader styles */
.chart-loader-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 0.475rem;
    z-index: 1100;
    gap: 0.5rem;
    color: #fff;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
}

.chart-loader-inner {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

@keyframes dotPulse {
    0% {
        transform: translateY(0);
        opacity: 0.6
    }
    50% {
        transform: translateY(-6px);
        opacity: 1
    }
    100% {
        transform: translateY(0);
        opacity: 0.6
    }
}

.chart-loader-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ffffff;
    opacity: 0.8;
    display: inline-block;
}

.chart-loader-dot:nth-child(1) {
    animation: dotPulse 0.9s infinite ease-in-out;
    animation-delay: 0s
}

.chart-loader-dot:nth-child(2) {
    animation: dotPulse 0.9s infinite ease-in-out;
    animation-delay: 0.12s
}

.chart-loader-dot:nth-child(3) {
    animation: dotPulse 0.9s infinite ease-in-out;
    animation-delay: 0.24s
}

.chart-loader-dot:nth-child(4) {
    animation: dotPulse 0.9s infinite ease-in-out;
    animation-delay: 0.36s
}

.chart-loader-dot:nth-child(5) {
    animation: dotPulse 0.9s infinite ease-in-out;
    animation-delay: 0.48s
}

.file-multiple-upload {
    border: 1px solid var(--bs-gray-300);
    border-radius: 0.475rem;
}

.multiple-file-input {
    opacity: 0;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    border: 1px solid var(--bs-gray-300);
    border-radius: 0.475rem;
}

@media print {
    @page {
        size: auto;
        margin: 0mm;
    }

    body * {
        visibility: hidden !important;
    }

    #printArea, #printArea * {
        visibility: visible !important;
    }

    #printArea {
        position: absolute;
        left: 0;
        top: 0;
        width: 100% !important;
        margin: 0;
        padding: 0;
    }

    .dataTables_paginate,
    .dataTables_length,
    .dataTables_filter,
    .dataTables_info,
    .toolbar,
    .breadcrumb,
    header,
    footer,
    nav {
        display: none !important;
    }

    .dataTables_scrollBody {
        overflow: visible !important;
        height: auto !important;
    }
}

.list-item-bordered {
    border-bottom: 1px solid #dee2e6;
}

.list-icon-large {
    font-size: 1.2rem;
}

.list-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: .25rem;
    padding: .25rem 0;
}

/* Make all videos inside modals responsive */
.modal video {
    width: 100%;
    max-height: 700px;
    height: auto;
    display: block;
    margin: 0 auto;
    object-fit: contain;
}

/* Tablet (max width 1024px) */
@media (max-width: 1024px) {
    .modal video {
        max-height: 500px;
    }
}

/* Mobile (max width 768px) */
@media (max-width: 768px) {
    .modal video {
        max-height: 300px;
    }
}

.chart-loader-overlay {
    z-index: 1000;
}


.select2-container--open {
    z-index: 99999 !important;
}

.select2-dropdown {
    z-index: 99999 !important;
}


.apexcharts-tooltip-title {
    max-width: 400px !important;
    white-space: normal !important;
}

/* Thicker and darker horizontal borders */
.table-row-bordered tr {
    border-bottom-width: 2px !important;
    border-bottom-color: #E5E5E9 !important;
}

.table th,
.table td {
    padding: 1.5rem 1.5rem !important;
}

.date-rang-wrapper {
    height: 45px !important;
}

.collaborator-avatar {
    position: relative;
    display: inline-block;
    margin-right: 5px;
}

.collaborator-avatar:hover .tooltip-content {
    display: block;
}

.tooltip-content {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    white-space: nowrap;
    z-index: 1000;
    font-size: 12px;
}

.tooltip-content::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
}

.collaborator-avatar {
    position: relative;
    display: inline-block;
    margin-right: 5px;
}

.collaborator-avatar:hover .tooltip-content {
    display: block;
}

.tooltip-content {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    white-space: nowrap;
    z-index: 1000;
    font-size: 12px;
    margin-bottom: 5px;
}

.tooltip-content::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
}

/* Ticket Attachment Image */
.ticket-attachment-img {
    width: 50px;
    height: auto;
}

/* Collaborators Container */
.collaborators-container {
    display: flex;
    align-items: center;
}

/* Collaborator Avatar */
.collaborator-avatar {
    margin-right: 5px;
    position: relative;
}

/* Collaborator Image */
.collaborator-img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    border: 2px solid white;
}

/* Collaborator Initials */
.collaborator-initials {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    color: white;
    font-size: 14px;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
}

/* Collaborator Count Badge */
.collaborator-count {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: #eee;
    color: #333;
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
    cursor: pointer;
    margin-right: 5px;
}

/* Collaborator Add Button */
.collaborator-add-btn {
    font-size: 20px;
    margin-left: 5px;
    cursor: pointer;
}

/* Ticket Comments Container */
.ticket-comments-container {
    max-height: 500px;
    overflow-y: auto;
}

/* Remarks History Container */
.remarks-history-container {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e0e0e0;
    padding: 10px;
    border-radius: 5px;
    background: #f9f9f9;
}

.ticket-details-field-row {
    display: flex;
    align-items: baseline;
    margin-bottom: 1rem;
}

.ticket-details-label {
    font-weight: 600;
    min-width: 170px;
    max-width: 220px;
    color: #1b2838;
    white-space: nowrap;
    padding-right: 14px;
    line-height: 1.8;
    text-align: right;
    display: inline-block;
}

.ticket-details-value {
    flex: 1;
    font-weight: 400;
    color: #333;
    line-height: 1.8;
}

.collaborator-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 31px;
    height: 31px;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    font-size: 12px;
    margin-right: 3px;
    margin-bottom: 2px;
    vertical-align: middle;
}

.ticket-history-entry {
    display: flex;
    align-items: center;
    font-size: 15px;
    gap: 10px;
    border: 1px solid #edf2f5;
    border-radius: 7px;
    background: #fafbfc;
    box-shadow: 0 2px 3px rgba(60, 60, 100, 0.03), 0 0.2px 0.5px rgba(0, 0, 0, 0.03);
    padding: 11px 19px;
    margin-bottom: 11px;
}

.history-user-icon {
    color: #007bff;
    font-size: 18px;
    margin-right: 8px;
    margin-top: 2px;
}

.history-user-name {
    font-weight: 600;
    margin-right: 7px;
    color: #222;
}

.history-comment {
    flex: 1;
    margin-right: 10px;
    color: #383d42;
}

.history-meta {
    color: #888;
    font-size: 13px;
    white-space: nowrap;
}

#readMoreTicketHistory {
    border-radius: 22px;
    transition: background 0.2s, color 0.2s;
    letter-spacing: 0.02em;
}

#readMoreTicketHistory:hover {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

/* Prevent native select flash before Select2 styling */
.select2-init-hidden {
    opacity: 0;
}

.select2-init-ready {
    opacity: 1;
    transition: opacity 0.15s ease-in;
}

#profileImageDropzon {
    border: 2px solid #d7dce3;
    border-radius: 10px;
    background: #fff;
    min-height: 100px; /* adjust height as needed */
    text-align: center;
}

#profileImageDropzon .dz-message {
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
    margin: 0 !important;
    width: 100%;
    height: 100%;
}

#profileImageDropzon .dz-progress {
    display: none;
}

/* Container to align Input and Icon */
.dt-search-container {
    display: inline-flex !important;
    align-items: center !important;
    vertical-align: middle;
}

/* The Info Icon Styling */
.search-help-icon {
    cursor: pointer;
    font-size: 18px;
    margin-left: 8px;
    vertical-align: middle;
}

.user-detail .card-header {
    min-height: 45px;
    padding: 0 1rem;
}

.bg-address {
    background-color: #3062a0 !important;
}

.bg-sms {
    background-color: #3e7182 !important;
}

.bg-location {
    background-color: #669d66 !important;
}

.bg-log {
    background-color: #ac9649 !important;
}

.bg-feedback-ticket {
    background-color: #8d7d4b !important;
}

.bg-ticket {
    background-color: #8f8f6b !important;
}

.form-check-input:checked {
    background-color: #2E9A07;
    border-color: #2E9A07;
}

.badge-success {
    background-color: #41CD0A !important;
}

.bg-success {
    background-color: #41CD0A !important;
}

.border-success {
    border-color: #41CD0A !important;
}

.text-success {
    color: #41CD0A !important;
}

.cycle-detail .card-header {
    min-height: 1px;
    padding: 0 1rem;
}

/* Ticket Form - Readonly Field Styles */
.pointer-events-none {
    pointer-events: none !important;
}

.select2-container.border-danger .select2-selection {
    border-color: #dc3545 !important;
    border-width: 1px !important;
}

.select2-container.bg-light .select2-selection {
    background-color: #f8f9fa !important;
    cursor: not-allowed !important;
}

.select2-container.bg-light .select2-selection__rendered {
    color: #6c757d !important;
}

input.bg-light[readonly],
textarea.bg-light[readonly] {
    background-color: #f8f9fa !important;
    cursor: not-allowed !important;
    color: #6c757d !important;
}

.invalid-feedback {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.95rem;
    color: #F8285A;
}

.select2-container.bg-light .select2-selection__arrow {
    opacity: 0.5;
}
