:root{--animate-duration:1s;--animate-delay:1s;--animate-repeat:1}.animated{animation-duration:1s;animation-duration:var(--animate-duration);animation-fill-mode:both}.animated.infinite{animation-iteration-count:infinite}.animated.repeat-1{animation-iteration-count:1;animation-iteration-count:var(--animate-repeat)}.animated.repeat-2{animation-iteration-count:2;animation-iteration-count:calc(var(--animate-repeat)*2)}.animated.repeat-3{animation-iteration-count:3;animation-iteration-count:calc(var(--animate-repeat)*3)}.animated.delay-1s{animation-delay:1s;animation-delay:var(--animate-delay)}.animated.delay-2s{animation-delay:2s;animation-delay:calc(var(--animate-delay)*2)}.animated.delay-3s{animation-delay:3s;animation-delay:calc(var(--animate-delay)*3)}.animated.delay-4s{animation-delay:4s;animation-delay:calc(var(--animate-delay)*4)}.animated.delay-5s{animation-delay:5s;animation-delay:calc(var(--animate-delay)*5)}.animated.faster{animation-duration:.5s;animation-duration:calc(var(--animate-duration)/2)}.animated.fast{animation-duration:.8s;animation-duration:calc(var(--animate-duration)*.8)}.animated.slow{animation-duration:2s;animation-duration:calc(var(--animate-duration)*2)}.animated.slower{animation-duration:3s;animation-duration:calc(var(--animate-duration)*3)}@media (prefers-reduced-motion:reduce),print{.animated{animation-duration:1ms!important;animation-iteration-count:1!important;transition-duration:1ms!important}.animated[class*=Out]{opacity:0}}@keyframes bounce{0%,20%,53%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1);transform:translateZ(0)}40%,43%{animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-30px,0) scaleY(1.1)}70%{animation-timing-function:cubic-bezier(.755,.05,.855,.06);transform:translate3d(0,-15px,0) scaleY(1.05)}80%{transform:translateZ(0) scaleY(.95);transition-timing-function:cubic-bezier(.215,.61,.355,1)}90%{transform:translate3d(0,-4px,0) scaleY(1.02)}}.bounce{animation-name:bounce;transform-origin:center bottom}@keyframes flash{0%,50%,to{opacity:1}25%,75%{opacity:0}}.flash{animation-name:flash}@keyframes pulse{0%{transform:scaleX(1)}50%{transform:scale3d(1.05,1.05,1.05)}to{transform:scaleX(1)}}.pulse{animation-name:pulse;animation-timing-function:ease-in-out}@keyframes rubberBand{0%{transform:scaleX(1)}30%{transform:scale3d(1.25,.75,1)}40%{transform:scale3d(.75,1.25,1)}50%{transform:scale3d(1.15,.85,1)}65%{transform:scale3d(.95,1.05,1)}75%{transform:scale3d(1.05,.95,1)}to{transform:scaleX(1)}}.rubberBand{animation-name:rubberBand}@keyframes shakeX{0%,to{transform:translateZ(0)}10%,30%,50%,70%,90%{transform:translate3d(-10px,0,0)}20%,40%,60%,80%{transform:translate3d(10px,0,0)}}.shakeX{animation-name:shakeX}@keyframes shakeY{0%,to{transform:translateZ(0)}10%,30%,50%,70%,90%{transform:translate3d(0,-10px,0)}20%,40%,60%,80%{transform:translate3d(0,10px,0)}}.shakeY{animation-name:shakeY}@keyframes headShake{0%{transform:translateX(0)}6.5%{transform:translateX(-6px) rotateY(-9deg)}18.5%{transform:translateX(5px) rotateY(7deg)}31.5%{transform:translateX(-3px) rotateY(-5deg)}43.5%{transform:translateX(2px) rotateY(3deg)}50%{transform:translateX(0)}}.headShake{animation-name:headShake;animation-timing-function:ease-in-out}@keyframes swing{20%{transform:rotate(15deg)}40%{transform:rotate(-10deg)}60%{transform:rotate(5deg)}80%{transform:rotate(-5deg)}to{transform:rotate(0deg)}}.swing{animation-name:swing;transform-origin:top center}@keyframes tada{0%{transform:scaleX(1)}10%,20%{transform:scale3d(.9,.9,.9) rotate(-3deg)}30%,50%,70%,90%{transform:scale3d(1.1,1.1,1.1) rotate(3deg)}40%,60%,80%{transform:scale3d(1.1,1.1,1.1) rotate(-3deg)}to{transform:scaleX(1)}}.tada{animation-name:tada}@keyframes wobble{0%{transform:translateZ(0)}15%{transform:translate3d(-25%,0,0) rotate(-5deg)}30%{transform:translate3d(20%,0,0) rotate(3deg)}45%{transform:translate3d(-15%,0,0) rotate(-3deg)}60%{transform:translate3d(10%,0,0) rotate(2deg)}75%{transform:translate3d(-5%,0,0) rotate(-1deg)}to{transform:translateZ(0)}}.wobble{animation-name:wobble}@keyframes jello{0%,11.1%,to{transform:translateZ(0)}22.2%{transform:skewX(-12.5deg) skewY(-12.5deg)}33.3%{transform:skewX(6.25deg) skewY(6.25deg)}44.4%{transform:skewX(-3.125deg) skewY(-3.125deg)}55.5%{transform:skewX(1.5625deg) skewY(1.5625deg)}66.6%{transform:skewX(-.78125deg) skewY(-.78125deg)}77.7%{transform:skewX(.390625deg) skewY(.390625deg)}88.8%{transform:skewX(-.1953125deg) skewY(-.1953125deg)}}.jello{animation-name:jello;transform-origin:center}@keyframes heartBeat{0%{transform:scale(1)}14%{transform:scale(1.3)}28%{transform:scale(1)}42%{transform:scale(1.3)}70%{transform:scale(1)}}.heartBeat{animation-duration:1.3s;animation-duration:calc(var(--animate-duration)*1.3);animation-name:heartBeat;animation-timing-function:ease-in-out}@keyframes backInDown{0%{opacity:.7;transform:translateY(-1200px) scale(.7)}80%{opacity:.7;transform:translateY(0) scale(.7)}to{opacity:1;transform:scale(1)}}.backInDown{animation-name:backInDown}@keyframes backInLeft{0%{opacity:.7;transform:translateX(-2000px) scale(.7)}80%{opacity:.7;transform:translateX(0) scale(.7)}to{opacity:1;transform:scale(1)}}.backInLeft{animation-name:backInLeft}@keyframes backInRight{0%{opacity:.7;transform:translateX(2000px) scale(.7)}80%{opacity:.7;transform:translateX(0) scale(.7)}to{opacity:1;transform:scale(1)}}.backInRight{animation-name:backInRight}@keyframes backInUp{0%{opacity:.7;transform:translateY(1200px) scale(.7)}80%{opacity:.7;transform:translateY(0) scale(.7)}to{opacity:1;transform:scale(1)}}.backInUp{animation-name:backInUp}@keyframes backOutDown{0%{opacity:1;transform:scale(1)}20%{opacity:.7;transform:translateY(0) scale(.7)}to{opacity:.7;transform:translateY(700px) scale(.7)}}.backOutDown{animation-name:backOutDown}@keyframes backOutLeft{0%{opacity:1;transform:scale(1)}20%{opacity:.7;transform:translateX(0) scale(.7)}to{opacity:.7;transform:translateX(-2000px) scale(.7)}}.backOutLeft{animation-name:backOutLeft}@keyframes backOutRight{0%{opacity:1;transform:scale(1)}20%{opacity:.7;transform:translateX(0) scale(.7)}to{opacity:.7;transform:translateX(2000px) scale(.7)}}.backOutRight{animation-name:backOutRight}@keyframes backOutUp{0%{opacity:1;transform:scale(1)}20%{opacity:.7;transform:translateY(0) scale(.7)}to{opacity:.7;transform:translateY(-700px) scale(.7)}}.backOutUp{animation-name:backOutUp}@keyframes bounceIn{0%,20%,40%,60%,80%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:scale3d(.3,.3,.3)}20%{transform:scale3d(1.1,1.1,1.1)}40%{transform:scale3d(.9,.9,.9)}60%{opacity:1;transform:scale3d(1.03,1.03,1.03)}80%{transform:scale3d(.97,.97,.97)}to{opacity:1;transform:scaleX(1)}}.bounceIn{animation-duration:.75s;animation-duration:calc(var(--animate-duration)*.75);animation-name:bounceIn}@keyframes bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0) scaleY(3)}60%{opacity:1;transform:translate3d(0,25px,0) scaleY(.9)}75%{transform:translate3d(0,-10px,0) scaleY(.95)}90%{transform:translate3d(0,5px,0) scaleY(.985)}to{transform:translateZ(0)}}.bounceInDown{animation-name:bounceInDown}@keyframes bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0) scaleX(3)}60%{opacity:1;transform:translate3d(25px,0,0) scaleX(1)}75%{transform:translate3d(-10px,0,0) scaleX(.98)}90%{transform:translate3d(5px,0,0) scaleX(.995)}to{transform:translateZ(0)}}.bounceInLeft{animation-name:bounceInLeft}@keyframes bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0) scaleX(3)}60%{opacity:1;transform:translate3d(-25px,0,0) scaleX(1)}75%{transform:translate3d(10px,0,0) scaleX(.98)}90%{transform:translate3d(-5px,0,0) scaleX(.995)}to{transform:translateZ(0)}}.bounceInRight{animation-name:bounceInRight}@keyframes bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0) scaleY(5)}60%{opacity:1;transform:translate3d(0,-20px,0) scaleY(.9)}75%{transform:translate3d(0,10px,0) scaleY(.95)}90%{transform:translate3d(0,-5px,0) scaleY(.985)}to{transform:translateZ(0)}}.bounceInUp{animation-name:bounceInUp}@keyframes bounceOut{20%{transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;transform:scale3d(1.1,1.1,1.1)}to{opacity:0;transform:scale3d(.3,.3,.3)}}.bounceOut{animation-duration:.75s;animation-duration:calc(var(--animate-duration)*.75);animation-name:bounceOut}@keyframes bounceOutDown{20%{transform:translate3d(0,10px,0) scaleY(.985)}40%,45%{opacity:1;transform:translate3d(0,-20px,0) scaleY(.9)}to{opacity:0;transform:translate3d(0,2000px,0) scaleY(3)}}.bounceOutDown{animation-name:bounceOutDown}@keyframes bounceOutLeft{20%{opacity:1;transform:translate3d(20px,0,0) scaleX(.9)}to{opacity:0;transform:translate3d(-2000px,0,0) scaleX(2)}}.bounceOutLeft{animation-name:bounceOutLeft}@keyframes bounceOutRight{20%{opacity:1;transform:translate3d(-20px,0,0) scaleX(.9)}to{opacity:0;transform:translate3d(2000px,0,0) scaleX(2)}}.bounceOutRight{animation-name:bounceOutRight}@keyframes bounceOutUp{20%{transform:translate3d(0,-10px,0) scaleY(.985)}40%,45%{opacity:1;transform:translate3d(0,20px,0) scaleY(.9)}to{opacity:0;transform:translate3d(0,-2000px,0) scaleY(3)}}.bounceOutUp{animation-name:bounceOutUp}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.fadeIn{animation-name:fadeIn}@keyframes fadeInDown{0%{opacity:0;transform:translate3d(0,-100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInDown{animation-name:fadeInDown}@keyframes fadeInDownBig{0%{opacity:0;transform:translate3d(0,-2000px,0)}to{opacity:1;transform:translateZ(0)}}.fadeInDownBig{animation-name:fadeInDownBig}@keyframes fadeInLeft{0%{opacity:0;transform:translate3d(-100%,0,0)}to{opacity:1;transform:translateZ(0)}}.fadeInLeft{animation-name:fadeInLeft}@keyframes fadeInLeftBig{0%{opacity:0;transform:translate3d(-2000px,0,0)}to{opacity:1;transform:translateZ(0)}}.fadeInLeftBig{animation-name:fadeInLeftBig}@keyframes fadeInRight{0%{opacity:0;transform:translate3d(100%,0,0)}to{opacity:1;transform:translateZ(0)}}.fadeInRight{animation-name:fadeInRight}@keyframes fadeInRightBig{0%{opacity:0;transform:translate3d(2000px,0,0)}to{opacity:1;transform:translateZ(0)}}.fadeInRightBig{animation-name:fadeInRightBig}@keyframes fadeInUp{0%{opacity:0;transform:translate3d(0,100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInUp{animation-name:fadeInUp}@keyframes fadeInUpBig{0%{opacity:0;transform:translate3d(0,2000px,0)}to{opacity:1;transform:translateZ(0)}}.fadeInUpBig{animation-name:fadeInUpBig}@keyframes fadeInTopLeft{0%{opacity:0;transform:translate3d(-100%,-100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInTopLeft{animation-name:fadeInTopLeft}@keyframes fadeInTopRight{0%{opacity:0;transform:translate3d(100%,-100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInTopRight{animation-name:fadeInTopRight}@keyframes fadeInBottomLeft{0%{opacity:0;transform:translate3d(-100%,100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInBottomLeft{animation-name:fadeInBottomLeft}@keyframes fadeInBottomRight{0%{opacity:0;transform:translate3d(100%,100%,0)}to{opacity:1;transform:translateZ(0)}}.fadeInBottomRight{animation-name:fadeInBottomRight}@keyframes fadeOut{0%{opacity:1}to{opacity:0}}.fadeOut{animation-name:fadeOut}@keyframes fadeOutDown{0%{opacity:1}to{opacity:0;transform:translate3d(0,100%,0)}}.fadeOutDown{animation-name:fadeOutDown}@keyframes fadeOutDownBig{0%{opacity:1}to{opacity:0;transform:translate3d(0,2000px,0)}}.fadeOutDownBig{animation-name:fadeOutDownBig}@keyframes fadeOutLeft{0%{opacity:1}to{opacity:0;transform:translate3d(-100%,0,0)}}.fadeOutLeft{animation-name:fadeOutLeft}@keyframes fadeOutLeftBig{0%{opacity:1}to{opacity:0;transform:translate3d(-2000px,0,0)}}.fadeOutLeftBig{animation-name:fadeOutLeftBig}@keyframes fadeOutRight{0%{opacity:1}to{opacity:0;transform:translate3d(100%,0,0)}}.fadeOutRight{animation-name:fadeOutRight}@keyframes fadeOutRightBig{0%{opacity:1}to{opacity:0;transform:translate3d(2000px,0,0)}}.fadeOutRightBig{animation-name:fadeOutRightBig}@keyframes fadeOutUp{0%{opacity:1}to{opacity:0;transform:translate3d(0,-100%,0)}}.fadeOutUp{animation-name:fadeOutUp}@keyframes fadeOutUpBig{0%{opacity:1}to{opacity:0;transform:translate3d(0,-2000px,0)}}.fadeOutUpBig{animation-name:fadeOutUpBig}@keyframes fadeOutTopLeft{0%{opacity:1;transform:translateZ(0)}to{opacity:0;transform:translate3d(-100%,-100%,0)}}.fadeOutTopLeft{animation-name:fadeOutTopLeft}@keyframes fadeOutTopRight{0%{opacity:1;transform:translateZ(0)}to{opacity:0;transform:translate3d(100%,-100%,0)}}.fadeOutTopRight{animation-name:fadeOutTopRight}@keyframes fadeOutBottomRight{0%{opacity:1;transform:translateZ(0)}to{opacity:0;transform:translate3d(100%,100%,0)}}.fadeOutBottomRight{animation-name:fadeOutBottomRight}@keyframes fadeOutBottomLeft{0%{opacity:1;transform:translateZ(0)}to{opacity:0;transform:translate3d(-100%,100%,0)}}.fadeOutBottomLeft{animation-name:fadeOutBottomLeft}@keyframes flip{0%{animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn)}40%{animation-timing-function:ease-out;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg)}50%{animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg)}80%{animation-timing-function:ease-in;transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg)}to{animation-timing-function:ease-in;transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg)}}.animated.flip{animation-name:flip;backface-visibility:visible}@keyframes flipInX{0%{animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateX(90deg)}40%{animation-timing-function:ease-in;transform:perspective(400px) rotateX(-20deg)}60%{opacity:1;transform:perspective(400px) rotateX(10deg)}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}.flipInX{animation-name:flipInX;backface-visibility:visible!important}@keyframes flipInY{0%{animation-timing-function:ease-in;opacity:0;transform:perspective(400px) rotateY(90deg)}40%{animation-timing-function:ease-in;transform:perspective(400px) rotateY(-20deg)}60%{opacity:1;transform:perspective(400px) rotateY(10deg)}80%{transform:perspective(400px) rotateY(-5deg)}to{transform:perspective(400px)}}.flipInY{animation-name:flipInY;backface-visibility:visible!important}@keyframes flipOutX{0%{transform:perspective(400px)}30%{opacity:1;transform:perspective(400px) rotateX(-20deg)}to{opacity:0;transform:perspective(400px) rotateX(90deg)}}.flipOutX{animation-duration:.75s;animation-duration:calc(var(--animate-duration)*.75);animation-name:flipOutX;backface-visibility:visible!important}@keyframes flipOutY{0%{transform:perspective(400px)}30%{opacity:1;transform:perspective(400px) rotateY(-15deg)}to{opacity:0;transform:perspective(400px) rotateY(90deg)}}.flipOutY{animation-duration:.75s;animation-duration:calc(var(--animate-duration)*.75);animation-name:flipOutY;backface-visibility:visible!important}@keyframes lightSpeedInRight{0%{opacity:0;transform:translate3d(100%,0,0) skewX(-30deg)}60%{opacity:1;transform:skewX(20deg)}80%{transform:skewX(-5deg)}to{transform:translateZ(0)}}.lightSpeedInRight{animation-name:lightSpeedInRight;animation-timing-function:ease-out}@keyframes lightSpeedInLeft{0%{opacity:0;transform:translate3d(-100%,0,0) skewX(30deg)}60%{opacity:1;transform:skewX(-20deg)}80%{transform:skewX(5deg)}to{transform:translateZ(0)}}.lightSpeedInLeft{animation-name:lightSpeedInLeft;animation-timing-function:ease-out}@keyframes lightSpeedOutRight{0%{opacity:1}to{opacity:0;transform:translate3d(100%,0,0) skewX(30deg)}}.lightSpeedOutRight{animation-name:lightSpeedOutRight;animation-timing-function:ease-in}@keyframes lightSpeedOutLeft{0%{opacity:1}to{opacity:0;transform:translate3d(-100%,0,0) skewX(-30deg)}}.lightSpeedOutLeft{animation-name:lightSpeedOutLeft;animation-timing-function:ease-in}@keyframes rotateIn{0%{opacity:0;transform:rotate(-200deg)}to{opacity:1;transform:translateZ(0)}}.rotateIn{animation-name:rotateIn;transform-origin:center}@keyframes rotateInDownLeft{0%{opacity:0;transform:rotate(-45deg)}to{opacity:1;transform:translateZ(0)}}.rotateInDownLeft{animation-name:rotateInDownLeft;transform-origin:left bottom}@keyframes rotateInDownRight{0%{opacity:0;transform:rotate(45deg)}to{opacity:1;transform:translateZ(0)}}.rotateInDownRight{animation-name:rotateInDownRight;transform-origin:right bottom}@keyframes rotateInUpLeft{0%{opacity:0;transform:rotate(45deg)}to{opacity:1;transform:translateZ(0)}}.rotateInUpLeft{animation-name:rotateInUpLeft;transform-origin:left bottom}@keyframes rotateInUpRight{0%{opacity:0;transform:rotate(-90deg)}to{opacity:1;transform:translateZ(0)}}.rotateInUpRight{animation-name:rotateInUpRight;transform-origin:right bottom}@keyframes rotateOut{0%{opacity:1}to{opacity:0;transform:rotate(200deg)}}.rotateOut{animation-name:rotateOut;transform-origin:center}@keyframes rotateOutDownLeft{0%{opacity:1}to{opacity:0;transform:rotate(45deg)}}.rotateOutDownLeft{animation-name:rotateOutDownLeft;transform-origin:left bottom}@keyframes rotateOutDownRight{0%{opacity:1}to{opacity:0;transform:rotate(-45deg)}}.rotateOutDownRight{animation-name:rotateOutDownRight;transform-origin:right bottom}@keyframes rotateOutUpLeft{0%{opacity:1}to{opacity:0;transform:rotate(-45deg)}}.rotateOutUpLeft{animation-name:rotateOutUpLeft;transform-origin:left bottom}@keyframes rotateOutUpRight{0%{opacity:1}to{opacity:0;transform:rotate(90deg)}}.rotateOutUpRight{animation-name:rotateOutUpRight;transform-origin:right bottom}@keyframes hinge{0%{animation-timing-function:ease-in-out}20%,60%{animation-timing-function:ease-in-out;transform:rotate(80deg)}40%,80%{animation-timing-function:ease-in-out;opacity:1;transform:rotate(60deg)}to{opacity:0;transform:translate3d(0,700px,0)}}.hinge{animation-duration:2s;animation-duration:calc(var(--animate-duration)*2);animation-name:hinge;transform-origin:top left}@keyframes jackInTheBox{0%{opacity:0;transform:scale(.1) rotate(30deg);transform-origin:center bottom}50%{transform:rotate(-10deg)}70%{transform:rotate(3deg)}to{opacity:1;transform:scale(1)}}.jackInTheBox{animation-name:jackInTheBox}@keyframes rollIn{0%{opacity:0;transform:translate3d(-100%,0,0) rotate(-120deg)}to{opacity:1;transform:translateZ(0)}}.rollIn{animation-name:rollIn}@keyframes rollOut{0%{opacity:1}to{opacity:0;transform:translate3d(100%,0,0) rotate(120deg)}}.rollOut{animation-name:rollOut}@keyframes zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}.zoomIn{animation-name:zoomIn}@keyframes zoomInDown{0%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0)}60%{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}}.zoomInDown{animation-name:zoomInDown}@keyframes zoomInLeft{0%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0)}60%{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(10px,0,0)}}.zoomInLeft{animation-name:zoomInLeft}@keyframes zoomInRight{0%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(1000px,0,0)}60%{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(-10px,0,0)}}.zoomInRight{animation-name:zoomInRight}@keyframes zoomInUp{0%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,1000px,0)}60%{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}}.zoomInUp{animation-name:zoomInUp}@keyframes zoomOut{0%{opacity:1}50%{opacity:0;transform:scale3d(.3,.3,.3)}to{opacity:0}}.zoomOut{animation-name:zoomOut}@keyframes zoomOutDown{40%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,-60px,0)}to{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,2000px,0)}}.zoomOutDown{animation-name:zoomOutDown;transform-origin:center bottom}@keyframes zoomOutLeft{40%{opacity:1;transform:scale3d(.475,.475,.475) translate3d(42px,0,0)}to{opacity:0;transform:scale(.1) translate3d(-2000px,0,0)}}.zoomOutLeft{animation-name:zoomOutLeft;transform-origin:left center}@keyframes zoomOutRight{40%{opacity:1;transform:scale3d(.475,.475,.475) translate3d(-42px,0,0)}to{opacity:0;transform:scale(.1) translate3d(2000px,0,0)}}.zoomOutRight{animation-name:zoomOutRight;transform-origin:right center}@keyframes zoomOutUp{40%{animation-timing-function:cubic-bezier(.55,.055,.675,.19);opacity:1;transform:scale3d(.475,.475,.475) translate3d(0,60px,0)}to{animation-timing-function:cubic-bezier(.175,.885,.32,1);opacity:0;transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0)}}.zoomOutUp{animation-name:zoomOutUp;transform-origin:center bottom}@keyframes slideInDown{0%{transform:translate3d(0,-100%,0);visibility:visible}to{transform:translateZ(0)}}.slideInDown{animation-name:slideInDown}@keyframes slideInLeft{0%{transform:translate3d(-100%,0,0);visibility:visible}to{transform:translateZ(0)}}.slideInLeft{animation-name:slideInLeft}@keyframes slideInRight{0%{transform:translate3d(100%,0,0);visibility:visible}to{transform:translateZ(0)}}.slideInRight{animation-name:slideInRight}@keyframes slideInUp{0%{transform:translate3d(0,100%,0);visibility:visible}to{transform:translateZ(0)}}.slideInUp{animation-name:slideInUp}@keyframes slideOutDown{0%{transform:translateZ(0)}to{transform:translate3d(0,100%,0);visibility:hidden}}.slideOutDown{animation-name:slideOutDown}@keyframes slideOutLeft{0%{transform:translateZ(0)}to{transform:translate3d(-100%,0,0);visibility:hidden}}.slideOutLeft{animation-name:slideOutLeft}@keyframes slideOutRight{0%{transform:translateZ(0)}to{transform:translate3d(100%,0,0);visibility:hidden}}.slideOutRight{animation-name:slideOutRight}@keyframes slideOutUp{0%{transform:translateZ(0)}to{transform:translate3d(0,-100%,0);visibility:hidden}}.slideOutUp{animation-name:slideOutUp}.animated.delay-100ms{animation-delay:.1s}.animated.delay-200ms{animation-delay:.2s}.animated.delay-500ms{animation-delay:.5s}.o-animations-control__popover:not(.is-mobile).is-bottom{z-index:9999999}.o-animations-control__popover .components-popover__content{overflow-y:hidden}.o-animations-control__popover .components-menu-group{padding:7px}.o-animations-control__popover .components-popover__items{max-height:300px;overflow-y:auto}.o-animations-control__popover .components-popover__items button.is-selected{background:#f8f9f9}.o-animations-control__popover .components-popover__items button i{margin-right:5px}.o-animations-control__popover .components-popover__items .o-animations-control__category{font-weight:700}.o-animations-control .components-dropdown{display:flex}.o-animations-control .components-button.is-secondary{margin-top:24px}.o-animations-control .o-animations-control__button{background:transparent;border:1px solid #8d96a0;border-radius:4px;box-shadow:0 0 0 transparent;height:auto;line-height:28px;padding:0 12px 2px;position:relative;transition:box-shadow .1s linear;width:100%}.o-animations-control .o-animations-control__button.is-button{background:transparent}.o-animations-control .o-animations-control__button:hover{background:#fafafa;border-color:#999;box-shadow:inset 0 -1px 0 #999;color:#23282d;text-decoration:none}.o-animations-control .o-animations-control__button:focus{border:1px solid #000}.o-animations-control .o-animations-control__button:after{border-left:3px solid transparent;border-right:3px solid transparent;border-top:5px solid;content:"";display:block;height:0;margin-left:4px;margin-right:2px;pointer-events:none;position:absolute;right:8px;top:12px;width:0}.o-animations-control>.components-unit-control-wrapper{margin-top:10px}.otter-animations-count-image{width:100%}.o-animation-popover .components-popover__content{min-width:240px;padding:20px}.o-animation-popover .components-popover__content .components-heading{margin-bottom:12px}@media screen{.hidden-animated{animation-play-state:paused;visibility:hidden}.animated .wp-block-navigation,.animated.wp-block-navigation{animation-fill-mode:none}}@media(max-width:782px){.o-animations-control .o-animations-control__button{padding:5px 24px 5px 8px}.o-animations-control .o-animations-control__button:after{top:16px}}.block-editor .animated,.block-editor-block-list__layout .animated{animation-play-state:running;visibility:initial}.customize-control-sidebar_block_editor .animated{animation:none}
.o-control-panel-control{padding:10px 0}.o-control-panel-control .components-base-control__title{align-items:center;display:flex;justify-content:space-between}.o-control-panel-control .components-base-control__title label{padding:5px 0}.o-control-panel-control .components-base-control__title .floating-controls .components-dropdown{display:flex}.o-control-panel-control .components-base-control__title .floating-controls .components-dropdown button.is-tertiary{border:none;box-shadow:none;color:#1e1e1e}.o-control-panel-control .components-base-control__title .floating-controls .components-dropdown button.is-active,.o-control-panel-control .components-base-control__title .floating-controls .components-dropdown button.is-tertiary:hover{color:var(--wp-admin-theme-color)}.o-control-panel-control .components-base-control__title .floating-controls .components-dropdown button .dashicon{margin:2px}.otter-popover-settings{min-width:300px;overflow:hidden;padding:10px}.otter-popover-settings .components-button-group:not(.o-toggle-group-control){padding-bottom:10px}/**
 * Portfolio Filter Gallery - Core Styles
 * Lightweight replacement for Bootstrap grid
 * 
 * @package Portfolio_Filter_Gallery
 * @version 2.0.0
 */

/* ==========================================================================
   CSS Variables & Defaults
   ========================================================================== */

.pfg-gallery-wrapper {
  --pfg-cols-xl: 4;
  --pfg-cols-lg: 3;
  --pfg-cols-md: 2;
  --pfg-cols-sm: 1;
  --pfg-gap: 20px;
  --pfg-border-width: 0px;
  --pfg-border-color: #ffffff;
  --pfg-border-radius: 0px;
  --pfg-filter-bg: #3858e9;
  --pfg-filter-text: #ffffff;
  --pfg-overlay-bg: rgba(0, 0, 0, 0.6);
  --pfg-transition: 0.3s ease;

  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu,
    Cantarell, "Helvetica Neue", sans-serif;
  box-sizing: border-box;
}

.pfg-gallery-wrapper *,
.pfg-gallery-wrapper *::before,
.pfg-gallery-wrapper *::after {
  box-sizing: inherit;
}

/* ==========================================================================
   Gallery Preloader
   ========================================================================== */

.pfg-gallery-wrapper.pfg-loading {
  position: relative;
  min-height: 300px;
}

.pfg-gallery-wrapper.pfg-loading .pfg-grid {
  opacity: 0;
  visibility: hidden;
}

.pfg-preloader {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.pfg-preloader-spinner {
  width: 48px;
  height: 48px;
  border: 4px solid #e2e8f0;
  border-top-color: var(--pfg-filter-bg, #3858e9);
  border-radius: 50%;
  animation: pfg-spin 0.8s linear infinite;
}

.pfg-preloader-text {
  font-size: 14px;
  color: #64748b;
}

@keyframes pfg-spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* CSS-only fallback: hide preloader after 3s animation delay */
@keyframes pfg-fade-out {

  0%,
  90% {
    opacity: 1;
    visibility: visible;
  }

  100% {
    opacity: 0;
    visibility: hidden;
  }
}

.pfg-preloader {
  animation: pfg-fade-out 3.5s forwards;
}

.pfg-gallery-wrapper.pfg-loaded .pfg-preloader {
  display: none;
  animation: none;
}

.pfg-gallery-wrapper.pfg-loaded .pfg-grid {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.3s ease;
}

/* ==========================================================================
   Filter Buttons
   ========================================================================== */

.pfg-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 30px;
}

.pfg-filters--top {
  justify-content: flex-start;
}

.pfg-filters--center {
  justify-content: center;
}

.pfg-filters--right {
  justify-content: flex-end;
}

/* ==========================================================================
   Sidebar Layout
   ========================================================================== */

.pfg-gallery-wrapper--sidebar {
  display: flex;
  gap: 30px;
  overflow: visible;
}

.pfg-gallery-wrapper--sidebar-right {
  flex-direction: row-reverse;
}

.pfg-gallery-wrapper--sidebar .pfg-filters {
  flex-direction: column;
  flex-wrap: nowrap;
  flex-shrink: 0;
  width: 240px;
  margin-bottom: 0;
  padding: 16px;
  background: #f8fafc;
  border-radius: 12px;
  align-self: flex-start;
  position: sticky;
  top: 20px;
  max-height: calc(100vh - 40px);
  overflow-x: hidden;
  overflow-y: auto;
  gap: 6px;
}

/* Custom scrollbar for sidebar */
.pfg-gallery-wrapper--sidebar .pfg-filters::-webkit-scrollbar {
  width: 4px;
}

.pfg-gallery-wrapper--sidebar .pfg-filters::-webkit-scrollbar-track {
  background: transparent;
}

.pfg-gallery-wrapper--sidebar .pfg-filters::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.pfg-gallery-wrapper--sidebar .pfg-gallery-main {
  flex: 1;
  min-width: 0;
}

/* Sidebar filter buttons - vertical style */
.pfg-gallery-wrapper--sidebar .pfg-filter {
  width: 100%;
  justify-content: flex-start;
  padding: 10px 14px;
  border-radius: 8px;
  text-align: left;
  font-size: 14px;
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #fff);
  position: relative;
  overflow: visible;
}

.pfg-gallery-wrapper--sidebar .pfg-filter:hover {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #fff));
}

.pfg-gallery-wrapper--sidebar .pfg-filter--active {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #fff));
}

/* Color dot in sidebar - inline with text */
.pfg-gallery-wrapper--sidebar .pfg-filter-color {
  flex-shrink: 0;
}

/* On hover, add a subtle ring/glow around the color dot using its own color */
.pfg-gallery-wrapper--sidebar .pfg-filter:hover .pfg-filter-color {
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.6);
  transform: scale(1.2);
  transition: all 0.2s ease;
}

/* CRITICAL: Override hierarchical filter styles for sidebar */
.pfg-gallery-wrapper--sidebar .pfg-filter-group {
  display: flex !important;
  flex-direction: column !important;
  width: 100% !important;
  margin-bottom: 4px;
}

.pfg-gallery-wrapper--sidebar .pfg-filter--parent {
  width: 100% !important;
}

.pfg-gallery-wrapper--sidebar .pfg-filter-children {
  margin-left: 0;
  margin-top: 4px;
  padding-left: 20px;
  border-left: 2px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}

.pfg-gallery-wrapper--sidebar .pfg-filter-children .pfg-filter {
  padding: 8px 12px;
  font-size: 13px;
  width: 100%;
}

/* Sidebar: Override hierarchical orphan filter white background */
.pfg-gallery-wrapper--sidebar .pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child) {
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #fff);
  border: none;
}

.pfg-gallery-wrapper--sidebar .pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child):hover {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
}

