:root {
    --primary-color: #2F5233;
    --background-color: #F5F1E9;
    --text-color: #4A4A4A;
    --light-gray: #D3D3D3;
    --white: #FFFFFF;
    --danger: #C62828;
    --warning: #F57C00;
    --radius: 12px;
    --font-main: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    --font-title: 'Georgia', 'Times New Roman', Times, serif;
}

/* --- MISE EN PAGE DE BASE --- */
body {
    font-family: var(--font-main);
    margin: 0;
    background-color: var(--background-color);
    color: var(--text-color);
}
body.static-page, body.admin-page {
	display: block !important;
    height: auto !important; /* La hauteur s'adapte au contenu */
    overflow-y: auto !important; /* On réactive le défilement vertical */
}
body.map-page-body {
    height: 100vh; /* Prend 100% de la hauteur de la fenêtre */
    overflow: hidden; /* Bloque le défilement */
    display: flex;
    flex-direction: column;
}

/* --- EN-TÊTE --- */
header {
    background-color: var(--white);
    padding: 0 2rem; /* On retire le padding vertical */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    z-index: 1001;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px; /* ✨ On fixe la hauteur de l'en-tête */
}

header h1 {
    margin: 0;
    font-size: 1.8rem;
    color: var(--primary-color);
}

header nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

header nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

header nav a:hover {
    color: var(--primary-color);
}
.alerte-tva{
	color:red;							  
}
/* --- CONTENEUR PRINCIPAL DE L'APPLICATION --- */
main {
    flex-grow: 1;
    position: relative;
    background-color: var(--light-gray); /* Fond de carte pendant le chargement */
}

#map {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* --- BARRE DE RECHERCHE EN SUPERPOSITION (MODIFIÉE) --- */
.search-section {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 1000;
    background-color: var(--white);
    padding: 10px 15px; /* Moins de padding vertical */
    border-radius: var(--radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    width: 900px; /* Plus large pour accommoder les boutons */
    max-width: calc(100% - 430px); /* Empêche de superposer la liste de droite */
}

.search-controls {
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-controls input, .search-controls select, .search-controls button {
    padding: 8px 12px; /* Moins de padding pour réduire la hauteur */
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 0.9rem; /* Taille de police légèrement réduite */
}

.search-controls button {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    cursor: pointer;
    height: 37px; /* Aligner la hauteur avec les inputs */
}

/* --- PANNEAU LATÉRAL DES RÉSULTATS --- */
.results-section {
    position: absolute;
    top: 15px;
    right: 15px;
    bottom: 15px;
    width: 380px;
    z-index: 1000;
    background-color: var(--white);
    border-radius: var(--radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.results-section h2 {
    margin: 0;
    padding: 15px;
    font-size: 1.2rem;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

#resultsList {
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* --- CARTES DE LA LISTE --- */
.point-card {
    background-color: var(--white);
    border: 1px solid #eee;
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    cursor: pointer;
    transition: box-shadow 0.3s ease;
	min-height:100px;
}

.point-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.point-card .card-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    flex-shrink: 0;
}

.point-card .card-content {
    padding: 10px;
    flex-grow: 1;
}

.point-card h4 {
    margin: 0 0 5px 0;
    font-size: 1rem;
    color: var(--text-color);
}

.point-card p {
    margin: 2px 0;
    font-size: 0.85rem;
    color: #666;
}

.point-card .card-actions {
    display: none; /* Inutile dans cette mise en page */
}

/* --- STYLES GÉNÉRIQUES POUR LES MODALES --- */
.modal {
    display: none;
    position: fixed;
    z-index: 1001; /* Au-dessus des panneaux superposés */
    left: 0; top: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.6);
    animation: fadeIn 0.3s;
}

.modal-content {
    position: relative;
    background-color: var(--background-color);
    margin: 5vh auto;
    width: 90%;
    max-width: 700px;
    border-radius: var(--radius);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    animation: slideIn 0.3s;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
    flex-shrink: 0;
}

.modal-header h3 {
    margin: 0; padding: 0; border: none; font-size: 1.5rem;
}

.close-button {
    font-size: 28px;
    cursor: pointer;
    color: #aaa;
    transition: color 0.2s ease;
}

.close-button:hover { color: var(--text-color); }

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex-grow: 1;
}

/* --- STYLES SPÉCIFIQUES À LA MODALE DE DÉTAILS --- */
.modal-hero {
    height: 250px;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    justify-content: flex-end;
    padding: 20px;
    color: var(--white);
    flex-shrink: 0;
}

.modal-hero::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 50%);
}

