/**
 * TP Process Steps — widget styles
 *
 * @package Technoproekt
 * @author  Kkalganov <https://kkalganov.com>
 */

/* ==========================================================================
   Grid — managed by the widget itself (repeater-based)
   ========================================================================== */

.tp-process-steps {
    width: 100%;
}

.tp-process-steps__grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 30px !important;
    width: 100% !important;
}

/* ==========================================================================
   Process Step Card
   ========================================================================== */

.tp-process-step {
    padding: 40px 32px;
    text-align: center;
    background: var(--tp-white);
    transition: all 0.4s;
    position: relative;
}

.tp-process-step:hover {
    background: var(--tp-green-dark);
}

/* Force widget to fill container — override Elementor grid/flex constraints */
.elementor-widget-tp_process_step {
    width: 100% !important;
    max-width: 100% !important;
    --container-widget-width: 100% !important;
    grid-column: 1 / -1 !important; /* Span all columns if parent is a grid */
}

.elementor-widget-tp_process_step > .elementor-widget-container {
    width: 100%;
}

.tp-process-step__number {
    width: 56px;
    height: 56px;
    background: var(--tp-green-main);
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Unbounded', system-ui, sans-serif;
    font-size: 20px;
    font-weight: 800;
    color: var(--tp-white);
    clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
    transition: all 0.4s;
}

.tp-process-step:hover .tp-process-step__number {
    background: var(--tp-yellow);
    color: var(--tp-dark);
}

.tp-process-step__title {
    font-family: 'Unbounded', system-ui, sans-serif !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: var(--tp-text);
    text-transform: uppercase !important;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    transition: color 0.4s;
}

.tp-process-step:hover .tp-process-step__title {
    color: var(--tp-white) !important;
}

.tp-process-step__desc {
    font-size: 14px;
    color: var(--tp-text-light);
    line-height: 1.7;
    transition: color 0.4s;
}

.tp-process-step:hover .tp-process-step__desc {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* ==========================================================================
   Cream card background variant
   ========================================================================== */

.tp-process-steps--cream .tp-process-step {
    background: var(--tp-cream);
}

.tp-process-steps--cream .tp-process-step:hover {
    background: var(--tp-green-dark);
}

/* ==========================================================================
   Connector arrow between steps (desktop only)
   ========================================================================== */

@media (min-width: 1025px) {
    .tp-process-step::after {
        content: '';
        position: absolute;
        top: 50%;
        right: -20px;
        transform: translateY(-50%);
        width: 0;
        height: 0;
        border-top: 8px solid transparent;
        border-bottom: 8px solid transparent;
        border-left: 10px solid var(--tp-cream-warm);
        z-index: 1;
    }

    .tp-process-step:last-child::after {
        display: none;
    }
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (min-width: 769px) {
    .tp-process-steps__grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (min-width: 1025px) {
    .tp-process-steps__grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}
