/* ============================
   STYLES GLOBAUX
   ============================ */
body {
    background-color: #f4f4f9;
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
}

/* ============================
   EN-TÊTES
   ============================ */
h1, h2, h3 {
    color: #333;
    text-align: center;
    margin-bottom: 10px;
}

h2 {
    margin-bottom: 1.5rem;
}

/* ============================
   CONTENEUR PRINCIPAL
   ============================ */
.container {
    max-width: 800px;
    margin: 20px auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* ============================
   NAVIGATION PRINCIPALE
   ============================ */
.container-fluid {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 10px;
}

.nav-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.nav-left {
    display: flex;
    align-items: center;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Style pour le lien Accueil placé à côté du logo */
.home-link {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    display: inline-block;
    padding: 0.3em 0.6em;
    border-radius: 5px;
    margin-left: 0.5rem;
    transition: background-color 0.2s;
}

.home-link:hover {
    background-color: #f0f0f0;
    text-decoration: none;
}

/* Navigation centrale optimisée */
.nav-center {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 0;
    margin: 0.6rem 0 0.3rem 0;
    list-style: none;
    gap: 1em;
}

.nav-center li {
    display: inline-flex;
    justify-content: center;
}

/* Liens de navigation */
nav a {
    color: black;
    text-decoration: none;
    margin-right: 15px;
}

nav a:hover {
    text-decoration: underline;
}

/* Style spécial pour le lien Mode d'emploi */
.mode-emploi-link {
    color: #B22222 !important;
    font-weight: 500;
}

.mode-emploi-link:hover {
    text-decoration: none !important;
    opacity: 0.9;
}

/* Logo */
.logo {
    max-height: 120px;
    width: auto;
    margin-right: 1rem;
}

/* Sélecteur de langue */
.lang-select {
    padding: 8px;
    border-radius: 5px;
    height: 40px;
    background-color: #f4f4f9;
    border: 1px solid #d9cbb6;
}

/* ============================
   BOUTONS DE NAVIGATION
   ============================ */
.button-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
    max-width: 150px;
}

.button-container a:first-child {
    background-color: #8b6e5a;
    color: white;
    text-align: center;
    padding: 0.5rem;
    border-radius: 8px;
    font-weight: bold;
}

.button-container a:first-child:hover {
    background-color: #7a5f4f;
}

.button-container a:last-child {
    background-color: #d9cbb6;
    color: black;
    text-align: center;
    padding: 0.5rem;
    border-radius: 8px;
    font-weight: bold;
}

.button-container a:last-child:hover {
    background-color: #c7b49e;
}

/* Mode Mobile pour les boutons de navigation */
@media (max-width: 768px) {
    .button-container {
        margin: 0;
        max-width: 90px;
    }

    .button-container a {
        padding: 0.2rem !important;
        font-size: 0.75rem;
    }
}

/* ============================
   BOUTONS
   ============================ */

/* Masquer complètement l'élément de type file */
.file-upload input[type="file"] {
    display: none !important;
}

/* Styles pour les icônes cliquables */
.custom-file-upload, .custom-voice-input {
    background-color: transparent !important;
    color: #e03131 !important;
    border: none !important;
    padding: 0 !important;
    font-size: 14px !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: flex-start !important;
    gap: 5px !important;
}

.custom-file-upload:hover, .custom-voice-input:hover {
    color: #cc0000 !important;
}

/* Styles pour le conteneur des options */
.options-container {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    margin-top: 5px !important;
    flex-wrap: wrap !important;
}

.file-upload, .voice-input {
    flex: none !important;
}

/* Mode Mobile */
@media (max-width: 768px) {
    .options-container {
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 10px !important;
    }

    .file-upload, .voice-input {
        width: 45% !important;
        text-align: left !important;
        font-size: 12px !important;
    }

    /* Styles pour les champs de formulaire sur mobile */
    textarea, input[type="email"] {
        background-color: white !important;
        color: black !important;
        border: 1px solid #ccc !important;
        border-radius: 5px !important;
        padding: 10px !important;
    }

    textarea:focus, input[type="email"]:focus {
        border-color: #007bff !important;
        outline: none !important;
    }

    /* Styles pour la réponse sur mobile */
    #response-section p {
        font-weight: bold !important;
        color: #333 !important;
    }

    /* Styles pour les labels et autres textes sur mobile */
    label, .response-text, .additional-text {
        font-weight: bold !important;
        color: #333 !important;
    }

    .italic-text {
        font-style: italic !important;
        color: #333 !important;
    }
}

