/* --- CSS VARIABLES & WHITE/BLACK/BEIGE/RED THEME --- */
:root {
    --bg-base: #f4ece4; 
    --glass-bg: rgba(255, 255, 255, 0.45); 
    --glass-border: rgba(0, 0, 0, 0.08); 
    --glass-highlight: rgba(255, 255, 255, 0.9); 
    --text-main: #0a0a0a; 
    --text-muted: #52525b; 
    --accent-red: #dc2626; 
    --accent-beige: #d6c5b3; 
    --shadow-color: rgba(0, 0, 0, 0.08); 
    --font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--bg-base);
    color: var(--text-main);
    font-family: var(--font-family);
    min-height: 100vh;
    padding: 1rem; 
    background-image: 
        radial-gradient(circle at 85% 10%, rgba(220, 38, 38, 0.08), transparent 45%),
        radial-gradient(circle at 10% 90%, rgba(0, 0, 0, 0.04), transparent 50%),
        radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.6), transparent 80%);
    overflow-x: hidden;
}

/* --- UTILITY: GLASSMORPHISM --- */
.glass-panel {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(255, 255, 255, 0.2));
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border-top: 1.5px solid var(--glass-highlight);
    border-left: 1.5px solid var(--glass-highlight);
    border-right: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: 0 24px 48px -12px var(--shadow-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding-bottom: 2rem;
}

/* --- NAVBAR --- */
.navbar {
    display: flex;
    flex-direction: row; 
    justify-content: space-between; 
    align-items: center;
    padding: 0.75rem 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.12);
    position: relative;
    z-index: 100;
    width: 100%; 
}

.nav-brand { display: flex; align-items: center; gap: 1rem; }
.nav-logo {
    width: 45px; height: 45px; border-radius: 10px; object-fit: cover;
    border: 1.5px solid var(--glass-highlight); box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.nav-name { font-size: 1.5rem; font-weight: 800; color: var(--text-main); letter-spacing: 1.5px; }
.nav-menu { display: flex; align-items: center; gap: 2rem; }
.nav-link {
    text-decoration: none; color: var(--text-muted); font-weight: 700;
    font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1.5px;
    transition: color 0.3s ease, transform 0.3s ease;
}
.nav-link:hover, .nav-link.active-link { color: var(--accent-red); transform: translateY(-2px); }

.side-panel-btn {
    background: none; border: none; color: var(--text-main); cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    transition: color 0.3s ease, transform 0.3s ease; padding: 0.5rem;
}
.side-panel-btn:hover { color: var(--accent-red); transform: scale(1.1); }

/* --- SIDE PANEL --- */
.side-panel {
    position: fixed; top: 0; right: 0; width: 320px; height: 100vh;
    background: rgba(244, 236, 228, 0.95); backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px); border-left: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.15); z-index: 2000;
    transform: translateX(100%); transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex; flex-direction: column; padding: 2rem;
}
.side-panel.open { transform: translateX(0); }
.side-panel-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 2.5rem; border-bottom: 1.5px solid rgba(0,0,0,0.08); padding-bottom: 1rem;
}
.side-panel-title { font-size: 1.25rem; font-weight: 800; color: var(--text-main); text-transform: uppercase; letter-spacing: 2px; }
.close-panel-btn { background: none; border: none; color: var(--text-main); cursor: pointer; transition: color 0.3s ease, transform 0.3s ease; }
.close-panel-btn:hover { color: var(--accent-red); transform: rotate(90deg); }
.side-panel-nav { display: flex; flex-direction: column; gap: 1rem; }
.side-panel-link {
    text-decoration: none; color: var(--text-muted); font-size: 1.1rem;
    font-weight: 600; padding: 0.75rem 1rem; border-radius: 8px; transition: all 0.3s ease;
}
.side-panel-link:hover, .side-panel-link.active-link {
    background: rgba(255, 255, 255, 0.6); color: var(--accent-red);
    transform: translateX(5px); box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}
