* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --vw-color-intensity: 0.5;
    --vw-scan-intensity: 0.5;
    --vw-glitch-frequency: 10s;
    --vw-bloom-intensity: 0.5;
    --vw-aberration: 0.05;
    --clock-bg-opacity: 0.7;
    --bokeh-blur: 20px;
    --bokeh-speed: 15s;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #000;
    overflow: hidden;
    position: relative;
    width: 100vw;
    height: 100vh;
    touch-action: none;
    -webkit-user-select: none;
    user-select: none;
}

/* Slideshow Container */
#slideshow-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: #000;
    cursor: pointer;
}

/* YouTube Video Container */
#youtube-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    z-index: 1;
}

#youtube-player {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 56.25vw; /* 16:9 aspect ratio */
    min-height: 100vh;
    min-width: 177.77vh; /* 16:9 aspect ratio */
}

/* YouTube controls styling */
#youtube-controls {
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 10px;
}

#youtube-controls input[type="range"] {
    background: #333;
    border-radius: 3px;
    height: 6px;
    outline: none;
    opacity: 0.7;
    transition: opacity 0.2s;
}

#youtube-controls input[type="range"]:hover {
    opacity: 1;
}

#youtube-controls input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

#youtube-controls input[type="range"]::-moz-range-thumb {
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    border: none;
}

#youtube-controls button {
    background-color: #444;
    color: white;
    border: 1px solid #666;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.2s;
}

#youtube-controls button:hover {
    background-color: #555;
}

#youtube-volume-display,
#youtube-time-display {
    color: #ccc;
    font-size: 0.9rem;
    min-width: 60px;
    text-align: center;
}

/* Ensure YouTube video covers full screen properly */
@media (max-aspect-ratio: 16/9) {
    #youtube-player {
        width: 177.77vh;
        height: 100vh;
    }
}

@media (min-aspect-ratio: 16/9) {
    #youtube-player {
        width: 100vw;
        height: 56.25vw;
    }
}

#image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

#current-image {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: filter 0.3s ease; /* Faster transition for blur changes */
    min-width: 100%;
    min-height: 100%;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Always use cover behavior for panning images */
#current-image.panning {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

/* For images wider than screen, scale by height and ensure width coverage */
#current-image.panning.landscape {
    width: auto;
    height: 100%;
    min-width: 100%;
    object-fit: cover;
}

/* For images taller than screen, scale by width and ensure height coverage */
#current-image.panning.portrait {
    width: 100%;
    height: auto;
    min-height: 100%;
    object-fit: cover;
}

/* Ken Burns Effect - Slow zoom */
#current-image.ken-burns {
    animation: kenBurns var(--motion-speed, 20s) ease-in-out infinite alternate;
}

@keyframes kenBurns {
    0% {
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        transform: translate(-50%, -50%) scale(1.1);
    }
}

/* Bokeh Overlay */
#bokeh-overlay, #youtube-bokeh-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
    overflow: hidden;
}

#bokeh-overlay.active, #youtube-bokeh-overlay.active {
    opacity: 1;
}

.bokeh-circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(var(--bokeh-blur));
    -webkit-backdrop-filter: blur(var(--bokeh-blur));
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Enhanced Vaporwave Effects */
.vaporwave-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
    z-index: 10;
}

.vaporwave-overlay.active {
    opacity: 1;
}

/* Layer system for vaporwave effects */
.vw-layer-1, .vw-layer-2, .vw-layer-3, .vw-layer-4, .vw-layer-5 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Animated color shift with multiple layers */
.vaporwave-filter {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        45deg,
        rgba(255, 0, 255, calc(0.2 * var(--vw-color-intensity))) 0%,
        rgba(0, 255, 255, calc(0.1 * var(--vw-color-intensity))) 25%,
        rgba(255, 255, 0, calc(0.05 * var(--vw-color-intensity))) 50%,
        rgba(0, 255, 255, calc(0.1 * var(--vw-color-intensity))) 75%,
        rgba(255, 0, 255, calc(0.2 * var(--vw-color-intensity))) 100%
    );
    mix-blend-mode: screen;
    animation: vaporwaveShift 8s ease-in-out infinite, vaporwaveRotate 20s linear infinite;
}

