/* Секция схемы работы */
.workflow-section {
    max-width: 1200px;
    margin: 80px auto;
    padding: 0 20px;
    position: relative;
    scroll-margin-top: 100px;
}

.workflow-section::before {
    content: '';
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 400px;
    height: 4px;
    background: linear-gradient(90deg, #e70000 0%, #ff3333 50%, #e70000 100%);
    border-radius: 2px;
}

.workflow-container {
    position: relative;
}

/* Заголовок и навигация */
.workflow-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 50px;
}

.workflow-title-block {
    flex: 1;
}

.workflow-subtitle {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: #e70000;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.workflow-title {
    font-size: 36px;
    font-weight: 600;
    color: #000;
    margin: 0;
    line-height: 1.2;
}

.workflow-nav {
    display: flex;
    gap: 12px;
}

.workflow-nav-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid #e8e8e8;
    background: #fff;
    color: #333;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.workflow-nav-btn:hover:not(:disabled) {
    border-color: #e70000;
    background: #e70000;
    color: #fff;
    transform: translateY(-2px);
}

.workflow-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Контейнер слайдера */
.workflow-slider {
    position: relative;
    overflow: hidden;
    padding: 20px 0;
    margin: 0 -20px;
    cursor: grab;
}

.workflow-slider:active {
    cursor: grabbing;
}

/* Трек слайдера */
.slider-track {
    display: flex;
    gap: 24px;
    transition: transform 0.6s cubic-bezier(0.2, 1, 0.3, 1);
    will-change: transform;
    padding: 0 20px;
    user-select: none;
}

/* Карточка шага */
.workflow-step {
    flex: 0 0 280px;
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid #eee;
    position: relative;
    transition: all 0.3s ease;
    min-height: 280px;
    display: flex;
    flex-direction: column;
}

.workflow-step:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
    border-color: #e70000;
}

.step-number {
    position: absolute;
    top: -20px;
    left: 30px;
    width: 40px;
    height: 40px;
    background: #e70000;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(231, 0, 0, 0.3);
}

.step-content {
    margin-top: 10px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.step-title {
    font-size: 20px;
    font-weight: 600;
    color: #000;
    margin: 0 0 15px 0;
    line-height: 1.3;
}

.step-description {
    font-size: 15px;
    line-height: 1.6;
    color: #444;
    margin: 0 0 20px 0;
    flex: 1;
}

.step-btn {
    display: inline-block;
    padding: 12px 24px;
    background: #e70000;
    color: #fff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    align-self: flex-start;
    margin-top: auto;
}

.step-btn:hover {
    background: #cc0000;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(231, 0, 0, 0.3);
}

/* Адаптивность */
@media (max-width: 992px) {
    .workflow-section {
        margin: 60px auto;
        padding: 0 15px;
    }

    .workflow-title {
        font-size: 32px;
    }

    .workflow-step {
        flex: 0 0 260px;
        padding: 25px;
    }

    .step-title {
        font-size: 19px;
    }

    .step-description {
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .workflow-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        margin-bottom: 40px;
    }

    .workflow-nav {
        align-self: flex-start;
    }

    .workflow-title {
        font-size: 28px;
    }

    .workflow-slider {
        margin: 0 -15px;
        padding: 15px 0;
    }

    .slider-track {
        padding: 0 15px;
        gap: 20px;
    }

    .workflow-step {
        flex: 0 0 240px;
        min-height: 260px;
        padding: 20px;
    }

    .step-number {
        width: 36px;
        height: 36px;
        font-size: 18px;
        top: -18px;
        left: 20px;
    }

    .step-title {
        font-size: 18px;
        margin-bottom: 12px;
    }

    .step-description {
        font-size: 13px;
        margin-bottom: 15px;
    }

    .step-btn {
        padding: 10px 20px;
        font-size: 13px;
    }
}

@media (max-width: 576px) {
    .workflow-section {
        margin: 50px auto;
        padding: 0 10px;
    }

    .workflow-title {
        font-size: 24px;
    }

    .workflow-subtitle {
        font-size: 11px;
    }

    .workflow-nav-btn {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }

    .workflow-step {
        flex: 0 0 220px;
        min-height: 240px;
        padding: 18px;
    }

    .step-number {
        width: 32px;
        height: 32px;
        font-size: 16px;
        top: -16px;
        left: 18px;
    }

    .step-title {
        font-size: 17px;
    }

    .step-description {
        font-size: 12px;
        line-height: 1.5;
    }
}

@media (max-width: 480px) {
    .workflow-step {
        flex: 0 0 200px;
        min-height: 220px;
    }

    .step-title {
        font-size: 16px;
    }

    .workflow-nav-btn {
        width: 40px;
        height: 40px;
    }
}

/* Индикатор загрузки при drag */
.slider-track.dragging {
    transition: none;
    cursor: grabbing;
}

/* Активный шаг */
.workflow-step.active {
    border-color: #e70000;
    box-shadow: 0 10px 35px rgba(231, 0, 0, 0.15);
}

/* Скрыть горизонтальный скроллбар */
.workflow-slider::-webkit-scrollbar {
    display: none;
}