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

:root {
    --ui-bg: #f0f2f5;
    --ui-surface: #ffffff;
    --ui-surface-2: #f7f8fa;
    --ui-text: #1a1a1a;
    --ui-text-muted: #666666;
    --ui-accent: #007bff;
    --ui-accent-2: #00b3ff;
    --ui-accent-hover: #0056b3;
    --ui-border: #e1e5e9;
    --ui-shadow: rgba(0, 0, 0, 0.1);
    --ui-glow: rgba(0, 123, 255, 0.25);
    --ui-progress-bg: #e9ecef;
    --ui-progress-fill: var(--ui-accent);
    --ui-scanline: rgba(0, 0, 0, 0.12);
    --ui-mesh-1: rgba(0, 123, 255, 0.18);
    --ui-mesh-2: rgba(255, 75, 120, 0.18);
    --ui-mesh-3: rgba(88, 255, 204, 0.16);
    --ui-button-bg: var(--ui-accent);
    --ui-button-text: #ffffff;
    --ui-button-border: transparent;
    --ui-control-radius: 50%;
    --ui-play-radius: 50%;
    --ui-timer-font: inherit;
    --theme-transition: 280ms cubic-bezier(0.4, 0, 0.2, 1);

    --bg-primary: var(--ui-bg);
    --bg-secondary: var(--ui-surface);
    --text-primary: var(--ui-text);
    --text-secondary: var(--ui-text-muted);
    --accent: var(--ui-accent);
    --accent-hover: var(--ui-accent-hover);
    --border: var(--ui-border);
    --shadow: var(--ui-shadow);
    --progress-bg: var(--ui-progress-bg);
    --progress-fill: var(--ui-progress-fill);
}

[data-mode="dark"],
[data-theme="dark"] {
    --ui-bg: #0f0f0f;
    --ui-surface: #1a1a1a;
    --ui-surface-2: #141414;
    --ui-text: #ffffff;
    --ui-text-muted: #b0b0b0;
    --ui-accent: #dc3545;
    --ui-accent-2: #ff6b6b;
    --ui-accent-hover: #c82333;
    --ui-border: #333333;
    --ui-shadow: rgba(0, 0, 0, 0.5);
    --ui-glow: rgba(220, 53, 69, 0.3);
    --ui-progress-bg: #333333;
}

[data-theme="glass"] {
    --ui-bg: #11131a;
    --ui-surface: rgba(24, 28, 36, 0.72);
    --ui-surface-2: rgba(36, 42, 52, 0.7);
    --ui-border: rgba(255, 255, 255, 0.12);
    --ui-shadow: rgba(0, 0, 0, 0.55);
    --ui-glow: rgba(120, 204, 255, 0.35);
    --ui-mesh-1: rgba(88, 160, 255, 0.25);
    --ui-mesh-2: rgba(255, 94, 125, 0.22);
    --ui-mesh-3: rgba(108, 255, 209, 0.2);
}

[data-theme="oled"] {
    --ui-bg: #000000;
    --ui-surface: #050505;
    --ui-surface-2: #090909;
    --ui-text: #f5f5f5;
    --ui-text-muted: #8f8f8f;
    --ui-accent: #00f5ff;
    --ui-accent-2: #4dff9b;
    --ui-accent-hover: #00c7cf;
    --ui-border: #101010;
    --ui-shadow: rgba(0, 0, 0, 0);
    --ui-glow: rgba(0, 245, 255, 0.25);
    --ui-progress-bg: #101010;
}

[data-theme="synth"],
[data-theme="synthwave"] {
    --ui-accent: #2dfcff;
    --ui-accent-2: #a7ff2f;
    --ui-accent-hover: #14dbe0;
    --ui-glow: rgba(45, 252, 255, 0.45);
    --ui-timer-font: "Courier New", "Lucida Console", monospace;
}

[data-theme="synthwave"][data-mode="dark"],
[data-theme="synth"][data-mode="dark"] {
    --ui-bg: #140b2d;
    --ui-surface: #1b0f3d;
    --ui-surface-2: #23114a;
    --ui-text: #f9e6ff;
    --ui-text-muted: #c7a6ff;
    --ui-border: rgba(255, 79, 216, 0.28);
    --ui-shadow: rgba(255, 79, 216, 0.24);
    --ui-progress-bg: rgba(93, 255, 253, 0.2);
}

