@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

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

:root {
    --bg: #050508;
    --glass: rgba(10, 10, 15, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shine: rgba(255, 255, 255, 0.1);
    --surface: rgba(15, 15, 20, 0.5);
    --surface-hover: rgba(25, 25, 35, 0.7);
    --text: rgba(255, 255, 255, 0.95);
    --text-secondary: rgba(255, 255, 255, 0.5);
    --text-tertiary: rgba(255, 255, 255, 0.28);
    --accent-purple: #7c3aed;
    --accent-blue: #3b82f6;
    --accent-cyan: #06b6d4;
    --radius-card: 22px;
    --radius-btn: 18px;
    --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html, body {
    height: 100%;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* ─── BACKGROUND ──────────────────────────────── */
.bg-blob {
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    will-change: transform;
}
.blob-1 {
    width: 700px; height: 700px;
    background: radial-gradient(circle at center, rgba(40, 40, 50, 0.2), transparent 70%);
    top: -200px; left: -180px;
    animation: drift1 45s ease-in-out infinite alternate;
}
.blob-2 {
    width: 600px; height: 600px;
    background: radial-gradient(circle at center, rgba(20, 25, 35, 0.3), transparent 70%);
    bottom: -150px; right: -150px;
    animation: drift2 55s ease-in-out infinite alternate;
}
.blob-3 {
    width: 300px; height: 300px;
    background: radial-gradient(circle at center, rgba(30, 30, 45, 0.15), transparent 70%);
    top: 40%; left: 50%; transform: translate(-50%, -50%);
    animation: drift3 40s ease-in-out infinite alternate;
}
@keyframes drift1 { from { transform: translate(0,0) scale(1); } to { transform: translate(40px, 60px) scale(1.1); } }
@keyframes drift2 { from { transform: translate(0,0) scale(1); } to { transform: translate(-50px, -40px) scale(1.08); } }
@keyframes drift3 { from { transform: translate(-50%,-50%) scale(1); } to { transform: translate(-48%,-52%) scale(0.9); } }

/* ─── NOISE LAYER ─────────────────────────────── */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    opacity: 0.03;
    pointer-events: none;
    z-index: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 128px;
}

/* ─── LAYOUT ──────────────────────────────────── */
.page-wrapper {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px 60px;
}

.card {
    width: 100%;
    max-width: 390px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

/* ─── PROFILE ─────────────────────────────────── */
.profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 36px;
    text-align: center;
}

.avatar-ring {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    padding: 2.5px;
    background: linear-gradient(145deg, #2a2a36, #121218, #303040, #2a2a36);
    background-size: 300% 300%;
    animation: gradientSpin 20s ease-in-out infinite;
    margin-bottom: 20px;
    box-shadow:
        0 0 0 1px rgba(255,255,255,0.06),
        0 8px 32px rgba(124, 58, 237, 0.35),
        0 24px 60px rgba(0,0,0,0.5);
    flex-shrink: 0;
}
@keyframes gradientSpin {
    0%   { background-position: 0% 50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    object-position: center top;
    display: block;
    border: 2.5px solid var(--bg);
}

.name {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--text);
    margin-bottom: 6px;
    line-height: 1.15;
}

.bio {
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--text-secondary);
    margin-bottom: 22px;
    letter-spacing: 0.005em;
}

/* ─── SOCIALS ─────────────────────────────────── */
.socials {
    display: flex;
    gap: 12px;
    align-items: center;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    transition: transform 0.35s var(--spring);
    text-decoration: none;
}
.social-icon svg { width: 32px; height: 32px; }
.social-icon:hover {
    transform: scale(1.15) translateY(-2px);
}
.social-icon:active { transform: scale(0.94); transition-duration: 0.1s; }

/* ─── LINKS ───────────────────────────────────── */
.links {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 22px;
    margin-bottom: 40px;
}

.link-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-btn);
    padding: 18px 20px 18px 18px;
    cursor: pointer;
    text-align: left;
    color: var(--text);
    font-family: 'Inter', sans-serif;
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    transition:
        background 0.25s,
        transform 0.4s var(--spring),
        box-shadow 0.3s,
        border-color 0.25s;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 1px 0 rgba(255,255,255,0.08) inset,
        0 8px 24px rgba(0,0,0,0.3);
}

