/* ═══════════════════════════════════════════════════════
   HOME.CSS — Landing page Estudio Via Traço
   Estrutura baseada no PDF aprovado
═══════════════════════════════════════════════════════ */

/* ── RESET DE UPPERCASE PARA HOME ──────────────────────
   Na home os títulos são em caixa baixa (editorial style)
   conforme PDF — override do global uppercase */
.home .h-headline,
.home .h-hero__headline { text-transform: none; }

/* ═══ HERO ═══════════════════════════════════════════ */
/* h-hero: 50/50 split layout */
.h-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
  padding-top: 64px; /* nav clearance */
  background: var(--bg);
}

/* Left: logo + traço SVG */
.h-hero__left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 7vw, 96px) clamp(36px, 5vw, 80px);
  border-right: none;
  position: relative;
}

.h-hero__logo {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 48px;
}

.h-hero__logo-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.h-logo-pre {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink2);
}

.h-logo-name {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: clamp(28px, 3.5vw, 44px);
  font-weight: 200;
  line-height: 1;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--ink);
}

/* Animated SVG trace */
.hero-trace {
  width: 100%;
  max-width: 360px;
  height: auto;
}

.trace-dot {
  transform-origin: center;
  transform-box: fill-box;
  animation: tracePulse 2.2s ease-in-out 2.2s infinite;
}

@keyframes tracePulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: .4;
    transform: scale(.65);
  }
}

/* Right: headline + text */
.h-hero__right {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 7vw, 96px) clamp(36px, 5vw, 80px);
  gap: 28px;
}

.h-hero__headline {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: clamp(42px, 4vw, 78px);
  font-weight: 200;
  line-height: 1.05;
  color: var(--ink);
  letter-spacing: -.01em;
}

.h-hero__body {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: clamp(14px, 1.85vw, 21px);
  line-height: 1.35;
  color: var(--ink2);
  max-width: 420px;
}

.h-hero__scroll {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin-top: 20px;
}

.h-hero__scroll span { font-weight: 700;
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: 10px;
  letter-spacing: .22em;
  color: rgba(28,27,24,.36);
  text-transform: uppercase;
}

/* ═══ SERVICE SECTIONS ════════════════════════════════ */
.h-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 80vh;
  border-top: none;
}

