.steam-cd-key-page {
  --cdkey-radius: var(--sf-header-radius, 4px);
}

.steam-cd-key-page.cdkey-page {
  padding: 0 0 52px;
}

.steam-cd-key-page .cdkey-shell {
  width: min(1540px, calc(100% - 28px));
  margin: 0 auto;
  display: grid;
  gap: 0;
}

.cover.steam-cd-key-cover {
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  overflow: hidden;
  border-radius: var(--cdkey-radius);
  border: 0;
  background: #08152f;
  box-shadow: 0 24px 48px rgba(2, 6, 16, 0.28);
}

.cover.steam-cd-key-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(3, 7, 16, 0.82) 0%, rgba(3, 7, 16, 0.36) 18%, rgba(3, 7, 16, 0.12) 42%, rgba(3, 7, 16, 0.52) 76%, rgba(0, 0, 0, 1) 100%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.42) 0%, rgba(0, 0, 0, 0.08) 18%, rgba(0, 0, 0, 0.08) 82%, rgba(0, 0, 0, 0.42) 100%);
  pointer-events: none;
  z-index: 1;
}

section.cover.steam-cd-key-cover .cdkey-hero-inner {
  width: 100%;
}

.cdkey-hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding: 88px 24px 64px;
}

.cdkey-hero-copy {
  position: relative;
  width: 100%;
  max-width: 980px;
  display: grid;
  justify-items: center;
  gap: 14px;
  text-align: center;
  padding: 18px 24px;
  border-radius: var(--cdkey-radius);
  margin: 0 auto;
}

.cdkey-hero-copy > div {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
}

.cdkey-hero-copy::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100vw;
  top: -140px;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(5, 12, 28, 0.7) 0%, rgba(5, 12, 28, 0.42) 36%, rgba(5, 12, 28, 0.18) 72%, rgba(5, 12, 28, 0) 100%);
  pointer-events: none;
}

.cdkey-hero-copy > * {
  position: relative;
  z-index: 1;
}

.cdkey-hero-image {
  display: block;
  width: 100%;
  height: auto;
  min-height: 670px;
  object-fit: cover;
  object-position: center center;
}

.cdkey-hero-icon {
  width: 58px;
  height: 58px;
  border-radius: 999px;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  box-shadow: none;
}

.cdkey-hero-icon img {
  width: 54px;
  height: 54px;
  object-fit: contain;
  display: block;
  filter: brightness(0) invert(1);
}

.cdkey-hero-title {
  margin: 0;
  color: #fff;
  font-size: clamp(42px, 4.6vw, 62px);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.03em;
  text-shadow: 0 10px 32px rgba(0, 0, 0, 0.34);
}

.cdkey-hero-description {
  max-width: 760px;
  margin: 0 auto;
  color: rgba(246, 249, 255, 0.94);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  text-shadow: 0 6px 18px rgba(0, 0, 0, 0.36);
}

.steam-cd-key-page .filter-box,
section.cover.steam-cd-key-cover .filter-box {
  width: 100%;
  margin: 0;
  border-radius: var(--cdkey-radius);
}

.cover.steam-cd-key-cover .cdkey-hero-search {
  width: 100% !important;
  max-width: 560px;
  margin: 18px auto 0;
}

.cdkey-search,
section.cover.steam-cd-key-cover .search-box {
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(34, 40, 56, 0.74);
  padding: 8px;
  border-radius: var(--cdkey-radius);
  box-shadow: 0 18px 44px rgba(4, 10, 24, 0.22);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
}

.cdkey-search form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 54px;
  gap: 10px;
  align-items: center;
}

.cdkey-search input {
  width: 100%;
  min-height: 40px;
  border-radius: var(--cdkey-radius);
  border: 0;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  padding: 0 18px;
  outline: none;
}

.cdkey-search input::placeholder {
  color: rgba(225, 233, 250, 0.82);
}

.cdkey-search button {
  min-height: 40px;
  border-radius: var(--cdkey-radius);
  border: 0;
  background: rgba(255, 255, 255, 0.2);
  color: #f4f7ff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.cdkey-search button svg {
  width: 20px;
  height: 20px;
}

.cdkey-platforms {
  width: min(620px, calc(100% - 48px)) !important;
  max-width: min(620px, calc(100% - 48px));
  margin: 0 auto;
  padding: 6px;
  background: rgba(20, 24, 35, 0.74);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--cdkey-radius);
  display: grid;
  grid-template-columns: repeat(var(--cdkey-platform-count, 4), minmax(0, 1fr));
  align-items: stretch;
  gap: 10px;
}

