/* Страницы макета: каталог, объявление, подача, вход. */

.gallery__main img,
.gallery__thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.avatar {
  overflow: hidden;
  padding: 0;
  text-decoration: none;
  color: #fff;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.ad-status-banner {
  width: min(1200px, calc(100% - 48px));
  margin: 16px auto 0;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--gold-soft);
  color: var(--red-deep);
  font-weight: 600;
}

#reportForm.hidden,
#reportForm[hidden] {
  display: none;
}

#reportForm:not(.hidden):not([hidden]) {
  display: block;
  margin-top: 16px;
}

.search-page--gallery .search-page__layout.listing {
  display: block;
  width: auto;
  margin: 0;
  padding: 0 0 80px;
}

@media (min-width: 1080px) {
  .search-page--gallery .listing.search-page__layout {
    display: grid;
    grid-template-columns: 264px 1fr;
    gap: 32px;
    align-items: start;
  }

  body.site-body .search-page--gallery .search-page__aside.filters {
    position: sticky !important;
    top: 96px !important;
    inset: auto !important;
    width: auto !important;
    visibility: visible !important;
    pointer-events: auto !important;
    overflow: visible !important;
    z-index: 2 !important;
    display: flex !important;
    flex-direction: column;
    gap: 0;
  }

  body.site-body .search-page__aside::before {
    display: none !important;
    content: none !important;
  }

  body.site-body .search-page__aside .search-filters-panel,
  body.site-body .search-page__aside .search-filters-form {
    position: static !important;
    width: auto !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    background: transparent !important;
    box-shadow: none !important;
    display: block !important;
  }
}

.search-filter-section {
  border-bottom: 1.5px dashed var(--line-2);
  padding: 0 0 18px;
  margin: 0 0 18px;
}

.search-filter-section__label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 10px;
}

.search-filters-form__input,
.search-filters-form__select,
.search-page--gallery .ui-select-control select,
.toolbar select {
  height: 42px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 0 12px;
}

.search-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 36px;
}

.search-pagination__link,
.search-pagination__status {
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1.5px solid var(--line);
  font-weight: 600;
}

.ad-create-page--gallery {
  width: min(1200px, calc(100% - 48px));
  margin: 0 auto 72px;
}

.ad-create-wizard,
.ad-create-card {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  padding: 22px 24px;
  margin-bottom: 18px;
  box-shadow: none;
}

.ad-create-wizard__heading,
.ad-create-card__title {
  font-family: var(--font-display);
}

.ad-create-stages {
  display: flex;
  gap: 0;
  margin-top: 16px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  background: #fff;
  list-style: none;
  padding: 0;
}

.ad-create-stages__item {
  flex: 1;
  text-align: center;
  padding: 12px 8px;
  font-weight: 600;
  color: var(--ink-3);
  border-right: 1.5px solid var(--line);
}

.ad-create-stages__item:last-child {
  border-right: 0;
}

.ad-create-stages__item.is-current,
.ad-create-stages__item.is-done {
  background: var(--red);
  color: #fff;
}

.ad-create-page .form-input,
.ad-create-page textarea,
.ad-create-page select {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  padding: 12px 14px;
  font-family: var(--font-body);
}

.form-page--gallery {
  min-height: 62vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 16px 80px;
}

.form-page--gallery .form-card {
  width: min(460px, 100%);
}

.form-page--gallery .form-input {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  padding: 13px 16px;
}

:root {
  --wrap: 1280px;
  --x-accent: #A62B1F;
  --x-accent-hover: #7E1F16;
  --x-accent-soft: rgba(166, 43, 31, .12);
  --home-primary: #A62B1F;
  --home-primary-hover: #7E1F16;
  --home-primary-deep: #7E1F16;
}

.header__in {
  gap: 10px;
}

.header .search {
  flex: 1 1 280px;
  min-width: 260px;
}

.header .search input {
  min-width: 7.5rem;
  color: var(--ink);
  font-size: 15px;
}

.cta__art img {
  width: 190px;
  height: 190px;
  object-fit: contain;
  filter: drop-shadow(0 16px 30px rgba(0, 0, 0, .3));
}