.vaporwave-filter-2 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle at 20% 80%,
        rgba(255, 0, 128, calc(0.3 * var(--vw-color-intensity))) 0%,
        transparent 50%
    ),
    radial-gradient(
        circle at 80% 20%,
        rgba(0, 255, 255, calc(0.3 * var(--vw-color-intensity))) 0%,
        transparent 50%
    );
    mix-blend-mode: multiply;
    animation: vaporwavePulse 10s ease-in-out infinite;
}

@keyframes vaporwaveShift {
    0%, 100% {
        opacity: calc(0.3 * var(--vw-color-intensity));
        transform: translateY(0) scale(1);
    }
    50% {
        opacity: calc(0.6 * var(--vw-color-intensity));
        transform: translateY(-20px) scale(1.02);
    }
}

@keyframes vaporwaveRotate {
    0% {
        filter: hue-rotate(0deg);
    }
    100% {
        filter: hue-rotate(360deg);
    }
}

@keyframes vaporwavePulse {
    0%, 100% {
        transform: scale(1) rotate(0deg);
    }
    50% {
        transform: scale(1.1) rotate(5deg);
    }
}

/* Enhanced scan lines */
.scanlines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(255, 255, 255, calc(0.06 * var(--vw-scan-intensity))) 2px,
        rgba(255, 255, 255, calc(0.06 * var(--vw-scan-intensity))) 4px
    );
    animation: scanlineMove 8s linear infinite;
}

.scanlines::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        transparent 50%,
        rgba(255, 255, 255, calc(0.03 * var(--vw-scan-intensity))) 50%
    );
    background-size: 100% 4px;
    animation: scanlineFlicker 0.15s infinite;
}

@keyframes scanlineMove {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(10px);
    }
}

@keyframes scanlineFlicker {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.95;
    }
}

/* CRT screen curve effect */
.crt-curve {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        ellipse at center,
        transparent 0%,
        transparent 60%,
        rgba(0, 0, 0, 0.4) 100%
    );
}

/* Updated TV static noise that actually works */
.tv-noise {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: calc(0.5 * var(--vw-scan-intensity));
    overflow: hidden;
}

.tv-noise::before {
    content: '';
    position: absolute;
    top: -200%;
    left: -200%;
    width: 400%;
    height: 400%;
    background-image: 
        repeating-linear-gradient(
            0deg,
            transparent 0,
            rgba(255, 255, 255, 0.03) 1px,
            transparent 2px,
            rgba(0, 0, 0, 0.02) 3px,
            transparent 4px
        ),
        repeating-linear-gradient(
            90deg,
            transparent 0,
            rgba(255, 255, 255, 0.03) 1px,
            transparent 2px,
            rgba(0, 0, 0, 0.02) 3px,
            transparent 4px
        );
    background-size: 4px 4px;
    animation: staticMove 0.2s steps(5) infinite;
}

@keyframes staticMove {
    0% { transform: translate(0, 0); }
    10% { transform: translate(-5%, -10%); }
    20% { transform: translate(-10%, 5%); }
    30% { transform: translate(5%, -5%); }
    40% { transform: translate(-5%, 15%); }
    50% { transform: translate(-10%, 5%); }
    60% { transform: translate(15%, 0); }
    70% { transform: translate(0, 10%); }
    80% { transform: translate(-15%, 0); }
    90% { transform: translate(10%, 5%); }
    100% { transform: translate(5%, 0); }
}

/* Fixed glitch effect */
.glitch-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    animation: glitchAnimation var(--vw-glitch-frequency) infinite;
    pointer-events: none;
    z-index: 15;
}

