/**
 * A2G Homes Map Styles
 * Modern, responsive design for the homes finder map
 */

/* Main Container */
.a2g-homes-map-wrapper {
    max-width: 100%;
    margin: 0 auto;
    background: #ffffff;
    overflow: hidden;
    min-height: 600px;
    gap: 30px;
}

/* Top section with filters and map */
.top-section {
    display: flex;
    min-height: 600px;
    gap: 30px;
}

/* Map content wrapper */
.map-content {
    width: 100%;
}

/* Main Content Area */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 600px;
}

/* Map and List Sections */
.map-section {
    min-height: 600px;
    flex: 0 0 auto;
}

.list-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 400px;
    margin-top: 20px;
    width: 100%;
}

/* Map Section */
.map-section {
    min-height: 600px;
    flex-direction: column;
    display: flex;
}

/* Map Section - Left Side */
.a2g-map-container {
    flex: 1;
    position: relative;
    min-height: 600px;
}

/* Filters Section - Sidebar */
.a2g-map-filters {
    width: 400px;
    background: #ffffff;
    padding: 32px;
    /* border-right: 1px solid #e9ecef; */
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
}

.filters-header {
    margin-bottom: 32px;
}

.filters-header h3 {
    color: #1B1E22;
    font-size: 28px;
    font-weight: 700;
    margin: 0 0 16px 0;
}

.filters-header p {
    color: #6B7280;
    font-size: 16px;
    margin: 0;
    line-height: 1.6;
}

.results-counter {
    background: transparent;
    color: #6B7280;
    padding: 0;
    border-radius: 0;
    font-size: 14px;
    font-weight: 400;
    display: block;
    margin-top: 16px;
}

/* Filter Rows */
.filter-row {
    display: block;
    margin-bottom: 24px;
}

.filter-group {
    width: 100%;
}

.filter-group label {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #1B1E22;
    margin-bottom: 10px;
    font-size: 16px;
    font-family: 'Museo', sans-serif;
}

.filter-icon {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    background-image: url('../icons/location.svg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.search-icon {
    width: 20px;
    height: 20px;
    background-image: url('../icons/arrow-right.svg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin-left: 8px;
}

/* Form Inputs */
.filter-input,
.filter-select,
.sort-select {
    width: 100%;
    padding: 12px 16px!important;
    border: 2px solid #E5E7EB!important;
    border-radius: 20px!important;
    font-size: 14px!important;
    transition: all 0.3s ease!important;
    background: #ffffff!important;
    color: #1B1E22!important;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

.filter-select {
    background-image: url('../icons/down-arrow.svg');
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 40px;
}

.filter-input:focus,
.filter-select:focus {
    outline: none;
    border-color: #3B82F6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-input::placeholder {
    color: #9CA3AF;
}

/* Filter Actions */
.filter-actions {
    display: flex;
    flex-direction: row;
    gap: 12px;
    margin-top: auto;
    padding-top: 32px;
}

.reset-btn,
.search-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.reset-btn {
    background: transparent;
    color: #6B7280;
    border: 2px solid #E5E7EB;
}

.reset-btn:hover {
    background: #F9FAFB;
    color: #6B7280;
    border-color: #D1D5DB;
}

.search-btn {
    background: #8ACEF1;
    order: -1; 
}

.search-btn:hover {
    background: #2563EB;
    transform: translateY(-1px);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.2);
}

.reset-icon,
.search-icon {
    font-size: 22px;
}

/* Map Styles */
#a2g-homes-map {
    width: 100%;
    height: 100%;
    border-radius: 20px;
    min-height: 600px;
}

/* Map Loading */
.map-loading {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e9ecef;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

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

.map-loading p {
    color: #6c757d;
    font-size: 14px;
    margin: 0;
}

/* Map Error */
.map-error {
    padding: 40px;
    text-align: center;
    color: #dc3545;
}

.map-error h3 {
    margin: 0 0 16px 0;
    font-size: 18px;
}

.map-error p {
    margin: 0;
    font-size: 14px;
}

/* Info Window Styles */
.map-info-window {
    min-width: 200px;
}

.map-info-window h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #2c3e50;
}

.map-info-window p {
    margin: 0 0 8px 0;
    font-size: 14px;
    color: #6c757d;
}

/* Availability Badges */
.availability-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.availability-badge.available {
    background: #d4edda;
    color: #155724;
}

.availability-badge.limited {
    background: #fff3cd;
    color: #856404;
}

.availability-badge.waiting_list {
    background: #d1ecf1;
    color: #0c5460;
}

.availability-badge.full {
    background: #f8d7da;
    color: #721c24;
}

/* Home Details Modal */
.home-modal {
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.modal-content {
    background: #ffffff;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    /* overflow-y: auto; */
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e9ecef;
}

.close-modal {
    font-size: 28px;
    font-weight: bold;
    color: #adb5bd;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-modal:hover {
    color: #495057;
    background: #f8f9fa;
}

.availability-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 8px 0 16px 0;
}

.availability-overlay {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255, 255, 255, 0.95);
    padding: 6px 12px;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 5;
    margin: 0;
}

