/* Shared three-strike combat. Captures alone continue with saved heraldry. */
.map-vfx-layer.crownlands-capture-active { z-index: 19; }
.crownlands-vfx--city-capture {
  animation: crownlandsCaptureEnd var(--vfx-duration) linear both;
}
.crownlands-vfx__part--capture-sword-left,
.crownlands-vfx__part--capture-sword-right {
  z-index: 8;
  left: 10%; top: 1.5%; width: 80%; height: 80%;
  opacity: 0;
  transform-origin: 50% 79.1667%;
  animation: crownlandsCaptureSword 1820ms linear both;
  --capture-hand: 1;
}
.crownlands-vfx__part--capture-sword-right { --capture-hand: -1; z-index: 9; }
.crownlands-vfx__part--capture-sword-left svg,
.crownlands-vfx__part--capture-sword-right svg { display: block; width: 100%; height: 100%; }
@keyframes crownlandsCaptureSword {
  0%, 15.38% { opacity: 0; transform: translate(calc(var(--capture-hand) * -60%), -10%) rotate(calc(var(--capture-hand) * -55deg)); }
  23% { opacity: 1; }
  32.97% { opacity: 1; transform: translate(calc(var(--capture-hand) * -29%), 0) rotate(calc(var(--capture-hand) * 43deg)); }
  42% { transform: translate(calc(var(--capture-hand) * -44%), -7%) rotate(calc(var(--capture-hand) * -34deg)); }
  56.04% { transform: translate(calc(var(--capture-hand) * -27%), 1%) rotate(calc(var(--capture-hand) * 52deg)); }
  67% { transform: translate(calc(var(--capture-hand) * -49%), -9%) rotate(calc(var(--capture-hand) * -43deg)); }
  79.12% { opacity: 1; transform: translate(calc(var(--capture-hand) * -25%), 2%) rotate(calc(var(--capture-hand) * 43deg)); }
  85% { opacity: 1; }
  100% { opacity: 0; transform: translate(calc(var(--capture-hand) * -63%), 14%) rotate(calc(var(--capture-hand) * -32deg)); }
}
.crownlands-vfx__part--capture-contact {
  z-index: 10; left: 50%; top: 43%; width: 14%; height: 14%;
  opacity: 0;
  background: radial-gradient(circle, #fff5cb 0 12%, #e4b96566 25%, transparent 68%);
  animation: crownlandsCaptureContact 1820ms linear both;
}
@keyframes crownlandsCaptureContact {
  0%, 32%, 40%, 55%, 63%, 78%, 88%, 100% { opacity: 0; }
  33%, 56%, 79% { opacity: .9; }
}
:is(.crownlands-vfx--city-attack, .crownlands-vfx--city-capture) .crownlands-vfx__particle--spark {
  top: 43%; width: 1.2%; height: 1.2%;
  animation-duration: 270ms;
  box-shadow: 0 0 3px #e8bd70;
}
:is(.crownlands-vfx--city-attack, .crownlands-vfx--city-capture) .crownlands-vfx__particle--spark::after { width: 250%; height: 35%; }
.crownlands-vfx__part--capture-dust {
  z-index: 3; left: 48%; top: 87%; width: 48%; height: 14%;
  border-radius: 50%;
  background: radial-gradient(ellipse, #b39c7180, #8a765630 45%, transparent 72%);
  animation: crownlandsVfxDust 650ms ease-out 1440ms both;
}
.crownlands-vfx__part--capture-pulse {
  z-index: 2; top: 84%; width: 66%; height: 20%;
  border: 1px solid var(--vfx-new-primary); border-radius: 50%;
  animation: crownlandsCapturePulse 660ms ease-out 2230ms both;
}
@keyframes crownlandsCapturePulse {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.7); }
  20% { opacity: .5; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.3); }
}
.crownlands-vfx__part--capture-drape {
  z-index: 7; left: 35%; top: 25%; width: 47.5%; height: 70.6%;
  transform: none;
  filter: drop-shadow(1px 2px 1px #18242766);
  animation: crownlandsCaptureUnfurl 620ms ease-in-out 1820ms both;
}
.crownlands-vfx--city-capture .capture-owner-cloth {
  position: relative; width: 100%; height: 100%;
  border: 1px solid var(--flag-secondary); border-radius: 0;
  clip-path: polygon(0 2%, 18% 0, 42% 3%, 65% 1%, 84% 3%, 100% 2%, 98% 45%, 100% 75%, 98% 98%, 81% 100%, 58% 97%, 37% 100%, 15% 98%, 2% 100%, 0 65%, 2% 35%);
  box-shadow: inset 0 0 0 2px #19252b44;
  transform-origin: 50% 4%;
  animation: crownlandsCaptureCloth 850ms ease-in-out 1860ms both;
}
.capture-owner-cloth .flag-symbol { width: 58%; height: 42%; display: grid; place-items: center; }
.capture-owner-cloth .flag-symbol-icon { width: 100%; height: 100%; object-fit: contain; }
.capture-cloth-folds {
  position: absolute; z-index: 3; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, #152a3855, #f4f0d833 12%, #10202c4d 26%, #ffffff18 43%, #13262f4d 63%, #fffce633 80%, #0e233c66), linear-gradient(#fff6d92b, transparent 15%, #17242822 80%, #fff2c412);
  box-shadow: inset 0 0 0 3px #d6bd7755;
}
@keyframes crownlandsCaptureUnfurl {
  from { opacity: 0; clip-path: inset(0 0 100% 0); }
  8% { opacity: 1; }
  to { opacity: 1; clip-path: inset(0); }
}
@keyframes crownlandsCaptureCloth {
  0% { transform: scaleY(.92) skewX(-2deg); }
  56% { transform: scaleY(1.025) skewX(1.1deg); }
  79% { transform: scaleY(1) skewX(-.5deg); }
  100% { transform: none; }
}
@keyframes crownlandsCaptureEnd { 0%, 93% { opacity: 1; } 100% { opacity: 0; } }
.crownlands-vfx--mode-reduced .crownlands-vfx__part--capture-drape {
  animation: crownlandsCaptureReduced 520ms ease-out both;
}
.crownlands-vfx--mode-reduced .capture-owner-cloth { animation: none; }
@keyframes crownlandsCaptureReduced { 0% { opacity: 0; } 25%, 80% { opacity: 1; } 100% { opacity: 0; } }
.crownlands-vfx--city-attack.crownlands-vfx--mode-reduced :is(.crownlands-vfx__part--capture-sword-left, .crownlands-vfx__part--capture-sword-right) {
  transform: translate(calc(var(--capture-hand) * -29%), 0) rotate(calc(var(--capture-hand) * 43deg));
  animation: crownlandsCaptureReduced 360ms ease-out both;
}

