/* Палитра модуля */

.punish-feed {
  --punish-ban: #ff6b7a;
  --punish-mute: #e8b15a;
  --punish-gag: #5ab4e0;
  --punish-silence: #b48cf0;
  --punish-cs2: #7B9CFF;
  --punish-csgo: #D58613;
  --punish-expired: var(--text-default);
  --punish-kind: var(--text-default);
}

/* Контейнер ленты */

.punish-feed {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  width: 100%;
  max-width: 1366px;
  margin-inline: auto;
  margin-bottom: 0.4rem;
  display: flex;
  flex-direction: column;
  background: var(--card);
  border-radius: var(--br-16);
}

.punish-feed .card-header {
  padding: 1rem 1rem 0;
}

.punish-feed .card-container {
  padding: 0.5rem 1rem 1rem;
}

.punish-feed__empty {
  padding: 0.9rem 0;
  color: var(--text-default);
  text-align: center;
  opacity: 0.65;
}

.punish-feed .badge {
  width: 100%;
  padding-top: 0;
  padding-right: 0;
  padding-left: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.punish-feed__title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  margin: 0;
  padding: 0.5rem 0.5rem 0.5rem 0.8rem;
  color: var(--text-custom);
  font-size: inherit;
  font-weight: var(--font-weight-5);
  background-color: var(--transparent-2-w);
  border-radius: var(--br-8);
}

.punish-feed__title > span:first-child {
  white-space: nowrap;
}

.punish-feed__nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.punish-feed__total-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  padding: 0 0.45rem;
  box-sizing: border-box;
  color: var(--text-default);
  background: var(--input-form);
  border: 1px solid var(--transparent-3-w);
  border-radius: var(--br-8);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-6);
}

.punish-feed__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  color: var(--text-default);
  background: var(--input-form);
  border: 1px solid var(--transparent-3-w);
  border-radius: var(--br-8);
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.2s ease, background 0.2s ease;
}

.punish-feed__arrow svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.punish-feed__settings {
  box-sizing: border-box;
  flex: 0 0 28px;
}

/* Иконка шестерёнки квадратная, а шеврон узкий — выравниваем по видимому размеру. */
.punish-feed__settings svg {
  width: 12px;
  height: 12px;
}

.punish-feed__arrow:hover {
  opacity: 1;
  background: var(--span-low);
  color: var(--span);
}

.punish-feed__arrow:disabled {
  opacity: 0.28;
  cursor: default;
  pointer-events: none;
}

.punish-feed__viewport {
  position: relative;
  overflow: hidden;
}

.punish-feed__fade {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 10002;
  width: 72px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.punish-feed__fade--left {
  left: 0;
  background: linear-gradient(90deg, var(--card) 0%, var(--card) 18%, transparent 100%);
}

.punish-feed__fade--right {
  right: 0;
  background: linear-gradient(270deg, var(--card) 0%, var(--card) 18%, transparent 100%);
}

.punish-feed__viewport.has-left .punish-feed__fade--left,
.punish-feed__viewport.has-right .punish-feed__fade--right {
  opacity: 1;
}

.punish-feed__track {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
  padding: 0.35rem 0;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 0.25rem;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.punish-feed__track::-webkit-scrollbar {
  display: none;
}

/* Карточка наказания */

.punish-tile {
  position: relative;
  z-index: 1;
  box-sizing: border-box;
  flex: 0 0 auto;
  width: 268px;
  min-height: 78px;
  padding: 0.55rem 0.55rem 0.5rem 0.5rem;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.55rem;
  overflow: hidden;
  scroll-snap-align: start;
  background: var(--input-form);
  border: 1px solid var(--transparent-3-w);
  border-radius: var(--br-12);
  opacity: 0.82;
  filter: saturate(0.92);
  transition: opacity 0.35s ease, filter 0.35s ease;
}

.punish-tile::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(90deg, color-mix(in srgb, var(--punish-kind) 30%, var(--input-form)) 0%, color-mix(in srgb, var(--punish-kind) 12%, var(--input-form)) 100%);
}

.punish-tile.has-bg {
  background: #12141a;
}

.punish-tile.has-bg::after {
  background: linear-gradient(
    90deg,
    color-mix(in srgb, var(--punish-kind) 32%, transparent) 0%,
    color-mix(in srgb, var(--input-form) 42%, transparent) 100%
  );
}

/* Личный фон профиля Steam (тот же виджет, что и на странице профиля) под цветным тонированием. */
.punish-tile__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.punish-tile__bg img,
.punish-tile__bg video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.55) saturate(0.95);
}

