/* Styles personnalisés pour l'application mobile */

/* Styles généraux */
body {
    padding-bottom: 70px; /* Espace pour la barre de navigation fixe */
    background-color: #f8f9fa;
}

/* Adapte les conteneurs aux écrans mobiles */
.container {
    max-width: 100%;
    padding-left: 15px;
    padding-right: 15px;
}

/* Style pour les boutons de commande */
.order-button {
    display: block;
    width: 100%;
    padding: 10px 15px;
    margin-bottom: 10px;
    text-align: left;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    transition: all 0.2s ease-in-out;
}

.order-button:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.order-button .reference {
    font-size: 0.8rem;
    color: #6c757d;
}

.order-button .company {
    margin-top: 5px;
    font-weight: bold;
}

/* Style pour la carte détails */
.order-details {
    background-color: #fff;
    border-radius: 0.25rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 15px;
    margin-bottom: 15px;
}

.order-details .title {
    font-weight: bold;
    margin-bottom: 5px;
    color: #495057;
}

.order-details .value {
    margin-bottom: 15px;
}

.product-item {
    padding: 8px 0;
    border-bottom: 1px solid #dee2e6;
}

.product-item:last-child {
    border-bottom: none;
}

.message-item {
    background-color: #f8f9fa;
    padding: 10px;
    border-radius: 0.25rem;
    margin-bottom: 8px;
}

/* Style pour les formulaires */
.login-container {
    max-width: 400px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 0.25rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Style pour la barre de navigation fixe */
.fixed-bottom {
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* Fix pour les petits écrans */
@media (max-width: 576px) {
    .pagination .page-link {
        padding: 0.25rem 0.5rem;
        font-size: 0.875rem;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .order-button {
        padding: 8px 12px;
    }
}

/* Styles pour les états */
.badge-processed {
    background-color: #28a745;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 18px;
}

.badge-unprocessed {
    background-color: #dc3545;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 18px;
}
/* Modification du style des boutons de commande */
.order-button {
    display: block;
    width: 100%;
    padding: 15px;
    margin-bottom: 15px;
    text-align: left;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    transition: all 0.2s ease-in-out;
    text-decoration: none; /* Retire le soulignement */
    color: #212529; /* Couleur de texte par défaut */
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.order-button:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-decoration: none; /* Assure qu'il n'y a pas de soulignement au survol */
}

/* Style du badge "En attente" */
.badge-unprocessed {
    background-color: #dc3545;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
}

/* Retirer le soulignement de tous les liens */
a {
    text-decoration: none;
}

a:hover {
    text-decoration: none;
}

/* Style pour l'info de référence */
.reference {
    font-size: 0.85rem;
    color: #6c757d;
    margin-top: 3px;
}

/* Style pour l'info de l'entreprise */
.company {
    margin-top: 8px;
    font-weight: 500;
}
.mb-6 {
    margin-bottom: 5rem; /* Augmente la marge pour dépasser la hauteur du footer fixe */
}

.mb-pagination {
    margin-bottom: 70px; /* Ajustez cette valeur selon la hauteur de votre footer */
}
/* Styles pour les animations de swipe */
@keyframes swipeRight {
    0% { transform: translateX(0); }
    50% { transform: translateX(40px); }
    100% { transform: translateX(0); }
}

@keyframes swipeLeft {
    0% { transform: translateX(0); }
    50% { transform: translateX(-40px); }
    100% { transform: translateX(0); }
}

.swipe-right {
    animation: swipeRight 0.3s ease;
}

.swipe-left {
    animation: swipeLeft 0.3s ease;
}

/* Styles pour les indicateurs de sélection */
.order-button {
    position: relative;
    transition: background-color 0.2s;
}

body.selection-mode .order-button::before {
    content: '';
    position: absolute;
    top: 10px;
    right: 10px;
    width: 22px;
    height: 22px;
    border: 2px solid #ddd;
    border-radius: 50%;
    background-color: white;
    transition: all 0.2s;
}

body.selection-mode .order-button.selected::before {
    background-color: #0d6efd;
    border-color: #0d6efd;
    content: '✓';
    color: white;
    text-align: center;
    line-height: 18px;
    font-size: 14px;
}

/* Style pour le bouton SMT (toujours actif) */
#smt-button {
    position: fixed;
    bottom: 100px; /* Valeur augmentée de 65px à 100px */
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    display: none;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    border-radius: 25px; /* Pour un look plus arrondi */
    padding: 10px 20px; /* Un peu plus d'espace pour le texte */
}

#smt-button.visible {
    display: block;
    animation: buttonPop 0.3s ease;
}

@keyframes buttonPop {
    0% { transform: translateX(-50%) scale(0.8); opacity: 0; }
    100% { transform: translateX(-50%) scale(1); opacity: 1; }
}

/* Instructions pour glisser (optionnel) */
#swipe-instructions {
    text-align: center;
    color: #6c757d;
    padding: 10px;
    margin-bottom: 15px;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#swipe-instructions i {
    font-size: 18px;
    margin: 0 5px;
}
.smt-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0; /* Assurez-vous qu'elle couvre toute la hauteur */
    width: 100%;
    height: 100vh; /* Utilisez viewport height */
    background-color: rgba(0,0,0,0.5);
    z-index: 1050;
}

