/* ============================================================
   Birigui Drone — estilos
   Seção hero: vídeo 360° imersivo com controle por giroscópio
   ============================================================ */

:root {
  --bg: #05070d;
  --ink: #eef4ff;
  --muted: rgba(238, 244, 255, 0.66);
  --accent: #38bdf8;
  --accent-2: #22d3ee;
  --glass: rgba(10, 14, 22, 0.55);
  --hairline: rgba(255, 255, 255, 0.14);
  --shadow: 0 18px 60px rgba(0, 0, 0, 0.5);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Rola na vertical; trava só a horizontal */
body {
  overflow-x: hidden;
  overscroll-behavior-y: none;
}
html { scroll-behavior: smooth; }

/* ======================= PRELOADER ======================= */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: var(--bg);
  display: grid;
  place-items: center;
  transition: opacity 0.55s var(--ease), visibility 0.55s;
}
.preloader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.preloader__inner {
  display: grid;
  justify-items: center;
  gap: 20px;
  padding: 24px;
  width: 100%;
}
.preloader__logo {
  width: clamp(160px, 56vw, 260px);
  height: auto;
  animation: preloaderPulse 2.2s ease-in-out infinite;
}
.preloader__bar {
  width: clamp(170px, 60vw, 260px);
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}
.preloader__bar-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.5);
  transition: width 0.25s ease;
}
.preloader__pct {
  font-size: 13px;
  letter-spacing: 1.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
@keyframes preloaderPulse {
  0%, 100% { opacity: 0.85; }
  50% { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .preloader__logo { animation: none; }
}

/* ======================= HERO ======================= */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh; /* respeita a barra do navegador no mobile */
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg);
  isolation: isolate;
}

/* Área do vídeo 360° — ~70% da altura no mobile (deixa o vídeo menos "esticado") */
.hero__media {
  position: relative;
  flex: 0 0 70%;
  height: 70%;
  min-height: 0;
  overflow: hidden;
  background: #000;
}
@media (min-width: 768px) {
  .hero__media { flex-basis: 82%; height: 82%; }
}

/* Canvas WebGL onde a esfera 360° é renderizada (preenche a tela) */
.hero__canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  display: block;
  background: #000;
  touch-action: none;
}

/* Vídeo equiretangular: fonte da textura. Invisível, mas renderizado
   (o iOS só decodifica frames se o elemento estiver "tocando" no layout). */
.hero__video {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
}

/* Camada transparente que captura o arraste (desktop) e gestos */
.hero__interactor {
  position: absolute;
  inset: 0;
  z-index: 1;
  cursor: grab;
  touch-action: pan-y; /* arraste horizontal = olhar em volta; vertical = rolar a página */
  -webkit-user-select: none;
  user-select: none;
}
.hero__interactor.is-dragging { cursor: grabbing; }

/* ======================= UI decorativa ======================= */
.hero__ui {
  position: absolute;
  inset: 0;
  z-index: 3; /* acima do degradê (.hero__fade z-index 2) para a dica não ficar coberta */
  pointer-events: none; /* deixa o arraste passar para a camada de baixo */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(16px, 3.2vw, 34px);
}

.hero__topbar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

/* Degradê que funde a base do vídeo na faixa preta da marca */
.hero__fade {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 48%;
  z-index: 2;
  pointer-events: none;
  /* Transição bem gradual que vira SÓLIDO (= cor da faixa) antes da borda,
     deixando o encontro vídeo/faixa imperceptível; várias paradas evitam "banding". */
  background: linear-gradient(180deg,
    rgba(5, 7, 13, 0) 0%,
    rgba(5, 7, 13, 0.12) 28%,
    rgba(5, 7, 13, 0.42) 52%,
    rgba(5, 7, 13, 0.78) 72%,
    var(--bg) 88%,
    var(--bg) 100%);
}

