@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@600;800&family=Nunito:wght@400;700;900&display=swap');

:root {
  --bg: #fff8f0;
  --text-dark: #3a2e3f;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  font-family: 'Nunito', 'Hiragino Kaku Gothic ProN', sans-serif;
  color: var(--text-dark);
  overflow-x: hidden;
  position: relative;
  padding: 40px 20px 60px;
}

/* soft floating color blobs for a playful background */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(10px);
  opacity: 0.35;
  z-index: 0;
  animation: float 9s ease-in-out infinite;
}

.blob-1 {
  width: 260px;
  height: 260px;
  background: #ff6b6b;
  top: -80px;
  left: -60px;
  animation-delay: 0s;
}

.blob-2 {
  width: 320px;
  height: 320px;
  background: #4ecdc4;
  bottom: -100px;
  right: -80px;
  animation-delay: 2s;
}

.blob-3 {
  width: 200px;
  height: 200px;
  background: #ffd93d;
  top: 40%;
  right: 10%;
  animation-delay: 4s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(20px, -30px) scale(1.08); }
}

.hub-header {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 600px;
  margin: 0 auto 40px;
}

.hub-header h1 {
  font-family: 'Baloo 2', sans-serif;
  font-size: 44px;
  font-weight: 800;
  margin: 0;
  color: var(--text-dark);
  text-shadow: 3px 3px 0 #ffd93d;
}

.hub-header h1 span {
  color: #ff6b6b;
  text-shadow: 3px 3px 0 #ffb4b4;
}

.subtitle {
  font-size: 16px;
  font-weight: 700;
  color: #6b5b6e;
  margin-top: 12px;
}

.game-grid {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.game-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #fff;
  border-radius: 24px;
  padding: 32px 20px;
  text-decoration: none;
  color: var(--text-dark);
  border: 4px solid var(--card-color, #ff6b6b);
  box-shadow: 0 8px 0 var(--card-color, #ff6b6b);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

a.game-card:hover,
a.game-card:active {
  transform: translateY(-4px);
  box-shadow: 0 12px 0 var(--card-color, #ff6b6b);
}

a.game-card:active {
  transform: translateY(2px);
  box-shadow: 0 4px 0 var(--card-color, #ff6b6b);
}

.game-card-empty {
  opacity: 0.55;
  border-style: dashed;
  box-shadow: none;
}

.card-icon {
  font-size: 52px;
  margin-bottom: 12px;
}

.game-card h2 {
  font-family: 'Baloo 2', sans-serif;
  font-size: 24px;
  margin: 0 0 8px;
}

.game-card p {
  font-size: 14px;
  font-weight: 700;
  color: #6b5b6e;
  margin: 0;
  line-height: 1.5;
}

.play-badge {
  display: inline-block;
  margin-top: 16px;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--card-color, #ff6b6b);
  color: #fff;
  font-weight: 900;
  font-size: 13px;
}

.hub-footer {
  position: relative;
  z-index: 1;
  text-align: center;
  margin-top: 50px;
  font-size: 14px;
  font-weight: 700;
  color: #9b8a9e;
}

.ad-slot {
  position: relative;
  z-index: 1;
  max-width: 728px;
  min-height: 90px;
  margin: 24px auto 0;
  padding: 8px;
  border: 2px dashed rgba(255, 107, 107, 0.4);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
}

.ad-slot-label {
  font-size: 12px;
  font-weight: 700;
  color: #b39a9a;
}

.ad-slot.hidden {
  display: none;
}

@media (max-width: 480px) {
  .hub-header h1 { font-size: 36px; }
}
