/* ============================================================
   DOCTOR PIES — Login Page
   login.css  (separado para no contaminar main.css)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* ─── Override font para login ───────────────────────────── */
.login-page * { font-family: 'Inter', 'Segoe UI', sans-serif; }

/* ─── Fondo ──────────────────────────────────────────────── */
.login-page {
  min-height: 100vh;
  background: #EEF2FF;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.login-bg { position: fixed; inset: 0; pointer-events: none; z-index: 0; }

.bg-circle {
  position: absolute;
  border-radius: 50%;
  opacity: .18;
}
.bg-circle-1 {
  width: 600px; height: 600px;
  background: radial-gradient(circle, #1B3A6B, transparent 70%);
  top: -180px; left: -180px;
}
.bg-circle-2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, #2E5FA3, transparent 70%);
  bottom: -150px; right: -100px;
}
.bg-circle-3 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, #00B4D8, transparent 70%);
  top: 40%; left: 55%;
  opacity: .10;
}

/* ─── Wrapper principal ──────────────────────────────────── */
.login-wrapper {
  display: flex;
  width: 960px;
  max-width: 96vw;
  min-height: 600px;
  border-radius: 24px;
  overflow: hidden;
  box-shadow:
    0 20px 60px rgba(27,58,107,.18),
    0 4px 16px rgba(0,0,0,.08);
  position: relative;
  z-index: 1;
}

/* ─── Panel Izquierdo — Branding ──────────────────────────── */
.login-left {
  flex: 1;
  background: linear-gradient(150deg, #0F2342 0%, #1B3A6B 45%, #1e4a8a 100%);
  padding: 48px 44px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}

/* Patrón de puntos decorativo */
.login-left::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

.login-left-inner { position: relative; z-index: 1; }

/* Logo */
.login-logo-wrap {
  background: white;
  display: inline-block;
  padding: 16px 28px;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  margin-bottom: 32px;
}
.login-logo {
  display: block;
  width: 220px;
  max-width: 100%;
  height: auto;
}

/* Línea divisoria */
.login-divider {
  width: 48px;
  height: 3px;
  background: #00B4D8;
  border-radius: 4px;
  margin-bottom: 20px;
}

.login-brand-title {
  font-size: 20px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 10px;
  line-height: 1.3;
}

.login-brand-sub {
  font-size: 13.5px;
  color: rgba(255,255,255,.60);
  line-height: 1.6;
  margin-bottom: 32px;
}

/* Lista de features */
.login-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.login-features li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.feat-icon {
  width: 38px; height: 38px;
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
}
.login-features li div {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 2px;
}
.login-features li strong {
  font-size: 13px;
  font-weight: 600;
  color: #fff;
}
.login-features li span {
  font-size: 12px;
  color: rgba(255,255,255,.50);
}

.login-left-footer {
  font-size: 11.5px;
  color: rgba(255,255,255,.35);
  position: relative;
  z-index: 1;
}
.login-left-footer strong { color: rgba(255,255,255,.55); }

/* ─── Panel Derecho — Formulario ─────────────────────────── */
.login-right {
  width: 420px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 44px;
}

.login-form-box { width: 100%; }

/* Header del form */
.login-form-header { text-align: center; margin-bottom: 32px; }

.login-form-avatar {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, #1B3A6B, #2E5FA3);
  border-radius: 20px;
  display: flex; align-items: center; justify-content: center;
  color: white;
  margin: 0 auto 16px;
  box-shadow: 0 8px 24px rgba(27,58,107,.25);
}

.login-form-header h1 {
  font-size: 24px;
  font-weight: 800;
  color: #0F2342;
  margin-bottom: 6px;
}
.login-form-header p {
  font-size: 13.5px;
  color: #64748B;
}

/* Alert de error */
.login-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: #B91C1C;
  font-size: 13px;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 20px;
}

/* Grupos de campo */
.lf-group {
  margin-bottom: 20px;
}
.lf-group label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 7px;
}
.lf-group label svg { color: #6B7280; }

.lf-group input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1.5px solid #D1D5DB;
  border-radius: 12px;
  font-size: 14px;
  color: #111827;
  background: #F9FAFB;
  transition: border-color .15s, box-shadow .15s, background .15s;
  outline: none;
}
.lf-group input:focus {
  border-color: #2E5FA3;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(46,95,163,.10);
}
.lf-group input::placeholder { color: #9CA3AF; }

.lf-input-wrap { position: relative; }
.lf-input-wrap input { padding-right: 46px; }

.lf-eye {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  color: #9CA3AF;
  padding: 4px;
  line-height: 0;
  transition: color .15s;
}
.lf-eye:hover { color: #374151; }

.lf-error {
  display: block;
  font-size: 11.5px;
  color: #EF4444;
  margin-top: 5px;
  min-height: 14px;
}

/* Botón submit */
.lf-submit {
  width: 100%;
  height: 48px;
  background: linear-gradient(135deg, #1B3A6B, #2E5FA3);
  color: white;
  font-size: 15px;
  font-weight: 700;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  transition: all .2s;
  box-shadow: 0 4px 16px rgba(27,58,107,.30);
  letter-spacing: .01em;
}
.lf-submit:hover:not(:disabled) {
  background: linear-gradient(135deg, #162e55, #2551a3);
  box-shadow: 0 6px 20px rgba(27,58,107,.40);
  transform: translateY(-1px);
}
.lf-submit:active:not(:disabled) { transform: scale(.98); }
.lf-submit:disabled { opacity: .65; cursor: not-allowed; }

/* Spinner */
.lf-spinner {
  width: 20px; height: 20px;
  border: 2.5px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .65s linear infinite;
  display: flex;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Shake en error */
@keyframes shake {
  0%,100% { transform: translateX(0); }
  20%,60%  { transform: translateX(-6px); }
  40%,80%  { transform: translateX(6px); }
}
.shake { animation: shake .4s ease; }

/* Help text */
.lf-help {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 12px;
  color: #9CA3AF;
  margin-top: 20px;
  text-align: center;
}

/* ─── Responsive ─────────────────────────────────────────── */
@media (max-width: 720px) {
  .login-left  { display: none; }
  .login-right { width: 100%; padding: 36px 28px; }
  .login-wrapper { border-radius: 16px; }
}
