/* --- Global Variables (Halo Red vs Blue Theme) --- */
:root {
    --bg-main: #0a0d14;         /* Dark, metallic sci-fi background */
    --bg-nav: #05070a;          /* Deeper matte black for nav/footer */
    --bg-card: #121824;         /* Steel-toned card background */
    
    /* Team Colors */
    --accent-red: #dc2626;      /* Crimson Red (Primary Accent for buttons/headers) */
    --accent-red-hover: #b91c1c;/* Darker red for active button states */
    --accent-blue: #2563eb;     /* Cobalt Blue (Secondary Accent for logins/highlights) */
    --accent-blue-hover: #1d4ed8;/* Darker blue for secondary hover states */
    
    /* Text Hierarchy */
    --text-main: #f3f4f6;       /* Crisp off-white */
    --text-muted: #9ca3af;     /* Visor-gray for secondary text */
}

/* --- Base Reset --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: var(--text-main);
}

/* --- Navigation --- */
.navbar {
    display: flex;
    justify-content: center; 
    align-items: center;
    padding: 1.5rem 5%;
    
    /* RETAINED: Sleek, high-tech slanted stripes texture */
    background-color: var(--bg-nav);
    background-image: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 4px,
        rgba(255, 255, 255, 0.03) 4px,
        rgba(255, 255, 255, 0.03) 8px
    );
    
    border-bottom: 2px solid var(--bg-card);
}

/* REFACTORED: Stretches the inner wrapper to full width to allow left/center/right alignment */
.navbar-content-wrapper {
    display: flex;
    align-items: center;
    width: 100%;
    position: relative; /* Allows absolute mathematical centering of the main links */
}

.logo {
    /* Anchored to the left naturally */
    margin-right: 0; 
}

.logo h2 {
    color: var(--text-main);
    letter-spacing: 2px;
    white-space: nowrap;
}

.logo h2 span {
    color: var(--accent-red);
}

/* NEW: Mathematically locks the core navigation exactly in the center of the page */
.nav-links-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    list-style: none;
    display: flex;
    gap: 2rem; 
    align-items: center;
    margin: 0;
    padding: 0;
}

/* NEW: Pushes the admin/login controls flush against the right side of the navbar */
.nav-links-right {
    margin-left: auto;
    list-style: none;
    display: flex;
    gap: 1.5rem; 
    align-items: center;
    margin-top: 0;
    margin-bottom: 0;
    padding: 0;
}

