/* --- VARIABLES & THEME (CYBER PURPLE) --- */
:root {
    /* PRIMARY COLOR CHANGE: Gray & Goldish-Orange Theme */
    --primary: #d44a4a; 
    --primary-glow: rgba(220, 20, 60, 0.5); /* Red Glow */
    --bg-dark: #050505;
    --text-main: #ffffff;
    --text-muted: #a1a1aa;
    --glass-border: rgba(255, 255, 255, 0.08);
    --blur: blur(12px);
}


.ip-widget {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    padding: 1.5rem;
    border-radius: 12px;
    width: 100%;
    max-width: 500px;
    margin: 2rem auto 0 auto; /* Pulls the next section closer */
    backdrop-filter: blur(10px);
}

/* --- SERVER STATUS INDICATOR --- */
.status-dot {
    width: 8px;
    height: 8px;
    background: #808080; /* Gray when checking */
    border-radius: 50%;
    display: inline-block;
    transition: all 0.3s ease;
}

.status-dot.online {
    background: #00ff00;
    box-shadow: 0 0 10px #00ff00;
}

.status-dot.offline {
    background: #ff4b4b;
    box-shadow: 0 0 10px #ff4b4b;
}

/* --- SPACING FOR SECTIONS BELOW --- */
#about, #features {
    padding: 60px 0; /* Tightens the gap between sections */
}

/* --- CORE RESET & LAYOUT --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
/* --- CORE RESET & LAYOUT --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { 
    scroll-behavior: smooth; 
    /* THE FIX: Reserves space for the scrollbar so content never jumps */
    scrollbar-gutter: stable; 
    overflow-y: scroll; 
}

html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
    min-height: 100vh;
    box-shadow: 0 0 50px rgba(220, 20, 60, 0.1) inset;
}

/* Custom Scrollbar for a cleaner look */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(220, 20, 60, 0.4);
    border-radius: 10px;
}

#canvas-container {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1;
    /* Enhanced radial gradient for a deeper, glowing background */
    background: radial-gradient(circle at center, #1a1410 0%, #000000 100%); /* Subtle warm dark background */
}

/* --- NAVBAR --- */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    padding: 0.5rem 0; transition: all 0.4s ease;
    background: rgba(5, 5, 5, 0.95); border-bottom: 1px solid var(--glass-border);
}
.navbar.scrolled {
    background: rgba(5, 5, 5, 0.85); backdrop-filter: var(--blur);
    border-bottom: 1px solid var(--glass-border); padding: 0.5rem 0;
}
.nav-container {
    max-width: 1200px; margin: 0 auto; padding: 0 2rem;
    display: flex; justify-content: space-between; align-items: center;
}
.logo-link { display: flex; align-items: center; text-decoration: none; }
.logo-img {
    height: 96px; width: auto; transition: all 0.3s ease;
}
.logo-img:hover { transform: scale(1.05); filter: drop-shadow(0 0 8px var(--primary)); }
.nav-links { display: flex; gap: 2rem; list-style: none; align-items: center; }
.nav-links a {
    color: var(--text-muted); text-decoration: none; font-weight: 500;
    transition: color 0.3s ease; font-size: 0.95rem;
}
.nav-links a:hover { color: white; text-shadow: 0 0 10px rgba(255,255,255,0.5); }
.nav-links a.active { color: white; border-bottom: 1px solid var(--primary); }
.nav-btn {
    background: rgba(255, 255, 255, 0.1); border: 1px solid var(--glass-border);
    padding: 0.6rem 1.5rem; border-radius: 8px; color: white !important; transition: all 0.3s ease;
}
.nav-btn:hover { background: var(--primary); border-color: var(--primary); box-shadow: 0 0 20px var(--primary-glow); }

