/* =====================
   1. Global Resets & Base Styles
===================== */
:root {
    --primary-color: #0047AB;
    --text-color: #333;
    --border-color: #ddd;
    --light-bg: #f9f9f9;
    --card-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
}

body {
    font-family: Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.5;
}

body.modal-open {
    overflow: hidden;
}

.dogs-for-sale {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

img {
    max-width: 100%;
    height: auto;
}

/* =====================
   2. Header & Navigation
===================== */
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 1000;
    /* Ensure header is above filters */
}

.logo {
    max-width: 180px;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.page-title {
    padding: 2rem 1rem;
    margin: 0;
    text-align: center;
    font-size: 2rem;
    background-position: center;
    background-size: cover;
    color: #fff;
    position: relative;
}

.page-title::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.page-title span {
    position: relative;
    z-index: 2;
}

/* =====================
   3. Filters Bar
===================== */
.filters-bar {
    background: #fff;
    padding: 1rem;
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    justify-content: center;
}

.filters-dropdown {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    max-width: 800px;
    justify-content: center;
}

.filter-btn,
#stateSelectorBtn,
#mapToggleBtn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--primary-color);
    color: #FFF;
    border: none;
    /* border-radius: 2rem; */
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 13px !important;
    white-space: nowrap;
    font-weight: 600 !important;
    height: 39px !important;
}

.filter-btn:hover,
#stateSelectorBtn:hover,
#mapToggleBtn:hover {
    background-color: #002E2C;
}

.state-selector,
.sort-selector {
    position: relative;
}

/* Dropdown styling */
.form-control.select-field {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #fff url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23333' viewBox='0 0 16 16'><path d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/></svg>") no-repeat;
    background-position: calc(100% - 15px) center;
    padding: 8px 36px 8px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    color: #212529;
    width: 100%;
    height: auto;
    cursor: pointer;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control.select-field:focus {
    border-color: #80bdff;
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-control.select-field:hover {
    border-color: #b3b3b3;
}

.form-control.select-field option {
    padding: 10px;
    background-color: #fff;
    color: #212529;
}

.sort-selector {
    position: relative;
    display: inline-block;
    min-width: 180px;
}

/* Price range filter styling */
.filter-section .price-range {
    margin-bottom: 15px;
}

.price-range .form-group {
    margin-bottom: 0;
}

/* =====================
   4. Filter Modal
===================== */
.filter-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    /* Higher than header/menu */
    padding: 0;
}

.filter-modal.show {
    display: flex;
}

.filter-modal-content {
    background: #fff;
    width: 90%;
    max-width: 450px;
    border-radius: 10px;
    padding: 1.25rem;
    position: relative;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    margin: 0 auto;
    left: 0;
    right: 0;
    transform: translateY(0);
}

.filter-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
}

.filter-modal-body {
    flex: 1;
    overflow-y: auto;
}

.filter-section {
    margin-bottom: 1.25rem;
}

