/* Service Process Module - Advanced Layout Support */

/* 1. Reset and Container */
.service_process_module ol.process-steps {
    list-style: none;
    margin: 0;
    padding: 0;
    /* PHP now injects display: grid or flex and the gap here */
}

/* 2. The Step Item */
.service_process_module li.process-step {
    list-style: none;
    position: relative;
    transition: background-color 0.3s ease;
    opacity: 0; /* Prepared for animation */
    box-sizing: border-box;
    
    /* When Equalize is ON, PHP adds display: flex to this li. 
       We ensure the content inside stretches correctly: */
    display: flex; 
    overflow: hidden; 
}

/* Vertical Layout specifics */
.service_process_module section.align-left li.process-step {
    flex-direction: row;
    align-items: center; /* Default, overridden by PHP text_v_align */
}

/* Horizontal Grid Layout specifics */
.service_process_module section.align-horizontal li.process-step {
    flex-direction: column;
    text-align: center;
}

/* 3. Indicators (Number/Icon) */
.service_process_module .process-number,
.service_process_module .process-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    z-index: 2;
    transition: transform 0.3s ease;
    text-align: center;
}

/* 4. The Text Block (This is the secret to equal heights) */
.service_process_module .process-text {
    flex: 1; /* Forces the text container to fill the remaining height/width */
    padding: 1.25rem;
    font-weight: 500;
    line-height: 1.4;
    display: flex;
    align-items: inherit; /* Inherits the vertical alignment chosen in PHP */
    justify-content: inherit; /* Keeps horizontal alignment consistent */
}

.service_process_module section.align-horizontal .process-text {
    justify-content: center;
}

/* 5. Hover Effects */
.service_process_module .process-step:hover .process-number,
.service_process_module .process-step:hover .process-icon {
    transform: scale(1.1); /* Increased slightly to test the overflow */
    z-index: 10; /* Ensure it pops to the front */
}

/* 6. Mobile Responsiveness */
@media (max-width: 767px) {
    .service_process_module ol.process-steps {
        grid-template-columns: 1fr !important; /* Force single column on mobile */
    }
    
    .service_process_module section.align-horizontal li.process-step {
        flex-direction: row; /* Switch to row layout on mobile for better readability */
        text-align: left;
    }
}

/* 7. Animations */
.service_process_module .animate-fade { animation: fadeIn 0.6s forwards; }
.service_process_module .animate-slide { animation: fadeInUp 0.6s forwards; }
.service_process_module .animate-zoom { animation: zoomIn 0.6s forwards; }

@keyframes fadeIn { from {opacity:0;} to {opacity:1;} }
@keyframes fadeInUp { from {opacity:0; transform:translateY(20px);} to {opacity:1; transform:translateY(0);} }
@keyframes zoomIn { from {opacity:0; transform:scale(0.8);} to {opacity:1; transform:scale(1);} }