/* Estilos específicos para el catálogo */

.catalog-filters {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #333;
}

.filter-select, .filter-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.filter-buttons {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.btn-filter {
    padding: 10px 20px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
}

.btn-reset {
    padding: 10px 20px;
    background: #95a5a6;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
}

.btn-filter:hover {
    background: #2980b9;
}

.btn-reset:hover {
    background: #7f8c8d;
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    margin: 30px 0;
    gap: 10px;
}

.page-link {
    padding: 8px 15px;
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 5px;
    text-decoration: none;
    color: #333;
    cursor: pointer;
    transition: all 0.3s;
}

.page-link:hover {
    background: #e9ecef;
}

.page-link.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.page-link.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Propiedad destacada en carrusel */
.featured-property {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.featured-property-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.featured-property-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.featured-property-title {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: #2c3e50;
}

.featured-property-price {
    font-size: 1.4rem;
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 10px;
}

.featured-property-location {
    color: #7f8c8d;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.featured-property-description {
    color: #555;
    font-size: 0.9rem;
    line-height: 1.5;
    flex-grow: 1;
    margin-bottom: 15px;
}

.featured-property-badge {
    display: inline-block;
    background: #2ecc71;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    margin-top: auto;
    align-self: flex-start;
}

/* Grid de propiedades */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.property-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

.property-image-container {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.property-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.property-card:hover .property-image {
    transform: scale(1.05);
}

.property-category {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(52, 152, 219, 0.9);
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: 500;
}

.property-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.property-title {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: #2c3e50;
    line-height: 1.3;
}

.property-price {
    font-size: 1.3rem;
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 10px;
}

.property-location {
    color: #7f8c8d;
    margin-bottom: 15px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.property-description {
    color: #555;
    font-size: 0.9rem;
    line-height: 1.5;
    flex-grow: 1;
    margin-bottom: 15px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.property-actions {
    margin-top: auto;
    display: flex;
    gap: 10px;
}

.btn-details {
    padding: 8px 15px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    transition: background 0.3s;
    flex: 1;
    justify-content: center;
}

.btn-details:hover {
    background: #2980b9;
    color: white;
}

.btn-whatsapp {
    padding: 8px 15px;
    background: #25D366;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    transition: background 0.3s;
    flex: 1;
    justify-content: center;
}

.btn-whatsapp:hover {
    background: #1da851;
    color: white;
}

/* Controles del carrusel */
.carousel-container {
    position: relative;
    margin-bottom: 40px;
}

.carousel {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 10px 0;
    gap: 20px;
}

.carousel::-webkit-scrollbar {
    display: none;
}

.carousel-item {
    flex: 0 0 calc(33.333% - 20px);
    min-width: 300px;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.carousel-btn:hover {
    background: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.carousel-btn.prev {
    left: 10px;
}

.carousel-btn.next {
    right: 10px;
}

.carousel-btn i {
    font-size: 18px;
    color: #333;
}

.results-info {
    text-align: center;
    margin: 20px 0;
    font-size: 1.1rem;
    color: #666;
}

.no-properties {
    text-align: center;
    padding: 40px;
    background: #f8f9fa;
    border-radius: 10px;
    margin: 20px 0;
    grid-column: 1 / -1;
}

.no-properties i {
    font-size: 3rem;
    color: #95a5a6;
    margin-bottom: 20px;
}

.loading {
    text-align: center;
    padding: 40px;
    grid-column: 1 / -1;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 992px) {
    .carousel-item {
        flex: 0 0 calc(50% - 20px);
    }
    
    .properties-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .catalog-filters {
        flex-direction: column;
    }
    
    .filter-group {
        min-width: 100%;
    }
    
    .filter-buttons {
        width: 100%;
    }
    
    .carousel-item {
        flex: 0 0 calc(100% - 20px);
    }
    
    .properties-grid {
        grid-template-columns: 1fr;
    }
    
    .property-actions {
        flex-direction: column;
    }
}