/* ================================================
   TRIP DETAILS PAGE — trip-details.css
   ================================================ */

/* ── Page wrapper ── */
.trip-details-page {
    background: #f8fafc;
    min-height: 100vh;
    padding-bottom: 3rem;
}

/* ── Topbar ── */
.page-topbar {
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 0;
}

.page-topbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.breadcrumb-nav {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: #64748b;
    flex-wrap: wrap;
}

.breadcrumb-nav a {
    color: #64748b;
    text-decoration: none;
    transition: color 0.15s;
}

.breadcrumb-nav a:hover { color: #4F46E5; }

.breadcrumb-nav .sep {
    color: #cbd5e1;
    font-size: 0.7rem;
}

.breadcrumb-nav .current {
    color: #1e293b;
    font-weight: 500;
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #475569;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    text-decoration: none;
    transition: background 0.15s;
    white-space: nowrap;
}

.btn-back:hover { background: #e2e8f0; color: #1e293b; }

/* ── Hero ── */
.trip-hero {
    background: linear-gradient(135deg, #4F46E5 0%, #7C3AED 70%, #6D28D9 100%);
    padding: 2rem 0;
    position: relative;
    overflow: hidden;
}

.trip-hero::before {
    content: '';
    position: absolute;
    top: -80px; right: -80px;
    width: 280px; height: 280px;
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
    pointer-events: none;
}

.trip-hero-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1rem;
    position: relative;
    z-index: 1;
}

/* Status badge */
.trip-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.3rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 99px;
    margin-bottom: 1rem;
}

.trip-status-badge.active {
    background: rgba(16,185,129,0.2);
    color: #6ee7b7;
    border: 1px solid rgba(16,185,129,0.3);
}

.trip-status-badge.inactive {
    background: rgba(239,68,68,0.2);
    color: #fca5a5;
    border: 1px solid rgba(239,68,68,0.3);
}

/* Replaces: style="font-size:0.5rem;" on status dot icons */
.status-dot { font-size: 0.5rem; }

/* Route hero */
.trip-hero-route {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (min-width: 640px) {
    .trip-hero-route { flex-wrap: nowrap; gap: 1.5rem; }
}

.hero-city-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.hero-city-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.hero-city-name {
    font-size: clamp(1.5rem, 4vw, 2.25rem);
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.hero-city-country {
    font-size: 0.8125rem;
    color: rgba(255,255,255,0.65);
    font-weight: 500;
}

.hero-route-arrow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    padding: 0 0.5rem;
}

.hero-route-arrow .plane-icon {
    font-size: 1.375rem;
    color: rgba(255,255,255,0.9);
    animation: floatPlane 3s ease-in-out infinite;
}

.hero-route-arrow .route-line {
    display: flex;
    align-items: center;
    gap: 2px;
}

.hero-route-arrow .route-line span {
    display: block;
    width: 30px;
    height: 2px;
    background: rgba(255,255,255,0.3);
    border-radius: 99px;
}

@keyframes floatPlane {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-4px); }
}

