:root {
    --primary: #ff0000;
    --primary-glow: rgba(255, 0, 0, 0.7);
    --secondary: #00ff00;
    --secondary-glow: rgba(0, 255, 0, 0.7);
    --accent: #ffff00;
    --accent-glow: rgba(255, 255, 0, 0.7);
    --background: #000000;
    --surface: #0a0a0a;
    --surface-alt: #151515;
    --text: #ffffff;
    --text-dim: #aaaaaa;
    --scanline-color: rgba(255, 255, 255, 0.2);
    --scanline-gap: 4px;
    --flicker-opacity: 0.3;
    --noise: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.6' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

@keyframes scanline {
    0% {
        transform: translateY(-100vh);
    }
    100% {
        transform: translateY(100vh);
    }
}

@keyframes flicker {
    0% { opacity: 0.93; }
    5% { opacity: 0.89; }
    10% { opacity: 0.97; }
    15% { opacity: 0.82; }
    20% { opacity: 0.96; }
    25% { opacity: 0.83; }
    30% { opacity: 0.95; }
    35% { opacity: 0.87; }
    40% { opacity: 0.94; }
    45% { opacity: 0.84; }
    50% { opacity: 0.98; }
    55% { opacity: 0.81; }
    60% { opacity: 0.97; }
    65% { opacity: 0.88; }
    70% { opacity: 0.92; }
    75% { opacity: 0.86; }
    80% { opacity: 0.98; }
    85% { opacity: 0.81; }
    90% { opacity: 0.93; }
    95% { opacity: 0.87; }
    100% { opacity: 0.95; }
}

@keyframes rgb-split {
    0% {
        text-shadow: -2px 0 var(--primary-glow), 2px 0 var(--secondary-glow);
    }
    25% {
        text-shadow: -3px 0 var(--primary-glow), 3px 0 var(--secondary-glow);
    }
    50% {
        text-shadow: -2px 0 var(--primary-glow), 2px 0 var(--secondary-glow);
    }
    75% {
        text-shadow: -3px 0 var(--primary-glow), 3px 0 var(--secondary-glow);
    }
    100% {
        text-shadow: -2px 0 var(--primary-glow), 2px 0 var(--secondary-glow);
    }
}

@keyframes rgbScan {
    0% {
        transform: translateY(-50vh);
    }
    100% {
        transform: translateY(50vh);
    }
}

@keyframes noise {
    0%, 100% { transform: translate(0, 0) scale(1.5); }
    10% { transform: translate(-5%, -5%) scale(1.5); }
    20% { transform: translate(-10%, 5%) scale(1.5); }
    30% { transform: translate(5%, -10%) scale(1.5); }
    40% { transform: translate(-5%, 15%) scale(1.5); }
    50% { transform: translate(-10%, 5%) scale(1.5); }
    60% { transform: translate(15%, 0) scale(1.5); }
    70% { transform: translate(0, 10%) scale(1.5); }
    80% { transform: translate(-15%, 0) scale(1.5); }
    90% { transform: translate(10%, 5%) scale(1.5); }
}

@keyframes glitch {
    0% { transform: translateX(0); }
    10% { transform: translateX(-5px); }
    20% { transform: translateX(5px); }
    30% { transform: translateX(-10px); }
    40% { transform: translateX(10px); }
    50% { transform: translateX(0); }
    60% { transform: translateX(-5px); }
    70% { transform: translateX(5px); }
    80% { transform: translateX(-10px); }
    90% { transform: translateX(10px); }
    100% { transform: translateX(0); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

@keyframes powerUp {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(0); }
}

@keyframes scanDistort {
    0% {
        transform: skew(0deg);
    }
    50% {
        transform: skew(0.3deg);
    }
    100% {
        transform: skew(0deg);
    }
}

/* Smooth scrolling and better animations */
html {
    scroll-behavior: smooth;
}

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

body {
    background-color: var(--background);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
    font-family: 'Inter', sans-serif;
    width: 100%;
}

/* Modern scrollbar */
::-webkit-scrollbar {
    width: 8px;
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

/* CRT and Retro Effects Container */
.retro-effects {
    position: fixed;
    top: -50vh;
    left: -50vw;
    right: -50vw;
    bottom: -50vh;
    width: 200vw;
    height: 200vh;
    pointer-events: none;
    z-index: 9999;
    animation: scanDistort 2s infinite;
    transform-origin: center center;
}

/* Scanlines */
.scanlines,
.moving-scanline,
.noise,
.flicker,
.vignette {
    position: fixed;
    top: -50vh;
    left: -50vw;
    right: -50vw;
    bottom: -50vh;
    width: 200vw;
    height: 200vh;
}

.scanlines {
    background: repeating-linear-gradient(
        0deg,
        transparent 0px,
        transparent 1px,
        var(--scanline-color) 2px,
        var(--scanline-color) 3px
    );
    background-size: 100% 4px;
    opacity: 0.4;
    pointer-events: none;
    mix-blend-mode: overlay;
}

.scanlines::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.9) 0px,
        rgba(0, 0, 0, 0.9) 1px,
        transparent 1px,
        transparent 2px
    );
    background-size: 100% 2px;
    opacity: 0.3;
    mix-blend-mode: multiply;
}

