/* --- Holiday Container --- */
#holiday-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    overflow: hidden;
}

/* --- Snow Canvas --- */
#holiday-snow-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* --- Garland --- */
.holiday-garland {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 50px;
    overflow: hidden;
    background: linear-gradient(to bottom, rgba(255,255,255,0.1) 0%, transparent 100%);
    border-bottom: 1px solid rgba(0,0,0,0.05);
    z-index: 9998;
    pointer-events: none;
}

.holiday-wire {
    position: absolute;
    top: 5px;
    left: 0;
    width: 100%;
    height: 30px;
    border-bottom: 2px solid rgba(100, 100, 100, 0.3);
    z-index: 20;
}

.holiday-bulbs-container {
    position: absolute;
    top: 10px;
    left: 0;
    width: 100%;
    height: 30px;
    display: flex;
    justify-content: space-around;
    align-items: flex-start;
    z-index: 10;
}

.holiday-bulb-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 5px;
}

.holiday-bulb {
    width: 10px;
    height: 16px;
    border-radius: 50% 50% 40% 40%;
    position: relative;
    animation: twinkle 3s infinite ease-in-out;
    box-shadow: 0 0 8px currentColor;
    filter: drop-shadow(0 0 2px rgba(0,0,0,0.3));
    z-index: 1;
    margin-top: 0;
    transform: rotate(180deg);
}

.holiday-bulb::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 3px;
    width: 4px;
    height: 5px;
    background: rgba(200, 200, 200, 0.5);
    border-radius: 1px;
    /* Better connection to wire */
    box-shadow: 0 -1px 1px rgba(0,0,0,0.1);
}

.holiday-bulb.red { background-color: #ff6b6b; color: #ff6b6b; animation-delay: 0s; }
.holiday-bulb.blue { background-color: #48dbfb; color: #48dbfb; animation-delay: 0.75s; }
.holiday-bulb.yellow { background-color: #feca57; color: #feca57; animation-delay: 1.5s; }
.holiday-bulb.green { background-color: #1dd1a1; color: #1dd1a1; animation-delay: 2.25s; }

@keyframes twinkle {
    0%, 100% { opacity: 0.6; transform: scale(0.95) rotate(180deg); box-shadow: 0 0 3px currentColor; }
    50% { opacity: 1; transform: scale(1.05) rotate(180deg); box-shadow: 0 0 12px currentColor; }
}

/* --- Control Panel --- */
.holiday-control-panel {
    position: fixed;
    top: 70px;
    right: -250px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    pointer-events: auto;
    z-index: 10000;
    border: 1px solid rgba(0,0,0,0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    width: 220px;
    transition: right 0.3s ease;
}

.holiday-control-panel.visible {
    right: 20px;
}

.holiday-control-panel h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.holiday-control-panel h4 .close-btn {
    cursor: pointer;
    font-size: 16px;
    color: #999;
}

.holiday-toggle-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 13px;
    color: #555;
}

.holiday-toggle-row:last-child {
    margin-bottom: 0;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 20px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 20px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

.toggle-switch input:checked + .toggle-slider {
    background-color: #4CAF50;
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

/* --- Panel Toggle Button --- */
.holiday-panel-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    cursor: pointer;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #666;
    border: 1px solid rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    pointer-events: auto;
}

.holiday-panel-toggle:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.1);
}

/* --- Mobile Adaptation --- */
@media (max-width: 768px) {
    .holiday-wire { 
        height: 20px; 
        border-bottom-width: 1px; 
    }
    .holiday-bulbs-container {
        top: 8px;
        height: 20px;
    }
    .holiday-bulb { 
        width: 7px; 
        height: 12px; 
    }
    .holiday-panel-toggle { 
        bottom: 20px; 
        right: 20px; 
    }
    .holiday-control-panel { 
        top: auto; 
        bottom: 80px; 
        right: -250px; 
        width: 180px; 
    }
    .holiday-control-panel.visible {
        right: 20px;
    }
    .holiday-bulb-container {
        margin-top: 3px;
    }
}
