* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: url('https://metodo.profesordepapel.com/css/imagen_01.jpeg') no-repeat center;
  background-size: cover;
  font-family: 'Inter', 'Segoe UI', sans-serif;
  height: 100vh;
  position: relative;
}

/* Overlay para oscurecer el fondo */
body::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.75);
  z-index: 1;
}

.login-wrapper {
  height: 100vh;
  width: 100vw;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 2;
}

.form {
  position: relative;
  width: 100%;
  max-width: 380px;
  padding: 80px 40px 40px;
  background: rgba(17, 17, 17, 0.85);
  border-radius: 10px;
  color: #fff;
  box-shadow: 0 15px 25px rgba(0, 0, 0, 0.6);
}

.form::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: rgba(255, 255, 255, 0.05);
  transform: skewX(-26deg);
  transform-origin: bottom left;
  border-radius: 10px;
  pointer-events: none;
}

.form img {
  position: absolute;
  top: -50px;
  left: calc(50% - 50px);
  width: 100px;
  height: 100px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.form h2 {
  text-align: center;
  letter-spacing: 1px;
  margin-bottom: 2rem;
  color: #FF0000; /* Color rojo de YouTube */
  font-weight: 700;
  font-size: 1.8rem;
}

.form .input-group {
  position: relative;
  margin-bottom: 30px;
}

.form .input-group input {
  width: 100%;
  padding: 10px 0;
  font-size: 1rem;
  letter-spacing: 0.5px;
  border: none;
  border-bottom: 1px solid #fff;
  outline: none;
  background-color: transparent;
  color: inherit;
}

.form .input-group label {
  position: absolute;
  top: 0;
  left: 0;
  padding: 10px 0;
  font-size: 1rem;
  pointer-events: none;
  transition: 0.3s ease-out;
}

.form .input-group input:focus + label,
.form .input-group input:valid + label {
  transform: translateY(-18px);
  color: #FF0000; /* Color rojo de YouTube */
  font-size: 0.8rem;
}

.submit-btn {
  display: block;
  width: 100%;
  margin-top: 10px;
  border: none;
  outline: none;
  background: #FF0000; /* Color rojo de YouTube */
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 20px;
  border-radius: 50px;
  cursor: pointer;
  color: white;
  font-weight: 600;
  transition: all 0.3s ease;
}

.submit-btn:hover {
  background: #cc0000;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
}

.back-to-home {
  display: block;
  text-align: center;
  margin-top: 20px;
  color: #fff;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.back-to-home:hover {
  color: #FF0000;
}

.error-message {
  color: #FF0000;
  font-size: 0.9rem;
  margin-top: -20px;
  margin-bottom: 20px;
  text-align: center;
}

/* Añadir animación de entrada */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Animación de sacudida para error */
@keyframes shake {
  0%, 100% {transform: translateX(0);}
  10%, 30%, 50%, 70%, 90% {transform: translateX(-5px);}
  20%, 40%, 60%, 80% {transform: translateX(5px);}
}

.form {
  animation: fadeIn 0.5s ease forwards;
}

.shake {
  animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

.hidden {
  display: none;
}

/* Logo de YouTube Premium */
.yt-premium-logo {
  position: absolute;
  top: 20px;
  left: 20px;
  color: white;
  font-weight: 700;
  font-size: 1.5rem;
  z-index: 10;
  display: flex;
  align-items: center;
}

.yt-premium-logo span {
  background-color: #FF0000;
  padding: 5px 10px;
  border-radius: 5px;
  margin-right: 5px;
}

/* Mensaje de copyright en el pie de página */
.copyright {
  position: absolute;
  bottom: 20px;
  left: 0;
  width: 100%;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.8rem;
  z-index: 10;
}