.cards-box {
    padding: 4rem 1rem;
    /* background-color: #f9f9f9; */
}

.nearby-heading {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.nearby-cards {
    font-family: "Inter", sans-serif;
}

.grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    width: 90%;
    margin: 0px auto;
}

.card {
    display: flex;
    flex-direction: column;
    background-color: #fff;
    border-radius: 0.4rem;
    overflow: hidden;
    width: 100%; /* Full width for mobile */
    max-width: 350px; /* Limit max width */
    box-shadow: 0 3rem 6rem rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    padding-bottom: 2rem; /* Add padding at the bottom for the button */
    margin: 20px;
}

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

.card__img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card__content {
    padding: 1.5rem;
    flex-grow: 1; /* Allow content to grow */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Space between text and button */
}

.card__header {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: #333;
    text-align: center;
    margin-top: 10px;
}

.card__text-wrapper {
    margin-bottom: 1.5rem;
}

.card__text {
    font-size: 14px;
    letter-spacing: 0.1rem;
    line-height: 1.7;
    color: #3f3f3f;
    margin-bottom: 1rem;
}

.card__btn {
    display: block;
    width: 100%; /* Ensure full width for the button */
    padding: 1rem;
    font-size: 1.2rem;
    text-align: center;
    color: blue;
    background-color: rgba(107, 107, 245, 0.196);
    border: none;
    border-radius: 0.4rem;
    transition: var(--transition);
    cursor: pointer;
    margin-top: auto; /* Push the button to the bottom */
}

.card__btn span{
    margin-left: 10px;
}

.card__btn:hover span {
    margin-left: 15px;
    transition: var(--transition);
}

@media (max-width: 1200px){
    .card{
        position: relative;
    }
    .card__btn{
        max-width: 85%;
        position: absolute;
        left: 50%;
        transform: translate(-50%);
        bottom: 20px;
    }
    .gallery__grid {
        gap: 2rem !important;
    }
}
/* Media Queries */
@media (min-width: 768px) {

    .btn-solar {
        font-size: 1.3rem;
    }
}

@media (min-width: 992px) {

    .btn-solar {
        font-size: 1.5rem;
    }
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    .card {
        width: 100%; /* Full width for mobile */
        max-width: 100%; /* No width restriction on mobile */
        margin: 1rem 0; /* Adjust margins for smaller screens */
        padding-bottom: 2rem; /* Ensure space for the button */
    }

    .card__btn {
        font-size: 1rem; /* Reduce button size for mobile */
        padding: 0.8rem; /* Adjust padding for mobile button */
        max-width: 85%;
    }
}