/* ==========================================================================
   WarspectClient Portal — Home Page (Clean Warspect Identity + Rich Motion)
   ========================================================================== */

/* 1. Full-Bleed Centered Hero */
.wsHero {
  position: relative;
  min-height: clamp(640px, 94dvh, 900px);
  padding: calc(var(--header-h) + 48px) 0 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-ground);
}

.wsHeroMedia {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.wsHeroMedia img {
  width: 100%;
  height: 118%;
  object-fit: cover;
  object-position: center 22%;
  opacity: 0.44;
  filter: saturate(1.1) contrast(1.06);
  transform: translate3d(0, 0, 0) scale(1.06);
  will-change: transform;
  animation: heroBgIntro 1.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes heroBgIntro {
  from {
    opacity: 0;
    filter: saturate(0.9) blur(6px);
    transform: translate3d(0, 0, 0) scale(1.16);
  }
  to {
    opacity: 0.44;
    filter: saturate(1.1) blur(0);
    transform: translate3d(0, 0, 0) scale(1.06);
  }
}

.wsHeroDust {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.wsHeroShade {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    radial-gradient(ellipse 68% 58% at 50% 42%, rgba(220, 38, 38, 0.18) 0%, transparent 66%),
    linear-gradient(180deg, rgba(17, 19, 24, 0.72) 0%, rgba(17, 19, 24, 0.44) 46%, rgba(17, 19, 24, 0.98) 100%);
  animation: shadeBreath 7s ease-in-out infinite alternate;
}

@keyframes shadeBreath {
  from { opacity: 0.92; }
  to { opacity: 1; }
}

.wsHeroInner {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  will-change: transform, opacity;
}

.wsHeroInner > * {
  animation: wsHeroEnter 0.85s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.wsHeroInner > :nth-child(1) { animation-delay: 80ms; }
.wsHeroInner > :nth-child(2) { animation-delay: 180ms; }
.wsHeroInner > :nth-child(3) { animation-delay: 280ms; }
.wsHeroInner > :nth-child(4) { animation-delay: 380ms; }
.wsHeroInner > :nth-child(5) { animation-delay: 460ms; }

@keyframes wsHeroEnter {
  from {
    opacity: 0;
    transform: translate3d(0, 28px, 0) scale(0.96);
    filter: blur(5px);
  }
  to {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
    filter: blur(0);
  }
}

.wsHeroMark {
  width: 86px;
  height: 86px;
  border-radius: 20px;
  margin-bottom: 22px;
  filter: drop-shadow(0 14px 34px rgba(220, 38, 38, 0.52));
  animation:
    wsHeroEnter 0.85s cubic-bezier(0.16, 1, 0.3, 1) 80ms both,
    wsMarkFloat 4.8s ease-in-out 1s infinite;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), filter 0.35s ease;
}

@keyframes wsMarkFloat {
  0%, 100% {
    transform: translateY(0px);
    filter: drop-shadow(0 14px 32px rgba(220, 38, 38, 0.45));
  }
  50% {
    transform: translateY(-9px);
    filter: drop-shadow(0 22px 44px rgba(239, 68, 68, 0.72));
  }
}

.wsHeroMark:hover {
  transform: scale(1.09) rotate(-3deg);
}

.wsHeroTitle {
  font-size: clamp(46px, 7.6vw, 84px);
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: -0.04em;
  color: #fff;
  text-shadow: 0 12px 42px rgba(0, 0, 0, 0.72);
}

.wsHeroTitle .accentText {
  background: linear-gradient(110deg, #ef4444 0%, #fca5a5 48%, #dc2626 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: titleSheen 5.5s ease-in-out infinite;
}

@keyframes titleSheen {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.wsHeroSub {
  margin-top: 20px;
  max-width: 560px;
  font-size: clamp(16px, 1.5vw, 19px);
  line-height: 1.55;
  color: #dbe2ee;
}

.wsHeroCta {
  margin-top: 34px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.btnHeroDiscord {
  min-height: 56px;
  padding: 0 28px;
  font-size: 14px;
  border-radius: 14px;
  background: rgba(88, 101, 242, 0.2);
  border: 1px solid rgba(129, 140, 248, 0.45);
  color: #eef2ff;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 26px rgba(88, 101, 242, 0.22);
}

.btnHeroDiscord:hover {
  background: rgba(88, 101, 242, 0.36);
  border-color: rgba(165, 180, 252, 0.72);
  color: #fff;
  box-shadow: 0 14px 34px rgba(88, 101, 242, 0.42);
  transform: translateY(-2px);
}

.wsHeroLivePill {
  margin-top: 22px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(16, 185, 129, 0.34);
  background: rgba(10, 14, 20, 0.72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: #d1fae5;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.wsHeroLivePill strong {
  color: #fff;
  font-weight: 700;
  font-size: 13.5px;
}

.livePulseDot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--emerald-500);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.75);
  animation: pulseEmerald 2.2s infinite;
  flex-shrink: 0;
}

@keyframes pulseEmerald {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.btnHeroDownload {
  min-height: 56px;
  padding: 0 36px;
  font-size: 14.5px;
  border-radius: 14px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(220, 38, 38, 0.36);
  animation: ctaBreath 3.6s ease-in-out infinite;
}

@keyframes ctaBreath {
  0%, 100% {
    box-shadow: 0 10px 28px rgba(220, 38, 38, 0.34), 0 0 0 0 rgba(239, 68, 68, 0.35);
  }
  50% {
    box-shadow: 0 14px 40px rgba(239, 68, 68, 0.56), 0 0 0 8px rgba(239, 68, 68, 0);
  }
}

.btnHeroDownload::after {
  content: "";
  position: absolute;
  top: -40%;
  bottom: -40%;
  left: -65%;
  width: 45%;
  background: linear-gradient(105deg, transparent 0%, rgba(255, 255, 255, 0.35) 50%, transparent 100%);
  transform: skewX(-20deg);
  pointer-events: none;
  transition: left 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.btnHeroDownload:hover::after {
  left: 135%;
}

.btnHeroDownload:hover .iconSvg {
  animation: arrowDrop 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes arrowDrop {
  0% { transform: translateY(0); }
  45% { transform: translateY(4px); }
  100% { transform: translateY(0); }
}

.wsScrollHint {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(10, 11, 16, 0.62);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.72);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  animation: scrollBounce 2.2s ease-in-out infinite;
}

.wsScrollHint:hover {
  color: #fff;
  border-color: rgba(239, 68, 68, 0.6);
  background: rgba(220, 38, 38, 0.2);
}

@keyframes scrollBounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 8px); }
}

/* 2. Centered Section Intro */
.wsSectionIntro {
  text-align: center;
  max-width: 640px;
  margin: 0 auto clamp(34px, 4.5vw, 52px);
}

.wsSectionIntro h2 {
  font-size: clamp(28px, 3.6vw, 44px);
  line-height: 1.08;
  font-weight: 700;
}

.wsSectionIntro p {
  margin-top: 12px;
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* 3. Clean 3-Pillar Grid with Alive Previews */
.wsPillarsSection {
  background: var(--bg-ground);
}

.wsPillarGrid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.wsPillarCard {
  position: relative;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--rim-top), var(--shadow-sm);
  transition:
    transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.3s ease,
    background 0.3s ease,
    box-shadow 0.35s ease;
}

.wsPillarCard:hover {
  transform: translateY(-7px);
  border-color: rgba(239, 68, 68, 0.42);
  background: var(--bg-surface-2);
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.48), 0 0 36px rgba(220, 38, 38, 0.14);
}

.wsPillarPreview {
  position: relative;
  height: 138px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background:
    radial-gradient(ellipse 70% 70% at 50% 50%, rgba(220, 38, 38, 0.1), transparent 72%),
    var(--bg-inset);
  margin-bottom: 20px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 8px;
  overflow: hidden;
}

.wsPreviewMods {
  flex-direction: row;
  flex-wrap: wrap;
  align-content: center;
  gap: 7px;
}

.wsMiniTag {
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 5px 10px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
  transition:
    transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.25s ease,
    background 0.25s ease,
    color 0.25s ease,
    box-shadow 0.25s ease;
}

.wsMiniTag.on {
  border-color: rgba(239, 68, 68, 0.65);
  background: rgba(220, 38, 38, 0.2);
  color: #fff;
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 6px 16px rgba(220, 38, 38, 0.28);
}

.wsTagMock {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 18px;
  border-radius: var(--radius-sm);
  background: rgba(15, 17, 24, 0.96);
  border: 1px solid rgba(239, 68, 68, 0.34);
  font-family: var(--font-mono);
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.55), 0 0 24px rgba(220, 38, 38, 0.18);
  animation: tagFloat 4.2s ease-in-out infinite;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
}

.wsTagMock::after {
  content: "";
  position: absolute;
  top: -30%;
  bottom: -30%;
  left: -80%;
  width: 50%;
  background: linear-gradient(110deg, transparent 0%, rgba(255, 255, 255, 0.24) 50%, transparent 100%);
  transform: skewX(-20deg);
  animation: tagSheen 4.8s ease-in-out infinite;
}

@keyframes tagFloat {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-5px); }
}

