.apartments-section {
  padding: 40px 0 100px;
  scroll-margin-top: 100px;
}

.apartments-section__title {
  font-size: 42px;
  font-weight: 500;
  line-height: 1.2;
  text-transform: uppercase;
  margin-bottom: 40px;
  letter-spacing: 1px;
}

.apartments-section__title span {
  font-weight: 300;
}

.apartments-filter {
  --filter-bg: linear-gradient(160deg, #fbfaf9 0%, #f4f2ef 45%, #f9f7f4 100%);
  --filter-border: rgba(28, 25, 23, 0.07);
  --filter-accent: #292524;
  --filter-muted: #78716c;
  --filter-field: #ffffff;
  --filter-ring: rgba(87, 83, 78, 0.18);
  --filter-control-h: 46px;
  --filter-radius: 12px;
  position: relative;
  margin-bottom: 48px;
  padding: 0;
  border-radius: 22px;
  background: var(--filter-bg);
  border: 1px solid var(--filter-border);
  box-shadow:
    0 1px 3px rgba(28, 25, 23, 0.035),
    0 24px 56px -28px rgba(28, 25, 23, 0.14);
  overflow: visible;
}

.apartments-filter::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.9) 0%,
    rgba(255, 255, 255, 0) 40%,
    rgba(120, 113, 108, 0.06) 100%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.apartments-filter__head {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 20px;
  padding: 24px 28px 20px;
  border-bottom: 1px solid rgba(28, 25, 23, 0.055);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.72) 0%, rgba(255, 255, 255, 0.38) 100%);
  backdrop-filter: blur(10px);
  text-align: center;
}

.apartments-filter__head-text {
  min-width: 0;
  max-width: 40rem;
  margin: 0 auto;
}

.apartments-filter__title {
  margin: 0 0 8px;
  font-size: 1.375rem;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--filter-accent);
  line-height: 1.2;
}

.apartments-filter__subtitle {
  margin: 0 auto;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--filter-muted);
  font-weight: 400;
  max-width: 36rem;
  opacity: 0.92;
}

.apartments-filter__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 260px));
  justify-content: center;
  gap: 20px 28px;
  padding: 22px 28px 4px;
  align-items: end;
  background: rgba(255, 255, 255, 0.5);
  overflow: visible;
}

.apartments-filter__group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  width: 100%;
}

.apartments-filter__group--finishing {
  min-width: 0;
  align-self: stretch;
}

.apartments-filter__group--finishing .apartments-filter__dd {
  position: relative;
  z-index: 2;
  margin-top: 0;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.apartments-filter .apartments-filter__group--finishing button.apartments-filter__dd-trigger {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  width: 100%;
  max-width: 100%;
  height: var(--filter-control-h);
  min-height: var(--filter-control-h);
  padding: 0 40px 0 16px;
  margin: 0;
  border: 1px solid rgba(28, 25, 23, 0.12);
  border-radius: var(--filter-radius);
  background-color: var(--filter-field);
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.035);
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--filter-accent);
  cursor: pointer;
  text-align: left;
  box-sizing: border-box;
  line-height: 1.25;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.apartments-filter .apartments-filter__group--finishing button.apartments-filter__dd-trigger:hover {
  border-color: rgba(28, 25, 23, 0.2);
}

.apartments-filter .apartments-filter__group--finishing button.apartments-filter__dd-trigger:focus-visible {
  border-color: rgba(28, 25, 23, 0.28);
  outline: 0;
  box-shadow: 0 0 0 3px var(--filter-ring);
}

.apartments-filter__dd {
  position: relative;
}

.apartments-filter__dd-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
}

.apartments-filter__dd-value {
  flex: 1;
  min-width: 0;
  line-height: 1.35;
}

.apartments-filter__dd-value--accent {
  color: #2f6f4e;
  font-weight: 600;
}

