/* ============================================================
   ??????? ???????? — ????? CSS ??? pvc.html ? p_*.html
   ============================================================ */

/* ---------- ???????: ???????? ---------- */
.catalog-page { padding-bottom: 24px; }
.catalog-page__h1 { font-size: 26px; margin-bottom: 6px; }
.catalog-page__lead { font-size: 14px; margin-bottom: 18px; }

/* ---------- ?????? ???????? ---------- */
.catalog-filters {
  border: 1px solid #ece6df;
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 18px;
  background: #fbf9f7;
}
.catalog-filters__row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}
.catalog-filters__search {
  flex: 1;
  min-width: 0;
  height: 32px;
  padding: 0 10px;
  font-size: 13px;
  border: 1px solid #d8cfc4;
  border-radius: 6px;
  background: #fff;
}
.catalog-filters__search:focus { outline: none; border-color: #27190E; }
.catalog-filters__reset {
  height: 32px;
  padding: 0 12px;
  font-size: 13px;
  border: 1px solid #d8cfc4;
  border-radius: 6px;
  background: #fff;
  color: #27190E;
  cursor: pointer;
  white-space: nowrap;
}
.catalog-filters__reset:hover { background: #27190E; color: #fff; }

.catalog-filters__group { margin-bottom: 10px; }
.catalog-filters__group:last-child { margin-bottom: 0; }
.catalog-filters__label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #8a7d70;
  margin-bottom: 6px;
}
.catalog-filters__grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px 16px;
}
.catalog-filters__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chip {
  display: inline-flex;
  align-items: center;
  height: 26px;
  padding: 0 10px;
  font-size: 12.5px;
  border: 1px solid #d8cfc4;
  border-radius: 13px;
  background: #fff;
  color: #27190E;
  cursor: pointer;
  user-select: none;
  transition: background .12s, color .12s, border-color .12s;
}
.chip:hover { border-color: #27190E; }
.chip.is-active {
  background: #27190E;
  color: #fff;
  border-color: #27190E;
  box-shadow: 0 0 0 2px rgba(39,25,14,.15);
}
.catalog-filters__num {
  display: flex;
  align-items: center;
  gap: 6px;
}
.catalog-filters__num input {
  width: 80px;
  height: 30px;
  padding: 0 8px;
  font-size: 13px;
  border: 1px solid #d8cfc4;
  border-radius: 6px;
  background: #fff;
  -moz-appearance: textfield;
}
.catalog-filters__num input:focus { outline: none; border-color: #27190E; }
.catalog-filters__num input::-webkit-outer-spin-button,
.catalog-filters__num input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.catalog-filters__num span { color: #8a7d70; font-size: 13px; }
.catalog-filters__summary { margin-top: 8px; font-size: 13px; color: #8a7d70; }
.catalog-filters__count { font-weight: 600; color: #27190E; }

/* ???????? ????????? */
.catalog-filters__num input.is-active {
  border-color: #27190E;
  background: #fff8f0;
  box-shadow: 0 0 0 2px rgba(39,25,14,.08);
  font-weight: 600;
}
.catalog-filters__group.is-active > .catalog-filters__label {
  color: #27190E;
  font-weight: 700;
}
.catalog-filters__search.is-active {
  border-color: #27190E;
  background: #fff8f0;
}

/* ---------- ????? ???????? ---------- */
.catalog-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
@media (max-width: 991.98px) {
  .catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 767.98px) {
  .catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
@media (max-width: 359.98px) {
  .catalog-grid { grid-template-columns: 1fr; }
}

/* ---------- ???????? ---------- */
.catalog-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #ece6df;
  overflow: hidden;
  height: 100%;
  transition: box-shadow .15s, border-color .15s;
}
.catalog-card:hover {
  box-shadow: 0 4px 14px rgba(39,25,14,.08);
  border-color: #d8cfc4;
}
.catalog-card__img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  overflow: hidden;
}
.catalog-card__img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}
.catalog-card__weigh {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid #aaa;
  border-radius: 50px;
  background: rgba(255,255,255,.99);
  color: #27190E;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: .7;
  transition: opacity .12s, background .12s, color .12s;
}
.catalog-card__weigh:hover { opacity: 1; background: #fff; }
.catalog-card__weigh svg { width: 15px; height: 15px; display: block; }
.catalog-card__weigh.is-active { opacity: 1; background: #27190E; color: #fff; }

.catalog-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 8px 10px 8px;
  min-height: 0;
}
.catalog-card__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
  margin: 0 0 6px;
  color: #212529;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: calc(1.25em * 2);
}
.catalog-card__name a { color: inherit; text-decoration: none; }
.catalog-card__name a:hover { color: #27190E; }
.catalog-card__specs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  padding: 6px 0;
  border-top: 1px solid #f1ece7;
  border-bottom: 1px solid #f1ece7;
  margin-bottom: 4px;
  text-align: center;
}
.catalog-card__spec { min-width: 0; }
.catalog-card__spec-val {
  font-size: 15px;
  font-weight: 700;
  color: #27190E;
  line-height: 1.1;
  white-space: nowrap;
}
.catalog-card__spec-lbl {
  font-size: 10px;
  color: #8a7d70;
  text-transform: uppercase;
  letter-spacing: .02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.catalog-card__foot {
  margin-top: auto;
  font-size: 11.5px;
  color: #6b5f54;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 4px;
}
.catalog-card__rating { font-weight: 700; color: #27190E; }

@media (max-width: 767.98px) {
  .catalog-card__body { padding: 6px 8px 6px; }
  .catalog-card__name { font-size: 13px; }
  .catalog-card__specs { padding: 5px 0; margin-bottom: 2px; }
  .catalog-card__spec-val { font-size: 14px; }
  .catalog-card__spec-lbl { font-size: 9px; }
  .catalog-card__weigh { width: 36px; height: 36px; top: 4px; right: 4px; }
  .catalog-card__weigh svg { width: 20px; height: 20px; }
  .catalog-filters { padding: 10px; }
  .catalog-filters__grid { grid-template-columns: 1fr; gap: 8px; }
  .catalog-page__h1 { font-size: 21px; }
}

/* ---------- ????????? ---------- */
.catalog-more {
  display: flex;
  justify-content: center;
  padding: 18px 0 4px;
}
.catalog-more__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 8px 22px;
  font-size: 14px;
  line-height: 1.2;
  border: 1px solid #27190E;
  border-radius: 6px;
  background: #fff;
  color: #27190E;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  transition: background .12s, color .12s;
}
.catalog-more__btn:hover { background: #27190E; color: #fff; }
.catalog-more__btn[disabled] { opacity: .5; cursor: default; }
.catalog-more__sentinel { height: 1px; width: 100%; }

@media (max-width: 480px) {
  .catalog-more__btn {
    padding: 8px 14px;
    font-size: 13px;
  }
}
.catalog-more__sentinel { height: 1px; width: 100%; }
.catalog-loading { grid-column: 1 / -1; text-align: center; padding: 32px 0; }

/* ---------- ?????? ???????? (????? ? rate.js) ---------- */
.rating-container { display: inline-flex; align-items: center; gap: 6px; }
.rating-value { font-weight: 700; color: #27190E; }
.rating-bars { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.rating-bars .bar { width: 4px; height: 6px; background: #e0d6ca; border-radius: 1px; display: inline-block; }
.rating-bars .bar:nth-child(2) { height: 8px; }
.rating-bars .bar:nth-child(3) { height: 11px; }
.rating-bars .bar:nth-child(4) { height: 14px; }
.rating-bars .bar.active { background: #27190E; }
.rating-bars .bar.active.level-1 { background: #c9a27a; }
.rating-bars .bar.active.level-2 { background: #b08656; }
.rating-bars .bar.active.level-3 { background: #8d6438; }
.rating-bars .bar.active.level-4 { background: #27190E; }

/* ---------- ???????? ??????? (?? ????????? ?????) ---------- */
.catalog-grid--archived .catalog-card { opacity: .7; }
.catalog-grid--archived .catalog-card:hover { opacity: 1; }
.catalog-archive {
  margin-top: 20px;
  border: 1px dashed #d8cfc4;
  border-radius: 8px;
  background: #fbf9f7;
}
.catalog-archive > summary {
  padding: 10px 14px;
  cursor: pointer;
  font-weight: 600;
  color: #27190E;
  list-style: none;
}
.catalog-archive > summary::-webkit-details-marker { display: none; }
.catalog-archive > summary::before {
  content: '+';
  display: inline-block;
  width: 18px;
  margin-right: 6px;
  font-weight: 700;
  color: #8a7d70;
}
.catalog-archive[open] > summary::before { content: '-'; }
.catalog-archive__content { padding: 0 14px 14px; }
.catalog-filters__check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #27190E;
  cursor: pointer;
  user-select: none;
}
.catalog-filters__check input[type="checkbox"] {
  width: 14px;
  height: 14px;
  accent-color: #27190E;
  cursor: pointer;
}