.punish-feed:hover .punish-tile:not(.is-focus) {
  opacity: 0.7;
  filter: saturate(0.85);
}

.punish-tile.is-focus {
  z-index: 2;
  opacity: 1 !important;
  filter: saturate(1) !important;
}

/* Аватар */

.punish-tile__portrait {
  position: relative;
  z-index: 2;
  display: block;
  flex: 0 0 auto;
  overflow: hidden;
  border: 2px solid color-mix(in srgb, var(--punish-kind) 75%, transparent);
  border-radius: var(--br-8);
}

.punish-tile__photo {
  display: block;
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #6b7180, #464b56);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: var(--br-8);
}

/* Текст: тип, ник, причина, дата */

.punish-tile__body {
  position: relative;
  z-index: 2;
  min-width: 0;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.12rem;
}

.punish-tile__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  width: 100%;
  min-width: 0;
}

.punish-tile__tags {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.35rem;
  min-width: 0;
  width: 100%;
}

.punish-tile__chips {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  flex: 0 0 auto;
  gap: 0.3rem;
}

.punish-feed:not(.is-hide-reason) .punish-tile__reason + .punish-tile__chips {
  margin-left: auto;
}

.punish-tile__kind,
.punish-tile__game,
.punish-tile__date {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 3px 8px;
  color: var(--punish-kind);
  background: color-mix(in srgb, var(--punish-kind) 22%, transparent);
  border: 1px solid color-mix(in srgb, var(--punish-kind) 50%, transparent);
  border-radius: var(--br-6);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-7);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.punish-tile__ico {
  width: 11px;
  height: 11px;
  flex: 0 0 auto;
  fill: currentColor;
}

.punish-tile__state {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.12rem;
  max-width: 100%;
  padding: 2px 1px;
  overflow: hidden;
  color: #f3d9a8;
  background: rgba(12, 14, 18, 0.78);
  border: 0;
  border-radius: 0 0 var(--br-8) var(--br-8);
  font-size: 8px;
  font-weight: var(--font-weight-7);
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0;
  white-space: nowrap;
}


.punish-tile.is-expired .punish-tile__photo {
  filter: grayscale(0.55) brightness(0.82);
}

.punish-tile--ban {
  --punish-kind: var(--punish-ban);
}

.punish-tile--mute {
  --punish-kind: var(--punish-mute);
}

.punish-tile--gag {
  --punish-kind: var(--punish-gag);
}

.punish-tile--silence {
  --punish-kind: var(--punish-mute);
}

.punish-tile__kind--ban {
  --punish-kind: var(--punish-ban);
}

.punish-tile__kind--mute {
  --punish-kind: var(--punish-mute);
}

.punish-tile__kind--gag {
  --punish-kind: var(--punish-gag);
}

.punish-tile__game--cs2 {
  --punish-kind: var(--punish-cs2);
}

.punish-tile__game--csgo {
  --punish-kind: var(--punish-csgo);
}

.punish-tile__reason {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-secondary);
  font-size: var(--font-size-s);
}

.punish-feed.is-style-2 .punish-tile::after {
  display: none;
}

.punish-feed.is-hide-title .punish-feed__title > span:first-child {
  display: none;
}

.punish-feed.is-hide-kind .punish-tile__kind {
  display: none;
}

.punish-feed.is-hide-game .punish-tile__game {
  display: none;
}

.punish-feed.is-hide-reason .punish-tile__reason {
  display: none;
}

.punish-feed.is-hide-issued .punish-tile__date {
  display: none;
}

.punish-feed__settings {
  text-decoration: none;
  color: inherit;
}

.punish-tile__nick {
  min-width: 0;
  max-width: 100%;
  padding-right: 5.2rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-default);
  font-weight: var(--font-weight-6);
}

.punish-tile__date {
  position: absolute;
  top: 0.4rem;
  right: 0.4rem;
  z-index: 4;
  margin: 0;
  --punish-kind: var(--text-default);
  color: color-mix(in srgb, var(--text-default) 82%, transparent);
  background: color-mix(in srgb, var(--input-form) 28%, transparent);
  border-color: color-mix(in srgb, var(--transparent-3-w) 70%, transparent);
  text-transform: none;
  letter-spacing: 0.01em;
  font-weight: var(--font-weight-6);
}

/* Адаптив */

@media (max-width: 575px) {
  .punish-tile {
    width: 232px;
    min-height: 72px;
  }

  .punish-tile__photo {
    width: 42px;
    height: 42px;
  }
}
