/**
 * Tema `tema02` — verde e cobre (corretor).
 *
 * Desenho próprio, do site "Roberto Claus": topo claro, capa verde-escura com foto, categorias com foto,
 * busca, faixa "Quem somos", rodapé claro — e as páginas internas (imóveis, ficha, blog, contato, Sobre)
 * no mesmo desenho. Folha única, sem Bootstrap e sem herdar CSS de outro tema.
 *
 * Cores: o tema nasce com a paleta do desenho e a imobiliária pode trocá-la no painel (color picker).
 *   --cor-principal   botões e realces                 (padrão #f4bb83, areia)
 *   --cor-secundaria  faixas escuras: capa e Quem somos (padrão #1c2823, verde-escuro)
 *   --cor-topo-fundo  fundo do topo e do rodapé        (padrão #fffdf9)
 *   --cor-font-topo   letra do topo e do rodapé        (padrão #202a24)
 * Sem cor escolhida o `var()` cai nestes padrões — as mesmas cores declaradas em `theme.json`.
 * O cobre dos ícones e links é identidade fixa do tema.
 */
body#template {
  --ouro: var(--cor-principal, #f4bb83);
  --ouro-forte: #ffd3a8;
  --areia: #f4bb83;
  --sobre-ouro: #272019;
  --ink: #202a24;
  --floresta: var(--cor-secundaria, #1c2823);
  /* Letra sobre a faixa escura: branca, ou preta se a imobiliária escolher uma cor clara. */
  --sobre-floresta: #fffdf9;
  --muted: #535c54;
  --papel: #f9f6f0;
  --branco: #fffdf9;
  --linha: #dfd8ca;
  --cobre: #ad5e25;
  --serif: Georgia, "Times New Roman", serif;
  margin: 0;
  font-family: system-ui, sans-serif;
  font-size: 15px;
  font-synthesis: none;
  color: var(--ink);
  background: var(--papel);
}
@supports (color: oklch(from red l c h)) {
  body#template {
    --sobre-ouro: oklch(from var(--ouro) clamp(0, (0.62 - l) * 1000, 1) 0 0);
    --sobre-floresta: oklch(from var(--floresta) clamp(0, (0.62 - l) * 1000, 1) 0 0);
  }
}
body#template *, body#template *::before, body#template *::after { box-sizing: border-box; }
body#template .raiz { min-height: 100vh; display: flex; flex-direction: column; overflow-x: clip; }
body#template .principal { width: 100%; flex: 1; }
body#template a { color: inherit; text-decoration: none; }
body#template button { font: inherit; cursor: pointer; }
body#template h1, body#template h2, body#template h3, body#template p { margin: 0; }
body#template h1, body#template h2 { font-family: var(--serif); font-weight: 400; letter-spacing: -.055em; }
body#template [hidden], body#template [x-cloak] { display: none !important; }
body#template a:focus-visible, body#template button:focus-visible, body#template select:focus-visible, body#template input:focus-visible, body#template textarea:focus-visible { outline: 3px solid #b06328; outline-offset: 4px; }
body#template .sangra { width: 100vw; margin-left: calc(50% - 50vw); }
body#template svg.icon { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linejoin: round; stroke-linecap: round; flex: none; }
body#template .soLeitor { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ====== botões ====== */
body#template .t02-botao, body#template .btn { display: inline-flex; gap: 9px; align-items: center; justify-content: center; width: fit-content; min-height: 46px; padding: 10px 16px; border: 1px solid transparent; border-radius: 7px; cursor: pointer; font: 700 14px/1.25 system-ui, sans-serif; transition: background-color .2s; }
body#template .t02-contorno, body#template .btn { border-color: #c9baaa; color: var(--ink); background: transparent; }
body#template .t02-contorno:hover, body#template .btn:hover { background: #f1e6d8; }
body#template .t02-primario, body#template .btn.primary { background: var(--ouro); border-color: var(--ouro); color: var(--sobre-ouro); }
body#template .t02-primario:hover, body#template .btn.primary:hover { background: var(--ouro-forte); border-color: var(--ouro-forte); }
body#template .t02-escuro, body#template .btn.dark { background: var(--floresta); border-color: var(--floresta); color: var(--sobre-floresta); }
body#template .t02-escuro:hover, body#template .btn.dark:hover { background: #344a3e; background: color-mix(in srgb, var(--floresta) 82%, #fff); }
body#template .btn.sm { min-height: 38px; padding: 6px 12px; font-size: 13px; }
body#template .btn:disabled { opacity: .45; cursor: default; }
body#template .btn.larguraTotal, body#template .larguraTotal { width: 100%; }