[data-theme="synthwave"][data-mode="light"],
[data-theme="synth"][data-mode="light"] {
    --ui-bg: #f5edff;
    --ui-surface: #ffffff;
    --ui-surface-2: #f0e8ff;
    --ui-text: #2b1240;
    --ui-text-muted: #6b4b9b;
    --ui-border: rgba(45, 252, 255, 0.35);
    --ui-shadow: rgba(45, 252, 255, 0.22);
}

[data-theme="glass"][data-mode="light"] {
    --ui-bg: #f6f7ff;
    --ui-surface: rgba(255, 255, 255, 0.78);
    --ui-surface-2: rgba(255, 255, 255, 0.6);
    --ui-text: #1a1a1a;
    --ui-text-muted: #5d5d6f;
    --ui-accent: #4f7cff;
    --ui-accent-2: #ff9fb3;
    --ui-accent-hover: #355fdb;
    --ui-border: rgba(255, 255, 255, 0.7);
    --ui-shadow: rgba(0, 0, 0, 0.12);
    --ui-button-bg: rgba(255, 255, 255, 0.92);
    --ui-button-text: #1d1d1f;
    --ui-button-border: rgba(255, 255, 255, 0.75);
}

[data-theme="glass"][data-mode="dark"] {
    --ui-bg: #121525;
    --ui-surface: rgba(22, 28, 40, 0.75);
    --ui-surface-2: rgba(36, 44, 60, 0.62);
    --ui-text: #f4f6ff;
    --ui-text-muted: #aeb3d6;
    --ui-accent: #7bc6ff;
    --ui-accent-2: #ffc6a8;
    --ui-accent-hover: #54a9f2;
    --ui-border: rgba(255, 255, 255, 0.18);
    --ui-shadow: rgba(0, 0, 0, 0.45);
    --ui-button-bg: rgba(255, 255, 255, 0.2);
    --ui-button-text: #f7f9ff;
    --ui-button-border: rgba(255, 255, 255, 0.25);
}

[data-theme="glass"] body {
    background: linear-gradient(135deg, #ffd7b5 0%, #bcd3ff 50%, #f3d6ff 100%);
}

[data-theme="glass"][data-mode="dark"] body {
    background: linear-gradient(135deg, #2a2342 0%, #1f2c3d 50%, #3a1f3d 100%);
}

[data-theme="forest"][data-mode="light"] {
    --ui-bg: #dbe7d6;
    --ui-surface: #f6f1e8;
    --ui-surface-2: #eee6d7;
    --ui-text: #263020;
    --ui-text-muted: #5b6c52;
    --ui-accent: #b86b4b;
    --ui-accent-2: #8a5a3d;
    --ui-accent-hover: #9b5a3f;
    --ui-border: #c9d3c2;
    --ui-shadow: rgba(46, 58, 44, 0.18);
    --ui-control-radius: 18px;
    --ui-play-radius: 14px;
}

[data-theme="forest"][data-mode="dark"] {
    --ui-bg: #1f2a23;
    --ui-surface: #2a352d;
    --ui-surface-2: #354139;
    --ui-text: #f0f3ea;
    --ui-text-muted: #a9b6a2;
    --ui-accent: #c47b57;
    --ui-accent-2: #a56a4c;
    --ui-accent-hover: #b06c4f;
    --ui-border: #3b483e;
    --ui-shadow: rgba(0, 0, 0, 0.45);
    --ui-control-radius: 18px;
    --ui-play-radius: 14px;
}

[data-theme="cyberpunk"][data-mode="dark"] {
    --ui-bg: #141414;
    --ui-surface: #1b1b1b;
    --ui-surface-2: #222222;
    --ui-text: #f4f4f4;
    --ui-text-muted: #b4b4b4;
    --ui-accent: #ffd500;
    --ui-accent-2: #ff5b5b;
    --ui-accent-hover: #e4be00;
    --ui-border: #2b2b2b;
    --ui-shadow: rgba(0, 0, 0, 0.6);
    --ui-control-radius: 6px;
    --ui-play-radius: 8px;
    --ui-button-bg: #ffd500;
    --ui-button-text: #111111;
    --ui-button-border: #b69300;
}

[data-theme="cyberpunk"][data-mode="light"] {
    --ui-bg: #f1f1f1;
    --ui-surface: #ffffff;
    --ui-surface-2: #ececec;
    --ui-text: #1a1a1a;
    --ui-text-muted: #5f5f5f;
    --ui-accent: #ffb800;
    --ui-accent-2: #c1001f;
    --ui-accent-hover: #d99d00;
    --ui-border: #cccccc;
    --ui-shadow: rgba(0, 0, 0, 0.12);
    --ui-control-radius: 6px;
    --ui-play-radius: 8px;
    --ui-button-bg: #ffb800;
    --ui-button-text: #111111;
    --ui-button-border: #c9a100;
}

[data-theme="cyberpunk"] .clear-btn {
    background: #c1001f;
}

[data-theme="synth"] {
    --ui-bg: #12081c;
    --ui-surface: rgba(26, 10, 38, 0.9);
    --ui-surface-2: rgba(34, 14, 50, 0.85);
    --ui-text: #f9e6ff;
    --ui-text-muted: #c7a6ff;
    --ui-accent: #ff4fd8;
    --ui-accent-2: #5dfffd;
    --ui-accent-hover: #ff2bc1;
    --ui-border: rgba(255, 79, 216, 0.25);
    --ui-shadow: rgba(255, 79, 216, 0.22);
    --ui-glow: rgba(93, 255, 253, 0.35);
    --ui-progress-bg: rgba(93, 255, 253, 0.2);
    --ui-scanline: rgba(255, 255, 255, 0.08);
}

html,
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    transition: background-color var(--theme-transition), color var(--theme-transition);
    overflow-x: hidden;
}

.theme-transition,
.theme-transition * {
    transition: background-color var(--theme-transition), color var(--theme-transition), border-color var(--theme-transition), box-shadow var(--theme-transition);
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, var(--ui-mesh-1), transparent 48%),
        radial-gradient(circle at 70% 10%, var(--ui-mesh-2), transparent 45%),
        radial-gradient(circle at 50% 80%, var(--ui-mesh-3), transparent 55%);
    opacity: 0.7;
    pointer-events: none;
    z-index: -1;
}