.smt-modal-content {
    background-color: white;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    padding: 20px;
    position: fixed; /* Fixed au lieu d'absolute */
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-height: 80vh; /* Limitez la hauteur */
    overflow-y: auto;
}
nav.fixed-bottom .col-3 {
    flex: 0 0 25%;
    max-width: 25%;
    position: relative;
    width: 100%;
    padding-left: 15px;
    padding-right: 15px;
}

/* Assurer que le bouton d'annulation ne perturbe pas la mise en page quand il est caché */
#cancel-selection[style*="display: none"] {
    visibility: hidden !important;
    opacity: 0 !important;
    height: 0 !important;
    width: 0 !important;
    position: absolute !important;
}

/* Positionnement constant pour le bouton de déconnexion */
nav.fixed-bottom .col-3:last-child {
    text-align: center;
}
/* Décaler tous les boutons légèrement vers la droite */
nav.fixed-bottom .row .col-3 {
    padding-left: 5px;  /* Réduire le padding gauche */
    padding-right: 25px; /* Augmenter le padding droit */
}

/* Ou décaler vers la gauche */
nav.fixed-bottom .row .col-3 {
    padding-left: 15px; /* Augmenter le padding gauche */
    padding-right: 25px;  /* Réduire le padding droit */
}
/* Styles pour les messages */
.employee-message {
    background-color: #f8f9fa;
    border-left: 4px solid #0d6efd !important;
}

.customer-message {
    background-color: #f8f9fa;
    border-left: 4px solid #6c757d !important;
}

.message-content {
    white-space: pre-wrap;
    word-break: break-word;
}
.badge-warning {
    background-color: #ffa807;
    color: #ffffff;
    padding: 5px 30px;
    border-radius: 4p7;
    font-size: 18px;
    font-weight: 500;
}
/* Styles pour le scan */
#video-container {
    position: relative;
}

#scan-video {
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
}

.scan-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scan-target {
    width: 70%;
    height: 30%;
    border: 2px solid rgba(0, 123, 255, 0.5);
    border-radius: 10px;
    box-shadow: 0 0 0 2000px rgba(0, 0, 0, 0.3);
    position: relative;
}

.badge-processed {
    background-color: #28a745;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: bold;
}

.badge-unprocessed {
    background-color: #dc3545;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: bold;
}

/* Animation pour indiquer un traitement réussi */
.scan-success {
    animation: flashSuccess 0.5s;
}

@keyframes flashSuccess {
    0% { background-color: transparent; }
    50% { background-color: rgba(40, 167, 69, 0.3); }
    100% { background-color: transparent; }
}