.modal-hero h3 {
    position: relative; z-index: 2; font-size: 2rem;
    margin: 0; text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* --- STYLE POUR LA SECTION D'INFO RAPIDE (MODALE) --- */

.quick-info-section {
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    color: var(--white); /* Le texte sera blanc par défaut */
}

/* On définit la couleur de fond pour chaque statut */
.quick-info-section.ouvert {
    background-color: var(--primary-color);
}
.quick-info-section.fermé {
    background-color: var(--danger);
}
.quick-info-section.bientot {
    background-color: var(--warning);
}
.quick-info-section.inconnu {
    background-color: #757575; /* Un gris neutre */
}

.quick-info-section p {
    margin: 0; /* On retire les marges par défaut des paragraphes */
}

.quick-info-section .status-text {
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.quick-info-section .address-text,
.quick-info-section .distance-text {
    font-size: 1rem;
    opacity: 0.9;
}

.quick-info-section .distance-text {
    margin-top: 5px;
}

.actions-container {
    display: flex;
    justify-content: space-around;
    padding: 15px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}

.action-button { cursor: pointer; font-weight: bold; color: var(--primary-color); }

.heading { font-family: var(--font-title); font-size: 1.5rem; color: var(--primary-color); margin-top: 20px; margin-bottom: 10px; }

/* --- STYLES POUR LES ONGLETS DE LA MODALE --- */
.tab-container {
    display: flex;
    border: 1px solid var(--primary-color);
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 20px;
}

.tab-button {
    flex: 1;
    padding: 10px;
    background-color: transparent;
    border: none;
    cursor: pointer;
    font-weight: bold;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

.tab-button.active, .tab-button:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

#tab-content {
    animation: fadeIn 0.4s;
}

/* --- STYLES POUR LES FILTRES DE CATÉGORIE PRODUIT --- */
.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.category-pill {
    padding: 8px 15px;
    border-radius: 20px;
    background-color: var(--white);
    border: 1px solid var(--light-gray);
    color: var(--text-color);
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.category-pill.active, .category-pill:hover {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
}

/* --- STYLES POUR LA LISTE DE PRODUITS --- */
.produit-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.produit-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 10px;
    background-color: var(--white);
    border-radius: 8px;
    border: 1px solid #eee;
}

.produit-item .produit-prix {
    font-weight: bold;
}

/* --- STYLES POUR LE FORMULAIRE ET LA LISTE D'AVIS --- */
#reviewForm {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

#reviewForm select, #reviewForm textarea {
    width: 100%;
    margin-bottom: 10px;
    /* Utilise les styles de formulaire globaux */
}

.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.review-item {
    border: 1px solid #e0e0e0;
    border-radius: var(--radius);
    padding: 15px;
    background-color: var(--white);
}

.review-item .review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.review-item .review-author {
    font-weight: bold;
    color: var(--text-color);
}

.review-item .review-rating {
    font-size: 1.1em;
    color: var(--warning);
}

.review-item .review-comment {
    margin: 0 0 10px 0;
    line-height: 1.6;
    font-style: italic;
    color: #555;
}

.review-item .review-date {
    font-size: 0.85em;
    color: #888;
    text-align: right;
    margin: 0;
}

																																																	  /* --- STYLES POUR LES PRODUITS --- */
.produit-info {
    display: flex;
    flex-direction: column;
}

.produit-nom {
    font-weight: bold;
}

.bio-badge-produit {
    display: inline-block;
    margin-left: 8px;
    padding: 2px 6px;
    border-radius: 10px;
    background-color: var(--primary-color);
    color: var(--white);
    font-size: 0.7rem;
    vertical-align: middle;
}

.allergenes-container {
    display: flex;
    flex-wrap: wrap;
    margin-top: 5px;
}

.allergene-pill {
    font-size: 0.75rem;
    color: var(--danger);
    background-color: #FFEBEE;
    border-radius: 10px;
    padding: 2px 8px;
    margin-right: 5px;
    margin-bottom: 5px;
}

/* --- STYLES POUR LES FILTRES AVANCÉS (MODIFIÉS) --- */
.advanced-filters {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px; /* Espacement vertical et horizontal réduit */
    align-items: center;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group.checkbox-group {
    flex-direction: row;
    align-items: center;
}

.filter-group label {
    font-weight: bold;
    font-size: 0.9rem;
}

#rayonSlider {
    width: 150px;
}
																																																				
																																																				/* --- STYLES POUR LES PAGES D'AUTHENTIFICATION --- */
.auth-main {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 20px;
}

.auth-section {
    width: 100%;
    max-width: 450px;
    background-color: var(--white);
    padding: 30px 40px;
    border-radius: var(--radius);
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.auth-section h2 {
    text-align: center;
    margin-top: 0;
    font-size: 2rem;
}

.auth-subtitle {
    text-align: center;
    color: #666;
    margin-top: -15px;
    margin-bottom: 30px;
}

.auth-section .input-container {
    margin-bottom: 20px;
}

.auth-section button[type="submit"] {
    width: 100%;
    margin-top: 10px;
}

.auth-link {
    text-align: center;
    margin-top: 25px;
}

.auth-link a {
    color: var(--primary-color);
    font-weight: bold;
    text-decoration: none;
}
.auth-link a:hover {
    text-decoration: underline;
}
																																																							  /* --- STYLES SPÉCIFIQUES POUR LES FORMULAIRES D'AUTHENTIFICATION --- */

.auth-section .input-container input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 1rem;
    box-sizing: border-box; /* Important pour que le padding soit inclus */
}

.auth-section button[type="submit"] {
    width: 100%;
    padding: 15px;
    margin-top: 10px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.auth-section button[type="submit"]:hover {
    background-color: #1a3a1c; /* Une version plus foncée du vert primaire */
}
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
    flex-shrink: 0;
}

.results-header h2 {
    margin: 0;
    padding: 0;
    border: none;
    font-size: 1.2rem;
}

.results-header .close-button {
    /* On réutilise le style du bouton de fermeture de la modale */
    position: static; /* On annule la position absolue */
    font-size: 24px;
    padding: 0 5px;
    border: none;
    background: transparent;
}
/* --- AUTRES --- */
.status-message { text-align: center; margin-top: 15px; padding: 10px; border-radius: 8px; }
.status-message.error { color: var(--danger); background-color: #ffe0e0; border: 1px solid var(--danger); }
.status-message.success { color: #155724; background-color: #d4edda; border: 1px solid #c3e6cb; }
/* --- STYLE POUR LE BOUTON FLOTTANT --- */
.fab {
    position: absolute;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
    width: 60px;
    height: 60px;
    border-radius: 30px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    font-size: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.fab:hover {
    transform: scale(1.1);
}	
/* --- STYLES POUR LA MODALE DE SUGGESTION --- */

#suggestForm {
    display: flex;
    flex-direction: column;
    gap: 15px; /* Espace entre les groupes de champs */
}

#suggestForm label {
    font-weight: bold;
    margin-bottom: -5px; /* Rapproche le label de son champ */
    font-size: 0.9rem;
}

/* Styles pour les champs de saisie, select et textarea */
#suggestForm input[type="text"],
#suggestForm select,
#suggestForm textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 1rem;
    box-sizing: border-box;
}
#suggestForm button {
    padding-top: 12px;
    padding-bottom: 12px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    border-radius: var(--radius);
    transition: all 0.2s ease;
    width: 100%; /* S'assurer qu'ils prennent toute la largeur */
}