.h-section--light { background: #fff; }
.h-section--mid   { background: #fff; }
.h-section--dark  { background: #fff; }

/* Text side */
.h-section__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(60px, 8vw, 110px) clamp(36px, 6vw, 88px);
  gap: 20px;
  opacity: 0;
  transform: translateX(-120px);
  transition: opacity .7s ease, transform .7s ease;
}

.h-section__text--right { border-left: none; }
.h-section__text--left  { border-right: none; }

/* Art / placeholder side */
.h-section__art {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(40px, 5vw, 72px);
  opacity: 0;
  transform: translateX(-120px);
  transition: opacity .7s ease .15s, transform .7s ease .15s;
}

/* Scroll reveal */
.is-visible {
  opacity: 1 !important;
  transform: none !important;
}

/* ── Label ────────────────────────────────────────── */
.h-label {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: 16px;
  font-weight: 300;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: #000;
  display: block;
}

/* ── Section headline ─────────────────────────────── */
 .h-headline {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: clamp(42px, 4vw, 78px);
  font-weight: 200;
  line-height: 1.05;
  color: var(--ink);
  letter-spacing: -.01em;
}

/* ── Body text ────────────────────────────────────── */
.h-body {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: clamp(16px, 1.75vw, 22px);
  line-height: 1.32;
  color: var(--ink2);
  max-width: 420px;
}

/* ── CTA link ─────────────────────────────────────── */
.h-link {
  display: inline-block;
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: 13px;
  font-weight: 200;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1.5px solid var(--ink);
  padding-bottom: 2px;
  transition: color .2s, border-color .2s;
  align-self: flex-start;
  margin-top: 8px;
}
.h-link:hover { color: var(--green); border-color: var(--green); }

/* ── Green italic em ──────────────────────────────── */
.h-green {
  color: var(--green);
  font-style: italic;
}

/* ═══ ART PLACEHOLDERS ════════════════════════════════
   Onde as artes animadas serão inseridas
═══════════════════════════════════════════════════════ */
.h-art-placeholder {
  width: 100%;
  max-width: 480px;
  aspect-ratio: 4/3;
  border: 1.5px dashed rgba(28,27,24,.2);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(28,27,24,.03);
  position: relative;
}

.h-art-placeholder span {
  font-family: "Noto Sans", sans-serif, var(--serif);
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink3);
}

/* Grid placeholder (identidade) */
.h-art-placeholder--grid {
  aspect-ratio: 1;
  max-width: 360px;
}

.h-art-grid {
  width: 70%;
  height: 70%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.h-art-grid div {
  background: rgba(28,27,24,.07);
  border-radius: 3px;
  transition: background .3s;
}

.h-art-placeholder--grid:hover .h-art-grid div {
  background: rgba(46,181,78,.12);
}

/* ═══ RESPONSIVO ══════════════════════════════════════ */
@media (max-width: 900px) {
  .h-hero,
  .h-section {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .h-hero__left {
    border-right: none;
    border-bottom: none;
    padding: 100px 28px 48px;
  }

  .h-hero__right { padding: 48px 28px 60px; }

  .h-section__text--right { border-left: none; }
  .h-section__text--left  { border-right: none; border-bottom: none; }

  .h-section__text,
  .h-section__art { padding: 48px 28px; }

  /* On mobile, art always below text */
  .h-section__art--left { order: 2; }
  .h-section__text--right { order: 1; }
}

@media (max-width: 600px) {
  .h-hero__headline { font-size: clamp(32px, 10vw, 48px); }
  .h-headline       { font-size: clamp(28px, 8vw, 38px); }
  .h-logo-name      { font-size: 32px; }
}

/* ═══ VIDEO SCROLL SCRUB SECTION ══════════════════════
   .h-section--scrub usa sticky para manter o conteúdo
   visível enquanto o .h-scrub-driver empurra o scroll.
══════════════════════════════════════════════════════ */
.h-section--scrub {
  /* Remove o grid/min-height padrão do h-section */
  display: block;
  min-height: auto;
  position: relative;
}

/* Outer wrapper — altura total = viewport + espaço de scrub */
.h-scrub-wrap {
  position: relative;
}

/* Sticky container: gruda no topo e fica enquanto driver rola */
.h-scrub-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
  background: var(--bg);
  border-top: none;
}

/* O driver não é visível — só empurra a altura da seção.
   320vh = scroll mais longo para texto ficar legível enquanto o vídeo avança */
.h-scrub-driver {
  height: 320vh;
  pointer-events: none;
  visibility: hidden;
}

/* Vídeo dentro do painel direito
   Mantém o livro branco original: sem mix-blend-mode.
   Como o MP4 tem fundo branco, esta seção fica branca para o fundo não aparecer. */
.h-section--scrub,
.h-section--scrub .h-scrub-sticky,
.h-section--scrub .h-video-wrap {
  background: #fff;
}

.h-video-wrap {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  overflow: hidden;
}

.h-scrub-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  transform: scale(1.75);
  transform-origin: center center;
  background: #fff;
  outline: none;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}



/* Texto sincronizado com o scrub do livro
   Entra em fade-in pelo scroll e sai reto para a esquerda. */
.h-section--scrub .h-scrub-text {
  opacity: var(--scrub-text-opacity, 0) !important;
  transform: translate3d(var(--scrub-text-x, 0px), var(--scrub-text-y, 32px), 0) !important;
  transition: none !important;
  will-change: transform, opacity;
  position: relative;
  z-index: 2;
}

/* Mobile: anula completamente a animação de scrub no texto */
@media (max-width: 900px) {
  .h-section--scrub .h-scrub-text {
    opacity: 1 !important;
    transform: none !important;
    will-change: auto;
  }
}

.h-section--scrub .h-scrub-text .h-label,
.h-section--scrub .h-scrub-text .h-headline,
.h-section--scrub .h-scrub-text .h-body,
.h-section--scrub .h-scrub-text .h-link {
  will-change: transform, opacity;
}

@media (max-width: 900px) {
  .h-section--scrub .h-scrub-sticky {
    grid-template-columns: 1fr;
  }
}


/* Esconde TODOS os controles nativos do browser */
.h-scrub-video::-webkit-media-controls          { display: none !important; }
.h-scrub-video::-webkit-media-controls-enclosure { display: none !important; }

@media (max-width: 900px) {
  .h-scrub-sticky {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 100vh;
    position: relative; /* sticky não funciona bem em mobile aqui */
  }
  .h-scrub-driver { height: 100vh; }
  .h-video-wrap { padding: 0; max-height: 56vh; }
  .h-scrub-video { object-fit: contain; transform: scale(1.25); }
}


/* Ajustes pedidos: home branca e sem divisórias visuais entre containers */
body.home,
.home .h-hero,
.home .h-section,
.home .h-scrub-sticky,
.home .h-section--scrub,
.home .h-video-wrap {
  background: #fff !important;
}

.home .h-hero__left,
.home .h-section,
.home .h-section__text,
.home .h-section__text--left,
.home .h-section__text--right,
.home .h-scrub-sticky {
  border: none !important;
}

/* Ajuste novo: vídeo de abertura no lugar da marca/traço da home */
.h-home-intro {
  width: min(720px, 100%);
  aspect-ratio: 1600 / 854;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow: visible;
  background: #fff;
}

.h-home-intro__video {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  background: #fff;
  outline: none;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}

.h-home-intro__video::-webkit-media-controls,
.h-home-intro__video::-webkit-media-controls-enclosure {
  display: none !important;
}

/* Tamanhos separados: livro permanece grande; computador entra completo na tela */
#livrosVideo {
  transform: scale(1.75);
}