.cdkey-platform {
  min-height: 54px;
  border-radius: var(--cdkey-radius);
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: rgba(255, 255, 255, 0.06);
  text-decoration: none;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 5px 4px;
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  line-height: 1.2;
}

.cdkey-platform.is-active {
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.cdkey-platform-icon {
  width: 20px;
  height: 20px;
  border-radius: 0;
  background: transparent;
  flex: 0 0 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  overflow: hidden;
  margin-inline: auto;
  transform: none;
}

.cdkey-platform > span:last-child {
  width: 100%;
  display: block;
  text-align: center;
}

.cdkey-platform-icon img {
  width: 18px;
  height: 18px;
  object-fit: contain;
  display: block;
  filter: brightness(0) invert(1);
  margin-inline: auto;
}

.steam-cd-key-products,
section.category.steam-cd-key-products {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  margin-top: -18px;
  position: relative;
  z-index: 3;
  padding: 0 0 0;
}

.post-item.product-card {
  border-radius: var(--cdkey-radius);
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: #1d1d20;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 12px;
  height: auto;
  min-height: 0;
}

.cdkey-card-media {
  position: relative;
  aspect-ratio: 1 / 1;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  border-radius: var(--cdkey-radius);
}

.cdkey-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cdkey-card-media > a {
  display: block;
  width: 100%;
  height: 100%;
}

.cdkey-card-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 10, 15, 0.02) 18%, rgba(8, 10, 15, 0.18) 44%, rgba(8, 10, 15, 0.78) 100%);
  pointer-events: none;
}

.cdkey-card-media::before {
  content: '';
  position: absolute;
  right: -26px;
  bottom: -18px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 10px solid rgba(255, 255, 255, 0.12);
  opacity: 0.32;
  z-index: 1;
  pointer-events: none;
}

.cdkey-card-platform {
  position: absolute;
  top: 12px;
  left: 12px;
  width: 38px;
  height: 38px;
  border-radius: var(--cdkey-radius);
  background: rgba(20, 24, 35, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.16);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  overflow: hidden;
}

.cdkey-card-platform img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.cdkey-card-discount {
  position: absolute;
  top: 12px;
  right: 12px;
  min-width: 42px;
  height: 28px;
  border-radius: 10px;
  background: linear-gradient(180deg, #19db67 0%, #0db955 100%);
  color: #fff;
  font-size: 14px;
  font-weight: 900;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  box-shadow: 0 10px 20px rgba(7, 92, 40, 0.28);
}

.cdkey-card-poster-copy {
  position: absolute;
  inset: auto 16px 16px;
  z-index: 2;
  text-align: center;
  display: grid;
  gap: 4px;
  justify-items: center;
}

.cdkey-card-poster-type {
  color: rgba(255, 255, 255, 0.96);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.05;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.44);
}

