/* ===========================
   LISTINGS PAGE — SPECIFIC STYLES
   (imports styles.css for base)
   =========================== */

/* ===========================
   NAV ACTIVE STATE
   =========================== */
.nav-link-active {
  font-weight: 600;
  color: #111111;
}

/* ===========================
   PAGE HEADER
   =========================== */
.listings-header {
  padding-top: 88px;
  padding-bottom: 0;
  border-bottom: 1px solid #e8e8e8;
  background: #ffffff;
}

.listings-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 16px;
}

.listings-title {
  font-size: clamp(24px, 4vw, 32px);
  font-weight: 600;
  letter-spacing: -0.03em;
  color: #111111;
  margin-bottom: 6px;
}

.listings-subtitle {
  font-size: 14px;
  color: #777777;
}

.listings-count {
  font-size: 13px;
  color: #aaaaaa;
  white-space: nowrap;
  padding-bottom: 4px;
}

/* ===========================
   FILTERS
   =========================== */
.filters-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.filter-tabs {
  display: flex;
  gap: 2px;
}

.filter-tab {
  font-size: 13px;
  font-weight: 400;
  font-family: inherit;
  color: #666666;
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px 14px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.filter-tab:hover {
  color: #111111;
}

.filter-tab.active {
  color: #111111;
  font-weight: 600;
  border-bottom-color: #111111;
}

.sort-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sort-label {
  font-size: 12px;
  color: #999999;
  white-space: nowrap;
}

.sort-select {
  font-size: 13px;
  font-family: inherit;
  color: #333333;
  background: #ffffff;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  padding: 6px 10px;
  cursor: pointer;
  outline: none;
  transition: border-color 0.15s;
}

.sort-select:focus {
  border-color: #111111;
}

/* ===========================
   LISTINGS MAIN
   =========================== */
.listings-main {
  padding: 40px 0 80px;
}

/* ===========================
   LISTINGS GRID
   =========================== */
.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

/* ===========================
   LISTING CARD
   =========================== */
.listing-card {
  background: #ffffff;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}

.listing-card:hover {
  border-color: #c0c0c0;
  box-shadow: 0 4px 16px rgba(0,0,0,0.07);
  transform: translateY(-2px);
}

/* Image */
.card-image-wrap {
  position: relative;
  height: 200px;
  overflow: hidden;
  background: #f0f0f0;
}

.card-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.listing-card:hover .card-image-wrap img {
  transform: scale(1.04);
}

/* Type badge */
.card-type-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(255,255,255,0.95);
  color: #111111;
  border-radius: 5px;
  padding: 4px 8px;
  backdrop-filter: blur(4px);
}

/* Platform badge */
.card-platform-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 5px;
}

.badge-platform {
  background: #111111;
  color: #ffffff;
}

.badge-community {
  background: rgba(255,255,255,0.9);
  color: #555555;
  border: 1px solid #e0e0e0;
}

/* Card body */
.card-body {
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-location {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #999999;
  margin-bottom: 6px;
}

.card-name {
  font-size: 16px;
  font-weight: 600;
  color: #111111;
  letter-spacing: -0.015em;
  line-height: 1.3;
  margin-bottom: 12px;
}

/* Key details strip */
.card-details {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f0f0f0;
}

.card-detail {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.detail-label {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #bbbbbb;
}

.detail-value {
  font-size: 13px;
  font-weight: 600;
  color: #222222;
}

/* Extra details */
.card-extras {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
  flex: 1;
}

.extra-tag {
  font-size: 11px;
  color: #555555;
  background: #f6f6f6;
  border-radius: 4px;
  padding: 3px 8px;
  line-height: 1.5;
}

/* Card footer */
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
}

.card-price {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.price-amount {
  font-size: 18px;
  font-weight: 600;
  color: #111111;
  letter-spacing: -0.02em;
}

.price-period {
  font-size: 11px;
  color: #999999;
}

.card-cta {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: #ffffff;
  background: #111111;
  border: none;
  border-radius: 6px;
  padding: 9px 16px;
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
  transition: background 0.15s;
}

.card-cta:hover {
  background: #333333;
}

/* ===========================
   EMPTY STATE
   =========================== */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 64px 0;
  color: #aaaaaa;
  font-size: 15px;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 700px) {
  .listings-title-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
  }

  .filters-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-bottom: 4px;
  }

  .filter-tabs {
    overflow-x: auto;
    width: 100%;
    padding-bottom: 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .filter-tabs::-webkit-scrollbar { display: none; }

  .sort-wrap {
    width: 100%;
    justify-content: flex-end;
    padding-bottom: 8px;
  }

  .listings-grid {
    grid-template-columns: 1fr;
  }

  .listings-main {
    padding: 28px 0 60px;
  }
}
