body {
    margin: 0;
    font-family: 'Poppins', sans-serif;
    background-color: #fff;
}

body, html {
    overflow-x: hidden;
}

.container,
.content-wrapper {
    width: 100%;
    position: relative;
}

.properties-bg {
    position: relative;
    width: 100%;
    height: 580px;
    margin-top: 50px;
    overflow: hidden;
}

.properties-bg picture,
.properties-bg img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.background-container picture,
.background-container img {
    display: block;
    width: 100%;
}

.background-container img {
    height: 70vh;
    object-fit: cover;
}

.featured-section {
    position: relative;
    width: 100%;
    height: auto;
    padding: 60px 0;
    overflow: visible;
    background: #F4E0B5;
}

.section-title {
    font-size: 2.3rem;
    font-weight: normal;
    letter-spacing: 1px;
    color: black;
    text-align: center;
    margin-bottom: 50px;
}

.models-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 30px;

    width: 100%;
    max-width: 1200px;   
    margin: 50px auto 0 auto;  
    padding: 0 20px;     
}

.models-card {
    width: 100%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    position: relative;
    text-decoration: none;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.models-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.18);
}

.models-card:hover img {
    transform: scale(1.02);
}

.models-card img {
    width: 100%;
    height: fit-content;       
    object-fit: cover;  
    display: block;
    transition: transform 0.6s ease;
}

.models-text {
    width: 60%;
    margin: 50px auto 0 auto;
    text-align: justify;
}

.models-text h2 {
    font-size: 2.3rem;
    font-weight: normal;
    letter-spacing: 1px;
    color: black;
    margin-bottom: 20px;
}

.models-text p {
    font-size: 1.05rem;
    line-height: 1.7;
    color: #4a4a4a;
}

.active-models-section {

    padding: 60px 20px;

    width: 100%;
    max-width: 1200px;   
    margin: 0 auto;     
}

.subdivision {
    padding-bottom: 90px;
}

.subdivision-link {
    color: inherit;         
    text-decoration: none;  
    cursor: pointer;
}

.subdivision-title {
    font-size: 2rem;
    font-weight: normal;
    color: #222;
    margin-bottom: 8px;
}

.subdivision-line {
    width: 100%;
    height: 2px;
    background: #c6b089;
    margin-bottom: 25px;
}

.active-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* always 4 columns on desktop */
    gap: 25px;

    width: 100%;
    max-width: 1200px;   
    margin: 0 auto;
}

.active-card {
    background: transparent;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.active-card:hover {
    transform: scale(1.03);
}

.active-card img {
    width: 100%;
    height: auto;        
    object-fit: contain; 
    display: block;
}

.area-row {
    display: flex;
    justify-content: space-evenly;
    padding: 10px 15px 0 15px;
}

.area-label {
    font-size: 14px;
    color: #222;
}

.area-value-row {
    display: flex;
    justify-content: space-evenly;
    padding: 2px 15px 15px 15px;
}

.area-value {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.modal {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    padding-top: 60px; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%;
    overflow: auto; 
    background-color: rgba(0,0,0,0.8); 
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 100%;
    max-height: 100%;
    border-radius: 10px;
}

.close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #ff0000;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

#caption {
    margin: 20px auto;
    text-align: center;
    color: #fff;
    font-size: 18px;
}

@media (max-width: 768px) {

    .models-grid {
        display: grid;  
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 15px;

        width: 100%;
        max-width: 100%; 
        margin: 0 auto;
        padding: 0 15px;
    }

    .models-card {
        aspect-ratio: 3 / 4;

    }

    .models-card img {
        width: 100%;
        height: fit-content;
        object-fit: cover;

    }

    .active-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: 15px;
    }

    .active-card img {
        height: auto;
    }
}

