/* Gran Legado Residence : identidade local
   Mantém o esqueleto do styles.css (Scenario design system) e veste com a paleta
   da marca (bordô/vinho + dourado, color-pick por pixel da capa do catálogo, p.1) +
   a camada de interação do ÚNICCO: textura grain, marquee, molduras com hover-zoom
   e reveal on-scroll. Tudo escopado em body.gran-legado-residence.

   OBS de produto: torre vertical EM OBRAS na Zona Nova, Capão da Canoa (vídeo de
   acompanhamento datado maio/2025; sem data de entrega divulgada). Preço via tabela
   CNDD de 2026-07 (R$ 555 mil a R$ 1,32 milhão, até 72 meses para pagar).
*/

body.gran-legado-residence {
  /* Paleta Gran Legado Residence (color-pick por pixel, GRAN CATÁLOGO.pdf p.1) */
  --navy:        #501725;
  --navy-2:      #6C2337;
  --navy-deep:   #300E17;
  --champagne:   #B6A26E;
  --champagne-2: #D4BD87;
  --champagne-deep: #8A784B;
  --bg:          #F6EEE6;
  --bg-deep:     #ECDFD3;
  --paper:       #FBF6F0;
  --ink:         var(--navy);
  --ink-2:       var(--navy-2);
  --muted:       #6E5E58;
  --line:        rgba(80, 23, 37, 0.16);
  --line-2:      rgba(80, 23, 37, 0.08);
  --wood:        var(--champagne);

  background: var(--bg);
  color: var(--ink);
}

/* ============================================================
   GRAIN : textura sutil de ruído (do ÚNICCO) sobre seções escuras
   ============================================================ */
body.gran-legado-residence .grain { position: relative; overflow: hidden; }
body.gran-legado-residence .grain::before {
  content: "";
  position: absolute; inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.06;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.45 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}
body.gran-legado-residence .grain > .container,
body.gran-legado-residence .contato.grain .contato-inner,
body.gran-legado-residence footer.grain .row,
body.gran-legado-residence footer.grain .legal { position: relative; z-index: 2; }
body.gran-legado-residence .hero.grain .stack,
body.gran-legado-residence .hero.grain .top-meta,
body.gran-legado-residence .hero.grain .scroll-cue { position: relative; z-index: 2; }

/* ============================================================
   HERO
   ============================================================ */
body.gran-legado-residence .hero.empreendimento { min-height: 92vh; min-height: 92svh; }
body.gran-legado-residence .hero.empreendimento .scrim {
  background: linear-gradient(to top,
    rgba(24,10,15,.86) 0%, rgba(24,10,15,.76) 14%, rgba(24,10,15,.56) 32%,
    rgba(24,10,15,.34) 50%, rgba(24,10,15,.12) 66%, rgba(24,10,15,0) 80%);
}
body.gran-legado-residence .hero .stack .eyebrow { color: var(--champagne); letter-spacing: 0.34em; }
body.gran-legado-residence .hero h1 em { font-style: italic; color: var(--champagne-2); }

/* ============================================================
   MARQUEE : faixa de diferenciais rolando (do ÚNICCO)
   ============================================================ */
body.gran-legado-residence .gl-marquee {
  background: var(--navy);
  color: var(--champagne-2);
  border-top: 1px solid rgba(182,162,110,0.22);
  border-bottom: 1px solid rgba(182,162,110,0.22);
  overflow: hidden;
  padding: 16px 0;
  position: relative;
}
body.gran-legado-residence .gl-marquee .track {
  display: inline-flex; align-items: center; gap: 26px;
  white-space: nowrap;
  will-change: transform;
  animation: gl-marquee 36s linear infinite;
}
body.gran-legado-residence .gl-marquee span {
  font-family: var(--sans); font-weight: 300;
  font-size: 13px; letter-spacing: 0.26em; text-transform: uppercase;
}
body.gran-legado-residence .gl-marquee .dot { color: var(--champagne); opacity: 0.7; }
@keyframes gl-marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  body.gran-legado-residence .gl-marquee .track { animation: none; }
}

/* ============================================================
   MOLDURAS COM HOVER-ZOOM (figrow do conceito + mapa)
   ============================================================ */
body.gran-legado-residence .gl-figrow {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 16px; margin-top: clamp(32px, 4vw, 56px);
}
body.gran-legado-residence .frame {
  position: relative; overflow: hidden; margin: 0;
  background: var(--bg-deep);
  aspect-ratio: 4/3; cursor: zoom-in;
}
body.gran-legado-residence .gl-figrow .frame.wide { grid-row: span 2; aspect-ratio: 4/5; }
body.gran-legado-residence .frame img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .8s cubic-bezier(.2,.6,.2,1);
}
body.gran-legado-residence .frame:hover img { transform: scale(1.06); }
body.gran-legado-residence .frame::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(24,10,15,0.76) 100%);
  opacity: 0; transition: opacity .4s ease; pointer-events: none;
}
body.gran-legado-residence .frame:hover::after { opacity: 1; }
body.gran-legado-residence .frame figcaption {
  position: absolute; left: 20px; bottom: 16px; z-index: 2;
  display: flex; flex-direction: column; gap: 3px;
  color: var(--paper);
  transform: translateY(8px); opacity: 0;
  transition: transform .4s ease, opacity .4s ease;
}
body.gran-legado-residence .frame:hover figcaption { transform: none; opacity: 1; }
body.gran-legado-residence .frame figcaption .s {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.22em;
  text-transform: uppercase; opacity: 0.8;
}
body.gran-legado-residence .frame figcaption .n {
  font-family: var(--serif); font-style: italic; font-size: 22px; line-height: 1;
}
@media (max-width: 760px) {
  body.gran-legado-residence .gl-figrow { grid-template-columns: 1fr; }
  body.gran-legado-residence .gl-figrow .frame.wide { grid-row: auto; aspect-ratio: 4/5; }
  body.gran-legado-residence .frame figcaption { opacity: 1; transform: none; }
}