[data-theme="oled"] body::before {
    display: none;
}

[data-theme="synth"],
[data-theme="synth"] body::after,
[data-theme="synthwave"] body::after {
    content: '';
    position: fixed;
    inset: 0;
    background: repeating-linear-gradient(
        to bottom,
        var(--ui-scanline),
        var(--ui-scanline) 1px,
        transparent 1px,
        transparent 3px
    );
    mix-blend-mode: screen;
    opacity: 0.22;
    pointer-events: none;
    z-index: 1;
}

[data-theme="cyberpunk"] body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 214, 0, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 214, 0, 0.08) 1px, transparent 1px);
    background-size: 22px 22px;
    opacity: 0.3;
    pointer-events: none;
    z-index: 1;
}

body.warning-bar-active {
    padding-top: 50px;
}

.pip-mode.warning-bar-active {
    padding-top: 0;
}

.pip-mode {
    width: 100vw;
    height: 100vh;
    overflow: auto;
}

.pip-mode .container {
    max-width: 100%;
    padding: clamp(8px, 3vw, 16px);
}

.pip-mode #pipContent {
    padding: clamp(8px, 3vw, 16px);
}

.pip-mode .header,
.pip-mode .upload-area,
.pip-mode .warning-bar,
.pip-mode .warning-popup,
.pip-mode .update-log {
    display: none;
}

.pip-mode .player-container {
    padding: clamp(10px, 3vw, 18px);
    margin-bottom: clamp(8px, 3vw, 14px);
    border-radius: clamp(10px, 3vw, 16px);
}

.pip-mode .current-song {
    margin-bottom: clamp(8px, 2.5vw, 14px);
}

.pip-mode .song-title {
    font-size: clamp(0.9rem, 3vw, 1.1rem);
}

.pip-mode .controls {
    gap: clamp(6px, 2vw, 10px);
    flex-wrap: wrap;
    margin-bottom: clamp(8px, 2.5vw, 14px);
}

.pip-mode .control-btn {
    width: clamp(30px, 9vw, 44px);
    height: clamp(30px, 9vw, 44px);
    font-size: clamp(12px, 3.6vw, 16px);
}

.pip-mode .play-pause-btn {
    width: clamp(38px, 11vw, 56px);
    height: clamp(38px, 11vw, 56px);
    font-size: clamp(16px, 4.2vw, 22px);
}

