/* --- 5. PAGE SPECIFIC: SERVICES HEADER --- */
/* Mimics your Portfolio.css exactly */
.services-page { 
    padding: 80px 10%; 
    text-align: center; 
    background-color: #ffffff;
}

.services-page h1 { 
    margin-bottom: 40px; 
    font-size: 2.5rem; 
    position: relative; 
    padding-bottom: 10px; 
    text-transform: uppercase;
    color: #111;
}

/* The Gold Underline */
.services-page h1::after { 
    content: ''; 
    width: 60px; 
    height: 4px; 
    background: #c5a059; 
    position: absolute; 
    bottom: 0; 
    left: 50%; 
    transform: translateX(-50%); 
}

/* --- 6. PAGE SPECIFIC: GRID & CARDS --- */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 25px;
    margin-top: 40px;
    margin-left: 20px;
    margin-right: 20px;
    margin-bottom: 40px;
}

.card { 
    background: white; 
    overflow: hidden; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.05); 
    transition: 0.3s; 
    cursor: pointer; 
}

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

.card img { 
    width: 100%; 
    height: 320px; 
    object-fit: cover; 
    display: block; 
}

.card p { 
    padding: 25px; 
    font-weight: bold; 
    font-size: 1.1rem; 
    letter-spacing: 1px; 
    text-transform: uppercase; 
    color: #111;
}

/* --- 5. CARD LINK WRAPPER --- */
.card-link {
    text-decoration: none; /* Kills the underline */
    color: inherit;        /* Keeps your text black/bold */
    display: block;        /* Makes the whole card clickable */
}

.card-link:hover .card {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.card-desc {
    padding: 0 25px 30px;
    color: #555;
    font-size: 0.95rem;
    line-height: 1.5;
    text-align: left;
}

@media (max-width: 768px) {

    .grid {
        /* 1. Swap 10% for a fixed small pixel value */
        padding: 0 15px 60px !important;

        /* 2. Lower the floor to 280px so it fits even small phones */
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));

        /* 3. Tighten the gap so cards don't feel "loose" */
        gap: 20px;
    }

    .card-link {
        /* 4. Ensure the card itself doesn't have a fixed width */
        width: 100%;
        max-width: 100%;
        padding: 40px 20px;
    }
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .grid {
        /* Change 280px to 250px to survive the "Fold" test */
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        padding: 0 10px 40px !important;
    }
}