/* Animation pour indiquer une erreur */
.scan-error {
    animation: flashError 0.5s;
}

@keyframes flashError {
    0% { background-color: transparent; }
    50% { background-color: rgba(220, 53, 69, 0.3); }
    100% { background-color: transparent; }
}
/* Dans la section <style> de votre page */
#barcodeInput:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Animation pour le scan réussi */
@keyframes scanSuccess {
    0% { background-color: transparent; }
    50% { background-color: rgba(25, 135, 84, 0.15); }
    100% { background-color: transparent; }
}

.scan-success {
    animation: scanSuccess 0.8s;
}

/* ... vos autres styles ... */

/* Animation améliorée pour le scan réussi */
@keyframes scanSuccess {
    0% { background-color: transparent; }
    50% { background-color: rgba(25, 135, 84, 0.25); }
    100% { background-color: transparent; }
}

/* Animation pour un scan en double */
@keyframes scanError {
    0% { background-color: transparent; }
    50% { background-color: rgba(220, 53, 69, 0.25); }
    100% { background-color: transparent; }
}

.scan-success {
    animation: scanSuccess 0.8s;
}

.scan-error {
    animation: scanError 0.8s;
}
.btn-pulse {
    animation: pulse 1.5s infinite;
}

    /* Styles pour les quantités de produits */
    .table-sm th {
        font-weight: 600;
        color: #495057;
    }
    
    .badge.rounded-pill {
        font-size: 0.85rem;
        padding: 0.35em 0.65em;
    }
    
    .text-success {
        color: #28a745 !important;
    }
    
    .text-warning {
        color: #ffc107 !important;
    }
    
    .text-danger {
        color: #dc3545 !important;
    }
    
    /* Style existant pour conserver l'apparence */
    .order-details .title {
        font-weight: 600;
        color: #6c757d;
        margin-bottom: 0.3rem;
    }
    
    .order-details .value {
        padding-left: 0.5rem;
    }
    
    .product-item {
        padding: 0.5rem 0;
        border-bottom: 1px solid #f1f1f1;
    }
    
    .product-item:last-child {
        border-bottom: none;
    }
    
    /* Améliorations pour la table responsive */
    .table-responsive {
        margin-top: 0.5rem;
        border-radius: 0.25rem;
        overflow: hidden;
    }
    
    .table-sm {
        margin-bottom: 0;
    }

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}
.badge-preparation {
    background-color: #0d6efd; /* Bleu Bootstrap */
    color: white;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */    font-size: 0.75em;
    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}

.badge-command {
    background-color: #288c3f; /* Vert foncé */
    color: white;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */    font-size: 0.75em;
    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}

.badge-tofinish {
    background-color: #ffc107; /* Jaune Bootstrap */
    color: #212529;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */    font-size: 0.75em;
    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}

.badge-processed {
    background-color: #084298; /* Vert Bootstrap */
    color: white;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}

.badge-processed-tnt {
    background-color: #2a9343; /* Vert foncé pour les commandes avec suivi TNT */
    color: white;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */
    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}

.badge-tnt-missing {
    background-color: #e20101; /* Rouge pour les commandes Mister Minit sans suivi TNT */
    color: white;
    padding: 0.35em 0.65em;
    display: inline-block; /* Force le respect de min-width */
    text-align: center; /* Centre le texte */
    min-width: 100px;
    width: 100px; /* Ajout d'une largeur fixe */
    box-sizing: border-box; /* Inclut padding dans la largeur */
    font-size: 0.75em;
    font-weight: 700;
    border-radius: 0.25rem;
}
    .btn-orange {
        background-color: #FF8C00; /* Orange foncé */
        color: white;
        border-color: #FF8C00;
    }
    .btn-orange:hover {
        background-color: #E07700; /* Orange plus foncé pour le hover */
        border-color: #E07700;
        color: white;
    }