.rs-page { padding-block: 20px 48px; }
.rs-back { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; color: var(--muted); font-size: 13px; }
.rs-back { width: fit-content; font-weight: 600; }
.rs-back:hover { color: var(--primary-dark); }

.rs-shop, .rs-native, .rs-detail-art {
  --rs-ink: var(--text);
  --rs-muted: var(--muted);
  --rs-line: var(--line);
  --rs-ground: var(--surface);
  --rs-raised: var(--surface-soft);
  --rs-accent: var(--primary-dark);
}
.rs-shop { padding: 20px; border: 1px solid var(--rs-line); border-radius: 16px; background: var(--rs-ground); color: var(--rs-ink); }
.rs-head, .rs-home-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.rs-head { margin-bottom: 16px; }
.rs-head h1, .rs-detail h1 { margin: 0; font-size: clamp(24px, 3.2vw, 36px); line-height: 1.14; font-weight: 650; }
.rs-head p { margin: 4px 0 0; color: var(--rs-muted); font-size: 13px; line-height: 1.45; }
.rs-rotation { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; color: var(--rs-muted); font-size: 12px; }
.rs-head .rs-rotation { flex-shrink: 0; border: 1px solid var(--rs-line); border-radius: 8px; padding: 8px 12px; }
.rs-rotation i { color: var(--rs-accent); font-size: 14px; }
.rs-rotation time { white-space: nowrap; color: var(--rs-ink); font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.rs-toolbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px 16px; margin-bottom: 12px; }
.rs-groups { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.rs-groups a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--rs-line);
  border-radius: 8px;
  color: var(--rs-muted);
  font-size: 13px;
  font-weight: 600;
}
.rs-groups a[aria-current="page"] { border-color: var(--line-strong); background: var(--primary-soft); color: var(--rs-accent); }
.rs-groups a:hover { background: var(--rs-raised); color: var(--rs-ink); }
.rs-groups a { min-height: 32px; padding: 4px 8px; font-size: 12px; }
.rs-filters { display: flex; flex-shrink: 0; min-width: 0; width: min(100%, 300px); border: 1px solid var(--rs-line); border-radius: 8px; }
.rs-filters:focus-within { border-color: var(--rs-accent); }
.rs-search { flex: 1; min-width: 0; }
.rs-search input {
  width: 100%;
  min-height: 38px;
  padding: 0 12px !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--rs-ink) !important;
  font: inherit;
  font-size: 14px;
}
.rs-search input::placeholder { color: var(--rs-muted); }
.rs-search-button { flex: 0 0 40px; border: 0; background: transparent; color: var(--rs-muted); cursor: pointer; }
.rs-search-button:hover { color: var(--rs-ink); }
.rs-notice { margin: 0 0 12px; font-size: 13px; color: var(--rs-muted); }