/* Sidebar filter count badge - inline style (not tooltip) */
.pfg-gallery-wrapper--sidebar .pfg-filter-count {
  position: static;
  margin-left: auto;
  background: #e2e8f0;
  padding: 2px 8px;
  border-radius: 10px;
  font-size: 11px;
  color: #64748b;
  opacity: 1;
  transform: none;
  box-shadow: none;
  pointer-events: auto;
  max-width: none;
  overflow: visible;
  display: inline-block;
}

.pfg-gallery-wrapper--sidebar .pfg-filter--active .pfg-filter-count {
  background: rgba(255, 255, 255, 0.2);
  color: inherit;
}

/* Maintain active count styling on hover */
.pfg-gallery-wrapper--sidebar .pfg-filter--active:hover .pfg-filter-count {
  background: rgba(255, 255, 255, 0.3);
  color: inherit;
}

/* Reset hover tooltip style for sidebar */
.pfg-gallery-wrapper--sidebar.pfg-filters--count-hover .pfg-filter-count {
  position: static;
  opacity: 1;
  transform: none;
  top: auto;
  right: auto;
}

/* Responsive sidebar - collapse on mobile */
@media (max-width: 768px) {
  .pfg-gallery-wrapper--sidebar {
    flex-direction: column;
  }

  .pfg-gallery-wrapper--sidebar .pfg-filters {
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    padding: 15px;
    position: static;
    max-height: none;
  }

  .pfg-gallery-wrapper--sidebar .pfg-filter {
    width: auto;
    padding: 8px 16px;
  }

  .pfg-gallery-wrapper--sidebar .pfg-filter-children {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
    flex-direction: row;
    flex-wrap: wrap;
  }
}

