:root {
    --bg-color: #050505;
    --text-color: #e0e0e0;
    --primary-color: #00ffcc; /* Cyan Neon */
    --secondary-color: #ff00ff; /* Magenta Neon */
    --accent-color: #7000ff; /* Purple Neon */
    --card-bg: #111111;
    --font-main: 'Roboto', sans-serif;
    --font-display: 'Orbitron', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Скрываем курсор только если кастомный инициализирован */
html.custom-cursor-active, 
html.custom-cursor-active * {
    cursor: none !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: #000; 
}
::-webkit-scrollbar-thumb {
    background: #333; 
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color); 
}

/* Text Selection */
::selection {
    background: var(--primary-color);
    color: #000;
}

/* Custom Cursor */
.cursor-dot,
.cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--primary-color);
}

.cursor-outline {
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary-color);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

body:hover .cursor-outline {
    opacity: 1;
}

/* Preloader */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    transition: opacity 0.5s ease, visibility 0.5s;
}

.loader-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(0, 255, 204, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Scroll Progress */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: var(--secondary-color);
    z-index: 1001;
    width: 0%;
    box-shadow: 0 0 10px var(--secondary-color);
}

/* Background Grid Effect */
.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 255, 204, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 204, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -1;
    perspective: 1000px;
    transform: translateZ(0);
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    background: rgba(5, 5, 5, 0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 255, 204, 0.2);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 700;
    color: white;
    letter-spacing: 2px;
}

.neon-text {
    color: var(--primary-color);
    text-shadow: 0 0 10px var(--primary-color);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
}

nav a:hover, nav a.active {
    color: var(--primary-color);
    text-shadow: 0 0 5px var(--primary-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background-color: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    box-shadow: 0 0 10px rgba(0, 255, 204, 0.2);
}

.btn-primary:hover {
    background-color: var(--primary-color);
    color: #000;
    box-shadow: 0 0 20px rgba(0, 255, 204, 0.6);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
    box-shadow: 0 0 10px rgba(255, 0, 255, 0.2);
}

.btn-secondary:hover {
    background-color: var(--secondary-color);
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.6);
}

.btn-outline {
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
}

.btn-outline:hover {
    border-color: white;
    background: rgba(255,255,255,0.1);
}

.btn-large {
    padding: 15px 40px;
    font-size: 1.2rem;
}

.btn-logout-mini {
    margin-left: 12px;
    color: #ff4444;
    font-size: 1rem;
    opacity: 0.6;
    transition: 0.3s;
    text-decoration: none;
}

.btn-logout-mini:hover {
    opacity: 1;
    transform: scale(1.1);
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 60px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(112, 0, 255, 0.15) 0%, transparent 70%);
    z-index: -1;
}

.hero h1 {
    font-family: var(--font-display);
    font-size: 5rem;
    margin-bottom: 10px;
    color: white;
    text-transform: uppercase;
    position: relative;
    display: inline-block;
}

.hero .subtitle {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    letter-spacing: 5px;
    text-transform: uppercase;
}

.hero .description {
    font-size: 1.1rem;
    color: #aaa;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-bottom: 50px;
}

.stats-preview {
    display: flex;
    justify-content: center;
    gap: 50px;
    margin-top: 30px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-family: var(--font-display);
    font-size: 2rem;
    color: white;
}

.stat-label {
    font-size: 0.8rem;
    color: #777;
    text-transform: uppercase;
}

/* Glitch Effect */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
}

