/* ==========================================================================
   HungPhatBDS New — layout overrides (colors: palette.css)
   ========================================================================== */

:root {
  --bk-topbar-h: 42px;
  --bk-header-h: 76px;
  --header-offset: calc(var(--bk-topbar-h) + var(--bk-header-h));
  --container-max: 1560px;
}

body {
  background: var(--bk-cream);
  color: var(--bk-text);
  font-family: var(--font-body);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--bk-dark-mid);
}

/* ── Topbar / Header ─────────────────────────────────────────────────── */
.bk-topbar--pro,
.bk-topbar--qvp {
  background: #0d2137;
  color: #fff;
  border-bottom: 2px solid rgba(62, 158, 106, 0.4);
  font-size: 0.8125rem;
}

/* phone item — brightest element */
.bk-topbar--pro .bk-topbar__item--phone {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.bk-topbar--pro .bk-topbar__item--phone:hover { color: #6ee6a7; }

/* address — slightly muted but still legible */
.bk-topbar--pro .bk-topbar__item--addr { color: rgba(255,255,255,.85); }
.bk-topbar--pro .bk-topbar__item--addr:hover { color: #fff; }

.bk-topbar--pro .bk-topbar__icon { opacity: 1; }
.bk-topbar--pro .bk-topbar__sep  { background: rgba(255,255,255,.35); }

/* CTA buttons */
.bk-header-cta {
  display: inline-flex; align-items: center;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.8rem; font-weight: 600;
  text-decoration: none;
  transition: all .15s ease;
}
.bk-header-cta--outline {
  color: #fff;
  border: 1.5px solid rgba(255,255,255,.65);
  background: transparent;
}
.bk-header-cta--outline:hover {
  background: rgba(255,255,255,.12);
  border-color: #fff;
  color: #fff;
}
.bk-header-cta--fill {
  color: #fff;
  border: 1.5px solid var(--bk-accent, #3e9e6a);
  background: var(--bk-accent, #3e9e6a);
}
.bk-header-cta--fill:hover {
  background: #328a59;
  border-color: #328a59;
  color: #fff;
}

.bk-header--pro,
.bk-header--qvp {
  background: #fff;
  border-bottom: 1px solid var(--bk-border);
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
}

.bk-brand--pro .bk-brand__name,
.bk-brand--qvp .bk-brand__name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--bk-dark-mid);
}

.bk-brand--pro .bk-brand__mark,
.bk-brand--qvp .bk-brand__mark {
  background: var(--bk-gradient);
  color: #fff;
}

.bk-nav--pro .bk-nav__link,
.bk-nav--qvp .bk-nav__link {
  font-family: var(--font-nav);
  font-size: 0.9rem;
  padding: 8px 14px;
  color: var(--bk-text);
  border-radius: 6px;
  transition: color 0.2s ease, background 0.2s ease;
}

.bk-nav--pro .bk-nav__link:hover,
.bk-nav--pro .bk-nav__item:hover > .bk-nav__link,
.bk-nav--qvp .bk-nav__link:hover,
.bk-nav--qvp .bk-nav__item:hover > .bk-nav__link {
  color: var(--bk-accent);
  background: var(--bk-accent-light);
}

.bk-nav--pro .bk-nav__submenu,
.bk-nav--qvp .bk-nav__submenu {
  border: 1px solid var(--bk-border);
  border-radius: 8px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
}

.bk-nav--pro .bk-nav__submenu a:hover,
.bk-nav--qvp .bk-nav__submenu a:hover {
  background: var(--bk-accent-light);
  color: var(--bk-accent);
}

.bk-header__phone--pro,
.bk-header__phone--qvp {
  font-weight: 700;
  color: var(--bk-accent);
  font-size: 0.9375rem;
}

/* ── Hero professional ───────────────────────────────────────────────── */
.bk-hero--pro {
  position: relative;
  padding: 48px 0 56px;
  overflow: hidden;
  color: #fff;
}

.bk-hero--pro .bk-hero__bg {
  position: absolute;
  inset: 0;
  background: var(--bk-gradient-hero, var(--bk-gradient));
  z-index: 0;
}

.bk-hero--pro .bk-hero__bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 255, 255, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 85% 80%, rgba(0, 0, 0, 0.15) 0%, transparent 50%);
}

.bk-hero--pro .bk-hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.bk-hero--pro .bk-container {
  position: relative;
  z-index: 1;
}

.bk-hero--pro .bk-hero__grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.95fr) minmax(320px, 1.05fr);
  gap: 40px;
  align-items: center;
}

.bk-hero__brand-mark {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}

.bk-hero__brand-mark .bk-brand__mark {
  width: 56px;
  height: 56px;
  font-size: 1.25rem;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(8px);
}

.bk-hero__company-name {
  margin: 0 0 6px;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
}

.bk-hero__slogan {
  margin: 0;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.5;
  max-width: 42ch;
}

.bk-hero__address {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 24px;
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.5;
}

.bk-hero__phones {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.bk-hero__phone-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  transition: background 0.25s ease, transform 0.25s ease;
}

