/* ============================================================
   LexOS — auth.css
   Estilos específicos de autenticación, landing y onboarding
   ============================================================ */

/* ── Landing page ────────────────────────────────────────────── */
.landing-page {
  min-height: 100vh;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse at 15% 50%, rgba(99,102,241,.12) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 20%, rgba(99,102,241,.08) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 90%, rgba(16,185,129,.05) 0%, transparent 50%);
  display: flex;
  flex-direction: column;
}

.landing-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 48px;
  border-bottom: 1px solid var(--border);
}
.landing-nav .nav-brand {
  display: flex; align-items: center; gap: 10px;
}
.landing-nav .nav-brand .logo-icon {
  width: 36px; height: 36px;
  background: var(--accent); border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: .9rem; color: #fff;
}
.landing-nav .nav-brand .brand-text {
  font-weight: 800; font-size: 1.15rem; color: var(--text);
}
.landing-nav .nav-actions {
  display: flex; gap: 12px; align-items: center;
}

.landing-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  text-align: center;
}
.landing-hero .hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent-soft); border: 1px solid var(--accent-glow);
  color: var(--accent); font-size: .72rem; font-weight: 600;
  padding: 5px 14px; border-radius: 20px;
  margin-bottom: 24px; letter-spacing: .5px; text-transform: uppercase;
}
.landing-hero h1 {
  font-size: 3rem; font-weight: 800;
  color: var(--text); line-height: 1.15;
  letter-spacing: -1.5px; max-width: 640px;
  margin-bottom: 16px;
}
.landing-hero h1 .accent { color: var(--accent); }
.landing-hero p.sub {
  font-size: 1.05rem; color: var(--text-2);
  max-width: 500px; line-height: 1.7;
  margin-bottom: 36px;
}

.discover-form {
  display: flex; gap: 0;
  max-width: 460px; width: 100%;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.discover-form:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft), var(--shadow);
}
.discover-form input {
  flex: 1; background: none; border: none; outline: none;
  color: var(--text); font-size: .9rem; padding: 14px 18px;
}
.discover-form input::placeholder { color: var(--text-3); }
.discover-form button {
  background: var(--accent); color: #fff;
  border: none; padding: 0 22px;
  font-size: .85rem; font-weight: 700;
  cursor: pointer; white-space: nowrap;
  transition: background var(--transition);
}
.discover-form button:hover { background: var(--accent-hover); }

.discover-hint {
  margin-top: 12px; font-size: .75rem; color: var(--text-3);
}
.discover-result {
  margin-top: 16px; max-width: 460px; width: 100%;
}

/* Tenant card en discovery */
.tenant-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-3); border: 1px solid var(--accent-glow);
  border-radius: var(--radius); padding: 14px 16px;
  margin-bottom: 8px; cursor: pointer;
  transition: background var(--transition);
}
.tenant-card:hover { background: var(--bg-4); }
.tenant-card .tc-icon {
  width: 38px; height: 38px; border-radius: 8px;
  background: var(--accent); display: flex; align-items: center;
  justify-content: center; font-weight: 800; color: #fff; flex-shrink: 0;
}
.tenant-card .tc-name { font-weight: 600; font-size: .88rem; }
.tenant-card .tc-sub  { font-size: .72rem; color: var(--text-3); }
.tenant-card .tc-arrow { margin-left: auto; color: var(--text-3); }

/* Feature grid */
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px; max-width: 960px; width: 100%;
  margin: 48px auto 0; padding: 0 24px;
}
.feature-item {
  background: var(--bg-3); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
  transition: border-color var(--transition);
}
.feature-item:hover { border-color: var(--border-light); }
.feature-icon { font-size: 1.5rem; margin-bottom: 10px; }
.feature-title { font-weight: 600; font-size: .88rem; margin-bottom: 6px; }
.feature-desc  { font-size: .78rem; color: var(--text-3); line-height: 1.6; }

/* ── Auth card (login, forgot, reset) ────────────────────────── */
.auth-split {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 768px) {
  .auth-split { grid-template-columns: 1fr; }
  .auth-split .auth-left { display: none; }
}

.auth-left {
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 48px;
  background-image:
    radial-gradient(ellipse at 30% 40%, rgba(99,102,241,.15) 0%, transparent 60%);
}
.auth-left .al-logo {
  display: flex; align-items: center; gap: 12px; margin-bottom: 48px;
}
.auth-left .al-logo .logo-icon {
  width: 48px; height: 48px; border-radius: 10px;
  background: var(--accent); display: flex; align-items: center;
  justify-content: center; font-weight: 800; font-size: 1.1rem; color: #fff;
}
.auth-left h2 { font-size: 1.4rem; font-weight: 700; margin-bottom: 12px; }
.auth-left p  { font-size: .88rem; color: var(--text-2); line-height: 1.7; max-width: 340px; }

