:root {
    --bg-dark: #0a0a1a;
    --card-bg: rgba(25, 25, 45, 0.6);
    --card-border: rgba(255, 255, 255, 0.1);
    --primary: #8a2be2;
    --primary-hover: #9d4edd;
    --secondary: #00f2fe;
    --text-main: #ffffff;
    --text-muted: #a0a0b8;
    --danger: #ff4757;
    --success: #2ed573;
    --slider-track: rgba(255, 255, 255, 0.3);
    --font-main: 'Inter', sans-serif;
    --transition: all 0.3s ease;
}

body.light-mode {
    --bg-dark: #f0f2f5;
    --card-bg: rgba(255, 255, 255, 0.8);
    --card-border: rgba(0, 0, 0, 0.1);
    --text-main: #1a1a2e;
    --text-muted: #6b7280;
    --primary: #6c5ce7;
    --primary-hover: #5f27cd;
    --slider-track: rgba(0, 0, 0, 0.15);
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Background Orbs */
.bg-orbs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.5;
    animation: float 20s infinite ease-in-out alternate;
}

.orb-1 {
    top: -10%;
    left: -10%;
    width: 50vw;
    height: 50vw;
    background: radial-gradient(circle, rgba(138,43,226,0.3) 0%, rgba(0,0,0,0) 70%);
}

.orb-2 {
    bottom: -10%;
    right: -10%;
    width: 40vw;
    height: 40vw;
    background: radial-gradient(circle, rgba(0,242,254,0.2) 0%, rgba(0,0,0,0) 70%);
    animation-delay: -5s;
}

