/* Miguel Carneiro: página de cada imóvel, lista de imóveis, páginas de texto, galeria em ecrã inteiro */

/* Página do imóvel */
.imovel { padding-top: calc(var(--hdr) + 28px); }
.crumbs { display: flex; flex-wrap: wrap; gap: 10px; font-size: 13px; color: var(--mute); margin-bottom: 28px; }
.crumbs a:hover { color: var(--ink); }
.imovel__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 24px 48px; margin-bottom: 32px; }
.imovel__head .eyebrow { margin-bottom: 16px; }
.imovel__head h1 { max-width: 16em; }
.imovel__price { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; text-align: right; }
.imovel__price-v { font: 400 clamp(1.9rem, 3vw, 2.7rem)/1 var(--serif); }
.imovel__price small { color: var(--mute); font-size: 12.5px; }
.mosaic { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: repeat(2, 1fr); gap: 8px; height: clamp(360px, 52vw, 660px); border-radius: 4px; overflow: hidden; }
.mosaic__i { position: relative; padding: 0; border: 0; background: var(--sand); overflow: hidden; cursor: zoom-in; }
.mosaic__i img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease), opacity .4s; }
.mosaic__i:hover img { transform: scale(1.04); }
.mosaic__i:first-child { grid-column: span 2; grid-row: span 2; }
.mosaic--1 .mosaic__i:first-child { grid-column: 1 / -1; }
.mosaic--2 .mosaic__i:nth-child(2) { grid-column: span 2; grid-row: span 2; }
.mosaic--3 .mosaic__i:nth-child(n+2) { grid-column: span 2; }
.mosaic--4 .mosaic__i:nth-child(4) { grid-column: span 2; }
.mosaic__all { position: absolute; right: 18px; bottom: 18px; box-shadow: 0 10px 24px rgba(0, 0, 0, .18); }
.imovel__grid { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: clamp(40px, 6vw, 96px); padding: clamp(40px, 5vw, 72px) 0 clamp(64px, 8vw, 120px); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); margin: 0 0 40px; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.facts > div { padding: 18px 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts dt { font: 600 10.5px/1.4 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--mute); margin-bottom: 6px; }
.facts dd { margin: 0; font: 400 1.5rem/1.15 var(--serif); }
.imovel__lead { font: 400 clamp(1.5rem, 2.2vw, 2rem)/1.25 var(--serif); margin-bottom: 28px; }
.feats { display: flex; flex-wrap: wrap; gap: 8px; }
.feats li { padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; background: var(--paper); }
.video { position: relative; aspect-ratio: 16 / 9; border-radius: 4px; overflow: hidden; background: var(--ink); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.imovel__aside { position: relative; }
.book { position: sticky; top: calc(var(--hdr) + 24px); padding: 28px; background: var(--paper); border: 1px solid var(--line); border-radius: 6px; }
.book__who { display: flex; align-items: center; gap: 14px; padding-bottom: 20px; margin-bottom: 22px; border-bottom: 1px solid var(--line); }
.book__who img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; object-position: top; background: var(--sand); }
.book__who div { display: flex; flex-direction: column; line-height: 1.3; }
.book__who b { font-weight: 600; }
.book__who span { font-size: 13px; color: var(--mute); }
.book .form__title { font-size: 1.8rem; margin-bottom: 16px; }
.form--compact .fld textarea { min-height: 76px; }
.form--compact .fld input { min-height: 46px; }
.book__alt { display: grid; gap: 10px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); text-align: center; }
.book__tel { font-size: 13.5px; color: var(--mute); }
.book__tel:hover { color: var(--ink); }
.related { background: var(--paper); }
.related .sec__head { grid-template-columns: 1fr auto; }
@media (max-width: 1000px) {
  .imovel__grid { grid-template-columns: 1fr; }
  .book { position: static; }
}
@media (max-width: 700px) {
  .mosaic { display: block; height: auto; aspect-ratio: 4 / 3.2; }
  .mosaic__i:not(:first-child) { display: none; }
  .mosaic__i:first-child { position: absolute; inset: 0; }
  .imovel__price { align-items: flex-start; text-align: left; }
  .related .sec__head { grid-template-columns: 1fr; }
}