.auth-testimonial {
  margin-top: 40px;
  background: var(--bg-3); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
  max-width: 360px;
}
.auth-testimonial .quote {
  font-size: .85rem; color: var(--text-2); line-height: 1.7;
  font-style: italic; margin-bottom: 12px;
}
.auth-testimonial .author {
  font-size: .75rem; color: var(--text-3); font-weight: 600;
}

.auth-right {
  display: flex; align-items: center; justify-content: center;
  padding: 48px 40px;
  background: var(--bg);
}
.auth-right .ar-inner {
  width: 100%; max-width: 400px;
}
.ar-inner .ar-header {
  margin-bottom: 28px;
}
.ar-inner .ar-header h1 {
  font-size: 1.5rem; font-weight: 800; color: var(--text);
  letter-spacing: -.5px; margin-bottom: 6px;
}
.ar-inner .ar-header p {
  font-size: .83rem; color: var(--text-3); line-height: 1.6;
}

/* Input with icon */
.input-group {
  position: relative;
}
.input-group .input-icon {
  position: absolute; left: 12px; top: 50%;
  transform: translateY(-50%); color: var(--text-3);
  pointer-events: none;
}
.input-group .form-control { padding-left: 38px; }
.input-group .input-toggle {
  position: absolute; right: 12px; top: 50%;
  transform: translateY(-50%); cursor: pointer;
  color: var(--text-3); background: none; border: none;
  padding: 2px;
}
.input-group .input-toggle:hover { color: var(--text); }

/* Remember me & forgot */
.login-meta {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 20px;
}
.checkbox-label {
  display: flex; align-items: center; gap: 8px;
  font-size: .8rem; color: var(--text-2); cursor: pointer;
  user-select: none;
}
.checkbox-label input[type="checkbox"] {
  width: 15px; height: 15px; accent-color: var(--accent);
}

/* ── Register tenant ─────────────────────────────────────────── */
.plan-cards {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
  margin-bottom: 4px;
}
.plan-card {
  border: 2px solid var(--border);
  border-radius: var(--radius); padding: 16px;
  cursor: pointer; position: relative;
  transition: border-color var(--transition), background var(--transition);
}
.plan-card:hover { border-color: var(--border-light); background: var(--bg-4); }
.plan-card input[type="radio"] {
  position: absolute; opacity: 0; pointer-events: none;
}
.plan-card.selected {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.plan-card .plan-name  { font-weight: 700; font-size: .9rem; }
.plan-card .plan-price { font-size: .8rem; color: var(--text-3); margin-top: 4px; }
.plan-card .plan-badge {
  position: absolute; top: -8px; right: 10px;
  background: var(--accent); color: #fff;
  font-size: .6rem; font-weight: 700; padding: 2px 8px;
  border-radius: 10px; text-transform: uppercase; letter-spacing: .5px;
}

.tipos-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
}
.tipo-check {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg-4); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 8px 12px;
  cursor: pointer; font-size: .8rem; font-weight: 500;
  transition: all var(--transition);
}
.tipo-check input[type="checkbox"] { accent-color: var(--accent); }
.tipo-check:has(input:checked) {
  border-color: var(--accent); background: var(--accent-soft); color: var(--accent);
}

/* Password strength */
.pwd-strength { margin-top: 6px; }
.pwd-bar {
  height: 3px; border-radius: 2px; background: var(--border);
  overflow: hidden; margin-bottom: 4px;
}
.pwd-bar-fill { height: 100%; border-radius: 2px; transition: all .3s; }
.pwd-bar-fill.w-0  { width: 0;    background: var(--danger); }
.pwd-bar-fill.w-25 { width: 25%;  background: var(--danger); }
.pwd-bar-fill.w-50 { width: 50%;  background: var(--warning); }
.pwd-bar-fill.w-75 { width: 75%;  background: var(--info); }
.pwd-bar-fill.w-100{ width: 100%; background: var(--success); }
.pwd-label { font-size: .68rem; color: var(--text-3); }

/* ── Onboarding (misceláneo compartido) ──────────────────────── */
.ob-progress-bar {
  height: 4px; background: var(--border); border-radius: 2px; overflow: hidden;
}
.ob-progress-fill {
  height: 100%; background: var(--accent); border-radius: 2px;
  transition: width .5s cubic-bezier(.4, 0, .2, 1);
}

/* ── Animaciones de ilustraciones ────────────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-8px); }
}
@keyframes pulse-ring {
  0%   { transform: scale(1);    opacity: .6; }
  100% { transform: scale(1.35); opacity: 0; }
}
@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes draw-check {
  from { stroke-dashoffset: 50; }
  to   { stroke-dashoffset: 0; }
}
@keyframes slide-up {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}