/* ====== peças comuns ====== */
body#template .t02-sobretitulo, body#template .eyebrow { display: flex; gap: 9px; align-items: center; font-weight: 750; font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: #905020; }
body#template .t02-sobretitulo::before, body#template .eyebrow::before { content: ""; width: 18px; height: 1px; background: currentColor; }
body#template .t02-sobretitulo span { display: none; }
body#template .t02-hero .t02-sobretitulo, body#template .t02-sobre .t02-sobretitulo { color: var(--areia); }
body#template .t02-so-desktop { display: inline; }
body#template .t02-secao-cab { display: flex; align-items: end; justify-content: space-between; gap: 15px 40px; margin-bottom: 25px; }
body#template .t02-secao-cab h2, body#template .page-head h1 { margin-top: 9px; font-size: clamp(35px, 4.5vw, 57px); line-height: 1.04; }
body#template .t02-secao-cab > p { max-width: 275px; color: var(--muted); font-size: 14px; line-height: 1.55; }

/* ====== topo ====== */
body#template .t02-topo, body#template .t02-rodape { background: var(--cor-topo-fundo, var(--branco)); color: var(--cor-font-topo, var(--ink)); }
body#template .t02-topo .t02-contorno { color: inherit; }
body#template .t02-topo-miolo { width: min(100% - 72px, 1180px); margin-inline: auto; min-height: 86px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
body#template .t02-marca { display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; }
body#template .t02-marca img { display: block; max-height: 56px; max-width: 220px; width: auto; height: auto; object-fit: contain; }
body#template .t02-marca strong { display: block; font-size: 20px; line-height: 1.15; letter-spacing: -.04em; }
body#template .t02-marca small { display: block; margin-top: 4px; font-size: 9px; text-transform: uppercase; font-weight: 700; letter-spacing: .15em; }
body#template .t02-menu { display: flex; gap: 32px; color: var(--cor-font-topo, var(--muted)); font-size: 14px; font-weight: 650; }
body#template .t02-menu a:hover, body#template .t02-menu a.ativo, body#template .t02-rodape address a:hover { color: var(--cobre); text-decoration: underline; text-underline-offset: 5px; }

/* ====== capa ====== */
body#template .public-main.t02-main-home { max-width: none; padding: 0; width: 100%; }
body#template .t02-hero { position: relative; isolation: isolate; display: grid; align-content: center; min-height: 525px; color: var(--sobre-floresta); background: var(--floresta); overflow: hidden; }
body#template .t02-hero-arte { position: absolute; inset: 0 0 0 28%; z-index: -2; width: 72%; height: 100%; object-fit: cover; object-position: center 55%; }
body#template .t02-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, #1c2823 0%, #1c2823 31%, #1c2823eb 40%, #1c28234d 63%, transparent 85%); background: linear-gradient(90deg, var(--floresta) 0%, var(--floresta) 31%, color-mix(in srgb, var(--floresta) 92%, transparent) 40%, color-mix(in srgb, var(--floresta) 30%, transparent) 63%, transparent 85%); }
body#template .t02-hero-conteudo { width: min(100% - 72px, 1180px); margin-inline: auto; padding-block: 72px 98px; }
body#template .t02-hero h1 { font-size: clamp(51px, 6vw, 89px); line-height: .98; margin-block: 21px; color: var(--sobre-floresta); }
body#template .t02-hero h1 em { font-weight: inherit; color: var(--areia); }
body#template .t02-intro { max-width: 410px; color: color-mix(in srgb, var(--sobre-floresta) 90%, transparent); font-size: 17px; line-height: 1.65; }
body#template .t02-acoes { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 25px; }
body#template .t02-link-texto { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-size: 14px; font-weight: 650; }
body#template .t02-link-texto:hover { text-decoration: underline; text-underline-offset: 5px; }
body#template .t02-hero-rodape { position: absolute; inset: auto 0 0; width: min(100% - 72px, 1180px); margin-inline: auto; padding-block: 13px; border-top: 1px solid #fef5e33b; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }

/* ====== categorias e busca ====== */
body#template .t02-catalogo { width: min(100% - 72px, 1180px); margin-inline: auto; padding-block: 62px 70px; }
body#template .t02-categorias { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
body#template .t02-categoria { display: block; overflow: hidden; border: 1px solid var(--linha); background: var(--branco); border-radius: 9px; }
body#template .t02-categoria:hover { border-color: #ad754e; background: #fff4e6; }
body#template .t02-categoria-foto { display: block; width: 100%; height: auto; aspect-ratio: 1.85; object-fit: cover; background: #d6cec0; }
body#template .t02-categoria-texto { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px; }
body#template .t02-categoria strong, body#template .t02-categoria small { display: block; }
body#template .t02-categoria strong { font-size: 15px; }
body#template .t02-categoria small { margin-top: 4px; color: var(--muted); font-size: 11px; line-height: 1.35; }
body#template .t02-categoria-texto .icon { width: 16px; color: #905020; }
body#template .t02-busca, body#template .public-search { background: var(--branco); border: 1px solid var(--linha); border-radius: 12px; padding: 24px; }
body#template .t02-busca { margin-top: 22px; }
body#template .t02-busca-cab { display: flex; gap: 12px; align-items: center; }
body#template .t02-busca-icone { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 7px; background: #f5e9da; color: #905020; }
body#template .t02-busca-cab h3 { font-size: 20px; letter-spacing: -.025em; }
body#template .t02-busca-cab p { color: var(--muted); margin-top: 4px; font-size: 14px; line-height: 1.45; }
body#template .t02-busca form { display: grid; grid-template-columns: 1fr 1fr 1.15fr auto; align-items: end; gap: 12px; margin-top: 21px; }
body#template .t02-busca label, body#template .field label { display: block; min-width: 0; font-size: 13px; font-weight: 700; }
body#template .t02-opcional { color: var(--muted); font-size: 11px; font-weight: 400; }
body#template .t02-busca select, body#template .t02-busca input,
body#template .field input:not([type="checkbox"]):not([type="radio"]), body#template .field select, body#template .field textarea { display: block; width: 100%; min-height: 46px; margin-top: 6px; padding: 9px; background: var(--branco); border: 1px solid #bcb7ab; border-radius: 6px; color: var(--ink); font: 14px/1.3 system-ui, sans-serif; }
body#template .field textarea { min-height: 110px; resize: vertical; }

/* ====== quem somos ====== */
body#template .t02-sobre { background: var(--floresta); color: var(--sobre-floresta); }
body#template .t02-sobre-miolo { width: min(100% - 72px, 1180px); margin-inline: auto; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 24px; padding-block: 42px; }
body#template .t02-sobre-miolo:has(.t02-sobre-marca) { grid-template-columns: auto 1fr auto; }
body#template .t02-sobre-marca { display: grid; place-items: center; width: 132px; aspect-ratio: 1; padding: 14px; background: var(--branco); border-radius: 8px; }
body#template .t02-sobre-marca img { max-width: 100%; max-height: 100%; object-fit: contain; }
body#template .t02-sobre h2 { margin-top: 9px; font-size: clamp(35px, 4.5vw, 57px); line-height: 1.04; color: var(--sobre-floresta); }
body#template .t02-sobre p:not(.t02-sobretitulo) { max-width: 520px; margin-top: 10px; color: color-mix(in srgb, var(--sobre-floresta) 90%, transparent); line-height: 1.55; }
body#template .t02-licenca { display: inline-block; margin-top: 13px; color: var(--areia); font-size: 12px; letter-spacing: .08em; font-weight: 700; }

