/* Property Listings Styles - Professional & Compact */
.property-listings {
    padding: 20px 0;
    background-color: var(--bg-gray);
    min-height: auto !important; 
    padding-bottom: 40px;
}

/* Compact Header */
.compact-header {
    text-align: center;
    margin-bottom: 20px;
}

.compact-header h1 {
    color: var(--dark);
    margin-bottom: 5px;
    font-size: 2rem;
}

.compact-header p {
    color: var(--text-gray);
    font-size: 1rem;
}

/* Compact Filter Bar - IMPROVED FOR LARGER SCREENS */
.compact-filter-bar {
    background: var(--light);
    padding: 15px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    border: 1px solid var(--border-gray);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.filter-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

/* View Toggle */
.view-toggle {
    display: flex;
    background: var(--bg-gray);
    border-radius: 6px;
    padding: 2px;
    border: 1px solid var(--border-gray);
}

.toggle-btn {
    padding: 6px 10px;
    border: none;
    background: transparent;
    border-radius: 4px;
    cursor: pointer;
    color: var(--text-gray);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 32px;
}

.toggle-btn.active {
    background: var(--primary);
    color: white;
}

.toggle-btn:hover:not(.active) {
    background: var(--light-gray);
}

/* Compact Filters - IMPROVED LAYOUT */
.compact-filters {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    flex-wrap: wrap;
}

.compact-select {
    padding: 8px 10px;
    border: 1px solid var(--border-gray);
    border-radius: 4px;
    font-size: 0.85rem;
    background: var(--light);
    color: var(--text-gray);
    min-width: 120px;
    cursor: pointer;
    transition: var(--transition);
}

.compact-select:focus {
    border-color: var(--primary);
    outline: none;
}

/* Search Box */
.search-box {
    position: relative;
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

.search-box i {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    font-size: 0.9rem;
}

.search-box input {
    width: 100%;
    padding: 8px 10px 8px 32px;
    border: 1px solid var(--border-gray);
    border-radius: 4px;
    font-size: 0.85rem;
    transition: var(--transition);
}

.search-box input:focus {
    border-color: var(--primary);
    outline: none;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
}

/* Results Count */
.results-count {
    text-align: right;
    font-size: 0.9rem;
    color: var(--text-gray);
    margin-top: 10px;
    font-weight: 600;
}

/* Active Filters */
.active-filters {
    background: var(--light);
    padding: 12px 15px;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    border: 1px solid var(--border-gray);
}

.filter-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-tag {
    background: var(--primary-light);
    color: var(--dark);
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.remove-filter {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray);
    padding: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.6rem;
}

/* LARGER SCREEN OPTIMIZATION (Desktop) */
@media (min-width: 1024px) {
    .compact-filter-bar {
        padding: 15px 20px;
    }
    
    .filter-controls {
        display: flex;
        align-items: center;
        gap: 15px;
        flex-wrap: nowrap; /* Prevent wrapping on large screens */
    }
    
    .compact-filters {
        display: flex;
        align-items: center;
        gap: 10px;
        flex: 0 1 auto; /* Don't grow too much */
        flex-wrap: nowrap;
    }
    
    .mobile-controls-row {
        display: flex;
        align-items: center;
        gap: 15px;
        flex: 1;
        justify-content: flex-end;
    }
    
    .view-toggle {
        flex-shrink: 0;
    }
    
    .search-box {
        flex: 0 1 250px; /* Flexible but constrained */
        min-width: 200px;
        max-width: 300px;
    }
    
    .action-buttons {
        flex-shrink: 0;
    }
}

/* MEDIUM SCREEN OPTIMIZATION (Tablets) */
@media (min-width: 769px) and (max-width: 1023px) {
    .compact-filter-bar {
        padding: 12px 15px;
    }
    
    .filter-controls {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    .compact-filters {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 10px;
        width: 100%;
    }
    
    .mobile-controls-row {
        display: grid;
        grid-template-columns: auto 1fr auto;
        gap: 12px;
        align-items: center;
        width: 100%;
    }
    
    .search-box {
        min-width: auto;
        max-width: none;
    }
}

/* PROFESSIONAL MOBILE LAYOUT */
@media (max-width: 768px) {
    .compact-filter-bar {
        padding: 12px 15px;
    }
    
    .filter-controls {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    /* Row 1: All Filters in One Compact Row */
    .compact-filters {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        width: 100%;
    }
    
    /* Show all filters on mobile */
    #status-filter,
    #bedroom-filter,
    #price-filter {
        display: block;
        min-width: auto;
        width: 100%;
    }
    
    /* Make availability filter span full width */
    #status-filter {
        grid-column: 1 / -1;
    }
    
    /* Row 2: Controls - Toggle, Search, Actions in One Compact Row */
    .mobile-controls-row {
        display: grid;
        grid-template-columns: auto 1fr auto;
        gap: 10px;
        align-items: center;
        width: 100%;
    }
    
    .view-toggle {
        grid-column: 1;
    }
    
    .search-box {
        grid-column: 2;
        min-width: auto;
        max-width: none;
        margin: 0;
    }
    
    .action-buttons {
        grid-column: 3;
        gap: 6px;
    }
    
    /* Row 3: Results Count */
    .results-count {
        text-align: center;
        margin-top: 8px;
        width: 100%;
    }
}

/* SMALL MOBILE OPTIMIZATION */
@media (max-width: 480px) {
    .compact-filter-bar {
        padding: 12px 15px;
    }
    
    .filter-controls {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    /* Row 1: All Filters in One Compact Row */
    .compact-filters {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        width: 100%;
    }
    
    /* Show all filters on mobile */
    #status-filter,
    #bedroom-filter,
    #price-filter {
        display: block;
        min-width: auto;
        width: 100%;
    }
    
    /* Make availability filter span full width */
    #status-filter {
        grid-column: 1 / -1;
    }
    
    /* Row 2: Controls - Toggle, Search, Actions in One Compact Row */
    .mobile-controls-row {
        display: grid;
        grid-template-columns: auto 1fr auto;
        gap: 10px;
        align-items: center;
        width: 100%;
    }
    
    .view-toggle {
        grid-column: 1;
    }
    
    .search-box {
        grid-column: 2;
        min-width: auto;
        max-width: none;
        margin: 0;
    }
    
    .action-buttons {
        grid-column: 3;
        gap: 6px;
    }
    
    /* Row 3: Results Count */
    .results-count {
        text-align: center;
        margin-top: 8px;
        width: 100%;
    }
}

/* EXTRA SMALL MOBILE */
@media (max-width: 360px) {
    .compact-filter-bar {
        padding: 8px 10px;
    }
    
    .compact-filters {
        gap: 6px;
    }
    
    .mobile-controls-row {
        gap: 6px;
    }
    
    .compact-select {
        padding: 6px 8px;
        font-size: 0.75rem;
    }
    
    .search-box input {
        padding: 6px 8px 6px 28px;
        font-size: 0.75rem;
    }
    
    .btn-sm {
        padding: 4px 6px;
        font-size: 0.7rem;
    }
}

/* Rest of your existing table and card styles remain the same */
.table-container {
    background: var(--light);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    border: 1px solid var(--border-gray);
}

.properties-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.properties-table th {
    background: var(--primary);
    color: white;
    padding: 12px 10px;
    text-align: left;
    font-weight: 600;
    font-size: 0.85rem;
}

.properties-table td {
    padding: 12px 10px;
    border-bottom: 1px solid var(--border-gray);
    vertical-align: top;
}

.properties-table tr:last-child td {
    border-bottom: none;
}

.properties-table tr:hover {
    background: var(--bg-gray);
}

/* Table Columns */
.address-col { width: 35%; }
.price-col { width: 20%; }
.availability-col { width: 25%; }
.actions-col { width: 20%; }

/* Property Info in Table */
.property-info-table h4 {
    color: var(--dark);
    margin-bottom: 3px;
    font-size: 0.95rem;
    font-weight: 600;
}

.property-info-table .bed-bath {
    color: var(--text-gray);
    font-size: 0.8rem;
}

/* Price Styling */
.price-range {
    font-weight: 600;
    color: var(--primary);
    font-size: 0.9rem;
}

/* Availability Badges */
.availability-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 3px;
}