.logo__mark {
  width: 40px;
  height: 40px;
  object-fit: contain;
  background: transparent;
  flex: none;
}

.logo__word {
  white-space: nowrap;
}

.logo__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

body.site-body > footer.footer,
body.home-body > footer.footer {
  background: #211D18 !important;
  color: #CFC7BA;
  margin-top: 80px;
}

.footer .logo__word {
  color: #fff;
}

.footer .logo__word em {
  color: #E9A13B;
  font-style: normal;
}

.footer .logo__sub {
  color: #8F867A;
}

.footer a.logo:hover .logo__word {
  color: #fff;
}

.footer a.logo:hover .logo__word em {
  color: #E9A13B;
}

.footer a.logo:hover .logo__sub {
  color: #8F867A;
}

.footer a.btn,
.footer a.btn:hover,
.footer a.btn:focus-visible {
  display: inline-flex;
  width: auto;
  padding: 13px 22px;
  font-size: 15px;
  line-height: 1;
}

.footer .btn--gold,
.footer a.btn--gold,
.footer a.btn--gold:hover,
.footer a.btn--gold:focus-visible,
a.btn--gold,
a.btn--gold:hover,
a.btn--gold:focus-visible,
button.btn--gold,
button.btn--gold:hover,
button.btn--gold:focus-visible {
  color: #7E1F16;
  background: #E9A13B;
}

.footer a.btn--gold:hover,
.footer a.btn--gold:focus-visible,
a.btn--gold:hover,
a.btn--gold:focus-visible,
button.btn--gold:hover,
button.btn--gold:focus-visible {
  color: #7E1F16;
  background: #f0ad4e;
}

a.btn--primary,
a.btn--primary:hover,
a.btn--primary:focus-visible,
button.btn--primary,
button.btn--primary:hover,
button.btn--primary:focus-visible,
.search__btn,
.search__btn:hover,
.search__btn:focus-visible,
.phone,
.phone:hover,
.phone:focus-visible {
  color: #fff;
}

a.btn--ghost,
a.btn--ghost:hover,
a.btn--ghost:focus-visible,
button.btn--ghost,
button.btn--ghost:hover,
button.btn--ghost:focus-visible {
  color: #211D18;
}

.fav[data-favorited="1"],
.fav[data-favorited="1"]:hover,
.fav.is-fav,
.fav.is-fav:hover,
.ad-card__favorite[data-favorited="1"],
.ad-card__favorite[data-favorited="1"]:hover {
  color: #fff;
  background: #A62B1F;
}

.fav[data-favorited="1"] svg,
.fav.is-fav svg,
.ad-card__favorite[data-favorited="1"] svg,
.fav[data-favorited="1"]:hover svg,
.ad-card__favorite[data-favorited="1"]:hover svg {
  color: #fff;
  fill: currentColor;
  stroke: #fff;
}

.x-chip.is-active,
.x-chip.is-active:hover,
.portal-hub__chip.is-active,
.portal-hub__chip.is-active:hover,
.search-quick-filter-chip--active,
.search-quick-filter-chip--active:hover,
.pager a.is-cur,
.pager a.is-cur:hover {
  color: #E9A13B;
}

.header .nav a {
  padding: 8px 8px;
}

.header__cabinet-btn {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
}

