/* =========================================================
   Casa térrea à venda no Alphaville II – Campo Grande–MS
   Paleta: verde-floresta, creme, areia e dourado · Fonte: Asap
   ========================================================= */

:root {
  --ink: #14211d;
  --ink-soft: #4a5752;
  --forest: #102b24;
  --forest-light: #1d483c;
  --forest-deep: #091d18;
  --cream: #f3eee3;
  --paper: #fbf8f1;
  --sand: #e9e2d5;
  --gold: #b9944a;          /* botões e filetes */
  --gold-light: #dfc078;    /* rótulos sobre verde */
  --gold-text: #7d5f22;     /* rótulos sobre creme (contraste AA) */
  --line: rgba(20, 33, 29, 0.16);
  --line-dark: rgba(255, 255, 255, 0.14);
  --whatsapp: #25d366;

  --font: "Asap", Arial, sans-serif;
  --wrap: 1240px;
  --gutter: clamp(20px, 5vw, 64px);
  --header-h: 72px;
  --mobile-bar-h: 70px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 8px); }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
picture { display: contents; }
[hidden] { display: none !important; }
h1, h2, h3 { font-family: var(--font); font-weight: 400; margin: 0; text-wrap: balance; }
p { margin: 0; }
a { color: inherit; }
figure { margin: 0; }

:focus-visible { outline: 2px solid var(--forest-light); outline-offset: 3px; }
.hero :focus-visible, .section-forest :focus-visible, .cta :focus-visible, .site-header :focus-visible,
.site-footer :focus-visible, .mobile-bar :focus-visible, .lightbox :focus-visible { outline-color: var(--gold-light); }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--paper); color: var(--forest); padding: 10px 16px; font-weight: 700; text-decoration: none; }
.skip-link:focus { top: 12px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

/* Rótulo numerado */
.label {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold-light);
}
.label-dark { color: var(--gold-text); }

/* ---------- Botões ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 28px; border-radius: 2px;
  font-family: var(--font); font-size: 0.74rem; font-weight: 700; letter-spacing: 0.13em; text-transform: uppercase;
  text-decoration: none; border: 1px solid transparent; cursor: pointer;
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}
.btn .icon { width: 18px; height: 18px; flex: none; }
.btn-gold { background: var(--gold-light); color: var(--forest); }
.btn-gold:hover { background: #ead08f; }
.btn-ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.55); }
.btn-ghost:hover { border-color: var(--gold-light); color: var(--gold-light); }
.btn-small { min-height: 46px; padding: 10px 16px; font-size: 0.68rem; letter-spacing: 0.08em; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }
.btn-row-center { justify-content: center; }

/* ---------- 1. Cabeçalho (transparente sobre a fachada) ---------- */

.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40; color: #fff;
  background: linear-gradient(180deg, rgba(9, 29, 24, 0.7), rgba(9, 29, 24, 0));
  transition: background-color .3s ease, box-shadow .3s ease;
}
.site-header.is-solid, .no-js .site-header { background: rgba(16, 43, 36, 0.97); box-shadow: 0 1px 0 var(--line-dark); }
.header-inner { min-height: var(--header-h); display: flex; align-items: center; gap: 28px; }

.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; margin-right: auto; min-width: 0; }
.brand-logo { height: 46px; width: auto; }
.brand-creci { font-size: 0.6rem; font-weight: 700; letter-spacing: 0.16em; line-height: 1.35; color: var(--gold-light); padding-left: 14px; border-left: 1px solid var(--line-dark); white-space: nowrap; }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 30px; }
.site-nav a { text-decoration: none; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(255, 255, 255, 0.9); padding: 8px 0; border-bottom: 1px solid transparent; }
.site-nav a:hover { color: var(--gold-light); border-bottom-color: var(--gold-light); }

.btn-header { min-height: 42px; padding: 8px 16px; font-size: 0.68rem; color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.btn-header .icon { color: var(--whatsapp); }
.btn-header:hover { border-color: var(--gold-light); }

/* ---------- 2. Abertura ---------- */

.hero {
  position: relative; min-height: 100vh; min-height: 100svh; color: #fff;
  display: flex; align-items: flex-end; background: var(--forest); overflow: hidden;
}
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 62% 50%; }
.hero.no-photo .hero-img { display: none; }
/* Celular: casa visível no alto, texto sobre a parte escura de baixo */
.hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7, 28, 23, 0.15) 0%, rgba(7, 28, 23, 0.1) 26%, rgba(7, 28, 23, 0.82) 52%, rgba(7, 28, 23, 0.95) 100%); }
.hero-content { position: relative; z-index: 1; padding-top: calc(var(--header-h) + 40px); padding-bottom: 56px; }
.hero h1 { font-size: clamp(2.4rem, 8.6vw, 4.6rem); line-height: 1.02; letter-spacing: -0.045em; max-width: 13ch; margin: 18px 0 20px; }
.hero-features { font-size: 1.02rem; color: rgba(255, 255, 255, 0.88); max-width: 40ch; }
.hero-features span { color: var(--gold-light); margin: 0 6px; }
.hero-price { margin: 22px 0 28px; font-size: clamp(1.9rem, 6vw, 2.6rem); font-weight: 500; letter-spacing: -0.02em; white-space: nowrap; }

