:root {
    --accent: #dc2626;
    --accent-strong: #ef4444;
    --accent-soft: rgba(220, 38, 38, 0.12);
    --bg-dark: #0f172a;
    --panel: #1e293b;
    --panel-soft: #334155;
    --text-light: #f1f5f9;
    --text-muted: #94a3b8;
    --gold: #f59e0b;
    --success: #10b981;
    --error: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Manrope", "Inter", "SF Pro Display", -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background:
        radial-gradient(110% 90% at 10% 10%, rgba(220, 38, 38, 0.15), transparent 60%),
        radial-gradient(80% 80% at 85% 15%, rgba(239, 68, 68, 0.12), transparent 55%),
        radial-gradient(60% 60% at 50% 50%, rgba(220, 38, 38, 0.08), transparent 70%),
        linear-gradient(180deg, #0f172a 0%, #020617 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    color: var(--text-light);
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(220, 38, 38, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(239, 68, 68, 0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.top-nav {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
}

.nav-link {
    padding: 10px 20px;
    background: rgba(30, 41, 59, 0.8);
    backdrop-filter: blur(10px);
    color: var(--text-light);
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    border: 1px solid rgba(220, 38, 38, 0.2);
}

.nav-link:hover {
    background: rgba(30, 41, 59, 0.95);
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(220, 38, 38, 0.3);
}

.container {
    width: 100%;
    max-width: 600px;
    position: relative;
    z-index: 1;
}

.header {
    text-align: center;
    margin-bottom: 40px;
}

.logo {
    width: 120px;
    height: 120px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 10px 30px rgba(220, 38, 38, 0.5));
}

.logo-svg {
    width: 100%;
    height: 100%;
}

.logo-text {
    font-size: 36px;
    font-weight: 800;
    color: white;
}

h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    background: linear-gradient(135deg, var(--text-light) 0%, var(--accent-strong) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: var(--text-muted);
    font-size: 15px;
}

.card {
    background: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 
        0 25px 70px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(220, 38, 38, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(148, 163, 184, 0.1);
}

.input-group {
    margin-bottom: 25px;
}

label {
    display: block;
    color: var(--text-light);
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 14px;
}

input[type="text"] {
    width: 100%;
    padding: 14px 18px;
    background: rgba(15, 23, 42, 0.6);
    border: 2px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    font-size: 16px;
    color: var(--text-light);
    transition: all 0.3s ease;
    font-family: "Manrope", sans-serif;
}

input[type="text"]:focus {
    outline: none;
    border-color: var(--accent);
    background: rgba(15, 23, 42, 0.8);
    box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.1), 0 0 20px rgba(220, 38, 38, 0.2);
}

.input-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 8px;
}

.btn-primary {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--accent) 0%, #b91c1c 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(220, 38, 38, 0.4);
    font-family: "Manrope", sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(220, 38, 38, 0.5);
    background: linear-gradient(135deg, var(--accent-strong) 0%, #991b1b 100%);
}

.btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.message {
    padding: 14px 18px;
    border-radius: 12px;
    margin-top: 20px;
    font-size: 14px;
    border: 1px solid;
}

.message.success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
    border-color: rgba(16, 185, 129, 0.3);
}

.message.error {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
    border-color: rgba(239, 68, 68, 0.3);
}

.build-progress {
    margin-top: 30px;
    padding: 25px;
    background: rgba(15, 23, 42, 0.4);
    border-radius: 16px;
    border: 1px solid rgba(220, 38, 38, 0.2);
}

.progress-header h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-light);
}

.progress-header p {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.progress-bar-container {
    width: 100%;
    height: 8px;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent) 0%, #b91c1c 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-light);
}

.download-section {
    margin-top: 30px;
    text-align: center;
}

.success-message {
    margin-bottom: 25px;
}

.check-icon {
    width: 64px;
    height: 64px;
    color: var(--success);
    margin: 0 auto 20px;
    display: block;
}

.success-message h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-light);
}

.success-message p {
    color: var(--text-muted);
    font-size: 14px;
}

.btn-download {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.4);
}

.btn-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.5);
    background: linear-gradient(135deg, #34d399 0%, var(--success) 100%);
}

.btn-download svg {
    width: 20px;
    height: 20px;
}

.footer {
    text-align: center;
    margin-top: 40px;
    color: var(--text-muted);
    font-size: 14px;
}
