/* RESET ET STYLES DE BASE */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Roboto', 'Segoe UI', sans-serif;
}

:root {
  --primary: #24881c;
  --primary-dark: #185a13;
  --primary-light: #3aaa3f;
  --secondary: #2d2d2d;
  --dark: #171717;
  --light: #f1f1f1;
  --danger: #b42b2b;
  --warning: #e67e22;
  --success: #27ae60;
  --info: #0288d1;
  --accent: #75b934;
}

body {
  background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.85)), 
              url('/images/dayz-background.jpg') no-repeat center center fixed;
  background-size: cover;
  color: var(--light);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

/* CONTAINER DE CONNEXION */
.login-container {
  width: 100%;
  max-width: 450px;
  background-color: rgba(25, 25, 25, 0.95);
  border-radius: 8px;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  border: 1px solid rgba(70, 70, 70, 0.5);
  animation: fadeIn 0.4s ease-out forwards;
}

/* HEADER DE CONNEXION */
.login-header {
  background: linear-gradient(120deg, var(--dark), var(--secondary));
  padding: 25px 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  position: relative;
}

.login-header h1 {
  color: var(--primary-light);
  font-size: 1.8rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 0 0 10px 0;
  text-shadow: 0 0 10px rgba(58, 170, 63, 0.3);
}

.login-header p {
  color: #aaa;
  font-size: 0.9rem;
}

.login-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--primary-light), transparent);
}

/* LOGO */
.login-logo {
  text-align: center;
  margin-bottom: 10px;
}

.login-logo img {
  width: 80px;
  height: auto;
}

/* FORMULAIRE DE CONNEXION */
.login-form {
  padding: 30px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.9rem;
  color: #bbb;
  font-weight: 500;
}

.form-control {
  width: 100%;
  padding: 12px 15px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  color: var(--light);
  font-size: 0.95rem;
  transition: all 0.2s ease;
}

.form-control:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 2px rgba(58, 170, 63, 0.25);
}

.input-icon-wrapper {
  position: relative;
}

.input-icon {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #aaa;
}

.input-with-icon {
  padding-left: 40px;
}

/* BOUTON DE CONNEXION */
.login-btn {
  width: 100%;
  padding: 12px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.login-btn:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.login-btn:active {
  transform: translateY(0);
  box-shadow: none;
}

/* EFFET DE PULSE SUR LE BOUTON */
.login-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5px;
  height: 5px;
  background: rgba(255, 255, 255, 0.5);
  opacity: 0;
  border-radius: 100%;
  transform: scale(1, 1) translate(-50%);
  transform-origin: 50% 50%;
}

.login-btn:focus:not(:active)::after {
  animation: ripple 1s ease-out;
}

@keyframes ripple {
  0% {
    transform: scale(0, 0);
    opacity: 0.5;
  }
  20% {
    transform: scale(25, 25);
    opacity: 0.3;
  }
  100% {
    transform: scale(40, 40);
    opacity: 0;
  }
}

/* MESSAGES D'ERREUR ET D'INFORMATION */
.alert {
  padding: 12px 15px;
  margin-bottom: 20px;
  border-radius: 4px;
  font-size: 0.9rem;
}

.alert-danger {
  background-color: rgba(231, 76, 60, 0.2);
  color: #e74c3c;
  border: 1px solid rgba(231, 76, 60, 0.3);
}

.alert-warning {
  background-color: rgba(230, 126, 34, 0.2);
  color: #e67e22;
  border: 1px solid rgba(230, 126, 34, 0.3);
}

.alert-info {
  background-color: rgba(41, 128, 185, 0.2);
  color: #3498db;
  border: 1px solid rgba(41, 128, 185, 0.3);
}

/* LIENS SUPPLÉMENTAIRES */
.login-links {
  margin-top: 25px;
  text-align: center;
  font-size: 0.9rem;
}

.login-links a {
  color: var(--primary-light);
  text-decoration: none;
  transition: color 0.2s ease;
}

.login-links a:hover {
  color: var(--accent);
  text-decoration: underline;
}



/* BOUTON DE RETOUR */
.return-btn-container {
  margin-top: 25px;
  text-align: center;
}

.return-btn {
  display: inline-block;
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--secondary), var(--dark));
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  border: 1px solid rgba(70, 70, 70, 0.5);
}

.return-btn:hover {
  background: linear-gradient(135deg, var(--dark), var(--secondary));
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
  color: var(--primary-light);
  text-decoration: none;
}

.return-btn i {
  margin-right: 5px;
}

/* FOOTER */
.login-footer {
  text-align: center;
  padding: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.8rem;
  color: #777;
}

/* ANIMATIONS */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* MEDIA QUERIES */
@media (max-width: 480px) {
  .login-container {
    width: 95%;
  }
  
  .login-header h1 {
    font-size: 1.6rem;
  }
  
  .login-form {
    padding: 20px;
  }
}

/* PERSONNALISATION DE LA BARRE DE DÉFILEMENT */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 10px;
  border: 2px solid rgba(0, 0, 0, 0.3);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-light);
}

/* AJOUT D'EFFETS VISUELS POUR LE THEME DAYZ */
.login-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-dark), var(--primary-light), var(--primary-dark));
  z-index: 1;
}