/* ===== PROJECTS GRID ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

/* ===== PROJECT CARD ===== */
.project-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

/* Оранжевая полоска сверху — единственный декоративный слой */
.project-card__accent {
    height: 3px;
    background: var(--gradient-primary);
    flex-shrink: 0;
}

.project-card__body {
    padding: 1.5rem 1.5rem 1rem;
    flex: 1;
}

.project-card__title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.project-card__desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.65;
    margin: 0;
}

.project-card__footer {
    padding: 1rem 1.5rem 1.25rem;
    border-top: 1px solid var(--border-light);
    display: flex;
    align-items: center;
}

.project-card__link {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--primary);
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: gap 0.2s ease, color 0.2s ease;
}

.project-card__link:hover {
    color: var(--primary-dark);
    gap: 0.65rem;
}

/* ===== MOBILE ===== */
@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    /* На мобиле убираем hover-подъём — он не работает на touch */
    .project-card:hover {
        transform: none;
        box-shadow: none;
    }

    /* Вместо этого — активное состояние при нажатии */
    .project-card:active {
        border-color: var(--primary);
    }

    .project-card__body {
        padding: 1.25rem 1.25rem 0.75rem;
    }

    .project-card__footer {
        padding: 0.75rem 1.25rem 1rem;
    }

    .project-card__title {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .projects-grid {
        gap: 0.75rem;
    }
}

/* ===== СТИЛИ ДЛЯ СТРАНИЦЫ ДЕТАЛЬНОГО РЕШЕНИЯ ===== */

.solution-section {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.solution-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.section-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-left: 5px solid var(--primary);
    padding-left: 1.25rem;
}

.section-content {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

/* Вложенные заголовки */
.section-content h2,
.section-content h3 {
    margin-top: 1.5em;
    margin-bottom: 0.75em;
    color: var(--text-primary);
    font-weight: 600;
}

.section-content h2 {
    font-size: 1.4rem;
    border-bottom: 1px dashed var(--border-light);
    padding-bottom: 0.5rem;
}

.section-content h3 {
    font-size: 1.2rem;
}

.section-content ul,
.section-content ol {
    margin: 1rem 0 1rem 1.5rem;
}

.section-content li {
    margin-bottom: 0.5rem;
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    .solution-section {
        margin-bottom: 2rem;
        padding-bottom: 1rem;
    }
    .section-title {
        font-size: 1.5rem;
        padding-left: 1rem;
        border-left-width: 4px;
    }
    .section-content {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .section-title {
        font-size: 1.35rem;
    }
}