.apartments-filter__group--finishing .apartments-filter__dd-chevron {
  position: absolute;
  right: 14px;
  top: 50%;
  width: 10px;
  height: 10px;
  margin-top: -2px;
  border-right: 2px solid #57534e;
  border-bottom: 2px solid #57534e;
  transform: translateY(-50%) rotate(45deg);
  transition: transform 0.2s ease;
  flex-shrink: 0;
  pointer-events: none;
}

.apartments-filter__group--finishing .apartments-filter__dd.is-open .apartments-filter__dd-chevron {
  transform: translateY(-50%) rotate(-135deg);
  margin-top: 2px;
}

.apartments-filter__dd-list {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  z-index: 100;
  min-width: 100%;
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--filter-field);
  border: 1px solid rgba(28, 25, 23, 0.14);
  border-radius: var(--filter-radius);
  box-shadow:
    0 1px 2px rgba(28, 25, 23, 0.06),
    0 16px 40px rgba(28, 25, 23, 0.12);
  overflow: hidden;
}

.apartments-filter__group--finishing:has(.apartments-filter__dd.is-open),
.apartments-filter__group--finishing.apartments-filter__group--dd-open {
  z-index: 5;
}

.apartments-filter__dd-list[hidden] {
  display: none !important;
}

.apartments-filter__dd-option {
  display: block;
  width: 100%;
  padding: 14px 16px;
  border: 0;
  border-bottom: 1px solid rgba(28, 25, 23, 0.1);
  background: #fff;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--filter-accent);
  text-align: left;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.apartments-filter__dd-list li:last-child .apartments-filter__dd-option {
  border-bottom: 0;
}

.apartments-filter__dd-option:hover,
.apartments-filter__dd-option:focus-visible {
  outline: 0;
  background: rgba(47, 111, 78, 0.06);
  color: #2f6f4e;
}

.apartments-filter__dd-option.is-selected {
  color: #2f6f4e;
  font-weight: 600;
  background: rgba(47, 111, 78, 0.08);
}

.apartments-filter__group--types {
  grid-column: 1 / -1;
}

@media (min-width: 992px) {
  .apartments-filter__group--types {
    grid-column: auto;
  }
}

.apartments-filter__label {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--filter-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  line-height: 1.2;
  display: flex;
  align-items: center;
  gap: 9px;
}

.apartments-filter__label::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--filter-muted);
  opacity: 0.28;
  flex-shrink: 0;
}

.apartments-filter__select {
  width: 100%;
  height: var(--filter-control-h);
  padding: 0 40px 0 16px;
  border: 1px solid rgba(28, 25, 23, 0.09);
  border-radius: var(--filter-radius);
  background-color: var(--filter-field);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2357544e' d='M1.4 0L6 4.6 10.6 0 12 1.4l-6 6-6-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  font-size: 0.9375rem;
  font-family: inherit;
  color: var(--filter-accent);
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.035);
  box-sizing: border-box;
  line-height: 1.25;
}

.apartments-filter__select:hover {
  border-color: rgba(28, 25, 23, 0.16);
}

.apartments-filter__select:focus {
  border-color: rgba(28, 25, 23, 0.28);
  outline: 0;
  box-shadow: 0 0 0 3px var(--filter-ring);
}

.apartments-filter__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.apartments-filter__chips--rooms {
  flex-wrap: nowrap;
  gap: 0;
  padding: 3px;
  min-height: var(--filter-control-h);
  height: var(--filter-control-h);
  border-radius: var(--filter-radius);
  background: rgba(28, 25, 23, 0.035);
  border: 1px solid rgba(28, 25, 23, 0.06);
  box-sizing: border-box;
  align-items: stretch;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.65);
}

.apartments-filter__chips--rooms .apartments-filter__chip {
  flex: 1 1 0;
  min-width: 0;
  min-height: 100%;
  padding: 0 10px;
  border-radius: 0;
  border: 0;
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  background: transparent;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
}