.header__cabinet-drop a,
.header__cabinet-drop button,
.mmenu .header__lang {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-badge {
  width: 28px;
  height: 18px;
  border-radius: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
  line-height: 1;
}

.lang-badge--ru {
  color: #A62B1F;
  background: #fff;
  border: 1.5px solid #E4DAC8;
}

.lang-badge--cv {
  color: #7E1F16;
  background: #E9A13B;
  border: 1.5px solid #C47F1E;
}

.header__cabinet-drop a.header__lang.is-current {
  background: var(--paper-2);
}

.header .btn--primary {
  padding: 12px 16px;
}

.header .nav {
  flex: none;
}

.footer .logo {
  display: flex;
  align-items: center;
  gap: 11px;
}

.footer .btn {
  display: inline-flex;
  width: auto;
}

@media (max-width: 1280px) {
  .header .logo__sub {
    display: none;
  }

  .header .nav a {
    padding: 8px 8px;
  }
}

body.site-body .form-page--gallery {
  background: transparent;
}

body.site-body .form-page--gallery .form-card {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  padding: 32px 28px;
  box-shadow: var(--shadow-1);
}

body.site-body .ad-create-page--gallery .ad-create-card {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  box-shadow: none;
  padding: 26px 28px;
  margin-bottom: 18px;
}

body.site-body .ad-create-page .btn-primary,
body.site-body .ad-create-page .ad-create-btn--primary {
  background: var(--red);
  color: #fff;
  border: 0;
  border-radius: 999px;
  box-shadow: 0 6px 18px rgba(166, 43, 31, .28);
}

.search-toolbar .ui-icon-btn {
  background: #fff;
  border: 1.5px solid var(--line);
  color: var(--ink);
  border-radius: 12px;
}

.search-toolbar .ui-icon-btn--active {
  background: var(--ink);
  color: var(--gold);
  border-color: var(--ink);
}

.search-page--gallery {
  background: transparent;
  padding: 0 0 24px;
}

.search-page--gallery .search-page__layout {
  width: auto;
  margin: 0;
  padding: 0 0 48px;
}

.portal-hub__cta {
  margin: 18px 0 0;
}

.form-page--gallery .form-card__title,
.form-page--gallery .form-card__brand {
  font-family: var(--font-display);
}

.form-page--gallery .form-submit {
  width: 100%;
  height: 48px;
  margin-top: 14px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-weight: 600;
}

.ad-create-page.home-container {
  width: min(var(--wrap), calc(100% - 48px));
  max-width: none;
  margin: 0 auto 72px;
}

.hero-search {
  margin-top: 18px;
  max-width: 720px;
}

.hero-search__label {
  margin: 18px 0 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.portal-hub .hero-search {
  max-width: none;
  width: min(720px, 100%);
  margin-top: 16px;
}

.portal-hub .hero-search__label + .hero-search {
  margin-top: 0;
}

.page-head .lead {
  max-width: 64ch;
}

.portal-hub > .wrap,
.jobs-hub.home-container,
.portal-hub__body.home-container,
.org-catalog > .home-container {
  width: min(var(--wrap), calc(100% - 48px));
  max-width: none;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
}

body.site-body .jobs-hub--gallery {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Каталог: сайдбар как в макете, на узком экране остаётся выезжающая панель. */
@media (min-width: 1080px) {
  body.site-body .search-page--gallery .listing.search-page__layout,
  body.site-body .listing-hub {
    display: grid !important;
    grid-template-columns: 264px minmax(0, 1fr) !important;
    gap: 18px 32px !important;
    align-items: start !important;
    width: auto !important;
  }

  body.site-body .listing-hub {
    grid-template-areas: "hubhead hubhead" "hubfilters hubads";
  }

  body.site-body .listing-hub > header {
    grid-area: hubhead;
  }

  body.site-body .listing-hub > aside {
    grid-area: hubfilters;
  }

  body.site-body .listing-hub > .jobs-catalog__ads,
  body.site-body .listing-hub > .realty-catalog__ads {
    grid-area: hubads;
    min-width: 0;
  }

  body.site-body .search-page__aside,
  body.site-body .jobs-filters-aside,
  body.site-body .realty-filters-aside {
    position: sticky !important;
    top: 96px !important;
    inset: auto !important;
    width: auto !important;
    max-height: none !important;
    visibility: visible !important;
    pointer-events: auto !important;
    overflow: visible !important;
    z-index: 2 !important;
    display: flex !important;
    flex-direction: column;
    background: transparent !important;
    transform: none !important;
  }

  body.site-body .search-page__aside::before,
  body.site-body .jobs-filters-aside::before,
  body.site-body .realty-filters-aside::before {
    display: none !important;
    content: none !important;
  }

  body.site-body .search-page__aside .search-filters-panel,
  body.site-body .jobs-filters-aside .search-filters-panel,
  body.site-body .realty-filters-aside .search-filters-panel,
  body.site-body .search-page__aside .search-filters-form,
  body.site-body .jobs-filters-aside .search-filters-form,
  body.site-body .realty-filters-aside .search-filters-form {
    position: static !important;
    inset: auto !important;
    width: auto !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    transform: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    display: block !important;
  }

  body.site-body .search-filters-form__mobile-head {
    display: none !important;
  }

  body.site-body .search-page__aside #searchCategoryNav {
    display: block !important;
  }

  #mobileFiltersToggle {
    display: none !important;
  }
}

.search-page--gallery .search-page__grid.ads-grid,
.realty-catalog__ads .search-page__grid.ads-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 18px !important;
}

