/* ── Hero / Cards Background ── */
.cards-background {
  position: fixed;
  top: 35%;
  left: 0;
  width: 100%;
  height: 18rem;
  transform: translateY(-50%);
  pointer-events: none;
  z-index: 0;
  opacity: 0.08;
  overflow: hidden;
}

.cards-track-wrapper {
  display: flex;
  width: max-content;
  animation: scrollCards 120s linear infinite;
  white-space: nowrap;
  gap: 4rem;
}

.cards-track {
  display: inline-block;
  white-space: nowrap;
  font-size: 14rem;
  user-select: none;
  line-height: 1;
}

@keyframes scrollCards {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ── Main layout ── */
main {
  position: relative;
  z-index: 1;
  flex-grow: 1;
  padding: 0 1.5rem 3rem;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
}

/* ── Hero content ── */
.hero-content {
  text-align: center;
  padding: 3.5rem 1rem 2.5rem;
}

.hero-content h1 {
  font-size: 3rem;
  margin: 0 0 0.75rem;
  line-height: 1.15;
  color: var(--text);
}

.hero-content h1 span { color: var(--accent); }

.hero-content p {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin: 0 0 1.75rem;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Categories section ── */
.categories-section {
  margin-top: 2rem;
  padding-bottom: 1rem;
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.category-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  text-decoration: none;
  color: var(--text);
  transition: border-color var(--transition), transform 0.15s, box-shadow var(--transition);
}

.category-tile:hover,
.category-tile:focus-visible {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 4px 18px rgba(97, 218, 251, 0.12);
  color: var(--text);
  outline: none;
}

.category-tile-emoji   { font-size: 2.4rem; line-height: 1; margin-bottom: 0.3rem; }
.category-tile-name    { font-size: 1.15rem; font-weight: 700; color: var(--accent); }
.category-tile-count   { font-size: 0.82rem; font-weight: 700; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.05em; }
.category-tile-tagline { font-size: 0.88rem; color: var(--text-muted); line-height: 1.4; margin-top: 0.2rem; }

/* ── Recently played ── */
.recent-section {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.section-label {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 1rem;
}

.small-grid {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .hero-content h1 { font-size: 2.1rem; }
  .hero-content p  { font-size: 1rem; }
  .hero-actions .btn-lg { width: 100%; }
  .categories-grid { grid-template-columns: 1fr 1fr; }
}