.badge-ready-now {
    background: #d4edda;
    color: #155724;
}

.badge-ready-soon {
    background: #fff3cd;
    color: #856404;
}

.badge-ask {
    background: #f8d7da;
    color: #721c24;
}

.availability-date {
    color: var(--text-gray);
    font-size: 0.8rem;
}

/* Action Buttons - Professional Flex Layout */
.table-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.action-btn {
    padding: 5px 10px;
    border: 1px solid var(--border-gray);
    border-radius: 4px;
    background: var(--light);
    color: var(--text-gray);
    cursor: pointer;
    font-size: 0.75rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 3px;
    white-space: nowrap;
    flex: 1;
    min-width: 60px;
    justify-content: center;
}

.action-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.action-btn.video {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.action-btn.video:hover {
    background: var(--accent-dark);
}

/* Responsive Table Actions */
@media(max-width: 768px)  {
    .properties-table {
        font-size: 0.8rem;
    }
    
    .properties-table th,
    .properties-table td {
        padding: 10px 8px;
    }
    
    .table-actions {
        flex-direction: column;
        gap: 4px;
    }
    
    .action-btn {
        min-width: auto;
        padding: 4px 8px;
    }
    
    .address-col { width: 30%; }
    .price-col { width: 20%; }
    .availability-col { width: 30%; }
    .actions-col { width: 20%; }
}

/* Card View */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.property-card-listings {
    background: var(--light);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    border: 1px solid var(--border-gray);
    transition: var(--transition);
}

.property-card-listings:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.card-header {
    position: relative;
}

.card-header img {
    width: 100%;
    height: 160px;
    object-fit: cover;
}

.card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary);
    color: white;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 600;
}

