:root {
  --fundo: #f6f4ef;
  --texto: #171614;
  --suave: #6b6862;
  --linha: #dedad1;
  --capa: #e6e2d8;
  --titulo: "Anton", "Arial Narrow", Impact, sans-serif; /* teste; trocar por Druk Text se aprovar */
  --fonte: "Inter", -apple-system, "Helvetica Neue", Arial, sans-serif;
  --margem: clamp(20px, 5vw, 64px);
  --topo-h: 86px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--fundo);
  color: var(--texto);
  font-family: var(--fonte);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

/* ---------- topo ---------- */
/* Flutua por cima da imagem no topo de cada página (transparente); body.cabecalho-claro deixa o texto branco quando há imagem atrás. */
.topo {
  --topo-texto: var(--texto);
  --topo-suave: var(--suave);
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 5;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 14px 40px;
  padding: 28px var(--margem);
}
body.cabecalho-claro .topo { --topo-texto: #fff; --topo-suave: rgba(255, 255, 255, .75); }
.logo {
  color: var(--topo-texto);
  font-weight: 500;
  font-size: .9rem;
  letter-spacing: .28em;
  text-transform: uppercase;
}
nav { display: flex; gap: 28px; flex-wrap: wrap; margin-left: auto; }
nav a {
  font-size: .82rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--topo-suave);
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: color .2s, border-color .2s;
}
nav a:hover { color: var(--topo-texto); }
nav a.ativo { color: var(--topo-texto); border-color: var(--topo-texto); }
#idiomas { margin-left: 0; gap: 12px; }

/* ---------- estrutura ---------- */
main { min-height: 70vh; }
.hero, .bloco { padding: 0 var(--margem); max-width: 1320px; margin: 0 auto; }
.hero { padding-top: clamp(48px, 10vw, 120px); padding-bottom: clamp(48px, 8vw, 96px); }
.bloco { padding-top: 32px; padding-bottom: 96px; }
.estreito { max-width: 760px; margin-left: 0; padding-top: calc(var(--topo-h) + 32px); }
@media (min-width: 900px) { .estreito { margin-left: max(var(--margem), calc((100vw - 1320px) / 2 + var(--margem))); padding-left: 0; } }

h1, h2, h3 { font-weight: 500; line-height: 1.1; letter-spacing: -.02em; }
/* Títulos grandes: fonte condensada em maiúsculas */
h1 { font-family: var(--titulo); font-weight: 400; text-transform: uppercase; letter-spacing: .01em; line-height: .95; }
.apoio-hero { font-size: 1.1rem; color: var(--suave); margin-top: 20px; }

.titulo-secao { font-size: clamp(2.8rem, 8vw, 6rem); }
.apoio {
  margin-top: 10px;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--suave);
}
.texto { max-width: 640px; margin-top: 28px; font-size: 1.1rem; text-align: justify; hyphens: auto; }
/* Nas abas sem foto ao lado (Cinema, Campanhas, Publicidade), o texto ocupa a largura da grade abaixo. */
.texto.largo { max-width: none; }
.rotulo {
  font-family: var(--fonte);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--suave);
  margin: 64px 0 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--linha);
}
.sobre-grid { display: grid; gap: 40px 72px; align-items: start; }
@media (min-width: 900px) { .sobre-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 400px); } }
.foto { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: var(--capa); }
.foto.vazia { display: flex; align-items: center; justify-content: center; font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--suave); }

/* ---------- abertura (capa do Sobre) ---------- */
.abertura {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--margem) clamp(40px, 8vh, 80px);
  overflow: hidden;
  background: linear-gradient(160deg, #e2ddd0, var(--fundo) 70%);
}
.abertura-midia { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.slides { position: absolute; inset: 0; }
.slide { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.slide.ativa, .slide.saindo { animation: zoom var(--dur) linear forwards; }
.slide.ativa { opacity: 1; transition: opacity var(--fade, 1s) ease; }
.slide.saindo { opacity: 0; transition: opacity var(--fade, 1s) ease; }
@keyframes zoom { from { transform: scale(1); } to { transform: scale(1.09); } }
/* Camada escura uniforme por cima de todas as imagens, pra garantir leitura do texto off-white em qualquer quadro. */
.abertura::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .4);
}
@media (prefers-reduced-motion: reduce) { .slide.ativa { animation: none; } }
.abertura-texto {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
  width: 88%;
}
.abertura-nome { font-size: clamp(1.8rem, 8.5vw, 7.5rem); white-space: nowrap; color: var(--fundo); }
.abertura-funcao { font-size: clamp(1.6rem, 4.2vw, 2.8rem); text-transform: uppercase; letter-spacing: .1em; opacity: .9; white-space: nowrap; color: var(--fundo); }
.abertura p { margin-top: 16px; font-size: 1.05rem; opacity: .9; }
.rolar { position: absolute; z-index: 1; right: var(--margem); bottom: clamp(40px, 8vh, 80px); font-size: 1.5rem; color: var(--fundo); opacity: .75; transition: opacity .2s; }
.rolar:hover { opacity: 1; }
#bio { padding-top: 96px; }

