/* Página principal: bento de juegos. */
.home {
  min-height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.bento {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: minmax(210px, auto);
  gap: 20px;
  width: min(1200px, 100%);
  margin: 0 auto;
  padding: 12px clamp(16px, 3vw, 32px) 24px;
  align-content: center;
}

.card {
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 10px;
  padding: 26px;
  border-radius: var(--r-xl);
  color: var(--ink);
  text-decoration: none;
  animation: card-in 0.6s var(--ease-pop) backwards;
}

.card:nth-child(2) {
  animation-delay: 0.08s;
}

.card:nth-child(3) {
  animation-delay: 0.16s;
}

@keyframes card-in {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
}

.card h2 {
  font-size: 1.6rem;
}

.card p {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink-soft);
  line-height: 1.4;
}

/* Tarjeta de juego */
.game-card {
  grid-column: span 3;
  grid-row: span 2;
  grid-template-columns: minmax(240px, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 20px 32px;
  padding: 32px 40px;
  transition: transform 0.25s var(--ease-pop), box-shadow 0.25s;
}

.game-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-3), inset 0 1px 0 #fff;
}

.game-card:hover .art-bubble {
  scale: 1.04;
}

.game-card h2 {
  font-size: clamp(2.2rem, 4.4vw, 3.4rem);
  background: linear-gradient(180deg, #31c3f5 0%, #0a7fc4 55%, #075b98 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 0 #fff);
}

.game-card p {
  font-size: 1.2rem;
}

.game-info {
  display: grid;
  gap: 14px;
  justify-items: start;
}

.skills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.skills li {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1.5px solid #fff;
  background: rgba(255, 255, 255, 0.6);
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--aqua-5);
}

.game-art {
  position: relative;
  width: 100%;
  max-width: 380px;
  aspect-ratio: 1;
  justify-self: center;
}

.art-bubble {
  position: absolute;
  inset: 10%;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.95);
  background: radial-gradient(circle at 50% 55%, rgba(255, 255, 255, 0.15) 52%, rgba(255, 255, 255, 0.55) 72%, rgba(200, 244, 255, 0.9) 100%);
  box-shadow: inset 0 0 30px rgba(255, 255, 255, 0.6), inset 0 -14px 30px rgba(63, 198, 243, 0.35), 0 18px 40px rgba(2, 40, 80, 0.25);
  transition: scale 0.3s var(--ease-pop);
  animation: float 6s ease-in-out infinite;
}

.art-bubble::before {
  content: '';
  position: absolute;
  top: 8%;
  left: 16%;
  width: 38%;
  height: 20%;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0));
  transform: rotate(-28deg);
}

.art-bubble img {
  width: 66%;
  filter: drop-shadow(0 10px 12px rgba(2, 40, 80, 0.3));
}

.art-letter {
  position: absolute;
  display: grid;
  place-items: center;
  width: 22%;
  aspect-ratio: 1;
  border: 2px solid #fff;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 25%, rgba(255, 255, 255, 0.95) 0 9%, rgba(255, 255, 255, 0) 27%),
    radial-gradient(circle at 50% 50%, hsl(var(--h) 100% 98%), hsl(var(--h) 90% 91%) 52%, hsl(var(--h) 75% 79%));
  box-shadow: inset 0 -6px 12px hsl(var(--h) 70% 60% / 0.3), 0 8px 16px rgba(2, 40, 80, 0.22);
  color: #0a2f4d;
  font: 700 clamp(1.4rem, 3.4vw, 2.6rem) / 1 var(--font-letter);
  text-shadow: 0 2px 0 rgba(255, 255, 255, 0.85);
  animation: float 4s ease-in-out infinite;
}

.art-letter.l0 { left: 0; top: 4%; animation-delay: -1s; }
.art-letter.l1 { right: 2%; top: 0; animation-delay: -2s; }
.art-letter.l2 { left: 2%; bottom: 6%; animation-delay: -3s; }
.art-letter.l3 { right: 0; bottom: 2%; animation-delay: -0.5s; }

@keyframes float {
  50% {
    translate: 0 -10px;
  }
}

/* Tarjetas pequeñas */
.hello-icon {
  width: 64px;
  height: 64px;
  transform-origin: 70% 80%;
  animation: wave 2.4s ease-in-out infinite;
}

@keyframes wave {
  0%,
  60%,
  100% {
    rotate: 0deg;
  }
  10%,
  30% {
    rotate: 16deg;
  }
  20%,
  40% {
    rotate: -8deg;
  }
}

.hello .btn img {
  width: 26px;
  height: 26px;
}

.soon {
  opacity: 0.92;
  border-style: dashed;
}

.soon-icons {
  display: flex;
  gap: 4px;
}

.soon-icons img {
  width: 46px;
  height: 46px;
  filter: grayscale(0.3);
  opacity: 0.85;
}

.home-foot {
  padding: 10px 16px 18px;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 2px rgba(2, 40, 80, 0.5);
}

.home-foot a {
  color: #fff;
}

@media (max-width: 980px) {
  .bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .game-card {
    grid-column: span 2;
    grid-row: auto;
  }
}

@media (max-width: 640px) {
  .bento {
    grid-template-columns: 1fr;
  }

  .game-card {
    grid-column: auto;
    grid-template-columns: 1fr;
    padding: 24px;
    text-align: center;
  }

  .game-info {
    justify-items: center;
  }

  .skills {
    justify-content: center;
  }

  .game-art {
    max-width: 260px;
  }
}