.pfg-filter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  border: none;
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #ffffff);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 6px;
  transition:
    background-color 0.25s ease,
    color 0.25s ease,
    transform 0.2s ease,
    opacity 0.2s ease;
}

.pfg-filter-color {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.pfg-filter:hover,
.pfg-filter:focus {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #ffffff));
  outline: none;
}

.pfg-filter--active {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
}

.pfg-filter--active:hover,
.pfg-filter--active:focus {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
  opacity: 0.9;
}

.pfg-filter-count {
  opacity: 0.7;
  font-size: 0.85em;
  margin-left: 2px;
}

/* Hover-only count display - Tooltip style badge */
.pfg-filters--count-hover .pfg-filter {
  position: relative;
}

.pfg-filters--count-hover .pfg-filter-count {
  position: absolute;
  top: -8px;
  right: -8px;
  background: var(--pfg-filter-active-bg, #333);
  color: #fff;
  font-size: 0.7em;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
  opacity: 0;
  transform: scale(0.5) translateY(5px);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
  pointer-events: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
  margin-left: 0;
}

.pfg-filters--count-hover .pfg-filter:hover .pfg-filter-count {
  opacity: 1;
  transform: scale(1) translateY(0);
}

/* ==========================================================================
   Filter Style Variations
   ========================================================================== */

/* Buttons (Default) - Already styled above */
.pfg-filters--buttons .pfg-filter {
  border-radius: 6px;
}

/* Pills - Fully rounded */
.pfg-filters--pills .pfg-filter {
  border-radius: 50px;
  padding: 10px 24px;
}

/* Minimal - Text only, no background, no border */
.pfg-filters--minimal .pfg-filter {
  background: transparent !important;
  border: none !important;
  padding: 8px 16px;
  color: #64748b;
  font-weight: 500;
  border-radius: 0;
  box-shadow: none;
  transition:
    color 0.25s ease,
    opacity 0.2s ease;
}

.pfg-filters--minimal .pfg-filter:hover {
  background: transparent !important;
  color: #1e293b;
}

.pfg-filters--minimal .pfg-filter--active {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  font-weight: 600;
}

.pfg-filters--minimal .pfg-filter--active:hover {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  opacity: 0.8;
}

.pfg-filters--minimal .pfg-filter--selected {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  font-weight: 600;
}

/* Outline - Bordered */
.pfg-filters--outline .pfg-filter {
  background: transparent;
  border: 2px solid #e2e8f0;
  color: #64748b;
  padding: 8px 18px;
  border-radius: 6px;
  transition:
    border-color 0.25s ease,
    color 0.25s ease,
    opacity 0.2s ease;
}

.pfg-filters--outline .pfg-filter:hover {
  background: transparent;
  border-color: #94a3b8;
  color: #475569;
}

.pfg-filters--outline .pfg-filter--active {
  background: transparent;
  border-color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
}

.pfg-filters--outline .pfg-filter--active:hover {
  opacity: 0.8;
}

.pfg-filters--outline .pfg-filter--selected {
  background: transparent !important;
  border-color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
}

/* Underline - Only bottom border on active, no other borders */
.pfg-filters--underline .pfg-filter {
  background: transparent !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  padding: 10px 16px;
  color: #64748b;
  font-weight: 500;
  border-radius: 0;
  box-shadow: none;
  transition:
    color 0.25s ease,
    border-color 0.25s ease,
    opacity 0.2s ease;
}

.pfg-filters--underline .pfg-filter:hover {
  background: transparent !important;
  color: #1e293b;
  border-bottom-color: #e2e8f0 !important;
}

.pfg-filters--underline .pfg-filter--active {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  border-bottom-color: var(--pfg-filter-active-bg,
      var(--pfg-filter-bg)) !important;
  font-weight: 600;
}

.pfg-filters--underline .pfg-filter--active:hover {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  opacity: 0.9;
}

.pfg-filters--underline .pfg-filter--selected {
  background: transparent !important;
  color: var(--pfg-filter-active-bg, var(--pfg-filter-bg)) !important;
  border-bottom-color: var(--pfg-filter-active-bg,
      var(--pfg-filter-bg)) !important;
  font-weight: 600;
}

/* Flat - Rectangular buttons, no border-radius, uses theme colors */
.pfg-filters--flat .pfg-filter {
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #ffffff);
  border: none;
  border-radius: 0;
  padding: 10px 22px;
  font-weight: 500;
  box-shadow: none;
}

.pfg-filters--flat .pfg-filter--active {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
}

.pfg-filters--flat .pfg-filter--selected {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
}

/* Flat style: ensure border-radius: 0 overrides hierarchical and other selectors */
.pfg-filters--flat.pfg-filters--hierarchical>.pfg-filter,
.pfg-filters--flat .pfg-filter--parent,
.pfg-filters--flat .pfg-filter--child,
.pfg-filters--flat.pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child),
.pfg-gallery-wrapper--sidebar .pfg-filters--flat .pfg-filter {
  border-radius: 0;
}

/* Multi-select mode - selected filters */
.pfg-filters--multi .pfg-filter--selected {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
  position: relative;
  /* padding-right: 32px;  Make room for checkmark */
}


/* AND/OR Logic Toggle - More prominent styling */
.pfg-logic-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0;
  margin-left: auto;
  border: 2px solid var(--pfg-filter-bg);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.pfg-logic-btn {
  padding: 10px 18px;
  border: none;
  background: transparent;
  color: var(--pfg-filter-bg);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.25s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pfg-logic-btn:hover {
  background: rgba(56, 88, 233, 0.1);
}

.pfg-logic-btn--active {
  background: var(--pfg-filter-bg);
  color: var(--pfg-filter-text);
}

.pfg-logic-btn--active:hover {
  background: var(--pfg-filter-bg);
  opacity: 0.9;
}

/* Hierarchical Filters - Inline groups with children below parent */
.pfg-filters--hierarchical {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-start;
}

.pfg-filter-group {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

.pfg-filter--parent {
  font-weight: 600;
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #fff);
  border-radius: 6px;
  width: fit-content;
}

.pfg-filter--parent:hover {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #fff));
}

.pfg-filter--parent.pfg-filter--active,
.pfg-filter--parent.pfg-filter--selected {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
}

.pfg-filter-children {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-left: 10px;
  margin-left: 4px;
  border-left: 3px solid var(--pfg-filter-bg);
  align-items: center;
}

/* Nested children (3rd level and beyond) */
.pfg-filter-children .pfg-filter-group {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  margin: 0;
  padding: 0;
}

.pfg-filter-children .pfg-filter-children {
  padding-left: 8px;
  margin-left: 3px;
  border-left-width: 2px;
}

.pfg-filter--child {
  font-size: 13px;
  padding: 6px 12px;
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #ffffff);
  border: none;
  border-radius: 6px;
}

.pfg-filter--child:hover {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #ffffff));
}

.pfg-filter--child.pfg-filter--active,
.pfg-filter--child.pfg-filter--selected {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
  border-color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
}

/* Orphan filters - use primary color like standard filters */
.pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child) {
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #ffffff);
  border: none;
  border-radius: 8px;
  padding: 10px 16px;
  align-self: center;
  font-size: 14px;
}

.pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child):hover {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg, #3858e9));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text, #ffffff));
}

/* Active state for orphan filters (All button, standalone filters) */
.pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child).pfg-filter--active,
.pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child).pfg-filter--selected {
  background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
  color: var(--pfg-filter-active-text, var(--pfg-filter-text));
  border-color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
}

