* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    color: #2c3e50;
}

.entete {
    background: #16a085;
    color: white;
    padding: 0.8rem 1.2rem;
}
.entete h1 { margin: 0; font-size: 1.3rem; }
.entete p { margin: 0.2rem 0 0; font-size: 0.85rem; opacity: 0.9; }

#carte {
    width: 100%;
    height: calc(100vh - 68px);
}

.bouton-flottant {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
    font-size: 1.2rem;
    cursor: pointer;
}

.panneau {
    position: fixed;
    top: 0;
    right: 0;
    width: min(380px, 100vw);
    height: 100vh;
    background: white;
    box-shadow: -2px 0 12px rgba(0,0,0,0.2);
    z-index: 1100;
    overflow-y: auto;
    padding: 1.2rem;
}
.panneau.hidden { display: none; }

.bouton-fermer {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 6px 10px;
}

.discret { color: #7f8c8d; font-size: 0.85rem; }

.legende-couleurs { list-style: none; padding: 0; }
.legende-couleurs li { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.pastille { width: 14px; height: 14px; border-radius: 50%; display: inline-block; }

.onglets {
    display: flex;
    gap: 4px;
    margin: 1rem 0 1rem 0;
    border-bottom: 1px solid #ecf0f1;
}
.onglet {
    flex: 1;
    padding: 0.5rem;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 0.85rem;
    border-bottom: 2px solid transparent;
}
.onglet.actif {
    border-bottom-color: #16a085;
    font-weight: 600;
    color: #16a085;
}

.contenu-onglet { display: none; }
.contenu-onglet.actif { display: block; }

form label {
    display: block;
    margin-top: 0.8rem;
    margin-bottom: 0.2rem;
    font-size: 0.85rem;
    font-weight: 600;
}

form select, form input[type="date"], form input[type="file"], form textarea {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #dcdde1;
    border-radius: 6px;
    font-size: 0.9rem;
}

fieldset.checklist {
    border: 1px solid #ecf0f1;
    border-radius: 6px;
    margin-top: 0.8rem;
    padding: 0.6rem 0.8rem;
}
fieldset.checklist legend { font-size: 0.85rem; font-weight: 600; padding: 0 4px; }
fieldset.checklist label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: normal;
    margin-top: 0.4rem;
}
fieldset.checklist input { width: auto; }

.bouton-principal {
    margin-top: 1rem;
    width: 100%;
    padding: 0.7rem;
    background: #16a085;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.95rem;
    cursor: pointer;
}
.bouton-principal:hover { background: #138a72; }

.message-retour { margin-top: 0.6rem; font-size: 0.85rem; }
.message-retour.succes { color: #27ae60; }
.message-retour.erreur { color: #c0392b; }

.liste-historique { list-style: none; padding: 0; }
.liste-historique li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #ecf0f1;
    font-size: 0.85rem;
}

@media (max-width: 480px) {
    .panneau { width: 100vw; }
}
