* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

body {
    font-family: 'Open Sans', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background: #f8faf9;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    font-size: 18px;
}

/* Animated background dots */
.background-dots {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -2;
    opacity: 0.4;
}

.background-dots canvas {
    display: block;
}

/* Brain pattern overlay */
.brain-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
    opacity: 0.03;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(0, 100, 150, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(50, 150, 100, 0.1) 0%, transparent 50%),
        url("data:image/svg+xml,%3Csvg width='100' height='100' xmlns='http://www.w3.org/2000/svg'%3E%3Cdefs%3E%3Cpattern id='brain' width='100' height='100' patternUnits='userSpaceOnUse'%3E%3Cpath d='M30,20 Q40,10 50,20 Q60,30 70,20 Q80,10 90,20' stroke='%23006494' stroke-width='0.5' fill='none' opacity='0.3'/%3E%3Cpath d='M20,40 Q30,30 40,40 Q50,50 60,40 Q70,30 80,40' stroke='%23006494' stroke-width='0.5' fill='none' opacity='0.3'/%3E%3Cpath d='M25,60 Q35,50 45,60 Q55,70 65,60 Q75,50 85,60' stroke='%23006494' stroke-width='0.5' fill='none' opacity='0.3'/%3E%3Ccircle cx='30' cy='25' r='1' fill='%23006494' opacity='0.2'/%3E%3Ccircle cx='60' cy='45' r='1' fill='%23006494' opacity='0.2'/%3E%3Ccircle cx='40' cy='65' r='1' fill='%23006494' opacity='0.2'/%3E%3C/pattern%3E%3C/defs%3E%3Crect width='100' height='100' fill='url(%23brain)'/%3E%3C/svg%3E");
}

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

/* Header Styles */
header {
    text-align: center;
    margin-bottom: 60px;
    color: #1a1a1a;
    position: relative;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.header-text {
    text-align: center;
    flex: 1;
    min-width: 300px;
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .header-text {
        text-align: center;
        min-width: auto;
    }
}

header::before {
    content: '';
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 80px;
    background: url("data:image/svg+xml,%3Csvg width='80' height='80' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M40,10 C20,10 10,25 15,40 C10,50 20,60 30,55 C25,65 35,70 45,65 C55,70 65,65 60,55 C70,60 80,50 75,40 C80,25 70,10 50,10 C45,5 40,10 40,10 Z' fill='none' stroke='%23006494' stroke-width='2' opacity='0.6'/%3E%3Ccircle cx='30' cy='30' r='2' fill='%23006494' opacity='0.4'/%3E%3Ccircle cx='50' cy='35' r='2' fill='%23006494' opacity='0.4'/%3E%3Ccircle cx='35' cy='45' r='1.5' fill='%23006494' opacity='0.4'/%3E%3Ccircle cx='55' cy='50' r='1.5' fill='%23006494' opacity='0.4'/%3E%3C/svg%3E") no-repeat center;
    background-size: contain;
}

header h1 {
    font-size: 3.2rem;
    font-weight: 600;
    margin-bottom: 16px;
    margin-top: 20px;
    letter-spacing: 0.5px;
    color: #006494;
    text-shadow: 2px 2px 4px rgba(0, 100, 148, 0.2);
}

header p {
    font-size: 1.3rem;
    color: #4b5563;
    font-weight: 500;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

/* Main Content */
main {
    background: white;
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    margin-bottom: 40px;
    border: 1px solid rgba(0, 100, 148, 0.08);
    position: relative;
    backdrop-filter: blur(10px);
}

/* Upload Section */
.upload-section {
    margin-bottom: 40px;
}

.upload-area {
    border: 2px dashed #006494;
    border-radius: 12px;
    padding: 60px 30px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafbfc;
    position: relative;
    overflow: hidden;
}

.upload-area::before {
    content: '';
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: url("data:image/svg+xml,%3Csvg width='40' height='40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg opacity='0.3'%3E%3Ccircle cx='10' cy='10' r='1' fill='%23006494'/%3E%3Ccircle cx='30' cy='15' r='1.5' fill='%23006494'/%3E%3Ccircle cx='20' cy='25' r='1' fill='%23006494'/%3E%3Ccircle cx='35' cy='30' r='1' fill='%23006494'/%3E%3C/g%3E%3C/svg%3E") no-repeat;
}

.upload-area:hover {
    border-color: #004d73;
    background: #f0f9ff;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 100, 148, 0.1);
}

.upload-area.dragover {
    border-color: #003d5c;
    background: #e6f7ff;
    transform: scale(1.02);
}

.upload-content h3 {
    margin: 20px 0 12px;
    color: #1a1a1a;
    font-size: 1.4rem;
    font-weight: 500;
}

.upload-content p {
    color: #6b7280;
    margin: 6px 0;
    font-size: 0.95rem;
}

.upload-icon {
    width: 56px;
    height: 56px;
    color: #006494;
    stroke-width: 1.5;
}

/* Video Preview */
.video-preview {
    margin-bottom: 40px;
    padding: 24px;
    background: #fafbfc;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.video-preview h3 {
    margin-bottom: 18px;
    color: #1a1a1a;
    font-weight: 500;
    font-size: 1.2rem;
}

.video-preview video {
    width: 100%;
    max-width: 600px;
    height: auto;
    border-radius: 8px;
    margin-bottom: 18px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.video-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.video-info p {
    margin: 6px 0;
    color: #4b5563;
    font-size: 0.95rem;
}

/* Settings Panel */
.settings-panel {
    margin-bottom: 40px;
    padding: 24px;
    background: #fafbfc;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.settings-panel h3 {
    margin-bottom: 24px;
    color: #1a1a1a;
    font-weight: 500;
    font-size: 1.2rem;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

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

.setting-group label {
    font-weight: 500;
    margin-bottom: 12px;
    color: #374151;
    font-size: 0.95rem;
}

.setting-group input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    outline: none;
    margin-bottom: 12px;
}

.setting-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #006494;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 100, 148, 0.3);
}

.setting-group input[type="range"]::-webkit-slider-thumb:hover {
    background: #004d73;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 100, 148, 0.4);
}

.setting-value {
    font-weight: 600;
    color: #006494;
    font-size: 0.9rem;
}

/* Buttons */
.action-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 40px;
}

.btn {
    padding: 16px 32px;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 160px;
    justify-content: center;
    font-family: inherit;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
    letter-spacing: 0.5px;
}

.btn-primary {
    background: #006494;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 100, 148, 0.2);
}

.btn-primary:hover {
    background: #004d73;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 100, 148, 0.3);
}

.btn-primary:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background: #e5e7eb;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-success {
    background: #059669;
    color: white;
    box-shadow: 0 2px 8px rgba(5, 150, 105, 0.2);
}

