.custom-select {
    position: relative;
    width: 100%;
}

.custom-select-native {
    position: absolute !important;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    pointer-events: none;
    z-index: -1;
}

.custom-select-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 6px 10px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.86rem;
    color: #1a2b4a;
    background-color: #f8fafc;
    cursor: pointer;
    min-height: 34px;
    height: 34px;
    transition: all 0.15s;
    user-select: none;
    -webkit-user-select: none;
}

.custom-select-display:hover {
    border-color: #cbd5e1;
}

.custom-select.menu-open .custom-select-display {
    border-color: #0d6efd;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.08);
}

.custom-select-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.custom-select-arrow {
    color: #94a3b8;
    font-size: 0.75rem;
    flex-shrink: 0;
    transition: transform 0.15s;
}

.custom-select.menu-open .custom-select-arrow {
    transform: rotate(180deg);
    color: #0d6efd;
}

.custom-select.disabled .custom-select-display {
    background: #f1f5f9;
    color: #94a3b8;
    cursor: not-allowed;
    border-color: #e2e8f0;
}

.custom-select.disabled .custom-select-arrow {
    opacity: 0.4;
}

.custom-select-menu {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.15), 0 4px 8px rgba(15, 23, 42, 0.06);
    padding: 4px;
    z-index: 1080;
    max-height: 240px;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.custom-select-menu.open {
    display: block;
}

.custom-select.menu-up .custom-select-menu {
    top: auto;
    bottom: calc(100% + 4px);
}

.custom-select-option {
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.86rem;
    color: #1a2b4a;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    transition: background 0.1s;
}

.custom-select-option:hover {
    background: #f1f5f9;
}

.custom-select-option.selected {
    background: #0d6efd;
    color: #fff;
    font-weight: 600;
}

.custom-select-option.selected:hover {
    background: #0b5ed7;
}

.custom-select-menu::-webkit-scrollbar {
    width: 6px;
}

.custom-select-menu::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.custom-select-menu::-webkit-scrollbar-track {
    background: transparent;
}

@media (max-width: 575.98px) {
    .custom-select-display {
        font-size: 0.84rem;
        padding: 5px 9px;
        min-height: 32px;
        height: 32px;
    }
    .modal-body .row.g-2 > .col-6 .custom-select-display {
        font-size: 0.78rem;
        padding: 4px 6px;
        min-height: 30px;
        height: 30px;
    }
    .custom-select-menu {
        max-height: 220px;
    }
    .custom-select-option {
        padding: 9px 12px;
        font-size: 0.82rem;
    }
}

.img-preview-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    overflow: hidden;
    touch-action: none;
}

.img-preview-img {
    max-width: 95%;
    max-height: 95%;
    object-fit: contain;
    user-select: none;
    -webkit-user-select: none;
    transition: transform 0.12s ease-out;
    cursor: zoom-in;
}

.img-preview-img:active {
    cursor: grabbing;
}

.img-preview-tip {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8rem;
    pointer-events: none;
    white-space: nowrap;
}

.img-preview-loading {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    font-size: 0.78rem;
    padding: 4px 12px;
    border-radius: 20px;
    pointer-events: none;
    z-index: 10;
}

.img-preview-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #fff;
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.img-preview-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.img-icon-btn {
    background: #f0f6ff;
    border: 1px solid #cfe2ff;
    border-radius: 6px;
    color: #0d6efd;
    padding: 4px 10px;
    font-size: 1.1rem;
    line-height: 1;
    min-height: unset;
    height: auto;
    cursor: pointer;
    transition: all 0.15s;
}

.img-icon-btn:hover {
    background: #0d6efd;
    color: #fff;
    border-color: #0d6efd;
}

.img-icon-btn.disabled,
.img-icon-btn:disabled {
    background: #f1f3f5;
    border-color: #e9ecef;
    color: #adb5bd;
    cursor: not-allowed;
}

.img-icon-btn.disabled:hover,
.img-icon-btn:disabled:hover {
    background: #f1f3f5;
    color: #adb5bd;
    border-color: #e9ecef;
}

.loc-icon-btn {
    background: #fff5e6;
    border: 1px solid #ffe0b3;
    border-radius: 6px;
    color: #fd7e14;
    padding: 4px 10px;
    font-size: 1.1rem;
    line-height: 1;
    min-height: unset;
    height: auto;
    cursor: pointer;
    transition: all 0.15s;
}

.loc-icon-btn:hover {
    background: #fd7e14;
    color: #fff;
    border-color: #fd7e14;
}

.loc-icon-btn.disabled {
    background: #f1f3f5;
    border-color: #e9ecef;
    color: #adb5bd;
    cursor: not-allowed;
}

.loc-icon-btn.disabled:hover {
    background: #f1f3f5;
    color: #adb5bd;
    border-color: #e9ecef;
}

.loc-icon-btn-sm {
    padding: 1px 6px;
    font-size: 0.9rem;
    vertical-align: middle;
}

.fab-add {
    position: fixed;
    right: 18px;
    bottom: calc(24px + var(--safe-bottom));
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
    border: none;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(16, 185, 129, 0.42);
    z-index: 1040;
    cursor: pointer;
    min-height: unset;
    padding: 0;
    transition: transform 0.15s, box-shadow 0.15s;
}

.fab-add:hover {
    box-shadow: 0 8px 22px rgba(16, 185, 129, 0.52);
}

.fab-add:active {
    transform: scale(0.92);
}

.trip-actions {
    display: flex;
    flex-direction: column;
    padding: 0;
}

.trip-action-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border: none;
    background: transparent;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s;
    color: #212529;
    border-bottom: 1px solid #f0f0f0;
    min-height: unset;
    font-size: 1rem;
    width: 100%;
}

.trip-action-btn:last-child {
    border-bottom: none;
}

.trip-action-btn:hover {
    background: #f8f9fa;
}

.trip-action-btn:active {
    background: #f0f0f0;
}

.trip-action-btn > i:first-child {
    font-size: 1.4rem;
    color: #0d6efd;
    width: 24px;
    text-align: center;
    flex-shrink: 0;
}

.trip-action-btn.danger > i:first-child {
    color: #dc3545;
}

.trip-action-btn.danger .trip-action-title {
    color: #dc3545;
}

.trip-action-btn.warning > i:first-child {
    color: #fd7e14;
}

.trip-action-btn.warning .trip-action-title {
    color: #fd7e14;
}

.trip-action-btn.warning:hover {
    background: #fff5e6;
}

.trip-action-text {
    flex: 1;
    min-width: 0;
}

.trip-action-title {
    font-weight: 600;
    font-size: 0.95rem;
    color: #212529;
    margin-bottom: 2px;
}

.trip-action-sub {
    font-size: 0.78rem;
    color: #999;
}

.trip-action-arrow {
    color: #ced4da;
    font-size: 1rem;
    flex-shrink: 0;
}