:root {
  --primary: #146176; /* Tu azul milagroso */
  --primary-dark: #0d4250; /* Un tono más oscuro para que el botón haga algo cuando pasas el cursor */
  --bg-light: #f0f2f5; /* Fondo de la pantalla, para que no parezca que estás en una cueva */
  --white: #ffffff;
  --text-main: #333333; /* Texto oscuro para fondos claros. Magia, lo sé. */
  --text-muted: #64748b; /* Gris para textos secundarios */
  --border: #cbd5e1;
}

* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Segoe UI', sans-serif; }

body {
  background: var(--bg-light);
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

.container {
  width: 90%;
  max-width: 1000px;
  height: 600px;
  background: var(--white); /* Pasamos de tu cueva oscura a la civilización */
  border-radius: 20px;
  box-shadow: 0 15px 35px rgba(0,0,0,0.1); /* Le devolví la sombra para que no flote a lo pendejo */
  display: flex;
  overflow: hidden;
  position: relative;
}

/* Panel izquierdo (hero) - AHORA ES AZUL */
.left {
  flex: 1;
  background: var(--primary);
  color: var(--white);
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 2rem;
  text-align: center;
}
.left::before, .left::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
}
.left::before { width: 180px; height: 180px; top: 80px; left: 80px; }
.left::after { width: 260px; height: 260px; bottom: -50px; right: -60px; }

.logo { width: 100%; text-align: left; margin-bottom: 1.0rem; }
.logo img { max-width: 80px; height: auto; display: block; margin-top: -10px; }
.logo-right { width: 100%; text-align: center; margin-bottom: 1.5rem; }
.logo-right img { max-width: 100px; width: 100%; height: auto; display: inline-block; }

.welcome { max-width: 360px; z-index: 1; }
.welcome h1 {
  font-size: 1.9rem; font-weight: 800; margin: -0.5rem 0 0.75rem 0;
  /* El degradado feo amarillo ahora es blanco decente */
  color: var(--white);
  text-shadow: 0 1px 0 rgba(0,0,0,.1);
  animation: fadeInDown 800ms ease both;
}
.welcome p { margin: 0 0 1rem 0; font-size: 1rem; color: #e0f2fe; animation: fadeIn 1s ease both; }

.footer-left { font-size: .85rem; color: #bae6fd; margin-top: 2rem; }
.footer-left a { color: var(--white); font-weight: 600; text-decoration: none; }
.footer-left a:hover { text-decoration: underline; }

/* Panel derecho (login) - AHORA ES BLANCO */
.right {
  flex: 1; display: flex; justify-content: center; align-items: center; padding: 2rem;
  background: var(--white);
}

.form-box {
  background-color: var(--white);
  padding: 2rem; border-radius: 12px;
  width: 100%; max-width: 320px;
}
.form-box h2 { 
  color: var(--text-main); /* El texto ahora se ve */
  text-align: center; 
  margin-bottom: 1.5rem; 
}

.form-box .input-group {
    position: relative;
    margin-bottom: 1rem;
}

.form-box input {
  width: 100%; padding: .75rem;
  border: 1px solid var(--border); 
  border-radius: 6px; font-size: 1rem;
  background-color: #f8fafc; /* Fondo clarito para el input, no esa cosa negra que tenías */
  color: var(--text-main); 
  transition: border-color 0.2s;
}
.form-box input:focus {
  outline: none;
  border-color: var(--primary);
}
.form-box input[name="password"] {
    padding-right: 2.5rem; 
}

.form-box .toggle-icon {
    position: absolute;
    top: 50%;
    right: 0.75rem;
    transform: translateY(-50%);
    cursor: pointer;
    color: #94a3b8; /* Gris sutil */
}

.form-box button {
  width: 100%; 
  background: var(--primary); /* El botón es azul */
  color: var(--white); 
  padding: .75rem; border: none; border-radius: 6px; font-weight: bold; font-size: 1rem; cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}
.form-box button:hover { 
  background: var(--primary-dark); 
}

.form-footer { 
  margin-top: 1rem; 
  text-align: center; 
  font-size: .9rem; 
  color: var(--text-muted); 
}

.form-footer a {
  color: var(--primary); /* Enlaces en azul, no en tu amarillo radiactivo */
  text-decoration: none;
  font-weight: 600;
}
.form-footer a:hover {
  text-decoration: underline;
}

/* Mensajes de error/éxito */
.error-message {
  background-color: #fef2f2;
  color: #dc2626;
  padding: 0.75rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  border: 1px solid #fecaca;
}

.success-message {
  background-color: #f0fdf4;
  color: #16a34a;
  padding: 0.75rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  border: 1px solid #bbf7d0;
}

/* Animaciones (Las dejé para que creas que haces cosas fancy) */
@keyframes fadeInDown { from { opacity: 0; transform: translateY(-16px) } to { opacity: 1; transform: translateY(0) } }
@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(12px) } to { opacity: 1; transform: translateY(0) } }