.orb-3 {
    top: 40%;
    left: 60%;
    width: 30vw;
    height: 30vw;
    background: radial-gradient(circle, rgba(255,0,255,0.15) 0%, rgba(0,0,0,0) 70%);
    animation-delay: -10s;
}

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

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.badges {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-primary {
    background: rgba(138,43,226,0.2);
    color: #d896ff;
    border: 1px solid rgba(138,43,226,0.5);
}

.badge-secondary {
    background: rgba(0,242,254,0.2);
    color: var(--secondary);
    border: 1px solid rgba(0,242,254,0.5);
}

/* Hero */
.hero {
    text-align: center;
    margin-bottom: 3rem;
}

.gradient-text {
    background: linear-gradient(to right, #00f2fe, #4facfe, #8a2be2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Cards & Glassmorphism */
.card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    margin-bottom: 2rem;
    transition: var(--transition);
}

.hidden {
    display: none !important;
}

/* Tabs */
.tabs {
    display: flex;
    position: relative;
    background: rgba(0,0,0,0.3);
    border-radius: 30px;
    padding: 0.25rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(255,255,255,0.05);
}

.tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 25px;
    cursor: pointer;
    z-index: 1;
    transition: var(--transition);
}

.tab-btn.active {
    color: var(--text-main);
}

.tab-highlight {
    position: absolute;
    top: 0.25rem;
    left: 0.25rem;
    height: calc(100% - 0.5rem);
    width: calc(50% - 0.25rem);
    background: linear-gradient(135deg, rgba(138,43,226,0.6), rgba(0,242,254,0.6));
    border-radius: 25px;
    transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 0;
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

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

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

/* Inputs */
.input-group {
    display: flex;
    gap: 0.5rem;
}

input[type="text"] {
    flex: 1;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 1rem 1.5rem;
    color: var(--text-main);
    font-size: 1rem;
    transition: var(--transition);
}

input[type="text"]:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(138,43,226,0.2);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-main);
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn:hover {
    background: rgba(255,255,255,0.15);
}

.btn-icon {
    padding: 1rem;
}

.btn-primary {
    background: linear-gradient(135deg, #8a2be2, #4facfe);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #9d4edd, #00f2fe);
    transform: translateY(-2px);
}

.btn-glow {
    box-shadow: 0 0 20px rgba(138,43,226,0.4);
}

.btn-glow:hover {
    box-shadow: 0 0 30px rgba(138,43,226,0.6);
}

.btn-danger {
    background: rgba(255, 71, 87, 0.2);
    color: var(--danger);
    border: 1px solid rgba(255, 71, 87, 0.5);
}

.btn-danger:hover {
    background: rgba(255, 71, 87, 0.3);
}

.btn-large {
    width: 100%;
    padding: 1.2rem;
    font-size: 1.2rem;
    margin-top: 2rem;
    border-radius: 16px;
}

/* Dropzone */
.dropzone {
    border: 2px dashed rgba(255,255,255,0.2);
    border-radius: 16px;
    padding: 3rem 2rem;
    text-align: center;
    position: relative;
    background: rgba(0,0,0,0.2);
    transition: var(--transition);
    cursor: pointer;
}

.dropzone:hover, .dropzone.dragover {
    border-color: var(--secondary);
    background: rgba(0,242,254,0.05);
}

.dropzone input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

.dropzone-content svg {
    color: var(--secondary);
    margin-bottom: 1rem;
}

.dropzone-content p {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.dropzone-content p span {
    color: var(--secondary);
    font-weight: 600;
}

.file-limits {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.file-preview {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.4);
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.1);
}

.file-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-info svg {
    color: var(--secondary);
}

.video-preview {
    display: flex;
    gap: 1rem;
    background: rgba(0,0,0,0.4);
    padding: 1rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.1);
    margin-top: 1rem;
    align-items: center;
}

.video-preview img {
    width: 120px;
    height: 68px;
    object-fit: cover;
    border-radius: 8px;
}

.preview-info {
    flex: 1;
}

.preview-info h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.duration-badge {
    background: rgba(255,255,255,0.1);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    margin: 2rem 0;
}

/* Customization Panel */
.customization-panel {
    background: rgba(0,0,0,0.2);
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid rgba(255,255,255,0.05);
}

.panel-title {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.panel-title::before {
    content: '';
    display: block;
    width: 4px;
    height: 1.2rem;
    background: var(--secondary);
    border-radius: 2px;
}

.settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.setting-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.setting-group label {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
}

select {
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--text-main);
    padding: 0.75rem;
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23FFFFFF%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem top 50%;
    background-size: 0.65rem auto;
}

select:focus {
    outline: none;
    border-color: var(--primary);
}

.presets {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

.preset-btn {
    background: rgba(255,255,255,0.1);
    border: none;
    color: var(--text-muted);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: var(--transition);
}

.preset-btn:hover, .preset-btn.active {
    background: var(--primary);
    color: white;
}

/* Custom Sliders */
input[type=range] {
    -webkit-appearance: none;
    width: 100%;
    background: transparent;
}

input[type=range]:focus {
    outline: none;
}

input[type=range]::-webkit-slider-runnable-track {
    width: 100%;
    height: 6px;
    cursor: pointer;
    background: var(--slider-track);
    border-radius: 3px;
}

input[type=range]::-webkit-slider-thumb {
    height: 16px;
    width: 16px;
    border-radius: 50%;
    background: var(--secondary);
    cursor: pointer;
    -webkit-appearance: none;
    margin-top: -5px;
    box-shadow: 0 0 10px rgba(0,242,254,0.5);
}

/* Color Pickers */
.color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(0,0,0,0.4);
    padding: 0.5rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
}

input[type="color"] {
    -webkit-appearance: none;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    padding: 0;
    background: none;
}

input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}

input[type="color"]::-webkit-color-swatch {
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 4px;
}

.color-val {
    font-family: monospace;
    font-size: 0.9rem;
}

/* Toggles */
.toggle-group {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.2);
    padding: 0.75rem;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
}

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

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

.slider.round {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255,255,255,0.2);
    transition: .4s;
    border-radius: 24px;
}

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

input:checked + .slider.round {
    background-color: var(--primary);
}

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