@media (max-width: 1080px) {
  .search-page--gallery .search-page__grid.ads-grid,
  .realty-catalog__ads .search-page__grid.ads-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 640px) {
  .search-page--gallery .search-page__grid.ads-grid,
  .realty-catalog__ads .search-page__grid.ads-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }
}

.search-page__grid .ad-card,
.ads-grid .ad-card {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-1);
  overflow: hidden;
  animation: none;
}

.search-page__grid .ad-card:hover,
.ads-grid .ad-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-2);
}

.search-filter-section__label,
.search-cat-nav__title,
.org-filters__title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.search-cat-nav {
  border-bottom: 1.5px dashed var(--line-2);
  padding-bottom: 16px;
  margin-bottom: 16px;
}

.search-cat-nav__child,
.search-cat-nav__group-link,
.search-cat-nav__back {
  display: block;
  padding: 6px 0;
  color: var(--ink-2);
}

.search-cat-nav__child--active,
.search-cat-nav__group-link--active {
  color: var(--red);
  font-weight: 600;
}

.search-filter-inline-check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  color: var(--ink-2);
}

body.site-body .search-filters-form__submit {
  position: static;
  width: 100%;
  margin-top: 8px;
  height: 48px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 6px 18px rgba(166, 43, 31, .32);
}

.search-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex-wrap: wrap;
}

.search-toolbar__district,
.search-toolbar__layout {
  display: none !important;
}

.search-toolbar select,
.ui-select-control select {
  height: 42px;
  padding: 0 14px;
  border-radius: 12px;
  background: #fff;
  border: 1.5px solid var(--line);
  font-weight: 500;
}

.search-quick-filters,
.search-active-filters,
.hero__chips,
.org-catalog__chips,
.portal-hub__filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 8px 0 16px;
}

.search-quick-filter-chip,
.search-filter-chip,
.x-chip,
.portal-hub__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  background: #fff;
  border: 1.5px solid var(--line);
  font-size: 14px;
  font-weight: 500;
}

.x-chip.is-active,
.portal-hub__chip.is-active,
.search-quick-filter-chip--active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--gold);
}

.pager a,
.pager .search-pagination__link,
.pager .search-pagination__status {
  min-width: 44px;
  height: 44px;
  padding: 0 14px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1.5px solid var(--line);
  font-weight: 600;
}

.gallery.ad-detail-gallery {
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.gallery .gallery__main.ad-detail-gallery__main {
  height: auto;
  max-height: none;
  aspect-ratio: 4 / 3;
}

.ad-create-page--gallery:not(.ad-create-page--jobs) .ad-create-wizard__meta,
.ad-create-page--gallery:not(.ad-create-page--jobs) .ad-create-wizard__track {
  display: none;
}

.ad-create-page--gallery .ad-create-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 36px;
  align-items: start;
}

.ad-create-page--gallery .ad-create-main {
  order: 1;
  min-width: 0;
}

.ad-create-page--gallery .ad-create-aside {
  order: 2;
  position: sticky;
  top: 96px;
}

.ad-create-coach,
.ad-create-cabinet {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  padding: 22px;
}

.ad-create-page--gallery .ad-create-stages {
  border-radius: 18px;
}

@media (max-width: 1080px) {
  .ad-create-page--gallery .ad-create-shell {
    grid-template-columns: 1fr;
  }

  .ad-create-page--gallery .ad-create-aside {
    position: static;
    order: 2;
  }
}