/* ---------- capa das abas (Cinema, Campanhas, Publicidade) ---------- */
/* Imagem por trás do cabeçalho, do topo até o título + linha de apoio; a grade abaixo volta pro fundo normal. */
.secao-capa {
  position: relative;
  padding: calc(var(--topo-h) + clamp(28px, 6vw, 64px)) var(--margem) clamp(40px, 7vw, 72px);
  overflow: hidden;
  background: var(--capa);
}
.secao-capa::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .45);
}
.secao-capa-texto { position: relative; z-index: 1; max-width: 1320px; margin: 0 auto; }
.secao-capa .titulo-secao, .secao-capa .apoio { color: #fff; }
.secao-capa .apoio { opacity: .85; }
/* Depois da faixa de imagem, tudo vem mais colado — a própria faixa já respira embaixo do texto. */
.bloco.apos-capa { padding-top: 8px; }
.apos-capa > .texto:first-child { margin-top: 32px; }
.bloco.apos-capa > .rotulo:first-child,
.texto + .rotulo { margin-top: 32px; }

/* ---------- grade de projetos ---------- */
.grade {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: 48px 32px;
}
.projeto h3 { font-size: 1.15rem; margin-top: 14px; letter-spacing: -.01em; }
.meta { font-size: .85rem; color: var(--suave); margin-top: 4px; }
.papel { font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; color: var(--suave); margin-top: 2px; }
.sinopse { font-size: .95rem; margin-top: 12px; text-align: justify; hyphens: auto; }
.nota { font-size: .85rem; color: var(--suave); margin-top: 10px; font-style: italic; }
/* Na página de projeto, nota + logo (ex. selo de laboratório) lado a lado. */
.nota-linha { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; margin-top: 48px; }
.nota-linha .nota { margin-top: 0; }
.nota-logo { display: block; height: 160px; width: auto; }

/* ---------- página de projeto (filme individual) ---------- */
.projeto-pagina { padding-top: calc(var(--topo-h) + 32px); }
.voltar { display: inline-block; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--suave); margin-bottom: 28px; transition: color .2s; }
.voltar:hover { color: var(--texto); }
.projeto-pagina .apoio { margin-top: 6px; }
.projeto-pagina > .texto:first-of-type { margin-top: 24px; }

/* Pôster e referências em sangria total (edge-to-edge), pra imergir na imagem em vez de uma grade pequena. */
.projeto-poster, .cine {
  position: relative;
  left: 50%;
  width: 100vw;
  margin-left: -50vw;
  display: block;
  background: var(--capa);
}
.projeto-poster { height: auto; margin-bottom: 40px; }
.cine { height: 84vh; max-height: 900px; min-height: 340px; margin-top: 6px; margin-bottom: 6px; overflow: hidden; }
.cine img { width: 100%; height: 100%; object-fit: cover; display: block; }
.projeto-secao + .cine, .texto + .cine { margin-top: 28px; }
.cine + .projeto-secao, .cine + .texto { margin-top: 64px; }

/* Logos das produtoras, acima do texto de cada uma. */
.produtora { margin-top: 28px; }
.produtora:first-child { margin-top: 0; }
/* Largura e altura máximas iguais pra todo logo, cada um encaixado (object-fit) dentro da mesma caixa — evita que uma marca larga (wordmark) fique gigante ao lado de uma alta/quadrada (monograma). */
.produtora-logo { display: block; width: 150px; height: 64px; object-fit: contain; object-position: left center; margin-bottom: 14px; }
.produtora .texto { margin-top: 0; }

/* Ficha de elenco: foto ao lado do nome/papel/bio. */
.elenco-item { display: flex; gap: 28px; flex-wrap: wrap; margin-top: 28px; }
.elenco-item:first-child { margin-top: 0; }
.elenco-foto { width: 140px; aspect-ratio: 1 / 1; object-fit: cover; flex-shrink: 0; background: var(--capa); }
.elenco-texto { flex: 1; min-width: 240px; }
.elenco-texto .texto { margin-top: 0; }
.elenco-texto .texto + .texto { margin-top: 10px; }

/* Contato do projeto com imagem de fundo em sangria total, texto claro por cima. */
.projeto-contato {
  position: relative;
  left: 50%;
  width: 100vw;
  margin-left: -50vw;
  margin-top: 64px;
  overflow: hidden;
}
.projeto-contato-fundo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.projeto-contato::after { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .55); }
.projeto-contato-conteudo {
  position: relative;
  z-index: 1;
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(56px, 10vw, 96px) var(--margem);
}
.projeto-contato-conteudo .rotulo { color: rgba(255, 255, 255, .75); border-color: rgba(255, 255, 255, .3); }
.projeto-contato-conteudo .texto { color: #fff; }

/* Teaser embutido na página do projeto, em sangria total, proporção 16:9. */
.projeto-video {
  position: relative;
  left: 50%;
  width: 100vw;
  margin-left: -50vw;
  aspect-ratio: 16 / 9;
  margin-top: 6px;
  margin-bottom: 6px;
  background: var(--capa);
}
.projeto-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.projeto-secao + .projeto-video { margin-top: 28px; }
.projeto-video + .projeto-secao { margin-top: 64px; }

/* Imagem divisora de seção (ex. "Pesquisa de Imagens"), em sangria total com título grande sobreposto. */
.projeto-divisor {
  position: relative;
  left: 50%;
  width: 100vw;
  margin-left: -50vw;
  height: 84vh;
  max-height: 900px;
  min-height: 340px;
  margin-top: 6px;
  margin-bottom: 6px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
.projeto-divisor img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.projeto-divisor::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(0, 0, 0, .6), rgba(0, 0, 0, 0) 55%); }
.projeto-divisor-titulo {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 var(--margem) clamp(32px, 6vw, 56px);
  color: #fff;
  font-family: var(--titulo);
  font-weight: 400;
  text-transform: uppercase;
  line-height: .95;
  font-size: clamp(2rem, 6vw, 4rem);
}