.apartments-filter__chips--rooms .apartments-filter__chip:first-child {
  border-radius: calc(var(--filter-radius) - 3px) 0 0 calc(var(--filter-radius) - 3px);
}

.apartments-filter__chips--rooms .apartments-filter__chip:last-child {
  border-radius: 0 calc(var(--filter-radius) - 3px) calc(var(--filter-radius) - 3px) 0;
}

.apartments-filter__chips--rooms .apartments-filter__chip--active {
  background: var(--filter-field);
  color: var(--filter-accent);
  box-shadow: 0 1px 4px rgba(28, 25, 23, 0.07), 0 0 0 1px rgba(28, 25, 23, 0.04);
}

/* Тип апартаментов — тот же сегментированный ряд, что и комнатность */
.apartments-filter__chips--types.apartments-filter__chips--rooms .apartments-filter__chip {
  font-size: clamp(0.75rem, 0.35vw + 0.65rem, 0.875rem);
  font-weight: 600;
  padding: 0 8px;
}

.apartments-filter__chips--types .apartments-filter__chip-text {
  display: block;
  text-align: center;
  line-height: 1.2;
  hyphens: auto;
  overflow-wrap: anywhere;
}

.apartments-filter__chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border: 1px solid rgba(28, 25, 23, 0.1);
  border-radius: 999px;
  background: var(--filter-field);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--filter-accent);
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
}

.apartments-filter__chips--types .apartments-filter__chip:hover {
  border-color: rgba(28, 25, 23, 0.2);
}

.apartments-filter__chips--rooms .apartments-filter__chip:hover:not(.apartments-filter__chip--active) {
  color: var(--filter-accent);
}

.apartments-filter__chip--active {
  background: var(--filter-accent);
  border-color: var(--filter-accent);
  color: #fff;
  box-shadow: 0 4px 14px rgba(28, 25, 23, 0.22);
}

.apartments-filter__chip:has(.apartments-filter__chip-input:checked) {
  background: var(--filter-accent);
  border-color: var(--filter-accent);
  color: #fff;
  box-shadow: 0 4px 14px rgba(28, 25, 23, 0.22);
}

.apartments-filter__chip-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.apartments-filter__inputs {
  display: flex;
  align-items: stretch;
  gap: 12px;
  min-height: var(--filter-control-h);
  height: var(--filter-control-h);
  box-sizing: border-box;
}

.apartments-filter__input {
  flex: 1;
  height: 100%;
  min-height: 0;
  padding: 0 14px;
  border: 1px solid rgba(28, 25, 23, 0.09);
  border-radius: var(--filter-radius);
  font-size: 0.9375rem;
  font-family: inherit;
  min-width: 0;
  background: var(--filter-field);
  color: var(--filter-accent);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
  box-sizing: border-box;
}

.apartments-filter__input::placeholder {
  color: #a8a29e;
}

.apartments-filter__input:focus {
  border-color: rgba(28, 25, 23, 0.28);
  outline: 0;
  box-shadow: 0 0 0 3px var(--filter-ring);
}

.apartments-filter__separator {
  color: #a8a29e;
  font-weight: 400;
  font-size: 0.875rem;
  flex-shrink: 0;
  align-self: center;
  line-height: 1;
}

.apartments-filter__actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px 28px;
  flex-wrap: wrap;
  padding: 18px 28px 24px;
  margin-top: 0;
  border-top: none;
  background: rgba(255, 255, 255, 0.5);
  overflow: visible;
  position: relative;
  z-index: 0;
}

.apartments-filter__clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--filter-muted);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(28, 25, 23, 0.1);
  border-radius: var(--filter-radius);
  cursor: pointer;
  text-decoration: none;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  flex-shrink: 0;
  box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
}

.apartments-filter__clear:hover {
  color: var(--filter-accent);
  border-color: rgba(28, 25, 23, 0.16);
  background: #fff;
  box-shadow: 0 2px 8px rgba(28, 25, 23, 0.06);
}