.scanlines::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        repeating-linear-gradient(
            0deg,
            rgba(255, 0, 0, 0.1) 0px,
            rgba(255, 0, 0, 0.1) 1px,
            transparent 1px,
            transparent 2px
        ),
        repeating-linear-gradient(
            0deg,
            rgba(0, 255, 0, 0.1) 1px,
            rgba(0, 255, 0, 0.1) 2px,
            transparent 2px,
            transparent 3px
        );
    background-size: 100% 4px;
    opacity: 0.2;
    mix-blend-mode: screen;
    animation: rgbScan 3s linear infinite;
}

/* Moving scanline */
.moving-scanline {
    height: 4px;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(255, 255, 255, 0.5) 50%,
        transparent 100%
    );
    animation: scanline 4s linear infinite;
    opacity: 0.7;
    mix-blend-mode: overlay;
}

.moving-scanline::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 10px;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0.1) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0.1) 100%
    );
    animation: scanline 6s linear infinite;
    animation-delay: -2s;
}

/* Noise effect */
.noise {
    background-image: var(--noise);
    opacity: 0.08;
    animation: noise 0.5s steps(2) infinite;
    mix-blend-mode: overlay;
    pointer-events: none;
}

/* Screen flicker */
.flicker {
    background: transparent;
    opacity: 0.2;
    animation: flicker 0.12s infinite;
    mix-blend-mode: multiply;
}

/* Vignette effect */
.vignette {
    background: radial-gradient(
        circle at center,
        transparent 0%,
        rgba(0, 0, 0, 0.2) 60%,
        rgba(0, 0, 0, 0.8) 100%
    );
    transform-origin: center center;
}

/* Modern layout with retro accents */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    overflow: visible;
}

.hero {
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    min-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 6rem 0 3rem;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.9));
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(45deg, var(--primary-glow) 0%, transparent 100%),
        linear-gradient(-45deg, var(--secondary-glow) 0%, transparent 100%);
    opacity: 0.1;
    mix-blend-mode: overlay;
}

.hero-content {
    text-align: center;
    position: relative;
    z-index: 1;
}

.hero-title {
    margin-bottom: 2rem;
}

.glitch-text {
    font-family: 'Press Start 2P', monospace;
    font-size: 2rem;
    color: var(--accent);
    text-shadow: 0 0 10px var(--accent-glow);
    display: block;
    margin-bottom: 1rem;
    animation: glitch 2s infinite;
}