.panel-backdrop {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background: rgba(10, 10, 10, 0.4); backdrop-filter: blur(3px); z-index: 1500;
    opacity: 0; pointer-events: none; transition: opacity 0.4s ease;
}
.panel-backdrop.open { opacity: 1; pointer-events: all; }

/* --- BLANK PAGES --- */
.blank-slate { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 60vh; text-align: center; padding: 3rem; }
.blank-slate h1 { font-size: 3rem; color: var(--text-main); margin-bottom: 1rem; background: linear-gradient(to right, var(--text-main), var(--accent-red)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.blank-slate p { color: var(--text-muted); font-size: 1.2rem; max-width: 600px; line-height: 1.6; }

/* --- EVENTS DASHBOARD --- */
.stats-container { display: flex; width: 100%; justify-content: space-around; align-items: center; padding: 2.5rem 2rem; margin-bottom: 2rem;}
.stat-block { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0.5rem; flex: 1; }
.stat-divider { width: 1.5px; height: 70px; background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.15), transparent); }
.stat-value { font-size: 3.25rem; font-weight: 800; color: var(--text-main); letter-spacing: -1.5px; text-shadow: 0 4px 12px rgba(255, 255, 255, 0.8); }
.stat-label { font-size: 0.875rem; color: var(--accent-red); text-transform: uppercase; letter-spacing: 2px; font-weight: 700; }
.carousel-container { display: flex; gap: 1rem; padding: 1rem; overflow-x: auto; scrollbar-width: none; margin-bottom: 2rem; }
.carousel-item { width: 60px; height: 60px; border-radius: 50%; cursor: pointer; transition: all 0.4s ease; border: 2px solid transparent; opacity: 0.4; object-fit: cover; background-color: var(--accent-beige); filter: grayscale(100%); }
.carousel-item:hover { opacity: 0.8; filter: grayscale(50%); }
.carousel-item.active { opacity: 1; filter: grayscale(0%); border-color: var(--accent-red); box-shadow: 0 0 20px rgba(220, 38, 38, 0.25); transform: scale(1.15); }
.dashboard { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; width: 100%; }
.collage-container { padding: 1.5rem; height: 100%; min-height: 450px; }
.collage-grid { display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: repeat(3, 1fr); gap: 12px; height: 100%; }
.collage-box { background-color: var(--accent-beige); border-radius: 8px; overflow: hidden; box-shadow: inset 0 0 15px rgba(0,0,0,0.1); }
.collage-box img { width: 100%; height: 100%; object-fit: cover; opacity: 0.9; transition: opacity 0.4s ease, transform 0.4s ease; }
.collage-box:hover img { opacity: 1; transform: scale(1.05); }
.box-1 { grid-row: 1 / span 2; grid-column: 1; } .box-2 { grid-row: 1; grid-column: 2; } .box-3 { grid-row: 2; grid-column: 2; } .box-4 { grid-row: 3; grid-column: 1; } .box-5 { grid-row: 3; grid-column: 2; }
.details-container { padding: 2.5rem; display: flex; flex-direction: column; gap: 1.5rem; }
.event-header h1 { font-size: 2.75rem; margin-bottom: 0.5rem; background: linear-gradient(to right, var(--text-main), var(--accent-red)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.event-description { color: var(--text-muted); line-height: 1.7; font-size: 1.05rem; font-weight: 500; }
.event-stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; margin-top: auto; }
.event-stat-box { background: rgba(255, 255, 255, 0.5); border: 1px solid rgba(255, 255, 255, 0.9); padding: 1.25rem; border-radius: 12px; border-left: 3px solid var(--text-main); transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease; }
.event-stat-box:hover { background: rgba(255, 255, 255, 0.9); transform: translateY(-2px); box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.08); }
.event-stat-box.red-accent { border-left-color: var(--accent-red); }
.stat-box-label { font-size: 0.75rem; color: var(--text-muted); text-transform: uppercase; margin-bottom: 0.4rem; letter-spacing: 1px; font-weight: 600; }
.stat-box-value { font-size: 1.35rem; font-weight: 800; color: var(--text-main); }
@media (max-width: 900px) { 
    .dashboard { grid-template-columns: 1fr; } 
    .stats-container { flex-direction: column; gap: 2rem; padding: 2rem 1rem; } 
    
    /* --- Mobile Navbar Fixes --- */
    .nav-menu { gap: 1rem; } /* Reduces space between links */
    .nav-link { 
        display: inline-block; /* Brings the links back */
        font-size: 0.75rem; /* Shrinks font slightly for mobile */
        letter-spacing: 0.5px; 
    }
    .nav-name { display: none; } /* Hides the text "FORSE" next to the logo so links have room to breathe */
}

