:root {
    --ice: #d8dedf;
    --ice-2: #aeb8be;
    --snow: #f7fbfb;
    --ink: #101516;
    --soft-ink: rgba(16, 21, 22, 0.74);
    --ghost: rgba(247, 251, 251, 0.72);
    --ghost-faint: rgba(247, 251, 251, 0.24);
    --line: rgba(247, 251, 251, 0.38);
    --line-dark: rgba(16, 21, 22, 0.16);
    --accent: #f2f7ff;
    --signal: #f0683f;
    --blueprint: #dcecff;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    min-height: 100vh;
    margin: 0;
    overflow: hidden;
    color: var(--snow);
    background:
        radial-gradient(circle at 50% 20%, rgba(255, 255, 255, 0.28), transparent 34%),
        linear-gradient(145deg, #eef3f3 0%, #aeb8be 52%, #7e8a92 100%);
    font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
    line-height: 1.35;
}

body::before,
body::after {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    content: "";
}

body::before {
    opacity: 0.34;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.2) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.2) 1px, transparent 1px),
        linear-gradient(120deg, transparent 0 48%, rgba(255, 255, 255, 0.28) 49% 50%, transparent 51% 100%);
    background-size: 72px 72px, 72px 72px, 180px 180px;
    mask-image: linear-gradient(to bottom, black, transparent 82%);
}

body::after {
    background:
        linear-gradient(to bottom, rgba(255, 255, 255, 0.2), transparent 25%, transparent 75%, rgba(16, 21, 22, 0.3)),
        radial-gradient(circle at 50% 50%, transparent 0 44%, rgba(14, 20, 22, 0.22) 100%);
}

.page-shell {
    position: relative;
    z-index: 3;
    min-height: 100vh;
    isolation: isolate;
}

#contentWrapper {
    position: relative;
    min-height: 100vh;
}

#modelContainer {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    background: var(--ice-2);
}

#modelContainer::before,
#modelContainer::after {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    content: "";
}

#modelContainer::before {
    background:
        linear-gradient(to right, rgba(255, 255, 255, 0.34), transparent 14%, transparent 86%, rgba(255, 255, 255, 0.22)),
        repeating-linear-gradient(to bottom, rgba(255, 255, 255, 0.12) 0 1px, transparent 1px 5px);
    mix-blend-mode: screen;
    opacity: 0.26;
}

#modelContainer::after {
    border: 1px solid rgba(255, 255, 255, 0.36);
    box-shadow: inset 0 0 100px rgba(255, 255, 255, 0.2);
}

#modelContainer iframe {
    display: block;
    width: 100%;
    height: 100vh;
    border: 0;
    background: var(--ice-2);
    filter: grayscale(0.78) contrast(1.08) brightness(1.08);
}

.top-nav {
    position: fixed;
    top: 22px;
    right: 24px;
    z-index: 8;
    display: flex;
    gap: 6px;
    padding: 5px;
    background: rgba(235, 241, 242, 0.2);
    border: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

.top-nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 13px;
    color: var(--ghost);
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    border: 1px solid transparent;
}

.top-nav a:hover,
.top-nav a:focus-visible {
    color: var(--snow);
    border-color: var(--line);
    outline: none;
}

.top-nav a.is-active {
    color: var(--ink);
    background: var(--snow);
}

.page-header {
    position: fixed;
    top: 24px;
    left: 26px;
    z-index: 6;
    width: min(58vw, 760px);
    color: var(--snow);
    text-shadow: 0 2px 18px rgba(18, 24, 26, 0.22);
}

.page-header p {
    margin: 0 0 10px;
    color: var(--ghost);
    font-size: clamp(0.72rem, 1.3vw, 0.92rem);
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.page-header p::before {
    content: "// ";
}

h1 {
    margin: 0;
    color: var(--snow);
    font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
    font-size: clamp(4.5rem, 11vw, 10.5rem);
    font-weight: 900;
    line-height: 0.78;
    letter-spacing: 0;
    text-transform: uppercase;
}

.page-header::after {
    display: block;
    width: min(400px, 44vw);
    margin-top: 16px;
    color: rgba(247, 251, 251, 0.7);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    content: "SPECIMEN // GLTF ATLAS // LIVE MODEL";
}

#key {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 7;
    width: min(330px, calc(100vw - 48px));
    max-height: min(62vh, 560px);
    overflow: auto;
    padding: 16px;
    color: var(--snow);
    background: rgba(20, 28, 30, 0.28);
    border: 1px solid var(--line);
    backdrop-filter: blur(22px);
    box-shadow: 0 24px 70px rgba(13, 18, 20, 0.2);
}

#key h2 {
    margin: 0 0 13px;
    color: var(--ghost);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

#key h2::before {
    content: "// ";
}

#key ol {
    display: grid;
    gap: 1px;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: key-counter;
}

#key ol li {
    display: grid;
    grid-template-columns: 34px 1fr;
    align-items: center;
    min-height: 36px;
    color: rgba(247, 251, 251, 0.86);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    border-top: 1px solid rgba(247, 251, 251, 0.16);
    counter-increment: key-counter;
}

#key ol li:last-child {
    border-bottom: 1px solid rgba(247, 251, 251, 0.16);
}

#key ol li::before {
    content: counter(key-counter, decimal-leading-zero);
    color: var(--blueprint);
    font-size: 0.72rem;
    font-weight: 900;
}

.scan-meta {
    position: fixed;
    left: 26px;
    bottom: 24px;
    z-index: 6;
    display: grid;
    gap: 5px;
    color: rgba(247, 251, 251, 0.74);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-shadow: 0 2px 14px rgba(18, 24, 26, 0.22);
}

.scan-meta span::before {
    color: var(--snow);
    content: "//// ";
}

@media (max-width: 820px) {
    .top-nav {
        top: 10px;
        right: 10px;
        left: 10px;
    }

    .top-nav a {
        flex: 1;
        min-width: 0;
        padding: 0 8px;
        font-size: 0.68rem;
    }

    .page-header {
        top: 70px;
        left: 14px;
        width: calc(100vw - 28px);
    }

    .page-header p {
        margin-bottom: 8px;
    }

    h1 {
        font-size: clamp(3.4rem, 19vw, 5rem);
    }

    .page-header::after {
        width: 78vw;
        margin-top: 12px;
        font-size: 0.64rem;
    }

    #key {
        right: 10px;
        bottom: 10px;
        left: 10px;
        width: auto;
        max-height: 33vh;
        padding: 13px;
    }

    #key ol li {
        grid-template-columns: 32px 1fr;
        min-height: 34px;
        font-size: 0.72rem;
    }

    .scan-meta {
        display: none;
    }
}

@media (max-width: 420px) {
    #modelContainer iframe {
        filter: grayscale(0.74) contrast(1.06) brightness(1.05);
    }

    h1 {
        font-size: 3.25rem;
    }
}
