/* ==============================================================================
    SERVICES PAGE STYLESHEET - MOBILE FIXED
    - Modern Design Matching Home Page Theme
    - Custom List Styling with Icons
    - Responsive Layout
    - Interactive Hover Effects
    - FIXED: Better mobile centering and overflow prevention
    ============================================================================== */

/* ==============================================================================
    BASE FIXES FOR MOBILE
    ============================================================================== */

/* Prevent horizontal overflow on mobile */
* {
    box-sizing: border-box;
}

/* ==============================================================================
    PAGE HEADER SECTION
    ============================================================================== */

.page-header {
    width: 100%;
    padding: 80px 20px 60px;
    background: linear-gradient(135deg, #0f0f0f 0%, #1a1a2e 50%, #16213e 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Animated electric grid background effect */
.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
            linear-gradient(90deg, rgba(255, 193, 7, 0.03) 1px, transparent 1px),
            linear-gradient(rgba(255, 193, 7, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: grid-flow 20s linear infinite;
    pointer-events: none;
}

@keyframes grid-flow {
    0% { transform: translateY(0); }
    100% { transform: translateY(50px); }
}

.page-header h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    color: #ffffff;
    margin-bottom: 0.5em;
    text-transform: uppercase;
    font-family: 'Oswald', 'Impact', sans-serif;
    letter-spacing: 2px;
    text-shadow:
            2px 2px 0 #007bff,
            4px 4px 8px rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 1;
}

.page-header .lead {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    color: #e0e0e0;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
    position: relative;
    z-index: 1;
    padding: 0 15px; /* Added padding for mobile */
}

/* ==============================================================================
    SERVICE LIST SECTION
    ============================================================================== */

.service-list {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px;
    background: linear-gradient(to bottom, #f8f9fa 0%, #ffffff 100%);
}

.service-list h2 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 30px;
    margin-top: 40px;
    font-family: 'Oswald', 'Impact', sans-serif;
    position: relative;
    padding-left: 20px;
    word-wrap: break-word; /* Prevent text overflow */
}

/* First h2 has no top margin */
.service-list h2:first-of-type {
    margin-top: 0;
}

/* Accent bar on the left side of headings */
.service-list h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 100%;
    background: linear-gradient(180deg, #ffc107, #007bff);
    border-radius: 3px;
}

.service-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

/* Individual Service Item */
.service-list li {
    background: #ffffff;
    padding: 25px 25px 25px 60px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: relative;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
    font-size: 1.05rem;
    color: #333;
    line-height: 1.6;
    opacity: 0;
    animation: slideIn 0.6s forwards;
    word-wrap: break-word; /* Prevent text overflow */
    overflow-wrap: break-word; /* Added for better word breaking */
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Electric bolt icon before each item */
.service-list li::before {
    content: '⚡';
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    background: linear-gradient(135deg, #ffc107, #ff9800);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(255, 193, 7, 0.3);
}

/* Hover effect */
.service-list li:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 20px rgba(0, 123, 255, 0.15);
    border-left-color: #007bff;
}

.service-list li:hover::before {
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.6);
    transform: translateY(-50%) scale(1.1);
}

/* Stagger the animation for each list item */
.service-list li:nth-child(1) { animation-delay: 0.1s; }
.service-list li:nth-child(2) { animation-delay: 0.2s; }
.service-list li:nth-child(3) { animation-delay: 0.3s; }
.service-list li:nth-child(4) { animation-delay: 0.4s; }
.service-list li:nth-child(5) { animation-delay: 0.5s; }
.service-list li:nth-child(6) { animation-delay: 0.6s; }

/* ==============================================================================
    RESPONSIVE DESIGN - IMPROVED MOBILE SUPPORT
    ============================================================================== */

@media (max-width: 768px) {
    .page-header {
        padding: 60px 15px 50px; /* Increased horizontal padding */
    }

    .page-header .lead {
        padding: 0 10px; /* Extra padding on mobile */
    }

    .service-list {
        padding: 60px 15px; /* Increased horizontal padding */
    }

    .service-list ul {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .service-list h2 {
        margin-top: 30px;
        margin-bottom: 20px;
        padding-left: 15px; /* Reduced padding on mobile */
    }

    .service-list li {
        padding: 20px 20px 20px 55px; /* Adjusted padding */
    }

    .service-list li::before {
        left: 15px; /* Moved icon closer to edge */
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 50px 10px 40px; /* More compact on small phones */
    }

    .page-header h1 {
        letter-spacing: 1px; /* Reduced letter spacing */
    }

    .page-header .lead {
        padding: 0 5px;
    }

    .service-list {
        padding: 50px 10px; /* More compact on small phones */
    }

    .service-list li {
        padding: 18px 15px 18px 50px; /* More compact */
        font-size: 0.95rem; /* Slightly smaller text */
    }

    .service-list li::before {
        width: 26px;
        height: 26px;
        font-size: 1rem;
        left: 12px;
    }

    .service-list h2 {
        padding-left: 12px;
        font-size: 1.5rem; /* Smaller headings on tiny screens */
    }

    .service-list h2::before {
        width: 4px; /* Thinner accent bar */
    }
}

/* iPhone SE and very small screens */
@media (max-width: 375px) {
    .page-header {
        padding: 40px 8px 35px;
    }

    .service-list {
        padding: 40px 8px;
    }

    .service-list li {
        padding: 15px 12px 15px 45px;
        font-size: 0.9rem;
    }

    .service-list li::before {
        width: 24px;
        height: 24px;
        font-size: 0.9rem;
        left: 10px;
    }
}

/* ==============================================================================
    SERVICE CTA SECTION
    ============================================================================== */

.service-cta {
    width: 100%;
    padding: 80px 20px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f0f0f 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Animated grid background */
.service-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
            linear-gradient(90deg, rgba(255, 193, 7, 0.03) 1px, transparent 1px),
            linear-gradient(rgba(255, 193, 7, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: grid-flow 20s linear infinite;
    pointer-events: none;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    padding: 0 15px; /* Added padding for mobile */
}

.service-cta h2 {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 900;
    color: #ffffff;
    margin-bottom: 0.5em;
    font-family: 'Oswald', 'Impact', sans-serif;
    letter-spacing: 2px;
    text-shadow:
            2px 2px 0 #007bff,
            4px 4px 8px rgba(0, 0, 0, 0.5);
    word-wrap: break-word; /* Prevent text overflow */
}

.service-cta p {
    font-size: clamp(1.1rem, 2.5vw, 1.3rem);
    color: #e0e0e0;
    line-height: 1.7;
    margin-bottom: 2rem;
    word-wrap: break-word; /* Prevent text overflow */
}

.service-cta .btn-primary {
    background: linear-gradient(135deg, #ffc107, #ff9800);
    border: none;
    color: #1a1a2e;
    padding: 18px 45px;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(255, 193, 7, 0.4);
    display: inline-block;
    text-decoration: none;
}

.service-cta .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 30px rgba(255, 193, 7, 0.6);
    background: linear-gradient(135deg, #ffd54f, #ffb74d);
}

/* Mobile CTA adjustments */
@media (max-width: 768px) {
    .service-cta {
        padding: 60px 15px;
    }

    .cta-content {
        padding: 0 10px;
    }
}

@media (max-width: 480px) {
    .service-cta {
        padding: 50px 10px;
    }

    .service-cta .btn-primary {
        padding: 15px 35px;
        font-size: 1rem;
        letter-spacing: 0.5px;
    }

    .service-cta h2 {
        letter-spacing: 1px;
    }
}

/* ==============================================================================
    UTILITY CLASSES
    ============================================================================== */

.lead {
    font-weight: 400;
}

/* Prevent horizontal scroll */
body {
    overflow-x: hidden;
}