.card-content {
    padding: 15px;
}

.card-content h3 {
    color: var(--dark);
    margin-bottom: 5px;
    font-size: 1.1rem;
}

.card-bed-bath {
    color: var(--text-gray);
    margin-bottom: 10px;
    font-size: 0.85rem;
}

.card-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 8px;
}

.card-availability {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    font-size: 0.85rem;
    color: var(--text-gray);
}

.card-actions {
    display: flex;
    gap: 8px;
}

/* Card View Styles */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.property-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e9ecef;
}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.property-card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.property-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.property-card:hover .property-card-image img {
    transform: scale(1.05);
}

.gallery-count {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.property-card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
}

.badge-ready-now {
    background: #2ecc71;
}

.badge-ready-soon {
    background: #f39c12;
}

.badge-contact {
    background: #3498db;
}

.badge-available {
    background: #7f8c8d;
}

.property-card-content {
    padding: 20px;
}

.property-card-title {
    margin: 0 0 10px 0;
    font-size: 1.2rem;
    color: #2c3e50;
    font-weight: 600;
}

.property-card-location {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    color: #7f8c8d;
    font-size: 0.9rem;
}

.property-card-location i {
    color: #3498db;
}

.property-card-features {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e9ecef;
}

.feature {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #5a6c7d;
    font-size: 0.9rem;
}

.feature i {
    color: #3498db;
}

.property-card-price {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-bottom: 10px;
}

.price {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
}

.price-period {
    color: #7f8c8d;
    font-size: 0.9rem;
}

.property-card-availability {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 15px;
    color: #5a6c7d;
    font-size: 0.9rem;
}

.property-card-availability i {
    color: #2ecc71;
}

.property-card-description {
    color: #5a6c7d;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 20px;
}

.property-card-actions {
    display: flex;
    gap: 10px;
}

.property-card-actions .btn {
    flex: 1;
    text-align: center;
    padding: 8px 12px;
    font-size: 0.85rem;
}

/* Responsive card grid */
@media (max-width: 768px) {
    .properties-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .properties-grid {
        grid-template-columns: 1fr;
    }
    
    .property-card-actions {
        flex-direction: column;
    }
}

/* No Results */
.no-results {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-gray);
    background: var(--light);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-gray);
}

.no-results i {
    margin-bottom: 15px;
    color: var(--light-gray);
}

.no-results h3 {
    margin-bottom: 8px;
    color: var(--dark);
    font-size: 1.1rem;
}

.no-results p {
    font-size: 0.9rem;
}

/* Date Filter Styles */
.custom-date-range {
    background: var(--light);
    padding: 12px 15px;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    border: 1px solid var(--border-gray);
}

.date-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.date-inputs input[type="date"] {
    padding: 8px 10px;
    border: 1px solid var(--border-gray);
    border-radius: 4px;
    font-size: 0.85rem;
    background: var(--light);
    color: var(--text-gray);
    min-width: 140px;
}

.date-inputs span {
    color: var(--text-gray);
    font-size: 0.85rem;
}

/* Update mobile layouts for the new filter */
@media (max-width: 768px) {
    .compact-filters {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 8px;
        width: 100%;
    }
    
    /* Make availability and date filters span full width */
    #status-filter,
    #date-filter {
        grid-column: 1 / -1;
    }
    
    .date-inputs {
        flex-direction: column;
        align-items: stretch;
    }
    
    .date-inputs input[type="date"] {
        min-width: auto;
        width: 100%;
    }
}

@media (min-width: 769px) and (max-width: 1023px) {
    .compact-filters {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        gap: 10px;
        width: 100%;
    }
    
    #date-filter {
        grid-column: 1 / -1;
    }
}

/* ===== Property FAQ Section Styles ===== */
.property-faq {
    padding: 60px 0;
    background-color: #ffffff;
}

.property-faq .section-title {
    text-align: center;
    color: var(--dark);
    margin-bottom: 10px;
}

.property-faq .section-subtitle {
    text-align: center;
    color: var(--text-gray);
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.faq-grid {
    max-width: 900px;
    margin: 0 auto 40px;
}

.faq-item {
    background: var(--light);
    border: 1px solid var(--border-gray);
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.faq-question {
    padding: 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    background: var(--bg-gray);
}

.faq-question h3 {
    color: var(--dark);
    margin: 0;
    font-size: 1.1rem;
    flex: 1;
}

.faq-question i {
    color: var(--primary);
    transition: transform 0.3s ease;
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-answer.active {
    padding: 20px;
    max-height: 1000px;
}

.faq-answer p {
    color: var(--text-gray);
    margin-bottom: 15px;
    line-height: 1.6;
}

.faq-answer ol,
.faq-answer ul {
    color: var(--text-gray);
    margin-bottom: 15px;
    padding-left: 20px;
}

.faq-answer li {
    margin-bottom: 8px;
    line-height: 1.5;
}

.faq-answer a {
    color: var(--primary);
    text-decoration: none;
}

.faq-answer a:hover {
    text-decoration: underline;
}

/* Utilities Grid */
.utilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin: 20px 0;
}

.utility-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg-gray);
    padding: 12px 15px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-gray);
}

