/* Главная: витрина → пополнение Steam → каталог. */

/* ── Витрина: сразу товар ── */
.showcase-wrap { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.showcase-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; }
.showcase-head h1 { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.2rem); }
.showcase-head p { color: var(--muted); font-size: var(--fs-sm); max-width: 52ch; }
.showcase { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 16px; }
.spot--lead {
  position: relative; display: grid; grid-template-columns: minmax(170px, 0.85fr) minmax(0, 1fr); gap: 28px; align-items: center;
  min-height: 420px; padding: 26px; border-radius: var(--r-xl); overflow: hidden; isolation: isolate;
  background: var(--surface); color: var(--text); border: 1px solid var(--line);
}
.spot__bg { position: absolute; inset: -40px; z-index: -1; background: var(--cover) center / cover; filter: blur(36px) saturate(1.5); opacity: 0.9; }
.spot--lead::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(12, 10, 24, 0.35), rgba(12, 10, 24, 0.85) 55%); }
.spot__cover { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: var(--r-md); box-shadow: 0 30px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08); }
.spot__body { display: grid; gap: 10px; align-content: end; padding-bottom: 6px; }
.spot__tag { justify-self: start; padding: 4px 10px; border-radius: 6px; background: var(--violet-soft); color: #c7beff; font-size: var(--fs-xs); font-weight: 600; }
.spot__title { font-family: var(--font-display); font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.6rem); line-height: 1.02; }
.spot__meta { color: var(--muted); font-size: var(--fs-sm); }
.spot__lead { color: var(--text-2, #cfcae6); font-size: var(--fs-sm); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.spot__buy { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 8px; }
.spot__buy .price { font-family: var(--font-display); font-size: 1.6rem; color: var(--accent); font-variant-numeric: tabular-nums; }
.hits { display: grid; grid-template-rows: auto 1fr; gap: 12px; min-width: 0; }
.hits__title { font-size: var(--fs-lg, 1.15rem); }
.hits__list { display: grid; grid-auto-rows: 1fr; gap: 10px; }
.hit { display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; align-items: center; gap: 16px; padding: 10px 16px 10px 10px; border-radius: var(--r-md); background: var(--surface); border: 1px solid var(--line); color: var(--text); transition: border-color var(--t-fast); }
.hit:hover, .hit:focus-visible { border-color: var(--accent); }
.hit__cover { width: 76px; aspect-ratio: 2 / 3; height: auto; object-fit: contain; border-radius: 8px; background: var(--bg-2); }
.hit__body { display: grid; gap: 3px; min-width: 0; }
.hit__name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hit__meta { color: var(--faint); font-size: var(--fs-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hit .game__price { white-space: nowrap; }
.skeleton.spot--lead { min-height: 420px; }
.hits .skeleton { min-height: 120px; border-radius: var(--r-md); }

/* ── Пополнение Steam: одна строка ── */
.steam { margin-top: 28px; display: grid; gap: 14px; padding: 20px 22px; border-radius: var(--r-xl); background: linear-gradient(120deg, rgba(108, 92, 231, 0.16), rgba(23, 20, 45, 0.9) 45%); border: 1px solid var(--line-strong); }
.steam__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.steam__head h2 { font-size: var(--fs-xl); }
.steam__tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--bg-2); }
.steam__tab { height: 34px; padding: 0 14px; border: 0; border-radius: 9px; background: none; color: var(--muted); font: inherit; font-size: var(--fs-sm); font-weight: 600; cursor: pointer; }
.steam__tab[aria-selected="true"] { background: var(--accent); color: var(--accent-ink); }
.steam__form { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr) minmax(0, 1fr) auto; gap: 14px; align-items: end; }
.steam__sum { display: grid; gap: 2px; }
.steam__total { font-family: var(--font-display); font-size: 1.7rem; color: var(--accent); line-height: 1.1; font-variant-numeric: tabular-nums; }
.steam__credit { color: var(--muted); font-size: var(--fs-xs); }
.steam__credit.is-error { color: var(--warn); }
.steam__form .btn { min-height: 52px; }
.steam__presets { display: flex; flex-wrap: wrap; gap: 6px; }
.steam__note { color: var(--warn); font-size: var(--fs-sm); }
.steam__note:empty { display: none; }

/* ── Каталог ── */
.catalog { margin-top: var(--section); display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; scroll-margin-top: calc(var(--header-h) + 12px); }
#steam { scroll-margin-top: calc(var(--header-h) + 12px); }
.catalog__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 14px; }
.catalog__head h2 { display: flex; align-items: baseline; gap: 12px; }
.catalog__count { font-family: var(--font); font-size: var(--fs-sm); font-weight: 500; color: var(--faint); }
.catalog__search { display: flex; align-items: center; gap: 10px; width: min(340px, 100%); height: 44px; padding: 0 14px; border-radius: var(--r-sm); background: var(--surface); border: 1px solid var(--line); color: var(--faint); }
.catalog__search:focus-within { border-color: var(--accent); }
.catalog__search svg { width: 17px; height: 17px; }
.catalog__search input { flex: 1; min-width: 0; border: 0; background: none; color: var(--text); font: inherit; outline: none; }
.catalog__bar { position: sticky; top: var(--header-h); z-index: 20; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; background: linear-gradient(var(--bg) 70%, transparent); }
.cats { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; min-width: 0; flex: 1 1 520px; }
.cats::-webkit-scrollbar { display: none; }
.cat { flex: none; display: inline-flex; align-items: center; gap: 7px; height: 38px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); font: inherit; font-size: var(--fs-sm); font-weight: 500; cursor: pointer; transition: color var(--t-fast), border-color var(--t-fast), background var(--t-fast); }
.cat span { color: var(--faint); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.cat:hover { color: var(--text); border-color: var(--line-strong); }
.cat[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.cat[aria-pressed="true"] span { color: rgba(18, 20, 10, 0.6); }
.catalog__tools { display: flex; align-items: center; gap: 8px; }
.price-range { display: inline-flex; align-items: center; gap: 6px; color: var(--faint); }
.price-range input, .sort { height: 38px; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-size: var(--fs-sm); }
.price-range input { width: 96px; }
.sort { padding-right: 30px; appearance: none; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a7a2cf' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center / 14px; cursor: pointer; }
.catalog__more { justify-self: center; margin-top: 10px; }
.catalog__empty { display: grid; justify-items: center; gap: 12px; padding: 40px 0; color: var(--muted); }

@media (max-width: 1000px) {
  .showcase { grid-template-columns: minmax(0, 1fr); }
  .steam__form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .steam__form .btn { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .spot--lead { grid-template-columns: 112px minmax(0, 1fr); min-height: 0; padding: 16px; gap: 16px; align-items: center; }
  .spot__title { font-size: 1.4rem; }
  .spot__lead { display: none; }
  .spot__buy .price { font-size: 1.25rem; }
  .spot__buy .btn { min-height: 44px; padding: 0 16px; font-size: var(--fs-sm); }
  .hits__list { grid-auto-flow: column; grid-auto-columns: 38%; grid-auto-rows: auto; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--gutter); scrollbar-width: none; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); }
  .hits__list::-webkit-scrollbar { display: none; }
  .hit { grid-template-columns: minmax(0, 1fr); align-items: start; gap: 8px; padding: 0; background: none; border: 0; scroll-snap-align: start; }
  .hit__cover { width: 100%; border-radius: var(--r-md); }
  .hit__meta { display: none; }
  .steam { padding: 16px; }
  .steam__sum { grid-column: 1 / -1; }
  .catalog__bar { position: static; }
  .catalog__tools { width: 100%; }
  .price-range input { width: 82px; }
  .sort { flex: 1; }
}
