/* Cabeçalho único VidalRun (HTML em lib/topo.js, comportamento em assets/js/topo.js).
   Mesma barra em todas as páginas: logo, 5 itens, RUN+ e o botão amarelo.
   Classes com prefixo vt- para não colidir com os estilos de cada página. */
:root {
  --vt-altura: 64px;
  --vt-vacuo: #030A26;
  --vt-noite: #06103D;
  --vt-ciano: #1ECBF5;
  --vt-sinal: #F2EC1D;
  --vt-claro: #DCE6F7;
  --vt-claro-2: #93A4CC;
  --vt-fio: rgba(30, 203, 245, .22);
  --vt-margem: clamp(20px, 5vw, 56px);
  --vt-curva: cubic-bezier(.2, .7, .1, 1);
}
@media (min-width: 1280px) { :root { --vt-altura: 76px; } }
html { scroll-padding-top: calc(var(--vt-altura) + env(safe-area-inset-top, 0px) + 8px); }

.vt {
  position: sticky; top: 0; z-index: 60;
  padding-top: env(safe-area-inset-top, 0px);
  color: #fff; font-family: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: rgba(3, 10, 38, .94);
  border-bottom: 1px solid var(--vt-fio);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  transition: background-color .3s, border-color .3s;
}
/* Home: transparente sobre a foto do time; fica sólido ao rolar */
.vt--sobre { position: fixed; inset: 0 0 auto 0; background: transparent; border-bottom-color: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
.vt--sobre::before { content: ""; position: absolute; inset: 0 0 -24px; z-index: -1; pointer-events: none; background: linear-gradient(rgba(3, 10, 38, .55), rgba(3, 10, 38, 0)); transition: opacity .3s; }
.vt--sobre.is-solido { background: rgba(3, 10, 38, .94); border-bottom-color: var(--vt-fio); -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%); }
.vt--sobre.is-solido::before { opacity: 0; }

.vt__barra {
  height: var(--vt-altura); max-width: 1360px; margin-inline: auto; padding-inline: var(--vt-margem);
  display: flex; align-items: center; gap: 24px;
}
.vt__marca { flex: none; display: block; line-height: 0; border-radius: 4px; }
.vt__marca img { display: block; height: 34px; width: auto; }
@media (min-width: 1280px) { .vt__marca img { height: 40px; } }

