@font-face {
    font-family: 'GreenEnergy';
    src: url('../assets/GreenEnergy.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

:root {
    --text-shadow: 0 0 12px rgba(255, 255, 255, 1), 0 0 24px rgba(255, 255, 255, .8), 0 0 36px rgba(255, 255, 255, .6);
    --white: #fff;
    --pad: clamp(12px, 2vw, 24px);
}

* {
    box-sizing: border-box;
}

*,
*::before,
*::after {
    cursor: none !important;
}

html, body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    color: var(--white);
    font-family: 'GreenEnergy', Arial, sans-serif;
    cursor: none;
    background: #000;
}

/* BG */
.bg {
    position: fixed;
    inset: 0;
    z-index: -3;
}

.bg video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.backdrop {
    position: fixed;
    inset: 0;
    z-index: -2;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, .15) 0%, rgba(0, 0, 0, .55) 65%, rgba(0, 0, 0, .9));
    pointer-events: none;
}

/* PRELOADER */
.preloader {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: grid;
    place-items: center;
    background: rgba(0, 0, 0, .85);
    transition: opacity .4s ease;
}

.preloader img {
    max-width: min(55vw, 420px);
    height: auto;
}

.preloader.hidden {
    opacity: 0;
    pointer-events: none;
}

/* CRT EFFECT */
.crt-overlay {
    position: fixed;
    inset: 0;
    z-index: 4000;
    pointer-events: none;
    background: radial-gradient(circle at center, rgba(255, 255, 255, .08), rgba(0, 0, 0, 0.3));
    mix-blend-mode: overlay;
    backdrop-filter: contrast(1.05) saturate(1.1); /* Removed blur */
    animation: crt-glitch 1s infinite linear alternate, crt-scanlines 0.05s infinite;
}

@keyframes crt-scanlines {
    0% {
        background-image: linear-gradient(rgba(255, 0, 0, 0.2) 1px, transparent 1px);
    }
    50% {
        background-image: linear-gradient(rgba(0, 255, 0, 0.2) 1px, transparent 1px);
    }
    100% {
        background-image: linear-gradient(rgba(0, 0, 255, 0.2) 1px, transparent 1px);
    }
}

.fisheye {
    position: fixed;
    inset: 0;
    z-index: 3999;
    pointer-events: none;
    backdrop-filter: contrast(1.05); /* Removed blur */
    transform: scale(1.02);
    border-radius: 50% / 45%;
    overflow: hidden;
}

/* LAYOUT */
.stage {
    position: relative;
    min-height: 100vh;
    padding: var(--pad);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(16px, 3vh, 32px);
}

.logo img, .nav, .tshirt-row, .policy {
    opacity: 0;
    transition: opacity .5s ease;
}

body.reveal .logo img, body.reveal .nav, body.reveal .tshirt-row, body.reveal .policy {
    opacity: 1;
}

.logo img {
    max-width: clamp(200px, 30vw, 420px);
    filter: drop-shadow(0 0 24px rgba(255, 255, 255, 1)) brightness(1.2);
}

/* NAV */
.nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: clamp(-6px, -1.8vh, -14px);
}

.nav a {
    font-size: clamp(22px, 3vw, 44px);
    text-decoration: none;
    color: var(--white);
    opacity: .92;
    text-shadow: var(--text-shadow);
    position: relative;
    display: inline-block;
    transition: transform .35s ease, color .35s ease, opacity .35s ease;
    animation: shake 2s infinite;
}

/*.nav a::before {*/
/*    content: "";*/
/*    position: absolute;*/
/*    top: 50%;*/
/*    left: 50%;*/
/*    transform: translate(-50%, -50%);*/
/*    width: 0;*/
/*    height: 1.25em;*/
/*    background: var(--white);*/
/*    z-index: -1;*/
/*    transition: width .4s ease;*/
/*}*/

.nav a:hover::before {
    width: 96vw;
}

.nav a:hover {
    color: #000;
    opacity: 1;
    transform: scale(1.18);
}

/* PRODUCTS ROW */
.tshirt-row {
    display: flex;
    justify-content: center;
    flex-wrap: nowrap;
    gap: clamp(5px, 1vw, 15px);
}

