@font-face {
  font-family: "Host Grotesk";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("assets/fonts/host-grotesk-500.ttf") format("truetype");
}

@font-face {
  font-family: "Host Grotesk";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/host-grotesk-700.ttf") format("truetype");
}

@font-face {
  font-family: "Host Grotesk";
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url("assets/fonts/host-grotesk-800.ttf") format("truetype");
}

@font-face {
  font-family: "Host Grotesk";
  font-style: italic;
  font-weight: 300;
  font-display: swap;
  src: url("assets/fonts/host-grotesk-300-italic.ttf") format("truetype");
}

:root {
  color-scheme: dark;
  --background: #0a0a0a;
  --video-background: #121212;
  --foreground: #fff;
  --accent: #38ff50;
  --muted: rgb(255 255 255 / 60%);
  --subtle: rgb(255 255 255 / 40%);
  --border: rgb(255 255 255 / 10%);
  --grain-opacity: .06;
  /* Uma unidade do desenho de 1920 px; mantém as proporções no desktop. */
  --u: min(0.052083333333vw, 1px);
  --asset-scale: 1;
  font-family: "Host Grotesk", sans-serif;
  font-synthesis: none;
  background: var(--background);
  color: var(--foreground);
}

*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, p, ul { margin: 0; }
html { scroll-behavior: smooth; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; }
em { font-weight: 300; font-style: italic; }

/* Textura fixa sobre o site e, na camada superior, sobre o modal. */
body::after, .video-modal::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  background-image: url("assets/grain.png");
  background-repeat: repeat;
  background-position: top left;
  background-size: 256px 256px;
  mix-blend-mode: screen;
  opacity: var(--grain-opacity);
}

.page { max-width: 1920px; margin-inline: auto; }
.narrow-container { width: calc(1280 * var(--u)); margin-inline: auto; }
.wide-container { width: calc(1723.4588 * var(--u)); margin-inline: auto; }

.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  height: 100vh;
  height: 100svh;
  background: #000;
  overflow: hidden;
}

.hero-background { position: absolute; inset: 0; z-index: -1; pointer-events: none; animation: hero-fade-in 1.8s ease both; }
.hero-video { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.hero-background::after { content: ""; position: absolute; inset: 0; background: rgb(0 0 0 / 70%); }

.site-header, .site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: calc(90 * var(--u));
  padding: calc(20 * var(--u));
  border-radius: calc(6 * var(--u));
}

.site-header {
  position: absolute;
  top: calc(68 * var(--u));
  left: 50%;
  transform: translateX(-50%);
  border-bottom: 1px solid var(--border);
  animation: hero-header-in .9s cubic-bezier(.23, .98, .56, 1) .06s both;
}

.brand { position: relative; display: block; width: calc(104.3012 * var(--u)); height: calc(27.1728 * var(--u)); }
.brand-symbol, .brand-wordmark { position: absolute; top: 0; left: 0; }
.brand-wordmark { top: calc(4.16 * var(--u)); left: calc(41.9628 * var(--u)); }
.brand img, .icon img, .logo-contronic img { display: block; transform: scale(var(--asset-scale)); transform-origin: top left; }
.header-label { color: var(--subtle); font-size: calc(15 * var(--u)); font-weight: 700; line-height: 1.05; letter-spacing: -.02em; text-transform: uppercase; }

.hero-content { display: flex; flex-direction: column; align-items: flex-start; gap: calc(15.0093 * var(--u)); }
.hero h1 { width: calc(573 * var(--u)); font-size: calc(77.323 * var(--u)); font-weight: 800; line-height: calc(81 * var(--u)); letter-spacing: -.02em; text-transform: uppercase; }
.hero-cta { display: flex; animation: hero-cta-in 1.2s cubic-bezier(.23, .98, .56, 1) .65s both; }
.reveal-line { display: block; overflow: hidden; }
.reveal-line > span { display: block; animation: hero-title-in 1.2s cubic-bezier(.23, .98, .56, 1) var(--line-delay, .16s) both; }
.reveal-line:nth-child(2) { --line-delay: .26s; }
.reveal-line:nth-child(3) { --line-delay: .36s; }
.reveal-line:nth-child(4) { --line-delay: .46s; }

@keyframes hero-title-in {
  from { opacity: 0; transform: translateY(110%); }
  to { opacity: 1; transform: none; }
}

@keyframes hero-header-in {
  from { opacity: 0; translate: 0 -16px; }
  to { opacity: 1; translate: none; }
}

