/* style.css */

/* Header principal */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: #121025; /* fond du header */
    color: #e4e4e7; /* texte clair */
    font-family: Arial, sans-serif;
}

/* Conteneur titre + menu */
header > div:first-child {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Titre du site */
header h1 {
    color: #e040fb; /* couleur du titre */
    margin: 0;
}

/* Menu de navigation */
header nav {
    display: flex;
    gap: 15px;
}

header nav a {
    color: #e4e4e7; /* couleur des liens */
    text-decoration: none;
}

header nav a:hover {
    text-decoration: underline;
}

/* Section utilisateur */
header > div:last-child {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Photo profil */
header img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

/* Initiale si pas de photo */
header div.initiale {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e040fb; /* même couleur que le titre */
    color: #121025; /* fond sombre */
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 18px;
}

/* Message bonjour */
header span {
    font-weight: bold;
}

/* Bouton déconnexion */
header a.deconnexion {
    background-color: #e040fb;
    color: #121025;
    padding: 6px 12px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: bold;
}

header a.deconnexion:hover {
    background-color: #c628d6;
}

/* Message connectez-vous si non connecté */
header > span {
    font-weight: bold;
}
/* Bouton déconnexion */
a.deconnexion {
    background-color: #e040fb; /* fond violet */
    color: #121025;            /* texte sombre */
    padding: 6px 12px;         /* espacement */
    border-radius: 6px;        /* coins arrondis */
    text-decoration: none;     /* pas de soulignement */
    font-weight: bold;         /* texte gras */
    transition: background-color 0.2s ease;
}

a.deconnexion:hover {
    background-color: #c628d6; /* couleur au hover */
}

/* Texte "Connectez-vous" */
span.connexion {
    font-weight: bold;
    color: #e4e4e7; /* couleur claire pour le contraste */
}

/* Corps de page */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: Arial, sans-serif;
    margin: 0;
    background: #121025; /* fond sombre */
    color: #e4e4e7;      /* texte clair */
}

/* Header */
header {
    background: linear-gradient(90deg, #4e2a8e, #2e1a4c);
    color: #e4e4e7;
    padding: 10px 20px;
}

.header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.header-top h1 {
    margin: 0;
    font-size: 26px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5);
}

nav a {
    margin: 0 10px;
    color: #e4e4e7;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

nav a:hover {
    color: #e040fb; /* magenta clair */
    text-decoration: underline;
}

/* Main */
main {
    flex: 1;
    max-width: 1000px;
    margin: 20px auto;
    padding: 0 10px;
}

/* Titre de page */
.page-title {
    font-size: 28px;
    text-align: center;
    color: #e040fb;
    margin-bottom: 20px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

/* Conteneur des détails */
.detail-container {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
    background: #2e1a4c;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

/* Photo de profil */
.photo-profil {
    flex: 1 1 200px;
    text-align: center;
}

.photo-profil img {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #e040fb;
}

/* Infos profil */
.infos-profil {
    flex: 2 1 300px;
}

.infos-profil p {
    margin: 6px 0;
    color: #c2c2d6;
}

.infos-profil strong {
    color: #ffffff;
}

/* Description et galerie */
.description,
.galerie-container {
    background: #2e1a4c;
    padding: 15px;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
    margin-bottom: 20px;
}

/* Galerie */
.galerie-container {
    text-align: center;
    position: relative;
}

.galerie-container img {
    width: 80%;
    max-height: 300px;
    object-fit: cover;
    border-radius: 6px;
    border: 2px solid #e040fb;
}

/* Flèches galerie */
.galerie-container .prev,
.galerie-container .next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 30px;
    color: #e040fb;
    background: rgba(0,0,0,0.5);
    border: none;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 5px;
}

.prev { left: 10px; }
.next { right: 10px; }

/* Bouton retour */
.back-button {
    display: block;
    width: 200px;
    margin: 0 auto 20px;
    text-align: center;
    background: #e040fb;
    color: #121025;
    text-decoration: none;
    padding: 10px;
    border-radius: 5px;
    font-weight: bold;
    transition: 0.3s;
}

.back-button:hover {
    background: #d500f9;
}

/* Footer */
footer {
    background: linear-gradient(90deg, #4e2a8e, #2e1a4c);
    color: #e4e4e7;
    padding: 15px 20px;
    text-align: center;
}

.footer-nav a {
    color: #e4e4e7;
    text-decoration: none;
    margin: 0 5px;
    font-weight: bold;
}

.footer-nav a:hover {
    color: #e040fb;
    text-decoration: underline;
}

/* Responsive */
@media(max-width:700px) {
    .detail-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

/* Styles pour la page "Modifier mes informations" */
#formulaire-profil {
    max-width: 900px; /* largeur maximale plus réaliste */
    width: 90%;       /* prend 90% de l’écran */
    margin: 20px auto;
    background: #2e1a4c;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.6);
}


#formulaire-profil h2 {
    text-align: center;
    font-size: 28px;
    color: #e040fb;
    margin-bottom: 25px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

#formulaire-profil .champ {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;
}

#formulaire-profil label {
    font-weight: bold;
    margin-bottom: 5px;
}


#formulaire-profil input,
#formulaire-profil textarea {
    width: 100%;  /* prend toute la largeur du conteneur */
    padding: 10px;
    border-radius: 8px;
    border: none;
    background: #1b112e;
    color: #e4e4e7;
    font-size: 14px;
}

#formulaire-profil textarea {
    resize: vertical;
    min-height: 80px;
}

