/* =============================================================
   Portfólio — Design gráfico & Vídeo
   ============================================================= */

@font-face {
  font-family: "Anton";
  src: url("../assets/fonts/anton.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("../assets/fonts/fraunces.woff2") format("woff2");
  font-weight: 300;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("../assets/fonts/montserrat.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #0a0a0b;
  --bg-2: #101012;
  --surface: #17171b;
  --surface-2: #1f1f25;
  --line: rgba(255, 255, 255, 0.09);
  --line-2: rgba(255, 255, 255, 0.18);
  --text: #f3f1ec;
  --text-2: #cfcdc6;
  --muted: #9c9ca3;
  --accent: #d4ff3a;
  --accent-2: #e4ff80;
  --accent-ink: #0a0a0b;
  --rec: #ff3b30;

  --f-display: "Anton", Impact, "Arial Narrow", sans-serif;
  --f-serif: "Fraunces", Georgia, "Times New Roman", serif;
  --f-body: "Montserrat", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --pad: clamp(16px, 4vw, 56px);
  --px: var(--pad); /* margem lateral das seções: o conteúdo ocupa a tela toda */
  --radius: 18px;
  --header-h: 72px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}
html.is-locked,
html.menu-open { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* nada pode estourar a largura da tela (no celular isso desalinha a página inteira) */
main { overflow-x: hidden; }
@supports (overflow-x: clip) { main { overflow-x: clip; } }

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
::selection { background: var(--accent); color: var(--accent-ink); }

em { font-style: normal; }

.skip {
  position: fixed; left: 16px; top: -60px; z-index: 200;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 16px; border-radius: 999px; font-weight: 600;
  transition: top 0.2s;
}
.skip:focus { top: 12px; }

.grain {
  position: fixed; inset: 0; z-index: 120; pointer-events: none; opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
  height: 52px; padding: 0 26px; border-radius: 999px;
  font-weight: 600; font-size: 15px; letter-spacing: 0.01em; white-space: nowrap;
  transition: transform 0.35s var(--ease-out), background-color 0.25s, color 0.25s, border-color 0.25s;
}
.btn svg { width: 22px; height: 22px; flex: none; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(0.98); }
.btn--accent { background: var(--accent); color: var(--accent-ink); }
.btn--accent:hover { background: var(--accent-2); }
.btn--ghost { border: 1px solid var(--line-2); color: var(--text); }
.btn--ghost:hover { border-color: var(--text); background: rgba(255, 255, 255, 0.05); }
.btn--dark { background: var(--accent-ink); color: var(--accent); }
.btn--sm { height: 42px; padding: 0 18px; font-size: 14px; }
.btn--lg { height: 64px; padding: 0 30px; font-size: 16px; }

.play-ico {
  width: 0; height: 0;
  border-left: 10px solid currentColor;
  border-top: 6px solid transparent; border-bottom: 6px solid transparent;
}

/* ---------- Topo ---------- */
.topbar {
  position: fixed; inset: 0 0 auto; z-index: 60;
  height: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  padding-top: env(safe-area-inset-top, 0px);
  padding-inline: var(--px);
  display: flex; align-items: center; gap: 24px;
  transition: background-color 0.35s, border-color 0.35s, backdrop-filter 0.35s;
  border-bottom: 1px solid transparent;
}
.topbar.is-scrolled {
  background: rgba(10, 10, 11, 0.72);
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  border-bottom-color: var(--line);
}
html.menu-open .topbar { background: var(--bg); border-bottom-color: var(--line); }

.brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-display); font-size: clamp(18px, 5.4vw, 24px); letter-spacing: 0.02em; text-transform: uppercase; line-height: 1;
  white-space: nowrap; flex: none;
}
.brand__dot {
  width: 10px; height: 10px; border-radius: 50%; background: var(--rec);
  box-shadow: 0 0 0 4px rgba(255, 59, 48, 0.18);
  animation: blink 1.6s steps(1) infinite;
}

.nav { display: flex; gap: 30px; margin-left: auto; }
.nav a {
  position: relative; padding: 6px 0;
  font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted);
  transition: color 0.25s;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent);
  transform: scaleX(0); transform-origin: right; transition: transform 0.4s var(--ease-out);
}
.nav a:hover, .nav a[aria-current="true"] { color: var(--text); }
.nav a:hover::after, .nav a[aria-current="true"]::after { transform: scaleX(1); transform-origin: left; }

.menu-toggle {
  display: none; align-items: center; gap: 12px; margin-left: auto;
  height: 44px; padding: 0 14px 0 18px; border-radius: 999px; border: 1px solid var(--line-2);
  font-size: 14px; font-weight: 600;
}
.menu-toggle__icon { position: relative; width: 18px; height: 10px; }
.menu-toggle__icon i {
  position: absolute; left: 0; right: 0; height: 2px; background: currentColor; border-radius: 2px;
  transition: transform 0.35s var(--ease-out), top 0.35s var(--ease-out);
}
.menu-toggle__icon i:first-child { top: 0; }
.menu-toggle__icon i:last-child { top: 8px; }
.menu-toggle[aria-expanded="true"] .menu-toggle__icon i:first-child { top: 4px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-toggle__icon i:last-child { top: 4px; transform: rotate(-45deg); }

.menu-mobile {
  position: fixed; inset: 0; z-index: 55;
  background: var(--bg);
  padding: calc(var(--header-h) + 24px) var(--pad) 32px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
  overflow-y: auto;
}
.menu-mobile nav { display: flex; flex-direction: column; }
.menu-mobile nav a {
  display: flex; align-items: baseline; gap: 16px;
  font-family: var(--f-display); text-transform: uppercase; font-size: clamp(2.6rem, 12vw, 4.4rem); line-height: 1.1;
  padding: 8px 0; border-bottom: 1px solid var(--line);
  animation: menu-in 0.6s var(--ease-out) both;
}
.menu-mobile nav a small { font: 500 12px var(--f-mono); color: var(--accent); letter-spacing: 0.1em; }
.menu-mobile nav a:nth-child(2) { animation-delay: 50ms; }
.menu-mobile nav a:nth-child(3) { animation-delay: 100ms; }
.menu-mobile nav a:nth-child(4) { animation-delay: 150ms; }
.menu-mobile nav a:nth-child(5) { animation-delay: 200ms; }
.menu-mobile .btn { align-self: stretch; height: 60px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 48px) var(--px) 120px;
  /* onde o mural começa: um pouco antes da metade da tela */
  --wall-x: calc(var(--pad) + (100% - 2 * var(--pad)) * 0.48);
}

