:root {
    --bg-top: #09090b;
    --bg-mid: #000000;
    --bg-bottom: #18181b;
    --text: #ffffff;
    --text-muted: #d4d4d8;
    --text-soft: #a1a1aa;
    --text-footer: #71717a;
    --border: rgba(255, 255, 255, 0.1);
    --border-hover: rgba(255, 255, 255, 0.2);
    --card: rgba(255, 255, 255, 0.1);
    --card-hover: rgba(255, 255, 255, 0.18);
    --shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: linear-gradient(to bottom, var(--bg-top), var(--bg-mid), var(--bg-bottom));
    color-scheme: dark;
}

body {
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.1;
    background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.9) 1px, transparent 0);
    background-size: 22px 22px;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.02), transparent);
}

.page {
    position: relative;
    z-index: 1;
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 48px 24px;
}

.container {
    width: 100%;
    max-width: 500px;
}

.profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.avatar {
    width: 112px;
    height: 112px;
    border-radius: 999px;
    object-fit: cover;
    border: 4px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow);
}

.name {
    margin: 20px 0 0;
    font-size: clamp(2rem, 4vw, 2.4rem);
    line-height: 1.1;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.bio {
    margin: 12px 0 0;
    max-width: 520px;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.links {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.link-card {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
    border-radius: 24px;
    border: 1px solid var(--border);
    background: var(--card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.link-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-hover);
    background: var(--card-hover);
}

.card-badge {
    position: absolute;
    top: -16px;
    left: 16px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
    background: #ffffff;
    color: #000000;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    z-index: 2;
}

.badge-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.badge-icon svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
}

.link-left {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 16px;
}

.icon-box {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.1);
    transition: background 0.2s ease;
}

.link-card:hover .icon-box,
.link-card:hover .link-badge {
    background: rgba(255, 255, 255, 0.2);
}

.icon-box svg {
    width: 20px;
    height: 20px;
    display: block;
}

.link-text {
    min-width: 0;
}

.link-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.link-description {
    margin: 6px 0 0;
    font-size: 0.8rem;
    color: var(--text-soft);
}

.link-badge {
    flex-shrink: 0;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: background 0.2s ease, color 0.2s ease;
}

.link-card:hover .link-badge {
    color: var(--text);
}

.footer {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    text-align: center;
    font-size: 0.78rem;
    color: var(--text-footer);
}

.cta {
    position: absolute;
    padding: 10px 20px;
    text-decoration: none;
    color: var(--text);
    border: 1px solid var(--border);
    background: var(--card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.cta:hover {
    background: var(--card-hover);
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

/* 404 */
.not-found-page {
    height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    overflow: hidden;
}

.not-found-page::before {
    opacity: 0.08;
}

.card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 560px;
    text-align: center;
    padding: 40px 28px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: var(--shadow);
}

.code {
    margin: 0;
    font-size: clamp(4rem, 14vw, 7rem);
    line-height: 1;
    font-weight: 800;
    letter-spacing: -0.06em;
}

.title {
    margin: 16px 0 0;
    font-size: clamp(1.4rem, 4vw, 2rem);
    font-weight: 700;
    letter-spacing: -0.03em;
}

.text {
    margin: 14px auto 0;
    max-width: 420px;
    color: var(--text-soft);
    line-height: 1.6;
    font-size: 0.98rem;
}

.actions {
    margin-top: 28px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 150px;
    padding: 14px 18px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    transition: 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-primary {
    background: rgba(255, 255, 255, 0.12);
    color: white;
}

.btn-primary:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: var(--text-soft);
}

.btn-secondary:hover {
    background: var(--card-hover);
    color: white;
    transform: translateY(-2px);
}

.footer-404 {
    margin-top: 22px;
    padding-top: 0;
    border-top: none;
    font-size: 0.82rem;
}

@media (max-width: 640px) {
    .page {
        padding: 32px 16px;
    }

    .link-card {
        padding: 16px;
        border-radius: 20px;
    }

    .link-description {
        font-size: 0.88rem;
    }

    .link-badge {
        display: none;
    }
}