#formulaire-profil input[type="file"] {
    background: none;
    padding: 0;
}

#formulaire-profil .boutons {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 20px;
}

#formulaire-profil button,
#formulaire-profil .bouton-annuler {
    flex: 1;
    padding: 12px;
    border-radius: 8px;
    font-weight: bold;
    border: none;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: 0.3s;
}

#formulaire-profil button {
    background: #e040fb;
    color: #121025;
}

#formulaire-profil button:hover {
    background: #d500f9;
}

#formulaire-profil .bouton-annuler {
    background: #444;
    color: #e4e4e7;
}

#formulaire-profil .bouton-annuler:hover {
    background: #666;
}
/* ================================
   CSS spécifique à la page d’accueil
================================ */

/* Tout le CSS spécifique à la page d’accueil */
.page-accueil {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
  background-color: var(--bg);
  color: #e6eef8;

  /* Prendre tout l’écran */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Conteneur principal prend tout l'espace disponible */
.page-accueil .container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 0;
  display: flex;
  flex-direction: column;
  flex: 1; /* remplit l'espace vertical */
  gap: 30px;
}

/* Bannière */
.page-accueil .header-image img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  border-radius: 12px;
}

/* Hero / Statistiques */
.page-accueil .hero {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: space-between;
}

/* aside card (stats et actions) */
.page-accueil .hero .aside-card {
  flex: 1 1 350px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  padding: 20px;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(2,6,23,0.6);
}

/* Stats */
.page-accueil .hero .stats {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 15px;
}

.page-accueil .hero .stat {
  flex: 1;
  text-align: center;
}

.page-accueil .hero .stat strong {
  display: block;
  font-size: 20px;
  color: #fff;
}

.page-accueil .hero .stat span {
  font-size: 13px;
  color: var(--muted);
}

/* Actions (boutons) */
.page-accueil .hero .actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.page-accueil .hero .actions .btn {
  flex: 0 0 auto; /* fixe leur taille */
  min-width: 140px;
  text-align: center;
  padding: 12px 16px;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.3s;
}

/* Boutons principaux visibles */
.page-accueil .hero .actions .btn.primary {
  background-color: #e040fb; /* violet vif */
  color: #fff;               /* texte blanc */
  border: none;              /* pas de bordure */
  outline: none;             /* pas de contour par défaut */
  padding: 12px 20px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s;
}



/* Supprime contour bleu/violet au focus et optionnel halo */
.page-accueil .hero .actions .btn.primary:focus {
  outline: none;
  box-shadow: 0 0 0 2px #e040fb; /* facultatif, halo violet */
}

/* Sections */
.page-accueil .section-card {
  background: var(--card);
  padding: 20px;
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.4);
}

.page-accueil .section-card h2 {
  margin-top: 0;
  color: var(--accent);
}

/* Features */
.page-accueil .features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 12px;
}

.page-accueil .feature {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.page-accueil .feature-icon {
  font-size: 24px;
  color: var(--accent);
  flex-shrink: 0;
}

/* Témoignages / avatars */
.page-accueil .feature .avatar {
  flex-shrink: 0;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
}

/* Footer en bas */
.page-accueil footer {
  margin-top: auto; /* pousse le footer en bas si contenu court */
}

/* Responsive */
@media (max-width:900px) {
  .page-accueil .hero {
    flex-direction: column;
    align-items: center;
  }
  .page-accueil .features {
    grid-template-columns: 1fr;
  }
}
/* === Boutons du formulaire d'inscription === */
#formulaire-profil .btn-container {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 20px;
}

