/* login.agentistics.com.br — tela dividida (visual aprovado do mockup login-hero).
   Tokens iguais aos de services/cloud/src/web/page.css. Sem webfont (a CSP real não deixa). */
:root {
  --bg-base: #0a0a0f;
  --bg-card: #16161f;
  --bg-elevated: #1e1e2e;
  --bg-elevated-hover: #262638;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text-primary: rgba(255, 255, 255, 0.92);
  --text-muted: rgba(255, 255, 255, 0.64);
  --accent-text: #f59e0b;
  --accent-fill: #d97706;
  --accent-fill-hover: #f59e0b;
  --on-accent: #0a0a0f;
  --accent-green: #10b981;
  --accent-red: #f87171;
  --danger-bg: rgba(239, 68, 68, 0.1);
  --danger-border: rgba(239, 68, 68, 0.35);
  --warning-bg: rgba(245, 158, 11, 0.1);
  --brand-mark: #fd8924;
  --grid-line: rgba(255, 255, 255, 0.035);
  --hero-bg: radial-gradient(120% 90% at 60% 45%, #15131c 0%, #0b0a10 55%, #060609 100%);
  --hero-ink: rgba(255, 255, 255, 0.94);
  --hero-muted: rgba(255, 255, 255, 0.62);
  --sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg-base: #f4f4f7;
  --bg-card: #ffffff;
  --bg-elevated: #f0f1f5;
  --bg-elevated-hover: #e6e7ee;
  --border: rgba(0, 0, 0, 0.1);
  --border-strong: rgba(0, 0, 0, 0.16);
  --text-primary: #18181b;
  --text-muted: rgba(24, 24, 27, 0.72);
  --accent-text: #c2410c;
  --accent-fill: #c2410c;
  --accent-fill-hover: #9a3412;
  --on-accent: #ffffff;
  --accent-green: #047857;
  --accent-red: #b91c1c;
  --danger-bg: rgba(185, 28, 28, 0.06);
  --danger-border: rgba(185, 28, 28, 0.3);
  --warning-bg: rgba(194, 65, 12, 0.07);
  --brand-mark: #c2410c;
  --grid-line: rgba(0, 0, 0, 0.045);
  --hero-bg: radial-gradient(120% 90% at 60% 45%, #fbfaf7 0%, #f1efea 60%, #e8e5de 100%);
  --hero-ink: #1c1917;
  --hero-muted: rgba(28, 25, 23, 0.7);
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body {
  min-height: 100dvh;
  background: var(--bg-base);
  color: var(--text-primary);
  font: 400 1rem/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: 0.5; }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
strong { font-weight: 600; color: var(--text-primary); }
html[data-lang="pt"] [data-l="en"], html[data-lang="en"] [data-l="pt"] { display: none; }

/* ------------------------------------------------------------ split */
.split {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 58fr) minmax(400px, 42fr);
  min-height: 100dvh;
}

/* ------------------------------------------------------------ hero (esquerda) */
.hero {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100dvh;
  overflow: hidden;
  background: var(--hero-bg);
  color: var(--hero-ink);
  isolation: isolate;
}
.hero canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}
.hero-brand {
  position: absolute;
  top: 1.5rem;
  left: 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  z-index: 1;
}
.hero-brand svg { width: 1.9rem; height: 1.9rem; color: var(--brand-mark); }
.hero-brand small { font-size: inherit; font-weight: 400; color: var(--hero-muted); }
.hero-copy {
  position: absolute;
  left: 1.75rem;
  right: 1.75rem;
  bottom: 1.75rem;
  z-index: 1;
  pointer-events: none;
}
.hero-copy h2 {
  margin: 0;
  max-width: 21ch;
  font-size: clamp(1.6rem, 2.6vw, 2.5rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
  font-weight: 700;
}
.hero-copy h2 em { font-style: normal; color: var(--brand-mark); }
.beats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}
.beats li {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.7rem;
  border: 1px solid color-mix(in srgb, var(--hero-ink) 14%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--hero-ink) 4%, transparent);
  font: 500 0.78rem/1.2 var(--mono);
  color: var(--hero-muted);
  transition: color 0.4s, border-color 0.4s, background 0.4s;
}
.beats li::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.5;
}
.beats li.on {
  color: var(--hero-ink);
  border-color: color-mix(in srgb, var(--brand-mark) 60%, transparent);
  background: color-mix(in srgb, var(--brand-mark) 12%, transparent);
}
.beats li.on::before { background: var(--brand-mark); opacity: 1; }

/* ------------------------------------------------------------ lado do login (direita) */
.side {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background-color: var(--bg-base);
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 48px 48px;
  border-left: 1px solid var(--border);
}
.top {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
}
.top .brand { display: none; margin-right: auto; align-items: center; gap: 0.5rem; font-weight: 600; }
.top .brand svg { width: 1.6rem; height: 1.6rem; color: var(--brand-mark); }
.top .brand small { font-size: inherit; font-weight: 400; color: var(--text-muted); }
.switch {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
}
.switch button {
  min-width: 2.6rem;
  min-height: 2.25rem;
  padding: 0 0.6rem;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.8125rem;
  font-weight: 600;
}
.switch button[aria-pressed="true"] { background: var(--bg-elevated); color: var(--text-primary); }
.icon-btn {
  display: grid;
  place-items: center;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
  color: var(--text-muted);
}
.icon-btn svg { width: 1.15rem; height: 1.15rem; }