.pip-mode .progress-container {
    margin-bottom: clamp(8px, 2.5vw, 12px);
}

.pip-mode .time-display {
    font-size: clamp(0.75rem, 2.5vw, 0.9rem);
}

.pip-mode .volume-container {
    margin-bottom: clamp(8px, 2.5vw, 12px);
    gap: clamp(6px, 2vw, 10px);
}

.pip-mode .volume-slider {
    width: clamp(90px, 35vw, 150px);
}

.pip-mode .playlist {
    padding: clamp(8px, 2.5vw, 14px);
    border-radius: clamp(10px, 3vw, 16px);
    max-height: none;
    overflow-y: visible;
}

.pip-mode .playlist-title {
    font-size: clamp(0.95rem, 3vw, 1.1rem);
    margin-bottom: clamp(8px, 2.5vw, 12px);
}

.pip-mode .playlist-item {
    padding: clamp(6px, 2vw, 10px);
    margin-bottom: clamp(4px, 1.6vw, 8px);
}

.pip-mode .song-number {
    width: clamp(20px, 6vw, 28px);
    margin-right: clamp(6px, 2vw, 10px);
}

.pip-mode .song-duration {
    font-size: clamp(0.7rem, 2.2vw, 0.85rem);
}

.pip-mode .remove-btn {
    width: clamp(20px, 6vw, 28px);
    height: clamp(20px, 6vw, 28px);
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

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

.title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.theme-select {
    background: var(--bg-secondary);
    border: 2px solid var(--border);
    border-radius: 999px;
    padding: 8px 12px;
    font-size: 14px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.theme-select:hover {
    border-color: var(--accent);
}

.theme-toggle {
    background: var(--bg-secondary);
    border: 2px solid var(--border);
    border-radius: 50px;
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-primary);
    font-size: 14px;
}

.theme-toggle:hover {
    border-color: var(--accent);
}

/* Dropdown Menu Styles */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-btn {
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 8px 16px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.dropdown-btn:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    background: var(--bg-secondary);
    min-width: 200px;
    box-shadow: 0 8px 16px var(--shadow);
    border-radius: 10px;
    z-index: 1000;
    overflow: hidden;
    border: 2px solid var(--border);
    margin-top: 5px;
}

.dropdown.active .dropdown-content {
    display: block;
}

.dropdown-item {
    color: var(--text-primary);
    padding: 12px 16px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.dropdown-item:hover {
    background: var(--bg-primary);
    color: var(--accent);
}

.dropdown-item:not(:last-child) {
    border-bottom: 1px solid var(--border);
}

.player-container {
    background: var(--bg-secondary);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px var(--shadow);
    margin-bottom: 30px;
}

[data-theme="glass"] .player-container,
[data-theme="glass"] .playlist,
[data-theme="glass"] .dropdown-content,
[data-theme="glass"] .modal,
[data-theme="glass"] .update-log-content,
[data-theme="glass"] .warning-popup-content {
    backdrop-filter: blur(18px) saturate(130%);
    background: var(--bg-secondary);
    border: 1px solid var(--border);
}

[data-theme="oled"] .player-container,
[data-theme="oled"] .playlist,
[data-theme="oled"] .dropdown-content,
[data-theme="oled"] .modal {
    box-shadow: none;
    border: 1px solid var(--border);
}

.upload-area {
    border: 3px dashed var(--border);
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    margin-bottom: 30px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.upload-area.dragover {
    border-color: var(--accent);
    background: var(--accent);
    opacity: 0.1;
}

.upload-area:hover {
    border-color: var(--accent);
}

.upload-text {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.file-input {
    display: none;
}

.upload-btn {
    background: var(--ui-button-bg);
    color: var(--ui-button-text);
    border: 1px solid var(--ui-button-border);
    padding: 12px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
}

.upload-btn:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.upload-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 10px;
}

.clear-btn {
    background: #d9534f;
}

.clear-btn:hover {
    background: #c9302c;
}

.streaming-area {
    background: var(--bg-primary);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 30px;
    border: 2px solid var(--border);
}

.streaming-input {
    flex: 1;
    padding: 10px 15px;
    border: 2px solid var(--border);
    border-radius: 25px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.3s ease;
    min-width: 200px;
}

.streaming-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}

.streaming-input::placeholder {
    color: var(--text-secondary);
}

.current-song {
    text-align: center;
    margin-bottom: 30px;
}

.song-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 5px;
}

.song-info {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.control-btn {
    background: var(--bg-primary);
    border: 2px solid var(--border);
    border-radius: var(--ui-control-radius);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-primary);
    font-size: 18px;
}

.control-btn:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.control-btn.active {
    background: var(--accent);
    border-color: var(--accent);
    color: white;
}

.control-btn.active:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.play-pause-btn {
    width: 60px;
    height: 60px;
    background: var(--accent);
    border-color: var(--accent);
    color: white;
    font-size: 24px;
    box-shadow: 0 0 20px var(--ui-glow);
    border-radius: var(--ui-play-radius);
}

.play-pause-btn:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.progress-container {
    margin-bottom: 20px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--progress-bg);
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--progress-fill);
    border-radius: 4px;
    transition: width 0.1s ease;
    width: 0%;
}