/* Bouton S’inscrire */
#formulaire-profil .btn-submit {
  flex: 1;
  background-color: #e040fb;
  color: #121025;
  border: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  text-align: center;
  transition: 0.3s ease;
}

#formulaire-profil .btn-submit:hover {
  background-color: #d500f9;
}

/* Bouton Annuler */
#formulaire-profil .btn-cancel {
  flex: 1;
  text-align: center;
  background-color: #444; /* gris sombre */
  color: #e4e4e7;
  text-decoration: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: bold;
  transition: 0.3s ease;
  display: inline-block;
}

#formulaire-profil .btn-cancel:hover {
  background-color: #666;
}

/* ================================
   Styles spécifiques à la page de connexion
================================ */

.page-connexion {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 90vh;
  background: #121025;
  font-family: "Poppins", sans-serif;
  color: #e4e4e7;
}

.page-connexion form {
  background: #2e1a4c;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  padding: 40px 30px;
  width: 90%;
  max-width: 420px;
}

.page-connexion h2 {
  text-align: center;
  font-size: 26px;
  color: #e040fb;
  margin-bottom: 30px;
}

.page-connexion label {
  font-weight: 600;
  color: #c7b7ff;
  display: block;
  margin-bottom: 6px;
}

.page-connexion input[type="email"],
.page-connexion input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #2e1a4c;
  background: rgba(255,255,255,0.08);
  color: #fff;
  font-size: 15px;
  margin-bottom: 15px;
  transition: all 0.3s ease;
}

.page-connexion input:focus {
  outline: none;
  border-color: #9b4dff;
  box-shadow: 0 0 10px #9b4dff60;
  background: rgba(255,255,255,0.1);
}

.page-connexion span {
  display: block;
  color: #ff6b6b;
  font-size: 13px;
  margin-bottom: 10px;
}

.page-connexion button {
  width: 100%;
  background: linear-gradient(135deg, #9b4dff, #d47bff);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 12px;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 5px;
  box-shadow: 0 4px 10px rgba(155, 77, 255, 0.4);
}

.page-connexion button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(155, 77, 255, 0.6);
}

.page-connexion .lien-annuler,
.page-connexion .btn-creer-compte {
  display: block;
  text-align: center;
  padding: 12px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  margin-top: 12px;
  transition: all 0.3s ease;
}

.page-connexion .lien-annuler {
  background: rgba(255,255,255,0.1);
  color: #d8d8e2;
}

.page-connexion .lien-annuler:hover {
  background: rgba(255,255,255,0.2);
}

.page-connexion .btn-creer-compte {
  background: linear-gradient(135deg, #4a00e0, #8e2de2);
  color: white;
}

.page-connexion .btn-creer-compte:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(155, 77, 255, 0.6);
}

.page-connexion p {
  text-align: center;
  margin-top: 18px;
  font-size: 14px;
  color: #c7b7ff;
}
/* ================================
   Styles spécifiques à la page de déconnexion
================================ */

.logout-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 90vh;
  background: #121025; /* fond sombre identique au thème global */
  font-family: "Poppins", sans-serif;
  color: #e4e4e7;
}

.logout-box {
  background: #2e1a4c;
  border-radius: 16px;
  padding: 40px 50px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  text-align: center;
  max-width: 420px;
  width: 90%;
}

.logout-box h2 {
  font-size: 26px;
  color: #e040fb;
  margin-bottom: 15px;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

.logout-box p {
  font-size: 16px;
  color: #c7b7ff;
  margin-bottom: 30px;
}

.logout-buttons {
  display: flex;
  justify-content: center;
  gap: 20px;
}

/* Bouton confirmer */
.btn-logout-confirm {
  background: linear-gradient(135deg, #9b4dff, #d47bff);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 12px 24px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(155, 77, 255, 0.4);
}

.btn-logout-confirm:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(155, 77, 255, 0.6);
}

/* Bouton annuler */
.btn-logout-cancel {
  display: inline-block;
  background: rgba(255,255,255,0.1);
  color: #d8d8e2;
  text-decoration: none;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  transition: all 0.3s ease;
}

.btn-logout-cancel:hover {
  background: rgba(255,255,255,0.2);
}
