/**

 * Texas IDX Plugin Styles - Complete Version

 */



/* Container and Layout */

.mdg-reso-container {

    max-width: 100%;

    margin: 0 auto;

    padding: 20px 0;

}



.mdg-reso-results {

    width: 100%;

}



/* Modern Compact Search Form */

.mdg-reso-search-form {

    margin-bottom: 30px;

}



.mdg-reso-search-bar {

    display: flex;

    align-items: center;

    gap: 8px;

    padding: 12px;

    background: #fff;

    border-radius: 10px;

    transition: box-shadow 0.3s ease;

}





.mdg-search-input {

    flex: 1;

    min-width: 200px;

    max-width: 300px;

    padding: 10px 18px;

    border: none;

    background: #f8f8f8;

    border-radius: 20px;

    font-size: 14px;

    color: #333;

    outline: none;

    transition: background 0.2s ease;

}



.mdg-search-input:focus {

    background: #f0f0f0;

}



.mdg-search-input::placeholder {

    color: #999;

}



/* Custom Filter Dropdowns */

.mdg-custom-filter {

    position: relative;

}



.mdg-filter-trigger {

    padding: 10px 16px;

    border: 1px solid #e0e0e0;

    background: #fff;

    border-radius: 24px;

    font-size: 13px;

    font-weight: 500;

    color: #333;

    cursor: pointer;

    transition: background-color 0.2s ease, border-color 0.2s ease;

    outline: none;

    display: inline-flex;

    align-items: center;

    gap: 6px;

    white-space: nowrap;

    box-sizing: border-box;

}



.mdg-filter-trigger .filter-label {

    font-size: 13px;

    color: #333;

}



.mdg-filter-trigger .filter-arrow {

    font-size: 10px;

    color: #666;

    transition: transform 0.3s ease;

    margin-left: 2px;

}



.mdg-custom-filter.active .mdg-filter-trigger .filter-arrow {

    transform: rotate(180deg);

}



.mdg-filter-trigger:hover {

    background: #f0f0f0;

    border: 1px solid #999;

    color: #333;

}



.mdg-custom-filter.active .mdg-filter-trigger {

    background: #e8e8e8;

    border: 1px solid #999;

}



.mdg-custom-filter.active .mdg-filter-trigger:hover {

    background: #ddd;

    border: 1px solid #888;

    color: #333;

}



/* Filter Panels */

.mdg-filter-panel {

    position: absolute;

    top: calc(100% + 8px);

    left: 0;

    background: #fff;

    border: 1px solid #ddd;

    border-radius: 16px;

    padding: 20px;

    box-shadow: 0 8px 24px rgba(0,0,0,0.12);

    z-index: 1000;

    min-width: 280px;

    display: none;

}



.mdg-custom-filter.active .mdg-filter-panel {

    display: block;

    animation: slideDown 0.2s ease;

}



@keyframes slideDown {

    from {

        opacity: 0;

        transform: translateY(-10px);

    }

    to {

        opacity: 1;

        transform: translateY(0);

    }

}



.filter-panel-header {

    font-size: 14px;

    font-weight: 600;

    color: #222;

    margin-bottom: 16px;

}



/* Price Range Slider */

.price-range-display {

    display: flex;

    align-items: center;

    justify-content: space-between;

    margin-bottom: 20px;

    gap: 12px;

}



.price-value {

    flex: 1;

    padding: 10px 14px;

    background: #f8f8f8;

    border-radius: 8px;

    text-align: center;

}



.price-min-display,

.price-max-display {

    font-size: 15px;

    font-weight: 600;

    color: #333;

}



.price-separator {

    color: #999;

    font-weight: 300;

}



.slider-container {

    position: relative;

    height: 40px;

    margin-bottom: 8px;

}



.price-slider {

    position: absolute;

    width: 100%;

    height: 6px;

    background: transparent;

    -webkit-appearance: none;

    appearance: none;

    outline: none;

    pointer-events: none;

}



.price-slider::-webkit-slider-track {

    width: 100%;

    height: 6px;

    background: #e0e0e0;

    border-radius: 3px;

}



.price-slider::-webkit-slider-thumb {

    -webkit-appearance: none;

    appearance: none;

    width: 20px;

    height: 20px;

    background: #333;

    border: 3px solid #fff;

    border-radius: 50%;

    cursor: pointer;

    pointer-events: all;

    box-shadow: 0 2px 6px rgba(0,0,0,0.2);

}



.price-slider::-moz-range-track {

    width: 100%;

    height: 6px;

    background: #e0e0e0;

    border-radius: 3px;

}



.price-slider::-moz-range-thumb {

    width: 20px;

    height: 20px;

    background: #333;

    border: 3px solid #fff;

    border-radius: 50%;

    cursor: pointer;

    pointer-events: all;

    box-shadow: 0 2px 6px rgba(0,0,0,0.2);

}



.price-slider:hover::-webkit-slider-thumb {

    background: #000;

}



.price-slider:hover::-moz-range-thumb {

    background: #000;

}



.filter-panel-labels {

    display: flex;

    justify-content: space-between;

    font-size: 11px;

    color: #999;

    margin-top: 4px;

}



/* Number Options (Beds/Baths) */

.number-options {

    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 8px;

}



.number-option {

    padding: 12px;

    border: 2px solid #e0e0e0;

    background: #fff;

    border-radius: 10px;

    font-size: 14px;

    font-weight: 600;

    color: #666;

    cursor: pointer;

    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;

    text-align: center;

    box-sizing: border-box;

}



.number-option:hover {

    border: 2px solid #ccc;

    background: #f8f8f8;

    color: #666;

}



.number-option.active {

    border: 2px solid #333;

    background: #333;

    color: #fff;

}



.number-option.active:hover {

    border: 2px solid #000;

    background: #000;

    color: #fff;

}



/* Type Options */

.type-options {

    display: flex;

    flex-direction: column;

    gap: 8px;

}



.type-option {

    padding: 12px 16px;

    border: 2px solid #e0e0e0;

    background: #fff;

    border-radius: 10px;

    font-size: 14px;

    font-weight: 500;

    color: #666;

    cursor: pointer;

    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;

    text-align: left;

    box-sizing: border-box;

}



.type-option:hover {

    border: 2px solid #ccc;

    background: #f8f8f8;

    color: #666;

}



.type-option.active {

    border: 2px solid #333;

    background: #333;

    color: #fff;

}



.type-option.active:hover {

    border: 2px solid #000;

    background: #000;

    color: #fff;

}



.mdg-search-btn {

    padding: 10px 28px;

    background: #333;

    color: #fff;

    border: none;

    border-radius: 25px;

    font-size: 14px;

    font-weight: 600;

    cursor: pointer;

    transition: all 0.3s ease;

    white-space: nowrap;

}



.mdg-search-btn:hover {

    background: #555;

    box-shadow: 0 4px 12px rgba(0,0,0,0.2);

}



.mdg-search-reset {

    padding: 10px 16px;

    background: #f5f5f5;

    color: #666;

    border: 1px solid #ddd;

    border-radius: 25px;

    font-size: 13px;

    font-weight: 500;

    cursor: pointer;

    transition: background 0.2s ease, color 0.2s ease;

    white-space: nowrap;

    margin-left: 8px;

    display: inline-flex;

    align-items: center;

    gap: 5px;

}



.mdg-search-reset .reset-icon {

    font-size: 16px;

    font-weight: 300;

    line-height: 1;

}



.mdg-search-reset:hover {

    background: #e8e8e8;

    color: #333;

    border: 1px solid #ddd !important;

    padding: 10px 16px !important;

    font-weight: 500;

}



/* Spacer to push map toggle to the end */

.mdg-search-spacer {

    flex: 1;

    min-width: 20px;

}



/* Map Toggle Inline in Search Bar */

.mdg-map-toggle-inline {

    display: flex;

    align-items: center;

    margin-left: auto;

}



.mdg-reso-search-bar .mdg-map-toggle-wrapper {

    display: inline-flex;

    align-items: center;

    gap: 8px;

    padding: 6px 12px;

    background: #f5f5f5;

    border-radius: 20px;

    cursor: pointer;

    transition: all 0.2s ease;

}



.mdg-reso-search-bar .mdg-map-toggle-wrapper:hover {

    background: #e8e8e8;

}



.mdg-reso-search-bar .mdg-map-toggle-label {

    font-size: 13px;

    font-weight: 500;

    color: #333;

    order: 2;

}