.apartments-filter__submit {
  flex: 0 1 auto;
  min-width: min(100%, 220px);
  max-width: 400px;
  margin-left: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 26px;
  background: linear-gradient(165deg, #3d3835 0%, #292524 48%, #1c1917 100%);
  color: #fafaf9;
  border: 1px solid rgba(28, 25, 23, 0.35);
  font-size: 0.9375rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.01em;
  cursor: pointer;
  border-radius: var(--filter-radius);
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  box-shadow:
    0 2px 6px rgba(28, 25, 23, 0.12),
    0 12px 32px -16px rgba(28, 25, 23, 0.35);
}

.apartments-filter__submit:hover {
  filter: brightness(1.06);
  box-shadow:
    0 4px 14px rgba(28, 25, 23, 0.14),
    0 18px 40px -18px rgba(28, 25, 23, 0.4);
  transform: translateY(-1px);
}

.apartments-filter__submit:active {
  transform: translateY(0);
  filter: brightness(0.98);
}

.apartments-filter__submit:focus-visible {
  outline: 0;
  box-shadow:
    0 0 0 3px rgba(255, 255, 255, 0.95),
    0 0 0 5px var(--filter-ring),
    0 12px 32px -16px rgba(28, 25, 23, 0.35);
}

.apartments-filter__clear:focus-visible {
  outline: 0;
  box-shadow: 0 0 0 3px var(--filter-ring);
}

.apartments-filter__count {
  font-weight: 700;
  margin: 0 0.2em;
  opacity: 0.95;
}

.apartments-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.apartments-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.45;
  color: #292524;
}

.apartments-table thead th {
  text-align: left;
  font-weight: 600;
  font-size: 13px;
  color: #57534e;
  padding: 14px 12px 12px;
  border-bottom: 1px solid rgba(28, 25, 23, 0.12);
  white-space: nowrap;
}

.apartments-table__th-sort {
  vertical-align: bottom;
}

.apartments-table__sort-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  color: inherit;
  text-decoration: none;
  font-weight: 600;
}

.apartments-table__sort-link:hover {
  color: #2f6f4e;
}

.apartments-table__sort-label {
  white-space: nowrap;
}

.apartments-table__sort-arrow {
  font-size: 0.72em;
  line-height: 1;
  font-weight: 700;
}

.apartments-table__sort-arrow--idle {
  color: #a8a29e;
}

.apartments-table__sort-arrow--active {
  color: #2f6f4e;
}

th.apartments-table__col-status.apartments-table__th-sort .apartments-table__sort-link {
  justify-content: flex-end;
  width: 100%;
}

.apartments-table tbody td {
  padding: 16px 12px;
  border-bottom: 1px solid #eee;
  vertical-align: middle;
}

.apartments-table tbody tr:last-child td {
  border-bottom: none;
}

.apartments-table__col-status,
.apartments-table__cell-status {
  text-align: right;
}

.apartments-table__cell-status {
  white-space: nowrap;
  color: #44403c;
}

.apartments-table__accent-link {
  color: #2f6f4e;
  font-weight: 600;
  text-decoration: none;
}

.apartments-table__accent-link:hover {
  text-decoration: underline;
}

.apartments-table__price {
  color: #2f6f4e;
  font-weight: 600;
  white-space: nowrap;
}

.apartments-table__tags {
  max-width: 240px;
}

.apartments-table__tag {
  display: inline-block;
  margin: 2px 6px 2px 0;
  padding: 4px 10px;
  font-size: 12px;
  line-height: 1.3;
  color: #2f6f4e;
  border: 1px solid rgba(47, 111, 78, 0.45);
  border-radius: 999px;
  white-space: nowrap;
}

.apartments-table__tag--more {
  border-style: dashed;
}

.apartments-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
}

.apartment-card {
  display: block;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #eee;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  text-decoration: none;
  color: inherit;
}

.apartment-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.apartment-card__image {
  aspect-ratio: 4/3;
  overflow: hidden;
  background: #f0f0f0;
}