/* ========================================= */
/* --- ABOUT US PAGE SPECIFIC STYLES --- */
/* ========================================= */

.about-intro-container {
    padding: 3.5rem 2rem;
    text-align: center;
}

.about-intro-container h2 {
    font-size: 2.2rem;
    color: var(--text-main);
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.about-intro-container p {
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.8;
    max-width: 800px;
    margin: 0 auto 2rem auto;
    font-weight: 500;
}

/* Custom Buttons */
.action-btn {
    background: var(--accent-red);
    color: #fff;
    border: none;
    padding: 0.85rem 2.5rem;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 50px; /* Pill shape */
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3);
    text-decoration: none;
    display: inline-block;
}

.action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(220, 38, 38, 0.5);
    background: #b91c1c; /* Slightly darker red */
}

.outline-btn {
    background: transparent;
    border: 2px solid var(--accent-red);
    color: var(--accent-red);
    box-shadow: none;
}

.outline-btn:hover {
    background: var(--accent-red);
    color: #fff;
}

/* Verticals Grid */
.verticals-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
}

.hidden {
    display: none !important;
}

/* Animation Wrapper for the 1-by-1 pop-up */
.vertical-wrapper {
    opacity: 0;
    transform: scale(0.3);
    transition: opacity 0.5s ease, transform 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Creates a bouncy pop-up effect */
}

.vertical-wrapper.show {
    opacity: 1;
    transform: scale(1);
}

/* The actual round containers */
.vertical-circle {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 2px solid var(--glass-highlight);
    box-shadow: 0 15px 35px -10px var(--shadow-color);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    
    /* Idle floating animation */
    animation: floatIdle 3.5s ease-in-out infinite;
}

.vertical-circle span {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
    pointer-events: none; /* Allows the circle to catch clicks smoothly */
    line-height: 1.3;
}

