/* Adam's Arcade — neon arcade theme */

:root {
  --bg:        #0a0a16;
  --surface:   #13132b;
  --surface-2: #1b1b3d;
  --border:    #2c2c5e;
  --text:      #e8e8ff;
  --text-mut:  #8b8bc0;
  --magenta:   #ff2d78;
  --cyan:      #2de2ff;
  --yellow:    #ffd24d;
  --radius:    16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 48px 20px 32px;
  overflow-x: hidden;
}

/* Faint scrolling grid backdrop */
.bg-grid {
  position: fixed;
  inset: -100% 0 0 0;
  background-image:
    linear-gradient(rgba(45, 226, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(45, 226, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  animation: grid-drift 60s linear infinite;
  pointer-events: none;
  z-index: 0;
}

@keyframes grid-drift {
  from { transform: translateY(0); }
  to   { transform: translateY(48px); }
}

@media (prefers-reduced-motion: reduce) {
  .bg-grid { animation: none; }
}

header, main, footer { position: relative; z-index: 1; }

/* Header */
.site-header { text-align: center; margin-bottom: 48px; }

.logo-mark {
  display: inline-block;
  filter: drop-shadow(0 0 14px rgba(255, 45, 120, 0.45));
  margin-bottom: 14px;
}

.site-title {
  font-size: clamp(2rem, 6vw, 3.4rem);
  font-weight: 900;
  letter-spacing: 0.14em;
  text-shadow: 0 0 24px rgba(45, 226, 255, 0.35);
}

.site-title span {
  color: transparent;
  background: linear-gradient(100deg, var(--magenta), var(--cyan));
  background-clip: text;
  -webkit-background-clip: text;
}

.site-tagline {
  margin-top: 10px;
  color: var(--text-mut);
  font-size: 1.05rem;
}

/* Game grid — grows naturally as more cards are added */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 380px));
  justify-content: center;
  gap: 28px;
  width: 100%;
  max-width: 1240px;
}

.game-card {
  display: flex;
  flex-direction: column;
  background: linear-gradient(160deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

a.game-card:hover,
a.game-card:focus-visible {
  transform: translateY(-6px);
  border-color: var(--cyan);
  box-shadow:
    0 0 0 1px var(--cyan),
    0 12px 40px rgba(45, 226, 255, 0.18),
    0 0 30px rgba(255, 45, 120, 0.10);
  outline: none;
}

.card-art {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 190px;
  background:
    radial-gradient(circle at 50% 60%, rgba(45, 226, 255, 0.14), transparent 65%),
    #0d0d20;
  border-bottom: 1px solid var(--border);
}

.card-art img {
  width: 128px;
  height: 128px;
  border-radius: 24px;
  filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.6));
  transition: transform 0.25s ease;
}

a.game-card:hover .card-art img { transform: scale(1.07); }

.card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 20px 22px 22px;
  flex: 1;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--cyan);
}

.card-desc {
  color: var(--text-mut);
  font-size: 0.95rem;
  line-height: 1.5;
  flex: 1;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.card-tags li {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--yellow);
  background: rgba(255, 210, 77, 0.10);
  border: 1px solid rgba(255, 210, 77, 0.35);
  border-radius: 999px;
  padding: 3px 10px;
}

.card-cta {
  margin-top: 4px;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--magenta);
}

a.game-card:hover .card-cta { text-shadow: 0 0 12px rgba(255, 45, 120, 0.7); }

/* Coming-soon placeholder card */
.coming-soon { opacity: 0.55; border-style: dashed; }

.coming-soon .mystery {
  font-size: 4.5rem;
  font-weight: 900;
  color: var(--border);
  text-shadow: 0 0 18px rgba(45, 226, 255, 0.25);
}

.coming-soon .card-title { color: var(--text-mut); }

/* Card entrance animation (applied by app.js; hidden state only when JS is on) */
.js .game-card { opacity: 0; transform: translateY(18px); }

.js .game-card.revealed {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s ease, transform 0.5s ease,
              border-color 0.25s ease, box-shadow 0.25s ease;
}

a.game-card.revealed:hover { transform: translateY(-6px); }

@media (prefers-reduced-motion: reduce) {
  .js .game-card { opacity: 1; transform: none; transition: none; }
}

/* Footer */
.site-footer {
  margin-top: 56px;
  text-align: center;
  color: var(--text-mut);
  font-size: 0.85rem;
  line-height: 1.8;
}

.site-footer a { color: var(--cyan); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