@keyframes glitchAnimation {
    0%, 88%, 100% {
        opacity: 0;
        transform: translateX(0);
    }
    89% {
        opacity: 1;
        transform: translateX(2px);
        background: repeating-linear-gradient(
            90deg,
            rgba(255, 0, 255, 0.5) 0px,
            rgba(255, 0, 255, 0.5) 2px,
            transparent 2px,
            transparent 4px
        );
        filter: contrast(10) saturate(10);
    }
    89.5% {
        opacity: 1;
        transform: translateX(-2px);
        background: repeating-linear-gradient(
            90deg,
            rgba(0, 255, 255, 0.5) 0px,
            rgba(0, 255, 255, 0.5) 2px,
            transparent 2px,
            transparent 4px
        );
    }
    90% {
        opacity: 1;
        transform: translateY(1px);
        background: repeating-linear-gradient(
            0deg,
            rgba(255, 255, 0, 0.5) 0px,
            rgba(255, 255, 0, 0.5) 2px,
            transparent 2px,
            transparent 4px
        );
    }
    91% {
        opacity: 0;
        transform: translate(0);
    }
}

.glitch-effect-2 {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    animation: glitchAnimation2 calc(var(--vw-glitch-frequency) * 1.7) infinite;
    z-index: 16;
}

@keyframes glitchAnimation2 {
    0%, 93%, 100% {
        opacity: 0;
    }
    94% {
        opacity: 1;
        clip-path: inset(20% 0 70% 0);
        transform: translateX(-4px);
        background: rgba(255, 0, 128, 0.5);
    }
    94.5% {
        opacity: 1;
        clip-path: inset(50% 0 30% 0);
        transform: translateX(4px);
        background: rgba(0, 255, 255, 0.5);
    }
    95% {
        opacity: 1;
        clip-path: inset(80% 0 5% 0);
        transform: translateX(-2px);
        background: rgba(255, 255, 0, 0.5);
    }
}

/* Animated retro grid */
.retro-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 0, 255, calc(0.2 * var(--vw-color-intensity))) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 255, calc(0.2 * var(--vw-color-intensity))) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: gridMove 20s linear infinite, gridPerspective 10s ease-in-out infinite;
    opacity: calc(0.6 * var(--vw-color-intensity));
    transform-origin: center bottom;
}

@keyframes gridMove {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(50px, 50px);
    }
}

@keyframes gridPerspective {
    0%, 100% {
        transform: perspective(800px) rotateX(25deg) scale(1);
    }
    50% {
        transform: perspective(800px) rotateX(25deg) scale(1.1);
    }
}

/* Enhanced bloom effect */
.bloom-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle at center,
        rgba(255, 100, 200, calc(0.4 * var(--vw-bloom-intensity))) 0%,
        transparent 70%
    );
    animation: bloomPulse 6s ease-in-out infinite, bloomRotate 15s linear infinite;
    mix-blend-mode: screen;
}

@keyframes bloomPulse {
    0%, 100% {
        opacity: calc(0.3 * var(--vw-bloom-intensity));
        transform: scale(1);
    }
    50% {
        opacity: calc(0.6 * var(--vw-bloom-intensity));
        transform: scale(1.2);
    }
}

@keyframes bloomRotate {
    0% {
        filter: hue-rotate(0deg);
    }
    100% {
        filter: hue-rotate(-360deg);
    }
}

/* Working chromatic aberration */
.chromatic-aberration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    mix-blend-mode: screen;
    opacity: calc(var(--vw-aberration) * 2);
    pointer-events: none;
    z-index: 14;
}

#slideshow-container.vaporwave-active .chromatic-aberration::before,
#slideshow-container.vaporwave-active .chromatic-aberration::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to right,
        rgba(255, 0, 0, 0.1) 0%,
        transparent 50%,
        rgba(0, 255, 255, 0.1) 100%
    );
}

#slideshow-container.vaporwave-active .chromatic-aberration::before {
    transform: translateX(calc(var(--vw-aberration) * 3px));
    animation: aberrationShift 3s ease-in-out infinite;
}

#slideshow-container.vaporwave-active .chromatic-aberration::after {
    transform: translateX(calc(var(--vw-aberration) * -3px));
    animation: aberrationShift 3s ease-in-out infinite reverse;
}

@keyframes aberrationShift {
    0%, 100% {
        transform: translateX(calc(var(--vw-aberration) * 3px)) scaleX(1.01);
    }
    50% {
        transform: translateX(calc(var(--vw-aberration) * -3px)) scaleX(0.99);
    }
}

