:root {
    --bg-color: #050505;
    --panel-bg: #111;
    --neon-cyan: #0ff;
    --neon-pink: #f0f;
    --neon-green: #0f0;
    --text-color: #fff;
    --font-family: 'Segoe UI', 'Roboto', Helvetica, Arial, sans-serif;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --header-height: 70px;
    --bar-height: 60px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    background: url('../img/bg.jpg') no-repeat center center fixed;
    background-size: cover;
    color: var(--text-color);
    font-family: var(--font-family);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: -1;
}

/* Scrollbar */
@keyframes gradient-pulse {
    0% { filter: brightness(1) drop-shadow(0 0 0px transparent); }
    100% { filter: brightness(2.5) drop-shadow(0 0 15px rgba(255, 0, 255, 1.0)); }
}

::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #000; 
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #00bfff, #ff00ff, #9900ff);
    border-radius: 4px;
    animation: gradient-pulse 2s infinite alternate;
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, #00bfff, #ff00ff, #9900ff);
}

/* Dashboard Layout */
.dashboard-layout {
    display: flex;
    height: 100vh;
    width: 100%;
}

.sidebar {
    width: 220px;
    background: rgba(0, 0, 0, 0.6);
    border-right: none;
    display: flex;
    flex-direction: column;
    padding: 20px 0;
    box-shadow: 5px 0 25px rgba(0, 255, 255, 0.1);
    z-index: 1001; /* Higher z-index */
    height: 100vh;
    overflow-y: auto;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
}

.sidebar-header {
    text-align: center;
    margin-bottom: 30px;
}

.sidebar-header a {
    font-family: 'Orbitron', sans-serif;
    font-weight: 900;
    font-size: 1.6em;
    text-decoration: none;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: none;
}

.menu-group-title {
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.9em; /* Larger */
    padding: 15px 0 5px 0;
    text-align: center;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: none;
    opacity: 1; /* Full opacity */
    border-bottom: 1px solid transparent;
    border-image: linear-gradient(90deg, transparent, #00bfff, #ff00ff, #9900ff, transparent) 1;
    margin-bottom: 5px;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-menu li {
    padding: 0;
    transition: 0.3s;
}

.sidebar-menu a {
    color: #ccc;
    text-decoration: none;
    display: block;
    padding: 0px 10px 0px 25px;
    line-height: 30px; /* Ensure some height for clickability */
    font-size: 0.95em;
    transition: 0.3s;
    border-left: 3px solid transparent;
}

.sidebar-menu a:hover, .sidebar-menu a.active {
    background: rgba(0, 255, 255, 0.1);
    color: var(--text-color);
    border-left: 3px solid var(--neon-cyan);
    text-shadow: 0 0 5px var(--neon-cyan);
}

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: rgba(0, 0, 0, 0.2); /* Slight overlay */
    overflow: auto;
    margin-left: 220px;
}

.header {
    height: var(--header-height);
    background: rgba(0, 0, 0, 0.6); /* Darker header */
    backdrop-filter: blur(10px);
    border-bottom: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    box-shadow: 0 5px 15px rgba(0, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 99;
}

.header::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #000 0%, #00bfff 25%, #ff00ff 50%, #9900ff 75%, #000 100%);
    animation: gradient-pulse 2s infinite alternate;
    z-index: 100;
}

.header-title {
    font-size: 1.4em;
    font-weight: 600;
    color: var(--neon-cyan);
    text-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

.user-info {
    font-size: 0.9em;
    color: #ccc;
}

.content-area {
    padding: 15px;
    overflow-y: auto;
    overflow-x: hidden;
    flex: 1;
}

/* Cards & Content */
.card {
    background: #111; /* Darker card background */
    border: 1px solid #333;
    border-radius: 8px; /* Slightly sharper corners */
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

h3 {
    color: var(--neon-cyan);
    margin-top: 0;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 10px;
    text-shadow: 0 0 5px rgba(0, 255, 255, 0.2);
}

/* Forms & Buttons */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    color: #ccc;
    font-size: 0.9em;
}

.input-group input, .input-group select, .input-group textarea {
    width: 100%;
    padding: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid #444;
    border-radius: 4px;
    color: #fff;
    font-family: inherit;
    box-sizing: border-box;
    transition: 0.3s;
}

.input-group input:focus, .input-group select:focus, .input-group textarea:focus,
input:focus, select:focus, textarea:focus {
    outline: none;
    border-top: 1px solid transparent;
    border-bottom: 1px solid transparent;
    border-left: none;
    border-right: none;
    border-image: linear-gradient(90deg, transparent, #00bfff, #ff00ff, #9900ff, transparent) 1;
    box-shadow: none;
}

select option {
    background-color: #000;
    color: #fff;
}

.neon-btn {
    background: rgba(255, 0, 255, 0.1);
    color: var(--neon-pink);
    border: 1px solid var(--neon-pink);
    padding: 10px 20px;
    font-size: 1em;
    cursor: pointer;
    transition: 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: bold;
    border-radius: 4px;
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.1);
    width: 100%;
    display: inline-block;
    text-align: center;
}

.neon-btn:hover {
    background: var(--neon-pink);
    color: #fff;
    box-shadow: 0 0 20px var(--neon-pink);
}

.logout-btn {
    color: var(--neon-pink);
    text-decoration: none;
    font-weight: bold;
    border: 1px solid var(--neon-pink);
    padding: 5px 15px;
    border-radius: 4px;
    transition: 0.3s;
}

.logout-btn:hover {
    background: var(--neon-pink);
    color: #fff;
    box-shadow: 0 0 10px var(--neon-pink);
}

/* Tables */
.neon-table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    margin-top: 20px;
    background: rgba(0,0,0,0.2);
    border-radius: 8px;
    overflow: hidden;
}

.neon-table th, .neon-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.neon-table th {
    background: rgba(255, 0, 255, 0.1);
    color: var(--neon-pink);
    text-transform: uppercase;
    font-size: 0.85em;
    letter-spacing: 1px;
}

.neon-table tr:last-child td {
    border-bottom: none;
}

.neon-table tr:hover {
    background: rgba(255,255,255,0.02);
}

.badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: bold;
    text-transform: uppercase;
}

