/* ==========================================================================
   Home page (index.html)
   ========================================================================== */

.page--home {
  padding-block: 3rem;
}

/* ---------- Hero ---------- */

.home-hero {
  position: relative;
  display: grid;
  align-items: center;
  gap: 2.5rem;
}

.home-hero__dots {
  position: absolute;
  inset-inline: calc(var(--gutter) * -1);
  top: -4rem;
  height: 20rem;
  opacity: 0.7;
  pointer-events: none;
}

.home-hero__intro {
  position: relative;
}

.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.875rem;
  border-radius: 9999px;
  background: rgb(255 255 255 / 0.8);
  box-shadow: var(--ring-faint), var(--shadow-soft);
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 600;
  color: var(--slate-600);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.live-badge__dot {
  position: relative;
  display: flex;
  width: 0.5rem;
  height: 0.5rem;
}

.live-badge__dot::before,
.live-badge__dot::after {
  content: "";
  border-radius: 9999px;
}

/* Pulsing halo */
.live-badge__dot::before {
  position: absolute;
  inset: 0;
  background: var(--brand-400);
  opacity: 0.6;
}

.live-badge__dot::after {
  position: relative;
  width: 0.5rem;
  height: 0.5rem;
  background: var(--brand-500);
}

@media (prefers-reduced-motion: no-preference) {
  .live-badge__dot::before {
    animation: ping 1s var(--ease-out) infinite;
  }
}

.home-hero__title {
  margin-top: 1.5rem;
  font-size: 2.25rem;
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--slate-900);
}

.home-hero__highlight {
  background-image: linear-gradient(to right, var(--brand-600), #10b981, #84cc16);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.home-hero__lead {
  max-width: 42rem;
  margin-top: 1.25rem;
  font-size: 1.125rem;
  line-height: 1.625;
  color: var(--slate-500);
}

.stat-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.stat-chip {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 1.25rem 0.625rem 0.625rem;
  border-radius: 1rem;
  background: rgb(255 255 255 / 0.8);
  box-shadow: var(--ring-faint), var(--shadow-soft);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.stat-chip__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: var(--brand-50);
  box-shadow: inset 0 0 0 1px rgb(3 152 85 / 0.1);
  color: var(--brand-600);
}

.stat-chip__value {
  display: block;
  font-size: 1.125rem;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--slate-900);
  font-variant-numeric: tabular-nums;
}

.stat-chip__label {
  display: block;
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 500;
  color: var(--slate-500);
}

/* Decorative floating emoji tiles (large screens only). Each tile sets
   --x, --y, --size, --rotate and --delay inline. */
.hero-tiles {
  position: relative;
  display: none;
  height: 18rem;
}

.hero-tiles__glow {
  position: absolute;
  inset: 1.5rem;
  border-radius: 9999px;
  background-image: linear-gradient(to top right, rgb(166 244 197 / 0.6), rgb(254 243 199 / 0.5), transparent);
  filter: blur(64px);
}

.hero-tile {
  position: absolute;
  left: var(--x);
  top: var(--y);
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--size);
  height: var(--size);
  border-radius: 1.5rem;
  background: rgb(255 255 255 / 0.8);
  box-shadow: var(--ring-faint), var(--shadow-card);
  font-family: var(--font-emoji);
  font-size: calc(var(--size) * 0.5);
  rotate: var(--rotate);
  animation-delay: var(--delay);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

/* ---------- Categories ---------- */

.section-head--home {
  margin-top: 3.5rem;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

/* ---------- Breakpoints ---------- */

@media (min-width: 640px) {
  .home-hero__title {
    font-size: 3rem;
    line-height: 1;
  }

  .category-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
  }
}

@media (min-width: 768px) {
  .page--home {
    padding-block: 4rem;
  }
}

@media (min-width: 1024px) {
  .home-hero {
    grid-template-columns: minmax(0, 1fr) 420px;
  }

  .home-hero__title {
    font-size: 3.75rem;
  }

  .hero-tiles {
    display: block;
  }

  .category-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (min-width: 1280px) {
  .category-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}
