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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #fafafa;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    color: #1a1a1a;
}

.container {
    background: white;
    border: 1px solid #e0e0e0;
    padding: 40px 40px;
    max-width: 480px;
    width: 100%;
    text-align: center;
}

h1 {
    font-size: 2rem;
    margin-bottom: 8px;
    color: #1a1a1a;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 40px;
    font-weight: 400;
}

.upload-area {
    border: 2px dashed #d0d0d0;
    padding: 50px 20px;
    margin-bottom: 20px;
    transition: border-color 0.2s ease;
    cursor: pointer;
    background: #fafafa;
}

.upload-area:hover {
    border-color: #1a1a1a;
}

.upload-area.dragover {
    border-color: #1a1a1a;
    background: #f5f5f5;
}

.upload-icon {
    font-size: 2.5rem;
    margin-bottom: 16px;
    opacity: 0.6;
}

.upload-text {
    font-size: 1rem;
    color: #1a1a1a;
    margin-bottom: 6px;
    font-weight: 500;
}

.upload-hint {
    font-size: 0.875rem;
    color: #888;
}

#fileInput {
    display: none;
}

.file-name {
    margin-top: 16px;
    padding: 12px 16px;
    background: #f5f5f5;
    color: #1a1a1a;
    font-size: 0.9rem;
    display: none;
    border-left: 3px solid #1a1a1a;
}

.file-name.show {
    display: block;
}

.btn {
    background: #1a1a1a;
    color: white;
    border: none;
    padding: 16px 32px;
    font-size: 0.95rem;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.2s ease;
    width: 100%;
    margin-top: 12px;
    letter-spacing: 0.01em;
}

.btn:hover:not(:disabled) {
    background: #000;
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.message {
    margin-top: 20px;
    padding: 14px 16px;
    display: none;
    font-size: 0.9rem;
    text-align: left;
    border-left: 3px solid;
}

.message.show {
    display: block;
}

.message.error {
    background: #fef2f2;
    color: #991b1b;
    border-color: #991b1b;
}

.message.success {
    background: #f0fdf4;
    color: #166534;
    border-color: #166534;
}

.message.info {
    background: #f8f9fa;
    color: #495057;
    border-color: #495057;
}

.loader {
    border: 3px solid #f0f0f0;
    border-top: 3px solid #1a1a1a;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    animation: spin 0.8s linear infinite;
    margin: 20px auto;
    display: none;
}

.loader.show {
    display: block;
}

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

footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
    font-size: 0.85rem;
    color: #888;
}

footer a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.2s ease;
}

footer a:hover {
    opacity: 0.6;
}

@media (max-width: 600px) {
    body {
        padding: 12px;
    }

    .container {
        padding: 32px 20px;
        border: none;
    }

    h1 {
        font-size: 1.5rem;
        line-height: 1.2;
    }

    .subtitle {
        font-size: 0.875rem;
        margin-bottom: 32px;
    }

    .upload-area {
        padding: 32px 16px;
    }

    .upload-icon {
        font-size: 2rem;
    }

    .upload-text {
        font-size: 0.95rem;
    }

    .btn {
        padding: 14px 24px;
        font-size: 0.9rem;
    }

    footer {
        font-size: 0.8rem;
        margin-top: 32px;
    }

    footer a {
        display: inline-block;
        margin: 4px 6px;
    }
}