#suggestForm .button-style.secondary {
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

#suggestForm .button-style.secondary:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

#suggestForm .button-style[type="submit"] {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
}

#suggestForm .button-style[type="submit"]:hover {
    background-color: #1a3a1c;
}

#suggestForm textarea {
    height: 120px;
    resize: vertical;
}

/* Style pour le bouton "Utiliser ma position" */
#useCurrentLocationBtn {
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    width: 100%;
}
#useCurrentLocationBtn:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Style pour l'aperçu de la photo */
#photoPreview {
    max-width: 120px;
    height: auto;
    border-radius: var(--radius);
    border: 1px solid var(--light-gray);
    align-self: center; /* Centre l'aperçu */
}
/* --- STYLES POUR LA PAGE D'ADMINISTRATION --- */

/* Conteneur principal */
.admin-main {
    max-width: 1200px; /* Limite la largeur pour une meilleure lisibilité */
    margin: 30px auto; /* Centre le bloc horizontalement avec des marges */
    padding: 0 20px;   /* Ajoute un peu d'espace sur les côtés */
    background-color: transparent;
    box-shadow: none;
}

/* Panneau de navigation des outils */
.admin-controls {
    background-color: var(--white);
    padding: 20px;
    border-radius: var(--radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    margin-bottom: 30px;
}
/* Style de base pour TOUS les boutons dans ce menu */
.admin-controls button {
    padding: 10px 22px;
    border-radius: 50px; /* Forme "pilule" */
    font-weight: bold;
    font-size: 0.9rem;
    border: 2px solid var(--primary-color);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}
.admin-controls h2 {
    width: 100%;
    margin: 0 0 10px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    font-size: 1.5rem;
}
/* 2. Améliorer les boutons du menu d'outils */
.admin-controls .button-style {
    transition: all 0.2s ease-in-out;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.admin-controls .button-style:hover {
    transform: translateY(-2px); /* Effet de lévitation au survol */
    box-shadow: 0 4px 8px rgba(0,0,0,0.12);
}

/* Style pour le bouton ACTIF (celui qui n'a pas la classe 'secondary') */
.admin-controls .button-style {
    background-color: var(--primary-color);
    color: var(--white);
    border: 1px solid var(--primary-color);
}

/* Style pour les boutons INACTIFS */
.admin-controls .button-style.secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}
.admin-controls .button-style.secondary:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Sections de formulaire (cartes) */
.form-section {
    background-color: var(--white);
    padding: 25px;
    border: none;
    border-radius: var(--radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-bottom: 30px;
}

.form-section h3 {
    margin-top: 0;
    font-size: 1.3rem;
}
.form-section form button[type="submit"] {
    /* On réutilise le style de base */
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 12px 25px;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    transition: all 0.2s ease-in-out;
    width: auto; /* Permet au bouton de s'adapter à son contenu */
    display: inline-block;
    margin-top: 10px;
}

.form-section form button[type="submit"]:hover {
    background-color: #1a3a1c; /* Vert plus foncé */
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

																																																																																														  
/* --- STYLE UNIFIÉ POUR TOUS LES BOUTONS DANS L'ADMIN --- */

.form-section .button-style {
    /* Style de base */
    display: inline-block;
    text-decoration: none;
    border: none;
    
    /* Apparence Primaire (fond vert) */
    background-color: var(--primary-color);
    color: var(--white);
    
    /* Dimensions et Forme */
    padding: 12px 25px;
    border-radius: var(--radius);
    
    /* Typographie */
    font-size: 1rem;
    font-weight: bold;
    text-align: center;
    
    /* Comportement */
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.form-section .button-style:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Style Secondaire (contour) */
.form-section .button-style.secondary {
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.form-section .button-style.secondary:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Style pour les boutons désactivés (ex: plan d'abonnement actuel) */
.form-section .button-style:disabled {
    background-color: var(--light-gray);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
    border-color: var(--light-gray);
}
/* Cas particulier pour le petit formulaire "Ajouter Catégorie" */
.inline-form button[type="submit"] {
    flex-shrink: 0; /* Empêche le bouton de se compresser */
    padding: 10px 20px;
}
/* Styles pour les tableaux */
#pointsListTableContainer, #reviewListTableContainer {
    overflow-x: auto;
    border: 1px solid #ddd;
    border-radius: var(--radius);
}

#pointsListTable, #reviewListTable {
    width: 100%;
    border-collapse: collapse;
}

#pointsListTable th, #reviewListTable th {
    background-color: #f8f9fa;
    padding: 12px 15px;
    text-align: left;
    font-size: 0.9rem;
    color: var(--text-color);
    text-transform: uppercase;
    border-bottom: 2px solid #ddd;
}

#pointsListTable td, #reviewListTable td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}

#pointsListTable tbody tr:last-child td,
#reviewListTable tbody tr:last-child td {
    border-bottom: none;
}

#pointsListTable tbody tr:hover,
#reviewListTable tbody tr:hover {
    background-color: #f1f1f1;
}

#pointsListTable button, #reviewListTable button {
    padding: 6px 12px;
    font-size: 0.85rem;
    margin-right: 5px;
    /* Utilise les styles de boutons globaux */
}																																																						  
/* --- STYLES SPÉCIFIQUES POUR L'ADMINISTRATION (SUITE) --- */