/* Visible wave distortion */
.wave-distortion {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.8;
    pointer-events: none;
    z-index: 13;
}

#slideshow-container.vaporwave-active .wave-distortion {
    background: repeating-linear-gradient(
        0deg,
        transparent 0px,
        transparent 98px,
        rgba(255, 255, 255, 0.03) 98px,
        rgba(255, 255, 255, 0.03) 100px
    );
    animation: waveDistort 2s linear infinite;
    filter: blur(0.5px);
}

@keyframes waveDistort {
    0% {
        transform: translateY(0) scaleY(1);
        background-position: 0 0;
    }
    50% {
        transform: translateY(2px) scaleY(1.02);
        background-position: 0 50px;
    }
    100% {
        transform: translateY(0) scaleY(1);
        background-position: 0 100px;
    }
}

/* Fixed to ensure filters work together */
#slideshow-container.vaporwave-active #current-image {
    transition: filter 0.3s ease;
    /* Removed the animation that was interfering with blur */
}

/* Ensure proper z-indexing */
#slideshow-container.vaporwave-active #image-wrapper {
    isolation: isolate;
}

/* Clock + Controls */
#top-controls {
    position: fixed;
    z-index: 20;
}

#clock-fullscreen-wrap {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: none;
    background: none;
    position: relative;
    transition: box-shadow 0.3s ease;
}

#clock-fullscreen-wrap:hover {
    box-shadow: 0 2px 16px 0 rgba(0,0,0,0.13);
}

/* Move shadow to wrapper when controls are being hovered */
#clock-fullscreen-wrap:hover #clock-controls-stack,
#clock-controls-stack:hover {
    /* No additional shadow needed, parent handles it */
}

/* Add a larger hover zone for better UX */
#clock-fullscreen-wrap::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -20px;
    z-index: -1;
    pointer-events: auto;
}

#clock-fullscreen-wrap:hover::before {
    pointer-events: none;
}

#clock-container {
    background-color: rgba(0, 0, 0, var(--clock-bg-opacity));
    color: white;
    padding: 15px 25px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 16px 0 rgba(0,0,0,0.13);
}

#clock-container:hover {
    background-color: rgba(0, 0, 0, calc(var(--clock-bg-opacity) + 0.15));
}

/* When controls are visible, clock should only have top rounded corners and no shadow */
#clock-fullscreen-wrap:hover #clock-container,
#clock-controls-stack:hover + #clock-container {
    border-radius: 10px 10px 0 0;
    box-shadow: none;
}

#clock {
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 2px;
    font-variant-numeric: tabular-nums;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

#clock .time {
    display: block;
    line-height: 1.2;
    font-size: 1em;
}

#clock .date-info {
    font-size: 0.75em;
    margin-top: 2px;
    opacity: 0.9;
    display: block;
    line-height: 1.1;
    font-weight: 300;
}

/* When both date and day are shown, make them more compact */
#clock .date-info.has-both {
    font-size: 0.65em;
    line-height: 1.0;
}

/* Media query for smaller screens - stack the content */
@media (max-width: 480px) {
    #clock .date-info {
        font-size: 0.6em;
    }
    
    #clock .date-info.has-both {
        font-size: 0.55em;
    }
}

/* Controls Stack - Now horizontal with autohide */
#clock-controls-stack {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    background: none;
    transform: translateY(-100%);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    pointer-events: none;
}

#clock-fullscreen-wrap:hover #clock-controls-stack,
#clock-controls-stack:hover {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.clock-fs-btn {
    background-color: rgba(0,0,0,0.3);
    color: rgba(255,255,255,0.5);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    padding: 12px;
    min-width: 44px;
    flex: 1;
    border-top: 1px solid rgba(255,255,255,0.08);
}

.clock-fs-btn:not(:last-child) {
    border-right: 1px solid rgba(255,255,255,0.08);
}

.clock-fs-btn:first-child {
    border-radius: 0 0 0 10px;
}