/* ---------- Seções ---------- */

.section { position: relative; padding: clamp(72px, 11vw, 140px) 0; overflow: hidden; }
.section-paper { background: var(--paper); }
.section-cream { background: var(--cream); }
.section-sand { background: var(--sand); }
.section-forest { background: var(--forest); color: rgba(255, 255, 255, 0.78); }
.section > .wrap { position: relative; z-index: 1; }

.section h2 { font-size: clamp(2rem, 5.2vw, 3.3rem); line-height: 1.08; letter-spacing: -0.035em; color: var(--ink); margin: 16px 0 0; max-width: 20ch; }
.section-forest h2, .cta h2 { color: #fff; }

.head-note { color: var(--ink-soft); font-size: 0.95rem; margin-top: 14px; }
.section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 8px 32px; }

/* ---------- 01 · O imóvel ---------- */

.two-col { display: grid; gap: 32px; }
.col-text { display: grid; gap: 18px; color: var(--ink-soft); font-size: 1.05rem; line-height: 1.75; max-width: 60ch; }
.metrics { margin: 18px 0 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.metric { padding: 22px 0; }
.metric + .metric { border-left: 1px solid var(--line); padding-left: 24px; }
.metric dt { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-text); }
.metric dd { margin: 8px 0 0; font-size: clamp(2.6rem, 8vw, 3.6rem); line-height: 1; letter-spacing: -0.04em; color: var(--ink); }
.metric dd span { font-size: 0.4em; letter-spacing: 0; color: var(--ink-soft); }

/* ---------- 02 · Ambientes ---------- */

.gallery { list-style: none; margin: 44px 0 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 28px; }
.gallery-item { display: flex; flex-direction: column; min-width: 0; }
.gallery-btn {
  display: block; width: 100%; padding: 0; border: 0; border-radius: 4px; overflow: hidden;
  background: var(--sand); cursor: zoom-in; aspect-ratio: 4 / 5;
  box-shadow: 0 22px 44px -28px rgba(9, 29, 24, 0.55);
}
.r-land .gallery-btn { aspect-ratio: 5 / 3; }
.gallery-btn img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
.gallery-btn:hover img { transform: scale(1.03); }
.gallery-caption { margin-top: 12px; font-size: 0.86rem; color: var(--ink-soft); }

/* ---------- 03 e 06 · Seções verdes com foto ---------- */

.watermark { position: absolute; right: -60px; bottom: -80px; width: 340px; height: auto; opacity: 0.06; pointer-events: none; z-index: 0; }
.split { display: grid; gap: 44px; align-items: center; }
.split-text { display: grid; gap: 20px; font-size: 1.05rem; line-height: 1.75; max-width: 58ch; }
.split-text h2 { margin: 0; }
.split-media img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 4px; }
.split-media figcaption { margin-top: 12px; font-size: 0.84rem; color: rgba(255, 255, 255, 0.62); }
.quote { margin: 8px 0 0; padding: 4px 0 4px 22px; border-left: 2px solid var(--gold-light); color: #fff; font-size: 1.25rem; line-height: 1.5; }

/* ---------- 04 · Diferenciais ---------- */

.cards { display: grid; grid-template-columns: 1fr; margin-top: 44px; border: 1px solid var(--line); background: var(--paper); }
.card { padding: clamp(28px, 4vw, 44px); border-bottom: 1px solid var(--line); }
.card:last-child { border-bottom: 0; }
.card-label { font-size: 0.68rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-text); }
.card h3 { font-size: clamp(1.5rem, 3vw, 1.8rem); line-height: 1.2; letter-spacing: -0.02em; color: var(--ink); margin: 18px 0 14px; }
.card ul { list-style: none; margin: 0; padding: 0; color: var(--ink-soft); }
.card li { padding: 4px 0; }

.photo-row { display: grid; grid-template-columns: 1fr; gap: 24px; margin-top: 32px; }
.photo-row img { width: 100%; height: clamp(300px, 40vw, 460px); object-fit: cover; border-radius: 4px; }
.photo-row figcaption { margin-top: 10px; font-size: 0.86rem; color: var(--ink-soft); }

/* ---------- 05 · Ficha técnica ---------- */

