/* Christmas Theme Styles - Temporary Holiday Decoration */

/* Santa Animation Container - Now in Hero Section */
.christmas-santa-container {
    position: absolute;
    top: 50%;
    left: -500px;
    transform: translateY(-50%);
    z-index: 10001;
    pointer-events: none;
    display: block;
    animation: santaSlide 12s forwards;
    animation-delay: 1s;
    width: auto;
}

/* Santa Sleigh Animation */
.christmas-santa {
    display: flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    transform: scale(0.8);
}

.christmas-santa-icon {
    font-size: 32px;
    animation: santaBounce 0.5s ease-in-out infinite;
}

.christmas-reindeer {
    font-size: 24px;
    animation: reindeerBounce 0.6s ease-in-out infinite;
    animation-delay: 0.1s;
}

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

.christmas-banner {
    background: linear-gradient(135deg, #ffffff 0%, #f8f8f8 50%, #ffffff 100%);
    color: #2B2B2B;
    padding: 30px 70px;
    font-weight: 600;
    font-size: 56px;
    white-space: nowrap;
    box-shadow: 0 8px 35px rgba(0, 0, 0, 0.25), 0 0 50px rgba(255, 255, 255, 0.95), inset 0 0 35px rgba(255, 255, 255, 0.7);
    font-family: 'Caveat', 'Brush Script MT', 'Lucida Handwriting', cursive, serif;
    position: relative;
    overflow: visible;
    border: 4px solid rgba(255, 255, 255, 0.98);
    /* Simple banner shape with rounded ends */
    border-radius: 50px 15px 50px 15px;
    transform: scale(1.2);
    transform-origin: center;
    animation: sparkleGlow 3s ease-in-out infinite;
}

/* Add decorative wavy ribbon ends */
.christmas-banner::before {
    content: '';
    position: absolute;
    top: -12px;
    left: -15px;
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(248, 248, 248, 0.95) 100%);
    border-radius: 50% 0 50% 0;
    transform: rotate(45deg);
    z-index: -1;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.christmas-banner::after {
    content: '';
    position: absolute;
    top: -12px;
    right: -15px;
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(248, 248, 248, 0.95) 100%);
    border-radius: 0 50% 0 50%;
    transform: rotate(-45deg);
    z-index: -1;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.christmas-banner span {
    position: relative;
    z-index: 1;
}

/* Sparkle glow animation for banner */
@keyframes sparkleGlow {
    0%, 100% {
        box-shadow: 0 8px 35px rgba(0, 0, 0, 0.25), 0 0 50px rgba(255, 255, 255, 0.95), inset 0 0 35px rgba(255, 255, 255, 0.7);
    }
    50% {
        box-shadow: 0 8px 35px rgba(0, 0, 0, 0.25), 0 0 60px rgba(255, 255, 255, 1), inset 0 0 40px rgba(255, 255, 255, 0.9);
    }
}

/* Santa Animation Keyframes - Faster movement within hero section */
@keyframes santaSlide {
    0% {
        left: -500px;
        opacity: 0;
        transform: translateY(-50%) translateX(0);
    }
    5% {
        opacity: 1;
    }
    35% {
        left: calc(50% - 250px);
        transform: translateY(-50%) translateX(0);
    }
    40% {
        left: calc(50% - 250px);
        transform: translateY(-50%) translateX(0);
    }
    45% {
        left: calc(50% - 250px);
        transform: translateY(-50%) translateX(0);
    }
    88% {
        opacity: 1;
    }
    100% {
        left: calc(100% + 500px);
        opacity: 0;
        transform: translateY(-50%) translateX(0);
    }
}

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

/* Snowfall Container - Behind all content */
.christmas-snow-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.christmas-snowflake {
    position: absolute;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1em;
    font-family: Arial, sans-serif;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.8);
    animation: snowfall linear infinite;
    user-select: none;
}

/* Snowfall Animation */
@keyframes snowfall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(360deg);
        opacity: 0;
    }
}

/* Christmas Ribbon Decorations - Diagonal Ribbons Across Corners */
.christmas-ribbon {
    position: fixed;
    z-index: 9999;
    pointer-events: none;
    opacity: 0.85;
    overflow: hidden;
}

.christmas-ribbon-top-left {
    top: 0;
    left: 0;
    width: 200%;
    height: 60px;
    transform: rotate(-45deg);
    transform-origin: top left;
    margin-top: -30px;
    margin-left: -50px;
}

.christmas-ribbon-top-right {
    top: 0;
    right: 0;
    width: 200%;
    height: 60px;
    transform: rotate(45deg);
    transform-origin: top right;
    margin-top: -30px;
    margin-right: -50px;
}

.christmas-ribbon-bottom-left {
    bottom: 0;
    left: 0;
    width: 200%;
    height: 60px;
    transform: rotate(45deg);
    transform-origin: bottom left;
    margin-bottom: -30px;
    margin-left: -50px;
}