@keyframes hero-cta-in {
  from { opacity: 0; translate: 0 24px; }
  to { opacity: 1; translate: none; }
}

@keyframes hero-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Entradas progressivas; sem JavaScript, todo o conteúdo segue visível. */
.reveal-pending {
  opacity: 0;
  translate: 0 var(--reveal-distance, 48px);
  transition:
    opacity var(--reveal-duration, 1.7s) cubic-bezier(.23, .98, .56, 1) var(--reveal-delay, 0ms),
    translate var(--reveal-duration, 1.7s) cubic-bezier(.23, .98, .56, 1) var(--reveal-delay, 0ms);
}
.reveal-pending.is-revealed { opacity: 1; translate: 0 0; }
[data-reveal="fade"] { --reveal-distance: 0px; }
[data-reveal="header"] { --reveal-distance: -16px; --reveal-duration: .9s; }
[data-reveal="line"] { --reveal-distance: 110%; --reveal-duration: 1.2s; }
.hero-background[data-reveal] { --reveal-duration: 1.8s; }
.project.reveal-pending { --reveal-distance: 80px; }

@media (max-width: 767px) {
  .project.reveal-pending { --reveal-distance: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal-pending { opacity: 1; translate: none; transition: none; }
  .hero .reveal-line > span,
  .hero .hero-background,
  .hero .site-header,
  .hero .hero-cta,
  .hero .hero-scroll { animation: none; }
}

.hero-scroll {
  position: absolute;
  bottom: clamp(16px, 3.5vh, 38px);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
  color: rgb(255 255 255 / 65%);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .28em;
  text-transform: uppercase;
  animation: hero-fade-in 1s ease .9s both;
}
.hero-scroll span { padding-left: .28em; }
.scroll-mouse { display: block; flex-shrink: 0; }
.hero-scroll:hover { color: #fff; }

.contact-button {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: calc(6 * var(--u));
  flex: 0 0 auto;
  width: calc(253 * var(--u));
  height: calc(50 * var(--u));
  padding: calc(14 * var(--u)) calc(30 * var(--u));
  border: 0;
  border-radius: calc(6 * var(--u));
  background: var(--accent);
  color: var(--background);
  cursor: pointer;
  overflow: visible;
  transform: scale(1);
  transition: transform .3s ease;
}

.contact-button::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: -12px -18px;
  border-radius: inherit;
  background: var(--accent);
  filter: blur(18px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
  animation: contact-glow-drift 2.6s ease-in-out infinite paused;
}

/* Mantém a face do botão nítida acima da luz difusa. */
.contact-button::after { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--accent); pointer-events: none; }

.button-shine { position: absolute; inset: 0; z-index: 1; overflow: hidden; border-radius: inherit; pointer-events: none; }
.button-shine::before {
  content: "";
  position: absolute;
  top: -50%;
  left: 0;
  width: 45%;
  height: 200%;
  background: linear-gradient(90deg, transparent, rgb(255 255 255 / 65%), transparent);
  transform: translateX(-220%) skewX(-20deg);
}

@keyframes contact-shine {
  from { transform: translateX(-220%) skewX(-20deg); }
  to { transform: translateX(350%) skewX(-20deg); }
}

@keyframes contact-glow-drift {
  0%, 100% { transform: translateX(-6px) scale(1); }
  50% { transform: translateX(6px) scale(1.06); }
}

@media (hover: hover) and (pointer: fine) {
  .contact-button:hover { transform: scale(1.03); }
  .contact-button:hover::before { opacity: .1; animation-play-state: running; }
  .contact-button:hover .button-shine::before { animation: contact-shine .7s ease-out both; }
}

@media (prefers-reduced-motion: reduce) {
  .contact-button, .contact-button::before { transition: none; }
  .contact-button:hover { transform: none; }
  .contact-button::before { animation: none; }
  .contact-button .button-shine::before { animation: none; }
}

.contact-button > span:last-child { width: calc(165 * var(--u)); white-space: nowrap; font-size: calc(16 * var(--u)); font-weight: 800; line-height: 1.05; letter-spacing: -.02em; text-transform: uppercase; }
.icon { display: block; flex: 0 0 auto; width: calc(22 * var(--u)); height: calc(22 * var(--u)); }
[aria-disabled="true"] { cursor: default; }

.clients {
  display: flex;
  align-items: center;
  gap: calc(88 * var(--u));
  height: calc(365 * var(--u));
  padding-left: calc(148.0819 * var(--u));
  overflow: hidden;
}

.clients h2 { flex: 0 0 calc(388.9181 * var(--u)); font-size: calc(42 * var(--u)); font-weight: 800; line-height: 1.05; letter-spacing: -.02em; text-transform: uppercase; }
.client-carousel { flex: 1; min-width: 0; overflow: hidden; mask-image: linear-gradient(to right, transparent, #000 40px, #000 calc(100% - 40px), transparent); }
.client-carousel:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.client-track { display: flex; width: max-content; }
.client-track.is-ready { animation: client-marquee var(--client-marquee-duration, 32s) linear infinite; will-change: transform; }
.client-logos { display: flex; align-items: center; gap: calc(50 * var(--u)); flex: 0 0 auto; list-style: none; padding: calc(20 * var(--u)) calc(50 * var(--u)) calc(20 * var(--u)) 0; }

@keyframes client-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(calc(-100% / 3)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .client-track.is-ready { animation: none; transform: none; will-change: auto; }
  .client-logos[aria-hidden="true"] { display: none; }
  .client-carousel { overflow-x: auto; mask-image: none; }
}
.client-logo { position: relative; flex: 0 0 auto; overflow: hidden; }
.client-logo img { display: block; }
.logo-zabaleta { width: calc(171.1084 * var(--u)); height: calc(37.1752 * var(--u)); }
.logo-zabaleta img { position: absolute; width: 115.59%; height: 189.42%; left: -4.52%; top: -39.62%; }
.logo-hospital { width: calc(130.3312 * var(--u)); height: calc(40.1223 * var(--u)); }
.logo-hospital img { width: 100%; height: 100%; object-fit: cover; }
.logo-arisa { width: calc(146.4967 * var(--u)); height: calc(44.1964 * var(--u)); }
.logo-arisa img { position: absolute; width: 120.99%; height: 207.18%; left: -10.5%; top: -53.59%; }
.logo-sinduscon { width: calc(68.605 * var(--u)); height: calc(72.2259 * var(--u)); }
.logo-sinduscon img { width: 100%; height: 100%; }
.logo-contronic { width: calc(174.871 * var(--u)); height: calc(33.9831 * var(--u)); }
.logo-urbe { width: calc(74.4619 * var(--u)); height: calc(48.1024 * var(--u)); }
.logo-urbe img { width: 100%; height: 100%; object-fit: cover; }
.logo-alianca { width: calc(150.65 * var(--u)); height: calc(29.8637 * var(--u)); }
.logo-alianca img { width: 100%; height: 100%; object-fit: contain; }

.portfolio { height: calc(2613 * var(--u)); padding-top: calc(140 * var(--u)); }
.project-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: calc(20 * var(--u)); align-items: start; }
.project-row-middle { grid-template-columns: 744.92065fr repeat(3, 311.2705fr); gap: calc(14.9089 * var(--u)); margin-top: calc(109.36 * var(--u)); }
.project-row-last { margin-top: calc(90.36 * var(--u)); }
.project { min-width: 0; }
.video-slot { position: relative; width: 100%; height: calc(755.3982 * var(--u)); border-radius: calc(6.973 * var(--u)); background: var(--video-background); overflow: hidden; }
.project-row-middle .video-slot { height: calc(419.018 * var(--u)); border-radius: calc(3.868 * var(--u)); }
.project-landscape .video-slot { border-radius: 0; }
.video-slot video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; transform: scale(1); transform-origin: center; transition: transform 380ms cubic-bezier(.2, .65, .3, 1); }

@media (hover: hover) and (pointer: fine) {
  .video-slot:hover video { transform: scale(1.04); }
}

@media (prefers-reduced-motion: reduce) {
  .video-slot video { transition: none; }
  .video-slot:hover video { transform: none; }
}
.video-play { position: absolute; inset: 0; display: grid; place-items: center; width: 100%; height: 100%; padding: 0; border: 0; background: transparent; color: #fff; cursor: pointer; }
.video-play:focus-visible { outline-offset: -5px; }
.play-icon { display: grid; place-items: center; width: clamp(44px, calc(64 * var(--u)), 64px); aspect-ratio: 1; border: 1px solid rgb(255 255 255 / 65%); border-radius: 50%; background: rgb(0 0 0 / 35%); }
.play-icon::before { content: ""; width: 0; height: 0; margin-left: 4px; border-top: 9px solid transparent; border-bottom: 9px solid transparent; border-left: 14px solid currentColor; }

body.video-modal-open { overflow: hidden; }
.video-modal { width: fit-content; max-width: calc(100vw - 32px); max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); padding: 0; border: 0; margin: auto; background: transparent; color: #fff; overflow: visible; }
.video-modal::backdrop { background: rgb(0 0 0 / 82%); }
.video-modal-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 48px; }
.video-modal-header h2 { max-width: min(75vw, 800px); font-size: 14px; font-weight: 500; line-height: 1.3; text-transform: uppercase; }
.video-modal-close { display: grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; padding: 0; border: 0; background: transparent; color: #fff; font-size: 32px; font-weight: 300; line-height: 1; cursor: pointer; }
.video-modal-player { display: block; width: auto; height: auto; max-width: min(1100px, calc(100vw - 32px)); max-height: calc(100vh - 164px); max-height: calc(100dvh - 164px); margin-inline: auto; border-radius: 6px; background: #000; object-fit: contain; }
.player-controls { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 4px 0; color: #fff; }
.player-controls button { display: grid; place-items: center; flex-shrink: 0; min-width: 36px; height: 40px; padding: 0 4px; border: 0; border-radius: 4px; background: transparent; color: inherit; font-size: 13px; cursor: pointer; }
.player-toggle span { width: 0; height: 0; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 11px solid currentColor; }
.player-toggle.is-playing span { width: 11px; height: 14px; border: 0; border-left: 4px solid currentColor; border-right: 4px solid currentColor; }
.player-time { flex-shrink: 0; font-size: 12px; font-variant-numeric: tabular-nums; }
.player-seek { display: block; flex: 1; min-width: 40px; height: 36px; margin: 0; accent-color: var(--accent); cursor: pointer; }
.player-seek:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.player-seek:disabled { opacity: .4; cursor: default; }
.player-controls .player-fullscreen { font-size: 24px; }
.video-modal.is-expanded { position: fixed; inset: 0; width: 100%; max-width: none; height: 100vh; height: 100dvh; max-height: none; margin: 0; background: #000; overflow: hidden; }
.video-modal.is-expanded .video-modal-header { display: none; }
.video-stage:fullscreen, .is-expanded .video-stage { position: relative; display: flex; flex-direction: column; justify-content: center; width: 100%; height: 100%; min-height: 0; padding: calc(64px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) calc(8px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: #000; }
.video-stage:fullscreen { width: 100vw; height: 100vh; height: 100dvh; }
.video-stage:fullscreen .video-modal-player, .is-expanded .video-modal-player { flex: 1 1 0; min-height: 0; width: 100%; max-width: 100%; max-height: none; border-radius: 0; }
.video-stage:fullscreen .player-controls, .is-expanded .player-controls { flex-shrink: 0; width: min(1100px, 100%); margin-inline: auto; }
.player-exit-fullscreen { position: absolute; z-index: 2; top: calc(8px + env(safe-area-inset-top, 0px)); right: max(16px, env(safe-area-inset-right, 0px)); display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; border: 1px solid rgb(255 255 255 / 35%); border-radius: 24px; background: #202020; color: #fff; font: inherit; font-size: 13px; cursor: pointer; touch-action: manipulation; }
.player-exit-fullscreen span { font-size: 28px; line-height: 1; }
.player-exit-fullscreen[hidden] { display: none; }

/* Mobile: imagem de ponta a ponta; os controles ficam por cima, sem reservar faixas. */
@media (pointer: coarse), (max-width: 767px) {
  .video-stage:fullscreen, .is-expanded .video-stage { display: block; padding: 0; overflow: hidden; }
  .video-stage:fullscreen .video-modal-player, .is-expanded .video-modal-player { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; object-fit: cover; object-position: center; }
  .video-stage:fullscreen .player-controls, .is-expanded .player-controls { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; width: 100%; margin: 0; padding: 24px max(12px, env(safe-area-inset-right, 0px)) calc(12px + env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)); background: linear-gradient(transparent, rgb(0 0 0 / 80%)); }
  .video-stage:fullscreen .player-status, .is-expanded .player-status { position: absolute; z-index: 1; left: 16px; right: 16px; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); margin-inline: auto; }
}

@media (max-width: 480px) {
  .player-controls { gap: 6px; }
  .player-controls button { min-width: 30px; }
}
.project-caption { display: flex; flex-direction: column; gap: calc(5 * var(--u)); margin-top: calc(14.6018 * var(--u)); font-weight: 500; line-height: 1.05; letter-spacing: -.02em; }
.project-caption h2 { font-size: calc(20 * var(--u)); font-weight: inherit; text-transform: uppercase; }
.project-caption p { font-size: calc(18 * var(--u)); color: var(--muted); }

.closing { height: calc(398 * var(--u)); padding-top: calc(114 * var(--u)); }
.closing-content { display: flex; align-items: flex-start; justify-content: space-between; padding-right: calc(221.7294 * var(--u)); }
.manifesto { width: calc(616.2889 * var(--u)); font-size: calc(32 * var(--u)); font-weight: 800; line-height: 1.4; letter-spacing: -.02em; text-transform: uppercase; }
.closing-contact { display: flex; flex-direction: column; align-items: flex-end; gap: calc(8 * var(--u)); width: calc(346 * var(--u)); margin-top: calc(44 * var(--u)); }
.closing-contact h2 { width: 100%; font-size: calc(24 * var(--u)); font-weight: 800; line-height: 1.4; letter-spacing: -.02em; text-transform: uppercase; white-space: nowrap; }
.site-footer { border-top: 1px solid var(--border); }
.instagram-link { display: flex; align-items: center; gap: calc(12 * var(--u)); padding: 0; border: 0; background: none; color: var(--subtle); font-size: calc(15 * var(--u)); font-weight: 500; line-height: 1.05; letter-spacing: -.02em; text-transform: uppercase; cursor: pointer; }

/* O arquivo enviado tem um layout desktop. Abaixo, adaptação para telas pequenas. */
@media (max-width: 767px) {
  :root { --u: 1px; }
  .narrow-container, .wide-container { width: calc(100% - 40px); }
  .site-header { top: 20px; height: 76px; padding: 15px 0; }
  .header-label { font-size: 12px; }
  .hero-content { gap: 24px; padding-top: 36px; }
  .hero h1 { width: 100%; font-size: clamp(48px, 9.9vw, 70px); line-height: 1.05; }
  .clients { height: auto; padding: 60px 20px 50px; flex-direction: column; align-items: flex-start; gap: 36px; }
  .clients h2 { flex-basis: auto; max-width: 340px; font-size: 32px; }
  .client-carousel { flex: 0 0 auto; width: 100%; }
  .client-logos { gap: 30px; padding: 20px 30px 20px 0; }
  .portfolio { height: auto; padding-top: 30px; padding-bottom: 70px; }
  .project-row, .project-row-middle { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  .project-row-middle, .project-row-last { margin-top: 42px; }
  .video-slot, .project-row-middle .video-slot { height: auto; aspect-ratio: 561.153 / 755.3982; border-radius: 5px; }
  .project-landscape { grid-column: 1 / -1; }
  .project-landscape .video-slot { aspect-ratio: 744.92065 / 419.018; border-radius: 0; }
  .project-caption { margin-top: 12px; }
  .project-caption h2 { font-size: 16px; }
  .project-caption p { font-size: 14px; line-height: 1.25; }
  .closing { height: auto; padding-top: 20px; padding-bottom: 70px; }
  .closing-content { flex-direction: column; gap: 36px; padding-right: 0; }
  .manifesto { width: 100%; max-width: 590px; font-size: 24px; }
  .closing-contact { align-items: flex-start; width: 100%; margin-top: 0; }
  .closing-contact h2 { font-size: 22px; }
  .site-footer { height: 90px; padding: 20px 0; }
  .instagram-link { gap: 8px; font-size: 11px; }
}

@media (max-width: 380px) {
  .hero h1 { font-size: 46px; }
}

.player-status { max-width: 680px; margin: 8px auto; padding: 8px 12px; color: #fff; background: #282828; font-size: 14px; line-height: 1.4; }
.player-status[hidden] { display: none; }

/* Mantém o conteúdo utilizável quando o celular é girado. */
@media (max-width: 1024px) and (max-height: 600px) and (orientation: landscape) {
  .hero .site-header { top: 8px; height: 42px; padding: 4px 0; }
  .hero-content { padding-top: 56px; padding-bottom: 16px; gap: 12px; }
  .hero h1 { width: auto; font-size: clamp(24px, 9svh, 48px); line-height: 1.02; }
  .hero .contact-button { min-height: 40px; padding: 10px 16px; font-size: 14px; }
  .hero-scroll { left: auto; right: 24px; bottom: 20px; transform: none; font-size: 9px; }
}
