/* --- Services Section Polish --- */

.service-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

#services .card {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    border: 2px solid transparent; /* Hidden border for the 'grow' effect */
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    cursor: pointer;
}

/* The Gold Hover Effect on the Card */
#services .card:hover {
    border-color: var(--brand-gold); /* */
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 69, 129, 0.1); /* Soft Navy tint to the shadow */
}

#services .card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
    /* Removed the hover effect from the image itself as requested */
}

#services .card h3 {
    color: var(--brand-navy); /* */
    margin-bottom: 12px;
    font-family: 'Montserrat', sans-serif;
}

#services .card p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-dark); /* */
}

@media (max-width: 768px) {
    /* 1. THE TRACK: Target .service-grid (Matches your HTML) */
    .service-grid {
        display: flex !important;           /* Kills the grid from line 3 */
        flex-direction: row !important;      /* Forces side-by-side */
        flex-wrap: nowrap !important;        /* Prevents stacking */

        overflow-x: auto !important;         /* Enables the horizontal swipe */
        scroll-snap-type: x mandatory !important;
        -webkit-overflow-scrolling: touch;   /* Smooth iOS momentum */

        gap: 15px !important;
        padding: 10px 20px 40px 20px !important; /* Extra bottom padding for card shadows */
        margin: 0 !important;
        scrollbar-width: none;               /* Hides scrollbar on Firefox */
    }

    .service-grid::-webkit-scrollbar {
        display: none;                       /* Hides scrollbar on Chrome/Safari */
    }

    /* 2. THE CARDS: Target #services .card */
    #services .card {
        flex: 0 0 82% !important;            /* 82% width gives the perfect 'peek' */
        min-width: 82% !important;
        max-width: 82% !important;
        scroll-snap-align: center !important;

        margin: 0 !important;
        padding: 15px !important;
        height: auto !important;
        border-color: var(--brand-gold) !important; /* Keep your gold border on mobile */
        box-shadow: 0 8px 20px rgba(0,0,0,0.1) !important;
    }

    /* 3. THE IMAGES: Standardize for the swipe track */
    #services .card img {
        height: 200px !important;
        width: 100% !important;
        object-fit: cover !important;
    }

    /* 4. TEXT ADJUSTMENTS: Polish for mobile readability */
    #services .card h3 {
        font-size: 1.25rem !important;
        margin-top: 15px !important;
        text-align: center;
    }

    #services .card p {
        font-size: 0.95rem !important;
        text-align: center;
        line-height: 1.5 !important;
    }
}