.rs-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.rs-grid-native { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.rs-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--rs-line);
  border-radius: 10px;
  background: var(--rs-ground);
  color: var(--rs-ink);
  transition: border-color 180ms ease-out, background-color 180ms ease-out;
}
.rs-card-media, .rs-detail-art {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  min-width: 0;
  background: var(--rs-raised);
  color: var(--rs-muted);
}
.rs-card-media { aspect-ratio: 1.18; }
.rs-card-media img, .rs-detail-art img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: translateY(3%) scale(1.52);
  transition: transform 200ms ease-out;
}
.rs-card:hover, .rs-card:focus-visible { border-color: var(--rs-accent); color: var(--rs-ink); }
.rs-card:focus-visible { outline: 2px solid var(--rs-accent); outline-offset: -2px; }
.rs-card:is(:hover, :focus-visible) .rs-card-media img { transform: translateY(1%) scale(1.6); }
.rs-price {
  display: block;
  margin-top: 4px;
  color: var(--rs-ink);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  line-height: 1.35;
  font-weight: 650;
}
.rs-placeholder { font-size: 22px; }
.rs-card-info { display: flex; align-items: center; justify-content: space-between; flex: 1; gap: 8px; min-height: 58px; padding: 8px 12px; }
.rs-card-info > div { min-width: 0; }
.rs-card-info :is(strong, h3) { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; margin: 0; color: inherit; font-size: 14px; font-weight: 600; line-height: 1.25; }
.rs-card-info :is(small, p) { display: block; overflow: hidden; margin: 4px 0 0; color: var(--rs-muted); font-size: 11px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.rs-card-arrow { flex: 0 0 auto; color: var(--rs-muted); font-size: 12px; transition: transform 180ms ease-out, color 180ms ease-out; }
.rs-card:is(:hover, :focus-visible) .rs-card-arrow { color: var(--rs-accent); transform: translateX(2px); }

.rs-card-cover .rs-card-media { aspect-ratio: 1; }
.rs-card-cover .rs-card-media img,
.rs-card-cover:is(:hover, :focus-visible) .rs-card-media img { object-fit: contain; transform: none; }
.rs-native-card .rs-card-info h3 { font-size: 14px; }
.rs-native-card .rs-price del { color: var(--rs-muted); font-weight: 400; }
.rs-native .rs-notice { grid-column: 1 / -1; }

.rs-native .rs-empty { border-color: var(--line); background: var(--surface); color: var(--muted); }
.rs-empty { grid-column: 1 / -1; margin: 0; padding: 16px; border: 1px solid var(--rs-line); border-radius: 8px; color: var(--rs-muted); font-size: 14px; }
.rs-empty a { color: var(--rs-ink); text-decoration: underline; }
.rs-pager { display: flex; justify-content: center; align-items: center; gap: 12px; margin-top: 16px; color: var(--rs-muted); font-size: 13px; }
.rs-pager a { display: grid; width: 40px; height: 40px; place-items: center; border: 1px solid var(--rs-line); border-radius: 8px; color: var(--rs-ink); }
.rs-catalog-link { display: inline-flex; align-items: center; gap: 8px; padding-block: 8px; color: var(--primary-dark); font-size: 13px; font-weight: 600; }

.rs-home { min-width: 0; margin: 0 0 20px; padding: 16px; scroll-margin-top: var(--site-header-space, 80px); }
[data-home-layout] > .rs-home { order: 210; }
.rs-home h2 { margin: 0; color: var(--rs-ink); font-size: clamp(19px, 3vw, 24px); font-weight: 650; line-height: 1.15; }
.rs-home .rs-rotation { margin-block: 8px 12px; }
.rs-home-note { margin: 8px 0 0; color: var(--rs-muted); font-size: 13px; }
html[data-miniapp="true"] .rs-home { margin: 0; }

.rs-detail { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: start; gap: 16px; }
.rs-detail-art { aspect-ratio: 1.55; border-radius: 16px; }
.rs-detail-cover { aspect-ratio: 1.22; }
.rs-detail-cover img { transform: none; object-fit: contain; }
.rs-detail-dlc {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  gap: clamp(16px, 3vw, 40px);
  padding: clamp(12px, 2.5vw, 24px);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
}
.rs-detail-dlc .rs-detail-art { aspect-ratio: 1.24; }
.rs-detail-dlc .rs-detail-panel { padding: clamp(6px, 1.5vw, 20px); border: 0; }
.rs-detail-dlc .rs-detail-base { margin-top: 8px; line-height: 1.5; }
.rs-detail-panel { min-width: 0; padding: clamp(16px, 2.5vw, 24px); border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.rs-detail h1 { overflow-wrap: anywhere; }
.rs-detail-type { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: var(--muted); font-size: 13px; font-weight: 600; }
.rs-detail-base { margin: 4px 0 0; color: var(--muted); }
.rs-detail-price {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 16px;
  max-width: 440px;
  margin-top: 20px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
}
.rs-detail-price span { color: var(--muted); font-size: 13px; }
.rs-detail-price strong { font-size: clamp(19px, 3vw, 24px); font-weight: 650; white-space: nowrap; font-variant-numeric: tabular-nums; }
.rs-detail-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.rs-buy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease;
}
.rs-buy:hover { background: #1d4ed8; color: #fff; }
.rs-buy i { flex: 0 0 auto; font-size: 14px; }
.rs-buy-compact { display: none; }
.rs-buy:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; }
.rs-buy-secondary { border-color: var(--line); background: var(--surface-soft); color: var(--text); }
.rs-buy-secondary:hover { border-color: var(--line-strong); background: var(--primary-soft); color: var(--text); }
.rs-muted { margin: 8px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.rs-price-note { margin-top: 12px; max-width: 56ch; }
.rs-price-note strong { font-weight: 600; }
.rs-dlc-purchase { margin-top: 20px; }
.rs-dlc-purchase .rs-detail-price { margin-top: 0; }
.rs-dlc-purchase .rs-detail-actions {
  display: inline-grid;
  grid-auto-flow: column;
  grid-auto-columns: max-content;
  max-width: 100%;
}
.rs-dlc-purchase .rs-buy { white-space: nowrap; }
.rs-dlc-purchase > .rs-muted:first-child { margin-top: 0; }
.rs-specs { margin: 16px 0 0; border-top: 1px solid var(--line); font-size: 13px; }
.rs-specs div { display: flex; gap: 12px; justify-content: space-between; padding-block: 8px; border-bottom: 1px solid var(--line); }
.rs-specs dt { color: var(--muted); }
.rs-specs dd { margin: 0; text-align: end; overflow-wrap: anywhere; }
.rs-specs a { color: var(--primary-dark); }
.rs-related { margin-top: 20px; }
.rs-related .skin-related-heading { margin-bottom: 12px; }
.rs-related-track .rs-card { flex: 0 0 clamp(136px, 22%, 236px); scroll-snap-align: start; }
.rs-related-track { padding-bottom: 8px; }
.steam-search-results { margin-block: 0 16px; }
.steam-search-results h2 { margin: 0 0 12px; font-size: 19px; font-weight: 650; }

body.rs-topup-open { overflow: hidden; }
.rs-topup-dialog:not([open]) { display: none; }
.catalog-page.rs-topup-dialog {
  width: min(940px, calc(100% - 24px));
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: 20px;
  overflow: visible;
  background: transparent;
  color: var(--text);
}
.rs-topup-dialog::backdrop { background: rgb(15 23 42 / 65%); }
.rs-topup-dialog .hero-grid { margin: 0; }
.catalog-page.rs-topup-dialog #steam-topup.steam-widget {
  margin: 0;
  max-height: calc(100vh - 24px);
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.rs-topup-dialog .steam-widget-badge { display: none; }
.rs-topup-close {
  display: grid;
  place-items: center;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
  color: var(--text);
  cursor: pointer;
  font-size: 16px;
  transition: background-color 150ms ease, border-color 150ms ease;
}
.rs-topup-close:hover { background: var(--primary-soft); border-color: var(--line-strong); }
.rs-topup-close:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

.product-wrap.rust-dlc-detail .product-page .product-visual { display: grid; place-items: center; aspect-ratio: 1.8; min-height: 0; border: 1px solid var(--line); border-radius: 16px; background: var(--surface-soft); }
.product-wrap.rust-dlc-detail .product-visual [data-gallery-main] { width: 100%; height: 100%; max-height: 100%; object-fit: contain; }
.product-wrap.rust-dlc-detail .product-gallery-thumbs { gap: 8px; }
.product-wrap.rust-dlc-detail .product-gallery-thumb { border-radius: 8px; }

@media (max-width: 1120px) {
  .rs-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .rs-grid-native { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .rs-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 690px) {
  .rs-page { padding-block: 12px 32px; }
  .rs-shop { padding: 12px; }
  .rs-head { align-items: flex-start; flex-direction: column; gap: 8px; margin-bottom: 12px; }
  .rs-head .rs-rotation { padding: 4px 8px; }
  .rs-toolbar { align-items: stretch; flex-direction: column; }
  .rs-filters { width: 100%; }
  .rs-search input { font-size: 16px; }
  .rs-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .rs-card-info { min-height: 52px; padding: 8px; }
  .rs-card-info :is(strong, h3) { font-size: 13px; }
  .rs-detail { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .rs-detail-art { aspect-ratio: 1.7; }
  .rs-detail-cover { aspect-ratio: 1.44; }
  .rs-detail-dlc { gap: 16px; }
  .rs-detail-dlc .rs-detail-art { width: 100%; height: clamp(184px, 58vw, 264px); aspect-ratio: auto; }
  .rs-detail-dlc .rs-detail-panel { padding: 0 2px 2px; }
  .rs-detail-dlc h1 { font-size: clamp(24px, 6.5vw, 30px); }
  .rs-dlc-purchase { margin-top: 16px; }
  .rs-dlc-purchase .rs-detail-price { flex-wrap: nowrap; gap: 8px; padding: 8px 10px; }
  .rs-dlc-purchase .rs-detail-price span { min-width: 0; }
  .rs-dlc-purchase .rs-detail-price strong { flex: 0 0 auto; }
  .rs-dlc-purchase .rs-detail-actions { display: grid; grid-auto-columns: minmax(max-content, 1fr); }
  .rs-detail-price { margin-top: 16px; }
}
@media (max-width: 480px) {
  .rs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 370px) {
  .rs-buy { gap: 6px; padding-inline: 10px; font-size: 12px; }
  .rs-buy-wide { display: none; }
  .rs-buy-compact { display: inline; }
}
@media (max-width: 400px), (min-width: 691px) and (max-width: 850px) {
  .rs-dlc-purchase .rs-buy { gap: 6px; padding-inline: 8px; font-size: 12px; }
  .rs-dlc-purchase .rs-buy i { flex: 0 0 1em; min-block-size: 1em; text-align: center; }
  .rs-dlc-purchase .rs-buy-wide { display: none; }
  .rs-dlc-purchase .rs-buy-compact { display: inline; }
}
.rs-grid-weekly {
  grid-template: repeat(2, auto) / none;
  grid-auto-flow: column;
  grid-auto-columns: minmax(132px, calc((100% - 72px) / 7));
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
}
.rs-grid-weekly .rs-card { scroll-snap-align: start; }
.rs-grid-weekly .rs-card-media { aspect-ratio: 1.4; }
@media (max-width: 690px) {
  .rs-grid-weekly {
    grid-template-rows: auto;
    grid-auto-columns: clamp(128px, 43%, 188px);
    padding-block-end: 8px;
    scroll-snap-type: x mandatory;
  }
  .rs-grid-weekly .rs-card-info { align-items: flex-start; }
  .rs-grid-weekly .rs-card-arrow { align-self: center; }
}
@media (prefers-reduced-motion: reduce) {
  .rs-card, .rs-card-media img, .rs-card-arrow, .rs-buy { transition: none; }
}