.apartment-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.apartment-card__placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #e8e8e8 0%, #f5f5f5 100%);
}

.apartment-card__body {
  padding: 20px;
}

.apartment-card__title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.3;
}

.apartment-card__meta {
  font-size: 15px;
  color: #666;
  line-height: 1.4;
}

.apartments-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-top: 50px;
  padding-top: 30px;
  border-top: 1px solid #eee;
}

.apartments-pagination__link {
  padding: 10px 20px;
  border: 1px solid #000;
  border-radius: 10px;
  color: #000;
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s ease;
}

.apartments-pagination__link:hover {
  background: #000;
  color: #fff;
}

.apartments-pagination__info {
  font-size: 15px;
  color: #666;
}

.apartments-empty {
  text-align: center;
  font-size: 20px;
  color: #666;
  padding: 60px 20px;
}

.complexes-section__hint {
  font-size: 16px;
  color: #666;
  margin-bottom: 28px;
  line-height: 1.5;
}

.complexes-section__hint-link {
  color: #292524;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.complexes-section__hint-link:hover {
  color: #000;
}

.houses-index__cross {
  margin: -16px 0 32px;
  font-size: 15px;
  color: #666;
}

.houses-index__cross-link {
  color: #292524;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(41, 37, 36, 0.3);
  transition: border-color 0.15s ease, color 0.15s ease;
}

.houses-index__cross-link:hover {
  color: #000;
  border-bottom-color: rgba(0, 0, 0, 0.45);
}

.houses-index__grid {
  margin-top: 4px;
}

.complexes-section {
  margin-top: 8px;
}

.complexes-section__title {
  font-size: 28px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 28px;
  color: #000;
}

.complexes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}

.complex-card {
  display: block;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #eee;
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.complex-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.complex-card__image {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: #f0f0f0;
}

.complex-card--coming-soon {
  cursor: default;
}

.complex-card--coming-soon:hover {
  box-shadow: none;
  transform: none;
}

.complex-card--coming-soon .complex-card__meta {
  color: #666;
}

.complex-card__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #fff;
  background: rgba(0, 0, 0, 0.72);
  border-radius: 6px;
}

.complex-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.complex-card__placeholder {
  width: 100%;
  height: 100%;
  min-height: 180px;
  background: linear-gradient(135deg, #e8e8e8 0%, #f5f5f5 100%);
}

.complex-card__body {
  padding: 20px;
}

.complex-card__title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-wrap: break-word;
  hyphens: auto;
}

.complex-card__address {
  font-size: 14px;
  color: #666;
  line-height: 1.45;
  margin-bottom: 10px;
  overflow-wrap: anywhere;
  word-wrap: break-word;
}

.complex-card__meta {
  font-size: 14px;
  color: #000;
  font-weight: 500;
}

.complex-card__body--house .complex-card__address {
  margin-bottom: 10px;
  color: #292524;
  font-size: 15px;
}

.complex-card__body--house:has(.complex-card__location) .complex-card__address {
  margin-bottom: 6px;
}

.complex-card__body--house .complex-card__location {
  font-size: 14px;
  color: #666;
  line-height: 1.45;
  margin: 0 0 10px;
}

.complex-card__body--house .complex-card__price {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: #111;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.complex-card--coming-soon .complex-card__body--house .complex-card__price {
  font-size: 15px;
  font-weight: 600;
  color: #57534e;
}

.complex-detail {
  padding: 40px 0 100px;
}

.complex-detail__back {
  display: inline-block;
  margin-bottom: 24px;
  color: #666;
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s ease;
}

.complex-detail__back:hover {
  color: #000;
}

.complex-detail__header {
  margin-bottom: 36px;
}

.complex-detail__title {
  font-size: 36px;
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.2;
}

.complex-detail__address {
  font-size: 17px;
  color: #444;
  margin-bottom: 6px;
  line-height: 1.45;
}

