:root {
    --primary: #0f0;
    --primary-dark: #0a0;
    --primary-light: #3f3;
    --bg-dark: #050905;
    --bg-light: #0a120a;
    --text-light: #e0ffe0;
    --text-gray: #8f9e8f;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'WDXL Lubrifont JP N', sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
    transition: all 0.3s ease;
}

/* Абстрактные элементы фона */
.background-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.grid-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(90deg, rgba(0, 30, 0, 0.05) 1px, transparent 1px),
        linear-gradient(180deg, rgba(0, 30, 0, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
}

.hex-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.1;
    background-image: 
        radial-gradient(circle at center, var(--primary) 0.5px, transparent 1px);
    background-size: 50px 50px;
    background-position: 0 0, 25px 25px;
}

/* Контент */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 30px;
    position: relative;
    z-index: 10;
    transition: padding 0.3s ease;
}

/* Навигация */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 20px;
    z-index: 100;
    background: rgba(5, 15, 5, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 255, 0, 0.1);
    transition: all 0.3s ease;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 40px;
    transition: gap 0.3s ease;
}

nav a {
    color: var(--text-gray);
    text-decoration: none;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    font-size: 1rem;
    padding: 10px 15px;
    border-radius: 30px;
    transition: all 0.3s ease;
    position: relative;
}

nav a:hover, nav a.active {
    color: var(--primary);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

nav a:hover::after, nav a.active::after {
    width: 60%;
}

/* Заголовок */
.hero {
    text-align: center;
    margin: 100px 0 120px;
    position: relative;
    overflow: hidden;
    transition: margin 0.3s ease;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 10;
}

.hero h1 {
    font-size: 5.5rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 5px;
    margin-bottom: 20px;
    background: linear-gradient(to right, var(--primary-light), var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 15px rgba(0, 255, 0, 0.3);
    position: relative;
    transition: all 0.5s ease;
}

.hero h2 {
    font-size: 1.8rem;
    font-weight: 300;
    color: var(--primary-light);
    margin-bottom: 40px;
    letter-spacing: 3px;
    position: relative;
    transition: all 0.5s ease;
}

/* Контент h2 для разных разрешений */
.hero h2::before {
    content: "DEVELOPER OF 'COOL' GAMES";
    display: block;
}

.hero h2::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: linear-gradient(to right, transparent, var(--primary), transparent);
    transition: all 0.3s ease;
}

.hero-abstract {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 255, 0, 0.05) 0%, transparent 70%);
    z-index: 0;
    transition: all 0.5s ease;
}

/* Информация */
.info-section {
    background: rgba(5, 15, 5, 0.5);
    border: 1px solid rgba(0, 255, 0, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 50px;
    margin-bottom: 80px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.info-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(to right, transparent, var(--primary), transparent);
}

.info-section h3 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 30px;
    text-transform: uppercase;
    letter-spacing: 2px;
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
}

.info-section h3::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 50%;
    height: 2px;
    background: var(--primary);
    transition: all 0.3s ease;
}

.info-section p {
    font-size: 1.2rem;
    line-height: 1.8;
    margin-bottom: 25px;
    color: var(--text-light);
    transition: all 0.3s ease;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 40px;
    transition: all 0.3s ease;
}

.skill-card {
    background: rgba(10, 30, 10, 0.3);
    border: 1px solid rgba(0, 255, 0, 0.1);
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.skill-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    box-shadow: 0 5px 15px rgba(0, 255, 0, 0.2);
}

.skill-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.skill-name {
    font-weight: 600;
    color: var(--text-light);
    transition: all 0.3s ease;
}

/* Проекты */
.projects-section {
    margin-bottom: 80px;
    transition: all 0.3s ease;
}

.projects-section h3 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 60px;
    text-transform: uppercase;
    letter-spacing: 3px;
    text-align: center;
    transition: all 0.3s ease;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 40px;
    transition: all 0.3s ease;
}

