:root {
    --bg: #03040a;
    --primary: #8b2cf5;
    --primary-2: #6366f1;
    --primary-glow: rgba(139, 44, 245, 0.4);
    --accent: #00d4ff;
    --accent-glow: rgba(0, 212, 255, 0.3);
    --success: #00ffb3;
    --text: #f0f4ff;
    --text-2: #94a3b8;
    --text-3: #475569;
    --border: rgba(255, 255, 255, 0.06);
}

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

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* ── Aurora background ───────────────────────────────── */
.glow-wrapper {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.glow-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0;
    animation: blob-in 2s forwards;
}

@keyframes blob-in {
    to { opacity: 1; }
}

.blob-1 {
    width: 650px; height: 650px;
    background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
    top: -20%; left: -5%;
    opacity: 0;
    animation: blob-in 2s 0.2s forwards, float-1 30s 2s infinite alternate ease-in-out;
}

.blob-2 {
    width: 550px; height: 550px;
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
    bottom: -15%; right: -5%;
    opacity: 0;
    animation: blob-in 2s 0.4s forwards, float-2 26s 2s infinite alternate ease-in-out;
}

.blob-3 {
    width: 380px; height: 380px;
    background: radial-gradient(circle, #ff2d78 0%, transparent 70%);
    top: 35%; left: 55%;
    opacity: 0;
    animation: blob-in 2s 0.6s forwards, float-3 34s 2s infinite alternate ease-in-out;
}

.blob-4 {
    width: 280px; height: 280px;
    background: radial-gradient(circle, var(--success) 0%, transparent 70%);
    top: 60%; left: 15%;
    opacity: 0;
    animation: blob-in 2s 0.8s forwards, float-4 28s 2s infinite alternate ease-in-out;
}

@keyframes float-1 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(70px, 60px) scale(1.08); }
}
@keyframes float-2 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-80px, -60px) scale(1.12); }
}
@keyframes float-3 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-40px, 50px) scale(0.92); }
}
@keyframes float-4 {
    0%   { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, -30px) scale(1.06); }
}

/* Grid mesh overlay */
.glow-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.015) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 0%, transparent 100%);
}

/* ── Card container ──────────────────────────────────── */
.container {
    width: 100%;
    max-width: 460px;
    padding: 20px;
    z-index: 10;
    animation: card-in 1.1s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes card-in {
    from { opacity: 0; transform: translateY(40px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Glassmorphism login card ────────────────────────── */
.login-card {
    background: rgba(20, 18, 40, 0.32);
    backdrop-filter: blur(40px) saturate(160%);
    -webkit-backdrop-filter: blur(40px) saturate(160%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 28px;
    padding: 52px 44px;
    box-shadow:
        0 30px 70px rgba(0, 0, 0, 0.35),
        0 0 0 1px rgba(139, 44, 245, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: background-color 0.5s var(--ease-smooth), box-shadow 0.5s var(--ease-smooth);
}

/* Top shimmer sweep */
.login-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(
        105deg,
        transparent 40%,
        rgba(255,255,255,0.04) 50%,
        transparent 60%
    );
    transform: translateX(-100%);
    animation: shimmer-card 5s 1s infinite linear;
}

@keyframes shimmer-card {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Gradient border glow on top */
.login-card::after {
    content: '';
    position: absolute;
    top: 0; left: 10%; right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139,44,245,0.6), var(--accent), rgba(139,44,245,0.6), transparent);
    border-radius: 999px;
}

/* ── Logo ────────────────────────────────────────────── */
.logo-container {
    position: relative;
    width: 88px; height: 88px;
    margin: 0 auto 32px;
}

.logo-glow {
    position: absolute;
    inset: -4px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 26px;
    filter: blur(16px);
    opacity: 0.65;
    animation: glow-pulse 3.5s ease-in-out infinite alternate;
}

@keyframes glow-pulse {
    0%   { transform: scale(0.9);  opacity: 0.5; }
    100% { transform: scale(1.1);  opacity: 0.85; }
}

.logo-icon {
    position: relative;
    width: 100%; height: 100%;
    background: linear-gradient(135deg, #160c2e, #081428);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.logo-icon svg {
    width: 38px; height: 38px;
    fill: url(#logo-grad);
    filter: drop-shadow(0 0 8px rgba(139,44,245,0.5));
}

/* ── Typography ──────────────────────────────────────── */
h1 {
    font-size: 27px;
    font-weight: 800;
    margin-bottom: 10px;
    letter-spacing: 0.4px;
    background: linear-gradient(135deg, #ffffff 30%, #c4b5fd 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-2);
    font-size: 14px;
    margin-bottom: 38px;
    line-height: 1.6;
}

/* ── Steps block ─────────────────────────────────────── */
.instructions {
    text-align: left;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 18px;
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 32px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    position: relative;
    overflow: hidden;
}

.instructions::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--primary), var(--accent), transparent);
    border-radius: 2px;
}

.step {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.step-num {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #fff;
    width: 26px; height: 26px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 800;
    flex-shrink: 0;
    box-shadow: 0 4px 10px var(--primary-glow);
}

.step-text {
    font-size: 14px;
    line-height: 1.55;
    color: #dde5f4;
    padding-top: 3px;
}

.step-text code {
    background: rgba(0, 212, 255, 0.08);
    color: var(--accent);
    padding: 2px 8px;
    border-radius: 6px;
    font-family: 'Fira Code', 'Consolas', monospace;
    font-size: 12.5px;
    border: 1px solid rgba(0, 212, 255, 0.15);
}

/* ── Error alert ─────────────────────────────────────── */
.alert-error {
    background: rgba(255, 77, 109, 0.07);
    border: 1px solid rgba(255, 77, 109, 0.25);
    color: #ff8fa3;
    padding: 14px 18px;
    border-radius: 14px;
    font-size: 13px;
    margin-bottom: 24px;
    text-align: left;
    line-height: 1.5;
    display: none;
    animation: shake 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%       { transform: translateX(-8px); }
    40%       { transform: translateX(8px); }
    60%       { transform: translateX(-5px); }
    80%       { transform: translateX(5px); }
}

/* ── Footer ──────────────────────────────────────────── */
.footer {
    font-size: 11.5px;
    color: var(--text-3);
    margin-top: 8px;
    letter-spacing: 0.3px;
}
