/* =========================================================================
   HORKOS · site institucional
   O markup vem do protótipo de alta fidelidade e carrega estilo inline.
   Inline vence folha de estilo, então os ajustes daqui usam !important
   de propósito. Não é gambiarra: é a única forma de sobrepor o inline.
   ========================================================================= */

/* ---------- 1. tokens ---------- */
:root {
  --night: #111C26;
  --night-deep: #0B141C;
  --petrol: #073B4C;
  --petrol-050: #EDF4F6;
  --petrol-100: #D6E6EA;
  --petrol-200: #A9CCD5;
  --proof: #00B8B5;
  --proof-light: #4CC898;
  --proof-deep: #007D7B;
  --proof-darker: #00615F;
  --proof-bg: #E4F6F5;
  --proof-border: #A8E3E1;
  --ink-600: #4C5A66;
  --ink-500: #65727D;
  --ink-400: #8C99A3;
  --line-300: #BCC9CF;
  --line-200: #D7E1E5;
  --surface-2: #E9EFF1;
  --canvas: #F2F6F7;
  --surface-alt: #F8FBFB;
  --nav-h: 68px;

  --font-sans: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: Sora, Inter, system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ---------- 2. base ---------- */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--night-deep);
  font-family: var(--font-sans);
  color: var(--night);
  -webkit-font-smoothing: antialiased;
  /* clip (e não hidden) para não quebrar o position: sticky da nav */
  overflow-x: clip;
}

a { color: var(--proof-deep); text-decoration: none; }
a:hover { color: var(--proof-darker); }
::selection { background: var(--petrol-100); color: var(--night); }

img { max-width: 100%; }
button { font-family: inherit; }

:focus-visible {
  outline: 2px solid var(--proof);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 100;
  background: #fff;
  color: var(--night);
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
}
.skip-link:focus { left: 12px; }

/* âncoras não ficam escondidas atrás da nav fixa */
.anchor { scroll-margin-top: calc(var(--nav-h) + 12px); }

/* ícones Material Symbols */
.ms {
  font-family: "Material Symbols Rounded";
  font-weight: 400;
  font-style: normal;
  line-height: 1;
  display: inline-block;
  white-space: nowrap;
  flex-shrink: 0;
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

/* ---------- 3. animações ---------- */
@keyframes hk-pulse   { 0%,100% { opacity: 1 } 50% { opacity: .3 } }
@keyframes hk-ring    { 0% { transform: scale(.82); opacity: .5 } 100% { transform: scale(1.35); opacity: 0 } }
@keyframes hk-breathe { 0%,100% { transform: scale(1) } 50% { transform: scale(1.045) } }
@keyframes hk-blink   { 0%,92%,100% { transform: scaleY(1) } 96% { transform: scaleY(.08) } }
@keyframes hk-talk    { 0%,100% { height: 7px; width: 20px } 35% { height: 15px; width: 23px } 70% { height: 9px; width: 17px } }
@keyframes hk-wave    { 0%,100% { transform: scaleY(.32) } 50% { transform: scaleY(1) } }
@keyframes hk-float   { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-7px) } }
@keyframes hk-float2  { 0%,100% { transform: translateY(-4px) } 50% { transform: translateY(5px) } }
@keyframes hk-rise    { from { opacity: 0; transform: translateY(22px) } to { opacity: 1; transform: translateY(0) } }
@keyframes hk-orbit   { from { transform: rotate(0deg) } to { transform: rotate(360deg) } }
@keyframes hk-dash    { to { stroke-dashoffset: 0 } }