body.site-body .jobs-hub--gallery .job-card,
.job-card {
  display: block;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  padding: 0;
  box-shadow: none;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

body.site-body .jobs-hub--gallery .job-card:hover,
.job-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-2);
  border-color: var(--line);
}

body.site-body .jobs-hub--gallery .job-card__link,
.job-card__link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 20px 16px;
  color: inherit;
  text-decoration: none;
}

.jobs-catalog__list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

@media (max-width: 760px) {
  .jobs-catalog__list {
    grid-template-columns: 1fr;
  }
}

body.site-body .jobs-hub--gallery .job-card__kind,
.job-card__kind {
  display: inline-flex;
  align-self: flex-start;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--paper-2, #F1E9DA);
  font-family: var(--font-body);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--red-deep, #7E1F16);
  margin-bottom: 6px;
}

body.site-body .jobs-hub--gallery .job-card__title,
.job-card__title {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.35;
  color: var(--ink);
}

body.site-body .jobs-hub--gallery .job-card:hover .job-card__title {
  color: var(--red);
}

body.site-body .jobs-hub--gallery .job-card__salary,
.job-card__salary {
  margin: 4px 0 2px;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -.01em;
  color: var(--ink);
}

body.site-body .jobs-hub--gallery .job-card__note,
.job-card__note {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-3);
}

body.site-body .jobs-hub--gallery .job-card__meta,
.job-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0 4px;
  margin-top: 4px;
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--ink-3);
}

body.site-body .jobs-hub--gallery .job-card__verified,
.job-card__verified {
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--green);
}

/* Юридические страницы */
body.site-body .legal-page--gallery {
  padding: 0 0 72px;
  max-width: none;
  width: 100%;
}

body.site-body .legal-page--gallery .legal-doc__title {
  margin: 12px 0 8px;
  font-family: var(--font-display);
  font-size: clamp(30px, 4vw, 44px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -.01em;
  color: var(--ink);
  max-width: none;
}

.legal-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 264px;
  gap: 24px 48px;
  align-items: start;
  margin-top: 18px;
}

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

body.site-body .legal-page--gallery .legal-doc {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  padding: 28px 32px 22px;
  max-width: 760px;
}

body.site-body .legal-page--gallery .legal-doc h2 {
  margin: 22px 0 8px;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink);
}

body.site-body .legal-page--gallery .legal-doc h2:first-child {
  margin-top: 0;
}

body.site-body .legal-page--gallery .legal-doc p,
body.site-body .legal-page--gallery .legal-doc li {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-2);
}

body.site-body .legal-page--gallery .legal-doc__meta {
  margin: 22px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-3);
}

body.site-body .legal-page--gallery .legal-doc a {
  color: var(--red);
}

.legal-nav {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 18px 20px;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
}

.legal-nav h4 {
  margin: 0 0 8px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.legal-nav a {
  display: block;
  padding: 7px 10px;
  margin: 0 -10px;
  border-radius: 10px;
  font-size: 14px;
  color: var(--ink-2);
  transition: background .15s ease, color .15s ease;
}

.legal-nav a:hover {
  background: var(--paper-2);
  color: var(--ink);
}

.legal-nav a[aria-current="page"] {
  background: var(--gold-soft);
  color: var(--red-deep);
  font-weight: 600;
}

/* Пустые состояния: 404, 500 и т.п. */
body.site-body .empty-page--gallery {
  max-width: 560px;
  margin: 0 auto;
  padding: 72px 24px 96px;
  text-align: center;
}

body.site-body .empty-page--gallery .empty-state {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  padding: 40px 32px 36px;
}

body.site-body .empty-page--gallery .empty-state__icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: var(--gold-soft);
  color: var(--red);
}

body.site-body .empty-page--gallery .empty-state__icon svg {
  width: 36px;
  height: 36px;
}

body.site-body .empty-page--gallery h1,
body.site-body .empty-page--gallery .empty-state__title {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
}

body.site-body .empty-page--gallery p,
body.site-body .empty-page--gallery .empty-state__text {
  margin: 0 0 24px;
  font-family: var(--font-body);
  font-size: 15.5px;
  line-height: 1.5;
  color: var(--ink-2);
}