.time-display {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-family: var(--ui-timer-font);
}

.volume-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.volume-slider {
    width: 150px;
    height: 6px;
    background: var(--progress-bg);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
}

.volume-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: var(--accent);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.playlist {
    background: var(--bg-secondary);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px var(--shadow);
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    width: min(420px, 90vw);
    box-shadow: 0 20px 60px var(--shadow);
}

.modal-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.modal-text {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.playlist-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
}

.playlist-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 10px;
    border: 2px solid transparent;
}

.playlist-item:hover {
    background: var(--bg-primary);
}

.playlist-item.active {
    background: var(--accent);
    color: white;
}

.playlist-item.active:hover {
    background: var(--accent-hover);
}

.song-number {
    width: 30px;
    text-align: center;
    font-weight: 600;
    margin-right: 15px;
}

.song-details {
    flex: 1;
}

.song-name {
    font-weight: 500;
    margin-bottom: 3px;
}

.song-duration {
    font-size: 0.85rem;
    opacity: 0.8;
}

.remove-btn {
    background: #ffc107;
    color: #000;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0;
}

.playlist-item:hover .remove-btn {
    opacity: 1;
}

.remove-btn:hover {
    background: #ffca2c;
    transform: scale(1.1);
}

.empty-playlist {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

.repeat-indicator {
    position: absolute;
    top: -5px;
    right: -5px;
    width: 12px;
    height: 12px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease;
    box-shadow: 0 0 12px var(--ui-glow);
}

.control-btn.active .repeat-indicator {
    opacity: 1;
}

.pip-utility {
    display: none;
    margin-top: 18px;
    padding: 12px;
    border-radius: 12px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    box-shadow: inset 0 0 18px rgba(0, 0, 0, 0.2);
    gap: 12px;
    flex-direction: column;
}

.pip-utility canvas {
    width: 100%;
    height: 48px;
    border-radius: 8px;
    background: linear-gradient(90deg, rgba(0,0,0,0.25), rgba(0,0,0,0.05));
}

.pip-queue {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pip-queue-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-secondary);
}

.pip-queue-ticker {
    overflow: hidden;
    white-space: nowrap;
    border-radius: 999px;
    padding: 6px 10px;
    border: 1px solid var(--border);
    background: var(--bg-secondary);
}

.pip-queue-ticker span {
    display: inline-block;
    padding-left: 100%;
    animation: pipTicker 12s linear infinite;
}

@keyframes pipTicker {
    from { transform: translateX(0); }
    to { transform: translateX(-100%); }
}

.pip-mode .pip-utility {
    display: flex;
}

.changelog-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-top: 20px;
}

.changelog-entry {
    background: var(--bg-secondary);
    border: 2px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 12px 34px var(--shadow);
}

