/* =========================================
   COMMON FESTIVAL ANIMATION CONTAINER
========================================= */

#festival-effects {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: visible;
    pointer-events: none;
    z-index: 99999;
}


/* =========================================
   COMMON FESTIVAL PARTICLES
========================================= */

.festival-particle {
    position: absolute;
    top: -30px;
    pointer-events: none;
    user-select: none;
    animation: festivalParticleFall linear infinite;
    will-change: transform;
}

.festival-particle.sparkles {
    color: #ffd700;
    text-shadow: 0 0 10px orange;
}

.festival-particle.colors {
    color: #ff1493;
    text-shadow: 0 0 10px currentColor;
}

.festival-particle.stars {
    color: #ffd700;
    text-shadow: 0 0 10px gold;
}

@keyframes festivalParticleFall {
    0% {
        transform: translateY(-30px) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(110vh) rotate(360deg);
        opacity: 0;
    }
}


/* =========================================
   CHRISTMAS SNOWFALL
========================================= */

.festival-snowflake {
    position: absolute;
    top: -30px;
    color: #fff;
    line-height: 1;
    user-select: none;
    pointer-events: none;
    animation-name: festivalSnowfall;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    will-change: transform;
}

@keyframes festivalSnowfall {
    0% {
        transform: translate3d(0, -30px, 0) rotate(0deg);
    }

    100% {
        transform: translate3d(40px, 110vh, 0) rotate(360deg);
    }
}


/* =========================================
   CHRISTMAS SIDE DECORATIONS
========================================= */

.christmas-premium-side {
    position: fixed;
    top: 10%;
    height: 100vh;
    width: 90px;
    z-index: 99998;
    pointer-events: none;
}

.christmas-side-left {
    left: 0;
}

.christmas-side-right {
    right: 0;
    transform: scaleX(-1);
}

/* Pine Garland */

