:root{
  --red: #C00000;
  --red-dark: #8B0000;
  --bg: #f5f5f5;
  --text: #1a1a1a;
  --muted: #6b7280;
  --border: #e5e7eb;
  color-scheme: light;   /* el login siempre claro: que los inputs nativos no se pinten oscuros en un SO oscuro */
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body{
  font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: linear-gradient(135deg, #fdf3f3 0%, #f5f5f5 50%, #fff 100%);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  display: grid; place-items: center; min-height: 100vh;
}
.login-wrap{
  width: 100%; max-width: 420px; padding: 24px;
  display: flex; flex-direction: column; align-items: center; gap: 24px;
}
.login-card{
  background: #fff; width: 100%;
  border-radius: 12px;
  padding: 32px 28px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.04);
  border-top: 4px solid var(--red);
}
.login-brand{
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  margin-bottom: 28px;
}
.brand-logo{
  max-height: 70px; max-width: 240px; width: auto; height: auto;
  object-fit: contain; display: block;
}
.logo-tag{ font-size: 12px; color: var(--red); font-weight: 600; letter-spacing: .5px; text-transform: uppercase; }
/* Legacy (por si algun template aun usa logo-main) */
.logo-main{ font-weight: 800; font-size: 32px; color: #1a1a1a; letter-spacing: -.5px; }
.logo-x{ color: var(--red); }
/* ===== formulario de autenticacion =====
   Va por CLASE, no por id: lo usan LOGIN y CAMBIAR CONTRASEÑA (y cualquier otra
   pagina publica que se agregue). Cuando esto estaba como `#loginForm`/`#loginBtn`,
   la pagina de cambiar contraseña (`#cpForm`/`#cpBtn`) salia SIN NINGUN estilo:
   etiquetas pegadas al campo, inputs y boton del navegador, todo corrido. */
.auth-form{ display: flex; flex-direction: column; gap: 14px; }
.auth-form label{ display: flex; flex-direction: column; gap: 6px; }
.auth-form label > span{
  font-size: 11px; font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: .5px;
}
.auth-form input{
  width: 100%;
  border: 1px solid var(--border); border-radius: 8px;
  padding: 11px 14px; font-size: 14px; font-family: inherit;
  background: #fafafa; transition: all .15s;
}
.auth-form input:focus{
  outline: none; border-color: var(--red); background: #fff;
  box-shadow: 0 0 0 3px rgba(192,0,0,.12);
}
.auth-btn{
  background: var(--red); color: #fff; border: 0; padding: 12px;
  font-size: 14px; font-weight: 700; font-family: inherit;
  border-radius: 8px; cursor: pointer; transition: background .15s;
  letter-spacing: .5px; text-transform: uppercase;
  margin-top: 6px; width: 100%;
}
.auth-btn:hover:not(:disabled){ background: var(--red-dark); }
.auth-btn:disabled{ opacity: .6; cursor: wait; }
.auth-link{
  display: block; margin-top: 16px; text-align: center;
  color: var(--muted); font-size: 12px; text-decoration: none;
}
.auth-link:hover{ color: var(--red); text-decoration: underline; }
.login-error{
  background: #fff5f5; color: var(--red-dark);
  border: 1px solid #fcc;
  padding: 8px 12px; border-radius: 6px;
  font-size: 13px; font-weight: 500;
}
.login-hint{
  font-size: 11px; color: var(--muted); text-align: center;
  margin: 18px 0 0; line-height: 1.5;
}
.login-footer{ font-size: 11px; color: #999; }