.bk-hero__phone-card:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  color: #fff;
}

.bk-hero__phone-label {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.7);
}

.bk-hero__phone-num {
  font-size: 1.0625rem;
  font-weight: 700;
  color: #fff;
}

.bk-hero__search-panel {
  background: #fff;
  border-radius: 14px;
  padding: 24px 26px 26px;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
}

.bk-hero__filter-label {
  margin: 0 0 16px;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--bk-accent);
}

.bk-filter__grid--hero-compact {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.bk-filter__grid--hero-compact .bk-field--submit {
  grid-column: 1 / -1;
}

@media (max-width: 1100px) {
  .bk-hero--pro .bk-hero__grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .bk-filter__grid--hero-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .bk-hero__phones {
    grid-template-columns: 1fr;
  }

  .bk-filter__grid--hero-compact {
    grid-template-columns: 1fr;
  }
}

/* ── Sections ────────────────────────────────────────────────────────── */
.bk-section--light {
  background: #fff;
}

.bk-section--white {
  background: var(--bk-cream);
}

.bk-section__head--center {
  text-align: center;
  justify-content: center;
  flex-direction: column;
  align-items: center;
}

.bk-section__title--upper {
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: clamp(1.5rem, 2.8vw, 2.125rem);
  font-weight: 800;
  color: var(--bk-dark-mid);
  line-height: 1.2;
}

.bk-section__title--upper::after {
  content: '';
  display: block;
  width: 56px;
  height: 4px;
  margin: 12px auto 0;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--hp-olive) 0%, var(--hp-blue) 100%);
}

.bk-eyebrow--muted {
  color: var(--hp-olive);
  font-weight: 700;
  font-size: 0.8125rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  justify-content: center;
  text-align: center;
}

/* ── Homepage grid 4×3 ──────────────────────────────────────────────── */
.bk-property-grid--home {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

@media (max-width: 1400px) {
  .bk-property-grid--home {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 1024px) {
  .bk-property-grid--home {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 639px) {
  .bk-property-grid--home {
    grid-template-columns: 1fr;
  }
}

/* ── Property cards ─────────────────────────────────────────────────── */
.bk-property-card {
  background: #fff;
  border: 1px solid var(--bk-border);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.bk-property-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
}

.bk-card__media-wrap {
  position: relative;
}

.bk-card__shade {
  opacity: 1;
  background: linear-gradient(to top, rgba(12, 18, 34, 0.84) 0%, rgba(12, 18, 34, 0.44) 32%, transparent 58%);
}

.bk-card__tags,
.bk-card__badges {
  pointer-events: auto;
  z-index: 5;
}

.bk-card__tag,
.bk-card__badges .bk-badge {
  pointer-events: auto;
  position: relative;
  z-index: 6;
}

.bk-badge--hot {
  background: #ef4444 !important;
  color: #fff !important;
}

.bk-card__detail-btn:hover {
  border-color: var(--bk-accent);
  color: var(--bk-accent);
  background: var(--bk-accent-light);
}

.bk-card__price-overlay,
.bds-card__price {
  font-size: 1.28rem;
}

/* ── PLP sticky sidebar ─────────────────────────────────────────────── */
.bk-plp-head--qvp .bk-plp-head__title {
  color: var(--bk-dark-mid);
}

.bk-plp-sidebar {
  position: sticky;
  top: calc(var(--header-offset) + 16px);
  align-self: start;
  max-height: calc(100vh - var(--header-offset) - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.bk-filter--sidebar {
  background: #fff;
  border: 1px solid var(--bk-border);
  border-radius: 10px;
  padding: 20px;
}

.bk-filter button,
.bk-filter select,
.bk-filter input {
  font-family: var(--font-ui);
}

/* ── CTA banner ─────────────────────────────────────────────────────── */
.bk-cta-banner--pro,
.bk-cta-banner--qvp {
  background: var(--bk-gradient);
  border-radius: 14px;
  padding: 48px 32px;
  text-align: center;
  box-shadow: 0 12px 40px rgba(5, 150, 105, 0.25);
}

.bk-eyebrow--light {
  color: rgba(255, 255, 255, 0.75) !important;
}

/* ── Footer ─────────────────────────────────────────────────────────── */
.bk-footer--pro .bk-footer__main,
.bk-footer--qvp .bk-footer__main {
  background: var(--bk-dark);
}

.bk-footer .bk-footer__main {
  background: var(--bk-dark);
}

.bk-footer--pro .bk-footer__top {
  /* Footer markup hiện tại = 4 cột (brand / projects+loc / price / contact) */
  grid-template-columns: minmax(240px, 1.4fr) repeat(3, minmax(0, 1fr));
  gap: 28px 20px;
}

.bk-footer .bk-footer__top {
  grid-template-columns: minmax(240px, 1.4fr) repeat(3, minmax(0, 1fr));
  gap: 28px 20px;
}

.bk-footer--pro .bk-footer__hotline-number {
  color: var(--hp-olive);
}

.bk-footer .bk-footer__hotline-number {
  color: var(--hp-olive);
}

.bk-footer--pro .bk-footer__col-title {
  position: relative;
  padding-bottom: 8px;
}

.bk-footer--pro .bk-footer__col-title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--hp-olive);
  border-radius: 1px;
}

.bk-footer .bk-footer__col-title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--hp-olive);
  border-radius: 1px;
}

/* Compatibility: nếu page đang render footer parent (.bds-footer) */
.bds-footer {
  background: var(--bk-dark);
  color: rgba(255, 255, 255, 0.75);
}

.bds-footer__main {
  padding: 48px 0 28px;
  background: var(--bk-dark);
}

.bds-footer__top {
  display: grid;
  grid-template-columns: minmax(240px, 1.4fr) repeat(2, minmax(0, 1fr));
  gap: 28px 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.bds-footer__title {
  position: relative;
  margin-bottom: 14px;
  padding-bottom: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #fff;
}

.bds-footer__title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 28px;
  height: 2px;
  background: var(--hp-olive);
  border-radius: 1px;
}

.bds-footer__links a,
.bds-footer__chip {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.9rem;
}

.bds-footer__links a:hover,
.bds-footer__chip:hover {
  color: var(--hp-olive);
}

.bds-footer__bar {
  color: rgba(255, 255, 255, 0.55);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 1200px) {
  .bds-footer__top {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .bds-footer__top {
    grid-template-columns: 1fr;
  }
}

/* Fallback khi còn markup bds-card từ cache cũ */
.bds-card--property {
  background: #fff;
  border: 1px solid var(--bk-border);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
}

.bds-card--property:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
}

.bds-card--property .bds-card__media {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: #e8eef6;
}

.bds-card--property .bds-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.bds-card--property:hover .bds-card__media img {
  transform: scale(1.05);
}

.bds-card--property .bds-card__badges {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  z-index: 6;
  display: flex;
  justify-content: space-between;
  gap: 6px;
  pointer-events: none;
}

.bds-card--property .bds-badge {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.18);
}