#sitesVideo {
  transform: scale(1.48);
}

@media (max-width: 900px) {
  #livrosVideo { transform: scale(1.25); }
  #sitesVideo  { transform: scale(1.08); }
  .h-home-intro { width: 100%; }
}

/* Correção: manter a home em branco puro sem alterar as cores dos vídeos */
html,
body.home {
  background: #fff !important;
}

body.home {
  --bg: #fff;
  --bg2: #fff;
  --white: #fff;
}

body.home .h-hero,
body.home .h-hero__left,
body.home .h-hero__right,
body.home .h-section,
body.home .h-section--light,
body.home .h-section--mid,
body.home .h-section--dark,
body.home .h-section--scrub,
body.home .h-scrub-wrap,
body.home .h-scrub-sticky,
body.home .h-section__text,
body.home .h-section__art,
body.home .h-video-wrap,

body.home .h-scrub-video {
  background-color: #fff !important;
  background-image: none !important;
}

body.home .h-scrub-video,
body.home .h-home-intro__video {
  
  filter: none !important;
}

/* ═══════════════════════════════════════
   RESPONSIVE PATCH — Home
   Mantém desktop intacto e evita cortes/overflow no mobile.
═══════════════════════════════════════ */
body.home {
  overflow-x: hidden;
}

@media (max-width: 900px) {
  body.home .h-hero {
    display: flex;
    flex-direction: column;
    min-height: auto;
    padding-top: 86px;
  }

  body.home .h-hero__left,
  body.home .h-hero__right {
    width: 100%;
    padding-left: 24px;
    padding-right: 24px;
  }

  body.home .h-hero__left {
    padding-top: 48px;
    padding-bottom: 24px;
    align-items: flex-start;
  }

  body.home .h-home-intro {
    width: min(560px, 92vw);
    max-width: 100%;
    margin: 0 auto;
  }

  body.home .h-hero__right {
    padding-top: 20px;
    padding-bottom: 64px;
  }

  body.home .h-hero__headline {
    font-size: clamp(36px, 9vw, 58px);
  }

  body.home .h-section:not(.h-section--scrub) {
    display: flex;
    flex-direction: column;
    min-height: auto;
  }

  body.home .h-section__text,
  body.home .h-section__art {
    width: 100%;
    padding: 44px 24px;
  }

  body.home .h-section__art--left,
  body.home .h-section__text--right {
    order: initial;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-wrap {
    min-height: auto;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-sticky {
    position: relative;
    top: auto;
    height: auto;
    min-height: auto;
    display: flex;
    flex-direction: column;
    overflow: visible;
  }

  /* Art/vídeo: PRIMEIRO no mobile (topo) */
  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    order: 1;
    width: 100%;
    height: min(56vh, 480px);
    min-height: 240px;
    padding: 0;
    opacity: 1 !important;
    transform: none !important;
  }

  /* Texto: SEGUNDO no mobile (baixo) */
  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text {
    order: 2;
    width: 100%;
    opacity: 1 !important;
    transform: none !important;
    /* Força scrub-text-opacity a não esconder o texto no mobile */
    --scrub-text-opacity: 1;
    --scrub-text-x: 0px;
    --scrub-text-y: 0px;
    padding: 40px 24px 32px;
  }

  body.home .h-scrub-driver {
    display: none;
    height: 0;
  }

  body.home .h-video-wrap {
    width: 100%;
    height: auto;
    max-height: 420px;
    min-height: 200px;
    overflow: hidden;
    padding: 0;
  }

  body.home .h-scrub-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    transform-origin: center center;
  }

  body.home #livrosVideo { transform: scale(1.12); }
  body.home #sitesVideo  { transform: scale(.98); }

  body.home .h-body {
    max-width: 560px;
  }
}