.filter-section h4 {
    /* font-size: 1rem; */
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.filter-categories .category-item {
    margin-bottom: 0.75rem;
}

/* Category toggles / subcategory lists */
.category-title {
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.category-title .arrow {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
    font-size: 0.8em;
}

.category-title.open .arrow {
    transform: rotate(180deg);
}

.subcategory-list {
    list-style: none;
    padding-left: 1rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.subcategory-list.show {
    max-height: 300px;
}

.subcategory-list li {
    margin-bottom: 0.25rem;
    /* font-size: 0.875rem; */
}

.no-results {
    font-size: 0.875rem;
    color: #999;
}

/* Modal container */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    /* Higher than filters and other elements */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 20px;
    border-radius: 6px;
    width: 90%;
    max-width: 600px;
    position: relative;
}

.close {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 40px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
}

.close:hover {
    color: #000;
}

.modal-title {
    text-align: center;
    margin-bottom: 1rem;
}

/* Filter Bar 2 Layout */
.filter-bar-2 {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
}

.price-inputs {
    display: flex;
    gap: 1rem;
}

.filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

.filter-actions .btn {
    font-size: 13px;
}

/* Button Styling */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

.reset-btn {
    background-color: #f0f0f0;
    color: #333;
    border: 1px solid #ccc;
}

.apply-btn {
    background-color: #d0a32d;
    color: #fff;
    border: 1px solid #d0a32d;
    position: relative;
    z-index: 9999;
}

.reset-btn:hover {
    background-color: #e2e2e2;
}

.apply-btn:hover {
    background-color: #b68f25;
}

/* Filter modal bottom actions */
.filter-actions {
    display: flex;
    margin-top: 1rem;
    gap: 1rem;
}

.filter-bar-2 {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.reset-btn {
    background: #ccc;
    color: #333;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
}

.apply-btn {
    background: var(--primary-color);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    border: none;
    cursor: pointer;
    font-size: 0.875rem;
}

.reset-btn:hover,
.apply-btn:hover {
    /* opacity: 0.9; */
    color: #FFF;
}

/* STATE MODAL */
.state-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.state-modal.show {
    display: flex;
}

.state-modal-content {
    background: #fff;
    width: 450px;
    max-width: 90%;
    max-height: 80vh;
    border-radius: 12px;
    padding: 20px;
    overflow-y: auto;
    position: relative;
    margin: 0 auto;
    left: 0;
    right: 0;
    transform: translateY(0);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.state-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.close-state-modal {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

.country-header {
    font-weight: bold;
    margin-top: 12px;
}

.state-item {
    list-style: none;
    padding: 6px 0;
}

.state-option {
    text-decoration: none;
    color: #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.state-option.selected {
    font-weight: bold;
    color: #C9A137;
}

.price-inputs {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.price-input {
    display: flex;
    flex-direction: column;
}

.price-input input[type="number"] {
    width: 100px;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s;
}

.price-input input[type="number"]:focus {
    border-color: #007bff;
    outline: none;
}

/* =====================
   6. Main Layout - Map & Listings
===================== */
/* Since only one view is shown at a time, we use a simple block layout */
.content-wrapper {
    margin-top: 1.25rem;
}

/* MAP SECTION */
.map-col {
    overflow: hidden;
    width: 100%;
    position: relative;
    top: 0;
    height: 80vh;
    margin-bottom: 1rem;
    z-index: 50;
}

#map {
    width: 100%;
    height: 100%;
    border-radius: 1.25rem;
}

/* Map Toggle Button Styles */
.map-toggle-btn {
    background-color: var(--primary-color);
    border: none;
    border-radius: 2rem;
    color: #fff;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.3s ease;
}

.map-loading-overlay {
    position: fixed;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 150px;
    background: rgba(255, 255, 255, 0.8);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transform: translate(-50%, -50%);
    border: 1px solid #ccc;
    border-radius: 8px;
    text-align: center;
}

.map-loading-overlay .spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #ccc;
    border-top: 4px solid #2f8f3d;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
    /* Space between spinner and text */
}

/* Optional: styling for the text */
.map-loading-overlay .loading-text {
    font-size: 14px;
    color: #333;
}


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

    100% {
        transform: rotate(360deg);
    }
}

.map-loading-overlay.hidden {
    display: none;
}



/* Elements hidden via the 'hidden' class */
#mapCol.hidden {
    display: none;
}

.adverts-col.hidden {
    display: none;
}

.two-col-grid.map-hidden {
    grid-template-columns: 1fr;
}

/* Custom Popup Styles (Centered on Page) */
.custom-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 11000;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.3);
    width: 300px;
    transition: opacity 0.3s ease;
}

.custom-popup.boosted {
    background-color: #C9A137 !important;
}

.custom-popup.hidden {
    opacity: 0;
    pointer-events: none;
}

.custom-popup.visible {
    opacity: 1;
    pointer-events: auto;
}

.custom-popup-content {
    position: relative;
    padding: 10px;
}

.custom-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    cursor: pointer;
    font-size: 40px;
    z-index: 9997;
    background-color: red;
    color: #CCC;
    border-radius: 5px;
    padding: 4px;
}

.custom-popup-close:hover {
    background-color: darkred;
    color: #FFF;
}

/* Popup Card Styles */
.popup-card {
    display: block;
    width: 100%;
    max-width: 280px;
    background: #fff;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    overflow: hidden;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.15);
}

.popup-card .listing-image {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
}

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

.popup-card .dog-sold {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 50px;
    z-index: 2;
}

.popup-card .badge-boosted {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #C9A137;
    padding: 2px 6px;
    font-size: 12px;
    color: #fff;
    border-radius: 4px;
    z-index: 2;
}

.popup-card .badge-verified {
    position: absolute;
    top: 35px;
    left: 10px;
    background: #0B5B34;
    padding: 2px 6px;
    font-size: 12px;
    color: #fff;
    border-radius: 4px;
    z-index: 2;
}