body.site-body .empty-page--gallery .empty-state__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

body.site-body .empty-page--gallery .btn-primary,
body.site-body .empty-page--gallery .btn--primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
}

body.site-body .empty-page--gallery .btn-primary:hover,
body.site-body .empty-page--gallery .btn--primary:hover {
  background: var(--red-deep);
}

body.site-body .empty-page--gallery .btn-outline,
body.site-body .empty-page--gallery .btn--secondary,
body.site-body .empty-page--gallery .btn-ghost,
body.site-body .empty-page--gallery .empty-state__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--card);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

body.site-body .empty-page--gallery .btn-outline:hover,
body.site-body .empty-page--gallery .btn--secondary:hover,
body.site-body .empty-page--gallery .btn-ghost:hover,
body.site-body .empty-page--gallery .empty-state__link:hover {
  border-color: var(--gold);
  background: var(--gold-soft);
}

body.site-body .org-catalog__manifesto-bar {
  width: min(var(--wrap), calc(100% - 48px));
  max-width: none;
  margin: 10px auto 22px;
  padding: 0;
}

body.site-body .org-catalog--gallery .org-catalog__manifesto-btn {
  height: 40px;
  padding: 0 16px;
  border: 1.5px solid var(--line);
  background: var(--card);
  color: var(--red-deep);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  border-radius: 999px;
  transition: border-color .15s ease, background .15s ease;
}

body.site-body .org-catalog--gallery .org-catalog__manifesto-btn:hover {
  border-color: var(--gold);
  background: var(--gold-soft);
}

body.site-body .org-catalog--gallery .org-catalog__body {
  display: grid !important;
  grid-template-columns: 264px minmax(0, 1fr);
  gap: 18px 32px;
  align-items: start;
}

.org-catalog__chips {
  grid-column: 1 / -1;
}

.org-catalog__aside {
  position: sticky;
  top: 96px;
}

.org-card--media {
  display: block;
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-1);
}

.org-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

@media (max-width: 860px) {
  body.site-body .org-catalog--gallery .org-catalog__body {
    grid-template-columns: 1fr;
  }

  .org-catalog__aside {
    position: static;
  }

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

.dating-track,
.dating-card,
.profile-cabinet--gallery .card {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 22px;
  box-shadow: none;
}

.dating-hub,
.dating-track-grid {
  width: min(1200px, calc(100% - 48px));
  margin-left: auto;
  margin-right: auto;
}

.dating-track-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  padding-bottom: 48px;
}

.dating-track {
  padding: 24px;
}

.dating-btn,
.profile-settings__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: #fff;
  font-weight: 600;
}

.dating-btn--primary,
.profile-settings__btn--secondary,
.profile-cabinet--gallery .profile-nav__item.is-active {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

.profile-cabinet--gallery {
  width: min(1100px, calc(100% - 48px));
  margin: 28px auto 80px;
}

.profile-cabinet__title,
.jobs-main__title,
.realty-catalog__title {
  font-family: var(--font-display);
}

.profile-cabinet__layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  margin-top: 18px;
}

@media (max-width: 860px) {
  .profile-cabinet__layout,
  .dating-track-grid {
    grid-template-columns: 1fr;
  }
}

body.site-body .chat-widget__fab,
body.site-body .chat-widget__fab:hover,
body.site-body .chat-widget__header,
body.site-body .chat-widget__bubble--mine,
body.site-body .chat-widget__send,
body.site-body .chat-widget__send:hover {
  background: #A62B1F;
  background-image: none;
}

.chat-widget__panel {
  border: 1.5px solid var(--line);
  border-radius: 22px;
  background: var(--paper);
}

.jobs-hub.home-container,
.portal-hub__body.home-container,
.ad-detail-jobs.home-container {
  width: min(var(--wrap), calc(100% - 48px));
  max-width: none;
  margin-left: auto;
  margin-right: auto;
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 48px;
}

.search-filters-form__select--sync {
  display: none !important;
}

.search-filters-form__input--query {
  width: 100%;
}

.search-filters-form__tools {
  margin: 8px 0 12px;
}

