/* General Styles for the Services Page */
.services-section {
    padding: 60px 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa; /* Light background for the section */
}

.services-container {
    max-width: 1200px;
    margin: auto;
    text-align: center;
}

.section-title {
    font-size: 2.5em; /* Larger, more prominent title */
    color: #212529;
    margin-bottom: 15px;
    font-weight: 700;
}

.section-description {
    font-size: 1.1em;
    color: #6c757d;
    margin-bottom: 50px;
    line-height: 1.6;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Page Header Specific Styles (moved from inline for better organization) */
.page-header-section {
    position: relative; /* For image overlay */
    overflow: hidden; /* Ensure background doesn't overflow */
    /* Dynamic styles from PHP will be applied directly here */
}

.page-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    padding: 20px 0; /* Adjust internal padding if needed */
}

.page-title {
    font-family: 'Raleway', sans-serif;
    font-size: 1.8em;
    font-weight: 600;
    margin: 0; /* Reset default margin */
    flex-grow: 1; /* Allow title to take available space */
    text-align: left; /* Align title to the left */
}

.breadcrumb-nav {
    font-family: 'Raleway', sans-serif;
    font-size: 0.9em;
    margin: 0; /* Reset default margin */
    display: flex;
    align-items: center;
}

.breadcrumb {
    display: flex;
    padding: 0;
    margin: 0;
    list-style: none;
}

.breadcrumb-item {
    display: flex;
    align-items: center;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "/";
    padding: 0 8px;
    color: inherit; /* Inherit color from parent */
}

.breadcrumb-item a {
    text-decoration: none;
    font-weight: 600;
}

.breadcrumb-item.active {
    font-weight: 400; /* Active item usually less bold */
}


/* Service Grid Layouts */
.service-grid {
    display: grid;
    gap: 30px; /* Space between items */
    margin-top: 40px;
    justify-content: center; /* Center grid items if they don't fill the row */
}

/* Type 0: Image-based services (e.g., 3 columns) */
.service-type-0 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* Type 1: Icon-based services (text beside icon, e.g., 2 columns) */
.service-type-1 {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

/* Type 2: Icon-based services (text below icon, e.g., 4 columns) */
.service-type-2 {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}


/* General Service Item Styles */
.service-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    overflow: hidden;
    position: relative; /* For animation */
    /* Initial state for appear-animation */
    opacity: 0;
    transform: translateY(20px);
}

.service-item:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    transform: translateY(-5px);
}

/* Animation for services */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fadeInUp-active {
    animation: fadeInUp 0.6s ease-out forwards;
}


.service-title {
    font-size: 1.5em;
    color: #343a40;
    margin-top: 15px;
    margin-bottom: 10px;
    font-weight: 600;
}

.service-title a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

.service-title a:hover {
    color: #007bff; /* Highlight on hover */
}

.service-spot {
    font-size: 0.95em;
    color: #6c757d;
    line-height: 1.5;
}