@media (max-width: 600px) {
  body.home .h-hero__left,
  body.home .h-hero__right,
  body.home .h-section__text,
  body.home .h-section__art {
    padding-left: 20px;
    padding-right: 20px;
  }

  body.home .h-home-intro {
    width: min(440px, 94vw);
  }

  body.home .h-headline {
    font-size: clamp(30px, 9.4vw, 42px);
    line-height: 1.08;
  }

  body.home .h-body {
    font-size: 14px;
    line-height: 1.7;
  }

  body.home .h-video-wrap {
    height: 46vh;
    max-height: 420px;
  }

  body.home #livrosVideo { transform: scale(1.04); }
  body.home #sitesVideo  { transform: scale(.92); }
}

@media (max-width: 390px) {
  body.home .h-video-wrap {
    height: 42vh;
  }

  body.home .h-home-intro {
    width: 96vw;
    margin-left: -2vw;
  }
}

/* ═══════════════════════════════════════
   MOBILE SCRUB PATCH — desacelera vídeos da home no responsivo
   Mantém o controle por scroll também no celular/tablet.
═══════════════════════════════════════ */
@media (max-width: 900px) {
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-wrap {
    min-height: auto !important;
    position: relative !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-sticky {
    position: sticky !important;
    top: 0 !important;
    height: 100svh !important;
    min-height: 100svh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text {
    order: 1 !important;
    width: 100% !important;
    min-height: 42svh !important;
    padding: 96px 24px 18px !important;
    opacity: var(--scrub-text-opacity, 0) !important;
    transform: translate3d(var(--scrub-text-x, 0px), var(--scrub-text-y, 32px), 0) !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    order: 2 !important;
    width: 100% !important;
    min-height: 58svh !important;
    padding: 0 0 24px !important;
    opacity: 1 !important;
    transform: none !important;
  }

  body.home .h-scrub-driver {
    display: block !important;
    height: 520vh !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body.home .h-video-wrap {
    height: 58svh !important;
    max-height: none !important;
    overflow: hidden !important;
  }

  body.home #livrosVideo { transform: scale(1.18) !important; }
  body.home #sitesVideo  { transform: scale(1.02) !important; }
}

@media (max-width: 600px) {
  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text {
    min-height: 44svh !important;
    padding: 88px 20px 16px !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    min-height: 56svh !important;
    padding-bottom: 22px !important;
  }

  body.home .h-scrub-driver {
    height: 620vh !important;
  }

  body.home .h-video-wrap {
    height: 56svh !important;
  }

  body.home #livrosVideo { transform: scale(1.08) !important; }
  body.home #sitesVideo  { transform: scale(.96) !important; }
}

/* ─── Hero scrub structure ─────────────────────────────────────── */
/* h-hero--scrub removed */ .h-hero--scrub--UNUSED {
  position: relative;
  display: block; /* override the grid */
}

/* Driver: 150vh de scroll para controlar o vídeo de 4.9s */

@media (max-width: 900px) {
  
  
}

/* Video intro: transparent background so no white square */
.h-home-intro,
.h-home-intro__video {
  background: transparent !important;
}
.h-home-intro__video {
   /* white pixels in video match site background */
}

/* ══ CORRECAO: Video intro sem quadrado branco ══════════════════
   Todos os fundos da area do video combinam com var(--bg)
═══════════════════════════════════════════════════════════════ */
.h-hero,
.h-hero--scrub,
.h-hero__sticky,
.h-hero__left,
.h-home-intro {
  background: var(--bg) !important;
}
.h-home-intro__video {
  background: transparent !important;
}
/* Quando nav tem card branco, hero esquerdo tambem fica branco */
@media (min-width: 0px) {
  body.home .h-home-intro {
    background: var(--bg) !important;
    background-color: var(--bg) !important;
  }
}


/* Libera overflow em toda a cadeia do sites-digital */


/* Remove padding e borda da arte */



/* Vídeo maior, ancorado à direita, sem margem direita */



/* Remove grid, a seção vira um bloco posicionado */


/* Vídeo: absoluto, preenche tudo */



/* Gradiente: escurece a esquerda para o texto ser legível */


/* Texto: flutua por cima do gradiente */


/* Textos ficam brancos sobre o fundo escuro */




.h-link--light {
  color: #fff !important;
  border-bottom-color: rgba(255,255,255,0.6) !important;
}
.h-link--light:hover {
  color: rgba(255,255,255,0.7) !important;
  border-bottom-color: rgba(255,255,255,0.4) !important;
}

/* Remove regras antigas que conflitam */


@media (max-width: 900px) {
  
}

/* h-video-wrap: sem mix-blend, fundo branco limpo */
.h-section--scrub,
.h-section--scrub .h-scrub-sticky,
.h-section--scrub .h-video-wrap {
  background: #fff;
}

.h-video-wrap {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  overflow: hidden;
}

.h-scrub-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  transform: scale(1.75);
  transform-origin: center center;
  background: #fff;
  outline: none;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}
/* PATCH: vídeo de assinatura sem bloco aparente */
body.home,
body.home .h-hero,
body.home .h-hero--scrub,
body.home .h-hero__sticky,
body.home .h-hero__left,
body.home .h-home-intro,
body.home .h-home-intro__video {
  background: #ffffff !important;
  background-color: #ffffff !important;
  background-image: none !important;
  box-shadow: none !important;
  filter: none !important;
  mix-blend-mode: normal !important;
}

body.home .h-home-intro {
  overflow: visible !important;
  border: none !important;
}

body.home .h-home-intro__video {
  display: block !important;
  border: none !important;
  outline: none !important;
}
body.home .h-home-intro__video {
  display: block !important;
  border: none !important;
  outline: none !important;
}

/* Ajuste final: vídeo Sites e Digital maior, sem mexer na margem */
#sitesVideo {
  transform: scale(1.65) !important;
  object-position: center center !important;
}
/* ═══════════════════════════════════════
   CORREÇÃO FINAL MOBILE — seções com vídeo/animação
   Mobile: vídeo em cima, texto embaixo, sem sticky/driver gigante.
   Desktop permanece com o scrub original.
═══════════════════════════════════════ */
@media (max-width: 900px) {
  body.home .h-section--scrub,
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-wrap {
    display: block !important;
    min-height: auto !important;
    height: auto !important;
    position: relative !important;
    overflow: visible !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-sticky {
    position: relative !important;
    top: auto !important;
    display: flex !important;
    flex-direction: column !important;
    height: auto !important;
    min-height: auto !important;
    overflow: visible !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    order: 1 !important;
    width: 100% !important;
    min-height: auto !important;
    height: auto !important;
    padding: 74px 20px 8px !important;
    opacity: 1 !important;
    transform: none !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text,
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-text {
    order: 2 !important;
    width: 100% !important;
    min-height: auto !important;
    height: auto !important;
    padding: 18px 24px 56px !important;
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
    --scrub-text-opacity: 1 !important;
    --scrub-text-x: 0px !important;
    --scrub-text-y: 0px !important;
    background: #fff !important;
  }

  body.home .h-scrub-driver {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body.home .h-video-wrap {
    width: 100% !important;
    height: min(48vh, 390px) !important;
    min-height: 230px !important;
    max-height: 390px !important;
    overflow: hidden !important;
    padding: 0 !important;
    background: #fff !important;
  }

  body.home .h-scrub-video {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: #fff !important;
  }

  body.home #livrosVideo {
    transform: scale(1.12) !important;
  }

  body.home #sitesVideo {
    transform: scale(1.02) !important;
  }
}

@media (max-width: 600px) {
  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    padding: 68px 16px 4px !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text,
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-text {
    padding: 16px 20px 48px !important;
  }

  body.home .h-video-wrap {
    height: min(44vh, 340px) !important;
    min-height: 210px !important;
  }

  body.home #livrosVideo {
    transform: scale(1.06) !important;
  }

  body.home #sitesVideo {
    transform: scale(.96) !important;
  }
}