.role-super_admin {
    background: rgba(255, 0, 0, 0.2);
    color: #ff5555;
    border: 1px solid #ff5555;
    box-shadow: 0 0 5px rgba(255, 0, 0, 0.2);
}

.role-admin {
    background: rgba(255, 165, 0, 0.2);
    color: #ffa500;
    border: 1px solid #ffa500;
    box-shadow: 0 0 5px rgba(255, 165, 0, 0.2);
}

.role-moderator {
    background: rgba(0, 255, 0, 0.2);
    color: #0f0;
    border: 1px solid #0f0;
    box-shadow: 0 0 5px rgba(0, 255, 0, 0.2);
}

.role-user {
    background: rgba(0, 255, 255, 0.2);
    color: #0ff;
    border: 1px solid #0ff;
    box-shadow: 0 0 5px rgba(0, 255, 255, 0.2);
}

/* Alerts */
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    border: 1px solid transparent;
}

.alert.success {
    background: rgba(0, 255, 0, 0.1);
    border-color: var(--neon-green);
    color: var(--neon-green);
}

.alert.error {
    background: rgba(255, 0, 0, 0.1);
    border-color: #ff5555;
    color: #ff5555;
}

/* Action Buttons */
.action-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    color: #ccc;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    transition: 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: 5px;
}

.action-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: #fff;
    color: #fff;
}

.edit-btn:hover {
    border-color: var(--neon-cyan);
    color: var(--neon-cyan);
    box-shadow: 0 0 5px var(--neon-cyan);
}

.delete-btn:hover {
    border-color: #ff5555;
    color: #ff5555;
    box-shadow: 0 0 5px #ff5555;
}

/* Login Page */
.login-container {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-box {
    width: 400px;
    padding: 40px;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid #000;
    border-radius: 8px;
    box-shadow: 0 0 30px rgba(0,0,0,0.5);
    text-align: center;
    position: relative;
}

.login-box::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #000 0%, #00bfff 25%, #ff00ff 50%, #9900ff 75%, #000 100%);
    animation: gradient-pulse 2s infinite alternate;
    z-index: 1;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.login-box::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #000 0%, #00bfff 25%, #ff00ff 50%, #9900ff 75%, #000 100%);
    animation: gradient-pulse 2s infinite alternate;
    z-index: 1;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.login-box h2 {
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 30px;
    text-shadow: none;
}

.login-box .input-group {
    display: flex;
    align-items: center;
}

.login-box .input-group label {
    margin-bottom: 0;
    margin-right: 15px;
    width: 70px;
    text-align: right;
    flex-shrink: 0;
}

.login-box .input-group input {
    flex-grow: 1;
    padding: 6px;
}

.login-box .neon-btn {
    padding: 8px 25px;
    font-size: 0.9em;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    color: #fff;
    border: none;
    text-shadow: none;
    box-shadow: none;
    transition: 0.3s;
}

.login-box .neon-btn:hover {
    box-shadow: 0 0 15px #00bfff, 0 0 25px #ff00ff, 0 0 35px #9900ff;
    transform: scale(1.05);
}


.error-msg {
    color: #ff5555;
    background: rgba(255, 0, 0, 0.1);
    padding: 10px;
    border: 1px solid #ff5555;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 0.9em;
}

/* Modal */
.modal {
    display: none; 
    position: fixed; 
    z-index: 1000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.5); 
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: rgba(0, 0, 0, 0.9);
    margin: 5% auto; 
    padding: 30px;
    border: none;
    width: 500px; 
    border-radius: 8px;
    box-shadow: none;
    position: relative;
    animation: modalOpen 0.3s;
}

