/* Techglab: a manchete aparece quebrada em tokens, como um modelo de linguagem a lê; as quatro cores dos tokens são as
   quatro frentes de serviço. Claro e mineral; o escuro segue o sistema (prefers-color-scheme). Sem JavaScript. */

@font-face {
  font-family: "Bricolage Grotesque";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(fontes/bricolage-grotesque-700.woff2) format("woff2");
}
@font-face {
  font-family: "Instrument Sans";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url(fontes/instrument-sans.woff2) format("woff2");
}
@font-face {
  font-family: "Martian Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fontes/martian-mono-400.woff2) format("woff2");
}

:root {
  --bg: #e6ebe8;
  --surface: #f5f7f6;
  --ink: #121715;
  --muted: #4b5752;
  --line: #c9d2cd;
  --accent: #2236b8;
  /* uma cor por frente: estratégia, agentes, nuvem, governança */
  --t1: #c6daf5;
  --t2: #f3d3bf;
  --t3: #d0e8c2;
  --t4: #e2d0f1;
  --display: "Bricolage Grotesque", "Avenir Next", system-ui, sans-serif;
  --body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Martian Mono", ui-monospace, Menlo, Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1312;
    --surface: #161c1a;
    --ink: #e5ece9;
    --muted: #a3b3ad;
    --line: #2b3532;
    --accent: #9aa8ff;
    --t1: #22395a;
    --t2: #5a3624;
    --t3: #2c4a24;
    --t4: #46305c;
    color-scheme: dark;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  background: var(--bg);
  color: var(--ink);
}
h1,
h2,
h3,
p {
  margin: 0;
}
h2,
h3 {
  text-wrap: balance;
}
a {
  color: inherit;
}
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
.so-leitor {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.pular {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10;
  background: var(--surface);
  padding: 10px 14px;
  border-radius: 6px;
}
.pular:focus {
  top: 16px;
}

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

/* ---------- topo ---------- */
.topo {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-block: 22px;
}
.marca {
  font: 700 1.25rem/1 var(--display);
  letter-spacing: -0.01em;
  text-decoration: none;
}
.marca span {
  display: inline-block;
  background: var(--t1);
  padding: 2px 4px;
  border-radius: 4px;
  margin-left: 1px;
}
.topo nav {
  display: flex;
  gap: 20px;
  font-size: 0.94rem;
}
.topo nav a {
  text-decoration: none;
  color: var(--muted);
}
.topo nav a:hover {
  color: var(--ink);
}

/* ---------- abertura ---------- */
.abertura {
  padding-block: 56px 72px;
  display: grid;
  gap: 28px;
}
.meta {
  font: 400 0.75rem/1.4 var(--mono);
  color: var(--muted);
  letter-spacing: 0.02em;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.meta b {
  font-weight: 400;
  color: var(--ink);
}
.manchete {
  font: 700 clamp(2.4rem, 7.4vw, 5.6rem)/1.04 var(--display);
  letter-spacing: -0.035em;
  max-width: 14ch;
}
.tk {
  position: relative;
  border-radius: 0.12em;
  padding: 0 0.02em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  background: linear-gradient(var(--c), var(--c)) no-repeat 0 0 / 100% 100%;
}
.tk + .tk {
  margin-left: 0.05em;
}
.c1 { --c: var(--t1); }
.c2 { --c: var(--t2); }
.c3 { --c: var(--t3); }
.c4 { --c: var(--t4); }
/* O texto está sempre visível; só o fundo de cada token entra em sequência, como numa resposta em streaming. */
@media (prefers-reduced-motion: no-preference) {
  .manchete .tk {
    background-size: 0% 100%;
    animation: enche 0.45s cubic-bezier(0.3, 0.7, 0.2, 1) forwards;
  }
  .manchete .tk:nth-child(1) { animation-delay: 200ms; }
  .manchete .tk:nth-child(2) { animation-delay: 310ms; }
  .manchete .tk:nth-child(3) { animation-delay: 420ms; }
  .manchete .tk:nth-child(4) { animation-delay: 530ms; }
  .manchete .tk:nth-child(5) { animation-delay: 640ms; }
  .manchete .tk:nth-child(6) { animation-delay: 750ms; }
  .manchete .tk:nth-child(7) { animation-delay: 860ms; }
  .manchete .tk:nth-child(8) { animation-delay: 970ms; }
  .manchete .tk:nth-child(9) { animation-delay: 1080ms; }
}
@keyframes enche {
  to {
    background-size: 100% 100%;
  }
}
.manchete .tk:hover::after {
  content: attr(data-id);
  position: absolute;
  left: 0;
  top: -1.6em;
  font: 400 0.6875rem/1 var(--mono);
  letter-spacing: 0;
  background: var(--ink);
  color: var(--bg);
  padding: 4px 6px;
  border-radius: 4px;
  white-space: nowrap;
}
.sub {
  max-width: 58ch;
  font-size: 1.15rem;
  color: var(--muted);
}
.sub mark {
  background: none;
  color: var(--ink);
  border-bottom: 3px solid var(--c);
  transition: background-color 0.2s;
}
/* Passar o mouse numa frente acende o trecho dela na frase de abertura. */
body:has(.frente.c1:hover) .sub mark.c1,
body:has(.frente.c2:hover) .sub mark.c2,
body:has(.frente.c3:hover) .sub mark.c3,
body:has(.frente.c4:hover) .sub mark.c4 {
  background: var(--c);
}
.acoes {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.botao {
  font: 600 1rem/1 var(--body);
  padding: 15px 22px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
}
.botao.sec {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--line);
}
.botao.sec:hover {
  box-shadow: inset 0 0 0 1.5px var(--ink);
}

/* ---------- seções ---------- */
main section {
  padding-block: 64px;
  border-top: 1px solid var(--line);
}
.rotulo {
  font: 400 0.75rem/1 var(--mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 18px;
}
main h2 {
  font: 700 clamp(1.8rem, 4vw, 2.8rem)/1.1 var(--display);
  letter-spacing: -0.025em;
  max-width: 22ch;
}
.frentes {
  margin: 36px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px;
  background: var(--line);
  border-radius: 14px;
  overflow: hidden;
}
.frente {
  background: var(--surface);
  padding: 28px;
  display: grid;
  gap: 12px;
  align-content: start;
  position: relative;
}
.frente::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--c);
  transition: width 0.35s ease;
}
.frente:hover::before {
  width: 8px;
}
.frente > * {
  position: relative;
}
.chip {
  justify-self: start;
  font: 400 0.6875rem/1 var(--mono);
  background: var(--c);
  padding: 6px 8px;
  border-radius: 4px;
}
.frente h3 {
  font: 700 1.45rem/1.15 var(--display);
  letter-spacing: -0.015em;
}
.frente p {
  color: var(--muted);
}
.frente ul {
  margin: 4px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.frente li {
  font-size: 0.875rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 10px;
}

.contato {
  display: grid;
  gap: 22px;
}
.email {
  font: 700 clamp(1.5rem, 5vw, 3.4rem)/1.1 var(--display);
  letter-spacing: -0.03em;
  overflow-wrap: anywhere;
}
.email a {
  text-decoration: none;
}
.email a:hover .tk {
  text-decoration: underline;
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}
.contato p:last-child {
  color: var(--muted);
}

.rodape {
  padding-block: 28px 40px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

/* ---------- 404 ---------- */
.erro {
  padding-block: 72px 96px;
  display: grid;
  gap: 24px;
}

@media (max-width: 760px) {
  .frentes {
    grid-template-columns: minmax(0, 1fr);
  }
  .topo nav {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .frente::before,
  .sub mark {
    transition: none;
  }
}
@media (hover: none) {
  .meta .dica {
    display: none;
  }
}
