:root {
    color-scheme: dark;
    --background: #050505;
    --surface: rgba(12, 12, 12, 0.9);
    --surface-raised: rgba(22, 22, 22, 0.94);
    --border: rgba(255, 255, 255, 0.16);
    --border-strong: rgba(255, 255, 255, 0.3);
    --text: #ffffff;
    --muted: #b5b5b5;
    --red: #ed1b2f;
    --red-bright: #ff3044;
    --red-dark: #980f1d;
    --green: #3be09a;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--background);
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    color: var(--text);
    background: var(--background);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    color: inherit;
    font: inherit;
}

.material-symbols-outlined {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-variation-settings: "FILL" 0, "wght" 550, "GRAD" 0, "opsz" 24;
    line-height: 1;
}

.visual-backdrop {
    position: fixed;
    z-index: 0;
    inset: 0;
    height: 100svh;
    overflow: hidden;
    pointer-events: none;
    animation: backdrop-arrive 900ms both ease-out;
}

.visual-backdrop picture,
.visual-backdrop img {
    display: block;
    width: 100%;
    height: 100%;
}

.visual-backdrop img {
    object-fit: cover;
    object-position: center;
    filter: saturate(0.92) contrast(1.06);
}

.visual-backdrop::before,
.visual-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
}

.visual-backdrop::before {
    background: rgba(0, 0, 0, 0.36);
}

.visual-backdrop::after {
    background: linear-gradient(180deg, rgba(5, 5, 5, 0.04) 0%, rgba(5, 5, 5, 0.52) 56%, #050505 100%);
}

.page-shell {
    position: relative;
    z-index: 1;
    width: min(100%, 760px);
    margin: 0 auto;
    padding: 42px 20px 48px;
}

.profile-header {
    position: relative;
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 32px 64px 40px;
    text-align: center;
    animation: identity-arrive 680ms 80ms both cubic-bezier(0.22, 1, 0.36, 1);
}

.profile-header::after {
    content: "";
    width: 54px;
    height: 3px;
    margin-top: 26px;
    background: var(--red);
}

.brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 58px;
}

.brand img {
    display: block;
    width: 252px;
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.55));
}

.icon-button {
    position: absolute;
    top: 0;
    right: 0;
    width: 46px;
    height: 46px;
    display: inline-grid;
    place-items: center;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 50%;
    color: #fff;
    background: rgba(8, 8, 8, 0.76);
    backdrop-filter: blur(14px);
    cursor: pointer;
    transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.icon-button:hover,
.icon-button:focus-visible {
    color: #fff;
    border-color: var(--red);
    background: var(--red);
    transform: translateY(-2px);
}

.profile-copy {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 14px;
}

.profile-copy p {
    margin: 0;
}

.handle {
    color: var(--text);
    font-size: 0.98rem;
    font-weight: 800;
}

.descriptor {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
}

.status-dot {
    width: 7px;
    height: 7px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 4px rgba(59, 224, 154, 0.12);
}

.link-section {
    padding-top: 2px;
}

.featured-link {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid var(--border-strong);
    border-radius: 8px;
    background: #111;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
    animation: link-arrive 620ms both cubic-bezier(0.22, 1, 0.36, 1);
    animation-delay: calc(160ms + (var(--link-index) * 55ms));
    transition: border-color 200ms ease, box-shadow 200ms ease, transform 200ms ease;
}

.featured-link::after {
    content: "";
    position: absolute;
    z-index: 1;
    inset: 32% 0 0;
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.94));
    pointer-events: none;
}

.featured-link:hover,
.featured-link:focus-visible {
    border-color: var(--red-bright);
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.58), 0 0 0 1px rgba(237, 27, 47, 0.34);
    transform: translateY(-4px);
}

.featured-image {
    position: absolute;
    inset: 0;
    display: block;
    overflow: hidden;
    background: #161616;
}

.featured-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 500ms cubic-bezier(0.22, 1, 0.36, 1);
}

.featured-link:hover .featured-image img,
.featured-link:focus-visible .featured-image img {
    transform: scale(1.025);
}

.featured-placeholder {
    display: grid;
    place-items: center;
    background: #211014;
}

.featured-placeholder > .material-symbols-outlined {
    color: var(--red);
    font-size: 72px;
}

.feature-label {
    position: absolute;
    z-index: 3;
    top: 16px;
    left: 16px;
    padding: 7px 10px;
    border-radius: 4px;
    color: #fff;
    background: var(--red);
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
}

.featured-content {
    position: absolute;
    z-index: 2;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    padding: 74px 22px 20px;
}

.featured-content > span:first-child {
    min-width: 0;
}

.featured-content strong,
.featured-content small {
    display: block;
}

.featured-content strong {
    font-family: Outfit, Inter, sans-serif;
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.16;
}

.featured-content small {
    margin-top: 6px;
    color: #d0d0d0;
    font-size: 0.88rem;
    line-height: 1.4;
}

