/* ── Hero ── */
.hero-swiper {
  width: 100%;
  height: 520px;
}
@media (max-width: 767px) {
  .hero-swiper {
    height: 420px;
  }
}
.hero-slide {
  position: relative;
  overflow: hidden;
}
.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.62) 0%,
    rgba(0, 0, 0, 0.25) 60%,
    transparent 100%
  );
}
.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 24px 20px 0;
}
@media (min-width: 768px) {
  .hero-content {
    padding: 0 60px;
  }
}
.hero-tag {
  display: inline-block;
  background: var(--green-mid);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 3px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
}
.hero-title {
  font-size: clamp(24px, 5vw, 42px);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
}
.hero-title span {
  color: #86efac;
}
.hero-sub {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.82);
  margin-top: 10px;
  max-width: 480px;
}

/* ── Search Box ── */
.search-box {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.13);
  padding: 20px;
}
.tab-btn {
  padding: 8px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  background: transparent;
  color: #6b7280;
}
.tab-btn.active {
  background: var(--green);
  color: #fff;
}
.search-box select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
}
.quick-tag {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  background: #f3f4f6;
  color: #374151;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.quick-tag:hover {
  background: var(--green-light);
  color: var(--green);
}

/* ── Category icons ── */
.cat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: transform 0.2s;
}
.cat-item:hover {
  transform: translateY(-3px);
}
.cat-icon {
  width: 60px;
  height: 60px;
  background: var(--green-light);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--green);
  transition: background 0.2s;
}
.cat-item:hover .cat-icon {
  background: var(--green);
  color: #fff;
}
.cat-label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  text-align: center;
}
.cat-count {
  font-size: 11px;
  color: #9ca3af;
}

/* ── Section header ── */
.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 6px;
}
.section-title {
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 800;
  color: #111827;
}

/* ── Project cards ── */
.proj-card {
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
  transition:
    transform 0.25s,
    box-shadow 0.25s;
}
.proj-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.13);
}
.proj-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}
@media (min-width: 768px) {
  .proj-card img {
    height: 200px;
  }
}
.badge-noi-bat {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--green);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
}

/* ── Listing rows ── */
.listing-row {
  display: flex;
  gap: 12px;
  background: #fff;
  border-radius: 10px;
  padding: 12px;
  border: 1px solid #f0f0f0;
  transition: box-shadow 0.2s;
  cursor: pointer;
}
.listing-row:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.09);
}
.listing-row img {
  width: 90px;
  height: 72px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}
@media (min-width: 640px) {
  .listing-row img {
    width: 110px;
    height: 84px;
  }
}
.listing-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 3px;
  display: inline-block;
}
.badge-moi {
  background: #dcfce7;
  color: #166534;
}
.badge-tot {
  background: #fef9c3;
  color: #854d0e;
}
.badge-noibat {
  background: #fee2e2;
  color: #991b1b;
}

/* ── Why invest ── */
.why-card {
  background: #fff;
  border-radius: 12px;
  padding: 16px 12px;
  border: 1px solid var(--green-light);
  text-align: center;
}
@media (min-width: 640px) {
  .why-card {
    padding: 20px 16px;
  }
}
.why-icon {
  width: 44px;
  height: 44px;
  background: var(--green-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: var(--green);
  margin: 0 auto 12px;
}
@media (min-width: 640px) {
  .why-icon {
    width: 52px;
    height: 52px;
    font-size: 20px;
  }
}

/* ── News cards ── */
.news-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  transition: transform 0.2s;
}
.news-card:hover {
  transform: translateY(-3px);
}
.news-card img {
  width: 100%;
  height: 110px;
  object-fit: cover;
}
@media (min-width: 640px) {
  .news-card img {
    height: 160px;
  }
}

/* ── CTA Banner ── */
.cta-banner {
  background: linear-gradient(135deg, var(--green) 0%, var(--green-dark) 100%);
}

/* ── Swiper custom ── */
.swiper-pagination-bullet {
  background: #fff;
  opacity: 0.5;
}
.swiper-pagination-bullet-active {
  background: #86efac;
  opacity: 1;
}
.proj-swiper .swiper-pagination-bullet {
  background: #9ca3af;
}
.proj-swiper .swiper-pagination-bullet-active {
  background: var(--green);
}
.swiper-button-next,
.swiper-button-prev {
  color: var(--green) !important;
  background: #fff;
  width: 36px !important;
  height: 36px !important;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
.swiper-button-next::after,
.swiper-button-prev::after {
  font-size: 13px !important;
  font-weight: 900;
}

/* ── Map placeholder ── */
.map-bg {
  background: url("https://images.unsplash.com/photo-1569336415962-a4bd9f69cd83?w=900&q=80")
    center/cover;
  border-radius: 12px;
  position: relative;
}
.map-overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}
.map-pin {
  position: absolute;
  width: 28px;
  height: 28px;
  background: var(--green);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 12px;
  border: 2px solid #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  transition: transform 0.2s;
}
.map-pin:hover {
  transform: scale(1.2);
}
.map-pin-label {
  position: absolute;
  top: -22px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--green);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  white-space: nowrap;
}

