/* LearnPokémon — decorative side VS battle (set/pack gallery pages) */
.lp-vs-root {
  position: fixed;
  inset: 0;
  /* Above the set-page scenic wash (z-index auto), below .set-inner (z-index 2). */
  z-index: 1;
  pointer-events: none !important;
  overflow: hidden;
  }
.lp-vs-root[hidden] { display: none !important; }

/* 3× the previous flank box: clamp(88px, 9.5vw, 148px) */
.lp-vs-flank {
  position: fixed;
  top: 46%;
  width: clamp(264px, 28.5vw, 444px);
  height: auto;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  filter: drop-shadow(0 2px 0 rgba(255,255,255,0.65)) drop-shadow(0 12px 18px rgba(16, 22, 36, 0.42));
  opacity: 1;
  pointer-events: none !important;
  z-index: 0;
}
.lp-vs-flank--left {
  left: max(4px, calc((100vw - 1240px) / 2 - clamp(264px, 28.5vw, 444px) - 10px));
}
.lp-vs-flank--right {
  right: max(4px, calc((100vw - 1240px) / 2 - clamp(264px, 28.5vw, 444px) - 10px));
}

.lp-vs-sprite-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}
/* Ground contact only — no milky disc over the artwork */
.lp-vs-sprite-wrap::before {
  content: "";
  position: absolute;
  left: 18%;
  right: 18%;
  bottom: 2%;
  height: 12%;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(16, 22, 36, 0.28) 0%, transparent 72%);
  z-index: 0;
  pointer-events: none;
}
.lp-vs-sprite { position: relative; z-index: 1; }
.lp-vs-sprite {
  width: 92%;
  height: 92%;
  object-fit: contain;
  opacity: 1;
  filter: none;
  user-select: none;
  -webkit-user-drag: none;
  transition: transform 0.25s ease, filter 0.25s ease;
}
.lp-vs-flank--left .lp-vs-sprite { transform: scaleX(-1); }
.lp-vs-flank.is-attacking .lp-vs-sprite {
  filter: brightness(1.12) saturate(1.15);
}
.lp-vs-flank--left.is-attacking .lp-vs-sprite {
  transform: scaleX(-1) translateX(22px);
}
.lp-vs-flank--right.is-attacking .lp-vs-sprite {
  transform: translateX(-22px);
}
.lp-vs-flank.is-hit .lp-vs-sprite { animation: lp-vs-shake 0.48s ease; }
.lp-vs-flank--left.is-hit .lp-vs-sprite { animation: lp-vs-shake-flip 0.48s ease; }

@keyframes lp-vs-shake {
  0%, 100% { transform: translateX(0) rotate(0); }
  18% { transform: translateX(16px) rotate(-3deg); }
  40% { transform: translateX(-14px) rotate(2.5deg); }
  62% { transform: translateX(9px) rotate(-1deg); }
  82% { transform: translateX(-5px); }
}
@keyframes lp-vs-shake-flip {
  0%, 100% { transform: scaleX(-1) translateX(0); }
  18% { transform: scaleX(-1) translateX(-16px) rotate(3deg); }
  40% { transform: scaleX(-1) translateX(14px) rotate(-2deg); }
  62% { transform: scaleX(-1) translateX(-9px); }
  82% { transform: scaleX(-1) translateX(5px); }
}

.lp-vs-label {
  margin-top: 2px;
  max-width: 100%;
  padding: 2px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, #fffaf0 78%, transparent);
  color: #2a3344;
  font: 600 11px/1.3 Outfit, system-ui, sans-serif;
  letter-spacing: 0.02em;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
}

/* Wide type-true attack. Core ~min(55vw, 720px) from flank mid toward
   the opponent; leading particles travel farther so the hit reaches across. */