.cdkey-card-poster-title {
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.12;
  text-shadow: 0 8px 24px rgba(0, 0, 0, 0.44);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.cdkey-card-copy {
  padding: 10px 4px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cdkey-stars {
  color: #ffb326;
  font-size: 13px;
  letter-spacing: 1px;
  text-align: center;
  line-height: 1;
}

.cdkey-title {
  margin: 0;
  min-height: 0;
  color: #fff;
  font-size: 16px;
  line-height: 1.32;
  font-weight: 800;
  text-align: center;
  letter-spacing: -0.01em;
  white-space: normal;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.cdkey-subtitle {
  color: rgba(255, 255, 255, 0.66);
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  min-height: 18px;
  line-height: 1.3;
  display: none;
}

.cdkey-pricing {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding-bottom: 2px;
}

.cdkey-old {
  color: rgba(255, 255, 255, 0.32);
  font-size: 12px;
  font-weight: 700;
  text-decoration: line-through;
}

.cdkey-price {
  color: #ffb326;
  font-size: 16px;
  font-weight: 900;
}

.cdkey-actions {
  margin: 6px 0 2px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  gap: 8px;
}

.cdkey-qty-wrap {
  min-height: 48px;
  border-radius: var(--cdkey-radius);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(24, 28, 38, 0.96);
  display: grid;
  grid-template-columns: 38px 1fr 38px;
  align-items: center;
}

.cdkey-qty {
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  text-align: center;
  line-height: 1;
  -webkit-user-select: none;
  user-select: none;
}

.cdkey-qty-btn,
.cdkey-buy-btn {
  width: 100%;
  height: 100%;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.82);
  font-size: 16px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.cdkey-buy-btn {
  min-height: 48px;
  border-radius: var(--cdkey-radius);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(24, 28, 38, 0.96);
}

.cdkey-buy-btn.is-disabled {
  grid-column: 1 / -1;
  pointer-events: none;
  background: rgba(72, 76, 86, 0.92);
  color: rgba(255, 255, 255, 0.82);
  font-weight: 800;
}

.cdkey-buy-btn svg {
  width: 18px;
  height: 18px;
}

.cdkey-empty {
  border-radius: var(--cdkey-radius);
  border: 1px dashed rgba(255, 255, 255, 0.2);
  background: rgba(11, 14, 22, 0.55);
  min-height: 220px;
  display: grid;
  place-items: center;
  text-align: center;
  color: rgba(255, 255, 255, 0.76);
  padding: 20px;
}

.cdkey-empty strong {
  display: block;
  font-size: 24px;
  color: #fff;
  margin-bottom: 8px;
}

.cdkey-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 8px 0 4px;
}

.cdkey-page-link {
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--cdkey-radius);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(38, 44, 62, 0.92);
  color: #e8eeff;
  font-weight: 700;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.cdkey-page-link.is-active {
  border-color: rgba(123, 153, 255, 0.78);
  background: rgba(74, 98, 163, 0.86);
  color: #fff;
}

.cdkey-page-link.is-disabled {
  pointer-events: none;
  opacity: 0.45;
}

@media (max-width: 1399.98px) {
  .steam-cd-key-products {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 1199.98px) {
  .steam-cd-key-products {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .cover.steam-cd-key-cover {
    min-height: 0;
  }

  .cdkey-hero-image {
    min-height: 620px;
  }

  .cdkey-platforms {
    width: min(560px, calc(100% - 40px)) !important;
    max-width: min(560px, calc(100% - 40px));
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .steam-cd-key-products {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .cdkey-hero-overlay {
    padding: 64px 20px 56px;
    gap: 20px;
  }

  .cdkey-hero-image {
    min-height: 580px;
  }

  .cdkey-hero-title {
    font-size: clamp(32px, 7vw, 46px);
  }

  .cdkey-hero-description {
    font-size: 14px;
  }

  .cdkey-title {
    font-size: 16px;
  }
}

@media (max-width: 767.98px) {
  .steam-cd-key-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .post-item.product-card {
    padding: 12px;
  }

  .cdkey-shell {
    width: calc(100% - 18px);
  }

  .cover.steam-cd-key-cover {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    min-height: 0;
  }

  .cdkey-hero-image {
    min-height: 500px;
  }

  .cdkey-hero-overlay {
    padding: 56px 16px 36px;
    gap: 16px;
  }

  .cover.steam-cd-key-cover .cdkey-hero-search,
  .cdkey-platforms {
    width: calc(100% - 24px) !important;
  }

  .cdkey-search,
  section.cover.steam-cd-key-cover .search-box {
    padding: 10px;
    border-radius: 12px;
  }

  .cdkey-search form {
    grid-template-columns: minmax(0, 1fr) 52px;
    gap: 10px;
  }

  .cdkey-search input,
  .cdkey-search button {
    min-height: 48px;
  }

  .cdkey-search input {
    font-size: 15px;
    padding: 0 14px;
  }

  .cdkey-hero-icon {
    width: 52px;
    height: 52px;
  }

  .cdkey-hero-icon img {
    width: 44px;
    height: 44px;
  }

  .cdkey-hero-title {
    font-size: 28px;
  }

  .cdkey-hero-description {
    font-size: 13px;
    line-height: 1.45;
  }

  .cdkey-platforms {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 10px;
    gap: 8px;
  }

  .steam-cd-key-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
  }

  .cdkey-title {
    min-height: 0;
    font-size: 14px;
    line-height: 1.35;
    white-space: normal;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .cdkey-qty {
    font-size: 16px;
  }

  .cdkey-price {
    font-size: 16px;
  }

  .cdkey-subtitle {
    font-size: 12px;
    min-height: 0;
  }
}
