:root {
    --bg-color: #0a0a0f;
    --text-color: #e2e8f0;
    --accent-color: #00ff66;
    --accent-glow: rgba(0, 255, 102, 0.3);
    --card-bg: rgba(20, 20, 30, 0.7);
    --hex-color: rgba(0, 255, 102, 0.05);
}

body {
    font-family: 'JetBrains Mono', Monospace;
    background-color: var(--bg-color);
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 40px 20px;
    min-height: 100vh;
    background-image: 
        radial-gradient(circle at center, transparent 0%, var(--bg-color) 70%),
        linear-gradient(30deg, var(--hex-color) 12%, transparent 12.5%, transparent 87%, var(--hex-color) 87.5%, var(--hex-color)),
        linear-gradient(-30deg, var(--hex-color) 12%, transparent 12.5%, transparent 87%, var(--hex-color) 87.5%, var(--hex-color)),
        linear-gradient(30deg, var(--hex-color) 12%, transparent 12.5%, transparent 87%, var(--hex-color) 87.5%, var(--hex-color)),
        linear-gradient(-30deg, var(--hex-color) 12%, transparent 12.5%, transparent 87%, var(--hex-color) 87.5%, var(--hex-color)),
        linear-gradient(60deg, rgba(0, 255, 102, 0.03) 25%, transparent 25.5%, transparent 75%, rgba(0, 255, 102, 0.03) 75%, rgba(0, 255, 102, 0.03)),
        linear-gradient(60deg, rgba(0, 255, 102, 0.03) 25%, transparent 25.5%, transparent 75%, rgba(0, 255, 102, 0.03) 75%, rgba(0, 255, 102, 0.03));
    background-size: 80px 140px;
}

.container {
    width: 100%;
    max-width: 450px;
    text-align: center;
    position: relative;
    z-index: 1;
}

.profile-img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 3px solid var(--accent-color);
    box-shadow: 0 0 15px var(--accent-glow);
    margin-bottom: 10px;
    object-fit: cover;
    transition: 0.3s;
}

h1 { 
    font-family: "Pixelify Sans", Sans-Serif;
    font-size: 1.6rem; 
    margin: 10px 0 5px; 
    color: var(--accent-color);
    text-shadow: 0 0 10px var(--accent-glow);
}

.bio-text { font-size: 0.9rem; opacity: 0.8; margin-bottom: 25px; }

.tabs-menu {
    display: flex;
    gap: 8px;
    margin-bottom: 25px;
    background: rgba(0, 0, 0, 0.4);
    padding: 6px;
    border-radius: 14px;
    border: 1px solid var(--accent-glow);
}

.tab-btn {
    flex: 1;
    padding: 12px 5px;
    border: none;
    background: none;
    color: var(--text-color);
    font-family: "JetBrains Mono", Monospace;
    font-size: 0.8rem;
    font-weight: bold;
    cursor: pointer;
    border-radius: 10px;
    transition: 0.3s;
    opacity: 0.6;
}

.tab-btn.active {
    background: #000000; 
    color: #39FF14;
    opacity: 1;
    box-shadow: 0 0 20px rgba(57, 255, 20, 0.6);
    font-weight: 900;
    border: 1px solid #ffffff;
}

.info-block {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 18px;
    text-align: left;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 20px;
    border: 1px solid rgba(0, 255, 102, 0.1);
    backdrop-filter: blur(5px);
}

.info-block span { color: var(--accent-color); font-weight: bold; }

.gallery-title {
    text-align: left;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
    color: var(--accent-color);
    opacity: 0.9;
}

.links { display: flex; flex-direction: column; gap: 12px; }
.link-card {
    background: var(--card-bg);
    border: 1px solid rgba(0, 255, 102, 0.15);
    padding: 15px;
    border-radius: 12px;
    text-decoration: none;
    color: white;
    font-weight: 500;
    transition: 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
}