@keyframes tagSheen {
  0%, 62% { left: -80%; }
  100% { left: 150%; }
}

.wsPillarCard:hover .wsTagMock {
  border-color: rgba(239, 68, 68, 0.65);
  transform: scale(1.07);
}

.wsTagMock img {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  filter: drop-shadow(0 0 8px rgba(239, 68, 68, 0.65));
}

.wsFpsReadout {
  position: relative;
  text-align: center;
  padding: 12px 26px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(239, 68, 68, 0.25);
  background: rgba(220, 38, 38, 0.08);
  animation: verPulse 3.8s ease-in-out infinite;
}

@keyframes verPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.26);
    transform: scale(1);
  }
  50% {
    box-shadow: 0 0 28px 2px rgba(239, 68, 68, 0.24);
    transform: scale(1.04);
  }
}

.wsFpsReadout strong {
  display: block;
  font-family: var(--font-display);
  font-size: 40px;
  line-height: 1;
  letter-spacing: -0.04em;
  color: #fff;
}

.wsPillarCard h3 {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.2;
}

.wsPillarCard p {
  margin-top: 10px;
  font-size: 14.5px;
  color: var(--text-muted);
  line-height: 1.62;
}

/* 4. Balanced 5-Cape Gallery with 3D Interactive Tilt + Sheen */
.capeGallery {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.capeCard {
  position: relative;
  min-width: 0;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  overflow: hidden;
  padding: 0;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transform-style: preserve-3d;
  will-change: transform;
  transition:
    transform 0.28s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.28s ease,
    box-shadow 0.32s ease;
}

.capeCard::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    260px circle at var(--gx, 50%) var(--gy, 25%),
    rgba(255, 255, 255, 0.22),
    transparent 62%
  );
  opacity: 0;
  pointer-events: none;
  z-index: 3;
  transition: opacity 0.26s ease;
}