.clock-fs-btn:last-child {
    border-radius: 0 0 10px 0;
}

.clock-fs-btn:hover {
    background-color: rgba(0,0,0,0.5);
    color: rgba(255,255,255,0.8);
}

.clock-fs-btn svg {
    display: block;
    width: 20px;
    height: 20px;
}

/* Favorites styling */
#favorite-btn.is-favorite .heart-outline {
    display: none;
}

#favorite-btn.is-favorite .heart-filled {
    display: block;
    color: #e91e63;
}

#favorites-mode-btn.active {
    background-color: rgba(233, 30, 99, 0.3);
    color: #e91e63;
}

#favorites-mode-btn.active:hover {
    background-color: rgba(233, 30, 99, 0.5);
}

.heart-filled {
    color: #e91e63;
}

.font-default { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }
.font-inter { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }
.font-jetbrains { font-family: 'JetBrains Mono', 'Courier New', Courier, monospace; }
.font-playfair { font-family: 'Playfair Display', Georgia, 'Times New Roman', serif; }
.font-space { font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }
.font-crimson { font-family: 'Crimson Text', Georgia, 'Times New Roman', serif; }
.font-fira { font-family: 'Fira Code', 'Courier New', Courier, monospace; }
.font-merriweather { font-family: 'Merriweather', Georgia, 'Times New Roman', serif; }
.font-oswald { font-family: 'Oswald', Impact, Haettenschweiler, sans-serif; }
.font-roboto-slab { font-family: 'Roboto Slab', Georgia, 'Times New Roman', serif; }
.font-source { font-family: 'Source Sans Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }
.font-mono { font-family: 'Courier New', Courier, monospace; }
.font-serif { font-family: Georgia, 'Times New Roman', serif; }
.font-display { font-family: Impact, Haettenschweiler, sans-serif; }
.font-elegant { font-family: 'Palatino Linotype', 'Book Antiqua', Palatino, serif; }

/* Position classes for top-controls */
#top-controls.top-left {
    top: 20px;
    left: 20px;
}

#top-controls.top-left #clock-fullscreen-wrap {
    transform-origin: top left;
}

#top-controls.top-right {
    top: 20px;
    right: 20px;
}

#top-controls.top-right #clock-fullscreen-wrap {
    transform-origin: top right;
}

#top-controls.bottom-left {
    bottom: 20px;
    left: 20px;
}

#top-controls.bottom-left #clock-fullscreen-wrap {
    transform-origin: bottom left;
}

#top-controls.bottom-right {
    bottom: 20px;
    right: 20px;
}

#top-controls.bottom-right #clock-fullscreen-wrap {
    transform-origin: bottom right;
}

/* Settings Panel */
#settings-panel {
    position: fixed;
    right: 0;
    top: 0;
    width: 400px;
    height: 100%;
    background-color: rgba(20, 20, 20, 0.95);
    color: white;
    padding: 30px;
    overflow-y: auto;
    transform: translateX(0);
    transition: transform 0.3s ease;
    backdrop-filter: blur(20px);
    z-index: 30;
}

#settings-panel.hidden {
    transform: translateX(100%);
}

.settings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.settings-header h2 {
    margin: 0;
    font-weight: 300;
    font-size: 2rem;
}

.close-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
}

.settings-section {
    margin-bottom: 40px;
}

.settings-section h3 {
    margin-bottom: 20px;
    font-weight: 400;
    font-size: 1.2rem;
    color: #ccc;
}

.setting-item {
    margin-bottom: 20px;
}

.setting-item label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: #aaa;
}

.setting-item input[type="range"] {
    width: 70%;
    -webkit-appearance: none;
    appearance: none;
    height: 5px;
    background: #333;
    outline: none;
    border-radius: 5px;
}

.setting-item input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    background: white;
    cursor: pointer;
    border-radius: 50%;
}

.setting-item input[type="range"]::-moz-range-thumb {
    width: 15px;
    height: 15px;
    background: white;
    cursor: pointer;
    border-radius: 50%;
    border: none;
}