/* Faixa da marca (~30% no mobile) */
.hero__brandbar {
  flex: 1 1 auto;
  min-height: 0;
  background: var(--bg);
  display: grid;
  place-items: center;
  padding: clamp(12px, 3vw, 22px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.2px;
}
.brand__logo {
  height: clamp(46px, 11vw, 78px);
  width: auto;
  max-width: 82%;
  object-fit: contain;
  display: block;
}

.hero__badge {
  position: relative;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #eafcff;
  border: 1px solid var(--hairline);
  background: var(--glass);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.hero__hint {
  /* posicionada ACIMA do degradê da base */
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 16px;
  border-radius: 999px;
  color: var(--ink);
  background: var(--glass);
  border: 1px solid var(--hairline);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  font-size: 14px;
  white-space: nowrap;
  animation: floaty 3.6s var(--ease) infinite;
  transition: opacity 0.5s ease;
}
.hero__hint-icon {
  display: inline-grid;
  place-items: center;
  color: var(--accent);
  animation: swipe 1.9s ease-in-out infinite;
}
.hero__hint.is-hidden { opacity: 0; }

/* ======================= Portão de ativação ======================= */
.hero__gate {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 24px;
  background: radial-gradient(90% 80% at 50% 45%, rgba(5, 7, 13, 0.35) 0%, rgba(5, 7, 13, 0.82) 100%);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  transition: opacity 0.6s var(--ease), visibility 0.6s;
}
.hero__gate.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.gate__inner {
  display: grid;
  justify-items: center;
  gap: 16px;
  animation: rise 0.7s var(--ease) both;
}
.gate__ring {
  color: var(--accent);
  filter: drop-shadow(0 6px 22px rgba(56, 189, 248, 0.45));
  animation: spin 9s linear infinite;
}
.gate__btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  font-size: clamp(15px, 2.4vw, 17px);
  color: #04101a;
  padding: 15px 26px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  box-shadow: 0 14px 40px rgba(34, 211, 238, 0.4);
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.gate__btn:hover { transform: translateY(-2px); box-shadow: 0 18px 48px rgba(34, 211, 238, 0.55); }
.gate__btn:active { transform: translateY(0) scale(0.98); }
.gate__sub {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
}

/* ======================= Animações ======================= */
@keyframes floaty {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, -6px); }
}
@keyframes swipe {
  0%, 100% { transform: translateX(-4px); }
  50% { transform: translateX(4px); }
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero__hint, .hero__hint-icon, .gate__ring, .gate__inner { animation: none !important; }
}

/* ============================================================
   SEÇÕES (produto, frase, portfólio, contato)
   ============================================================ */
.section {
  position: relative;
  padding: clamp(64px, 11vh, 130px) clamp(20px, 5vw, 40px);
  background: var(--bg);
}
.section__inner {
  max-width: 1100px;
  margin: 0 auto;
  text-align: center;
}
.eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
}
.section__title {
  margin: 0 0 16px;
  font-size: clamp(30px, 6vw, 58px);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.5px;
  color: #fff;
}
.grad {
  background: linear-gradient(100deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.section__lead {
  margin: 0 auto;
  max-width: 620px;
  font-size: clamp(15px, 2.4vw, 19px);
  line-height: 1.6;
  color: var(--muted);
}

/* Botão padrão / WhatsApp */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: clamp(15px, 2.2vw, 17px);
  padding: 15px 28px;
  border-radius: 999px;
  cursor: pointer;
  border: 0;
  text-decoration: none;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), filter 0.2s var(--ease);
}
.btn--wa {
  color: #04140b;
  background: linear-gradient(135deg, #25d366 0%, #12b552 100%);
  box-shadow: 0 14px 40px rgba(37, 211, 102, 0.35);
}
.btn--wa:hover { transform: translateY(-3px); box-shadow: 0 20px 52px rgba(37, 211, 102, 0.5); }
.btn--wa:active { transform: translateY(-1px) scale(0.99); }
.btn--lg { padding: 18px 34px; font-size: clamp(16px, 2.6vw, 19px); }

/* Indicador de rolagem (no hero) */
.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: none;
  border: 0;
  cursor: pointer;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  z-index: 4;
  transition: opacity 0.4s ease, color 0.2s ease;
}
.scroll-cue:hover { color: var(--accent); }
.scroll-cue svg { animation: cueBob 1.8s ease-in-out infinite; }
@keyframes cueBob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(4px); } }