/* Todos os imóveis */
.iarchive { padding: calc(var(--hdr) + clamp(40px, 6vw, 88px)) 0 clamp(80px, 10vw, 140px); }
.archive__head { max-width: 900px; margin-bottom: clamp(36px, 4vw, 56px); }
.archive__head .lead { margin-top: 24px; }
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 18px; padding: 18px 0; margin-bottom: 36px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.filters__f { display: flex; flex-direction: column; gap: 6px; }
.filters__f span { font: 600 10.5px/1.3 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--mute); }
.filters select { min-width: 190px; min-height: 46px; padding: 0 38px 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%237A7168' stroke-width='1.5'%3E%3Cpath d='m1 1 5 5 5-5'/%3E%3C/svg%3E") no-repeat right 16px center; appearance: none; font-size: 14.5px; }
.filters__check { display: flex; align-items: center; gap: 8px; min-height: 46px; font-size: 14.5px; }
.filters__check input { width: 18px; height: 18px; accent-color: var(--accent); }
.filters__n { margin: 0 0 0 auto; align-self: center; color: var(--mute); font-size: 14px; }
.filters__n b { color: var(--ink); }
.archive__empty { padding: 40px 0; font: 400 1.5rem/1.3 var(--serif); }
.archive__empty a { color: var(--accent); text-decoration: underline; }
@media (max-width: 640px) { .filters__f, .filters select { width: 100%; } .filters__n { margin: 0; } }

/* Páginas de texto */
.tpage { padding: calc(var(--hdr) + clamp(40px, 6vw, 88px)) var(--gut) clamp(80px, 10vw, 140px); }
.page__head { max-width: 900px; margin-bottom: 40px; }
.page__img { margin: 0 0 40px; border-radius: 4px; overflow: hidden; }
.prose { max-width: 46em; color: var(--ink2); }
.prose h2 { font: 400 clamp(1.6rem, 2.4vw, 2.1rem)/1.15 var(--serif); color: var(--ink); margin: 1.6em 0 .5em; }
.prose h3 { font-weight: 600; color: var(--ink); margin: 1.4em 0 .4em; }
.prose a { color: var(--accent); text-decoration: underline; }
.prose ul { list-style: disc; padding-left: 1.2em; margin-bottom: 1em; }
.page__item { padding: 24px 0; border-bottom: 1px solid var(--line); }
.tpage.page--404 { min-height: 80vh; display: flex; flex-direction: column; justify-content: center; }
.page--404 .lead { margin: 24px 0 32px; }
.page__mono { width: 90px; color: var(--accent); stroke-width: 1.4; margin-bottom: 32px; }
.page__mono path { vector-effect: non-scaling-stroke; }

/* Galeria em ecrã inteiro */
.lb { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(14, 12, 10, .96); color: #fff; }
.lb[open] { display: grid; grid-template-columns: 72px 1fr 72px; align-items: center; }
.lb::backdrop { background: rgba(0, 0, 0, .6); }
.lb__fig { margin: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 56px 0 24px; min-width: 0; }
.lb__fig img { max-width: 100%; max-height: calc(100dvh - 120px); object-fit: contain; }
.lb__n { font-size: 13px; color: rgba(255, 255, 255, .6); }
.lb__nav, .lb__x { border: 0; background: none; color: #fff; font-size: 26px; width: 56px; height: 56px; border-radius: 50%; transition: background .25s; }
.lb__nav:hover, .lb__x:hover { background: rgba(255, 255, 255, .1); }
.lb__x { position: absolute; top: 12px; right: 12px; font-size: 34px; }
@media (max-width: 640px) { .lb[open] { grid-template-columns: 44px 1fr 44px; } .lb__nav { width: 44px; } }
