.header {
    position: relative;
    background-color: var(--dark-bg);
    min-height: 100vh;
    overflow: hidden;
    padding-top: 30px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 80px; /* Добавляем отступ снизу */
}

/* Navigation */
.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    position: relative;
    z-index: 10;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-light);
    display: flex;
    align-items: center;
}

.logo-circle {
    width: 24px;
    height: 24px;
    background-color: var(--primary-color);
    border-radius: 50%;
    margin-right: 10px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    color: var(--text-light);
    font-weight: 500;
    position: relative;
    padding-bottom: 5px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-button {
    background-color: var(--primary-color);
    color: var(--dark-bg);
    border: none;
    padding: 8px 18px;
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-button:hover {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 101;
}

.hamburger span {
    display: block;
    width: 30px;
    height: 2px;
    background-color: var(--text-light);
    transition: all 0.3s ease;
}

/* Hero section */
.hero {
    position: relative;
    z-index: 2;
    min-height: calc(100vh - 100px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
}

.social-link {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 16px;
    transition: all 0.3s ease;
}

.social-link:hover {
    background-color: var(--primary-color);
    color: var(--dark-bg);
    border-color: var(--primary-color);
}

.hero-content {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 30px;
    text-transform: uppercase;
    text-align: center;
}

.highlight {
    color: var(--primary-color);
    position: relative;
    display: block;
    text-decoration: underline;
}

.hero-description {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 40px;
    line-height: 1.6;
    color: var(--text-gray);
    text-align: center;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    justify-content: center;
}

.arrow-icon {
    font-size: 20px;
}

/* Stats section */
.stats-cards {
    display: flex;
    justify-content: space-between;
    margin-top: 80px;
    gap: 30px;
    width: 100%;
}

.stats-card {
    flex: 1;
    background-color: #171717; /* Единый темный фон для обоих блоков */
    border: 1px solid var(--border-color);
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    height: 340px; /* Фиксированная высота для обоих блоков */
    display: flex;
}

.stats-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    pointer-events: none;
    z-index: 1;
}

/* Стили для правого блока */
.stats-card:nth-child(2) {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 0;
}

.stats-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 20px;
    background-color: rgba(24, 24, 24, 0.6);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    height: calc(340px / 3); /* Ровно треть высоты блока */
}

.stats-item:last-child {
    border-bottom: none;
}

.stats-item .icon {
    color: var(--primary-color);
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
}

.stats-item-text {
    font-weight: 600;
    font-size: 1rem;
}

/* Редизайн левого блока в header по новому макету */
.stats-card:first-child {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    text-align: center;
}

.stats-card-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 30px;
    height: 100%;
}

/* Стили и анимация для иконки кода */
.code-icon-container {
    margin-bottom: 20px;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.code-icon {
    width: 60px;
    height: 60px;
    color: var(--primary-color);
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}



/* Улучшенная анимация свечения для иконки */
/* Полностью новая версия анимации пульсации */
@keyframes simplePulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Полное переопределение стилей иконки */
.code-symbol {
    stroke: var(--primary-color) !important;
    fill: transparent;
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
    animation: simplePulse 3s infinite ease-in-out;
    transform-origin: center;
    /* Убираем все свойства, которые могут влиять на цвет */
}

/* Убираем любую тень или другие эффекты из родительских элементов */
.code-icon svg {
    width: 100%;
    height: 100%;
    background-color: rgba(17, 17, 17, 0.3);
    border-radius: 8px;
    padding: 5px;
    border: 1px solid rgba(196, 255, 0, 0.2);
    /* Убираем filter и другие эффекты */
}

.stats-card-title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 12px;
    text-transform: uppercase;
    color: var(--primary-color);
    letter-spacing: 1px;
}

.stats-card-subtitle {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 15px;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.stack-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stack-dot {
    width: 6px;
    height: 6px;
    background-color: var(--primary-color);
    border-radius: 50%;
    display: inline-block;
}

.stats-card-content {
    font-size: 0.95rem;
    color: var(--text-gray);
    line-height: 1.5;
    max-width: 380px;
}

/* Responsive styles for header */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .stats-cards {
        flex-direction: column;
        gap: 20px;
    }
    
    .stats-card {
        max-width: 100%;
        height: auto; /* Сбрасываем фиксированную высоту */
        margin-left: 0;
        margin-right: 0;
    }

    .stats-card:first-child {
        margin-bottom: 20px;
    }

    .stats-item {
        height: auto; /* Отменяем фиксированную высоту элементов на мобильных */
    }

    .stats-card-title {
        font-size: 1.4rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .primary-button, .secondary-button {
        width: 100%;
    }

    .stats-cards {
        width: 100%;
    }
    
    /* Первый блок (код) */
    .stats-card:first-child {
        padding: 40px 20px;
        height: auto;
        min-height: 340px; /* Минимальная высота для первого блока */
    }
    
    /* Второй блок (статистика) */
    .stats-card:nth-child(2) {
        display: flex;
        flex-direction: column;
        height: auto;
    }
    
    /* Выравниваем элементы статистики в мобильной версии */
    .stats-item {
        padding: 20px;
        height: auto;
        min-height: 80px; /* Минимальная высота каждого элемента */
        display: flex;
        align-items: center;
        justify-content: center
    }
    
    .stats-item .icon {
        flex-shrink: 0;
    }
    
    .stats-item-text {
        font-size: 0.95rem;
        line-height: 1.4;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .stats-card {
        padding: 0;
    }

    .stats-card-title {
        font-size: 1.4rem;
    }

    .stats-card-subtitle {
        gap: 8px;
    }

    .stats-item {
        padding: 15px;
        min-height: 70px;
    }

    .stats-item-text {
        font-size: 0.9rem;
    }

    .code-icon {
        width: 60px;
        height: 60px;
    }

    .stats-card:first-child {
        padding: 30px 15px;
    }
}