/* Float Keyframes */
@keyframes floatIdle {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Hover and Active State for Round Containers */
.vertical-circle:hover, .vertical-circle.active {
    background: var(--text-main);
    border-color: var(--text-main);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    animation: none; /* Stops the float so the hover scale is smooth */
    transform: scale(1.1);
}

.vertical-circle:hover span, .vertical-circle.active span {
    color: var(--bg-base); /* Flips text color to beige for high contrast */
}

/* Details Sub-Container */
.vertical-details {
    margin-top: 1rem;
    padding: 3rem 2rem;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.vertical-details.show {
    opacity: 1;
    transform: translateY(0);
}

.vertical-details h3 {
    font-size: 2rem;
    color: var(--accent-red);
    margin-bottom: 1rem;
}

.vertical-details p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.7;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* ========================================= */
/* --- FULL SCREEN 16-BIT ENGINE --- */
/* ========================================= */

.pixel-body { margin: 0; padding: 0; overflow: hidden; background: #1a1a20; }
.pixel-viewport { position: relative; width: 100vw; height: 100vh; overflow: hidden; }
.stage-layer { position: absolute; top: 0; left: 0; width: 100%; height: 100%; transition: opacity 0.8s ease; }
.stage-layer.hidden { opacity: 0; pointer-events: none; }
.pixel-img { image-rendering: pixelated; image-rendering: crisp-edges; }

/* --- OUTDOOR STAGE: STATIC BACKGROUND --- */
.outdoor-bg { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100vw; 
    height: 100vh; 
    z-index: 1; /* Keeps it strictly behind the player and the shop */
    overflow: hidden; 
}

.static-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Forces the image to fill the screen without leaving borders */
    position: absolute;
    top: 0;
    left: 0;
}

/* --- OUTDOOR OBJECTS --- */
.player-avatar {
    position: absolute; bottom: 5vh; left: -7vw; height: 35vh;
    /* THE FIX: Changed 'left' to 'all' so the centering transform smoothly slides instead of instantly teleporting */
    transition: left 4s linear; 
    z-index: 10;
}
.player-avatar.hidden { display: none; }

/* 1. Massively widen the window to prevent clipping */
#player-walking {
    height: 50vh;
    bottom: 2vh; 
    width: 40vw; /* INCREASED from 25vw to 40vw. He has half the screen of room now! */
    overflow: hidden; 
    display: flex; 
    justify-content: center; /* Centers the AI GIF safely away from the invisible walls */
}

@keyframes cancelAIWalk {
    0% { transform: translateX(0); }
    /* REDUCED from -40% to -12%. Adjust this slightly up or down if he still drifts! */
    100% { transform: translateX(-12%); } 
}

/* The wrapper that holds the Shop AND the Billboard side-by-side */
#environment-scroller {
    position: absolute; bottom: 2vh; right: -150vw; /* Starts way off screen right */
    display: flex; flex-direction: row; align-items: flex-end; gap: 1vw;
    transition: right 4s linear; z-index: 5;
}

#shop-exterior-img { 
    height: 80vh; 
    transition: filter 0.2s ease, transform 0.2s ease;
}

/* This class gets added by JS only AFTER he arrives at the shop */
#shop-exterior-img.interactive {
    cursor: pointer;
}

#shop-exterior-img.interactive:hover {
    filter: brightness(1.2); /* Makes the neon pop when hovered */
    transform: scale(1.02);  /* Slight bump effect */
}

/* Billboard Logic */
#sponsor-billboard { display: flex; align-items: flex-end; }
.desktop-banner { height: 40vh; max-height: 400px; display: block; }
.mobile-banner { height: 50vh; display: none; } /* Hidden on desktop */

/* --- INDOOR STAGE (The Room) --- */
/* 1. Reset the wrapper to a strict full-screen block */
.interior-scene-wrapper { 
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw; 
    height: 100vh; 
    display: block !important; /* Kills the old flexbox layout */
    background: #000; 
    overflow: hidden;
}

/* 2. Force the image to cover everything, no exceptions */
.interior-bg-img { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100vw !important; 
    height: 100vh !important; 
    max-width: none !important; /* Annihilates the old max-width constraint */
    max-height: none !important; /* Annihilates the old max-height constraint */
    object-fit: cover !important; /* Forces it to fill the screen */
    z-index: 1; 
}

#visual-event-poster {
    position: absolute;
    z-index: 0; /* Forces it behind the room (.interior-bg-img is z-index: 1) */
    object-fit: cover; /* Ensures the poster fills the coordinate box without stretching weirdly */
    pointer-events: none; /* Prevents the poster from accidentally stealing mouse clicks */
}

/* Forces the indoor room to render completely over top of the outdoor avatars and props */
#indoor-stage {
    z-index: 100; 
}

