/* ==========================================================================
 * EcoRadar Urbano · saas-auth.css
 * Estilos para el sistema de licencias, permisos y delimitación territorial
 * ========================================================================== */

@font-face {
  font-family: 'AvenirNextLTPro';
  src: url('../fonts/AvenirNextLTPro-Demi.woff2') format('woff2'),
       url('../../fonts/AvenirNextLTPro-Demi.woff2') format('woff2'),
       url('../AvenirNextLTPro-Demi.woff2') format('woff2'),
       url('../../AvenirNextLTPro-Demi.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* Barra de Estado de Licencia y Delimitación Territorial en Visor */
.eu-saas-banner {
  font-family: 'AvenirNextLTPro', sans-serif;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 2px 16px;
  font-size: 11.5px;
  font-weight: 600;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  transition: all 0.25s ease;
  min-height: 26px;
  max-height: 28px;
  box-sizing: border-box;
}

.eu-saas-banner.is-authorized {
  background: #f0fdf4;
  color: #166534;
  border-bottom-color: rgba(22, 101, 52, 0.2);
}

.eu-saas-banner.is-restricted {
  background: #fffbeb;
  color: #92400e;
  border-bottom-color: rgba(180, 83, 9, 0.2);
}

.eu-saas-banner-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.eu-saas-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.is-authorized .eu-saas-badge-pill {
  background: #bbf7d0;
  color: #14532d;
  border: 1px solid rgba(20, 83, 45, 0.2);
}

.is-restricted .eu-saas-badge-pill {
  background: #fef3c7;
  color: #78350f;
  border: 1px solid rgba(120, 53, 15, 0.2);
}

.eu-saas-banner-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.eu-saas-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.15s ease;
}

.eu-saas-btn-primary {
  background: #0f5132;
  color: #ffffff;
}

.eu-saas-btn-primary:hover {
  background: #093722;
  transform: translateY(-1px);
}

.eu-saas-btn-ghost {
  background: transparent;
  color: inherit;
  border: 1px solid currentColor;
  opacity: 0.85;
}

.eu-saas-btn-ghost:hover {
  opacity: 1;
  background: rgba(0, 0, 0, 0.05);
}

/* Modal de Autenticación de Cliente y Licencia */
.eu-auth-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.eu-auth-modal-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

.eu-auth-modal {
  background: #ffffff;
  border-radius: 20px;
  width: 100%;
  max-width: 520px;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(15, 81, 50, 0.15);
  overflow: hidden;
  transform: translateY(20px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.eu-auth-modal-backdrop.is-open .eu-auth-modal {
  transform: translateY(0);
}

.eu-auth-modal-head {
  padding: 24px 28px;
  background: linear-gradient(135deg, #f0fdf4 0%, #edf7f2 100%);
  border-bottom: 1px solid rgba(15, 81, 50, 0.12);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.eu-auth-modal-head h3 {
  margin: 0;
  font-size: 20px;
  font-weight: 800;
  color: #09261a;
}

.eu-auth-modal-head p {
  margin: 6px 0 0;
  font-size: 13px;
  color: #475569;
}

.eu-auth-modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: #64748b;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
}

.eu-auth-modal-body {
  padding: 28px;
}

.eu-auth-form-group {
  margin-bottom: 20px;
}

.eu-auth-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 8px;
}

.eu-auth-input {
  width: 100%;
  padding: 12px 16px;
  font-size: 15px;
  font-family: monospace;
  letter-spacing: 0.05em;
  border: 1.5px solid #cbd5e1;
  border-radius: 10px;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}

.eu-auth-input:focus {
  border-color: #0f5132;
  box-shadow: 0 0 0 3px rgba(15, 81, 50, 0.12);
}

.eu-auth-help {
  font-size: 12px;
  color: #64748b;
  margin-top: 6px;
}

.eu-auth-demo-keys {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 20px;
}

.eu-auth-demo-keys small {
  display: block;
  font-weight: 700;
  color: #334155;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.eu-auth-demo-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.eu-auth-demo-pill {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-family: monospace;
  cursor: pointer;
  color: #0f5132;
  font-weight: 700;
  transition: all 0.15s;
}

.eu-auth-demo-pill:hover {
  background: #0f5132;
  color: #ffffff;
  border-color: #0f5132;
}

.eu-auth-error {
  background: #fef2f2;
  color: #991b1b;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 16px;
  display: none;
}

.eu-auth-submit-btn {
  width: 100%;
  padding: 14px;
  background: #0f5132;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.2s;
}

.eu-auth-submit-btn:hover {
  background: #093722;
}

/* Pantalla de Bloqueo por Ciudad No Contratada */
.eu-access-gate {
  background: #ffffff;
  border: 2px dashed #f59e0b;
  border-radius: 18px;
  padding: 32px;
  text-align: center;
  margin: 20px 0;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.08);
}

.eu-access-gate-icon {
  font-size: 44px;
  margin-bottom: 12px;
}

.eu-access-gate h3 {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 10px;
}

.eu-access-gate p {
  font-size: 14px;
  color: #475569;
  max-width: 540px;
  margin: 0 auto 20px;
  line-height: 1.6;
}