/* Stat chips */
.trip-stat-chips {
    display: flex;
    gap: 0.625rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.trip-stat-chip {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 0.75rem 1.25rem;
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 0.75rem;
    min-width: 110px;
    transition: background 0.2s;
}

.trip-stat-chip:hover { background: rgba(255,255,255,0.18); }

.chip-value {
    font-size: 1.375rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
}

.chip-label {
    font-size: 0.7rem;
    color: rgba(255,255,255,0.65);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.chip-sub {
    font-size: 0.65rem;
    color: rgba(255,255,255,0.5);
    margin-top: 1px;
}

/* ── Layout principal ── */
.trip-content {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
}

@media (min-width: 1024px) {
    .trip-content {
        grid-template-columns: 1fr 340px;
        padding: 2rem 1rem;
        gap: 1.5rem;
    }
}

.trip-main    { min-width: 0; display: flex; flex-direction: column; gap: 1.25rem; }
.trip-sidebar { display: flex; flex-direction: column; gap: 1.25rem; }

/* ── Detail cards communes ── */
.detail-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    overflow: hidden;
    animation: fadeInUp 0.5s ease both;
}

.detail-card:nth-child(1) { animation-delay: 0.1s; }
.detail-card:nth-child(2) { animation-delay: 0.15s; }
.detail-card:nth-child(3) { animation-delay: 0.2s; }
.detail-card:nth-child(4) { animation-delay: 0.25s; }

/* FIX: display:flex manquant dans l'original */
.detail-card-header {
    align-items: center;
    gap: 0.625rem;
    padding: 1.125rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
}

.detail-card-icon {
    width: 36px; height: 36px;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.detail-card-icon.indigo  { background: #eef2ff; color: #4F46E5; }
.detail-card-icon.emerald { background: #d1fae5; color: #059669; }
.detail-card-icon.amber   { background: #fef3c7; color: #d97706; }
.detail-card-icon.sky     { background: #e0f2fe; color: #0284c7; }

.detail-card-title {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.detail-card-body { padding: 1.25rem; }

/* ── Route détaillée ── */
.route-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.875rem;
}

@media (min-width: 480px) {
    .route-grid { grid-template-columns: 1fr auto 1fr; align-items: center; }
}

.route-endpoint {
    padding: 1rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
}

.route-endpoint.departure { border-left: 3px solid #4F46E5; }
.route-endpoint.arrival   { border-left: 3px solid #10B981; }

.route-endpoint-label {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 0.375rem;
}

.route-endpoint.departure .route-endpoint-label { color: #4F46E5; }
.route-endpoint.arrival   .route-endpoint-label { color: #10B981; }

.route-endpoint-city {
    font-size: 1.25rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 2px;
}

.route-endpoint-country {
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 0.625rem;
}

.route-endpoint-datetime {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.route-datetime-row {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8rem;
    color: #475569;
}

.route-datetime-row i { width: 14px; text-align: center; color: #94a3b8; font-size: 0.75rem; }

.route-separator { display: none; }

@media (min-width: 480px) {
    .route-separator {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 6px;
        padding: 0 0.5rem;
    }
}

.route-separator i { font-size: 1.125rem; color: #c7d2fe; }

.route-separator-dot {
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #e0e7ff;
}

/* ── GP (transporteur) card ── */
.gp-header-row {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.gp-avatar-wrap { flex-shrink: 0; }

.gp-avatar-img {
    width: 64px; height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #e0e7ff;
    transition: border-color 0.2s, transform 0.2s;
}

.gp-avatar-img:hover { border-color: #4F46E5; transform: scale(1.04); }

.gp-avatar-placeholder {
    width: 64px; height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4F46E5, #7C3AED);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
    border: 3px solid #e0e7ff;
    transition: transform 0.2s;
}

.gp-avatar-placeholder:hover { transform: scale(1.04); }

.gp-meta { flex: 1; min-width: 0; }

.gp-name-link {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1e293b;
    text-decoration: none;
    transition: color 0.15s;
    display: block;
    margin-bottom: 0.25rem;
}

.gp-name-link:hover { color: #4F46E5; }

.gp-stars {
    display: flex;
    align-items: center;
    gap: 2px;
    font-size: 0.8125rem;
    margin-bottom: 0.375rem;
}

.gp-stars .review-count {
    color: #94a3b8;
    font-size: 0.75rem;
    margin-left: 4px;
}

/* Replaces: style="{{ i <= rating ? 'color:#f59e0b' : 'color:#e2e8f0' }}" */
.star--active { color: #f59e0b; }
.star--empty  { color: #e2e8f0; }

.gp-verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.625rem;
    font-size: 0.7rem;
    font-weight: 700;
    color: #059669;
    background: #d1fae5;
    border-radius: 99px;
}

.gp-description {
    padding-top: 0.875rem;
    margin-top: 0.875rem;
    border-top: 1px solid #f1f5f9;
    font-size: 0.875rem;
    color: #475569;
    line-height: 1.6;
}

.gp-actions {
    display: flex;
    gap: 0.625rem;
    flex-wrap: wrap;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

.btn-gp-action {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.55rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 0.5rem;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s, box-shadow 0.15s;
    min-height: 38px;
    white-space: nowrap;
    border: 1.5px solid transparent;
}

.btn-gp-action.phone   { background: #eef2ff; color: #4F46E5; border-color: #c7d2fe; }
.btn-gp-action.phone:hover { background: #e0e7ff; }

.btn-gp-action.email   { background: #f8fafc; color: #475569; border-color: #e2e8f0; }
.btn-gp-action.email:hover { background: #f1f5f9; }

.btn-gp-action.reviews { background: #fffbeb; color: #d97706; border-color: #fde68a; }
.btn-gp-action.reviews:hover { background: #fef3c7; }

.btn-gp-action.favorite { background: #fff1f2; color: #f43f5e; border-color: #fecdd3; }
.btn-gp-action.favorite:hover { background: #ffe4e6; }
.btn-gp-action.favorite.active { background: #f43f5e; color: #fff; border-color: #f43f5e; }

/* ── Services ── */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

@media (min-width: 480px) {
    .services-grid { grid-template-columns: 1fr 1fr; }
}

.service-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
}

.service-item:hover {
    background: #eef2ff;
    border-color: #c7d2fe;
    transform: translateY(-1px);
}

.service-item-icon {
    width: 38px; height: 38px;
    border-radius: 0.5rem;
    background: #eef2ff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #4F46E5;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s;
}

.service-item:hover .service-item-icon { background: #4F46E5; color: #fff; }

.service-item-content { flex: 1; min-width: 0; }

.service-item-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1px;
}

.service-item-desc {
    font-size: 0.75rem;
    color: #64748b;
    line-height: 1.4;
}

.service-insurance-badge {
    padding: 0.2rem 0.5rem;
    font-size: 0.7rem;
    font-weight: 700;
    background: #fef3c7;
    color: #92400e;
    border-radius: 99px;
    white-space: nowrap;
}

/* ── Trust & Sécurité ── */
.trust-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

@media (min-width: 640px) {
    .trust-grid { grid-template-columns: repeat(4, 1fr); }
}

.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.5rem;
    padding: 1rem 0.75rem;
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border: 1px solid #bbf7d0;
    border-radius: 0.75rem;
    transition: transform 0.15s;
}

.trust-item:hover { transform: translateY(-2px); }

.trust-item-icon {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    color: #059669;
    box-shadow: 0 2px 8px rgba(16,185,129,0.2);
}

.trust-item-name {
    font-size: 0.75rem;
    font-weight: 700;
    color: #065f46;
}

/* FIX: suppression de la couleur dupliquée (#6ee7b7 écrasée par #047857) */
.trust-item-desc {
    font-size: 0.65rem;
    color: #047857;
    line-height: 1.3;
}

/* ── Sidebar — Réservation ── */
.booking-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    overflow: hidden;
    position: sticky;
    top: 1.5rem;
    animation: fadeInUp 0.5s 0.2s ease both;
}

.booking-card-header {
    padding: 1.125rem 1.25rem;
    background: linear-gradient(135deg, #4F46E5, #7C3AED);
    color: #fff;
}

.booking-card-title {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.booking-card-subtitle {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.75);
}

.booking-card-body { padding: 1.25rem; }

.booking-price-row {
    display: flex;
    align-items: baseline;
    gap: 0.375rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.booking-price-amount {
    font-size: 2rem;
    font-weight: 800;
    color: #4F46E5;
    line-height: 1;
}

.booking-price-unit {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
}

.booking-recap {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 1.25rem;
}

.booking-recap-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    font-size: 0.8125rem;
}

.booking-recap-label {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    color: #64748b;
}

.booking-recap-label i { width: 14px; text-align: center; color: #94a3b8; font-size: 0.75rem; }

.booking-recap-value {
    font-weight: 600;
    color: #1e293b;
    text-align: right;
}

/* Replaces: style="color:{% if availableCapacity < 5 %}...{% endif %};" */
.capacity--critical { color: #ef4444; }
.capacity--low      { color: #f59e0b; }
.capacity--ok       { color: #059669; }

.booking-capacity-bar { margin-bottom: 1.25rem; }

.booking-capacity-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 0.375rem;
}

.booking-capacity-track {
    height: 6px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
}

.booking-capacity-fill {
    height: 100%;
    background: linear-gradient(to right, #10B981, #059669);
    border-radius: 99px;
    transition: width 0.6s ease;
}

.booking-capacity-fill.low      { background: linear-gradient(to right, #f59e0b, #d97706); }
.booking-capacity-fill.critical { background: linear-gradient(to right, #ef4444, #dc2626); }

.btn-book {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 0.9375rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #4F46E5, #7C3AED);
    border: none;
    border-radius: 0.75rem;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s, opacity 0.15s;
    margin-bottom: 0.75rem;
    min-height: 52px;
}

.btn-book:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(79,70,229,0.35);
    color: #fff;
}

.btn-book:disabled,
.btn-book.disabled {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-book-whatsapp {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, #25d366, #128c7e);
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    margin-bottom: 0.75rem;
    min-height: 46px;
}

.btn-book-whatsapp:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(37,211,102,0.35);
    color: #fff;
}

.btn-book-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    width: 100%;
    padding: 0.625rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #475569;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 0.625rem;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s;
    min-height: 40px;
}

.btn-book-secondary:hover { background: #e2e8f0; color: #1e293b; }

.booking-trust {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.booking-trust-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: #64748b;
}

.booking-trust-item i { color: #10B981; width: 14px; text-align: center; }

.booking-note {
    margin-top: 1rem;
    padding: 0.875rem 1rem;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-left: 3px solid #f59e0b;
    border-radius: 0.625rem;
    font-size: 0.8125rem;
    color: #92400e;
    line-height: 1.5;
}

/* FIX: suppression du display:block redondant (display:flex suffit) */
.booking-note strong {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    color: #78350f;
    margin-bottom: 0.25rem;
}

/* ── Sidebar — Contact GP ── */
.contact-card-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.contact-row {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.875rem;
    color: #334155;
    padding: 0.625rem 0.75rem;
    background: #f8fafc;
    border-radius: 0.5rem;
    text-decoration: none;
    transition: background 0.15s;
    border: 1px solid #e2e8f0;
}

.contact-row:hover { background: #eef2ff; border-color: #c7d2fe; color: #4F46E5; }

.contact-row i {
    width: 32px; height: 32px;
    border-radius: 0.375rem;
    background: #eef2ff;
    color: #4F46E5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.contact-row.phone i    { background: #ecfdf5; color: #059669; }
.contact-row.email i    { background: #e0f2fe; color: #0284c7; }
.contact-row.whatsapp i { background: #f0fdf4; color: #16a34a; }

/* Replaces: style="font-weight:600;" and style="font-size:0.75rem;color:#64748b;" */
.contact-row-title { font-weight: 600; }
.contact-row-desc  { font-size: 0.75rem; color: #64748b; }

/* ── Animations ── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
