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

:root {
  --azul: #1a73e8;
  --azul-hover: #1765cc;
  --gris-borde: #dadce0;
  --gris-texto: #5f6368;
  --gris-fondo: #f8f9fa;
  --texto: #202124;
  --error: #d93025;
}

body {
  font-family: 'Segoe UI', Roboto, Arial, sans-serif;
  background: var(--gris-fondo);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--texto);
  padding: 20px;
}

.login-card {
  background: #fff;
  border: 1px solid var(--gris-borde);
  border-radius: 12px;
  padding: 48px 40px 36px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 1px 3px rgba(60,64,67,0.08), 0 4px 12px rgba(60,64,67,0.06);
  text-align: center;
  animation: fadeIn 0.35s ease-out;
}

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

.login-logo {
  --logo-ancho: 600px;
  --logo-alto: auto;
  width: var(--logo-ancho);
  height: var(--logo-alto);
  max-width: 100%;
  object-fit: contain;
  margin: 0 auto 24px;
  display: block;
}

.login-title {
  font-size: 24px;
  font-weight: 400;
  margin-bottom: 8px;
  color: var(--texto);
}

.login-subtitle {
  font-size: 14px;
  color: var(--gris-texto);
  margin-bottom: 32px;
}

.field {
  position: relative;
  margin-bottom: 20px;
  text-align: left;
}

.field input {
  width: 100%;
  padding: 16px 14px 14px;
  font-size: 15px;
  border: 1px solid var(--gris-borde);
  border-radius: 6px;
  outline: none;
  background: #fff;
  color: var(--texto);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.field input:focus {
  border-color: var(--azul);
  box-shadow: 0 0 0 1px var(--azul);
}

.field label {
  position: absolute;
  left: 14px;
  top: 16px;
  font-size: 15px;
  color: var(--gris-texto);
  background: #fff;
  padding: 0 4px;
  pointer-events: none;
  transition: all 0.15s ease-out;
}

/* Flotado del label */
.field input:focus + label,
.field input:not(:placeholder-shown) + label {
  top: -9px;
  font-size: 12px;
  color: var(--azul);
}

.field input:not(:focus):not(:placeholder-shown) + label {
  color: var(--gris-texto);
}

.btn-primario {
  width: 100%;
  padding: 12px;
  font-size: 15px;
  font-weight: 500;
  color: #fff;
  background: var(--azul);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
  margin-top: 8px;
}

.btn-primario:hover { background: var(--azul-hover); }
.btn-primario:disabled { background: #b8c8e0; cursor: not-allowed; }

.login-links {
  display: flex;
  justify-content: space-between;
  margin-top: 24px;
  font-size: 14px;
}

.login-links a {
  color: var(--azul);
  text-decoration: none;
  font-weight: 500;
}

.login-links a:hover { text-decoration: underline; }

.mensaje {
  margin-top: 18px;
  font-size: 14px;
  min-height: 20px;
  color: var(--error);
}