/* Responsive */
@media (max-width: 768px) {
  .container { flex-direction: column; height: auto; border-radius: 0; }
  .left, .right { flex: none; width: 100%; height: auto; align-items: center; text-align: center; }
  .logo { align-self: center; }
  .left { padding: 3rem 1.5rem; }
}

/* ============================================= */
/* == Estilos para la página de Olvidé Clave == */
/* ============================================= */

.form-box .form-description {
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

.form-box .back-to-login {
  display: block;
  margin-top: 1.5rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--primary);
  transition: opacity 0.2s;
}

.form-box .back-to-login:hover {
  text-decoration: underline;
}

/* Splash Screen intocable */
#splash-screen {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background-color: #fff; display: flex; flex-direction: column;
    justify-content: center; align-items: center; z-index: 9999;
    transition: opacity 1s ease-out;
}
#splash-screen img { max-width: 300px; width: 100%; }
#splash-screen #frase-motivacional {
    margin-top: 25px; font-size: 1.3em; color: #4a4a4a; text-align: center;
    padding: 0 30px; font-style: italic; max-width: 80%;
}

/* ================================================= */
/* == Estilos para Restablecer Clave (PHP NUEVO) == */
/* ================================================= */

.login-box {
    background-color: var(--white);
    padding: 2rem;
    border-radius: 12px;
    width: 100%;
    max-width: 380px;
}

.login-box > p {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.login-box h2 {
    color: var(--text-main);
    text-align: center;
    margin-bottom: 1rem; 
}

.login-box p[style*="color"] {
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    border: 1px solid;
    background-color: var(--bg-light); 
}

.login-box p[style*="green"] a {
    color: var(--primary);
    font-weight: bold;
    text-decoration: none;
}
.login-box p[style*="green"] a:hover { text-decoration: underline; }

.login-box .input-group { margin-bottom: 1rem; }

.login-box .input-group label {
    display: block;
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    text-align: left;
}

.login-box .input-field { position: relative; }

.login-box .input-field i {
    position: absolute; top: 50%; left: 0.75rem; transform: translateY(-50%);
    color: #94a3b8; 
}

.login-box .input-field input {
    width: 100%; padding: .75rem; padding-left: 2.5rem;
    border: 1px solid var(--border); border-radius: 6px; font-size: 1rem;
    background-color: #f8fafc; color: var(--text-main);
}
.login-box .input-field input:focus {
    outline: none; border-color: var(--primary);
}

.login-box .btn {
    width: 100%; background: var(--primary); color: var(--white);
    padding: .75rem; border: none; border-radius: 6px; font-weight: bold; font-size: 1rem; cursor: pointer;
    transition: background-color 0.2s ease-in-out; text-transform: uppercase;
}
.login-box .btn:hover { background: var(--primary-dark); }

.login-box .signup { text-align: center; margin-top: 1.5rem; }
.login-box .signup a {
    display: block; font-weight: 600; text-decoration: none; color: var(--primary);
}
.login-box .signup a:hover { text-decoration: underline; }

.container > footer {
    position: absolute; bottom: 1rem; left: 50%; transform: translateX(-50%);
    color: var(--text-muted); font-size: 0.85rem;
}