.vt a { color: inherit; text-decoration: none; }
.vt :focus-visible { outline: 2px solid var(--vt-ciano); outline-offset: 4px; }
.vt ul { list-style: none; margin: 0; padding: 0; }
.vt__sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Computador ---------- */
@media (min-width: 1280px) {
  .vt__nav { margin-left: auto; display: flex; align-items: center; gap: 22px; }
  .vt__links { display: flex; align-items: center; gap: 22px; }
  .vt__link {
    position: relative; display: block; padding: 10px 0;
    font-size: .9375rem; font-weight: 600; font-stretch: 105%; letter-spacing: .005em; white-space: nowrap;
    color: var(--vt-claro); transition: color .2s;
  }
  .vt__num { display: none; }
  /* A linha de chegada: um traço que corre da esquerda ao passar o mouse */
  .vt__link::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 2px;
    background: var(--vt-ciano); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--vt-curva);
  }
  .vt__link:hover { color: #fff; }
  .vt__link:hover::after { transform: scaleX(1); }
  .vt__link[aria-current="page"] { color: #fff; }
  .vt__link[aria-current="page"]::after { transform: scaleX(1); background: var(--vt-sinal); }

  .vt__run {
    display: flex; align-items: center; padding: 6px 0 6px 22px; border-left: 1px solid rgba(255, 255, 255, .16);
    transition: transform .25s var(--vt-curva), filter .25s;
  }
  .vt__run img { display: block; height: 26px; width: auto; }
  .vt__run-rotulo { display: none; }
  .vt__run:hover { transform: translateX(2px); filter: drop-shadow(0 0 10px rgba(30, 203, 245, .55)); }
  .vt__run[aria-current="page"] img { filter: drop-shadow(0 0 8px rgba(30, 203, 245, .6)); }

  .vt__extra { display: none; }
  .vt__botao { display: none; }
}

/* Botão amarelo (mesmo desenho dos botões do site) */
.vt__cta {
  display: inline-flex; align-items: center; justify-content: center; flex: none;
  min-height: 44px; padding: 0 1.25em; border-radius: 4px; border: 1px solid var(--vt-sinal);
  background: var(--vt-sinal); color: var(--vt-noite) !important;
  font-size: .875rem; font-weight: 800; font-stretch: 112%; letter-spacing: .01em; white-space: nowrap;
  transition: box-shadow .3s var(--vt-curva), transform .2s var(--vt-curva), background-color .2s;
}
.vt__cta:hover { box-shadow: 0 0 0 4px rgba(242, 236, 29, .18), 0 10px 32px -10px rgba(242, 236, 29, .6); transform: translateY(-1px); }
.vt__cta:active { transform: translateY(1px); }

/* Barra de progresso da leitura (ciano para amarelo) */
.vt__progresso { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; pointer-events: none; }
.vt__progresso span {
  display: block; height: 100%; background: linear-gradient(90deg, var(--vt-ciano), var(--vt-sinal));
  transform-origin: left; transform: scaleX(0); box-shadow: 0 0 10px rgba(30, 203, 245, .7);
}

/* ---------- Celular e tablet: gaveta em tela cheia ---------- */
@media (max-width: 1279.98px) {
  .vt__botao {
    margin-left: auto; margin-right: -10px; flex: none;
    display: grid; place-items: center; width: 48px; height: 48px;
    background: none; border: 0; color: #fff; cursor: pointer;
  }
  .vt__linhas, .vt__linhas::before, .vt__linhas::after { content: ""; display: block; width: 24px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .3s var(--vt-curva), background-color .2s; }
  .vt__linhas { position: relative; }
  .vt__linhas::before { position: absolute; top: -7px; }
  .vt__linhas::after { position: absolute; top: 7px; width: 16px; }
  .vt__botao[aria-expanded="true"] .vt__linhas { background: transparent; }
  .vt__botao[aria-expanded="true"] .vt__linhas::before { transform: translateY(7px) rotate(45deg); }
  .vt__botao[aria-expanded="true"] .vt__linhas::after { width: 24px; transform: translateY(-7px) rotate(-45deg); }

  .vt__nav {
    position: fixed; z-index: -1; left: 0; right: 0; bottom: 0;
    top: calc(var(--vt-altura) + env(safe-area-inset-top, 0px));
    display: flex; flex-direction: column; gap: 28px;
    padding: 20px var(--vt-margem) calc(24px + env(safe-area-inset-bottom, 0px));
    background: var(--vt-vacuo); overflow-y: auto; overscroll-behavior: contain;
    visibility: hidden; opacity: 0; transform: translateY(-8px);
    transition: opacity .25s, transform .35s var(--vt-curva), visibility 0s .35s;
  }
  .vt__nav.is-aberto { visibility: visible; opacity: 1; transform: none; transition: opacity .25s, transform .35s var(--vt-curva); }
  .vt.is-aberto { background: var(--vt-vacuo); border-bottom-color: var(--vt-fio); -webkit-backdrop-filter: none; backdrop-filter: none; } /* sem filtro: a gaveta fixa passa a ocupar a tela toda */
  .vt.is-aberto::before { opacity: 0; }

  .vt__links { border-top: 1px solid var(--vt-fio); }
  .vt__links li { border-bottom: 1px solid var(--vt-fio); }
  .vt__link {
    display: flex; align-items: baseline; gap: 16px; padding: 16px 0;
    font-size: clamp(1.5rem, 1.1rem + 2vw, 2.125rem); font-weight: 800; font-stretch: 118%;
    text-transform: uppercase; letter-spacing: -.015em; line-height: 1.05; color: #fff;
  }
  .vt__num { flex: none; width: 2ch; font-size: .8125rem; font-weight: 700; font-stretch: 112%; color: var(--vt-ciano); font-variant-numeric: tabular-nums; letter-spacing: .04em; }
  .vt__link[aria-current="page"] { color: var(--vt-sinal); }
  .vt__nav.is-aberto .vt__links li { animation: vt-entra .5s var(--vt-curva) both; }
  .vt__nav.is-aberto .vt__links li:nth-child(2) { animation-delay: .03s; }
  .vt__nav.is-aberto .vt__links li:nth-child(3) { animation-delay: .06s; }
  .vt__nav.is-aberto .vt__links li:nth-child(4) { animation-delay: .09s; }
  .vt__nav.is-aberto .vt__links li:nth-child(5) { animation-delay: .12s; }
  .vt__nav.is-aberto .vt__links li:nth-child(6) { animation-delay: .15s; }

  .vt__run {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 18px 20px; border-radius: 6px;
    background: linear-gradient(110deg, rgba(11, 42, 148, .55), rgba(30, 203, 245, .12)); border: 1px solid var(--vt-fio);
  }
  .vt__run img { height: 30px; width: auto; display: block; }
  .vt__run-rotulo { font-size: .8125rem; font-weight: 600; color: var(--vt-claro-2); text-align: right; }

  .vt__extra { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 16px; }
  .vt__extra a { display: block; padding: 10px 0; font-size: .9375rem; font-weight: 600; color: var(--vt-claro); }
  .vt__extra a:hover { color: var(--vt-ciano); }

  .vt__cta { margin-top: auto; min-height: 56px; font-size: 1rem; width: 100%; }
}
@media (max-width: 380px) { .vt__extra { grid-template-columns: 1fr; } }
@keyframes vt-entra { from { opacity: 0; transform: translateX(-14px); } }
html.vt-travado, html.vt-travado body { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .vt *, .vt *::before, .vt *::after { transition: none !important; animation: none !important; }
}
@media print { .vt { display: none !important; } }