.capeCard:hover::after {
  opacity: 1;
}

.capeCard:hover {
  transform: translateY(-8px);
  border-color: var(--cape-accent, rgba(255, 255, 255, 0.34));
  box-shadow:
    0 22px 46px rgba(0, 0, 0, 0.64),
    0 0 34px color-mix(in srgb, var(--cape-accent, #ef4444) 36%, transparent);
}

.capeThumbWrap {
  position: relative;
  aspect-ratio: 5 / 7;
  overflow: hidden;
  background: #090a0f;
}

.capeThumbImg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.capeCard:hover .capeThumbImg {
  transform: scale(1.08);
}

.capeCornerTag {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.capeCornerTag.free {
  background: rgba(6, 28, 22, 0.84);
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: #6ee7b7;
}

.capeCardBody {
  padding: 13px 14px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: var(--bg-surface);
}

.capeCardBody h3 {
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.capeInspectHint {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: color var(--t-fast) ease, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.capeCard:hover .capeInspectHint {
  color: #fff;
  transform: translateX(4px);
}

/* Horizontal Extras Strip with Smooth Ken Burns Photo */
.wsExtrasStrip {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  box-shadow: var(--rim-top), var(--shadow-sm);
  overflow: hidden;
  transition: border-color 0.3s ease, box-shadow 0.35s ease;
}

.wsExtrasStrip:hover {
  border-color: rgba(239, 68, 68, 0.34);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.52);
}

.wsExtraPhoto {
  overflow: hidden;
  background: #05060a;
  min-height: 220px;
}

.wsExtraPhoto img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 26%;
  animation: wsKenBurns 14s ease-in-out infinite alternate;
  will-change: transform;
}

@keyframes wsKenBurns {
  from { transform: scale(1) translate3d(0, 0, 0); }
  to { transform: scale(1.08) translate3d(-1.5%, -1.5%, 0); }
}

.wsExtraCopy {
  padding: 32px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
}

.wsExtraCopy h3 {
  font-size: clamp(21px, 2.2vw, 26px);
  line-height: 1.18;
}

.wsExtraCopy p {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 520px;
}

.wsExtraCounts {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 22px;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
  font-size: 14px;
  color: var(--text-secondary);
}

.wsExtraCounts span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), color 0.2s ease;
}

.wsExtraCounts span:hover {
  transform: translateY(-2px);
  color: #fff;
}

.wsExtraCounts strong {
  font-family: var(--font-mono);
  color: var(--brand-400);
  font-size: 16px;
}

/* Responsive */
@media (max-width: 1080px) {
  .wsPillarGrid {
    grid-template-columns: minmax(0, 1fr);
  }
  .capeGallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .wsExtrasStrip {
    grid-template-columns: minmax(0, 1fr);
  }
  .wsExtraPhoto {
    max-height: 250px;
  }
}

@media (max-width: 640px) {
  .wsHero {
    min-height: 580px;
  }
  .capeGallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .wsExtraCopy {
    padding: 22px;
  }
}
