/* Service Detail Page Styles (updated) */

/* Breadcrumb */
.breadcrumb {
    /* background-color: #f8f9fa; */
    padding: 15px 0;
    margin-bottom: 30px;
}

.breadcrumb ul {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 14px;
}

.breadcrumb li {
    margin-right: 10px;
    color: #666;
}

.breadcrumb li:after {
    content: '/'; 
    margin-left: 10px;
    color: #999;
}

.breadcrumb li:last-child:after {
    content: '';
}

.breadcrumb a {
    color: #ff7b00;
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: #e66a00;
    text-decoration: underline;
}

/* Service Hero */
.service-hero {
    position: relative;
    padding: 120px 0 80px;
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('../../img/service-hero-bg.jpg') no-repeat center center/cover;
    color: #fff;
    text-align: center;
    margin-bottom: 50px;
}

.service-hero h1 {
    font-size: 3rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.service-hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.9;
}

/* Service Details */
.service-details {
    padding: 50px 0;
}

/* ---------- Fixed: Universal centered heading + underline ---------- */
/* Use a more specific, conflict-resistant selector and center the underline */
.service-details h2,
.service-overview h2,
.service-benefits h2,
.service-process h2,
.service-gallery h2 {
    color: #333;
    margin: 0 0 25px;
    position: relative;
    padding-bottom: 0;
    display: inline-block;       /* allow underline to be centered */
    text-align: center;
    width: auto;
    vertical-align: middle;
    /* ensure parent layout won't push it off-center */
    box-sizing: border-box;
}

/* Center the pseudo-element by using left:50% + translateX(-50%) */
.service-details h2:after,
.service-overview h2:after,
.service-benefits h2:after,
.service-process h2:after,
.service-gallery h2:after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -8px;               /* slightly below the heading text */
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: #ff7b00;
    border-radius: 2px;
    box-shadow: 0 2px 6px rgba(255,122,0,0.12);
    /* ensure it's visible above backgrounds */
    z-index: 2;
}

/* Make sure parent sections don't clip the underline */
.service-overview,
.service-benefits,
.service-process,
.service-gallery,
.service-details {
    overflow: visible;
}

/* Service Features */
.service-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.feature {
    text-align: center;
    padding: 30px 20px;
    background: #f9f9f9;
    border-radius: 8px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.feature i {
    font-size: 2.5rem;
    color: #ff7b00;
    margin-bottom: 20px;
}

.feature h4 {
    margin: 15px 0 10px;
    color: #333;
}

/* Benefits Grid */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.benefit {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s;
}

.benefit:hover {
    transform: translateY(-5px);
}

.benefit h4 {
    color: #ff7b00;
    margin-bottom: 10px;
}

/* Process Steps */
.process-steps {
    margin: 40px 0;
}

.step {
    display: flex;
    margin-bottom: 30px;
    position: relative;
    padding-left: 40px;
}

.step:last-child {
    margin-bottom: 0;
}

.step-number {
    position: absolute;
    left: 0;
    top: 0;
    width: 30px;
    height: 30px;
    background: #ff7b00;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.1rem;
}

.step-content {
    padding-left: 20px;
}

.step-content h4 {
    margin: 0 0 10px;
    color: #333;
}

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.gallery-item:hover {
    transform: scale(1.03);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

/* CTA Section */
.service-cta {
    background: linear-gradient(135deg, #ff7b00 0%, #e66a00 100%);
    padding: 50px;
    border-radius: 8px;
    text-align: center;
    color: #fff;
    margin: 60px 0;
}

.service-cta h3 {
    font-size: 2rem;
    margin-bottom: 15px;
}

.service-cta p {
    font-size: 1.1rem;
    margin-bottom: 25px;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: #fff;
    color: #ff7b00;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid #fff;
}

.btn:hover {
    background: transparent;
    color: #fff;
}

/* Responsive */
@media (max-width: 768px) {
    .service-hero {
        padding: 80px 0 60px;
    }
    
    .service-hero h1 {
        font-size: 2.2rem;
    }
    
    .service-features, .benefits-grid {
        grid-template-columns: 1fr;
    }
    
    .service-cta {
        padding: 30px 20px;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    /* ensure headings remain readable and properly spaced on small screens */
    .service-details h2,
    .service-overview h2,
    .service-benefits h2,
    .service-process h2,
    .service-gallery h2 {
        display: block;
        width: 100%;
        margin: 0 0 16px;
    }
}
