/* ================================================================
   Grupo Digiytal — Webmail · Login
   Misma estética que la intranet: negro neutro, blanco monocromo.
   ================================================================ */

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

html { font-size:15px; -webkit-font-smoothing:antialiased; }

body {
  font-family: "Inter", "SF Pro Text", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #0a0a0a;
  color: #fafafa;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  overflow: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: -30%; left: 50%;
  transform: translateX(-50%);
  width: 700px; height: 500px;
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.05) 0%, transparent 70%);
  pointer-events: none;
}
body::after {
  content: '';
  position: fixed;
  bottom: -10%; left: 20%;
  width: 400px; height: 300px;
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.03) 0%, transparent 70%);
  pointer-events: none;
}

.login-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 380px;
  z-index: 1;
}

.login-box {
  width: 100%;
  background: #141414;
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 18px;
  padding: 36px 32px 28px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.55), 0 0 0 1px rgba(255,255,255,0.03);
  animation: slideUp 0.45s cubic-bezier(.16,1,.3,1) both;
}

.login-logo { display:flex; justify-content:center; margin-bottom:18px; }
.login-logo img { width:52px; height:52px; border-radius:12px; object-fit:contain; }

.login-box h2 {
  font-size: 1.3rem;
  font-weight: 700;
  text-align: center;
  color: #f0f4ff;
  margin-bottom: 5px;
  letter-spacing: -0.02em;
}
.login-box > p {
  text-align: center;
  color: #4d607a;
  font-size: 0.85rem;
  margin-bottom: 26px;
}

form input {
  width: 100%;
  padding: 10px 13px;
  background: #1e1e1e;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 9px;
  color: #f0f4ff;
  font-size: 0.9rem;
  font-family: inherit;
  margin-bottom: 12px;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
  appearance: none;
}
form input::placeholder { color: #3d4a63; }
form input:focus {
  border-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.14);
}

/* Campo de contraseña con ojo */
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 42px; }
.pw-toggle {
  position: absolute;
  top: 50%; right: 6px;
  transform: translateY(-50%);
  margin-top: -6px;
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  background: none; border: none; cursor: pointer;
  color: #4d607a;
  border-radius: 7px;
  transition: color .15s, background .15s;
}
.pw-toggle:hover { color: #cfcfcf; background: rgba(255,255,255,.06); }
.pw-toggle.on { color: #ffffff; }
.pw-toggle svg { width: 16px; height: 16px; }

button[type="submit"] {
  width: 100%;
  padding: 10px;
  background: #ffffff;
  border: none;
  border-radius: 9px;
  color: #0a0a0a;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s, transform 0.1s;
  margin-top: 4px;
}
button[type="submit"]:hover {
  background: #e5e5e5;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.18);
  transform: translateY(-1px);
}
button[type="submit"]:active { transform: translateY(0); }
button[type="submit"]:disabled { opacity:.6; cursor:default; transform:none; }

.error {
  background: rgba(239,68,68,0.10);
  border: 1px solid rgba(239,68,68,0.25);
  color: #fca5a5;
  padding: 10px 13px;
  border-radius: 8px;
  font-size: 0.83rem;
  margin-bottom: 14px;
  text-align: center;
  line-height: 1.45;
}

/* Datos del servidor */
.srv-info { margin-top: 18px; }
.srv-info summary {
  list-style: none;
  cursor: pointer;
  font-size: 0.74rem;
  color: #3d4a63;
  text-align: center;
  transition: color .15s;
}
.srv-info summary::-webkit-details-marker { display: none; }
.srv-info summary:hover { color: #8a8a8a; }
.srv-info dl {
  margin-top: 12px;
  padding: 12px 14px;
  background: #101010;
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 10px;
  font-size: 0.74rem;
}
.srv-info dt { color: #6b6b6b; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; font-size: .64rem; }
.srv-info dd { color: #cfcfcf; margin: 2px 0 8px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.srv-info dd:last-child { margin-bottom: 0; }

footer {
  margin-top: 22px;
  color: #2a3448;
  font-size: 0.75rem;
  text-align: center;
}

@keyframes slideUp {
  from { opacity:0; transform: translateY(18px); }
  to   { opacity:1; transform: translateY(0); }
}

@media (max-width: 420px) {
  .login-box { padding: 28px 22px 22px; }
}
