/* ─────────────────────────────────────────────────────────────────────────
   admon.cloud — landing (despliegue de aplicaciones).
   Estilos y animaciones ORIGINALES, inspirados en patrones de producto comunes
   (pills flotantes, lista de deploys git-driven, red global). Self-contained:
   sin CDN ni assets externos (regla del repo). Todo scoped a .admon-landing.
   ──────────────────────────────────────────────────────────────────────── */

.admon-landing {
  --al-bg: #ffffff;
  --al-fg: #0a0a0a;
  --al-muted: #5b6470;
  --al-line: #e8eaed;
  --al-card: #ffffff;
  --al-card-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px rgba(16, 24, 40, .06);
  --al-ink: #0a0a0a;
  --al-on-ink: #ffffff;
  --al-radius: 16px;

  --al-blue: #2563eb;
  --al-purple: #7c3aed;
  --al-green: #16a34a;
  --al-pink: #db2777;
  --al-teal: #0d9488;
  --al-orange: #ea580c;
  --al-red: #dc2626;

  margin: 0;
  background: var(--al-bg);
  color: var(--al-fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

.admon-landing * { box-sizing: border-box; }

/* ── Nav (solo logo + Sign In) ───────────────────────────────────────────── */
.al-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1120px;
  margin: 0 auto;
  padding: 20px 24px;
}
.al-brand { display: inline-flex; align-items: center; }
.al-logo { height: 30px; width: auto; display: block; }
.al-logo-dark { display: none; }

/* ── Botones ─────────────────────────────────────────────────────────────── */
.al-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform .08s ease, box-shadow .15s ease, background .15s ease;
  cursor: pointer;
}
.al-btn:active { transform: translateY(1px); }
.al-btn-primary { background: var(--al-ink); color: var(--al-on-ink); }
.al-btn-primary:hover { box-shadow: 0 6px 18px rgba(10, 10, 10, .22); }
.al-btn-ghost { background: transparent; color: var(--al-fg); border-color: var(--al-line); }
.al-btn-ghost:hover { background: rgba(10, 10, 10, .04); }

