/* ===================================================================
   site.css — Styles globaux TDS LOGISTIC
   (Déplacé depuis le <style> inline de _Layout.cshtml pour être
   effectivement chargé par le navigateur et permettre le cache-busting
   via asp-append-version="true")
=================================================================== */

html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

:root {
    --pt-navy: #1A2B4A;
    --pt-blue: #2E5FA3;
    --pt-steel: #4A6FA5;
    --pt-gray: #6B7280;
    --pt-light: #F8FAFC;
    --pt-white: #FFFFFF;
    --pt-border: #E5E7EB;
    --pt-red: #E2001A;
    --pt-shadow: 0 4px 24px rgba(26,43,74,0.10);
    --pt-shadow-lg: 0 8px 40px rgba(26,43,74,0.16);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'DM Sans', sans-serif;
    background: #F0F2F5;
    color: #1A2B4A;
    font-size: 15px;
    margin-bottom: 60px; /* remplace l'ancien site.css par défaut */
}

/* ── NAVBAR ── */
.pt-navbar {
    background: var(--pt-white);
    border-bottom: 3px solid var(--pt-red);
    box-shadow: 0 2px 16px rgba(26,43,74,0.08);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.pt-logo {
    height: 100px;
    width: auto;
    object-fit: contain;
}

.pt-nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
}

    .pt-nav-links a {
        text-decoration: none;
        color: var(--pt-navy);
        font-weight: 500;
        font-size: 14px;
        padding: 8px 16px;
        border-radius: 8px;
        transition: all .2s;
        display: flex;
        align-items: center;
        gap: 6px;
    }

        .pt-nav-links a:hover {
            background: var(--pt-light);
            color: var(--pt-blue);
        }

    .pt-nav-links .btn-admin {
        background: var(--pt-navy);
        color: white !important;
        border-radius: 8px;
        padding: 8px 18px;
    }

        .pt-nav-links .btn-admin:hover {
            background: var(--pt-blue) !important;
        }

    .pt-nav-links .btn-logout {
        background: #FEF2F2;
        color: var(--pt-red) !important;
        border: 1px solid #FECACA;
        border-radius: 8px;
        padding: 8px 14px;
    }

        .pt-nav-links .btn-logout:hover {
            background: var(--pt-red) !important;
            color: white !important;
        }

.pt-user-chip {
    background: var(--pt-light);
    border: 1px solid var(--pt-border);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 13px;
    color: var(--pt-gray);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ── ALERT ── */
.pt-alert {
    background: #ECFDF5;
    border: none;
    border-left: 4px solid #10B981;
    border-radius: 0;
    color: #065F46;
    padding: 12px 24px;
    font-size: 14px;
}

/* ── BADGES STATUT ── */
.badge-EN_PREPARATION {
    background: #64748B;
    color: #fff;
}

.badge-EXPEDIE {
    background: #2563EB;
    color: #fff;
}

.badge-EN_TRANSIT {
    background: #0284C7;
    color: #fff;
}

.badge-EN_DOUANE {
    background: #D97706;
    color: #fff;
}

.badge-EN_LIVRAISON {
    background: #16A34A;
    color: #fff;
}

.badge-LIVRE {
    background: #15803D;
    color: #fff;
}

.badge-ECHEC {
    background: #DC2626;
    color: #fff;
}

/* ── TIMELINE ── */
.timeline {
    position: relative;
    padding-left: 2rem;
}

    .timeline::before {
        content: '';
        position: absolute;
        left: .6rem;
        top: 0;
        width: 2px;
        height: 100%;
        background: #E5E7EB;
    }

.timeline-item {
    position: relative;
    margin-bottom: 1.5rem;
}

.timeline-dot {
    position: absolute;
    left: -1.9rem;
    top: .25rem;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--pt-blue);
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px var(--pt-blue);
}

    .timeline-dot.active {
        background: #16A34A;
        box-shadow: 0 0 0 2px #16A34A;
    }

/* ── CARTE ── */
#carte {
    height: 380px;
    border-radius: 12px;
    z-index: 1;
}

/* ── CARDS ── */
.pt-card {
    background: white;
    border: 1px solid var(--pt-border);
    border-radius: 16px;
    box-shadow: var(--pt-shadow);
    overflow: hidden;
}

.pt-card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--pt-border);
    font-weight: 600;
    font-size: 14px;
    color: var(--pt-navy);
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
}

.pt-card-body {
    padding: 20px;
}

/* ── STAT CARD ── */
.stat-card {
    background: white;
    border: 1px solid var(--pt-border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: var(--pt-shadow);
    border-top: 4px solid var(--pt-blue);
    transition: transform .2s, box-shadow .2s;
}

    .stat-card:hover {
        transform: translateY(-2px);
        box-shadow: var(--pt-shadow-lg);
    }

/* ── FOOTER ── */
.pt-footer {
    background: var(--pt-navy);
    color: rgba(255,255,255,0.7);
    padding: 20px 0;
    margin-top: 60px;
    font-size: 13px;
}

    .pt-footer a {
        color: rgba(255,255,255,0.5);
        text-decoration: none;
    }

    .pt-footer .footer-logo {
        height: 80px;
        filter: brightness(1) invert(0) opacity(0.7);
    }

.pt-navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    max-width: 1600px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.pt-nav-toggler {
    display: none;
    background: none;
    border: none;
    font-size: 1.7rem;
    color: var(--pt-navy);
    cursor: pointer;
    padding: 6px 8px;
    line-height: 1;
    order: 2;
}

.pt-nav-collapse {
    order: 3;
}
/* Sur desktop large, le menu doit toujours être visible : on ignore l'état
   collapse/show de Bootstrap (qui ne sert que sous 1200px, piloté par le burger) */
@media (min-width: 1200px) {
    .pt-nav-collapse.collapse:not(.show) {
        display: block !important;
    }
}

.pt-user-chip {
    max-width: 220px;
}

.pt-user-chip-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── RESPONSIVE NAVBAR (burger < 1200px) ── */
@media (max-width: 1199.98px) {
    .pt-navbar-inner {
        flex-wrap: wrap;
        height: auto;
        min-height: 60px;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .pt-logo-link {
        order: 1;
    }

    .pt-logo {
        height: 50px;
    }

    .pt-nav-toggler {
        display: block;
    }

    .pt-nav-collapse {
        flex-basis: 100%;
        width: 100%;
    }

    .pt-nav-links {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        gap: 4px;
        padding: 12px 0 16px;
        border-top: 1px solid var(--pt-border);
        margin-top: 8px;
    }

        .pt-nav-links > li {
            width: 100%;
        }

        .pt-nav-links a,
        .pt-nav-links .btn-logout {
            width: 100%;
            justify-content: flex-start;
            padding: 12px 10px;
        }

    .pt-user-chip {
        width: 100%;
        max-width: 100%;
        justify-content: flex-start;
        border-radius: 8px;
    }

    .pt-user-chip-text {
        max-width: none;
        white-space: normal;
        word-break: break-all;
    }
}
