:root {
    --bg: #030712;
    --surface: #0b1120;
    --border: #1e3a5f;
    --border-subtle: #0f172a;
    --text: #e2e8f0;
    --text-dim: #64748b;
    --accent: #0ea5e9;
    --accent-bright: #38bdf8;
    --accent-deep: #0284c7;
    --accent-glow: rgba(14, 165, 233, 0.3);
    --error: #ef4444;
    --error-glow: rgba(239, 68, 68, 0.25);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --mono: "JetBrains Mono", "SF Mono", "Menlo", "Consolas", monospace;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    background: var(--bg); color: var(--text); font-family: var(--font);
    display: flex; justify-content: center; align-items: flex-start;
    min-height: 100vh; padding: 60px 20px; overflow-x: hidden; position: relative;
}
.bg-mesh { position: fixed; inset: 0; z-index: 0; overflow: hidden; }
.bg-mesh::before {
    content: ''; position: absolute; width: 140%; height: 140%; top: -20%; left: -20%;
    background:
        radial-gradient(ellipse 80% 50% at 20% 40%, rgba(14,165,233,0.12) 0%, transparent 55%),
        radial-gradient(ellipse 60% 40% at 80% 60%, rgba(56,189,248,0.08) 0%, transparent 50%),
        radial-gradient(ellipse 50% 50% at 50% 100%, rgba(2,132,199,0.06) 0%, transparent 40%);
    animation: meshFloat 20s ease-in-out infinite;
}
@keyframes meshFloat {
    0%,100% { transform: translate(0,0) rotate(0deg); }
    33% { transform: translate(2%,1%) rotate(0.5deg); }
    66% { transform: translate(-1%,2%) rotate(-0.3deg); }
}
.grid-overlay {
    position: fixed; inset: 0; z-index: 0;
    background-image: linear-gradient(rgba(14,165,233,0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(14,165,233,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 30%, transparent 70%);
    -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 30%, transparent 70%);
    pointer-events: none;
}
.particles { position: fixed; inset: 0; pointer-events: none; z-index: 0; }
.particle { position: absolute; border-radius: 50%; animation: floatUp linear infinite; }
.particle.type-1 { width: 2px; height: 2px; background: rgba(56,189,248,0.6); box-shadow: 0 0 6px rgba(56,189,248,0.4); }
.particle.type-2 { width: 3px; height: 3px; background: rgba(14,165,233,0.4); box-shadow: 0 0 10px rgba(14,165,233,0.3); }
.particle.type-3 { width: 1px; height: 1px; background: rgba(186,230,253,0.8); }
@keyframes floatUp {
    0% { transform: translateY(110vh) scale(0); opacity: 0; }
    8% { opacity: 1; } 92% { opacity: 1; }
    100% { transform: translateY(-10vh) scale(1.2); opacity: 0; }
}
.app { position: relative; z-index: 1; width: 100%; max-width: 740px; }

.header { display: flex; align-items: center; gap: 16px; margin-bottom: 40px; animation: fadeUp 0.6s ease forwards; }
.logo { width: 48px; height: 48px; position: relative; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.logo-ring { position: absolute; inset: 0; border-radius: 14px; border: 2px solid rgba(14,165,233,0.3); animation: logoRingPulse 3s ease-in-out infinite; }
.logo-ring-2 { position: absolute; inset: 4px; border-radius: 10px; border: 1.5px solid rgba(56,189,248,0.15); animation: logoRingPulse 3s ease-in-out infinite 0.5s; }
@keyframes logoRingPulse { 0%,100% { border-color: rgba(14,165,233,0.2); transform: scale(1); } 50% { border-color: rgba(14,165,233,0.5); transform: scale(1.02); } }
.logo svg { width: 26px; height: 26px; z-index: 1; filter: drop-shadow(0 0 8px rgba(14,165,233,0.5)); }
.header-text h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.8px; line-height: 1.1; background: linear-gradient(135deg, #f1f5f9 0%, #94a3b8 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.header-text span { font-size: 13.5px; color: var(--text-dim); font-weight: 500; display: block; margin-top: 4px; letter-spacing: 0.2px; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 32px; animation: fadeUp 0.6s ease forwards 0.1s; opacity: 0; }
.step { background: linear-gradient(145deg, rgba(11,17,32,0.9), rgba(17,24,39,0.7)); border: 1px solid var(--border-subtle); border-radius: 14px; padding: 20px 18px; transition: all 0.35s cubic-bezier(0.4,0,0.2,1); cursor: default; position: relative; overflow: hidden; backdrop-filter: blur(10px); }
.step::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: 0; transition: opacity 0.4s; }
.step:hover { transform: translateY(-4px); border-color: rgba(14,165,233,0.3); box-shadow: 0 12px 40px rgba(14,165,233,0.1), 0 0 0 1px rgba(14,165,233,0.1); }
.step:hover::before { opacity: 1; }
.step-number { font-size: 10px; font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: 1.2px; opacity: 0.85; }
.step-title { font-size: 15px; font-weight: 600; color: #e0f2fe; margin-top: 6px; letter-spacing: -0.2px; }
.step-desc { font-size: 12px; color: var(--text-dim); line-height: 1.55; margin-top: 5px; font-weight: 400; }

.features-strip { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 30px; animation: fadeUp 0.6s ease forwards 0.15s; opacity: 0; }
.feature-item { display: flex; align-items: center; gap: 10px; flex: 1; padding: 12px 16px; background: linear-gradient(135deg, rgba(14,165,233,0.04), rgba(56,189,248,0.02)); border: 1px solid rgba(14,165,233,0.08); border-radius: 12px; transition: all 0.3s ease; backdrop-filter: blur(4px); }
.feature-item:hover { background: linear-gradient(135deg, rgba(14,165,233,0.08), rgba(56,189,248,0.04)); border-color: rgba(14,165,233,0.2); transform: translateY(-1px); }
.feature-icon { font-size: 18px; opacity: 0.9; filter: drop-shadow(0 0 4px rgba(14,165,233,0.3)); }
.feature-text { font-size: 12.5px; font-weight: 500; color: #94a3b8; }

.card { background: linear-gradient(165deg, rgba(11,17,32,0.95), rgba(17,24,39,0.85)); border: 1px solid var(--border-subtle); border-radius: 18px; padding: 36px 40px; box-shadow: 0 0 0 1px rgba(14,165,233,0.05), 0 20px 60px rgba(0,0,0,0.5), 0 0 80px rgba(14,165,233,0.03); position: relative; overflow: hidden; transition: all 0.4s ease; animation: fadeUp 0.6s ease forwards 0.2s; opacity: 0; backdrop-filter: blur(20px); }
.card::before { content: ''; position: absolute; top: 0; left: 30px; right: 30px; height: 1.5px; background: linear-gradient(90deg, transparent, var(--accent-bright), transparent); opacity: 0; transition: opacity 0.5s; box-shadow: 0 0 20px var(--accent-glow); }
.card:hover { box-shadow: 0 0 0 1px rgba(14,165,233,0.1), 0 30px 80px rgba(0,0,0,0.6), 0 0 100px rgba(14,165,233,0.06); border-color: rgba(14,165,233,0.15); }
.card:hover::before { opacity: 1; }
.card::after { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: radial-gradient(circle at 30% 20%, rgba(14,165,233,0.03) 0%, transparent 40%); pointer-events: none; }

.field { margin-bottom: 22px; position: relative; z-index: 1; }
.field-label { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; color: #94a3b8; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.6px; }
.field-label .icon { font-size: 15px; opacity: 0.85; transition: transform 0.2s; }
.field:hover .field-label .icon { transform: scale(1.1); }
.input-wrap { position: relative; }
.input-wrap input { width: 100%; height: 54px; padding: 0 50px 0 18px; background: linear-gradient(145deg, rgba(3,7,18,0.8), rgba(11,17,32,0.6)); border: 1.5px solid rgba(30,58,95,0.4); border-radius: 12px; color: #e2e8f0; font-family: var(--mono); font-size: 14px; outline: none; transition: all 0.3s cubic-bezier(0.4,0,0.2,1); letter-spacing: -0.2px; }
.input-wrap input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-glow), 0 0 20px rgba(14,165,233,0.1); background: linear-gradient(145deg, rgba(3,7,18,0.9), rgba(11,17,32,0.7)); }
.input-wrap input::placeholder { color: #334155; font-family: var(--mono); font-size: 13px; }
.input-wrap input.error { border-color: var(--error) !important; box-shadow: 0 0 0 4px var(--error-glow) !important; background: linear-gradient(145deg, rgba(239,68,68,0.05), rgba(11,17,32,0.6)) !important; }
.input-wrap .status-icon { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-size: 17px; color: #334155; pointer-events: none; transition: all 0.3s ease; }
.input-wrap:focus-within .status-icon { color: var(--accent-bright); transform: translateY(-50%) scale(1.15); filter: drop-shadow(0 0 6px rgba(14,165,233,0.4)); }
.input-wrap input.error ~ .status-icon { color: var(--error); filter: drop-shadow(0 0 6px rgba(239,68,68,0.4)); }

.error-msg { display: none; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; color: var(--error); font-weight: 500; animation: shake 0.4s ease; }
.error-msg.show { display: flex; }
@keyframes shake { 0%,100% { transform: translateX(0); } 20% { transform: translateX(-4px); } 40% { transform: translateX(4px); } 60% { transform: translateX(-3px); } 80% { transform: translateX(3px); } }

.divider { display: flex; align-items: center; gap: 16px; margin: 28px 0; position: relative; z-index: 1; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: linear-gradient(to right, transparent, rgba(30,58,95,0.6), transparent); }
.divider span { font-size: 11px; font-weight: 700; color: #475569; letter-spacing: 2px; text-transform: uppercase; padding: 4px 12px; background: rgba(11,17,32,0.8); border-radius: 20px; border: 1px solid rgba(30,58,95,0.3); }

.btn { width: 100%; height: 56px; background: linear-gradient(135deg, #0284c7, #0ea5e9, #38bdf8); background-size: 200% 200%; background-position: 0% 50%; border: none; border-radius: 14px; color: white; font-size: 15px; font-weight: 600; font-family: var(--font); cursor: pointer; transition: all 0.35s cubic-bezier(0.4,0,0.2,1); letter-spacing: 0.3px; position: relative; overflow: hidden; box-shadow: 0 8px 30px rgba(14,165,233,0.3), 0 0 0 1px rgba(56,189,248,0.2), inset 0 1px 0 rgba(255,255,255,0.1); margin-top: 8px; z-index: 1; }
.btn:hover { background-position: 100% 50%; box-shadow: 0 12px 40px rgba(14,165,233,0.45), 0 0 0 1px rgba(56,189,248,0.3), inset 0 1px 0 rgba(255,255,255,0.15); transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(0.98); box-shadow: 0 4px 15px rgba(14,165,233,0.3), 0 0 0 1px rgba(56,189,248,0.2); }
.btn::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent); transition: left 0.6s ease; }
.btn:hover::before { left: 100%; }

.security-note { margin-top: 28px; display: flex; align-items: flex-start; gap: 14px; padding: 18px 20px; background: linear-gradient(135deg, rgba(14,165,233,0.04), rgba(56,189,248,0.02)); border: 1px solid rgba(14,165,233,0.1); border-radius: 12px; font-size: 12.5px; color: #64748b; line-height: 1.6; transition: all 0.3s ease; position: relative; z-index: 1; backdrop-filter: blur(4px); }
.security-note:hover { background: linear-gradient(135deg, rgba(14,165,233,0.06), rgba(56,189,248,0.03)); border-color: rgba(14,165,233,0.2); transform: translateX(2px); }
.security-note .shield { font-size: 20px; flex-shrink: 0; margin-top: 1px; filter: drop-shadow(0 0 6px rgba(14,165,233,0.3)); }

.footer { margin-top: 32px; text-align: center; font-size: 12px; color: #475569; display: flex; justify-content: center; gap: 28px; flex-wrap: wrap; animation: fadeUp 0.6s ease forwards 0.25s; opacity: 0; }
.footer span { display: flex; align-items: center; gap: 6px; font-weight: 500; }
.dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; }
.dot.green { background: #22d3ee; box-shadow: 0 0 8px rgba(34,211,238,0.6); }
.dot.blue { background: #0ea5e9; box-shadow: 0 0 8px rgba(14,165,233,0.6); }
.dot.cyan { background: #67e8f9; box-shadow: 0 0 8px rgba(103,232,249,0.5); }

@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.scanline { position: fixed; inset: 0; z-index: 2; pointer-events: none; background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(14,165,233,0.008) 2px, rgba(14,165,233,0.008) 4px); }

.overlay { position: fixed; inset: 0; z-index: 100; background: rgba(3,7,18,0.92); backdrop-filter: blur(20px); display: none; align-items: center; justify-content: center; opacity: 0; transition: opacity 0.4s ease; }
.overlay.show { display: flex; }
.overlay.fade-in { opacity: 1; }
.overlay-content { text-align: center; padding: 40px; max-width: 420px; width: 90%; }

.spinner-wrap { position: relative; width: 80px; height: 80px; margin: 0 auto 28px; }
.spinner { width: 80px; height: 80px; border-radius: 50%; border: 3px solid rgba(14,165,233,0.1); border-top-color: var(--accent-bright); border-right-color: var(--accent); animation: spin 1s linear infinite; }
.spinner-inner { position: absolute; inset: 12px; border-radius: 50%; border: 2px solid rgba(14,165,233,0.08); border-bottom-color: rgba(56,189,248,0.6); animation: spin 1.5s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }

.overlay-title { font-size: 20px; font-weight: 700; color: #f1f5f9; margin-bottom: 8px; letter-spacing: -0.3px; }
.overlay-subtitle { font-size: 13.5px; color: var(--text-dim); margin-bottom: 28px; }

.game-preview { display: none; background: linear-gradient(145deg, rgba(11,17,32,0.95), rgba(17,24,39,0.9)); border: 1px solid rgba(14,165,233,0.2); border-radius: 16px; overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 40px rgba(14,165,233,0.1); animation: previewIn 0.5s cubic-bezier(0.4,0,0.2,1) forwards; }
.game-preview.show { display: block; }
@keyframes previewIn { from { opacity: 0; transform: scale(0.9) translateY(20px); } to { opacity: 1; transform: scale(1) translateY(0); } }

.game-image { width: 100%; aspect-ratio: 16/9; background: linear-gradient(135deg, #0c4a6e 0%, #075985 40%, #0369a1 70%, #0ea5e9 100%); position: relative; overflow: hidden; }
.game-image img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; z-index: 2; }
.game-image .img-fallback { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; z-index: 1; font-size: 48px; }
.game-image .img-shine { position: absolute; inset: 0; background: linear-gradient(105deg, transparent 40%, rgba(255,255,255,0.08) 50%, transparent 60%); z-index: 3; pointer-events: none; }

.game-info { padding: 20px 24px; text-align: left; }
.game-title { font-size: 17px; font-weight: 700; color: #f1f5f9; margin-bottom: 4px; letter-spacing: -0.2px; }
.game-meta { font-size: 12.5px; color: var(--text-dim); display: flex; align-items: center; gap: 12px; }
.game-meta span { display: flex; align-items: center; gap: 4px; }
.progress-bar { width: 100%; height: 4px; background: rgba(14,165,233,0.1); border-radius: 2px; margin-top: 16px; overflow: hidden; }
.progress-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--accent-deep), var(--accent-bright)); border-radius: 2px; transition: width 0.3s ease; box-shadow: 0 0 10px rgba(14,165,233,0.4); }
.download-btn { width: 100%; margin-top: 16px; height: 46px; background: linear-gradient(135deg, #0284c7, #0ea5e9); border: none; border-radius: 10px; color: white; font-size: 14px; font-weight: 600; font-family: var(--font); cursor: pointer; transition: all 0.25s ease; box-shadow: 0 6px 20px rgba(14,165,233,0.25); }
.download-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 25px rgba(14,165,233,0.4); }
.close-overlay { position: absolute; top: 24px; right: 24px; width: 40px; height: 40px; background: rgba(11,17,32,0.8); border: 1px solid rgba(14,165,233,0.2); border-radius: 10px; color: var(--text-dim); font-size: 18px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; }
.close-overlay:hover { background: rgba(14,165,233,0.1); border-color: rgba(14,165,233,0.4); color: var(--accent-bright); }

@media (max-width: 640px) { .steps { grid-template-columns: 1fr; } .features-strip { flex-direction: column; } .card { padding: 24px 20px; } .header-text h1 { font-size: 26px; } body { padding: 40px 16px; } }