.availability-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.availability-dot.available {
    background: #28a745;
}

.availability-dot.unavailable {
    background: #dc3545;
}

.availability-dot.not_available {
    background: #dc3545;
}

.availability-dot.limited {
    background: #ffc107;
}

.availability-dot.waiting_list {
    background: #17a2b8;
}

.availability-dot.full {
    background: #dc3545;
}

.availability-text {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.modal-body {
    padding: 0;
}

.home-image {
    width: 100%;
    height: 200px;
    overflow: visible;
    position: relative;
    border-radius: 16px 16px 0 0;
}

.home-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 16px 16px 0 0;
    overflow: hidden;
}

.home-image .close-modal {
    position: absolute;
    top: -12px;
    right: -12px;
    background: black;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 10;
}

.home-details {
    padding: 24px;
}

#modal-home-title {
    font-size: 24px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 8px 0;
}

.home-address {
    color: #6c757d;
    font-size: 14px;
    margin: 0 0 16px 0;
}

.home-distance {
    color: #FF8C00;
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 12px 0;
}

.home-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
}

.home-badge.available {
    background: #d4edda;
    color: #155724;
}

.home-badge.limited {
    background: #fff3cd;
    color: #856404;
}

.home-badge.waiting_list {
    background: #d1ecf1;
    color: #0c5460;
}

.home-badge.full {
    background: #f8d7da;
    color: #721c24;
}

.home-description {
    color: #495057;
    line-height: 1.6;
    margin-bottom: 24px;
    font-size:15px
}

.home-specs {
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 20px;
    padding: 22px 30px;
    margin-bottom: 24px;
}

.spec-item {
    display:grid;
    grid-template-columns: 1fr 4fr;
    margin-bottom: 8px;
    font-size: 14px;
    gap:40px
}

.spec-item:last-child {
    margin-bottom: 0;
}

.spec-item label {
    font-weight: 500;
    color: #495057;
}

.spec-item span {
    color: #6c757d;
}

/* .home-actions {
    text-align: center;
} */

.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: #007bff;
    color: #ffffff;
}

.btn-primary:hover {
    background: #0056b3;
    transform: translateY(-1px);
    color: #ffffff;
}

/* Desktop Layout - Filters on Left, Map on Right, List Full Width Below */
@media (min-width: 1101px) {
    .a2g-homes-map-wrapper {
        align-items: stretch;
        min-height: 600px;
        flex-direction: column;
    }
    
    /* Top section with filters and map side by side */
    .top-section {
        display: flex;
        min-height: 600px;
        gap: 30px;
    }
    
    .a2g-map-filters {
        width: 400px;
        flex-shrink: 0;
        display: flex;
        flex-direction: column;
    }
    
    .map-content {
        flex: 1;
        display: flex;
        flex-direction: column;
        width: 100%;
    }
    
    .map-section {
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 600px;
    }
    
    .a2g-map-container {
        flex: 1;
        position: relative;
        min-height: 600px;
    }
    
    #a2g-homes-map {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100%;
    }
    
    /* List section spans full width */
    .list-section {
        width: 100%;
        margin-top: 30px;
    }
}

