.steam-games {
  --steam-row-hover: rgba(255, 255, 255, 0.56);
  --steam-row-active: rgba(255, 255, 255, 0.68);
  --steam-border: rgba(28, 34, 42, 0.12);
  --steam-text: #24272d;
  --steam-muted: #697386;
  --steam-accent: #168f7d;
  --steam-accent-soft: rgba(22, 143, 125, 0.14);
  --steam-row-shadow: 0 10px 24px rgba(22, 28, 38, 0.09);
  --steam-cover-bg: rgba(28, 34, 42, 0.08);

  padding: 0 1.5rem;
  color: var(--steam-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.steam-games__title {
  margin: 0 0 1.2rem;
  padding-bottom: 0.8rem;
  color: var(--steam-text);
  font-size: 1.4em;
  font-weight: 700;
}

.steam-games__list {
  overflow: hidden;
  border-top: 1px solid var(--steam-border);
  border-bottom: 1px solid var(--steam-border);
  background: transparent;
}

.steam-games__item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 72px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--steam-border);
  outline: none;
  transition: background-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.steam-games__item:last-child {
  border-bottom: 0;
}

.steam-games__item::before {
  position: absolute;
  inset: 10px auto 10px 0;
  width: 3px;
  border-radius: 999px;
  background: var(--steam-accent);
  content: "";
  opacity: 0;
  transform: scaleY(0.45);
  transition: opacity 180ms ease, transform 180ms ease;
}

.steam-games__item:hover,
.steam-games__item:focus-visible {
  z-index: 1;
  background: var(--steam-row-hover);
  box-shadow: var(--steam-row-shadow);
  transform: translateX(4px);
}

.steam-games__item:hover::before,
.steam-games__item:focus-visible::before {
  opacity: 1;
  transform: scaleY(1);
}

.steam-games__cover {
  width: 145px;
  aspect-ratio: 460 / 215;
  border-radius: 7px;
  overflow: hidden;
  flex: 0 0 auto;
  background: var(--steam-cover-bg);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.steam-games__cover img {
  display: block;
  width: 100%;
  height: 100%;
  margin: 0 !important;
  object-fit: cover;
  transition: filter 180ms ease, transform 220ms ease;
}

.steam-games__item:hover .steam-games__cover img,
.steam-games__item:focus-visible .steam-games__cover img {
  filter: saturate(1.08) contrast(1.04);
  transform: scale(1.035);
}

.steam-games__info {
  flex: 1 1 auto;
  min-width: 0;
}

.steam-games__name {
  margin: 0;
  overflow: hidden;
  color: var(--steam-text);
  font-size: 16px;
  font-weight: 650;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.steam-games__meta {
  margin-top: 3px;
  color: var(--steam-muted);
  font-size: 12px;
  line-height: 1.4;
}

.steam-games__time {
  min-width: 145px;
  flex: 0 0 auto;
  color: var(--steam-muted);
  font-size: 13px;
  line-height: 1.5;
  text-align: right;
}

.steam-games__time span {
  display: block;
}

.steam-games__recent {
  display: inline-block;
  color: var(--steam-accent);
  font-weight: 650;
}

.steam-games__recent::before {
  display: inline-block;
  width: 0.52em;
  height: 0.52em;
  margin-right: 0.45em;
  border-radius: 999px;
  background: var(--steam-accent);
  box-shadow: 0 0 0 5px var(--steam-accent-soft);
  content: "";
  vertical-align: 0.04em;
}

.steam-games__state {
  padding: 2rem;
  color: var(--steam-muted);
  font-size: 14px;
  text-align: center;
}

.steam-games__source {
  margin-top: 1rem;
  color: var(--steam-muted);
  font-size: 0.85em;
  text-align: right;
}

.steam-games__source a {
  color: var(--steam-muted);
  text-decoration: none;
  transition: color 160ms ease;
}

.steam-games__source a:hover {
  color: var(--steam-accent);
}

body.theme-dark .steam-games,
html.theme-dark .steam-games,
.theme-dark .steam-games,
[data-theme="dark"] .steam-games,
[theme="dark"] .steam-games {
  --steam-row-hover: rgba(255, 255, 255, 0.075);
  --steam-row-active: rgba(255, 255, 255, 0.1);
  --steam-border: rgba(255, 255, 255, 0.09);
  --steam-text: #f2f4f7;
  --steam-muted: #b5bdc9;
  --steam-accent: #4fd1b8;
  --steam-accent-soft: rgba(79, 209, 184, 0.16);
  --steam-row-shadow: 0 12px 24px rgba(0, 0, 0, 0.22);
  --steam-cover-bg: rgba(255, 255, 255, 0.08);
}

body.theme-white .steam-games,
html.theme-white .steam-games,
.theme-white .steam-games,
body.theme-light .steam-games,
html.theme-light .steam-games,
.theme-light .steam-games,
body.theme-sunset .steam-games,
html.theme-sunset .steam-games,
.theme-sunset .steam-games,
[data-theme="white"] .steam-games,
[data-theme="light"] .steam-games,
[data-theme="sunset"] .steam-games,
[theme="white"] .steam-games,
[theme="light"] .steam-games,
[theme="sunset"] .steam-games {
  --steam-row-hover: rgba(255, 255, 255, 0.54);
  --steam-row-active: rgba(255, 255, 255, 0.66);
  --steam-border: rgba(32, 39, 50, 0.13);
  --steam-text: #20242a;
  --steam-muted: #5f6877;
  --steam-accent: #b65f2b;
  --steam-accent-soft: rgba(182, 95, 43, 0.14);
  --steam-row-shadow: 0 10px 24px rgba(46, 36, 28, 0.1);
  --steam-cover-bg: rgba(32, 39, 50, 0.08);
}

@media (max-width: 576px) {
  .steam-games {
    padding: 0 1rem;
  }

  .steam-games__item {
    gap: 12px;
    padding: 11px 12px;
  }

  .steam-games__cover {
    width: 126px;
  }

  .steam-games__info {
    display: none;
  }

  .steam-games__time {
    min-width: 118px;
    margin-left: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .steam-games__item,
  .steam-games__item::before,
  .steam-games__cover img,
  .steam-games__source a {
    transition: none;
  }

  .steam-games__item:hover,
  .steam-games__item:focus-visible {
    transform: none;
  }
}