.christmas-ribbon-bottom-right {
    bottom: 0;
    right: 0;
    width: 200%;
    height: 60px;
    transform: rotate(-45deg);
    transform-origin: bottom right;
    margin-bottom: -30px;
    margin-right: -50px;
}

/* Ribbon SVG Design */
.christmas-ribbon svg {
    width: 100%;
    height: 100%;
}

/* Snow Accumulation Border at Bottom */
.christmas-snow-border {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: linear-gradient(to top, 
        rgba(255, 255, 255, 0.95) 0%,
        rgba(255, 255, 255, 0.85) 30%,
        rgba(255, 255, 255, 0.6) 70%,
        rgba(255, 255, 255, 0) 100%
    );
    z-index: 2;
    pointer-events: none;
    animation: snowAccumulate 30s linear forwards;
    box-shadow: none;
    border: none;
    outline: none;
}

@keyframes snowAccumulate {
    0% {
        height: 0;
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    100% {
        height: 25px;
        opacity: 1;
    }
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .christmas-santa {
        transform: scale(0.8);
    }
    
    .christmas-santa-icon {
        font-size: 24px;
    }
    
    .christmas-banner {
        font-size: 36px;
        padding: 20px 45px;
        transform: scale(1);
    }
    
    .christmas-santa-container {
        left: -400px;
    }
    
    @keyframes santaSlide {
        0% {
            left: -400px;
            opacity: 0;
            transform: translateY(-50%) translateX(0);
        }
        8% {
            opacity: 1;
        }
        40% {
            left: calc(50% - 200px);
            transform: translateY(-50%) translateX(0);
        }
        45% {
            left: calc(50% - 200px);
            transform: translateY(-50%) translateX(0);
        }
        50% {
            left: calc(50% - 200px);
            transform: translateY(-50%) translateX(0);
        }
        55% {
            left: calc(50% - 200px);
            transform: translateY(-50%) translateX(0);
        }
        60% {
            left: calc(50% - 200px);
            transform: translateY(-50%) translateX(0);
        }
        92% {
            opacity: 1;
        }
        100% {
            left: calc(100% + 400px);
            opacity: 0;
            transform: translateY(-50%) translateX(0);
        }
    }
    
    .christmas-ribbon {
        height: 40px;
    }
    
    .christmas-ribbon-top-left,
    .christmas-ribbon-top-right,
    .christmas-ribbon-bottom-left,
    .christmas-ribbon-bottom-right {
        margin-top: -20px;
        margin-bottom: -20px;
        margin-left: -30px;
        margin-right: -30px;
    }
    
    @keyframes santaSlide {
        0% {
            left: -300px;
            opacity: 0;
            transform: translateX(0);
        }
        8% {
            opacity: 1;
        }
        40% {
            left: calc(50% - 150px);
            transform: translateX(0);
        }
        45% {
            left: calc(50% - 150px);
            transform: translateX(0);
        }
        50% {
            left: calc(50% - 150px);
            transform: translateX(0);
        }
        55% {
            left: calc(50% - 150px);
            transform: translateX(0);
        }
        60% {
            left: calc(50% - 150px);
            transform: translateX(0);
        }
        92% {
            opacity: 1;
        }
        100% {
            left: calc(100% + 300px);
            opacity: 0;
            transform: translateX(0);
        }
    }
}

@media (max-width: 480px) {
    .christmas-santa {
        transform: scale(0.7);
    }
    
    .christmas-banner {
        font-size: 24px;
        padding: 12px 25px;
        transform: scale(0.9);
    }
    
    .christmas-santa-container {
        left: -350px;
    }
    
    .christmas-ribbon {
        height: 30px;
    }
    
    .christmas-ribbon-top-left,
    .christmas-ribbon-top-right,
    .christmas-ribbon-bottom-left,
    .christmas-ribbon-bottom-right {
        margin-top: -15px;
        margin-bottom: -15px;
        margin-left: -20px;
        margin-right: -20px;
    }
}

/* Performance Optimizations */
.christmas-santa-container,
.christmas-snow-container,
.christmas-ribbon {
    will-change: transform;
    backface-visibility: hidden;
}

/* Christmas Lights Under Header - Fixed Position at Bottom of Header */
.christmas-lights {
    position: fixed;
    top: 80px; /* Will be overridden by JS to match header height */
    left: 0;
    width: 100%;
    height: auto;
    z-index: 1001;
    pointer-events: none;
    overflow: visible;
}

.christmas-light-string {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: auto;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    padding-bottom: 8px; /* Space from bottom of header */
    margin-bottom: 0;
}

.christmas-light {
    width: 14px;
    height: 18px;
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    background: #ffffff;
    border: 2px solid rgba(0, 0, 0, 0.15);
    box-shadow: 
        0 0 10px rgba(255, 255, 255, 1),
        0 0 20px rgba(255, 255, 255, 0.9),
        0 0 30px rgba(255, 255, 255, 0.7),
        0 0 40px rgba(255, 255, 255, 0.4),
        0 2px 6px rgba(0, 0, 0, 0.2),
        inset 0 -2px 10px rgba(255, 255, 255, 0.8),
        inset 0 2px 4px rgba(255, 255, 255, 1);
    animation: lightTwinkle 1.5s ease-in-out infinite, lightSparkle 2s ease-in-out infinite;
    position: relative;
    transform-origin: center;
}

/* Bulb base/socket */
.christmas-light::before {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 4px;
    background: linear-gradient(to bottom, 
        rgba(100, 100, 100, 0.6) 0%,
        rgba(50, 50, 50, 0.8) 100%
    );
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Sparkle particles */
.christmas-light::after {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 4px;
    background: radial-gradient(circle, rgba(255, 255, 255, 1) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: 50%;
    opacity: 0;
    animation: sparkleParticle 2s ease-in-out infinite;
    pointer-events: none;
    box-shadow: 
        0 0 4px rgba(255, 255, 255, 1),
        0 0 8px rgba(255, 255, 255, 0.8),
        2px -2px 2px rgba(255, 255, 255, 0.6),
        -2px 2px 2px rgba(255, 255, 255, 0.6);
}

/* Vary light sizes for whimsical effect */
.christmas-light:nth-child(3n) {
    width: 16px;
    height: 20px;
}

.christmas-light:nth-child(5n) {
    width: 12px;
    height: 15px;
}

.christmas-light:nth-child(7n) {
    width: 18px;
    height: 22px;
}

/* Stagger sparkle animations */
.christmas-light:nth-child(odd) {
    animation: lightTwinkle 1.5s ease-in-out infinite, lightSparkle 2s ease-in-out infinite;
    animation-delay: 0s, 0s;
}

.christmas-light:nth-child(even) {
    animation: lightTwinkle 1.5s ease-in-out infinite, lightSparkle 2s ease-in-out infinite;
    animation-delay: 0.75s, 1s;
}

.christmas-light:nth-child(3n)::after {
    animation-delay: 0.5s;
}

.christmas-light:nth-child(5n)::after {
    animation-delay: 1s;
}


@keyframes lightTwinkle {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(0.98);
    }
}

@keyframes lightSparkle {
    0%, 100% {
        box-shadow: 
            0 0 10px rgba(255, 255, 255, 1),
            0 0 20px rgba(255, 255, 255, 0.9),
            0 0 30px rgba(255, 255, 255, 0.7),
            0 0 40px rgba(255, 255, 255, 0.4),
            0 2px 6px rgba(0, 0, 0, 0.2),
            inset 0 -2px 10px rgba(255, 255, 255, 0.8),
            inset 0 2px 4px rgba(255, 255, 255, 1);
    }
    25% {
        box-shadow: 
            0 0 15px rgba(255, 255, 255, 1),
            0 0 30px rgba(255, 255, 255, 1),
            0 0 45px rgba(255, 255, 255, 0.9),
            0 0 60px rgba(255, 255, 255, 0.6),
            0 2px 8px rgba(0, 0, 0, 0.2),
            inset 0 -2px 12px rgba(255, 255, 255, 1),
            inset 0 2px 6px rgba(255, 255, 255, 1);
    }
    50% {
        box-shadow: 
            0 0 12px rgba(255, 255, 255, 1),
            0 0 25px rgba(255, 255, 255, 0.95),
            0 0 38px rgba(255, 255, 255, 0.8),
            0 0 50px rgba(255, 255, 255, 0.5),
            0 2px 7px rgba(0, 0, 0, 0.2),
            inset 0 -2px 11px rgba(255, 255, 255, 0.9),
            inset 0 2px 5px rgba(255, 255, 255, 1);
    }
    75% {
        box-shadow: 
            0 0 18px rgba(255, 255, 255, 1),
            0 0 35px rgba(255, 255, 255, 1),
            0 0 50px rgba(255, 255, 255, 0.95),
            0 0 70px rgba(255, 255, 255, 0.7),
            0 2px 9px rgba(0, 0, 0, 0.2),
            inset 0 -2px 14px rgba(255, 255, 255, 1),
            inset 0 2px 7px rgba(255, 255, 255, 1);
    }
}

@keyframes sparkleParticle {
    0%, 100% {
        opacity: 0;
        transform: translateX(-50%) translateY(0) scale(0);
    }
    20% {
        opacity: 1;
        transform: translateX(-50%) translateY(-5px) scale(1);
    }
    40% {
        opacity: 0.8;
        transform: translateX(-50%) translateY(-10px) scale(1.2);
    }
    60% {
        opacity: 0.5;
        transform: translateX(-50%) translateY(-15px) scale(1);
    }
    80% {
        opacity: 0.2;
        transform: translateX(-50%) translateY(-20px) scale(0.8);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(-25px) scale(0);
    }
}

/* Hide Christmas theme when disabled */
body.no-christmas .christmas-santa-container,
body.no-christmas .christmas-snow-container,
body.no-christmas .christmas-ribbon,
body.no-christmas .christmas-lights {
    display: none !important;
}

