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

body {
    font-family: 'Poppins', sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    text-align: center;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 2.5rem;
    color: #2563eb;
    margin-bottom: 0.5rem;
}

header p {
    color: #64748b;
    font-size: 1.1rem;
}

main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Upload container */
.upload-container {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

#drop-zone {
    border: 2px dashed #cbd5e1;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

#drop-zone:hover, #drop-zone.dragover {
    border-color: #2563eb;
    background-color: #f0f7ff;
}

#drop-zone .icon {
    color: #64748b;
    transition: color 0.3s ease;
}

#drop-zone:hover .icon {
    color: #2563eb;
}

.custom-file-upload {
    background-color: #2563eb;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-weight: 500;
}

.custom-file-upload:hover {
    background-color: #1d4ed8;
}

input[type="file"] {
    display: none;
}

.file-info {
    color: #64748b;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

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

#transcribe-btn {
    background-color: #2563eb;
    color: white;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

#transcribe-btn:hover {
    background-color: #1d4ed8;
}

#transcribe-btn:disabled {
    background-color: #cbd5e1;
    cursor: not-allowed;
}

/* Loading spinner */
.loading-spinner {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin: 2rem 0;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #2563eb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Results container */
.results-container {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    display: none;
}

.tab-container {
    display: flex;
    border-bottom: 1px solid #e2e8f0;
}

.tab-button {
    flex: 1;
    background: none;
    border: none;
    padding: 1rem;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    color: #64748b;
    transition: all 0.3s ease;
}

.tab-button:hover {
    background-color: #f8fafc;
}

.tab-button.active {
    color: #2563eb;
    border-bottom: 2px solid #2563eb;
}

.tab-content {
    display: none;
    padding: 2rem;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

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

.text-controls {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.copy-button, .download-button {
    background-color: #f1f5f9;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.copy-button:hover, .download-button:hover {
    background-color: #e2e8f0;
}

.result-text {
    background-color: #f8fafc;
    border-radius: 8px;
    padding: 1.5rem;
    min-height: 200px;
    white-space: pre-wrap;
    line-height: 1.8;
    color: #334155;
}

footer {
    text-align: center;
    margin-top: 2rem;
    color: #64748b;
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }

    .options {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .tab-container {
        flex-direction: column;
    }
    
    .tab-button {
        text-align: left;
    }
}