.link-card:hover { 
    background: rgba(0, 255, 102, 0.1); 
    border-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.gallery-item {
    aspect-ratio: 1/1;
    background: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: 0.3s;
}

.gallery-item:hover { 
    border-color: var(--accent-color); 
    box-shadow: 0 0 10px var(--accent-glow);
}

.gallery-item img { width: 100%; height: 100%; object-fit: cover; }

.gallery-sub-content {
    display: none;
    animation: slideUp 0.4s ease;
}

.gallery-sub-content.active {
    display: block;
}

.ref-large {
    width: 100%;
    aspect-ratio: auto;
    background: var(--card-bg);
}

.ref-large img {
    width: 100%;
    height: auto;
    display: block;
}

.easter-egg-zone {
    position: fixed !important;
    top: 0; left: 0;
    width: 60px; height: 60px;
    z-index: 10000;
    color: transparent;
    display: flex; justify-content: center; align-items: center;
    text-decoration: none;
    transition: 0.3s;
}
.easter-egg-zone:hover, .easter-egg-zone.visible {
    color: var(--accent-color);
    background: rgba(0, 255, 102, 0.05);
}

.ai-credit { margin-top: 40px; font-size: 0.7rem; opacity: 0.3; }

.tab-content { display: none; animation: slideUp 0.4s ease; }
.tab-content.active { display: block; }

@keyframes slideUp {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

#lightbox {
    display: none;
    position: fixed;
    z-index: 10001;
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%;
    background: rgba(5, 5, 10, 0.95);
    justify-content: center; 
    align-items: center;
    cursor: pointer;
}

#lightbox img { 
    max-width: 90%; 
    max-height: 85vh;
    object-fit: contain;
    border: 2px solid var(--accent-color); 
    border-radius: 10px; 
    box-shadow: 0 0 20px var(--accent-glow);
}

.link-card, .tab-btn.active, .info-block {
    position: relative;
    overflow: hidden;
    background-color: var(--card-bg);
    background-image: 
        linear-gradient(rgba(0, 255, 102, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 102, 0.05) 1px, transparent 1px);
    background-size: 15px 15px;
    border: 1px solid rgba(0, 255, 102, 0.2);
    backdrop-filter: blur(8px);
}

.lore-container {
    max-height: 350px;
    overflow-y: auto;
    white-space: pre-wrap;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    padding-left: 15px;
    border-left: 2px solid var(--accent-color);
}

.lore-container::-webkit-scrollbar { width: 4px; }
.lore-container::-webkit-scrollbar-thumb { background: var(--accent-color); border-radius: 10px; }

.sub-tabs {
    margin-bottom: 10px;
    background: rgba(0, 255, 102, 0.05);
}

.sub-tabs .tab-btn {
    padding: 8px 5px;
    font-size: 0.7rem;
}

.lang-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.6);
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    padding: 8px 12px;
    border-radius: 8px;
    font-family: 'JetBrains Mono', monospace;
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent-glow);
    transition: 0.3s;
}

.lang-btn:hover {
    background: var(--accent-color);
    color: black;
}

.now-playing {
    font-size: 0.7rem;
    color: var(--accent-color);
    margin-top: 10px;
    font-family: 'JetBrains Mono', monospace;
    opacity: 0.8;
    letter-spacing: 0.5px;
}

.music-icon {
    display: inline-block;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
    100% { transform: scale(1); opacity: 0.8; }
}

body.emergency-mode {
    --accent-color: #ff3333; 
    --accent-glow: rgba(255, 51, 51, 0.5);
    filter: sepia(0.5) saturate(2);
    animation: alarm-shake 0.2s infinite;
}

@keyframes alarm-shake {
    0% { transform: translate(0, 0); }
    25% { transform: translate(1px, 1px); }
    50% { transform: translate(-1px, -1px); }
    75% { transform: translate(1px, -1px); }
    100% { transform: translate(0, 0); }
}

.lore-container::after {
    content: "|";
    animation: blink 1s infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

#track-name::after {
    content: "|";
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

.btn-icon {
    width: 20px;
    height: 20px;
    margin-right: 10px; 
    filter: invert(1); 
    transition: 0.3s;
}

.link-card:hover .btn-icon {
    filter: invert(48%) sepia(79%) saturate(2476%) hue-rotate(87deg) brightness(118%) contrast(119%);
}

.link-card:hover .btn-txt {
    color: var(--accent-color)
}

/* Анимация для геймпада, работающая так же, как и для музыки */
.game-icon {
    display: inline-block;
    animation: pulse 2s infinite;
    animation-delay: 0.5s; /* Небольшое смещение, чтобы они не пульсировали строго одновременно */
}

#discord-game {
    font-size: 0.7rem;
    color: var(--accent-color);
    font-family: 'JetBrains Mono', monospace;
    opacity: 0.8;
    letter-spacing: 0.5px;
}
