:root {
  --paper: #f1efea;
  --paper-2: #e7e4dd;
  --ink: #0d0d0d;
  --ink-soft: #55524c;
  --line: #cfcbc2;
  --red: #e3120b;
  --red-deep: #8d0702;

  --font: 'Archivo', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;

  --gutter: clamp(16px, 3vw, 40px);
  --max: 1440px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
::selection { background: var(--red); color: #fff; }

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.mono {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* ---------- Botão pílula ---------- */
.pill {
  display: inline-flex; align-items: center; gap: .7em;
  background: var(--ink); color: var(--paper);
  padding: .95em 1.4em; border-radius: 999px;
  text-decoration: none; white-space: nowrap;
  transition: background .25s, transform .25s;
}
.pill span { transition: transform .25s; }
.pill:hover { background: var(--red); }
.pill:hover span { transform: translateX(4px); }
.pill--big { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; padding: 1.2em 1.8em; }

/* ================= HERO ================= */
.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  overflow: hidden;
  cursor: crosshair;
  touch-action: pan-y;
}
.hero__canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hero__top, .hero__tagline, .hero__bottom, .hero__hint { position: absolute; }
.hero__bottom > .pill { justify-self: start; }
/* Texto continua legível quando a tinta preta passa por baixo */
.hero__top, .hero__tagline, .hero__meta, .hero__links, .hero__hint { color: #fff; mix-blend-mode: difference; }
.hero__bottom { pointer-events: none; }
.hero__bottom a { pointer-events: auto; }

.hero__top {
  top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px var(--gutter);
}
.logo {
  font-weight: 900; font-size: 26px; text-decoration: none; line-height: 1;
  font-stretch: 120%;
}
.logo sup { font-size: .55em; font-weight: 600; top: -.7em; position: relative; vertical-align: baseline; }
.nav { display: flex; gap: .7em; }
.nav a { text-decoration: none; position: relative; }
.nav a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .3s;
}
.nav a:hover::after { transform: scaleX(1); }

.hero__tagline {
  top: 74px; left: var(--gutter);
  font-size: clamp(14px, 1.15vw, 17px);
  font-weight: 500; line-height: 1.3; max-width: 30em;
}

.hero__bottom {
  bottom: 0; left: 0; right: 0;
  padding: 22px var(--gutter);
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
}
.hero__meta { text-align: center; }
.hero__links { text-align: right; }
.hero__links a { text-decoration: none; }
.hero__links a:hover { color: var(--red); }

.hero__hint {
  left: 50%; top: 74px; transform: translateX(-50%);
  color: var(--ink-soft); opacity: .8;
  transition: opacity .6s;
}
.hero.is-touched .hero__hint { opacity: 0; }

/* Entrada do topo (só com JS; sem JS o texto já aparece) */
.hero__canvas { will-change: transform; transform-origin: 50% 0; }
.js .hero:not(.is-ready) :is(.hero__top, .hero__tagline, .hero__bottom > *, .hero__hint) { opacity: 0; }
.hero.is-ready :is(.hero__top, .hero__tagline, .hero__bottom > *) { animation: heroIn 1.1s cubic-bezier(.16,.84,.24,1) backwards; }
.hero.is-ready .hero__top { animation-delay: .15s; }
.hero.is-ready .hero__tagline { animation-delay: .3s; }
.hero.is-ready .hero__bottom > :nth-child(1) { animation-delay: .5s; }
.hero.is-ready .hero__bottom > :nth-child(2) { animation-delay: .6s; }
.hero.is-ready .hero__bottom > :nth-child(3) { animation-delay: .7s; }
@keyframes heroIn { from { opacity: 0; transform: translateY(18px); } }
/* Ao rolar, os textos do topo somem aos poucos */
.hero__tagline, .hero__bottom, .hero__hint { opacity: calc(1 - var(--hp, 0) * 2.2); }
.hero.is-touched .hero__hint { opacity: 0; }

@media (max-width: 760px) {
  .nav a:not([href="#contato"]), .nav span { display: none; }
  .hero__hint { display: none; }
  .hero__bottom { grid-template-columns: 1fr auto; }
  .hero__meta { display: none; }
}

/* ================= SEÇÕES ================= */
main > section { padding-top: clamp(96px, 14vw, 180px); }

.label { color: var(--ink-soft); margin-bottom: 28px; }
.h2 {
  font-weight: 900; font-stretch: 115%;
  font-size: clamp(40px, 6.4vw, 96px);
  line-height: .92; letter-spacing: -.035em;
  text-transform: uppercase;
}
.section-head { margin-bottom: clamp(48px, 6vw, 80px); }
.section-head--row { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }

/* Manifesto */
.statement { border-top: 1px solid var(--line); padding-top: 28px; }
.statement__text {
  font-size: clamp(28px, 4.2vw, 64px);
  font-weight: 500; line-height: 1.08; letter-spacing: -.025em;
  max-width: 20ch; max-width: 22em;
  text-wrap: balance;
}
.statement__text em {
  font-style: normal; color: var(--red);
  font-weight: 800; font-stretch: 115%;
}

/* Serviços */
.services__grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--ink);
}
.service {
  padding: 32px 28px 40px 0;
  display: flex; flex-direction: column; gap: 16px;
}
.service + .service { border-left: 1px solid var(--line); padding-left: 28px; }
.service__num { color: var(--red); }
.service h3 {
  font-size: clamp(24px, 2.2vw, 32px); font-weight: 800; font-stretch: 110%;
  line-height: 1.05; letter-spacing: -.02em;
}
.service p { color: var(--ink-soft); max-width: 34ch; }
.service ul { margin-top: auto; padding-top: 16px; display: grid; gap: 10px; }
.service li { display: flex; gap: 10px; border-top: 1px dashed var(--line); padding-top: 10px; }
.service li::before { content: '+'; color: var(--red); }

