/* JAOS — Hub Réservations Location (cartes premium) */

.ja-rental-bookings-hub-page .fi-header {
    margin-bottom: 0.5rem;
}

.ja-rental-bookings-hub-page .fi-ta-content,
.ja-rental-bookings-hub-page .fi-ta-content-grid {
    width: 100% !important;
    max-width: none !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.85rem !important;
}

.ja-rental-bookings-hub-page .fi-ta-record {
    width: 100% !important;
    max-width: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border: 0 !important;
    padding: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0 !important;
}

.ja-rental-bookings-hub-page .fi-ta-record > div,
.ja-rental-bookings-hub-page .fi-ta-cell {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    padding: 0 !important;
    border: 0 !important;
}

.ja-rental-bookings-hub-page .fi-ta-actions {
    display: none !important;
}

/* ── Carte réservation ── */
.ja-rental-booking-card {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-radius: 1rem;
    border: 1px solid rgba(148, 163, 184, 0.14);
    background: rgba(15, 23, 42, 0.72);
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ja-rental-bookings-hub-page .fi-ta-record:hover .ja-rental-booking-card {
    border-color: rgba(167, 139, 250, 0.32);
}

.ja-rental-booking-card__body {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    flex: 1 1 auto;
    padding: 1.15rem 1.15rem 1rem;
    color: inherit;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s ease;
}

.ja-rental-booking-card__body:hover {
    background: rgba(124, 77, 255, 0.05);
}

.ja-rental-booking-card__body:focus-visible {
    outline: 2px solid rgba(124, 77, 255, 0.55);
    outline-offset: -2px;
}

.ja-rental-booking-card--mobile {
    margin-bottom: 0.15rem;
}

.ja-rental-booking-card--active {
    border-color: rgba(124, 77, 255, 0.45);
    box-shadow: 0 0 0 1px rgba(124, 77, 255, 0.2);
}

.ja-rental-booking-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.ja-rental-booking-card__ref-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
}

.ja-rental-booking-card__ref {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #c4b5fd;
}

.ja-rental-booking-card__amount {
    font-size: 1.15rem;
    font-weight: 700;
    color: #f8fafc;
    white-space: nowrap;
}

.ja-rental-booking-card__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem 1rem;
}

.ja-rental-booking-card__cell--wide {
    grid-column: span 1;
}

.ja-rental-booking-card__label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.2rem;
}

.ja-rental-booking-card__value {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #e2e8f0;
    line-height: 1.35;
}

.ja-rental-booking-card__client {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.ja-rental-booking-card__client-text {
    min-width: 0;
}

.ja-rental-booking-card__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0 1.15rem 1.15rem;
    border-top: 1px solid rgba(148, 163, 184, 0.1);
    background: rgba(0, 0, 0, 0.08);
}

.ja-rental-booking-card__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.25rem;
    padding: 0.4rem 0.85rem;
    border-radius: 0.6rem;
    border: 1px solid rgba(148, 163, 184, 0.2);
    background: rgba(255, 255, 255, 0.04);
    color: #e2e8f0;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.ja-rental-booking-card__btn:hover:not(:disabled) {
    border-color: rgba(167, 139, 250, 0.4);
    background: rgba(124, 77, 255, 0.1);
}

.ja-rental-booking-card__btn--primary {
    border-color: rgba(124, 77, 255, 0.55);
    background: rgba(124, 77, 255, 0.22);
    color: #f5f3ff;
    font-weight: 700;
}

.ja-rental-booking-card__btn--ghost {
    color: #94a3b8;
}

.ja-rental-booking-card__btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.ja-rental-booking-card__menu {
    position: relative;
}

.ja-rental-booking-card__dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 0.35rem);
    z-index: 30;
    min-width: 11rem;
    padding: 0.35rem;
    border-radius: 0.65rem;
    border: 1px solid rgba(148, 163, 184, 0.18);
    background: #0f172a;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
}