main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem 2rem;
}
.card {
  width: 100%;
  max-width: 26.5rem;
  display: grid;
  gap: 1rem;
}
.badge {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent-text) 16%, transparent);
  color: var(--accent-text);
}
.badge.danger { background: var(--danger-bg); color: var(--accent-red); }
.badge.busy { animation: breathe 2.4s ease-in-out infinite; }
.badge svg { width: 1.4rem; height: 1.4rem; }
@keyframes breathe { 50% { box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent-text) 8%, transparent); } }
h1 {
  margin: 0;
  font-size: clamp(1.45rem, 2.1vw, 1.75rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 700;
}
.lead { margin: -0.35rem 0 0; color: var(--text-muted); }
.lead em, .small em { font-style: italic; }
.providers { display: grid; gap: 0.6rem; margin-top: 0.25rem; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  min-height: 3rem;
  padding: 0 1rem;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--bg-elevated);
  color: var(--text-primary);
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.btn:hover:not(:disabled) { background: var(--bg-elevated-hover); border-color: color-mix(in srgb, var(--brand-mark) 45%, var(--border-strong)); }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn svg { width: 1.15rem; height: 1.15rem; flex: none; }
.btn-primary { background: var(--accent-fill); border-color: transparent; color: var(--on-accent); }
.btn-primary:hover:not(:disabled) { background: var(--accent-fill-hover); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-muted); min-height: 2.5rem; }
.divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-muted);
  font-size: 0.8rem;
}
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.field { display: grid; gap: 0.4rem; }
.field label { font-size: 0.875rem; font-weight: 600; }
.field > input {
  min-height: 3rem;
  padding: 0 0.9rem;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--bg-card);
}
.note {
  display: flex;
  gap: 0.6rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
  font-size: 0.9rem;
}
.note svg { width: 1.1rem; height: 1.1rem; flex: none; margin-top: 0.15rem; }
.note.danger { border-color: var(--danger-border); background: var(--danger-bg); }
.note.danger svg { color: var(--accent-red); }
.note.warning { background: var(--warning-bg); }
.small { margin: 0; color: var(--text-muted); font-size: 0.85rem; }
.privacy {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  margin-top: 0.4rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.85rem;
}
.privacy svg { width: 1.1rem; height: 1.1rem; flex: none; color: var(--accent-green); margin-top: 0.1rem; }
.privacy strong { display: block; color: var(--text-primary); }
footer {
  padding: 0 1.5rem 1.25rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* ------------------------------------------------------------ tablet / mobile */
@media (max-width: 1080px) {
  .split { grid-template-columns: minmax(0, 52fr) minmax(380px, 48fr); }
  .hero-copy h2 { font-size: 1.6rem; }
}
@media (max-width: 768px) {
  .split { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .hero { position: relative; height: 176px; }
  .hero-brand { top: 1rem; left: 1rem; }
  .hero-copy { left: 1rem; right: 50%; bottom: 0.9rem; }
  .hero-copy h2 { font-size: 1.05rem; line-height: 1.15; max-width: none; }
  .hero::after { height: 0; }
  .beats { display: none; }
  .side { border-left: 0; border-top: 1px solid var(--border); }
  .top { position: absolute; top: 0.6rem; right: 0.6rem; padding: 0; gap: 0.4rem; z-index: 2; }
  .switch button { min-width: 2.3rem; min-height: 2rem; }
  .icon-btn { width: 2.4rem; height: 2.4rem; }
  .hero-brand small { display: none; }
  main { align-items: flex-start; padding: 1.5rem 1rem 1.5rem; }
  footer { padding: 0 1rem 4rem; }
}

/* esmaecido sob o texto do hero (legibilidade) e medidor ?fps */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 42%;
  background: linear-gradient(to bottom, transparent, var(--hero-fade));
  pointer-events: none;
}
:root { --hero-fade: rgba(6, 6, 9, 0.92); }
:root[data-theme="light"] { --hero-fade: rgba(232, 229, 222, 0.94); }
.fps {
  position: absolute;
  top: 1.6rem;
  right: 1rem;
  z-index: 2;
  font: 600 0.75rem var(--mono);
  color: var(--hero-muted);
}
@media (prefers-reduced-motion: reduce) {
  .badge.busy { animation: none; }
  .btn, .beats li { transition: none; }
}

/* ------------------------------------------------------------ lista de espera */
.field > input[type="date"] { color-scheme: inherit; }
.field .hint { margin: 0; color: var(--text-muted); font-size: 0.8rem; }
.check {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  padding: 0.85rem 0.9rem;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--bg-card);
  font-size: 0.9rem;
  cursor: pointer;
}
.check input { width: 1.25rem; height: 1.25rem; margin: 0.1rem 0 0; flex: none; accent-color: var(--accent-fill); }
.who { margin: 0; padding: 0.7rem 0.9rem; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-card); font-size: 0.9rem; overflow-wrap: anywhere; }
.who strong { display: block; }
.links { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; font-size: 0.85rem; }
.links a, .links button { color: var(--text-muted); background: none; border: 0; padding: 0.35rem 0; text-decoration: underline; font-size: inherit; }
a.btn { cursor: pointer; }
.btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; }
.soon { margin-left: 0.35rem; padding: 0.05rem 0.45rem; border-radius: 999px; background: var(--bg-card); border: 1px solid var(--border-strong); font: 600 0.7rem var(--mono); color: var(--text-muted); }
.prose { max-width: 40rem; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; display: grid; gap: 1rem; }
.prose h2 { margin: 1rem 0 0; font-size: 1.1rem; }
.prose ul { margin: 0; padding-left: 1.2rem; color: var(--text-muted); }
.prose a { color: var(--accent-text); }
.prose table { border-collapse: collapse; width: 100%; font-size: 0.9rem; }
.prose th, .prose td { text-align: left; padding: 0.45rem 0.6rem; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th { color: var(--text-muted); font-weight: 600; }
.prose .top { padding: 0; }
footer a { color: inherit; }