@media (max-width: 900px) {
  .services__grid { grid-template-columns: 1fr; }
  .service, .service + .service { border-left: 0; padding: 32px 0 40px; }
  .service + .service { border-top: 1px solid var(--line); }
}

/* Projetos */
.filters { display: flex; gap: 6px; flex-wrap: wrap; }
.filter {
  border: 1px solid var(--ink); background: transparent;
  border-radius: 999px; padding: .8em 1.2em; cursor: pointer;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  transition: background .2s, color .2s;
}
.filter:hover { background: var(--paper-2); }
.filter.is-active { background: var(--ink); color: var(--paper); }

.projects {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: clamp(48px, 6vw, 88px) clamp(20px, 3vw, 40px);
}
.project { display: flex; flex-direction: column; gap: 22px; }
.project[hidden] { display: none; }
.project--wide { grid-column: 1 / -1; display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(20px, 3vw, 48px); align-items: end; }

.shot {
  position: relative; overflow: hidden;
  background: var(--ink); border-radius: 10px;
  padding-top: 26px;
  box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 30px 60px -30px rgba(0,0,0,.35);
}
.shot__bar { position: absolute; top: 0; left: 0; height: 26px; display: flex; gap: 6px; align-items: center; padding-left: 12px; }
.shot__bar i { width: 8px; height: 8px; border-radius: 50%; background: #3a3a3a; }
.shot__bar i:first-child { background: var(--red); }
.shot img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; transition: transform .9s cubic-bezier(.2,.7,.2,1); }
.project:hover .shot img { transform: scale(1.035); }