/* ============================
   MODE D'EMPLOI
   ============================ */
.category-container {
    max-width: 800px;
    margin: 0.5rem auto;
}

.main-category {
    margin-bottom: 1.5rem;
}

.category-header {
    padding: 0.6rem 1rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    background-color: rgba(217, 203, 182, 0.2);
    margin-bottom: 0.8rem;
}

.category-icon {
    flex-shrink: 0;
}

.category-icon svg {
    width: 32px;
    height: 32px;
}

.category-header h2 {
    margin: 0;
    font-size: 1.3rem;
    color: #5a4736;
    text-align: left;
}

.sub-category {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
    margin-bottom: 0.5rem;
}

.sub-category h3 {
    color: #B22222;
    font-size: 1.15rem;
    margin: 0.3rem 0;
    text-align: left;
    padding-left: 1rem;
}

.topic-group {
    margin-bottom: 0.4rem;
    padding-left: 2rem;
}

.topic-group h4 {
    color: #666;
    font-size: 1rem;
    margin: 0.2rem 0;
}

.topic-items {
    margin-left: 3rem;
    margin-bottom: 0.3rem;
}

.topic-link {
    display: block;
    padding: 0.1rem 0;
    color: #666;
    text-decoration: none;
    transition: color 0.2s;
    line-height: 1.2;
}

.topic-link:hover {
    color: #B22222;
}


/* Style spécial pour le lien Mode d'emploi */
.mode-emploi-link {
    color: #B22222 !important;
    font-weight: 500;
    text-align: center; /* Centrer le texte */
    display: inline-block; /* Assurer que le lien est traité comme un bloc inline */
}

.mode-emploi-link:hover {
    text-decoration: none !important;
    opacity: 0.9;
}

/* Mode Mobile pour le lien Mode d'emploi */
@media (max-width: 768px) {
    .mode-emploi-link {
        display: block; /* Afficher le lien comme un bloc pour centrer le texte */
        text-align: center; /* Centrer le texte */
    }
}

/* ============================
   RESPONSIVE DESIGN
   ============================ */
@media (max-width: 768px) {
    body {
        padding: 0 10px;
    }
    .container-fluid {
        padding: 0.5rem;
    }
    .nav-top {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        margin-bottom: 1rem;
    }
    .nav-right {
        display: flex;
        align-items: center;
        gap: 0.3rem;
        max-width: 65%;
    }
    .lang-select {
        height: 25px;
        padding: 2px;
        font-size: 0.8rem;
        min-width: 50px;
    }
    .logo {
        max-height: 60px;
    }
    .button-container {
        margin: 0;
        max-width: 90px;
    }
    .button-container a {
        padding: 0.2rem !important;
        font-size: 0.75rem;
    }
    .category-header {
        padding: 0.5rem 0.8rem;
    }
    .category-icon svg {
        width: 28px;
        height: 28px;
    }
    .sub-category {
        margin-left: 0;
    }
    .topic-group {
        padding-left: 1.5rem;
    }
    .topic-items {
        margin-left: 2rem;
    }
    .topic-link {
        font-size: 0.95rem;
    }
    
    /* Ajustements pour mobile */
    .nav-center {
        gap: 0.5em;
        margin: 0.4rem 0;
    }
    
    .home-link {
        font-size: 0.9em;
        margin-left: 0.3rem;
    }
}

/* Styles pour la fenêtre modale */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border-radius: 8px;
    width: 80%;
    max-width: 600px;
    position: relative;
}

.modal-header {
    margin-bottom: 15px;
}

