/* Services Navigation and Box Styles */
.services-nav {
    background: white;
    border-radius: 50px;
    padding: 8px;
    display: flex;
    flex-wrap: nowrap; /* Changed from wrap to nowrap for horizontal scrolling */
    justify-content: flex-start; /* Changed from center to flex-start */
    gap: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    max-width: 900px;
    margin: 0 auto 20px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    white-space: nowrap;
    scrollbar-width: none; /* Hide scrollbar for Firefox */
    -ms-overflow-style: none; /* Hide scrollbar for IE and Edge */
}

/* Hide scrollbar for Chrome, Safari and Opera */
.services-nav::-webkit-scrollbar {
    display: none;
}

.services-nav button {
    background: #f5f5f5;
    color: #333;
    border: none;
    padding: 8px 16px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
    min-width: 100px;
}

.services-nav button.active {
    background: #60349e;
    color: white;
}

.services-nav button:hover {
    background: #e0e0e0;
}

.services-nav button.active:hover {
    background: #4a2a7a;
}

.box-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.box {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
}

.box i {
    font-size: 40px;
    color: #60349e;
    margin-bottom: 15px;
}

.box h3 {
    font-size: 18px;
    margin: 15px 0;
    color: #333;
    font-weight: 600;
}

/* Box hover effects */
.box:hover {
    transform: translateY(-10px);
    transition: 0.3s;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .services-nav {
        padding: 5px 10px;
        gap: 8px;
        overflow-x: auto;
        justify-content: flex-start;
        width: 92%;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        position: relative;
    }
    
    .services-nav:after {
        content: '';
        position: absolute;
        right: 0;
        top: 0;
        height: 100%;
        width: 20px;
        background: linear-gradient(to right, transparent, white);
        pointer-events: none;
    }
    
    .services-nav button, 
    .services-nav a.service-nav-item {
        font-size: 13px;
        padding: 8px 12px;
        min-width: auto;
        white-space: nowrap;
        flex-shrink: 0;
    }
    
    .box-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 10px;
        margin: 0 auto;
        width: 95%;
    }
    
    .box {
        padding: 15px;
        min-height: 130px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    
    .box i {
        font-size: 30px;
    }
    
    .box h3 {
        font-size: 16px;
        margin: 10px 0;
        line-height: 1.2;
    }
}

@media (max-width: 480px) {
    .box-container {
        grid-template-columns: 1fr;
        width: 90%;
    }
    
    .services-nav {
        width: 90%;
        padding: 5px;
        margin-bottom: 15px;
    }
    
    .services-nav button,
    .services-nav a.service-nav-item {
        font-size: 12px;
        padding: 6px 10px;
        border-radius: 20px;
    }
    
    .service-card {
        padding: 20px !important;
    }
    
    .service-card h4 {
        font-size: 18px !important;
    }
    
    .service-card p,
    .service-card ul {
        font-size: 14px !important;
    }
    
    .service-card ul li {
        margin-bottom: 5px !important;
    }
    
    .box {
        min-height: 100px;
    }
}
