/* --- RESET DE BASE --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: #2b2b2b; /* Gris foncé du fond */
    color: white;
    font-family: 'Georgia', serif; /* Police type cinéma */
}

/* --- HEADER (Haut de page) --- */
header {
    background-color: #000000; /* Fond noir */
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 40px;
}

.logo-container {
    text-align: center;
}

.logo-container img {
    height: 50px; /* À ajuster selon ton image */
}

.profile-container img {
    height: 50px;
    width: 50px;
    border-radius: 50%; /* Rend l'image de profil ronde */
    background-color: #555; /* Fond par défaut si image transparente */
}

/* --- NAVIGATION --- */
nav {
    background-color: #000000;
    border-top: 1px solid #ffffff;
    border-bottom: 1px solid #ffffff;
    text-align: center;
    padding: 8px 0;
}

nav a {
    color: white;
    text-decoration: none;
    font-size: 18px;
    padding: 0 20px;
}

nav a:not(:last-child) {
    border-right: 1px solid #ffffff; /* La petite barre de séparation */
}

nav a:hover {
    color: #cccccc;
}

/* --- TITRE DE LA PAGE --- */
.page-title {
    background-color: #555555; /* Gris plus clair */
    display: inline-block;
    padding: 10px 30px;
    font-size: 24px;
    margin-top: 20px;
}

/* --- PAGE ACCUEIL --- */
.accueil-content {
    text-align: center;
    margin-top: 60px;
}

.circle-logo {
    background-color: #000000;
    border-radius: 50%;
    width: 180px;
    height: 180px;
    margin: 0 auto 20px auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.circle-logo img {
    height: 60px;
}

.accueil-content h2 {
    font-size: 32px;
    margin-bottom: 10px;
}

.accueil-content p {
    font-size: 18px;
    color: #dddddd;
    margin-bottom: 40px;
}

/* --- GALERIE (Films / Séries) --- */
.galerie {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    padding: 40px;
}

.carte {
    background-color: #555555;
    width: 160px;
    height: 240px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    text-decoration: none;
    transition: transform 0.2s;
}

.carte:hover {
    transform: scale(1.05); /* Petit effet de zoom au survol */
}

/* La carte spéciale pour le Rêveur */
.carte-ajout {
    background-color: #000000;
    flex-direction: column;
    border: 2px dashed #555;
}

.carte-ajout .plus {
    font-size: 50px;
    font-weight: normal;
    margin-bottom: 10px;
}

.carte-ajout p {
    font-size: 12px;
    color: #aaaaaa;
}

.cinerevelogo {
    height: auto;
}

/* --- PAGE EDITEUR (add.php) --- */
.editor-container {
    padding: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

/* Titre */
.input-titre {
    background-color: #555555;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 24px;
    padding: 10px 20px;
    font-weight: bold;
    margin-bottom: 30px;
    width: auto;
    font-family: inherit;
}
.input-titre::placeholder { color: #cccccc; }

/* Grille Affiche + Description */
.editor-grid {
    display: flex;
    gap: 30px;
    margin-bottom: 30px;
}

/* Faux boutons d'upload (pour cacher le <input type="file"> moche) */
.upload-box {
    background-color: #555555;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    cursor: pointer;
    text-align: center;
    transition: background-color 0.2s;
}
.upload-box:hover { background-color: #666666; }
.upload-box input[type="file"] { display: none; /* Cache le vrai bouton d'upload */ }

.box-affiche {
    width: 250px;
    height: 350px;
    flex-shrink: 0;
}

/* Zone Description */
.box-description {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.box-description h3 {
    margin-bottom: 10px;
    font-size: 28px;
}
.box-description textarea {
    background-color: #555555;
    border: none;
    border-radius: 12px;
    color: white;
    padding: 20px;
    font-size: 16px;
    flex-grow: 1;
    resize: none;
    font-family: inherit;
}

/* Zone YouTube */
.box-youtube {
    background-color: #555555;
    border-radius: 12px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 30px;
}
.box-youtube input {
    background: transparent;
    border: none;
    color: white;
    font-size: 20px;
    text-align: center;
    width: 80%;
    outline: none;
}
.box-youtube input::placeholder { color: #ffffff; }

/* Zone Images Tournage */
.tournage-title {
    background-color: #555555;
    display: inline-block;
    padding: 10px 20px;
    border-radius: 20px;
    margin-bottom: 15px;
}
.box-tournage {
    width: 150px;
    height: 150px;
}
.box-tournage .plus { font-size: 40px; margin-bottom: 5px; }
.box-tournage p { font-size: 12px; color: #ccc; }

/* Bouton Poster */
.btn-poster {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 18px;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 40px;
    display: block;
    width: 100%;
    font-weight: bold;
}
.btn-poster:hover { background-color: #218838; }

.presentation {
    max-width: 800px;
    margin: 50px auto;
    padding: 30px;
    text-align: center;
    font-family: Arial, sans-serif;
    line-height: 1.8;
}

.circle-logo {
    margin-bottom: 20px;
}

.circle-logo img {
    width: 180px;
    height: 180px;
    object-fit: cover;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.presentation h2 {
    font-size: 2.5rem;
    margin-bottom: 25px;
    color: #222;
}

.presentation p {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 20px;
    text-align: justify;
}

/* --- BOUTONS D'ADMINISTRATION SUR LES CARTES --- */
.carte-container {
    position: relative;
    width: 160px; /* Aligné sur la taille de tes cartes */
    height: 245px;
}

/* Les boutons d'action (cachés par défaut) */
.admin-actions {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75); /* Fond sombre transparent */
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 15px;
    opacity: 0; /* Caché */
    transition: opacity 0.2s ease-in-out;
    z-index: 2;
}

/* Fait apparaître les boutons quand on passe la souris sur la carte */
.carte-container:hover .admin-actions {
    opacity: 1;
}

/* Style des boutons Modifier / Supprimer */
.btn-admin {
    display: inline-block;
    padding: 8px 15px;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: bold;
    width: 80%;
    text-align: center;
    transition: transform 0.1s;
}
.btn-admin:hover {
    transform: scale(1.05);
}

.btn-edit { background-color: #007bff; } /* Bleu */
.btn-edit:hover { background-color: #0056b3; }

.btn-delete { background-color: #dc3545; } /* Rouge */
.btn-delete:hover { background-color: #bd2130; }