:root {
  --bg: #fff;
  --fg: #0a0a0a;
  --muted: #f0f0f0;
  --dim: #6b6b6b;
  --accent: #ff5a3c; /* coral da série Unframe */
  --ease: cubic-bezier(.22, 1, .36, 1);
  --pad: 16px;
  --radius: 24px;
  --nav: 56px;
}
@media (min-width: 768px) { :root { --pad: 24px; } }

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-font-smoothing: antialiased; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body { background: var(--bg); color: var(--fg); font-family: "Archivo", system-ui, sans-serif; font-size: 16px; line-height: 1.45; overflow-x: hidden; }
img, video { display: block; max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nav-icons button svg path { fill: currentColor; stroke: none; }
.fill { fill: currentColor; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.mono { font-family: "JetBrains Mono", monospace; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.dim { color: rgba(255,255,255,.45); }
.small { font-size: 13px; line-height: 1.6; }

/* Tipografia da série Unframe: retas em Anton, redondas em Archivo larga na mesma altura de caixa */
.uf { font-family: "Anton", Impact, sans-serif; font-weight: 400; text-transform: uppercase; line-height: .9; letter-spacing: .005em; }
.uf .r { font-family: "Archivo", sans-serif; font-weight: 800; font-stretch: 96%; font-size: 1.2em; line-height: 0; letter-spacing: -.01em; }
.uf-light { font-family: "Archivo", sans-serif; font-weight: 300; font-stretch: 110%; letter-spacing: -.02em; }

/* Grão e cursor */
.grain { position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .07;
  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='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite; }
@keyframes grain { 0%{transform:translate(0,0)} 20%{transform:translate(-3%,2%)} 40%{transform:translate(2%,-3%)} 60%{transform:translate(-2%,-1%)} 80%{transform:translate(3%,3%)} 100%{transform:translate(0,0)} }
.cursor { position: fixed; left: 0; top: 0; z-index: 95; pointer-events: none; width: 84px; height: 84px; margin: -42px 0 0 -42px; border-radius: 50%;
  background: var(--accent); color: #fff; display: grid; place-items: center; transform: scale(0); transition: transform .35s var(--ease); }
.cursor span { font-family: "JetBrains Mono", monospace; font-size: 11px; letter-spacing: .12em; }
.cursor.on { transform: scale(1); }
@media (hover: none) { .cursor { display: none; } }

/* Nav */
.nav { position: fixed; inset: 0 0 auto 0; height: var(--nav); z-index: 80; background: var(--bg); display: flex; align-items: center; justify-content: space-between; padding: 0 var(--pad); }
.nav-logo img { height: 26px; width: auto; }
.nav-right { display: flex; align-items: center; gap: 18px; }
.nav-icons { display: none; gap: 16px; }
.nav-icons a, .nav-icons button, .nav-ig { opacity: .85; transition: opacity .2s, transform .3s var(--ease); }
.nav-icons a:hover, .nav-icons button:hover, .nav-ig:hover { opacity: 1; transform: translateY(-2px); }
.nav-sep { display: none; width: 1px; height: 18px; background: #ddd; }
.nav-cta { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; position: relative; }
.nav-cta::after { content: ""; position: absolute; left: 0; right: 0; bottom: -3px; height: 1.5px; background: var(--accent); transform: scaleX(0); transform-origin: right; transition: transform .4s var(--ease); }
.nav-cta:hover::after { transform: scaleX(1); transform-origin: left; }
.lang { display: flex; gap: 4px; font-size: 11px; color: #aaa; }
.lang button.on { color: var(--fg); font-weight: 700; }
@media (min-width: 768px) { .nav-icons, .nav-sep { display: flex; } }

/* Card com moldura branca */
.frame { position: relative; width: 100%; height: 100%; border-radius: var(--radius); overflow: hidden; background: #111; isolation: isolate; }
.frame video.bg, .case-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.veil { position: absolute; inset: 0; background: rgba(0,0,0,.22); }
.veil.v40 { background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,.25) 40%, rgba(0,0,0,.55)); }

/* Bloco preso */
.pin-sticky { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.track { display: flex; height: 100vh; will-change: transform; }
.panel { flex-shrink: 0; height: 100vh; padding: var(--nav) var(--pad) var(--pad); }
.hero, .cases { width: 100vw; }

/* Hero */
.hero-center { position: absolute; inset: 0; z-index: 2; display: grid; place-items: center; text-align: center; color: #fff; perspective: 1000px; }
.hero-logo, .hero-text { grid-area: 1 / 1; }
.hero-logo { height: clamp(90px, 14vw, 200px); width: auto; animation: logoIn .8s var(--ease) both, logoOut .7s var(--ease) 1.9s forwards; }
@keyframes logoIn { from { opacity: 0; transform: scale(.5) rotateY(-90deg); } }
@keyframes logoOut { to { opacity: 0; transform: scale(1.2) rotateY(90deg); } }
.hero-text { opacity: 0; }
.hero-text.on { animation: fadeIn .6s var(--ease) forwards; }
.hero-text.on .hero-tag { animation: dropIn .6s var(--ease) .1s both; }
.hero-text.on .hero-title { animation: scaleIn .9s var(--ease) .2s both; }
.hero-text.off { animation: fadeOut .6s var(--ease) forwards; }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes fadeOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes dropIn { from { opacity: 0; transform: translateY(-20px); } }
@keyframes scaleIn { from { opacity: 0; transform: scale(.8); filter: blur(14px); } }
.hero-tag { font-family: "JetBrains Mono", monospace; font-size: clamp(11px, 1.1vw, 15px); letter-spacing: .16em; text-transform: uppercase; margin-bottom: 10px; }
.hero-title { font-size: clamp(4.2rem, 17vw, 16rem); line-height: .82; }
.hero-foot { position: absolute; z-index: 2; left: 24px; right: 24px; bottom: 20px; display: flex; justify-content: space-between; color: rgba(255,255,255,.8); }
.rec { display: flex; align-items: center; gap: 8px; }
.rec i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: blink 1.2s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Sobre */
.sobre { display: flex; gap: 48px; align-items: stretch; padding-right: 64px; }
.sobre-video { width: min(30vw, 46vh); flex-shrink: 0; }
.sobre-body { display: flex; flex-direction: column; justify-content: center; gap: 48px; padding-top: 24px; }
.sobre-head { font-size: clamp(2.6rem, 6.4vw, 6.6rem); white-space: nowrap; }
.sobre-head > span { display: block; }
.sobre-head > span:last-child { color: var(--accent); }
.sobre-cols { display: flex; gap: 40px; align-items: flex-start; }
.retrato { width: clamp(220px, 21vw, 340px); aspect-ratio: 4/5; border-radius: 18px; overflow: hidden; background: var(--muted); flex-shrink: 0; }
.retrato img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .8s var(--ease), transform 1.2s var(--ease); }
.retrato:hover img { filter: grayscale(0); transform: scale(1.04); }
.col { width: 280px; display: grid; gap: 16px; font-size: 15px; color: #3a3a3a; }
.col .strong, .col b { color: var(--fg); font-weight: 700; }

/* Cases */
.case-media > div { position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease-in-out; }
.case-media > div.on { opacity: 1; }
.case-media > div video { transform: scale(1.08); transition: transform 6s linear; }
.case-media > div.on video { transform: scale(1); }
.case-center { position: absolute; inset: 0; z-index: 3; display: grid; place-items: center; text-align: center; color: #fff; padding: 0 24px; }
.case-center > div { grid-area: 1/1; }
.case-title { font-size: clamp(3rem, 10vw, 9.5rem); }
.case-title .w { display: inline-block; overflow: hidden; vertical-align: bottom; padding-bottom: .02em; }
.case-title .w > span { display: inline-block; transform: translateY(105%); transition: transform .8s var(--ease); }
.case-sub { margin-top: 14px; opacity: 0; transition: opacity .6s .25s; color: rgba(255,255,255,.75); }
.case-center .on .w > span { transform: none; }
.case-center .on .case-sub { opacity: 1; }
.case-center .out .w > span { transform: translateY(-105%); }
.case-dots { position: absolute; z-index: 3; right: 28px; top: 50%; transform: translateY(-50%); display: grid; gap: 10px; }
.case-dots i { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.3); transition: all .5s var(--ease); }
.case-dots i.on { background: var(--accent); transform: scale(1.3); }
.case-count { position: absolute; z-index: 3; top: 22px; left: 24px; color: rgba(255,255,255,.8); }
.case-all { position: absolute; z-index: 3; left: 50%; bottom: 28px; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,.85); transition: color .2s, gap .3s var(--ease); }
.case-all:hover { color: #fff; gap: 14px; }
.case-all svg, .link-arrow svg { width: 16px; height: 16px; }

/* Pilares que viram em 3D */
.pilares { display: grid; grid-template-columns: 1fr; gap: 48px; padding: 96px var(--pad) 64px; }
@media (min-width: 1024px) { .pilares { grid-template-columns: 1.15fr 1fr; gap: 80px; padding: 140px 48px 96px; align-items: center; } }
.pilares-list { display: grid; gap: 2px; border-radius: var(--radius); overflow: hidden; }
.flip { --d: 75px; height: calc(var(--d) * 2); perspective: 900px; cursor: default; overflow: hidden; }
.flip-in { position: relative; height: 100%; transform-style: preserve-3d; transform: translateZ(calc(var(--d) * -1)); transition: transform .6s var(--ease); }
.flip:hover .flip-in, .flip:focus-within .flip-in { transform: translateZ(calc(var(--d) * -1)) rotateX(-90deg); }
.flip-face { position: absolute; inset: 0; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 48px; backface-visibility: hidden; }
.flip-front { background: var(--muted); transform: translateZ(var(--d)); }
.flip-back { background: var(--fg); color: #fff; transform: rotateX(90deg) translateZ(var(--d)); }
.flip-front h3 { font-size: clamp(1.4rem, 2.6vw, 2.4rem); }
.flip-back p { font-size: clamp(1.05rem, 1.6vw, 1.4rem); font-weight: 500; max-width: 30ch; }
.flip-n { color: var(--dim); }
.flip-back .flip-n { color: var(--accent); }
.quote blockquote { font-size: clamp(2.2rem, 4.4vw, 4.4rem); line-height: 1.02; }
.quote-a { margin: 20px 0 32px; font-weight: 600; }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; border-bottom: 1px solid currentColor; padding-bottom: 4px; transition: gap .3s var(--ease); }
.link-arrow:hover { gap: 14px; }

/* Clientes */
.clientes { padding: 40px 0 72px; overflow: hidden; }
.big-title { font-size: clamp(3.2rem, 8vw, 7.5rem); padding: 0 var(--pad) 28px; }
@media (min-width: 768px) { .big-title { padding: 0 48px 36px; } }
.marquee { overflow: hidden; }
.marquee-in { display: flex; width: max-content; animation: mq 38s linear infinite; }
.marquee.rev .marquee-in { animation-direction: reverse; animation-duration: 46s; }
.marquee:hover .marquee-in { animation-play-state: paused; }
@keyframes mq { to { transform: translateX(-50%); } }
.mq-item { font-family: "Anton", sans-serif; text-transform: uppercase; font-size: clamp(2.4rem, 5.5vw, 5rem); line-height: 1.1; padding: 0 .35em; white-space: nowrap; display: flex; align-items: center; gap: .7em; }
.mq-item::after { content: "✦"; font-size: .4em; color: var(--accent); }
.people { margin-bottom: 28px; }
.people .marquee-in { animation-duration: 50s; gap: 14px; padding-right: 14px; }
.person { width: clamp(150px, 15vw, 210px); flex-shrink: 0; }
.person figure { aspect-ratio: 3/4; border-radius: 16px; overflow: hidden; background: var(--muted); }
.person img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .6s var(--ease), transform .9s var(--ease); }
.person:hover img { filter: grayscale(0); transform: scale(1.04); }
.person p { margin-top: 10px; font-family: "JetBrains Mono", monospace; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); }
.outline .mq-item { color: transparent; -webkit-text-stroke: 1.2px var(--fg); }
.outline .mq-item:hover { color: var(--fg); }

/* Projetos */
.projetos { background: var(--fg); color: #fff; padding: 88px var(--pad) 96px; }
@media (min-width: 768px) { .projetos { padding: 110px 48px 120px; } }
.proj-head { display: flex; align-items: flex-end; justify-content: space-between; }
.proj-head .big-title { padding-left: 0; padding-right: 0; }
.proj-n { color: rgba(255,255,255,.5); padding-bottom: 40px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.filters button { font-family: "JetBrains Mono", monospace; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; padding: 10px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.22); color: rgba(255,255,255,.7); transition: background .25s, color .25s, border-color .25s; }
.filters button:hover { color: #fff; border-color: rgba(255,255,255,.6); }
.filters button.on { background: #fff; color: var(--fg); border-color: #fff; }
.filters button sup { margin-left: 4px; opacity: .55; }
.filters button:focus-visible, .card:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.card[hidden] { display: none; }
.grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid { grid-template-columns: repeat(3, 1fr); } }
.card { position: relative; aspect-ratio: 16/10; border-radius: 18px; overflow: hidden; background: #1a1a1a; text-align: left; cursor: none;
  transform: translateY(30px); transition: transform .7s var(--ease); }
@media (hover: none) { .card { cursor: pointer; } }
.card.in { transform: none; }
.card img, .card video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease), opacity .5s, filter .6s; }
.card img { filter: grayscale(1) brightness(.75); }
.card video { opacity: 0; }
.card:hover img { transform: scale(1.06); filter: grayscale(0) brightness(.7); }
.card.playing video { opacity: 1; }
.card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.35), transparent 35%, transparent 55%, rgba(0,0,0,.75)); }
.card-top { position: absolute; z-index: 2; top: 16px; left: 18px; right: 18px; display: flex; justify-content: space-between; color: rgba(255,255,255,.7); }
.card-bot { position: absolute; z-index: 2; left: 18px; right: 18px; bottom: 16px; }
.card-bot h3 { font-size: clamp(1.4rem, 2.1vw, 1.9rem); }
.card-bot p { margin-top: 6px; color: rgba(255,255,255,.65); }

/* Rodapé */
.footer { background: var(--fg); color: #fff; border-top: 1px solid rgba(255,255,255,.08); overflow: hidden; }
.foot-cta { text-align: center; padding: 110px var(--pad) 90px; }
.foot-title { font-size: clamp(3rem, 9vw, 8.5rem); }
.scribble { position: relative; margin-top: 22px; font-size: clamp(1rem, 1.6vw, 1.3rem); padding: 10px 26px; }
.scribble svg { position: absolute; left: -10%; top: -32%; width: 120%; height: 164%; overflow: visible; pointer-events: none; }
.scribble path { fill: none; stroke: var(--accent); stroke-width: 2.2; stroke-linecap: round; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.4s var(--ease); }
.scribble.in path, .scribble:hover path { stroke-dashoffset: 0; }
.foot-cols { display: grid; gap: 32px; grid-template-columns: 1fr; padding: 40px var(--pad); font-size: 14px; }
@media (min-width: 768px) { .foot-cols { grid-template-columns: repeat(4, 1fr); padding: 40px 48px; } }
.foot-cols > div { display: grid; gap: 8px; align-content: start; }
.foot-links { list-style: none; display: grid; gap: 6px; }
.foot-links a, .foot-links button, .foot-cols a { color: rgba(255,255,255,.65); transition: color .2s; }
.foot-links a:hover, .foot-links button:hover, .foot-cols a:hover { color: #fff; }
.u { text-decoration: underline; text-underline-offset: 3px; }
.foot-legal { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; padding: 18px var(--pad); border-top: 1px solid rgba(255,255,255,.1); color: rgba(255,255,255,.4); }
@media (min-width: 768px) { .foot-legal { padding: 18px 48px; } }
.foot-mq { padding: 18px 0 10px; }
.foot-mq .mq-item { font-size: clamp(5rem, 13vw, 13rem); line-height: .95; }
.foot-mq .marquee-in { animation-duration: 30s; }

/* Modais */
.modal { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.92); display: grid; place-items: center; padding: 24px; opacity: 0; transition: opacity .4s var(--ease); }
.modal.open { opacity: 1; }
.modal[hidden] { display: none; }
.modal-x { position: absolute; top: 20px; right: 24px; color: rgba(255,255,255,.8); }
.modal-x.dark { color: var(--fg); top: 18px; right: 20px; }
.player-box { width: min(1100px, 100%); }
.player-box video { width: 100%; max-height: 76vh; border-radius: 16px; background: #000; }
.player-bar { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; color: rgba(255,255,255,.75); gap: 12px; }
.player-bar button:disabled { opacity: .25; cursor: default; }
.contact-box { position: relative; width: min(460px, 100%); background: #fff; color: var(--fg); border-radius: var(--radius); padding: 48px 28px 28px; display: grid; gap: 12px; transform: translateY(20px); transition: transform .5s var(--ease); }
.modal.open .contact-box { transform: none; }
.contact-box h3 { font-size: 2.2rem; margin-bottom: 8px; }
.choice { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 20px; border-radius: 14px; background: var(--muted); transition: background .25s, color .25s; }
.choice:hover { background: var(--fg); color: #fff; }

/* Revelação ao rolar */
.reveal-lines > span { overflow: hidden; }

/* Celular e tablet: pilha vertical, sem trilho horizontal */
@media (max-width: 767px) {
  :root { --radius: 16px; }
  .pin-sticky { position: static; height: auto; overflow: visible; }
  .track { display: block; height: auto; transform: none !important; }
  .panel { width: 100%; height: auto; }
  .hero, .cases { height: 100svh; padding: var(--nav) 12px 12px; }
  .sobre { flex-direction: column; gap: 28px; padding: 72px var(--pad) 40px; }
  .sobre-video { width: 100%; aspect-ratio: 4/5; height: auto; }
  .sobre-head { white-space: normal; font-size: clamp(2.6rem, 11vw, 4rem); }
  .sobre-body { gap: 28px; padding-top: 0; }
  .sobre-cols { flex-direction: column; gap: 24px; }
  .retrato { width: 100%; aspect-ratio: 1; }
  .col { width: auto; }
  .flip { --d: 64px; }
  .flip-face { padding: 0 28px; }
  .hero-foot span:last-child { display: none; }
  .case-dots { right: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .grain { display: none; }
}
