/* Modern Table Layout */
.games-table {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.table-row {
  display: grid;
  grid-template-columns: 100px 3.5fr 0.8fr 0.8fr 1.5fr;
  gap: 1rem;
  padding: 1rem;
  background-color: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-top: none;
  transition: all 0.2s;
  align-items: center;

  @media (max-width: 1024px) {
    grid-template-columns: 80px 2fr 0.8fr 0.8fr 1.5fr;
    gap: 0.75rem;
  }

  @media (max-width: 768px) {
    grid-template-columns: auto 1fr 1fr;
    gap: 0.25rem 0.75rem;
    padding: 0.5rem;

    .rating-label {
      display: none;
    }
  }
}

.table-row:first-child {
  border-top: 1px solid var(--border);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.table-row:last-child {
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.table-row:first-child:last-child {
  border-radius: var(--radius-lg);
}

.table-row:hover {
  background-color: var(--bg-float);
  border-color: var(--blue);
  transform: translateX(4px);
  box-shadow: -4px 0 0 var(--blue);
}

.game-row-link {
  text-decoration: none !important;
  color: inherit;
}

.game-row-link:hover {
  text-decoration: none !important;
}

.game-row-link:hover * {
  text-decoration: none !important;
}

.table-cell {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-self: center;
}

.cell-cover {
  justify-content: center;

  @media (max-width: 768px) {
    grid-column: 1;
    grid-row: 1 / span 2;
    justify-content: flex-start;
    align-self: start;
  }
}

.table-game-cover {
  width: 68px;
  height: 90px;
  object-fit: cover;
  border-radius: var(--radius-md);

  @media (max-width: 1024px) {
    width: 60px;
    height: 80px;
  }
}

.table-game-cover-placeholder {
  width: 68px;
  height: 90px;
  background-color: var(--bg-primary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;

  @media (max-width: 1024px) {
    width: 60px;
    height: 80px;
  }
}

.cell-title {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.1rem;

  @media (max-width: 768px) {
    grid-column: 2 / span 2;
  }
}

.cell-difficulty {
  justify-content: center;

  @media (max-width: 768px) {
    grid-column: 2;
    justify-content: flex-start;
    font-size: 0.85rem;
  }
}

.cell-rating {
  justify-content: center;

  @media (max-width: 768px) {
    grid-column: 3;
    justify-content: flex-start;
    font-size: 0.85rem;
  }
}

.cell-learning-grid {
  justify-content: center;

  @media (max-width: 768px) {
    display: none;
  }
}

.learning-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 0.5rem;
  width: 100%
}

.title-primary {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--fg-primary);

  @media (max-width: 1024px) {
    font-size: 1rem;
  }
}

.title-year {
  font-weight: 400;
  color: var(--fg-secondary);
}

.title-secondary {
  font-size: 0.875rem;
  color: var(--fg-secondary);
}

.platforms-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}


.badge-positive {
  background-color: rgba(158, 206, 106, 0.15);
  color: var(--success);
  border: 1px solid rgba(158, 206, 106, 0.3);
}

.badge-negative {
  background-color: rgba(247, 118, 142, 0.15);
  color: var(--danger);
  border: 1px solid rgba(247, 118, 142, 0.3);
}

.badge-neutral {
  background-color: rgba(255, 184, 108, 0.15);
  color: rgb(196, 120, 0);
  border: 1px solid rgba(255, 184, 108, 0.3);
}

.badge-platform {
  background-color: rgba(125, 207, 255, 0.15);
  color: var(--cyan);
  border: 1px solid rgba(125, 207, 255, 0.3);
}

.badge-genre {
  background-color: rgba(169, 177, 214, 0.15);
  color: var(--purple);
  border: 1px solid rgba(169, 177, 214, 0.3);
}

.badge {
  @media (max-width: 1024px) {
    font-size: 0.625rem;
    padding: 0.2rem 0.4rem;
  }
}

.user-games-table-row {
  grid-template-columns: 100px 3fr 0.8fr 0.8fr;

  @media (max-width: 768px) {
    grid-template-columns: auto 1fr 1fr;
  }
}

.cover-wrapper {
  position: relative;
  display: inline-block;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.row-status-badge {
  position: absolute;
  top: 0;
  left: 0;
  width: 36px;
  height: 36px;
  clip-path: polygon(0 0, 100% 0, 0 100%);
}

.row-status-badge svg {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 14px;
  height: 14px;
}

.row-status-badge.badge-background { background: var(--bg-secondary); }