.glitch::before {
    left: 2px;
    text-shadow: -1px 0 red;
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-2 3s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -1px 0 blue;
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim 2.5s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% { clip: rect(10px, 9999px, 30px, 0); }
    20% { clip: rect(80px, 9999px, 100px, 0); }
    40% { clip: rect(30px, 9999px, 60px, 0); }
    60% { clip: rect(90px, 9999px, 10px, 0); }
    80% { clip: rect(10px, 9999px, 130px, 0); }
    100% { clip: rect(50px, 9999px, 70px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip: rect(60px, 9999px, 10px, 0); }
    20% { clip: rect(10px, 9999px, 90px, 0); }
    40% { clip: rect(100px, 9999px, 30px, 0); }
    60% { clip: rect(5px, 9999px, 60px, 0); }
    80% { clip: rect(70px, 9999px, 120px, 0); }
    100% { clip: rect(30px, 9999px, 10px, 0); }
}

/* News Section */
.section-title {
    font-family: var(--font-display);
    font-size: 2rem;
    margin-bottom: 40px;
    text-align: center;
    color: white;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: var(--primary-color);
    box-shadow: 0 0 10px var(--primary-color);
}

.news-section {
    padding: 80px 0;
    background: #080808;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.news-card {
    background: var(--card-bg);
    border: 1px solid #222;
    padding: 25px;
    border-radius: 10px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    border-color: var(--secondary-color);
    box-shadow: 0 5px 20px rgba(0,0,0,0.5);
}

.news-date {
    font-size: 0.8rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.news-card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: white;
}

.news-card p {
    color: #aaa;
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.read-more {
    color: white;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 700;
}

.read-more:hover {
    color: var(--secondary-color);
}

/* Servers Section */
.servers-section {
    padding: 80px 0;
}

.servers-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.server-card {
    background: rgba(255, 255, 255, 0.03);
    border-left: 5px solid #333;
    padding: 20px 30px;
    display: flex;
    align-items: center;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.server-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-left-color: var(--primary-color);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.server-icon {
    font-size: 2rem;
    margin-right: 25px;
    color: var(--primary-color);
    width: 50px;
    text-align: center;
}

.server-info {
    flex-grow: 1;
}

.server-info h3 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 5px;
}

.server-info p {
    color: #888;
    font-size: 0.9rem;
}

.server-online {
    text-align: right;
    color: #aaa;
}

.online-count {
    color: var(--primary-color);
    font-weight: 700;
    font-family: var(--font-display);
}

/* Launcher Section */
.launcher-section {
    padding: 100px 0;
    background: linear-gradient(45deg, #0a0a0a 0%, #150020 100%);
    text-align: center;
}

.launcher-content {
    max-width: 800px;
}

.launcher-text h2 {
    font-family: var(--font-display);
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: white;
}

.launcher-text p {
    font-size: 1.1rem;
    color: #ccc;
    margin-bottom: 40px;
}

.glow-effect {
    animation: glow 2s infinite alternate;
}

@keyframes glow {
    from { box-shadow: 0 0 10px rgba(0, 255, 204, 0.5); }
    to { box-shadow: 0 0 30px rgba(0, 255, 204, 0.9); border-color: white; }
}

.small-text {
    margin-top: 15px;
    font-size: 0.8rem;
    color: #555;
}

/* Footer */
footer {
    background: #020202;
    padding: 60px 0 20px;
    border-top: 1px solid #111;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h3 {
    color: white;
    margin-bottom: 20px;
    font-family: var(--font-display);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col a {
    color: #777;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-col a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: #111;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: white;
}

.social-links a:hover {
    background: var(--primary-color);
    color: black;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #111;
    color: #444;
    font-size: 0.8rem;
}

/* User Profile in Header */
.user-actions {
    display: flex;
    align-items: center;
}

.user-profile {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    padding: 5px 12px;
    border-radius: 30px;
    border: 1px solid rgba(0, 255, 204, 0.3);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.user-profile:hover {
    background: rgba(0, 255, 204, 0.1);
    border-color: var(--primary-color);
    box-shadow: 0 0 15px rgba(0, 255, 204, 0.2);
}

.user-avatar-small {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin-right: 10px;
    border: 2px solid var(--primary-color);
    object-fit: cover;
}

.user-avatar-head {
    width: 32px;
    height: 32px;
    border-radius: 4px; /* Minecraft стиль - квадратная голова */
    border: 2px solid var(--primary-color);
    margin-right: 10px;
    background-size: 800%; /* Увеличиваем скин в 8 раз, чтобы показать только голову */
    background-position: 14.3% 14.3%; /* Координаты головы в файле скина */
    image-rendering: pixelated; /* Сохраняем пиксельность как в игре */
    background-repeat: no-repeat;
    box-shadow: 0 0 10px rgba(0, 255, 204, 0.3);
}

.user-profile:hover .user-avatar-head {
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--primary-color);
}

.user-avatar-head-img {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    border: 2px solid var(--primary-color);
    margin-right: 12px;
    image-rendering: pixelated;
    background: #1a1a1a;
    box-shadow: 0 0 10px rgba(0, 255, 204, 0.4);
}

.user-profile:hover .user-avatar-head-img {
    transform: scale(1.1);
    border-color: var(--primary-color);
}

.user-info-mini {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.user-profile .username {
    font-family: var(--font-display);
    font-size: 0.8rem;
    color: white;
}

.user-profile .balance {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 0.7rem;
}

/* Social Links Styles */
.social-bind-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    margin-bottom: 10px;
    border: 1px solid #222;
}

.social-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.social-info i {
    font-size: 1.5rem;
    width: 30px;
    text-align: center;
}

.fa-discord { color: #5865F2; }
.fa-vk { color: #0077FF; }
.fa-telegram { color: #26A5E4; }

.bind-status {
    font-size: 0.8rem;
    color: #666;
}

.bind-status.connected {
    color: var(--primary-color);
}

/* Remember Me Checkbox */
.remember-me {
    margin-top: -10px;
    margin-bottom: 20px;
}

.checkbox-container {
    display: block;
    position: relative;
    padding-left: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #aaa;
    user-select: none;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 20px;
    width: 20px;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid #333;
    border-radius: 4px;
}

.checkbox-container:hover input ~ .checkmark {
    border-color: var(--primary-color);
}

.checkbox-container input:checked ~ .checkmark {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid black;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Site Switcher */
.site-switch-container {
    display: flex;
    background: rgba(0, 0, 0, 0.3);
    padding: 4px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin: 0 20px;
}

.site-tag {
    font-family: var(--font-display);
    font-size: 0.7rem;
    padding: 5px 10px;
    border-radius: 7px;
    text-decoration: none;
    color: #555;
    transition: 0.3s;
}

.site-tag.active {
    background: var(--primary-color);
    color: black;
    box-shadow: 0 0 10px var(--primary-color);
}

.site-tag:hover:not(.active) {
    color: white;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 3rem;
    }
    
    .nav {
        display: none;
    }
}