/* Position Buttons */
.position-buttons {
    display: flex;
    background: rgba(0,0,0,0.4);
    border-radius: 8px;
    padding: 0.25rem;
}

.pos-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
}

.pos-btn.active {
    background: rgba(255,255,255,0.1);
    color: var(--text-main);
}

.live-preview-box {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin-top: 1.5rem;
    border: 1px solid rgba(255,255,255,0.1);
    position: relative;
}

.preview-label {
    position: absolute;
    top: 0;
    left: 0;
    background: rgba(0,0,0,0.6);
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    border-bottom-right-radius: 8px;
    color: var(--text-muted);
    z-index: 10;
}

.preview-container {
    height: 200px;
    position: relative;
    background-image: 
        linear-gradient(45deg, #111 25%, transparent 25%), 
        linear-gradient(-45deg, #111 25%, transparent 25%), 
        linear-gradient(45deg, transparent 75%, #111 75%), 
        linear-gradient(-45deg, transparent 75%, #111 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.subtitle-text {
    text-align: center;
    line-height: 1.2;
    transition: all 0.1s ease;
    max-width: 90%;
    word-wrap: break-word;
}

.subtitle-text.pos-top {
    position: absolute;
    top: 20px;
}
.subtitle-text.pos-center {
    /* default flex center */
}
.subtitle-text.pos-bottom {
    position: absolute;
    bottom: 20px;
}

/* Progress Section */
#progress-section {
    text-align: center;
}

.progress-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255,255,255,0.1);
    border-top-color: var(--secondary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.steps-indicator {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    position: relative;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    z-index: 1;
    width: 60px;
}

.step-dot {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    transition: var(--transition);
}

.step span {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
    white-space: nowrap;
}

.step.active .step-dot {
    background: var(--primary);
    box-shadow: 0 0 15px rgba(138,43,226,0.5);
}

.step.active span {
    color: var(--text-main);
}

.step.completed .step-dot {
    background: var(--success);
}

.step-line {
    flex: 1;
    height: 2px;
    background: rgba(255,255,255,0.1);
    margin: 0 -15px;
    position: relative;
    top: -10px;
}

.step-line.active {
    background: var(--primary);
}

.progress-bar-container {
    height: 8px;
    background: rgba(255,255,255,0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.3s ease;
}

.progress-percentage {
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    margin-top: 15px;
    margin-bottom: 15px;
}

/* Error Section */
#error-section {
    text-align: center;
}

.error-icon {
    color: var(--danger);
    margin-bottom: 1rem;
}

#error-message {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

/* Results Section */
#results-section {
    text-align: center;
}

#results-section h2 {
    margin-bottom: 0.5rem;
}

#results-section p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.video-container {
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

video {
    width: 100%;
    max-height: 400px;
    display: block;
}

.download-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 2rem;
}

.action-footer {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1.5rem;
}

.btn-outline {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.05);
}

/* Toasts */
#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 9999;
}

.toast {
    background: rgba(25, 25, 45, 0.9);
    backdrop-filter: blur(10px);
    border-left: 4px solid var(--primary);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    color: white;
    transform: translateX(120%);
    animation: slideIn 0.3s forwards, slideOut 0.3s forwards 3s;
}

.toast.error {
    border-left-color: var(--danger);
}

.toast.success {
    border-left-color: var(--success);
}

@keyframes slideIn {
    to { transform: translateX(0); }
}

@keyframes slideOut {
    to { transform: translateX(120%); opacity: 0; }
}

/* Responsive */
@media (max-width: 768px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
    
    .download-actions {
        flex-direction: column;
    }
    
    .gradient-text {
        font-size: 2rem;
    }
    
    .steps-indicator {
        flex-wrap: wrap;
        gap: 10px;
    }
    .step-line {
        display: none;
    }
}

.setting-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    margin: 16px 0;
    grid-column: 1 / -1;
}