.tshirt {
    flex: 1 1 clamp(300px, 35vw, 500px);
    max-width: clamp(300px, 35vw, 500px);
    text-align: center;
}

.tshirt img {
    width: 100%;
    height: auto;
    object-fit: contain;
    transition: filter .3s ease;
    display: block;
    margin: 0 auto;
}

.tshirt:hover img {
    filter: invert(1);
}

/* POLICY */
.policy {
    font-size: clamp(22px, 3vw, 44px);
    animation: shake 3s infinite;
    text-align: center;
}

.policy a {
    color: var(--white);
    text-decoration: none;
    position: relative;
    display: inline-block;
    transition: transform .35s ease, color .35s ease, opacity .35s ease;
    opacity: .92;
    text-shadow: var(--text-shadow);
}

.policy a::before, .nav a::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 1.25em;
    background: var(--white);
    z-index: -1;
    transition: width .4s ease;
}

.policy a:hover::before {
    width: 96vw;
}

.policy a:hover {
    color: #000;
    opacity: 1;
}

/* Shake Effect */
@keyframes shake {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    20% {
        transform: translate(-1px, 1px) rotate(-0.5deg);
    }
    40% {
        transform: translate(-1px, -1px) rotate(0.5deg);
    }
    60% {
        transform: translate(1px, 1px) rotate(-0.5deg);
    }
    80% {
        transform: translate(1px, -1px) rotate(0.5deg);
    }
    100% {
        transform: translate(0, 0) rotate(0deg);
    }
}

/* CART Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -480px;
    width: min(92vw, 480px);
    height: 100%;
    background: rgba(0, 0, 0, .95);
    color: #fff;
    z-index: 2500;
    padding: 16px;
    box-shadow: -2px 0 18px rgba(0, 0, 0, .7);
    transition: right .4s ease;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cart-sidebar.open {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 2rem;
    color: var(--white);
    margin: 0 10px 0 10px;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.cart-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px;
    border-bottom: 1px solid #333;
    font-size: clamp(10px, 2vw, 20px);
}

.cart-item img {
    width: 120px;
    height: 120px;
    object-fit: cover;
}

.cart-item-details {
}

.cart-item-details p {
}

.cart-item-remove {
    font-family: 'GreenEnergy', Arial, sans-serif;
    font-size: clamp(14px, 2vw, 28px);
    background: none;
    border: none;
    color: #ef4444;
}

.cart-item-remove:hover {
    color: #dc2626;
}

.cart-footer {
    border-top: 1px solid #333;
    padding-top: 10px;
    display: grid;
    gap: 10px;
    font-size: clamp(14px, 2vw, 28px);
}

.cart-total {
    text-align: left;
    margin: 0;
}

.cart-footer button {
    font-family: 'GreenEnergy', Arial, sans-serif;
    font-size: clamp(14px, 2vw, 28px);
    padding: 5px;
    background: #111;
    border: 1px solid #444;
    color: #fff;
}

.cart-footer button:hover {
    background: #444;
}

/* CROSSHAIR */
.crosshair {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 5000;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.crosshair.shown {
    opacity: 1;
}

.crosshair-line {
    position: absolute;
    background: var(--white);
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.8);
}

.crosshair-horizontal-top, .crosshair-horizontal-bottom {
    width: 100%;
    height: 2px;
}

.crosshair-vertical-left, .crosshair-vertical-right {
    height: 100%;
    width: 2px;
}

/* TV overlay (off on mobile) */
.tv-overlay {
    position: fixed;
    inset: 0;
    z-index: 998;
    pointer-events: none;
    background: url('../assets/tv.png') no-repeat center;
    background-size: contain;
}

#cartClose {
    font-family: 'GreenEnergy', serif;
    font-weight: normal;
    font-style: normal;
    background-color: black;
    color: var(--white);
    border: none;
    font-size: 28px;
}

@media (max-width: 768px) {
    .nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1rem;
    }

    .tshirt-row {
        flex-direction: column;
        align-items: center;
    }

    .tv-overlay {
        display: none;
    }

    .crosshair {
        display: none;
    }

    .crosshair.shown {
        display: none;
    }

    .cart-sidebar {
        width: 100%;
    }

    #cartClose {
        font-size: 56px;
    }
}