.popup-card .listing-content {
    padding: 0.75rem 1rem;
}

.popup-card h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    font-weight: bold;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.popup-card .listing-price {
    font-size: 1rem;
    font-weight: bold;
    color: #28a745;
    margin-bottom: 0.5rem;
}

.popup-card .listing-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.875rem;
    color: #666;
}

.leaflet-marker-icon {
    font-family: 'Roboto', sans-serif !important;
}

.marker-cluster-small {
    background: linear-gradient(135deg, #2f8f3d 0%, #C9A137 100%);
    color: #fff;
    font-family: 'Roboto', sans-serif !important;
}

.marker-cluster-medium {
    background: linear-gradient(135deg, #2f8f3d 0%, #C9A137 100%);
    color: #fff;
    font-family: 'Roboto', sans-serif !important;
}



/* Base styles for the popup */
.leaflet-popup {
    z-index: 1000;
}

/* Remove the popup tip/arrow since we're customizing position */
.leaflet-popup-tip-container {
    display: none !important;
}

/* Style the popup content container */
.leaflet-popup-content-wrapper {
    border-radius: 8px !important;
    box-shadow: 0 3px 20px rgba(0, 0, 0, 0.3) !important;
    padding: 0 !important;
}

/* Popup positioning for markers in bottom half - moves popup above marker */
.popup-position-top {
    margin-top: -10px !important;
    transform: translateY(-100%) !important;
}

/* Popup positioning for markers in top half - moves popup below marker */
.popup-position-bottom {
    margin-top: 10px !important;
}

/* Style the close button */
.leaflet-popup-close-button {
    top: 5px !important;
    right: 5px !important;
    padding: 4px !important;
    width: 22px !important;
    height: 22px !important;
    background-color: white !important;
    border-radius: 50% !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
    text-align: center;
    line-height: 14px;
    z-index: 1001;
}

/* Smooth animation */
.leaflet-fade-anim .leaflet-popup {
    animation: popupFadeIn 0.2s ease;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.custom-popup-content {
    display: flex;
    justify-content: center;
}

.popup-card {
    display: block;
    width: 100%;
    max-width: 280px;
    background: #FFF;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    overflow: hidden;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.15);
}

.popup-card .listing-image {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
}

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

.popup-card .dog-sold {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 50px;
    height: auto;
    z-index: 2;
}

.popup-card .badge-boosted {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #C9A137;
    padding: 2px 6px;
    font-size: 12px;
    color: #fff;
    border-radius: 4px;
    z-index: 2;
}

.popup-card .badge-verified {
    position: absolute;
    top: 35px;
    left: 10px;
    background: #0B5B34;
    padding: 2px 6px;
    font-size: 12px;
    color: #fff;
    border-radius: 4px;
    z-index: 2;
}

/* Content area */
.popup-card .listing-content {
    padding: 0.75rem 1rem;
}

/* Title, Price, etc. */
.popup-card h3 {
    margin: 0 0 6px;
    font-size: 1rem;
    font-weight: bold;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.popup-card .listing-price {
    font-size: 1rem;
    font-weight: bold;
    color: #28a745;
    margin-bottom: 0.5rem;
}

.popup-card .listing-meta {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    font-size: 0.875rem;
    color: #666;
}

/* ADVERTS SECTION */
.adverts-col {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* Results Count */
.results-count {
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: var(--text-color);
}

/* Listings Grid */
.listings-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(3, auto);
    gap: 1.25rem;
}


/* Listing Card */
.listing-card {
    display: block;
    background: #fff;
    border: none;
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.listing-card:hover {
    /* box-shadow: 0 10px 20px rgba(0, 0, 0, 0.432); */
    transform: translateY(-3px);
}

/* Listing Image */
.listing-image {
    position: relative;
    width: 100%;
    padding-top: 75%;
    overflow: hidden;
}

.listing-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Sold Badge & Advert Badges */
.dog-sold {
    position: absolute;
    top: 0px;
    left: 0px;
    right: 0;
    margin: 0px auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: rgb(0 0 0 / 70%);
    font-size: 30px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 10px;
}

.dog-sold img {
    object-fit: contain;
}

.badges {
    top: 0.625rem;
    left: 0.625rem;
    color: #fff;
    font-size: 0.75rem;
    display: flex;
    flex-direction: row;
    align-items: start;
    gap: 0.25rem;
    align-items: center;
}

.badge-boosted {
    background-color: #C9A137;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.badge-verified {
    background-color: #0B5B34;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
}

.listing-content {
    padding: 0.75rem;
}

.listing-content h2 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.listing-price {
    font-weight: bold;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.listing-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.625rem;
    font-size: 0.75rem;
    color: #777;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.meta-item i {
    color: #666;
    font-size: 0.875rem;
}

/* =====================
   7. Sponsored Section
===================== */
.sponsored-footer {
    max-width: 85%;
    height: 330px;
    padding-top: 20px !important;
    padding-bottom: 20px !important;
}

.sponsored-footer .card {
    display: block;
    background: #fff;
    border: none;
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18);
    width: 290px;
    height: 290px;
}

.sponsored-footer .card img {
    width: 290px;
    height: 290px;
}

.sponsored-footer .swiper {
    padding: 20px 0;
}

.sponsored-footer .swiper-slide {
    display: flex;
    justify-content: center;
}

.sponsored-footer .swiper-button-next,
.sponsored-footer .swiper-button-prev {
    color: #C41E3A;
}

.sponsored-footer .swiper-button-next:after,
.sponsored-footer .swiper-button-prev:after {
    font-weight: 900;
}

.sponsored-footer .card:hover {
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.432);
    transform: translateY(-3px);
}

/* =====================
   8. Pagination
===================== */
.pagination-container {
    margin: 1.5rem 0;
    display: flex;
    justify-content: center;
}

.pagination {
    display: inline-flex;
    gap: 0.25rem;
}

.page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-color);
    color: #fff;
    border-radius: 0.25rem;
    padding: 0.375rem 0.625rem;
    min-width: 2rem;
    text-decoration: none;
    font-size: 0.875rem;
}

.page-btn:hover:not(.disabled) {
    opacity: 0.9;
}

.page-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.page-btn.active {
    background: #C41E3A;
}

.page-dots {
    align-self: center;
    color: #999;
    padding: 0 0.25rem;
}

/* =====================
   9. Responsive Breakpoints
===================== */
/* Large devices (desktops, < 1200px) */
@media (max-width: 1199.98px) {
    .sponsored-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Medium devices (tablets, < 992px) */
@media (max-width: 991.98px) {
    .map-col {
        height: 100vh;
        max-height: 600px;
        position: relative;
    }

    .sponsored-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Small devices (landscape phones, < 768px) */
@media (max-width: 767.98px) {
    .filters-dropdown {
        justify-content: center;
    }

    .page-title {
        font-size: 1.75rem;
        padding: 1.5rem 1rem;
    }

    .listings-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    .filter-modal-content,
    .state-dropdown-list {
        max-width: 100%;
    }

    .sponsored-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .filters-bar {
        z-index: 100;
    }

    .map-col {
        margin-top: 15px;
        height: calc(100vh - 60px);
        max-height: 500px;
        position: relative !important;
        z-index: 50;
    }

    #map {
        height: 100% !important;
    }

    /* Mobile menu styles */
    .mobile-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: #165636;
        z-index: 1500;
        /* Higher than filters but lower than modals */
        overflow-y: auto;
    }

    .mobile-menu-content {
        padding: 1rem;
    }
}

/* Extra small devices (portrait phones, < 576px) */
@media (max-width: 575.98px) {
    html {
        font-size: 14px;
    }

    .dogs-for-sale {
        padding: 0 0.5rem;
    }

    .listings-grid {
        grid-template-columns: 1fr;
    }

    .map-col {
        height: 80vh;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .page-title {
        font-size: 1.5rem;
        padding: 1rem;
    }

    .filter-modal-content {
        padding: 1rem;
    }

    .pagination .page-btn:not(.active):not(:first-child):not(:last-child) {
        display: none;
    }
}

@media only screen and (max-width: 375px) {

    .filter-btn,
    #stateSelectorBtn,
    #mapToggleBtn {
        font-size: 11px !important;
        height: 30px !important;
    }
}

/* =====================
   Custom Marker
===================== */
.custom-marker .marker-content {
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    width: 50px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* =====================
   Typography Overrides for Custom Fonts
===================== */
.custom-marker,
.listing-content {
    font-family: 'Montserrat', sans-serif;
}

input#stateSearchInput {
    max-height: 30px;
}