/* ═══════════════════════════════════════
   PATCH FINAL — MOBILE SCRUB POR SCROLL
   Mantém vídeo/animação em cima, texto embaixo,
   e controla os frames pelo scroll também no responsivo.
═══════════════════════════════════════ */
@media (max-width: 900px) {
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-wrap {
    position: relative !important;
    min-height: auto !important;
    height: auto !important;
    overflow: visible !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-sticky {
    position: sticky !important;
    top: 0 !important;
    height: 100svh !important;
    min-height: 100svh !important;
    display: flex !important;
    flex-direction: column !important;
    overflow: hidden !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    order: 1 !important;
    width: 100% !important;
    height: 56svh !important;
    min-height: 260px !important;
    padding: 72px 18px 0 !important;
    opacity: 1 !important;
    transform: none !important;
    background: #fff !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text,
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-text {
    order: 2 !important;
    width: 100% !important;
    height: 44svh !important;
    min-height: 260px !important;
    padding: 24px 24px 44px !important;
    opacity: var(--scrub-text-opacity, 0) !important;
    transform: translate3d(var(--scrub-text-x, 0px), var(--scrub-text-y, 32px), 0) !important;
    visibility: visible !important;
    background: #fff !important;
  }

  body.home .h-scrub-driver {
    display: block !important;
    height: 420vh !important;
    min-height: 420vh !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body.home .h-video-wrap {
    width: 100% !important;
    height: 100% !important;
    max-height: none !important;
    min-height: 0 !important;
    overflow: hidden !important;
    padding: 0 !important;
    background: #fff !important;
  }

  body.home .h-scrub-video {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: #fff !important;
  }

  body.home #livrosVideo {
    transform: scale(1.12) !important;
  }

  body.home #sitesVideo {
    transform: scale(1.02) !important;
  }

  body.home .h-hero__scroll {
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    text-align: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

@media (max-width: 600px) {
  body.home .h-section--scrub:not(.h-section--carousel) .h-section__art {
    height: 55svh !important;
    min-height: 240px !important;
    padding: 64px 14px 0 !important;
  }

  body.home .h-section--scrub:not(.h-section--carousel) .h-section__text,
  body.home .h-section--scrub:not(.h-section--carousel) .h-scrub-text {
    height: 45svh !important;
    min-height: 250px !important;
    padding: 20px 20px 42px !important;
  }

  body.home .h-scrub-driver {
    height: 500vh !important;
    min-height: 500vh !important;
  }

  body.home #livrosVideo {
    transform: scale(1.05) !important;
  }

  body.home #sitesVideo {
    transform: scale(.96) !important;
  }

  body.home .h-hero__scroll {
    align-items: center !important;
  }
}

/* ══════════════════════════════════════════════════════════════════
   CARROSSEL KASA — Identidade Visual
   Controle por scroll, setas, teclado e swipe.
   Imagens quadradas com bordas arredondadas.
══════════════════════════════════════════════════════════════════ */

/* Driver do carrossel: 720vh para 9 imagens × 80vh cada */
.h-carousel-driver {
  height: 720vh;
}

/* Art panel: centraliza o carrossel */
.h-carousel-art {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(32px, 5vw, 64px) !important;
}

/* Container principal do carrossel */
.h-carousel {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
}

/* Frame da imagem: quadrado com bordas arredondadas */
.h-carousel__frame {
  position: relative;
  width: min(520px, calc(50vw - 80px));
  aspect-ratio: 1 / 1;
  border-radius: 18px;
  overflow: hidden;          /* janela: esconde os slides fora de vista */
  background: var(--bg2, #f5f5f5);
  box-shadow: 0 4px 32px rgba(0,0,0,.07);
}

/* Trilho deslizante: todas as imagens em linha */
.h-carousel__track {
  display: flex;
  height: 100%;
  width: 100%;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

/* Cada slide ocupa 100% da largura do frame */
.h-carousel__slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
}

.h-carousel__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Setas de navegação — delicadas, fora do frame */
.h-carousel__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(calc(-50% - 20px)); /* sobe para alinhar com o frame */
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(28,27,24,.15);
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink);
  transition: border-color .2s, background .2s, transform .2s;
  padding: 0;
}
.h-carousel__arrow:hover {
  border-color: var(--ink);
  background: #fff;
  transform: translateY(calc(-50% - 20px)) scale(1.08);
}
.h-carousel__arrow:disabled {
  opacity: 0.3;
  cursor: default;
}
.h-carousel__arrow--prev { left: 0; }
.h-carousel__arrow--next { right: 0; }

