/* 🌞 Mode Clair (semi-clair) */
.light-mode {
    background: #F3F4F6; /* Gris clair au lieu du blanc */
    color: #1F2937; /* Texte foncé */
}

/* ✅ Bouton Mode Sombre */
#darkModeToggle {
    background: linear-gradient(135deg, #6366F1, #4338CA);
    color: white;
    padding: 10px 15px;
    border-radius: 10px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 150px;
    transition: all 0.3s ease-in-out;
}

.light-mode #darkModeToggle {
    background: linear-gradient(135deg, #FACC15, #EAB308);
    color: #1F2937;
}

.light-mode #logoutButton {
    background: linear-gradient(135deg, #DC2626, #991B1B);
}

.light-mode .auth-box {
    background: rgba(0, 0, 0, 0.05);
}

.light-mode input {
    background: rgba(0, 0, 0, 0.1);
    color: #1F2937;
}

.light-mode .blue-btn {
    background: linear-gradient(135deg, #60A5FA, #2563EB);
}

.light-mode .red-btn {
    background: linear-gradient(135deg, #F87171, #B91C1C);
}


.light-mode .box {
    background: rgba(0, 0, 0, 0.05);
}

.light-mode .history-container {
    color: #1F2937;
}

.light-mode .history-card {
    background: rgba(0, 0, 0, 0.05);
}


/* Général */
body {
    font-family: 'Poppins', sans-serif;
    background: #111827;
    color: #ffffff;
    text-align: center;
    margin: 0;
    padding: 20px;
}


/* Conteneur du header */
.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 15px;
    width: 100%;
}

/* Centrer le logo */
#logo {
    margin: 0 auto;
    display: block;
    width: 60px;
}

/* Bouton de déconnexion aligné à droite */
#logoutButton {
    background: linear-gradient(135deg, #EF4444, #B91C1C);
    color: white;
    padding: 10px 15px;
    border-radius: 8px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 20px;
}



/* Centrer toute la section d’authentification */
.auth-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 80vh; /* Prend toute la hauteur */
}

.title {
    margin-top: 100px;
}

/* La box qui englobe le formulaire */
.auth-box {
    background: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.2);
}

/* Espacement et style des inputs */
input {
    width: 95%;
    padding: 12px;
    margin: 30px 0;
    border-radius: 8px;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 16px;
}

/* Boutons de connexion */
.blue-btn {
    background: linear-gradient(135deg, #3B82F6, #1E40AF);
    color: white;
    font-size: 16px;
    padding: 12px;
    width: 100%;
}

.red-btn {
    background: linear-gradient(135deg, #EF4444, #B91C1C);
    color: white;
    font-size: 16px;
    padding: 12px;
    width: 100%;
}

/* Espacement entre boutons */
button {
    margin: 10px 0;
    padding: 12px 15px;
    border-radius: 8px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease-in-out;
}

/* Boutons bleus */
.blue-btn {
    background: linear-gradient(135deg, #3B82F6, #1E40AF);
    color: white;
}

.blue-btn:hover {
    background: linear-gradient(135deg, #1E40AF, #1E3A8A);
}

.switch-btn {
    margin-left: 10px;
    padding: 10
    px
}

/* Input & Bouton Analyser (Glassmorphism) */
.search-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px 0;
}

.search-container input {
    width: 50%;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: rgb(25, 19, 188);
}

.search-container button {
    padding: 12px 80px;
    font-size: 18px;
    margin-left: 10px;
    border-radius: 8px;
    color: rgb(39, 19, 191);
}

.search-container button:hover {
    background: rgba(163, 133, 206, 0.3);
    color: #f5f7fd;
}

/* Centrer et espacer les résultats */
.results-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
}

/* Style des boxes */
.box {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 12px;
    width: 80%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.1);
}

.summary-box {
    width: 80%;
    max-width: 1070px;
}

.issues-box {
    width: 80%;
    max-width: 1070px;
}

.objectivity-container {
    display: flex;
    font-weight: bold;
    justify-content: center;
    gap: 20px;
    width: 100%;
}

/* Alignement côte à côte des sources */
.sources-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    width: 100%;
}

.sources-box a {
    color: white; /* Change la couleur du texte */
    text-decoration: none; /* Supprime le soulignement */
    font-weight: bold; /* Rend le texte un peu plus visible */
}

.light-mode .sources-box a {
    color: rgb(30, 30, 30); /* Change la couleur du texte */
    text-decoration: none; /* Supprime le soulignement */
    font-weight: bold; /* Rend le texte un peu plus visible */
}

/* Effet au survol */
.sources-box a:hover {
    color: #facc15; /* Change la couleur au survol (exemple : jaune) */
    text-decoration: underline; /* Ajoute un soulignement au survol */
}

.articleUrl {
    display: inline-block;  /* Assure que le texte reste bien dans la ligne */
    max-width: 250px;       /* Ajuste la largeur maximale du lien */
    overflow: hidden;       /* Cache le texte dépassant la largeur */
    white-space: nowrap;    /* Empêche le texte de passer à la ligne */
    text-overflow: ellipsis; /* Ajoute "..." si le texte est trop long */
    color: #007bff;        /* Couleur du lien */
    text-decoration: none;  /* Supprime le soulignement */
}

.articleUrl:hover {
    text-decoration: underline; /* Ajoute un soulignement au survol */
}


.circle-box {
    display: flex;
    justify-content: center;
    font-size: 22px;
    font-weight: bold;
}

/* 🏛️ Cercle de crédibilité avec transition fluide */
.circle {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 6px solid gray; /* Couleur par défaut */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    transition: border-color 0.5s ease-in-out;
}


/* 🏛️ Styles pour l'objectivité avec couleur de fond et texte contrasté */
.objectivity-gauche {
    background-color: #3b82f6 !important; /* Bleu */
    color: white !important; /* Texte en blanc pour le contraste */
    padding: 10px;
    border-radius: 8px;
}

.objectivity-droite {
    background-color: #ef4444 !important; /* Rouge */
    color: white !important;
    padding: 10px;
    border-radius: 8px;
}

.objectivity-extreme {
    background-color: #9333ea !important; /* Violet */
    color: white !important;
    padding: 10px;
    border-radius: 8px;
}

.objectivity-neutre {
    background-color: #facc15 !important; /* Jaune */
    color: black !important;
    padding: 10px;
    border-radius: 8px;
}


.historyButton {
    margin-top: 35px;
    padding: 15px 50px;
    background: rgba(255, 255, 255, 0.2);
    color: white;

}

/* Conteneur de l'historique */
.history-container {
    word-wrap: break-word;
    color: #ffffff;
    display: flex;
    flex-wrap: wrap; /* Permet le retour à la ligne */
    justify-content: center; /* Centre les cartes */
    gap: 20px; /* Espacement entre les cartes */
}

/* Style des cartes d'historique */
.history-card {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 12px;
    width: 40%;
    max-width: 500px;
    text-align: center;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease-in-out;
    cursor: pointer;
}

.history-card:hover {
    transform: scale(1.05);
}

/* Liens des articles */
.article-link {
    color: #3B82F6;
    text-decoration: none;
    font-weight: bold;
}

.article-link:hover {
    text-decoration: underline;
}

/* Ajustement pour 2 cartes par ligne sur écran plus petit */
@media (max-width: 800px) {
    .history-card {
        width: calc(70% - 20px); /* 2 cartes par ligne */
    }
}

/* Une seule carte par ligne sur mobile */
@media (max-width: 500px) {
    .history-card {
        width: 100%; /* 1 carte par ligne */
    }
}

.hidden {
    display: none !important;
}
