/* Ilha Lar Floripa - Estilos Gerais */
:root {
  --primary: #1a6b62;        /* Verde Ilha (Logo IlhaLar) */
  --primary-hover: #13524b;
  --primary-light: #e6f4f1;
  --secondary: #059669;      /* Verde Esmeralda / Natureza */
  --secondary-light: #d1fae5;
  --accent: #eb693c;         /* Laranja Sol (Logo IlhaLar) */
  --dark: #0f172a;           /* Grafite Escuro */
  --gray-100: #f8fafc;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --gray-600: #475569;
  --gray-800: #1e293b;
  --white: #ffffff;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --radius: 12px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
  background-color: #f1f5f9;
  color: var(--gray-800);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header & Navbar */
header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: var(--shadow-sm);
}

.navbar {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--dark);
}

.logo-img {
  height: 56px;
  max-width: 240px;
  object-fit: contain;
}

.logo-fallback {
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-icon {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 20px;
  box-shadow: 0 2px 8px rgba(26, 107, 98, 0.35);
}

.logo-text-wrap h1 {
  font-size: 20px;
  font-weight: 800;
  color: var(--dark);
  line-height: 1.1;
  letter-spacing: -0.5px;
}

.logo-text-wrap span {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Botões */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--primary);
  color: white;
}
.btn-primary:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-success {
  background: var(--secondary);
  color: white;
}
.btn-success:hover {
  background: #047857;
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--gray-600);
  border: 1px solid var(--gray-300);
}
.btn-outline:hover {
  background: var(--gray-100);
  color: var(--dark);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

/* Banner Hero */
.hero {
  background: linear-gradient(rgba(15, 23, 42, 0.75), rgba(15, 23, 42, 0.75)), 
              url('https://images.unsplash.com/photo-1507525428034-b723cf961d3e?w=1600&auto=format&fit=crop&q=80') center/cover;
  color: white;
  padding: 48px 20px 60px;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}

.hero p {
  font-size: 16px;
  color: #cbd5e1;
  margin-bottom: 24px;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.hero-stat-badge {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
}

/* Barra de Filtros / Busca */
.search-container {
  max-width: 1100px;
  margin: -30px auto 30px;
  padding: 0 20px;
  position: relative;
  z-index: 10;
}

.search-box {
  background: white;
  padding: 20px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) 120px;
  gap: 14px;
  align-items: end;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 12px;
  font-weight: 700;
  color: var(--gray-600);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-control {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  font-size: 14px;
  color: var(--dark);
  background: white;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(26, 107, 98, 0.15);
}

/* Área Principal / Vitrine */
.main-content {
  max-width: 1200px;
  margin: 0 auto 60px;
  padding: 0 20px;
  flex: 1;
  width: 100%;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.section-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--dark);
}

.results-count {
  font-size: 14px;
  color: var(--gray-600);
}

/* Grid de Imóveis */
.properties-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

/* Card do Imóvel */
.property-card {
  background: white;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--gray-200);
}

.property-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-image-wrap {
  position: relative;
  width: 100%;
  height: 210px;
  background: #e2e8f0;
  overflow: hidden;
}

.card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.property-card:hover .card-image {
  transform: scale(1.04);
}

.card-badge-type {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: white;
  letter-spacing: 0.5px;
}

.badge-temporada {
  background: var(--accent);
}

.badge-anual {
  background: var(--primary);
}

.card-badge-direct {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(4px);
  color: white;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 600;
}

.card-price-tag {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(4px);
  color: white;
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: 800;
  font-size: 16px;
}

.card-price-tag span {
  font-size: 12px;
  font-weight: 400;
  opacity: 0.85;
}

.card-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 6px;
}

.card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 44px;
}

.card-features {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 13px;
  color: var(--gray-600);
  padding: 10px 0;
  border-top: 1px solid var(--gray-100);
  border-bottom: 1px solid var(--gray-100);
  margin-bottom: 12px;
}