@media (max-width: 639px) {
  .hero-content {
    padding: 20px 16px 0;
  }
}
/* ============================================================
   LISTING ROW  —  Mobile-first responsive
   Thêm vào style.css hoặc enqueue riêng trong functions.php
   ============================================================ */

/* ── Container ── */
.listing-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #fff;
  border: 1px solid #f0f0f0;
  border-radius: 12px;
  padding: 10px;
  cursor: pointer;
  transition:
    box-shadow 0.2s,
    transform 0.2s;
  text-decoration: none;
  width: 100%;
}

.listing-row:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.09);
  transform: translateY(-1px);
}

/* ── Thumbnail wrapper ── */
.listing-thumb {
  width: 88px;
  height: 72px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.listing-thumb__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s;
}

.listing-row:hover .listing-thumb__img {
  transform: scale(1.05);
}

/* Badge bên trong ảnh */
.listing-badge {
  position: absolute;
  top: 5px;
  left: 5px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.4px;
  padding: 2px 7px;
  border-radius: 4px;
  line-height: 1.5;
  pointer-events: none;
}

.badge-moi {
  background: #166534;
  color: #dcfce7;
}
.badge-tot {
  background: #854d0e;
  color: #fef9c3;
}
.badge-noibat {
  background: #991b1b;
  color: #fee2e2;
}

/* ── Body ── */
.listing-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* Title */
.listing-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #111827;
  line-height: 1.35;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.18s;
}

.listing-row:hover .listing-title {
  color: var(--green);
}

/* Address */
.listing-addr {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  font-size: 11px;
  color: #9ca3af;
  line-height: 1.4;
}

.listing-addr__icon {
  color: var(--green);
  font-size: 10px;
  flex-shrink: 0;
  margin-top: 1px;
}

.listing-addr__text {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Price row */
.listing-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.listing-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--green);
  line-height: 1;
}

