/* ======== Style global ======== */
:root {
    --main-color: #004a3b;
    --text-light: #fff;
    --text-dark: #222;
    --bg-light: #f6f6f6;
    --bg-medium: #dedede;
    --bg-dark: #333;
    --hover:#006652;
    --shadow: rgba(0,0,0,0.15);

}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "Poppins", sans-serif;
}

body {
    background: var(--bg-light);
    color: var(--text-dark);
    min-height: 100vh;
}

h3{margin-bottom:5px;}

/* ======== Header ======== */
.site-header {
    background: var(--main-color);
    color: var(--text-light);
    position: fixed;
    top: 0;
    width: 100%;
    height: 60px;
    display: flex;
    align-items: center;
    box-shadow: 0 2px 4px var(--shadow);
    z-index: 1000;
}

.header-container {
    position: relative; /* nécessaire pour la position absolue du logo */
    width: 100%;
    max2-width: 1200px;
    margin: auto;
    display: flex;
    justify-content: flex-end; /* on pousse le reste (nav-icons) à droite */
    align-items: center;
    padding: 0 20px;
}

/* Fixe le logo toujours à gauche */
.logo {
    position: absolute;
    left: 20px; /* marge gauche */
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo img {
    height: 50px;
    display: block;
}

.nav-icons {
    display: flex;
    align-items: center;
    gap: 15px;
}

a.icon-link {
    color: var(--text-light);
    width: 22px;
    height: 22px;
}

/* ======== Burger ======== */
.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    cursor: pointer;
}
.burger span {
    width: 22px;
    height: 2px;
    background: var(--text-light);
    border-radius: 2px;
}


/* ======== Sidebar améliorée ======== */
.sidebar {
    position: fixed;
    top: 60px;
    left: -260px;
    width: 260px;
    height: calc(100% - 60px);
    background: var(--main-color);
    color: var(--text-light);
    transition: left 0.3s ease;
    z-index: 999;
    padding-top: 15px;
}
.sidebar.active {
    left: 0;
}

.sidebar-header {
    padding: 0 20px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-user i {
    width: 26px;
    height: 26px;
    color: var(--text-light);
}

.sidebar-menu {
    list-style: none;
    margin-top: 15px;
}

.sidebar-menu li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-light);
    text-decoration: none;
    font-size: 15px;
    transition: background 0.2s;
}
.sidebar-menu li a:hover {
    background: rgba(255, 255, 255, 0.1);
}
.sidebar-menu i {
    width: 20px;
    height: 20px;
}




/* ======== Main ======== */
 .dashboard-content {
    padding: 100px 20px 40px 20px;
    max-width: 1000px;
    margin: auto;
}