.card-feature-item {
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-amenities {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.amenity-pill {
  background: var(--gray-100);
  color: var(--gray-600);
  font-size: 11px;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 4px;
}

.card-footer {
  margin-top: auto;
  display: flex;
  gap: 10px;
}

.btn-whatsapp {
  background: #25D366;
  color: white;
  flex: 1;
  text-decoration: none;
  padding: 10px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.2s;
}

.btn-whatsapp:hover {
  background: #1eb956;
}

/* Modais e Detalhes */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: white;
  border-radius: var(--radius);
  max-width: 800px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  background: white;
  z-index: 10;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--gray-600);
}

.modal-body {
  padding: 20px;
}

/* Estilos de Formulário de Postagem */
.post-form-container {
  max-width: 850px;
  margin: 30px auto 60px;
  background: white;
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-200);
}

.form-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--dark);
  border-bottom: 2px solid var(--primary-light);
  padding-bottom: 8px;
  margin-top: 24px;
  margin-bottom: 16px;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-grid-3 {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}

/* Área de Upload de Fotos */
.photo-upload-zone {
  border: 2px dashed var(--primary);
  background: var(--primary-light);
  border-radius: 12px;
  padding: 28px;
  text-align: center;
  cursor: pointer;
  transition: background 0.2s;
  margin-bottom: 16px;
}

.photo-upload-zone:hover {
  background: #cceae3;
}

.photo-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.preview-item {
  position: relative;
  height: 112px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--gray-300);
}

.preview-item.is-cover {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(235, 105, 60, 0.2);
}

.preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.preview-cover-badge {
  position: absolute;
  top: 5px;
  left: 5px;
  background: var(--accent);
  color: white;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 6px;
  letter-spacing: 0.3px;
}

.preview-set-cover {
  position: absolute;
  bottom: 5px;
  left: 5px;
  right: 5px;
  background: rgba(15, 23, 42, 0.82);
  color: white;
  border: none;
  padding: 4px 6px;
  border-radius: 5px;
  font-size: 10.5px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
}

.preview-set-cover:hover {
  background: var(--primary);
}

.preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(220, 38, 38, 0.85);
  color: white;
  border: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Checkboxes & Amenities */
.amenities-selector {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  cursor: pointer;
  color: var(--gray-800);
  padding: 6px 10px;
  background: var(--gray-100);
  border-radius: 6px;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.checkbox-label:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

/* Banner de Serviço Opcional (Anúncio + Visitas + Manutenções) */
.service-banner {
  margin-top: 48px;
  background: linear-gradient(135deg, #134e47 0%, #1a6b62 65%, #0f172a 100%);
  border-radius: var(--radius);
  padding: 32px;
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 28px;
  flex-wrap: wrap;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.service-banner-content {
  flex: 1 1 460px;
}

.service-banner-badge {
  display: inline-block;
  background: var(--accent);
  color: white;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.service-banner h3 {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 10px;
}

.service-banner p {
  font-size: 14px;
  color: #e2e8f0;
  line-height: 1.6;
  margin-bottom: 16px;
}

.service-banner-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.service-pill {
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
}

.service-banner-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 250px;
}

/* Botões Redes Sociais (Instagram & Facebook) */
.social-links-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
  color: white;
  text-decoration: none;
  flex-shrink: 0;
  transition: transform 0.15s, opacity 0.2s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.22);
}

.social-btn-sm {
  width: 34px;
  height: 34px;
}

.social-btn:hover {
  transform: translateY(-1px);
  opacity: 0.92;
}

.social-instagram {
  background: linear-gradient(135deg, #f58529 0%, #dd2a7b 52%, #8134af 100%);
}

.social-facebook {
  background: #1877f2;
}

/* Footer */
footer {
  background: var(--dark);
  color: white;
  padding: 32px 20px;
  margin-top: auto;
  border-top: 1px solid #334155;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-text {
  font-size: 13px;
  color: #94a3b8;
}

/* Responsivo */
@media (max-width: 768px) {
  .search-box {
    grid-template-columns: 1fr;
  }
  .form-grid-2, .form-grid-3 {
    grid-template-columns: 1fr;
  }
  .properties-grid {
    grid-template-columns: 1fr;
  }
  .hero h2 {
    font-size: 24px;
  }
}
