:root {
    --void: #08080a;
    --concrete: #131316;
    --steel: #3a3d42;
    --trace-white: #e7e5df;
    --static: #6a6d72;
    --signal-red: #c81e3a;
}

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

html, body {
    height: 100%;
    background: var(--void);
    color: var(--trace-white);
    font-family: 'JetBrains Mono', ui-monospace, 'Courier New', monospace;
    overflow: hidden;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    isolation: isolate;
    min-height: 100dvh;
    padding: 2rem 0;
}

/* subtle static grain */
.grain {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.05;
    background-image: repeating-conic-gradient(#fff 0% 0.0001%, transparent 0% 0.0002%);
    background-size: 3px 3px;
    animation: grain-shift 1s steps(2) infinite;
}

@keyframes grain-shift {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(-1px, 1px);
    }
}

/* scanlines */
.scanlines {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background: repeating-linear-gradient(
            to bottom,
            rgba(0, 0, 0, 0.0) 0px,
            rgba(0, 0, 0, 0.18) 1px,
            transparent 2px,
            transparent 3px
    );
    animation: scanline-glitch 3.5s infinite steps(1);
}

@keyframes scanline-glitch {
    0%, 80%, 100% { transform: translate(0, 0); opacity: 1; background-color: transparent; }
    81% { transform: translate(0, -4px); opacity: 0.6; background-color: rgba(200, 30, 58, 0.12); }
    82% { transform: translate(0,  3px); opacity: 1;   background-color: rgba(200, 30, 58, 0.07); }
    83% { transform: translate(0, -2px); opacity: 0.8; background-color: rgba(200, 30, 58, 0.15); }
    84% { transform: translate(0,  0);   opacity: 1;   background-color: transparent; }
    90% { transform: translate(0,  5px); opacity: 0.5; background-color: rgba(200, 30, 58, 0.1); }
    91% { transform: translate(0,  0);   opacity: 1;   background-color: transparent; }
}

.vignette {
    position: fixed;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.65) 100%);
}

/* corner readouts */
.corner {
    position: fixed;
    z-index: 3;
    font-size: 0.62rem;
    letter-spacing: 0.12em;
    color: var(--static);
    line-height: 1.6;
}


.corner.tl {
    top: 22px;
    left: 24px;
}

.corner.tr {
    top: 22px;
    right: 24px;
    text-align: right;
}

.corner a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.corner a:hover {
    color: var(--signal-red);
}

.corner .dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--signal-red);
    margin-right: 6px;
    box-shadow: 0 0 6px var(--signal-red);
    -webkit-animation: blink-dot 1.6s ease-in-out infinite;
    animation: blink-dot 1.6s ease-in-out infinite;
}

@-webkit-keyframes blink-dot {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.15;
    }
}

@keyframes blink-dot {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.15;
    }
}

/* hero image */
.hero-image {
    width: 100vw;
    max-width: 100vw;
    position: relative;
    animation: hero-in 1.4s ease-out both, hero-glitch 4s 1.4s infinite steps(1);
}

.hero-image img {
    display: block;
    width: 100%;
    min-height: 100vh;
    object-fit: cover;
    transform: translateY(-20%);
    filter: grayscale(0.15) contrast(1.05);
    -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
}

@keyframes hero-glitch {
    0%, 75%, 100% { transform: translate(0, 0); filter: none; }
    76% { transform: translate(-3px,  1px); filter: brightness(1.15) contrast(1.1) hue-rotate(8deg) blur(4px); }
    77% { transform: translate( 2px, -1px); filter: brightness(0.9)  saturate(1.4) hue-rotate(-5deg) blur(2px); }
    78% { transform: translate(-1px,  1px); filter: brightness(1.2)  contrast(1.2) blur(5px); }
    79% { transform: translate( 0,    0);   filter: none; }
    88% { transform: translate( 2px,  0);   filter: brightness(1.1) hue-rotate(6deg) blur(3px); }
    89% { transform: translate(-2px,  1px); filter: brightness(0.95) saturate(1.3) blur(2px); }
    90% { transform: translate( 0,    0);   filter: none; }
}

@keyframes hero-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


.bottom-overlay {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1;
    pointer-events: none;
    text-align: center;
    margin-bottom: 1rem;
}

/* wordmark */
.wordmark-wrap {
    position: relative;
    display: inline-block;
}

.wordmark-logo {
    display: block;
    width: clamp(220px, 40vw, 400px);
    height: auto;
    position: relative;
    z-index: 1;
}