/* top shine line */
.link-btn::before {
    content: '';
    position: absolute;
    top: 0; left: 12px; right: 12px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    pointer-events: none;
}

/* press ripple */
.link-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at var(--rx,50%) var(--ry,50%), rgba(255,255,255,0.08), transparent 70%);
    opacity: 0;
    transition: opacity 0.6s;
    pointer-events: none;
}
.link-btn.pressed::after { opacity: 1; transition: opacity 0s; }

.link-btn:hover {
    background: var(--surface-hover);
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-3px) scale(1.005);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.1) inset,
        0 20px 48px rgba(0,0,0,0.45),
        0 0 0 1px rgba(255,255,255,0.06);
}
.link-btn:active {
    transform: scale(0.975);
    transition-duration: 0.1s;
}

.link-thumb {
    width: 72px;
    height: 72px;
    border-radius: 18px;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    position: relative;
}
.link-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 18px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.25), inset 0 -1px 0 rgba(0,0,0,0.2);
    pointer-events: none;
}
.link-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 18px;
}
.link-thumb.yt {
    background: linear-gradient(145deg, #ff3b30, #cc2d22);
    color: #fff;
}
.link-thumb.yt svg { width: 24px; height: 24px; position: relative; z-index: 1; }

.link-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}
.link-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    letter-spacing: -0.01em;
    white-space: normal;
    word-break: break-word;
}
.link-sub {
    font-size: 0.76rem;
    color: var(--text-secondary);
    font-weight: 400;
    letter-spacing: 0.005em;
}

.link-arrow {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255,255,255,0.07);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s, transform 0.3s var(--spring);
}
.link-arrow svg {
    width: 14px;
    height: 14px;
    color: var(--text-secondary);
    transition: color 0.2s, transform 0.3s var(--spring);
    margin-left: 1px;
}
.link-btn:hover .link-arrow {
    background: rgba(255,255,255,0.12);
    transform: translateX(2px);
}
.link-btn:hover .link-arrow svg {
    color: var(--text);
    transform: translateX(1px);
}

/* ─── FOOTER ──────────────────────────────────── */
.footer-brand {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    letter-spacing: 0.04em;
    font-weight: 400;
    user-select: none;
}

/* ─── ENTRANCE ANIMATIONS ─────────────────────── */
.anim-in {
    opacity: 0;
    transform: translateY(28px) scale(0.97);
    animation: slideIn 0.8s var(--ease) forwards;
    animation-delay: var(--d, 0s);
}
@keyframes slideIn {
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ─── VERIFY OVERLAY ──────────────────────────── */
.verify-overlay {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: env(safe-area-inset-bottom, 0px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s var(--ease);
}
.verify-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    transition: opacity 0.35s;
}
.verify-overlay.open {
    opacity: 1;
    pointer-events: all;
}

.verify-modal {
    position: relative;
    z-index: 1;
    background: rgba(28, 28, 36, 0.92);
    border: 1px solid rgba(255,255,255,0.1);
    border-bottom: none;
    border-radius: 28px 28px 0 0;
    padding: 12px 28px 44px;
    width: 100%;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transform: translateY(100%);
    transition: transform 0.55s var(--spring);
    box-shadow:
        0 -1px 0 rgba(255,255,255,0.12),
        0 -40px 80px rgba(0,0,0,0.5);
    backdrop-filter: blur(40px) saturate(200%);
    -webkit-backdrop-filter: blur(40px) saturate(200%);
}
.verify-overlay.open .verify-modal {
    transform: translateY(0);
}

/* pill handle */
.verify-modal::before {
    content: '';
    display: block;
    width: 40px;
    height: 5px;
    background: rgba(255,255,255,0.2);
    border-radius: 99px;
    margin: 0 auto 28px;
    flex-shrink: 0;
}

.verify-step {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}
.verify-step.hidden { display: none; }

/* Spinner */
.spinner-ring {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2.5px solid rgba(255,255,255,0.06);
    border-top-color: #a78bfa;
    border-right-color: #60a5fa;
    animation: spin 0.85s linear infinite;
    box-shadow: 0 0 20px rgba(167,139,250,0.2);
    margin-bottom: 4px;
}
@keyframes spin { to { transform: rotate(360deg); } }

.step-label {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text);
    min-height: 1.5em;
    transition: opacity 0.3s;
    letter-spacing: -0.01em;
}