/* ---------------- PRODUTO ---------------- */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(14px, 2.2vw, 22px);
  margin: clamp(34px, 6vw, 54px) 0;
}
.feature {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  border: 1px solid var(--hairline);
  text-align: left;
  transition: transform 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
.feature:hover {
  transform: translateY(-6px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}
/* Área de vídeo (prévia) no topo do card */
.feature__media {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #0b1220, #05070d);
  overflow: hidden;
}
.feature__media iframe,
.feature__media canvas,
.feature__media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  object-fit: cover;
}
.feature__overlay { position: absolute; inset: 0; z-index: 2; } /* bloqueia interação com o iframe */
/* Card com vídeo vertical (ex.: plano sequência): mostra inteiro, sem cortar */
.feature__media--portrait video { object-fit: contain; }
.feature__media--360 { cursor: grab; touch-action: pan-y; }
.feature__media--360.is-dragging { cursor: grabbing; }
.feature__badge,
.feature__draghint {
  position: absolute;
  z-index: 3;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: #eafcff;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--glass);
  border: 1px solid var(--hairline);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  pointer-events: none;
}
.feature__badge { top: 12px; right: 12px; }
.feature__draghint { top: 12px; left: 12px; display: inline-flex; align-items: center; gap: 5px; font-weight: 500; }
/* Texto sobre o vídeo (degradê na base) */
.feature__body {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  padding: clamp(20px, 3vw, 30px) clamp(18px, 2.4vw, 26px) clamp(16px, 2.4vw, 24px);
  background: linear-gradient(180deg, rgba(5,7,13,0) 0%, rgba(5,7,13,0.55) 45%, rgba(5,7,13,0.92) 100%);
}
.feature__body h3 { margin: 0 0 6px; font-size: clamp(19px, 2.6vw, 24px); color: #fff; text-shadow: 0 2px 14px rgba(0,0,0,0.5); }
.feature__body p { margin: 0; font-size: clamp(13.5px, 1.8vw, 15px); line-height: 1.5; color: rgba(238,244,255,0.88); text-shadow: 0 1px 10px rgba(0,0,0,0.5); }

.price {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(16px, 3vw, 30px);
  padding: clamp(22px, 3vw, 30px);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(56,189,248,0.08), rgba(255,255,255,0.02));
  border: 1px solid var(--hairline);
}
.price__box { display: grid; text-align: left; }
.price__label { font-size: 12px; letter-spacing: 2px; text-transform: uppercase; color: var(--muted); }
.price__value { font-size: clamp(22px, 4vw, 30px); font-weight: 500; color: #fff; }
.price__value strong { color: var(--accent); }

/* ---------------- FRASE DE EFEITO ---------------- */
.section--frase { overflow: hidden; }
.frase__bg {
  position: absolute;
  inset: -10% 0;
  background:
    radial-gradient(60% 60% at 20% 20%, rgba(56,189,248,0.14), transparent 70%),
    radial-gradient(60% 60% at 85% 80%, rgba(34,211,238,0.12), transparent 70%);
  z-index: 0;
  will-change: transform;
}
.section--frase .section__inner { position: relative; z-index: 1; max-width: 960px; }
.frase {
  margin: 0;
  font-size: clamp(26px, 5.5vw, 52px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.5px;
  color: #fff;
}
.frase__line { display: block; }
.frase em { font-style: normal; color: var(--accent); }
.frase__sub {
  display: block;
  margin-top: 22px;
  font-size: clamp(15px, 2.2vw, 19px);
  font-weight: 400;
  line-height: 1.6;
  color: var(--muted);
}

/* ---------------- PORTFÓLIO (carrossel) ---------------- */
.section--portfolio { padding-bottom: clamp(70px, 12vh, 140px); }
.carousel { position: relative; margin-top: clamp(30px, 5vw, 48px); }
.carousel__viewport { overflow: hidden; }
.carousel__track {
  display: flex;
  gap: clamp(14px, 2vw, 22px);
  padding: 6px clamp(20px, 5vw, 40px);
  will-change: transform;
  cursor: grab;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
}
.carousel__track.is-dragging { cursor: grabbing; }
.slide {
  flex: 0 0 auto;
  width: min(84vw, 720px);
  margin: 0;
}
.slide__media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--hairline);
}
/* Gradientes = "poster" enquanto o vídeo carrega */
.slide__media.ph1 { background: linear-gradient(135deg, #f2a65a, #7a3b2e); }
.slide__media.ph2 { background: linear-gradient(135deg, #38bdf8, #1e3a8a); }
.slide__media.ph3 { background: linear-gradient(135deg, #34d399, #14532d); }
.slide__media.ph4 { background: linear-gradient(135deg, #a78bfa, #4c1d95); }
.slide__media.ph5 { background: linear-gradient(135deg, #fb7185, #7f1d1d); }
.slide__media iframe,
.slide__media video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; z-index: 1; }
/* Slide com vídeo vertical (ex.: plano sequência): mostra o vídeo inteiro,
   sem cortar, sobre o gradiente da capa (fica com aspecto de "reel"). */
.slide__media--portrait video { object-fit: contain; }
.slide__overlay { position: absolute; inset: 0; z-index: 2; } /* captura o arraste do carrossel sobre o vídeo */
.slide__tag {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 3;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.5px;
  color: #fff;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.18);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.slide figcaption {
  margin-top: 14px;
  font-size: clamp(15px, 2vw, 17px);
  font-weight: 600;
  color: var(--ink);
  text-align: left;
  padding-left: 2px;
}
.slide__more {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 12px;
  font: inherit;
  font-weight: 700;
  font-size: 14px;
  color: var(--accent);
  padding: 9px 18px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.35);
  cursor: pointer;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.slide__more:hover { background: rgba(56, 189, 248, 0.2); transform: translateY(-2px); box-shadow: 0 10px 26px rgba(56, 189, 248, 0.22); }
.slide__more svg { transition: transform 0.2s var(--ease); }
.slide__more:hover svg { transform: translateX(3px); }
.carousel__btn {
  position: absolute;
  /* centro vertical do vídeo (altura = largura do slide * 9/16) */
  top: calc(6px + min(78vw, 460px) * 0.28125);
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--hairline);
  background: var(--glass);
  color: #fff;
  cursor: pointer;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  transition: background 0.2s ease, transform 0.2s ease;
  z-index: 3;
}
.carousel__btn:hover { background: rgba(56,189,248,0.25); transform: translateY(-50%) scale(1.08); }
.carousel__btn--prev { left: clamp(8px, 2vw, 20px); }
.carousel__btn--next { right: clamp(8px, 2vw, 20px); }
.carousel__dots {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin-top: 26px;
}
.carousel__dots button {
  width: 9px; height: 9px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  background: rgba(255,255,255,0.25);
  transition: background 0.2s ease, transform 0.2s ease;
}
.carousel__dots button.is-active { background: var(--accent); transform: scale(1.3); }

/* ---------------- CONTATO / RODAPÉ ---------------- */
.section--contato {
  background: radial-gradient(90% 90% at 50% 0%, #0b1220 0%, var(--bg) 70%);
}
.section--contato .btn--wa { margin-top: 30px; }
.footer {
  margin-top: clamp(56px, 10vh, 100px);
  padding-top: 30px;
  border-top: 1px solid var(--hairline);
  display: grid;
  justify-items: center;
  gap: 14px;
}
.footer__logo { height: 42px; width: auto; opacity: 0.9; }
.footer p { margin: 0; font-size: 12.5px; color: var(--muted); }

/* ---------------- Botão flutuante WhatsApp ---------------- */
.wa-float {
  position: fixed;
  right: clamp(16px, 4vw, 26px);
  bottom: clamp(16px, 4vw, 26px);
  z-index: 40;
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(135deg, #25d366, #12b552);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.45);
  opacity: 0;
  transform: scale(0.6);
  pointer-events: none;
  transition: transform 0.35s var(--ease), box-shadow 0.2s ease;
}
.wa-float.is-visible { opacity: 1; transform: scale(1); pointer-events: auto; }
.wa-float:hover { transform: scale(1.08); box-shadow: 0 16px 40px rgba(37, 211, 102, 0.6); }
.wa-float::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5);
  animation: waPulse 2.4s ease-out infinite;
}
@keyframes waPulse {
  0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
  70% { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

@media (max-width: 720px) {
  .features { grid-template-columns: 1fr; gap: clamp(16px, 4vw, 22px); }
  /* Blocos altos e imersivos (~85% da tela) no celular */
  .feature__media { aspect-ratio: auto; height: 85vh; height: 85svh; }
  /* Portfólio: slide grande (retrato) — cabe heading + vídeo na tela */
  .slide { width: 85vw; }
  .slide__media { aspect-ratio: auto; height: 54vh; height: 54svh; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-cue svg, .wa-float::before { animation: none !important; }
}

/* ============================================================
   PÁGINA DA CASA (casa.html)
   Template único; o "sotaque" (cor de destaque + variante de layout)
   é aplicado por casa via JS: --accent / --accent-2 / --accent-rgb.
   ============================================================ */
body.casa {
  /* entrada suave, sem depender de JS (evita tela em branco se o JS falhar) */
  animation: casaIn 0.5s var(--ease) both;
}
@keyframes casaIn { from { opacity: 0; } to { opacity: 1; } }

/* ---- Barra superior (logo + voltar), fixa ---- */
.casa__nav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px clamp(16px, 4vw, 34px);
  background: rgba(5, 7, 13, 0.72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--hairline);
}
.casa__brand { display: inline-flex; align-items: center; }
.casa__brand img { height: clamp(28px, 6vw, 36px); width: auto; display: block; }
.casa__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  color: var(--ink);
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--hairline);
  background: var(--glass);
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.casa__back:hover {
  transform: translateX(-3px);
  border-color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
}
.casa__back svg { transition: transform 0.2s var(--ease); }
.casa__back:hover svg { transform: translateX(-3px); }
.casa__back-label { display: inline; }

/* ---- Hero da casa (capa editorial, distinta da home) ---- */
.casa__hero {
  position: relative;
  overflow: hidden;
  padding: clamp(56px, 12vh, 132px) clamp(20px, 5vw, 40px) clamp(40px, 8vh, 90px);
}
.casa__hero-bg {
  position: absolute;
  inset: -25% -12%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(48% 55% at 18% 22%, rgba(var(--accent-rgb), 0.30), transparent 70%),
    radial-gradient(52% 55% at 84% 82%, rgba(var(--accent-2-rgb), 0.24), transparent 72%);
  will-change: transform;
}
.casa__hero-bg::after { /* linha de grade sutil */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(70% 70% at 50% 40%, #000 0%, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 70% at 50% 40%, #000 0%, transparent 75%);
}
.casa__hero-inner {
  position: relative;
  max-width: 1000px;
  margin: 0 auto;
  min-height: clamp(220px, 34vh, 340px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  text-align: center;
  align-items: center;
}
.casa__index {
  position: absolute;
  z-index: 0;
  pointer-events: none;
  font-size: clamp(140px, 34vw, 320px);
  font-weight: 900;
  line-height: 0.72;
  letter-spacing: -0.05em;
  color: transparent;
  -webkit-text-fill-color: transparent;
  background: linear-gradient(180deg, rgba(var(--accent-rgb), 0.32), rgba(var(--accent-rgb), 0));
  -webkit-background-clip: text;
  background-clip: text;
  opacity: 0.85;
}
.casa__hero-text { position: relative; z-index: 1; }
.casa__eyebrow {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
}
.casa__title {
  margin: 0 0 14px;
  font-size: clamp(32px, 7vw, 66px);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -0.6px;
  color: #fff;
}
.casa__loc {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 auto 18px;
  padding: 7px 15px;
  border-radius: 999px;
  font-size: clamp(13px, 2vw, 15px);
  font-weight: 600;
  color: var(--ink);
  background: rgba(var(--accent-rgb), 0.1);
  border: 1px solid rgba(var(--accent-rgb), 0.32);
}
.casa__loc svg { color: var(--accent); flex: 0 0 auto; }
.casa__desc {
  max-width: 620px;
  margin: 0 auto;
  font-size: clamp(15px, 2.4vw, 19px);
  line-height: 1.65;
  color: var(--muted);
}

/* Variante A (casas ímpares): número centralizado atrás do título */
.casa--v1 .casa__index { top: 50%; left: 50%; transform: translate(-50%, -50%); }

/* Variante B (casas pares): capa alinhada à esquerda, número no canto */
.casa--v2 .casa__hero-inner { text-align: left; align-items: flex-start; }
.casa--v2 .casa__loc { margin-left: 0; margin-right: auto; }
.casa--v2 .casa__desc { margin-left: 0; }
.casa--v2 .casa__index { top: -0.28em; right: -0.04em; opacity: 0.7; }

/* ---- Produtos da casa (linhas alternadas) ---- */
.casa__products { padding-top: clamp(20px, 4vh, 48px); }
.casa__product-list {
  max-width: 1100px;
  margin: clamp(30px, 6vw, 58px) auto 0;
  display: grid;
  gap: clamp(30px, 6vw, 66px);
  padding: 0 clamp(20px, 5vw, 40px);
}
.casa__product {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(22px, 4vw, 48px);
  align-items: center;
}
.casa__product:nth-child(even) .casa__product-media { order: 2; }
.casa__product-media {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  background: linear-gradient(135deg, #0b1220, #05070d);
  box-shadow: var(--shadow);
}
.casa__product-media video,
.casa__product-media canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border: 0;
}
.casa__product-media--360 { cursor: grab; touch-action: pan-y; }
.casa__product-media--360.is-dragging { cursor: grabbing; }
/* Produto vertical (plano sequência em pé): quadro retrato, sem cortar */
.casa__product-media--portrait {
  aspect-ratio: 9 / 16;
  height: min(72vh, 640px);
  width: auto;
  max-width: 100%;
  margin-inline: auto;
}
.casa__product-info { text-align: left; }
.casa__product-tag {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
  border-radius: 50%;
  font-weight: 800;
  font-size: 16px;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.1);
  border: 1px solid rgba(var(--accent-rgb), 0.4);
}
.casa__product-info h3 {
  margin: 0 0 12px;
  font-size: clamp(22px, 3.6vw, 34px);
  font-weight: 800;
  letter-spacing: -0.4px;
  color: #fff;
}
.casa__product-info p {
  margin: 0;
  font-size: clamp(15px, 2vw, 17px);
  line-height: 1.65;
  color: var(--muted);
}

/* ---- Encerramento / navegação entre casas ---- */
.casa__outro { background: radial-gradient(90% 90% at 50% 0%, #0b1220 0%, var(--bg) 70%); }
.casa__pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: clamp(34px, 6vw, 54px);
}
.casa__pager-link,
.casa__pager-home {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  padding: 11px 20px;
  border-radius: 999px;
  border: 1px solid var(--hairline);
  color: var(--ink);
  background: var(--glass);
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.casa__pager-home {
  color: var(--accent);
  border-color: rgba(var(--accent-rgb), 0.4);
  background: rgba(var(--accent-rgb), 0.1);
}
.casa__pager-link:hover,
.casa__pager-home:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

@media (max-width: 720px) {
  .casa__back-label { display: none; } /* no celular, só a seta */
  .casa__product { grid-template-columns: 1fr; gap: clamp(16px, 4vw, 22px); }
  .casa__product:nth-child(even) .casa__product-media { order: 0; } /* empilha sempre vídeo em cima */
  .casa__pager { flex-direction: column; }
  .casa__pager-link, .casa__pager-home { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  body.casa { animation: none; }
}