/* ====== rodapé ====== */
body#template .t02-rodape-miolo { width: min(100% - 72px, 1180px); margin-inline: auto; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 18px 28px; padding-block: 22px; }
body#template .t02-rodape address { display: flex; flex-wrap: wrap; gap: 14px 20px; font-style: normal; font-size: 14px; }
body#template .t02-rodape address a { display: inline-flex; align-items: center; gap: 6px; }
body#template .t02-rodape-licenca { font-size: 12px; color: var(--muted); }
body#template .t02-rodape-base { width: min(100% - 72px, 1180px); margin-inline: auto; padding: 14px 0 70px; border-top: 1px solid var(--linha); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
body#template .t02-rodape-links { display: flex; gap: 16px; flex-wrap: wrap; }
body#template .t02-rodape-links a:hover { color: var(--cobre); text-decoration: underline; text-underline-offset: 5px; }
body#template .t02-flutuante { position: fixed; right: 16px; bottom: 17px; width: 55px; height: 55px; border-radius: 50%; background: #27cc7a; color: #fff; display: grid; place-items: center; z-index: 100; box-shadow: 0 4px 12px #0003; }
body#template .t02-flutuante:hover { background: #21b76c; }
body#template .t02-flutuante::before, body#template .t02-flutuante::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 3px solid #27cc7a; opacity: 0; pointer-events: none; animation: t02-onda 2.6s ease-out infinite; }
body#template .t02-flutuante::after { animation-delay: 1.3s; }
@keyframes t02-onda { 0% { transform: scale(1); opacity: .75; } 100% { transform: scale(2.2); opacity: 0; } }

/* ====== páginas internas (mesmo desenho) ====== */
body#template .public-main { width: min(100% - 72px, 1180px); margin-inline: auto; padding: 44px 0 70px; }
body#template .page-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
body#template .subtitle { margin-top: 10px; color: var(--muted); font-size: 15px; line-height: 1.55; max-width: 560px; }
body#template .actions { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
body#template .panel { background: var(--branco); border: 1px solid var(--linha); border-radius: 12px; margin-bottom: 20px; overflow: hidden; }
body#template .panel-head { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 22px 24px 8px; }
body#template .panel-head h2 { font-size: 26px; letter-spacing: -.04em; }
body#template .panel-head small { display: block; margin-top: 5px; color: var(--muted); font-size: 12px; }
body#template .panel-body { padding: 10px 24px 26px; }
body#template .muted { color: var(--muted); }
body#template .link { border: 0; background: none; color: var(--cobre); font-weight: 700; padding: 0; display: inline-flex; align-items: center; gap: 5px; text-decoration: underline; text-underline-offset: 5px; }
body#template .grid { display: grid; gap: 20px; }
body#template .grid.two { grid-template-columns: 1fr 1fr; }
body#template .list-row { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--linha); }
body#template .list-row:last-child { border: 0; }
body#template .badge { font-size: 11px; font-weight: 700; padding: 4px 8px; border-radius: 4px; background: #f5e9da; color: #905020; display: inline-block; white-space: nowrap; }
body#template .badge.blue { background: #e6eee9; color: #345446; }
body#template .empty { padding: 50px 20px; text-align: center; color: var(--muted); }
body#template .empty .icon { width: 32px; height: 32px; margin-bottom: 12px; }
body#template .empty p { margin: 10px 0 18px; }
body#template .form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
body#template .field { display: flex; flex-direction: column; min-width: 0; }
body#template .field.full { grid-column: 1/-1; }
body#template .check { display: flex; align-items: center; gap: 9px; font-size: 14px; line-height: 1.6; }
body#template .check input { accent-color: var(--floresta); height: 16px; width: 16px; flex-shrink: 0; }
body#template .checks { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
body#template .formulario { display: grid; gap: 16px; }
body#template .isca { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; opacity: 0; }
body#template .erro { background: #fbeceb; color: #a1473d; border: 1px solid #f0cfcb; border-radius: 6px; padding: 10px 12px; font-size: 13px; line-height: 1.6; }
body#template .sucesso { background: #eaf3ec; color: #2c5a3d; border: 1px solid #cfe2d6; border-radius: 8px; padding: 18px; line-height: 1.7; }
body#template .sucesso b { display: block; font-size: 16px; margin-bottom: 4px; }
body#template .avisoWhatsapp { font-size: 13px; color: var(--muted); }
body#template .corpo { font-size: 16px; line-height: 1.85; color: #3b463f; max-width: 860px; overflow-wrap: anywhere; }
body#template .corpo p, body#template .corpo div { margin: 0 0 14px; }
body#template .corpo h2, body#template .corpo h3 { color: var(--ink); margin: 26px 0 10px; font-size: 28px; }
body#template .corpo ul, body#template .corpo ol { padding-left: 22px; margin: 0 0 14px; }
body#template .acao { margin-top: 20px; }
body#template .postagem { display: grid; gap: 8px; }
body#template .postagem time { font-size: 12px; color: var(--muted); }