.link-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.link-row {
    position: relative;
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr) 40px;
    min-height: 92px;
    align-items: center;
    gap: 16px;
    overflow: hidden;
    padding: 10px 14px 10px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    backdrop-filter: blur(15px);
    animation: link-arrive 620ms both cubic-bezier(0.22, 1, 0.36, 1);
    animation-delay: calc(160ms + (var(--link-index) * 55ms));
    transition: background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.link-row::before {
    content: "";
    position: absolute;
    top: 12px;
    bottom: 12px;
    left: 0;
    width: 3px;
    background: var(--red);
    transform: scaleY(0);
    transition: transform 180ms ease;
}

.link-row:hover,
.link-row:focus-visible {
    border-color: rgba(237, 27, 47, 0.72);
    background: var(--surface-raised);
    box-shadow: 0 16px 38px rgba(0, 0, 0, 0.34);
    transform: translateY(-3px);
}

.link-row:hover::before,
.link-row:focus-visible::before {
    transform: scaleY(1);
}

.link-thumbnail,
.link-icon {
    display: flex;
    width: 70px;
    height: 70px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 6px;
    background: #202020;
}

.link-thumbnail {
    object-fit: cover;
}

.link-icon .material-symbols-outlined {
    color: #fff;
    font-size: 30px;
}

.link-icon-red {
    background: linear-gradient(145deg, var(--red), var(--red-dark));
}

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

.link-copy strong,
.link-copy small {
    display: block;
}

.link-copy strong {
    overflow-wrap: anywhere;
    font-family: Outfit, Inter, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.25;
}

.link-copy small {
    margin-top: 5px;
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.35;
}

.action-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    display: inline-grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 50%;
    color: #d8d8d8;
    background: rgba(0, 0, 0, 0.3);
    font-size: 21px;
    transition: color 160ms ease, background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.tracked-link:hover .action-icon,
.tracked-link:focus-visible .action-icon {
    color: #fff;
    border-color: var(--red);
    background: var(--red);
    transform: translate(2px, -2px);
}

.featured-content .action-icon {
    border-color: rgba(255, 255, 255, 0.28);
    color: #fff;
    background: rgba(0, 0, 0, 0.5);
}

.page-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 34px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
}

.page-footer p {
    margin: 0;
    color: #858585;
    font-size: 0.74rem;
}

.empty-links {
    margin: 20px 0 10px;
    padding: 28px 20px;
    border: 1px dashed var(--border);
    border-radius: 8px;
    color: var(--muted);
    text-align: center;
}

.share-notice {
    position: fixed;
    z-index: 10;
    left: 50%;
    bottom: 22px;
    max-width: calc(100vw - 32px);
    padding: 11px 15px;
    border: 1px solid var(--border-strong);
    border-radius: 6px;
    color: var(--text);
    background: #171717;
    font-size: 0.84rem;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 12px);
    transition: opacity 160ms ease, transform 160ms ease;
}

.share-notice.is-visible {
    opacity: 1;
    transform: translate(-50%, 0);
}

:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 3px;
}

@keyframes backdrop-arrive {
    from { opacity: 0; transform: scale(1.025); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes identity-arrive {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes link-arrive {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 600px) {
    .visual-backdrop::before {
        background: rgba(0, 0, 0, 0.24);
    }

    .visual-backdrop::after {
        background: linear-gradient(180deg, rgba(5, 5, 5, 0.08) 0%, rgba(5, 5, 5, 0.5) 48%, #050505 100%);
    }

    .page-shell {
        padding: 24px 14px 36px;
    }

    .profile-header {
        min-height: 226px;
        padding: 26px 52px 32px;
    }

    .brand img {
        width: 214px;
    }

    .icon-button {
        width: 42px;
        height: 42px;
    }

    .profile-copy {
        flex-direction: column;
        gap: 5px;
        margin-top: 10px;
    }

    .profile-header::after {
        margin-top: 20px;
    }

    .featured-link {
        aspect-ratio: 4 / 3;
    }

    .featured-content {
        padding: 72px 16px 16px;
    }

    .featured-content strong {
        font-size: 1.22rem;
    }

    .featured-content small {
        font-size: 0.8rem;
    }

    .feature-label {
        top: 12px;
        left: 12px;
    }

    .link-list {
        gap: 10px;
        margin-top: 12px;
    }

    .link-row {
        grid-template-columns: 58px minmax(0, 1fr) 34px;
        min-height: 80px;
        gap: 12px;
        padding: 10px 11px 10px 10px;
    }

    .link-thumbnail,
    .link-icon {
        width: 58px;
        height: 58px;
    }

    .link-icon .material-symbols-outlined {
        font-size: 27px;
    }

    .link-copy strong {
        font-size: 0.92rem;
    }

    .link-copy small {
        font-size: 0.74rem;
    }

    .action-icon {
        width: 32px;
        height: 32px;
        font-size: 19px;
    }

    .page-footer {
        margin-top: 26px;
    }
}

@media (max-width: 350px) {
    .brand img {
        width: 188px;
    }

    .featured-content strong {
        font-size: 1.08rem;
    }

    .link-row {
        grid-template-columns: 54px minmax(0, 1fr) 30px;
        gap: 10px;
    }

    .link-thumbnail,
    .link-icon {
        width: 54px;
        height: 54px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}
