/* ======================================================
   VARIABLES BASE (VERDE / APP)
====================================================== */
:root{
  --green: #16a34a;
  --green-dark: #166534;
  --green-soft: #ecfdf5;

  --bg-1: #ecfdf5;
  --bg-2: #d1fae5;

  --text-dark: #1f2937;
  --text-muted: #6b7280;
}

/* ======================================================
   RESET BÁSICO
====================================================== */
*{
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body{
  font-family: Arial, Helvetica, sans-serif;
  background: linear-gradient(180deg, var(--bg-1), var(--bg-2));
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--text-dark);
}

/* ======================================================
   CONTENEDOR LOGIN
====================================================== */
.login-container{
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  border-radius: 14px;
  padding: 32px 28px;
  box-shadow: 0 20px 40px rgba(0,0,0,.08);
  text-align: center;
  position: relative;
}

/* ======================================================
   BOTÓN VOLVER
====================================================== */
.login-back{
  text-align: left;
  margin-bottom: 18px;
}

.btn-back{
  text-decoration: none;
  font-size: 13px;
  color: var(--green-dark);
  font-weight: 600;
}

.btn-back:hover{
  text-decoration: underline;
}

/* ======================================================
   TÍTULOS
====================================================== */
.login-container h2{
  font-size: 22px;
  margin-bottom: 6px;
}

.login-subtitle{
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* ======================================================
   FORMULARIO
====================================================== */
.login-form{
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.login-form input{
  width: 100%;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid #d1d5db;
  font-size: 14px;
}

.login-form input:focus{
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 2px rgba(22,163,74,.15);
}

.login-form button{
  background: var(--green);
  color: #ffffff;
  border: none;
  padding: 14px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  transition: background .2s ease;
}

.login-form button:hover{
  background: var(--green-dark);
}

/* ======================================================
   AVISOS
====================================================== */
.login-notice{
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: var(--green-dark);
  font-size: 13px;
  padding: 10px 12px;
  border-radius: 8px;
}

.login-warning{
  margin-top: 18px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 13px;
  text-align: left;
  color: var(--green-dark);
}

.login-warning ul{
  margin-top: 8px;
  padding-left: 18px;
}

.login-warning li{
  margin-bottom: 6px;
}

/* ======================================================
   LOADER GLOBAL (OFICIAL APP)
====================================================== */
.loader-wrapper{
  position: fixed;
  inset: 0;
  background: radial-gradient(
    900px 700px at 50% 10%,
    #f6fffb 0%,
    var(--bg-1) 45%,
    var(--bg-2) 100%
  );
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  gap: 22px;
  z-index: 2000;
  padding: 32px;
  text-align:center;
}

.loader-text{
  color: var(--green-dark);
  font-weight: 900;
  letter-spacing: 1px;
  font-size: 18px;
  line-height: 1.35;
}

/* ======================================================
   LOADER VERDE
====================================================== */
.loader{
  transform: rotateZ(45deg);
  perspective: 1000px;
  border-radius: 50%;
  width: 72px;
  height: 72px;
  color: var(--green);
  position: relative;
  filter: drop-shadow(0 10px 22px rgba(39,174,96,.35));
}

.loader:before,
.loader:after{
  content:'';
  display:block;
  position:absolute;
  inset: 0;
  border-radius:50%;
  transform: rotateX(70deg);
  animation: spin 1.4s linear infinite;
}

.loader:after{
  transform: rotateY(70deg);
  animation-delay: .4s;
}

/* ======================================================
   ANIMACIÓN LOADER
====================================================== */
@keyframes spin{
  0%{
    box-shadow: .2em 0 0 0 currentColor;
  }
  12%{
    box-shadow: .2em .2em 0 0 currentColor;
  }
  25%{
    box-shadow: 0 .2em 0 0 currentColor;
  }
  37%{
    box-shadow: -.2em .2em 0 0 currentColor;
  }
  50%{
    box-shadow: -.2em 0 0 0 currentColor;
  }
  62%{
    box-shadow: -.2em -.2em 0 0 currentColor;
  }
  75%{
    box-shadow: 0 -.2em 0 0 currentColor;
  }
  87%{
    box-shadow: .2em -.2em 0 0 currentColor;
  }
  100%{
    box-shadow: .2em 0 0 0 currentColor;
  }
}
