/* styles.css */
a {
    color: #cc3a00; /* Bleu par défaut */
    text-decoration: none; /* Supprime le soulignement */
    transition: color 0.3s ease; /* Transition douce pour le changement de couleur */
}

a:hover {
    color: #ff6600; /* Orange au survol */
    text-decoration: underline; /* Soulignement au survol */
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: Arial, sans-serif;
    color: #333;
    background-image: url('img/bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: repeat;
}

h1 {
    color: #4CAF50; /* Couleur verte, cette règle peut être écrasée */
    text-align: center;
}

h1 {
    color: #4CAF50; /* Couleur verte, cette règle peut être écrasée */
    text-align: center;
}

/* Nouveau style pour le conteneur de cadeaux */
.cadeaux-container {
    max-width: 600px; /* Limite la largeur du conteneur */
    margin: 50px auto; /* Centre le conteneur */
    margin-left: 20px;
    background-color: white; /* Fond blanc */
    border-radius: 15px; /* Coins arrondis */
    padding: 20px; /* Espacement intérieur */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1); /* Ombre légère */
    text-align: center; /* Centre le texte */
}

.cadeaux-container h1 {
    color: #BF0A30 !important; /* Couleur rouge noël */
    margin: 0; /* Supprime la marge par défaut */
}

.container {
    max-width: 70%;
    margin: 50px auto;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.edit-btn {
    background-color: #f4a226; /* orange doux */
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: 0.2s;
}

.edit-btn:hover {
    background-color: #d98a1f; /* plus foncé au survol */
}


form {
    margin-bottom: 20px;
    background-color: white;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

label {
    font-weight: bold;
}

input[type="text"],
input[type="password"] {
    padding: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: calc(100% - 22px);
}

button {
    padding: 10px;
    margin-top: 10px;
    border: none;
    border-radius: 4px;
    background-color: #4CAF50;
    color: white;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
}

button:hover {
    background-color: #45a049;
}

.error {
    color: red;
    text-align: center;
    margin-bottom: 20px;
}

ul {
    list-style-type: none;
    padding: 0;
}

li {
    background-color: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 15px;
    margin: 5px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}
#giftList {
    list-style-type: none;
    padding: 0;
    margin: 0;
    margin-left: 20px;
}

.gift-item {
    display: flex; /* Utilisation du flexbox pour aligner les éléments horizontalement */
    justify-content: space-between; /* Espace entre les éléments */
    align-items: center; /* Aligne verticalement les éléments */
    background-color: white; /* Fond blanc */
    padding: 10px 25px; /* Ajoute un padding sur tous les côtés, en particulier à droite */
    border-radius: 5px; /* Coins arrondis */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Ombre légère */
    margin: 5px 0; /* Espacement entre les éléments */
    width: fit-content; /* La largeur s'ajuste au contenu */
}

.gift-item .gift-action {
    margin-left: 10px; /* Espace entre les détails du cadeau et le bouton */
}

.gift-item::after {
    content: ""; /* Ajoute un espace vide */
    display: block; /* Forcer un retour à la ligne après chaque élément */
    width: 100%; /* Utilisé pour remplir la ligne */
}


.gift-details {
    display: inline-block;
    max-width: 100%;
    margin-right: 15px;
    word-wrap: break-word; /* Pour éviter que le texte dépasse */
}


/* Espacement entre le lien et les autres éléments */
.gift-details span,
.gift-details a {
    margin-right: 10px;
}

li button {
    margin-left: 10px;
    padding: 5px 10px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

li button:hover {
    background-color: #45a049;
}

.top-header {
    text-align: center;
}

.footer-box {
    padding: 20px 0;
}

#scroll-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: none;
    z-index: 1000;
}

.navbar {
    background-color: #333;
    overflow: hidden;
}

.navbar a {
    display: block;
    color: white;
    text-align: center;
    padding: 14px 20px;
    text-decoration: none;
}

.navbar a:hover {
    background-color: #ddd;
    color: black;
}

.navbar a.active {
    background-color: #04AA6D;
    color: white;
}

.navbar-right {
    display: flex;
    align-items: center;
}

.notification-badge {
    background-color: red;
    color: white;
    border-radius: 50%;
    padding: 3px 8px;
    font-size: 12px;
    vertical-align: super;
}
/* Style spécifique pour le bouton "Retour" */
button[type="button"] {
    background-color: #808080; /* Gris */
    color: white; /* Texte blanc */
    width: 100%; /* Prend toute la largeur disponible */
    padding: 10px; /* Même padding que le bouton "Se connecter" */
    margin-top: 10px; /* Même espacement qu'avec le bouton "Se connecter" */
    border: none; /* Supprime la bordure */
    border-radius: 4px; /* Coins arrondis */
    cursor: pointer; /* Curseur de type pointeur */
    transition: background-color 0.3s; /* Transition de couleur lors du survol */
}

/* Effet au survol du bouton "Retour" */
button[type="button"]:hover {
    background-color: #666666; /* Gris plus foncé au survol */
}

.implemented-date {
    display: block;
    font-size: 0.9em;
    color: #4CAF50;
    margin-top: 10px;
}

.password-wrapper {
    position: relative;
    width: 100%;
}

.password-wrapper input {
    width: 100%;
    padding-right: 30px; /* Espace pour l'icône d'œil */
}

.password-wrapper i {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none; /* L'icône ne doit pas interférer avec l'input */
}

body.dark-mode {
    color: #e0e0e0;
    background-color: #121212; /* Couleur de fond sombre */
    background-image: none; /* Désactive l'image de fond */
}

body.dark-mode h1 {
    color: #4d8a1b; /* Vert clair */
}

body.dark-mode .cadeaux-container,
body.dark-mode .container,
body.dark-mode form,
body.dark-mode li {
    background-color: #1e1e1e; /* Fond sombre */
    color: #e0e0e0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

body.dark-mode .navbar {
    background-color: #1f1f1f;
}

body.dark-mode .navbar a {
    color: #e0e0e0;
}

body.dark-mode .navbar a:hover {
    background-color: #333;
    color: #fff;
}

body.dark-mode button {
    background-color: #4a7f1f;
    color: #121212;
}

form textarea { 
    padding: 10px;
    font-size: 1em; 
    border: 1px solid #ddd; 
    border-radius: 5px; 
    margin-bottom: 10px; 
    margin-top: 10px; 
    resize: vertical; 
    width: 100%;
    }

body.dark-mode button:hover {
    background-color: #32640a;
}

body.dark-mode .error {
    color: #FF5252;
}

body.dark-mode .notification-badge {
    background-color: #FF5722;
}

#theme-toggle {
    font-size: 24px;
    cursor: pointer;
    transition: transform 0.3s ease, color 0.3s ease;
    color:floralwhite;
}

#theme-toggle:hover {
    transform: scale(1.2);
    color: #f1c40f; /* Change la couleur de l'icône au survol */
}

/* Règle spécifique pour forcer le style du bouton Modifier */
.gift-item .gift-action .edit-btn,
li .gift-action .edit-btn {
    background-color: #f4a226; /* orange doux */
    color: #ffffff;
    border: none;
    padding: 6px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 700;
    transition: background-color 0.15s ease;
    width: 100%;     
    display: inline-block;
}

/* Hover */
.gift-item .gift-action .edit-btn:hover,
li .gift-action .edit-btn:hover {
    background-color: #d98a1f;
}