.modal-header h3 {
    color: #8b6e5a;
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.modal-description {
    font-size: 0.95rem;
    font-weight: 500;
    color: #444;
    margin-bottom: 15px;
    line-height: 1.3;
}

.example-questions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.example-question {
    padding: 8px 12px;
    background-color: #f5f0eb;
    border: 1px solid #e0d5cc;
    border-radius: 8px;
    margin-bottom: 6px;
    display: block;
    color: #5a4736;
    text-decoration: none;
    transition: all 0.2s;
    font-size: 0.9rem;
    line-height: 1.2;
}

.example-question:hover {
    transform: none;
    color: #B22222;
    background-color: #f8f4f1;
}

.modal-footer {
    text-align: right;
    margin-top: 12px;
}

.return-button {
    background-color: #8b6e5a;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    display: inline-block;
    font-size: 0.9rem;
}

.return-button:hover {
    background-color: #7a5f4f;
}

.close-modal {
    display: none;
}

/* Style optimisé pour les liens spéciaux */
.special-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.15em 0.6em;
    border: 1px solid #c10000;
    border-radius: 6px;
    color: #c10000;
    font-weight: 500;
    font-size: 1em;
    text-decoration: none;
    text-align: center;
    height: 1.8em;
    box-sizing: border-box;
}

.special-link:hover {
    background-color: rgba(193, 0, 0, 0.05);
    text-decoration: none;
}

@media (max-width: 600px) {
    .nav-center {
        padding: 0;
        gap: 0.3em;
    }

    .nav-center a.special-link {
        font-size: 0.85em;
        padding: 0.15em 0.4em;
        height: 1.7em;
    }

/* Styles pour les liens encadrés */
	  .special-link {
		margin-bottom: 2px; /* Réduire la marge en dessous des liens */
	  }



    .nav-center a {
        font-size: 0.85em;
    }

    .intro-text,
    .feature-list li {
        font-size: 1em;
        font-weight: bold;
        line-height: 1.4;
        color: #333;
    }

    .feature-list li {
        margin: 0.2em 0;
    }

    select {
        background-color: #e6d8c3 !important;
        color: #000 !important;
        border: 1px solid #333;
        border-radius: 4px;
    }
}

/* Harmonisation des boutons de la zone de saisie */
textarea + div button,
textarea + div label {
    background-color: #e6d8c3 !important;
    color: black !important;
    border: 1px solid #5c4436;
    border-radius: 6px;
    padding: 0.5em;
}

textarea + div button svg,
textarea + div label svg {
    fill: #5c4436 !important;
}

/* Bouton central "Vos questions" */
.central-question-button {
    text-align: center;
    margin-top: 2px;
    margin-bottom: 1em;
}

.central-question-button .brown-button {
    display: inline-block;
    padding: 0.3em 6.5em; /* ← bien large */
    background-color: #d9cbb6; /* ← couleur exacte du bouton "Abonnement" */
    color: black;
    border-radius: 6px;
    font-weight: 600;
    text-decoration: none;
    font-size: 1.05em;
    border: 1px solid black;
}

.page-title {
    color: #c10000; /* même rouge que les titres des sous-menus */
    font-size: 1.6em;
    font-weight: 600;
    text-align: center;
    margin-bottom: 0.5em;
}

.intro-text {
    background-color: #f8f3ed;
    border-left: 4px solid #c1a96d;
    padding: 1em;
    margin: 1em auto 1.5em auto;
    font-size: 1.05em;
    line-height: 1.4;
    max-width: 800px;
    border-radius: 4px;
}

.feature-list {
    list-style: none;
    padding: 0;
    margin: 1em auto;         /* ← Légèrement réduit */
    max-width: 700px;
}

.feature-list li {
    margin: 0.3em 0;          /* ← Réduit l'espace vertical */
    font-size: 1.02em;        /* ← Léger ajustement, mais facultatif */
    line-height: 1.1;         /* ← Réduit l'interligne */
}

.feature-list li::before {
    content: "✔️";
    color: #c10000;
    margin-right: 0.5em;
}

.brown-button {
    background-color: #d9cbb6;
    color: black;
    font-weight: 600;
    font-size: 1.05em;
    padding: 0.5em 1em;
    border-radius: 6px;
    border: 1px solid black;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.brown-button:hover {
    background-color: #cdbca4;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.2);
    transform: scale(1.01);
}