.step-dots {
    display: flex;
    gap: 7px;
    margin-top: 4px;
}
.step-dots span {
    width: 7px; height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    animation: dotPulse 1.6s ease-in-out infinite;
}
.step-dots span:nth-child(2) { animation-delay: 0.25s; }
.step-dots span:nth-child(3) { animation-delay: 0.5s; }
@keyframes dotPulse {
    0%,100% { background: rgba(255,255,255,0.12); transform: scale(1); }
    50% { background: #a78bfa; transform: scale(1.4); }
}

/* Lock step */
.lock-icon-wrap {
    width: 88px; height: 88px;
    border-radius: 28px;
    background: linear-gradient(145deg, rgba(124,58,237,0.18), rgba(59,130,246,0.1));
    border: 1px solid rgba(124,58,237,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
    animation: lockPop 0.55s var(--spring);
    box-shadow:
        0 0 0 8px rgba(124,58,237,0.05),
        0 16px 40px rgba(0,0,0,0.35);
    position: relative;
    overflow: hidden;
}
.lock-icon-wrap::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 50%;
    background: linear-gradient(180deg, rgba(255,255,255,0.08), transparent);
    border-radius: 28px 28px 0 0;
}
@keyframes lockPop {
    0% { transform: scale(0) rotate(-10deg); opacity: 0; }
    60% { transform: scale(1.08) rotate(2deg); }
    100% { transform: scale(1) rotate(0); opacity: 1; }
}
.lock-svg {
    width: 38px; height: 38px;
    color: #c4b5fd;
    position: relative; z-index: 1;
}

.lock-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.025em;
    line-height: 1.2;
}
.lock-desc {
    font-size: 0.84rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 260px;
    font-weight: 400;
}

.unlock-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(255,255,255,0.97);
    color: #09090f;
    font-family: 'Inter', sans-serif;
    font-size: 0.97rem;
    font-weight: 650;
    border: none;
    border-radius: 16px;
    padding: 16px 24px;
    cursor: pointer;
    transition: background 0.2s, transform 0.35s var(--spring), box-shadow 0.25s;
    letter-spacing: -0.01em;
    margin-top: 8px;
    box-shadow:
        0 1px 0 rgba(255,255,255,1) inset,
        0 12px 28px rgba(0,0,0,0.35);
}
.unlock-btn svg { width: 16px; height: 16px; }
.unlock-btn:hover {
    background: #f0efff;
    transform: translateY(-2px);
    box-shadow: 0 1px 0 rgba(255,255,255,1) inset, 0 20px 40px rgba(0,0,0,0.45);
}
.unlock-btn:active { transform: scale(0.97); transition-duration: 0.1s; }

.cancel-btn {
    background: none;
    border: none;
    color: var(--text-tertiary);
    font-size: 0.84rem;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    padding: 6px 12px;
    transition: color 0.2s;
    font-weight: 400;
    letter-spacing: 0.01em;
    margin-top: 2px;
}
.cancel-btn:hover { color: var(--text-secondary); }

/* ─── DESKTOP ─────────────────────────────────── */
@media (min-width: 640px) {
    .card {
        max-width: 420px;
        background: rgba(10, 10, 15, 0.4);
        border: 1px solid var(--glass-border);
        border-radius: 32px;
        padding: 48px 36px 40px;
        backdrop-filter: blur(40px) saturate(150%);
        -webkit-backdrop-filter: blur(40px) saturate(150%);
        box-shadow:
            0 1px 0 rgba(255,255,255,0.1) inset,
            0 0 0 0.5px rgba(255,255,255,0.06),
            0 40px 100px rgba(0,0,0,0.55),
            0 80px 160px rgba(0,0,0,0.3);
        position: relative;
        overflow: hidden;
    }
    .card::before {
        content: '';
        position: absolute;
        top: 0; left: 0; right: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    }

    .verify-overlay {
        align-items: center;
        padding-bottom: 0;
    }
    .verify-modal {
        border-radius: 28px;
        border: 1px solid rgba(255,255,255,0.1);
        padding: 16px 32px 36px;
        max-width: 400px;
    }
    .verify-modal::before {
        margin-bottom: 32px;
    }
}