.mdg-reso-search-bar .mdg-map-toggle-switch {

    width: 40px;

    height: 22px;

    background-color: #ddd;

    border-radius: 22px;

    transition: background-color 0.3s ease;

    order: 1;

}



.mdg-reso-search-bar .mdg-map-toggle-switch::before {

    width: 16px;

    height: 16px;

    top: 3px;

    left: 3px;

    transition: transform 0.3s ease;

}



.mdg-reso-search-bar .mdg-map-toggle-input:checked + .mdg-map-toggle-switch {

    background-color: #4CAF50;

}



.mdg-reso-search-bar .mdg-map-toggle-input:checked + .mdg-map-toggle-switch::before {

    transform: translateX(18px);

}



/* Grid Layout - FIXED */

.mdg-reso-grid {

    display: grid;

    gap: 20px;

    margin-bottom: 30px;

    width: 100%;

}



.mdg-reso-grid.mdg-reso-cols-1 {

    grid-template-columns: 1fr;

}



.mdg-reso-grid.mdg-reso-cols-2 {

    grid-template-columns: repeat(2, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-3 {

    grid-template-columns: repeat(3, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-4 {

    grid-template-columns: repeat(4, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-5 {

    grid-template-columns: repeat(5, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-6 {

    grid-template-columns: repeat(6, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-7 {

    grid-template-columns: repeat(7, 1fr);

}



.mdg-reso-grid.mdg-reso-cols-8 {

    grid-template-columns: repeat(8, 1fr);

}



/* Property Card - FIXED */

.mdg-reso-card {

    background: white;

    border-radius: 8px;

    overflow: hidden;

    box-shadow: 0 2px 8px rgba(0,0,0,0.1);

    transition: transform 0.3s ease, box-shadow 0.3s ease;

    cursor: pointer;

    display: flex;

    flex-direction: column;

    height: 100%;

}



.mdg-reso-card:hover {

    box-shadow: 0 4px 16px rgba(0,0,0,0.15);

}



.mdg-reso-card-image {

    position: relative;

    width: 100%;

    padding-bottom: 66.67%; /* 3:2 Aspect Ratio */

    overflow: hidden;

    background: #f0f0f0;

}

/* Card Action Buttons (Save/Share) */
.mdg-reso-card-actions {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    gap: 8px;
    z-index: 10;
    opacity: 1;
}

.mdg-reso-card-action-btn,
.mdg-reso-card-action-btn:hover,
.mdg-reso-card-action-btn:focus,
.mdg-reso-card-action-btn:active {
    width: 28px !important;
    height: 28px !important;
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 !important;
    transition: transform 0.15s ease, opacity 0.15s ease;
    color: #fff;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.5));
}

.mdg-reso-card-action-btn:hover {
    transform: scale(1.15);
    opacity: 0.85;
}

.mdg-reso-card-action-btn svg {
    width: 22px;
    height: 22px;
}

.mdg-reso-card-save.saved,
.mdg-reso-card-save.saved:hover {
    color: #e74c3c !important;
}

.mdg-reso-card-save.saved svg {
    fill: #e74c3c;
}

.mdg-reso-card-image img {

    position: absolute;

    top: 0;

    left: 0;

    width: 100%;

    height: 100%;

    object-fit: cover;

    transition: transform 0.3s ease;

}



.mdg-reso-card:hover .mdg-reso-card-image img {

    transform: scale(1.05);

}



.mdg-reso-no-image {

    position: absolute;

    top: 0;

    left: 0;

    width: 100%;

    height: 100%;

    display: flex;

    align-items: center;

    justify-content: center;

    background: #f5f5f5;

    color: #999;

}





.mdg-reso-photo-count {

    position: absolute;

    bottom: 10px;

    right: 10px;

    background: rgba(0,0,0,0.7);

    color: white;

    padding: 5px 10px;

    border-radius: 4px;

    font-size: 12px;

}



/* Status Badge */

.mdg-reso-status-badge {

    position: absolute;

    top: 10px;

    left: 10px;

    padding: 6px 12px;

    border-radius: 4px;

    font-size: 12px;

    font-weight: 700;

    text-transform: uppercase;

    letter-spacing: 0.5px;

    z-index: 10;

}



/* Status colors based on MLS status */

.mdg-reso-status-active {

    background: #27ae60;

    color: white;

}



.mdg-reso-status-pending {

    background: #f39c12;

    color: white;

}



.mdg-reso-status-sold,

.mdg-reso-status-closed {

    background: #e74c3c;

    color: white;

}



.mdg-reso-status-coming-soon,

.mdg-reso-status-active-under-contract {

    background: #3498db;

    color: white;

}



.mdg-reso-status-expired,

.mdg-reso-status-withdrawn,

.mdg-reso-status-canceled,

.mdg-reso-status-cancelled {

    background: #95a5a6;

    color: white;

}



.mdg-reso-status-hold {

    background: #9b59b6;

    color: white;

}



/* Overlay Card Layout */

.mdg-reso-card-overlay .mdg-reso-card-image {

    position: relative;

}



.mdg-reso-card-overlay .mdg-reso-card-image::after {

    content: '';

    position: absolute;

    bottom: 0;

    left: 0;

    right: 0;

    height: 70%;

    background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.85) 100%);

    pointer-events: none;

    z-index: 1;

}



.mdg-reso-card-overlay .mdg-reso-card-details {

    position: absolute;

    bottom: 0;

    left: 0;

    right: 0;

    padding: 20px;

    background: transparent;

    z-index: 2;

    color: #ffffff;

}



.mdg-reso-card-overlay .mdg-reso-price,

.mdg-reso-card-overlay .mdg-reso-address,

.mdg-reso-card-overlay .mdg-reso-features,

.mdg-reso-card-overlay .mdg-reso-features span {

    color: #ffffff !important;

}



.mdg-reso-card-overlay .mdg-reso-status-badge,

.mdg-reso-card-overlay .mdg-reso-photo-count {

    z-index: 3;

}



/* Standard Card Layout (default) */

.mdg-reso-card-details {

    padding: 15px;

    display: flex;

    flex-direction: column;

    flex: 1;

}



.mdg-reso-price {

    font-size: 24px;

    font-weight: 600;

    color: #2c3e50;

}



.mdg-reso-address {

    font-size: 16px;

    color: #333;

    margin-bottom: 5px;

    font-weight: 400;

    line-height: 1.4;

}



.mdg-reso-city {

    font-size: 14px;

    color: #666;

    margin-bottom: 15px;

}



.mdg-reso-features {

    display: flex;

    gap: 15px;

    padding-top: 5px;

    flex-wrap: wrap;

}



.mdg-reso-feature {

    font-size: 14px;

    color: #555;

    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 4px;

}

.mdg-reso-feature svg {
    flex-shrink: 0;
    opacity: 0.7;
}



.mdg-reso-feature strong {

    font-weight: 600;

}



.mdg-reso-actions {

    display: flex;

    gap: 10px;

    margin-top: auto;

}



/* Buttons */

.mdg-reso-btn {

    display: inline-block;

    padding: 10px 20px;

    border: none;

    border-radius: 4px;

    font-size: 14px;

    font-weight: 600;

    text-decoration: none;

    text-align: center;

    cursor: pointer;

    transition: background-color 0.3s ease;

    width: 100%;

}



.mdg-reso-btn-primary,

.mdg-reso-btn.mdg-reso-btn-primary {

    background: #3498db;

    color: white;

}



.mdg-reso-btn-primary:hover,

.mdg-reso-btn.mdg-reso-btn-primary:hover {

    background: #2980b9;

    color: white;

    text-decoration: none;

}



.mdg-reso-btn-secondary {

    background: #95a5a6;

    color: white;

}



.mdg-reso-btn-secondary:hover {

    background: #7f8c8d;

    color: white;

}



/* List View */

.mdg-reso-list {

    display: flex;

    flex-direction: column;

    gap: 20px;

    width: 100%;

}



.mdg-reso-row {

    display: flex;

    background: white;

    border-radius: 8px;

    overflow: hidden;

    box-shadow: 0 2px 8px rgba(0,0,0,0.1);

    transition: box-shadow 0.3s ease;

    cursor: pointer;

}



.mdg-reso-row:hover {

    box-shadow: 0 4px 16px rgba(0,0,0,0.15);

}



.mdg-reso-row-image {

    width: 300px;

    flex-shrink: 0;

    position: relative;

    background: #f0f0f0;

}



.mdg-reso-row-image img {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.mdg-reso-row-details {

    padding: 20px;

    flex: 1;

    display: flex;

    flex-direction: column;

    justify-content: space-between;

}



.mdg-reso-row-info {

    flex: 1;

}



.mdg-reso-row-actions {

    padding-top: 15px;

    border-top: 1px solid #eee;

}



/* Pagination */

.mdg-reso-pagination {

    display: flex;

    justify-content: center;

    align-items: center;

    gap: 10px;

    margin-top: 30px;

    flex-wrap: wrap;

}



.mdg-reso-page {

    display: inline-block;

    padding: 8px 12px;

    background: white;

    border: 1px solid #ddd;

    border-radius: 4px;

    color: #333;

    text-decoration: none;

    transition: all 0.3s ease;

}



.mdg-reso-page:hover {

    background: #3498db;

    color: white;

    border-color: #3498db;

}



.mdg-reso-page.current {

    background: #3498db;

    color: white;

    border-color: #3498db;

    font-weight: bold;

}



.mdg-reso-prev,

.mdg-reso-next {

    background: #3498db;

    color: white;

    border: none;

    font-weight: 600;

}



.mdg-reso-prev:hover,

.mdg-reso-next:hover {

    background: #2980b9;

    border: none;

}



/* Loading State */

.mdg-reso-loading {

    text-align: center;

    padding: 40px;

}



.mdg-reso-loading .spinner {

    display: inline-block;

    width: 40px;

    height: 40px;

    border: 4px solid #f3f3f3;

    border-top: 4px solid #3498db;

    border-radius: 50%;

    animation: spin 1s linear infinite;

}



@keyframes spin {

    0% { transform: rotate(0deg); }

    100% { transform: rotate(360deg); }

}



/* Error State */

.mdg-reso-error {

    background: #fee;

    border: 1px solid #fcc;

    border-radius: 4px;

    padding: 20px;

    text-align: center;

    color: #c00;

}



.mdg-reso-no-results {

    text-align: center;

    padding: 40px;

    color: #666;

    font-size: 16px;

}



/* Map Toggle Switch */

.mdg-view-toggle {

    display: flex;

    justify-content: flex-end;

    margin-bottom: 20px;

}



/* When inside search form */

.mdg-reso-search-form .mdg-view-toggle {

    padding-top: 20px;

    margin-top: 20px;

    margin-bottom: 0;

    border-top: 1px solid #e0e0e0;

}



/* When standalone (no search form) */

.mdg-reso-container > .mdg-view-toggle {

    padding: 15px;

    background: #f8f9fa;

    border-radius: 8px;

    margin-bottom: 20px;

}



.mdg-map-toggle-wrapper {

    display: inline-flex;

    align-items: center;

    gap: 12px;

    cursor: pointer;

    user-select: none;

}



.mdg-map-toggle-label {

    font-size: 16px;

    font-weight: 600;

    color: #333;

}



.mdg-map-toggle-input {

    position: absolute;

    opacity: 0;

    width: 0;

    height: 0;

}



.mdg-map-toggle-switch {

    position: relative;

    display: inline-block;

    width: 52px;

    height: 28px;

    background-color: #ccc;

    border-radius: 28px;

    transition: background-color 0.3s ease;

}



.mdg-map-toggle-switch::before {

    content: '';

    position: absolute;

    width: 22px;

    height: 22px;

    border-radius: 50%;

    background-color: white;

    top: 3px;

    left: 3px;

    transition: transform 0.3s ease;

    box-shadow: 0 2px 4px rgba(0,0,0,0.2);

}



.mdg-map-toggle-input:checked + .mdg-map-toggle-switch {

    background-color: #4CAF50;

}



.mdg-map-toggle-input:checked + .mdg-map-toggle-switch::before {

    transform: translateX(24px);

}



.mdg-map-toggle-input:focus + .mdg-map-toggle-switch {

    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.2);

}



.mdg-map-toggle-wrapper:hover .mdg-map-toggle-switch {

    background-color: #b3b3b3;

}



.mdg-map-toggle-wrapper:hover .mdg-map-toggle-input:checked + .mdg-map-toggle-switch {

    background-color: #45a049;

}



/* Map Container */

#mdg-listings-map,

#mdg-property-map {

    width: 100%;

    border: 1px solid #ddd;

    border-radius: 8px;

    box-shadow: 0 2px 4px rgba(0,0,0,0.1);

}

/* Custom Map Marker Styles */
.mdg-map-price-marker {
    position: relative;
}

.mdg-map-price-marker span {
    display: inline-block;
    background: #e74c3c;
    color: #fff;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: bold;
    font-size: 12px;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0,0,0,0.3);
    transform: translateY(-50%);
}

.mdg-map-price-marker::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #e74c3c;
}

#mdg-listings-map {

    display: none;

    height: 600px;

    margin-bottom: 20px;

}



.mdg-reso-container.map-view #mdg-listings-map {

    display: block;

}



/* Split-Screen Map View */

.mdg-reso-map-view-split {

    display: flex;

    gap: 20px;

    margin-bottom: 20px;

}



.mdg-reso-map-view-listings {

    flex: 1;

    min-width: 0; /* Prevent flex item from overflowing */

}



.mdg-reso-map-view-map {

    flex: 1;

    position: sticky;

    top: 20px;

    align-self: flex-start;

    height: calc(100vh - 40px); /* Full height minus top (20px) and bottom (20px) gaps */

}



.mdg-reso-map-view-map #mdg-listings-map {

    display: block;

    height: 100%;

    margin-bottom: 0;

}



/* Map Info Window - Modern Card Style */

.mdg-map-info-window {
    max-width: 280px;
    min-width: 260px;
    padding: 0;
    box-sizing: border-box;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.mdg-map-info-window .mdg-info-image-wrapper {
    position: relative;
    overflow: hidden;
}

.mdg-map-info-window img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    margin: 0;
    display: block;
    transition: transform 0.3s ease;
}

.mdg-map-info-window:hover img {
    transform: scale(1.05);
}

.mdg-map-info-window .mdg-info-price-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 6px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}

.mdg-map-info-window .mdg-info-content {
    padding: 14px 16px;
    background: #fff;
}

.mdg-map-info-window h4 {
    color: #1a1a2e;
    margin: 0 0 8px 0;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    word-wrap: break-word;
}

.mdg-map-info-window .mdg-info-features {
    display: flex;
    gap: 12px;
    font-size: 13px;
    color: #555;
    margin: 0 0 14px 0;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.mdg-map-info-window .mdg-info-feature {
    display: flex;
    align-items: center;
    gap: 4px;
}

.mdg-map-info-window .mdg-info-feature strong {
    color: #1a1a2e;
    font-weight: 600;
}

.mdg-map-info-window .mdg-reso-btn {
    display: block;
    width: 100%;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    box-sizing: border-box;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.mdg-map-info-window .mdg-reso-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Override Google Maps info window default styles */
.gm-style-iw-c {
    padding: 0 !important;
    max-width: 300px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15) !important;
    overflow: hidden !important;
}

.gm-style-iw-d {
    overflow: hidden !important;
    max-width: 300px !important;
    padding: 0 !important;
}

/* Remove any wrapper padding that causes white space */
.gm-style-iw-chr {
    display: none !important;
}

/* Custom close button positioned on image */
.gm-style-iw-c button.gm-ui-hover-effect {
    position: absolute !important;
    top: 8px !important;
    right: 8px !important;
    width: 28px !important;
    height: 28px !important;
    background: rgba(255,255,255,0.9) !important;
    border-radius: 50% !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2) !important;
    opacity: 1 !important;
    z-index: 10 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
}

.gm-style-iw-c button.gm-ui-hover-effect:hover {
    background: #fff !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3) !important;
}

.gm-style-iw-c button.gm-ui-hover-effect > span {
    width: 16px !important;
    height: 16px !important;
    margin: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.gm-style-iw-c button.gm-ui-hover-effect > span > img,
.gm-style-iw-c button.gm-ui-hover-effect > span > svg {
    width: 14px !important;
    height: 14px !important;
}

/* Remove the tail/arrow pointer styling issues */
.gm-style-iw-tc {
    display: none !important;
}

/* Responsive Design for Grid */

@media (max-width: 1600px) {

    .mdg-reso-grid.mdg-reso-cols-8,

    .mdg-reso-grid.mdg-reso-cols-7 {

        grid-template-columns: repeat(5, 1fr);

    }

    

    .mdg-reso-grid.mdg-reso-cols-6,

    .mdg-reso-grid.mdg-reso-cols-5 {

        grid-template-columns: repeat(4, 1fr);

    }

}



@media (max-width: 1200px) {

    .mdg-reso-grid.mdg-reso-cols-8,

    .mdg-reso-grid.mdg-reso-cols-7,

    .mdg-reso-grid.mdg-reso-cols-6,

    .mdg-reso-grid.mdg-reso-cols-5,

    .mdg-reso-grid.mdg-reso-cols-4 {

        grid-template-columns: repeat(3, 1fr);

    }

}



@media (max-width: 992px) {

    .mdg-reso-grid.mdg-reso-cols-8,

    .mdg-reso-grid.mdg-reso-cols-7,

    .mdg-reso-grid.mdg-reso-cols-6,

    .mdg-reso-grid.mdg-reso-cols-5,

    .mdg-reso-grid.mdg-reso-cols-4,

    .mdg-reso-grid.mdg-reso-cols-3 {

        grid-template-columns: repeat(2, 1fr);

    }

    

    /* Tablet - custom filters 2 per row */

    .mdg-custom-filter {

        flex: 1 1 calc(50% - 4px);

        min-width: 140px;

    }

    

    .mdg-filter-panel {

        left: 50%;

        transform: translateX(-50%);

        min-width: 280px;

        max-width: 400px;

    }

}



@media (max-width: 768px) {

    .mdg-reso-search-fields {

        grid-template-columns: repeat(2, 1fr);

    }

    

    .mdg-reso-grid.mdg-reso-cols-2,

    .mdg-reso-grid.mdg-reso-cols-3,

    .mdg-reso-grid.mdg-reso-cols-4,

    .mdg-reso-grid.mdg-reso-cols-5,

    .mdg-reso-grid.mdg-reso-cols-6,

    .mdg-reso-grid.mdg-reso-cols-7,

    .mdg-reso-grid.mdg-reso-cols-8 {

        grid-template-columns: repeat(2, 1fr);

    }

    

    .mdg-reso-row {

        flex-direction: column;

    }

    

    .mdg-reso-row-image {

        width: 100%;

        height: 200px;

    }

    

    #mdg-listings-map {
        height: 650px !important;
        margin-bottom: 16px;
    }
    
    .mdg-view-toggle {
        text-align: center;
    }
    
    /* Stack split-screen on mobile */
    .mdg-reso-map-view-split {
        flex-direction: column;
        gap: 12px;
    }
    
    .mdg-reso-map-view-map {
        position: relative !important;
        top: 0 !important;
        height: 650px !important;
        max-height: none !important;
        order: -1; /* Show map first on mobile */
        width: 100%;
        margin-bottom: 12px;
    }
    
    .mdg-reso-map-view-listings {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }
    
    .mdg-reso-map-view-listings .mdg-reso-grid {
        height: auto !important;
        max-height: none !important;
        overflow: visible !important;
    }
    
    .mdg-reso-map-view-listings .mdg-reso-card {
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        flex: none !important;
    }
    
    .mdg-reso-map-view-listings .mdg-reso-card-image {
        height: auto !important;
        padding-bottom: 66.67% !important;
    }
    
    .mdg-reso-map-view-listings .mdg-reso-card-details {
        height: auto !important;
        overflow: visible !important;
    }

}



@media (max-width: 576px) {

    .mdg-reso-grid.mdg-reso-cols-2,

    .mdg-reso-grid.mdg-reso-cols-3,

    .mdg-reso-grid.mdg-reso-cols-4,

    .mdg-reso-grid.mdg-reso-cols-5,

    .mdg-reso-grid.mdg-reso-cols-6,

    .mdg-reso-grid.mdg-reso-cols-7,

    .mdg-reso-grid.mdg-reso-cols-8 {

        grid-template-columns: 1fr;

    }

    .mdg-reso-search-field {

        min-width: 0;

        width: 100%;

    }

    .mdg-reso-features {

        flex-direction: column;

        gap: 8px;

    }

    .mdg-reso-search-actions .mdg-reso-btn {

        padding: 12px 6px;

        font-size: 14px;

    }

    

    .mdg-reso-feature {

        display: flex;

        justify-content: space-between;

    }

    

    .mdg-reso-search-form {
        margin-bottom: 16px;
    }
    
    /* Responsive search bar - stack on mobile */
    .mdg-reso-search-bar {
        flex-wrap: wrap;
        border-radius: 10px;
        padding: 12px;
        gap: 8px;
    }

    .mdg-search-input {
        width: 100%;
        min-width: unset;
        max-width: unset;
        order: -1;
        margin-bottom: 4px;
        border-radius: 24px;
        padding: 12px 16px;
    }

    /* Custom filters on mobile - equal width grid */
    .mdg-custom-filter {
        flex: 1 1 calc(50% - 4px);
        min-width: 0;
        max-width: calc(50% - 4px);
    }

    .mdg-filter-trigger {
        width: 100%;
        justify-content: center;
        font-size: 12px;
        padding: 10px 8px;
        text-align: center;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .mdg-filter-trigger .filter-label {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mdg-filter-trigger .filter-arrow {
        flex-shrink: 0;
    }

    .mdg-filter-panel {
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        min-width: 280px;
        max-width: calc(100vw - 32px);
        width: auto;
        padding: 16px;
    }

    

    /* Price range on mobile */

    .price-range-display {

        flex-direction: row;

        gap: 8px;

    }

    

    .price-value {

        padding: 8px 10px;

    }

    

    .price-min-display,

    .price-max-display {

        font-size: 13px;

    }

    

    /* Number and type options on mobile */

    .number-options {

        grid-template-columns: repeat(3, 1fr);

        gap: 6px;

    }

    

    .number-option {

        padding: 10px 8px;

        font-size: 13px;

    }

    

    .type-option {

        padding: 10px 14px;

        font-size: 13px;

    }

    

    .filter-panel-header {

        font-size: 13px;

        margin-bottom: 12px;

    }

    

    .mdg-search-btn {

        width: 100%;

        margin-top: 8px;

    }

    .mdg-search-reset {
        width: auto;
        margin-top: 8px;
        margin-left: 0;
        padding: 8px 14px;
        font-size: 12px;

        top: 10px;

        right: 10px;

        bottom: auto;

        left: auto;

    }

    

    .mdg-reso-card-overlay .mdg-reso-features {

        display: flex;

        flex-direction: row;

        gap: 12px;

        justify-content: flex-start;

    }

    

    .mdg-reso-card-overlay .mdg-reso-feature {

        display: flex;

        flex-direction: column;

        align-items: center;

        text-align: center;

        gap: 2px;

        white-space: nowrap;

    }

    

    .mdg-reso-card-overlay .mdg-reso-feature strong {

        font-size: 16px;

        order: -1;

    }



}



/* Print Styles */

@media print {

    .mdg-reso-search-form,

    .mdg-reso-pagination,

    .mdg-view-toggle,

    #mdg-listings-map {

        display: none !important;

    }

    

    .mdg-reso-card {

        break-inside: avoid;

        page-break-inside: avoid;

    }

}



/* Single Property Page */

.mdg-reso-single {

    max-width: 1400px;

    margin: 0 auto;

    padding: 20px;

}



.mdg-reso-property-wrapper {


}



/* Gallery Styles */

.mdg-reso-gallery {

    margin-bottom: 30px;

    max-width: 100%;

}



/* Full-Width Gallery */

.mdg-reso-gallery-fullwidth {

    width: 100vw;

    max-width: 100vw;

    margin-left: calc(50% - 50vw);

    margin-right: calc(50% - 50vw);

    margin-top: 0;

    margin-bottom: 20px;

    position: relative;

    padding: 0;

}

/* Split Layout Gallery */
.mdg-reso-gallery-split {
    margin-top: 20px;
    margin-bottom: 20px;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 4px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    height: 500px;
    max-height: 500px;
    min-height: 500px;
    overflow: hidden;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-main {
    position: relative;
    background: #f0f0f0;
    border-radius: 8px 0 0 8px;
    overflow: hidden;
    cursor: pointer;
    height: 100%;
    max-height: 500px;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-main:hover img {
    transform: scale(1.02);
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side {
    display: flex;
    flex-direction: column;
    gap: 4px;
    height: 100%;
    max-height: 500px;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image {
    flex: 1;
    position: relative;
    background: #f0f0f0;
    overflow: hidden;
    cursor: pointer;
    max-height: calc(250px - 2px);
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image:first-child {
    border-radius: 0 8px 0 0;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image:last-child {
    border-radius: 0 0 8px 0;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image:hover img {
    transform: scale(1.05);
}

.mdg-reso-gallery-split .mdg-reso-gallery-view-all-btn {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.95);
    color: #333;
    border: none;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    transition: all 0.2s ease;
    z-index: 10;
}

.mdg-reso-gallery-split .mdg-reso-gallery-view-all-btn:hover {
    background: #fff;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

.mdg-reso-gallery-split .mdg-reso-gallery-view-all-btn svg {
    flex-shrink: 0;
}

.mdg-reso-gallery-split .mdg-reso-gallery-more-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.mdg-reso-gallery-split .mdg-reso-gallery-split-side-image:hover .mdg-reso-gallery-more-overlay {
    background: rgba(0, 0, 0, 0.6);
}

.mdg-reso-gallery-split .mdg-reso-gallery-more-overlay span {
    color: white;
    font-size: 24px;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.mdg-reso-gallery-split .mdg-reso-gallery-counter {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10;
}

/* Mobile responsive for split layout */
@media (max-width: 768px) {
    .mdg-reso-gallery-split .mdg-reso-gallery-split-container {
        grid-template-columns: 1fr;
        height: auto;
        padding: 0;
    }
    
    .mdg-reso-gallery-split .mdg-reso-gallery-split-main {
        height: 300px;
        max-height: 300px;
        border-radius: 0;
    }
    
    .mdg-reso-gallery-split .mdg-reso-gallery-split-side {
        flex-direction: row;
        height: 150px;
        max-height: 150px;
    }
    
    .mdg-reso-gallery-split .mdg-reso-gallery-split-side-image {
        border-radius: 0 !important;
        max-height: 150px;
    }
    
    .mdg-reso-gallery-split .mdg-reso-gallery-split-container {
        max-height: none;
        min-height: auto;
    }
}



.mdg-reso-gallery-fullwidth .mdg-reso-gallery-main {

    border-radius: 0;

    height: 600px;

    max-height: 600px;

}

/* Ensure split layout ignores standard gallery height overrides */
.mdg-reso-gallery-split .mdg-reso-gallery-split-container,
.mdg-reso-gallery-split .mdg-reso-gallery-split-main {
    height: 500px !important;
    max-height: 500px !important;
}

@media (max-width: 768px) {
    .mdg-reso-gallery-split .mdg-reso-gallery-split-container {
        height: auto !important;
        max-height: none !important;
    }
    
    .mdg-reso-gallery-split .mdg-reso-gallery-split-main {
        height: 300px !important;
        max-height: 300px !important;
    }
}



.mdg-reso-gallery-fullwidth .mdg-reso-thumbnails-wrapper {

    max-width: 1400px;

    margin: 0 auto;

    padding: 0 20px;

}



.mdg-reso-gallery-main {

    position: relative;

    width: 100%;

    max-height: 600px;

    background: #f0f0f0;

    margin-bottom: 10px;

    overflow: hidden;

    border-radius: 8px;

}



.mdg-reso-gallery-main img {

    width: 100%;

    height: 100%;

    object-fit: contain;

    display: block;

}



.mdg-reso-gallery-main.no-image {

    height: 400px;

    display: flex;

    align-items: center;

    justify-content: center;

}



.mdg-reso-no-image-placeholder {

    text-align: center;

    color: #999;

}



.mdg-reso-gallery-counter {

    position: absolute;

    bottom: 20px;

    right: 20px;

    background: rgba(0,0,0,0.7);

    color: white;

    padding: 8px 16px;

    border-radius: 4px;

    font-size: 14px;

}



/* Thumbnails wrapper with navigation */

.mdg-reso-thumbnails-wrapper {

    position: relative;

    display: flex;

    align-items: center;

    gap: 10px;

    margin-top: 15px;

}



.mdg-reso-thumb-nav {

    flex: 0 0 40px;

    width: 40px;

    height: 40px;

    background: rgba(255, 255, 255, 0.9);

    border: 1px solid #ddd;

    border-radius: 50%;

    font-size: 24px;

    line-height: 1;

    cursor: pointer;

    transition: all 0.3s ease;

    z-index: 10;

    color: #333;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 0;

    box-shadow: 0 2px 4px rgba(0,0,0,0.1);

}



.mdg-reso-thumb-nav:hover {

    background: #fff;

    border-color: #3498db;

    color: #3498db;

    box-shadow: 0 2px 8px rgba(0,0,0,0.15);

}



.mdg-reso-thumb-nav:active {

    transform: scale(0.95);

}



.mdg-reso-thumb-nav:disabled {

    opacity: 0.3;

    cursor: not-allowed;

    pointer-events: none;

}



.mdg-reso-gallery-thumbnails {

    display: flex;

    gap: 10px;

    overflow-x: auto;

    overflow-y: hidden;

    padding: 10px 0;

    scroll-behavior: smooth;

    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */

    flex: 1;

    /* Hide scrollbar for cleaner look */

    scrollbar-width: thin;

}



/* Custom scrollbar styling - thin and subtle */

.mdg-reso-gallery-thumbnails::-webkit-scrollbar {

    height: 6px;

}



.mdg-reso-gallery-thumbnails::-webkit-scrollbar-track {

    background: transparent;

}



.mdg-reso-gallery-thumbnails::-webkit-scrollbar-thumb {

    background: rgba(0,0,0,0.2);

    border-radius: 3px;

}



.mdg-reso-gallery-thumbnails::-webkit-scrollbar-thumb:hover {

    background: rgba(0,0,0,0.4);

}



/* Hide scrollbar completely on mobile for cleaner look */

@media (max-width: 768px) {

    .mdg-reso-gallery-thumbnails::-webkit-scrollbar {

        display: none;

    }

    .mdg-reso-gallery-thumbnails {

        -ms-overflow-style: none;  /* IE and Edge */

        scrollbar-width: none;  /* Firefox */

    }

}



.mdg-reso-thumbnail {

    position: relative;

    flex: 0 0 120px; /* Fixed width, no grow/shrink */

    height: 90px; /* Fixed height for 4:3 aspect ratio */

    background: #f0f0f0;

    cursor: pointer;

    overflow: hidden;

    border-radius: 4px;

    border: 2px solid transparent;

    transition: all 0.3s ease;

}



.mdg-reso-thumbnail img {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.mdg-reso-thumbnail:hover {

    border-color: #3498db;

    transform: translateY(-2px);

    box-shadow: 0 4px 8px rgba(0,0,0,0.15);

}



.mdg-reso-thumbnail.active {

    border-color: #3498db;

}

/* Split Gallery Header (appears above gallery when split layout enabled) */
.mdg-reso-split-header {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px 15px;
}

.mdg-reso-split-header-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.mdg-reso-split-header-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.mdg-reso-split-header h1 {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    color: #222;
    line-height: 1.2;
}

.mdg-reso-split-header-details {
    display: flex;
    align-items: center;
    gap: 16px;
    color: #666;
    font-size: 15px;
}

.mdg-reso-split-header-location {
    color: #555;
}

.mdg-reso-split-header-mls {
    color: #888;
    font-size: 14px;
}

.mdg-reso-split-header-price {
    font-size: 28px;
    font-weight: 700;
    /* color set dynamically via inline styles from price_color setting */
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-top: 4px;
}

.mdg-reso-split-header-ppsf {
    font-size: 14px;
    font-weight: 400;
    color: #888;
}

/* Share Buttons */
.mdg-reso-split-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    padding-top: 5px;
}

.mdg-reso-share-buttons {
    display: flex;
    gap: 8px;
}

.mdg-reso-share-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: #fff !important;
    border: 1px solid #ddd !important;
    border-radius: 8px !important;
    font-size: 14px;
    font-weight: 500;
    color: #444 !important;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: none !important;
}

.mdg-reso-share-btn:hover {
    background: #f5f5f5 !important;
    border-color: #ccc !important;
    color: #444 !important;
}

.mdg-reso-share-btn:focus,
.mdg-reso-share-btn:active {
    background: #fff !important;
    border-color: #ddd !important;
    color: #444 !important;
    outline: none !important;
    box-shadow: none !important;
}

.mdg-reso-share-btn svg {
    flex-shrink: 0;
}

/* Save Button States */
.mdg-reso-save-btn.saved,
.mdg-reso-save-btn.saved:hover,
.mdg-reso-save-btn.saved:focus,
.mdg-reso-save-btn.saved:active {
    background: #ffe6e6 !important;
    border-color: #e74c3c !important;
    color: #e74c3c !important;
}

.mdg-reso-save-btn.saved svg {
    fill: #e74c3c;
    stroke: #e74c3c;
}

.mdg-reso-save-btn.saved span {
    color: #e74c3c;
}

/* Email Modal Specific Styles */
.mdg-reso-email-modal-content {
    max-width: 450px;
}

@media (max-width: 768px) {
    .mdg-reso-split-header {
        padding: 20px 15px;
    }
    
    .mdg-reso-split-header-content {
        flex-direction: column;
        gap: 16px;
    }
    
    .mdg-reso-split-header h1 {
        font-size: 24px;
    }
    
    .mdg-reso-split-header-details {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .mdg-reso-split-header-price {
        font-size: 22px;
    }
    
    .mdg-reso-share-buttons {
        width: 100%;
    }
    
    .mdg-reso-share-btn {
        flex: 1;
        justify-content: center;
        padding: 10px 12px;
    }
    
    .mdg-reso-share-btn span {
        display: none;
    }
}

/* Property Header */

.mdg-reso-property-header {

    display: flex;

    justify-content: space-between;

    align-items: flex-start;

    gap: 20px;

    margin-bottom: 30px;

    padding: 20px;

    background: #f8f9fa;

    border-radius: 8px;

}



.mdg-reso-property-title h1 {

    margin: 0 0 10px 0;

    color: #2c3e50;

    font-size: 28px;

}



.mdg-reso-property-address {

    font-size: 18px;

    color: #666;

    margin-bottom: 5px;

}



.mdg-reso-property-mls {

    font-size: 14px;

    color: #999;

}



.mdg-reso-property-price-box {

    text-align: right;

}



.mdg-reso-property-price {

    font-size: 36px;

    font-weight: bold;

    color: #27ae60;

}



.mdg-reso-price-per-sqft {

    font-size: 14px;

    color: #666;

    margin-top: 5px;

}



/* Key Features Bar */

.mdg-reso-property-key-features {

    display: flex;

    gap: 20px;

    padding: 20px;

    background: white;

    border: 1px solid #e0e0e0;

    border-radius: 8px;

    margin-bottom: 30px;

    justify-content: space-around;

}



.mdg-reso-key-feature {

    text-align: center;

    flex: 1;

}



.mdg-reso-key-feature-value {

    font-size: 24px;

    font-weight: bold;

    color: #2c3e50;

    display: block;

    margin-bottom: 5px;

}



.mdg-reso-key-feature-label {

    font-size: 14px;

    color: #666;

    display: block;

    order: -1;

    margin-bottom: 8px;

}

.mdg-reso-property-key-features.has-icons .mdg-reso-key-feature {

    display: flex;

    flex-direction: column;

    align-items: center;

    line-height: 1;

}

.mdg-reso-property-key-features.has-icons .mdg-reso-key-feature-label {

    font-size: 12px;

    font-weight: 600;

    text-transform: uppercase;

    letter-spacing: 0.5px;

    color: #888;

}

.mdg-reso-property-key-features.has-icons .mdg-reso-key-feature-value {

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 8px;

    margin-bottom: 0;

}

.mdg-reso-property-key-features.has-icons .mdg-reso-key-feature-value svg {

    width: 24px;

    height: 24px;

    flex-shrink: 0;

}

/* Main Property Layout with Sidebar */
.mdg-reso-property-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    margin-top: 30px;
}

.mdg-reso-property-left {
    min-width: 0;
}

/* Property Header inside layout */
.mdg-reso-property-layout .mdg-reso-property-header {
    margin-bottom: 20px;
}

/* Key Features inside layout */
.mdg-reso-property-layout .mdg-reso-property-key-features {
    margin: 0 0 30px 0;
}

/* Financial & School Split Layout */
.mdg-reso-info-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

.mdg-reso-info-box {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.08);
}

.mdg-reso-info-box h3 {
    margin: 0 0 15px 0;
    font-size: 18px;
    color: #2c3e50;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db; /* fallback, overridden by dynamic styles */
}

.mdg-reso-info-details .mdg-reso-detail-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.mdg-reso-info-details .mdg-reso-detail-row:last-child {
    border-bottom: none;
}

/* Content Grid - now for main content only */

.mdg-reso-property-main {

    min-width: 0;

}



/* Property Sections */

.mdg-reso-property-section {

    background: white;

    padding: 25px;

    margin-bottom: 30px;

    border-radius: 8px;

    box-shadow: 0 2px 4px rgba(0,0,0,0.08);

    margin-top: 30px;

}



.mdg-reso-property-section h2 {

    margin: 0 0 20px 0;

    color: #2c3e50;

    font-size: 24px;

    border-bottom: 2px solid #3498db;

    padding-bottom: 10px;

}



.mdg-reso-property-description {

    color: #333;

    line-height: 1.8;

    font-size: 16px;

}



/* Details Grid */

.mdg-reso-details-grid {

    display: grid;

    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));

    gap: 30px;

}



.mdg-reso-detail-group {

    background: #f8f9fa;

    padding: 20px;

    border-radius: 6px;

}



.mdg-reso-detail-group h3 {

    margin: 0 0 15px 0;

    color: #2c3e50;

    font-size: 18px;

    font-weight: 600;

}



.mdg-reso-detail-row {

    display: flex;

    justify-content: space-between;

    padding: 8px 0;

    border-bottom: 1px solid #e0e0e0;

}



.mdg-reso-detail-row:last-child {

    border-bottom: none;

}



.mdg-reso-detail-label {

    font-weight: 500;

    color: #666;

    font-size: 14px;

}



.mdg-reso-detail-value {

    color: #333;

    font-size: 14px;

    text-align: right;

    font-weight: 500;

}



/* Features Grid */

.mdg-reso-features-grid {

    display: grid;

    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));

    gap: 25px;

}



.mdg-reso-feature-group h3 {

    margin: 0 0 10px 0;

    color: #2c3e50;

    font-size: 16px;

    font-weight: 600;

}



.mdg-reso-feature-list {

    list-style: none;

    padding: 0;

    margin: 0;

}



.mdg-reso-feature-list li {

    padding: 6px 0;

    color: #333;

    font-size: 14px;

    border-bottom: 1px solid #f0f0f0;

}



.mdg-reso-feature-list li:last-child {

    border-bottom: none;

}



.mdg-reso-feature-list li:before {

    content: "✓";

    color: #27ae60;

    margin-right: 8px;

}



/* Sidebar */

.mdg-reso-property-sidebar {

    position: sticky;

    top: 20px;

    height: fit-content;

}



.mdg-reso-sidebar-card {

    background: white;

    padding: 20px;

    margin-bottom: 20px;

    border-radius: 8px;

    box-shadow: 0 2px 4px rgba(0,0,0,0.08);

    border: 1px solid #e0e0e0

}



.mdg-reso-sidebar-card h3 {

    margin: 0 0 15px 0;

    color: #2c3e50;

    font-size: 18px;

    border-bottom: 2px solid #3498db;

    padding-bottom: 10px;

}



.mdg-reso-agent-info {

    padding: 10px 0;

}



.mdg-reso-agent-name {

    font-size: 16px;

    font-weight: 600;

    color: #333;

    margin-bottom: 5px;

}



.mdg-reso-agent-office {

    font-size: 14px;

    color: #666;

    margin-bottom: 5px;

}



.mdg-reso-agent-phone a {

    color: #3498db;

    text-decoration: none;

    font-size: 14px;

}



.mdg-reso-agent-phone a:hover {

    text-decoration: underline;

}


/* Broker Contact Box - inherits sidebar card styling */
.mdg-reso-broker-card {
    /* Inherits from .mdg-reso-sidebar-card: white bg, padding, border-radius, shadow */
}

.mdg-reso-broker-card h3 {
    margin: 0 0 15px 0;
    font-size: 18px;
    padding-bottom: 10px;
}

.mdg-reso-broker-header {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.mdg-reso-broker-photo {
    flex-shrink: 0;
}

.mdg-reso-broker-photo img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #e0e0e0;
}

.mdg-reso-broker-info {
    flex: 1;
}

.mdg-reso-broker-name {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #2c3e50;
}

.mdg-reso-broker-title {
    font-size: 13px;
    color: #7f8c8d;
    margin: 0 0 2px 0;
    font-weight: 500;
}

.mdg-reso-broker-company {
    font-size: 14px;
    color: #333;
    margin: 0;
    font-weight: 600;
}

.mdg-reso-broker-tagline {
    font-size: 14px;
    color: #666;
    margin: 0 0 15px 0;
    font-style: italic;
    line-height: 1.4;
}

.mdg-reso-broker-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mdg-reso-broker-phone-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 15px;
    border-radius: 6px;
    transition: all 0.2s ease;
    /* Uses secondary button colors */
}

.mdg-reso-broker-phone-link svg {
    width: 18px;
    height: 18px;
}

.mdg-reso-broker-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.5px;
    /* Uses primary button colors */
}

.mdg-reso-broker-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Tour Request Section */
.mdg-reso-tour-request {
    margin: 20px 0 0 0;
    padding: 20px 0 0 0;
    background: transparent;
    border: none;
    border-top: 1px solid #e0e0e0;
    border-radius: 0;
}

.mdg-reso-tour-heading {
    font-size: 13px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 16px 0;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 8px;
}


.mdg-reso-tour-type {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
}

.mdg-reso-radio-label {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.mdg-reso-radio-label:hover {
    border-color: #c0c0c0;
    background: #f5f5f5;
}

.mdg-reso-radio-label:has(input:checked) {
    border-color: #2c3e50;
    background: rgba(44,62,80,0.15);
    color: #2c3e50;
}

.mdg-reso-radio-label input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.mdg-reso-radio-label span {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mdg-reso-radio-label span svg {
    opacity: 0.7;
    transition: all 0.25s ease;
}

.mdg-reso-radio-label:has(input:checked) span svg {
    opacity: 1;
}

.mdg-reso-tour-date {
    display: flex;
    flex-direction: column;
}

/* Custom Date Picker */
.mdg-reso-date-picker {
    position: relative;
}

.mdg-reso-date-display {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.mdg-reso-date-display:hover {
    border-color: #c0c0c0;
    background: #fafafa;
}

.mdg-reso-date-display.active {
    border-color: #2c3e50;
    box-shadow: 0 0 0 3px rgba(44,62,80,0.1);
}

.mdg-reso-date-display.has-date {
    border-color: #2c3e50;
    background: rgba(44,62,80,0.1);
}

.mdg-reso-date-display svg:first-child {
    color: #888;
    flex-shrink: 0;
}

.mdg-reso-date-display.has-date svg:first-child {
    color: #2c3e50;
}

.mdg-reso-date-text {
    flex: 1;
    font-size: 15px;
    font-weight: 500;
    color: #999;
}

.mdg-reso-date-display.has-date .mdg-reso-date-text {
    color: #2c3e50;
    font-weight: 600;
}

.mdg-reso-date-arrow {
    color: #888;
    transition: transform 0.2s ease;
}

.mdg-reso-date-display.active .mdg-reso-date-arrow {
    transform: rotate(180deg);
}

/* Calendar Dropdown */
.mdg-reso-calendar {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    z-index: 100;
    padding: 12px;
    overflow: hidden;
}

.mdg-reso-calendar.active {
    display: block;
    animation: calendarSlideIn 0.2s ease;
}

@keyframes calendarSlideIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mdg-reso-calendar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.mdg-reso-calendar-title {
    font-size: 14px;
    font-weight: 700;
    color: #2c3e50;
}

.mdg-reso-calendar-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    background: #f5f5f5;
    border-radius: 6px;
    cursor: pointer;
    color: #666;
    transition: all 0.2s ease;
}

.mdg-reso-calendar-nav:hover {
    background: #e8e8e8;
    color: #333;
}

.mdg-reso-calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    margin-bottom: 4px;
}

.mdg-reso-calendar-weekdays span {
    text-align: center;
    font-size: 10px;
    font-weight: 600;
    color: #999;
    text-transform: uppercase;
    padding: 4px 0;
}

.mdg-reso-calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}

.mdg-reso-calendar-day {
    width: 100%;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    padding: 0;
    margin: 0;
}

.mdg-reso-calendar-day:hover:not(.disabled):not(.selected) {
    background: #f0f0f0;
}

.mdg-reso-calendar-day.today {
    border: 2px solid #2c3e50;
}

.mdg-reso-calendar-day.selected {
    background: #2c3e50;
    color: #fff;
    font-weight: 600;
}

.mdg-reso-calendar-day.disabled {
    color: #ccc;
    cursor: not-allowed;
}

.mdg-reso-calendar-day.other-month {
    color: #bbb;
}

.mdg-reso-broker-license {
    font-size: 11px;
    color: #95a5a6;
    margin-top: 15px;
    text-align: center;
}


/* Default Listing Agent Contact Card (when broker is disabled) */
.mdg-reso-agent-card {
    /* Inherits from .mdg-reso-sidebar-card */
}

.mdg-reso-agent-card h3 {
    margin: 0 0 15px 0;
    font-size: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.mdg-reso-agent-header {
    margin-bottom: 15px;
}

.mdg-reso-agent-info {
    flex: 1;
}

.mdg-reso-agent-name {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 4px 0;
    color: #2c3e50;
}

.mdg-reso-agent-office {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.mdg-reso-agent-phone {
    font-size: 14px;
    color: #555;
    margin-top: 4px;
}

.mdg-reso-agent-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mdg-reso-agent-phone-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 15px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.mdg-reso-agent-phone-link svg {
    width: 18px;
    height: 18px;
}

.mdg-reso-agent-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 0.5px;
    text-decoration: none;
    text-align: center;
}

.mdg-reso-agent-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    text-decoration: none;
}


/* Save & Share Card (Sidebar) */
.mdg-reso-save-share-card {
    /* Inherits from .mdg-reso-sidebar-card */
}

.mdg-reso-save-share-buttons {
    display: flex;
    gap: 10px;
}

.mdg-reso-save-share-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 15px 10px;
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    color: #555;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.mdg-reso-save-share-btn:hover {
    background: #fff;
    border-color: #3498db;
    color: #3498db;
    text-decoration: none;
}

.mdg-reso-save-share-btn svg {
    width: 20px;
    height: 20px;
}

.mdg-reso-save-share-btn.saved {
    background: #fff5f5;
    border-color: #e74c3c;
    color: #e74c3c;
}

.mdg-reso-save-share-btn.saved svg {
    fill: #e74c3c;
}

.mdg-reso-view-saved-link {
    display: block;
    text-align: center;
    margin-top: 12px;
    padding: 10px;
    color: #e74c3c;
    font-size: 14px;
    font-weight: 500;
    border-top: 1px solid #e0e0e0;
    padding-bottom: 0;
    line-height: 1;
    text-decoration: none;
}

.mdg-reso-view-saved-link:hover {
    color: #c0392b;
    text-decoration: underline;
}

.mdg-reso-view-saved-link svg {
    display: none;
}

/* Split header version of View Saved link */
.mdg-reso-split-saved-link {
    margin-top: 10px;
    padding: 0;
    border-top: none;
    font-size: 13px;
}


/* Broker Contact Modal */
.mdg-reso-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.mdg-reso-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.mdg-reso-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
}

