/* Materiais do Agente — base copiada do Abil Lab (~/abil-lab/app/styles.css), mesmo sistema visual. */
@font-face { font-family: 'Outfit'; src: url('/fonts/outfit-300.ttf') format('truetype'); font-weight: 300; font-display: swap; }
@font-face { font-family: 'Outfit'; src: url('/fonts/outfit-400.ttf') format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Outfit'; src: url('/fonts/outfit-500.ttf') format('truetype'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Outfit'; src: url('/fonts/outfit-600.ttf') format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Outfit'; src: url('/fonts/outfit-700.ttf') format('truetype'); font-weight: 700; font-display: swap; }

:root,
:root[data-theme='light'] {
  color-scheme: light;
  --os-bg: #f5f7fa;
  --os-panel: #ffffff;
  --os-panel-2: #f0f3f7;
  --os-panel-glass: rgba(255, 255, 255, 0.88);
  --os-ink: #101521;
  --os-muted: #687184;
  --os-line: rgba(16, 21, 33, 0.1);
  --os-line-strong: rgba(16, 21, 33, 0.17);
  --os-blue: #1746f5;
  --os-blue-ink: #ffffff;
  --os-blue-soft: rgba(23, 70, 245, 0.09);
  --os-gold: #c99632;
  --os-gold-soft: rgba(201, 150, 50, 0.12);
  --os-green: #12805c;
  --os-green-soft: rgba(18, 128, 92, 0.1);
  --os-amber: #af7119;
  --os-amber-soft: #fff4e5;
  --os-red: #b42318;
  --os-shadow: 0 18px 55px rgba(20, 31, 55, 0.09);
  --os-shadow-sm: 0 4px 24px rgba(21, 34, 63, 0.04);
  --os-scrim: rgba(16, 21, 33, 0.28);
}

:root[data-theme='dark'] {
  color-scheme: dark;
  --os-bg: #090b0e;
  --os-panel: #101318;
  --os-panel-2: #171b21;
  --os-panel-glass: rgba(16, 19, 24, 0.92);
  --os-ink: #f4f6f8;
  --os-muted: #9098a6;
  --os-line: rgba(255, 255, 255, 0.085);
  --os-line-strong: rgba(255, 255, 255, 0.15);
  --os-blue: #6382ff;
  --os-blue-ink: #0b0f1a;
  --os-blue-soft: rgba(99, 130, 255, 0.13);
  --os-gold: #d2aa4f;
  --os-gold-soft: rgba(210, 170, 79, 0.12);
  --os-green: #4cc79a;
  --os-green-soft: rgba(76, 199, 154, 0.12);
  --os-amber: #e0a54a;
  --os-amber-soft: rgba(224, 165, 74, 0.12);
  --os-red: #ff8a80;
  --os-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
  --os-shadow-sm: 0 4px 24px rgba(0, 0, 0, 0.25);
  --os-scrim: rgba(0, 0, 0, 0.55);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: 'Outfit', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: var(--os-ink);
  background: var(--os-bg);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(900px 460px at 78% -8%, var(--os-blue-soft), transparent 72%),
              radial-gradient(700px 380px at -10% 30%, var(--os-gold-soft), transparent 70%);
  z-index: 0;
}
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; }
a { color: var(--os-blue); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--os-blue) 35%, transparent); outline-offset: 2px; border-radius: 8px; }
.num { font-variant-numeric: tabular-nums; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg.i { width: 16px; height: 16px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ── Cabeçalho ───────────────────────────────────────────── */
.topo {
  position: sticky; top: 0; z-index: 30;
  height: 64px;
  display: flex; align-items: center; gap: 16px;
  padding: 0 max(16px, calc((100vw - 1120px) / 2));
  background: color-mix(in srgb, var(--os-bg) 86%, transparent);
  backdrop-filter: blur(24px) saturate(130%);
  -webkit-backdrop-filter: blur(24px) saturate(130%);
  border-bottom: 1px solid var(--os-line);
}
.marca { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--os-ink); min-width: 0; }
.marca img { width: 30px; height: 30px; border-radius: 9px; }
.marca strong { font-size: 17px; font-weight: 600; letter-spacing: -0.02em; white-space: nowrap; }
.marca strong b { color: var(--os-blue); font-weight: 600; }
.nav {
  position: relative;
  margin: 0;
  display: flex; gap: 2px; padding: 4px;
  border: 1px solid var(--os-line);
  background: var(--os-panel-glass);
  border-radius: 12px;
}
.nav button {
  position: relative; z-index: 1;
  display: inline-flex; align-items: center; gap: 7px;
  height: 34px; padding: 0 14px;
  border: 0; background: none; border-radius: 9px;
  color: var(--os-muted); font-size: 13.5px; font-weight: 500;
  transition: color .18s ease;
}
.nav button:hover { color: var(--os-ink); }
.nav button[aria-current='page'] { color: var(--os-ink); }
.nav .marcador {
  position: absolute; z-index: 0; top: 4px; height: 34px; border-radius: 9px;
  background: var(--os-panel); box-shadow: 0 1px 2px rgba(15, 23, 42, .08), inset 0 0 0 1px var(--os-line);
  transition: transform 280ms cubic-bezier(.2,.85,.25,1), width 280ms cubic-bezier(.2,.85,.25,1);
}
:root[data-theme='dark'] .nav .marcador { background: var(--os-panel-2); }
.nav button svg.i { width: 15px; height: 15px; }
.nav button[aria-current='page'] svg.i { color: var(--os-blue); }
.topo-acoes { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.icone-btn {
  width: 34px; height: 34px; display: grid; place-items: center;
  border: 1px solid transparent; background: none; border-radius: 9px; color: var(--os-muted);
  transition: background .18s ease, color .18s ease;
}
.icone-btn:hover { background: var(--os-panel-2); color: var(--os-ink); }
.quem { display: flex; align-items: center; gap: 9px; padding: 4px 4px 4px 10px; border-radius: 11px; border: 1px solid var(--os-line); background: var(--os-panel-glass); max-width: 260px; }
.quem-txt { min-width: 0; line-height: 1.15; }
.quem-txt b { display: block; font-size: 12.5px; font-weight: 560; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.quem-txt span { display: block; font-size: 11px; color: var(--os-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.avatar { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; font-size: 12px; font-weight: 600; color: var(--os-blue); background: var(--os-blue-soft); flex: none; }

/* ── Página ──────────────────────────────────────────────── */
main { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; padding: 28px 16px 80px; }
.vista { animation: vista-in 220ms ease both; }
@keyframes vista-in { from { opacity: .72; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.selo-equipe { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; color: var(--os-gold); background: var(--os-gold-soft); padding: 3px 10px; border-radius: 99px; }
.kicker { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--os-muted); }
h1, h2, h3, h4 { margin: 0; font-weight: 500; letter-spacing: -0.02em; }
.secao-titulo { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 40px 0 16px; }
.secao-titulo h2 { font-size: 21px; font-weight: 500; letter-spacing: -0.03em; }
.secao-titulo p { margin: 4px 0 0; color: var(--os-muted); font-size: 14px; }

.card {
  background: var(--os-panel);
  border: 1px solid var(--os-line);
  border-radius: 20px;
  box-shadow: var(--os-shadow-sm);
}

/* Herói */
.heroi { display: grid; grid-template-columns: 1fr auto; gap: 28px; align-items: center; padding: 30px 32px; position: relative; overflow: hidden; }
.heroi::after { content: ''; position: absolute; right: -120px; top: -140px; width: 420px; height: 420px; border-radius: 50%; background: radial-gradient(closest-side, var(--os-blue-soft), transparent); pointer-events: none; }
.heroi h1 { font-size: clamp(30px, 3.4vw, 46px); font-weight: 480; letter-spacing: -0.05em; line-height: 1.05; margin: 10px 0 10px; }
.heroi h1 span { color: var(--os-blue); }
.heroi p { margin: 0; color: var(--os-muted); font-size: 15.5px; max-width: 520px; }
.heroi-acoes { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }
.anel { position: relative; width: 148px; height: 148px; z-index: 1; margin: 0 auto; }
.anel svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.anel circle { fill: none; stroke-width: 10; }
.anel .trilho { stroke: color-mix(in srgb, var(--os-blue) 10%, var(--os-panel-2)); }
.anel .valor { stroke: var(--os-blue); stroke-linecap: round; transition: stroke-dashoffset 1.1s cubic-bezier(.2,.8,.2,1); }
.anel-centro { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.anel-centro b { font-size: 34px; font-weight: 500; letter-spacing: -0.045em; line-height: 1; }
.anel-centro span { font-size: 12px; color: var(--os-muted); margin-top: 4px; }

/* Botões */
.btn { text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 38px; padding: 0 16px; border-radius: 9px;
  border: 1px solid transparent; font-size: 14px; font-weight: 500; white-space: nowrap;
  transition: background-color .2s ease-out, border-color .2s ease-out, color .2s, box-shadow .2s, transform .2s cubic-bezier(.2,.8,.2,1);
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn-pri { background: var(--os-blue); color: var(--os-blue-ink); box-shadow: 0 1px 2px rgba(15,23,42,.12); }
.btn-pri:hover { transform: translateY(-1px); background: color-mix(in srgb, var(--os-blue) 88%, #000); box-shadow: 0 5px 14px color-mix(in srgb, var(--os-blue) 28%, transparent); }
.btn-sec { background: var(--os-panel); border-color: var(--os-line-strong); color: var(--os-ink); }
.btn-sec:hover { background: var(--os-panel-2); }
.btn-fant { background: none; color: var(--os-muted); }
.btn-fant:hover { color: var(--os-ink); background: var(--os-panel-2); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn .i { width: 15px; height: 15px; }

/* Selos */
.selo { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 9px; border-radius: 99px; font-size: 11.5px; font-weight: 500; white-space: nowrap; }
.selo .i { width: 12px; height: 12px; }
.selo-neutro { background: var(--os-panel-2); color: var(--os-muted); }
.selo-azul { background: var(--os-blue-soft); color: var(--os-blue); }
.selo-verde { background: var(--os-green-soft); color: var(--os-green); }
.selo-ambar { background: var(--os-amber-soft); color: var(--os-amber); }
.selo-ouro { background: var(--os-gold-soft); color: var(--os-gold); }

/* ── Pop-ups ─────────────────────────────────────────────── */
.camada { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; }
.camada-fundo { position: absolute; inset: 0; background: var(--os-scrim); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: fundo-in .2s ease both; }
.camada.saindo .camada-fundo { animation: fundo-out .18s ease both; }
@keyframes fundo-in { from { opacity: 0; } } @keyframes fundo-out { to { opacity: 0; } }
.janela {
  position: relative; width: min(640px, 100%); max-height: min(88vh, 900px);
  display: flex; flex-direction: column;
  background: var(--os-panel); border: 1px solid var(--os-line); border-radius: 22px; box-shadow: var(--os-shadow);
  animation: janela-in .32s cubic-bezier(.2,.85,.25,1) both;
  overflow: hidden;
}
.camada.saindo .janela { animation: janela-out .18s ease both; }
@keyframes janela-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }
@keyframes janela-out { to { opacity: 0; transform: translateY(8px) scale(.985); } }
.janela.larga { width: min(980px, 100%); }
.janela:focus { outline: none; }
.janela.tela { width: min(1180px, 100%); height: min(92vh, 980px); max-height: none; }
.janela-cab { display: flex; align-items: flex-start; gap: 14px; padding: 20px 22px 16px; border-bottom: 1px solid var(--os-line); }
.janela-cab h2 { font-size: 19px; letter-spacing: -0.03em; }
.janela-cab p { margin: 3px 0 0; color: var(--os-muted); font-size: 13.5px; }
.janela-cab .icone-btn { margin-left: auto; flex: none; }
.janela-corpo { padding: 20px 22px; overflow-y: auto; flex: 1; }
.janela-corpo.sem-pad { padding: 0; }
.janela-pe { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--os-line); background: color-mix(in srgb, var(--os-panel-2) 55%, transparent); flex-wrap: wrap; }
.janela-pe .esq { margin-right: auto; font-size: 13px; color: var(--os-muted); display: flex; align-items: center; gap: 6px; }

.video-caixa { position: relative; aspect-ratio: 16 / 9; width: min(100%, calc((88vh - 250px) * 16 / 9)); margin: 0 auto; background: #05070b; border-radius: 14px; overflow: hidden; }
.video-caixa iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-vazio { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; color: #9aa3b5; gap: 8px; }
.partes { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.parte { height: 32px; padding: 0 13px; border-radius: 99px; border: 1px solid var(--os-line-strong); background: none; font-size: 13px; color: var(--os-muted); display: inline-flex; align-items: center; gap: 6px; }
.parte[aria-pressed='true'] { background: var(--os-ink); color: var(--os-bg); border-color: var(--os-ink); }
.parte .i { width: 13px; height: 13px; }

.wizard-frame { width: 100%; height: 100%; border: 0; display: block; background: var(--os-bg); }

.grupo-int { margin-bottom: 20px; }
.grupo-int h4 { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--os-muted); margin-bottom: 8px; }
.item-int { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--os-line); border-radius: 14px; margin-bottom: 8px; transition: background .2s, border-color .2s; }
.item-int.feito { background: var(--os-green-soft); border-color: transparent; }
.marcar { width: 24px; height: 24px; border-radius: 8px; border: 1.5px solid var(--os-line-strong); background: var(--os-panel); display: grid; place-items: center; flex: none; padding: 0; color: transparent; transition: background .2s, border-color .2s, color .2s, transform .2s; }
.marcar:hover { border-color: var(--os-blue); }
.item-int.feito .marcar { background: var(--os-green); border-color: var(--os-green); color: #fff; }
.marcar .i { width: 14px; height: 14px; stroke-width: 2.6; }
.marcar:active { transform: scale(.9); }
.item-int-txt { flex: 1; min-width: 0; }
.item-int-txt b { display: block; font-size: 14px; font-weight: 500; }
.item-int-txt span { display: block; font-size: 12.5px; color: var(--os-muted); }

.campo { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.campo label { font-size: 13px; font-weight: 500; }
.campo label em { color: var(--os-red); font-style: normal; }
.campo input, .campo select, .campo textarea { width: 100%; border: 1px solid var(--os-line-strong); background: var(--os-panel); border-radius: 10px; padding: 9px 12px; font-size: 14px; outline: 0; transition: border-color .2s, box-shadow .2s; }
.campo textarea { min-height: 96px; resize: vertical; }
.campo input:focus, .campo select:focus, .campo textarea:focus { border-color: var(--os-blue); box-shadow: 0 0 0 3px var(--os-blue-soft); }
.opcoes { display: flex; flex-wrap: wrap; gap: 6px; }
.opcoes label { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--os-line-strong); border-radius: 99px; font-size: 13px; font-weight: 400; cursor: pointer; }
.opcoes input { width: auto; }
.opcoes label:has(input:checked) { border-color: var(--os-blue); background: var(--os-blue-soft); color: var(--os-blue); }

.pontos { margin: 14px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.pontos li { display: flex; gap: 10px; font-size: 14px; }
.pontos li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--os-blue); margin-top: 8px; flex: none; }
.texto-longo { white-space: pre-wrap; font-size: 14.5px; line-height: 1.65; margin: 0; }

/* ── Toast, esqueleto, avisos ─────────────────────────────── */
.toasts { position: fixed; z-index: 90; left: 50%; bottom: 22px; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 11px 16px; border-radius: 14px; background: var(--os-ink); color: var(--os-bg); font-size: 14px; box-shadow: var(--os-shadow); animation: toast-in .5s cubic-bezier(.22,1,.36,1) both; }
.toast.erro { background: var(--os-red); color: #fff; }
.toast.saindo { transition: opacity .25s, transform .25s; opacity: 0; transform: translateY(8px); }
@keyframes toast-in { from { opacity: 0; transform: translateY(150%); } }
.esq-bloco { border-radius: 12px; background: linear-gradient(90deg, var(--os-panel-2), color-mix(in srgb, var(--os-panel-2) 40%, var(--os-panel)), var(--os-panel-2)); background-size: 300% 100%; animation: brilho 1.4s ease-in-out infinite; }
@keyframes brilho { from { background-position: 100% 0; } to { background-position: 0 0; } }
.aviso { min-height: calc(100vh - 140px); display: grid; place-items: center; }
.aviso .card { max-width: 440px; padding: 34px 32px; text-align: center; }
.aviso .tipo-icone { margin: 0 auto 16px; width: 52px; height: 52px; border-radius: 16px; }
.aviso h2 { font-size: 22px; letter-spacing: -0.03em; margin-bottom: 8px; }
.aviso p { margin: 0 0 20px; color: var(--os-muted); }
.giro { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: giro .7s linear infinite; }
@keyframes giro { to { transform: rotate(360deg); } }

/* ── Responsivo ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .grade-inicio, .grade-dados { grid-template-columns: 1fr; }
  .perfil { position: static; }
  .reunioes { grid-template-columns: 1fr; }
  .intro-slide { grid-template-columns: 1fr; gap: 20px; }
  .intro-cena { height: 260px; }
  .intro-slides { min-height: 620px; }
  .quem-txt { display: none; }
  .quem { padding: 3px; }
}
@media (max-width: 720px) {
  .topo { gap: 8px; }
  .marca strong { display: none; }
  .nav { margin: 0; flex: 1; justify-content: space-between; }
  .nav button { padding: 0 8px; font-size: 12.5px; gap: 5px; }
  .topo-acoes [data-acao] { display: none; }
  .nav button span { display: none; }
  .nav button[aria-current='page'] span { display: inline; }
  .heroi { grid-template-columns: 1fr; padding: 24px 20px; }
  .secao-titulo { flex-direction: column; align-items: stretch; }
  .resumo-trilha .barra { flex: 1; width: auto; }
  .trilha-cab { flex-wrap: wrap; }
  .proxima-rodape .btn { width: 100%; }
  .anel { width: 120px; height: 120px; }
  .tarefa { grid-template-columns: auto 1fr; }
  .tarefa-fim { grid-column: 2; }
  .respostas { grid-template-columns: 1fr; }
  .sugestoes { grid-template-columns: 1fr; }
  .janela { max-height: 92vh; border-radius: 20px; }
  .camada { padding: 8px; align-items: end; }
  .janela.tela { height: 94vh; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Peças do Lab usadas aqui */
.tipo-icone { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--os-blue-soft); color: var(--os-blue); flex: none; }
.tipo-icone .i { width: 19px; height: 19px; }
.tipo-icone.ouro { background: var(--os-gold-soft); color: var(--os-gold); }
.tipo-icone.verde { background: var(--os-green-soft); color: var(--os-green); }
.modulo-num { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 12px; font-weight: 600; background: var(--os-panel-2); color: var(--os-muted); flex: none; }
.vazio { border: 1px dashed var(--os-line-strong); border-radius: 16px; padding: 24px; text-align: center; color: var(--os-muted); font-size: 14px; }
.vazio .tipo-icone { margin: 0 auto 10px; }