/* --h vai de 0 a 1 enquanto o topo sai da tela (main.js) */
.hero__wall {
  position: absolute; z-index: -2;
  top: -30%; bottom: -30%; left: var(--wall-x); right: -6%;
  transform: rotate(calc(-9deg - var(--h, 0) * 7deg)) scale(calc(1 + var(--h, 0) * 0.2));
}
.wall { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; height: 100%; }
.wall__col { animation: wall-up var(--dur, 50s) linear infinite; will-change: transform; }
.wall__col:nth-child(2) { animation-name: wall-down; }
.wall__item {
  position: relative; aspect-ratio: 9 / 16; margin-bottom: 18px;
  border-radius: 14px; overflow: hidden; background: var(--surface);
}
.wall__item img,
.wall__item video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.hero__shade {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(90deg, var(--bg) 0%, var(--bg) calc(var(--wall-x) - 6%), rgba(10, 10, 11, 0.78) calc(var(--wall-x) + 10%), rgba(10, 10, 11, 0.2) 100%),
    linear-gradient(0deg, var(--bg) 0%, rgba(10, 10, 11, 0) 22%),
    linear-gradient(180deg, rgba(10, 10, 11, 0.85) 0%, rgba(10, 10, 11, 0) 22%);
}

.viewfinder {
  position: absolute; z-index: 1; pointer-events: none;
  inset: calc(var(--header-h) + 12px) var(--px) 28px;
  font: 500 12px var(--f-mono); letter-spacing: 0.12em; color: rgba(243, 241, 236, 0.75);
}
.vf-corner { position: absolute; width: 30px; height: 30px; border: 2px solid rgba(243, 241, 236, 0.55); }
.vf-corner--tl { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.vf-corner--tr { top: 0; right: 0; border-left: 0; border-bottom: 0; }
.vf-corner--bl { bottom: 0; left: 0; border-right: 0; border-top: 0; }
.vf-corner--br { bottom: 0; right: 0; border-left: 0; border-top: 0; }
.vf-cross { position: absolute; left: 74%; top: 48%; width: 22px; height: 22px; }
.vf-cross::before, .vf-cross::after { content: ""; position: absolute; background: rgba(243, 241, 236, 0.6); }
.vf-cross::before { left: 50%; top: 0; bottom: 0; width: 1.5px; transform: translateX(-50%); }
.vf-cross::after { top: 50%; left: 0; right: 0; height: 1.5px; transform: translateY(-50%); }
.vf-rec { position: absolute; left: 44px; bottom: 6px; display: flex; align-items: center; gap: 10px; }
.vf-rec__dot { width: 10px; height: 10px; border-radius: 50%; background: var(--rec); animation: blink 1.2s steps(1) infinite; }
.vf-tc { color: var(--text); font-variant-numeric: tabular-nums; }
.vf-specs { position: absolute; right: 44px; bottom: 6px; display: flex; align-items: center; gap: 8px; }
.vf-batt { position: relative; display: inline-block; width: 22px; height: 11px; border: 1.5px solid currentColor; border-radius: 2px; }
.vf-batt::after { content: ""; position: absolute; right: -4px; top: 2px; width: 2px; height: 4px; background: currentColor; }
.vf-batt i { position: absolute; inset: 1.5px; right: 30%; background: var(--accent); }

/* a primeira linha do título ("Design e vídeo") mede ~5,6em e a letra cresce com a tela (10.4vw):
   a coluna acompanha, senão a linha quebra em telas a partir de ~1880px */
.hero__content { position: relative; z-index: 2; max-width: max(1100px, 60vw); }

.hero__status {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 7px 14px 7px 12px; border-radius: 999px;
  border: 1px solid var(--line-2); background: rgba(10, 10, 11, 0.5);
  font-size: 13px; font-weight: 500; color: var(--text-2);
}
.pulse { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.pulse::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--accent);
  animation: pulse 2s var(--ease-out) infinite;
}

.eyebrow {
  margin: 26px 0 18px;
  font-size: 13px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted);
}