/* Consolidated Anchor Tag & Icon Base Styling for BOTH lists */
.nav-links-center a,
.nav-links-right a {
    font-size: 1.3rem; 
    color: var(--text-main);
    transition: color 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

/* Icon Hover Effect */
.nav-links-center a:hover,
.nav-links-right a:hover {
    color: var(--accent-red);
    transform: translateY(-2px);
}

/* NEW: Premium Tactical Text Style for the Admin Button */
.nav-admin-text-link {
    font-size: 0.75rem !important; /* Overrides the larger global icon font-size */
    font-weight: 800;
    letter-spacing: 1.5px;
    color: var(--accent-red) !important;
    text-decoration: none;
    padding: 0.4rem 0.8rem;
    border: 1px solid rgba(220, 38, 38, 0.2);
    border-radius: 2px;
    background-color: rgba(220, 38, 38, 0.02);
    transition: all 0.3s ease !important;
}

.nav-admin-text-link:hover {
    background-color: var(--accent-red) !important;
    color: #05070a !important; /* Dark text fallback to contrast with the bright background background */
    border-color: var(--accent-red) !important;
    box-shadow: 0 0 10px rgba(220, 38, 38, 0.4);
    transform: translateY(-2px);
}

/* Login/Logout Button Layout Adjustments for Icons */
.btn-login.icon-btn {
    border: 1px solid var(--accent-blue);
    padding: 0.5rem 0.75rem; 
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Distinct Button Hover Style - keeps its signature blue accent glow */
.btn-login.icon-btn:hover {
    background-color: var(--accent-blue);
    color: #fff !important;
    box-shadow: 0 0 10px rgba(37, 99, 235, 0.5);
    transform: translateY(0) !important; /* Prevents double elevation tracking */
}

/* --- Administrative Control Panel Links & Dropdowns --- */

/* Base Text-Link Console Style for ADMIN and NEWS CP */
.nav-cp-text-link {
    font-size: 0.75rem !important;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-decoration: none;
    padding: 0.4rem 0.8rem;
    border-radius: 2px;
    transition: all 0.3s ease !important;
}

/* ADMIN Button Theme color (Red) */
.admin-color {
    color: var(--accent-red) !important;
    border: 1px solid rgba(220, 38, 38, 0.2);
    background-color: rgba(220, 38, 38, 0.02);
}
.admin-color:hover {
    background-color: var(--accent-red) !important;
    color: #05070a !important;
    border-color: var(--accent-red) !important;
    box-shadow: 0 0 10px rgba(220, 38, 38, 0.4);
    transform: translateY(-2px);
}

/* NEWS CP Button Theme color (Orange/Yellow) */
.news-color {
    color: #ff9f43 !important;
    border: 1px solid rgba(255, 159, 67, 0.2);
    background-color: rgba(255, 159, 67, 0.02);
}
.news-color:hover {
    background-color: #ff9f43 !important;
    color: #05070a !important;
    border-color: #ff9f43 !important;
    box-shadow: 0 0 10px rgba(255, 159, 67, 0.4);
    transform: translateY(-2px);
}

/* --- Squad Dropdown Component Matrix --- */
.nav-dropdown-wrapper {
    position: relative;
    display: inline-block;
}

.nav-cp-dropdown {
    /* Completely strips the browser's ugly default dropdown arrow rendering */
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    
    font-family: inherit;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    color: var(--accent-blue, #00d2ff) !important;
    background-color: rgba(0, 210, 255, 0.02);
    border: 1px solid rgba(0, 210, 255, 0.2);
    border-radius: 2px;
    padding: 0.4rem 2rem 0.4rem 0.8rem; /* Extra padding on the right to leave safe room for our chevron font icon */
    cursor: pointer;
    outline: none;
    transition: all 0.3s ease;
}

/* Dropdown Hover State Matching the Blue Glow Framework Rules */
.nav-cp-dropdown:hover {
    background-color: rgba(0, 210, 255, 0.05);
    border-color: var(--accent-blue, #00d2ff);
    box-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

/* Styles the expanded option list container box natively */
.nav-cp-dropdown option {
    background-color: var(--bg-nav, #0a0f1a); /* Prevents the desktop browser from rendering a bright white option background box */
    color: var(--text-main, #ffffff);
    font-weight: 600;
    letter-spacing: 1px;
    padding: 0.6rem;
}

/* Forces disabled placeholder strings to stay muted and clean inside the expanded container panel options */
.nav-cp-dropdown option:disabled {
    color: var(--text-muted, #888);
    opacity: 0.5;
}

/* Absolute positioned placement indicator arrow matching the accent system framework layout colors */
.dropdown-arrow-hint {
    position: absolute;
    right: 0.8rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-blue, #00d2ff);
    font-size: 0.65rem;
    pointer-events: none; /* Clicking directly on the arrow passes the target action to the interactive select wrapper underneath */
}

/* ==========================================================================
   RESPONSIVE MOBILE OVERRIDES (Mobile Breakpoint)
   ========================================================================== */

/* Toggle Button Setup for Desktop */
.hamburger-label {
    display: none;
    cursor: pointer;
    color: var(--text-main, #ffffff);
    font-size: 1.5rem;
    user-select: none;
    padding: 0.5rem;
    z-index: 1010;
}

@media screen and (max-width: 992px) {
    .navbar {
        padding: 0.5rem 5%; 
    }

    .hamburger-label {
        display: block;
        margin-left: auto; /* Aligns menu button to the far right side */
    }

    /* FULL-SCREEN OVERLAY DIMMING MASK */
    .nav-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background-color: rgba(0, 0, 0, 0.75); /* Dark dimming */
        backdrop-filter: blur(3px); /* Elegant layout blur behind drawer */
        z-index: 1001;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease, visibility 0.3s ease;
        pointer-events: none;
    }

    /* Activates backdrop tint when active class is triggered */
    .nav-overlay.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    /* UNIFIED DRAWER CONFIGURATION: Syncs both navigation blocks */
    .nav-links-center,
    .nav-links-right {
        position: fixed;
        right: -320px; /* Hidden completely off-screen by default */
        width: 280px; 
        background-color: #05070a; /* REVERTED: Matches your deep, regular navbar color */
        border-left: 1px solid rgba(255, 255, 255, 0.05);
        
        /* Tactical background striping pattern */
        background-image: repeating-linear-gradient(
            -45deg,
            transparent,
            transparent 4px,
            rgba(255, 255, 255, 0.03) 4px,
            rgba(255, 255, 255, 0.03) 8px
        );
        
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
        align-items: center;
        padding: 2.5rem 1.5rem;
        box-sizing: border-box;
        transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease;
        z-index: 1005;
    }

    /* Slides the drawer panels smoothly onto the screen */
    .nav-links-center.active,
    .nav-links-right.active {
        right: 0;
    }

    /* UPPER SECTION NAVIGATION LIST */
    .nav-links-center {
        top: 0;
        height: 55vh; /* Upper 55% of the side view */
        border-bottom: 1px solid rgba(255, 255, 255, 0.03);
        transform: none; /* Resets desktop transform alignment */
        left: auto;
    }

    /* LOWER SECTION CONTROL CONTROLS LIST */
    .nav-links-right {
        top: 55vh; /* Upper section hand-off boundary line */
        height: 45vh; /* Lower 45% of the side view */
        z-index: 1004;
        margin-left: 0;
        padding-top: 0;
    }

    .nav-links-center li,
    .nav-links-right li {
        width: 100%;
        text-align: center;
    }

    .nav-links-center a,
    .nav-links-right a {
        display: inline-block;
        font-size: 1.4rem;
    }

    .nav-dropdown-wrapper {
        display: inline-block;
        width: 100%;
        max-width: 160px;
    }
    
    .nav-cp-dropdown {
        width: 100%;
        text-align: center;
    }
}

/* --- Live News Ticker --- */
.news-ticker-container {
    width: 100%;
    background-color: var(--bg-nav); /* Keeps the top bar matched with your navigation theme */
    border-bottom: 2px solid var(--bg-card); /* Sharp metallic divider line */
    overflow: hidden; /* Conceals the text when it loops off-screen */
    box-sizing: border-box;
    padding: 0.5rem 0;
}

.ticker-wrap {
    width: 100%;
    overflow: hidden;
    white-space: nowrap; /* Forces the text to stay on a single horizontal line */
    display: flex;
}

.ticker-move {
    display: inline-flex;
    padding-left: 100%; /* Starts the animation safely off the right side of the screen */
    animation: ticker-crawl 175s linear infinite; /* Loops smoothly and endlessly */
}

/* Pause the crawl if a player hovers over it to read closely */
.ticker-move:hover {
    animation-play-state: paused;
}

.ticker-item {
    display: inline-block;
    padding-right: 4rem; /* Generates a clean gap between the repeating messages */
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--accent-red); /* Hype Crimson Red text color */
    text-shadow: 0 0 10px rgba(220, 38, 38, 0.2); /* Subtle sci-fi energy glow */
}

/* Pure CSS Keyframe Animation handling the horizontal crawl */
@keyframes ticker-crawl {
    0% {
        transform: translate3d(0, 0, 0);
    }
    100% {
        transform: translate3d(-100%, 0, 0);
    }
}

/* --- Hero Section --- */
.hero {
    background: url('/assets/imgs/hero.jpg') no-repeat center center / cover;
    height: 80vh; /* Changed from 70vh to give the image a bit more room */
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    position: relative; /* Required for the dark overlay */
}

/* New: The dark overlay to make your text pop */
.hero::before {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6); 
}

/* New: Keeps the text above the dark overlay */
.hero-content {
    position: relative;
    z-index: 1;
}

/* --- Hero Logo Styling --- */
.hero-logo {
    max-width: 150px; /* Adjust this number to make the logo larger or smaller */
    height: auto;
    display: block;
    margin: 0 auto 1.5rem auto; /* Centers horizontally and creates space below it */
    filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.5)); /* Adds depth against the background image */
}

/* Keep all of your existing classes exactly as they are below this line! */
.est-text {
    color: var(--accent-blue);
    font-weight: bold;
    letter-spacing: 3px;
    margin-bottom: 1rem;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #ffffff; /* Added to ensure the heading stays white */
}

.highlight {
    color: var(--accent-red);
    text-shadow: 0 0 15px rgba(220, 38, 38, 0.3);
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem auto;
}

.btn-primary {
    display: inline-block;
    background-color: var(--accent-red);
    color: #fff;
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
    font-weight: bold;
    border-radius: 4px;
    transition: 0.3s;
}

.btn-primary:hover {
    background-color: var(--accent-red-hover);
    box-shadow: 0 0 15px rgba(220, 38, 38, 0.5);
}


/* --- News Grid Section --- */
.news-section {
    width: 100%;
    background-color: #ffffff; /* White background for the article display blocks */
}

/* New: Top Header Bar styled with Crimson Red */
.news-header-bar {
    background-color: var(--accent-red);
    padding: 1rem 5%;
    text-align: left;
    border-bottom: 2px solid var(--bg-card);
}

.news-header-bar h2 {
    color: #ffffff !important;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin: 0;
}

.news-grid {
    display: grid;
    grid-template-columns: 1fr; /* Mobile view: single column */
    grid-auto-rows: 400px;
}

/* Desktop View */
@media (min-width: 900px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr); /* 3 Equal Columns */
        grid-auto-rows: 350px; /* Fixed height for each row */
    }
    
    .news-card.featured {
        grid-column: span 1;
        grid-row: span 2; /* Makes the first card stretch down two rows */
    }
}

.news-card {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    text-decoration: none;
    padding: 2rem;
    transition: transform 0.3s ease;
    overflow: hidden;
}

.news-card:hover {
    transform: scale(0.98);
}

.text-card {
    background-color: #ffffff;
    justify-content: center; /* Centers text vertically */
}

.card-content {
    position: relative;
    z-index: 2;
}

.tag {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 800;
    margin-bottom: 10px;
}

.tag-yellow { color: #facc15; }
.tag-green { color: #4ade80; }

.news-card h2 {
    color: #ffffff;
    font-size: 2.5rem;
    text-transform: uppercase;
    line-height: 1.1;
    margin-bottom: 10px;
}

.text-card h3 {
    color: #111827; /* Dark text for white background */
    font-size: 1.5rem;
    text-transform: uppercase;
    line-height: 1.2;
    margin-bottom: 10px;
}

.date {
    display: block;
    font-size: 0.8rem;
    font-weight: bold;
    color: #ffffff;
    margin-bottom: 15px;
}

.date-dark {
    color: #6b7280; /* Darker date for white background */
}

.text-card p {
    color: #4b5563;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* New: Bottom Bar Container */
.news-footer-bar {
    background-color: var(--bg-nav); /* Uses the deeper matte black to match your site layout */
    padding: 2rem 0;
    text-align: center;
    border-top: 2px solid var(--bg-card);
}

/* New: Styled Plain Link Button for More Articles */
.more-articles-btn {
    display: inline-block;
    color: var(--text-main);
    font-size: 1.1rem;
    font-weight: bold;
    letter-spacing: 2px;
    text-transform: uppercase;
    padding: 0.75rem 2rem;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

/* Clean, subtle hover transition */
.more-articles-btn:hover {
    color: var(--accent-blue); /* Highlights to Cobalt Blue when hovered */
    letter-spacing: 4px; /* Subtle modern expansion effect */
}

/* --- Full-Width Modern Esports Layout --- */
.esports-about-fullwidth {
    width: 100%;
    background-color: var(--bg-nav); /* Uses deeper matte black background to mesh perfectly */
    border-top: 2px solid var(--bg-card);
    border-bottom: 2px solid var(--bg-card);
    padding: 0 0 4rem 0;
    overflow: hidden;
}

/* Full Bleed Track: Spans edge-to-edge identical to your news feed */
.esports-modern-track {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    width: 100%;
    gap: 2px; /* Super thin high-tech separation line */
    background-color: var(--bg-card); /* Creates the sleek separator gap line dynamically */
}

/* Elite Modern Panel Dashboard Block */
.modern-panel {
    position: relative;
    background-color: rgba(10, 15, 26, 0.98);
    padding: 4rem 3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 360px;
    width: 100%;
    max-width: 420px;
    transition: background-color 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Scanner Bar Animation tracking on hover */
.panel-scanner-line {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 3px;
    background: var(--accent-red, #ef4444);
    opacity: 0.3;
    transition: all 0.4s ease;
}

/* Tech Strings */
.system-string {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent-red, #ef4444);
    letter-spacing: 3px;
    display: block;
    margin-bottom: 0.5rem;
}

.modern-panel h3 {
    font-size: 1.5rem;
    color: #fff;
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin: 0;
}

/* High-readability Clean Modern Text Layout */
.panel-body-text p {
    color: #9ca3af;
    font-size: 1rem;
    line-height: 1.75;
    margin: 1.5rem 0 2.5rem 0;
}

/* Digital System Status Tags */
.panel-status-tag {
    align-self: flex-start;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 2px;
    padding: 0.35rem 0.85rem;
    border-radius: 2px;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
}

/* ================= PREMIER INTERACTIVE HOVER MATRIX ================= */

.modern-panel:hover {
    background-color: rgba(17, 24, 39, 0.6); /* Blends dark tint slightly lighter on focus */
    z-index: 5;
}

.modern-panel:hover .panel-scanner-line {
    width: 6px;
    opacity: 1;
    box-shadow: 0 0 15px var(--accent-red, #ef4444);
}

.modern-panel:hover .red-glow {
    background: rgba(239, 68, 68, 0.1);
    border-color: var(--accent-red, #ef4444);
    color: var(--accent-red, #ef4444);
    text-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
}

/* ================= ACTIVE BLUE SYSTEM PANEL OVERLAY (Center) ================= */

.modern-panel.active-modern-panel {
    background-color: rgba(13, 22, 41, 0.4); /* Built-in subtle blue matrix ambient hue */
}

.modern-panel.active-modern-panel .panel-scanner-line {
    background: var(--accent-blue, #00d2ff);
    opacity: 0.6;
}

.modern-panel.active-modern-panel .system-string {
    color: var(--accent-blue, #00d2ff);
}

/* Active Hover Responses */
.modern-panel.active-modern-panel:hover .panel-scanner-line {
    width: 6px;
    opacity: 1;
    box-shadow: 0 0 15px var(--accent-blue, #00d2ff);
}

.modern-panel.active-modern-panel:hover .blue-glow {
    background: rgba(0, 210, 255, 0.15);
    border-color: var(--accent-blue, #00d2ff);
    color: var(--accent-blue, #00d2ff);
    text-shadow: 0 0 8px rgba(0, 210, 255, 0.5);
}

/* --- FAQ Section Styling --- */
.faq-section {
    padding: 4rem 0;
    max-width: 1200px;
    margin: 0 auto;
    width: 90%;
}

.faq-container {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Individual Accordion Box */
.faq-item {
    background-color: var(--bg-card, #111827);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.faq-item:hover {
    border-color: var(--accent-blue, #00d2ff);
    box-shadow: 0 0 15px rgba(0, 210, 255, 0.1);
}

/* The Clickable Header Row */
.faq-item summary {
    padding: 1.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #fff;
    cursor: pointer;
    list-style: none; /* Hides default browser arrow */
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Webkit specific fix to hide default arrow */
.faq-item summary::-webkit-details-marker {
    display: none;
}

/* Custom indicator arrow using CSS pseudo-elements */
.faq-item summary::after {
    content: '➔';
    font-size: 0.9rem;
    color: var(--tag-yellow, #facc15);
    transition: transform 0.3s ease;
    transform: rotate(90deg); /* Points down by default */
}

/* Rotation effect when the accordion is active/open */
.faq-item[open] summary::after {
    transform: rotate(-90deg); /* Flips up when opened */
}

/* Inner Text Area */
.faq-content {
    padding: 0 1.5rem 1.5rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background-color: rgba(0, 0, 0, 0.2);
}

.faq-content p {
    color: #9ca3af; /* Soft grey text for readability */
    line-height: 1.6;
    font-size: 0.95rem;
    margin: 0;
    padding-top: 1rem;
}

/* --- FAQ Section Specific Header --- */
.faq-section .news-header-bar {
    border-left: 5px solid #00d2ff; /* Swaps the accent indicator to a sharp gaming blue */
    background: linear-gradient(to right, rgba(0, 210, 255, 0.15), transparent); /* Soft blue fade */
}

/* Optional: If you want the header text itself to lean into the blue accent theme */
.faq-section .news-header-bar h2 {
    color: #fff;
    text-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

/* --- NEWS Hub Layout Viewports --- */
.news-hub-container {
    width: 100%;
    background-color: var(--bg-nav, #0a0f1a);
    padding-bottom: 5rem;
}

/* Controls Dashboard Console Strip */
.hub-controls-panel {
    background-color: rgba(17, 24, 39, 0.4);
    border-bottom: 1px solid var(--bg-card, #1f2937);
    padding: 1.5rem 3rem; /* Aligns perfectly with full-width panel text pads */
    margin-bottom: 2px;
}

/* Full-width flush left flex matrix layout */
.controls-form {
    width: 100%;
    display: flex;
    justify-content: flex-start; /* Hard alignment completely to the left side */
    align-items: center;
    gap: 2.5rem; /* Evenly spaces the dropdown modules */
    flex-wrap: wrap;
}

/* Premium High-Tech Reset Button Element */
.hub-reset-btn {
    display: inline-block;
    text-decoration: none;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    padding: 0.55rem 1.2rem;
    border-radius: 2px;
    background-color: rgba(239, 68, 68, 0.05);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: var(--accent-red, #ef4444);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.hub-reset-btn i {
    margin-right: 6px;
    font-size: 0.8rem;
}

/* Active Hover Glow Matrix Response */
.hub-reset-btn:hover {
    background-color: var(--accent-red, #ef4444);
    color: #0a0f1a;
    border-color: var(--accent-red, #ef4444);
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.3);
    text-shadow: none;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.control-group label {
    font-size: 0.85rem;
    font-weight: 800;
    color: #a3a3c2;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.control-group label i {
    color: var(--accent-red, #ef4444);
    margin-right: 4px;
}

/* Custom Styled Dropdowns to match the tech theme */
.control-group select {
    background-color: #0a0f1a;
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #fff;
    padding: 0.5rem 2rem 0.5rem 1rem;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 2px;
    cursor: pointer;
    outline: none;
    transition: border-color 0.3s ease;
    -webkit-appearance: none; /* Strip standard windows styling */
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' fill='white'><polygon points='0,0 10,0 5,5'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
}

.control-group select:focus {
    border-color: var(--accent-blue, #00d2ff);
}

/* Clean Stream Fallback Layout */
.empty-stream-fallback {
    text-align: center;
    padding: 6rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    background: #0d1629;
}

.empty-stream-fallback i {
    font-size: 3rem;
    color: var(--accent-red, #ef4444);
    text-shadow: 0 0 15px rgba(239, 68, 68, 0.3);
}

.empty-stream-fallback p {
    color: #a3a3c2;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

/* ==========================================================================
   KSI.PRO - Global News Hub Styling
   ========================================================================== */

/* --- Media Hub Image Card Elements --- */
.hub-image-wrapper {
    width: 100%;
    height: 200px; /* Fixed tactical view box height */
    overflow: hidden;
    position: relative;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.hub-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Crops image uniformly without stretching aspect ratio */
    object-position: center;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Elite card zoom visual effect when hovering anywhere over the dashboard panel */
.modern-panel:hover .hub-card-img {
    transform: scale(1.06);
}

/* --- Modern Esports Pagination Bar --- */
.pagination-container {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 3rem 1rem; /* Added side padding to protect viewport limits */
    background-color: var(--bg-nav, #0a0f1a);
    box-sizing: border-box;
    overflow: hidden; /* Hard clip layout containment */
}

.pagination-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    list-style: none;
    gap: 0.5rem;
    padding: 0;
    margin: 0;
    flex-wrap: wrap; /* FIX: Allows buttons to break cleanly onto multiple lines on mobile instead of forcing horizontal overflow */
    max-width: 100%;
}

/* Base Style for every Pagination Button link */
.pagination-btn {
    display: block;
    text-decoration: none;
    background-color: rgba(17, 24, 39, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    color: #a3a3c2;
    font-weight: 700;
    font-size: 0.9rem;
    min-width: 42px;
    height: 42px;
    line-height: 40px; /* Aligns numeric text perfectly vertically */
    text-align: center;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ACTIVE PAGE MATRIX HIGHLIGHT (Cobalt Blue Cyber Outline) */
.pagination-btn.active-page-btn {
    background-color: rgba(0, 210, 255, 0.1) !important;
    border: 1px solid var(--accent-blue, #00d2ff) !important; /* Forces the cobalt blue outline */
    color: var(--accent-blue, #00d2ff) !important;
    text-shadow: 0 0 8px rgba(0, 210, 255, 0.6);
    box-shadow: inset 0 0 8px rgba(0, 210, 255, 0.2), 0 0 15px rgba(0, 210, 255, 0.3) !important; /* Outer glow outline effect */
    pointer-events: none; /* Prevents clicking the page you are already on */
}

/* Mobile Layout Tweaks: Scales down pagination button block sizes slightly for compact mobile grids */
@media (max-width: 480px) {
    .pagination-container {
        padding: 2rem 0.5rem;
    }
    .pagination-bar {
        gap: 0.35rem;
    }
    .pagination-btn {
        min-width: 36px;
        height: 36px;
        line-height: 34px;
        font-size: 0.8rem;
    }
}

/* Hover Response State */
.pagination-btn:hover {
    color: #fff;
    border-color: var(--accent-red, #ef4444);
    background-color: rgba(239, 68, 68, 0.05);
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.15);
}

/* Arrow Button specific padding overrides */
.pagination-btn.arrow-btn {
    font-size: 0.8rem;
    color: var(--accent-red, #ef4444);
}

.pagination-btn.arrow-btn:hover {
    background-color: var(--accent-red, #ef4444);
    color: #0a0f1a;
}

/* ACTIVE PAGE MATRIX HIGHLIGHT (Cobalt Blue Focus) */
.pagination-btn.active-page-btn {
    background-color: rgba(0, 210, 255, 0.1);
    border-color: var(--accent-blue, #00d2ff);
    color: var(--accent-blue, #00d2ff);
    text-shadow: 0 0 8px rgba(0, 210, 255, 0.4);
    box-shadow: inset 0 0 8px rgba(0, 210, 255, 0.1), 0 0 15px rgba(0, 210, 255, 0.15);
    pointer-events: none; /* Prevents clicking the active button */
}
/* --- High Performance Scroll Reveal Fade Matrices --- */
.news-hub-container .reveal-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

/* When your scroll script detects the element and injects the 'active' class */
.news-hub-container .reveal-on-scroll.active {
    opacity: 1;
    transform: translateY(0);
    transition-delay: var(--animation-delay, 0s); 
}

/* SAFE FALLBACK: If the page doesn't run the script or for the first row of articles */
.news-hub-container .esports-modern-track > div:nth-child(-n+3) {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ==========================================================================
   KSI.PRO - Global News Hub Content Wrapper Spacing Fix
   ========================================================================== */

/* Safely targets and collapses the container gap on Article, CP, and Editor views */
.public-article-view-page ~ .news-hub-container,
.cp-view-page ~ .news-hub-container,
.editor-view-page ~ .news-hub-container,
.news-hub-container:has(+ .public-article-view-page),
.news-hub-container:has(+ .cp-view-page),
.news-hub-container:has(+ .editor-view-page) {
    height: auto !important;
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
}

.news-hub-container:has(+ .public-article-view-page) .news-header-bar,
.news-hub-container:has(+ .cp-view-page) .news-header-bar,
.news-hub-container:has(+ .editor-view-page) .news-header-bar {
    margin-bottom: 0 !important;
    padding-bottom: 15px !important;
}

/* Normalizes the spacing layout below the collapsed bar for back-end panels */
.cp-view-page .ksi-admin-wrapper,
.editor-view-page .ksi-editor-wrapper {
    margin-top: 30px !important;
}

/* ==========================================================================
   KSI.PRO - Public Article View Structural Styles
   ========================================================================== */

/* Article Page Layout Structure */
.public-article-view-page {
    width: 100%;
    margin: 0 auto;
    padding-top: 30px; 
    padding-bottom: 60px;
}

.public-article-view-page .article-viewer-container { 
    max-width: 900px; 
    margin: 0 auto; 
    padding: 0 20px; 
    font-family: 'Segoe UI', Arial, sans-serif; 
    color: #ffffff; 
}

/* Typography & Interactive Markup */
.public-article-view-page .article-back-link { 
    color: #00d2ff; 
    text-decoration: none; 
    font-weight: bold; 
    font-size: 14px; 
    display: inline-block; 
    margin-bottom: 25px; 
    transition: color 0.2s; 
    text-transform: uppercase; 
    letter-spacing: 0.5px; 
}

.public-article-view-page .article-back-link:hover { 
    color: #ffffff; 
    text-decoration: underline; 
}

.public-article-view-page .article-hero-banner { 
    width: 100%; 
    max-height: 450px; 
    object-fit: cover; 
    border-radius: 8px; 
    border: 1px solid #1f293d; 
    margin-bottom: 25px; 
    box-shadow: 0 5px 20px rgba(0,0,0,0.6); 
}

.public-article-view-page .article-meta-header { 
    border-bottom: 1px solid #1f293d; 
    padding-bottom: 15px; 
    margin-bottom: 25px; 
}

.public-article-view-page .article-meta-header h1 { 
    font-size: 36px; 
    margin: 0 0 10px 0; 
    color: #ffffff; 
    line-height: 1.2; 
    letter-spacing: -0.5px; 
}

.public-article-view-page .article-string-details { 
    color: #b4c3dc; 
    font-size: 13px; 
    text-transform: uppercase; 
    letter-spacing: 1px; 
}

.public-article-view-page .article-string-details span { 
    color: #00d2ff; 
    font-weight: bold; 
}

.public-article-view-page .article-body-markup { 
    font-size: 18px; 
    line-height: 1.8; 
    color: #e2e8f0; 
}

.public-article-view-page .article-body-markup p { 
    margin-bottom: 20px; 
}

/* ==========================================================================
   KSI.PRO - Esports Native Podcast Audio Custom Elements
   ========================================================================== */
.podcast-audio-deck {
    width: 100%;
    margin-top: auto; /* Pushes player smoothly to bottom of card bounds */
    padding-top: 0.5rem;
}

/* Custom dark styling hooks for native HTML5 webkit players */
.esports-audio-node {
    width: 100%;
    height: 36px;
    border-radius: 4px;
    background: #111827;
    outline: none;
}

.esports-audio-node::-webkit-media-controls-panel {
    background-color: #111827;
}

.esports-audio-node::-webkit-media-controls-current-time-display,
.esports-audio-node::-webkit-media-controls-time-remaining-display {
    color: #00d2ff;
    font-family: monospace;
    font-weight: 700;
}

/* Fallback badge styling if audio enclosure tracks break */
.audio-unavailable-badge {
    width: 100%;
    text-align: center;
    background-color: rgba(244, 63, 94, 0.05);
    border: 1px dashed rgba(244, 63, 94, 0.2);
    color: #f43f5e;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.6rem 0;
    letter-spacing: 1px;
    border-radius: 2px;
}

/* ========================================================
   CYBERPUNK ESPORTS AUDIO PLAYER LAYER STYLES
   ======================================================== */
.podcast-audio-deck {
    background: rgba(10, 15, 28, 0.75);
    border: 1px solid rgba(0, 210, 255, 0.15);
    border-radius: 8px;
    padding: 10px;
    margin-top: 1rem;
    box-shadow: inset 0 0 10px rgba(0, 210, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.podcast-audio-deck:focus-within {
    border-color: var(--accent-blue, #00d2ff);
    box-shadow: 0 0 15px rgba(0, 210, 255, 0.2), inset 0 0 10px rgba(0, 210, 255, 0.1);
}

/* Base customizer for the engine control strip */
.esports-audio-node {
    width: 100%;
    height: 40px;
    outline: none;
    border-radius: 4px;
}

/* Custom styles for WebKit Browsers (Chrome, Safari, Edge, Opera) */
.esports-audio-node::-webkit-media-controls-panel {
    background-color: #0d1220; /* Deep space dark base */
}

.esports-audio-node::-webkit-media-controls-play-button {
    background-color: rgba(0, 210, 255, 0.1);
    border-radius: 50%;
    transform: scale(1.1);
    border: 1px solid rgba(0, 210, 255, 0.4);
    transition: all 0.2s ease;
}

.esports-audio-node::-webkit-media-controls-play-button:hover {
    background-color: var(--accent-blue, #00d2ff);
    border-color: var(--accent-blue, #00d2ff);
}

.esports-audio-node::-webkit-media-controls-current-time-display,
.esports-audio-node::-webkit-media-controls-time-remaining-display {
    color: #ffffff;
    font-family: 'Rajdhani', 'Orbitron', monospace; /* Esports styling fonts */
    font-weight: 600;
}

.esports-audio-node::-webkit-media-controls-timeline {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin-left: 10px;
    margin-right: 10px;
}

/* Custom styled badge for unavailable entries */
.audio-unavailable-badge {
    color: #ff3838;
    background: rgba(255, 56, 56, 0.08);
    border: 1px dashed rgba(255, 56, 56, 0.3);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-align: center;
    padding: 12px;
    border-radius: 6px;
}

/* =========================================================================
   --- Squad Matrix Dynamic Color Tiers ---
   ========================================================================= */

/* 1. Company Status (White Matrix) */
.white-glow {
    background-color: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
}
.white-glow-line {
    background: linear-gradient(90deg, #ffffff, transparent) !important;
}

/* 2. Split Status (Golden Matrix) */
.gold-glow {
    background-color: rgba(212, 175, 55, 0.04) !important;
    border: 1px solid rgba(212, 175, 55, 0.2) !important;
    color: #d4af37 !important;
}
.gold-glow:hover {
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.25) !important;
}
.gold-glow-line {
    background: linear-gradient(90deg, #d4af37, transparent) !important;
}

/* 3. Gradient Accent Underlays */
.blue-glow-line {
    background: linear-gradient(90deg, var(--accent-blue, #00d2ff), transparent) !important;
}
.red-glow-line {
    background: linear-gradient(90deg, var(--accent-red, #ef4444), transparent) !important;
}

/* ==========================================================================
   PROFILE AVATAR SELECTION GRID STYLING (RED CP UNIFIED)
   ========================================================================== */
.pfp-grid label input[type="radio"]:checked + .pfp-selector-img {
    border-color: #ff0000 !important;
    box-shadow: 0 0 12px rgba(255, 0, 0, 0.4);
    transform: scale(0.95);
    background-color: rgba(255, 0, 0, 0.1);
}

.pfp-grid label:hover .pfp-selector-img {
    border-color: rgba(255, 0, 0, 0.5);
    transform: scale(0.98);
}

.pfp-grid::-webkit-scrollbar {
    width: 6px;
}
.pfp-grid::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.01);
}
.pfp-grid::-webkit-scrollbar-thumb {
    background: rgba(255, 0, 0, 0.2);
    border-radius: 3px;
}
.pfp-grid::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 0, 0, 0.4);
}

/* ==========================================================================
   KSI.PRO - INTERNAL NEWS MANAGEMENT CONTROL PANEL & EDITOR STYLES
   ========================================================================== */

.ksi-admin-wrapper, .ksi-editor-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    font-family: 'Segoe UI', Arial, sans-serif;
}

.ksi-editor-wrapper {
    max-width: 900px;
}

/* Header utility action row just below the main crimson bar */
.ksi-action-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}

/* Core Esport Dark Glass Panels */
.ksi-data-table-container, .ksi-form-container {
    background: rgba(13, 19, 30, 0.75);
    border: 1px solid #1f293d;
    border-radius: 4px;
    padding: 25px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
}

.ksi-form-container {
    padding: 30px;
}

/* Form Grouping Layouts */
.form-group-block {
    margin-bottom: 20px;
}

.form-group-block label {
    display: block;
    color: #b4c3dc;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

/* Input Fields Matrix */
.ksi-input-field, .ksi-textarea-field, .ksi-select-field {
    width: 100%;
    padding: 12px;
    background: rgba(28, 35, 51, 0.9);
    border: 1px solid #1f293d;
    border-radius: 3px;
    color: #fff;
    font-size: 15px;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.ksi-input-field:focus, .ksi-textarea-field:focus, .ksi-select-field:focus {
    border-color: #990000;
    outline: none;
    background: #1c2333;
}

.ksi-textarea-field {
    height: 300px;
    font-family: inherit;
    line-height: 1.6;
    resize: vertical;
}

/* Action Trigger Buttons */
.btn-ksi-action {
    background: #990000;
    color: #fff;
    padding: 8px 16px;
    text-decoration: none;
    font-weight: bold;
    border-radius: 3px;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.5px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-block;
}

.btn-ksi-action:hover {
    background: #cc0000;
    box-shadow: 0 0 10px rgba(204, 0, 0, 0.4);
}

.ksi-form-container .btn-ksi-action {
    padding: 12px 24px;
    font-size: 13px;
}

.btn-ksi-edit {
    background: rgba(0, 210, 255, 0.1);
    color: #00d2ff;
    border: 1px solid #00d2ff;
}

.btn-ksi-edit:hover {
    background: #00d2ff;
    color: #000;
    box-shadow: 0 0 10px rgba(0, 210, 255, 0.3);
}

.btn-ksi-delete {
    background: rgba(255, 59, 48, 0.1);
    color: #ff3b30;
    border: 1px solid #ff3b30;
}

.btn-ksi-delete:hover {
    background: #ff3b30;
    color: #fff;
    box-shadow: 0 0 10px rgba(255, 59, 48, 0.3);
}

.btn-ksi-cancel {
    background: rgba(255, 59, 48, 0.1);
    color: #ff3b30;
    border: 1px solid #ff3b30;
    margin-left: 10px;
}

.btn-ksi-cancel:hover {
    background: #ff3b30;
    color: #fff;
}

/* Clean Styled Table Layout */
.ksi-table {
    width: 100%;
    border-collapse: collapse;
}

.ksi-table th {
    background: rgba(28, 35, 51, 0.8);
    color: #b4c3dc;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px;
    text-align: left;
    border-bottom: 2px solid #1f293d;
}

.ksi-table td {
    padding: 14px 12px;
    border-bottom: 1px solid #1f293d;
    color: #e2e8f0;
    font-size: 14px;
}

.ksi-table tr:hover td {
    background: rgba(31, 41, 61, 0.3);
}

/* System State Badges & Alerts */
.status-badge {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
    text-transform: uppercase;
}

.status-live {
    background: rgba(52, 199, 89, 0.2);
    color: #34c759;
    border: 1px solid #34c759;
}

.status-draft {
    background: rgba(142, 142, 147, 0.2);
    color: #aeaea3;
    border: 1px solid #8e8e93;
}

.alert-success {
    background: rgba(52, 199, 89, 0.15);
    border-left: 4px solid #34c759;
    color: #fff;
    padding: 15px;
    margin-bottom: 20px;
    font-size: 14px;
    border-radius: 2px;
}

/* ==========================================================================
   ADMIN AUTH FORMS
   ========================================================================== */

/* --- Authentication Forms --- */
.auth-container {
    min-height: 70vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.auth-box {
    background-color: var(--bg-card);
    padding: 3rem;
    border-radius: 8px;
    width: 100%;
    max-width: 400px;
    border-top: 4px solid var(--accent-red);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    text-align: center;
}

.auth-box h2 {
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

.input-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.input-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    text-transform: uppercase;
}

.input-group input {
    width: 100%;
    padding: 0.8rem;
    background-color: var(--bg-nav);
    border: 1px solid #1f2937;
    color: var(--text-main);
    border-radius: 4px;
    outline: none;
    transition: 0.3s;
}

.input-group input:focus {
    border-color: var(--accent-blue);
    box-shadow: 0 0 10px rgba(37, 99, 235, 0.2);
}

.admin-select {
    background: var(--bg-nav);
    color: var(--text-main);
    border: 1px solid #374151;
    padding: 0.4rem;
    border-radius: 4px;
}

.admin-grid {
    display: grid;
    grid-template-columns: 1.5fr 1.5fr 1fr 1fr 1fr 1fr;
    align-items: center;
    gap: 10px;
    padding: 10px;
}

.admin-header {
    border-bottom: 2px solid var(--accent-blue);
    font-weight: bold;
    color: var(--accent-blue);
    margin-bottom: 10px;
}

.admin-row {
    border-bottom: 1px solid #1f2937;
}

.admin-select {
    width: 100%;
}

/* Guest: Sleek Charcoal Dark Gradient */
.rank-username.rank-guest {
    background: linear-gradient(135deg, #2c3e50 0%, #000000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}

/* Recruit: Soft Matte Gold */
.rank-username.rank-recruit {
    background: linear-gradient(135deg, #f1c40f 0%, #f39c12 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Private: Vibrant Toxic Green */
.rank-username.rank-private {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Sergeant: Electric Cyber Blue */
.rank-username.rank-sergeant {
    background: linear-gradient(135deg, #55b0ec 0%, #00d2ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Lieutenant: Stealth Onyx / Dark Slate */
.rank-username.rank-lieutenant {
    background: linear-gradient(135deg, #434343 0%, #000000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Captain: Gunmetal Steel */
.rank-username.rank-captain {
    background: linear-gradient(135deg, #7f8c8d 0%, #111111 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Major: Royal Cosmic Purple */
.rank-username.rank-major {
    background: linear-gradient(135deg, #9250ee 0%, #4a00e0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* General: Hyper Neon Plasma Green */
.rank-username.rank-general {
    background: linear-gradient(135deg, #01f849 0%, #00bc2f 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Co-Founder & Founder: Classic Crimson Devs */
.rank-username.rank-co-founder,
.rank-username.rank-founder {
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Co-Divisional Leader: Lime Neon Cyber Punch */
.rank-username.rank-co-divisional-leader {
    background: linear-gradient(135deg, #d0f10f 0%, #9bca06 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Division Leader: Intense Gold Ignite */
.rank-username.rank-division-leader {
    background: linear-gradient(135deg, #f1c40f 0%, #e67e22 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Director: Deep Autumn Bronze */
.rank-username.rank-director {
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Senior Director: Heavy Rust Core */
.rank-username.rank-senior-director {
    background: linear-gradient(135deg, #c55e04 0%, #803900 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Co-Creator: Hot Neon Pink Punch */
.rank-username.rank-co-creator {
    background: linear-gradient(135deg, #e91e63 0%, #c2185b 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Creator: Deep Cyber Magenta */
.rank-username.rank-creator {
    background: linear-gradient(135deg, #ff00f3 0%, #7c0075 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* OWNER: Animated Mythic Sparkle Tier */
.rank-username.rank-owner {
    /* Uses your custom sparkle_effect.gif inside the font text characters */
    background: url('/assets/imgs/effects/sparkle_effect.gif') repeat, 
                linear-gradient(135deg, #00d2ff 0%, #ff00f3 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 900;
    text-transform: uppercase;
    filter: drop-shadow(0px 0px 3px rgba(0, 210, 255, 0.4));
    animation: moveBackground 8s linear infinite;
}

/* Smooth slow moving shimmer behind the text sparkles */
@keyframes moveBackground {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}

/* --- Scroll Animation Styles --- */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px); /* Tucks it slightly down before revealing */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

/* The class JavaScript applies when the user scrolls to the section */
.reveal-on-scroll.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Scroll to Top Button --- */
.scroll-to-top-btn {
    position: fixed;
    bottom: 25px; /* Aligned flush with the chat launcher baseline */
    left: 25px;   /* Pinned cleanly to the left side with matching padding */
    z-index: 999; /* Ensures it sits on top of all other elements */
    width: 45px;
    height: 45px;
    background-color: var(--bg-card, #111827);
    color: var(--text-main, #fff);
    border: 2px solid var(--accent-blue, #00d2ff); /* High-tech blue framing border */
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

/* Class added via JavaScript when user scrolls down */
.scroll-to-top-btn.show {
    opacity: 1;
    visibility: visible;
}

/* Interactive Hover state matching your gaming setup */
.scroll-to-top-btn:hover {
    background-color: var(--accent-blue, #00d2ff);
    color: #111827; /* Inverts color for sharp contrast */
    box-shadow: 0 0 15px rgba(0, 210, 255, 0.6);
}

/* ==========================================================================
   CUSTOM MASCOT SITE PRELOADER
   ========================================================================== */
.preloader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #05070a; /* Matches your main regular deep background color */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999; /* Higher than everything else, including navbar dropdowns */
    opacity: 1;
    visibility: visible;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

/* Structural assembly inside the screen mask */
.preloader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}

/* Mascot sizing and walk-bounce keyframe execution */
.preloader-mascot {
    width: 140px;
    height: auto;
    object-fit: contain;
    animation: mascotBobbing 1.2s ease-in-out infinite;
}

/* Tactical Progress Layout Track */
.preloader-status-bar {
    width: 200px;
    height: 4px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

/* Neon blue scanning animation bar */
.preloader-progress-line {
    position: absolute;
    top: 0;
    left: -100%;
    width: 70%;
    height: 100%;
    background: linear-gradient(90deg, transparent, #00d2ff, transparent);
    animation: dataScanning 1.5s infinite linear;
}

/* HUD System loading print */
.preloader-text {
    color: #00d2ff; /* Using your accent blue */
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin: 0;
    text-transform: uppercase;
    opacity: 0.8;
}

/* Trigger state to dismiss the curtain smoothly */
.preloader-overlay.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* ==========================================================================
   ANIMATION KEYFRAMES
   ========================================================================== */

/* Gives the mascot an organic, stylized step/bob movement sequence */
@keyframes mascotBobbing {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-12px) scale(0.98); /* Light squish at peak height */
    }
}

/* Loops a streaming glow effect across the data bar */
@keyframes dataScanning {
    0% {
        left: -100%;
    }
    100% {
        left: 100%;
    }
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 2rem;
    background-color: var(--bg-nav);
    color: var(--text-muted);
    border-top: 2px solid var(--bg-card);
    margin-top: 2rem;
}

@media (max-width: 900px) {
    .admin-grid {
        /* Switch to a single column stack on mobile */
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 20px;
        border-bottom: 2px solid #374151;
    }

    .admin-header {
        /* Hide the header on mobile since the layout changes */
        display: none;
    }

    .admin-row {
        /* Add labels for mobile view using pseudo-elements */
        display: block;
    }
    
    .admin-row div {
        margin-bottom: 5px;
    }

}