/* --- Center Oval Trigger + Glassy Dropdown --- */
.nav-center { display: flex; justify-content: center; align-items: center; position: relative; }
.nav-center-inner { position: relative; }
.nav-oval {
    appearance: none; border: 1px solid rgba(255,255,255,0.08);
    background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.02));
    color: white; padding: 0.6rem 2.2rem; border-radius: 999px; font-weight: 800; letter-spacing: 0.6px;
    backdrop-filter: blur(10px) saturate(120%); box-shadow: 0 8px 30px rgba(220, 20, 60, 0.14), inset 0 1px 0 rgba(255,255,255,0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.nav-oval:hover { transform: translateY(-3px); box-shadow: 0 14px 50px rgba(220, 20, 60, 0.22); }
.nav-oval::after { content: ''; position: absolute; left: 8%; top: 6%; width: 60%; height: 52%; filter: blur(6px); pointer-events: none; }
.nav-oval[aria-expanded="true"] { box-shadow: 0 20px 80px rgba(220, 20, 60, 0.28); }

.nav-dropdown {
    position: absolute; top: calc(100% + 14px); left: 50%; transform: translateX(-50%) translateY(-10px);
    min-width: 260px; max-width: 360px; background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
    border: 1px solid var(--glass-border); border-radius: 16px; padding: 0.8rem; backdrop-filter: blur(18px);
    opacity: 0; pointer-events: none; transition: opacity 0.28s ease, transform 0.28s ease;
    box-shadow: 0 30px 80px rgba(0,0,0,0.6), 0 6px 30px rgba(220, 20, 60, 0.06) inset;
    z-index: 1200;
}
.nav-dropdown.open, .nav-dropdown[aria-hidden="false"] { opacity: 1; pointer-events: auto; transform: translateX(-50%) translateY(0); }
.nav-dropdown .dropdown-link { display: block; color: var(--text-main); padding: 0.6rem 0.8rem; border-radius: 10px; text-decoration: none; font-weight: 700; transition: background 0.18s, color 0.18s; }
.nav-dropdown .dropdown-link:hover { background: rgba(220, 20, 60, 0.08); color: #fff; }
.dropdown-footer { margin-top: 0.6rem; text-align: center; }
.dropdown-cta { display: inline-block; padding: 0.5rem 1rem; background: linear-gradient(180deg, var(--primary), #d44a4a); color: #fff; border-radius: 10px; text-decoration: none; font-weight: 800; box-shadow: 0 10px 40px rgba(220,20,60,0.25); }

@media (max-width: 768px) {
    /* Mobile: use the center oval as full-screen menu (replace hamburger behavior) */
    .nav-dropdown {
        position: fixed; inset: 0; left: 0; top: 0; width: 100%; height: 100vh;
        display: flex; flex-direction: column; justify-content: center; align-items: center;
        background: rgba(5,5,5,0.98); backdrop-filter: blur(18px);
        transform: none; opacity: 0; pointer-events: none; padding: 2rem; border: none; border-radius: 0;
        box-shadow: none; z-index: 1999;
    }
    .nav-dropdown.open, .nav-dropdown[aria-hidden="false"] { opacity: 1; pointer-events: auto; }
    .nav-dropdown .dropdown-link { padding: 1rem 0; font-size: 1.3rem; }

    /* Keep `nav-links` visually hidden; dropdown replaces mobile menu */
    .nav-links { display: none !important; }
}

/* --- PAGE TRANSITION WRAPPER --- */
#page-wrapper { position: relative; overflow: hidden; min-height: 100vh; }
#page-content { width: 100%; transition: transform 0.6s cubic-bezier(0.86, 0, 0.07, 1); }

/* --- GENERAL SECTIONS --- */
.container { max-width: 1200px; margin: 0 auto; padding-top: 8rem; padding-bottom: 4rem; padding-left: 2rem; padding-right: 2rem; }
section { padding: 6rem 2rem; position: relative; z-index: 1; }
.section-header { margin-bottom: 4rem; text-align: center; }
.section-header h2 { font-family: 'Outfit', sans-serif; font-size: 3rem; font-weight: 800; margin-bottom: 1rem; }
.section-header p { color: var(--text-muted); font-size: 1.1rem; }

/* * UPDATED: Enhanced Glass Card for a more "Liquid" feel 
 */
.glass-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.06) 0%, rgba(255,255,255,0.02) 100%);
    border: 1px solid var(--glass-border); 
    padding: 2.5rem; 
    border-radius: 24px;
    backdrop-filter: blur(30px); /* Deeper Blur */
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1); /* Smoother, fluid transition */
}
.glass-card:hover { 
    border-color: var(--primary); 
    transform: translateY(-5px) scale(1.005); 
    /* UPDATED: Primary color glow on hover (Goldish-Orange) */
    box-shadow: 0 10px 60px -10px rgba(220, 20, 60, 0.6); 
    border-radius: 28px; /* Subtle shape shift on hover for fluidity */
}

