/* --- Global Reset & Variables --- */
:root {
    --bg-dark: #0f0f11;
    /* Very dark gray/black */
    --bg-light: #1a1a1d;
    /* Slightly lighter, but still dark */
    --accent: #a855f7;
    /* Purple */
    --text-main: #ffffff;
    --text-muted: #888888;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
}

/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    z-index: 1000;
    /* Glassmorphism effect */
    background: rgba(15, 15, 17, 0.8);
    backdrop-filter: blur(10px);
}

.nav-left,
.nav-right {
    width: 100px;
    /* Balance the center */
}

/* Dropdown */
.drop-btn {
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1rem;
    cursor: pointer;
    font-weight: bold;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--bg-light);
    min-width: 160px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.5);
    z-index: 1;
    border-radius: 4px;
}

.dropdown-content a {
    color: var(--text-main);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 0.9rem;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-content a:hover {
    background-color: var(--accent);
}

/* Center Logo (Hidden initially) */
.nav-center {
    flex-grow: 1;
    text-align: center;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 800;
    opacity: 0;
    /* Hidden by default */
    transform: translateY(-20px);
    transition: all 0.5s ease;
    color: var(--accent);
}

.nav-logo.visible {
    opacity: 1;
    transform: translateY(0);
}

.discord-icon {
    color: var(--text-main);
    font-size: 1.5rem;
    float: right;
    transition: color 0.3s;
}

.discord-icon:hover {
    color: #5865F2;
}

/* --- Hero Section --- */
#hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    background: radial-gradient(circle at center, #2a1b3d 0%, var(--bg-dark) 70%);
}

#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
}

.hero-content {
    text-align: center;
    z-index: 2;
    pointer-events: none;
    /* Lets you click through text to particles if needed */
}

