/* ════════════════════════════════════════════════════════
   ASOPADRES GIMNASIO MODERNO — Login Page
   Naranja #fd6b0d  |  Verde #047832  |  Gris #4b4b4b
   ════════════════════════════════════════════════════════ */

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

:root {
  --orange:        #fd6b0d;
  --orange-dark:   #d95800;
  --orange-light:  #fff3eb;
  --orange-mid:    #ffc89a;
  --green:         #047832;
  --green-dark:    #035a25;
  --green-light:   #e8f5ee;
  --gray:          #4b4b4b;
  --gray-light:    #f7f7f7;
  --border:        #e0e0e0;
  --white:         #ffffff;
  --shadow-card:   0 20px 60px rgba(0,0,0,.14);
  --radius:        16px;
  --radius-sm:     10px;
  --radius-xs:     6px;
  --font:          -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ── Fondo general ── */
html, body { height: 100%; }

.avm-login-body {
  font-family: var(--font);
  min-height: 100vh;
  background: #f0f4f8;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
}

/* ── Decoración geométrica de fondo (triángulos del logo) ── */
.avm-login-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.avm-bg-shape {
  position: absolute;
  border-radius: 50%;
  opacity: .06;
}
.avm-bg-shape-1 {
  width: 600px; height: 600px;
  background: var(--green);
  top: -200px; left: -150px;
}
.avm-bg-shape-2 {
  width: 400px; height: 400px;
  background: var(--orange);
  bottom: -100px; right: -80px;
}
.avm-bg-shape-3 {
  width: 250px; height: 250px;
  background: var(--green);
  bottom: 30%; right: 30%;
}

/* ── Layout principal: card + panel info ── */
.avm-login-outer {
  display: flex;
  width: 100%;
  max-width: 920px;
  min-height: 560px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  position: relative;
  z-index: 1;
}

/* ════════════════════════════════════════════════════════
   TARJETA DE FORMULARIO (izquierda)
   ════════════════════════════════════════════════════════ */
.avm-login-card {
  flex: 0 0 420px;
  background: var(--white);
  padding: 40px 44px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* ── Cabecera ── */
.avm-login-header { margin-bottom: 24px; }

.avm-login-logo {
  height: 52px;
  width: auto;
  display: block;
  margin-bottom: 20px;
}
.avm-login-divider {
  height: 3px;
  background: linear-gradient(90deg, var(--orange), var(--green));
  border-radius: 2px;
  margin-bottom: 18px;
}
.avm-login-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--gray);
  margin-bottom: 6px;
  letter-spacing: -.3px;
}
.avm-login-subtitle {
  font-size: 13px;
  color: #888;
  line-height: 1.5;
}
.avm-login-asamblea-ref {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  background: var(--green-light);
  border-left: 3px solid var(--green);
  border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  font-size: 13px;
  color: var(--green-dark);
  line-height: 1.4;
}
.avm-login-ref-icon { font-size: 18px; flex-shrink: 0; }
.avm-login-asamblea-ref strong { display: block; font-size: 14px; margin-bottom: 2px; }
.avm-login-asamblea-ref small { color: #6a9f7a; }

/* ── Alerta ── */
.avm-login-alert {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-radius: var(--radius-xs);
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 16px;
}
.avm-login-alert-error  { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.avm-login-alert-success { background: var(--green-light); color: var(--green-dark); border: 1px solid #86efac; }
.avm-login-alert-icon   { font-size: 16px; flex-shrink: 0; }

/* ── Formulario ── */
.avm-login-form { display: flex; flex-direction: column; gap: 16px; flex: 1; }

.avm-login-field { display: flex; flex-direction: column; gap: 6px; }

.avm-login-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: .4px;
}
.avm-login-label-icon { font-size: 14px; }

.avm-login-input {
  width: 100%;
  padding: 13px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 15px;
  color: var(--gray);
  background: var(--gray-light);
  transition: all .2s ease;
  outline: none;
  font-family: var(--font);
}
.avm-login-input:focus {
  border-color: var(--orange);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(253,107,13,.12);
}
.avm-login-input::placeholder { color: #bbb; }
.avm-login-input.avm-input-error { border-color: #ef4444; }

/* ── Campo contraseña con ojo ── */
.avm-login-password-wrap { position: relative; }
.avm-login-password-wrap .avm-login-input { padding-right: 48px; }
.avm-pwd-toggle {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 18px;
  padding: 0;
  color: #aaa;
  line-height: 1;
  transition: color .2s;
}
.avm-pwd-toggle:hover { color: var(--orange); }

/* ── Fila recordarme / olvidaste ── */
.avm-login-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: -4px;
}
.avm-login-check-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #666;
  cursor: pointer;
  user-select: none;
}
.avm-login-check-label input[type=checkbox] {
  width: 16px;
  height: 16px;
  accent-color: var(--orange);
  cursor: pointer;
}
.avm-login-forgot {
  font-size: 12px;
  color: var(--green);
  text-decoration: none;
  font-weight: 600;
  transition: color .2s;
}
.avm-login-forgot:hover { color: var(--green-dark); text-decoration: underline; }

/* ── Botón de submit ── */
.avm-login-submit {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, var(--orange), var(--orange-dark));
  color: var(--white);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: .2px;
  cursor: pointer;
  transition: all .25s ease;
  box-shadow: 0 4px 16px rgba(253,107,13,.35);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  margin-top: 4px;
}
.avm-login-submit:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--orange-dark), #b84a00);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(253,107,13,.40);
}
.avm-login-submit:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(253,107,13,.30);
}
.avm-login-submit:disabled {
  opacity: .7;
  cursor: not-allowed;
  transform: none;
}

