/* Сегодня 10 мая. Я только щас решил вынести 95% css сюды */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
:root {
    --bg: #0a0a0c;
    --bg-hero: #030303;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-alt: rgba(255, 255, 255, 0.015);
    --text: #ffffff;
    --text-secondary: #a1a1aa;
    --text-tertiary: #cbd5e1;
    --border: rgba(255, 255, 255, 0.06);
    --border-alt: rgba(255, 255, 255, 0.08);
    --card-hover: rgba(168, 85, 247, 0.25);
    --meta-bg: rgba(20, 20, 24, 0.6);
    --chart-bg: rgba(10, 10, 12, 0.7);
    --footer-text: #71717a;
    --btn-bg: #ffffff;
    --btn-text: #0a0a0c;
    --btn-hover: #e2e8f0;
    --gradient-start: #c084fc;
    --gradient-mid: #a855f7;
    --gradient-end: #7c3aed;
    --scrollbar-thumb: rgba(255, 255, 255, 0.15);
}
body.light {
    --bg: #f8fafc;
    --bg-hero: #f1f5f9;
    --surface: rgba(0, 0, 0, 0.02);
    --surface-alt: rgba(0, 0, 0, 0.01);
    --text: #0f172a;
    --text-secondary: #475569;
    --text-tertiary: #334155;
    --border: rgba(0, 0, 0, 0.06);
    --border-alt: rgba(0, 0, 0, 0.08);
    --card-hover: rgba(124, 58, 237, 0.2);
    --meta-bg: rgba(255, 255, 255, 0.8);
    --chart-bg: rgba(255, 255, 255, 0.7);
    --footer-text: #64748b;
    --btn-bg: #0f172a;
    --btn-text: #ffffff;
    --btn-hover: #1e293b;
    --scrollbar-thumb: rgba(0, 0, 0, 0.2);
}
body {
    font-family: "Inter", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
    transition:
        background 0.3s,
        color 0.3s;
    -webkit-tap-highlight-color: transparent;
}
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}
section {
    padding: 80px 0;
    position: relative;
}
.gradient-text {
    background: linear-gradient(
        135deg,
        var(--gradient-start) 0%,
        var(--gradient-mid) 40%,
        var(--gradient-end) 80%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: none;
    font-weight: 600;
    font-size: 1rem;
    padding: 14px 32px;
    border-radius: 60px;
    cursor: pointer;
    transition: all 0.25s ease;
    background: var(--btn-bg);
    color: var(--btn-text);
}
.btn:hover {
    background: var(--btn-hover);
    transform: translateY(-2px);
    box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.15);
}
.card {
    background: var(--surface);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 28px;
    padding: 28px;
    transition: border-color 0.2s;
}
.card:hover {
    border-color: var(--card-hover);
}
.hero {
    min-height: 90vh;
    display: flex;
    align-items: center;
    background:
        radial-gradient(
            circle at 30% 40%,
            rgba(124, 58, 237, 0.12) 0%,
            transparent 45%
        ),
        var(--bg-hero);
    position: relative;
    overflow: hidden;
    transition: background 0.3s;
}
body.light .hero {
    background:
        radial-gradient(
            circle at 30% 40%,
            rgba(124, 58, 237, 0.06) 0%,
            transparent 45%
        ),
        var(--bg-hero);
}
.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}
.server-title {
    font-size: clamp(3.5rem, 10vw, 6rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.1;
    margin-bottom: 20px;
}
.server-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 24px;
    margin: 28px 0 36px;
    color: var(--text-tertiary);
    font-weight: 500;
    font-size: 1.1rem;
    background: var(--meta-bg);
    backdrop-filter: blur(8px);
    padding: 12px 28px;
    border-radius: 60px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    border: 1px solid var(--border-alt);
    transition:
        background 0.3s,
        border-color 0.3s,
        color 0.3s;
}
.online-dot {
    width: 10px;
    height: 10px;
    background: #22c55e;
    border-radius: 50%;
    box-shadow: 0 0 12px #22c55e;
    display: inline-block;
    margin-right: 6px;
}
.online-dot.offline {
    background: #ef4444;
    box-shadow: 0 0 12px #ef4444;
}
.ip-copy {
    background: var(--surface);
    padding: 6px 16px;
    border-radius: 30px;
    font-family: monospace;
    font-size: 1rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--border);
    transition:
        background 0.3s,
        border-color 0.3s;
}
.ip-copy svg {
    stroke: var(--text-secondary);
}
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    margin-top: 48px;
}
.feature-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    margin-bottom: 20px;
    background: rgba(168, 85, 247, 0.1);
}
.feature-icon svg {
    width: 28px;
    height: 28px;
}
.card h3 {
    color: var(--text);
    font-weight: 600;
    margin-bottom: 6px;
}
.card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}
.steps {
    display: flex;
    flex-direction: column;
    gap: 28px;
    margin-top: 40px;
}
.step-item {
    display: flex;
    align-items: flex-start;
    gap: 24px;
    background: var(--surface);
    border-radius: 24px;
    padding: 24px;
    border: 1px solid var(--border);
    transition:
        background 0.3s,
        border-color 0.3s;
}
.step-item h4 {
    color: var(--text);
    margin-bottom: 4px;
}
.step-item p {
    color: var(--text-secondary);
}
.step-number {
    background: linear-gradient(135deg, #a855f7, #7c3aed);
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.3rem;
    flex-shrink: 0;
    color: #fff;
}
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 40px;
}
.gallery-placeholder {
    aspect-ratio: 16/10;
    border-radius: 24px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 1px solid var(--border);
    background-size: cover;
    background-position: center;
    transition: border-color 0.2s;
}
.gallery-placeholder:hover {
    transform: scale(1.05);
    border-color: var(--card-hover);
}
.rules-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 18px;
    margin-top: 32px;
}
.rule-item {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--surface);
    padding: 16px 20px;
    border-radius: 18px;
    border-left: 4px solid #7c3aed;
    color: var(--text);
    transition: background 0.3s;
}
.contacts {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 36px;
    justify-content: center;
}
.contact-link {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--surface);
    padding: 14px 28px;
    border-radius: 50px;
    text-decoration: none;
    color: var(--text);
    font-weight: 500;
    border: 1px solid var(--border);
    transition:
        background 0.2s,
        border-color 0.2s,
        color 0.2s;
}
.contact-link:hover {
    border-color: #a855f7;
    background: rgba(168, 85, 247, 0.08);
}
.contact-link svg {
    fill: var(--text);
    transition: fill 0.2s;
}
.chart-container {
    margin-top: 30px;
    background: var(--chart-bg);
    border-radius: 24px;
    padding: 20px;
    border: 1px solid var(--border);
    backdrop-filter: blur(10px);
    transition: background 0.3s;
}
.section-alt {
    background: var(--surface-alt);
    transition: background 0.3s;
}
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 999;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 48px;
    height: 48px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    transition:
        background 0.3s,
        border-color 0.3s;
}
.theme-toggle svg {
    width: 22px;
    height: 22px;
    stroke: var(--text);
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition:
        opacity 0.4s ease,
        transform 0.4s ease;
    position: absolute;
}
.sun-icon {
    opacity: 1;
    transform: rotate(0deg);
}
.moon-icon {
    opacity: 0;
    transform: rotate(-90deg);
}
body.light .sun-icon {
    opacity: 0;
    transform: rotate(90deg);
}
body.light .moon-icon {
    opacity: 1;
    transform: rotate(0deg);
}
footer {
    text-align: center;
    padding: 32px 0;
    color: var(--footer-text);
    font-size: 0.9rem;
    border-top: 1px solid var(--border);
    margin-top: 40px;
    transition:
        color 0.3s,
        border-color 0.3s;
}
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition:
        opacity 0.7s ease,
        transform 0.7s ease;
}
.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}
.lightbox img {
    max-width: 90%;
    max-height: 80vh;
    border-radius: 20px;
}
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 2rem;
    cursor: pointer;
}
/* Скроллбар */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--scrollbar-thumb);
    border-radius: 10px;
    border: 2px solid transparent;
    background-clip: padding-box;
    transition: background 0.2s;
}
::-webkit-scrollbar-thumb:hover {
    background: #a855f7;
}
html {
    scrollbar-width: thin;
    scrollbar-color: var(--scrollbar-thumb) transparent;
}
@media (max-width: 640px) {
    section {
        padding: 60px 0;
    }
    .server-meta {
        flex-direction: column;
        gap: 12px;
    }
    .features-grid {
        grid-template-columns: 1fr;
    }
    .gallery-grid {
        grid-template-columns: 1fr 1fr;
    }
}
.players-section {
    margin-top: 48px;
    background: var(--surface);
    border-radius: 24px;
    padding: 24px;
    border: 1px solid var(--border);
    backdrop-filter: blur(10px);
    transition:
        background 0.3s,
        border-color 0.3s;
}