.accordion { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 36px; }
.accordion details { background: var(--paper); border: 1px solid var(--line); border-radius: 2px; }
.accordion summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 56px; padding: 14px 20px; font-size: 1rem; color: var(--ink);
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after { content: "+"; font-size: 1.3rem; line-height: 1; color: var(--gold-text); transition: transform .25s ease; }
.accordion details[open] summary::after { transform: rotate(45deg); }
.accordion summary:hover { color: var(--forest-light); }
.accordion ul { margin: 0; padding: 0 20px 18px 38px; color: var(--ink-soft); }
.accordion li { padding: 3px 0; }
.source { padding: 0 20px 18px; font-size: 0.8rem; color: var(--ink-soft); }
.source a { color: var(--forest-light); text-underline-offset: 3px; }

/* ---------- Contato ---------- */

.cta { background: var(--forest); color: #fff; text-align: center; border-top: 1px solid var(--line-dark); }
.cta-inner { display: flex; flex-direction: column; align-items: center; }
.seal { width: clamp(120px, 26vw, 160px); height: auto; margin-bottom: 30px; }
.cta h2 { margin-left: auto; margin-right: auto; }
.cta-text { margin-top: 18px; font-size: 1.05rem; color: rgba(255, 255, 255, 0.78); max-width: 52ch; }
.cta-price { margin: 26px 0 30px; font-size: clamp(1.9rem, 6vw, 2.6rem); font-weight: 500; letter-spacing: -0.02em; white-space: nowrap; }
.agent { margin-top: 36px; padding-top: 24px; border-top: 1px solid var(--line-dark); display: flex; flex-direction: column; gap: 4px; }
.agent strong { font-size: 1.2rem; font-weight: 500; }
.agent span { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-light); }

/* ---------- Rodapé ---------- */

.site-footer { background: var(--forest-deep); color: rgba(255, 255, 255, 0.72); padding: 56px 0 0; }
.footer-inner { display: grid; gap: 28px; padding-bottom: 40px; }
.footer-logo { width: 200px; height: auto; }
.footer-meta { margin-top: 14px; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold-light); }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.footer-links a { display: inline-flex; flex-wrap: wrap; gap: 2px 12px; padding: 9px 0; text-decoration: none; overflow-wrap: anywhere; }
.footer-links a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.fl-label { min-width: 92px; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-light); padding-top: 4px; }
.footer-note { border-top: 1px solid rgba(255, 255, 255, 0.08); padding: 20px var(--gutter); text-align: center; font-size: 0.76rem; letter-spacing: 0.06em; color: rgba(255, 255, 255, 0.56); }

/* ---------- Barra inferior (celular) ---------- */

.mobile-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  display: flex; align-items: center; gap: 12px;
  padding: 10px var(--gutter);
  padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  padding-left: calc(var(--gutter) + env(safe-area-inset-left, 0px));
  padding-right: calc(var(--gutter) + env(safe-area-inset-right, 0px));
  background: rgba(16, 43, 36, 0.97); border-top: 1px solid var(--line-dark); color: #fff;
  transition: transform .3s ease, visibility .3s;
}
.mobile-bar.is-hidden { transform: translateY(110%); visibility: hidden; }
.mobile-bar-mark { width: 13px; height: auto; flex: none; }
.mobile-bar-price { font-size: 1.15rem; font-weight: 500; white-space: nowrap; margin-right: auto; }
body { padding-bottom: calc(var(--mobile-bar-h) + env(safe-area-inset-bottom, 0px)); }

/* ---------- Ampliação ---------- */