/* ======== Hero ======== */
.hero {
    text-align: center;
    background: var(--text-light);
    padding: 60px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

/* ======== Hero ======== */
.section {
    text-align: left;
    margin-bottom:50px;
    background: var(--text-light);
    padding: 60px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}
.section p{
    margin-top:10px;
    margin-bottom:10px;
     margin-left:30px;
}
.section h1{
    margin-top:0px;
    margin-bottom:20px;
   
}
.section h2{
    margin-top:0px;
    margin-bottom:10px;
   
}

.section ul {
    list-style: none;       /* enlève les puces par défaut */
    margin: 15px 0 20px 0;
    padding-left: 0;
    margin-left:20px;
}

.section ul li {
    position: relative;
    padding-left: 44px;   /* ou ta valeur actuelle */
    margin-bottom: 10px;
    line-height: 1.5;
    font-size: 16px;
}
.section ul li::before {
    content: "";
    position: absolute;
    left: 15px;     /* ← enfin visible ! */
    top: 7px;
    width: 8px;
    height: 8px;
    background-color: var(--main-color, #004a3b);
    border-radius: 50%;
}
.section label{
    line-height:30px;
    font-weight:bold;
    width:120px; 
    display:inline-block;
     margin-left:30px;
}




.btn {
    display: inline-block;
    margin-top: 20px;
    background: var(--main-color);
    color: var(--text-light);
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 8px;
    transition: 0.2s;
}
.btn:hover {
    background: var(--hover);
}

/* ======== Footer ======== */
.site-footer {
    text-align: center;
    padding: 20px;
    background: var(--main-color);
    color: var(--text-light);
    margin-top: 40px;
}


/* ======================================================
   🧾 FORMULAIRES — Style général pour le site et dashboard
   ====================================================== */
form {
    
    margin: 20px auto;
    background: var(--text-light);
    padding: 30px 25px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ✅ Centrage du titre et texte d’aide */
form h1, 
form h2 {
    text-align: center;
    color: var(--main-color);
    margin-bottom: 10px;
    font-size: 1.6rem;
}

form p {
    text-align: center;
    font-size: 0.9rem;
    color: var(--bg-dark);
    margin-top: 10px;
}

form small {
    text-align: center;
    font-size: 0.8rem;
    color: var(--bg-dark);
    margin-top: 0px;
}

/* Autres éléments inchangés */
form label {
    font-weight: 600;
    color: var(--bg-dark);
    margin-bottom: 5px;
}

form input,
form select,
form textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #f9f9f9;
    font-size: 15px;
    transition: border 0.2s, box-shadow 0.2s;
    font-family: inherit;
    resize: vertical;
    margin-bottom:5px;
}

form input:focus,
form select:focus,
form textarea:focus {
    outline: none;
    border-color: var(--main-color);
    box-shadow: 0 0 0 2px rgba(0, 74, 59, 0.15);
    background-color: var(--text-light);
}

form button,
button.btn,
a.btn {
    background-color: var(--main-color);
    color: var(--text-light);
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    transition: background 0.25s, transform 0.1s;
}

form button:hover,
button.btn:hover,
a.btn:hover {
    background-color: var(--hover);
}

form button:active,
button.btn:active,
a.btn:active {
    transform: scale(0.98);
}


 form.form-box{
    max-width:100%;
 }

.alert {
    text-align: center;
    padding: 10px 15px;
    border-radius: 6px;
    font-weight: 500;
}
.alert.error { background: #ffe3e3; color: #a80000; border: 1px solid #ffb6b6; }
.alert.success { background: #e8f7ee; color: #007c3b; border: 1px solid #a3e0b6; }

/* ================================
    Liste des clients (dashboard)
   ================================ */
form.clients-filter {
    max-width: 100%;
    margin: 20px auto;

    background: transparent;
    padding: 0;
    box-shadow: none;
    border-radius: 0;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    width: 100%;
    flex-wrap: nowrap;
}

/* Surcharge spécifique pour les champs de la barre de recherche */
.clients-filter input[type="text"],
.clients-filter select,
.clients-filter .btn {
    width: auto;              /* annule le width:100% global */
    background: var(--text-light);
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    padding: 8px 12px;
    height: auto;
}

.clients-filter input[type="text"] {
    flex: 1;
    min-width: 200px;
}

.clients-filter select {
    flex-shrink: 0;
    cursor: pointer;
}

.clients-filter .btn {
    flex-shrink: 0;
    padding: 10px 16px;
    font-size: 14px;
    background-color: var(--main-color);
    color: var(--text-light);
    font-weight: 500;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.25s;
    white-space: nowrap;
    margin-top: 0px;
}

.clients-filter .btn:hover {
    background-color: var(--hover);
}



/* ======= Table ======= */
.clients-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--text-light);
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
    border-radius: 0 0 10px 10px;
    overflow: hidden;
}
.clients-table th,
.clients-table td {
    text-align: left;
    padding: 12px 16px;
    border-bottom: 1px solid #eee;
}
.clients-table th {
    background: var(--bg-medium);;
   
    font-weight: 600;
    white-space: nowrap;
}
.clients-table th a {
    color: var(--text-dark);
    text-decoration: none;
}
.clients-table th a:hover {
    text-decoration: underline;
}
.clients-table tr:hover td {
    background: #f7fdf9;
}
.clients-table td.actions {
    text-align: center;
    white-space: nowrap;
}

/* ======= Icônes ======= */


.icon-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--main-color);
    color:var(--text-light);
    padding: 6px 8px;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.2s;
    margin: 0 2px;
}
.icon-btn:hover {
    background: #d9f3e9;
}
.badge-count {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ef4444;
    color: var(--text-light);
    font-size: 10px;
    font-weight: bold;
    border-radius: 50%;
    min-width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    padding: 0 3px;
    box-shadow: 0 0 2px rgba(0,0,0,0.2);
}


