/*
 * Unified "Assign Driver" (تحديد المندوب) button.
 * Single source of truth for the action's look across the whole dashboard:
 * operations tables, shipments, instant shipments and shipment details.
 * RTL/LTR aware (uses logical properties).
 */
.btn-assign-driver {
    --ad-color-1: #f5b849;
    --ad-color-2: #f39c12;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 14px;
    border: 0;
    border-radius: 8px;
    font-size: .8125rem;
    font-weight: 600;
    line-height: 1;
    color: #fff;
    background-image: linear-gradient(135deg, var(--ad-color-1), var(--ad-color-2));
    box-shadow: 0 2px 6px rgba(243, 156, 18, .30);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.btn-assign-driver:hover,
.btn-assign-driver:focus-visible {
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 5px 14px rgba(243, 156, 18, .45);
    filter: saturate(1.05);
}

.btn-assign-driver:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(243, 156, 18, .30);
}

.btn-assign-driver__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .22);
    font-size: 13px;
}

.btn-assign-driver__label {
    white-space: nowrap;
}

/* Tasteful shine sweep to draw attention without being noisy. */
.btn-assign-driver::after {
    content: "";
    position: absolute;
    top: 0;
    inset-inline-start: -80%;
    width: 45%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .4), transparent);
    transform: skewX(-20deg);
    animation: assignDriverShine 2.8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes assignDriverShine {
    0% {
        inset-inline-start: -80%;
    }

    55%,
    100% {
        inset-inline-start: 130%;
    }
}

@media (prefers-reduced-motion: reduce) {

    .btn-assign-driver,
    .btn-assign-driver::after {
        transition: none;
        animation: none;
    }
}