/* Formulaires Admin */
.form-section form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px 25px;
}

.form-section label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

/* Certains champs prennent toute la largeur */
.form-section #mapAdmin,
.form-section h3,
.form-section button[type="submit"] {
    grid-column: 1 / -1;
}

/* Outil de Fusion */
#mergeToolSection .results-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}
#mergeToolSection .merge-item {
    padding: 10px;
    border: 1px solid #eee;
    border-radius: 8px;
}

/* Tableaux */
#pointsListTable button.delete-btn,
#reviewListTable button.delete-review-btn {
    background-color: var(--danger);
    border-color: var(--danger);
}
#pointsListTable button.delete-btn:hover,
#reviewListTable button.delete-review-btn:hover {
    background-color: #9a1e1e;
}
/* --- CORRECTIONS POUR LA PAGE D'ADMINISTRATION --- */

/* 1. Réactive le défilement UNIQUEMENT pour la page admin */
body.admin-page {
    overflow: auto;
}

/* 2. Style pour les boutons du menu d'outils */
.admin-controls .button-style {
    /* Utilise les styles de .button-style que nous avons déjà */
}
.admin-controls .button-style.secondary {
    /* Utilise les styles de .button-style.secondary */
}

/* 3. Style pour tous les champs de formulaire dans l'admin */
.form-section input[type="text"],
.form-section input[type="number"],
.form-section input[type="file"],
.form-section select,
.form-section textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 1rem;
    box-sizing: border-box;
    margin-top: 5px;
}
/* --- STYLES POUR LE FORMULAIRE ADMIN --- */