/* Mobile Layout - Filters on Top */
@media (max-width: 1100px) {
    .a2g-homes-map-wrapper {
        flex-direction: column;
    }
    
    .top-section {
        flex-direction: column;
    }
    
    .a2g-map-filters {
        width: 100%;
        padding: 24px;
        border-left: none;
        border-bottom: 1px solid #e9ecef;
        min-height: auto;
    }
    
    .map-content {
        width: 100%;
    }
    
    .a2g-map-container {
        min-height: 400px;
    }
}

/* Responsive Design */
@media (max-width: 768px) {

    
    .filters-header h3 {
        font-size: 24px;
    }
    
    .filter-actions {
        padding-top: 24px;
    }
    
    .modal-content {
        margin: 10px;
        max-height: 95vh;
    }
    
    .modal-header {
        padding: 16px;
    }
    
    .home-details {
        padding: 16px;
    }
    
    #modal-home-title {
        font-size: 20px;
    }
    
    .spec-item {
        flex-direction: column;
        gap: 4px;
    }
    
    .spec-item span {
        max-width: 100%;
        text-align: left;
    }
}

@media (max-width: 480px) {

    
    .filters-header h3 {
        font-size: 20px;
    }
    
    .filter-input,
    .filter-select {
        padding: 10px 12px;
        border-radius: 16px;
    }
    
    .filter-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .reset-btn,
    .search-btn {
        padding: 10px 16px;
        font-size: 13px;
        width: 100%;
    }
}

/* ===== LIST SECTION STYLES ===== */

/* List Section Container */
.list-section {
    flex-direction: column;
    display: flex;
    min-height: 400px;
}

/* Results Heading */
.results-heading-container {
    background: #ffffff;
    padding: 24px 32px 0;
    text-align: center;
}

.results-heading {
    margin: 0;
    text-align: center;
}

/* Fixed List Controls Container */
.list-view-controls-container {
    background: #ffffff;
    padding: 32px;
    border-bottom: 1px solid #e9ecef;
    flex-shrink: 0; /* Prevent shrinking */
    position: relative;
    z-index: 10;
}

.list-view-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* Filter Controls Wrapper */
.filter-controls-wrapper {
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 0 auto;
}

/* Scrollable Content Area */
.list-content-area {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.sort-control {
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    background: #F5F5F5;
    border: 1px solid #F5F5F5;
    border-radius: 24px;
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sort-control:hover {
    background: #EEEEEE;
    border-color: #EEEEEE;
}

.sort-control label {
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    min-width: fit-content;
    margin: 0;
    cursor: pointer;
}

.dropdown-arrow {
    color: #6B7280;
    transition: transform 0.2s ease;
}

.sort-select {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border: none;
    background: transparent;
}

.availability-toggles {
    display: flex;
    gap: 24px;
    align-items: center;
}

.toggle-label {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    background: #F5F5F5;
    border: 1px solid #F5F5F5;
    border-radius: 24px;
    padding: 8px 16px;
    transition: all 0.2s ease;
}

.toggle-label:hover {
    background: #EEEEEE;
    border-color: #EEEEEE;
}

/* Toggle Switch Styles */
.toggle-switch {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: relative;
    width: 44px;
    height: 24px;
    background: #E5E7EB;
    border-radius: 24px;
    transition: all 0.3s ease;
    cursor: pointer;
    order: -1;
}

.toggle-slider:before {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: #ffffff;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-switch:checked + .toggle-slider {
    background: #059669;
}

.toggle-switch:checked + .toggle-slider:before {
    transform: translateX(20px);
}

.toggle-switch:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.1);
}

