:root {
    --bg: #02060a;
    --ink: #d8f4ff;
    --muted: #5a8aa8;
    --accent: #22d3ee;
}

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

body {
    margin: 0;
    min-height: 100dvh;
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 300;
    font-size: 0.85rem;
    background: var(--bg);
    color: var(--ink);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.grain {
    position: fixed;
    inset: 0;
    opacity: 0.04;
    pointer-events: none;
    z-index: 1;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.stage {
    position: relative;
    z-index: 4;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
}

.welcome {
    font-family: 'JetBrains Mono', monospace;
    font-size: clamp(1.2rem, 4vw, 1.5rem);
    font-weight: 500;
    letter-spacing: 0.15em;
    color: var(--accent);
    text-align: center;
    position: absolute;
    line-height: 1.2;
    text-shadow: 0 0 20px rgba(34, 211, 238, 0.3);
}

.welcome.out {
    opacity: 0;
    letter-spacing: 0.5em;
    filter: blur(10px);
    transition: all 0.6s ease;
}

.narrative {
    max-width: 32rem;
    width: 100%;
    text-align: center;
    opacity: 0;
    visibility: hidden;
}

.narrative.on {
    opacity: 1;
    visibility: visible;
    transition: opacity 1s ease;
}

.copy-block {
    margin-bottom: 1.5rem;
    min-height: 4.5em;
}

.rest-block {
    color: var(--muted);
    line-height: 1.7;
    letter-spacing: 0.02em;
    white-space: pre-line;
}

.site-line {
    margin-top: 1.2rem;
    font-size: 0.8rem;
    color: var(--ink);
    opacity: 0.8;
}

.github-line {
    margin-top: 0.9rem;
    font-size: 0.82rem;
}

.github-line a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(34, 211, 238, 0.3);
    transition: all 0.2s ease;
}

.github-line a:hover {
    color: var(--ink);
    border-bottom-color: var(--ink);
    text-shadow: 0 0 10px var(--accent);
}

.site-line a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(34, 211, 238, 0.3);
    transition: all 0.2s ease;
}

.site-line a:hover {
    color: var(--ink);
    border-bottom-color: var(--ink);
    text-shadow: 0 0 10px var(--accent);
}

.cursor {
    display: inline-block;
    width: 6px;
    height: 1em;
    background: var(--accent);
    margin-left: 4px;
    vertical-align: -0.15em;
    animation: bl 1s step-end infinite;
}

@keyframes bl {

    0%,
    50% {
        opacity: 1
    }

    51%,
    100% {
        opacity: 0
    }
}

.rule {
    width: 2rem;
    height: 1px;
    margin: 2.5rem auto 1.5rem;
    background: var(--muted);
    opacity: 0.3;
}

.sig {
    font-size: 0.9rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--ink);
    opacity: 0.6;
}