/* Rodapé: contador + dots */
.h-carousel__footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.h-carousel__counter {
  font-family: "Noto Sans", sans-serif;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: .18em;
  color: rgba(28,27,24,.4);
  text-transform: uppercase;
}

.h-carousel__dots {
  display: flex;
  gap: 6px;
}

.h-carousel__dot {
  width: 20px;
  height: 2px;
  border: none;
  border-radius: 2px;
  background: rgba(28,27,24,.2);
  cursor: pointer;
  padding: 0;
  transition: background .25s, width .25s;
}
.h-carousel__dot--active {
  background: var(--ink);
  width: 28px;
}
.h-carousel__dot:hover:not(.h-carousel__dot--active) {
  background: rgba(28,27,24,.45);
}

/* ══ RESPONSIVO — carrossel ═══════════════════════════════════════
   No mobile o carrossel MANTÉM scroll-freeze (igual desktop):
   a tela trava na seção e troca as imagens ao rolar/touch.
   Ao passar pela última imagem, a página avança — sem vão preto.
   Imagem em cima, texto embaixo, tudo proporcional à tela.
═══════════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  /* Mantém o scroll-freeze: sticky + driver ativos */
  .h-section--carousel .h-scrub-wrap {
    position: relative !important;
    min-height: auto !important;
  }
  .h-section--carousel .h-scrub-sticky {
    position: sticky !important;
    top: 0 !important;
    height: 100svh !important;
    min-height: 100svh !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    overflow: hidden !important;
    gap: 0 !important;
  }
  /* Driver ativo: 9 imagens × 80svh = scroll controlado */
  .h-section--carousel .h-carousel-driver {
    display: block !important;
    height: 720svh !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  /* Imagem PRIMEIRO (topo), proporcional */
  .h-section--carousel .h-section__art {
    order: 1 !important;
    width: 100% !important;
    min-height: auto !important;
    flex: 0 0 auto !important;
    opacity: 1 !important;
    transform: none !important;
    padding: 0 16px 14px !important;
  }

  /* Texto SEGUNDO (baixo), visível e compacto */
  .h-section--carousel .h-section__text {
    order: 2 !important;
    width: 100% !important;
    flex: 0 0 auto !important;
    opacity: 1 !important;
    transform: none !important;
    padding: 0 24px 0 !important;
    min-height: auto !important;
    gap: 10px !important;
  }

  /* Frame menor para caber imagem + texto na mesma tela */
  .h-section--carousel .h-carousel__frame {
    width: min(62vw, 270px);
  }

  /* Setas menores */
  .h-section--carousel .h-carousel__arrow {
    width: 30px;
    height: 30px;
  }

  .h-carousel-art {
    min-height: auto !important;
    padding: 0 16px !important;
  }

  /* ── Espaçamentos reduzidos do texto (pedido do print 2) ── */
  .h-section--carousel .h-section__text .h-label {
    margin-bottom: 2px !important;
  }
  .h-section--carousel .h-section__text .h-headline {
    margin: 4px 0 6px !important;
    line-height: 1.05 !important;
  }
  .h-section--carousel .h-section__text .h-body {
    margin-bottom: 10px !important;
  }
}