.toggle-text {
    font-weight: 500;
    margin: 0;
}

/* List Loading */
.list-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 32px;
    background: #ffffff;
}

.list-loading .loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e9ecef;
    border-top: 3px solid #2563EB;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 16px;
}

/* Homes List */
.homes-list {
    padding: 32px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    flex: 1;
    min-height: 0; /* Allow flexbox to shrink properly */
}

/* Results Info */
.results-info {
    font-size: 14px;
    color: #6B7280;
    font-weight: 500;
    text-align: center;
}

/* Pagination */
.pagination-container {
    padding: 24px 32px;
    background: #ffffff;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
}

.pagination-info {
    font-size: 14px;
    color: #6B7280;
    margin-right: 24px;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pagination-btn {
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #374151;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
}

.pagination-link {
    color: #374151;
    text-decoration: none;
}

.pagination-link:hover,
.pagination-link:focus {
    text-decoration: none;
    color: #374151;
}

.pagination-btn:hover:not(:disabled) {
    background: #f9fafb;
    border-color: #9ca3af;
}

.pagination-btn:disabled,
.pagination-disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.pagination-btn.active {
    background: #2563EB;
    color: #ffffff;
    border-color: #2563EB;
}

.pagination-btn.active:hover {
    background: #1d4ed8;
}

.pagination-ellipsis {
    padding: 8px 4px;
    color: #6B7280;
    font-size: 14px;
}

/* Home Card */
.home-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    position: relative;
    height: 100%;
    min-height: 320px;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.home-card:visited {
    color: inherit;
}

.home-card:hover,
.home-card:focus {
    text-decoration: none;
    color: inherit;
}

.home-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.home-card-image {
    position: relative;
    height: 140px;
    overflow: hidden;
}

.home-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.distance-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: #FF8C00;
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

.home-card-content {
    padding: 14px;
    display: flex;
    gap:10px;
    flex-direction: column;
    flex: 1;
    font-size:16px;
}

.home-card-title {
    font-size: 16px;
    font-weight: 600;
    color: #1B1E22;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.home-card-address {
    font-size: 14px;
    color: #6B7280;
    margin: 0 0 8px 0;
    line-height: 1.2;
}

.home-card-location {
    font-size: 14px;
    color: #6B7280;
    margin: 0 0 16px 0;
}
.home-card-badge-container {
    display: flex;
    gap: 5px;
}
.home-card-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 16px;
    font-size: 11px;
    font-weight: 600;
    margin: 0;
}

.badge-residential-support {
    background: #E0F2FE;
    color: #0369A1;
}

.badge-supported-living {
    background: #DCFCE7;
    color: #166534;
}

.badge-day-services{
    background: #FEF3F0;
    color: #C63A14;
}

.badge-dom-care {
    background: #FFFBEB;
    color: #D97706;
}

.home-card-description {
    font-size: 13px;
    color: #374151;
    line-height: 1.5;
    margin-bottom: 12px;
}

/* .home-card-specs {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 8px 10px;
    margin-top: 8px;
    font-size: 12px;
}

.home-card-specs .spec-item {
    display: flex;
    align-items: flex-start;
    gap: 4px;
    font-size: 12px;
    margin-bottom: 4px;
}

.home-card-specs .spec-item:last-child {
    margin-bottom: 0;
}

.home-card-specs .spec-label {
    font-weight: 600;
    color: #374151;
    min-width: 65px;
    flex-shrink: 0;
}

.home-card-specs .spec-value {
    color: #6B7280;
    flex: 1;
    line-height: 1.3;
} */
.home-card-specs {
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.home-card-specs .spec-label {
    font-weight: 600;
}

.specialism-badge {
    background: #e0f2fe;
    color: #0369a1;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    border: 1px solid #bae6fd;
}

.spec-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 14px;
}

.spec-label {
    font-weight: 600;
    color: #374151;
    min-width: 120px;
}