/* ── Main wrapper ────────────────────────────────────────────────────────── */
.al-main { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* ── Hero ────────────────────────────────────────────────────────────────── */
.al-hero { text-align: center; padding: 24px 0 56px; }
.al-hero h1 {
  font-size: clamp(34px, 6vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 800;
  margin: 8px 0 0;
}
.al-hero .al-sub {
  max-width: 640px;
  margin: 18px auto 0;
  font-size: clamp(16px, 2.4vw, 19px);
  color: var(--al-muted);
}
.al-cta { display: flex; gap: 12px; justify-content: center; margin-top: 28px; flex-wrap: wrap; }
.al-hero-powered { margin-top: 22px; font-size: 13px; color: var(--al-muted); }
.al-hero-powered strong { color: var(--al-fg); }

/* ── Stage: toolbar flotante + pills ─────────────────────────────────────── */
.al-stage {
  position: relative;
  height: 300px;
  margin: 0 auto 8px;
  max-width: 760px;
}
@media (max-width: 640px) { .al-stage { height: 230px; } }

.al-toolbar {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  background: #0d0d0f;
  border-radius: 9999px;
  box-shadow: 0 18px 50px rgba(10, 10, 10, .35);
  z-index: 3;
  animation: alBob 7s ease-in-out infinite;
}
.al-tool {
  width: 38px; height: 38px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; background: transparent; color: #cfd3da; border-radius: 10px;
  cursor: default;
}
.al-tool:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.al-tool svg { width: 20px; height: 20px; }
.al-tool-dot { position: relative; }
.al-tool-dot::after {
  content: ""; position: absolute; top: 7px; right: 7px;
  width: 7px; height: 7px; border-radius: 50%; background: var(--al-blue);
  box-shadow: 0 0 0 2px #0d0d0f; animation: alPulse 2s ease-in-out infinite;
}
.al-sep { width: 1px; height: 22px; background: rgba(255, 255, 255, .14); margin: 0 4px; }
.al-avatars { display: inline-flex; padding: 0 4px; }
.al-avatars span {
  width: 26px; height: 26px; border-radius: 50%; margin-left: -8px;
  border: 2px solid #0d0d0f; display: inline-block;
}
.al-avatars span:first-child { margin-left: 0; }
.al-av1 { background: linear-gradient(135deg, #f59e0b, #ef4444); }
.al-av2 { background: linear-gradient(135deg, #6366f1, #db2777); }
.al-av3 { background: linear-gradient(135deg, #06b6d4, #22c55e); }

/* pills */
.al-pill {
  position: absolute;
  left: 50%; top: 50%;
  margin-left: var(--x);
  margin-top: var(--y);
  transform: translate(-50%, -50%);
  padding: 8px 14px;
  border-radius: 9999px;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(10, 10, 10, .18);
  animation: alFloat 6s ease-in-out infinite;
  animation-delay: var(--d);
  z-index: 2;
}
.al-pill-blue { background: var(--al-blue); }
.al-pill-purple { background: var(--al-purple); }
.al-pill-green { background: var(--al-green); }
.al-pill-pink { background: var(--al-pink); }
.al-pill-teal { background: var(--al-teal); }
.al-pill-orange { background: var(--al-orange); }
.al-pill-red { background: var(--al-red); }
@media (max-width: 640px) { .al-pill { font-size: 11px; padding: 6px 10px; } }

@keyframes alFloat {
  0%, 100% { transform: translate(-50%, calc(-50% - 6px)); }
  50%      { transform: translate(-50%, calc(-50% + 6px)); }
}
@keyframes alBob {
  0%, 100% { transform: translate(-50%, -52%); }
  50%      { transform: translate(-50%, -48%); }
}
@keyframes alPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: .55; transform: scale(.8); }
}

/* ── Secciones ───────────────────────────────────────────────────────────── */
.al-section { padding: 56px 0; border-top: 1px solid var(--al-line); }
.al-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--al-muted);
  margin: 0 0 12px;
}
.al-eyebrow svg { width: 16px; height: 16px; }
.al-title {
  font-size: clamp(24px, 4vw, 36px); letter-spacing: -0.02em; font-weight: 800;
  margin: 0; max-width: 620px;
}
.al-text { color: var(--al-muted); font-size: 17px; max-width: 560px; margin: 14px 0 0; }
.al-section-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center;
}
@media (max-width: 860px) { .al-section-grid { grid-template-columns: 1fr; gap: 28px; } }

/* feature cards 3-up */
.al-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 12px; }
@media (max-width: 860px) { .al-features { grid-template-columns: 1fr; } }
.al-card {
  background: var(--al-card);
  border: 1px solid var(--al-line);
  border-radius: var(--al-radius);
  padding: 22px;
  box-shadow: var(--al-card-shadow);
}
.al-card h3 { margin: 0 0 6px; font-size: 17px; font-weight: 700; }
.al-card p { margin: 0; color: var(--al-muted); font-size: 15px; }

/* ── Deploys (git-driven) ────────────────────────────────────────────────── */
.al-deploys {
  background: var(--al-card);
  border: 1px solid var(--al-line);
  border-radius: var(--al-radius);
  box-shadow: var(--al-card-shadow);
  overflow: hidden;
}
.al-deploy-row {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1.1fr;
  gap: 12px;
  align-items: center;
  padding: 18px 20px;
  border-top: 1px solid var(--al-line);
}
.al-deploy-row:first-child { border-top: 0; }
.al-deploy-row.is-muted { opacity: .5; }
.al-deploy-host { font-weight: 700; font-size: 15px; }
.al-deploy-env { font-size: 13px; color: var(--al-muted); }
.al-deploy-status { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; }
.al-deploy-time { font-size: 13px; color: var(--al-muted); }
.al-deploy-git { font-size: 13px; color: var(--al-muted); display: flex; flex-direction: column; gap: 2px; }
.al-deploy-git code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

.al-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.al-dot-ready { background: var(--al-green); }
.al-dot-build { background: var(--al-orange); animation: alPulse 1.4s ease-in-out infinite; }
.al-dot-queue { background: #c2c7cf; }

.al-spinner {
  width: 13px; height: 13px; border-radius: 50%;
  border: 2px solid rgba(234, 88, 12, .25); border-top-color: var(--al-orange);
  display: inline-block; animation: alSpin .8s linear infinite;
}
@keyframes alSpin { to { transform: rotate(360deg); } }

/* ── Red global (globo) ──────────────────────────────────────────────────── */
.al-globe { width: 100%; max-width: 460px; height: auto; display: block; margin: 0 auto; }
.al-globe .al-grid { stroke: var(--al-line); stroke-width: 1; fill: none; }
.al-globe .al-node { fill: var(--al-fg); }
.al-globe .al-ring {
  fill: none; stroke: var(--al-blue); stroke-width: 2; opacity: 0;
  transform-origin: center; transform-box: fill-box;
  animation: alPing 3s ease-out infinite;
}
.al-globe .al-ring.d1 { animation-delay: .6s; }
.al-globe .al-ring.d2 { animation-delay: 1.4s; }
.al-globe .al-ring.d3 { animation-delay: 2.2s; }
.al-globe .al-signal { stroke: var(--al-blue); stroke-width: 2; fill: none; stroke-linecap: round;
  stroke-dasharray: 90; stroke-dashoffset: 90; animation: alDraw 3s ease-in-out infinite; }
.al-globe .al-signal.s2 { animation-delay: 1s; }
.al-globe .al-signal.s3 { animation-delay: 2s; }
@keyframes alPing { 0% { opacity: .7; transform: scale(.3); } 80%, 100% { opacity: 0; transform: scale(2.4); } }
@keyframes alDraw {
  0% { stroke-dashoffset: 90; opacity: 0; }
  30% { opacity: 1; }
  60% { stroke-dashoffset: 0; opacity: 1; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}

/* ── Powered-by band ─────────────────────────────────────────────────────── */
.al-powered-band {
  text-align: center; padding: 56px 0; border-top: 1px solid var(--al-line);
}
.al-powered-band .al-pb-title { font-size: 13px; font-weight: 700; color: var(--al-muted); letter-spacing: .04em; text-transform: uppercase; margin: 0 0 10px; }
.al-powered-band .al-pb-main { font-size: clamp(20px, 3.5vw, 28px); font-weight: 800; letter-spacing: -0.01em; margin: 0; }
.al-powered-band .al-pb-sub { color: var(--al-muted); margin: 8px 0 0; font-size: 15px; }

/* ── Footer (mínimo, sin ligas) ──────────────────────────────────────────── */
.al-footer {
  border-top: 1px solid var(--al-line);
  text-align: center;
  padding: 32px 24px 44px;
  color: var(--al-muted);
  font-size: 14px;
}
.al-footer p { margin: 4px 0; }
.al-footer .al-footer-powered strong { color: var(--al-fg); }

/* ── Login (auth) con la estética del landing ────────────────────────────── */
.admon-landing.al-auth-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.al-auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--al-card);
  border: 1px solid var(--al-line);
  border-radius: var(--al-radius);
  box-shadow: var(--al-card-shadow);
  padding: 32px 28px;
}
.al-auth-logo { display: flex; justify-content: center; margin-bottom: 30px; }
/* El logo se ENCAJA en una caja conservando su aspecto (width/height auto), nunca se
   estira: clave para logos de tenant anchos (p. ej. NEWTON207), que con una altura
   fija + max-width:100% se deformaban. El SVG oscuro de StackFire es cuadrado y queda
   ~125×125; un logo ancho de tenant se acota por el ancho (150px) y baja de alto solo. */
.al-auth-logo img { max-height: 125px; max-width: 150px; width: auto; height: auto; }
.al-auth-label { display: block; font-size: 14px; font-weight: 600; margin: 0 0 6px; }
.al-auth-input {
  width: 100%;
  padding: 11px 13px;
  font-size: 15px;
  border: 1px solid var(--al-line);
  border-radius: 10px;
  background: var(--al-bg);
  color: var(--al-fg);
  margin-bottom: 16px;
  outline: none;
  transition: border-color .12s ease, box-shadow .12s ease;
}
.al-auth-input:focus { border-color: var(--al-ink); box-shadow: 0 0 0 3px rgba(10, 10, 10, .08); }
.al-auth-submit { width: 100%; margin-top: 4px; }
.al-auth-foot { text-align: center; margin-top: 16px; }
.al-auth-link { color: var(--al-fg); font-weight: 600; font-size: 14px; text-decoration: none; }
.al-auth-link:hover { text-decoration: underline; }
.al-auth-error {
  background: #fee2e2; color: #991b1b; border: 1px solid #fecaca;
  border-radius: 10px; padding: 10px 12px; font-size: 14px; margin-bottom: 16px;
}

/* ── Dark (auto, por preferencia del SO) ─────────────────────────────────── */
@media (prefers-color-scheme: dark) {
  .admon-landing {
    --al-bg: #0a0a0b;
    --al-fg: #f4f5f7;
    --al-muted: #9aa3af;
    --al-line: #1f2125;
    --al-card: #121316;
    --al-card-shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 10px 30px rgba(0, 0, 0, .5);
    --al-ink: #ffffff;
    --al-on-ink: #0a0a0b;
  }
  .admon-landing .al-logo-light { display: none; }
  .admon-landing .al-logo-dark { display: block; }
  .al-btn-ghost:hover { background: rgba(255, 255, 255, .06); }
}

/* Respeta reduce-motion */
@media (prefers-reduced-motion: reduce) {
  .admon-landing * { animation: none !important; }
}