/* Classe pour les éléments qui doivent prendre toute la largeur du formulaire */
.full-width {
    grid-column: 1 / -1;
}

.coords-container {
    display: flex;
    gap: 25px; /* Espace entre les deux champs */
}

.coords-container > div {
    flex: 1; /* Chaque champ prend la moitié de l'espace */
}
																																																																																											  
/* --- STYLES POUR LE GESTIONNAIRE DE PRODUITS/CATÉGORIES --- */
.inline-form {
    display: flex;
    gap: 10px;
    margin: 20px 0;
    align-items: center;
}

.inline-form input {
    flex-grow: 1;
    margin-bottom: 0;
}

.list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background-color: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 8px;
    margin-bottom: 5px;
}

.button-style-delete {
    background-color: var(--danger);
    color: var(--white);
    border: none;
    padding: 5px 10px;
    border-radius: 8px;
    cursor: pointer;
}
/* --- STYLES POUR LA GESTION D'ABONNEMENT --- */
.subscription-plans {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}
.plan-card {
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
}
.plan-card.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(47, 82, 51, 0.2);
    transform: scale(1.02);
}
.plan-card h4 {
    margin-top: 0;
    color: var(--primary-color);
}
.plan-card .plan-price {
    font-size: 1.5rem;
    font-weight: bold;
    margin: 10px 0 0 0; /* On réduit la marge du bas */
}

.plan-card .plan-yearly {
    font-size: 0.9rem;
    color: #666;
    margin: 0 0 10px 0; /* On ajoute une petite marge en haut */
}
.plan-card ul {
    list-style: none;
    padding: 0;
    margin: 20px 0;
    text-align: left;
}
.plan-card ul li {
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}
.plan-card ul li::before {
    content: '✓';
    color: var(--primary-color);
    position: absolute;
    left: 0;
}
.plan-card button:disabled {
    background-color: var(--light-gray);
    cursor: not-allowed;
}
.current-plan {
    font-weight: bold;
    padding: 3px 8px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 8px;
}
.checkbox-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: var(--radius);
    border: 1px solid var(--light-gray);
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 5px;
}