.hero h1 {
    font-size: clamp(3rem, 10vw, 7rem);
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    background: linear-gradient(to right, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 20px var(--primary-glow));
    margin-bottom: 1rem;
    filter: brightness(1.2) drop-shadow(0 0 5px var(--primary-glow));
}

.power-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--surface);
    border: 2px solid var(--primary);
    color: var(--primary);
    font-family: 'Press Start 2P', monospace;
    font-size: 0.8rem;
    text-transform: uppercase;
    animation: pulse 2s infinite;
}

.hero p {
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    max-width: 800px;
    margin: 0 auto 3rem;
    opacity: 0.9;
    line-height: 1.6;
}

.cta-container {
    position: relative;
    display: inline-block;
}

.power-meter {
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--surface);
    overflow: hidden;
}

.power-meter::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, var(--primary), var(--secondary));
    animation: powerUp 2s ease-out forwards;
}

.services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 4rem 0;
}

.service-card {
    background: var(--surface);
    padding: 2rem;
    position: relative;
    overflow: hidden;
    border: 2px solid var(--primary);
    transition: all 0.3s ease;
}

.card-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    position: relative;
}

.card-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 10px var(--primary-glow));
}

.power-indicator {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to right, var(--primary), var(--secondary));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
    border-color: var(--secondary);
}

.service-card:hover .power-indicator {
    transform: scaleX(1);
}

.service-card h3 {
    font-family: 'Press Start 2P', monospace;
    font-size: 1.2rem;
    color: var(--primary);
    margin-bottom: 1rem;
    text-align: center;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 4rem 0;
}

.gallery-item {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
    border: 2px solid var(--primary);
}

.item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.power-level {
    font-family: 'Press Start 2P', monospace;
    color: var(--primary);
    text-shadow: 0 0 10px var(--primary-glow);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.gallery-item:hover .item-overlay {
    opacity: 1;
}

.gallery-item:hover .power-level {
    transform: translateY(0);
}

/* Modern buttons with retro accents */
.cta-button {
    display: inline-block;
    padding: 1.5rem 3rem;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--primary);
    background: transparent;
    border: 2px solid var(--primary);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    font-family: 'Press Start 2P', monospace;
    text-decoration: none;
    filter: brightness(1.2) drop-shadow(0 0 5px var(--primary-glow));
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--primary);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    z-index: -1;
}

.cta-button:hover {
    color: var(--background);
}

.cta-button:hover::before {
    transform: translateX(0);
}

/* Add smooth reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Modern card layout with retro accents */
.navbar {
    background-color: rgba(0, 0, 0, 0.95);
    padding: 1.5rem;
    position: fixed;
    width: 100vw;
    left: 50%;
    transform: translateX(-50%);
    top: 0;
    z-index: 1000;
    border-bottom: 4px solid var(--primary);
    text-transform: uppercase;
}

.navbar-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    font-size: 2rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 700;
    letter-spacing: 4px;
    text-shadow: 0 0 10px var(--primary-glow);
    animation: flicker 3s infinite;
    filter: brightness(1.2) drop-shadow(0 0 5px var(--primary-glow));
}

.nav-links {
    display: flex;
    gap: 3rem;
}

.nav-link {
    color: var(--text);
    text-decoration: none;
    letter-spacing: 2px;
    position: relative;
    padding: 0.5rem 1rem;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: var(--primary);
    border-color: var(--primary);
    text-shadow: 0 0 10px var(--primary-glow);
    box-shadow: 0 0 20px var(--primary-glow);
}

.contact-form {
    background-color: var(--surface);
    padding: 4rem;
    border: 4px solid var(--primary);
    position: relative;
    overflow: hidden;
    margin: 6rem 0;
}

.contact-form h2 {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary);
    text-shadow: 0 0 15px var(--primary-glow);
    animation: flicker 4s infinite;
}