.btn-success:hover {
    background: #047857;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(5, 150, 105, 0.3);
}

/* Loading Spinner */
.loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

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

/* Progress Section */
.progress-section {
    margin-bottom: 40px;
    padding: 24px;
    background: #fafbfc;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    text-align: center;
}

.progress-section h3 {
    margin-bottom: 24px;
    color: #1a1a1a;
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #006494, #0077b6);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 3px;
}

.progress-text {
    color: #1a1a1a;
    font-weight: 700;
    font-size: 1.2rem;
    text-align: center;
    letter-spacing: 0.5px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

/* Progress Steps Indicator */
.progress-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px 0 30px 0;
    padding: 0 20px;
}

.step-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0.4;
    transition: all 0.3s ease;
}

.step-indicator.active {
    opacity: 1;
}

.step-indicator.completed {
    opacity: 1;
}

.step-number {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #e5e7eb;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.step-indicator.active .step-number {
    background: #006494;
    color: white;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 100, 148, 0.3);
}

.step-indicator.completed .step-number {
    background: #059669;
    color: white;
}

.step-label {
    font-size: 0.9rem;
    color: #6b7280;
    font-weight: 700;
    text-align: center;
    letter-spacing: 0.3px;
}

.step-indicator.active .step-label {
    color: #006494;
    font-weight: 600;
}

.step-indicator.completed .step-label {
    color: #059669;
    font-weight: 600;
}

.step-connector {
    flex: 1;
    height: 2px;
    background: #e5e7eb;
    margin: 0 8px;
    transition: all 0.3s ease;
}

.step-connector.completed {
    background: #059669;
}

.step-connector.active {
    background: linear-gradient(90deg, #059669 0%, #006494 100%);
}

@media (max-width: 768px) {
    .progress-steps {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .step-connector {
        display: none;
    }
    
    .step-label {
        font-size: 0.7rem;
    }
    
    .step-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }
}

/* Result Section */
.result-section {
    padding: 24px;
    background: #fafbfc;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    text-align: center;
}

.result-section h3 {
    margin-bottom: 24px;
    color: #1a1a1a;
    font-weight: 500;
}

.result-container video {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: 8px;
    margin-bottom: 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.result-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Footer */
footer {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 12px;
    padding: 24px;
    color: #1a1a1a;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 100, 148, 0.08);
}

.info-section h4 {
    margin-bottom: 12px;
    font-size: 1.1rem;
    font-weight: 500;
    color: #006494;
}

.info-section p {
    color: #4b5563;
    line-height: 1.7;
    font-size: 0.95rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    main {
        padding: 20px;
    }
    
    .upload-area {
        padding: 40px 15px;
    }
    
    .settings-grid {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .result-actions {
        flex-direction: column;
        align-items: center;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

.slide-up {
    animation: slideUp 0.5s ease-out;
}

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

/* Error States */
.error {
    color: #dc2626;
    background: #fef2f2;
    border: 1px solid #fecaca;
    padding: 12px 16px;
    border-radius: 8px;
    margin: 12px 0;
    font-size: 0.95rem;
}

.success {
    color: #059669;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    padding: 12px 16px;
    border-radius: 8px;
    margin: 12px 0;
    font-size: 0.95rem;
}
