/* ============================================
   NIROVA — Card CSS (Listing pages)
   Compact horizontal cards + sidebar filters
   ============================================ */

/* --- Page Header --- */
.nr-page-header { margin-bottom: 8px; }
.nr-page-title {
  font-size: 22px;
  font-weight: 600;
  color: var(--nr-text);
  line-height: 1.3;
}

/* --- Location Info --- */
.nr-location-info {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  margin-bottom: 10px;
  background: var(--nr-primary-light);
  border-radius: var(--nr-radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--nr-text);
}
.nr-location-info svg { width: 14px; height: 14px; color: var(--nr-primary); }

/* --- Cards Count --- */
.nr-cards-count {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--nr-muted);
  margin-bottom: 12px;
}
.nr-cards-count svg { width: 16px; height: 16px; }

/* --- Layout: Content + Sidebar --- */
.nr-listing-layout {
  display: flex;
  gap: 24px;
}
.nr-listing__content { flex: 1; min-width: 0; }
.nr-listing__sidebar { display: none; }

/* --- Card --- */
.nr-card {
  display: flex;
  flex-direction: column;
  background: var(--nr-surface);
  border-radius: var(--nr-radius-md);
  box-shadow: var(--nr-shadow-sm);
  overflow: hidden;
  margin-bottom: 10px;
  transition: box-shadow 0.15s, transform 0.15s;
}
.nr-card:hover {
  box-shadow: var(--nr-shadow-md);
  transform: translateY(-1px);
}

/* --- Card Top (name + location, mobile only) --- */
.nr-card__top {
  padding: 10px 12px 6px;
}

/* --- Card Photo --- */
.nr-card__photo-link {
  display: block;
}
.nr-card__photo-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--nr-bg);
}
.nr-card__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s;
}
.nr-card:hover .nr-card__photo { transform: scale(1.03); }
.nr-card__photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--nr-border);
}
.nr-card__photo-placeholder svg { width: 32px; height: 32px; }
/* --- Photo Bar (gradient overlay) --- */
.nr-card__photo-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 10px 6px;
  background: linear-gradient(transparent, rgba(0,0,0,0.6));
  color: #fff;
  font-size: 11px;
  gap: 8px;
}
.nr-card__photo-bar-price {
  font-weight: 600;
  font-size: 13px;
}
.nr-card__photo-bar-right {
  display: flex;
  align-items: center;
  gap: 4px;
  opacity: 0.85;
}
.nr-card__photo-bar-right svg { width: 11px; height: 11px; }
.nr-card__photo-bar-sep { width: 1px; height: 10px; background: rgba(255,255,255,0.3); margin: 0 2px; }

/* --- Card Body --- */
.nr-card__body {
  flex: 1;
  min-width: 0;
  padding: 8px 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.nr-card__header {
  display: none;
  align-items: baseline;
  gap: 6px;
}
.nr-card__location--desktop { display: none; }
.nr-card__name {
  font-size: 15px;
  font-weight: 600;
  color: var(--nr-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nr-card__age {
  font-size: 13px;
  color: var(--nr-muted);
  flex-shrink: 0;
}

/* --- Card Location --- */
.nr-card__location {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--nr-muted);
}
.nr-card__location svg { width: 12px; height: 12px; flex-shrink: 0; }
.nr-card__location-link { color: var(--nr-primary); }
.nr-card__location-link:hover { text-decoration: underline; }

/* --- Card Params (with icons) --- */
.nr-card__params {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.nr-card__param {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--nr-surface);
  border: 1px solid var(--nr-border);
  border-radius: var(--nr-radius-sm);
  font-size: 12px;
  color: var(--nr-body);
  transition: background 0.12s;
}
.nr-card__param-icon { font-size: 12px; line-height: 1; }
.nr-card__param-label { color: #7A7A7A; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.3px; }
.nr-card__param-val { font-weight: 600; color: var(--nr-text); }
.nr-card__param--link { cursor: pointer; }
.nr-card__param--link:hover { background: var(--nr-primary-light); border-color: var(--nr-primary); }

/* --- Card Stats (legacy, kept for desktop bottom) --- */
.nr-card__stats {
  display: none;
}
.nr-card__stat {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 12px;
  color: var(--nr-muted);
}
.nr-card__stat svg { width: 13px; height: 13px; }
.nr-card__stat--likes { color: var(--nr-primary); }

/* --- Card Contacts --- */
.nr-card__contacts {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}
.nr-card__phone-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--nr-primary);
  color: #fff;
  border-radius: var(--nr-radius-sm);
  font-size: 13px;
  font-weight: 600;
  transition: background 0.15s;
}
.nr-card__phone-btn:hover { background: var(--nr-primary-hover); }
.nr-card__phone-btn svg { width: 14px; height: 14px; }
.nr-card__detail-btn {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  background: var(--nr-primary);
  color: #fff;
  border-radius: var(--nr-radius-sm);
  font-size: 13px;
  font-weight: 600;
  transition: background 0.15s;
}
.nr-card__detail-btn:hover { background: var(--nr-primary-hover); }
.nr-card__messengers {
  display: flex;
  gap: 6px;
}
.nr-card__messenger {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--nr-bg);
  color: var(--nr-muted);
  transition: background 0.15s;
}
.nr-card__messenger:hover { background: var(--nr-border); }
.nr-card__messenger--tg:hover { color: #2AABEE; }
.nr-card__messenger--wa:hover { color: #25D366; }
.nr-card__messenger--vb:hover { color: #7360F2; }

/* --- Card Bottom (contacts + stats row) --- */
.nr-card__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 2px;
}

/* --- Sidebar (desktop) --- */
.nr-sidebar {
  width: 260px;
  flex-shrink: 0;
}
.nr-sidebar__section {
  background: var(--nr-surface);
  border-radius: var(--nr-radius-md);
  box-shadow: var(--nr-shadow-sm);
  margin-bottom: 12px;
  overflow: hidden;
}
.nr-sidebar__title {
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--nr-text);
  border-bottom: 1px solid var(--nr-border);
}
.nr-sidebar__group {
  border-bottom: 1px solid var(--nr-border);
}
.nr-sidebar__group:last-child { border-bottom: none; }
.nr-sidebar__group-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--nr-text);
}
.nr-sidebar__group-toggle svg {
  width: 14px;
  height: 14px;
  color: var(--nr-muted);
  transition: transform 0.2s;
}
.nr-sidebar__group.is-expanded .nr-sidebar__group-toggle svg {
  transform: rotate(180deg);
}
.nr-sidebar__items {
  display: none;
  padding: 0 14px 10px;
  flex-wrap: wrap;
  gap: 4px;
}
.nr-sidebar__group.is-expanded .nr-sidebar__items {
  display: flex;
}
.nr-sidebar__link {
  display: inline-block;
  padding: 4px 10px;
  font-size: 12px;
  color: var(--nr-body);
  background: var(--nr-bg);
  border-radius: var(--nr-radius-sm);
  transition: background 0.12s;
}
.nr-sidebar__link:hover {
  background: var(--nr-primary-light);
  color: var(--nr-text);
}