.checkbox-group input[type="checkbox"] {
    width: auto; /* Annule le style global des inputs */
}

.checkbox-group label {
    margin-bottom: 0; /* Annule la marge par défaut */
    font-weight: normal;
}
/* --- STYLES POUR LES MODES DE PAIEMENT --- */
.payment-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.payment-method {
    display: flex;
    align-items: center;
    gap: 8px;
    background-color: var(--white);
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid #eee;
    font-size: 0.9rem;
}

.payment-method i {
    color: var(--primary-color);
    font-size: 1.5rem;
    width: 25px; /* Pour un alignement parfait */
    text-align: center;
}

/* --- STYLES POUR LA MODALE DE RÉCLAMATION --- */

#claimForm {
    display: grid;
    /* On crée une grille de 2 colonnes pour les champs courts */
    grid-template-columns: 1fr 1fr;
    gap: 15px 25px; /* Espace vertical et horizontal entre les champs */
}

/* On force certains éléments à prendre toute la largeur */
#claimForm p,
#claimForm label[for="claimSociete"],
#claimForm input#claimSociete,
#claimForm label[for="claimSiegeSocial"],
#claimForm textarea#claimSiegeSocial,
#claimForm label[for="claimMessage"],
#claimForm textarea#claimMessage,
#claimForm .checkbox-group,
#claimForm button[type="submit"],
#claimForm #claimMessageStatus {
    grid-column: 1 / -1;
}

#claimForm label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
    font-size: 0.9rem;
}

#claimForm textarea {
    min-height: 80px;
    resize: vertical;
}

/* On s'assure que le groupe de la case à cocher est bien stylisé */
#claimForm .checkbox-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}
#claimForm .checkbox-group input {
    width: auto;
}
#claimForm .checkbox-group label {
    margin-bottom: 0;
    font-weight: normal;
}
#claimForm button[type="submit"] {
    width: 100%;
    padding: 15px;
    margin-top: 10px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#claimForm button[type="submit"]:hover {
    background-color: #1a3a1c; /* Vert plus foncé */
}
.close-button {
    /* Positionnement */
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;

    /* Apparence */
    width: 36px;
    height: 36px;
    border-radius: 18px; /* Cercle parfait */
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(2px); /* Effet de flou (navigateurs modernes) */
    
    /* Centrage de l'icône */
    display: flex;
    justify-content: center;
    align-items: center;

    /* Réinitialisation */
    border: 1px solid rgba(0,0,0,0.1);
    padding: 0;
    cursor: pointer;
    
    /* Effets */
    transition: all 0.2s ease;
}

.close-button:hover {
    background-color: var(--white);
    transform: rotate(90deg);
}

.close-button i {
    font-size: 20px;
    color: var(--text-color);
}

/* --- STYLES POUR LA LISTE DES RÉCLAMATIONS --- */

.claim-item {
    flex-direction: column; /* On passe en colonne pour les détails */
    align-items: flex-start;
    gap: 10px;
}

.claim-info {
    width: 100%;
}

.claim-info p {
    margin: 4px 0;
    font-size: 0.9rem;
    color: #333;
    line-height: 1.4;
}

.claim-info p strong {
    color: var(--text-color);
    min-width: 150px;
    display: inline-block;
}

.claim-info p em {
    color: #555;
}

.claim-actions {
    align-self: flex-end; /* Aligne les boutons à droite */
    display: flex;
    gap: 10px;
    border-top: 1px solid #eee;
    padding-top: 10px;
    width: 100%;
    justify-content: flex-end;
}
/* --- STYLES POUR LA MISE EN PAGE SUPER ADMIN --- */
.super-admin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Deux colonnes de largeur égale */
    gap: 30px;
    align-items: start;
}

.admin-column .form-section {
    margin-top: 0; /* On retire la marge du haut pour les sections dans les colonnes */
}

.admin-search-input {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    box-sizing: border-box;
}

/* --- STYLES POUR LA MODÉRATION DES AVIS --- */