.project__info { display: flex; flex-direction: column; gap: 12px; }
.project__kind { color: var(--red); }
.project h3 {
  font-size: clamp(28px, 3vw, 44px); font-weight: 900; font-stretch: 112%;
  line-height: 1; letter-spacing: -.03em; text-transform: uppercase;
}
.project__info > p:not(.project__kind) { color: var(--ink-soft); max-width: 52ch; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.tags li { border: 1px solid var(--line); border-radius: 999px; padding: .5em .9em; font-size: 10px; }

@media (max-width: 900px) {
  .projects { grid-template-columns: 1fr; }
  .project--wide { grid-template-columns: 1fr; }
}


/* Quem sou eu */
.about__grid {
  display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(32px, 5vw, 88px);
  border-top: 1px solid var(--ink); padding-top: 32px;
}
.about__lead {
  font-size: clamp(26px, 3vw, 44px); font-weight: 500;
  line-height: 1.1; letter-spacing: -.025em; text-wrap: balance;
  margin-bottom: 28px;
}
.about__lead em { font-style: normal; color: var(--red); font-weight: 800; font-stretch: 115%; }
.about__intro p:not(.about__lead) { color: var(--ink-soft); max-width: 54ch; }
.about__intro p + p { margin-top: 16px; }
.about__facts { margin: 0; align-self: start; }
.about__facts div {
  display: grid; grid-template-columns: 10.5em 1fr; gap: 16px; align-items: baseline;
  padding: 18px 0; border-bottom: 1px dashed var(--line);
}
.about__facts div:first-child { padding-top: 6px; }
.about__facts dt { color: var(--red); }
.about__facts dd { margin: 0; font-weight: 600; font-size: clamp(16px, 1.25vw, 19px); line-height: 1.35; letter-spacing: -.01em; }

.secure {
  position: relative; overflow: hidden;
  margin-top: clamp(56px, 7vw, 96px);
  background: var(--ink); color: var(--paper);
  border-radius: 14px; padding: clamp(28px, 4vw, 56px);
  display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(28px, 4vw, 64px);
}
/* Linha de varredura que passa uma vez quando o bloco aparece */
.secure::after {
  content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 35%;
  background: linear-gradient(90deg, transparent, rgba(227,18,11,.22), transparent);
  transform: translateX(-110%); pointer-events: none;
}
.secure.is-in::after { animation: scan 1.6s cubic-bezier(.45,.05,.3,1) .25s; }
@keyframes scan { to { transform: translateX(320%); } }
.secure__tag { color: #8c8880; display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.secure__tag span { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(227,18,11,.6); animation: ping 2s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 9px rgba(227,18,11,0); } 100% { box-shadow: 0 0 0 0 rgba(227,18,11,0); } }
.secure h3 {
  font-size: clamp(26px, 2.8vw, 42px); font-weight: 900; font-stretch: 112%;
  line-height: 1; letter-spacing: -.03em; text-transform: uppercase; text-wrap: balance;
}
.secure__head > p:last-child { margin-top: 18px; color: #b8b4ab; max-width: 40ch; }
.secure__list { font-size: 12px; align-self: center; }
.secure__list li {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 0; border-top: 1px solid #262626;
  opacity: 0; transform: translateX(-12px);
  transition: opacity .6s, transform .6s cubic-bezier(.2,.7,.2,1);
  transition-delay: calc(.35s + var(--i) * .11s);
}
.secure__list li:last-child { border-bottom: 1px solid #262626; }
.secure__list i {
  flex: none; display: grid; place-items: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--red); color: #fff; font-style: normal; font-size: 11px;
  transform: scale(0); transition: transform .5s cubic-bezier(.3,1.6,.5,1);
  transition-delay: calc(.5s + var(--i) * .11s);
}
.secure.is-in li { opacity: 1; transform: none; }
.secure.is-in i { transform: none; }

.values {
  margin-top: clamp(56px, 7vw, 96px);
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--ink);
}
.value { padding: 24px 24px 0 0; display: flex; flex-direction: column; gap: 12px; }
.value + .value { padding-left: 24px; border-left: 1px solid var(--line); }
.value span { color: var(--red); }
.value h3 { font-size: clamp(20px, 1.7vw, 24px); font-weight: 800; font-stretch: 110%; line-height: 1.1; letter-spacing: -.02em; }
.value p { color: var(--ink-soft); }
.value:nth-child(2) { transition-delay: .08s; }
.value:nth-child(3) { transition-delay: .16s; }
.value:nth-child(4) { transition-delay: .24s; }

@media (max-width: 900px) {
  .about__grid, .secure { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr 1fr; row-gap: 32px; }
  .value:nth-child(3) { border-left: 0; padding-left: 0; }
}
@media (max-width: 520px) {
  .about__facts div { grid-template-columns: 1fr; gap: 6px; }
  .values { grid-template-columns: 1fr; }
  .value, .value + .value { border-left: 0; padding-left: 0; }
  .value + .value { border-top: 1px solid var(--line); padding-top: 24px; }
}

/* Processo */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); counter-reset: s; border-top: 1px solid var(--ink); }
.step { padding: 24px 24px 0 0; display: flex; flex-direction: column; gap: 14px; }
.step + .step { padding-left: 24px; border-left: 1px solid var(--line); }
.step span { color: var(--red); }
.step p { font-size: clamp(18px, 1.5vw, 21px); line-height: 1.3; font-weight: 500; letter-spacing: -.01em; }
@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr 1fr; row-gap: 32px; }
  .step:nth-child(3) { border-left: 0; padding-left: 0; }
}
@media (max-width: 520px) {
  .steps { grid-template-columns: 1fr; }
  .step, .step + .step { border-left: 0; padding-left: 0; }
  .step + .step { border-top: 1px solid var(--line); padding-top: 24px; }
}

