:root {
    --color-brand-purple: #872D84;
    --color-brand-green: #04C360;
    --color-link: #3498db;

     --error-color: #e74c3c;

    --bg-light-primary: #faf5f1;
    --bg-light-secondary: #f3eeea;
    --body-gradient: linear-gradient(135deg, #872D84 0%, #04C360 100%);

    --text-dark: #2c3e50;
    --text-muted: #7f8c8d;
    --border-light: #ecf0f1;

    --button-primary-bg: var(--color-brand-green);

    --button-hover-bg: #04a953; /* TODO: Vérifier la couleur vert foncé */
    --button-hover-red-bg : #cc4234; /* TODO: Vérifier la couleur rouge foncé */
    --button-hover-purple-bg: #72256f; /* TODO: Vérifier la couleur violet foncé */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

body {
    background: var(--body-gradient);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-dark);
    line-height: 1.6;
}

.container {
    background: var(--bg-light-primary);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.dashboard-container, .dashboard-container-v2 {
    max-width: none;
    width: 100%;
    height: 100vh;
    padding: 0;
    margin: 0;
    box-shadow: none;
    border-radius: 0;
    display: flex;
    align-items: flex-start;
}

.logo-placeholder {
    text-align: center;
}

.logo-placeholder img {
    max-width: 200px;
    height: auto;
}

h1, h2, h3 {
    color: var(--text-dark);
    font-weight: 600;
    /* margin-bottom: 1.5rem; */
}

h2 {
    font-size: 1.5rem;
}

form {
    /* gap: 10px; */
    display: flex;
    flex-direction: column;
}

.input-label {
    display: block;
    text-align: left;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0px;
    margin-top: 10px;
}

.info-label {
    display: block;
    text-align: left;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 0px;
}

input, textarea {
    padding: 12px 15px;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    font-size: 1rem;
    outline: none;
    resize: none;
    background-color: var(--bg-light-secondary);
    color: var(--text-dark);
}

input::placeholder {
    color: var(--text-muted);
}

/* button {
    padding: 14px;
    background: var(--button-primary-bg);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 1.05rem;
    font-weight: bold;
    cursor: pointer;
    letter-spacing: 0.5px;
} */

a {
    text-decoration: none;
    font-size: 0.95rem;
    display: inline-block;
}

.secondary-link {
    color: var(--text-muted) !important;
    font-size: 0.85rem !important;
    font-weight: normal;
    margin-top: 10px !important;
}

.secondary-link:hover {
    color: var(--text-dark) !important;
    text-decoration: none;
}

.error-msg, .success-msg, .info-msg {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    width: auto;
    max-width: 90%;
    padding: 12px 24px;
    border-radius: 50px;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    margin-bottom: 0;
}

.error-msg {
    color: var(--error-color);
    background: #fff0f0;
    border: 1px solid var(--error-color);
}

.success-msg {
    color: var(--color-brand-green);
    background: #f0fff4;
    border: 1px solid var(--color-brand-green);
}

.info-msg{
    color : var(--color-link);
    background: #e0f8ff;
    border: 1px solid var(--color-link);
}

#rgpd-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.rgpd-content {
    background: #faf5f1;
    padding: 35px;
    border-radius: 15px;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    border-top: 6px solid #e74c3c;
}

.icon {
    margin-right: 10px;
    font-size: 1.2rem;
}

input.input-error {
    border-color: var(--error-color) !important;
    background-color: #fce4e4; /* Optionnel : fond légèrement rouge */
}

input.input-error:focus {
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.2); /* Halo rouge au focus */
}



/* Sur mobile, on adapte la position */
@media (max-width: 850px) {
    #chatbot-toggler {
        bottom: 200px !important; /* Au-dessus de la barre de nav du bas */
        right: 15px;
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }

    #chatbot-widget-container {
        bottom: 140px;
        right: 10px; /* Presque plein écran ou centré */
        width: calc(100% - 20px);
        height: 60vh;
    }
}

/* Style du menu déroulant mobile */
    /* État caché */
    .mobile-more-menu.hidden {
        display: none;
        opacity: 0;
        transform: translateY(20px);
    }

    /* Grille d'icônes */
    .menu-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr); /* 4 colonnes */
        gap: 10px;
    }

    .menu-tile {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-decoration: none;
        color: #555;
        font-size: 12px;
        padding: 10px 5px;
        border-radius: 10px;
        background: #f3eeea;
    }

    .menu-tile:active, .menu-tile:hover {
        background: #f0f0f0;
        color: #000;
    }

    .menu-tile .icon {
        font-size: 24px;
        margin-bottom: 5px;
    }

    /* Petit ajustement pour que le bouton Menu change de couleur quand actif */
    #menu-trigger-btn.active-menu {
        color: #27ae60; /* Vert Entourage */
        font-weight: bold;
    }