:root {
  --ink: #eef7ff;
  --ink-muted: rgba(238, 247, 255, 0.86);
  --glass: rgba(220, 241, 255, 0.14);
  --glass-strong: rgba(255, 255, 255, 0.18);
  --line: rgba(220, 242, 255, 0.42);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Ubuntu", sans-serif;
  display: flex;
  justify-content: center;
  align-items: center;
  background: url("../media/TestFondo.png") no-repeat center;
  background-size: cover;
}

.login-box {
  width: min(92vw, 360px);
  padding: 30px 24px;
  border-radius: 24px;
  background:
    linear-gradient(162deg, rgba(255, 255, 255, 0.34), rgba(237, 248, 255, 0.08) 62%),
    var(--glass);
  border: 1px solid var(--line);
  box-shadow: 0 24px 60px rgba(4, 17, 34, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.52);
  backdrop-filter: blur(5px) saturate(100%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  margin-left: 35%;
}

h2 {
  text-align: center;
  color: var(--ink);
  margin: 0 0 8px;
  font-size: clamp(38px, 7vw, 50px);
}

h1 {
  color: var(--ink-muted);
  text-align: center;
  margin: 0 0 18px;
  font-size: 20px;
}

input, select {
  width: 100%;
  padding: 12px;
  margin-bottom: 12px;
  border-radius: 12px;
  border: 1px solid rgba(206, 233, 250, 0.7);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.54), rgba(234, 247, 255, 0.2));
  color: #133151;
  font: inherit;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23133151' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 15px;
  padding-right: 38px;
  cursor: pointer;
}

select option {
  color: #133151;
  background: #f6fbff;
}

input::placeholder {
  color: rgba(31, 69, 108, 0.7);
}

button {
  width: 100%;
  padding: 12px;
  border: 1px solid rgba(199, 229, 250, 0.78);
  border-radius: 12px;
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.52), rgba(214, 239, 255, 0.2));
  color: #113053;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(7, 31, 58, 0.18);
}

button:disabled {
  cursor: wait;
  opacity: 0.82;
  transform: none;
}

#loginButton {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.login-spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(17, 48, 83, 0.24);
  border-top-color: #113053;
  border-radius: 50%;
  animation: login-spin 0.75s linear infinite;
}

#loginButton.is-loading .login-spinner {
  display: inline-block;
}

@keyframes login-spin {
  to { transform: rotate(360deg); }
}

.error {
  color: #ffd5d5;
  text-align: center;
  margin-top: 10px;
  min-height: 20px;
}

#disclaimer {
  position: fixed;
  bottom: 0;
  right: 0;
  width: 100%;
  height: 30px;
  background: rgba(7, 28, 50, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid rgba(214, 237, 255, 0.36);
}

#dsclm, #chng {
  color: #eff8ff;
  text-decoration: none;
  font-size: 10px;
  text-align: center;
}

@media (max-width: 768px) {
  body {
    background: url("../media/fondo.jpg") no-repeat center;
    background-size: cover;
  }

  .login-box {
    padding: 24px 18px;
    border-radius: 20px;
  }
}