.project-card {
    background: rgba(10, 20, 10, 0.5);
    border: 1px solid rgba(0, 255, 0, 0.1);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
    transition: all 0.4s ease;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: var(--primary);
    box-shadow: 0 15px 30px rgba(0, 255, 0, 0.2);
}

.project-image {
    height: 400px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(45deg, 
            transparent 48%, 
            rgba(0, 255, 0, 0.05) 50%, 
            transparent 52%);
    background-size: 10px 10px;
    z-index: 2;
}

.project-content {
    padding: 25px;
    transition: all 0.3s ease;
}

.project-title {
    font-size: 1.5rem;
    color: var(--primary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.project-title i {
    margin-right: 10px;
}

.project-description {
    color: var(--text-gray);
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.tech-tag {
    background: rgba(0, 255, 0, 0.1);
    color: var(--primary-light);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.project-link {
    display: inline-block;
    padding: 8px 20px;
    background: transparent;
    color: var(--primary);
    text-decoration: none;
    border: 1px solid var(--primary);
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.project-link:hover {
    background: rgba(0, 255, 0, 0.1);
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.3);
}

/* Контакты */
.contacts-section {
    margin-bottom: 80px;
    transition: all 0.3s ease;
}

.contacts-section h3 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 60px;
    text-transform: uppercase;
    letter-spacing: 3px;
    text-align: center;
    transition: all 0.3s ease;
}

.social-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
    transition: all 0.3s ease;
}

.social-card {
    width: 220px;
    height: 220px;
    perspective: 1000px;
    transition: all 0.3s ease;
}

.social-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s;
    transform-style: preserve-3d;
}

.social-card:hover .social-inner {
    transform: rotateY(180deg);
}

.social-front, .social-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.social-front {
    background: rgba(10, 30, 10, 0.7);
    border: 1px solid rgba(0, 255, 0, 0.2);
}

.social-back {
    background: rgba(0, 20, 0, 0.8);
    border: 1px solid rgba(0, 255, 0, 0.4);
    transform: rotateY(180deg);
}

.social-icon {
    font-size: 3.5rem;
    margin-bottom: 15px;
    color: var(--primary);
    text-shadow: 0 0 10px rgba(0, 255, 0, 0.5);
    transition: all 0.3s ease;
}

.social-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.social-link {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 25px;
    background: rgba(0, 30, 0, 0.7);
    color: var(--primary);
    text-decoration: none;
    border-radius: 30px;
    border: 1px solid var(--primary);
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: rgba(0, 255, 0, 0.2);
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.4);
    transform: translateY(-3px);
}

/* Футер */
footer {
    text-align: center;
    padding: 30px 0 20px;
    border-top: 1px solid rgba(0, 255, 0, 0.1);
    position: relative;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

footer p {
    font-size: 1.1rem;
    color: var(--text-gray);
    letter-spacing: 1px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
    width: 100%;
}

.footer-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1px;
    background-color: var(--background-dark);
    color: var(--primary-light);
    width: 100%;
}

.footer-grid::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(45deg, 
            transparent 48%, 
            rgba(0, 255, 0, 0.05) 50%, 
            transparent 52%);
    background-size: 10px 10px;
    z-index: 2;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
    transition: all 0.3s ease;
    width: 100%;
}

.footer-links a {
    color: var(--text-gray);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--primary);
}

/* Частицы */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.7;
}

/* Эффекты появления */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Глитч эффект */
.glitch {
    position: relative;
    font-family: 'Press Start 2P', cursive;
    font-weight: 900;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 #ff00ff;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 #00ffff;
}

/* Эффект печатающей машинки */
.typewriter {
    font-family: 'Press Start 2P', cursive;
    overflow: hidden;
    white-space: nowrap;
    margin: 0 auto;
    letter-spacing: 0.15em;
    position: relative;
    display: inline-block;
}

.typewriter .caret {
    position: absolute;
    right: -15px; /* Увеличили отступ от текста */
    color: var(--primary);
    animation: blink-caret 0.75s step-end infinite;
    font-weight: 100; /* Делаем тоньше */
    opacity: 0.8; /* Немного прозрачности */
    font-size: 1.2em; /* Чуть меньше размер */
    transform: translateX(5px); /* Дополнительный сдвиг вправо */
}