.mdg-reso-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.mdg-reso-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 32px;
    height: 32px;
    border: none;
    background: #f1f5f9;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-size: 20px;
    color: #64748b;
    line-height: 1;
}

.mdg-reso-modal-close:hover {
    background: #e2e8f0;
    color: #334155;
}

.mdg-reso-modal-header {
    margin-bottom: 25px;
    padding-right: 40px;
}

.mdg-reso-modal-header h3 {
    margin: 0 0 8px 0;
    font-size: 22px;
    color: #3498db;
    font-weight: 700;
}

.mdg-reso-modal-header p {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.5;
}


/* Broker Contact Form */
.mdg-reso-contact-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.mdg-reso-form-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.mdg-reso-form-row label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
}

.mdg-reso-form-row input,
.mdg-reso-form-row textarea {
    padding: 12px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.2s ease;
    background: #f8fafc;
}

.mdg-reso-form-row input:focus,
.mdg-reso-form-row textarea:focus {
    outline: none;
    border-color: #3b82f6;
    background: white;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

.mdg-reso-form-row textarea {
    min-height: 120px;
    resize: vertical;
}

.mdg-reso-submit-btn {
    padding: 14px 24px;
    /* Colors set dynamically via inline styles from primary button settings */
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 5px;
}

.mdg-reso-submit-btn:hover {
    background: #2980b9;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(52,152,219,0.3);
}

.mdg-reso-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.mdg-reso-form-status {
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    display: none;
}

.mdg-reso-form-status.success {
    display: block;
    background: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.mdg-reso-form-status.error {
    display: block;
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}


/* Listing Agent Footer (Subtle) */
.mdg-reso-listing-agent-footer {
    margin-top: 40px;
    padding: 20px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    color: #64748b;
    font-size: 13px;
}

.mdg-reso-listing-agent-footer h4 {
    margin: 0 0 10px 0;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #94a3b8;
    font-weight: 600;
}

.mdg-reso-listing-agent-footer .agent-name {
    color: #475569;
    font-weight: 500;
}

.mdg-reso-listing-agent-footer .agent-office {
    color: #64748b;
}

.mdg-reso-listing-agent-footer .agent-phone {
    color: #64748b;
    margin-top: 5px;
}

.mdg-reso-listing-agent-footer .agent-phone a {
    color: #64748b;
    text-decoration: none;
}

.mdg-reso-listing-agent-footer .agent-phone a:hover {
    color: #475569;
    text-decoration: underline;
}


/* Property Map */

#mdg-property-map {

    width: 100%;

    height: 400px;

    border-radius: 8px;

    overflow: hidden;

}



/* Responsive Design for Single Property */

@media (max-width: 1024px) {

    .mdg-reso-property-layout {
        grid-template-columns: 1fr;
    }

    .mdg-reso-property-content {

        grid-template-columns: 1fr;

    }

    

    .mdg-reso-property-sidebar {

        position: static;

    }

    

    .mdg-reso-details-grid {

        grid-template-columns: 1fr;

    }
    
    .mdg-reso-info-split {
        grid-template-columns: 1fr;
    }

}



@media (max-width: 768px) {

    .mdg-reso-property-header {

        flex-direction: column;

    }

    

    .mdg-reso-property-price-box {

        text-align: left;

    }

    

    .mdg-reso-property-key-features {

        flex-wrap: wrap;

    }

    

    .mdg-reso-key-feature {

        flex: 1 1 45%;

        margin-bottom: 10px;

    }

    

    .mdg-reso-thumbnail {

        flex: 0 0 100px; /* Smaller thumbnails on mobile */

        height: 75px;

    }

    

    .mdg-reso-thumb-nav {

        width: 35px;

        height: 35px;

        font-size: 20px;

    }

    

    .mdg-reso-features-grid {

        grid-template-columns: 1fr;

    }

}



/* Lightbox Styles */

.mdg-lightbox {

    display: none;

    position: fixed;

    z-index: 99999;

    left: 0;

    top: 0;

    width: 100%;

    height: 100%;

    background-color: rgba(0, 0, 0, 0.95);

    overflow: hidden;

}



.mdg-lightbox-content {

    position: relative;

    width: 100%;

    height: 100%;

    display: flex;

    align-items: center;

    justify-content: center;

}



.mdg-lightbox-image {

    max-width: 90%;

    max-height: 90vh;

    object-fit: contain;

    user-select: none;

    animation: mdgLightboxZoom 0.3s ease;

}



@keyframes mdgLightboxZoom {

    from {

        transform: scale(0.8);

        opacity: 0;

    }

    to {

        transform: scale(1);

        opacity: 1;

    }

}



.mdg-lightbox-close {

    position: absolute;

    top: 20px;

    right: 35px;

    color: #fff;

    font-size: 50px;

    font-weight: 300;

    cursor: pointer;

    transition: all 0.3s ease;

    z-index: 100001;

    line-height: 1;

    width: 50px;

    height: 50px;

    display: flex;

    align-items: center;

    justify-content: center;

    background: rgba(0, 0, 0, 0.5);

    border-radius: 50%;

}



.mdg-lightbox-close:hover {

    background: rgba(255, 255, 255, 0.2);

    transform: rotate(90deg);

}



.mdg-lightbox-prev,

.mdg-lightbox-next {

    position: absolute;

    top: 50%;

    transform: translateY(-50%);

    color: #fff;

    font-size: 60px;

    font-weight: 300;

    cursor: pointer;

    padding: 20px;

    background: rgba(0, 0, 0, 0.5);

    border: none;

    transition: all 0.3s ease;

    z-index: 100001;

    line-height: 1;

    border-radius: 4px;

}



.mdg-lightbox-prev:hover,

.mdg-lightbox-next:hover {

    background: rgba(255, 255, 255, 0.2);

    transform: translateY(-50%) scale(1.1);

}



.mdg-lightbox-prev {

    left: 20px;

}



.mdg-lightbox-next {

    right: 20px;

}



.mdg-lightbox-counter {

    position: absolute;

    bottom: 30px;

    left: 50%;

    transform: translateX(-50%);

    color: #fff;

    font-size: 18px;

    background: rgba(0, 0, 0, 0.7);

    padding: 10px 20px;

    border-radius: 25px;

    z-index: 100001;

}



/* Make gallery images clickable with cursor change */

.mdg-reso-gallery-main img {

    cursor: zoom-in;

}



.mdg-reso-gallery-main img:hover {

    opacity: 0.95;

}



@media (max-width: 480px) {

    .mdg-reso-single {

        padding: 10px;

    }

    

    .mdg-reso-property-section {

        padding: 15px;

    }

    

    .mdg-reso-key-feature {

        flex: 1 1 100%;

    }

    

    .mdg-reso-gallery-main {

        max-height: 300px;

    }

    

    .mdg-lightbox-close {

        top: 10px;

        right: 10px;

        font-size: 40px;

        width: 40px;

        height: 40px;

    }

    

    .mdg-lightbox-prev,

    .mdg-lightbox-next {

        font-size: 40px;

        padding: 15px;

    }

    

    .mdg-lightbox-prev {

        left: 10px;

    }

    

    .mdg-lightbox-next {

        right: 10px;

    }

    

    .mdg-lightbox-image {

        max-width: 95%;

        max-height: 85vh;

    }

    

    .mdg-lightbox-counter {

        bottom: 20px;

        font-size: 16px;

        padding: 8px 16px;

    }

    

    /* Extra small screens - full width filters */

    .mdg-custom-filter {

        flex: 1 1 100%;

        min-width: unset;

        max-width: unset;

    }

    

    .mdg-filter-panel {

        min-width: unset;

        max-width: calc(100vw - 24px);

        padding: 14px;

    }

    

    .number-options {

        grid-template-columns: repeat(3, 1fr);

        gap: 6px;

    }

    

    .number-option {

        padding: 10px 6px;

        font-size: 12px;

    }

    

    .type-option {

        padding: 10px 12px;

        font-size: 12px;

    }

    

    .price-value {

        padding: 8px;

    }

    

    .price-min-display,

    .price-max-display {

        font-size: 12px;

    }

    

    .filter-panel-header {

        font-size: 12px;

    }

}

/* Skeleton Loading Placeholders
--------------------------------------------- */
@keyframes mdg-skeleton-shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.mdg-reso-skeleton-card {
    pointer-events: none;
}

.mdg-reso-skeleton-image {
    position: relative;
    width: 100%;
    padding-bottom: 66.67%; /* Match 3:2 aspect ratio */
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: mdg-skeleton-shimmer 1.5s infinite ease-in-out;
}

.mdg-reso-skeleton-details {
    padding: 15px;
}

.mdg-reso-skeleton-line {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: mdg-skeleton-shimmer 1.5s infinite ease-in-out;
    border-radius: 4px;
}

.mdg-reso-skeleton-price {
    height: 24px;
    width: 45%;
    margin-bottom: 10px;
}

.mdg-reso-skeleton-address {
    height: 18px;
    width: 80%;
    margin-bottom: 15px;
}

.mdg-reso-skeleton-features {
    display: flex;
    gap: 15px;
}

.mdg-reso-skeleton-feature {
    height: 16px;
    width: 60px;
}

/* Stagger animation for visual effect */
.mdg-reso-skeleton-card:nth-child(2) .mdg-reso-skeleton-line,
.mdg-reso-skeleton-card:nth-child(2) .mdg-reso-skeleton-image {
    animation-delay: 0.1s;
}

.mdg-reso-skeleton-card:nth-child(3) .mdg-reso-skeleton-line,
.mdg-reso-skeleton-card:nth-child(3) .mdg-reso-skeleton-image {
    animation-delay: 0.2s;
}

.mdg-reso-skeleton-card:nth-child(4) .mdg-reso-skeleton-line,
.mdg-reso-skeleton-card:nth-child(4) .mdg-reso-skeleton-image {
    animation-delay: 0.3s;
}

.mdg-reso-skeleton-card:nth-child(5) .mdg-reso-skeleton-line,
.mdg-reso-skeleton-card:nth-child(5) .mdg-reso-skeleton-image {
    animation-delay: 0.4s;
}

.mdg-reso-skeleton-card:nth-child(6) .mdg-reso-skeleton-line,
.mdg-reso-skeleton-card:nth-child(6) .mdg-reso-skeleton-image {
    animation-delay: 0.5s;
}