.modal-content::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 8px;
    padding: 2px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-mask: 
       linear-gradient(#fff 0 0) content-box, 
       linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

.modal-content > * {
    position: relative;
    z-index: 2;
}

@keyframes modalOpen {
    from {opacity: 0; transform: translateY(-50px);}
    to {opacity: 1; transform: translateY(0);}
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.close:hover,
.close:focus {
    color: var(--neon-pink);
    text-decoration: none;
    cursor: pointer;
    text-shadow: 0 0 10px var(--neon-pink);
}

/* Blinking text animation for suspended users */
@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0; }
    100% { opacity: 1; }
}

.blinking-text {
    animation: blink 1s linear infinite;
    text-shadow: 0 0 5px red;
}

/* Admin Message Modal */
.admin-message-modal {
    width: 100%;
    max-width: 700px;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 8px;
    padding: 20px;
    position: relative;
    box-shadow: none;
    color: #fff;
}

.admin-message-modal::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 8px;
    padding: 1px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-mask: 
       linear-gradient(#fff 0 0) content-box, 
       linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

.admin-message-modal > * {
    position: relative;
    z-index: 2;
}

/* Current Day Card Gradient Border */
.current-day-card {
    background: rgba(0, 0, 0, 0.6);
    border: none;
    position: relative;
    box-shadow: none;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.current-day-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 8px;
    padding: 2px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-mask: 
       linear-gradient(#fff 0 0) content-box, 
       linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

.current-day-card > * {
    position: relative;
    z-index: 2;
}

.player-modal-content {
    position: relative;
    width: 350px;
    height: 500px;
    background: rgba(0,0,0,0.9);
    border: none;
    border-radius: 20px;
    box-shadow: none;
    overflow: hidden;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.player-modal-content::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(90deg, #00bfff, #ff00ff, #9900ff);
    -webkit-mask: 
       linear-gradient(#fff 0 0) content-box, 
       linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

.player-modal-content > * {
    position: relative;
    z-index: 2;
}

/* Toggle Switch */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
  margin-left: 10px;
  vertical-align: middle;
}

.switch input { 
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #333;
  transition: .4s;
  border-radius: 34px;
  border: 1px solid #555;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 3px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .slider {
  background-color: var(--neon-pink);
  border-color: var(--neon-pink);
  box-shadow: 0 0 10px var(--neon-pink);
}

input:checked + .slider:before {
  transform: translateX(26px);
}

/* --- ACTION LOADER STYLES (From admin_stats.php) --- */
#actionLoader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    justify-content: center;
    align-items: center;
    background: rgba(0, 0, 0, 0.0);
    opacity: 0;
    transition: opacity 0.5s ease;
}

#actionLoader.active {
    opacity: 1;
}

#actionLoader .content-layer {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.status-message {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 1.5rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: #fff;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
    padding: 20px 40px;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 10px;
    position: relative;
    animation: expand-box 1.5s cubic-bezier(0.83, 0, 0.17, 1) forwards;
}

@keyframes expand-box {
    0% {
        clip-path: inset(0 50% 0 50%);
        opacity: 0;
    }
    100% {
        clip-path: inset(0 0 0 0);
        opacity: 1;
    }
}

.status-message::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 10px;
    padding: 2px;
    background: linear-gradient(90deg, #00f3ff, #ff00ff, #bc13fe);
    -webkit-mask:
       linear-gradient(#fff 0 0) content-box,
       linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.status-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid currentColor;
    box-shadow: 0 0 15px currentColor;
}

.equalizer {
    display: flex;
    gap: 12px;
    height: 100px;
    align-items: flex-end;
    margin: 0 auto 20px auto;
}

.bar {
    width: 18px;
    border-radius: 5px;
    animation: equalize 0.8s infinite ease-in-out alternate;
    box-shadow: 0 0 10px currentColor;
}

.bar:nth-child(1) { background: #00f3ff; color: #00f3ff; height: 60%; animation-delay: 0s; }
.bar:nth-child(2) { background: #ff00ff; color: #ff00ff; height: 80%; animation-delay: 0.2s; }
.bar:nth-child(3) { background: #bc13fe; color: #bc13fe; height: 50%; animation-delay: 0.4s; }
.bar:nth-child(4) { background: #ff00ff; color: #ff00ff; height: 90%; animation-delay: 0.1s; }
.bar:nth-child(5) { background: #00f3ff; color: #00f3ff; height: 70%; animation-delay: 0.3s; }

@keyframes equalize {
    0% { height: 20%; filter: brightness(1); }
    100% { height: 100%; filter: brightness(1.5); }
}
