@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@300;400;700&display=swap');

:root {
    --bg-color: #020202;
    --panel-bg: rgba(10, 10, 10, 0.85);
    /* Slightly transparent for blur */
    --text-primary: #00ff41;
    --text-secondary: #008f11;
    --accent-color: #00ff41;
    --accent-dim: rgba(0, 255, 65, 0.05);
    --border-color: #1a1a1a;
    --alert-color: #ff3333;
    --font-stack: 'JetBrains Mono', monospace;
    --card-shadow: 0 0 10px rgba(0, 255, 65, 0.1);
    --neon-glow: 0 0 10px rgba(0, 255, 65, 0.5), 0 0 20px rgba(0, 255, 65, 0.3);
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-stack);
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    position: relative;
}

/* --- ANIMATED BACKGROUND (Moving 3D Grid) --- */
body::before {
    content: "";
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background-image:
        linear-gradient(rgba(0, 255, 65, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 65, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: -2;
    transform: perspective(500px) rotateX(60deg) translateY(0) translateZ(-200px);
    animation: moveGrid 15s linear infinite;
    opacity: 0.6;
    pointer-events: none;
}

@keyframes moveGrid {
    0% {
        transform: perspective(500px) rotateX(60deg) translateY(0) translateZ(-200px);
    }

    100% {
        transform: perspective(500px) rotateX(60deg) translateY(1000px) translateZ(-200px);
    }
}

/* --- CRT SCANLINE & VIGNETTE --- */
body::after {
    content: " ";
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background:
        linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 50%),
        radial-gradient(circle, rgba(0, 0, 0, 0) 60%, rgba(0, 0, 0, 0.6) 100%);
    background-size: 100% 3px, 100% 100%;
    z-index: 999;
    pointer-events: none;
    animation: flicker 0.15s infinite;
}

@keyframes flicker {
    0% {
        opacity: 0.97;
    }

    5% {
        opacity: 0.95;
    }

    10% {
        opacity: 0.9;
    }

    15% {
        opacity: 0.95;
    }

    20% {
        opacity: 0.99;
    }

    100% {
        opacity: 0.96;
    }
}

/* --- GLITCH TEXT ANIMATION --- */
@keyframes glitch {
    0% {
        text-shadow: 2px 0 red, -2px 0 blue;
        transform: skew(0deg);
    }

    2% {
        text-shadow: 2px 0 red, -2px 0 blue;
        transform: skew(-1deg);
    }

    4% {
        text-shadow: -2px 0 red, 2px 0 blue;
        transform: skew(1deg);
    }

    5% {
        text-shadow: none;
        transform: skew(0deg);
    }

    100% {
        text-shadow: none;
        transform: skew(0deg);
    }
}

h1 strong,
h1 span,
h2 {
    animation: glitch 5s infinite steps(1);
    position: relative;
    display: inline-block;
}

/* --- LAYOUT --- */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
    /* Above background */
}

/* --- HEADER --- */
header {
    background: var(--panel-bg);
    border-bottom: 2px solid var(--accent-color);
    padding: 20px 30px;
    margin-bottom: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.2);
    backdrop-filter: blur(5px);
    clip-path: polygon(0 0, 100% 0, 100% 85%, 98% 100%, 0 100%);
}

header h1 {
    margin: 0;
    color: #fff;
    font-size: 1.8rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

header h1 span {
    color: var(--accent-color);
}

nav a {
    margin-left: 25px;
    font-weight: 500;
    font-size: 0.9rem;
    position: relative;
    padding: 5px 15px;
    border: 1px solid transparent;
    transition: 0.3s;
    text-transform: uppercase;
    color: #888;
}

nav a:hover,
nav a.active {
    color: #000;
    background: var(--accent-color);
    box-shadow: 0 0 15px var(--accent-color);
    border-color: var(--accent-color);
    text-shadow: none;
}

/* --- CARDS & PANELS --- */
.panel,
.stat-card,
.quick-panel,
.table-container {
    background: var(--panel-bg);
    border: 1px solid #333;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
    border-left: 4px solid var(--accent-color);
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
    margin-bottom: 30px;
    padding: 20px;
}

.panel:hover,
.stat-card:hover,
.quick-panel:hover,
.table-container:hover {
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.15);
    transform: translateY(-2px);
}

.stat-card h3 {
    margin: 0 0 15px 0;
    font-size: 0.85rem;
    color: #fff;
    opacity: 0.8;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.stat-card .value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-shadow: 0 0 15px var(--accent-color);
}

/* --- TABLES --- */
.table-container {
    padding: 0;
    border-radius: 4px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 15px 20px;
    text-align: left;
    border-bottom: 1px solid #222;
}

th {
    background: rgba(0, 255, 65, 0.05);
    color: var(--accent-color);
    letter-spacing: 1px;
    font-size: 0.85rem;
    text-transform: uppercase;
}

tr {
    transition: background 0.2s;
}

tr:hover {
    background: rgba(0, 255, 65, 0.1);
}

.status-active {
    color: #fff;
    background: #008f11;
    padding: 2px 8px;
    font-size: 0.8em;
    border-radius: 2px;
}

.status-banned {
    color: #fff;
    background: var(--alert-color);
    padding: 2px 8px;
    font-size: 0.8em;
    border-radius: 2px;
    animation: flashRed 1s infinite alternate;
}

@keyframes flashRed {
    from {
        box-shadow: 0 0 5px red;
    }

    to {
        box-shadow: 0 0 15px red;
    }
}

/* --- FORMS --- */
input[type="text"],
input[type="password"],
input[type="date"],
select {
    background: #000;
    border: 1px solid #444;
    color: var(--accent-color);
    padding: 12px 15px;
    font-family: var(--font-stack);
    transition: all 0.3s;
    outline: none;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.5);
}

input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 15px rgba(0, 255, 65, 0.2);
}

button {
    background: rgba(0, 255, 65, 0.05);
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    padding: 12px 25px;
    font-family: var(--font-stack);
    font-weight: bold;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

button:hover {
    background: var(--accent-color);
    color: #000;
    box-shadow: 0 0 20px var(--accent-color);
}

button.danger {
    color: var(--alert-color);
    border-color: var(--alert-color);
    background: rgba(255, 50, 50, 0.05);
}

button.danger:hover {
    background: var(--alert-color);
    color: #fff;
    box-shadow: 0 0 20px var(--alert-color);
}

/* --- STATS GRID --- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 25px;
}

/* --- UTILS --- */
.flex {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.flex>* {
    flex: 1;
    min-width: 200px;
}

/* Login Page specific */
.login-wrapper {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2;
    position: relative;
}

.login-box {
    width: 350px;
    padding: 40px;
    border: 1px solid var(--accent-color);
    background: #000;
    box-shadow: 0 0 30px rgba(0, 255, 65, 0.2);
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #000;
}

::-webkit-scrollbar-thumb {
    background: #333;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-color);
}