/* =============================================
   Browse Properties — video banner, sidebar, cards
   ============================================= */

/* ---- Video banner (Our Services style) ---- */

.prop-banner {
  position: relative;
  height: clamp(280px, 38vh, 420px);
  overflow: hidden;
}

.prop-banner__media {
  position: absolute;
  inset: 0;
}

.prop-banner__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.06);
}

.prop-banner__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(1.06);
  display: block;
}

.prop-banner__image[hidden],
.prop-banner__video[hidden] {
  display: none !important;
}

.prop-banner__overlay-top {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(34, 34, 34, 0.15) 0%, rgba(0, 0, 0, 0) 100%);
  pointer-events: none;
}

.prop-banner__overlay-bot {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 70%, rgba(34, 34, 34, 0.2) 100%);
  pointer-events: none;
}

body.page-properties .header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: transparent;
  box-shadow: none;
}

body.page-properties .header__nav {
  background: var(--header-nav-bg-solid);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

body.page-properties .header__links a.is-active {
  color: #ffffff;
  font-weight: 600;
  opacity: 1;
}

body.page-properties .section-projects {
  background: #ffffff;
  padding: clamp(2.5rem, 5vw, 3.5rem) 0 clamp(4.5rem, 9vw, 6.5rem);
}

body.page-properties .section-projects .container {
  max-width: 1760px;
  padding-left: clamp(1rem, 2.5vw, 2rem);
  padding-right: clamp(1rem, 2.5vw, 2rem);
}

/* ---- Page heading (above cards, no video overlay) ---- */

.properties-page__heading {
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

.properties-page__eyebrow {
  margin: 0 0 0.5rem;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #888888;
}

.properties-page__title {
  margin: 0 0 0.625rem;
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: #111111;
}

.properties-page__subtitle {
  margin: 0;
  font-size: clamp(0.9375rem, 1.4vw, 1.0625rem);
  line-height: 1.55;
  color: #666666;
  max-width: 640px;
}

/* Prevent scroll-motion from clipping page heading */
body.page-properties .properties-page__heading,
body.page-properties .properties-page__heading * {
  opacity: 1 !important;
  transform: none !important;
  clip-path: none !important;
  visibility: visible !important;
}

/* ---- Sidebar + results layout ---- */

.properties-layout {
  display: grid;
  grid-template-columns: minmax(260px, 300px) minmax(0, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: start;
}

.properties-sidebar {
  position: sticky;
  top: calc(80px + 1.25rem);
  z-index: 20;
}

.properties-sidebar__inner {
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  padding: clamp(1.25rem, 2vw, 1.5rem);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.properties-sidebar__title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #111111;
}

.properties-sidebar__subtitle {
  margin: 0 0 1.25rem;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: #666666;
}

.properties-results {
  min-width: 0;
}

/* ---- Vertical sidebar search bar (ash theme) ---- */

body.page-properties .search-bar--sidebar {
  position: static;
  max-width: none;
  margin: 0;
  opacity: 1;
  transform: none;
  width: 100%;
  color: #2a2a2a;
}

body.page-properties .search-bar--sidebar .search-bar__form {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  min-height: auto;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: #2a2a2a;
}

body.page-properties .search-bar--sidebar .search-bar__field {
  flex: none;
  padding: 1rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

body.page-properties .search-bar--sidebar .search-bar__field:last-of-type {
  border-bottom: none;
}

body.page-properties .search-bar--sidebar .search-bar__divider {
  display: none;
}

body.page-properties .search-bar--sidebar .search-bar__label {
  color: #888888;
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

body.page-properties .search-bar--sidebar .search-bar__value {
  color: #111111;
  font-size: 0.9375rem;
  font-weight: 600;
}

body.page-properties .search-bar--sidebar .search-bar__trigger {
  padding: 0.625rem 0.875rem;
  background: #f5f5f5;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 10px;
  color: #111111;
}

body.page-properties .search-bar--sidebar .search-bar__trigger:hover {
  background: #eeeeee;
  border-color: rgba(0, 0, 0, 0.16);
}

body.page-properties .search-bar--sidebar .search-bar__chevron {
  color: #555555;
  opacity: 1;
}

body.page-properties .search-bar--sidebar .search-bar__dropdown {
  bottom: auto;
  top: calc(100% + 0.5rem);
  left: 0;
  right: 0;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

body.page-properties .search-bar--sidebar .search-bar__option {
  color: #333333;
}

body.page-properties .search-bar--sidebar .search-bar__option:hover,
body.page-properties .search-bar--sidebar .search-bar__option.is-active {
  background: #f0f0f0;
  color: #111111;
}

body.page-properties .search-bar--sidebar .search-bar__submit {
  width: 100%;
  margin: 1.25rem 0 0;
  height: auto;
  padding: 1rem 1.25rem;
  border-radius: 12px;
  background: #111111;
  border: 1px solid #111111;
  color: #ffffff;
  font-size: 0.6875rem;
  box-shadow: none;
}

body.page-properties .search-bar--sidebar .search-bar__submit:hover {
  background: #2a2a2a;
  border-color: #2a2a2a;
}

body.page-properties .search-bar--sidebar .search-bar__count {
  color: #ffffff;
}

body.page-properties .projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.35rem, 2.2vw, 2rem);
}

body.page-properties .projects-grid__empty {
  grid-column: 1 / -1;
  text-align: center;
  color: #555555;
  font-size: 1rem;
  padding: 3rem 1rem;
}

/* ---- Listing card ---- */

.project-listing-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
}

.project-listing-card__link {
  display: flex;
  flex: 1;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
}

.project-listing-card__link:hover h3 {
  color: #000000;
}

.project-listing-card:hover {
  border-color: rgba(0, 0, 0, 0.14);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.project-listing-card__media {
  position: relative;
  margin: 0;
  overflow: hidden;
  aspect-ratio: 7 / 4;
  background: #f0f0f0;
}

.project-listing-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.project-listing-card:hover .project-listing-card__media img {
  transform: scale(1.04);
}

.corner-ribbon {
  position: absolute;
  top: 20px;
  right: -38px;
  z-index: 2;
  width: 160px;
  padding: 9px 0;
  background: #000000;
  color: #ffffff;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-align: center;
  text-transform: uppercase;
  transform: rotate(45deg);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.22);
  pointer-events: none;
}

.project-listing-card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: clamp(1.5rem, 2.6vw, 1.875rem) clamp(1.5rem, 2.6vw, 2rem) clamp(1.25rem, 2vw, 1.5rem);
}

.project-listing-card__body h3 {
  font-size: clamp(1.25rem, 1.85vw, 1.5rem);
  font-weight: 600;
  line-height: 1.3;
  color: #111111;
  margin-bottom: 0.625rem;
}

.project-listing-card__location {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.45;
  color: #555555;
  margin-bottom: 1rem;
}

.project-listing-card__meta {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 0;
}

.project-listing-card__meta > p,
.project-listing-card__details p {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.45;
  color: #555555;
  margin: 0;
}

.project-listing-card__details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.625rem 1rem;
}

.project-listing-card__icon {
  flex-shrink: 0;
  width: 17px;
  height: 17px;
  margin-top: 0.1rem;
  color: #111111;
}

.project-listing-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  margin-top: auto;
  min-height: 72px;
  padding: 1rem 1.75rem;
  background: #ebe9e6;
  border-top: none;
}

.project-listing-card__price {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.2rem;
  min-width: 0;
  flex: 1;
}

.project-listing-card__price span {
  font-size: 0.6875rem;
  font-weight: 500;
  color: #6b6560;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.project-listing-card__price strong {
  font-size: clamp(1.125rem, 1.65vw, 1.375rem);
  font-weight: 700;
  color: #111111;
  line-height: 1.15;
}

.project-listing-card__cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  align-self: center;
  padding: 0.25rem 0 0.25rem 0.5rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  color: #111111;
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.project-listing-card__cta:hover {
  color: #222222;
  opacity: 0.85;
  transform: none;
  box-shadow: none;
  background: none;
}

@media (max-width: 1500px) {
  body.page-properties .section-projects .container {
    max-width: 1440px;
  }
}

@media (max-width: 1100px) {
  body.page-properties .properties-layout {
    grid-template-columns: minmax(240px, 280px) minmax(0, 1fr);
  }

  body.page-properties .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  body.page-properties .properties-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  body.page-properties .properties-sidebar {
    position: static;
  }
}

@media (max-width: 680px) {
  body.page-properties .projects-grid {
    grid-template-columns: 1fr;
  }

  .project-listing-card__details {
    grid-template-columns: 1fr;
  }
}