/* ── Spinner de tres puntos ── */
.avm-login-btn-spinner {
  display: flex;
  align-items: center;
  gap: 5px;
}
.avm-spinner-dot {
  width: 7px;
  height: 7px;
  background: rgba(255,255,255,.8);
  border-radius: 50%;
  animation: avm-bounce 1.2s infinite ease-in-out;
}
.avm-spinner-dot:nth-child(2) { animation-delay: .2s; }
.avm-spinner-dot:nth-child(3) { animation-delay: .4s; }
@keyframes avm-bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: .5; }
  40%            { transform: scale(1);   opacity: 1; }
}

/* ── Pie de la tarjeta ── */
.avm-login-footer {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.avm-login-footer-lock {
  font-size: 12px;
  color: #aaa;
  text-align: center;
}
.avm-login-footer-site {
  text-align: center;
}
.avm-login-footer-site a {
  font-size: 13px;
  color: var(--green);
  text-decoration: none;
  font-weight: 600;
  transition: color .2s;
}
.avm-login-footer-site a:hover { color: var(--green-dark); text-decoration: underline; }

/* ════════════════════════════════════════════════════════
   PANEL INFORMATIVO (derecha, verde)
   ════════════════════════════════════════════════════════ */
.avm-login-info {
  flex: 1;
  background: linear-gradient(155deg, var(--green), var(--green-dark) 80%);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 44px 40px;
  position: relative;
  overflow: hidden;
}

/* Patrón decorativo */
.avm-login-info::before {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
  top: -80px; right: -80px;
}
.avm-login-info::after {
  content: '';
  position: absolute;
  width: 200px; height: 200px;
  background: rgba(253,107,13,.15);
  border-radius: 50%;
  bottom: -50px; left: -50px;
}

.avm-login-info-inner {
  position: relative;
  z-index: 1;
  max-width: 340px;
}

.avm-login-info-logo {
  height: 48px;
  width: auto;
  margin-bottom: 28px;
  filter: brightness(0) invert(1);
  opacity: .92;
}

.avm-login-info h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 12px;
  line-height: 1.2;
}

.avm-login-info > .avm-login-info-inner > p {
  font-size: 14px;
  color: rgba(255,255,255,.80);
  line-height: 1.6;
  margin-bottom: 28px;
}

/* ── Pasos ── */
.avm-login-steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 28px;
}
.avm-login-steps li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.avm-step-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  background: var(--orange);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 800;
  box-shadow: 0 3px 10px rgba(253,107,13,.40);
}
.avm-login-steps li div { display: flex; flex-direction: column; padding-top: 4px; }
.avm-login-steps li strong { font-size: 15px; color: var(--white); margin-bottom: 2px; }
.avm-login-steps li span  { font-size: 13px; color: rgba(255,255,255,.72); }

/* ── Agenda ── */
.avm-login-info-agenda {
  background: rgba(255,255,255,.10);
  border: 1px solid rgba(255,255,255,.20);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}
.avm-login-info-agenda strong {
  display: block;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--orange);
  margin-bottom: 6px;
}
.avm-login-info-agenda p {
  font-size: 13px;
  color: rgba(255,255,255,.80);
  line-height: 1.5;
  margin: 0;
}

/* ════════════════════════════════════════════════════════
   RESPONSIVE — Tablet y móvil
   ════════════════════════════════════════════════════════ */
@media (max-width: 820px) {
  .avm-login-outer {
    flex-direction: column;
    max-width: 480px;
  }
  .avm-login-info { display: none; }
  .avm-login-card {
    flex: none;
    padding: 32px 28px;
  }
}

@media (max-width: 480px) {
  .avm-login-body { padding: 12px; }
  .avm-login-card { padding: 28px 20px; }
  .avm-login-title { font-size: 18px; }
  .avm-login-submit { font-size: 15px; padding: 14px; }
  .avm-login-row { flex-direction: column; align-items: flex-start; gap: 10px; }
}
