/* Технологии — гибкая сетка */
.tech-stack {
    padding: 100px 0;
    background: #f8f9fa;
}

.tech-stack h2 {
    text-align: center;
    font-size: 2.8em;
    margin-bottom: 60px;
    color: #1a1a1a;
    font-weight: 700;
}

.tech-grid {
    display: grid;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Мобильный: 1 колонка */
@media (max-width: 599px) {
    .tech-grid {
        grid-template-columns: 1fr;
    }
}

/* Планшет: 2 колонки */
@media (min-width: 600px) and (max-width: 991px) {
    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Десктоп: 3 + 1 (нижняя по центру) */
@media (min-width: 992px) and (max-width: 1199px) {
    .tech-grid {
        grid-template-areas:
            "card1 card2 card3"
            ". card4 .";
        justify-items: center;
    }
    .tech-grid > div:nth-child(1) { grid-area: card1; }
    .tech-grid > div:nth-child(2) { grid-area: card2; }
    .tech-grid > div:nth-child(3) { grid-area: card3; }
    .tech-grid > div:nth-child(4) { grid-area: card4; }
}

/* Широкий экран: 4 в ряд */
@media (min-width: 1200px) {
    .tech-grid {
        grid-template-columns: repeat(4, 1fr);
        justify-items: stretch;
    }
}

/* Стиль карточки */
.tech-card {
    background: white;
    padding: 25px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transition: box-shadow 0.3s ease;
    width: 100%;
    max-width: none;
}

.tech-card:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.tech-card h3 {
    font-size: 1.3em;
    color: #2962ff;
    margin-bottom: 20px;
    font-weight: 600;
    padding-bottom: 12px;
    border-bottom: 2px solid #e0e7ff;
    position: relative;
}

.tech-card h3::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 40px;
    height: 2px;
    background: #2962ff;
}

.tech-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tech-card li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    font-size: 1.02em;
    color: #2d3748;
    font-weight: 500;
}

.tech-card li:hover {
    color: #2962ff;
}

.tech-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
    filter: brightness(1.1) contrast(1.05);
    transition: filter 0.3s ease;
    flex-shrink: 0;
}

.tech-card li:hover .tech-icon {
    filter: brightness(1.4) contrast(1.1) saturate(1.2);
}