.badge {
    display:inline-block;
    padding:3px 6px;
    border-radius:4px;
    font-size:12px;
    text-transform:capitalize;
    color:var(--text-light);
}
.badge.en_preparation { background:#2563eb; }
.badge.livré { background:#16a34a; }
.badge.annulé { background:#b1b1b1; }
.badge.envoyée { background:#df9b08; }
.badge.payée { background:#16a34a; }
.badge.en_attente { background:#2563eb; }
.badge.annulé { background:#b1b1b1; }
.badge.en_retard { background:#dc2626; }




.commandes{
background: var(--main-color);
padding:10px;
color:var(--text-light);

}

.commandes-table th, .commandes-table td {
    text-align:center;
    border-left:1px solid #e5e7eb;
    border-right:1px solid #e5e7eb;
}
.commandes-table th:first-child, .commandes-table td:first-child {
    border-left:none;
    text-align:left;
}
.commandes-table th:last-child, .commandes-table td:last-child {
    border-right:none;
}
.day-cell {
    background:#fafafa;
    font-weight:600;
    font-size:14px;
}

.icon-btn i {
    width: 18px;
    height: 18px;
}
.icon-btn:hover {
    background: var(--hover);
}

/* ======= Pagination ======= */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 25px;
    gap: 6px;
}
.pagination a {
    padding: 8px 12px;
    background: var(--text-light);
    border: 1px solid #ccc;
    border-radius: 6px;
    text-decoration: none;
    color: var(--main-color);
    font-weight: 500;
    transition: 0.2s;
}
.pagination a:hover {
    background: var(--main-color);
    color: var(--text-light);
}
.pagination a.active {
    background: var(--main-color);
    color: var(--text-light);
    font-weight: 600;
}

hr{
 height: 0;                  /* aucune hauteur réelle */
  border: none;               /* retire le style par défaut */
  border-top: 0px solid #ddd; /* ajoute une ligne fine */
  margin: 40px 0;
}
.inputs-grid {
    display:grid;
    grid-template-columns: repeat(7, 1fr);
    gap:10px;
    margin-top:14px;
    text-align:center;
}


/* tableau de livraion */

.tableau-livraison {
    width: 100%;
    border-collapse: collapse;
    font-size: 16px;
}

.tableau-livraison th {
    padding: 8px;
    border: 1px solid #ddd;
    text-align: left;
    background: var(--main-color);
    color: var(--text-light);
}

.tableau-livraison td {
    padding: 8px;
    border: 1px solid #ddd;
    text-align: left;
}

/* Alternance des lignes */
.tableau-livraison tbody tr:nth-child(odd) {
    background: var(--text-light)fff;
}

.tableau-livraison tbody tr:nth-child(even) {
    background: #f5f5f5;
}

/* Amélioration lisibilité des jours */
.tableau-livraison td.jour {
    font-weight: bold;
    vertical-align: top;
    background: #e8f5f2 !important; /* léger vert pastel */
}

.ligne-jour-blanc td {
    background: var(--text-light) !important;
}

.ligne-jour-gris td {
    background: #f2f2f2 !important;
}

/* cell jour améliorée */
.td-jour {
    font-weight: bold;
    vertical-align: top;
}


:root {
    --main-color: #004a3b;
    --text-light: #fff;
    --text-dark: #222;
    --bg-light: #f6f6f6;
    --bg-medium: #dedede;
    --bg-dark: #333;
    --hover:#006652;
    --shadow: rgba(0,0,0,0.15);

}

/* onglet  */

.tabs { display:flex; gap:10px; margin-top:40px; margin-bottom:-20px; }
.tab-btn {
    padding:20px 18px;
    border:0px solid #ccc;
    background:var(--hover);
    border-radius:2px;
    cursor:pointer;
    color:var(--text-light);
    font-size:16px;
}
.tab-btn.active {
    /* border-bottom:2px solid #2563eb; */
    font-weight:600;
    background:var(--main-color);
}
.tab-content { display:none; }
.tab-content.active { display:block; }




@media (min-width: 1000px) {
    
    .sidebar {
        left: 0;
    }
    .dashboard-content {
    margin-left: 260px; /* largeur de la sidebar */
    padding: 100px 40px 40px 40px; /* un peu plus d’air à gauche */
    max-width: calc(100% - 260px);
  }

    form {
        padding: 20px 15px;
        border-radius: 8px;
    }     
    
}
@media (max-width: 999px) {
    .burger {
            display: flex;
        }
    }

@media (max-width: 768px) {
    .burger {
        display: flex;
    }
  .dashboard-content {
    margin-left: 0;
    padding: 100px 20px 40px 20px;
  }
    form.clients-filter {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .clients-filter input[type="text"],
    .clients-filter select,
    .clients-filter .btn {
        width: 100%;
    }
 .plat-card {
        grid-template-columns: 1fr !important;
        text-align: center;
    }
    .plat-card img {
        margin: 0 auto 15px auto;
    }
    .plat-header {
        flex-direction: column;
        gap: 4px;
    }
    /* Grille inputs responsive */
.inputs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 10px;
    margin-top: 14px;
    text-align: center;
}

}

