@font-face {
    font-family: 'VCRFont';
    src: url('/fonts/vcr.ttf') format('truetype');
}

/* =========================
   MAIN PAGE SETTINGS
========================= */

body {
    background-color: #1a1a1a;
    color: #ffffff;
    margin: 0;
    padding: 20px;
    font-family: 'VCRFont', sans-serif;
    min-height: 100vh;
    position: relative;
    z-index: 0;
}


/* =========================
   BACKGROUND SYSTEM
========================= */

body::before {
    content: "";
    position: fixed;
    inset: 0;

    background-color: #1a1a1a;
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;

    opacity: 0.25;
    pointer-events: none;
    z-index: -1;
}


/* HOME BACKGROUND */
body.home::before {
    background-image: url("https://i.pinimg.com/1200x/e9/d9/26/e9d92621a0be522ea812b5240c8ab1df.jpg");
}


/* BLOG BACKGROUND */
body.blog::before {
    background-image: url("https://i.pinimg.com/736x/1c/51/57/1c5157086e327637af93a3cfe161178f.jpg");
}


/* HATE BACKGROUND */
body.hate::before {
    background-image: url("https://i.pinimg.com/736x/5a/10/8e/5a108e8da24faf74330fc778e385a4e4.jpg");
}


/* =========================
   VHS OVERLAY SYSTEM
========================= */

#overlay-noise,
#overlay-scanlines,
#overlay-vhs {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;

    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}


/* STATIC / FILM GRAIN */

#overlay-noise {
    z-index: 9999;

    background-image: url("https://i.pinimg.com/736x/c4/6c/23/c46c235823ef136afbb348c87af66654.jpg");

    opacity: 0.10;
    mix-blend-mode: screen;
}


/* CRT SCANLINES */

#overlay-scanlines {
    z-index: 9998;

    background-image: url("https://i.pinimg.com/736x/08/a6/de/08a6de86ec97b43961fc1a192b400e5c.jpg");

    opacity: 0.10;
    mix-blend-mode: multiply;
}


/* VHS TAPE DISTORTION */

#overlay-vhs {
    z-index: 9997;

    background-image: url("https://i.pinimg.com/originals/e5/57/b4/e557b46e7d5f64872f6e5ca0b9744d6c.gif");

    opacity: 0.18;
    mix-blend-mode: overlay;
}


/* =========================
   CRT FLICKER
========================= */

body {
    animation: vhs-flicker 0.18s infinite alternate;
}


@keyframes vhs-flicker {
    from {
        filter: brightness(1);
    }

    to {
        filter: brightness(0.97);
    }
}


/* =========================
   COLOR SHIFT EFFECT
========================= */

body::after {
    content: "";

    position: fixed;
    inset: 0;

    pointer-events: none;
    z-index: 9996;

    background: linear-gradient(
        90deg,
        rgba(255,0,0,0.015),
        transparent,
        rgba(0,0,255,0.015)
    );

    mix-blend-mode: screen;
}
/* =========================
   FNAF STYLE CAMERA DRIFT
   Lightweight version
========================= */

/* Move the background like a security camera slowly panning */
body::before {
    animation: camera-drift 18s ease-in-out infinite alternate;
    transform: scale(1.05);
    will-change: transform;
}


@keyframes camera-drift {

    0% {
        transform: scale(1.05) translateX(-25px);
    }

    100% {
        transform: scale(1.05) translateX(25px);
    }

}


/* Slight VHS tape movement */
#overlay-vhs {
    animation: vhs-wobble 8s ease-in-out infinite alternate;
    will-change: transform;
}


@keyframes vhs-wobble {

    0% {
        transform: translateX(-8px);
    }

    100% {
        transform: translateX(8px);
    }

}