.osw-header-heart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.osw-header-heart [hidden],
.osw-toast[hidden] {
  display: none !important;
}

.oilstore-product-page .ospp-head__fav[aria-pressed="true"] {
  color: #e30613;
}

.osw-page {
  padding-top: 20px;
  padding-bottom: 32px;
}

#content.osw-content {
  min-height: 0;
  color: #20252b;
  background: #fff;
  border: 1px solid #e5e8eb;
  border-radius: 20px;
  padding: clamp(16px, 3vw, 32px);
}

.osw-content .breadcrumb-box {
  margin: 0 0 16px;
  padding: 0;
}

.osw-content .breadcrumb [aria-current="page"] {
  color: inherit;
}

.osw-content h1 {
  margin: 0 0 12px;
  font-size: clamp(23px, 3vw, 32px);
  font-weight: 700;
}

.osw-guest {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-bottom: 20px;
  color: #56616b;
  font-size: 14px;
}

.osw-guest a {
  color: #20252b;
}

.osw-guest p,
.osw-empty p {
  margin: 0;
}

.osw-guest a,
.osw-toast a {
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
}

.osw-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(224px, 100%), 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.osw-card {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
  padding: 12px;
  border: 1px solid #e6e9ec;
  border-radius: 10px;
}

.osw-media {
  position: relative;
  width: 100%;
  padding-bottom: 20px;
}

.osw-image {
  display: block;
  width: 100%;
  height: 187px;
}

.osw-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.osw-remove {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 1;
  margin: 0;
}

.osw-heart {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  background: #fff;
  color: #e30613;
  border: 1px solid #e6e9ec;
  border-radius: 9px;
}

.osw-media .osw-stickers {
  --oilstore-sticker-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  max-width: calc(100% - 44px);
  opacity: 1;
  pointer-events: none;
}

.osw-stickers > :is(.oct-sticker-item, .oilstore-box-badge) {
  max-width: 100%;
  margin: 0;
  padding: 2px 6px;
  border-radius: var(--oilstore-sticker-radius);
  font-size: 11px;
  line-height: 15px;
  white-space: normal;
  overflow-wrap: anywhere;
}

.osw-media .osw-discount {
  display: block;
  top: auto;
  bottom: 0;
  left: 0;
  opacity: 1;
  pointer-events: none;
}

.osw-discount > .oct-discount-item {
  display: inline-block;
  margin: 0;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
}

.osw-name {
  display: -webkit-box;
  overflow: hidden;
  color: #24313d;
  font-size: 14px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.osw-card-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 37px;
  margin-top: auto;
}

.osw-stock {
  display: none;
}

.osw-prices {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 1px 8px;
  line-height: 1.15;
}

.osw-prices > .price-new {
  order: 1;
  font-size: 19px;
  font-weight: 700;
}

.osw-prices > .price-old {
  order: 2;
  min-width: 0;
  overflow: hidden;
  color: #9aa2a8;
  font-size: 14px;
  text-decoration: line-through;
  text-overflow: ellipsis;
}

.osw-prices > :is(.price-new, .price-old) {
  white-space: nowrap;
}

.osw-buy,
.osw-home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #e30613;
  border: 1px solid transparent;
  border-radius: 8px;
}

.osw-buy {
  flex: none;
  width: 37px;
  height: 37px;
  padding: 0;
  font-size: 16px;
  line-height: 1;
}

.osw-home {
  min-height: 40px;
  padding: 6px 14px;
  font-weight: 600;
}

@supports (grid-template-rows: subgrid) {
  .osw-card {
    display: grid;
    grid-row: span 4;
    grid-template-rows: subgrid;
    row-gap: 7px;
    align-items: start;
  }

  .osw-media { grid-row: 1; }
  .osw-prices { grid-row: 2; }
  .osw-name { grid-row: 3; }
  .osw-card-footer { grid-row: 4; margin-top: 0; align-self: end; }
}

.osw-buy:hover,
.osw-home:hover {
  background: #c8101d;
  color: #fff;
}

.osw-empty {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: clamp(28px, 6vw, 72px) 0;
  text-align: center;
}

.osw-empty-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  color: #e30613;
  background: #fff1f1;
  font-size: 28px;
}

.osw-empty h2 {
  margin: 0;
  font-size: clamp(18px, 2.8vw, 24px);
  font-weight: 700;
}

.osw-empty p {
  color: #657079;
}

.osw-home {
  margin-top: 4px;
}

.osw-toast {
  position: fixed;
  z-index: 21000;
  right: 20px;
  bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  max-width: calc(100vw - 40px);
  padding: 14px 16px;
  border: 1px solid #e1e4e8;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 8px 26px rgb(25 30 35 / 16%);
  color: #20252b;
}

@media (max-width: 767px) {
  .osw-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .osw-card {
    padding: 10px;
  }

  .osw-image {
    height: 128px;
  }

  .osw-media {
    padding-bottom: 16px;
  }

  .osw-discount > .oct-discount-item {
    padding: 2px 5px;
    font-size: 10px;
  }

  .osw-stickers > :is(.oct-sticker-item, .oilstore-box-badge) {
    padding: 2px 4px;
    font-size: 9px;
    line-height: 1.25;
  }

  .osw-prices {
    gap: 1px 3px;
  }

  .osw-prices > .price-new {
    font-size: clamp(14px, 4.2vw, 16px);
    letter-spacing: -.04em;
  }

  .osw-prices > .price-old {
    font-size: clamp(9px, 2.7vw, 11px);
    letter-spacing: -.04em;
  }

  .osw-prices .oct-carousel-old-ruble {
    display: none;
  }

  .osw-name {
    font-size: 12px;
    line-height: 1.3;
  }

  .osw-buy {
    width: 44px;
    height: 44px;
  }

  .osw-toast {
    right: 12px;
    bottom: calc(68px + env(safe-area-inset-bottom, 0px));
    max-width: calc(100vw - 24px);
  }
}