/* Mobile responsive styles for hierarchical filters */
@media (max-width: 768px) {

  /* Stack filter groups vertically on mobile */
  .pfg-filters--hierarchical {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .pfg-filter-group {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  /* Parent filters - make them stand out more on mobile */
  .pfg-filters--hierarchical .pfg-filter--parent {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 8px;
    position: relative;
  }

  /* Add visual indicator arrow for parent filters */
  .pfg-filters--hierarchical .pfg-filter--parent::before {
    content: "▶";
    font-size: 10px;
    margin-right: 8px;
    opacity: 0.7;
  }

  /* Children container - clear indentation on mobile */
  .pfg-filters--hierarchical .pfg-filter-children {
    margin-left: 0;
    margin-top: 4px;
    padding-left: 16px;
    border-left: 3px solid rgba(56, 88, 233, 0.3);
    background: rgba(56, 88, 233, 0.02);
    padding-top: 8px;
    padding-bottom: 8px;
    border-radius: 0 8px 8px 0;
  }

  /* Child filters - lighter styling to show subordination */
  .pfg-filters--hierarchical .pfg-filter--child {
    width: 100%;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 500;
    background: #f8fafc;
    color: #475569;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
  }

  .pfg-filters--hierarchical .pfg-filter--child:hover {
    background: #f1f5f9;
    border-color: var(--pfg-filter-bg, #3858e9);
    color: #334155;
    opacity: 1;
  }

  .pfg-filters--hierarchical .pfg-filter--child.pfg-filter--active,
  .pfg-filters--hierarchical .pfg-filter--child.pfg-filter--selected {
    background: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
    color: var(--pfg-filter-text, #fff);
    border-color: var(--pfg-filter-active-bg, var(--pfg-filter-bg));
    font-weight: 600;
  }

  /* Orphan/standalone filters on mobile */
  .pfg-filters--hierarchical>.pfg-filter:not(.pfg-filter--parent):not(.pfg-filter--child) {
    width: 100%;
    padding: 12px 16px;
  }
}

/* Dropdown style filters */
.pfg-filters--dropdown {
  position: relative;
}

.pfg-filters--dropdown select {
  padding: 12px 40px 12px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 14px;
  background: #fff url('data:image/svg+xml;charset=utf-8,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"%3E%3Cpath fill="%23475569" d="M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z"/%3E%3C/svg%3E') right 12px center no-repeat;
  background-size: 16px;
  cursor: pointer;
  min-width: 200px;
  appearance: none;
}

/* Cascading Dropdowns */
.pfg-cascading-dropdowns {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.pfg-dropdown-wrap {
  position: relative;
}

.pfg-filter-select {
  padding: 12px 40px 12px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #1e293b;
  background: #fff url('data:image/svg+xml;charset=utf-8,%3Csvg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"%3E%3Cpath fill="%23475569" d="M5.23 7.21a.75.75 0 011.06.02L10 11.168l3.71-3.938a.75.75 0 111.08 1.04l-4.25 4.5a.75.75 0 01-1.08 0l-4.25-4.5a.75.75 0 01.02-1.06z"/%3E%3C/svg%3E') right 12px center no-repeat;
  background-size: 16px;
  cursor: pointer;
  min-width: 180px;
  appearance: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.pfg-filter-select:hover {
  border-color: #cbd5e1;
}

.pfg-filter-select:focus {
  outline: none;
  border-color: var(--pfg-filter-active-bg, #3858e9);
  box-shadow: 0 0 0 3px rgba(56, 88, 233, 0.15);
}

/* Parent dropdown styling */
.pfg-parent-select {
  font-weight: 600;
}

/* Child dropdown styling */
.pfg-child-select {
  background-color: #f8fafc;
  border-color: #e2e8f0;
}

.pfg-child-select:focus,
.pfg-level2-select:focus,
.pfg-level3-select:focus {
  background-color: #fff;
}

/* Disabled dropdown state */
.pfg-filter-select:disabled {
  background-color: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
  opacity: 0.7;
}

/* Dropdown arrow indicator between dropdowns */
.pfg-dropdown-level2::before,
.pfg-dropdown-level3::before,
.pfg-dropdown-child::before {
  content: "→";
  position: absolute;
  left: -20px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 14px;
}

/* Responsive cascading dropdowns */
@media (max-width: 576px) {
  .pfg-cascading-dropdowns {
    flex-direction: column;
    width: 100%;
    gap: 8px;
  }

  .pfg-dropdown-wrap {
    width: 100%;
  }

  .pfg-filter-select {
    width: 100%;
    min-width: auto;
  }

  .pfg-dropdown-level2::before,
  .pfg-dropdown-level3::before,
  .pfg-dropdown-child::before {
    content: "↓";
    position: static;
    transform: none;
    display: block;
    text-align: center;
    margin: -4px 0;
  }
}

/* ==========================================================================
   Search Box
   ========================================================================== */

.pfg-search {
  display: flex;
  margin-bottom: 20px;
}

.pfg-search--left {
  justify-content: flex-start;
}

.pfg-search--center {
  justify-content: center;
}

.pfg-search--right {
  justify-content: flex-end;
}

.pfg-search-input {
  width: 100%;
  max-width: 300px;
  padding: 12px 16px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 14px;
  transition: border-color var(--pfg-transition);
}

.pfg-search-input:focus {
  outline: none;
  border-color: var(--pfg-filter-bg);
  box-shadow: 0 0 0 3px rgba(56, 88, 233, 0.1);
}

/* ==========================================================================
   Toolbar Controls (Sort & Shuffle)
   ========================================================================== */

.pfg-toolbar-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.pfg-toolbar-controls--left {
  justify-content: flex-start;
}

.pfg-toolbar-controls--center {
  justify-content: center;
}

.pfg-toolbar-controls--right {
  justify-content: flex-end;
}

.pfg-toolbar-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  font-size: 13px;
  font-weight: 500;
  border-radius: 6px;
  cursor: pointer;
  transition: all var(--pfg-transition);
}

.pfg-toolbar-btn:hover {
  background: #f8fafc;
  color: var(--pfg-filter-active-bg, #3858e9);
  border-color: var(--pfg-filter-active-bg, #3858e9);
}

.pfg-toolbar-btn:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(56, 88, 233, 0.15);
}

.pfg-toolbar-icon {
  flex-shrink: 0;
}

/* ==========================================================================
   Gallery Grid
   ========================================================================== */

.pfg-grid {
  display: grid;
  grid-template-columns: repeat(var(--pfg-cols-sm), 1fr);
  gap: var(--pfg-gap);
}

/* Base item styles for all layouts */
/* NOTE: Transitions are controlled by JavaScript to prevent double-animation issues */
.pfg-item {
  will-change: transform, opacity;
}

/* Visible items - full opacity and scale */
.pfg-item.pfg-item--visible {
  opacity: 1;
  transform: scale(1);
}

/* Phase 1: HIDING - Fade out animation (stays in layout for smooth exit) */
.pfg-item.pfg-item--hiding {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  transition:
    transform 0.25s cubic-bezier(0.33, 1, 0.68, 1),
    opacity 0.2s ease-out;
}

/* Phase 2: HIDDEN - Fully collapsed (after animation completes) */
.pfg-item.pfg-item--hidden {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
  /* Now collapse from layout */
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  margin: 0;
  padding: 0;
  border: 0;
  visibility: hidden;
}

@media (min-width: 576px) {
  .pfg-grid {
    grid-template-columns: repeat(var(--pfg-cols-sm), 1fr);
  }
}

@media (min-width: 768px) {
  .pfg-grid {
    grid-template-columns: repeat(var(--pfg-cols-md), 1fr);
  }
}

@media (min-width: 992px) {
  .pfg-grid {
    grid-template-columns: repeat(var(--pfg-cols-lg), 1fr);
  }
}

@media (min-width: 1200px) {
  .pfg-grid {
    grid-template-columns: repeat(var(--pfg-cols-xl), 1fr);
  }
}

/* Masonry layout - JS-powered absolute positioning (horizontal ordering) */
.pfg-grid--masonry {
  display: block;
  position: relative;
  overflow: hidden;
  transition: height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-grid--masonry .pfg-item {
  position: absolute;
  border-radius: var(--pfg-radius, 8px);
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  opacity: 1;
  transform: scale(1);
  /* Smooth position transitions for filtering */
  transition:
    left 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    top 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.25s ease-out,
    transform 0.25s ease-out;
}

/* Items waiting for JS positioning */
.pfg-grid--masonry .pfg-item:not(.pfg-item--positioned),
.pfg-grid--packed.pfg-grid--packed-cards .pfg-item:not(.pfg-item--positioned) {
  opacity: 0;
}

/* Items positioned by JS */
.pfg-grid--masonry .pfg-item.pfg-item--positioned {
  opacity: 1;
  transform: scale(1);
}

/* Phase 1: HIDING in masonry - fade out + scale down */
.pfg-grid--masonry .pfg-item.pfg-item--hiding {
  opacity: 0;
  transform: scale(0.9);
  pointer-events: none;
}

/* Phase 2: HIDDEN in masonry - remove from layout */
.pfg-grid--masonry .pfg-item.pfg-item--hidden {
  opacity: 0;
  pointer-events: none;
  position: absolute;
  left: -9999px !important;
  top: -9999px !important;
  width: 0;
  height: 0;
}

/* ==========================================================================
   Grid Layout - Fixed Height Images (non-masonry)
   ========================================================================== */

/* Fixed-height grid: crops images to same aspect ratio */
.pfg-grid--fixed-height .pfg-item {
  aspect-ratio: var(--pfg-grid-aspect, 4 / 3);
  overflow: hidden;
}

.pfg-grid--fixed-height .pfg-item-link {
  display: block;
  width: 100%;
  height: 100%;
}

.pfg-grid--fixed-height .pfg-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Grid with cards/captions: fixed aspect ratio image, caption below */
.pfg-grid--grid .pfg-item {
  display: flex;
  flex-direction: column;
}

.pfg-grid--grid .pfg-item-link {
  display: block;
  width: 100%;
  aspect-ratio: var(--pfg-grid-aspect, 4 / 3);
  overflow: hidden;
}

.pfg-grid--grid .pfg-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.pfg-grid--grid .pfg-item-caption {
  width: 100%;
  padding-top: 10px;
  flex-grow: 1;
  /* Below-image captions stretch to fill card height */
}

/* Grayscale effect */
.pfg-grid--grayscale .pfg-item-image {
  filter: grayscale(100%);
  transition: filter var(--pfg-transition);
}

.pfg-grid--grayscale .pfg-item:hover .pfg-item-image {
  filter: grayscale(0%);
}

/* RTL support */
.pfg-grid[dir="rtl"] {
  direction: rtl;
}

/* ==========================================================================
   Justified Layout
   ========================================================================== */

.pfg-grid--justified {
  display: flex;
  flex-wrap: wrap;
  gap: var(--pfg-gap, 10px);
  align-items: flex-start;
}

.pfg-grid--justified .pfg-item {
  flex-grow: var(--item-aspect, 1);
  flex-shrink: 1;
  flex-basis: calc(var(--pfg-row-height, 200px) * var(--item-aspect, 1));
  min-width: 100px;
  overflow: visible;
  display: flex;
  flex-direction: column;
}

/* Image link container scales height dynamically with aspect ratio to prevent cropping */
.pfg-grid--justified .pfg-item-link {
  width: 100%;
  height: auto;
  aspect-ratio: var(--item-aspect, 1);
  display: block;
  overflow: hidden;
}

.pfg-grid--justified .pfg-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Caption below image can expand naturally */
.pfg-grid--justified .pfg-caption,
.pfg-grid--justified .pfg-item-caption {
  width: 100%;
  padding-top: 10px;
  /* Below-image captions are always visible */
}

/* Last row handling: prevent stretching of items on the last row */
.pfg-grid--justified-last-left {
  justify-content: flex-start;
}

.pfg-grid--justified-last-left .pfg-item:last-child {
  flex-grow: 0;
}

.pfg-grid--justified-last-left::after {
  content: "";
  flex-grow: 999999;
  flex-basis: 0;
  height: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

/* Responsive Justified Layout for Mobile viewports (width <= 576px) */
@media (max-width: 576px) {
  .pfg-grid--justified {
    --pfg-row-height: 140px !important;
  }
  
  .pfg-grid--justified .pfg-item {
    flex-grow: var(--item-aspect, 1) !important;
  }
  
  /* Disable left-aligned last row restrictions on mobile to allow images to grow and fill the row */
  .pfg-grid--justified-last-left .pfg-item:last-child {
    flex-grow: var(--item-aspect, 1) !important;
  }
  
  .pfg-grid--justified-last-left::after {
    display: none !important;
  }
}

/* ==========================================================================
   Packed Layout (CSS Grid Dense)
   ========================================================================== */

/* Default packed layout - mosaic with overlay captions */
.pfg-grid--packed {
  display: grid;
  grid-template-columns: repeat(auto-fill,
      minmax(var(--pfg-packed-min, 150px), 1fr));
  grid-auto-rows: var(--pfg-packed-min, 150px);
  grid-auto-flow: row dense;
  /* Dense packing fills gaps when items span multiple cells */
  gap: var(--pfg-gap, 10px);
}

.pfg-grid--packed .pfg-item {
  overflow: hidden;
}

.pfg-grid--packed .pfg-item-link {
  display: block;
  width: 100%;
  height: 100%;
}

.pfg-grid--packed .pfg-item-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Size variations - spans grid cells */
.pfg-grid--packed .pfg-item--wide {
  grid-column: span 2;
}

.pfg-grid--packed .pfg-item--tall {
  grid-row: span 2;
}

.pfg-grid--packed .pfg-item--large {
  grid-column: span 2;
  grid-row: span 2;
}

/* Packed layout: Caption overlay (default) */
.pfg-grid--packed .pfg-item-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px 15px 15px;
  background: linear-gradient(to top,
      var(--pfg-overlay-color, rgba(0, 0, 0, 0.8)) 0%,
      rgba(0, 0, 0, 0.4) 60%,
      transparent 100%);
  z-index: 5;
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-grid--packed .pfg-item:hover .pfg-item-caption {
  opacity: 1;
  transform: translateY(0);
}

.pfg-grid--packed .pfg-item-caption .pfg-item-title {
  color: var(--pfg-title-color, #fff);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  font-size: 0.95em;
  margin-bottom: 4px;
  display: block;
}

.pfg-grid--packed .pfg-item-caption .pfg-item-categories {
  color: var(--pfg-category-color, rgba(255, 255, 255, 0.85));
  font-size: 0.8em;
  display: block;
}

/* Packed with cards mode - JS-powered mosaic with captions below */
.pfg-grid--packed.pfg-grid--packed-cards {
  position: relative;
  display: block !important;
  /* Override CSS Grid to use JS positioning */
  transition: height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-grid--packed.pfg-grid--packed-cards .pfg-item {
  overflow: hidden;
  /* Clips children to rounded corners */
  border-radius: var(--pfg-radius, 8px);
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  opacity: 1;
  transform: translateY(0) translateZ(0);
  /* JS positioning via custom properties */
  left: var(--pfg-x, 0);
  top: var(--pfg-y, 0);
  will-change: transform, opacity, left, top;
  transition:
    left 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    top 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.25s ease-out,
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  transition-delay: var(--pfg-stagger-delay, 0ms);
}

/* Show items after mosaic layout positions them */
.pfg-grid--packed.pfg-grid--packed-cards .pfg-item.pfg-item--positioned {
  opacity: 1;
  transform: translateY(0) translateZ(0);
}

.pfg-grid--packed.pfg-grid--packed-cards .pfg-item-link {
  display: block;
  overflow: hidden;
  border-radius: 0;
  /* Card handles border radius, not the image container */
}

/* Creative Agency template - top-only border radius (no bottom corners) */
.pfg-template-creative-agency .pfg-item {
  border-radius: var(--pfg-border-radius) var(--pfg-border-radius) 0 0;
}

.pfg-grid--packed.pfg-grid--packed-cards .pfg-item-caption {
  position: static !important;
  background: var(--pfg-caption-bg, #ffffff) !important;
  padding: 12px 10px;
  bottom: auto !important;
  left: auto !important;
  right: auto !important;
  /* Override inherited overlay styles - make visible for cards layout */
  opacity: 1 !important;
  transform: none !important;
}

.pfg-grid--packed.pfg-grid--packed-cards .pfg-item-caption .pfg-item-title {
  color: var(--pfg-caption-text, #1e293b);
  text-shadow: none;
  font-size: 0.9em;
  margin-bottom: 4px;
}

.pfg-grid--packed.pfg-grid--packed-cards .pfg-item-caption .pfg-item-categories {
  color: var(--pfg-primary-color, #3858e9);
  font-size: 0.75em;
}

/* Product price in packed cards - use primary color */
.pfg-grid--packed.pfg-grid--packed-cards .pfg-item-caption .pfg-product-caption-price {
  color: var(--pfg-primary-color, #3858e9);
  font-size: 0.85em;
  font-weight: 600;
}

/* Responsive: reduce spans on small screens */
@media (max-width: 768px) {

  .pfg-grid--packed .pfg-item--wide,
  .pfg-grid--packed .pfg-item--tall,
  .pfg-grid--packed .pfg-item--large {
    grid-column: span 1;
    grid-row: span 1;
  }
}

/* ==========================================================================
   Gallery Items
   ========================================================================== */

.pfg-item {
  position: relative;
  border-radius: var(--pfg-border-radius);
  border: var(--pfg-border-width) solid var(--pfg-border-color);
  background: #f8fafc;
  overflow: hidden;
  /* Clips children to rounded corners */
  /* Smooth animation properties - using cubic-bezier for natural motion */
  opacity: 1;
  transform: scale(1) translateY(0);
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity, transform;
}

/* Hiding state - fade out before removing */
.pfg-item--hiding {
  opacity: 0;
  transform: scale(0.95);
  transition:
    opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

/* Hidden state - completely remove from layout */
.pfg-item--hidden {
  display: none !important;
}

/* Visible items - JavaScript controls the animation */
.pfg-item--visible {
  opacity: 1;
  transform: scale(1);
}

/* Staggered animation delay with natural easing */
.pfg-item[data-delay="1"] {
  transition-delay: 0.02s;
}

.pfg-item[data-delay="2"] {
  transition-delay: 0.04s;
}

.pfg-item[data-delay="3"] {
  transition-delay: 0.06s;
}

.pfg-item[data-delay="4"] {
  transition-delay: 0.08s;
}

.pfg-item[data-delay="5"] {
  transition-delay: 0.1s;
}

.pfg-item[data-delay="6"] {
  transition-delay: 0.12s;
}

.pfg-item-link {
  display: block;
  position: relative;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
}

.pfg-item-image {
  display: block;
  width: 100%;
  height: auto;
  transition: transform var(--pfg-transition);
}

/* ==========================================================================
   Item Overlays
   ========================================================================== */

/* Legacy overlay class (for backwards compatibility) */
.pfg-item-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: var(--pfg-overlay-color, rgba(0, 0, 0, 0.7));
  color: #fff;
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* New overlay caption class */
.pfg-item-caption--overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 50px 15px 15px;
  background: linear-gradient(to top,
      var(--pfg-overlay-color, rgba(0, 0, 0, 0.7)) 0%,
      transparent 100%);
  color: #fff;
  opacity: 0;
  transform: translateY(10px);
  z-index: 5;
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-item:hover .pfg-item-overlay,
.pfg-item:hover .pfg-item-caption--overlay {
  opacity: 1;
  transform: translateY(0);
}

/* Overlay text colors */
.pfg-item-overlay .pfg-item-title,
.pfg-item-caption--overlay .pfg-item-title {
  color: var(--pfg-overlay-title, #fff);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.pfg-item-overlay .pfg-item-categories,
.pfg-item-caption--overlay .pfg-item-categories {
  color: var(--pfg-primary-color, #3858e9);
  font-size: 0.85em;
  margin-top: 4px;
}

.pfg-item-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
}

.pfg-item-number {
  display: inline-block;
  width: 24px;
  height: 24px;
  background: var(--pfg-filter-bg);
  color: var(--pfg-filter-text);
  font-size: 12px;
  font-weight: 600;
  line-height: 24px;
  text-align: center;
  border-radius: 50%;
  margin-bottom: 8px;
}

/* ==========================================================================
   Type Indicator Icons (Video/Link in corner)
   ========================================================================== */

.pfg-item-type-icon {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  transition:
    background 0.2s ease,
    transform 0.2s ease;
}

.pfg-item-type-icon svg {
  display: block;
}

.pfg-item:hover .pfg-item-type-icon {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

.pfg-item-type-icon--video {
  background: rgba(220, 38, 38, 0.85);
  /* YouTube red */
}

.pfg-item:hover .pfg-item-type-icon--video {
  background: rgba(220, 38, 38, 1);
}

/* Vimeo blue color variant */
.pfg-item-type-icon--vimeo {
  background: rgba(26, 183, 234, 0.85);
  /* Vimeo blue #1ab7ea */
}

.pfg-item:hover .pfg-item-type-icon--vimeo {
  background: rgba(26, 183, 234, 1);
}

.pfg-item-type-icon--link {
  background: var(--pfg-primary-color, rgba(59, 130, 246, 0.85));
}

.pfg-item:hover .pfg-item-type-icon--link {
  background: var(--pfg-primary-color, rgba(59, 130, 246, 1));
}

/* ==========================================================================
   Card Caption (title below image) - NOT overlay captions
   ========================================================================== */

.pfg-item-caption:not(.pfg-item-caption--overlay) {
  padding: 14px 16px;
  background: var(--pfg-caption-bg, #ffffff);
  /* Border radius is inherited from parent via overflow:hidden */
}

.pfg-item-caption:not(.pfg-item-caption--overlay) .pfg-item-title {
  margin: 0 0 4px 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--pfg-caption-text, #1e293b);
  line-height: 1.4;
}

.pfg-item-caption:not(.pfg-item-caption--overlay) .pfg-item-categories {
  font-size: 13px;
  color: var(--pfg-filter-bg, #3858e9);
  font-weight: 500;
}

.pfg-item-caption:not(.pfg-item-caption--overlay) .pfg-item-number {
  margin-bottom: 8px;
  color: var(--pfg-caption-text, #1e293b);
}

/* ==========================================================================
   Dual Action Icons (link + lightbox)
   ========================================================================== */

.pfg-item-link--dual {
  display: block;
  position: relative;
  cursor: default;
}

.pfg-item-actions {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  gap: 16px;
  opacity: 0;
  z-index: 10;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-item:hover .pfg-item-actions {
  opacity: 1;
}

.pfg-action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: #1e293b;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition:
    transform 0.25s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1),
    background 0.25s ease;
}

.pfg-action-btn svg {
  width: 22px;
  height: 22px;
}

.pfg-action-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  background: #fff;
  color: var(--pfg-filter-bg, #3858e9);
}

.pfg-action-btn:active {
  transform: scale(1.05);
}

/* Background overlay when dual icons are shown */
.pfg-item-link--dual::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 5;
  pointer-events: none;
}

.pfg-item:hover .pfg-item-link--dual::before {
  opacity: 1;
}

/* Video play button */
.pfg-video-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    transform var(--pfg-transition),
    background var(--pfg-transition);
}

.pfg-video-play svg {
  width: 24px;
  height: 24px;
  margin-left: 3px;
}

.pfg-item:hover .pfg-video-play {
  transform: translate(-50%, -50%) scale(1.1);
  background: #fff;
}

/* ==========================================================================
   Hover Effects
   ========================================================================== */

/* Fade */
.pfg-item-hover--fade:hover .pfg-item-image {
  opacity: 0.85;
}

/* Zoom */
.pfg-item-hover--zoom:hover .pfg-item-image {
  transform: scale(1.08);
}

/* Lift */
.pfg-item-hover--lift {
  transition:
    transform var(--pfg-transition),
    box-shadow var(--pfg-transition);
}

.pfg-item-hover--lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Overlay */
.pfg-item-hover--overlay .pfg-item-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pfg-overlay-bg);
  opacity: 0;
  transition: opacity var(--pfg-transition);
}

.pfg-item-hover--overlay:hover .pfg-item-link::after {
  opacity: 1;
}

/* Slide up */
.pfg-item-hover--slide-up .pfg-item-overlay {
  transform: translateY(100%);
  opacity: 1;
}

.pfg-item-hover--slide-up:hover .pfg-item-overlay {
  transform: translateY(0);
}

/* Dark overlay */
.pfg-item-hover--dark-overlay .pfg-item-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  transition: opacity var(--pfg-transition);
}

.pfg-item-hover--dark-overlay:hover .pfg-item-link::after {
  opacity: 1;
}

/* Color reveal (for grayscale galleries) */
.pfg-item-hover--color-reveal .pfg-item-image {
  filter: grayscale(100%);
}

.pfg-item-hover--color-reveal:hover .pfg-item-image {
  filter: grayscale(0%);
}

/* Subtle */
.pfg-item-hover--subtle:hover .pfg-item-image {
  transform: scale(1.02);
}

/* Overlay zoom */
.pfg-item-hover--overlay-zoom .pfg-item-link::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pfg-overlay-bg);
  opacity: 0;
  transition: opacity var(--pfg-transition);
}

.pfg-item-hover--overlay-zoom:hover .pfg-item-link::after {
  opacity: 1;
}

.pfg-item-hover--overlay-zoom:hover .pfg-item-image {
  transform: scale(1.1);
}

/* Slide in */
.pfg-item-hover--slide-in .pfg-item-overlay {
  transform: translateX(-100%);
  opacity: 1;
  background: var(--pfg-overlay-bg);
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.pfg-item-hover--slide-in:hover .pfg-item-overlay {
  transform: translateX(0);
}

/* ==========================================================================
   Error & Empty States
   ========================================================================== */

.pfg-error,
.pfg-empty {
  padding: 40px 20px;
  text-align: center;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: #dc2626;
}

.pfg-empty {
  background: #f8fafc;
  border-color: #e2e8f0;
  color: #64748b;
}

/* ==========================================================================
   Animation for filtering - Removed CSS animations, now controlled by JavaScript
   ========================================================================== */

/* ==========================================================================
   Accessibility
   ========================================================================== */

.pfg-filter:focus-visible,
.pfg-item-link:focus-visible {
  outline: 2px solid var(--pfg-filter-bg);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {

  .pfg-item,
  .pfg-item-image,
  .pfg-item-overlay,
  .pfg-filter,
  .pfg-video-play {
    transition: none;
    animation: none;
  }
}

/* ==========================================================================
   Print styles
   ========================================================================== */

@media print {

  .pfg-filters,
  .pfg-search,
  .pfg-item-overlay,
  .pfg-video-play {
    display: none;
  }

  .pfg-grid {
    display: block;
  }

  .pfg-item {
    page-break-inside: avoid;
    margin-bottom: 20px;
  }
}

/* ==========================================================================
   Pagination Styles
   ========================================================================== */

/* Hidden by pagination - remove from layout */
.pfg-item--paginated-hidden {
  display: none !important;
}

/* Pagination wrapper */
.pfg-pagination-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 30px;
  gap: 10px;
}

/* Load More Button */
.pfg-load-more {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 32px;
  background: var(--pfg-filter-bg, #3858e9) !important;
  color: var(--pfg-filter-text, #fff) !important;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

@media (hover: hover) {

  .pfg-load-more:hover,
  .pfg-load-more:focus:hover {
    background: var(--pfg-filter-active-bg, #2d4ad4) !important;
    color: var(--pfg-filter-active-text, var(--pfg-filter-text, #ffffff)) !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(56, 88, 233, 0.3);
  }
}

.pfg-load-more:active,
.pfg-load-more:focus,
.pfg-load-more:focus-visible {
  background: var(--pfg-filter-bg, #3858e9) !important;
  color: var(--pfg-filter-text, #fff) !important;
  outline: none !important;
  box-shadow: none !important;
  transform: translateY(0);
}

.pfg-load-more.loading {
  opacity: 0.7;
  pointer-events: none;
}

.pfg-load-more-count {
  opacity: 0.8;
  font-weight: 400;
  font-size: 13px;
}

.pfg-load-more-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: pfgSpin 0.8s linear infinite;
}

/* Numbered Pagination */
.pfg-numbered-pagination {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
}

.pfg-pagination-btn {
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  color: #475569;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.25s ease;
}

.pfg-pagination-btn:hover {
  background: #e2e8f0;
  color: #1e293b;
}

.pfg-pagination-btn.active {
  background: var(--pfg-filter-bg, #3858e9);
  color: var(--pfg-filter-text, #fff);
}

.pfg-pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pfg-pagination-ellipsis {
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 16px;
  font-weight: 600;
  user-select: none;
}

/* Infinite Scroll Loader */
.pfg-scroll-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  color: #64748b;
  font-size: 14px;
}

.pfg-scroll-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid #e2e8f0;
  border-top-color: var(--pfg-filter-bg, #3858e9);
  border-radius: 50%;
  animation: pfgSpin 0.8s linear infinite;
}

.pfg-scroll-trigger {
  height: 1px;
  visibility: hidden;
}

@keyframes pfgSpin {
  to {
    transform: rotate(360deg);
  }
}

/* Load more items animation */
@keyframes pfgSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================================================
   WooCommerce Product Gallery Styles
   ========================================================================== */

/* Product item container */
.pfg-product-item {
  position: relative;
}

.pfg-product-item .pfg-item-inner {
  position: relative;
  overflow: hidden;
}

/* Sale Badge */
.pfg-sale-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 10;
  padding: 4px 10px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
}

/* Product Price */
.pfg-product-price {
  display: block;
  margin: 8px 0;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
}

.pfg-product-price del {
  opacity: 0.6;
  font-size: 13px;
  margin-right: 6px;
}

.pfg-product-price ins {
  text-decoration: none;
  color: #10b981;
}

/* View Product Button */
.pfg-view-product {
  display: inline-block;
  padding: 8px 20px;
  margin-top: 12px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 25px;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
}

.pfg-product-item:hover .pfg-view-product {
  background: #fff;
  color: #1e293b;
  border-color: #fff;
  transform: scale(1.05);
}

/* Out of Stock */
.pfg-out-of-stock .pfg-item-image {
  filter: grayscale(50%);
}

.pfg-out-of-stock::after {
  content: "Out of Stock";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  padding: 8px 16px;
  background: rgba(0, 0, 0, 0.8);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 4px;
}

/* Product overlay enhancements */
.pfg-product-item .pfg-item-overlay {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.pfg-product-item .pfg-item-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
}

/* On Sale Animation */
.pfg-on-sale .pfg-sale-badge {
  animation: pfgPulse 2s ease-in-out infinite;
}

@keyframes pfgPulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.05);
  }
}

/* Product item hover effects */
.pfg-product-item .pfg-item-link:hover .pfg-item-image {
  transform: scale(1.05);
}

/* Product Caption Below Styles */
.pfg-product-item .pfg-item-caption {
  padding: 12px;
  text-align: center;
}

.pfg-product-caption-price {
  display: block;
  margin-top: 6px;
  font-size: 15px;
  font-weight: 600;
  color: #16a34a;
}

.pfg-product-caption-price del {
  color: #94a3b8;
  font-weight: 400;
  margin-right: 6px;
}

.pfg-product-caption-price ins {
  text-decoration: none;
  color: #16a34a;
}

/* View Product Button in Caption */
.pfg-product-caption {
  text-align: center;
}

.pfg-view-product-btn {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 18px;
  background: var(--pfg-primary-color, #3858e9);
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.3s ease;
}

.pfg-view-product-btn:hover {
  background: var(--pfg-hover-color, #2d4ad4);
  color: #fff;
  transform: translateY(-2px);
}

/* Caption in overlay mode - inside link */
.pfg-item-caption--overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 15px;
  background: linear-gradient(transparent,
      var(--pfg-overlay-color, rgba(0, 0, 0, 0.7)));
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-item-link:hover .pfg-item-caption--overlay {
  opacity: 1;
  transform: translateY(0);
}

/* Description in overlay mode */
.pfg-item-caption--overlay .pfg-item-description {
  margin: 4px 0 0 0;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.4;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  padding: 0;
}

/* Product Hover Effects - same as images */
.pfg-item[data-id] .pfg-item-link:hover .pfg-item-image {
  transform: scale(1.05);
}

/* Product overlay - gradient at bottom like images */
.pfg-item .pfg-item-overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: flex-start;
  background: linear-gradient(to top,
      var(--pfg-overlay-color, rgba(0, 0, 0, 0.7)) 0%,
      transparent 100%);
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 20px 15px;
  text-align: left;
  min-height: 80px;
}

.pfg-item .pfg-item-link:hover .pfg-item-overlay {
  opacity: 1;
  transform: translateY(0);
}

/* Product price in overlay */
.pfg-item .pfg-product-price {
  color: var(--pfg-title-color, #fff);
  font-size: 16px;
  font-weight: 600;
  margin-top: 6px;
}

.pfg-item .pfg-product-price del {
  color: rgba(255, 255, 255, 0.6);
  font-weight: 400;
  margin-right: 6px;
}

.pfg-item .pfg-product-price ins {
  text-decoration: none;
}

/* Sale badge positioning */
.pfg-item .pfg-sale-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 5;
}

/* ==========================================================================
   Watermark Overlay
   ========================================================================== */

.pfg-watermark {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  display: flex;
  box-sizing: border-box;
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* Watermark text styling */
.pfg-watermark-text {
  display: inline-block;
  white-space: nowrap;
}

/* Watermark image styling */
.pfg-watermark-image {
  display: block;
  height: auto;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
}

/* Full coverage mode — stretches to fill entire gallery item */
.pfg-watermark-image--cover {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover;
}

/* Position variants */
.pfg-watermark--top-left {
  justify-content: flex-start;
  align-items: flex-start;
  padding: 10px;
}

.pfg-watermark--top-center {
  justify-content: center;
  align-items: flex-start;
  padding: 10px;
}

.pfg-watermark--top-right {
  justify-content: flex-end;
  align-items: flex-start;
  padding: 10px;
}

.pfg-watermark--center {
  justify-content: center;
  align-items: center;
}

.pfg-watermark--bottom-left {
  justify-content: flex-start;
  align-items: flex-end;
  padding: 10px;
}

.pfg-watermark--bottom-center {
  justify-content: center;
  align-items: flex-end;
  padding: 10px;
}

.pfg-watermark--bottom-right {
  justify-content: flex-end;
  align-items: flex-end;
  padding: 10px;
}

/* Ensure proper positioning context for watermark */
.pfg-item-link {
  position: relative;
}

.pfg-item-link--dual {
  position: relative;
}

/* Description below image */
.pfg-item-description {
  margin-top: 8px;
  font-size: 14px;
  color: var(--pfg-caption-text, #64748b);
  line-height: 1.5;
  padding: 0 4px;
}

/* Attachment ID Styles */
.pfg-attachment-id {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background-color: rgba(0, 0, 0, 0.6);
  color: #fff;
  padding: 2px 6px;
  font-size: 11px;
  border-radius: 4px;
  z-index: 10;
  pointer-events: none;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Lightbox video frame size styles for Fancybox and PhotoSwipe
   ========================================================================== */
.pfg-lightbox-video {
  width: 90vw !important;
  height: 50.625vw !important;
  max-width: calc(85vh * 16 / 9) !important;
  max-height: 85vh !important;
  aspect-ratio: 16 / 9 !important;
  background: #000 !important;
  border: none !important;
  border-radius: 0 !important;
}

.pfg-lightbox-video iframe,
.pfg-lightbox-video video {
  width: 100% !important;
  height: 100% !important;
  border: none !important;
  outline: none !important;
  object-fit: contain !important;
}

/* Fancybox 5 Video Styling overrides */
.fancybox__content:has(video),
.fancybox__content:has(iframe) {
  width: 90vw !important;
  height: 50.625vw !important;
  max-width: calc(85vh * 16 / 9) !important;
  max-height: 85vh !important;
  aspect-ratio: 16 / 9 !important;
  background: #000 !important;
}

.fancybox__content>video,
.fancybox__content>iframe {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
}

/* Image Numbering Badge */
.pfg-item-number {
  position: absolute;
  top: 9px;
  left: 9px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--pfg-primary-color, var(--pfg-filter-bg, #3858e9));
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 12px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
  line-height: 1.2;
  pointer-events: none;
}/**
 * Portfolio Filter Gallery - Hover Effects
 *
 * @package Portfolio_Filter_Gallery
 */

/* ==========================================================================
   Base Transitions
   ========================================================================== */

/* Base .pfg-item transition removed - controlled by JavaScript for FLIP animation */
/* Hover effects apply to .pfg-item-image and specific hover classes instead */

.pfg-item-image {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                opacity 0.4s ease,
                filter 0.4s ease;
}

.pfg-item-link {
    position: relative;
    overflow: hidden;
}

/* ==========================================================================
   None - No Effect
   ========================================================================== */

.pfg-item-hover--none .pfg-item-image {
    transition: none;
}

/* ==========================================================================
   Zoom Effect
   ========================================================================== */

.pfg-item-hover--zoom .pfg-item-image {
    transform: scale(1);
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--zoom:hover .pfg-item-image {
    transform: scale(1.1);
}

/* ==========================================================================
   Fade Effect
   ========================================================================== */

.pfg-item-hover--fade .pfg-item-image {
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--fade:hover .pfg-item-image {
    opacity: 0.7;
    transform: scale(1.05);
}

/* Fade effect overlay - smooth transition */
.pfg-item-hover--fade .pfg-item-overlay,
.pfg-item-hover--fade .pfg-item-caption--overlay {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.pfg-item-hover--fade:hover .pfg-item-overlay,
.pfg-item-hover--fade:hover .pfg-item-caption--overlay {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Slide Up Effect - Applies to entire card
   ========================================================================== */

.pfg-item-hover--slide-up {
    position: relative;
    transform: translateY(0);
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--slide-up:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   Blur Effect (Premium)
   ========================================================================== */

.pfg-item-hover--blur .pfg-item-image {
    filter: blur(0);
    transition: filter 0.4s ease, transform 0.4s ease;
}

.pfg-item-hover--blur:hover .pfg-item-image {
    filter: blur(3px);
    transform: scale(1.02);
}

/* Make overlay more visible on blur */
.pfg-item-hover--blur .pfg-item-overlay,
.pfg-item-hover--blur .pfg-item-caption--overlay {
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
        background 0.35s ease;
}

.pfg-item-hover--blur:hover .pfg-item-overlay,
.pfg-item-hover--blur:hover .pfg-item-caption--overlay {
    background: rgba(0, 0, 0, 0.6);
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Grayscale Effect (Premium)
   ========================================================================== */

.pfg-item-hover--grayscale .pfg-item-image {
    filter: grayscale(70%);
    transform: scale(1);
    transition: filter 0.5s ease, transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--grayscale:hover .pfg-item-image {
    filter: grayscale(0%);
    transform: scale(1.08);
    transition: filter 0.5s ease, transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ==========================================================================
   Shine Effect (Premium)
   ========================================================================== */

.pfg-item-hover--shine .pfg-item-link {
    position: relative;
    overflow: hidden;
}

.pfg-item-hover--shine .pfg-item-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.1) 20%,
        rgba(255, 255, 255, 0.4) 50%,
        rgba(255, 255, 255, 0.1) 80%,
        transparent 100%
    );
    transform: skewX(-25deg);
    z-index: 5;
    pointer-events: none;
    transition: left 0s;
}

.pfg-item-hover--shine:hover .pfg-item-link::before {
    left: 150%;
    transition: left 0.8s ease;
}

/* ==========================================================================
   3D Tilt Effect (Premium) - Applies to entire card
   ========================================================================== */

.pfg-item-hover--3d-tilt {
    perspective: 1000px;
    transform-style: preserve-3d;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.pfg-item-hover--3d-tilt:hover {
    transform: perspective(1000px) rotateY(6deg) rotateX(4deg) scale(1.02);
    box-shadow: -8px 12px 30px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Lift Effect
   ========================================================================== */

.pfg-item-hover--lift {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--lift:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   Grow Shadow Effect (Legacy)
   ========================================================================== */

.pfg-item-hover--hvr-grow-shadow,
.pfg-item-hover--grow-shadow {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.pfg-item-hover--hvr-grow-shadow:hover,
.pfg-item-hover--grow-shadow:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Float Shadow Effect (Legacy)
   ========================================================================== */

.pfg-item-hover--hvr-float-shadow,
.pfg-item-hover--float-shadow {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.pfg-item-hover--hvr-float-shadow:hover,
.pfg-item-hover--float-shadow:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 30px rgba(0, 0, 0, 0.15);
}

/* ==========================================================================
   Glow Effect (Legacy)
   ========================================================================== */

.pfg-item-hover--hvr-glow,
.pfg-item-hover--glow {
    transition: box-shadow 0.4s ease;
}

.pfg-item-hover--hvr-glow:hover,
.pfg-item-hover--glow:hover {
    box-shadow: 0 0 25px rgba(56, 88, 233, 0.5);
}

/* ==========================================================================
   Box Shadow Effects (Legacy)
   ========================================================================== */

.pfg-item-hover--hvr-box-shadow-outset,
.pfg-item-hover--box-shadow-outset {
    transition: box-shadow 0.3s ease;
}

.pfg-item-hover--hvr-box-shadow-outset:hover,
.pfg-item-hover--box-shadow-outset:hover {
    box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.2);
}

.pfg-item-hover--hvr-box-shadow-inset,
.pfg-item-hover--box-shadow-inset {
    transition: box-shadow 0.3s ease;
}

.pfg-item-hover--hvr-box-shadow-inset:hover,
.pfg-item-hover--box-shadow-inset:hover {
    box-shadow: inset 0 0 0 4px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Scale Overlay Effect
   ========================================================================== */

.pfg-item-hover--scale-overlay .pfg-item-overlay {
    opacity: 0;
    transform: scale(0.85);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.pfg-item-hover--scale-overlay:hover .pfg-item-overlay {
    opacity: 1;
    transform: scale(1);
}