.review-admin-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

.review-info p {
    margin: 3px 0;
    font-size: 0.9rem;
}

.review-info p strong {
    color: var(--text-color);
}

.review-info .review-rating {
    font-size: 1.1em;
    color: var(--warning);
}

.review-info .review-comment {
    font-style: italic;
    color: #555;
    background-color: #f9f9f9;
    padding: 8px;
    border-radius: 6px;
    border: 1px solid #eee;
}

.review-actions {
    align-self: flex-end;
    margin-top: 5px;
}
/* --- STYLES POUR LES STATISTIQUES --- */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 20px;
}
.stat-card {
    background-color: #f9f9f9;
    border: 1px solid #eee;
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
}
.stat-card .stat-value {
    display: block;
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
}
.stat-card .stat-label {
    font-size: 1rem;
    color: #666;
}
.form-links {
    text-align: center;
    margin-top: 20px;
    font-size: 0.9rem;
}
.form-links a { color: var(--primary-color); }
.form-links p { margin-top: 10px; }
/* --- STYLES POUR L'INFOBULLE DE LA CARTE (POPUP) --- */

/* On personnalise le conteneur de base de Leaflet */
.leaflet-popup-content-wrapper {
    border-radius: var(--radius) !important;
    padding: 1px !important;
    background-color: var(--white);
}
.leaflet-popup-content .custom-popup {
    margin: 0 !important;
    width: 250px !important; /* Largeur fixe pour la cohérence */
}
.leaflet-popup-close-button {
    padding: 8px 8px 0 0 !important;
}

/* Nos styles personnalisés pour le contenu */
.map-popup {
    padding: 10px;
    font-family: var(--font-main);
}
.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
    margin-bottom: 8px;
}
.popup-header h4 {
    margin: 0;
    font-family: var(--font-title);
    color: var(--primary-color);
    font-size: 1.1rem;
    line-height: 1.2;
}
.popup-bio {
    font-size: 0.7rem;
    font-weight: bold;
    background-color: var(--primary-color);
    color: var(--white);
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 5px;
}
.popup-info {
    font-size: 0.9rem;
    margin: 4px 0;
    color: #555;
}
.popup-footer {
    margin-top: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}
.popup-distance {
    font-weight: bold;
}
.popup-action {
    color: var(--primary-color);
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
}
.popup-action:hover {
    text-decoration: underline;
}
/* --- STYLES POUR L'AFFICHAGE DE L'ABONNEMENT --- */
.subscription-status-box {
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    border-left-width: 5px;
    border-left-style: solid;
}
.subscription-status-box.status-active {
    background-color: #e8f5e9; /* Vert clair */
    border-left-color: var(--primary-color);
}
.subscription-status-box.status-canceled {
    background-color: #fff3e0; /* Orange clair */
    border-left-color: var(--warning);
}
.subscription-status-box p {
    margin: 0;
    font-weight: bold;
}

.cancel-subscription-container {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
}
.cancel-subscription-container p {
    font-size: 0.9rem;
    color: #666;
}

.button-style-delete {
    background-color: var(--danger);
    color: var(--white);
    /* ... autres styles de bouton ... */
}
.address-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.address-group input {
    flex-grow: 1; /* L'input prend toute la place disponible */
    margin-bottom: 0; /* On retire la marge par défaut des inputs dans ce groupe */
}
/* --- STYLES SPÉCIFIQUES POUR LES FORMULAIRES (Contact, Login, Register) --- */

.auth-section .input-container input,
.auth-section .input-container textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: var(--font-main); /* Assure la même police */
    box-sizing: border-box;
}

.auth-section .input-container textarea {
    height: 150px; /* Donne une hauteur par défaut */
    resize: vertical; /* Permet à l'utilisateur de redimensionner verticalement */
}