.complex-detail__header--house .complex-detail__address {
  margin-bottom: 10px;
}

.complex-detail__house-price {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #111;
  line-height: 1.2;
}

.complex-detail__house-price--aside {
  text-align: right;
  margin-bottom: 20px;
  font-size: 22px;
}

.complex-detail__city {
  font-size: 15px;
  color: #666;
  margin-bottom: 16px;
}

.complex-detail__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.complex-detail__badge {
  display: inline-block;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: #f0f0f0;
  color: #333;
  border-radius: 6px;
}

.complex-detail__badge--accent {
  background: #000;
  color: #fff;
}

.complex-detail__grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 48px;
  margin-bottom: 48px;
}

.complex-detail__main-img {
  aspect-ratio: 16/10;
  overflow: hidden;
  border-radius: 10px;
  background: #f0f0f0;
}

.complex-detail__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.complex-detail__placeholder {
  width: 100%;
  min-height: 320px;
  border-radius: 10px;
  background: linear-gradient(135deg, #e8e8e8 0%, #f5f5f5 100%);
}

.complex-detail__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.complex-detail__thumb {
  width: 88px;
  height: 66px;
  object-fit: cover;
  border-radius: 8px;
}

.complex-detail__gallery--house {
  min-width: 0;
}

.complex-detail__portfolio-slider.portfolio-slider {
  width: 100%;
  max-width: 100%;
  margin: 0;
  overflow: visible;
}

.complex-detail__portfolio-slider .slides {
  position: relative;
  isolation: isolate;
}

.complex-detail__portfolio-slider .slide:not(.active) {
  pointer-events: none;
}

.complex-detail__portfolio-slider .portfolio-controls {
  left: 12px;
  right: 12px;
  z-index: 20;
  pointer-events: none;
}

.complex-detail__portfolio-slider .portfolio-controls button {
  pointer-events: auto;
  cursor: pointer;
  font-size: 18px;
  font-weight: 600;
  color: #111;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 8px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
}

.complex-detail__grid:has(.complex-detail__portfolio-slider) {
  overflow: visible;
}

.complex-detail__gallery--house:has(.complex-detail__portfolio-slider) {
  overflow: visible;
}

.house-gallery-block {
  width: 100%;
  min-width: 0;
}

.house-gallery-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
  padding: 4px 2px 2px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.house-gallery-thumb {
  flex: 0 0 auto;
  padding: 0;
  margin: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  line-height: 0;
  background: #eee;
  opacity: 0.72;
  transition: opacity 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.house-gallery-thumb:hover {
  opacity: 1;
}

.house-gallery-thumb.is-active {
  opacity: 1;
  border-color: #292524;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

.house-gallery-thumb__img {
  display: block;
  width: 88px;
  height: 66px;
  object-fit: cover;
}

@media (max-width: 600px) {
  .house-gallery-thumb__img {
    width: 72px;
    height: 54px;
  }

  .house-gallery-thumbs {
    flex-wrap: nowrap;
  }
}

.complex-detail__aside {
  align-self: start;
}

.complex-detail__aside--house {
  align-self: start;
}

.complex-detail__params--house {
  margin-bottom: 20px;
}

.complex-detail__params {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px 24px;
  margin-bottom: 24px;
}

.complex-detail__params dt {
  color: #666;
  font-weight: 400;
}

.complex-detail__params dd {
  margin: 0;
  font-weight: 500;
}

.complex-detail__hint {
  font-size: 15px;
  color: #666;
  line-height: 1.5;
  margin-bottom: 20px;
}

.complex-detail__link {
  display: inline-block;
  margin-bottom: 16px;
  color: #000;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.complex-detail__link:hover {
  color: #444;
}

.complex-detail__btn {
  display: inline-block;
  padding: 14px 32px;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-align: center;
  text-decoration: none;
  border-radius: 10px;
  border: 2px solid #000;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.complex-detail__btn--primary {
  width: 100%;
  background: #000;
  color: #fff;
}

.complex-detail__btn--primary:hover {
  background: #fff;
  color: #000;
}

.complex-detail__text {
  box-sizing: border-box;
  max-width: min(800px, 100%);
  width: 100%;
  min-width: 0;
  margin-bottom: 40px;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.65;
  color: #000000;
  overflow-wrap: anywhere;
  word-wrap: break-word;
}

.complex-detail__text p {
  margin-bottom: 1em;
}

.complex-detail__text p:last-child {
  margin-bottom: 0;
}

.complex-detail__section {
  margin-bottom: 40px;
}

.complex-detail__section-title {
  font-size: 22px;
  font-weight: 600;
  margin-bottom: 16px;
}

.complex-detail__list {
  margin: 0;
  padding-left: 1.2em;
  line-height: 1.6;
  color: #333;
}

.complex-detail__list--infra {
  list-style: none;
  padding-left: 0;
}

.complex-detail__list--infra li {
  margin-bottom: 8px;
}

.complex-detail__infra-key {
  font-weight: 600;
}

.complex-detail__more {
  margin-top: 24px;
}

@media (max-width: 900px) {
  .complex-detail__grid {
    grid-template-columns: 1fr;
  }

  .complex-detail__btn--primary {
    width: auto;
  }
}

.apartment-detail {
  padding: 40px 0 100px;
}

.apartment-detail__back {
  display: inline-block;
  margin-bottom: 24px;
  color: #666;
  text-decoration: none;
  font-size: 15px;
  transition: color 0.2s ease;
}

.apartment-detail__back:hover {
  color: #000;
}

.apartment-detail__header {
  margin-bottom: 40px;
}

.apartment-detail__title {
  font-size: 36px;
  font-weight: 600;
  margin-bottom: 8px;
}

.apartment-detail__complex-link {
  color: inherit;
  text-decoration: none;
}

.apartment-detail__complex-link:hover {
  opacity: 0.72;
}

.apartment-detail__number {
  font-size: 18px;
  color: #666;
}

.apartment-detail__grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 50px;
}

.apartment-detail__main-img {
  aspect-ratio: 4/3;
  overflow: hidden;
  border-radius: 10px;
  background: #f0f0f0;
}

.apartment-detail__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.apartment-detail__placeholder {
  width: 100%;
  height: 100%;
  min-height: 300px;
  background: linear-gradient(135deg, #e8e8e8 0%, #f5f5f5 100%);
}

.apartment-detail__thumbs {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.apartment-detail__thumb {
  width: 80px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
}

.apartment-detail__params {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px 30px;
  margin-bottom: 30px;
}

.apartment-detail__params dt {
  color: #666;
  font-weight: 400;
}

.apartment-detail__params dd {
  margin: 0;
  font-weight: 500;
}

.apartment-detail__price {
  font-size: 24px;
  font-weight: 700;
}

.apartment-detail__actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.apartment-detail__btn {
  padding: 16px 40px;
  background: #ff8000;
  color: #fff;
  border: 2px solid #000;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.apartment-detail__btn:hover {
  background: #fff;
  color: #000;
}

a.apartment-detail__btn {
  display: inline-block;
  text-align: center;
  text-decoration: none;
  box-sizing: border-box;
}

.apartment-detail__btn.apartment-detail__btn--call {
  background: #fff;
  color: #ff8000;
}

.apartment-detail__btn.apartment-detail__btn--call:hover {
  background: #ff8000;
  color: #fff;
}

@media (max-width: 900px) {
  .apartment-detail__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 991px) {
  .apartments-filter__head {
    padding: 22px 22px 18px;
  }

  .apartments-filter__grid {
    grid-template-columns: repeat(2, minmax(180px, 340px));
    justify-content: center;
    align-items: stretch;
    padding: 22px 22px 6px;
    gap: 20px 28px;
  }

  .apartments-filter__group--types {
    grid-column: 1 / -1;
  }

  .apartments-filter__actions {
    padding: 16px 22px 22px;
  }
}

@media (max-width: 768px) {
  .apartments-section__title {
    font-size: 28px;
  }

  .apartments-filter__head {
    padding: 20px 18px 16px;
  }

  .apartments-filter__title {
    font-size: 1.2rem;
  }

  .apartments-filter__subtitle {
    font-size: 0.85rem;
  }

  .apartments-filter__grid {
    grid-template-columns: 1fr;
    justify-content: stretch;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
    padding: 20px 18px 4px;
  }

  .apartments-filter__grid > .apartments-filter__group:last-of-type {
    grid-column: auto;
    max-width: none;
    justify-self: stretch;
  }

  .apartments-filter__actions {
    flex-direction: column-reverse;
    align-items: stretch;
    padding: 16px 18px 20px;
    gap: 12px;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }

  .apartments-filter__submit {
    max-width: none;
    margin-left: 0;
    width: 100%;
  }

  .apartments-filter__clear {
    width: 100%;
    text-align: center;
  }

  .apartments-filter__chips--rooms {
    flex-wrap: wrap;
    height: auto;
    min-height: 0;
    padding: 0;
    gap: 8px;
    background: transparent;
    border: 0;
  }

  .apartments-filter__chips--rooms .apartments-filter__chip {
    flex: 1 1 calc(25% - 6px);
    min-width: 44px;
    min-height: var(--filter-control-h);
    height: var(--filter-control-h);
    border: 1px solid rgba(28, 25, 23, 0.1);
    border-radius: 12px;
    background: var(--filter-field);
    box-shadow: 0 1px 2px rgba(28, 25, 23, 0.04);
  }

  .apartments-filter__chips--rooms .apartments-filter__chip:first-child,
  .apartments-filter__chips--rooms .apartments-filter__chip:last-child {
    border-radius: 12px;
  }

  .apartments-filter__chips--rooms .apartments-filter__chip--active {
    box-shadow: 0 4px 14px rgba(28, 25, 23, 0.22);
  }

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

  .apartment-detail__title {
    font-size: 28px;
  }
}

/* --- История строительства (камеры) --- */

.construction-sites-index__hint {
  max-width: 720px;
  margin: 0 0 28px;
  font-size: 16px;
  line-height: 1.55;
  color: #555;
}

.construction-card {
  text-align: left;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.complex-card__placeholder.construction-card__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 180px;
  background: linear-gradient(145deg, #1a1a1a 0%, #2d2d2d 100%);
}

.construction-card__icon {
  width: 48px;
  height: 36px;
  border: 3px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  position: relative;
  box-sizing: border-box;
}

.construction-card__icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-40%, -50%);
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 8px 0 8px 14px;
  border-color: transparent transparent transparent rgba(255, 255, 255, 0.5);
}

.construction-card__body {
  flex: 1;
}

.construction-card__title {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 8px;
  line-height: 1.25;
  color: inherit;
}

.construction-card__meta {
  margin: 10px 0 0;
  font-size: 14px;
  color: #666;
}

.construction-site-show__text {
  margin-bottom: 32px;
}

.construction-site-show__cameras {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-bottom: 48px;
}

.construction-site-show__camera-title {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 14px;
}

.construction-site-show__embed {
  position: relative;
  width: 100%;
  max-width: 960px;
  aspect-ratio: 16 / 9;
  background: #111;
  border-radius: 10px;
  overflow: hidden;
}

.construction-site-show__embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Загруженное видео: высота блока по реальным пропорциям ролика */
.construction-site-show__embed.construction-site-show__embed--native {
  aspect-ratio: unset;
  height: auto;
  line-height: 0;
}

.construction-site-show__embed--native video.construction-site-show__video {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
  border: 0;
  vertical-align: top;
  background: #000;
}

.construction-site-show__empty {
  font-size: 16px;
  color: #666;
  margin-bottom: 40px;
}