/* --- NavLinks (quick links) --- */
.nr-navlinks {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 12px 0;
}
.nr-navlinks__link {
  padding: 5px 12px;
  background: var(--nr-surface);
  border: 1px solid var(--nr-border);
  border-radius: var(--nr-radius-sm);
  font-size: 13px;
  color: var(--nr-body);
  transition: border-color 0.15s, background 0.15s;
}
.nr-navlinks__link:hover {
  border-color: var(--nr-primary);
  background: var(--nr-primary-light);
}

/* --- Pagination --- */
.nr-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  margin: 24px 0 16px;
  flex-wrap: wrap;
}
.nr-pagination__item {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border-radius: var(--nr-radius-sm);
  font-size: 14px;
  color: var(--nr-body);
  background: var(--nr-surface);
  border: 1px solid var(--nr-border);
  transition: background 0.15s, border-color 0.15s;
}
.nr-pagination__item:hover {
  border-color: var(--nr-primary);
  background: var(--nr-primary-light);
}
.nr-pagination__item--active {
  background: var(--nr-primary);
  color: #fff;
  border-color: var(--nr-primary);
  font-weight: 600;
}
.nr-pagination__item--prev svg,
.nr-pagination__item--next svg { width: 16px; height: 16px; }
.nr-pagination__dots {
  padding: 0 4px;
  color: var(--nr-muted);
}

/* --- SEO Blocks --- */
.nr-seo-blocks {
  margin-top: 24px;
  padding: 20px;
  background: var(--nr-surface);
  border-radius: var(--nr-radius-md);
  box-shadow: var(--nr-shadow-sm);
}
.nr-seo-block--h1,
.nr-seo-block--h2 {
  font-size: 18px;
  font-weight: 600;
  color: var(--nr-text);
  margin: 16px 0 8px;
}
.nr-seo-block--h1:first-child,
.nr-seo-block--h2:first-child { margin-top: 0; }
.nr-seo-block--text {
  font-size: 14px;
  color: var(--nr-body);
  line-height: 1.6;
  margin-bottom: 8px;
}

/* --- Desktop (480px) --- */
@media (min-width: 480px) {
  .nr-card__photo-wrap { aspect-ratio: 16 / 9; }
}

/* --- Desktop (768px) --- */
@media (min-width: 768px) {
  .nr-page-title { font-size: 28px; }
  .nr-listing__sidebar { display: block; }
  /* Switch to horizontal layout */
  .nr-card { flex-direction: row; gap: 0; }
  .nr-card__top { display: none; }
  .nr-card__header--desktop { display: flex; }
  .nr-card__location--desktop { display: flex; }
  .nr-card__photo-link { width: 150px; flex-shrink: 0; }
  .nr-card__photo-wrap { aspect-ratio: 3 / 4; }
  .nr-card__body { padding: 12px 14px 12px 14px; gap: 4px; }
  .nr-card__name { font-size: 16px; }
  .nr-card__bottom { justify-content: flex-start; }
}

/* --- Desktop (1200px) --- */
@media (min-width: 1200px) {
  .nr-card__photo-link { width: 160px; }
}