/* listagem: filtro e cartões */
body#template .public-search { display: flex; gap: 12px; align-items: flex-end; margin: 0 0 30px; }
body#template .public-search .field { flex: 1; }
body#template .t02-botao-ouro { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 18px; border: 1px solid var(--ouro); background: var(--ouro); color: var(--sobre-ouro); border-radius: 7px; font-weight: 700; }
body#template .property-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
body#template .property-card { position: relative; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--linha); background: var(--branco); border-radius: 9px; }
body#template .property-card:hover { border-color: #ad754e; }
body#template .property-card .card-foto { display: block; }
body#template .property-card img { display: block; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: #d6cec0; }
body#template .property-card .content { display: flex; flex-direction: column; flex: 1; padding: 14px 16px 16px; }
body#template .property-card .cartaoTipo { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
body#template .property-card .cartaoTipo b { color: var(--ink); font-weight: 800; }
body#template .property-card .cartaoRef { font-size: 11px; text-transform: none; letter-spacing: 0; white-space: nowrap; }
body#template .property-card h3 { margin: 8px 0 8px; font-size: 17px; line-height: 1.3; font-weight: 700; letter-spacing: -.02em; }
body#template .property-card h3 a:hover { color: var(--cobre); }
body#template .property-card .cartaoLocal { display: flex; flex-wrap: wrap; gap: 4px 14px; color: var(--muted); font-size: 13px; }
body#template .cartaoInfo { display: inline-flex; align-items: center; gap: 6px; }
body#template .cartaoInfo svg { color: var(--cobre); flex: none; }
body#template .property-card .cartaoLocal b { color: var(--ink); font-weight: 700; }
body#template .property-card .price { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 22px; font-weight: 750; letter-spacing: -.03em; }
body#template .property-card .price svg { color: var(--cobre); flex: none; }
body#template .property-card .price small { font-size: 13px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
body#template .property-card .features { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 14px; padding-top: 13px; border-top: 1px solid var(--linha); font-size: 13px; color: var(--muted); }
body#template .property-card .features b { color: var(--ink); }
body#template .etiquetas { position: absolute; top: 12px; right: 12px; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; z-index: 1; }
body#template .etiqueta { font-size: 10px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; padding: 5px 8px; border-radius: 3px; background: #18251fdd; color: #fff; }
body#template .etiquetaNegociado { background: #6b7280; }
body#template .sugerido { position: absolute; top: 12px; left: 12px; z-index: 1; }
body#template .photo-fallback { background: linear-gradient(135deg, #cfc4b2, #ebe3d4); }
body#template .paginacao { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 30px; font-size: 13px; color: var(--muted); }
body#template .pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 5px; }
body#template .pagination .btn { min-width: 40px; min-height: 40px; padding: 6px 10px; }
body#template .pagination .gap { min-width: 20px; text-align: center; }
body#template .pagination .current { background: var(--floresta); border-color: var(--floresta); color: var(--branco); }