.changelog-meta {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.changelog-version {
    font-weight: 700;
    color: var(--accent);
}

.changelog-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.changelog-items {
    margin: 0;
    padding-left: 18px;
    color: var(--text-primary);
}

.changelog-items li {
    margin: 6px 0;
    line-height: 1.5;
}

.admin-panel {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.admin-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px var(--shadow);
}

.admin-form label {
    font-weight: 600;
    color: var(--text-primary);
}

.admin-form input,
.admin-form textarea {
    width: 100%;
    padding: 10px;
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-family: inherit;
}

.admin-output {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.admin-output-label {
    font-weight: 600;
    color: var(--text-primary);
}

.admin-output-code {
    white-space: pre-wrap;
    word-break: break-word;
    background: var(--bg-primary);
    color: var(--text-primary);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px;
    min-height: 220px;
    font-size: 0.9rem;
}

@media (max-width: 900px) {
    .admin-panel {
        grid-template-columns: 1fr;
    }
}

/* Features page styles */
.features-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.feature-card {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 24px;
    border: 2px solid var(--border);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px var(--shadow);
    border-color: var(--accent);
}

.feature-card.feature-completed {
    border-color: #43a047;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, rgba(67, 160, 71, 0.18) 100%);
    opacity: 0.95;
}

.feature-card.feature-completed:hover {
    opacity: 1;
}

[data-theme="dark"] .feature-card.feature-completed {
    border-color: #4caf50;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, rgba(76, 175, 80, 0.28) 100%);
}

.feature-category {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    margin-bottom: 12px;
    letter-spacing: 0.8px;
}

.feature-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-primary);
    line-height: 1.3;
}

.feature-description {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    flex-grow: 1;
}

.feature-checkbox {
    display: none;
}

@media (max-width: 600px) {
    .container {
        padding: 10px;
    }
    
    .controls {
        gap: 8px;
        flex-wrap: wrap;
    }
    
    .control-btn {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
    
    .play-pause-btn {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }
    
    .volume-container {
        flex-direction: column;
        gap: 10px;
    }
    
    .header {
        flex-wrap: wrap;
    }

    .dropdown-content {
        right: 0;
        left: auto;
    }

    .features-container {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   WARNING BAR & POPUP STYLES
   ============================================ */

/* Warning Bar - Top of Site */
.warning-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: white;
    padding: 0;
    z-index: 10000;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.warning-bar-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    max-width: 100%;
}

.warning-close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    margin-left: 10px;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.warning-close-btn:hover {
    opacity: 1;
}

/* Warning Popup Modal */
.warning-popup {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.warning-popup-content {
    background: var(--bg-secondary);
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
    overflow: hidden;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.warning-popup-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 25px;
    border-bottom: 2px solid var(--border);
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: white;
}

.warning-popup-header h2 {
    margin: 0;
    font-size: 1.5rem;
}

.warning-popup-close {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.warning-popup-close:hover {
    opacity: 1;
}

.warning-popup-body {
    padding: 25px;
    color: var(--text-primary);
}

.warning-popup-body p {
    margin: 10px 0;
    line-height: 1.6;
}

.warning-popup-body ul {
    margin: 10px 0 10px 25px;
    padding: 0;
}

.warning-popup-body li {
    margin: 8px 0;
    line-height: 1.5;
}

.warning-popup-footer {
    padding: 20px 25px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.warning-popup-btn {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a6f 100%);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.warning-popup-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 107, 0.4);
}

/* ============================================
   UPDATE LOG MODAL STYLES
   ============================================ */

.update-log {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10002;
    animation: fadeIn 0.3s ease;
}

.update-log-content {
    background: var(--bg-secondary);
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 560px;
    width: 92%;
    overflow: hidden;
    animation: slideUp 0.3s ease;
}

.update-log-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px;
    border-bottom: 2px solid var(--border);
    background: linear-gradient(135deg, #6c63ff 0%, #4e54c8 100%);
    color: white;
}

.update-log-header h2 {
    margin: 0;
    font-size: 1.5rem;
}

.update-log-close {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}

.update-log-close:hover {
    opacity: 1;
}

.update-log-body {
    padding: 24px;
    color: var(--text-primary);
}

.update-log-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.update-log-label {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.72rem;
}

.update-log-version {
    font-weight: 600;
    color: var(--text-primary);
}

.update-log-list {
    margin: 0;
    padding-left: 20px;
}

.update-log-list li {
    margin: 10px 0;
    line-height: 1.6;
}

.update-log-footer {
    padding: 18px 24px 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
}

.update-log-btn {
    background: linear-gradient(135deg, #6c63ff 0%, #4e54c8 100%);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.update-log-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(78, 84, 200, 0.4);
}

.site-version {
    position: fixed;
    right: 16px;
    bottom: 12px;
    font-size: 12px;
    color: rgba(176, 176, 176, 0.8);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    z-index: 9999;
    pointer-events: none;
}
