/* ========================= */
/* ===== Property Grid ===== */
/* ========================= */

/* Property Grid Container */
.idx-property-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(25%, 1fr));
    gap: 2rem;
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Property Card */
.idx-property-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.2s;
    text-decoration: none; /* Remove underline from links */
    color: inherit; /* Inherit text color */
}

.idx-property-card:hover {
    transform: translateY(-5px);
    cursor: pointer; /* Change cursor to pointer on hover */
}

/* Property Image */
.idx-property-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.idx-property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Price Reduced Badge */
.idx-price-reduced {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #22c55e;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.875rem;
}

/* Property Content */
.idx-property-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

/* Property Price */
.idx-property-price {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

/* Property Address */
.idx-property-address {
    color: #666;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

/* Property Stats */
.idx-property-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    padding: 1rem 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    margin-bottom: 1rem;
    text-align: center;
}

.idx-stat-label {
    color: #666;
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
}

.idx-stat-value {
    font-weight: 600;
    color: #1a1a1a;
}

/* Property Description */
.idx-property-description {
    color: #666;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Property Footer */
.idx-property-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.idx-property-id {
    color: #666;
    font-size: 0.875rem;
}

.idx-property-status {
    background: #e5f7ed;
    color: #16a34a;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.875rem;
}

.idx-property-status.status-sold {
    background: #e53e3e;  /* Red background for Sold */
    color: white;
}

.idx-property-status.status-pending {
    background: #ed8936;  /* Orange background for Pending */
    color: white;
}

.idx-property-status.status-active {
    background: #e5f7ed;  /* Original green for Active */
    color: #16a34a;
}

/* Removed the Property Buttons since "View Listing" is removed */

/* Responsive Design for Property Grid */
@media (max-width: 768px) {
    .idx-property-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
    }
    
    .idx-property-card {
        width: 100%; /* Ensure full width on tablets */
    }
}

@media (max-width: 480px) {
    .idx-property-card {
        width: 100%; /* Ensure full width on mobile devices */
    }
}

/* Responsive Design for Tablets (Increase Image Height) */
@media (min-width: 500px) and (max-width: 1024px) {
    .idx-property-image {
        height: 300px; /* Increased height for tablet devices */
    }
}