.players-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}

.players-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text);
    margin: 0;
}

.players-header svg {
    stroke: var(--text);
}

.players-count-badge {
    background: linear-gradient(135deg, #a855f7, #7c3aed);
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: white;
    font-weight: 600;
}

.refresh-btn {
    background: var(--surface-alt);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    border-color: #a855f7;
}

.refresh-btn svg {
    stroke: var(--text);
    width: 16px;
    height: 16px;
}

.players-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px;
    max-height: 420px;
    overflow-y: auto;
    padding: 4px;
}

.player-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 18px 12px;
    text-align: center;
    transition: all 0.2s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.player-card:hover {
    transform: translateY(-3px);
    border-color: rgba(168, 85, 247, 0.5);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.player-card--special {
    border-color: rgba(168, 85, 247, 0.3);
}

.player-avatar {
    width: 56px;
    height: 56px;
    margin: 0 auto 10px;
    border-radius: 18px;
    background: var(--surface-alt);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 2px solid var(--border);
    transition: border-color 0.2s;
}

.player-card:hover .player-avatar {
    border-color: rgba(168, 85, 247, 0.4);
}

.player-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: pixelated;
}

.player-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: #fff;
    font-weight: 700;
    line-height: 1;
}

.player-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text);
    margin-bottom: 4px;
    word-break: break-word;
}