/* ficha do imóvel */
body#template .detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }
body#template .detail-layout > * { min-width: 0; }
body#template .side-card { padding: 24px; }
body#template .side-card .price { font-family: var(--serif); font-size: 38px; letter-spacing: -.05em; margin: 8px 0 18px; }
body#template .side-card .btn { width: 100%; margin-top: 8px; }
body#template .side-card h3 { margin-top: 22px; padding-top: 22px; border-top: 1px solid var(--linha); font-size: 18px; }
body#template .metricas { display: flex; flex-wrap: wrap; gap: 28px; padding: 6px 0 22px; margin-bottom: 22px; border-bottom: 1px solid var(--linha); }
body#template .metrica, body#template .caracteristica { display: flex; align-items: center; gap: 10px; }
body#template .metricaIcone, body#template .caracteristicaIcone { color: var(--cobre); flex-shrink: 0; stroke-width: 2; }
body#template .metricas b { font-size: 22px; display: block; }
body#template .metricas small { font-size: 12px; color: var(--muted); }
body#template .description { font-size: 16px; line-height: 1.85; color: #3b463f; }
body#template .data-pairs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
body#template .data-pairs dt { color: var(--muted); font-size: 12px; margin-bottom: 6px; }
body#template .data-pairs dd { margin: 0; font-size: 15px; }
body#template .video { position: relative; aspect-ratio: 16 / 9; width: 100%; border-radius: 9px; overflow: hidden; background: #0f1c18; margin-top: 20px; }
body#template .video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
body#template .midia-imovel iframe, body#template .midia-imovel img, body#template .midia-imovel embed, body#template .midia-imovel object, body#template .midia-imovel video, body#template .midia-imovel table { max-width: 100%; }
body#template .galeria { margin-bottom: 20px; }
body#template .galeria-principal { position: relative; aspect-ratio: 4 / 3; max-height: 520px; width: 100%; border-radius: 9px; overflow: hidden; background: #d6cec0; }
/* Carrossel: a foto acompanha o dedo e encaixa na próxima (rolagem horizontal nativa + scroll-snap). */
body#template .galeria-trilho, body#template .lb-trilho { display: flex; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
body#template .galeria-trilho::-webkit-scrollbar, body#template .lb-trilho::-webkit-scrollbar { display: none; }
body#template .galeria-trilho { height: 100%; }
body#template .galeria-slide { all: unset; box-sizing: border-box; flex: 0 0 100%; width: 100%; height: 100%; scroll-snap-align: center; scroll-snap-stop: always; cursor: zoom-in; }
body#template .galeria-slide:disabled { cursor: default; }
body#template .galeria-slide:focus-visible { outline: 3px solid var(--cobre); outline-offset: -3px; }
body#template .galeria-slide img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; pointer-events: none; }
body#template .galeria-seta { position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 0; background: #000a; color: #fff; font-size: 26px; line-height: 1; }
body#template .galeria-seta.volta { left: 10px; }
body#template .galeria-seta.proxima { right: 10px; }
body#template .galeria-contador { position: absolute; left: 10px; bottom: 10px; background: #000a; color: #fff; border-radius: 20px; padding: 4px 10px; font-size: 12px; }
body#template .galeria-todas { position: absolute; right: 10px; bottom: 10px; background: var(--branco); border-color: var(--linha); }
body#template .galeria-mini { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 8px; }
body#template .galeria-mini button { position: relative; aspect-ratio: 4 / 3; padding: 0; border: 2px solid transparent; border-radius: 7px; overflow: hidden; background: #d6cec0; }
body#template .galeria-mini button.ativa { border-color: var(--cobre); }
body#template .galeria-mini img { width: 100%; height: 100%; object-fit: cover; display: block; }
body#template .galeria-mais { position: absolute; inset: 0; display: grid; place-items: center; background: #000b; color: #fff; font-size: 20px; font-weight: 700; }
body#template .galeria-acoes { margin-top: 8px; display: flex; justify-content: flex-end; }
/* galeria em tela cheia (sem biblioteca externa) */
body#template .lb { position: fixed; inset: 0; z-index: 1000; background: #000e; display: grid; grid-template-columns: 56px 1fr 56px; grid-template-rows: 1fr auto; align-items: center; }
body#template .lb-trilho { grid-column: 2; grid-row: 1; height: 100%; min-height: 0; min-width: 0; padding-top: 48px; padding-bottom: 8px; }
body#template .lb-slide { flex: 0 0 100%; width: 100%; height: 100%; display: grid; place-items: center; scroll-snap-align: center; scroll-snap-stop: always; }
body#template .lb-slide img { max-width: 100%; max-height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; }
body#template .lb-contador { position: absolute; top: 12px; left: 16px; color: #fff; font-size: 13px; }
body#template .lb-fechar { position: absolute; top: 6px; right: 12px; background: none; border: 0; color: #fff; font-size: 34px; line-height: 1; padding: 6px 10px; z-index: 2; }
body#template .lb-seta { background: none; border: 0; color: #fff; font-size: 44px; line-height: 1; height: 100%; width: 100%; opacity: .85; }
body#template .lb-seta:hover { opacity: 1; }
body#template .lb-seta.volta { grid-column: 1; grid-row: 1; }
body#template .lb-seta.proxima { grid-column: 3; grid-row: 1; }
body#template .lb-minis { grid-column: 1 / -1; grid-row: 2; display: flex; gap: 8px; justify-content: safe center; overflow-x: auto; padding: 10px 14px 14px; }
body#template .lb-minis button { flex: 0 0 auto; width: 90px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 4px; overflow: hidden; background: #222; opacity: .6; }
body#template .lb-minis button.ativa { border-color: #fff; opacity: 1; }
body#template .lb-minis img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Gaveta do filtro (só celular) */
body#template .t02-fundo, body#template .t02-gaveta-fechar, body#template .t02-gaveta-cab, body#template .t02-gatilho-lista { display: none; }

