/* Smooth theme transition */
* {
    transition: background-color 0.3s ease, 
                color 0.3s ease, 
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}

/* Disable transitions during theme change to prevent flash */
.theme-changing * {
    transition: none !important;
}

/* Special effects for theme toggle */
@keyframes themeToggleGlow {
    0% { box-shadow: 0 0 5px var(--primary-color); }
    50% { box-shadow: 0 0 20px var(--primary-color), 0 0 30px var(--primary-color); }
    100% { box-shadow: 0 0 5px var(--primary-color); }
}

.theme-toggle-btn:active {
    animation: themeToggleGlow 0.6s ease;
}

/* Page transition effect */
.theme-transition {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, var(--primary-color) 0%, transparent 70%);
    pointer-events: none;
    opacity: 0;
    z-index: 9999;
    animation: themeTransition 0.6s ease;
}

@keyframes themeTransition {
    0% { opacity: 0; transform: scale(0); }
    50% { opacity: 0.1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1.2); }
}