.stack { margin-top: clamp(64px, 8vw, 110px); }
.stack__list { display: flex; flex-wrap: wrap; gap: 0 .35em; }
.stack__list li {
  font-size: clamp(26px, 4vw, 56px); font-weight: 800; font-stretch: 112%;
  letter-spacing: -.03em; line-height: 1.1; text-transform: uppercase;
  color: var(--ink); transition: color .2s;
}
.stack__list li:not(:last-child)::after { content: ' /'; color: var(--line); }
.stack__list li:hover { color: var(--red); }

/* Contato */
.contact {
  margin-top: clamp(96px, 14vw, 180px);
  padding: clamp(80px, 12vw, 160px) 0;
  background: var(--ink); color: var(--paper);
}
.contact .label { color: #8c8880; }
.contact__title {
  font-weight: 900; font-stretch: 118%;
  font-size: clamp(44px, 8.5vw, 140px);
  line-height: .88; letter-spacing: -.04em; text-transform: uppercase;
}
.contact__sub { margin-top: 32px; max-width: 40ch; color: #b8b4ab; font-size: clamp(17px, 1.4vw, 20px); }
.contact__actions { margin-top: 44px; display: flex; flex-wrap: wrap; gap: 20px 32px; align-items: center; }
.contact .pill { background: var(--red); color: #fff; }
.contact .pill:hover { background: var(--paper); color: var(--ink); }
.contact__mail { font-size: 13px; text-decoration: none; border-bottom: 1px solid #55524c; padding-bottom: 4px; }
.contact__mail:hover { border-color: var(--red); }

.footer {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding-top: 28px; padding-bottom: 28px;
  background: var(--ink); color: #8c8880;
  max-width: none;
}
.footer a { text-decoration: none; }
.footer a:hover { color: var(--paper); }

/* Revelar ao rolar */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s, transform .9s cubic-bezier(.2,.7,.2,1); }
.reveal.is-in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .shot img, .pill, .pill span { transition: none; }
  .hero.is-ready :is(.hero__top, .hero__tagline, .hero__bottom > *) { animation: none; }
  .secure::after, .secure__tag span { animation: none; }
  .secure__list li, .secure__list i { opacity: 1; transform: none; transition: none; }
}