/* glitch layers */
.glitch-wrap {
    position: absolute;
    inset: 0;
    pointer-events: none;
    filter: blur(1px);
}

.glitch-layer {
    position: absolute;
    inset: 0;
    background-color: var(--signal-red);
    -webkit-mask: url('../img/logo.svg') no-repeat center / 100% auto;
    mask: url('../img/logo.svg') no-repeat center / 100% auto;
    opacity: 0;
}

.gl-a {
    animation: glitch-1 4s infinite steps(1);
}

.gl-b {
    background-color: #e03050;
    animation: glitch-2 4s infinite steps(1);
}

@keyframes glitch-1 {
    0%, 80%, 100% {
        opacity: 0;
        transform: translate(0, 0);
        clip-path: inset(0 0 0 0);
    }
    81% {
        opacity: 1;
        transform: translate(-14px, 2px);
        clip-path: inset(5% 0 70% 0);
    }
    82% {
        opacity: 1;
        transform: translate(12px, -3px);
        clip-path: inset(60% 0 8% 0);
    }
    83% {
        opacity: 0.9;
        transform: translate(-10px, 1px);
        clip-path: inset(30% 0 35% 0);
    }
    84% {
        opacity: 1;
        transform: translate(14px, 0px);
        clip-path: inset(15% 0 55% 0);
    }
    85% {
        opacity: 0;
    }
    90% {
        opacity: 0.8;
        transform: translate(-8px, 3px);
        clip-path: inset(45% 0 20% 0);
    }
    91% {
        opacity: 0;
    }
}

@keyframes glitch-2 {
    0%, 78%, 100% {
        opacity: 0;
        transform: translate(0, 0);
        clip-path: inset(0 0 0 0);
    }
    79% {
        opacity: 1;
        transform: translate(13px, 0px);
        clip-path: inset(20% 0 50% 0);
    }
    80% {
        opacity: 0.9;
        transform: translate(-12px, 3px);
        clip-path: inset(65% 0 5% 0);
    }
    81% {
        opacity: 1;
        transform: translate(10px, -2px);
        clip-path: inset(10% 0 65% 0);
    }
    82% {
        opacity: 0;
    }
    88% {
        opacity: 0.85;
        transform: translate(-14px, 2px);
        clip-path: inset(40% 0 25% 0);
    }
    89% {
        opacity: 0.85;
        transform: translate(9px, -3px);
        clip-path: inset(75% 0 3% 0);
    }
    90% {
        opacity: 0;
    }
}

/* bandcamp player */
.bandcamp-player{
    display: block;
    border: 0;
    width: clamp(280px, 60vw, 500px);
    height: 42px;
    margin: 0 auto;
    pointer-events: all;
}

/* countdown */
.countdown{
    display: flex;
    align-items: center;
    gap: 0.2rem;
    justify-content: center;
    margin: 1rem 0;
}
.countdown-unit{
    display: flex;
    flex-direction: column;
    align-items: center;
}
.countdown-num{
    font-size: clamp(1.6rem, 4vw, 2.6rem);
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--trace-white);
    line-height: 1;
}
.countdown-label{
    font-size: 0.52rem;
    letter-spacing: 0.2em;
    color: var(--static);
    margin-top: 0.25rem;
}
.countdown-sep{
    font-size: clamp(1.4rem, 3.5vw, 2.2rem);
    color: var(--signal-red);
    line-height: 1;
    margin-bottom: 1.1rem;
}

/* status readout */
.status {
    font-size: clamp(0.78rem, 1.6vw, 0.95rem);
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--trace-white);
    margin-bottom: 1rem;
    margin-top: 1rem;
}

.status .cursor {
    display: inline-block;
    width: 0.55em;
    height: 1em;
    background: var(--signal-red);
    margin-left: 0.35em;
    vertical-align: -0.15em;
    animation: cursor-blink 1s steps(1) infinite;
}

@keyframes cursor-blink {
    0%, 49% {
        opacity: 1;
    }
    50%, 100% {
        opacity: 0;
    }
}

/* tags */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: center;
}

.tag {
    font-size: 0.66rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--static);
    padding: 0.4rem 0.75rem;
}

.tag em {
    font-style: normal;
    color: var(--signal-red);
    margin-right: 0.4em;
}

@media (max-width: 480px) {
    .corner {
        font-size: 0.56rem;
    }

    .corner.tl {
        top: 16px;
        left: 16px;
    }

    .corner.tr {
        top: 16px;
        right: 16px;
    }
}