.form-group {
    margin-bottom: 2rem;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 1rem;
    color: var(--text);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background-color: var(--surface-alt);
    border: 2px solid var(--primary);
    color: var(--text);
    font-size: 1.1rem;
    transition: all 0.3s ease;
    font-family: 'Press Start 2P', monospace;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--secondary);
    box-shadow: 0 0 20px var(--secondary-glow);
}

.form-group textarea {
    height: 200px;
    resize: vertical;
}

footer {
    background-color: var(--surface);
    color: var(--text-dim);
    padding: 4rem 0;
    margin-top: 6rem;
    border-top: 4px solid var(--primary);
    position: relative;
    text-align: center;
    font-size: 1.1rem;
    letter-spacing: 2px;
}

/* Add styles for the credits */
.credits-text {
    font-family: 'Press Start 2P', monospace;
    font-size: 0.7rem;
    position: absolute;
    top: -1.5rem;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    color: var(--text-dim);
    opacity: 0.7;
    text-shadow: 0 0 5px var(--primary-glow);
}

.credits-text .player1 {
    color: var(--primary);
    animation: textGlow 2s infinite alternate;
}

.credits-text .player2 {
    color: var(--secondary);
    animation: textGlow 2s infinite alternate-reverse;
}

.credits-text .plus {
    color: var(--accent);
    animation: plusPulse 1s infinite;
}

.credits-text .combo {
    position: absolute;
    top: -1rem;
    right: -4rem;
    color: var(--accent);
    transform: rotate(-15deg);
    font-size: 0.6rem;
    opacity: 0;
    animation: comboPopup 5s infinite;
}

@keyframes textGlow {
    0% { text-shadow: 0 0 5px currentColor; }
    100% { text-shadow: 0 0 15px currentColor; }
}

@keyframes plusPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

@keyframes comboPopup {
    0%, 85%, 100% { opacity: 0; transform: rotate(-15deg) scale(0.8); }
    5%, 80% { opacity: 1; transform: rotate(-15deg) scale(1); }
}

/* Style the SVG icons */
.card-icon svg {
    width: 64px;
    height: 64px;
    fill: currentColor;
}

.icon-overclock {
    color: var(--primary);
}

.icon-overclock .power-surge {
    opacity: 0;
    animation: surgePulse 2s infinite;
}

.icon-hdmi {
    color: var(--secondary);
}

.icon-hdmi .scan-line {
    stroke: currentColor;
    stroke-width: 2;
    animation: scanMove 2s infinite;
}

.icon-beast {
    color: var(--accent);
}

.icon-beast .power-bolt {
    opacity: 0;
    animation: boltFlash 1.5s infinite;
}

@keyframes surgePulse {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

@keyframes scanMove {
    0% { transform: translateY(-6px); }
    100% { transform: translateY(6px); }
}

@keyframes boltFlash {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

/* Style the mod previews */
.mod-preview {
    width: 100%;
    height: 100%;
    background: var(--surface);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mod-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, var(--primary-glow), var(--secondary-glow));
    opacity: 0.1;
    animation: gradientMove 5s infinite;
}

.mod-stats {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 1rem;
    padding: 2rem;
    font-family: 'Press Start 2P', monospace;
    font-size: 0.8rem;
    text-align: center;
}

.stat {
    background: rgba(0, 0, 0, 0.7);
    padding: 0.5rem 1rem;
    border: 2px solid currentColor;
    animation: statPulse 2s infinite;
}

.mod-1 .stat { color: var(--primary); animation-delay: 0s; }
.mod-2 .stat { color: var(--secondary); animation-delay: 0.3s; }
.mod-3 .stat { color: var(--accent); animation-delay: 0.6s; }

@keyframes gradientMove {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(10%, 10%); }
}

@keyframes statPulse {
    0%, 100% { border-color: currentColor; }
    50% { border-color: transparent; }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.5rem;
        letter-spacing: 4px;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .contact-form {
        padding: 2rem;
    }
    
    .nav-links {
        display: none;
    }
    
    body {
        border-width: 10px;
    }
}