/* Grupos de apoio/produção (texto opcional + logos lado a lado). */
.apoio-grupo { margin-top: 40px; }
.apoio-grupo:first-child { margin-top: 0; }
.apoio-titulo { font-size: .78rem; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--suave); margin-bottom: 8px; }
.apoio-grupo .texto { margin-top: 0; margin-bottom: 16px; }
.apoio-logos { display: flex; align-items: center; gap: 32px; flex-wrap: wrap; }
.apoio-logo { height: 100px; width: auto; max-width: 240px; object-fit: contain; }

.carreira { margin-top: 12px; font-size: .85rem; }
.carreira summary {
  cursor: pointer;
  color: var(--texto);
  list-style: none;
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.carreira summary::-webkit-details-marker { display: none; }
.carreira summary:hover { color: var(--suave); }
.carreira[open] .mais, .carreira:not([open]) .menos { display: none; }
.carreira h4 {
  margin-top: 16px;
  font-family: var(--fonte);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--suave);
}
.carreira ul { margin-top: 6px; padding-left: 18px; color: var(--suave); }
.carreira li { margin-top: 4px; }
.carreira p { margin-top: 10px; color: var(--suave); text-align: justify; hyphens: auto; }
.carreira p:first-child { margin-top: 12px; }

.capa {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--capa);
  overflow: hidden;
}
.capa img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .4s, transform .5s;
}
.capa.carregada img { opacity: 1; }
button.capa:hover img { transform: scale(1.03); }
/* Pôster/key art com texto: mostra inteiro, sem cortar, em vez de preencher o quadro. */
.capa.conter img { object-fit: contain; }
button.capa.conter:hover img { transform: none; }
.play {
  position: absolute; left: 50%; top: 50%;
  width: 54px; height: 54px;
  margin: -27px 0 0 -27px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .9);
  transition: transform .2s;
}
.play::after {
  content: "";
  position: absolute; left: 21px; top: 16px;
  border-left: 16px solid #111;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
}
button.capa:hover .play { transform: scale(1.08); }
.externo {
  position: absolute; left: 50%; top: 50%;
  width: 54px; height: 54px;
  margin: -27px 0 0 -27px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .9);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem;
  color: #0e0e0d;
  transition: transform .2s;
}
a.capa:hover .externo { transform: scale(1.08); }
.capa.vazia { display: flex; align-items: center; justify-content: center; }
.capa.vazia span {
  font-size: .75rem; letter-spacing: .14em; text-transform: uppercase; color: var(--suave);
}

/* ---------- contato ---------- */
.email { font-size: clamp(1.4rem, 3.5vw, 2.1rem); font-weight: 500; letter-spacing: -.02em; margin-top: 24px; }
.email a { border-bottom: 1px solid var(--linha); transition: border-color .2s; }
.email a:hover { border-color: var(--texto); }
.telefone { font-size: clamp(1.1rem, 2.5vw, 1.4rem); color: var(--suave); margin-top: 10px; }
.telefone a:hover { color: var(--texto); }
.vimeo-destaque {
  display: inline-block;
  margin-top: 40px;
  font-family: var(--titulo);
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  text-transform: uppercase;
  letter-spacing: .01em;
  border-bottom: 2px solid var(--texto);
  padding-bottom: 4px;
  transition: opacity .2s;
}
.vimeo-destaque:hover { opacity: .7; }
.links { margin-top: 24px; display: flex; gap: 24px; font-size: .9rem; color: var(--suave); }
.links a:hover { color: var(--texto); }

.rodape { padding: 32px var(--margem); font-size: .8rem; color: var(--suave); border-top: 1px solid var(--linha); }

/* ---------- player ---------- */
dialog {
  border: 0; padding: 0; background: #fff; color: #111;
  width: min(1100px, 94vw);
  margin: auto;
  overflow: visible;
}
dialog::backdrop { background: rgba(20, 20, 20, .7); }
.video { aspect-ratio: 16 / 9; }
.video iframe { width: 100%; height: 100%; border: 0; display: block; }
.fechar { position: absolute; right: 0; top: -44px; font-size: 2rem; line-height: 1; color: #fff; }
.abrir-externo { display: block; padding: 12px 0 0; position: absolute; top: 100%; font-size: .8rem; color: #777; }
.abrir-externo:hover { color: #111; }
