/* ============================================
   PROPERTY CARD COMPONENT v2
   
   Compact, modern property cards.
   ============================================ */

/* Card container */
.property-card {
  background: var(--bg-primary);
  border-radius: 16px;
  overflow: hidden;
  margin: 12px 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06), 0 0 1px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.property-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1), 0 0 1px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

/* ============================================
   IMAGES SECTION
   ============================================ */

.property-card__images {
  position: relative;
  background: var(--bg-tertiary);
}

.property-card__images img {
  width: 100%;
  height: auto;
  max-height: 200px;
  object-fit: cover;
  display: block;
}

.property-card__images.slider-initialized {
  margin: 0;
  border-radius: 0;
}

.property-card__images .property-slider {
  border-radius: 0;
}

.property-card__images .slider-slides {
  aspect-ratio: 16 / 9;
  max-height: 200px;
}

/* Smaller slider controls inside card */
.property-card__images .slider-btn {
  width: 32px;
  height: 32px;
  font-size: 16px;
}

.property-card__images .slider-indicators {
  padding: 4px 8px;
  gap: 6px;
}

.property-card__images .slider-indicator {
  width: 6px;
  height: 6px;
}

.property-card__images .slider-indicator.active {
  width: 18px;
}

/* ============================================
   CONTENT SECTION
   ============================================ */

.property-card__content {
  padding: 12px 14px 14px;
}

/* Price row */
.property-card__price-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 6px;
}

.property-card__price {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}

.property-card__price-per-sqm {
  font-size: 12px;
  color: var(--text-muted);
}

/* Title (rooms, area, floor) */
.property-card__title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 2px;
  line-height: 1.3;
}

/* Subtitle (house info, JK name) */
.property-card__subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* ============================================
   TAGS - inline compact style
   ============================================ */

.property-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
}

.property-card__tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  background: var(--bg-tertiary);
  border-radius: 10px;
  font-size: 11px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.property-card__tag--highlight {
  background: rgba(5, 74, 92, 0.08);
  color: var(--accent-primary);
}

.property-card__tag--success {
  background: rgba(5, 150, 105, 0.08);
  color: var(--success-color);
}

/* ============================================
   DETAILS - compact inline
   ============================================ */

.property-card__details {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-bottom: 8px;
  padding: 8px 10px;
  background: var(--bg-secondary);
  border-radius: 8px;
  font-size: 12px;
}

.property-card__detail {
  color: var(--text-secondary);
  line-height: 1.4;
}

/* ============================================
   LOCATION (metro + address)
   ============================================ */

.property-card__location {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
  margin-bottom: 10px;
  font-size: 13px;
}

.property-card__metro {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--text-primary);
  font-weight: 500;
}

.property-card__metro-time {
  color: var(--text-secondary);
  font-weight: 400;
}

.property-card__address {
  color: var(--text-secondary);
}

/* ============================================
   ACTIONS - compact buttons
   ============================================ */

.property-card__actions {
  display: flex;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.property-card__map-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 12px;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.property-card__map-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-color: var(--border-medium);
}

.property-card__link {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 12px;
  background: var(--accent-primary);
  color: var(--text-inverse) !important;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.15s ease;
}

.property-card__link:link,
.property-card__link:visited,
.property-card__link:hover,
.property-card__link:active {
  color: var(--text-inverse) !important;
  text-decoration: none;
}

.property-card__link:hover {
  background: var(--color-brand-teal-dark);
}

/* ============================================
   CATEGORY-SPECIFIC
   ============================================ */

.property-card[data-category="flats_sale_primary"] .property-card__subtitle {
  color: var(--accent-secondary);
  font-weight: 500;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 480px) {
  .property-card {
    margin: 10px 0;
    border-radius: 12px;
  }

  .property-card__content {
    padding: 10px 12px 12px;
  }

  .property-card__price {
    font-size: 18px;
  }

  .property-card__title {
    font-size: 13px;
  }

  .property-card__images .slider-slides {
    aspect-ratio: 4 / 3;
    max-height: 180px;
  }

  .property-card__actions {
    flex-direction: column;
    gap: 6px;
  }

  .property-card__map-btn,
  .property-card__link {
    width: 100%;
  }
}

/* ============================================
   DARK THEME
   ============================================ */

@media (prefers-color-scheme: dark) {
  .property-card {
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 0 1px rgba(255, 255, 255, 0.1);
  }

  .property-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3), 0 0 1px rgba(255, 255, 255, 0.1);
  }

  .property-card__images {
    background: rgba(255, 255, 255, 0.03);
  }

  .property-card__tag {
    background: rgba(255, 255, 255, 0.08);
  }

  .property-card__details {
    background: rgba(255, 255, 255, 0.05);
  }

  .property-card__actions {
    border-top-color: rgba(255, 255, 255, 0.08);
  }

  .property-card__map-btn {
    border-color: rgba(255, 255, 255, 0.15);
  }

  .property-card__map-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.25);
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes cardAppear {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.property-card {
  animation: cardAppear 0.25s ease forwards;
}

/* Focus styles */
.property-card__map-btn:focus,
.property-card__link:focus {
  outline: 2px solid var(--accent-primary);
  outline-offset: 2px;
}