/* Variables pour un style facile à maintenir */
:root {
  /* Couleurs */
  --color-primary: #3ba3f8; /* Rouge/Orange du bouton Login */
  --color-dark-background: #0d0d1e; /* Fond très sombre pour l'image */
  --color-light-background: #ffffff;
  --color-text-dark: #333333;
  --color-text-subtle: #999999;
  --color-border: #eeeeee;
  --color-google-border: #c9c9c9;

  /* NOTE: --color-text-light n'est pas défini ici mais est utilisé dans le CSS. Je vais l'ajouter pour éviter une erreur. */
  --color-text-light: #ffffff;
}

/* -------------------------------------------
    GLOBAL & LAYOUT
    ------------------------------------------- */

/* Cache les labels pour l'accessibilité si non utilisés */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.login-page-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.login-card-wrapper {
  display: flex;
  width: 90%;
  max-width: 1100px;  
  border-radius: 20px;
  overflow: hidden;
  background-color: var(--color-light-background);
  /* Ombre douce et large pour l'effet flottant */
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.2); 
  min-height: 80dvh;
}

/* -------------------------------------------
    PARTIE GAUCHE (VISUELLE)
    ------------------------------------------- */

.login-card-left-panel {
  flex: 1; 
  min-width: 450px;
  position: relative;
  color: var(--color-text-light);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 30px;
  z-index: 2; /* S'assure que le contenu est au-dessus de l'image */
}

/* Conteneur pour l'image et son effet d'arrondi */
.image-content-area {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden;
  border-radius: 20px;
}

.image-content-area img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* L'image sur l'exemple semble avoir une légère opacité ou un filtre sombre */
  filter: brightness(0.9) contrast(1.1); 
}

/* Le contenu doit être au-dessus de l'image (z-index) */
.left-panel-header {
    position: relative;
    z-index: 10;
}

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

.selected-works-text {
  font-weight: 600;
  font-size: 1em;
}

.auth-links {
  display: flex;
  align-items: center;
}

.sign-up-link {
  color: var(--color-text-dark);
  text-decoration: none;
  margin-right: 20px;
  font-size: 0.9em;
  font-weight: 700;
}

.join-us-button {
  background-color: var(--color-light-background);
  color: var(--color-dark-background);
  border: none;
  padding: 8px 20px;
  border-radius: 50px;
  cursor: pointer;
  font-weight: 600;
  transition: opacity 0.2s;
}

/* -------------------------------------------
    PARTIE DROITE (FORMULAIRE)
    ------------------------------------------- */

.login-card-right-panel {
  flex: 1; 
  padding: 50px 70px;
  color: var(--color-text-dark);
}

.right-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 50px;
}

.logo-text {
  font-size: 1.4em;
  font-weight: 800;
  margin: 0;
  letter-spacing: 0.5px;
}

.language-selector {
  display: flex;
  align-items: center;
  padding: 5px 10px;
  border: 1px solid var(--color-border);
  border-radius: 50px;
  font-size: 0.85em;
  color: var(--color-text-subtle);
  font-weight: 500;
}

.language-flag {
  /* Placeholder pour le drapeau, dans une vraie app, ce serait une icône/image */
  width: 18px;
  height: 12px;
  /* La ligne suivante n'est plus nécessaire car le drapeau est un emoji (🇬🇧) dans le JSX. */
  /* background-color: #f0f0f0;  */
  border: 1px solid var(--color-border);
  margin-right: 5px;
  border-radius: 2px;
}

.language-arrow {
    margin-left: 5px;
    font-size: 0.7em;
}

.greeting-title {
  font-size: 2.2em;
  font-weight: 800;
  margin: 0;
  line-height: 1.1;
}

.welcome-text {
  color: var(--color-text-subtle);
  margin-top: 5px;
  margin-bottom: 30px;
  font-size: 0.95em;
}

/* --- Formulaire --- */
.input-group {
  margin-bottom: 25px;
}

.login-input {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-size: 1em;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.forgot-password-link {
  color: var(--color-primary);
  text-decoration: none;
  font-size: 0.8em;
  text-align: right;
  display: block; /* Important pour que text-align: right fonctionne */
  margin-top: 5px;
  font-weight: 500;
}

/* Séparateur "or" */
.separator-text {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 25px 0 15px 0;
  font-size: 0.9em;
  color: var(--color-text-subtle);
}

.separator-line {
  flex-grow: 1;
  border: none;
  border-top: 1px solid var(--color-border);
  margin: 0 15px;
}

/* Boutons */
.login-with-google-button {
  width: 100%;
  background-color: var(--color-light-background);
  color: var(--color-text-dark);
  border: 1px solid var(--color-google-border);
  padding: 10px 15px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1em;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); /* Ombre légère comme sur l'image */
}

/* Styles pour l'image Google */
.login-with-google-button > img { 
    width: 1em;
    margin-left: 10px;
}

.login-button {
  width: 100%;
  background-color: var(--color-primary);
  color: var(--color-text-light);
  border: none;
  padding: 12px 15px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.05em;
  font-weight: 600;
  box-shadow: 0 5px 15px rgba(59, 210, 248, 0.4); /* Ombre colorée pour le bouton */
  transition: background-color 0.2s;
}

/* Prompt d'inscription */
.signup-prompt {
  text-align: center;
  font-size: 0.9em;
  margin-top: 25px;
  color: var(--color-text-subtle);
}

.signup-link-inline {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 500;
}

/* -------------------------------------------
    BACKGROUND IMAGE
    ------------------------------------------- */
.image-background-area{
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1; 
  overflow: hidden;
  opacity: 0.5;
}
.image-background-area > img{
  width: 100%;
}

/* -------------------------------------------
    RESPONSIVE (pour les petits écrans)
    ------------------------------------------- */

@media (max-width: 950px) {
  .login-card-left-panel {
    display: none; 
  }

  .login-card-wrapper {
    width: 90%;
    max-width: 500px;
  }

  .login-card-right-panel {
    padding: 40px 30px;
  }
}