/* Halloween Animated Icons and SVG Effects */

/* Blinking Eye Animation */
@keyframes blink {
    0%, 90%, 100% {
        transform: scaleY(1);
    }
    95% {
        transform: scaleY(0.1);
    }
}

/* Blood Drip Animation */
@keyframes bloodDrip {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    100% {
        transform: translateY(500%);
        opacity: 0.8;
    }
}

/* Glowing Eyes */
@keyframes glowingEyes {
    0%, 100% {
        opacity: 1;
        filter: drop-shadow(0 0 5px #ff0000);
    }
    50% {
        opacity: 0.7;
        filter: drop-shadow(0 0 20px #ff0000);
    }
}

/* Floating Ghost */
@keyframes floatGhost {
    0%, 100% {
        transform: translateY(0) rotate(-5deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

/* Blood Container for Dripping Effect */
.blood-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    overflow: hidden;
}

.blood-drip {
    position: absolute;
    width: 2px;
    height: 50px;
    background: linear-gradient(to bottom, transparent, #8b0000, #ff0000);
    animation: bloodDrip 3s ease-in infinite;
    opacity: 0;
}

.blood-drip:nth-child(1) { left: 10%; animation-delay: 0s; }
.blood-drip:nth-child(2) { left: 25%; animation-delay: 1.5s; }
.blood-drip:nth-child(3) { left: 45%; animation-delay: 0.5s; }
.blood-drip:nth-child(4) { left: 65%; animation-delay: 2s; }
.blood-drip:nth-child(5) { left: 85%; animation-delay: 1s; }

/* Blinking Eyes in Corner */
.creepy-eyes {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 80px;
    height: 40px;
    z-index: 1000;
    opacity: 0.8;
}

.eye {
    position: absolute;
    width: 30px;
    height: 30px;
    background: radial-gradient(circle, #ff0000 30%, #8b0000 70%);
    border-radius: 50%;
    animation: glowingEyes 3s ease-in-out infinite, blink 5s ease-in-out infinite;
}

.eye:first-child {
    left: 0;
}

.eye:last-child {
    right: 0;
}

.eye::after {
    content: '';
    position: absolute;
    width: 10px;
    height: 10px;
    background: #000;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Icon Replacements with FontAwesome */
.icon-pumpkin::before {
    content: '\f863';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ff8c00;
    filter: drop-shadow(0 0 10px rgba(255, 140, 0, 0.8));
}

.icon-ghost::before {
    content: '\f6e2';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #f8f8ff;
    filter: drop-shadow(0 0 10px rgba(248, 248, 255, 0.8));
    animation: floatGhost 3s ease-in-out infinite;
}

.icon-heart::before {
    content: '\f004';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ff4444;
}

.icon-coins::before {
    content: '\f51e';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #FFD700;
}

.icon-star::before {
    content: '\f005';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ff6b35;
}

.icon-lightbulb::before {
    content: '\f0eb';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ffff00;
}

.icon-flask::before {
    content: '\f0c3';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #39ff14;
}

.icon-trophy::before {
    content: '\f091';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #FFD700;
}

.icon-skull::before {
    content: '\f54c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #f8f8ff;
}

.icon-crystal-ball::before {
    content: '\f52e';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #9370db;
}

.icon-check::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #39ff14;
}

.icon-times::before {
    content: '\f00d';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ff4444;
}

.icon-redo::before {
    content: '\f01e';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

.icon-volume-up::before {
    content: '\f028';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

.icon-volume-mute::before {
    content: '\f6a9';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

.icon-search::before {
    content: '\f002';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

.icon-eye::before {
    content: '\f06e';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

.icon-map::before {
    content: '\f279';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

/* Animated SVG Backgrounds */
.svg-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0.1;
}

/* Cobweb SVG in corners */
.cobweb {
    position: fixed;
    width: 200px;
    height: 200px;
    opacity: 0.3;
    z-index: 1;
}

.cobweb.top-left {
    top: 0;
    left: 0;
}

.cobweb.top-right {
    top: 0;
    right: 0;
    transform: scaleX(-1);
}

/* Spider Animation */
@keyframes spiderDrop {
    0% {
        transform: translateY(-100px);
    }
    50% {
        transform: translateY(50px);
    }
    100% {
        transform: translateY(-100px);
    }
}

.spider {
    position: fixed;
    top: -50px;
    right: 100px;
    width: 40px;
    height: 40px;
    z-index: 1000;
    animation: spiderDrop 10s ease-in-out infinite;
}

.spider::before {
    content: '\f717';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 2rem;
    color: #000;
    filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.8));
}

/* Bat Flying Animation */
@keyframes batFly {
    0% {
        transform: translateX(-100px) translateY(0) rotate(0deg);
    }
    25% {
        transform: translateX(25vw) translateY(-50px) rotate(10deg);
    }
    50% {
        transform: translateX(50vw) translateY(0) rotate(-10deg);
    }
    75% {
        transform: translateX(75vw) translateY(-50px) rotate(10deg);
    }
    100% {
        transform: translateX(100vw) translateY(0) rotate(0deg);
    }
}

.bat {
    position: fixed;
    top: 50px;
    left: -50px;
    font-size: 2rem;
    z-index: 1;
    animation: batFly 20s linear infinite;
    opacity: 0.6;
}

.bat::before {
    content: '\f6b3';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #000;
}

/* Pulsating Cauldron */
@keyframes cauldronBubble {
    0%, 100% {
        transform: scale(1);
        filter: brightness(1);
    }
    50% {
        transform: scale(1.05);
        filter: brightness(1.2);
    }
}

.icon-cauldron {
    animation: cauldronBubble 2s ease-in-out infinite;
}

.icon-cauldron::before {
    content: '\f6d6';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #228b22;
}

/* Spinning Wheel (for loading) */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.icon-spinner::before {
    content: '\f110';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    animation: spin 1s linear infinite;
}

/* Moon Phase */
@keyframes moonGlow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(255, 255, 200, 0.5);
    }
    50% {
        box-shadow: 0 0 40px rgba(255, 255, 200, 0.8);
    }
}

.moon {
    position: fixed;
    top: 50px;
    right: 50px;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, #fffacd 40%, #ffa500 100%);
    border-radius: 50%;
    z-index: 1;
    animation: moonGlow 4s ease-in-out infinite;
    opacity: 0.8;
}

/* Graveyard Cross */
.icon-cross::before {
    content: '\f654';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #808080;
}

/* Candle Flame Flicker */
@keyframes flicker {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

.icon-candle::before {
    content: '\f5e4';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ffa500;
    animation: flicker 2s ease-in-out infinite;
}

/* Witch Hat */
.icon-hat-wizard::before {
    content: '\f6e8';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #800080;
}

/* Bones */
.icon-bone::before {
    content: '\f5d7';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #f5f5dc;
}

/* Magic Wand */
.icon-wand-magic::before {
    content: '\f0d0';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #ff69b4;
}

/* Book Spell */
.icon-book-dead::before {
    content: '\f6b7';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: #8b4513;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .creepy-eyes {
        width: 60px;
        height: 30px;
    }
    
    .eye {
        width: 20px;
        height: 20px;
    }
    
    .cobweb {
        width: 100px;
        height: 100px;
    }
    
    .moon {
        width: 50px;
        height: 50px;
    }
}