body.site-body .search-price-filter__values,
body.site-body .search-price-filter__track {
  display: none;
}

body.site-body .search-filter-section__range,
body.site-body .search-dyn-range .search-filter-section__range {
  display: flex;
  align-items: center;
  gap: 8px;
}

body.site-body .search-filter-section__range .search-filters-form__input {
  flex: 1 1 0;
  min-width: 0;
  width: 100%;
}

body.dating-body .dating-filters--profiles .dating-filters__search {
  flex: 1 1 220px;
  max-width: none;
  min-width: 12rem;
}

body.site-body,
body.site-body *,
body.dating-body,
body.dating-body * {
  text-shadow: none !important;
}

body.site-body img,
body.dating-body img,
body.home-body img {
  color: transparent;
  font-size: 0;
}

.x-card__fav svg,
.ad-card__favorite svg,
.search-page--gallery .ad-card__favorite svg {
  filter: none;
}

/* Дерево рубрик в сайдбаре каталога */
body.site-body .search-cat-nav {
  padding: 4px 0 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

body.site-body .search-cat-nav__title {
  margin: 0 0 8px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-2);
}

body.site-body .search-cat-nav a,
body.site-body .search-cat-nav__child,
body.site-body .search-cat-nav__group-link,
body.site-body .search-cat-nav__back,
body.site-body .search-cat-nav__trail-link {
  display: block;
  padding: 6px 10px;
  margin: 0 -10px;
  border-radius: 10px;
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.3;
  color: var(--ink-2);
  transition: background .15s ease, color .15s ease;
}

body.site-body .search-cat-nav a:hover,
body.site-body .search-cat-nav__child:hover {
  background: var(--paper-2);
  color: var(--ink);
}

body.site-body .search-cat-nav a.is-active,
body.site-body .search-cat-nav a[aria-current],
body.site-body .search-cat-nav__child.is-active,
body.site-body .search-cat-nav__child--active {
  background: var(--gold-soft);
  color: var(--red-deep);
  font-weight: 600;
}

/* Сворачиваемый блок фильтров: заголовок со стрелкой, как раскрывающийся */
body.site-body .search-filter-more {
  border-top: 1px solid var(--line);
  margin-top: 6px;
}

body.site-body .search-filter-more__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 0;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink-2);
}

body.site-body .search-filter-more__summary::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-right: 4px;
  transition: transform .15s ease;
  flex: none;
}

body.site-body .search-filter-more[open] > .search-filter-more__summary::after {
  transform: rotate(-135deg);
}

/* Карточки в каталоге поиска — те же, что на главной (перебиваем gallery.css/search.css) */
body.site-body .ad-card {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  box-shadow: none;
  transition: transform .2s ease, box-shadow .2s ease;
}

body.site-body .ad-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-2);
  border: 1.5px solid var(--line);
}

body.site-body .ad-card__body {
  padding: 14px 16px 16px;
  gap: 5px;
  flex: 1;
}

body.site-body .ad-card__price {
  margin: 0;
  font-family: var(--font-display);
  font-size: 17.5px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
  letter-spacing: -.01em;
}

body.site-body .ad-card__price--free {
  color: var(--green);
}

body.site-body .ad-card__title {
  margin: 0;
  font-family: var(--font-body);
  font-size: 14.5px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--ink);
  letter-spacing: 0;
}

body.site-body .ad-card__title:hover {
  color: var(--red);
}

body.site-body .ad-card__meta {
  margin: auto 0 0;
  padding-top: 9px;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 6px;
  font-family: var(--font-body);
  font-size: 12.5px;
  line-height: 1.3;
  color: var(--ink-3);
}

body.site-body .ad-card__meta svg {
  width: 14px;
  height: 14px;
  flex: none;
  margin-top: 1px;
}

/* Рубрика в карточке фильтра не прилипает к рамке */
body.site-body .search-filters-panel #searchCategoryNav {
  padding: 16px 16px 4px;
}

