/* Plantão — Alasca UI (mesmos tokens da Central, do Renomeador e da Bancada) */
:root {
  --bg: #0a0c11;
  --elev: #0f131a;
  --surface: #151a22;
  --surface-2: #1b212b;
  --surface-3: #232b37;
  --border: #262e3a;
  --border-strong: #36404f;
  --ink: #f4f6fa;
  --ink-2: #c7cedb;
  --muted: #9aa7ba;
  --brand: #14a8f5;
  --brand-2: #5cc4ff;
  --green: #2bd47f;
  --red: #ff5c63;
  --amber: #ffb648;
  --c-central: #14a8f5;
  --c-renomeador: #ffb648;
  --c-bancada: #2bd47f;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --sombra-marca: 0 10px 30px -6px rgba(20, 168, 245, 0.5);
  --sombra-card: 0 2px 8px -2px rgba(0, 0, 0, 0.4);
  --sombra-alta: 0 18px 50px -12px rgba(0, 0, 0, 0.7);
  --gutter: 16px;
  --largura: 1120px;
  --medida: 68ch;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--ink);
  font-family: Satoshi, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
}
/* o brilho da casa, só no topo, discreto */
body::before {
  content: "";
  position: absolute;
  inset: -240px 0 auto 0;
  height: 620px;
  background: radial-gradient(closest-side at 50% 40%, rgba(20, 168, 245, 0.16), transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* superfícies do navegador que também carregam o design */
::selection { background: rgba(20, 168, 245, 0.35); color: var(--ink); }
:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 2px; border-radius: 6px; }
textarea, input { caret-color: var(--brand-2); }
* { scrollbar-color: var(--border-strong) transparent; scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 999px; border: 3px solid var(--bg); }
::-webkit-scrollbar-track { background: transparent; }

a { color: var(--brand-2); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: rgba(92, 196, 255, 0.45); }
a:hover { text-decoration-color: currentColor; }
button { font: inherit; color: inherit; cursor: pointer; touch-action: manipulation; }
button:disabled { cursor: not-allowed; opacity: 0.45; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.pular { position: absolute; left: var(--gutter); top: -60px; background: var(--brand); color: #fff; padding: 8px 12px; border-radius: 10px; font-weight: 700; z-index: 50; }
.pular:focus { top: 12px; }
.tnum { font-variant-numeric: tabular-nums; }
.ico { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.ponto { display: inline-block; width: 8px; height: 8px; border-radius: 999px; background: var(--muted); flex: none; }
.p-central { background: var(--c-central); }
.p-renomeador { background: var(--c-renomeador); }
.p-bancada { background: var(--c-bancada); }

/* ---------- topo ---------- */
.topo {
  position: relative;
  z-index: 1;
  max-width: var(--largura);
  margin: 0 auto;
  padding: calc(env(safe-area-inset-top) + 18px) var(--gutter) 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.marca { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); min-width: 0; }
.marca img { height: 22px; width: auto; display: block; }
.marca-sep { width: 1px; height: 20px; background: var(--border-strong); }
.marca-nome { font-weight: 900; letter-spacing: -0.02em; font-size: 17px; }
.marca-sub { color: var(--muted); font-size: 13px; font-weight: 500; }
.atalhos { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.atalhos a {
  display: inline-flex; align-items: center; gap: 7px;
  height: 36px; padding: 0 12px 0 10px;
  border-radius: 10px; border: 1px solid var(--border); background: rgba(21, 26, 34, 0.7);
  color: var(--ink-2); font-size: 13px; font-weight: 700; text-decoration: none;
  transition: border-color 160ms, color 160ms, background 160ms;
}
.atalhos a .ico { width: 13px; height: 13px; color: var(--muted); transition: transform 200ms var(--ease), color 160ms; }
.atalhos a:hover { border-color: var(--border-strong); color: var(--ink); background: var(--surface-2); }
.atalhos a:hover .ico { transform: translate(1px, -1px); color: var(--ink); }

main { position: relative; z-index: 1; max-width: var(--largura); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- o balcão ---------- */
.balcao { padding: 64px 0 40px; max-width: 800px; }
.balcao h1 {
  margin: 0 0 22px;
  font-size: clamp(2.5rem, 6.4vw, 3.5rem);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1;
  text-wrap: balance;
}
.reticencias { color: var(--brand-2); }

.pergunta { margin: 0; }
.campo {
  position: relative;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 8px 8px 8px 22px;
  min-height: 66px;
  border-radius: 20px;
  background: var(--elev);
  border: 1px solid var(--border-strong);
  box-shadow: var(--sombra-card);
  transition: border-color 180ms, box-shadow 220ms var(--ease), background 180ms;
}
.campo:focus-within { border-color: var(--brand); background: var(--surface); box-shadow: 0 0 0 4px rgba(20, 168, 245, 0.16), var(--sombra-marca); }
.campo textarea {
  flex: 1;
  min-width: 0;
  resize: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.35;
  padding: 12px 0;
  max-height: 200px;
  outline: none;
}
.campo textarea::placeholder { color: var(--muted); font-weight: 400; }
.enviar {
  flex: none;
  width: 48px; height: 48px;
  border-radius: 14px;
  border: 0;
  background: var(--brand);
  color: #fff;
  display: grid; place-items: center;
  box-shadow: var(--sombra-marca);
  transition: transform 160ms var(--ease), background 160ms, box-shadow 160ms;
}
.enviar .ico { width: 20px; height: 20px; stroke-width: 2.4; }
.enviar:hover { background: #2bb3f8; }
.enviar:active { transform: scale(0.96); }
.enviar:disabled { box-shadow: none; }
.enviar.ocupado { background: var(--surface-3); box-shadow: none; }
.enviar.ocupado .ico { animation: girar 900ms linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }

.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.chips button, .segmento button {
  display: inline-flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 13px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(21, 26, 34, 0.6);
  color: var(--ink-2);
  font-size: 13px; font-weight: 700;
  transition: border-color 160ms, background 160ms, color 160ms;
}
.chips button:hover, .segmento button:hover { border-color: var(--border-strong); color: var(--ink); }
.chips button[aria-checked="true"], .segmento button[aria-selected="true"] {
  background: rgba(20, 168, 245, 0.12);
  border-color: rgba(20, 168, 245, 0.4);
  color: var(--brand-2);
}
.ajuda { margin: 12px 0 0; color: var(--muted); font-size: 14px; }

.exemplos { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.exemplos button {
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink-2);
  font-size: 14px; font-weight: 500;
  padding: 8px 12px 8px 10px;
  border-radius: 10px;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background 160ms, color 160ms, border-color 160ms;
}
.exemplos button::before { content: ""; width: 6px; height: 6px; border-radius: 999px; background: var(--border-strong); transition: background 160ms; }
.exemplos button:hover { background: var(--surface); border-color: var(--border); color: var(--ink); }
.exemplos button:hover::before { background: var(--brand); }

/* ---------- conversa ---------- */
.conversa { max-width: 800px; padding: 0 0 56px; display: flex; flex-direction: column; gap: 22px; }
.troca {
  scroll-margin-top: 16px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--elev);
  box-shadow: var(--sombra-card);
  padding: 22px 26px 18px;
  animation: subir 420ms var(--ease) both;
}
@media (prefers-reduced-motion: reduce) { .troca { animation: none; } }
@keyframes subir { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.troca-pergunta { margin: 0 0 14px; font-size: 19px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); text-wrap: pretty; }
.troca-estado { display: inline-flex; align-items: center; gap: 9px; color: var(--muted); font-size: 13px; font-weight: 600; margin: 0 0 8px; min-height: 20px; }
.troca-estado .ponto { width: 7px; height: 7px; animation: pulsar 1.1s ease-in-out infinite; }
@keyframes pulsar { 0%, 100% { opacity: 0.35; } 50% { opacity: 1; } }
.troca-resposta { font-size: 17px; line-height: 1.6; color: var(--ink-2); max-width: var(--medida); min-height: 1.6em; }
.troca-resposta p { margin: 0 0 12px; }
.troca-resposta strong { color: var(--ink); font-weight: 700; }
.troca-resposta ol, .troca-resposta ul { margin: 0 0 12px; padding-left: 1.4em; }
.troca-resposta li { margin: 4px 0; padding-left: 4px; }
.troca-resposta li::marker { color: var(--brand-2); font-weight: 700; }
.troca-resposta code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.92em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; color: var(--ink); }
.troca-resposta .cursor { display: inline-block; width: 2px; height: 1.05em; background: var(--brand-2); vertical-align: -0.15em; margin-left: 2px; animation: pulsar 0.9s steps(2, end) infinite; }
.troca-resposta.erro { color: var(--amber); }
.troca-pe {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px;
  margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border);
  font-size: 13px; color: var(--muted);
}
.troca-fonte { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.troca-fonte a { color: var(--ink-2); font-weight: 600; text-decoration-color: rgba(199, 206, 219, 0.35); }
.troca-fonte a:hover { color: var(--brand-2); }
.troca-slack { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); text-decoration: none; font-weight: 600; }
.troca-slack .ico { width: 14px; height: 14px; }
.troca-slack:hover { color: var(--ink); }
.troca-video { display: flex; align-items: center; gap: 12px; margin-top: 14px; padding: 10px 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); color: var(--ink-2); text-decoration: none; font-size: 14px; font-weight: 600; }
.troca-video:hover { border-color: var(--border-strong); color: var(--ink); }
.troca-video .play { width: 28px; height: 28px; border-radius: 8px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: none; }
.troca-video .play .ico { width: 12px; height: 12px; fill: currentColor; stroke: none; }
.troca-video .tnum { color: var(--muted); margin-left: auto; font-weight: 500; }

/* ---------- manual ---------- */
.manual { padding: 24px 0 64px; border-top: 1px solid var(--border); }
.manual-cab { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 32px 0 24px; }
.manual h2, .videos h2 { margin: 0; font-size: 30px; font-weight: 900; letter-spacing: -0.03em; line-height: 1.1; }
.segmento { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--elev); border: 1px solid var(--border); overflow-x: auto; scrollbar-width: none; }
.segmento::-webkit-scrollbar { display: none; }
.segmento button { border-color: transparent; background: transparent; height: 34px; white-space: nowrap; }
.segmento button[aria-selected="true"] { background: rgba(20, 168, 245, 0.14); border-color: rgba(20, 168, 245, 0.45); color: var(--brand-2); }

.manual-corpo { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 40px; align-items: start; }
.trilho { position: sticky; top: 20px; }
.trilho select { display: none; }
.trilho ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.trilho li { margin: 0; }
.trilho a {
  display: block;
  padding: 7px 14px;
  margin-left: -1px;
  border-left: 1px solid transparent;
  color: var(--muted);
  font-size: 14px; font-weight: 600;
  text-decoration: none;
  line-height: 1.3;
  transition: color 160ms, border-color 160ms;
}
.trilho a:hover { color: var(--ink); }
.trilho a.ativo { color: var(--brand-2); border-left-color: var(--brand); }

.texto { min-width: 0; max-width: var(--medida); font-size: 17px; line-height: 1.6; color: var(--ink-2); }
.texto h1 { margin: 0 0 6px; font-size: 22px; font-weight: 900; letter-spacing: -0.02em; color: var(--ink); }
.texto > p:first-of-type { color: var(--muted); }
.texto h2 { margin: 40px 0 12px; font-size: 22px; font-weight: 900; letter-spacing: -0.02em; color: var(--ink); scroll-margin-top: 20px; line-height: 1.2; }
.texto h2:first-of-type { margin-top: 26px; }
.texto h2 a { color: inherit; text-decoration: none; }
.texto h2 a:hover::after { content: " #"; color: var(--border-strong); font-weight: 500; }
.texto h2.alvo { animation: realcar 1600ms var(--ease); }
@keyframes realcar { 0% { color: var(--brand-2); } 100% { color: var(--ink); } }
.texto p { margin: 0 0 14px; }
.texto strong { color: var(--ink); font-weight: 700; }
.texto ol, .texto ul { margin: 0 0 14px; padding-left: 1.4em; }
.texto li { margin: 5px 0; padding-left: 4px; }
.texto li::marker { color: var(--brand-2); font-weight: 700; }
.texto code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.9em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; color: var(--ink); white-space: nowrap; }
.texto .carregando { color: var(--muted); }

/* ---------- vídeos ---------- */
.videos { padding: 0 0 72px; }
.videos-cab { margin: 0 0 18px; display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.videos-cab p { margin: 0; color: var(--muted); font-size: 14px; }
.videos-lista { display: flex; gap: 14px; overflow-x: auto; padding: 4px 0 12px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.video {
  flex: 0 0 260px;
  scroll-snap-align: start;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--sombra-card);
  text-decoration: none;
  color: var(--ink);
  overflow: hidden;
  transition: transform 200ms var(--ease), border-color 200ms, box-shadow 200ms;
}
.video:hover { transform: translateY(-2px); border-color: var(--border-strong); box-shadow: 0 10px 30px -8px rgba(0, 0, 0, 0.6); }
.video-capa { position: relative; aspect-ratio: 16 / 9; background: linear-gradient(160deg, var(--surface-3), var(--elev)); display: grid; place-items: center; }
.video-capa img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.video-capa .play { position: relative; width: 44px; height: 44px; border-radius: 999px; background: rgba(10, 12, 17, 0.75); border: 1px solid var(--border-strong); color: #fff; display: grid; place-items: center; }
.video-capa .play .ico { width: 16px; height: 16px; fill: currentColor; stroke: none; margin-left: 2px; }
.video-capa .dur { position: absolute; right: 8px; bottom: 8px; font-size: 12px; font-weight: 700; background: rgba(10, 12, 17, 0.8); padding: 2px 7px; border-radius: 6px; }
.video-info { padding: 12px 14px 14px; }
.video-info strong { display: block; font-size: 15px; font-weight: 700; line-height: 1.3; }
.video-info span { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--muted); font-size: 12px; font-weight: 600; }
.videos-vazio {
  border: 1px dashed var(--border-strong);
  border-radius: 16px;
  padding: 22px 24px;
  color: var(--muted);
  font-size: 14px;
  max-width: 560px;
}
.videos-vazio strong { color: var(--ink-2); }
.videos-vazio code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.92em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; color: var(--ink); }

/* ---------- rodapé ---------- */
.rodape {
  position: relative; z-index: 1;
  max-width: var(--largura); margin: 0 auto;
  padding: 24px var(--gutter) calc(env(safe-area-inset-bottom) + 36px);
  border-top: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  color: var(--muted); font-size: 13px;
}
.rodape p { margin: 0; max-width: 60ch; }
.slack { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); color: var(--ink-2); font-weight: 700; text-decoration: none; transition: border-color 160ms, color 160ms; }
.slack:hover { border-color: var(--border-strong); color: var(--ink); }

/* ---------- responsivo ---------- */
@media (max-width: 900px) {
  .manual-corpo { grid-template-columns: 1fr; gap: 20px; }
  .trilho { position: static; }
  .trilho ol { display: none; }
  .trilho select {
    display: block; width: 100%; height: 44px; padding: 0 12px;
    border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--ink);
    font: inherit; font-size: 15px; font-weight: 600;
  }
}
@media (max-width: 640px) {
  .topo { flex-direction: column; align-items: flex-start; gap: 12px; }
  .atalhos { justify-content: flex-start; }
  .atalhos a { height: 34px; }
  .balcao { padding: 40px 0 32px; }
  .campo { padding-left: 16px; min-height: 60px; border-radius: 18px; }
  .campo textarea { font-size: 17px; padding: 10px 0; }
  .enviar { width: 44px; height: 44px; }
  .marca-sub { display: none; }
  .troca { padding: 18px 18px 14px; border-radius: 16px; }
  .troca-resposta, .texto { font-size: 16px; }
  .manual h2, .videos h2 { font-size: 26px; }
  .video { flex-basis: 232px; }
}