.main-title {
    font-size: 8rem;
    font-weight: 900;
    letter-spacing: -5px;
    /* The Pretty Purple Gradient */
    background: linear-gradient(180deg, #d8b4fe 0%, #7e22ce 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 20px rgba(168, 85, 247, 0.6));
    margin-bottom: 0px;
}

.tagline {
    font-size: 1rem;
    letter-spacing: 5px;
    color: var(--text-muted);
    margin-top: -10px;
}

/* --- Project Sections --- */
.project-section {
    padding: 100px 10%;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

/* --- High-Tech Backgrounds --- */

/* Dark Section: Spotlight Effect */
/* Makes the center slightly lighter, drawing eye to the content */
.dark-bg {
    background: radial-gradient(circle at center, #1a1a1e 0%, #050505 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.05); /* Subtle separator line */
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* Light Section: Engineering Grid */
/* Creates a faint dot-grid pattern like a blueprint */
.light-bg {
    background-color: #0f0f11; /* Dark base */
    background-image: radial-gradient(#333 1px, transparent 1px);
    background-size: 30px 30px; /* Size of the grid squares */
    border-top: 1px solid rgba(168, 85, 247, 0.1); /* Faint purple line separator */
    border-bottom: 1px solid rgba(168, 85, 247, 0.1);
}

.container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 60px;
    opacity: 0;
    /* For fade in */
    transform: translateY(50px);
    transition: all 1s ease-out;
}

/* Scroll Animation Class */
.container.active {
    opacity: 1;
    transform: translateY(0);
}

.reverse {
    flex-direction: row-reverse;
}

/* Images */
.project-visual {
    flex: 1;
    height: 400px;
}

.img-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #222, #333);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #555;
    font-weight: bold;
    border: 1px solid #333;
    /* Replace this div with an <img> tag when you have your renders */
}

.img-placeholder:hover {
    border-color: var(--accent);
    box-shadow: 0 0 30px rgba(168, 85, 247, 0.2);
    transition: 0.3s;
}

/* Text Info */
.project-details {
    flex: 0.8;
}

.category {
    font-size: 0.8rem;
    color: var(--accent);
    letter-spacing: 2px;
    font-weight: bold;
}

.client-logo-text {
    font-size: 3rem;
    font-weight: 800;
    margin: 10px 0 20px 0;
    line-height: 1;
}

/* Update your existing .client-logo-text to include a glow */
.client-logo-text {
    font-family: 'Inter', sans-serif;
    font-size: 3.5rem;
    font-weight: 900;
    margin: 10px 0 20px 0;
    text-transform: uppercase;
    line-height: 1;
    letter-spacing: -2px;
    color: #fff;
    /* The Glow Effect: */
    text-shadow: 0 0 20px rgba(168, 85, 247, 0.5);
}

/* Update Description to be more readable */
.description {
    color: #aaa;
    /* Lighter gray for better contrast */
    line-height: 1.7;
    /* More breathing room */
    font-size: 1.05rem;
    font-weight: 300;
    margin-bottom: 30px;
    max-width: 500px;
    /* Keeps text from getting too wide to read */
}

/* Update the Visit Button to look like a "Tech" button */
.visit-btn {
    display: inline-block;
    padding: 14px 40px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.visit-btn:hover {
    border-color: #a855f7;
    background: rgba(168, 85, 247, 0.1);
    /* Subtle purple tint */
    box-shadow: 0 0 30px rgba(168, 85, 247, 0.4);
    /* Glow */
    transform: translateY(-2px);
}

.cta-content h2 {
    font-family: 'Inter', sans-serif;
    font-size: 4rem;
    /* Massive text */
    font-weight: 900;
    letter-spacing: -3px;
    margin-bottom: 40px;
    color: #ffffff;
    text-transform: uppercase;
    /* Glitchy Text Shadow */
    text-shadow:
        2px 0 #a855f7,
        -2px 0 #22c55e;
    /* Tiny purple/green offset for a glitch look */
}


/* 1. For Harvester (Text Version) */
.client-logo-text {
    font-family: 'Inter', sans-serif;
    /* Ensures it uses Inter */
    font-size: 3.5rem;
    /* Nice and big */
    font-weight: 900;
    /* Extra Bold */
    margin: 10px 0 20px 0;
    text-transform: uppercase;
    line-height: 1;
    letter-spacing: -2px;
    /* Tighter tracking looks more "logo-like" */
    color: var(--text-main);
}

/* 2. For RBX & Proxyon (SVG Version) */
.client-logo-rbx {
    display: block;
    width: 100%;
    /* Responsive width */
    max-width: 400px;
    /* Prevents it from getting too huge */
    height: auto;
    /* Keeps the aspect ratio perfect */
    margin: 15px 0 25px 0;
}

.client-logo-prxyon {
    display: block;
    width: 100%;
    /* Responsive width */
    max-width: 300px;
    /* Prevents it from getting too huge */
    height: auto;
    /* Keeps the aspect ratio perfect */
    margin: 15px 0 25px 0;
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .client-logo-text {
        font-size: 2.5rem;
        text-align: center;
    }

    .client-logo-svg {
        max-width: 100px;
        margin: 15px auto;
        /* Centers the SVG on mobile */
    }
}

.description {
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.visit-btn:hover {
    background-color: var(--accent);
    border-color: var(--accent);
    box-shadow: 0 0 15px var(--accent);
}

/* --- Footer --- */
footer {
    padding: 50px;
    text-align: center;
    background-color: #050505;
    border-top: 1px solid #222;
}

footer p {
    color: var(--text-muted);
    margin-bottom: 20px;
}

.socials a {
    color: var(--text-main);
    margin: 0 15px;
    font-size: 1.2rem;
    transition: color 0.3s;
}

.socials a:hover {
    color: var(--accent);
}

/* Forces a black logo to become white */
.make-white {
    filter: brightness(0) invert(1);
}

/* --- Animated Call to Action (CTA) Section --- */
.cta-section {
    /* The Gradient: We mix 4 different purple/dark tones */
    background: linear-gradient(-45deg, #2e1065, #7e22ce, #a855f7, #4c1d95);
    background-size: 400% 400%; /* Makes the background huge so we can move it around */
    animation: gradientFlow 10s ease infinite; /* The animation engine */
    
    padding: 120px 20px;
    text-align: center;
    position: relative;
    border-top: 1px solid #333;
}

/* The Animation Keyframes */
@keyframes gradientFlow {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.cta-btn {
    display: inline-block;
    padding: 20px 60px;
    background-color: #ffffff;
    color: #581c87; /* Deep purple text */
    font-weight: 900;
    font-size: 1.2rem;
    text-decoration: none;
    border-radius: 50px;
    text-transform: uppercase;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3); /* Strong shadow */
    transition: all 0.3s ease;
}

.cta-btn:hover {
    transform: translateY(-5px) scale(1.05); /* Slight grow effect */
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    background-color: #f3e8ff; /* Very light purple tint on hover */
}

/* --- Global Aesthetic Overlays --- */

/* 1. The CRT Scanline Effect (covers whole screen) */
.global-scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    /* THE FIX: Changed rgba(0,0,0...) to rgba(255,255,255...) */
    /* This creates faint white lines that show up on dark backgrounds */
    background: repeating-linear-gradient(to bottom,
            transparent 0px,
            transparent 2px,
            rgba(255, 255, 255, 0.03) 3px,
            rgba(255, 255, 255, 0.03) 4px);

    pointer-events: none;
    /* Important: lets you click buttons underneath */
    z-index: 9999;
    /* Ensures it sits on top of images and text */
}

/* 2. Custom Purple Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: #050505; 
}
::-webkit-scrollbar-thumb {
    background: #333; 
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a855f7; /* Purple on hover */
}

.scanlines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(to bottom,
            transparent 0px,
            transparent 2px,
            rgba(0, 0, 0, 0.1) 3px);
    pointer-events: none;
    /* Lets you click through it */
}

/* --- 3D Warped Image Effect --- */

/* 1. The Stage: Sets up the 3D depth */
.project-visual {
    perspective: 1000px; /* How "deep" the 3D effect looks */
    flex: 1;
    display: flex; /* Centers the image */
    justify-content: center;
    align-items: center;
}

/* 2. The Actor: The Image Itself */
.project-render {
    width: 100%;
    max-width: 600px; /* Prevents it from getting massive on big screens */
    border-radius: 15px; /* Smooth corners */
    
    /* THE WARP: Tilted slightly away from the user */
    transform: rotateY(15deg) rotateX(5deg) scale(0.95);
    
    /* THE GLOW: A strong purple shadow */
    box-shadow: 20px 20px 60px rgba(168, 85, 247, 0.4); 
    
    /* THE TRANSITION: Smooth movement */
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1); /* "Eased" for a premium feel */
    cursor: pointer;
}

/* 3. The Hover: Corrects the warp */
.project-visual:hover .project-render {
    /* Flattens the image to 0 degrees and zooms in slightly */
    transform: rotateY(0deg) rotateX(0deg) scale(1.02);
    
    /* Reduces the glow to a standard shadow so it's easier to see details */
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    
    z-index: 10; /* Ensures it pops over everything else */
}

/* --- Handling Direction for Alternating Layouts --- */

/* Normal Sections (Image on Left): Tilt it to the Right */
.container .project-render {
    transform: rotateY(15deg) rotateX(5deg) scale(0.95);
    box-shadow: 20px 20px 60px rgba(168, 85, 247, 0.4); 
}

/* Reversed Sections (Image on Right): Tilt it to the Left */
/* This makes the layouts feel balanced */
.container.reverse .project-render {
    transform: rotateY(-15deg) rotateX(5deg) scale(0.95);
    box-shadow: -20px 20px 60px rgba(168, 85, 247, 0.4); /* Shadow flips too */
}

/* Hover State is the same for both (Flat) */
.container:hover .project-render, 
.container.reverse:hover .project-render {
    transform: rotateY(0deg) rotateX(0deg) scale(1.02);
    box-shadow: 0 15px 40px rgba(0,0,0,0.6);
}

/* Mobile Reset */
@media (max-width: 768px) {
    .project-render {
        /* On phone, just keep it flat. 3D looks weird on small vertical screens */
        transform: none !important; 
        box-shadow: 0 10px 20px rgba(168, 85, 247, 0.2) !important;
        margin-bottom: 30px;
    }
}

/* Mobile Adjustment */
@media (max-width: 768px) {
    .

/* Mobile Responsiveness */
@media (max-width: 768px) {

    .container,
    .container.reverse {
        flex-direction: column;
        text-align: center;
    }

    .main-title {
        font-size: 5rem;
    }

    .nav-left,
    .nav-right {
        width: auto;
    }
}