.spec-value {
    color: #6B7280;
    flex: 1;
}

.home-card-features {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}

.feature-item {
    background: #f0f9ff;
    color: #0369a1;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    border: 1px solid #e0f2fe;
}

/* Remove the checkmark */
.feature-item::before {
    display: none;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .a2g-homes-map-wrapper {
        flex-direction: column;
    }
    
    .a2g-map-filters {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e9ecef;
        order: -1; /* Move filters to top on mobile */
    }
    
    .main-content {
        width: 100%;
    }
}

/* Hide filter labels on smaller screens */
@media (max-width: 1020px) {
    .filter-group label {
        display: none;
    }
}

@media (max-width: 1400px) {
    .homes-list {
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
    }
}

@media (max-width: 1200px) {
    .homes-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .homes-list {
        grid-template-columns: 1fr;
        padding: 16px;
        gap: 16px;
    }
    
    .results-heading-container {
        padding: 16px 16px 0;
    }
    
    
    .list-view-controls-container {
        padding: 16px;
    }
    
    .list-view-controls {
        flex-direction: column;
        gap: 16px;
        align-items: center;
    }
    
    .filter-controls-wrapper {
        flex-direction: column;
        gap: 16px;
        width: 100%;
        align-items: center;
    }
    
    .sort-control,
    .toggle-label {
        width: auto;
        min-width: 200px;
        justify-content: center;
    }
    
    .availability-toggles {
        width: auto;
    }
    
    .home-card-content {
        padding: 16px;
    }
    
    .home-card-specs .spec-label {
        min-width: 70px;
        font-size: 11px;
    }
    
    .home-card-specs .spec-value {
        font-size: 11px;
    }

    
    .a2g-map-filters {
        padding: 16px;
    }
    
    .a2g-homes-map-wrapper {
        border-radius: 0;
    }
    
    .pagination-container {
        padding: 16px;
        flex-direction: column;
        gap: 12px;
    }
    
    .pagination-controls {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* Print Styles */
@media print {
    .a2g-map-filters,
    .home-modal {
        display: none !important;
    }
    
    .a2g-homes-map-wrapper {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* ========================================
   A2G Homes Search Interface Styles
   ======================================== */

.a2g-homes-search-wrapper {
    color: white;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Service Tiles */
.service-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
    gap: 20px;
    width: 100%;
}

.service-tile {
    background: rgba(255, 255, 255, 0.1);
    border: 3px solid transparent;
    border-radius: 16px;
    padding: 16px 12px 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.service-tile:hover,
.service-tile:focus {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.service-tile:focus {
    outline: 3px solid white;
    outline-offset: 2px;
}

/* Service Tile Styles */
.service-tile.style-orange {
    border-color: #EE754B;
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.2), rgba(249, 115, 22, 0.1));
}

.service-tile.style-blue {
    border-color: #2CB7E9;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.2), rgba(6, 182, 212, 0.1));
}

.service-tile.style-orange-dark {
    border-color: #F8A800;
    background: linear-gradient(135deg, rgba(234, 88, 12, 0.2), rgba(234, 88, 12, 0.1));
}

.service-tile.style-green {
    border-color: #0DB179;
    background: linear-gradient(135deg, rgba(5, 150, 105, 0.2), rgba(5, 150, 105, 0.1));
}

.tile-content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    position: relative;
    z-index: 2;
}

.tile-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.availability-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}

.availability-dot {
    width: 12px;
    height: 12px;
    background-color: #10b981;
    border-radius: 50%;
    display: inline-block;
}

/* Override default green for service tiles based on actual availability */
.service-tile .availability-dot.available {
    background-color: #10b981;
}

.service-tile .availability-dot.unavailable {
    background-color: #ef4444;
}

.service-title {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 12px 0;
    line-height: 1.3;
    font-family:'Arial', sans-serif;
}

.service-count-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.service-count {
    font-size: 16px;
    font-weight: 700;
}

.tile-arrow {
    opacity: 0.8;
    flex-shrink: 0;
    margin-left: 12px;
}

.tile-arrow svg {
    width: 20px;
    height: 20px;
}

/* Homes Search Section */
.homes-search-section {
    width: 100%;
    max-width: 1200px;
    margin-top: 40px;
}

.homes-search-container {
    display: flex;
    align-items: center;
    background: white;
    border-radius: 50px;
    padding: 4px 4px 4px 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    height: 45px;
}

.homes-search-input-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

input#homes-search-input {
    border: none;
    background: none;
}

.homes-search-icon {
    color: #6b7280!important;
    z-index: 2;
    width: 20px;
    height: 20px;
}

.homes-search-input {
    width: 100%;
    padding: 0 24px 0 44px;
    border: none;
    border-radius: 0;
    font-size: 1rem;
    background: transparent;
    color: #374151;
    outline: none;
    font-weight: 400;
    height: 100%;
}

.homes-search-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

.homes-search-button {
    background: #06b6d4;
    color: white;
    border: none;
    border-radius: 0 50px 50px 0;
    padding: 0 32px;
    font-family:'museo', sans-serif;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    height: 37px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.homes-search-button:hover {
    background: #0891b2;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.homes-search-button:active {
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 768px) {
    .a2g-homes-search-wrapper {
        padding: 40px 15px;
    }
    
    .service-tiles {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    
    .service-tile {
        padding: 20px;
    }
    
    .homes-search-section {
        max-width: 100%;
        margin-top: 30px;
    }
    
    .homes-search-container {
        flex-direction: column;
        gap: 12px;
        padding: 12px;
        border-radius: 24px;
        height: auto;
        width: 100%;
        max-width: 100%;
    }
    
    .homes-search-input-wrapper {
        width: 100%;
        min-width: 0;
        flex-shrink: 0;
    }
    
    .homes-search-icon {
        left: 16px;
    }
    
    .homes-search-input {
        padding: 12px 20px 12px 48px;
        font-size: 1rem;
        height: 40px;
        border-radius: 20px;
        width: 100%;
        min-width: 0;
    }
    
    .homes-search-button {
        padding: 12px 32px;
        border-radius: 20px;
        font-size: 1rem;
        height: 40px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .service-tile {
        padding: 16px;
    }
    
    .service-title {
        font-size: 1.25rem;
    }
    
    .homes-search-section {
        margin-top: 20px;
    }
    
    .homes-search-container {
        padding: 8px;
        border-radius: 20px;
        height: auto;
        width: 100%;
        max-width: 100%;
    }
    
    .homes-search-input-wrapper {
        width: 100%;
        min-width: 0;
        flex-shrink: 0;
    }
    
    .homes-search-input {
        padding: 10px 16px 10px 40px;
        font-size: 0.875rem;
        height: 36px;
        border-radius: 16px;
        width: 100%;
        min-width: 0;
    }
    
    .homes-search-icon {
        width: 16px;
        height: 16px;
        left: 12px;
    }
    
    .homes-search-button {
        padding: 10px 24px;
        border-radius: 16px;
        font-size: 0.875rem;
        height: 36px;
    }
}

/* ========================================
   A2G Homes Simple Search Interface Styles
   ======================================== */

.a2g-homes-search-simple-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

.simple-search-container {
    position: relative;
    width: 100%;
    max-width: 400px;
}

.simple-search-input {
    width: 100%;
    padding: 10px 60px 10px 24px!important;
    border: none!important;
    border-radius: 50px!important;
    background: #ffffff!important;
    font-size: 18px!important;
    color: #374151;
    font-weight: 600!important;
    outline: none!important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15)!important;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.simple-search-input:focus {
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.2)!important;
    transform: translateY(-2px)!important;
}

.simple-search-input::placeholder {
    color: #6b7280;
    font-weight: 500;
}

.simple-search-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    width: 24px;
    height: 24px;
    cursor: pointer;
    transition: all 0.2s ease;
    pointer-events: auto;
}

.simple-search-icon:hover {
    color: #374151;
    transform: translateY(-50%) scale(1.1);
}

/* Responsive Design for Simple Search */
@media (max-width: 768px) {
    .simple-search-input {
        padding: 18px 50px 18px 20px;
        font-size: 16px;
    }
    
    .simple-search-icon {
        width: 20px;
        height: 20px;
        right: 16px;
    }
}

@media (max-width: 480px) {
    .simple-search-input {
        padding: 16px 45px 16px 18px;
        font-size: 16px;
        border-radius: 30px;
    }
    
    .simple-search-icon {
        width: 18px;
        height: 18px;
        right: 14px;
    }
}

/* ========================================
   A2G Nearby Homes Shortcode Styles
   ======================================== */

.a2g-nearby-homes-wrapper {
    max-width: 100%;
    margin: 0 auto;
    background: transparent;
    padding: 0;
}

.a2g-nearby-homes-no-results,
.a2g-nearby-homes-error {
    text-align: center;
    padding: 40px 20px;
    color: #6B7280;
    font-size: 16px;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px dashed #d1d5db;
}


/* Nearby Homes Grid */
.nearby-homes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    width: 100%;
}

/* Nearby Home Card */
.nearby-home-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    position: relative;
    height: 100%;
    min-height: 350px;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    border: 2px solid transparent;
}