/* * NEW CLASS: For elements that need a continuous, liquid-like pulsing glow 
 * Apply this class (.liquid-glass-glow) to any card you want to emphasize.
 */
.liquid-glass-glow {
    box-shadow: 0 0 15px var(--primary-glow) inset, 0 0 15px var(--primary-glow);
    animation: liquid-pulse 4s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- HOME HERO SPECIFIC --- */
.hero {
    min-height: auto; /* Changed from 80vh to auto */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 130px 2rem 40px 2rem; /* Added more top padding for navbar (+30px total) */
    overflow: visible;
}
.hero-badge {
    /* UPDATED: Goldish-Orange badge background and border */
    background: rgba(220, 20, 60, 0.15); border: 1px solid rgba(220, 20, 60, 0.3);
    color: var(--primary); padding: 0.5rem 1rem; border-radius: 50px;
    font-size: 0.85rem; font-weight: 700; margin-bottom: 1.5rem;
    text-transform: uppercase; letter-spacing: 1px; animation: pulse 2s infinite;
    display: inline-block;
}
.hero h1 {
    font-family: 'Outfit', sans-serif; font-size: clamp(3rem, 7vw, 5.5rem);
    font-weight: 800; line-height: 1.1; margin-bottom: 1.5rem;
    background: linear-gradient(180deg, #fff 0%, #cccccc 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.hero h1 span {
    /* UPDATED: Red gradient for accent text */
    background: linear-gradient(135deg, #ff3333 0%, #d44a4a 100%); 
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.hero p { font-size: 1.25rem; color: var(--text-muted); max-width: 600px; margin-bottom: 3rem; }
.cta-group { display: flex; gap: 1.5rem; flex-wrap: wrap; justify-content: center; }
.btn {
    padding: 1rem 2.5rem; border-radius: 12px; font-weight: 700; text-decoration: none;
    transition: all 0.3s ease; display: flex; align-items: center; gap: 10px; font-family: 'Outfit', sans-serif;
}
.btn-primary { 
    background: var(--primary); color: white; 
    /* UPDATED: Goldish-Orange box shadow */
    box-shadow: 0 0 30px rgba(220, 20, 60, 0.3); 
}
.btn-primary:hover { 
    transform: translateY(-3px); 
    /* UPDATED: Goldish-Orange box shadow on hover */
    box-shadow: 0 0 50px rgba(220, 20, 60, 0.5); 
}
.btn-secondary { background: rgba(255, 255, 255, 0.05); border: 1px solid var(--glass-border); color: white; backdrop-filter: blur(10px); }
.btn-secondary:hover { background: rgba(255, 255, 255, 0.1); border-color: white; }

/* --- HOME WIDGETS --- */
.ip-widget {
    margin-top: 3rem; background: rgba(0,0,0,0.4); border: 1px solid var(--glass-border);
    padding: 0.8rem 1.5rem; border-radius: 16px; display: flex; align-items: center; gap: 1rem; backdrop-filter: blur(10px);
}
.ip-text { font-family: 'Inter', monospace; color: var(--primary); font-size: 1.1rem; font-weight: 600; }
.copy-btn {
    background: var(--glass-border); border: none; color: white; padding: 0.5rem 1rem;
    border-radius: 8px; cursor: pointer; font-weight: 600; transition: all 0.2s; font-family: 'Inter', sans-serif;
}
.copy-btn:hover { background: white; color: black; }
.copy-btn.copied { background: #10b981; color: white; }
.stat-number { font-size: 3.5rem; font-weight: 800; color: var(--primary); font-family: 'Outfit', sans-serif; line-height: 1; margin-bottom: 0.5rem; display: block; }
.feature-icon { 
    font-size: 3rem; margin-bottom: 1.5rem; 
    /* UPDATED: Goldish-Orange gradient for icon */
    background: linear-gradient(135deg, var(--primary), #fff); 
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; 
    /* UPDATED: Goldish-Orange drop shadow for icon */
    filter: drop-shadow(0 0 20px rgba(220, 20, 60, 0.4)); 
}
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.glass-card h3 { font-family: 'Outfit', sans-serif; font-size: 1.5rem; margin-bottom: 1rem; color: white; }

/* --- STAFF SPECIFIC --- */
.staff-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2rem; }
.staff-card { display: flex; flex-direction: column; align-items: center; text-align: center; }
.avatar {
    width: 120px; height: 120px; background: #111; border-radius: 50%;
    margin-bottom: 1.5rem; display: flex; align-items: center; justify-content: center;
    font-size: 3rem; border: 2px solid var(--primary);
    /* UPDATED: Goldish-Orange box shadow */
    box-shadow: 0 0 20px rgba(220, 20, 60, 0.2); position: relative; overflow: hidden;
}
.role-badge { display: inline-block; padding: 0.4rem 1rem; border-radius: 50px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase; margin-bottom: 1rem; letter-spacing: 0.5px; }
/* UPDATED: Owner role to use red */
.role-owner { background: rgba(255, 0, 0, 0.2); color: #ff3333; border: 1px solid rgba(255,0,0,0.4); }
.role-admin { background: rgba(255, 0, 0, 0.2); color: #ff4444; border: 1px solid rgba(255,0,0,0.3); }
.role-mod { background: rgba(255, 165, 0, 0.2); color: #ffa500; border: 1px solid rgba(255,165,0,0.3); }

/* --- RULES SPECIFIC --- */
.rules-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; max-width: 900px; margin: 0 auto; }
.rule-item { display: flex; gap: 1.5rem; align-items: flex-start; }
.rule-number {
    font-family: 'Outfit', sans-serif; font-size: 3rem; font-weight: 800;
    color: var(--primary); line-height: 1; opacity: 0.4; min-width: 60px;
}
.rule-content h3 { font-family: 'Outfit', sans-serif; font-size: 1.5rem; margin-bottom: 0.5rem; color: white; }

/* --- CHANGELOG SPECIFIC --- */
.changelog-grid { display: grid; grid-template-columns: 1fr; gap: 1.5rem; max-width: 800px; margin: 0 auto; }
.changelog-entry .changelog-summary { cursor: pointer; padding: 0.5rem 0; }
.changelog-entry .changelog-summary h3 {
    font-family: 'Outfit', sans-serif; font-size: 1.5rem; margin-bottom: 0.5rem; 
    color: var(--primary); border-bottom: 1px solid transparent; transition: border-bottom 0.3s;
}
.changelog-entry .changelog-summary:hover h3 { border-bottom: 1px solid var(--primary); }
.changelog-entry .click-to-view { font-size: 0.9rem; color: var(--primary); opacity: 0.8; }
.changelog-entry .changelog-details { 
    max-height: 0; overflow: hidden; 
    transition: max-height 0.3s ease-in-out, padding-top 0.3s ease-in-out; 
    padding-top: 0;
}
.changelog-entry .changelog-details.visible { max-height: 500px; padding-top: 1rem; }
.changelog-entry ul { list-style: none; padding-left: 0; }
.changelog-entry ul li { padding-left: 1.5rem; position: relative; margin-bottom: 0.75rem; color: var(--text-main); }
.changelog-entry ul li::before {
    content: '•'; color: var(--primary); font-size: 1.5rem; line-height: 1;
    position: absolute; left: 0; top: 2px;
}

/* --- FOOTER & ANIMATIONS --- */
footer { padding: 4rem 2rem; background: transparent; margin-top: 4rem; }
.footer-content { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2rem; }
.social-links { display: flex; align-items: center; gap: 1.5rem; }
.social-links a { color: var(--text-muted); font-size: 1.1rem; text-decoration: none; transition: color 0.3s; display: flex; align-items: center; }
.social-links a:hover { color: var(--primary); }

/* UPDATED: Pulse Animation (now goldish-orange) */
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(220, 20, 60, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(220, 20, 60, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 20, 60, 0); }
}

/* UPDATED: Liquid Pulse Animation (now red) */
@keyframes liquid-pulse {
    0% { box-shadow: 0 0 15px rgba(220, 20, 60, 0.4) inset, 0 0 15px rgba(220, 20, 60, 0.4); }
    50% { box-shadow: 0 0 25px rgba(255, 80, 80, 0.6) inset, 0 0 25px rgba(255, 80, 80, 0.6); } /* Lighter red for 50% */
    100% { box-shadow: 0 0 15px rgba(220, 20, 60, 0.4) inset, 0 0 15px rgba(220, 20, 60, 0.4); }
}

.fade-in { opacity: 0; transform: translateY(30px); transition: all 0.8s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 768px) {
    .hero h1 { font-size: 3rem; }
    .cta-group { flex-direction: column; width: 100%; }
    .ip-widget { flex-direction: column; width: 100%; }
    .rules-grid { padding: 0 1rem; }
    .rule-item { flex-direction: column; gap: 0.5rem; }
}

/* --- PAGE TRANSITION (CYBER WARP EFFECT) --- */

/* Base transition properties on the page content wrapper */
#page-content { 
    width: 100%; 
    
    transition: 
        transform 0.4s cubic-bezier(0.86, 0, 0.07, 1), 
        opacity 0.4s ease-out; 
    
    transform-origin: center center;
    /* Enable 3D transforms */
    perspective: 1000px;
    backface-visibility: hidden;
    position: relative; 
}

/* 1. WARP OUT (Outgoing Page) */
.warp-out {
    transform: translateX(calc(var(--warp-direction) * -100px));
    opacity: 0;
}

/* 2. WARP IN (Incoming Page - Initial State) */
.warp-in {
    transform: translateX(calc(var(--warp-direction) * 100px));
    opacity: 0;
}

/* --- HAMBURGER MENU STYLES (FIXED) --- */
.nav-toggle {
    display: none; /* Hidden on desktop */
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 10px; 
    z-index: 2000; /* Ensure it's on top */
    position: relative; 
}

.hamburger-line {
    pointer-events: none; /* Ensure clicks hit the button, not the line */
    display: block;
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 5px 0;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* Mobile View Settings */
@media (max-width: 768px) {
    /* Show the button */
    .nav-toggle {
        display: block; 
    }

    /* Override old CSS and set up the sliding menu */
    .nav-links {
        display: flex !important; /* Force visibility for slide-in */
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(5, 5, 5, 0.98); 
        backdrop-filter: blur(15px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 2rem;
        
        transform: translateX(100%); /* Hidden off-screen to the right */
        transition: transform 0.4s cubic-bezier(0.86, 0, 0.07, 1);
        z-index: 1999;
    }

    /* Class added by JS to show menu */
    .nav-links.mobile-open {
        transform: translateX(0);
    }

    /* Hamburger Animation to 'X' */
    .nav-toggle.open .hamburger-line:nth-child(1) {
        transform: rotate(45deg) translate(5px, 6px);
    }
    .nav-toggle.open .hamburger-line:nth-child(2) {
        opacity: 0;
    }
    .nav-toggle.open .hamburger-line:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -6px);
    }
}

/* --- THEME TOGGLE STYLES --- */
.theme-toggle {
    background: transparent;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 1rem;
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    box-shadow: 0 0 15px var(--primary-glow);
}

.theme-icon {
    width: 20px;
    height: 20px;
    stroke: var(--text-main);
    stroke-width: 2;
    transition: all 0.3s ease;
}

.theme-toggle:hover .theme-icon {
    stroke: var(--primary);
}

/* Light theme variables */
body.light-theme {
    --bg-dark: #f8f9fa;
    --text-main: #212529;
    --text-muted: #6c757d;
    --glass-border: rgba(0, 0, 0, 0.1);
    --primary-glow: rgba(220, 20, 60, 0.3);
}

body.light-theme #canvas-container {
    background: radial-gradient(circle at center, #e9ecef 0%, #f8f9fa 100%);
}

body.light-theme .navbar.scrolled {
    background: rgba(248, 249, 250, 0.85);
}

body.light-theme .nav-links a {
    color: var(--text-muted);
}

body.light-theme .nav-links a:hover {
    color: var(--text-main);
}

body.light-theme .nav-links a.active {
    color: var(--text-main);
}

body.light-theme .nav-btn {
    background: rgba(0, 0, 0, 0.05);
    border-color: var(--glass-border);
    color: var(--text-main) !important;
}

body.light-theme .nav-btn:hover {
    background: var(--primary);
    color: white !important;
}

body.light-theme .glass-card {
    background: linear-gradient(145deg, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0.4) 100%);
}

body.light-theme .logo-img {
    filter: none;
}

/* --- 404 ERROR PAGE --- */
.error-404 {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.error-content {
    text-align: center;
    max-width: 600px;
}

.error-code {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    position: relative;
}

.code-main {
    font-size: 8rem;
    font-weight: 900;
    font-family: 'Outfit', sans-serif;
    background: linear-gradient(45deg, var(--primary), #E6A85C);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.1em;
    line-height: 1;
}

.code-middle {
    margin: 0 1rem;
    position: relative;
}

.code-particle {
    font-size: 6rem;
    font-weight: 900;
    color: var(--primary);
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.error-title {
    font-size: 2.5rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--text-main), var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.error-description {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.error-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.error-actions .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.error-actions .btn-primary {
    background: var(--primary);
    color: white;
    border: 2px solid var(--primary);
}

.error-actions .btn-primary:hover {
    background: transparent;
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(220, 20, 60, 0.3);
}

.error-actions .btn-secondary {
    background: transparent;
    color: var(--text-main);
    border: 2px solid var(--glass-border);
}

.error-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

/* --- High-end Page Transition Overlay --- */
#page-transition-overlay {
    position: fixed; inset: 0; pointer-events: none; z-index: 3000;
    --ox: 50vw; --oy: 50vh; /* origin */
}
#page-transition-overlay .overlay-shape {
    position: absolute; left: 0; top: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at var(--ox) var(--oy), rgba(220, 20, 60, 0.18) 0%, rgba(220, 20, 60, 0.08) 10%, rgba(0,0,0,0.85) 35%);
    backdrop-filter: blur(6px) saturate(140%);
    clip-path: circle(0px at var(--ox) var(--oy));
    transform: translateZ(0);
    transition: clip-path 0.62s cubic-bezier(0.2, 0.9, 0.2, 1), opacity 0.4s ease;
}
#page-transition-overlay .overlay-shape.active-in {
    clip-path: circle(150% at var(--ox) var(--oy));
    opacity: 1;
}
#page-transition-overlay .overlay-shape.active-out {
    clip-path: circle(0px at var(--ox) var(--oy));
    opacity: 0;
}

/* Subtle inner sheen and scanning line for premium feel */
#page-transition-overlay .overlay-shine {
    position: absolute; inset: 0; pointer-events: none; mix-blend-mode: overlay;
    background: linear-gradient(90deg, rgba(255,255,255,0.02), rgba(255,255,255,0.06) 50%, rgba(255,255,255,0.02));
    opacity: 0; transform: translateX(-30%);
    transition: opacity 0.45s ease, transform 0.9s cubic-bezier(0.2,0.9,0.2,1);
}
#page-transition-overlay .overlay-shine.active {
    opacity: 1; transform: translateX(30%);
}

/* When overlay is active we slightly tilt the page wrapper for depth */
.page-tilt-active #page-content { transform: perspective(1200px) translateZ(-30px) rotateX(2deg) scale(0.995); filter: blur(0.6px); }

@media (prefers-reduced-motion: reduce) {
    #page-transition-overlay .overlay-shape,
    #page-transition-overlay .overlay-shine { transition: none; }
}

/* --- Smooth Scale Transitions for Premium Zoom Effect --- */
#page-content.transition-scale {
    transform-origin: center center;
    transition: transform 0.6s cubic-bezier(0.22, 0.9, 0.22, 1), opacity 0.32s ease, filter 0.4s ease;
}
#page-content.scale-out { transform: scale(0.92) translateZ(0); opacity: 0.96; filter: blur(0.6px); }
#page-content.scale-in { transform: scale(1) translateZ(0); opacity: 1; filter: none; }