/* Service Type 0 - Image Based */
.service-type-0 .service-item {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.service-type-0 .service-item img {
    max-width: 100%;
    height: 180px; /* Fixed height for consistency */
    object-fit: cover; /* Crop image to fit */
    border-radius: 8px;
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.service-type-0 .service-item:hover img {
    transform: scale(1.03); /* Slight zoom on image */
}

.service-type-0 .service-link {
    display: block; /* Make the image clickable */
    width: 100%;
    overflow: hidden; /* For image border-radius */
    border-radius: 8px;
}


/* Service Type 1 - Icon Beside Text */
.service-type-1 .service-item {
    display: flex;
    text-align: left;
    align-items: flex-start;
    padding: 20px; /* Adjust padding for side-by-side layout */
}

.service-type-1 .service-icon-wrapper {
    flex-shrink: 0; /* Prevent icon from shrinking */
    width: 60px;
    height: 60px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.service-type-1 .service-icon-wrapper i {
    font-size: 2.2em;
    color: #007bff !important; /* Emphasize icon color */
}

.service-type-1 .service-content-wrapper {
    flex-grow: 1;
}

.service-type-1 .service-title {
    margin-top: 0; /* Reset margin for aligned text */
    font-size: 1.3em;
}


/* Service Type 2 - Icon Above Text */
.service-type-2 .service-item {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.service-type-2 .service-item i {
    font-size: 3.5em; /* Larger icon */
    color: #007bff !important; /* Emphasize icon color */
    margin-bottom: 15px;
    display: block; /* Ensures margins are applied */
}

.service-type-2 .service-title {
    font-size: 1.4em;
}


/* No Services Found Message */
.no-services-found {
    grid-column: 1 / -1; /* Span across all columns */
    text-align: center;
    padding: 50px;
    background-color: #f0f0f0;
    border-radius: 10px;
    color: #555;
    font-style: italic;
}

.no-services-found p {
    margin-bottom: 20px;
    font-size: 1.1em;
}

.no-services-found .placeholder-image {
    max-width: 200px;
    height: auto;
    border-radius: 5px;
    opacity: 0.7;
}


/* Pagination Styles */
.pagination-container {
    margin-top: 70px;
    display: flex;
    justify-content: center;
}

.pagination {
    display: flex;
    padding-left: 0;
    list-style: none;
    border-radius: 0.25rem;
}

.page-item {
    margin: 0 5px; /* Spacing between buttons */
}

.page-link {
    position: relative;
    display: block;
    padding: 0.75rem 1rem;
    color: #007bff;
    text-decoration: none;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    transition: all 0.3s ease;
}

.page-link:hover {
    color: #0056b3;

    border-color: #dee2e6;
}

.page-item.active .page-link {
    z-index: 1;
    color: #fff;
    background-color: #007bff;
    border-color: #007bff;
}

.page-item.disabled .page-link {
    color: #6c757d;
    pointer-events: none;
    background-color: #fff;
    border-color: #dee2e6;
}


/* --- Responsive Adjustments --- */
@media (max-width: 992px) {
    .section-title {
        font-size: 2em;
    }
    .section-description {
        font-size: 1em;
        margin-bottom: 30px;
    }
    .service-type-0 {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    .service-type-1 {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    .service-type-2 {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
    .service-item {
        padding: 20px;
    }
}

@media (max-width: 768px) {
    .page-header-inner {
        flex-direction: column; /* Stack header elements */
        text-align: center;
        padding: 15px 0;
    }
    .page-title {
        font-size: 1.5em;
        margin-bottom: 10px;
        text-align: center;
    }
    .breadcrumb-nav {
        justify-content: center;
    }
    .services-section {
        padding: 40px 15px;
    }
    .section-title {
        font-size: 1.8em;
    }
    .section-description {
        font-size: 0.95em;
    }
    .service-type-0 {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    .service-type-1 {
        grid-template-columns: 1fr; /* Single column for type 1 on small screens */
        padding: 0 10px; /* Reduce horizontal padding */
    }
    .service-type-2 {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    .service-item {
        padding: 15px;
        border-radius: 10px;
    }
    .service-type-1 .service-icon-wrapper {
        width: 50px;
        height: 50px;
        margin-right: 15px;
    }
    .service-type-1 .service-icon-wrapper i {
        font-size: 1.8em;
    }
    .service-type-2 .service-item i {
        font-size: 3em;
    }
    .pagination .page-item {
        margin: 0 3px;
    }
    .pagination .page-link {
        padding: 0.5rem 0.75rem;
    }
}

@media (max-width: 576px) {
    .services-section {
        padding: 30px 10px;
    }
    .section-title {
        font-size: 1.5em;
    }
    .section-description {
        font-size: 0.9em;
        margin-bottom: 25px;
    }
    .service-grid {
        gap: 15px;
    }
    .service-type-0 {
        grid-template-columns: 1fr; /* Single column on smallest screens for image type */
    }
    .service-type-0 .service-item img {
        height: 150px;
    }
    .service-type-1 .service-item {
        flex-direction: column; /* Stack icon and text */
        text-align: center;
        align-items: center;
    }
    .service-type-1 .service-icon-wrapper {
        margin-right: 0;
        margin-bottom: 10px;
    }
    .service-type-2 {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); /* 2 columns for icon-only type */
    }
    .service-item {
        border-radius: 8px;
    }
}