.nearby-home-card:visited {
    color: inherit;
}

.nearby-home-card:hover,
.nearby-home-card:focus {
    text-decoration: none;
    color: inherit;
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border-color: #2563EB;
}

.nearby-home-card-image {
    position: relative;
    height: 160px;
    overflow: hidden;
    background: #f8f9fa;
}

.nearby-home-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nearby-home-no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
    color: #999;
    font-size: 14px;
}

.nearby-distance-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #FF8C00;
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.nearby-home-card-content {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.nearby-home-card-title {
    font-size: 18px;
    font-weight: 600;
    color: #1B1E22;
    margin: 0;
    line-height: 1.3;
}


.nearby-home-card-badge-container {
    display: flex;
    flex-direction: column;
    gap: 6px;
}


.nearby-home-card-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    align-self: flex-start;
}

.nearby-home-card-specs {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: auto;
}

.nearby-spec-label {
    font-size: 12px;
    font-weight: 600;
    color: #374151;
}

.nearby-spec-value {
    font-size: 13px;
    color: #6B7280;
    line-height: 1.4;
}

/* Responsive Design for Nearby Homes */

/* Tablet: 2 columns */
@media (max-width: 1024px) {
    .nearby-homes-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .a2g-nearby-homes-wrapper {
        padding: 0;
    }
    
    .nearby-homes-title {
        font-size: 28px;
    }
    
    .nearby-homes-subtitle {
        font-size: 16px;
    }
}

/* Mobile: 1 column */
@media (max-width: 768px) {
    .nearby-homes-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .a2g-nearby-homes-wrapper {
        padding: 0;
    }
    
    .nearby-homes-title {
        font-size: 24px;
    }
    
    .nearby-homes-subtitle {
        font-size: 14px;
    }
    
    .nearby-home-card {
        min-height: 320px;
    }
    
    .nearby-home-card-image {
        height: 140px;
    }
    
    .nearby-home-card-content {
        padding: 16px;
        gap: 10px;
    }
    
    .nearby-home-card-title {
        font-size: 16px;
    }
    
    .nearby-distance-badge {
        font-size: 11px;
        padding: 4px 8px;
    }
}

/* Extra small screens */
@media (max-width: 480px) {
    .a2g-nearby-homes-wrapper {
        padding: 0;
        margin: 0;
    }
    
    .nearby-homes-title {
        font-size: 20px;
    }
    
    .nearby-home-card {
        min-height: 300px;
    }
    
    .nearby-home-card-image {
        height: 120px;
    }
}