.christmas-pine {
    position: absolute;
    left: 28px;
    top: 0;
    width: 35px;
    height: 100%;
    border-left: 5px solid #17652c;
    border-radius: 50%;
    filter: drop-shadow(0 0 5px #0b5920);
}

.christmas-pine::before {
    content: "🌿";
    position: absolute;
    font-size: 65px;
    top: 5%;
    left: -32px;
    writing-mode: vertical-rl;
    letter-spacing: -18px;
}

/* Fairy Lights */

.christmas-garland-lights {
    position: absolute;
    top: 5%;
    left: 8px;
    height: 90%;
    width: 45px;
    border-left: 2px dashed #d4a52b;
    border-radius: 50%;
}

.christmas-garland-lights::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle, #ff3030 0 4px, transparent 6px) 0 0 / 30px 65px,
        radial-gradient(circle, #ffe45c 0 4px, transparent 7px) 12px 25px / 30px 65px,
        radial-gradient(circle, #00e676 0 4px, transparent 7px) 0 45px / 30px 65px;
    filter: drop-shadow(0 0 6px #ffdc55);
    animation: christmasLightsGlow 1.2s infinite alternate;
}

@keyframes christmasLightsGlow {
    from {
        opacity: .55;
        filter: brightness(.7);
    }

    to {
        opacity: 1;
        filter: brightness(1.5);
    }
}

/* Hanging Baubles */

.christmas-bauble {
    position: absolute;
    font-size: 25px;
    text-shadow: 0 0 12px currentColor;
    animation: baubleSwing 3s ease-in-out infinite alternate;
}

.bauble-red {
    color: #e51d36;
    top: 18%;
    left: 45px;
}

.bauble-gold {
    color: #ffd700;
    top: 43%;
    left: 10px;
    font-size: 20px;
    animation-delay: .5s;
}

.bauble-green {
    color: #00a84f;
    top: 68%;
    left: 48px;
    animation-delay: 1s;
}

@keyframes baubleSwing {
    from {
        transform: rotate(-15deg) scale(.9);
    }

    to {
        transform: rotate(15deg) scale(1.1);
    }
}

/* Stars, Bell and Gift */

.christmas-star,
.christmas-bell,
.christmas-gift {
    position: absolute;
    filter: drop-shadow(0 0 7px gold);
}

.christmas-star {
    color: #ffd700;
    font-size: 28px;
    animation: starTwinkle 1.5s infinite alternate;
}

.star-one {
    top: 32%;
    left: 48px;
}

.star-two {
    top: 57%;
    left: 5px;
    font-size: 23px;
}

.christmas-bell {
    top: 82%;
    left: 42px;
    font-size: 27px;
}

.christmas-gift {
    top: 5%;
    left: 45px;
    font-size: 25px;
}

@keyframes starTwinkle {
    from {
        opacity: .4;
        transform: scale(.8);
    }

    to {
        opacity: 1;
        transform: scale(1.2);
    }
}


/* =========================================
   CHRISTMAS BOTTOM FAIRY LIGHTS
========================================= */

.christmas-bottom-lights {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 55px;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    padding: 0 10px 12px;
    box-sizing: border-box;
    z-index: 99998;
    pointer-events: none;
    background: linear-gradient(transparent 0%,
            rgba(0, 50, 20, 0.12) 100%);
}

/* Hanging Wire */

.christmas-bottom-lights::before {
    content: "";
    position: absolute;
    top: 8px;
    left: 0;
    width: 100%;
    height: 22px;
    border-top: 2px solid #164b2b;
    border-radius: 50%;
}

/* Bulbs */

.christmas-bottom-bulb {
    position: relative;
    width: 12px;
    height: 17px;
    border-radius: 50% 50% 45% 45%;
    background: #ff3030;
    box-shadow: 0 0 8px #ff3030, 0 0 18px #ff3030;
    animation: bottomBulbGlow 1.2s infinite alternate;
}

.christmas-bottom-bulb:nth-child(4n+1) {
    background: #ff3030;
    box-shadow: 0 0 10px #ff3030, 0 0 20px #ff3030;
}

.christmas-bottom-bulb:nth-child(4n+2) {
    background: #00e676;
    box-shadow: 0 0 10px #00e676, 0 0 20px #00e676;
}

.christmas-bottom-bulb:nth-child(4n+3) {
    background: #ffeb3b;
    box-shadow: 0 0 10px #ffeb3b, 0 0 20px #ffeb3b;
}

.christmas-bottom-bulb:nth-child(4n) {
    background: #2196f3;
    box-shadow: 0 0 10px #2196f3, 0 0 20px #2196f3;
}

@keyframes bottomBulbGlow {
    from {
        opacity: .45;
        transform: scale(.8);
        filter: brightness(.7);
    }

    to {
        opacity: 1;
        transform: scale(1.15);
        filter: brightness(1.5);
    }
}


/* =========================================
   DIWALI SIDE DECORATIONS
========================================= */

.diwali-side-decor {
    position: fixed;
    top: 10%;
    height: 80vh;
    width: 75px;
    z-index: 99998;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
    pointer-events: none;
}

.diwali-side-decor.festival-side-left {
    left: 5px;
}

.diwali-side-decor.festival-side-right {
    right: 5px;
}

/* Diwali Lanterns */

.diwali-lantern {
    font-size: 35px;
    animation: diwaliFloat 2s infinite alternate;
    filter: drop-shadow(0 0 10px orange);
}

.diwali-star {
    color: #ffc107;
    font-size: 25px;
    animation: diwaliGlow 1.5s infinite alternate;
}

@keyframes diwaliFloat {
    from {
        transform: translateY(-8px);
    }

    to {
        transform: translateY(8px);
    }
}

@keyframes diwaliGlow {
    from {
        opacity: .4;
        transform: scale(.8);
    }

    to {
        opacity: 1;
        transform: scale(1.2);
    }
}


/* =========================================
   DIWALI BOTTOM DIYAS
========================================= */

.diwali-bottom-lights {
    position: fixed;
    bottom: 5px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 99998;
    pointer-events: none;
}

.diwali-bottom-diya {
    font-size: 28px;
    animation: diwaliGlow 1s infinite alternate;
    filter: drop-shadow(0 0 8px orange);
}


/* =========================================
   COMMON FESTIVAL GREETING IMAGE
========================================= */

.festival-greeting {
    position: fixed !important;
    left: 25px !important;
    right: auto !important;
    bottom: 75px !important;
    width: 220px;
    max-width: calc(100vw - 30px);
    z-index: 100001;
    text-align: center;
    animation: santaWishEntry 1s ease-out;
    pointer-events: auto;
    box-sizing: border-box;
}

.festival-greeting img {
    display: block;
    width: 100%;
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Close Button */

.festival-wish-close {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #b91c1c;
    color: #fff;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
}

.festival-wish-close:hover {
    background: #7f1111;
}

@keyframes santaWishEntry {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =========================================
   MOBILE RESPONSIVE
========================================= */

@media (max-width: 767px) {

    /* Christmas Side Decorations */

    .christmas-premium-side {
        display: none;
    }

    /* Christmas Bottom Lights */

    .christmas-bottom-lights {
        height: 40px;
        padding-bottom: 8px;
    }

    .christmas-bottom-bulb {
        width: 8px;
        height: 12px;
    }

    /* Diwali Decorations */

    .diwali-side-decor {
        width: 35px;
    }

    .diwali-lantern {
        font-size: 20px;
    }

    .diwali-star {
        font-size: 16px;
    }

    .diwali-bottom-diya {
        font-size: 18px;
    }

    /* Common Greeting */

    .festival-greeting {
        left: 8px !important;
        right: auto !important;
        bottom: 55px !important;
        width: 155px;
    }
}


/* =========================================
   REDUCED MOTION ACCESSIBILITY
========================================= */

@media (prefers-reduced-motion: reduce) {

    .festival-snowflake,
    .festival-particle,
    .christmas-premium-side *,
    .christmas-bottom-bulb,
    .diwali-side-decor *,
    .diwali-bottom-diya,
    .festival-greeting {
        animation: none !important;
    }
}