.setting-item input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.setting-item select {
    width: 100%;
    padding: 8px;
    background-color: #333;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.setting-item span {
    margin-left: 10px;
    color: #888;
}

.image-stats {
    background-color: #2a2a2a;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 10px;
}

.image-stats p {
    margin: 0;
    color: #aaa;
    font-size: 0.9rem;
}

#image-upload {
    width: 100%;
    padding: 10px;
    background-color: #333;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

#image-list {
    margin-top: 20px;
    color: #aaa;
}

.loading-text {
    color: #666;
    font-style: italic;
}

.reset-btn {
    width: 100%;
    padding: 10px;
    background-color: #d32f2f;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease;
}

.reset-btn:hover {
    background-color: #b71c1c;
}

/* Drop Zone */
#drop-zone {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 40;
    transition: opacity 0.3s ease;
}

#drop-zone.hidden {
    display: none;
}

.drop-content {
    border: 3px dashed white;
    border-radius: 20px;
    padding: 60px;
    text-align: center;
}

.drop-content p {
    color: white;
    font-size: 1.5rem;
    font-weight: 300;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    #settings-panel {
        width: 100%;
    }
    
    #clock-fullscreen-wrap {
        border-radius: 8px;
    }
    
    #clock-container {
        padding: 10px 20px;
        border-radius: 8px 8px 0 0;
    }
    
    .clock-fs-btn {
        min-width: 36px;
        padding: 10px;
    }
    
    .clock-fs-btn:first-child {
        border-radius: 0 0 0 8px;
    }
    
    .clock-fs-btn:last-child {
        border-radius: 0 0 8px 0;
    }
    
    #clock {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    #clock-fullscreen-wrap {
        border-radius: 6px;
    }
    
    #clock-container {
        padding: 8px 12px;
        border-radius: 6px 6px 0 0;
    }
    
    .clock-fs-btn {
        min-width: 28px;
        padding: 8px;
    }
    
    .clock-fs-btn:first-child {
        border-radius: 0 0 0 6px;
    }
    
    .clock-fs-btn:last-child {
        border-radius: 0 0 6px 0;
    }
    
    #clock {
        font-size: 1.2rem;
    }
}

/* Prevent text selection on mobile */
* {
    -webkit-tap-highlight-color: transparent;
    -webkit-touch-callout: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar { 
    width: 8px; 
}

::-webkit-scrollbar-track { 
    background: #1a1a1a; 
}

::-webkit-scrollbar-thumb { 
    background: #444; 
    border-radius: 4px; 
}

::-webkit-scrollbar-thumb:hover { 
    background: #555; 
}

/* Radio Button Group */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.radio-group label:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

.radio-group input[type="radio"] {
    margin: 0;
    width: 16px;
    height: 16px;
    accent-color: #007bff;
}

.radio-group input[type="radio"]:checked + span {
    color: #007bff;
    font-weight: 500;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    backdrop-filter: blur(5px);
}

.modal.hidden {
    display: none;
}

.modal-content {
    background-color: #2a2a2a;
    color: white;
    padding: 30px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-content h3 {
    margin: 0 0 20px 0;
    font-size: 1.5rem;
    color: #ff6b9d;
}

.modal-content p {
    margin: 0 0 15px 0;
    line-height: 1.5;
    color: #ccc;
}

.modal-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 25px;
}

.btn-primary, .btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-primary {
    background-color: #007bff;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #545b62;
    transform: translateY(-1px);
}

/* Color input styles */
input[type="color"] {
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 10px;
}

/* URL input styles */
input[type="url"] {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 0.9rem;
}

input[type="url"]:focus {
    outline: none;
    border-color: #007bff;
    background-color: rgba(255, 255, 255, 0.15);
}

/* Add URL button */
#add-url-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.2s ease;
}

#add-url-btn:hover {
    background-color: #218838;
}

/* Image list styling */
.user-image-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    margin: 5px 0;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    font-size: 0.9rem;
}

.user-image-item .image-name {
    flex: 1;
    color: #ccc;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-image-item .remove-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background-color 0.2s ease;
}

.user-image-item .remove-btn:hover {
    background-color: #c82333;
}