.hero__title {
  font-family: var(--f-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(3.2rem, 10.4vw, 13rem); line-height: 0.86; letter-spacing: 0;
}
.hero__title .line { display: block; overflow: hidden; padding: 0.16em 0.1em 0.12em 0; margin: -0.16em 0 -0.12em; }
.hero__title .line > span { display: inline-block; }
.js .hero__title .line > span { transform: translateY(110%); animation: rise 1.1s var(--ease-out) forwards; }
.js .hero__title .line:nth-child(2) > span { animation-delay: 0.1s; }
.js .hero__title .line:nth-child(3) > span { animation-delay: 0.2s; }
.hero__title em,
.section-title em,
.about__statement em,
.contact__title em,
.cta__title em {
  font-family: var(--f-serif); font-style: italic; font-weight: 300;
  text-transform: none; color: var(--accent); letter-spacing: -0.02em;
}
.hero__title em { font-size: 1.08em; padding-right: 0.04em; }
.accent-dot { color: var(--accent); font-weight: 400; }

.hero__lead {
  max-width: 36ch; margin: 30px 0 36px;
  font-size: clamp(1.05rem, 1.35vw, 1.25rem); line-height: 1.55; color: var(--text-2);
}
.js .hero__lead, .js .hero__actions, .js .hero__status, .js .eyebrow { animation: fade-up 1s var(--ease-out) 0.35s both; }
.js .hero__actions { animation-delay: 0.45s; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero__scroll {
  position: absolute; left: 50%; bottom: 30px; z-index: 2; transform: translateX(-50%);
  width: 26px; height: 42px; border-radius: 14px; border: 1.5px solid var(--line-2);
}
.hero__scroll span {
  position: absolute; left: 50%; top: 8px; width: 3px; height: 8px; margin-left: -1.5px;
  border-radius: 2px; background: var(--accent); animation: scroll-dot 1.8s var(--ease) infinite;
}

/* ---------- Faixa ---------- */
.ticker {
  position: relative; z-index: 3;
  margin: -34px -3vw 0; padding: 16px 0;
  background: var(--accent); color: var(--accent-ink);
  transform: rotate(-2deg); overflow: hidden;
  box-shadow: 0 20px 50px -20px rgba(212, 255, 58, 0.35);
}
/* o main.js repete o conteúdo 4x: a faixa anda sozinha e acelera com a rolagem (propriedade translate) */
.ticker__track { display: flex; align-items: center; width: max-content; }
.js .ticker__track { animation: tick 40s linear infinite; }
.ticker span {
  margin-right: 30px;
  font-family: var(--f-display); text-transform: uppercase; font-size: clamp(1.6rem, 3vw, 2.6rem); line-height: 1;
}
.ticker i {
  flex: none; width: 22px; height: 22px; margin-right: 30px; background: currentColor;
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%);
}

/* ---------- Seções ---------- */
.section { position: relative; padding: clamp(96px, 12vw, 170px) var(--px); }
.section-head { display: grid; gap: 22px; margin-bottom: clamp(40px, 6vw, 72px); }
.section-tag {
  display: flex; align-items: center; gap: 12px;
  font: 500 12px/1 var(--f-mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted);
}
.section-tag span { color: var(--accent); }
.section-tag::after { content: ""; width: 60px; height: 1px; background: var(--line-2); }
.section-title {
  font-family: var(--f-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(3rem, 8vw, 9rem); line-height: 0.9;
}
.section-title em { font-size: 1.04em; }

/* ---------- Trabalhos ---------- */
.work .section-head { grid-template-columns: 1fr auto; align-items: end; }
.work .section-tag { grid-column: 1 / -1; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.filter {
  display: inline-flex; align-items: center; gap: 8px;
  height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-2);
  font-size: 14px; font-weight: 500; color: var(--text-2);
  transition: background-color 0.25s, color 0.25s, border-color 0.25s;
}
.filter sup { font: 500 11px var(--f-mono); color: var(--muted); top: 0; }
.filter:hover { border-color: var(--text); color: var(--text); }
.filter[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.filter[aria-pressed="true"] sup { color: inherit; opacity: 0.6; }

.work-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 3vw, 40px) clamp(16px, 2vw, 28px);
  grid-auto-flow: dense;
}

.card { position: relative; display: flex; flex-direction: column; gap: 18px; }
.card--wide { grid-column: span 2; }

.card__stage {
  --shade: 58%;
  position: relative; isolation: isolate; overflow: hidden;
  height: clamp(420px, 40vw, 720px); border-radius: var(--radius);
  background:
    radial-gradient(120% 95% at 50% 105%,
      color-mix(in oklab, var(--stage) 92%, white) 0%,
      var(--stage) 30%,
      color-mix(in oklab, var(--stage) var(--shade), black) 100%);
  transition: border-radius 0.5s var(--ease-out);
}
.card--light .card__stage { --shade: 80%; }
.card__stage::before {
  content: ""; position: absolute; inset: 0; z-index: 0; opacity: 0.35;
  background-image: radial-gradient(rgba(255, 255, 255, 0.35) 1px, transparent 1.3px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(80% 70% at 50% 40%, #000, transparent);
  mask-image: radial-gradient(80% 70% at 50% 40%, #000, transparent);
}
.card--light .card__stage::before { background-image: radial-gradient(rgba(0, 0, 0, 0.25) 1px, transparent 1.3px); }

.card__word {
  position: absolute; left: 50%; top: 50%; z-index: 0;
  transform: translate(-50%, -50%);
  font-family: var(--f-display); text-transform: uppercase; white-space: nowrap; line-height: 1;
  font-size: clamp(6rem, 13vw, 13rem);
  color: transparent; -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.28);
  transition: transform 1.2s var(--ease-out);
}
.card--light .card__word { -webkit-text-stroke-color: rgba(0, 0, 0, 0.22); }
.card:hover .card__word { transform: translate(-54%, -50%); }

.stage { position: absolute; inset: 0; z-index: 1; display: grid; place-items: center; }

.phone {
  --x: 0; --r: 0; --s: 1;
  position: absolute; margin: 0;
  height: var(--ph, 78%); aspect-ratio: 9 / 16;
  border-radius: clamp(10px, 1.2vw, 16px); overflow: hidden; background: #000;
  box-shadow: 0 30px 60px -18px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.08);
  transform: translateX(calc(var(--x) * 1%)) rotate(calc(var(--r) * 1deg)) scale(var(--s));
  transition: transform 0.8s var(--ease-out);
}
.phone img,
.phone video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* vídeos do mural: aparecem quando começam a tocar */
.wall__item video { opacity: 0; transition: opacity 0.45s; }
.wall__item.is-playing > video { opacity: 1; }

/* celulares e o fundo acompanham o mouse (--mx/--my de -1 a 1), cada um numa profundidade --z */
.phone { translate: calc(var(--mx, 0) * var(--z, 12px)) calc(var(--my, 0) * var(--z, 12px)); }
.stage--1 .phone,
.stage--2 .phone { --z: 18px; }
.stage--3 .phone:nth-child(2) { --z: 24px; }
.shot { translate: calc(var(--mx, 0) * var(--z, 14px)) calc(var(--my, 0) * var(--z, 14px)); }
.shot:nth-child(2) { --z: 28px; }

.stage--1 .phone { --r: -3; }
.card:hover .stage--1 .phone { --r: 0; --s: 1.03; }

.stage--2 { --ph: 64%; }
.stage--2 .phone:nth-child(1) { --x: -40; --r: -6; }
.stage--2 .phone:nth-child(2) { --x: 40; --r: 6; }
.card:hover .stage--2 .phone:nth-child(1) { --x: -47; --r: -3; }
.card:hover .stage--2 .phone:nth-child(2) { --x: 47; --r: 3; }

.stage--3 { --ph: 72%; }
.stage--3 .phone:nth-child(1) { --x: -58; --r: -9; --s: 0.86; }
.stage--3 .phone:nth-child(2) { z-index: 2; }
.stage--3 .phone:nth-child(3) { --x: 58; --r: 9; --s: 0.86; }
.card:hover .stage--3 .phone:nth-child(1) { --x: -76; --r: -5; --s: 0.9; }
.card:hover .stage--3 .phone:nth-child(2) { --s: 1.03; }
.card:hover .stage--3 .phone:nth-child(3) { --x: 76; --r: 5; --s: 0.9; }

@media (min-width: 641px) {
  .card--wide .stage--3 { --ph: 78%; }
  .card--wide .stage--3 .phone:nth-child(1) { --x: -112; --r: -4; --s: 0.9; }
  .card--wide .stage--3 .phone:nth-child(3) { --x: 112; --r: 4; --s: 0.9; }
  .card--wide:hover .stage--3 .phone:nth-child(1) { --x: -118; --r: 0; --s: 0.94; }
  .card--wide:hover .stage--3 .phone:nth-child(3) { --x: 118; --r: 0; --s: 0.94; }
}

/* palco horizontal (sites, logos, embalagens) */
.shot {
  position: absolute; margin: 0; overflow: hidden; background: #000;
  border-radius: 12px;
  box-shadow: 0 40px 70px -24px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(0, 0, 0, 0.08);
  transition: transform 0.9s var(--ease-out);
}
.shot img { width: 100%; height: auto; }
.shot--browser { width: 72%; left: 7%; top: 13%; transform: rotate(-3deg); background: #111; }
.shot__bar { display: flex; gap: 6px; padding: 9px 12px; background: #1b1b1f; }
.shot__bar i { width: 8px; height: 8px; border-radius: 50%; background: #3a3a42; }
.shot__bar i:first-child { background: #ff5f57; }
.shot:nth-child(2) { width: 38%; right: 5%; bottom: 9%; transform: rotate(6deg); border-radius: 10px; }
.card:hover .shot--browser { transform: rotate(0) translateY(-2%) scale(1.02); }
.card:hover .shot:nth-child(2) { transform: rotate(2deg) translate(-4%, -6%); }

.card__badge {
  position: absolute; left: 16px; top: 16px; z-index: 3;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 12px; border-radius: 999px;
  background: rgba(10, 10, 11, 0.72); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  font: 500 11px var(--f-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text);
}
.card__badge .tri { width: 0; height: 0; border-left: 7px solid var(--accent); border-top: 4.5px solid transparent; border-bottom: 4.5px solid transparent; }
.card__badge .sq { width: 8px; height: 8px; border-radius: 2px; background: var(--accent); }

.card__arrow {
  position: absolute; right: 16px; top: 16px; z-index: 3;
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center; font-size: 20px;
  background: var(--bg); color: var(--text);
  transition: background-color 0.3s, color 0.3s, transform 0.5s var(--ease-out);
}
.card:hover .card__arrow { background: var(--accent); color: var(--accent-ink); transform: rotate(45deg); }

.card__meta { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; padding: 0 4px; }
.card__client { font: 500 12px var(--f-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-2); }
.card__client span { color: var(--muted); }
.card__year { grid-row: 1; grid-column: 2; font: 500 12px var(--f-mono); color: var(--muted); }
.card__title {
  grid-column: 1 / -1;
  font-size: clamp(1.25rem, 1.7vw, 1.6rem); font-weight: 600; line-height: 1.2; letter-spacing: -0.01em;
  transition: color 0.25s;
}
.card:hover .card__title { color: var(--accent); }
.card__tags { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.card__tags li { padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 12px; color: var(--text-2); }

/* card de chamada */
.card--cta .card__stage {
  flex: 1; min-height: 340px; height: auto;
  display: flex; flex-direction: column; justify-content: space-between; gap: 24px;
  padding: clamp(24px, 3vw, 36px);
  background: var(--accent); color: var(--accent-ink);
}
.card--cta .card__stage::before { display: none; }
.cta__kicker { font: 500 12px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; }
.cta__title {
  font-family: var(--f-display); text-transform: uppercase; font-weight: 400;
  font-size: clamp(3rem, 5.2vw, 5.4rem); line-height: 0.9;
}
.cta__title em { color: var(--accent-ink); font-size: 1.06em; }
.card--cta .btn { align-self: flex-start; }
.card--cta:hover .btn { transform: translateY(-2px); }

/* ---------- Reels ---------- */
/* a faixa de filme vai de ponta a ponta; só o título respeita a coluna central */
.reels { overflow: hidden; padding-inline: 0; }
.reels .section-head { padding-inline: var(--px); }
.section-head--row { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 24px; }
.section-head--row > div:first-child { display: grid; gap: 22px; }
.reels__ctrl { display: flex; align-items: center; gap: 10px; }
.reels__hint { margin-right: 10px; font-size: 13px; color: var(--muted); }
.round-btn {
  width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--line-2);
  display: grid; place-items: center; font-size: 18px;
  transition: background-color 0.25s, color 0.25s, border-color 0.25s, opacity 0.25s;
}
.round-btn:hover:not(:disabled) { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.round-btn:disabled { opacity: 0.3; cursor: default; }

.filmstrip {
  position: relative;
  padding: 38px 0;
  background: #050506;
  border-block: 1px solid var(--line);
}
.filmstrip::before,
.filmstrip::after {
  content: ""; position: absolute; left: 0; right: 0; height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='34' height='14'%3E%3Crect x='9' y='1' width='16' height='12' rx='3' fill='%2322222a'/%3E%3C/svg%3E") repeat-x;
}
.filmstrip::before { top: 12px; }
.filmstrip::after { bottom: 12px; }

.filmstrip__track {
  display: flex; gap: 18px; overflow-x: auto;
  padding: 0 var(--px); scroll-padding: 0 var(--px);
  scroll-snap-type: x mandatory; scrollbar-width: none;
  cursor: grab;
}
.filmstrip__track::-webkit-scrollbar { display: none; }
.filmstrip__track.is-dragging { scroll-snap-type: none; cursor: grabbing; user-select: none; }
.filmstrip__track.is-dragging .reel { pointer-events: none; }

.reel { flex: 0 0 auto; width: clamp(190px, 21vw, 280px); scroll-snap-align: start; text-align: left; }
.reel__frame {
  position: relative; display: block; aspect-ratio: 9 / 16;
  border-radius: 12px; overflow: hidden; background: var(--surface);
}
.reel__frame img,
.reel__frame video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.reel__frame img { transition: transform 0.8s var(--ease-out), filter 0.5s; filter: saturate(0.85) brightness(0.88); }
.reel:hover .reel__frame img,
.reel:hover .reel__frame video { transform: scale(1.04); filter: none; }
.reel__num {
  position: absolute; left: 12px; top: 12px; z-index: 2;
  font: 500 11px var(--f-mono); letter-spacing: 0.12em;
  padding: 5px 9px; border-radius: 999px; background: rgba(10, 10, 11, 0.7);
}
.reel__play {
  position: absolute; left: 50%; top: 50%; z-index: 2;
  width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%;
  background: var(--accent); display: grid; place-items: center;
  transition: transform 0.45s var(--ease-out), opacity 0.3s;
}
.reel__play::before {
  content: ""; margin-left: 4px;
  border-left: 16px solid var(--accent-ink); border-top: 10px solid transparent; border-bottom: 10px solid transparent;
}
.reel:hover .reel__play { transform: scale(1.12); }
.reel.is-preview .reel__play { opacity: 0; transform: scale(0.5); }
/* ---------- Prévia ao passar o mouse ---------- */
/* o vídeo (ou a próxima peça) sobe como uma cortina, puxada por uma linha verde */
.phone video,
.reel__frame video {
  clip-path: inset(100% 0 0 0);
  transition: clip-path 0.75s var(--ease-out), transform 0.8s var(--ease-out);
}
.phone.is-playing > video,
.reel__frame.is-playing > video { clip-path: inset(0); }

.phone .flip,
.shot .flip {
  position: absolute; left: 0; bottom: 0; width: 100%; height: 100%; object-fit: cover;
  animation: cortina 0.75s var(--ease-out) both;
  transition: opacity 0.4s;
}
.shot--browser .flip { height: calc(100% - 26px); }
.flip.sai { opacity: 0; }

.phone::after,
.shot::after,
.reel__frame::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; height: 2px;
  background: var(--accent); box-shadow: 0 0 16px 2px var(--accent);
  opacity: 0; pointer-events: none;
}
.phone.is-playing::after,
.reel__frame.is-playing::after,
.varre::after { animation: varredura 0.75s var(--ease-out); }

.card__rec,
.reel__rec {
  position: absolute; left: 16px; bottom: 18px; z-index: 3;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 11px; border-radius: 999px;
  background: rgba(10, 10, 11, 0.72); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  font: 500 11px var(--f-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text);
  opacity: 0; translate: 0 10px;
  transition: opacity 0.3s, translate 0.5s var(--ease-out);
}
.reel__rec { left: 10px; bottom: 14px; }
.card__rec i,
.reel__rec i { width: 8px; height: 8px; border-radius: 50%; background: var(--rec); animation: blink 1.2s steps(1) infinite; }
.card__rec b,
.reel__rec b { font-weight: 500; color: var(--accent); font-variant-numeric: tabular-nums; }

.card__progress,
.reel__progress {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; height: 4px;
  background: rgba(255, 255, 255, 0.16); opacity: 0; transition: opacity 0.3s;
}
.card__progress i,
.reel__progress i { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(0); }
.card[data-previa="imagens"] .card__progress i { transition: transform 0.6s var(--ease-out); }
.card--light .card__progress { background: rgba(0, 0, 0, 0.14); }
.card--light .card__progress i { background: var(--accent-ink); }

.is-preview .card__rec,
.is-preview .reel__rec { opacity: 1; translate: 0 0; }
.is-preview .card__progress,
.is-preview .reel__progress { opacity: 1; }

.reel__cap { display: flex; flex-direction: column; gap: 2px; margin-top: 14px; padding: 0 2px; }
.reel__cap small { font: 500 11px var(--f-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.reel__cap strong { font-size: 15px; font-weight: 600; line-height: 1.3; }

/* ---------- Serviços ---------- */
.service-list { border-top: 1px solid var(--line); }
.service {
  position: relative;
  display: grid; grid-template-columns: 72px minmax(0, 1.15fr) minmax(0, 1fr);
  grid-template-areas: "num title desc" "num title tags";
  gap: 14px 40px; align-items: start;
  padding: clamp(28px, 3.5vw, 44px) 0; border-bottom: 1px solid var(--line);
}
.service::before {
  content: ""; position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform 0.7s var(--ease-out);
}
.service:hover::before { transform: scaleX(1); }
.service__num { grid-area: num; padding-top: 0.7em; font: 500 13px var(--f-mono); color: var(--accent); letter-spacing: 0.1em; }
.service__title {
  grid-area: title;
  font-family: var(--f-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.3rem, 5vw, 4.6rem); line-height: 0.95;
  transition: transform 0.6s var(--ease-out), color 0.3s;
}
.service:hover .service__title { transform: translateX(14px); color: var(--accent); }
.service__desc { grid-area: desc; color: var(--text-2); max-width: 46ch; padding-top: 0.5em; }
.service__tags { grid-area: tags; display: flex; flex-wrap: wrap; gap: 6px; }
.service__tags li { padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 12px; color: var(--text-2); }

/* ---------- Sobre ---------- */
.about__grid {
  display: grid; grid-template-columns: minmax(260px, 400px) minmax(0, 1fr);
  gap: clamp(48px, 7vw, 110px); align-items: start;
}

.slate { position: relative; width: 100%; max-width: 400px; rotate: -4deg; margin-top: 20px; }
.slate__clap,
.slate__hinge { height: 54px; overflow: hidden; border: 2px solid var(--text); }
.slate__clap {
  border-radius: 10px 10px 0 0; border-bottom: 0;
  transform-origin: 2px 100%; transform: rotate(-16deg);
  transition: transform 0.35s cubic-bezier(0.6, 0, 0.9, 0.4);
}
.slate.is-in .slate__clap { transform: rotate(0); transition-delay: 0.5s; }
.slate:hover .slate__clap { animation: clap 0.7s var(--ease) both; }
.slate__stripes {
  height: 100%;
  background: repeating-linear-gradient(-55deg, var(--text) 0 24px, var(--bg) 24px 48px);
}
.slate__hinge .slate__stripes { background: repeating-linear-gradient(55deg, var(--text) 0 24px, var(--bg) 24px 48px); }
.slate__body {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px;
  background: var(--text); border: 2px solid var(--text); border-top: 0; border-radius: 0 0 12px 12px; overflow: hidden;
}
.slate__row { display: flex; flex-direction: column; gap: 4px; padding: 14px 18px 16px; background: #121215; }
.slate__row--full { grid-column: 1 / -1; }
.slate__row small { font: 500 10px var(--f-mono); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.slate__row strong { font-family: var(--f-display); font-weight: 400; text-transform: uppercase; font-size: 1.5rem; line-height: 1.05; }
.slate__row--full strong { font-size: clamp(2.6rem, 4vw, 3.4rem); color: var(--accent); }

.about__statement {
  font-family: var(--f-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(2.3rem, 4.6vw, 4.6rem); line-height: 0.95; margin-bottom: 28px;
}
.about__statement em { font-size: 1.06em; }
.about__text > p { max-width: 60ch; font-size: 1.1rem; color: var(--text-2); }

.stats { display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 56px); margin: 40px 0; padding: 28px 0; border-block: 1px solid var(--line); }
.stats li { display: flex; flex-direction: column; gap: 6px; }
.stats strong { font-family: var(--f-display); font-weight: 400; font-size: clamp(3rem, 5vw, 4.6rem); line-height: 1; font-variant-numeric: tabular-nums; }
.stats span { font: 500 11px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

.about__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.mini-title { margin-bottom: 14px; font: 500 12px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { padding: 8px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-size: 14px; }

.process { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: clamp(72px, 9vw, 120px); }
.process li {
  position: relative; padding: 28px; border-radius: var(--radius);
  background: var(--bg-2); border: 1px solid var(--line);
  transition: border-color 0.3s, transform 0.5s var(--ease-out);
}
.process li:hover { border-color: rgba(212, 255, 58, 0.5); transform: translateY(-4px); }
.process span { font-family: var(--f-display); font-size: 3.4rem; line-height: 1; color: transparent; -webkit-text-stroke: 1.2px var(--accent); }
.process h3 { margin: 18px 0 8px; font-size: 1.25rem; font-weight: 600; }
.process p { font-size: 0.95rem; color: var(--muted); }

/* ---------- Contato ---------- */
.contact { overflow: hidden; padding-bottom: clamp(110px, 14vw, 190px); }
.contact::before {
  content: ""; position: absolute; z-index: -1; pointer-events: none;
  width: 70vw; aspect-ratio: 1; right: -24vw; bottom: -40vw; border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 255, 58, 0.16), transparent 62%);
}
.contact__title {
  display: flex; flex-direction: column; margin: 28px 0 34px;
  font-family: var(--f-display); font-weight: 400; text-transform: uppercase;
  font-size: clamp(4rem, 14.5vw, 15rem); line-height: 0.86;
}
.contact__title span:nth-child(2) { padding-left: 9vw; }
.contact__title em { font-size: 1.06em; }
.contact__lead { max-width: 46ch; margin-bottom: 40px; font-size: 1.2rem; color: var(--text-2); }
.contact__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Rodapé ---------- */
.footer {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px;
  padding: 28px var(--px); border-top: 1px solid var(--line);
  font-size: 14px; color: var(--muted);
}
.footer__top { color: var(--text); font-weight: 600; }
.footer__top:hover { color: var(--accent); }

/* ---------- Visualizador ---------- */
.viewer {
  width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: rgba(8, 8, 9, 0.98); color: var(--text);
  overflow: hidden;
}
/* coluna presa à largura da tela: sem isso, um título de peça comprido alargava tudo no celular */
.viewer[open] { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); animation: fade-in 0.35s var(--ease-out); }
.viewer::backdrop { background: rgba(0, 0, 0, 0.75); }

.viewer__bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px var(--pad); border-bottom: 1px solid var(--line);
}
.viewer__count { display: flex; align-items: center; gap: 16px; min-width: 0; font: 500 13px var(--f-mono); letter-spacing: 0.08em; }
.viewer__piece { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.viewer__close {
  display: inline-flex; align-items: center; gap: 10px; flex: none;
  height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-2);
  font-size: 14px; font-weight: 600;
  transition: background-color 0.25s, color 0.25s, border-color 0.25s;
}
.viewer__close:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

.viewer__body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 400px); min-height: 0; }
.viewer__stage {
  position: relative; min-height: 0;
  display: flex; align-items: center; justify-content: center;
  padding: 24px 92px; touch-action: pan-y;
}
.viewer__media { width: 100%; height: 100%; min-height: 0; display: flex; align-items: center; justify-content: center; }
.viewer__media.is-enter > * { animation: media-in 0.5s var(--ease-out); }
.viewer__media video,
.viewer__media img {
  max-width: 100%; max-height: 100%; width: auto; height: auto;
  border-radius: 14px; background: #000;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.8);
}
.viewer__media video { height: 100%; aspect-ratio: 9 / 16; }
.viewer__media iframe { width: 100%; max-height: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 14px; }

.viewer__nav {
  position: absolute; top: 50%; z-index: 2; transform: translateY(-50%);
  width: 56px; height: 56px; border-radius: 50%;
  border: 1px solid var(--line-2); background: rgba(10, 10, 11, 0.6);
  display: grid; place-items: center; font-size: 20px;
  transition: background-color 0.25s, color 0.25s, border-color 0.25s;
}
.viewer__nav:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.viewer__nav--prev { left: 20px; }
.viewer__nav--next { right: 20px; }

.viewer__info {
  display: flex; flex-direction: column; gap: 20px;
  padding: 32px; border-left: 1px solid var(--line); overflow-y: auto;
}
.viewer__client { font: 500 12px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.viewer__title { font-family: var(--f-display); font-weight: 400; text-transform: uppercase; font-size: clamp(2rem, 2.8vw, 2.8rem); line-height: 0.95; }
.viewer__desc { font-size: 0.97rem; color: var(--text-2); }
.viewer__meta { display: grid; gap: 12px; margin: 0; padding: 18px 0; border-block: 1px solid var(--line); }
.viewer__meta div { display: grid; grid-template-columns: 88px 1fr; gap: 12px; }
.viewer__meta dt { font: 500 11px/1.9 var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.viewer__meta dd { margin: 0; font-size: 14px; }

.viewer__thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(58px, 1fr)); gap: 8px; }
.thumb {
  position: relative; aspect-ratio: 9 / 16; border-radius: 8px; overflow: hidden; background: var(--surface);
  opacity: 0.45; outline: 2px solid transparent; outline-offset: 2px;
  transition: opacity 0.25s, outline-color 0.25s;
}
.viewer--h .thumb { aspect-ratio: 4 / 3; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb:hover { opacity: 0.85; }
.thumb[aria-current="true"] { opacity: 1; outline-color: var(--accent); }
.thumb__play {
  position: absolute; left: 50%; top: 50%; transform: translate(-40%, -50%);
  border-left: 10px solid #fff; border-top: 6px solid transparent; border-bottom: 6px solid transparent;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6));
}

.viewer__next-project {
  margin-top: auto; display: flex; flex-direction: column; gap: 4px; text-align: left;
  padding: 18px 20px; border-radius: 14px; background: var(--surface);
  transition: background-color 0.25s, color 0.25s;
}
.viewer__next-project small { font: 500 11px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.viewer__next-project span { font-weight: 600; }
.viewer__next-project:hover { background: var(--accent); color: var(--accent-ink); }
.viewer__next-project:hover small { color: inherit; opacity: 0.6; }

/* ---------- Toast & cursor ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 130;
  max-width: calc(100vw - 32px);
  padding: 12px 20px; border-radius: 999px;
  background: var(--text); color: var(--bg); font-size: 14px; font-weight: 600;
  transform: translate(-50%, calc(100% + 40px)); visibility: hidden;
  transition: transform 0.45s var(--ease-out), visibility 0s 0.45s;
}
.toast a { text-decoration: underline; margin-left: 8px; }
.toast.is-show { transform: translate(-50%, 0); visibility: visible; transition-delay: 0s; }

.cursor-label {
  position: fixed; left: 0; top: 0; z-index: 110; pointer-events: none;
  width: 92px; height: 92px; border-radius: 50%;
  display: grid; place-items: center; text-align: center;
  background: var(--accent); color: var(--accent-ink);
  font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; line-height: 1.15;
  transform: translate3d(-200px, -200px, 0) scale(0);
  will-change: transform;
}
@media not all and (hover: hover) and (pointer: fine) { .cursor-label { display: none; } }

/* ---------- Revelar ao rolar ---------- */
.js .reveal { opacity: 0; transform: translateY(30px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); transition-delay: var(--d, 0ms); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- Animação de entrada ----------
   O <head> liga html.is-intro; o main.js roda a sequência (contagem 3-2-1 → nome → cortina abre). */
.intro { display: none; }
html.is-intro { overflow: hidden; }
html.is-intro .intro,
.intro.intro--out { display: block; }
.intro { position: fixed; inset: 0; z-index: 300; cursor: pointer; }
.intro--out { pointer-events: none; }

.intro__half {
  position: absolute; left: 0; right: 0; height: 50.5%; background: var(--bg);
  transition: transform 0.9s cubic-bezier(0.76, 0, 0.24, 1);
}
.intro__half--top { top: 0; }
.intro__half--bottom { bottom: 0; }
.intro--out .intro__half--top { transform: translateY(-101%); }
.intro--out .intro__half--bottom { transform: translateY(101%); }
.intro__seam {
  position: absolute; left: 0; right: 0; top: 50%; height: 2px; margin-top: -1px;
  background: var(--accent); box-shadow: 0 0 30px 4px rgba(212, 255, 58, 0.6);
  transform: scaleX(0); opacity: 0;
}
.intro--out .intro__seam { animation: seam 0.8s var(--ease-out) forwards; }

.intro__stage { position: absolute; inset: 0; transition: opacity 0.3s; }
.intro--out .intro__stage { opacity: 0; }

.intro__corner { position: absolute; width: 36px; height: 36px; border: 2px solid var(--text); opacity: 0; }
.intro__corner--tl { top: 24px; left: 24px; border-right: 0; border-bottom: 0; --cx: 1; --cy: 1; }
.intro__corner--tr { top: 24px; right: 24px; border-left: 0; border-bottom: 0; --cx: -1; --cy: 1; }
.intro__corner--bl { bottom: 24px; left: 24px; border-right: 0; border-top: 0; --cx: 1; --cy: -1; }
.intro__corner--br { bottom: 24px; right: 24px; border-left: 0; border-top: 0; --cx: -1; --cy: -1; }
.is-on .intro__corner { opacity: 1; animation: intro-corner 0.9s var(--ease-out) both; }

.intro__rec, .intro__skip {
  position: absolute; display: flex; align-items: center; gap: 10px;
  font: 500 12px var(--f-mono); letter-spacing: 0.14em; text-transform: uppercase; opacity: 0;
}
.intro__rec { left: 76px; top: 34px; color: var(--text); }
.intro__rec i { width: 10px; height: 10px; border-radius: 50%; background: var(--rec); animation: blink 0.8s steps(1) infinite; }
.intro__skip { right: 76px; bottom: 34px; color: var(--muted); }
.is-on .intro__rec, .is-on .intro__skip { opacity: 1; transition: opacity 0.4s 0.3s; }

.intro__leader {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%;
  width: min(54vmin, 340px); aspect-ratio: 1; border-radius: 50%;
  display: grid; place-items: center; opacity: 0;
  transition: opacity 0.3s, scale 0.5s var(--ease-out);
}
.intro__leader::before,
.intro__leader::after { content: ""; position: absolute; border-radius: 50%; border: 2px solid rgba(243, 241, 236, 0.55); }
.intro__leader::before { inset: 0; }
.intro__leader::after { inset: 9%; border-width: 1px; border-color: rgba(243, 241, 236, 0.25); }
.intro__cross { position: absolute; inset: -14%; }
.intro__cross::before,
.intro__cross::after { content: ""; position: absolute; background: rgba(243, 241, 236, 0.3); }
.intro__cross::before { left: 50%; top: 0; bottom: 0; width: 1px; }
.intro__cross::after { top: 50%; left: 0; right: 0; height: 1px; }
.intro__sweep { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(rgba(212, 255, 58, 0.3) var(--sweep), transparent 0); }
.intro__count { position: relative; font-family: var(--f-display); font-size: min(30vmin, 190px); line-height: 1; }
.intro__count.tick { animation: count-pop 0.38s var(--ease-out); }
.is-on .intro__leader { opacity: 1; animation: leader-in 0.45s var(--ease-out) backwards; }
.is-on .intro__sweep { animation: sweep 0.38s linear 3 both; }
/* a contagem some depressa e o nome só sobe depois, para os dois não se cruzarem */
.is-name .intro__leader { opacity: 0; scale: 1.3; transition-duration: 0.16s, 0.5s; }

.intro__name {
  position: absolute; left: 0; right: 0; top: 50%; translate: 0 -50%;
  overflow: hidden; padding: 0.12em 0; text-align: center; white-space: nowrap;
  font-family: var(--f-display); text-transform: uppercase; line-height: 1;
  font-size: clamp(2.4rem, 8.5vw, 8.5rem);
}
.intro__name .ch { display: inline-block; transform: translateY(120%); }
.intro__name .sp { display: inline-block; width: 0.26em; }
.intro__name .ch:last-child { color: var(--accent); }
.is-name .intro__name .ch { animation: rise 0.6s var(--ease-out) forwards; animation-delay: calc(140ms + var(--i) * 22ms); }
.intro__role {
  position: absolute; left: 0; right: 0; top: calc(50% + clamp(2.2rem, 6.5vw, 5.6rem)); text-align: center;
  font: 500 12px var(--f-mono); letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted);
  opacity: 0; transition: opacity 0.5s 0.35s;
}
.is-name .intro__role { opacity: 1; }
.intro__load {
  position: absolute; left: 0; bottom: 0; width: 100%; height: 3px;
  background: var(--accent); transform-origin: left; transform: scaleX(0);
}
.is-on .intro__load { animation: load 2.25s linear forwards; }

/* o topo só começa a animar quando a cortina abre */
.is-intro .hero__title .line > span,
.is-intro .hero__lead,
.is-intro .hero__actions,
.is-intro .hero__status,
.is-intro .eyebrow { animation-play-state: paused; }

@property --sweep { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
@keyframes sweep { from { --sweep: 0deg; } to { --sweep: 360deg; } }
@keyframes intro-corner { from { transform: translate(calc(var(--cx) * (50vw - 70px)), calc(var(--cy) * (50vh - 70px))); opacity: 0; } }
@keyframes leader-in { from { opacity: 0; scale: 0.7; } }
@keyframes count-pop { from { transform: scale(1.3); opacity: 0.2; } }
@keyframes load { to { transform: scaleX(1); } }
@keyframes seam { 0% { transform: scaleX(0); opacity: 1; } 40% { transform: scaleX(1); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }

/* ---------- Animações que acompanham a rolagem ----------
   O main.js grava o progresso de cada bloco em variáveis CSS:
   --h (topo saindo da tela), --p (bloco atravessando a tela, 0→1), --e (bloco entrando, 0→1), --a (perto do meio da tela). */
.scroll-progress {
  position: fixed; left: 0; top: env(safe-area-inset-top, 0px); z-index: 70; width: 100%; height: 3px;
  background: var(--accent); transform-origin: left; transform: scaleX(0); pointer-events: none;
}
.hero__content { translate: 0 calc(var(--h, 0) * 16vh); opacity: calc(1 - var(--h, 0) * 1.3); }
.viewfinder { scale: calc(1 - var(--h, 0) * 0.08); opacity: calc(1 - var(--h, 0) * 1.8); }
.hero__scroll { opacity: calc(1 - var(--h, 0) * 3); }

.section-title { translate: calc((0.5 - var(--p, 0.5)) * 9vw) 0; }
.card .stage { translate: 0 calc((0.5 - var(--p, 0.5)) * 60px); }
.card__word { translate: calc((0.5 - var(--p, 0.5)) * 40% - var(--mx, 0) * 26px) calc(var(--my, 0) * -14px); }
.filmstrip::before, .filmstrip::after { background-position-x: calc(var(--p, 0) * -680px); }
.service__title { opacity: calc(0.28 + var(--a, 1) * 0.72); }
.service::before { transform: scaleX(clamp(0, calc((var(--a, 0) - 0.55) * 2.6), 1)); }
.slate { rotate: calc(-4deg + (var(--p, 0.5) - 0.5) * 12deg); }
.about__statement.is-scrub .w { opacity: 0.16; transition: opacity 0.35s; }
.about__statement.is-scrub .w.on { opacity: 1; }
.process { position: relative; }
.process::before,
.process::after { content: ""; position: absolute; left: 0; right: 0; top: -32px; height: 2px; }
.process::before { background: var(--line); }
.process::after { background: var(--accent); transform-origin: left; transform: scaleX(var(--e, 1)); }
.process span { transition: color 0.4s; }
.process li.on span { color: var(--accent); }
.contact__title span:nth-child(1) { translate: calc((1 - var(--e, 1)) * -16vw) 0; }
.contact__title span:nth-child(2) { translate: calc((1 - var(--e, 1)) * 16vw) 0; }

/* ---------- Animações ---------- */
@keyframes blink { 50% { opacity: 0.15; } }
@keyframes pulse { from { transform: scale(0.6); opacity: 1; } to { transform: scale(1.8); opacity: 0; } }
@keyframes rise { to { transform: translateY(0); } }
@keyframes fade-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes media-in { from { opacity: 0; transform: scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes wall-up { from { transform: translateY(0); } to { transform: translateY(-50%); } }
@keyframes cortina { from { clip-path: inset(100% 0 0 0); scale: 1.08; } to { clip-path: inset(0); scale: 1; } }
@keyframes varredura { from { bottom: 0; opacity: 1; } 75% { opacity: 1; } to { bottom: 100%; opacity: 0; } }
@keyframes wall-down { from { transform: translateY(-50%); } to { transform: translateY(0); } }
@keyframes tick { to { transform: translateX(-25%); } }
@keyframes scroll-dot { 0% { transform: translateY(0); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(16px); opacity: 0; } }
@keyframes menu-in { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes clap {
  0% { transform: rotate(0); }
  35% { transform: rotate(-18deg); }
  60% { transform: rotate(0); }
  75% { transform: rotate(-4deg); }
  100% { transform: rotate(0); }
}

html.is-locked .wall__col,
html.is-locked .ticker__track { animation-play-state: paused; }

/* ---------- Responsivo ---------- */
@media (max-width: 1100px) {
  .nav { gap: 22px; }
  .work-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card__stage { height: clamp(400px, 58vw, 580px); }
  .card--cta { grid-column: span 2; }
  .card--cta .card__stage { min-height: 280px; }
  .process { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .service { grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1fr); gap: 14px 28px; }
}

/* menu de tela cheia até 1080px: abaixo disso nome + 5 links + botão não cabem lado a lado */
@media (max-width: 1080px) {
  .nav, .topbar__cta { display: none; }
  .menu-toggle { display: inline-flex; }
}

@media (max-width: 900px) {
  :root { --header-h: 64px; }

  .hero { align-items: flex-end; padding-bottom: 110px; }
  .hero__wall { top: -20%; bottom: -20%; left: -20%; right: -20%; width: auto; opacity: 0.55; }
  .hero__shade {
    background:
      linear-gradient(0deg, var(--bg) 8%, rgba(10, 10, 11, 0.82) 48%, rgba(10, 10, 11, 0.5) 100%),
      linear-gradient(180deg, rgba(10, 10, 11, 0.85) 0%, rgba(10, 10, 11, 0) 25%);
  }
  .vf-cross, .vf-specs, .hero__scroll { display: none; }
  .vf-rec { left: 40px; }

  .work .section-head { grid-template-columns: 1fr; }
  .filters { justify-content: flex-start; }

  .reels__hint { display: none; }

  .service { grid-template-columns: 1fr; grid-template-areas: "num" "title" "desc" "tags"; gap: 12px; }
  .service__num, .service__desc { padding-top: 0; }
  .service:hover .service__title { transform: none; }

  .about__grid { grid-template-columns: 1fr; }
  .slate { max-width: 360px; justify-self: center; }

  .viewer__body { display: block; overflow-y: auto; }
  .viewer__stage { height: 66dvh; padding: 14px 52px; }
  .viewer__nav { width: 40px; height: 40px; font-size: 16px; }
  .viewer__nav--prev { left: 6px; }
  .viewer__nav--next { right: 6px; }
  .viewer__info { border-left: 0; border-top: 1px solid var(--line); padding: 24px var(--pad) 32px; overflow: visible; }
  .viewer__thumbs { grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); }
}

@media (max-width: 640px) {
  .hero__title { font-size: clamp(3rem, 14.2vw, 5rem); }
  .hero__actions .btn { flex: 1 1 auto; }

  .work-grid { grid-template-columns: minmax(0, 1fr); }
  .card--wide, .card--cta { grid-column: auto; }
  .card__stage { height: clamp(400px, 118vw, 520px); }
  .card__word { font-size: 7rem; }
  .shot--browser { width: 86%; left: 5%; top: 16%; }
  .shot:nth-child(2) { width: 46%; right: 4%; bottom: 10%; }

  .section-head--row { align-items: flex-start; }

  .stats { gap: 22px 32px; }
  .about__cols { grid-template-columns: 1fr; }
  .process { grid-template-columns: minmax(0, 1fr); }

  .contact__title span:nth-child(2) { padding-left: 0; }
  .contact__actions .btn { width: 100%; }

  .footer { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0s !important;
    animation-delay: 0s !important;
  }
  .js .hero__lead, .js .hero__actions, .js .hero__status, .js .eyebrow { animation: none; }
  .wall__col, .ticker__track { animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .js .hero__title .line > span { transform: none; animation: none; }
}
