/* Login unificado (index.php) — todas las instituciones (UO, UOG, IADEU).
   Hoja autocontenida: no depende de style.css. */

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

.ulogin {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-family: "Open Sans", Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: #1f2937;
  background: #0b3a67;
  background-image:
    linear-gradient(135deg, rgba(8, 47, 89, 0.92) 0%, rgba(13, 86, 122, 0.92) 55%, rgba(9, 66, 95, 0.94) 100%),
    url("../img/wallpaperUO.jpg");
  background-size: cover;
  background-position: center;
}

.ulogin__card {
  width: 100%;
  max-width: 420px;
  background: #ffffff;
  border-radius: 20px;
  padding: 34px 34px 30px;
  box-shadow: 0 24px 60px rgba(3, 27, 49, 0.45);
  animation: uloginIn 0.45s ease;
}

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

/* Collage de logos */
.ulogin__brands {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding-bottom: 22px;
  margin-bottom: 22px;
  border-bottom: 1px solid #eef1f5;
}

.ulogin__brand {
  display: block;
  width: auto;
  object-fit: contain;
}

.ulogin__brand--uo    { height: 30px; }
.ulogin__brand--uog   { height: 40px; }
.ulogin__brand--iadeu { height: 48px; }

.ulogin__sep {
  width: 1px;
  align-self: stretch;
  background: #e5e9ef;
}

.ulogin__title {
  font-size: 21px;
  font-weight: 700;
  text-align: center;
  color: #0b3a67;
}

.ulogin__sub {
  font-size: 13px;
  text-align: center;
  color: #7b8794;
  margin-top: 4px;
  margin-bottom: 22px;
}

.ulogin__alert {
  background: #fdecea;
  color: #b71c1c;
  border: 1px solid #f5c6cb;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 13px;
  text-align: center;
  margin-bottom: 16px;
}

/* Formulario */
.ulogin__field {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #d8dee6;
  border-radius: 12px;
  padding: 0 14px;
  height: 50px;
  margin-bottom: 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ulogin__field:focus-within {
  border-color: #1565c0;
  box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.12);
}

.ulogin__ic {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
}
.ulogin__ic path { stroke: #9aa5b1; fill: none; stroke-width: 1; }

.ulogin__field input {
  flex: 1 1 auto;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  color: #1f2937;
  font-family: inherit;
}

.ulogin__submit {
  width: 100%;
  height: 50px;
  border: none;
  border-radius: 12px;
  background: #1565c0;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  margin-top: 6px;
  transition: background 0.2s, transform 0.05s;
}
.ulogin__submit:hover  { background: #0d4f9e; }
.ulogin__submit:active { transform: translateY(1px); }

.ulogin__forgot {
  text-align: center;
  font-size: 13px;
  color: #6b7280;
  margin-top: 14px;
}
.ulogin__forgot a { color: #1565c0; text-decoration: none; font-weight: 600; }
.ulogin__forgot a:hover { text-decoration: underline; }

/* Separador "o continúa con" */
.ulogin__divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0 16px;
  color: #9aa5b1;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.ulogin__divider::before,
.ulogin__divider::after {
  content: "";
  flex: 1 1 auto;
  height: 1px;
  background: #e5e9ef;
}

/* Botones sociales */
.ulogin__social { display: flex; flex-direction: column; gap: 10px; }

.ulogin__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid #d8dee6;
  background: #fff;
  color: #3c4043;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.ulogin__btn:hover {
  background: #f7f9fc;
  box-shadow: 0 2px 8px rgba(3, 27, 49, 0.08);
}
.ulogin__btn-ic { width: 20px; height: 20px; flex: 0 0 auto; }
.ulogin__btn small { color: #00a4ef; font-weight: 700; }

.ulogin__btn--ms { border-color: #d8dee6; }

@media (max-width: 480px) {
  .ulogin__card { padding: 26px 20px 24px; border-radius: 16px; }
  .ulogin__brands { gap: 10px; }
  .ulogin__brand--uo    { height: 24px; }
  .ulogin__brand--uog   { height: 32px; }
  .ulogin__brand--iadeu { height: 40px; }
}

/* ===== Pasarela de instituciones (index.php) ===== */
.gw {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  font-family: "Open Sans", Helvetica, Arial, sans-serif;
  font-size: 16px;
  color: #fff;
  background: #0b3a67;
  background-image:
    linear-gradient(135deg, rgba(8, 47, 89, 0.94) 0%, rgba(13, 86, 122, 0.92) 55%, rgba(9, 66, 95, 0.95) 100%),
    url("../img/wallpaperUO.jpg");
  background-size: cover;
  background-position: center;
}
.gw *, .gw *::before, .gw *::after { box-sizing: border-box; margin: 0; padding: 0; }

.gw__wrap { width: 100%; max-width: 920px; text-align: center; animation: uloginIn 0.45s ease; }
.gw__title { font-size: 30px; font-weight: 700; }
.gw__sub { font-size: 15px; color: rgba(255, 255, 255, 0.8); margin-top: 8px; margin-bottom: 34px; }

.gw__cards { display: flex; gap: 22px; justify-content: center; flex-wrap: wrap; }

.gw__card {
  flex: 1 1 240px;
  max-width: 280px;
  background: #fff;
  border-radius: 18px;
  padding: 26px 22px 22px;
  text-decoration: none;
  color: #1f2937;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 18px 44px rgba(3, 27, 49, 0.4);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.gw__card:hover { transform: translateY(-6px); box-shadow: 0 26px 56px rgba(3, 27, 49, 0.5); }

.gw__logo-box {
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.gw__logo { max-width: 190px; max-height: 86px; width: auto; height: auto; object-fit: contain; }

.gw__name { font-size: 16px; font-weight: 700; color: #0b3a67; text-align: center; }

.gw__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 13px;
  font-weight: 600;
  color: #1565c0;
}
.gw__arrow { width: 15px; height: 15px; transition: transform 0.18s ease; }
.gw__card:hover .gw__arrow { transform: translateX(4px); }

@media (max-width: 720px) {
  .gw__cards { flex-direction: column; align-items: center; }
  .gw__card { width: 100%; max-width: 360px; flex-basis: auto; }
  .gw__title { font-size: 24px; }
}

/* ===== Ajustes de la página por institución ===== */
.ulogin__card { position: relative; }

.ulogin__back {
  display: inline-block;
  font-size: 12.5px;
  color: #6b7280;
  text-decoration: none;
  margin-bottom: 12px;
}
.ulogin__back:hover { color: #1565c0; }

.ulogin__brands--single { justify-content: center; }
.ulogin__brand--solo { height: auto; max-height: 70px; max-width: 220px; }

.ulogin__btn--primary { height: 52px; font-size: 15px; border-color: #c7d0db; }
.ulogin__btn--primary:hover { box-shadow: 0 4px 14px rgba(3, 27, 49, 0.12); }