.lightbox { width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(9, 29, 24, 0.97); color: #fff; overflow: hidden; }
.lightbox::backdrop { background: rgba(9, 29, 24, 0.9); }
.lightbox[open] { display: flex; align-items: center; justify-content: center; }
.lightbox-figure { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 70px 16px 76px; touch-action: pan-y pinch-zoom; }
.lightbox-img { max-width: 100%; max-height: calc(100% - 44px); width: auto; height: auto; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.lightbox-caption { margin-top: 16px; font-size: 0.92rem; text-align: center; color: rgba(255, 255, 255, 0.88); }
.lightbox-count { position: absolute; top: 24px; left: 22px; font-size: 0.72rem; font-weight: 700; letter-spacing: 0.2em; color: var(--gold-light); }
.lightbox-mark { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); width: 104px; height: auto; opacity: 0.85; }
.lb-btn { position: absolute; width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid rgba(255, 255, 255, 0.32); border-radius: 50%; background: rgba(16, 43, 36, 0.7); color: #fff; cursor: pointer; }
.lb-btn svg { width: 22px; height: 22px; }
.lb-btn:hover { border-color: var(--gold-light); color: var(--gold-light); }
.lb-close { top: 10px; right: 10px; }
.lb-prev { left: 10px; bottom: 14px; }
.lb-next { right: 10px; bottom: 14px; }
.lightbox.single .lb-prev, .lightbox.single .lb-next { display: none; }

/* Celular e tablet: fachada inteira no topo, texto abaixo em verde */
@media (max-width: 1023px) {
  .hero { display: block; min-height: 0; }
  .hero-img { position: relative; inset: auto; height: auto; aspect-ratio: 1619 / 971; object-position: center 58%; }
  .hero-shade { display: none; }
  .hero-content { padding-top: 36px; padding-bottom: 52px; }
  .site-header { background: rgba(16, 43, 36, 0.97); }
  main { padding-top: var(--header-h); }
}

/* =========================================================
   Responsivo
   ========================================================= */

@media (max-width: 959px) { .site-nav { display: none; } }

@media (max-width: 400px) {
  .brand-logo { height: 40px; }
  .brand { gap: 10px; }
  .brand-creci { font-size: 0.54rem; padding-left: 10px; letter-spacing: 0.1em; }
  .btn-header span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .btn-header { padding: 8px 12px; }
  .hero .btn-row .btn { flex: 1 1 100%; }
  .mobile-bar-price { font-size: 1.05rem; }
}

@media (min-width: 600px) {
  .gallery { grid-template-columns: 1fr 1fr; gap: 34px 24px; }
  .r-land { grid-column: 1 / -1; }
  .r-land .gallery-btn { aspect-ratio: 16 / 9; }
  .cards { grid-template-columns: 1fr 1fr; }
  .card { border-right: 1px solid var(--line); }
  .card:nth-child(2n) { border-right: 0; }
  .card:nth-child(n+3) { border-bottom: 0; }
  .card:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .photo-row { grid-template-columns: 1.6fr 1fr; }
  .accordion { grid-template-columns: 1fr 1fr; align-items: start; }
}

@media (min-width: 768px) {
  .mobile-bar { display: none; }
  body { padding-bottom: 0; }
}

@media (min-width: 1024px) {
  :root { --header-h: 92px; }
  .brand-logo { height: 54px; }

  /* Abertura: escurecimento da esquerda para a direita, como no modelo */
  .hero { align-items: center; }
  .hero-shade { background: linear-gradient(90deg, rgba(7, 28, 23, 0.92) 0%, rgba(7, 28, 23, 0.72) 42%, rgba(7, 28, 23, 0.18) 78%, rgba(7, 28, 23, 0.05) 100%); }
  .hero-img { object-position: 60% 55%; }
  .hero-content { padding-top: var(--header-h); padding-bottom: 0; }
  .hero h1 { font-size: 4.4rem; }

  .two-col { grid-template-columns: 1fr 1fr; gap: 96px; align-items: start; }
  .two-col h2 { font-size: 3.1rem; }

  .mosaic { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 40px 24px; }
  .mosaic .gallery-item { grid-column: auto; }
  .mosaic .gallery-btn { aspect-ratio: auto; flex: 1; }
  .mosaic .m-a { grid-column: 1 / 9; }
  .mosaic .m-b { grid-column: 9 / 13; }
  .mosaic .m-c { grid-column: 1 / 5; }
  .mosaic .m-d { grid-column: 5 / 9; }
  .mosaic .m-e { grid-column: 9 / 13; }
  .mosaic .m-f { grid-column: 1 / 8; }
  .mosaic .m-g { grid-column: 8 / 13; }
  .mosaic .m-a .gallery-btn, .mosaic .m-b .gallery-btn { height: clamp(420px, 38vw, 560px); }
  .mosaic .m-c .gallery-btn, .mosaic .m-d .gallery-btn, .mosaic .m-e .gallery-btn { height: clamp(440px, 40vw, 600px); }
  .mosaic .m-f .gallery-btn, .mosaic .m-g .gallery-btn { height: clamp(400px, 36vw, 540px); }

  .split { grid-template-columns: 1.05fr 0.95fr; gap: 96px; }
  .split-media img { aspect-ratio: 5 / 6; }
  .split-reverse { grid-template-columns: 0.95fr 1.05fr; }
  .watermark { width: 460px; right: -80px; bottom: -120px; }

  .photo-row img { height: 460px; }

  .footer-inner { grid-template-columns: 1fr 1.2fr; column-gap: 72px; align-items: start; }

  .lb-prev, .lb-next { top: 50%; bottom: auto; transform: translateY(-50%); }
  .lb-prev { left: 24px; }
  .lb-next { right: 24px; }
  .lb-close { top: 20px; right: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .gallery-btn:hover img { transform: none; }
}
