/* 88BB Home Community Visual v1.0
   Formal homepage community section visual upgrade.
   Adds a cinematic command-room background only to the Community Hall panel.
*/

.home-community-section {
  --community-bg-glow: rgba(75, 216, 255, .16);
  isolation: isolate;
}

.home-community-section .home-community-panel {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  border-color: rgba(92, 226, 216, .20);
  background:
    linear-gradient(90deg, rgba(3, 7, 16, .96) 0%, rgba(4, 10, 22, .90) 38%, rgba(4, 10, 22, .54) 72%, rgba(3, 7, 16, .38) 100%),
    radial-gradient(circle at 72% 28%, rgba(90, 210, 255, .20), transparent 36%),
    url("homepage-community-bg-16x9.png") center right / cover no-repeat;
  box-shadow:
    0 28px 90px rgba(0, 0, 0, .34),
    inset 0 1px 0 rgba(255, 255, 255, .035),
    inset 0 0 0 1px rgba(78, 225, 218, .06);
}

.home-community-section .home-community-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, rgba(5, 10, 20, .98) 0%, rgba(5, 10, 20, .88) 36%, rgba(5, 10, 20, .22) 76%, rgba(5, 10, 20, .08) 100%),
    radial-gradient(circle at 78% 36%, rgba(91, 220, 255, .22), transparent 34%),
    radial-gradient(circle at 88% 18%, rgba(255, 195, 84, .14), transparent 28%);
  pointer-events: none;
  z-index: 0;
}

.home-community-section .home-community-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(90deg, rgba(118, 255, 228, .035) 0 1px, transparent 1px 108px),
    linear-gradient(180deg, transparent 0%, rgba(113, 251, 228, .045) 48%, transparent 100%);
  mix-blend-mode: screen;
  opacity: .52;
  transform-origin: center;
  animation: communityCommandBreath 7.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}

.home-community-section .home-community-panel > * {
  position: relative;
  z-index: 1;
  max-width: 520px;
}

.home-community-section .home-community-panel .home-kicker {
  color: #7affdf;
  text-shadow: 0 0 22px rgba(122, 255, 223, .22);
}

.home-community-section .home-community-panel h2 {
  max-width: 560px;
  text-wrap: balance;
}

.home-community-section .home-community-panel p {
  max-width: 560px;
}

.home-community-section .home-community-panel .home-secondary-button {
  box-shadow: 0 0 0 1px rgba(122, 255, 223, .16), 0 16px 40px rgba(0, 0, 0, .22);
  backdrop-filter: blur(10px);
}

.home-community-section .home-community-feed article {
  border-color: rgba(92, 226, 216, .16);
  background:
    linear-gradient(135deg, rgba(10, 22, 36, .82), rgba(4, 9, 19, .76)),
    radial-gradient(circle at 88% 18%, rgba(122, 255, 223, .08), transparent 30%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
}

@keyframes communityCommandBreath {
  0%, 100% {
    opacity: .38;
    transform: scale(1);
  }
  50% {
    opacity: .68;
    transform: scale(1.018);
  }
}

@media (max-width: 900px) {
  .home-community-section .home-community-panel {
    min-height: 330px;
    background:
      linear-gradient(180deg, rgba(3, 7, 16, .97) 0%, rgba(3, 7, 16, .88) 56%, rgba(3, 7, 16, .62) 100%),
      radial-gradient(circle at 72% 28%, rgba(90, 210, 255, .18), transparent 40%),
      url("homepage-community-bg-16x9.png") center center / cover no-repeat;
  }

  .home-community-section .home-community-panel > * {
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-community-section .home-community-panel::after {
    animation: none;
  }
}
