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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: #0f172a;
    color: #e2e8f0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.container {
    background: #1e293b;
    border-radius: 16px;
    padding: 40px;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
}

h1 {
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 6px;
    color: #f8fafc;
}

.subtitle {
    text-align: center;
    color: #94a3b8;
    margin-bottom: 28px;
    font-size: 0.95rem;
}

.upload-area {
    border: 2px dashed #334155;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 20px;
}

.upload-area:hover,
.upload-area.dragover {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.05);
}

.upload-area.has-file {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.05);
}

.upload-icon {
    width: 48px;
    height: 48px;
    color: #64748b;
    margin-bottom: 12px;
}

.upload-area.has-file .upload-icon {
    color: #22c55e;
}

.upload-content p {
    color: #94a3b8;
    font-size: 0.95rem;
}

.file-name {
    display: block;
    margin-top: 8px;
    color: #3b82f6;
    font-weight: 500;
    font-size: 0.9rem;
    word-break: break-all;
}

.options {
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #94a3b8;
}

.checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #3b82f6;
}

button[type="submit"] {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 10px;
    background: #3b82f6;
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

button[type="submit"]:hover:not(:disabled) {
    background: #2563eb;
}

button[type="submit"]:disabled {
    background: #334155;
    color: #64748b;
    cursor: not-allowed;
}

button[type="submit"]:active:not(:disabled) {
    transform: scale(0.98);
}

.progress-bar {
    height: 4px;
    background: #334155;
    border-radius: 2px;
    margin-top: 20px;
    overflow: hidden;
    display: none;
}

.progress-bar.active {
    display: block;
}

.progress-fill {
    height: 100%;
    background: #3b82f6;
    border-radius: 2px;
    width: 0%;
    transition: width 0.3s;
}

.progress-bar.indeterminate .progress-fill {
    width: 30%;
    animation: indeterminate 1.2s ease-in-out infinite;
}

@keyframes indeterminate {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(430%); }
}

.message {
    margin-top: 20px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    display: none;
}

.message.success {
    display: block;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #4ade80;
}

.message.error {
    display: block;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.result {
    margin-top: 20px;
    display: none;
    background: #0f172a;
    border-radius: 10px;
    padding: 16px;
}

.result.show {
    display: block;
}

.result-item {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 0.9rem;
    border-bottom: 1px solid #1e293b;
}

.result-item:last-of-type {
    border-bottom: none;
}

.result-item .label {
    color: #64748b;
}

.download-btn {
    display: block;
    text-align: center;
    margin-top: 14px;
    padding: 10px;
    background: #22c55e;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: background 0.2s;
}

.download-btn:hover {
    background: #16a34a;
}

@media (max-width: 540px) {
    .container {
        margin: 16px;
        padding: 24px;
    }
}