.lp-vs-fx {
  --lp-atk: #ffb020;
  --lp-atk2: #fff1c2;
  position: fixed;
  top: 46%;
  width: min(55vw, 720px);
  height: 280px;
  margin-top: -140px;
  pointer-events: none !important;
  z-index: 0;
  overflow: visible;
}
.lp-vs-fx--left {
  left: max(4px, calc((100vw - 1240px) / 2 - clamp(90px, 11vw, 210px)));
}
.lp-vs-fx--right {
  right: max(4px, calc((100vw - 1240px) / 2 - clamp(90px, 11vw, 210px)));
}
.lp-vs-fx-spin,
.lp-vs-fx-art {
  position: absolute;
  inset: 0;
  pointer-events: none !important;
}
.lp-vs-fx--left .lp-vs-fx-spin { transform-origin: left center; }
.lp-vs-fx--right .lp-vs-fx-spin { transform-origin: right center; }
.lp-vs-fx--right .lp-vs-fx-art { transform: scaleX(-1); transform-origin: center center; }
.lp-vs-fx-spin { opacity: 0; }
.lp-vs-root.is-firing-left .lp-vs-fx--left .lp-vs-fx-spin,
.lp-vs-root.is-firing-right .lp-vs-fx--right .lp-vs-fx-spin {
  animation: lp-vs-fx-travel 1.05s cubic-bezier(.2,.7,.2,1) both;
}
@keyframes lp-vs-fx-travel {
  0% { opacity: 0; transform: scaleX(0.06) scaleY(0.7); }
  16% { opacity: 1; transform: scaleX(0.42) scaleY(1); }
  58% { opacity: 1; transform: scaleX(1) scaleY(1); }
  100% { opacity: 0; transform: scaleX(1.04) scaleY(0.92); }
}