.ja-rental-booking-card__dropdown-item {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem 0.65rem;
    border: 0;
    border-radius: 0.45rem;
    background: transparent;
    color: #e2e8f0;
    font-size: 0.82rem;
    font-weight: 600;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.ja-rental-booking-card__dropdown-item:hover {
    background: rgba(124, 77, 255, 0.12);
}

.ja-rental-booking-card__dropdown-item--danger {
    color: #fca5a5;
}

.ja-rental-status {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    background: rgba(100, 116, 139, 0.2);
    color: #cbd5e1;
}

.ja-rental-status--primary { background: rgba(124, 77, 255, 0.18); color: #ddd6fe; }
.ja-rental-status--success { background: rgba(34, 197, 94, 0.16); color: #86efac; }
.ja-rental-status--warning { background: rgba(245, 158, 11, 0.16); color: #fcd34d; }
.ja-rental-status--danger { background: rgba(239, 68, 68, 0.16); color: #fca5a5; }
.ja-rental-status--info { background: rgba(59, 130, 246, 0.16); color: #93c5fd; }
.ja-rental-status--gray { background: rgba(100, 116, 139, 0.2); color: #cbd5e1; }

/* ── Workflow fiche édition ── */
.ja-rental-booking-edit-page .ja-rental-workflow {
    margin-bottom: 1.25rem;
    padding: 1rem 1.1rem;
    border-radius: 1rem;
    border: 1px solid rgba(124, 77, 255, 0.18);
    background: rgba(15, 23, 42, 0.45);
}

.ja-rental-workflow__timeline {
    overflow-x: auto;
    margin-bottom: 0;
}

.ja-rental-workflow__quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: 0.85rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.ja-rental-workflow__quick-btn {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    background: rgba(255, 255, 255, 0.03);
    color: #cbd5e1;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease;
}

.ja-rental-workflow__quick-btn:hover {
    border-color: rgba(167, 139, 250, 0.35);
    color: #ede9fe;
}

.ja-rental-workflow__pickup-sign {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.85rem;
}

.ja-rental-pickup-sign {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
}

.ja-rental-pickup-sign small {
    font-weight: 600;
    opacity: 0.85;
}

.ja-rental-pickup-sign--ok {
    background: rgba(34, 197, 94, 0.14);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.28);
}

.ja-rental-pickup-sign--missing {
    background: rgba(239, 68, 68, 0.12);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.28);
}

.ja-rental-workflow__sign-link {
    font-size: 0.78rem;
    font-weight: 600;
    color: #c4b5fd;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ja-rental-booking-edit-page .fi-header-actions-ctn {
    flex-wrap: nowrap;
    gap: 0.65rem;
}

@media (max-width: 767px) {
    .ja-rental-booking-card__grid {
        grid-template-columns: 1fr 1fr;
    }

    .ja-rental-booking-card__cell--wide {
        grid-column: span 2;
    }
}

@media (min-width: 768px) {
    .ja-rental-bookings-hub-page .ja-premium-mobile-cards {
        display: none;
    }
}

@media (max-width: 767px) {
    .ja-rental-bookings-hub-page .ja-premium-desktop-table {
        display: none;
    }
}

html.fi:not(.dark) .ja-rental-booking-card {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(148, 163, 184, 0.22);
}

html.fi:not(.dark) .ja-rental-booking-card__actions {
    background: rgba(248, 250, 252, 0.9);
    border-top-color: rgba(148, 163, 184, 0.16);
}

html.fi:not(.dark) .ja-rental-booking-card__body:hover {
    background: rgba(124, 77, 255, 0.04);
}

html.fi:not(.dark) .ja-rental-booking-card__amount,
html.fi:not(.dark) .ja-rental-booking-card__value {
    color: #0f172a;
}

html.fi:not(.dark) .ja-rental-booking-card__ref {
    color: #6d28d9;
}

html.fi:not(.dark) .ja-rental-booking-edit-page .ja-rental-workflow {
    background: rgba(248, 250, 252, 0.9);
    border-color: rgba(124, 77, 255, 0.15);
}

.ja-rental-site-badge{
    display:inline-flex;
    align-items:center;
    padding:.18rem .55rem;
    border-radius:999px;
    font-size:.68rem;
    font-weight:700;
    letter-spacing:.04em;
    text-transform:uppercase;
    border:1px solid rgba(200,166,106,.35);
    background:rgba(200,166,106,.14);
    color:#c8a66a;
}

.ja-rental-site-badge--confirmed{
    border-color:rgba(34,197,94,.35);
    background:rgba(34,197,94,.12);
    color:#86efac;
}

html.fi:not(.dark) .ja-rental-site-badge{
    border-color:rgba(180,140,70,.35);
    background:rgba(200,166,106,.18);
    color:#8b6914;
}

html.fi:not(.dark) .ja-rental-site-badge--confirmed{
    border-color:rgba(22,163,74,.28);
    background:rgba(34,197,94,.12);
    color:#15803d;
}