.player-role {
    font-size: 0.75rem;
    font-weight: 500;
}

.player-status::before {
    content: "";
    width: 6px;
    height: 6px;
    background: #22c55e;
    border-radius: 50%;
    display: inline-block;
}

.players-grid > .loading-skeleton {
    display: contents;
}

.skeleton-card {
    background: linear-gradient(
        90deg,
        var(--surface) 25%,
        var(--border) 50%,
        var(--surface) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: 20px;
    height: 140px;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

.empty-players {
    text-align: center;
    padding: 36px 20px;
    color: var(--text-secondary);
    grid-column: 1 / -1;
}

.empty-players svg {
    width: 56px;
    height: 56px;
    margin-bottom: 12px;
    opacity: 0.4;
    stroke: var(--text-secondary);
}

.empty-players p {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 2px;
}

.empty-players small {
    font-size: 0.85rem;
    opacity: 0.7;
}

.players-grid::-webkit-scrollbar {
    width: 5px;
}

.players-grid::-webkit-scrollbar-track {
    background: transparent;
}

.players-grid::-webkit-scrollbar-thumb {
    background: var(--scrollbar-thumb);
    border-radius: 10px;
}

.toast-notification {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: #1e1e24;
    color: #fff;
    padding: 10px 22px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-family: "Inter", sans-serif;
    z-index: 2000;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.toast-notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

@media (max-width: 640px) {
    .players-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 12px;
        max-height: 320px;
    }

    .player-card {
        padding: 14px 8px;
    }

    .player-avatar {
        width: 44px;
        height: 44px;
        border-radius: 14px;
    }
}