.lp-vs-layer {
  display: none;
  position: absolute;
  pointer-events: none !important;
}
.lp-vs-fx-glow,
.lp-vs-fx-core {
  position: absolute;
  pointer-events: none !important;
}
.lp-vs-fx-glow {
  left: -4%;
  right: -8%;
  top: 18%;
  bottom: 18%;
  background: linear-gradient(90deg, color-mix(in srgb, var(--lp-atk) 80%, white), var(--lp-atk) 28%, var(--lp-atk2) 70%, transparent 96%);
  filter: blur(16px);
  opacity: 0.9;
  border-radius: 999px;
}
.lp-vs-fx-core {
  left: 0;
  right: 0;
  top: 22%;
  bottom: 22%;
  background: linear-gradient(90deg, #fff, var(--lp-atk) 18%, var(--lp-atk2) 62%, transparent 100%);
  filter: drop-shadow(0 0 10px var(--lp-atk)) drop-shadow(0 0 22px var(--lp-atk2));
  border-radius: 999px;
}

.lp-vs-p {
  position: absolute;
  left: 10%;
  top: 42%;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  opacity: 0;
  pointer-events: none !important;
  background: radial-gradient(circle at 40% 40%, #fff, var(--lp-atk) 46%, transparent 72%);
  filter: drop-shadow(0 0 8px var(--lp-atk));
}
.lp-vs-p:nth-of-type(1) { left: 16%; top: 28%; }
.lp-vs-p:nth-of-type(2) { left: 34%; top: 58%; }
.lp-vs-p:nth-of-type(3) { left: 52%; top: 30%; }
.lp-vs-p:nth-of-type(4) { left: 70%; top: 60%; }
.lp-vs-p:nth-of-type(5) { left: 84%; top: 36%; }
.lp-vs-p:nth-of-type(6) { left: 94%; top: 50%; }
.lp-vs-root.is-firing-left .lp-vs-fx--left .lp-vs-p,
.lp-vs-root.is-firing-right .lp-vs-fx--right .lp-vs-p {
  animation: lp-vs-p-fly 1.05s ease-out both;
}
.lp-vs-p:nth-of-type(2) { animation-delay: 0.06s; }
.lp-vs-p:nth-of-type(3) { animation-delay: 0.1s; }
.lp-vs-p:nth-of-type(4) { animation-delay: 0.04s; }
.lp-vs-p:nth-of-type(5) { animation-delay: 0.12s; }
.lp-vs-p:nth-of-type(6) { animation-delay: 0.02s; }
@keyframes lp-vs-p-fly {
  0% { opacity: 0; transform: translateX(0) scale(0.35); }
  22% { opacity: 1; }
  100% { opacity: 0; transform: translateX(min(30vw, 380px)) scale(1.05); }
}

/* ---- fire: roaring tongues, not candle icons ---- */
.lp-vs-fx[data-kind="fire"] .lp-vs-fx-glow {
  top: 0;
  bottom: 0;
  left: -8%;
  right: -4%;
  opacity: 0.95;
  filter: blur(18px);
  background:
    radial-gradient(ellipse 40% 70% at 12% 62%, rgba(255, 220, 140, 0.95), transparent 70%),
    radial-gradient(ellipse 50% 80% at 42% 48%, rgba(255, 90, 0, 0.85), transparent 72%),
    radial-gradient(ellipse 46% 90% at 74% 55%, rgba(255, 40, 0, 0.7), transparent 74%),
    radial-gradient(ellipse 30% 60% at 92% 50%, rgba(255, 250, 220, 0.8), transparent 70%);
  animation: lp-fire-glow 0.16s ease-in-out infinite alternate;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-fx-core {
  top: 8%;
  bottom: 10%;
  border-radius: 46% 40% 42% 48% / 58% 42% 58% 42%;
  background:
    radial-gradient(ellipse 18% 36% at 16% 68%, #fff 0%, #ffe7a8 28%, transparent 70%),
    radial-gradient(ellipse 16% 30% at 38% 46%, #fffceb 0%, #ffc14a 34%, transparent 68%),
    radial-gradient(ellipse 20% 42% at 62% 64%, #fff 0%, #ff9a1a 30%, transparent 70%),
    radial-gradient(ellipse 22% 48% at 84% 50%, #fff6c8 0%, #ff5a00 36%, transparent 72%),
    linear-gradient(90deg, rgba(90, 8, 0, 0.15) 0%, rgba(255, 70, 0, 0.55) 18%, rgba(255, 150, 30, 0.75) 48%, rgba(255, 230, 140, 0.45) 78%, transparent 100%);
  filter: url(#lp-flame-turb) drop-shadow(0 0 10px #ff6a00) drop-shadow(0 0 22px #ff2a00);
  animation: lp-fire-lick 0.14s ease-in-out infinite alternate;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-l1,
.lp-vs-fx[data-kind="fire"] .lp-vs-l2,
.lp-vs-fx[data-kind="fire"] .lp-vs-l3,
.lp-vs-fx[data-kind="fire"] .lp-vs-l4 {
  display: block;
  filter: url(#lp-flame-turb);
  mix-blend-mode: screen;
  animation: lp-fire-lick 0.18s ease-in-out infinite alternate;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-l1 {
  left: 0;
  right: 8%;
  top: 6%;
  height: 42%;
  background: radial-gradient(ellipse at 18% 80%, #fff 0%, #ffd36a 16%, #ff6a00 42%, rgba(220, 20, 0, 0.15) 68%, transparent 76%);
  animation-duration: 0.13s;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-l2 {
  left: 6%;
  right: 0;
  top: 34%;
  height: 46%;
  background: radial-gradient(ellipse at 30% 72%, #fff8e0 0%, #ffb020 22%, #ff3b00 52%, transparent 74%);
  animation-duration: 0.17s;
  animation-delay: -0.05s;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-l3 {
  left: 0;
  right: 4%;
  top: 58%;
  height: 36%;
  background: radial-gradient(ellipse at 22% 40%, #fff 0%, #ffc14a 20%, #e02600 55%, transparent 76%);
  animation-duration: 0.11s;
  animation-delay: -0.08s;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-l4 {
  left: 40%;
  right: -2%;
  top: 18%;
  height: 58%;
  background: radial-gradient(ellipse at 70% 60%, rgba(255,255,255,0.95) 0%, rgba(255,180,40,0.7) 24%, rgba(255,60,0,0.25) 52%, transparent 70%);
  animation-duration: 0.15s;
}
.lp-vs-fx[data-kind="fire"] .lp-vs-p {
  width: 64px;
  height: 108px;
  border-radius: 50% 50% 46% 46% / 62% 62% 38% 38%;
  background:
    radial-gradient(ellipse at 50% 78%, #fff 0%, #ffe7a0 14%, #ff9a00 34%, #ff2d00 60%, transparent 76%);
  filter: url(#lp-flame-turb) blur(0.2px);
  mix-blend-mode: screen;
}
.lp-vs-root.is-firing-left .lp-vs-fx--left[data-kind="fire"] .lp-vs-p,
.lp-vs-root.is-firing-right .lp-vs-fx--right[data-kind="fire"] .lp-vs-p {
  animation-name: lp-vs-p-fly-fire;
}
@keyframes lp-fire-lick {
  from { transform: scaleY(0.94) scaleX(1) translateY(2%); }
  to { transform: scaleY(1.08) scaleX(1.03) translateY(-3%); }
}
@keyframes lp-fire-glow {
  from { opacity: 0.72; }
  to { opacity: 1; }
}
@keyframes lp-vs-p-fly-fire {
  0% { opacity: 0; transform: translate(0, 24px) scale(0.35) rotate(-8deg); }
  18% { opacity: 1; }
  100% { opacity: 0; transform: translate(min(32vw, 420px), -64px) scale(1.2) rotate(10deg); }
}

/* ---- water: liquid ribbons + foam, not rings ---- */
.lp-vs-fx[data-kind="water"] .lp-vs-fx-glow {
  top: 10%;
  bottom: 10%;
  filter: blur(16px);
  opacity: 0.9;
  background: linear-gradient(90deg, rgba(232, 248, 255, 0.2), rgba(40, 140, 220, 0.75) 35%, rgba(180, 230, 255, 0.55) 70%, transparent 96%);
}
.lp-vs-fx[data-kind="water"] .lp-vs-fx-core {
  top: 22%;
  bottom: 22%;
  border-radius: 40% 50% 46% 44% / 60% 40% 60% 40%;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.15), rgba(90, 180, 240, 0.15) 30%, rgba(16, 90, 180, 0.55) 72%, rgba(8, 50, 120, 0.2)),
    linear-gradient(90deg, rgba(255,255,255,0.65), rgba(70, 170, 230, 0.85) 22%, rgba(20, 100, 190, 0.8) 60%, transparent 100%);
  filter: url(#lp-water-turb) drop-shadow(0 10px 12px rgba(10, 60, 140, 0.35));
  animation: lp-water-surge 0.7s ease-in-out infinite;
}
.lp-vs-fx[data-kind="water"] .lp-vs-l1,
.lp-vs-fx[data-kind="water"] .lp-vs-l2,
.lp-vs-fx[data-kind="water"] .lp-vs-l3,
.lp-vs-fx[data-kind="water"] .lp-vs-l4 {
  display: block;
  left: 0;
  right: 0;
  height: 34px;
  border-radius: 50%;
  filter: url(#lp-water-turb);
}
.lp-vs-fx[data-kind="water"] .lp-vs-l1 {
  top: 18%;
  background: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(190, 235, 255, 0.35) 28%, rgba(30, 130, 210, 0.55) 70%, transparent);
  animation: lp-water-surge 0.65s ease-in-out infinite;
}
.lp-vs-fx[data-kind="water"] .lp-vs-l2 {
  top: 42%;
  height: 42px;
  background: linear-gradient(180deg, rgba(255,255,255,0.8), rgba(80, 180, 240, 0.25) 30%, rgba(14, 90, 180, 0.65) 78%, transparent);
  animation: lp-water-surge 0.8s ease-in-out infinite reverse;
}
.lp-vs-fx[data-kind="water"] .lp-vs-l3 {
  top: 66%;
  background: linear-gradient(180deg, rgba(255,255,255,0.75), rgba(40, 140, 210, 0.45) 40%, transparent 80%);
  animation: lp-water-surge 0.55s ease-in-out infinite;
}
.lp-vs-fx[data-kind="water"] .lp-vs-l4 {
  top: 30%;
  height: 18px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.95) 20%, rgba(255,255,255,0.2) 70%, transparent);
  filter: blur(1px);
  animation: lp-foam 0.45s ease-in-out infinite;
}
.lp-vs-fx[data-kind="water"] .lp-vs-p {
  width: 36px;
  height: 48px;
  border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
  background:
    radial-gradient(circle at 32% 28%, #fff 0%, #fff 18%, transparent 34%),
    radial-gradient(circle at 50% 60%, rgba(255,255,255,0.8), rgba(90, 190, 255, 0.55) 42%, rgba(16, 90, 180, 0.15) 70%, transparent 76%);
  filter: none;
}
@keyframes lp-water-surge {
  from { transform: translateY(3px) scaleX(1) scaleY(0.92); }
  to { transform: translateY(-5px) scaleX(1.04) scaleY(1.06); }
}
@keyframes lp-foam {
  from { opacity: 0.45; transform: translateX(-4%); }
  to { opacity: 1; transform: translateX(6%); }
}

/* ---- grass: vine + leaves ---- */
.lp-vs-fx[data-kind="grass"] .lp-vs-fx-glow {
  top: 34%;
  bottom: 34%;
  background: linear-gradient(90deg, #d8ff9a, #3e9a32 50%, transparent 92%);
}
.lp-vs-fx[data-kind="grass"] .lp-vs-fx-core {
  top: 42%;
  bottom: 42%;
  border-radius: 999px;
  background: linear-gradient(90deg, #f4ffd2, #7ed34a 20%, #2f8a30 70%, transparent);
  box-shadow: 0 0 16px #5cb85c;
  filter: none;
}
.lp-vs-fx[data-kind="grass"] .lp-vs-p {
  width: 22px;
  height: 36px;
  border-radius: 70% 0 70% 0;
  background: linear-gradient(#f3ffc4, #3d9a32);
  filter: drop-shadow(0 0 6px #7ed34a);
}

/* ---- electric: multi-fork lightning + flash ---- */
.lp-vs-fx[data-kind="electric"] .lp-vs-fx-glow {
  top: 0;
  bottom: 0;
  filter: blur(14px);
  opacity: 0.85;
  background: radial-gradient(ellipse at 62% 50%, rgba(255,255,255,0.95), rgba(140, 220, 255, 0.55) 28%, rgba(255, 230, 80, 0.25) 50%, transparent 70%);
  animation: lp-zap-flash 0.12s steps(2, end) infinite;
}
.lp-vs-fx[data-kind="electric"] .lp-vs-fx-core {
  top: 6%;
  bottom: 6%;
  border-radius: 0;
  background: #fff;
  clip-path: polygon(0 46%, 10% 46%, 16% 18%, 23% 18%, 29% 50%, 41% 50%, 47% 6%, 55% 6%, 61% 52%, 73% 52%, 79% 24%, 87% 24%, 94% 48%, 100% 48%, 100% 56%, 90% 56%, 83% 34%, 75% 34%, 69% 64%, 57% 64%, 51% 18%, 43% 18%, 37% 62%, 25% 62%, 19% 30%, 12% 30%, 6% 58%, 0 58%);
  filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 14px #7ad7ff) drop-shadow(0 0 22px #ffe14a);
  animation: lp-bolt-main 0.1s steps(2, end) infinite;
}
.lp-vs-fx[data-kind="electric"] .lp-vs-l1,
.lp-vs-fx[data-kind="electric"] .lp-vs-l2,
.lp-vs-fx[data-kind="electric"] .lp-vs-l3 {
  display: block;
  background: linear-gradient(90deg, #fff, #f3fbff 40%, #fff6b0);
  filter: drop-shadow(0 0 8px #fff) drop-shadow(0 0 12px #9ad7ff);
}
.lp-vs-fx[data-kind="electric"] .lp-vs-l1 {
  top: 8%;
  bottom: 28%;
  clip-path: polygon(0 62%, 18% 62%, 26% 20%, 34% 20%, 44% 70%, 62% 70%, 74% 8%, 100% 28%, 100% 40%, 78% 24%, 66% 84%, 48% 84%, 38% 36%, 28% 36%, 20% 74%, 0 74%);
  opacity: 0.95;
  animation: lp-zap-flash 0.14s steps(2, end) infinite;
}
.lp-vs-fx[data-kind="electric"] .lp-vs-l2 {
  top: 34%;
  bottom: 6%;
  background: #fff;
  clip-path: polygon(8% 20%, 22% 20%, 30% 58%, 48% 10%, 60% 10%, 70% 64%, 88% 30%, 100% 30%, 100% 42%, 80% 42%, 66% 78%, 52% 28%, 40% 28%, 32% 70%, 18% 36%, 8% 36%);
  animation: lp-bolt-main 0.09s steps(2, end) infinite reverse;
}
.lp-vs-fx[data-kind="electric"] .lp-vs-l3 {
  top: 20%;
  bottom: 20%;
  opacity: 0.55;
  filter: blur(6px);
  background: linear-gradient(90deg, transparent, #fff 15%, #c8f0ff 50%, #fff6b0 80%, transparent);
  clip-path: none;
  animation: lp-zap-flash 0.12s steps(2, end) infinite;
}
.lp-vs-fx[data-kind="electric"] .lp-vs-p {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 8px #fff, 0 0 16px #7ad7ff, 0 0 22px #ffe14a;
  filter: none;
}
@keyframes lp-zap-flash {
  0% { opacity: 1; }
  40% { opacity: 0.35; }
  70% { opacity: 1; }
  100% { opacity: 0.7; }
}
@keyframes lp-bolt-main {
  0% { transform: translateY(0) skewY(0deg); opacity: 1; }
  50% { transform: translateY(-6px) skewY(-2deg); opacity: 0.75; }
  100% { transform: translateY(5px) skewY(2deg); opacity: 1; }
}

/* ---- psychic / dragon: orb + energy beam ---- */
.lp-vs-fx[data-kind="psychic"] .lp-vs-fx-core,
.lp-vs-fx[data-kind="dragon"] .lp-vs-fx-core {
  top: 40%;
  bottom: 40%;
  background: linear-gradient(90deg, transparent, var(--lp-atk) 12%, #fff 48%, var(--lp-atk2) 70%, transparent);
  box-shadow: 0 0 18px var(--lp-atk), 0 0 42px var(--lp-atk2);
}
.lp-vs-fx[data-kind="psychic"] .lp-vs-fx-glow,
.lp-vs-fx[data-kind="dragon"] .lp-vs-fx-glow {
  background: radial-gradient(ellipse at 78% 50%, #fff 0%, var(--lp-atk) 28%, transparent 68%);
  filter: blur(8px);
}
.lp-vs-fx[data-kind="psychic"] .lp-vs-p,
.lp-vs-fx[data-kind="dragon"] .lp-vs-p {
  width: 54px;
  height: 54px;
  background: radial-gradient(circle at 40% 40%, #fff, var(--lp-atk) 36%, var(--lp-atk2) 62%, transparent 74%);
  box-shadow: 0 0 22px var(--lp-atk);
}

/* ---- ghost / dark: wisps ---- */
.lp-vs-fx[data-kind="ghost"] .lp-vs-fx-glow,
.lp-vs-fx[data-kind="dark"] .lp-vs-fx-glow {
  filter: blur(22px);
  opacity: 0.8;
  background: linear-gradient(90deg, transparent, var(--lp-atk) 20%, var(--lp-atk2) 60%, transparent);
}
.lp-vs-fx[data-kind="ghost"] .lp-vs-fx-core,
.lp-vs-fx[data-kind="dark"] .lp-vs-fx-core {
  top: 18%;
  bottom: 18%;
  border-radius: 40% 60% 50% 50%;
  filter: blur(6px);
  opacity: 0.85;
  background:
    radial-gradient(ellipse 30% 80% at 20% 60%, var(--lp-atk2), transparent 70%),
    radial-gradient(ellipse 28% 70% at 50% 40%, var(--lp-atk), transparent 72%),
    radial-gradient(ellipse 34% 90% at 80% 55%, var(--lp-atk2), transparent 74%);
}
.lp-vs-fx[data-kind="ghost"] .lp-vs-p,
.lp-vs-fx[data-kind="dark"] .lp-vs-p {
  width: 64px;
  height: 40px;
  filter: blur(6px);
  background: radial-gradient(ellipse, var(--lp-atk2), var(--lp-atk) 50%, transparent 74%);
}

/* ---- ice: frost beam + shards ---- */
.lp-vs-fx[data-kind="ice"] .lp-vs-fx-core {
  top: 38%;
  bottom: 38%;
  background: linear-gradient(90deg, #fff, #d8f6ff 20%, #7ec8e3 55%, transparent);
  box-shadow: 0 0 16px #bfefff, 0 0 32px #7ec8e3;
}
.lp-vs-fx[data-kind="ice"] .lp-vs-fx-glow {
  background: linear-gradient(90deg, #f3fbff, #7ec8e3 50%, transparent);
}
.lp-vs-fx[data-kind="ice"] .lp-vs-p {
  width: 18px;
  height: 36px;
  border-radius: 2px;
  background: linear-gradient(#fff, #9fe7ff 40%, #3aa0c8);
  clip-path: polygon(50% 0, 100% 72%, 68% 100%, 0 58%);
}

/* ---- steel: metallic glint ---- */
.lp-vs-fx[data-kind="steel"] .lp-vs-fx-core {
  top: 40%;
  bottom: 40%;
  background: linear-gradient(90deg, #5c656e, #eef2f6 22%, #fff 40%, #9aa0a8 58%, #e8edf2 78%, transparent);
  box-shadow: 0 0 12px #d5dbe2;
}
.lp-vs-fx[data-kind="steel"] .lp-vs-fx-core::after {
  content: "";
  position: absolute;
  top: -8px;
  bottom: -8px;
  width: 18%;
  left: 36%;
  background: linear-gradient(90deg, transparent, #fff, transparent);
  filter: blur(1px);
}
.lp-vs-fx[data-kind="steel"] .lp-vs-p {
  width: 16px;
  height: 16px;
  border-radius: 3px;
  background: linear-gradient(135deg, #fff, #9aa0a8);
}

/* ---- fairy / normal: star stream ---- */
.lp-vs-fx[data-kind="fairy"] .lp-vs-fx-core,
.lp-vs-fx[data-kind="normal"] .lp-vs-fx-core {
  top: 44%;
  bottom: 44%;
  opacity: 0.75;
  background: linear-gradient(90deg, transparent, var(--lp-atk) 30%, #fff 60%, transparent);
}
.lp-vs-fx[data-kind="fairy"] .lp-vs-p,
.lp-vs-fx[data-kind="normal"] .lp-vs-p {
  width: 22px;
  height: 22px;
  border-radius: 0;
  background: #fff;
  clip-path: polygon(50% 0, 62% 36%, 100% 50%, 62% 64%, 50% 100%, 38% 64%, 0 50%, 38% 36%);
  filter: drop-shadow(0 0 8px var(--lp-atk));
}

/* ---- fighting: shock rings ---- */
.lp-vs-fx[data-kind="fighting"] .lp-vs-fx-core {
  top: 10%;
  bottom: 10%;
  border-radius: 0;
  background:
    radial-gradient(circle at 18% 50%, transparent 34%, var(--lp-atk) 46%, transparent 56%),
    radial-gradient(circle at 48% 50%, transparent 32%, var(--lp-atk2) 46%, transparent 58%),
    radial-gradient(circle at 78% 50%, transparent 30%, #fff 42%, var(--lp-atk) 50%, transparent 62%);
  filter: drop-shadow(0 0 10px var(--lp-atk));
}
.lp-vs-fx[data-kind="fighting"] .lp-vs-p {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: transparent;
  box-shadow: inset 0 0 0 4px var(--lp-atk), 0 0 12px var(--lp-atk);
}

/* ---- poison: billowing gas, not bubbles ---- */
.lp-vs-fx[data-kind="poison"] .lp-vs-fx-glow {
  top: 4%;
  bottom: 4%;
  filter: blur(26px);
  opacity: 0.9;
  background:
    radial-gradient(ellipse at 20% 60%, rgba(170, 255, 70, 0.75), transparent 68%),
    radial-gradient(ellipse at 55% 40%, rgba(120, 20, 160, 0.8), transparent 70%),
    radial-gradient(ellipse at 82% 58%, rgba(40, 0, 60, 0.85), transparent 72%);
}
.lp-vs-fx[data-kind="poison"] .lp-vs-fx-core {
  top: 8%;
  bottom: 8%;
  border-radius: 46% 54% 48% 52%;
  background:
    radial-gradient(ellipse 34% 80% at 16% 62%, rgba(190, 255, 80, 0.75), transparent 70%),
    radial-gradient(ellipse 40% 90% at 42% 42%, rgba(140, 40, 190, 0.72), transparent 72%),
    radial-gradient(ellipse 36% 100% at 70% 58%, rgba(210, 255, 120, 0.55), transparent 70%),
    radial-gradient(ellipse 42% 90% at 90% 46%, rgba(70, 0, 90, 0.8), transparent 74%);
  filter: url(#lp-gas-turb) blur(2px);
  box-shadow: none;
  opacity: 0.92;
  animation: lp-gas-drift 2.4s ease-in-out infinite;
}
.lp-vs-fx[data-kind="poison"] .lp-vs-l1,
.lp-vs-fx[data-kind="poison"] .lp-vs-l2,
.lp-vs-fx[data-kind="poison"] .lp-vs-l3,
.lp-vs-fx[data-kind="poison"] .lp-vs-l4 {
  display: block;
  filter: url(#lp-gas-turb) blur(8px);
  opacity: 0.85;
  animation: lp-gas-drift 2.8s ease-in-out infinite;
}
.lp-vs-fx[data-kind="poison"] .lp-vs-l1 {
  left: -4%;
  width: 46%;
  top: 10%;
  height: 70%;
  background: radial-gradient(ellipse at 40% 60%, rgba(186, 255, 90, 0.8), rgba(90, 20, 120, 0.35) 46%, transparent 72%);
}
.lp-vs-fx[data-kind="poison"] .lp-vs-l2 {
  left: 28%;
  width: 48%;
  top: 0;
  height: 78%;
  background: radial-gradient(ellipse at 50% 50%, rgba(160, 60, 210, 0.75), rgba(40, 0, 70, 0.3) 50%, transparent 74%);
  animation-delay: -0.8s;
}
.lp-vs-fx[data-kind="poison"] .lp-vs-l3 {
  left: 52%;
  width: 50%;
  top: 22%;
  height: 74%;
  background: radial-gradient(ellipse at 40% 40%, rgba(220, 255, 140, 0.7), rgba(100, 20, 140, 0.25) 48%, transparent 72%);
  animation-delay: -1.4s;
}
.lp-vs-fx[data-kind="poison"] .lp-vs-l4 {
  left: 10%;
  width: 80%;
  top: 30%;
  height: 40%;
  filter: blur(14px);
  background: radial-gradient(ellipse at 50% 50%, rgba(80, 255, 60, 0.35), transparent 70%);
  animation-duration: 3.2s;
}
.lp-vs-fx[data-kind="poison"] .lp-vs-p {
  width: 90px;
  height: 64px;
  border-radius: 50%;
  background: radial-gradient(ellipse at 40% 45%, rgba(210, 255, 140, 0.75), rgba(120, 30, 170, 0.45) 42%, transparent 72%);
  box-shadow: none;
  filter: blur(6px);
}
.lp-vs-fx[data-kind="poison"] .lp-vs-p:nth-child(n) { width: 80px; height: 56px; }
@keyframes lp-gas-drift {
  0% { transform: translate3d(0, 4px, 0) scale(1); }
  50% { transform: translate3d(14px, -10px, 0) scale(1.08, 0.96); }
  100% { transform: translate3d(-6px, 6px, 0) scale(0.96, 1.06); }
}

/* ---- ground / rock: dust + chunks ---- */
.lp-vs-fx[data-kind="ground"] .lp-vs-fx-glow,
.lp-vs-fx[data-kind="rock"] .lp-vs-fx-glow {
  filter: blur(18px);
  background: linear-gradient(90deg, transparent, var(--lp-atk) 20%, var(--lp-atk2) 70%, transparent);
  opacity: 0.75;
}
.lp-vs-fx[data-kind="ground"] .lp-vs-fx-core,
.lp-vs-fx[data-kind="rock"] .lp-vs-fx-core {
  top: 28%;
  bottom: 20%;
  border-radius: 40%;
  background:
    radial-gradient(ellipse at 20% 70%, var(--lp-atk2), transparent 60%),
    radial-gradient(ellipse at 55% 60%, var(--lp-atk), transparent 62%),
    radial-gradient(ellipse at 85% 68%, var(--lp-atk2), transparent 64%);
  filter: blur(1px);
}
.lp-vs-fx[data-kind="ground"] .lp-vs-p,
.lp-vs-fx[data-kind="rock"] .lp-vs-p {
  width: 20px;
  height: 16px;
  border-radius: 2px;
  background: linear-gradient(160deg, var(--lp-atk2), var(--lp-atk));
  clip-path: polygon(10% 20%, 80% 0, 100% 70%, 40% 100%, 0 70%);
}

/* ---- bug: swarm ---- */
.lp-vs-fx[data-kind="bug"] .lp-vs-fx-core {
  top: 46%;
  bottom: 46%;
  opacity: 0.55;
  background: linear-gradient(90deg, transparent, var(--lp-atk), transparent);
}
.lp-vs-fx[data-kind="bug"] .lp-vs-p {
  width: 10px;
  height: 10px;
  background: radial-gradient(circle, #f4ffb0, var(--lp-atk) 60%, transparent 72%);
  box-shadow: 8px -14px 0 -1px var(--lp-atk2), -6px 10px 0 -2px var(--lp-atk);
}

/* ---- flying: wind slashes ---- */
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-core {
  background: none;
  filter: none;
  top: 10%;
  bottom: 10%;
}
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-core::before,
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-core::after {
  content: "";
  position: absolute;
  left: 0;
  right: 6%;
  height: 28px;
  border-radius: 50%;
  border-top: 7px solid var(--lp-atk);
  filter: drop-shadow(0 0 8px var(--lp-atk2));
}
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-core::before { top: 22%; transform: rotate(-10deg); }
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-core::after { top: 58%; transform: rotate(-4deg); border-top-color: var(--lp-atk2); }
.lp-vs-fx[data-kind="flying"] .lp-vs-fx-glow { opacity: 0.45; }
.lp-vs-fx[data-kind="flying"] .lp-vs-p {
  width: 36px;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, #fff, var(--lp-atk));
}


.lp-vs-vs { display: none; }

.lp-vs-root:not(.lp-vs-static) .lp-vs-flank--left .lp-vs-sprite-wrap {
  animation: lp-vs-bob 2.8s ease-in-out infinite;
}
.lp-vs-root:not(.lp-vs-static) .lp-vs-flank--right .lp-vs-sprite-wrap {
  animation: lp-vs-bob 2.8s ease-in-out infinite 1.4s;
}
@keyframes lp-vs-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* Wide viewports only — need real side margins beside the 1240px set-inner */
@media (max-width: 1360px) {
  .lp-vs-root { display: none !important; }
}
@media (max-height: 520px) {
  .lp-vs-root { display: none !important; }
}
@media (prefers-reduced-motion: reduce) {
  .lp-vs-root { display: none !important; }
}


/* Fighters sit above the full-bleed scenic wash and below opaque cards.
   page-wrap's enter animation used translateY, which would trap position:fixed
   to the document instead of the viewport — fade only. */
.page-wrap { animation-name: lp-vs-page-fade; }
@keyframes lp-vs-page-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
.set-page .set-inner { position: relative; z-index: 2; }
/* Sticky glass nav (non-home) is lp-glass-nav.css. Keep home relative. */
.home-app .nav { position: relative; z-index: 5; }
.footer { position: relative; z-index: 3; }
