/* --- BASE --- */
body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background-color: #f0f2f5;
    color: #333;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Permet au footer de rester en bas si peu de contenu */
}

/* --- HEADER --- */
header {
    background-color: #fff;
    border-bottom: 1px solid #ddd;
    margin-bottom: 2rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}

.header-top {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 1rem;
    flex-wrap: wrap;
    gap: 15px;
}

header h1 {
    margin: 0;
    font-size: 1.8rem;
    color: #2d3436;
}

.tagline {
    margin: 0;
    font-size: 0.9rem;
    color: #636e72;
}

/* --- MENU NAVIGATION --- */
.main-nav {
    background-color: #2d3436; /* Fond sombre pour le menu */
    color: white;
}

.main-nav ul {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
    list-style: none;
    display: flex;
    gap: 20px;
    overflow-x: auto; /* Permet le scroll sur mobile si trop petit */
}

.main-nav li {
    margin: 0;
}

.main-nav a {
    display: block;
    color: #dfe6e9;
    text-decoration: none;
    padding: 15px 0;
    font-size: 0.95rem;
    font-weight: 500;
    border-bottom: 3px solid transparent; /* Bordure invisible pour hover */
    transition: all 0.3s ease;
}

.main-nav a:hover, .main-nav a.active {
    color: #fff;
    border-bottom-color: #FFDD00; /* Soulignement jaune au survol */
}

/* --- BOUTON CAFÉ --- */
.bmc-button {
    background-color: #FFDD00;
    color: #000;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 4px 0 #d4b700;
    transition: transform 0.1s, box-shadow 0.1s;
    border: 1px solid #d4b700;
    display: inline-block;
}

.bmc-button:active {
    transform: translateY(4px);
    box-shadow: 0 0 0 #d4b700;
}

/* --- ARTICLES --- */
main {
    max-width: 700px;
    margin: 0 auto;
    padding: 0 1rem;
    flex: 1; /* Pousse le footer vers le bas */
    width: 100%;
    box-sizing: border-box;
}

.post-card {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    padding: 20px;
    margin-bottom: 40px;
    border: 1px solid #eee;
}


/* --- ZONE DE RÉPONSE --- */
.reponse-box {
    padding: 15px;
    border-radius: 8px;
    position: relative;
}

.content-text {
    margin-top: 10px;
    font-size: 1rem;
    margin-bottom: 0;
}
/* --- GESTION DES IMAGES (Portrait & Paysage) --- */
.media-screen {
    /* On crée une boîte avec un fond sombre pour faire ressortir le screenshot */
    background-color: #2d3436;
    border-radius: 8px;
    margin-bottom: 20px;
    overflow: hidden; /* Pour que l'image ne dépasse pas des bords arrondis */

    /* Flexbox pour centrer parfaitement l'image quelle que soit sa taille */
    display: flex;
    justify-content: center;
    align-items: center;
}

.media-screen img {
    /* RÈGLE D'OR : Ne jamais dépasser la largeur du conteneur... */
    max-width: 100%;
    /* ...ET ne jamais dépasser une certaine hauteur (ex: 550px) */
    max-height: 550px;

    /* On laisse le navigateur calculer le reste pour garder les proportions */
    width: auto;
    height: auto;

    display: block;
}

.meta-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
    padding-bottom: 5px;
}

/* STYLE IA */
.reponse-box.ai-generated {
    background-color: #f1f3f5;
    border-left: 4px solid #0984e3;
    font-family: 'Fira Code', monospace;
}

.reponse-box.ai-generated .badge.ai {
    background-color: #0984e3;
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: bold;
}

/* STYLE HUMAIN */
.reponse-box.human-generated {
    background-color: #fff0f0;
    border-left: 4px solid #d63031;
}

.reponse-box.human-generated .badge.error {
    background-color: #d63031;
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: bold;
    font-family: monospace;
}

.reponse-box.human-generated .content-text {
    font-family: 'Courier New', Courier, monospace;
    color: #2d3436;
    font-style: italic;
}

/* --- SOURCE --- */
.source-link {
    margin-top: 15px;
    text-align: right;
    font-size: 0.8rem;
    opacity: 0.6;
}

.source-link a {
    color: inherit;
    text-decoration: none;
}

/* --- FOOTER --- */
footer {
    background-color: #2d3436; /* Fond sombre */
    color: #b2bec3;
    padding-top: 40px;
    margin-top: 60px;
    border-top: 5px solid #FFDD00; /* Petite touche de couleur rappelant le bouton */
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
}

.footer-column h3 {
    color: #fff;
    font-size: 1.1rem;
    margin-top: 0;
}

.footer-column ul {
    list-style: none;
    padding: 0;
}

.footer-column ul li {
    margin-bottom: 8px;
}

.footer-column a {
    color: #b2bec3;
    text-decoration: none;
}

.footer-column a:hover {
    color: #FFDD00;
    text-decoration: underline;
}

.footer-bottom {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    background-color: #22282a; /* Encore plus sombre pour le bas-bas */
    font-size: 0.8rem;
}