@media (max-width: 600px) {
  .h-section--carousel .h-carousel__frame {
    width: min(58vw, 240px);
  }
  .h-carousel__arrow--prev { left: -2px; }
  .h-carousel__arrow--next { right: -2px; }
}

@media (max-width: 400px) {
  .h-section--carousel .h-carousel__frame {
    width: min(54vw, 210px);
  }
}

/* ══ FIX: linha embaixo do vídeo Sites e Digital ════════════════
   CAUSA REAL: o MP4 tem uma faixa cinza (sombra/base do iMac) nas
   ~20 linhas inferiores do frame. Com transform: scale(1.75) essa
   faixa é ampliada e vira uma linha visível ao rolar para baixo.
   SOLUÇÃO: clip-path corta as bordas do vídeo sem afetar o scroll.
═══════════════════════════════════════════════════════════════ */
.h-section--scrub .h-scrub-sticky {
  border: none !important;
  outline: none !important;
}
.h-section--scrub .h-scrub-driver {
  background: transparent;
  border: none;
}
.h-section--scrub + .h-section,
.h-section--scrub + section {
  border-top: none;
}

/* ══ ANTI-COSTURA: linha do vídeo no scroll ══════════════════════
   ANÁLISE: o vídeo (1920×1080, 16:9) com object-fit:contain +
   scale dentro do painel meio-tela cria uma costura horizontal na
   borda do elemento. overflow:hidden corta exatamente nessa linha.
   Aparece ao descer porque o sticky se solta nessa borda.
   SOLUÇÃO DEFINITIVA: máscaras brancas no topo E na base do painel
   do vídeo, dentro do próprio video-wrap, cobrindo qualquer costura
   em qualquer posição de scroll. Como o fundo é branco, ficam
   invisíveis ao usuário.
═══════════════════════════════════════════════════════════════ */
.h-section--scrub .h-scrub-sticky {
  height: calc(100vh + 2px) !important;
}
.h-section--scrub .h-video-wrap {
  position: relative;
  background: #fff !important;
  overflow: hidden;
}
/* Máscara branca inferior — cobre a costura de baixo */
.h-section--scrub .h-video-wrap::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  bottom: -2px;
  height: 14px;
  background: #fff;
  z-index: 5;
  pointer-events: none;
}
/* Máscara branca superior — cobre a costura de cima */
.h-section--scrub .h-video-wrap::before {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  top: -2px;
  height: 14px;
  background: #fff;
  z-index: 5;
  pointer-events: none;
}

/* ══════════════════════════════════════════════════════════════════
   TELAS LARGAS — painéis do HOME centralizados (máx. 1600px)
   Fundo branco (#fff/--bg) nas laterais → sem emenda. Não altera o scrub,
   que é guiado por scroll (independe da largura). Abaixo de 1600 nada muda.
   ══════════════════════════════════════════════════════════════════ */
@media (min-width: 901px) {
  body.home .h-hero,
  body.home .h-scrub-sticky,
  body.home .h-section:not(.h-section--scrub) {
    max-width: 1600px;
    margin-left: auto;
    margin-right: auto;
  }
}


/* ── Expografia (Home): imagem inteira (contain), sem corte de cartaz/logo ──
   Escopado a #expografia para NÃO afetar o carrossel Kasa, que compartilha
   as classes .h-carousel__*. As peças de Cícero Dias (cartazes verticais)
   aparecem completas; o espaço restante no frame quadrado fica branco. */
#expografia .h-carousel__frame { background: #fff; }
#expografia .h-carousel__img {
  object-fit: contain;
  object-position: center;
  background: #fff;
}

/* expografia: sem carrossel, a trava do scroll fica curta */
#expografia .h-scrub-driver { height: 60vh; }