/* INTERACTIVE HITBOXES */
.hitbox {
    position: absolute; display: block; 
    /*border: 2px dashed rgba(255, 0, 0, 0.8); /* Add this line back when adding another hitbox*/
    cursor: pointer; z-index: 20; transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.hitbox:hover { transform: scale(1.05); background: rgba(245, 245, 245, 0.05); box-shadow: none; border-radius: 8px; }

/* The Photo Frame */
.poster-frame-hitbox { display: flex; align-items: center; justify-content: center; overflow: hidden; padding: 2px; }

.exit-btn { position: absolute; top: 20px; right: 20px; background: #dc2626; color: white; border: 2px solid white; padding: 10px 20px; font-family: 'Courier New', monospace; font-weight: bold; cursor: pointer; z-index: 50; }

/* --- RPG DIALOGUE --- */
.rpg-dialogue { position: absolute; bottom: 5vh; left: 50%; transform: translateX(-50%); width: 80vw; max-width: 800px; background: rgba(0, 0, 0, 0.85); border: 4px solid #fff; color: #fff; padding: 2rem; font-family: 'Courier New', monospace; font-size: 1.5rem; display: flex; justify-content: space-between; align-items: center; z-index: 100; opacity: 0; transition: opacity 0.3s; }
.rpg-dialogue.show { opacity: 1; }
.dialogue-btn { background: none; border: none; color: #fff; font-size: 2rem; cursor: pointer; animation: bounce 1s infinite; }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }

/* --- MOBILE & POSITIONING ADJUSTMENTS --- */
@media (max-width: 768px) {
    #environment-scroller { flex-direction: column; align-items: center; right: -200vw; gap: 2rem; }
    #shop-exterior-img { height: 30vh; }
    
    /* Flip Banners */
    .desktop-banner { display: none; }
    .mobile-banner { display: block; height: 35vh; }
    
    /* Center logic */
    #environment-scroller.centered { right: 50%; transform: translateX(50%); }
    .player-avatar.centered { left: 50%; transform: translateX(-50%); }
}
@media (min-width: 769px) {
    /* Offset the scroller so the Shop lands in the center, not the whole wrapper */
    #environment-scroller.centered { right: calc(50% - 15vw); transform: translateX(50%); }
    .player-avatar.centered { left: calc(50% - 15vw); transform: translateX(-50%); }
}
/* --- FINAL ANIMATION FIX --- */
/* This forces the player to walk to the middle smoothly without teleporting */
.player-walking-animation {
    animation: walkToShop 4s linear forwards;
}

@keyframes walkToShop {
    0% { left: 15vw; }
    100% { left: 35vw; }
}

/* The container moves from 15vw to 35vw */
.player-walking-animation {
    animation: walkToShop 4s linear forwards;
}

@keyframes walkToShop {
    0% { left: 15vw; }
    100% { left: 35vw; }
}

/* The GIF plays inside the container, pulling backward to stay in place */
#ai-gif-treadmill {
    height: 100%;
    width: auto;
    /* This animation MUST match your GIF duration exactly */
    animation: cancelAIWalk 1.0s infinite linear; 
}

@keyframes cancelAIWalk {
    0% { transform: translateX(0); }
    100% { transform: translateX(-20%); } /* Tweak this % until he doesn't slide */
}

/* ========================================= */
/* --- BOTTOM NAVBAR (FOOTER) --- */
/* ========================================= */

.footer {
    width: 100%; 
    max-width: 1200px;
    margin: 4rem auto 2rem auto; 
    z-index: 100;   
    
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem; 
    
    box-sizing: border-box; 
}

.footer-left {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.footer-left h4 {
    font-size: 1rem;
    color: var(--text-main);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 800;
}

.footer-left p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin: 0;
    font-weight: 500;
}

.footer-right {
    display: flex;
    gap: 2rem;
}

.footer-link {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 700;
    
    /* THE FIX: Bumped up the size so the logos are clearly visible */
    font-size: 0.8rem; 
    
    text-transform: uppercase;
    letter-spacing: 1.5px;
    transition: color 0.3s ease, transform 0.3s ease;
}

.footer-link:hover {
    color: var(--accent-red);
    transform: translateY(-2px);
}

/* --- MOBILE FOOTER FIXES --- */
@media (max-width: 768px) {
    .footer {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
        padding: 2rem 1.5rem;
    }
    
    .footer-left {
        align-items: center;
    }
    
    .footer-right {
        flex-wrap: wrap; /* Allows links to wrap to a new line if the screen is tiny */
        justify-content: center;
        gap: 1.5rem;
    }
}
