/* ==========================================================================
   Services Section - EMAR Dental Clinic
   ========================================================================== */

/* Base Styles */
.services-section {
    padding: 120px 0 80px;
    background-color: var(--white);
    margin-top: 0;
    position: relative;
    overflow: hidden;
}

.services-section .section-header {
    margin-bottom: 60px;
}

.section-subtitle {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.section-title {
    font-size: 2.8rem;
    margin-bottom: 20px;
    color: #1a1a1a;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -15px;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--primary);
    border-radius: 2px;
}

.section-description {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 60px;
    position: relative;
    z-index: 1;
}

.services-grid::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255, 248, 230, 0.8) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.service-card {
    perspective: 1000px;
    height: 100%;
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

.service-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    background: #ffffff;
    border-radius: 15px;
    padding: 40px 25px;
    border: 1px solid rgba(212, 175, 55, 0.3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    z-index: 1;
    box-sizing: border-box;
}

.service-card:hover .service-card-inner {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.service-icon {
    width: 90px;
    height: 90px;
    margin: 0 auto 25px;
    background: linear-gradient(135deg, rgba(255, 248, 230, 0.8) 0%, rgba(255, 248, 230, 0.6) 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    color: var(--accent);
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.service-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: 0.5s;
}

.service-card:hover .service-icon {
    background: linear-gradient(135deg, var(--accent) 0%, #e8c04d 100%);
    color: #ffffff;
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.2);
    border-color: transparent;
}

.service-card:hover .service-icon::before {
    left: 100%;
}

.service-title {
    font-size: 1.5rem;
    margin: 0 0 15px 0;
    color: #2d2d2d;
    transition: all 0.3s ease;
    font-family: 'Bree Serif', serif;
    position: relative;
    display: block;
    width: 100%;
    padding: 0 15px 10px;
    box-sizing: border-box;
}

.service-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 50px;
    height: 2px;
    background: var(--accent);
    transition: all 0.3s ease;
}

.service-card:hover .service-title {
    color: var(--primary);
}

.service-description {
    color: #666;
    font-size: 1rem;
    line-height: 1.7;
    margin: 0 0 25px 0;
    min-height: 75px;
    font-weight: 400;
    padding: 0 15px;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    text-align: center;
}

.service-link {
    display: inline-flex;
    align-items: center;
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    position: relative;
    padding: 8px 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Bree Serif', serif;
}

.service-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: all 0.3s ease;
}

.service-link:hover {
    color: var(--accent-dark);
    letter-spacing: 1.5px;
}

.service-link:hover::after {
    width: 100%;
    background: var(--accent);
}

.service-link i {
    margin-left: 8px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    color: var(--accent);
}

.service-link:hover i {
    transform: translateX(5px);
    color: var(--accent-dark);
}

.cta-section {
    background: linear-gradient(135deg, #1a1a1a 0%, #333 100%);
    padding: 60px 30px;
    border-radius: 15px;
    color: #fff;
    margin-top: 40px;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiPjxkZWZzPjxwYXR0ZXJuIGlkPSJwYXR0ZXJuIiB3aWR0aD0iNDAiIGhlaWdodD0iNDAiIHBhdHRlcm5Vbml0cz0idXNlclNwYWNlT25Vc2UiIHBhdHRlcm5UcmFuc2Zvcm09InJvdGF0ZSg0NSkiPjxyZWN0IHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgZmlsbD0icmdiYSgyNTUsMjU1LDI1NSwwLjAzKSIvPjwvcGF0dGVybj48L2RlZnM+PHJlY3Qgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsbD0idXJsKCNwYXR0ZXJuKSIvPjwvc3ZnPg==');
    opacity: 0.3;
}

.cta-section h3 {
    font-size: 2rem;
    margin-bottom: 15px;
    color: #fff;
    position: relative;
}

.cta-section p {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto 30px;
    color: rgba(255, 255, 255, 0.9);
    position: relative;
}

.cta-section .btn-primary {
    background: #fff;
    color: #1a1a1a;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 1rem;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
    border: none;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.cta-section .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    background: var(--primary);
    color: #fff;
}

/* Responsive Styles */
@media (max-width: 1199px) {
    .services-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

@media (max-width: 992px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
    
    .service-card {
        max-width: 100%;
    }
    
    .service-icon {
        width: 80px;
        height: 80px;
        font-size: 2rem;
    }
    
    .service-title {
        font-size: 1.4rem;
    }
    
    .service-description {
        font-size: 0.95rem;
    }
}

@media (max-width: 767px) {
    .services-section {
        padding: 70px 0;
    }
    
    .section-title {
        font-size: 2.2rem;
    }
    
    .section-description {
        font-size: 1rem;
    }
    
    .services-grid {
        max-width: 500px;
        margin: 0 auto 40px;
    }
    
    .cta-section {
        padding: 40px 20px;
    }
    
    .cta-section h3 {
        font-size: 1.6rem;
    }
    
    .cta-section p {
        font-size: 1rem;
    }
}

@media (max-width: 479px) {
    .section-title {
        font-size: 1.8rem;
    }
    
    .section-subtitle {
        font-size: 0.9rem;
    }
}