.bds-card--property .bds-badge.is-hot { background: linear-gradient(135deg, #dc2626, #f97316); }
.bds-card--property .bds-badge.is-new { background: #059669; }
.bds-card--property .bds-badge.is-status { background: var(--bk-accent); }

/* Tag clickable góc phải (được render bằng .bk-card__tags trong child) */
.bds-card--property .bk-card__tags {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 7;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  max-width: 62%;
}

.bds-card--property .bk-card__tag {
  background: rgba(15, 23, 42, 0.72);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(6px);
}

.bds-card--property .bk-card__tag:hover {
  background: rgba(15, 23, 42, 0.86);
  color: #fff;
  transform: translateX(-2px);
}

.bds-card--property .bds-card__price {
  position: absolute;
  left: 14px;
  bottom: 12px;
  z-index: 5;
  padding: 0;
  background: none;
  font-size: 1.28rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
}

/* Lớp phủ đen chân ảnh để giá nổi bật (không phụ thuộc hover) */
.bds-card--property .bds-card__media::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(to top, rgba(12, 18, 34, 0.84) 0%, rgba(12, 18, 34, 0.44) 32%, transparent 58%);
}

.bk-footer__price-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.bk-footer__price-links li {
  margin: 0;
  padding: 0;
}

.bk-footer__price-links a {
  display: block;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.45;
  transition: color 0.2s ease;
}

.bk-footer__price-links a:hover {
  color: var(--hp-olive);
}

.bk-footer__cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

@media (max-width: 1200px) {
  .bk-footer--pro .bk-footer__top {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .bk-footer--pro .bk-footer__brand-col {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .bk-footer--pro .bk-footer__top {
    grid-template-columns: 1fr;
  }
}

/* ── Forms / fields ─────────────────────────────────────────────────── */
.bk-field__select:focus,
.bk-field__input:focus {
  border-color: var(--bk-accent);
  outline: none;
  box-shadow: 0 0 0 3px rgba(40, 85, 152, 0.15);
}

/* ── PLP mobile ─────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .bk-plp-filter-mobile {
    display: block;
    width: 100%;
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid var(--bk-border);
    border-radius: 8px;
    background: #fff;
    font-weight: 600;
    color: var(--bk-accent);
  }

  .bk-plp-sidebar .bk-filter--sidebar {
    display: none;
  }

  .bk-plp-sidebar.is-open .bk-filter--sidebar {
    display: block;
  }

  .bk-plp-sidebar {
    position: static;
    max-height: none;
  }
}

/* ── Generic pages ──────────────────────────────────────────────────── */
.bk-page-head__title {
  color: var(--bk-dark-mid);
}

.bk-404__code {
  background: var(--bk-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.bk-post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

@media (max-width: 1024px) {
  .bk-post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .bk-post-grid {
    grid-template-columns: 1fr;
  }
}

.bk-404__inner {
  text-align: center;
  padding: 64px 0;
}

.bk-404__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