/* ---------- 4. hover e foco (gerados a partir do protótipo) ---------- */
.hk-h1:hover, .hk-h1:focus-visible { color: #fff !important; }
.hk-h2:hover, .hk-h2:focus-visible { background: #D6E6EA !important; color: #111C26 !important; }
.hk-h3:hover, .hk-h3:focus-visible { border-color: #ffffff66 !important; color: #fff !important; }
.hk-h4:hover, .hk-h4:focus-visible { border-color: #BCC9CF !important; box-shadow: 0 10px 28px rgba(14,17,22,.07) !important; }
.hk-h5:hover, .hk-h5:focus-visible { border-color: #A9CCD5 !important; box-shadow: 0 10px 28px rgba(14,17,22,.07) !important; }
.hk-h6:hover, .hk-h6:focus-visible { background: #073B4C !important; color: #fff !important; }
.hk-h7:hover, .hk-h7:focus-visible { color: #00B8B5 !important; }
.hk-f8:focus { border-color: #00B8B5 !important; background: #ffffff14 !important; }
.hk-h9:hover, .hk-h9:focus-visible { border-color: #4C5A66 !important; color: #fff !important; }
.hk-h10:hover, .hk-h10:focus-visible { background: #D6E6EA !important; }

a, button, [data-step], .chip {
  transition: background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
}

/* ---------- 5. formulário ---------- */
.form-card input::placeholder { color: #5C6975; }
.form-card input:hover { border-color: #3D4C59 !important; }

.form-card input[aria-invalid="true"] {
  border-color: #E05252 !important;
  background: #E0525214 !important;
}

.field-error {
  font-size: 11px;
  font-weight: 500;
  color: #F2B7B3;
  min-height: 0;
}

.chip { cursor: pointer; }
.chip.is-on {
  color: #fff !important;
  background: #00B8B51f !important;
  border-color: #00B8B54d !important;
}

.form-status {
  margin: 0;
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
  color: var(--ink-400);
}
.form-status:empty { display: none; }
.form-status[data-tone="ok"] { color: #A7E3C6; }
.form-status[data-tone="erro"] { color: #F2B7B3; }

button[type="submit"][aria-busy="true"] { opacity: .6; pointer-events: none; }

/* ---------- 6. navegação mobile ---------- */
.nav-toggle {
  display: none;
  margin-left: auto;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid #ffffff26;
  border-radius: 10px;
  background: #ffffff0d;
  color: #fff;
  cursor: pointer;
  padding: 0;
}
.nav-toggle .ms { font-size: 22px; }
.nav-toggle:hover { background: #ffffff1a; }

@media (max-width: 1040px) {
  .nav-links { gap: 20px !important; }
}

@media (max-width: 940px) {
  .nav-toggle { display: flex; }

  .nav-links {
    display: none !important;
    position: absolute;
    left: 0;
    right: 0;
    top: var(--nav-h);
    margin-left: 0 !important;
    flex-direction: column;
    align-items: stretch !important;
    gap: 2px !important;
    padding: 14px 20px 20px;
    /* opaco de verdade: o painel cobre o hero, nada de texto vazando por trás */
    background: #0B141C;
    border-bottom: 1px solid #ffffff14;
    box-shadow: 0 24px 48px rgba(0,0,0,.4);
  }
  .nav-links.is-open { display: flex !important; }

  .nav-links > a {
    padding: 13px 2px !important;
    font-size: 15px !important;
    border-bottom: 1px solid #ffffff0f;
  }
  .nav-links > a:last-child {
    justify-content: center;
    margin-top: 12px;
    height: 48px !important;
    border-bottom: 0;
  }
}

/* ---------- 6b. largura útil em telas grandes ---------- */
/* O protótipo trava tudo em 1200px, o que deixa monitor largo com muito vazio
   nas laterais. O container cresce por faixa, mas os parágrafos seguem presos
   à medida em ch, então a linha continua legível. */
@media (min-width: 1340px) {
  .container { max-width: 1320px !important; }
  .cta-wrap { max-width: 1180px !important; }
}
@media (min-width: 1560px) {
  .container { max-width: 1480px !important; }
  .cta-wrap { max-width: 1260px !important; }
}
@media (min-width: 1800px) {
  .container { max-width: 1680px !important; }
  .cta-wrap { max-width: 1320px !important; }
}
@media (min-width: 2200px) {
  .container { max-width: 1840px !important; }
}

/* Com o container mais largo, as grades de 6 itens virariam 4 + 2. Travar em
   três colunas mantém o ritmo do desenho original. */
@media (min-width: 1100px) {
  #recursos .auto-grid,
  #seguranca .auto-grid { grid-template-columns: repeat(3, 1fr) !important; }
}

/* ---------- 7. responsivo ---------- */

/* hero em coluna e mocks fluidos */
@media (max-width: 980px) {
  .hero-wrap {
    flex-direction: column !important;
    gap: 56px !important;
    align-items: stretch !important;
    padding: 56px 32px 72px !important;
  }
  .hero-media { justify-content: center; }
  .h1 { font-size: 44px !important; }
}

@media (max-width: 900px) {
  .demo-stage {
    grid-template-columns: 1fr !important;
    min-width: 0 !important;
  }
  /* no empilhamento os painéis largos deixam de forçar 2 colunas */
  .demo-stage > [data-panel] { grid-column: 1 / -1 !important; }
}

/* aqui o desenho vira mobile de fato */
@media (max-width: 760px) {
  .sec, header.anchor > .hero-wrap { padding-left: 20px !important; padding-right: 20px !important; }
  .sec { padding-top: 64px !important; padding-bottom: 64px !important; }
  .hero-wrap { padding: 40px 20px 56px !important; }
  .hero-strip { padding: 22px 20px !important; }

  .h1 { font-size: 34px !important; line-height: 1.14 !important; }
  .h2 { font-size: 27px !important; line-height: 1.2 !important; }

  /* o mock do celular passa a mandar na largura disponível */
  .hero-phone { width: 100% !important; max-width: 344px; }

  /* os três cartões saem do absoluto e viram uma pilha abaixo do celular */
  .hero-media {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }
  .hero-float {
    position: static !important;
    animation: none !important;
    width: 100%;
    max-width: 344px;
    box-shadow: 0 10px 30px rgba(0,0,0,.35) !important;
  }

  .market-card { padding: 28px 22px !important; }
  .doc-mock { width: 100% !important; max-width: 380px; }
  /* o selo flutuante deixa de sobrepor o documento e passa a ficar abaixo */
  .doc-stage { flex-direction: column; align-items: center; }
  .doc-badge {
    position: static !important;
    animation: none !important;
    margin-top: 18px;
    width: 100%;
    max-width: 380px;
    justify-content: center;
  }
}

/* telas estreitas: tudo em uma coluna só */
@media (max-width: 620px) {
  .auto-grid { grid-template-columns: 1fr !important; }
  .always-grid { grid-template-columns: 1fr !important; }
  .field { flex: 1 1 100% !important; }
  .form-card { padding: 22px !important; }
  /* abaixo de 16px o Safari do iPhone dá zoom ao focar o campo */
  .form-card input { font-size: 16px !important; }
  .cta-wrap { gap: 40px !important; }

  [data-step] { padding: 18px 16px !important; gap: 14px !important; }
  [data-step-num] { width: 40px !important; height: 40px !important; }

  .win-mock { border-radius: 12px !important; }
  /* o cabeçalho da sessão tem altura fixa de 52px e corta o nome quando ele
     quebra em duas linhas no celular */
  .win-mock [style*="height: 52px"] {
    height: auto !important;
    min-height: 52px;
    padding: 10px 14px !important;
    flex-wrap: wrap;
  }
  /* a janela de desktop encolhe demais abaixo de 380px: rola na horizontal */
  .win-mock > div:last-child { overflow-x: auto; }

  .sec > div, .cta-wrap { min-width: 0 !important; }
}

@media (max-width: 420px) {
  .h1 { font-size: 30px !important; }
  .h2 { font-size: 24px !important; }
  .demo-phone { width: 100% !important; max-width: 262px; margin: 0 auto; }
  .sec { padding-top: 52px !important; padding-bottom: 52px !important; }
}

/* Colunas largas do protótipo (min-width 280-340px) empilham em vez de
   espremer. O flex-basis: 100% garante a quebra; o min-width: 0 evita que
   o conteúdo interno estoure a linha. */
@media (max-width: 760px) {
  .sec [style*="min-width: 340px"],
  .sec [style*="min-width: 320px"],
  .sec [style*="min-width: 300px"],
  .sec [style*="min-width: 280px"],
  #dossie [style*="min-width: 320px"],
  #contato [style*="min-width: 340px"],
  #contato [style*="min-width: 300px"] {
    flex-basis: 100% !important;
    min-width: 0 !important;
  }
}

/* ---------- 8. movimento reduzido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* =========================================================================
   9. Páginas legais (privacidade, termos)
   Conteúdo novo, então aqui o estilo é por classe e não inline: nada de
   !important, ao contrário do markup herdado do protótipo.
   ========================================================================= */

.legal-hero {
  background: var(--night-deep);
  padding: 56px 32px 64px;
  border-bottom: 1px solid #ffffff14;
}
.legal-hero-wrap { display: flex; flex-direction: column; gap: 16px; }

.legal-voltar {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-400);
  margin-bottom: 6px;
}
.legal-voltar:hover { color: #fff; }
.legal-voltar .ms { font-size: 17px; }

.legal-rotulo {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--proof);
  font-weight: 600;
}
.legal-h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 44px;
  line-height: 1.12;
  font-weight: 600;
  letter-spacing: -.026em;
  color: #fff;
  text-wrap: balance;
}
.legal-intro {
  margin: 0;
  max-width: 62ch;
  font-size: 17px;
  line-height: 1.65;
  color: var(--line-300);
  text-wrap: pretty;
}
.legal-data {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-500);
  padding-top: 6px;
}

.legal-main { background: #fff; padding: 56px 32px 96px; }
.legal-grid {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}

/* sumário fixo */
.legal-toc { position: sticky; top: calc(var(--nav-h) + 24px); min-width: 0; }
.legal-toc-titulo {
  display: block;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-400);
  padding-bottom: 12px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line-200);
}
.legal-toc ol { list-style: none; margin: 0; padding: 0; }
.legal-toc li { margin: 0; }
.legal-toc a {
  display: block;
  padding: 7px 0 7px 11px;
  border-left: 2px solid transparent;
  font-size: 13px;
  line-height: 1.4;
  color: var(--ink-600);
}
.legal-toc a:hover { color: var(--night); border-left-color: var(--line-300); }
.legal-toc a.is-atual {
  color: var(--night);
  font-weight: 600;
  border-left-color: var(--proof);
}

/* corpo do documento */
.legal-corpo { max-width: 74ch; min-width: 0; }
.legal-corpo h2 {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1.3;
  font-weight: 600;
  letter-spacing: -.016em;
  color: var(--night);
  scroll-margin-top: calc(var(--nav-h) + 20px);
  text-wrap: balance;
}
.legal-sec { padding: 30px 0; border-top: 1px solid var(--line-200); }
.legal-sec:first-of-type { border-top: 0; padding-top: 12px; }

.legal-corpo p {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--ink-600);
  text-wrap: pretty;
}
.legal-corpo p:last-child { margin-bottom: 0; }
.legal-corpo strong { color: var(--night); font-weight: 600; }
.legal-corpo a { color: var(--proof-deep); text-decoration: underline; text-underline-offset: 2px; }
.legal-corpo a:hover { color: var(--proof-darker); }

.legal-corpo ul { margin: 0 0 14px; padding-left: 0; list-style: none; }
.legal-corpo ul li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 9px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-600);
}
.legal-corpo ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 10px;
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: var(--petrol-200);
}
/* lista do que não fazemos, com marcador próprio */
.legal-nao li::before {
  content: "";
  left: 2px;
  top: 9px;
  width: 9px;
  height: 2px;
  border-radius: 2px;
  background: var(--risk, #E05252);
  opacity: .55;
}

/* resumo no topo */
.legal-resumo {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--petrol-050);
  border: 1px solid var(--petrol-100);
  border-radius: 16px;
  padding: 20px 22px;
  margin-bottom: 8px;
}
.legal-resumo .ms { font-size: 22px; color: var(--petrol); margin-top: 1px; }
.legal-resumo strong {
  display: block;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--petrol);
  margin-bottom: 5px;
}
.legal-resumo p { margin: 0; font-size: 14px; line-height: 1.65; color: #2A3742; }

/* tabelas */
.legal-tabela { overflow-x: auto; margin: 0 0 16px; }
.legal-tabela table {
  width: 100%;
  min-width: 460px;
  border-collapse: collapse;
  font-size: 14px;
}
.legal-tabela th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-500);
  font-weight: 600;
  padding: 0 14px 9px 0;
  border-bottom: 1px solid var(--line-200);
}
.legal-tabela td {
  padding: 12px 14px 12px 0;
  border-bottom: 1px solid var(--surface-2);
  color: var(--ink-600);
  line-height: 1.6;
  vertical-align: top;
}
.legal-tabela tr:last-child td { border-bottom: 0; }

/* dado que ainda falta preencher, marcado em vez de inventado */
.pendente {
  font-style: italic;
  color: var(--ink-400);
  border-bottom: 1px dashed var(--line-300);
}

.legal-contato {
  display: flex;
  flex-direction: column;
  gap: 11px;
  background: var(--canvas);
  border: 1px solid var(--line-200);
  border-radius: 14px;
  padding: 20px 22px;
}
.legal-contato div {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 14px;
  color: var(--ink-600);
}
.legal-contato .ms { font-size: 18px; color: var(--petrol); }

.legal-fim {
  margin-top: 40px;
  padding-top: 26px;
  border-top: 1px solid var(--line-200);
  display: flex;
  gap: 18px;
  align-items: center;
  flex-wrap: wrap;
}
.legal-fim p { flex: 1; min-width: 260px; margin: 0; font-size: 14px; color: var(--ink-500); }
.legal-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 20px;
  border-radius: 10px;
  background: var(--night);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}
.legal-corpo a.legal-cta { text-decoration: none; }
.legal-cta:hover { background: var(--petrol); color: #fff; }
.legal-cta .ms { font-size: 18px; }

@media (max-width: 900px) {
  /* minmax(0, 1fr) e não 1fr: com 1fr a largura mínima da tabela estica a
     coluna e a página inteira passa a rolar na horizontal */
  .legal-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .legal-toc {
    position: static;
    background: var(--canvas);
    border: 1px solid var(--line-200);
    border-radius: 14px;
    padding: 16px 18px;
  }
  .legal-toc ol { columns: 2; column-gap: 22px; }
  .legal-toc a { padding: 6px 0 6px 10px; break-inside: avoid; }
  .legal-toc a.is-atual { border-left-color: var(--proof); }
}

@media (max-width: 760px) {
  .legal-hero { padding: 36px 20px 44px; }
  .legal-main { padding: 40px 20px 64px; }
  .legal-h1 { font-size: 31px; }
  .legal-intro { font-size: 16px; }
  .legal-corpo h2 { font-size: 19px; }
  .legal-toc ol { columns: 1; }
  .legal-resumo { padding: 17px 18px; }
}