@media (prefers-reduced-motion: reduce) {
    #page-content.transition-scale { transition: none; }
}

.error-suggestions {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 2rem;
    backdrop-filter: blur(20px);
}

.error-suggestions h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.error-suggestions ul {
    list-style: none;
    padding: 0;
}

.error-suggestions li {
    margin-bottom: 0.5rem;
}

.error-suggestions a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-block;
}

.error-suggestions a:hover {
    color: var(--primary);
    text-decoration: underline;
}

/* Mobile responsiveness for 404 page */
@media (max-width: 768px) {
    .error-code {
        flex-direction: column;
        gap: 1rem;
    }

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

    .code-particle {
        font-size: 4rem;
    }

    .error-title {
        font-size: 2rem;
    }

    .error-actions {
        flex-direction: column;
        align-items: center;
    }

    .error-actions .btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
}

/* 404 Specific Styling */
.error-404 {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 100px 20px;
    background: #1a1410; /* Dark warm base */
    color: #ffffff;
    text-align: center;
}

.error-code {
    font-size: clamp(8rem, 20vw, 15rem);
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    color: #ff3333; /* Red glow */
    text-shadow: 0 0 20px rgba(220, 20, 60, 0.5);
}

.code-particle {
    color: #ff3333;
    animation: pulse 2s infinite;
}

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