.auth-section button[type="submit"] {
    width: 100%;
    padding: 15px;
    margin-top: 10px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.auth-section button[type="submit"]:hover {
    background-color: #1a3a1c;
}
/* --- LOGO CORRIGÉ --- */
.header-logo img {
    height: 60px; /* ✨ Le logo prendra 60px de hauteur (laissant 5px de marge en haut/bas) */
    width: auto;
    display: block; /* Améliore le rendu de l'image */
}
/* --- STYLES POUR LES PAGES STATIQUES (Mentions Légales, etc.) --- */
.static-page-main {
    max-width: 800px;
    margin: 30px auto;
    padding: 20px;
	overflow-y:auto;
}

.static-page-content {
    background-color: var(--white);
    padding: 30px 40px;
    border-radius: var(--radius);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
	
}
.static-page-content h3 {
    margin-top: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

/* --- STYLES POUR LES LIENS DU PIED DE PAGE --- */
.footer-links {
    margin-top: 10px;
}

.footer-links a {
    color: #666;
    text-decoration: none;
    margin: 0 10px;
}

.footer-links a:hover {
    text-decoration: underline;
}
/* --- CORRECTION POUR LE DÉFILEMENT DES PAGES STATIQUES --- */
/* EXCEPTION pour les pages de contenu qui DOIVENT défiler */
.filterModalContainer {
    background-color: var(--background-color);
    padding: SIZES.padding;
    border-top-left-radius: SIZES.radius * 1.5;
    border-top-right-radius: SIZES.radius * 1.5;
    max-height: 90vh; 																								
}
/* --- STYLE MODERNE POUR LE PIED DE PAGE (FOOTER) --- */

footer {
    background-color: var(--white);
    color: #666; /* Un gris plus doux pour le texte */
    padding: 30px 20px;
    text-align: center;
    border-top: 1px solid #e0e0e0;
    margin-top: auto; /* Permet de le "coller" en bas sur les pages courtes */
}

.footer-links {
    margin-top: 10px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap; /* Pour les petits écrans */
    gap: 10px 20px; /* Espace vertical et horizontal */
}

.footer-links a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}
/* --- STYLE MODERNE POUR LE SÉLECTEUR MENSUEL/ANNUEL --- */

.billing-cycle-selector {
    display: flex;
    background-color: #e9e9e9;
    border-radius: 50px; /* Conteneur arrondi */
    padding: 4px;
    margin: 10px auto;
    width: fit-content; /* S'adapte à la taille du contenu */
}

.billing-cycle-selector input[type="radio"] {
    display: none; /* On cache le bouton radio moche */
}

.billing-cycle-selector label {
    padding: 8px 16px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    color: #555;
    transition: all 0.3s ease;
}

/* Style du label quand le bouton radio correspondant est coché */
.billing-cycle-selector input[type="radio"]:checked + label {
    background-color: var(--primary-color);
    color: var(--white);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}
/* Fichier: global.css (à ajouter à la fin) */

/* ------------------------------------------- */
/* --- STYLES POUR LA MODALE DE BIENVENUE --- */
/* ------------------------------------------- */

#welcomeModal {
    z-index: 2000;
}

/* STYLE MODIFIÉ : Centrage du contenu de l'en-tête */
/* STYLE CORRIGÉ : Utilisation de Flexbox pour empiler et centrer le logo et le titre */
#welcomeModal .modal-header {
    display: flex;
    flex-direction: column; /* Aligne les éléments verticalement (logo au-dessus, titre en dessous) */
    align-items: center;   /* Centre horizontalement le logo et le titre */
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

#welcomeModal .modal-logo {
    max-height: 50px;
    margin-bottom: 15px;
}

/* STYLE AJOUTÉ : Image d'accueil dans la modale */
#welcomeModal .modal-image {
    width: 100%;
    height: 180px; /* Hauteur fixe pour l'image */
    object-fit: cover; /* Assure que l'image couvre l'espace sans se déformer */
    border-radius: 8px; /* Bords arrondis */
    margin-bottom: 20px;
}

#welcomeModal .modal-body {
    padding-top: 20px;
}

#welcomeModal .modal-footer {
    text-align: center;
    padding-top: 20px;
    margin-top: 15px;
    border-top: 1px solid #f0f0f0;
}

#welcomeModal .moderation-notice {
    font-style: italic;
    font-size: 0.9em;
    color: #666;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

#closeWelcomeModalBtn {
    background-color: #1a3a1c;
    color: white;
    border: none;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

#closeWelcomeModalBtn:hover {
    background-color: #45a049;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

#closeWelcomeModalBtn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}