/* Favourite button */
.listing-fav {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: #d1d5db;
  font-size: 15px;
  flex-shrink: 0;
  border-radius: 50%;
  line-height: 1;
  transition: color 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.listing-fav:hover,
.listing-fav.is-liked {
  color: #ef4444;
}

.listing-fav.is-liked i {
  font-family: "Font Awesome 6 Free";
  font-weight: 900; /* solid */
}

/* Stats row */
.listing-stats {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.listing-stat {
  font-size: 11.5px;
  color: #6b7280;
  display: flex;
  align-items: center;
  gap: 3px;
  white-space: nowrap;
}

.listing-stat__icon {
  color: var(--green);
  font-size: 11px;
}

/* ── Tablet (≥ 640px) ── */
@media (min-width: 640px) {
  .listing-thumb {
    width: 110px;
    height: 86px;
  }

  .listing-badge {
    font-size: 10px;
    padding: 3px 9px;
  }

  .listing-title {
    font-size: 14.5px;
  }

  .listing-addr {
    font-size: 12px;
  }

  .listing-price {
    font-size: 16px;
  }

  .listing-stat {
    font-size: 12px;
    gap: 4px;
  }

  .listing-stats {
    gap: 12px;
  }

  .listing-row {
    gap: 14px;
    padding: 12px;
  }
}

/* ── Desktop (≥ 1024px) ── */
@media (min-width: 1024px) {
  .listing-thumb {
    width: 120px;
    height: 92px;
  }

  .listing-row {
    padding: 12px 14px;
  }
}

/* ── Fade-up animation ── */
.fade-up {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 0.42s ease,
    transform 0.42s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   NEW STYLES FOR REDESIGNED HOMEPAGE
   ============================================================ */

/* ── Search Tab Buttons in Hero ── */
.search-tab-btn {
  font-size: 15px;
  font-weight: 700;
  color: #9ca3af;
  border-bottom: 2px solid transparent;
  padding-bottom: 8px;
  cursor: pointer;
  background: transparent;
  border: none;
}
.search-tab-btn.active {
  color: var(--green);
  border-bottom-color: var(--green);
}
.select-container .select2-container {
  margin-bottom: 0px !important;
}

/* ── New Category Cards (home-cat-card) ── */
.home-cat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid #eef2ee;
  border-radius: 12px;
  padding: 16px 12px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(26, 107, 47, 0.04);
  transition: all 0.25s ease;
  text-decoration: none;
  cursor: pointer;
}
.home-cat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(26, 107, 47, 0.1);
  border-color: var(--green);
}
.home-cat-icon {
  width: 52px;
  height: 52px;
  background: #f0f7f2;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: var(--green);
  margin-bottom: 10px;
  transition: all 0.25s ease;
}
.home-cat-card:hover .home-cat-icon {
  background: var(--green);
  color: #fff;
}
.home-cat-label {
  font-size: 12px;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.3;
}

/* ── New Project Card (home-project-card) ── */
.home-project-card {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  cursor: pointer;
  aspect-ratio: 3 / 4;
  background: #f3f4f6;
  transition: all 0.3s ease;
}
.home-project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}
.home-project-img-wrap {
  position: relative;
  width: 100%;
  height: 100%;
}
.home-project-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.home-project-card:hover .home-project-img-wrap img {
  transform: scale(1.05);
}
.home-project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 23, 42, 0.95) 0%, rgba(15, 23, 42, 0.4) 50%, transparent 100%);
  z-index: 1;
}
.home-project-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}
.home-project-fav, .bds-card-fav {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.home-project-fav:hover, .bds-card-fav:hover {
  background: #fff;
  color: #ef4444;
  transform: scale(1.05);
}
.home-project-fav.is-liked, .bds-card-fav.is-liked {
  color: #ef4444;
}
.home-project-fav.is-liked i, .bds-card-fav.is-liked i {
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}
.home-project-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  color: #fff;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.home-project-title {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  line-height: 1.35;
  margin: 0;
}
.home-project-location {
  font-size: 11px;
  color: #d1d5db;
  display: flex;
  align-items: center;
  gap: 4px;
}
.home-project-location i {
  color: #4ade80;
}
.home-project-price {
  font-size: 16px;
  font-weight: 800;
  color: #4ade80;
  margin-top: 2px;
}
.home-project-specs {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 8px;
  margin-top: 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
}
.home-project-spec-item {
  font-size: 10px;
  color: #9ca3af;
  display: flex;
  align-items: center;
  gap: 3px;
}
.home-project-spec-item i {
  font-size: 9px;
  color: #4ade80;
}

/* ── Bất Động Sản Lẻ Tab Filters ── */
.bds-filter-tab {
  background: #fff;
  border: 1px solid #eef2ee;
  border-radius: 20px;
  padding: 8px 18px;
  font-size: 12px;
  font-weight: 700;
  color: #4b5563;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 6px rgba(26, 107, 47, 0.02);
  transition: all 0.2s ease;
  cursor: pointer;
}
.bds-filter-tab:hover {
  background: #f0f7f2;
  color: var(--green);
  border-color: var(--green);
}
.bds-filter-tab.active {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
  box-shadow: 0 4px 12px rgba(26, 107, 47, 0.2);
}

/* ── New BĐS Lẻ Vertical Card (bds-card) ── */
.bds-card {
  background: #fff;
  border: 1px solid #eef2ee;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}
.bds-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
  border-color: var(--green);
}
.bds-card-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #f3f4f6;
}
.bds-card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.bds-card:hover .bds-card-img-wrap img {
  transform: scale(1.04);
}
.bds-card-info {
  padding: 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.bds-card-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.4;
  margin: 0 0 6px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 38px;
  transition: color 0.15s ease;
}
.bds-card:hover .bds-card-title {
  color: var(--green);
}
.bds-card-location {
  font-size: 11px;
  color: #9ca3af;
  display: flex;
  align-items: flex-start;
  gap: 4px;
  margin-bottom: 8px;
}
.bds-card-location i {
  color: var(--green);
  font-size: 10px;
  margin-top: 2px;
}
.bds-card-location span {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.bds-card-details {
  font-size: 11px;
  color: #6b7280;
  font-weight: 500;
  border-top: 1px solid #f3f4f6;
  padding-top: 8px;
  margin-top: auto;
  margin-bottom: 6px;
}
.bds-card-price {
  font-size: 15px;
  font-weight: 800;
  color: var(--green);
}

/* ── Subscriptions Form input ── */
#subscribe-email-input {
  border: 1px solid #e5e7eb;
}
#subscribe-email-input:focus {
  border-color: var(--green);
}

/* Fade-in animation for AJAX load */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-fade-in {
  animation: fadeIn 0.4s ease forwards;
}

