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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0f0f1a;
    color: #e0e0e0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.container {
    max-width: 640px;
    width: 100%;
    padding: 40px 20px;
    margin: 0 auto;
}

.header {
    text-align: center;
    margin-bottom: 40px;
}

.header h1 {
    font-size: 2.2rem;
    color: #fff;
    margin-bottom: 8px;
}

.header p {
    color: #888;
    font-size: 1rem;
}

.upload-area {
    border: 2px dashed #333;
    border-radius: 16px;
    padding: 60px 30px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    background: #16162a;
    position: relative;
}

.upload-area:hover,
.upload-area.dragover {
    border-color: #6c5ce7;
    background: #1a1a35;
}

.upload-area .icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.upload-area p {
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.upload-area .hint {
    color: #666;
    font-size: 0.85rem;
}

.file-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.btn {
    display: inline-block;
    padding: 14px 36px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: #6c5ce7;
    color: #fff;
}

.btn-primary:hover {
    background: #5a4bd1;
    transform: translateY(-1px);
}

.btn-primary:disabled {
    background: #444;
    cursor: not-allowed;
    transform: none;
}

.btn-download {
    background: #00b894;
    color: #fff;
    font-size: 1.1rem;
    padding: 16px 48px;
}

.btn-download:hover {
    background: #00a381;
}

.upload-btn-wrapper {
    margin-top: 24px;
}

.selected-file {
    margin-top: 16px;
    padding: 12px 20px;
    background: #1e1e3a;
    border-radius: 8px;
    display: none;
    align-items: center;
    justify-content: space-between;
}

.selected-file.show {
    display: flex;
}

.selected-file .name {
    color: #b0b0b0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 70%;
}

.selected-file .size {
    color: #6c5ce7;
    font-weight: 500;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: #222;
    border-radius: 3px;
    margin-top: 20px;
    overflow: hidden;
    display: none;
}

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

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

.progress-text {
    text-align: center;
    margin-top: 8px;
    color: #888;
    font-size: 0.9rem;
    display: none;
}

.progress-text.show {
    display: block;
}

.result-card {
    background: #16162a;
    border-radius: 16px;
    padding: 32px;
    text-align: center;
}

.result-card .check {
    font-size: 3rem;
    margin-bottom: 12px;
}

.result-card h2 {
    color: #00b894;
    margin-bottom: 20px;
}

.link-box {
    display: flex;
    align-items: center;
    background: #0f0f1a;
    border: 1px solid #333;
    border-radius: 10px;
    padding: 4px;
    margin: 20px 0;
}

.link-box input {
    flex: 1;
    background: none;
    border: none;
    color: #e0e0e0;
    padding: 12px 16px;
    font-size: 0.95rem;
    outline: none;
}

.link-box .copy-btn {
    padding: 10px 20px;
    background: #6c5ce7;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.2s;
}

.link-box .copy-btn:hover {
    background: #5a4bd1;
}

.file-info {
    color: #888;
    font-size: 0.9rem;
    margin-top: 12px;
    line-height: 1.8;
}

.download-card {
    background: #16162a;
    border-radius: 16px;
    padding: 40px 32px;
    text-align: center;
}

.download-card h2 {
    margin-bottom: 24px;
    color: #fff;
}

.download-card .meta {
    color: #888;
    margin-bottom: 32px;
    line-height: 2;
}

.download-card .meta span {
    color: #b0b0b0;
}

.error-card {
    background: #1a1020;
    border: 1px solid #e74c3c33;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
}

.error-card h2 {
    color: #e74c3c;
    margin-bottom: 12px;
}

.error-card p {
    color: #888;
}

.alert {
    padding: 14px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.alert-error {
    background: #2d1525;
    color: #e74c3c;
    border: 1px solid #e74c3c33;
}

.back-link {
    display: inline-block;
    margin-top: 24px;
    color: #6c5ce7;
    text-decoration: none;
}

.back-link:hover {
    text-decoration: underline;
}

.footer {
    text-align: center;
    padding: 30px;
    color: #444;
    font-size: 0.85rem;
}