.settings-subheading {
    color: #00f2fe;
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 8px 0;
    grid-column: 1 / -1;
}

.highlight-word {
    color: #00FF00;
    font-weight: 900;
    text-transform: uppercase;
    transition: color 0.2s;
}

/* Editor Styles */
.editor-header {
    text-align: center;
    margin-bottom: 24px;
}
.editor-header h2 {
    color: var(--secondary);
    margin-bottom: 8px;
}
.editor-container {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 10px;
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.editor-segment {
    display: flex;
    gap: 12px;
    background: rgba(255, 255, 255, 0.03);
    padding: 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.05);
}
.editor-time {
    font-family: monospace;
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    width: 100px;
    flex-shrink: 0;
    padding-top: 8px;
}
.editor-input {
    flex-grow: 1;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
    resize: vertical;
    min-height: 40px;
    font-family: 'Inter', sans-serif;
    transition: border-color 0.2s, background 0.2s;
}
.editor-input:focus {
    outline: none;
    border-color: var(--secondary);
}
.editor-video-container {
    width: fit-content;
    max-width: 100%;
    margin: 0 auto 20px auto;
    border-radius: 8px;
    overflow: hidden;
    background: #000;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}
.editor-video-container video {
    max-height: 500px;
    max-width: 100%;
    display: block;
}
.editor-segment.active-segment {
    border-color: var(--secondary);
    background: rgba(0, 242, 254, 0.1);
}
.editor-segment.active-segment .editor-time {
    color: var(--secondary);
    font-weight: bold;
}

/* Video Subtitle Overlay */
.video-subtitle-overlay {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    text-align: center;
    color: white;
    font-family: 'Inter', sans-serif;
    font-size: 24px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.9), -2px -2px 4px rgba(0, 0, 0, 0.9), 2px -2px 4px rgba(0, 0, 0, 0.9), -2px 2px 4px rgba(0, 0, 0, 0.9);
    pointer-events: none; /* Let clicks pass through to video controls */
    z-index: 10;
}

.video-subtitle-overlay.hidden {
    display: none;
}

/* Remove Button */
.btn-remove-segment {
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid rgba(255, 0, 0, 0.3);
    color: #ff6b6b;
    border-radius: 6px;
    cursor: pointer;
    padding: 0 10px;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    height: 40px;
    flex-shrink: 0;
}
.btn-remove-segment:hover {
    background: rgba(255, 0, 0, 0.5);
    color: white;
}

.progress-eta {
    text-align: center;
    margin-top: 5px;
    font-size: 14px;
    color: rgba(255,255,255,0.7);
}


/* Settings Icon */
.btn-icon {
    background: transparent;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}
.btn-icon:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary);
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}
.modal.hidden {
    display: none !important;
}
.modal-content {
    width: 90%;
    max-width: 500px;
    padding: 20px;
    animation: fadeIn 0.3s;
    background: var(--bg-dark); /* Solid background instead of glass */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
    border: 1px solid var(--card-border);
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}
.modal-header h2 {
    margin: 0;
    font-size: 1.5rem;
}

/* Mode Selection */
.mode-selection-container {
    margin-bottom: 25px;
    text-align: center;
}
.mode-selection-container h3 {
    margin-bottom: 15px;
    color: var(--text-main);
}
.mode-cards {
    display: flex;
    gap: 15px;
}
.mode-card {
    flex: 1;
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
    border-radius: 12px;
    padding: 15px;
    cursor: pointer;
    transition: var(--transition);
}
.mode-card:hover {
    background: rgba(0, 0, 0, 0.4);
}
.mode-card.active {
    border-color: var(--primary);
    background: rgba(138,43,226,0.15);
}
.mode-icon {
    font-size: 2rem;
    margin-bottom: 10px;
}
.mode-card h4 {
    margin-bottom: 5px;
    color: var(--text-main);
}
.mode-card p {
    font-size: 0.8rem;
    color: var(--text-muted);
}

