/* =========================================
   ESTILOS DA PÁGINA EXCLUSIVA DO IMÓVEL
========================================= */

/* Cabeçalho do Imóvel (Título e Info) */
.imovel-header { margin-top: 2rem; margin-bottom: 1.5rem; }
.imovel-title { font-size: 2rem; font-weight: 800; color: var(--brand-green); margin-bottom: 0.5rem; }
.imovel-meta { display: flex; align-items: center; gap: 1.5rem; color: var(--text-main); font-size: 1rem; font-weight: 500; }
.imovel-meta i { color: var(--brand-gold); }
.imovel-meta-link { color: var(--text-muted); text-decoration: underline; }

/* Galeria de Fotos Estilo Airbnb */
.gallery-container { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; border-radius: 1.5rem; overflow: hidden; height: 50vh; min-height: 400px; margin-bottom: 3rem; }
.gallery-main { width: 100%; height: 100%; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; cursor: pointer; transition: filter 0.3s; }
.gallery-main img:hover { filter: brightness(0.9); }

.gallery-grid { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 0.5rem; }
.gallery-grid img { width: 100%; height: 100%; object-fit: cover; cursor: pointer; transition: filter 0.3s; }
.gallery-grid img:hover { filter: brightness(0.9); }

/* Layout Dividido (Descrição Esquerda / Reserva Direita) */
.imovel-content { display: flex; gap: 5rem; margin-bottom: 4rem; }
.imovel-details { flex: 1; }
.imovel-sidebar { width: 380px; position: sticky; top: 2rem; height: fit-content; z-index: 10; }

/* Descrição e Comodidades */
.imovel-section { padding-bottom: 2rem; margin-bottom: 2rem; border-bottom: 1px solid var(--border-color); }
.imovel-section h3 { font-size: 1.5rem; color: var(--brand-green); margin-bottom: 1rem; }
.imovel-desc { color: var(--text-muted); line-height: 1.7; font-size: 1.05rem; }
.amenities-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.amenity-item { display: flex; align-items: center; gap: 1rem; font-size: 1.05rem; color: var(--text-main); }
.amenity-item i { font-size: 1.2rem; color: var(--brand-gold); width: 24px; text-align: center; }

/* Caixa de Reserva (Formulário) */
.booking-card { background: var(--white); border: 1px solid var(--border-color); border-radius: 1.5rem; padding: 1.5rem; box-shadow: var(--shadow-lg); }
.booking-price { font-size: 1.5rem; font-weight: 800; color: var(--text-main); margin-bottom: 1.5rem; }
.booking-price span { font-size: 1rem; font-weight: 400; color: var(--text-muted); }
.booking-form { border: 1px solid var(--border-color); border-radius: 0.75rem; overflow: hidden; margin-bottom: 1rem; }
.booking-dates { display: flex; border-bottom: 1px solid var(--border-color); }
.booking-input-group { flex: 1; padding: 0.75rem; display: flex; flex-direction: column; }
.booking-dates .booking-input-group:first-child { border-right: 1px solid var(--border-color); }
.booking-input-group label { font-size: 0.65rem; font-weight: 800; text-transform: uppercase; color: var(--brand-green); margin-bottom: 0.25rem; }
    .booking-input-group input, .booking-input-group select { border: none; outline: none; font-family: inherit; font-size: 0.9rem; color: var(--text-main); background: transparent; cursor: pointer; }
.btn-reserve { width: 100%; background: var(--brand-green); color: var(--white); padding: 1rem; border-radius: 0.75rem; font-size: 1rem; font-weight: 700; border: none; cursor: pointer; transition: background 0.3s; }
.btn-reserve:hover { background: var(--brand-green-dark); }


/* =========================================
   LIGHTBOX / CARROSSEL TELA CHEIA
========================================= */
.lightbox-overlay { display: none; position: fixed; z-index: 99999; top: 0; left: 0; width: 100vw; height: 100vh; background-color: rgba(0, 0, 0, 0.9); align-items: center; justify-content: center; }
.lightbox-overlay.active { display: flex; }
.lightbox-img { max-width: 90%; max-height: 90%; border-radius: 0.5rem; box-shadow: 0 0 20px rgba(0,0,0,0.5); user-select: none; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
.lightbox-close { position: absolute; top: 20px; right: 30px; color: #fff; font-size: 3rem; cursor: pointer; transition: color 0.2s; z-index: 100000; }
.lightbox-close:hover { color: var(--brand-gold); }
.lightbox-btn { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255, 255, 255, 0.2); color: #fff; border: none; width: 50px; height: 50px; border-radius: 50%; font-size: 1.5rem; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.3s; z-index: 100000; }
.lightbox-btn:hover { background: rgba(255, 255, 255, 0.5); color: var(--brand-green-dark); }
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }
.lightbox-counter { position: absolute; bottom: 20px; color: #fff; font-size: 1.2rem; font-weight: bold; }

/* Responsivo */
@media (max-width: 991px) {
    .imovel-content { flex-direction: column; gap: 2rem; }
    .imovel-sidebar { width: 100%; position: relative; top: 0; }
    .gallery-container { grid-template-columns: 1fr; height: 300px; min-height: auto; }
    .gallery-grid { display: none; } /* Esconde fotos pequenas no celular */
}