/* mapa na localização ocupa a coluna inteira da loc-grid */
body.gran-legado-residence .loc-grid .frame.map { aspect-ratio: auto; height: 100%; min-height: 320px; }

/* ============================================================
   BENTO ROOFTOP : 4 células (o material da CNDD só tem 4 fotos reais da
   cobertura , não as 6 do bento padrão) , sobrepõe os spans c1..c6 da base
   ============================================================ */
body.gran-legado-residence .club-grid.c4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-rows: minmax(260px, auto);
  gap: 4px;
}
body.gran-legado-residence .club-grid.c4 .cell.c1,
body.gran-legado-residence .club-grid.c4 .cell.c2,
body.gran-legado-residence .club-grid.c4 .cell.c3,
body.gran-legado-residence .club-grid.c4 .cell.c4 {
  grid-column: span 1;
  grid-row: span 1;
  min-height: 260px;
}
body.gran-legado-residence .club-grid .cell,
body.gran-legado-residence .esp-grid .cell {
  transition: transform .6s cubic-bezier(.2,.6,.2,1), filter .5s ease;
}
body.gran-legado-residence .club-grid .cell:hover,
body.gran-legado-residence .esp-grid .cell:hover { transform: scale(1.012); filter: brightness(1.04); }
body.gran-legado-residence .club-grid .cell .cap,
body.gran-legado-residence .esp-grid .cell .cap {
  transform: translateY(6px); opacity: 0.92;
  transition: transform .4s ease, opacity .4s ease;
}
body.gran-legado-residence .club-grid .cell:hover .cap,
body.gran-legado-residence .esp-grid .cell:hover .cap { transform: none; opacity: 1; }
@media (max-width: 980px) {
  body.gran-legado-residence .club-grid.c4 { grid-template-columns: repeat(2, 1fr); }
  body.gran-legado-residence .club-grid.c4 .cell.c1,
  body.gran-legado-residence .club-grid.c4 .cell.c2,
  body.gran-legado-residence .club-grid.c4 .cell.c3,
  body.gran-legado-residence .club-grid.c4 .cell.c4 { grid-column: span 1 !important; min-height: 240px !important; }
}
@media (max-width: 560px) {
  body.gran-legado-residence .club-grid.c4 { grid-template-columns: 1fr; }
}

/* ============================================================
   VIDA NO GRAN LEGADO : painel único (panorâmica da cobertura), sem o 2º
   slot do .esp-grid padrão , o material não tem uma 2ª foto distinta pra
   essa seção sem repetir uma célula já usada no bento acima.
   ============================================================ */
body.gran-legado-residence .esp-grid.solo {
  grid-template-columns: 1fr;
}
body.gran-legado-residence .esp-grid.solo .cell {
  aspect-ratio: 21/9;
}
@media (max-width: 760px) {
  body.gran-legado-residence .esp-grid.solo .cell { aspect-ratio: 4/3; }
}

/* ============================================================
   COMERCIALIZAÇÃO : CTA band
   ============================================================ */
body.gran-legado-residence .gl-cta-band {
  margin-top: clamp(36px, 4vw, 56px);
  padding-top: 28px; border-top: 1px solid var(--line);
  display: grid; grid-template-columns: 1fr auto; gap: clamp(24px, 4vw, 56px);
  align-items: center;
}
body.gran-legado-residence .gl-cta-band p {
  margin: 0; max-width: 56ch;
  font-size: 14px; line-height: 1.65; color: var(--ink-2);
}
@media (max-width: 760px) {
  body.gran-legado-residence .gl-cta-band { grid-template-columns: 1fr; }
}

/* ============================================================
   BRAND : selo vira monograma champagne com marca-mãe
   ============================================================ */
body.gran-legado-residence .top .brand .selo,
body.gran-legado-residence footer .brand-foot .selo {
  background: #1c2b3c url("../../assets/selo-cd.webp") center/84% no-repeat;
  border-radius: 50%; border: none; clip-path: none;
  box-shadow: 0 0 0 1px rgba(182,162,110,0.35);
}
body.gran-legado-residence .top .brand .selo::before,
body.gran-legado-residence footer .brand-foot .selo::before {
  content: none;
}

body.gran-legado-residence footer { background: var(--navy-deep); }
body.gran-legado-residence footer .brand-foot small { color: var(--champagne); }

/* contato : imagem de fundo (cobertura, lounge com lareira ao entardecer) */
body.gran-legado-residence .contato .bg {
  background: url("assets/rooftop-lounge.webp") center 38%/cover no-repeat;
  transform: scale(1.04);
}

/* CD-CONTATO-BG:start , gerado por scripts/build_contato_bg.py, nao edite a mao */
@media (max-width: 480px) and (max-resolution: 1.99dppx) { body.gran-legado-residence .contato .bg { background-image: url("assets/rooftop-lounge-480.webp"); } }
@media (max-width: 480px) and (min-resolution: 2dppx) { body.gran-legado-residence .contato .bg { background-image: url("assets/rooftop-lounge-960.webp"); } }
@media (min-width: 481px) and (max-width: 760px) { body.gran-legado-residence .contato .bg { background-image: url("assets/rooftop-lounge-960.webp"); } }
/* CD-CONTATO-BG:end */

/* CD-FRAME-MAP:start , gerado por scripts/build_frame_map.py, nao edite a mao */
body.gran-legado-residence .frame.map img { object-fit: contain; background: var(--paper); }
/* CD-FRAME-MAP:end */
