/* ================== CSS GENERER AVEC CHAT GPT ================== */
/* =============================================================== */


/* ================== PAGE LOGIN (index.html) ================== */


/* Thème sombre élégant */
body {
    font-family: 'Arial', sans-serif;
    text-align: center;
    background-color: #121212;
    color: #ffffff;
    margin: 0;
    padding: 0;
}

h1 {
    margin-top: 20px;
    font-size: 2.5em;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Conteneur des formulaires */
.container {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-top: 50px;
    flex-wrap: wrap;
}

/* Boîte pour Login & Register */
.box {
    background: #1e1e1e;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0px 4px 15px rgba(255, 255, 255, 0.05);
    width: 280px;
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
    margin-bottom: 20px;
}

.box:hover {
    transform: translateY(-5px);
    box-shadow: 0px 6px 20px rgba(255, 255, 255, 0.1);
}

h2 {
    margin-bottom: 15px;
    font-size: 1.5em;
    border-bottom: 2px solid #3a3a3a;
    display: inline-block;
    padding-bottom: 5px;
}

/* Style des formulaires */
form {
    display: flex;
    flex-direction: column;
}

/* Labels */
label {
    text-align: left;
    font-size: 14px;
    margin-top: 10px;
    font-weight: bold;
}

/* Champs de saisie */
input {
    padding: 12px;
    margin-top: 5px;
    border: none;
    border-radius: 5px;
    background-color: #2a2a2a;
    color: white;
    outline: none;
    transition: background 0.3s, box-shadow 0.3s;
}

input::placeholder {
    color: #888;
}

input:focus {
    background-color: #333;
    box-shadow: 0px 0px 10px rgba(255, 255, 255, 0.2);
}

/* Boutons */
button {
    margin-top: 20px;
    padding: 12px;
    font-size: 1em;
    font-weight: bold;
    text-transform: uppercase;
    background: linear-gradient(135deg, #333, #444);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.2s, background 0.3s, box-shadow 0.3s;
}

button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #444, #555);
    box-shadow: 0px 0px 15px rgba(255, 255, 255, 0.15);
}

button:active {
    transform: scale(0.98);
}

/* Styles spécifiques */
button.buy {
    background: #007bff;
}

button.buy:hover {
    background: #0056b3;
}

button.price {
    background: #28a745;
}

button.price:hover {
    background: #218838;
}

/* Déconnexion */
#logoutButton {
    display: inline-block;
    /* Le bouton prendra uniquement la largeur nécessaire */
    margin-top: 20px;
    /* Espacement sous le titre */
    padding: 10px 20px;
    /* Ajuster les espacements internes */
    font-size: 1em;
    /* Taille du texte du bouton */
    background: #ad2626;
    border-radius: 5px;
    text-align: center;
    cursor: pointer;
    transition: background 0.3s;
}

#disconnect:hover {
    background: #d32f2f;
    /* Changement de couleur au survol */
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
        align-items: center;
    }

    /* Déconnexion */
    #disconnect {
        margin-top: 20px;
        /* Espacement au-dessus du bouton */
        width: 100%;
        /* Le bouton occupe toute la largeur */
        text-align: center;
        /* Centrer le texte */
    }
}

/* ================== PAGE CLIENT (ClientView.html) ================== */

/* Informations du manga */
.manga-details {
    width: 350px;
    /* Largeur de la case */
    background: #1e1e1e;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 15px rgba(255, 255, 255, 0.05);
    text-align: left;
    margin-bottom: 20px;
    /* Ajout d'un espace en bas */
}

/* Titre du manga */
.manga-details h2 {
    font-size: 1.8em;
    margin-bottom: 10px;
}

/* Description du manga */
.manga-details p {
    font-size: 1.2em;
    margin-bottom: 15px;
    /* Espacement entre les éléments */
}

/* Conteneur du bouton et du prix */
.manga-details .manga-action {
    display: flex;
    /* Utilisation de flexbox pour aligner les éléments */
    justify-content: space-between;
    /* Espace entre le bouton et le prix */
    align-items: center;
    /* Centrer verticalement */
    margin-bottom: 20px;
    /* Espace avant le bas */
}

/* Style du prix */
.manga-details .manga-price {
    font-size: 1.4em;
    font-weight: bold;
    color: #28a745;
    /* Vert pour le prix */
}

/* Bouton Acheter */
button.buy {
    width: 48%;
    /* Le bouton prend 48% de la largeur pour laisser de l'espace au prix */
    padding: 12px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    margin-right: 25px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background 0.3s;
}

/* Changement de couleur au survol */
button.buy:hover {
    background: #0056b3;
}

/* ================== PAGE ADMIN (AdminView.html) ================== */

/* Liste des mangas disponibles */
.manga-list-box,
.sold-list-box {
    background: #1e1e1e;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0px 4px 15px rgba(255, 255, 255, 0.05);
    width: 280px;
    margin-bottom: 20px;
}

/* Liste des mangas vendus */
.sold-list-box {
    margin-top: 20px;
    position: relative;
}

/* Titre "SOLD" */
.sold-list-box h2 {
    font-size: 1.5em;
    color: #fff;
    margin-bottom: 10px;
    border-bottom: 2px solid #3a3a3a;
    padding-bottom: 5px;
}

/* Liste des mangas vendus */
#sold-list {
    height: 200px;
    overflow-y: auto;
}

/* Wallet */
.wallet {
    background: #1e1e1e;
    padding: 15px;
    border-radius: 10px;
    margin-top: 20px;
    width: 150px;
    text-align: center;
}

.wallet h3 {
    font-size: 1.2em;
    color: #fff;
    background-color: grey;
    margin-bottom: 10px;
    border-radius: 10px;
    /* Coins arrondis pour un look plus doux */

}

/* Affichage du montant du Wallet */
#wallet-balance {
    font-size: 1.5em;
    font-weight: bold;
    color: #fff;
    padding: 15px 20px;
    border-radius: 10px;
    text-align: center;
    width: auto;
    max-width: 250px;
    margin: 10px auto;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

/* Controles Admin */
.admin-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 20px;
}

button.red {
    background: #b22222;
    max-height: 100px;
}

button.red:hover {
    background: #d32f2f;
}

/* Liste déroulante - Manga sélectionné */
select {
    background-color: #333;
    /* Fond sombre pour la liste */
    color: #fff;
    /* Texte blanc */
    border: 2px solid #555;
    /* Bordure gris clair */
    border-radius: 5px;
    /* Bords arrondis */
    padding: 12px 20px;
    /* Espacement intérieur élargi */
    font-size: 16px;
    /* Taille du texte */
    width: 300px;
    /* Largeur de la liste augmentée */
    margin-top: 20px;
    /* Espacement en haut */
    transition: background-color 0.3s, border-color 0.3s;
    /* Transition douce */
}

/* Changement au survol de la liste déroulante */
select:hover {
    border-color: #979695;
    /* Bordure orange au survol */
}

/* Focus sur la liste déroulante */
select:focus {
    outline: none;
    /* Supprimer le contour par défaut */
    background-color: #444;
    /* Fond plus clair */
    border-color: #929190;
    /* Bordure orange */
}

/* Option sélectionnée */
option {
    background-color: #333;
    color: #fff;
    padding: 10px;
    transition: background 0.3s ease;
}

option:hover {
    background-color: #555;
    /* Fond plus clair au survol */
}