body.site-body .search-filters-panel .search-cat-nav a,
body.site-body .search-filters-panel .search-cat-nav__back,
body.site-body .search-filters-panel .search-cat-nav__child,
body.site-body .search-filters-panel .search-cat-nav__group-link,
body.site-body .search-filters-panel .search-cat-nav__trail-link {
  margin: 0;
  padding: 6px 8px;
}

/* Поиск и подробный фильтр — над объявлениями */
.search-listing-tools-mount:empty {
  display: none;
}

.search-listing-tools .search-filter-section--query {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
}

.search-listing-tools .search-filter-section__label {
  flex: 1 0 100%;
  margin: 0;
}

.search-listing-tools .search-filters-form__input--query {
  flex: 1 1 180px;
  height: 46px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 0 18px;
}

.search-listing-tools__submit {
  height: 46px;
  padding: 0 18px;
  flex: none;
}

.search-listing-tools-mount #searchListingDetail.search-filter-more {
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 16px;
  padding: 0 16px 4px;
  margin: 0 0 16px;
}

/* Цена — компактный бегунок по ценам объявлений */
body.site-body #searchPriceFilter .search-price-filter__values {
  display: flex;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
}

body.site-body #searchPriceFilter .search-price-filter__track {
  display: block;
  height: 22px;
  margin: 2px 0 6px;
}

body.site-body #searchPriceFilter .search-filter-section__range {
  display: none;
}

body.site-body #searchPriceFilter .search-price-filter__fill {
  background: #A62B1F;
}

body.site-body #searchPriceFilter .search-price-filter__range::-webkit-slider-thumb {
  border-color: #A62B1F;
  width: 16px;
  height: 16px;
  margin-top: -6px;
}

body.site-body #searchPriceFilter .search-price-filter__range::-moz-range-thumb {
  border-color: #A62B1F;
  width: 16px;
  height: 16px;
}

body.site-body .search-price-filter .search-filter-inline-checks {
  flex-wrap: nowrap;
  gap: 8px;
  margin-top: 2px;
}

body.site-body .search-price-filter .search-filter-inline-check {
  font-size: 12px;
  gap: 4px;
  padding: 0;
  white-space: nowrap;
}

body.site-body .search-price-filter .search-filter-inline-check input {
  width: 14px;
  height: 14px;
  accent-color: #A62B1F;
}

/* Зависимые поля: скрыты, пока не выбрано предыдущее, затем подсветка */
body.site-body .search-filter-section.is-waiting {
  display: none;
}

body.site-body .search-filter-section.is-ready {
  background: var(--gold-soft);
  border-radius: 12px;
  padding: 10px 12px 12px;
  opacity: 1;
  pointer-events: auto;
}

.ad-price-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.ad-price-row__main {
  min-width: 0;
}

.ad-price-row__tools {
  display: flex;
  gap: 8px;
  flex: none;
  margin-top: 8px;
}

.ad-price-row__tools .ad-detail__favorite,
.ad-price-row__tools .ad-detail__share {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: 50%;
}

.ad-detail__favorite[data-favorited="1"],
.ad-detail__favorite[data-favorited="1"]:hover {
  color: #fff;
  background: #A62B1F;
  border-color: #A62B1F;
}

.ad-detail__favorite[data-favorited="1"] svg,
.ad-detail__favorite[data-favorited="1"]:hover svg {
  color: #fff;
  fill: currentColor;
  stroke: #fff;
}

/* Узкий экран: «Разместить» в шапке выталкивает бургер за край.
   Та же кнопка есть в меню. Длинные слова в документах не раздувают страницу. */
@media (max-width: 1080px) {
  .header .burger {
    flex: none;
    width: 44px;
    min-width: 44px;
  }
}

@media (max-width: 520px) {
  .header .header__in > a.btn--primary {
    display: none;
  }
}

.legal-page--gallery .page-head,
.legal-page--gallery .legal-doc__title,
.legal-page--gallery .legal-doc,
.legal-page--gallery .legal-doc p,
.legal-page--gallery .legal-doc li {
  overflow-wrap: anywhere;
  min-width: 0;
}

.footer__bottom a.footer__credit {
  display: inline;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.footer__bottom a.footer__credit:hover {
  color: var(--gold);
}