.utility-item i {
    color: var(--primary);
    font-size: 1.2rem;
}

.utility-item span {
    color: var(--dark);
    font-weight: 500;
}

/* FAQ CTA */
.faq-cta {
    text-align: center;
    padding: 30px;
    background: var(--primary-light);
    border-radius: var(--border-radius);
    margin-top: 40px;
}

.faq-cta h3 {
    color: var(--dark);
    margin-bottom: 10px;
}

.faq-cta p {
    color: var(--text-gray);
    margin-bottom: 20px;
}

.faq-cta .cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== Booking Help Section Styles ===== */
.booking-help {
    padding: 60px 0;
    background-color: var(--bg-gray);
}

.booking-help-content {
    display: flex;
    align-items: center;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.booking-help-icon {
    flex-shrink: 0;
}

.booking-help-icon i {
    font-size: 4rem;
    color: var(--primary);
}

.booking-help-text {
    flex: 1;
}

.booking-help-text h2 {
    color: var(--dark);
    margin-bottom: 15px;
    font-size: 2rem;
}

.booking-help-text p {
    color: var(--text-gray);
    margin-bottom: 30px;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Booking Steps */
.booking-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.booking-step {
    background: white;
    padding: 20px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-gray);
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.step-content h4 {
    color: var(--dark);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.step-content p {
    color: var(--text-gray);
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

/* Booking Help Contact */
.booking-help-contact {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    margin-bottom: 30px;
}

/* Booking Tips */
.booking-tips {
    background: white;
    padding: 20px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-gray);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.booking-tips h4 {
    color: var(--dark);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.booking-tips h4 i {
    color: var(--accent);
}

.booking-tips ul {
    color: var(--text-gray);
    padding-left: 20px;
    margin: 0;
}

.booking-tips li {
    margin-bottom: 8px;
    line-height: 1.5;
}

/* ===== Quick Contact Section Styles ===== */
.quick-contact {
    padding: 60px 0;
    background-color: #ffffff;
}

.quick-contact-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.quick-contact-content h2 {
    color: var(--dark);
    margin-bottom: 15px;
    font-size: 2rem;
}

.quick-contact-content p {
    color: var(--text-gray);
    margin-bottom: 40px;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Contact Methods Grid */
.contact-methods-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.contact-method-card {
    background: var(--light);
    padding: 30px 20px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-gray);
    text-align: center;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.contact-method-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 1.5rem;
}

.contact-details h3 {
    color: var(--dark);
    margin-bottom: 10px;
    font-size: 1.3rem;
}

.contact-number,
.contact-email,
.contact-text {
    display: block;
    color: var(--primary);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
    text-decoration: none;
}

.contact-details p {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin: 0;
}

/* ===== Footer Styles (for property listings page) ===== */
footer {
    background: var(--dark);
    color: white;
    padding: 60px 0 30px;
    margin-top: 0;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-column h3 {
    color: white;
    margin-bottom: 20px;
    font-size: 1.3rem;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: var(--primary);
}

.footer-column p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin-bottom: 20px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.footer-links a i {
    font-size: 0.8rem;
}

.footer-links a.active {
    color: var(--primary);
    font-weight: 600;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.footer-cta {
    margin-top: 20px;
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .property-faq,
    .booking-help,
    .quick-contact {
        padding: 40px 0;
    }
    
    .booking-help-content {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
    
    .booking-help-icon i {
        font-size: 3rem;
    }
    
    .booking-steps {
        grid-template-columns: 1fr;
    }
    
    .booking-help-contact {
        flex-direction: column;
    }
    
    .contact-methods-grid {
        grid-template-columns: 1fr;
    }
    
    .faq-cta .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
 
}

@media (min-width: 769px) and (max-width: 1024px) {
    .booking-help-content {
        gap: 30px;
    }
    
    .booking-steps {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .contact-methods-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Animation Base Classes */
.fade-in {
    animation: fadeIn 0.8s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.slide-in-left {
    animation: slideInLeft 0.8s ease forwards;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.8s ease forwards;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Optional delay classes */
.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

/* Floating Filter Container */
.floating-filter-container {
    position: relative;
    z-index: 1000;
    transition: all 0.3s ease;
}

.floating-filter-container.floating {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 15px 0;
    z-index: 1000;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.floating-filter-container.floating .compact-filter-bar {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 20px;
}

/* Collapsible Filters */
.compact-filter-bar.collapsed .compact-filters {
    display: none;
}

.compact-filter-bar.collapsed .mobile-controls-row {
    margin-top: 0;
}

.compact-filter-bar.collapsed .custom-date-range {
    display: none !important;
}

.compact-filter-bar.collapsed .active-filters {
    display: none !important;
}

/* Toggle Filters Button */
#toggle-filters-btn {
    display: none;
}

@media (max-width: 768px) {
    #toggle-filters-btn {
        display: inline-flex;
    }
    
    .compact-filters {
        transition: max-height 0.3s ease;
        overflow: hidden;
    }
    
    .compact-filter-bar.collapsed .compact-filters {
        max-height: 0;
    }
}

/* Pagination Controls */
.pagination-controls {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-gray);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.pagination-info {
    color: var(--text-gray);
    font-size: 0.9rem;
}

.pagination-info span {
    font-weight: 600;
    color: var(--dark);
}

.pagination-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.pagination-btn {
    padding: 8px 16px;
    background: var(--light);
    border: 1px solid var(--border-gray);
    border-radius: 6px;
    color: var(--dark);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pagination-btn:hover:not(:disabled) {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-numbers {
    display: flex;
    gap: 5px;
}

.page-number {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: var(--light);
    border: 1px solid var(--border-gray);
    color: var(--dark);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.page-number:hover {
    background: var(--light-gray);
}

.page-number.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.page-number.ellipsis {
    background: transparent;
    border: none;
    cursor: default;
    width: 20px;
}

/* Responsive pagination */
@media (max-width: 768px) {
    .pagination-controls {
        flex-direction: column;
        text-align: center;
    }
    
    .pagination-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .page-numbers {
        order: 3;
        margin-top: 10px;
    }
    
    .pagination-btn {
        min-width: 120px;
        justify-content: center;
    }
}


/* Compact Filter Bar - Mobile First */
.compact-filter-bar {
    background: var(--light);
    border-radius: var(--border-radius);
    margin-bottom: 20px;
    border: 1px solid var(--border-gray);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

/* Mobile Filter Header */
.filter-header-mobile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 15px;
    background: var(--primary);
    color: white;
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.filter-header-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
    font-weight: 600;
}

.filter-header-title i {
    font-size: 1rem;
}

/* Collapsed State */
.compact-filter-bar.collapsed .filter-content {
    display: none;
}

.compact-filter-bar.collapsed .active-filters {
    display: none;
}

.compact-filter-bar.collapsed .filter-header-mobile {
    border-bottom: none;
}

/* Toggle Filters Button */
#toggle-filters-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.2);
    border: 1px solid rgba(255,255,255,0.3);
    color: white;
    font-size: 0.85rem;
    padding: 5px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.3s ease;
}

#toggle-filters-btn:hover {
    background: rgba(255,255,255,0.3);
}

/* Filter Content */
.filter-content {
    padding: 20px;
}

/* Compact Filters Layout */
.compact-filters {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

/* Mobile Controls Row */
.mobile-controls-row {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 15px;
}

/* View Toggle */
.view-toggle {
    display: flex;
    background: var(--bg-gray);
    border-radius: 8px;
    padding: 4px;
    border: 1px solid var(--border-gray);
    align-self: flex-start;
}

.toggle-btn {
    padding: 10px 10px;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    color: var(--text-gray);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;

}

.toggle-btn.active {
    background: var(--primary);
    color: white;
}

/* Search Box */
.search-box {
    position: relative;
    width: 100%;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
}

.search-box input {
    width: 100%;
    padding: 10px 12px 10px 40px;
    border: 1px solid var(--border-gray);
    border-radius: 6px;
    font-size: 0.9rem;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.9rem;
    flex: 1;
}

/* Active Filters */
.active-filters {
    background: var(--bg-gray);
    padding: 15px;
    border-radius: 6px;
    margin-top: 15px;
    border: 1px solid var(--border-gray);
}

.filter-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-tag {
    background: var(--primary-light);
    color: var(--dark);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Results Count */
.results-count {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-gray);
    margin-top: 15px;
    font-weight: 600;
}

/* Custom Date Range */
.custom-date-range {
    background: var(--bg-gray);
    padding: 15px;
    border-radius: 6px;
    margin: 15px 0;
    border: 1px solid var(--border-gray);
}

.date-inputs {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.date-inputs input[type="date"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-gray);
    border-radius: 6px;
    font-size: 0.9rem;
    background: var(--light);
    color: var(--text-gray);
}

/* Responsive Design - MOBILE (default) */
@media (max-width: 768px) {
    .compact-filter-bar {
        margin-bottom: 15px;
    }
    
    .filter-content {
        padding: 15px;
    }
    
    .compact-filters {
        grid-template-columns: 1fr;
    }
    
    .mobile-controls-row {
        flex-direction: column;
    }
    
    .action-buttons {
        flex-direction: row;
    }
}

/* DESKTOP */
@media (min-width: 769px) {
    .filter-header-mobile {
        display: none;
    }
    
    .compact-filter-bar {
        padding: 20px;
    }
    
    .filter-content {
        display: block !important;
        padding-top: 0;
    }
    
    .compact-filters {
        display: flex;
        gap: 15px;
        margin-bottom: 20px;
    }
    
    .mobile-controls-row {
        flex-direction: row;
        align-items: center;
        margin-bottom: 20px;
    }
    
    .view-toggle {
        flex-shrink: 0;
    }
    
    .search-box {
        flex: 1;
        min-width: 200px;
        max-width: 400px;
    }
    
    .action-buttons {
        flex-shrink: 0;
    }
    
    /* Show filters expanded by default on desktop */
    .compact-filter-bar:not(.collapsed) .filter-content {
        display: block;
    }
    
    .date-inputs {
        flex-direction: row;
        align-items: center;
    }
    
    .date-inputs input[type="date"] {
        min-width: 150px;
    }
}

/* Desktop specific optimizations */
@media (min-width: 1024px) {
    .compact-filter-bar {
        padding: 20px 25px;
    }
    
    .compact-filters {
        gap: 20px;
    }
    
    .compact-select {
        min-width: 50px;
    }
}


/* Smooth transitions for all interactive elements */
.smooth-transitions * {
    transition: background-color 0.3s ease,
                color 0.3s ease,
                border-color 0.3s ease,
                box-shadow 0.3s ease,
                transform 0.3s ease,
                opacity 0.3s ease;
}

/* Loading states */
.loading {
    position: relative;
    opacity: 0.7;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 11;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Fade in animations */
.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.fade-in-up {
    animation: fadeInUp 0.6s ease forwards;
}

.fade-in-down {
    animation: fadeInDown 0.6s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Staggered animations for lists */
.stagger-item {
    opacity: 0;
    animation: fadeInUp 0.5s ease forwards;
}

.stagger-item:nth-child(1) { animation-delay: 0.1s; }
.stagger-item:nth-child(2) { animation-delay: 0.2s; }
.stagger-item:nth-child(3) { animation-delay: 0.3s; }
.stagger-item:nth-child(4) { animation-delay: 0.4s; }
.stagger-item:nth-child(5) { animation-delay: 0.5s; }

/* Card hover effects */
.property-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.property-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Button loading state */
.btn.loading {
    position: relative;
    color: transparent;
}

.btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* Table row hover effects */
.properties-table tbody tr {
    transition: background-color 0.2s ease;
}

.properties-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Modal animations */
.property-modal {
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Filter animations */
.filter-content {
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
    }
    to {
        opacity: 1;
        max-height: 500px;
    }
}

/* Pulse animation for notifications */
@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(52, 152, 219, 0.7);
    }
    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(52, 152, 219, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(52, 152, 219, 0);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

/* Error state */
.error-state {
    text-align: center;
    padding: 60px 20px;
    color: #e74c3c;
}

.error-state i {
    margin-bottom: 20px;
    color: #e74c3c;
}

.error-state h3 {
    margin-bottom: 10px;
    color: #333;
}

.error-state p {
    margin-bottom: 20px;
    color: #666;
}

/* Performance monitoring badge (optional) */
.performance-badge {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: #2c3e50;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    opacity: 0.7;
    z-index: 1000;
    font-family: monospace;
}

/* Table loading overlay styles */
.table-loading-overlay {
    position: absolute;
    top: 40px; /* Start below the table header */
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10; /* Lower z-index to stay within table */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    border-radius: 0 0 8px 8px; /* Match table border radius */
}

/* Update table container structure */
.table-view {
    position: relative;
    background: white;
    border-radius: 8px;
    overflow: hidden;
}

.table-container {
    position: relative !important;
    min-height: 200px;
    overflow-x: auto;
}

.properties-table {
    width: 100%;
    border-collapse: collapse;
    position: relative;
}

.properties-table thead {
    position: sticky;
    top: 0;
    background: var(--bg-light);
    z-index: 20; /* Higher than loader */
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.properties-table tbody {
    position: relative;
}

/* Update filters-loading to be visual only */
.filters-loading {
    opacity: 0.8;
    /* DO NOT add pointer-events: none */
}

/* Add visual feedback for loading search */
.search-box.loading::after {
    content: '';
    position: absolute;
    top: 10px;
    right: 10px;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Keep search input always enabled */
#search-filter {
    pointer-events: auto !important;
    cursor: text !important;
}

/* Enhanced description styling */
.bullet-list {
    margin: 15px 0;
    padding-left: 0;
}

.bullet-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 8px;
    padding: 3px 0;
}

.bullet-icon {
    color: #4CAF50;
    font-weight: bold;
    margin-right: 10px;
    min-width: 20px;
    text-align: right;
}

.bullet-content {
    flex: 1;
    line-height: 1.5;
}

.bullet-item.numbered .bullet-icon {
    font-size: 0.9em;
}

/* Add this to your style.css */

/* ===== PROPERTY LISTINGS MODAL - SEPARATE STRUCTURE ===== */
.property-listings-modal-wrapper {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 5px !important;
    margin-bottom: 0px !important;
    max-height: 100vh !important;
    overflow: hidden !important;
    width: 100% !important;
}

.property-listings-gallery-container {
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 0 !important;
    overflow: hidden !important;
    margin-bottom: 8rem;
}

.property-listings-gallery-main {
    flex: 1 !important;
    min-height: 0 !important;
    border-radius: var(--border-radius) !important;
    overflow: hidden !important;
    border: 1px solid var(--border-gray) !important;
    position: relative !important;
}

.property-listings-gallery-main img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
}

.property-listings-thumbnails {
    flex-shrink: 0 !important;
    display: flex !important;
    gap: 10px !important;
    overflow-x: auto !important;
    padding: 10px 5px !important;
    min-height: 80px !important;
    max-height: 100px !important;
    margin-top: 10px !important;
}

.property-listings-details-wrapper {
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 0 !important;
    overflow: auto !important;

}

.property-listings-details-content {
    flex: 1 !important;
    overflow-y: auto !important;
    padding-right: 15px !important;
    max-height: 100% !important;
    min-height: 500px !important;
    
}

/* Style the scrollbar */
.property-listings-details-content::-webkit-scrollbar {
    width: 6px;
}

.property-listings-details-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.property-listings-details-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.property-listings-details-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Responsive */
@media (max-width: 768px) {
    .property-listings-modal-wrapper {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
        max-height: 85vh !important;
    }
    
    .property-listings-gallery-main {
        min-height: 300px !important;
        max-height: 350px !important;
    }
    
    .property-listings-details-content {
        max-height: 90vh !important;
    }
}

/* Make the entire details section scrollable */
.modal-details-scrollable {
    max-height: 800px;
    overflow-y: auto;
    padding-right: 15px;
}

.modal-details-scrollable::-webkit-scrollbar {
    width: 6px;
}

.modal-details-scrollable::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.modal-details-scrollable::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.modal-details-scrollable::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Add to your existing CSS */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* ===== MODAL ACTIONS - 2-ROW GRID LAYOUT ===== */

.modal-actions {
    display: grid;
    grid-template-columns: 1fr 1fr; /* Two equal columns */
    grid-template-rows: auto auto; /* Two rows */
    gap: 8px;
    padding: 5px;
    background: var(--bg-gray);
    border-top: 1px solid var(--border-gray);
}

/* Book button spans full width in first row */
#modal-book-btn {
    grid-column: 1 / -1; /* Spans all columns in first row */
    grid-row: 1;
}

/* Contact button spans full width in second row */
#modal-contact-btn {
    grid-column: 1 / -1; /* Spans all columns in second row */
    grid-row: 2;
}

/* Base button styles */
.modal-actions .btn {
    width: 100%;
    padding: 14px 16px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
    white-space: nowrap;
    min-height: 50px;
    border: none;
}

/* Book button (primary) */
#modal-book-btn {
    background: var(--primary);
    color: white;
    border: 2px solid var(--primary);
}

#modal-book-btn:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Contact button (accent) */
#modal-contact-btn {
    background: var(--accent);
    color: white;
    border: 2px solid var(--accent);
}

#modal-contact-btn:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Tablet */
@media (max-width: 1024px) {
    .modal-actions {
        padding: 16px;
        gap: 6px;
    }
    
    .modal-actions .btn {
        padding: 12px 14px;
        font-size: 0.95rem;
        min-height: 46px;
        gap: 8px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .modal-actions {
        padding: 14px;
        gap: 6px;
    }
    
    .modal-actions .btn {
        padding: 12px 16px;
        font-size: 0.95rem;
        min-height: 46px;
        gap: 8px;
    }
    
    .modal-actions .btn i {
        font-size: 1.1rem;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .modal-actions {
        padding: 12px;
        gap: 5px;
    }
    
    .modal-actions .btn {
        padding: 11px 14px;
        font-size: 0.9rem;
        min-height: 44px;
        gap: 6px;
    }
    
    .modal-actions .btn i {
        font-size: 1rem;
    }
    
    /* Shorten text for small screens */
    #modal-book-btn span {
        content: "Book This Property";
    }
    
    #modal-contact-btn span {
        content: "Contact Us";
    }
}

/* Very Small Mobile */
@media (max-width: 375px) {
    .modal-actions {
        padding: 10px;
        gap: 4px;
    }
    
    .modal-actions .btn {
        padding: 10px 12px;
        font-size: 0.85rem;
        min-height: 42px;
        gap: 5px;
    }
    
    /* Use shorter text */
    #modal-book-btn span {
        content: "Book Now";
    }
    
    #modal-contact-btn span {
        content: "Contact";
    }
}

/* Extra Small Mobile */
@media (max-width: 320px) {
    .modal-actions {
        padding: 8px;
        gap: 4px;
    }
    
    .modal-actions .btn {
        padding: 8px 10px;
        font-size: 0.8rem;
        min-height: 40px;
        gap: 4px;
    }
    
    .modal-actions .btn i {
        font-size: 0.9rem;
    }
    
    /* Even shorter text or icons only */
    #modal-book-btn span {
        content: "Book";
    }
    
    #modal-contact-btn span {
        content: "Message";
    }
    
    /* Alternative: Hide text, show only icons */
    /*
    .modal-actions .btn span {
        display: none;
    }
    
    .modal-actions .btn i {
        font-size: 1.1rem;
        margin: 0;
    }
    */
}

/* ===== ALTERNATIVE: SIDE-BY-SIDE ON WIDER SCREENS ===== */

/* For wider screens, you might want side-by-side buttons */
@media (min-width: 769px) {
    .modal-actions {
        grid-template-columns: 1fr 1fr; /* Two columns */
        grid-template-rows: auto; /* Single row */
    }
    
    #modal-book-btn {
        grid-column: 1; /* First column */
        grid-row: 1;
    }
    
    #modal-contact-btn {
        grid-column: 2; /* Second column */
        grid-row: 1;
    }
}

/* ===== ENSURE BUTTONS ARE ALWAYS VISIBLE ===== */

/* Make sure modal content doesn't hide buttons */
.property-modal .modal-content {
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

.modal-actions {
    flex-shrink: 0; /* Don't shrink buttons */
    margin-top: auto; /* Push to bottom */
}

/* Optional: Add sticky positioning for long modals */
.modal-actions {
    position: sticky;
    bottom: 0;
    background: var(--bg-gray);
    z-index: 10;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* Lazy Loading Styles */
.lazy-loading-overlay {
    position: relative;
    min-height: 100px;
}

.lazy-loading-indicator {
    text-align: center;
    padding: 20px;
    display: none;
}

.lazy-loading-indicator.active {
    display: block;
}

.lazy-loading-indicator .spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 10px;
}

.lazy-loading-indicator .loading-text {
    color: #666;
    font-size: 14px;
}

.load-more-btn {
    display: block;
    width: 200px;
    margin: 20px auto;
    padding: 12px 24px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
}

.load-more-btn:hover:not(:disabled) {
    background: var(--primary-dark);
}

.load-more-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.load-more-btn .btn-text {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.load-more-btn.loading .btn-text {
    opacity: 0;
}

.load-more-btn .loading-spinner {
    display: none;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.load-more-btn.loading .loading-spinner {
    display: block;
}

.load-more-btn .loading-spinner .spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Add to your CSS */
.scroll-load-indicator {
    pointer-events: none;
    user-select: none;
}

/* Prevent accidental triggers on desktop */
@media (min-width: 769px) {
    .table-container {
        min-height: 600px; /* Ensure there's enough content before auto-load */
    }
}

/* Add smooth loading animation */
.property-row {
    animation: fadeInUp 0.5s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger the animations for loaded items */
.property-row:nth-child(n) {
    animation-delay: calc(var(--item-index, 0) * 0.1s);
}

.container-listings {
    width: 100%;
    max-width: 1800px;
    margin: 0 auto;
    padding: 0 5px;
}

.modal-close {
    /* Positioning */
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 9999;
    
    /* Visibility */
    display: flex;
    visibility: visible;
    opacity: 1;
    
    /* Button styling */
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #ddd;
    background: white;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    
    /* Ensure it's above modal content */
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Hover effects */
.modal-close:hover {
    background: #f0f0f0;
    border-color: #999;

}

/* Icon styling */
.modal-close i {
    font-size: 20px;
    color: #333;
    line-height: 1;
}

/* If using SVG */
.modal-close svg {
    width: 40px;
    height: 40px;
    stroke: #333;
    stroke-width: 2;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .modal-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
    }
    
    .modal-close i {
        font-size: 18px;
    }
}

/* Hide bed/bath and address on mobile ONLY */
@media (max-width: 768px) {
   
    .property-address-mobile {
        display: none !important;
    }
    
   
    .property-info-table-mobile {
        padding-bottom: 0;
    }
    
  
    .property-info-table-mobile h4 {
        font-size: 0.95rem !important;
        margin-bottom: 0 !important;
    }
}

/* Add to property-listings.css */
@media (max-width: 768px) {
    /* Prevent pull-to-refresh on mobile */
    body {
        overscroll-behavior-y: contain;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Better touch handling for table */
    .table-container {
        -webkit-overflow-scrolling: touch;
        overflow-x: auto;
        touch-action: pan-y;
    }
    
    /* Prevent text selection on touch */
    .properties-table {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
    
    /* Better button touch targets */
    .action-btn-mobile {
        min-height: 44px !important; /* Apple's recommended minimum */
        padding: 12px 8px !important;
    }
    
    /* Prevent double-tap zoom */
    .table-view,
    .property-listings {
        touch-action: manipulation;
    }
    
    /* Smooth scrolling */
    .properties-table tbody {
        scroll-behavior: smooth;
    }
}