.typewriter::after {
    content: '|';
    position: absolute;
    right: 0;
    color: var(--primary);
    animation: blink-caret 0.75s step-end infinite;
}

/* Стили для кнопки копирования */
.copy-btn {
	font-family: 'WDXL Lubrifont JP N', sans-serif;
    display: inline-block;
    margin-top: 15px;
    padding: 10px 25px;
    background: rgba(0, 30, 0, 0.7);
    color: var(--primary);
    text-decoration: none;
    border-radius: 30px;
    border: 1px solid var(--primary);
    font-weight: 600;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: rgba(0, 255, 0, 0.2);
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.3);
}

.crypto-address {
    display: block;
    font-family: monospace;
    margin: 10px 0;
    word-break: break-all;
    color: var(--primary-light);
    font-size: 0.9rem;
}

#view-counter {
    font-size: 0.9rem;
    color: var(--primary-light);
    margin-top: 10px;
    animation: textGlow 3s infinite alternate;
}

.footer-text {
    font-size: 0.9rem;
    color: var(--primary-light);
    margin-top: 10px;
    animation: textGlow 3s infinite alternate;
    text-align: center; /* Центрирование текста по горизонтали */
}

/* Адаптивность */
@media (max-width: 1200px) {
    .hero h1 {
        font-size: 4.5rem;
        letter-spacing: 3px;
    }
    .hero h2 {
        font-size: 1.5rem;
    }
    .info-section h3, 
    .projects-section h3, 
    .contacts-section h3 {
        font-size: 2rem;
    }
    .hero-abstract {
        width: 500px;
        height: 500px;
    }
	.social-links {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .hero h2::before {
        content: "GAME DEVELOPER";
    }
    
    .hero h1 {
        font-size: 4rem;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
    
    .social-card {
        width: 180px;
        height: 180px;
    }
    
    .social-icon {
        font-size: 3rem;
    }
    
    .typewriter::after {
        right: -5px;
    }
}

@media (max-width: 768px) {
    nav ul {
        gap: 15px;
    }
    
    nav a {
        font-size: 0.9rem;
        padding: 8px 12px;
    }
    
    .hero {
        margin: 80px 0 100px;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .hero h2 {
        font-size: 1.4rem;
    }
    
    .info-section {
        padding: 30px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .social-links {
        gap: 25px;
        grid-template-columns: repeat(2, 1fr);
    }
    
    .project-image {
        height: 350px;
    }
    
    .hero-abstract {
        width: 400px;
        height: 400px;
    }
    
    .typewriter::after {
        right: -3px;
    }
}

@media (max-width: 576px) {
    .hero h2::before {
        content: "DEVELOPER";
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .social-card {
        width: 150px;
        height: 150px;
    }
    
    .social-icon {
        font-size: 2.5rem;
    }
    
    .social-name {
        font-size: 1.1rem;
    }
    
    .container {
        padding: 60px 20px;
    }
    
    .hero {
        margin: 60px 0 80px;
    }
    
    .hero h2 {
        font-size: 1.2rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    
    .hero-abstract {
        width: 300px;
        height: 300px;
    }
    
    .typewriter::after {
        right: -2px;
    }
}

@media (max-width: 480px) {
    .social-links {
        grid-template-columns: 1fr;
    }
}

/* Плавные переходы для адаптивных изменений */
@media (prefers-reduced-motion: no-preference) {
    .hero h1, 
    .hero h2,
    .info-section h3,
    .projects-section h3,
    .contacts-section h3,
    .skill-card,
    .project-card,
    .social-card {
        transition: all 0.5s ease;
    }
    
    .project-image img {
        transition: transform 0.7s cubic-bezier(0.25, 0.45, 0.45, 0.95);
    }
    
    .social-inner {
        transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    }
}

/* Плавное изменение размера шрифта при ресайзе */
html {
    text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
}
