/* Login — hero premium, coherente con landing */

:root {
  --bg: #05070a;
  --panel: rgba(7, 12, 18, 0.82);
  --panel-border: rgba(214, 163, 50, 0.28);
  --gold: #d6a332;
  --gold-soft: #f2c14e;
  --white: #ffffff;
  --muted: #b8c0cc;
  --line: rgba(214, 163, 50, 0.35);
  --header-h: 120px;
  --font-display: "Bebas Neue", "Arial Narrow", sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --login-overlay: linear-gradient(
    105deg,
    rgba(5, 7, 10, 0.97) 0%,
    rgba(5, 7, 10, 0.88) 42%,
    rgba(5, 7, 10, 0.45) 68%,
    rgba(5, 7, 10, 0.15) 100%
  );
}

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

html, body {
  height: 100%;
}

body.login-body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
}

.login-body a {
  color: inherit;
  text-decoration: none;
}

/* ─── Header ─── */
.login-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.5rem, 4vw, 3rem);
  background: rgba(5, 7, 10, 0.98);
  border-bottom: 1px solid var(--line);
}

.login-header__brand {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.login-header__logo-mxaib {
  height: 104px;
  width: auto;
  object-fit: contain;
}

.login-header__sep {
  width: 1px;
  height: 72px;
  background: var(--line);
}

.login-header__logo-onko {
  height: 42px;
  width: auto;
  object-fit: contain;
}

.login-header__back {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0.6rem 1.1rem;
  border: 1px solid var(--line);
  transition: color 0.2s, border-color 0.2s;
}

.login-header__back:hover {
  color: var(--gold-soft);
  border-color: var(--gold);
}

/* ─── Hero shell ─── */
.login-shell {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  position: relative;
}

.login-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--bg) url("../img/login-hero-bg.png") center right / cover no-repeat;
}

.login-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: var(--login-overlay);
  pointer-events: none;
}

.login-main {
  flex: 1;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 2rem) clamp(1.5rem, 5vw, 4rem) 2rem;
}

/* ─── Panel de acceso ─── */
.login-panel {
  width: 100%;
  max-width: 420px;
  padding: 2.75rem 2.5rem;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.55);
}

.login-panel__eyebrow {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

.login-panel__title {
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.login-panel__sub {
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 2rem;
  line-height: 1.5;
}

.login-flash {
  padding: 0.85rem 1rem;
  margin-bottom: 1.25rem;
  font-size: 0.85rem;
  border: 1px solid;
  line-height: 1.4;
}

.login-flash--danger {
  background: rgba(180, 40, 40, 0.15);
  border-color: rgba(220, 80, 80, 0.45);
  color: #ffb4b4;
}

.login-flash--success {
  background: rgba(40, 120, 60, 0.15);
  border-color: rgba(80, 180, 100, 0.4);
  color: #b8e8c0;
}

.login-flash--info {
  background: rgba(214, 163, 50, 0.1);
  border-color: var(--line);
  color: var(--gold-soft);
}

.login-field {
  margin-bottom: 1.25rem;
}

.login-field label {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

.login-field input {
  width: 100%;
  padding: 0.95rem 1rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--white);
  background: rgba(5, 7, 10, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.12);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.login-field input::placeholder {
  color: rgba(184, 192, 204, 0.45);
}

.login-field input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(214, 163, 50, 0.12);
}

.login-submit {
  width: 100%;
  margin-top: 0.5rem;
  padding: 1.05rem 2rem;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--gold);
  border: 1px solid var(--gold);
  cursor: pointer;
  transition: background 0.2s;
}

.login-submit:hover {
  background: var(--gold-soft);
}

.login-aegis {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.login-aegis img {
  height: 44px;
  width: auto;
  opacity: 0.9;
}

.login-aegis span {
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1.4;
}

/* ─── Footer logos ─── */
.login-footer {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  background: rgba(7, 12, 18, 0.92);
  border-top: 1px solid var(--line);
}

.login-footer__logos {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding: 1.25rem clamp(1.5rem, 4vw, 3rem);
}

.login-footer__logos img {
  object-fit: contain;
  opacity: 0.92;
}

.login-footer__logos .logo-mxaib { height: 40px; width: auto; }
.login-footer__logos .logo-onko  { height: 28px; width: auto; }
.login-footer__logos .logo-aegis { height: 52px; width: auto; }

.login-footer__sep {
  width: 1px;
  height: 32px;
  background: var(--line);
}

/* ─── Responsive ─── */
@media (max-width: 768px) {
  .login-header {
    height: auto;
    flex-wrap: wrap;
    padding: 1rem 1.25rem;
    gap: 1rem;
  }

  .login-header__logo-mxaib { height: 72px; }
  .login-header__sep { height: 52px; }
  .login-header__logo-onko { height: 30px; }

  .login-main {
    align-items: flex-end;
    padding-bottom: 1.5rem;
  }

  .login-panel {
    max-width: 100%;
    padding: 2rem 1.5rem;
  }

  .login-hero-bg {
    background-position: 70% center;
  }
}

@media (max-width: 520px) {
  .login-header__logo-mxaib { height: 56px; }
  .login-header__logo-onko { height: 24px; }
  .login-footer__sep { display: none; }
}