@media (max-width: 1060px) {
  body#template .property-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body#template .detail-layout { grid-template-columns: minmax(0, 1fr) 290px; }
}
@media (max-width: 960px) {
  body#template .t02-categorias { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body#template .t02-busca form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body#template .t02-busca form .t02-botao { width: 100%; }
  body#template .detail-layout { grid-template-columns: minmax(0, 1fr); }
  body#template .checks { grid-template-columns: repeat(2, 1fr); }
}
@media (hover: none) { body#template .galeria-seta { display: none; } }
@media (max-width: 680px) {
  body#template .t02-topo-miolo, body#template .t02-hero-conteudo, body#template .t02-hero-rodape, body#template .t02-catalogo,
  body#template .t02-sobre-miolo, body#template .t02-rodape-miolo, body#template .t02-rodape-base, body#template .public-main { width: calc(100% - 32px); }
  body#template .t02-topo-miolo { flex-wrap: wrap; gap: 3px 10px; padding-block: 8px; min-height: unset; }
  body#template .t02-marca strong { font-size: 18px; }
  body#template .t02-marca img { max-height: 44px; max-width: 160px; }
  body#template .t02-menu { order: 3; width: 100%; justify-content: space-between; border-top: 1px solid #eee7dc; padding-top: 4px; gap: 6px; }
  body#template .t02-menu a { display: flex; align-items: center; min-height: 38px; }
  body#template .t02-topo-whats { min-height: 40px; padding: 7px 8px; font-size: 12px; }
  body#template .t02-hero { min-height: 555px; align-content: start; }
  body#template .t02-hero-conteudo { padding-block: 34px 215px; }
  body#template .t02-hero-arte { inset: auto 0 0; width: 100%; height: 62%; object-position: 62% center; }
  body#template .t02-hero::after { background: linear-gradient(180deg, #1c2823 22%, #1c2823f5 36%, #1c2823a8 59%, #1c282333 82%, #1c2823c9); background: linear-gradient(180deg, var(--floresta) 22%, color-mix(in srgb, var(--floresta) 96%, transparent) 36%, color-mix(in srgb, var(--floresta) 66%, transparent) 59%, color-mix(in srgb, var(--floresta) 20%, transparent) 82%, color-mix(in srgb, var(--floresta) 79%, transparent) 100%); }
  body#template .t02-so-desktop { display: none; }
  body#template .t02-intro { font-size: 15px; }
  body#template .t02-acoes { gap: 4px 12px; margin-top: 17px; }
  body#template .t02-catalogo { padding-block: 36px 42px; }
  body#template .t02-secao-cab, body#template .page-head { display: block; margin-bottom: 16px; }
  body#template .t02-secao-cab > p { margin-top: 9px; max-width: none; }
  body#template .page-head .actions { margin-top: 14px; }
  body#template .t02-categorias { gap: 8px; }
  body#template .t02-categoria-texto { padding: 9px; }
  body#template .t02-categoria strong { font-size: 13px; }
  body#template .t02-categoria-texto .icon { display: none; }
  body#template .t02-busca, body#template .public-search { padding: 14px; }
  body#template .t02-busca form { grid-template-columns: 1fr; }
  body#template .t02-busca select, body#template .t02-busca input, body#template .field input, body#template .field select, body#template .field textarea { font-size: 16px; }
  body#template .t02-sobre-miolo, body#template .t02-sobre-miolo:has(.t02-sobre-marca) { grid-template-columns: 1fr; gap: 14px; padding-block: 30px; }
  body#template .t02-sobre-marca { display: none; }
  body#template .t02-rodape-miolo, body#template .t02-rodape address { align-items: flex-start; flex-direction: column; }
  body#template .public-main { padding: 28px 0 46px; }
  body#template .property-grid, body#template .form-grid, body#template .grid.two { grid-template-columns: 1fr; }
  body#template .checks { grid-template-columns: 1fr 1fr; gap: 12px; }
  body#template .data-pairs { gap: 18px; }
  body#template .metricas { gap: 20px; }
  body#template .galeria-mini { gap: 6px; }
  body#template .lb { grid-template-columns: 1fr; }
  body#template .lb-seta { display: none; }
  body#template .lb-trilho { grid-column: 1; }

  /* Filtro da listagem: botão "Filtrar imóveis"; a caixa vira gaveta pela direita. */
  body#template .t02-fundo { display: block; position: fixed; inset: 0; z-index: 140; background: rgba(0, 0, 0, .6); opacity: 0; visibility: hidden; transition: opacity .25s, visibility 0s linear .25s; }
  body#template .t02-fundo.aberto { opacity: 1; visibility: visible; transition: opacity .25s, visibility 0s; }
  body#template .t02-gaveta-fechar { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 42px; height: 42px; padding: 0; background: transparent; color: var(--ink); border: 1px solid var(--linha); border-radius: 10px; font-size: 28px; line-height: 1; }
  body#template .t02-gaveta-cab { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: sticky; top: 0; z-index: 1; padding: 14px 0; margin-bottom: 12px; background: var(--branco); border-bottom: 1px solid var(--linha); font-size: 18px; }
  body#template .t02-gatilho-lista { display: inline-flex; width: 100%; min-height: 48px; }
  body#template .t02-filtro-lista { margin: 0 0 22px; }
  body#template .t02-filtro-lista .public-search { position: fixed; top: 0; right: 0; bottom: 0; z-index: 150; width: min(88vw, 380px); margin: 0; padding: 0 16px 24px; flex-direction: column; flex-wrap: nowrap; align-items: stretch; align-content: flex-start; gap: 14px; border: 0; border-radius: 0; box-shadow: -8px 0 24px #0006; overflow-y: auto; transform: translateX(102%); visibility: hidden; transition: transform .28s ease, visibility 0s linear .28s; }
  body#template .t02-filtro-lista .public-search.aberto { transform: none; visibility: visible; transition: transform .28s ease, visibility 0s; }
  body#template .t02-filtro-lista .public-search .field { flex: none; }
}
@media (prefers-reduced-motion: reduce) {
  body#template .t02-flutuante::before, body#template .t02-flutuante::after { animation: none; display: none; }
  body#template .t02-filtro-lista .public-search, body#template .t02-filtro-lista .public-search.aberto,
  body#template .t02-fundo, body#template .t02-fundo.aberto, body#template .t02-botao, body#template .btn { transition: none; }
}
