
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #333;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

header {
    background: linear-gradient(to right, #1e3c72, #2a5298);
    color: white;
    padding: 25px 30px;
    text-align: center;
}

h1 {
    font-size: 2.2rem;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
}

.main-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.upload-section {
    background-color: #f8f9fa;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.upload-area {
    border: 3px dashed #1e3c72;
    border-radius: 10px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: rgba(30, 60, 114, 0.05);
}

.upload-area:hover {
    background-color: rgba(30, 60, 114, 0.1);
    transform: translateY(-5px);
}

.upload-icon {
    font-size: 50px;
    color: #1e3c72;
    margin-bottom: 15px;
}

.upload-text {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #1e3c72;
}

.upload-hint {
    color: #666;
    font-size: 0.9rem;
}

#file-input {
    display: none;
}

.file-list {
    margin-top: 20px;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background-color: white;
    border-radius: 8px;
    margin-bottom: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    border-left: 4px solid #1e3c72;
}

.file-name {
    font-weight: 500;
    flex: 1;
}

.file-size {
    color: #666;
    font-size: 0.9rem;
    margin-right: 15px;
}

.file-remove {
    color: #e74c3c;
    cursor: pointer;
    font-weight: bold;
}

.want-section {
    margin-top: 20px;
}

.want-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #1e3c72;
}

.want-input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 1rem;
    resize: vertical;
    min-height: 80px;
    transition: border-color 0.3s;
}

.want-input:focus {
    outline: none;
    border-color: #1e3c72;
    box-shadow: 0 0 0 3px rgba(30, 60, 114, 0.1);
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

button {
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

#extract-btn {
    background: linear-gradient(to right, #1e3c72, #2a5298);
    color: white;
    flex: 2;
}

#clear-btn {
    background-color: #e9ecef;
    color: #495057;
    flex: 1;
}

button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

#extract-btn:hover {
    background: linear-gradient(to right, #0d2c5a, #1a4080);
}

#clear-btn:hover {
    background-color: #dee2e6;
}

.results-section {
    background-color: #f8f9fa;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.results-title {
    font-size: 1.5rem;
    color: #1e3c72;
}

.status-indicator {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-processing {
    background-color: #fff3cd;
    color: #856404;
}

.status-completed {
    background-color: #d1ecf1;
    color: #0c5460;
}

.status-error {
    background-color: #f8d7da;
    color: #721c24;
}

.file-selector {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.file-tab {
    padding: 10px 20px;
    background-color: #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-tab.active {
    background-color: #1e3c72;
    color: white;
}

.content-display {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    min-height: 300px;
    max-height: 500px;
    overflow-y: auto;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    line-height: 1.6;
    white-space: pre-wrap;
    font-family: 'Courier New', monospace;
}

.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 15px;
    height: 200px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(30, 60, 114, 0.2);
    border-radius: 50%;
    border-top-color: #1e3c72;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #666;
}

.empty-icon {
    font-size: 60px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.table-info {
    margin-bottom: 15px;
    padding: 10px;
    background-color: #e8f4fd;
    border-radius: 5px;
    border-left: 4px solid #1e3c72;
}

.result-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.result-table th, .result-table td {
    border: 1px solid #dee2e6;
    padding: 10px;
    text-align: left;
}

.result-table th {
    background-color: #1e3c72;
    color: white;
}

.result-table tr:nth-child(even) {
    background-color: #f8f9fa;
}

.download-section {
    margin-top: 20px;
    padding: 15px;
    background-color: #e8f4fd;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.download-btn {
    background: linear-gradient(to right, #28a745, #20c997);
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

footer {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .main-content {
        padding: 20px;
    }

    .upload-section, .results-section {
        padding: 20px;
    }

    .action-buttons {
        flex-direction: column;
    }

    .file-selector {
        flex-wrap: wrap;
    }

    .download-section {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}