/* Glitch container */
.glitch {
    position: relative;
    display: inline-block;
    color: #fff; /* Base color */
}

/* Creating the ghost layers */
.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

/* Gold ghost layer (shaping the left side) */
.glitch::before {
    left: 2px;
    text-shadow: -2px 0 #ff3333; 
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

/* Cyan ghost layer (shaping the right side) */
.glitch::after {
    left: -2px;
    text-shadow: -2px 0 #99CCFF;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 2s infinite linear alternate-reverse;
}

/* The actual "Slicing" animation */
@keyframes glitch-anim {
    0% { clip: rect(31px, 9999px, 94px, 0); }
    10% { clip: rect(70px, 9999px, 71px, 0); }
    20% { clip: rect(29px, 9999px, 83px, 0); }
    30% { clip: rect(16px, 9999px, 91px, 0); }
    40% { clip: rect(2px, 9999px, 23px, 0); }
    50% { clip: rect(67px, 9999px, 40px, 0); }
    60% { clip: rect(56px, 9999px, 98px, 0); }
    70% { clip: rect(89px, 9999px, 6px, 0); }
    80% { clip: rect(27px, 9999px, 53px, 0); }
    90% { clip: rect(44px, 9999px, 94px, 0); }
    100% { clip: rect(9px, 9999px, 11px, 0); }
}

/* Minecraft Portal-style pulse for the "0" */
.code-particle {
    display: inline-block;
    animation: portal-pulse 2s ease-in-out infinite;
    text-shadow: 0 0 20px #ff3333;
}

@keyframes portal-pulse {
    0%, 100% { transform: scale(1); filter: brightness(1); }
    50% { transform: scale(1.15); filter: brightness(1.5); }
}