/*
==============================================================================
 DRAFT STANDARD — SEARCH SHARED CSS
 File: src/main/resources/static/css/search.css
 Revision Date: 2026-05-04

 PURPOSE
 - Shared CSS for IDX search pages.
 - Supports Phase 1 search landing page.
 - Supports Phase 2 search results page.
 - Supports Phase 3 property-detail page.
 - Uses ivory site background: #F3F0DF.

 2026-04-26 CLEANUP
 - Removed duplicate / competing Phase 3 gallery and print rules.
 - Keeps one clean hero + masonry gallery system.
 - Keeps one clean sticky contact box system.
 - Keeps one clean browser print / save-as-PDF brochure system.

 2026-05-04 CTA POLISH
 - Preserves the existing property-primary-button class.
 - Makes anchor links using property-primary-button render like real CTA buttons.
 - Fixes the Request Tour link on property-detail.html so it no longer appears as
   small red underlined browser text.
==============================================================================
*/

.results-shell-page {
    max-width: 1440px;
    margin: 0 auto;
}

.phase-one-page-shell,
.phase-one-editorial-list,
.phase-one-narrative-shell-clean,
.phase-one-smart-links {
    background-color: #F3F0DF;
}

/*
==============================================================================
 PHASE 1 HERO
==============================================================================
*/

.phase-one-hero-clean {
    position: relative;
    min-height: 520px;
    background-color: #F3F0DF;
    background-image:
            linear-gradient(rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.30)),
            url('/images/vibergman-1.png');
    background-size: 100% auto;
    background-position: center top;
    background-repeat: no-repeat;
    display: flex;
    align-items: flex-start;
}

.phase-one-hero-clean-inner {
    width: 100%;
    padding: 2.25rem 0 3.75rem;
    text-align: center;
}

.phase-one-hero-brand-line {
    color: #000000;
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    margin-bottom: 1.25rem;
    text-shadow: none;
}

.phase-one-hero-tabs {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 1.35rem;
}

.phase-one-tab {
    border: 1px solid rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.10);
    color: #000000;
    padding: 0.68rem 1.15rem;
    border-radius: 999px;
    font-size: 0.94rem;
    font-weight: 700;
    backdrop-filter: blur(8px);
    box-shadow: none;
    transition: all 0.18s ease;
}

.phase-one-tab:hover {
    background: rgba(255, 255, 255, 0.24);
    color: #000000;
    border-color: rgba(255, 255, 255, 0.85);
    transform: translateY(-1px);
}

.phase-one-tab-active {
    background: rgba(255, 255, 255, 0.28);
    color: #000000;
    border-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.14);
    transform: translateY(-1px);
}

.phase-one-hero-search {
    max-width: 980px;
    margin: 0 auto 4rem;
}

.phase-one-hero-search-shell {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 999px;
    padding: 0.4rem;
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
}

.phase-one-hero-search-input {
    flex: 1 1 auto;
    min-height: 64px;
    border: none;
    background: transparent;
    padding: 0 1.35rem;
    font-size: 1.05rem;
    outline: none;
    color: #222222;
}

.phase-one-hero-search-button {
    border: none;
    background: #c81f25;
    color: #ffffff;
    min-height: 56px;
    min-width: 150px;
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 700;
    padding: 0 1.3rem;
    transition: background 0.18s ease;
}

.phase-one-hero-search-button:hover {
    background: #af1b20;
}

.phase-one-hero-copy-block {
    max-width: 980px;
    margin: 8rem auto 0;
    text-align: left;
    color: #ffffff;
}

.phase-one-hero-heading {
    font-size: clamp(2.25rem, 4vw, 4rem);
    line-height: 1.04;
    font-weight: 600;
    margin-top: 0;
    margin-bottom: 1rem;
    text-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
}

.phase-one-hero-subcopy {
    max-width: 700px;
    font-size: 1.06rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.96);
    text-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}

/*
==============================================================================
 PHASE 1 SHARED TYPOGRAPHY + EDITORIAL SPLIT ROWS
==============================================================================
*/

.phase-one-section-title {
    font-size: clamp(2rem, 4vw, 3.25rem);
    line-height: 1.05;
    margin-bottom: 2rem;
    color: #1f2328;
    font-weight: 500;
}

.phase-one-section-copy {
    color: #666666;
    max-width: 860px;
    line-height: 1.75;
    margin-bottom: 1.4rem;
}

.phase-one-editorial-list {
    padding-top: 3.25rem;
    padding-bottom: 1.75rem;
}

.phase-one-split-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    gap: 0;
    margin-bottom: 0;
}

.phase-one-split-row-reverse {
    grid-template-columns: 1fr 1fr;
}

.phase-one-split-row-reverse .phase-one-split-image {
    order: 2;
}

.phase-one-split-row-reverse .phase-one-split-copy {
    order: 1;
}

.phase-one-split-image {
    display: block;
    min-height: 390px;
    height: 100%;
    width: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    text-decoration: none;
    border-radius: 0;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

.phase-one-split-image:hover {
    opacity: 0.94;
    transform: translateY(-1px);
}

.phase-one-split-copy {
    min-height: 390px;
    padding: 3rem 4rem;
    color: #000000;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.phase-one-eyebrow {
    color: #6D6928;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.85rem;
}

.phase-one-split-copy h3 {
    color: #000000;
    font-size: clamp(2rem, 3vw, 3.25rem);
    line-height: 1.05;
    font-weight: 800;
    margin-bottom: 1rem;
}

.phase-one-split-copy p {
    color: #000000;
    font-size: 1.05rem;
    line-height: 1.75;
    max-width: 620px;
    margin-bottom: 1.35rem;
}

.phase-one-split-link {
    color: #000000;
    font-weight: 800;
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 0, 0, 0.42);
    padding-bottom: 0.12rem;
    transition: opacity 0.18s ease, border-color 0.18s ease;
}

.phase-one-split-link:hover {
    color: #000000;
    opacity: 0.72;
    border-color: rgba(0, 0, 0, 0.72);
}

/*
==============================================================================
 PHASE 1 IMAGE UTILITY CLASSES
==============================================================================
*/

.phase-one-image-living {
    background-image: url('/images/vibergman-1.png');
}

.phase-one-image-ivy {
    background-image: url('/images/images-idx-starter/2MV.png');
}

.phase-one-image-stone {
    background-image: url('/images/images-idx-starter/3MV.png');
}

.phase-one-image-shoreline {
    background-image: url('/images/images-idx-starter/4MV.png');
}

.phase-one-image-new-listings {
    background-image: url('/images/vibergman-1.png');
}

.phase-one-image-price-decreases {
    background-image: url('/images/images-idx-starter/2MV.png');
}

.phase-one-image-open-houses {
    background-image: url('/images/images-idx-starter/3MV.png');
}

.phase-one-narrative-shell-clean {
    padding: 2.75rem 0 3rem;
    background-color: #F3F0DF;
}

.phase-one-narrative-shell-clean p {
    max-width: 980px;
    line-height: 1.85;
    color: #555555;
}

/*
==============================================================================
 PHASE 2 SEARCH RESULTS
==============================================================================
*/

.results-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    margin: 1.5rem 0 2rem;
    padding: 1rem;
    border: 1px solid #e8e8e8;
    border-radius: 16px;
    background: #fafafa;
}

.results-filter-pill {
    padding: 0.8rem 1rem;
    border: 1px solid #dcdcdc;
    border-radius: 12px;
    background: #ffffff;
    min-width: 150px;
    font-size: 0.95rem;
    color: #333333;
}

.results-filter-pill strong {
    display: block;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #777777;
    margin-bottom: 0.25rem;
}

.results-town-dropdown-menu {
    min-width: 340px;
    max-height: 380px;
    overflow-y: auto;
}

.results-town-dropdown-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.results-town-checklist {
    display: grid;
    gap: 0.1rem;
}

.results-drawer-town-list {
    max-height: 220px;
    overflow-y: auto;
    border: 1px solid #e3e3e3;
    border-radius: 10px;
    padding: 0.75rem;
    margin-bottom: 0.75rem;
}

.results-shell-body {
    display: grid;
    grid-template-columns: minmax(0, 1.85fr) minmax(320px, 0.55fr);
    gap: 1.5rem;
    align-items: start;
}

.results-left,
.results-right {
    min-width: 0;
}

.results-right {
    position: sticky;
    top: 1rem;
}

.results-meta-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.results-meta-bar p {
    margin: 0;
    color: #666666;
}

.results-sort {
    padding: 0.7rem 0.95rem;
    border: 1px solid #dcdcdc;
    border-radius: 10px;
    background: #ffffff;
    color: #333333;
    font-size: 0.92rem;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.result-card {
    background: #ffffff;
    border: 1px solid #e6e6e6;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.result-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.07);
}

.result-card-media {
    position: relative;
}

.result-card img {
    width: 100%;
    height: 230px;
    object-fit: cover;
    display: block;
}

.result-card-badges {
    position: absolute;
    top: 14px;
    left: 18px;
    right: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    z-index: 2;
}

.result-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.38rem 0.72rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: #ffffff;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}

.result-badge-new {
    background: #c62828;
}

.result-badge-open-house {
    background: #1f2328;
}

.result-badge-price-reduced {
    background: #8b1e3f;
}

.result-badge-coming-soon {
    background: #405d72;
}

.result-badge-waterfront {
    background: #0f5c7a;
}

.result-card-body {
    padding: 1rem;
}

/*
==============================================================================
 IDX 9 TWEAK — SPACING BETWEEN PRICE / FACTS / ADDRESS

 PURPOSE
 - Adds subtle breathing room between rows
 - Keeps clean, high-end card feel

 HOW TO ADJUST
 - More space: increase margin values
 - Less space: decrease margin values
==============================================================================
*/

.result-card-price {
    font-size: 1.35rem;
    font-weight: 700;

    /* was 0.35rem — increased for better spacing */
    margin-bottom: 0.8rem;
}

.result-card-address {
    font-weight: 600;

    /* adds slight separation from facts row */
    margin-top: 0.1rem;

    /* was 0.35rem — increased for breathing room */
    margin-bottom: 1rem;
}

.result-card-meta {
    color: #666666;
    font-size: 0.94rem;
    margin-bottom: 0.4rem;
}

.result-card-copy {
    color: #666666;
    font-size: 0.92rem;
    line-height: 1.6;
    margin-bottom: 0;
}

/*
==============================================================================
 PHASE 2 MAP / PAGINATION / BOTTOM LINKS
==============================================================================
*/

.map-shell {
    border: 1px solid #e3e3e3;
    border-radius: 18px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.map-shell-header {
    padding: 1rem 1rem 0.75rem;
    border-bottom: 1px solid #ededed;
}

.map-shell-header h2 {
    margin: 0 0 0.3rem;
    font-size: 1.1rem;
}

.map-shell-header p {
    margin: 0;
    color: #666666;
    font-size: 0.92rem;
}

.map-shell-box {
    position: relative;
    min-height: 680px;
    background:
            linear-gradient(rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.08)),
            url('/images/images-idx-starter/idx-map-placeholder.jpg') center center / cover no-repeat;
}

.map-pin {
    position: absolute;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #c62828;
    border: 2px solid #ffffff;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.22);
}

.map-pin-1 { top: 18%; left: 28%; }
.map-pin-2 { top: 30%; left: 46%; }
.map-pin-3 { top: 44%; left: 61%; }
.map-pin-4 { top: 56%; left: 38%; }
.map-pin-5 { top: 68%; left: 72%; }
.map-pin-6 { top: 76%; left: 49%; }

.results-pagination-shell {
    margin-top: 1.5rem;
    padding-top: 0.25rem;
}

.results-pagination-count {
    color: #666666;
    font-size: 0.95rem;
}

.results-pagination-shell .pagination {
    gap: 0.3rem;
}

.results-pagination-shell .page-item .page-link {
    border-radius: 10px;
    border: 1px solid #dddddd;
    color: #333333;
    background: #ffffff;
    padding: 0.6rem 0.85rem;
    font-size: 0.92rem;
    box-shadow: none;
}

.results-pagination-shell .page-item .page-link:hover {
    background: #f8f8f8;
    color: #111111;
}

.results-pagination-shell .page-item.active .page-link {
    background: #1f2328;
    border-color: #1f2328;
    color: #ffffff;
}

.results-pagination-shell .page-item.disabled .page-link {
    color: #9aa0a6;
    background: #f5f5f5;
    border-color: #e1e1e1;
}

.results-bottom-links {
    margin-top: 2.25rem;
    padding: 1.25rem;
    border: 1px solid #e9e1d7;
    border-radius: 18px;
    background: #faf8f4;
}

.results-bottom-links h2 {
    margin-bottom: 0.8rem;
}

.results-bottom-links ul {
    margin-bottom: 0;
}

.results-bottom-links li {
    margin-bottom: 0.45rem;
}

.results-inline-action-link {
    color: #0d6efd;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.results-inline-action-link:hover {
    color: #0a58ca;
}

/*
==============================================================================
 PHASE 3 PROPERTY DETAIL — GALLERY
==============================================================================
*/

.property-detail-page {
    background: #F3F0DF;
    color: #000000;
}

.property-detail-gallery-shell {
    background: #F3F0DF;
    padding: 2rem 2rem 3rem;
}

.property-hero-gallery {
    position: relative;
    max-width: 1280px;
    margin: 0 auto 1rem;
    background: #000000;
    overflow: hidden;
}

.property-hero-image {
    width: 100%;
    height: min(68vh, 720px);
    object-fit: contain;
    object-position: center center;
    display: block;
    border-radius: 0;
}

.property-hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
    width: 56px;
    height: 76px;
    border: none;
    background: rgba(0, 0, 0, 0.42);
    color: #ffffff;
    font-size: 3.5rem;
    line-height: 1;
    cursor: pointer;
}

.property-hero-arrow-left {
    left: 0;
}

.property-hero-arrow-right {
    right: 0;
}

.property-hero-arrow:hover {
    background: rgba(0, 0, 0, 0.68);
}


/*
==============================================================================
 PROPERTY DETAIL HERO — DOWNLOAD BROCHURE BUTTON

 POSITIONING
 - left: 50% keeps the button centered horizontally.
 - bottom controls vertical placement inside the hero.
   Increase bottom to move the button UP.
   Decrease bottom to move the button DOWN.
   Example:
     bottom: 4rem;  = higher / more centered over hero
     bottom: 2rem;  = lower / closer to bottom edge

 SIZE / SPACING
 - padding controls button size.
   First value = top/bottom.
   Second value = left/right.
   Example:
     padding: 1rem 1.6rem; = larger button
     padding: 0.7rem 1rem; = smaller button

 COLOR / OPACITY
 - rgba(121, 156, 175, 0.42) uses #799caf at 42% opacity.
 - Increase opacity for stronger color:
     rgba(121, 156, 175, 0.62)
 - Decrease opacity for lighter color:
     rgba(121, 156, 175, 0.28)

 TEXT
 - color controls text color.
 - font-weight controls boldness.
==============================================================================
*/

/*
Position:
- top: 50% = exact vertical center of hero
- top: 58% = slightly below center
- top: 62% = lower
- top: 45% = higher

Do not use bottom for centered hero placement.
*/

.property-detail-gallery-button {
    display: block;
    width: fit-content;
    margin: 1.5rem auto 1rem;
    border: none;
    background: rgba(121, 156, 175, 0.42);
    color: #000000;
    padding: 0.85rem 1.35rem;
    font-weight: 900;
    cursor: pointer;
    letter-spacing: 0.01em;
    text-decoration: none;
    white-space: nowrap;
}

.property-detail-gallery-button:hover,
.property-detail-gallery-button:focus {
    background: rgba(121, 156, 175, 0.62);
    color: #000000;
    text-decoration: none;
}

.property-masonry-grid {
    max-width: 1280px;
    margin: 0 auto;
    column-count: 3;
    column-gap: 10px;
}

.property-masonry-item {
    display: block;
    width: 100%;
    margin: 0 0 10px;
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    break-inside: avoid;
    border: none;
    border-radius: 0;
    background: transparent;
}

.property-masonry-item img {
    width: 100%;
    display: block;
    border-radius: 0;
    transition: transform 0.35s ease;
}

.property-masonry-item:hover img {
    transform: scale(1.035);
}

.property-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.94);
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.property-lightbox img {
    max-width: 88%;
    max-height: 86%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0;
}

.property-lightbox-close {
    position: absolute;
    top: 24px;
    right: 32px;
    border: none;
    background: transparent;
    color: #ffffff;
    font-size: 2rem;
    cursor: pointer;
    z-index: 10001;
}

.property-lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
    width: 76px;
    height: 96px;
    font-size: 4.5rem;
    line-height: 1;
    cursor: pointer;
    z-index: 10001;
}

.property-lightbox-arrow-left {
    left: 32px;
}

.property-lightbox-arrow-right {
    right: 32px;
}

.property-lightbox-arrow:hover {
    background: rgba(255, 255, 255, 0.36);
}

/*
==============================================================================
 PHASE 3 PROPERTY DETAIL — PAGE STRUCTURE
==============================================================================
*/

.property-detail-main-shell {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 3vw, 2rem) 4rem;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
    gap: clamp(1.25rem, 3vw, 2.5rem);
    align-items: start;
}

.property-detail-content-column {
    min-width: 0;
}

.property-detail-eyebrow {
    color: #6D6928;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 0.85rem;
}

.property-header-block,
.property-map-block,
.property-open-house-block,
.property-overview-block,
.property-mls-snapshot,
.property-details,
.property-features,
.property-similar,
.property-seo-links {
    padding: 2rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.14);
}

.property-header-block h1 {
    font-size: clamp(2.5rem, 5vw, 5rem);
    line-height: 0.95;
    font-weight: 900;
    margin-bottom: 0.6rem;
}

.property-detail-address {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.property-quick-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.property-quick-facts span {
    border: 1px solid rgba(0, 0, 0, 0.18);
    padding: 0.55rem 0.85rem;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.35);
}

.property-map-placeholder {
    min-height: 320px;
    background: rgba(255, 255, 255, 0.38);
    border: 1px solid rgba(0, 0, 0, 0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.property-open-house-card {
    border: 1px solid rgba(0, 0, 0, 0.14);
    background: rgba(255, 255, 255, 0.34);
    padding: 1.25rem;
}

.property-open-house-card p {
    margin: 0.5rem 0 0;
    line-height: 1.65;
}

.property-overview-block p,
.property-details p {
    max-width: 820px;
    line-height: 1.8;
    color: #333333;
}

.property-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid rgba(0, 0, 0, 0.14);
    border-left: 1px solid rgba(0, 0, 0, 0.14);
}

.property-grid div {
    padding: 1rem;
    min-height: 82px;
    border-right: 1px solid rgba(0, 0, 0, 0.14);
    border-bottom: 1px solid rgba(0, 0, 0, 0.14);
    background: rgba(255, 255, 255, 0.25);
    font-weight: 650;
}

.property-grid span {
    display: block;
    color: #666666;
    font-size: 0.82rem;
    margin-bottom: 0.35rem;
}

.property-grid strong {
    color: #000000;
    font-size: 1rem;
}

/*
==============================================================================
 IDX 31 PROPERTY DETAIL — FLEXIBLE MLS DETAIL SECTION SPACING

 PURPOSE
 - Adds breathing room for dynamic ListingDetailSectionView groups.
 - These sections render future public SmartMLS/RETS fields such as Interior,
   Exterior / Lot, Utilities, Waterfront, Financial, and MLS / Listing Info.

 HOW TO ADJUST
 - More space between section groups:
     increase gap on .property-detail-section-grid.
 - Less space between section groups:
     decrease gap on .property-detail-section-grid.
 - More space above the first section:
     increase margin-top on .property-detail-section-grid.
 - More space before each section heading:
     increase padding-top on .property-detail-section.
 - More space under headings:
     increase margin-bottom on .property-detail-section h3.
 - Larger/smaller headings:
     change font-size on .property-detail-section h3.
==============================================================================
*/


.property-detail-section-grid {
    display: grid;
    gap: 1.5rem;
    margin-top: 1.75rem;
}

.property-detail-section {
    padding-top: 1.25rem;
}

.property-detail-section h3 {
    margin-bottom: 0.9rem;
    font-size: 1.15rem;
    font-weight: 900;
}

.property-features ul {
    padding-left: 1.2rem;
    line-height: 1.9;
}

.property-card-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.property-card {
    min-height: 180px;
    background: rgba(255, 255, 255, 0.38);
    border: 1px solid rgba(0, 0, 0, 0.14);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 0.35rem;
    padding: 1rem;
    font-weight: 800;
}

.property-card span {
    color: #6D6928;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.property-seo-links a {
    color: #000000;
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.property-attribution {
    padding: 1.25rem 0 0.75rem;
}

.property-attribution p {
    font-size: 0.72rem;
    line-height: 1.55;
    color: #000000;
    font-weight: 500;
    opacity: 0.92;
    margin: 0;
}

.property-lower-contact-section {
    margin: 2rem 0;
    padding: 2rem;
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(280px, 0.75fr);
    gap: 1.5rem;
    background: rgba(255, 255, 255, 0.36);
    border: 1px solid rgba(0, 0, 0, 0.16);
}

.property-lower-contact-copy p {
    line-height: 1.75;
}

.property-lower-contact-form {
    display: grid;
    gap: 0.7rem;
}

.property-lower-contact-form input,
.property-lower-contact-form textarea {
    width: 100%;
    border: 1px solid rgba(0, 0, 0, 0.28);
    background: #ffffff;
    padding: 0.75rem;
}

.property-lower-contact-form button {
    border: none;
    background: #000000;
    color: #ffffff;
    min-height: 48px;
    font-weight: 900;
    cursor: pointer;
}

/*
==============================================================================
 PHASE 3 PROPERTY DETAIL — STICKY CONTACT BOX
==============================================================================
*/

.property-detail-sticky-column,
.property-side-column {
    position: sticky;
    top: 1.5rem;
    align-self: flex-start;
    padding-top: 2rem;
}

.property-contact-box {
    background: rgba(255, 255, 255, 0.62);
    border: 1px solid rgba(0, 0, 0, 0.18);
    padding: 1.5rem;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.08);
}

.property-contact-box h3 {
    font-size: 1.45rem;
    font-weight: 900;
    margin-bottom: 0.5rem;
}

.property-contact-box h4 {
    font-size: 1rem;
    font-weight: 900;
    margin: 1rem 0 0.75rem;
}

.property-contact-box p {
    color: #444444;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.property-contact-box input {
    width: 100%;
    min-height: 44px;
    border: 1px solid rgba(0, 0, 0, 0.35);
    background: #ffffff;
    padding: 0.65rem 0.75rem;
    margin-bottom: 0.65rem;
}

/*
==============================================================================
 PROPERTY DETAIL — PRIMARY / SECONDARY CTA BUTTONS

 PURPOSE
 - Styles both real <button> elements and <a> links that use these classes.
 - This is important because property-detail.html now uses an anchor link for
   Request Tour so it can route safely to /schedule-showing with listingIds.
 - Without display:flex and text-decoration:none, browser default link styling
   can make the CTA appear as small red underlined text.

 HOW TO TWEAK
 - Button height: change min-height.
 - Primary red: change background on .property-primary-button.
 - Text size: change font-size.
 - Rounded corners: add border-radius if desired.
==============================================================================
*/

.property-primary-button,
.property-secondary-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 46px;
    border: none;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.property-primary-button {
    background: #c81f25;
    color: #ffffff;
}

.property-primary-button:hover,
.property-primary-button:focus {
    background: #a30f16;
    color: #ffffff;
    text-decoration: none;
}

.property-secondary-button {
    background: #000000;
    color: #ffffff;
}

.property-secondary-button:hover,
.property-secondary-button:focus {
    background: #222222;
    color: #ffffff;
    text-decoration: none;
}

.property-contact-box hr {
    border: none;
    border-top: 1px solid rgba(0, 0, 0, 0.18);
    margin: 1.25rem 0;
}

/*
==============================================================================
 PHASE 3 PROPERTY DETAIL — PRINT / SAVE PDF BROCHURE
==============================================================================
*/

@media print {
    body {
        background: #ffffff !important;
        color: #000000 !important;
    }

    header,
    footer,
    nav,
    .property-hero-arrow,
    .property-lightbox,
    .property-contact-box,
    .property-detail-gallery-button {
        display: none !important;
    }

    .property-detail-page,
    .property-detail-gallery-shell {
        background: #ffffff !important;
    }

    .property-detail-gallery-shell {
        padding: 0 0 1rem !important;
    }

    .property-hero-gallery {
        max-width: 100% !important;
        margin: 0 0 1rem !important;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .property-hero-image {
        width: 100% !important;
        height: auto !important;
        max-height: 5.5in !important;
        object-fit: contain !important;
        display: block !important;
    }

    .property-masonry-grid {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0.1in !important;
        column-count: auto !important;
        max-width: 100% !important;
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .property-masonry-item {
        break-inside: avoid;
        page-break-inside: avoid;
        margin: 0 !important;
    }

    .property-masonry-item img {
        width: 100% !important;
        height: 1.6in !important;
        object-fit: cover !important;
        display: block !important;
    }

    .property-header-block,
    .property-map-block,
    .property-open-house-block,
    .property-overview-block,
    .property-mls-snapshot,
    .property-details,
    .property-features,
    .property-similar,
    .property-seo-links,
    .property-attribution {
        page-break-inside: avoid;
        break-inside: avoid;
    }

    .property-side-column {
        position: static !important;
    }

    a {
        color: #000000 !important;
        text-decoration: none !important;
    }
}

/*
==============================================================================
 RESPONSIVE
==============================================================================
*/

@media (max-width: 980px) {
    .results-shell-body,
    .property-detail-main-shell {
        grid-template-columns: 1fr;
    }

    .results-right,
    .property-detail-sticky-column,
    .property-side-column {
        position: static;
        padding-top: 0;
    }

    .property-contact-box {
        max-width: 720px;
        margin: 0 auto 2rem;
    }

    .map-shell-box {
        min-height: 460px;
    }

    .phase-one-split-row,
    .phase-one-split-row-reverse {
        grid-template-columns: 1fr;
    }

    .phase-one-split-row-reverse .phase-one-split-image,
    .phase-one-split-row-reverse .phase-one-split-copy {
        order: initial;
    }

    .phase-one-split-copy {
        padding: 1.5rem 0 0;
    }

    .property-lower-contact-section {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .property-masonry-grid {
        column-count: 2;
    }

    .property-hero-image {
        height: 52vh;
    }

    .property-card-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .results-grid {
        grid-template-columns: 1fr;
    }

    .results-meta-bar {
        flex-direction: column;
        align-items: flex-start;
    }

    .results-filter-pill {
        width: 100%;
    }

    .results-pagination-shell .pagination {
        flex-wrap: wrap;
    }

    .results-town-dropdown-menu {
        min-width: 100%;
    }

    .phase-one-hero-clean {
        min-height: 420px;
        background-size: cover;
        background-position: center center;
    }

    .phase-one-hero-clean-inner {
        padding: 2.25rem 0 4rem;
    }

    .phase-one-hero-search {
        margin-bottom: 3.25rem;
    }

    .phase-one-hero-search-shell {
        flex-direction: column;
        align-items: stretch;
        border-radius: 24px;
        padding: 0.55rem;
    }

    .phase-one-hero-search-input {
        min-height: 58px;
        width: 100%;
    }

    .phase-one-hero-search-button {
        width: 100%;
        min-width: 0;
    }

    .phase-one-hero-copy-block {
        text-align: left;
        margin: 5rem auto 0;
    }

    .phase-one-editorial-list {
        padding-top: 2.25rem;
    }

    .phase-one-split-row {
        margin-bottom: 2.5rem;
    }

    .phase-one-split-image {
        min-height: 260px;
    }

    .phase-one-split-copy h3 {
        font-size: 2rem;
    }
}

@media (max-width: 640px) {
    .property-grid {
        grid-template-columns: 1fr;
    }

    .property-quick-facts {
        flex-direction: column;
    }
}

@media (max-width: 600px) {
    .property-detail-gallery-shell {
        padding: 1rem;
    }

    .property-masonry-grid {
        column-count: 1;
    }

    .property-hero-image {
        height: 42vh;
    }

    .property-lightbox-arrow {
        width: 52px;
        height: 72px;
        font-size: 3rem;
    }
}

.property-search-modify-block {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
    margin-top: 1.25rem;
    padding: 1rem;
    border: 1px solid rgba(20, 20, 20, 0.12);
    background: rgba(243, 240, 223, 0.72);
}

.property-search-modify-label {
    display: block;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.property-search-modify-copy p {
    margin: 0.35rem 0 0;
}

.property-search-modify-button {
    white-space: nowrap;
    text-decoration: none;
    padding: 0.75rem 1rem;
    border: 1px solid currentColor;
    color: inherit;
}

.property-search-modify-button:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .property-search-modify-block {
        align-items: flex-start;
        flex-direction: column;
    }

    .property-search-modify-button {
        width: 100%;
        text-align: center;
    }
}

.result-card-minimal-line {
    font-size: 0.9rem;
    line-height: 1.35;
    color: rgba(0, 0, 0, 0.72);
    margin-top: 0.25rem;
    margin-bottom: 0.4rem;
}

.result-card-learn-more {
    display: inline-block;
    font-size: 0.78rem;
    line-height: 1.2;
    color: rgba(0, 0, 0, 0.78);
    text-decoration: underline;
    text-underline-offset: 0.18em;
}

.result-card-price {
    font-size: 1.45rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 0.7rem;
    color: rgba(0, 0, 0, 0.92);
}

/*
==============================================================================
 IDX 9 EDIT — BED / BATH / SQUARE FOOT FACT ROW

 CURRENT DESIGN
 - Facts row stretches across the card.
 - First fact aligns left.
 - Last fact aligns right.
 - This gives a cleaner left-to-right span like polished listing cards.

 HOW TO CHANGE BACK TO CENTERED
 - Change justify-content: space-between;
 - To:     justify-content: center;

 HOW TO CHANGE TO LEFT-ALIGNED
 - Change justify-content: space-between;
 - To:     justify-content: flex-start;
 - Then add: gap: 1.25rem;
==============================================================================
*/

/*
==============================================================================
 IDX 9 TWEAK — BED / BATH / SQUARE FOOT FACT ROW

 CURRENT FORMAT
 - Displays facts as:
     3 BED        2.5 BATH        2,536 SF
 - Uses Inter for a crisp, modern listing-card feel.
 - Spans left-to-right across the full card width.

 HOW TO ADJUST FONT
 - Font family:
     change font-family: "Inter", Arial, sans-serif;
 - Font size:
     change font-size: 0.9rem;
 - Font weight / stroke:
     change font-weight: 750;
     lower = lighter, higher = bolder

 HOW TO ADJUST SPACING
 - Space above facts row:
     change margin-top: 0.55rem;
 - Space below facts row:
     change margin-bottom: 1.1rem;
 - Space between left / center / right facts:
     keep justify-content: space-between;

 HOW TO CHANGE ALIGNMENT
 - Center all facts:
     change justify-content: center;
     add gap: 1.25rem;
 - Left-align all facts:
     change justify-content: flex-start;
     add gap: 1.25rem;

 HOW TO ADJUST COLOR
 - Text color:
     change color: rgba(0, 0, 0, 0.78);
==============================================================================
*/

.result-card-facts-row {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    width: 100%;
    text-align: center;

    font-family: "Inter", Arial, sans-serif;

    font-size: 0.9rem;
    font-weight: 750;
    line-height: 1.2;

    margin-top: 0.55rem;
    margin-bottom: 1.1rem;

    color: rgba(0, 0, 0, 0.78);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.result-card-facts-row {
    display: flex;
    flex-wrap: nowrap;
    justify-content: space-between;
    width: 100%;
    text-align: center;

    font-family: "Inter", Arial, sans-serif; /* TEST FONT */

    font-size: 0.9rem;
    font-weight: 750;
    line-height: 1.2;

    margin-top: 0.55rem;
    margin-bottom: 1.1rem;

    color: rgba(0, 0, 0, 0.78);
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.result-card-fact {
    white-space: nowrap;
}

.result-card-address {
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.35;
    margin-bottom: 0.95rem;
    color: rgba(0, 0, 0, 0.72);
}

.result-card-features {
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.35;
    margin-top: 0.25rem;
    margin-bottom: 0.75rem;
    color: rgba(0, 0, 0, 0.68);
}

/*
==============================================================================
 IDX 9 EDIT — PREFERRED SEARCH RESULT CARD POLISH

 HOW TO ADJUST
 - Card corner sharpness: change border-radius values.
 - Address size: change --result-card-address-font-size.
 - Card image height: change --result-card-image-height.
 - Teaser card width behavior: adjust .results-category-teasers .col-md-6.
==============================================================================
*/

:root {
    --result-card-image-height: 235px;
    --result-card-address-font-size: 1rem;
}

.result-card {
    border-radius: 0;
    overflow: hidden;
}

.result-card-media {
    border-radius: 0;
}

.result-card-media img {
    width: 100%;
    height: var(--result-card-image-height);
    object-fit: cover;
    border-radius: 0;
}

.result-card-address {
    font-size: var(--result-card-address-font-size);
    font-weight: 550;
    line-height: 1.38;
    margin-top: 0.85rem;
    margin-bottom: 1rem;
    color: rgba(0, 0, 0, 0.78);
}

/*
==============================================================================
 IDX 9 EDIT — FEATURE LINE BELOW ADDRESS

 HOW TO ADJUST
 - Color: change #6D6928.
 - Italic: remove font-style: italic if you want plainer text.
 - Separator line: adjust border-top.
==============================================================================
*/

.result-card-features {
    margin-top: 0.65rem;
    padding-top: 0.55rem;
    border-top: 1px solid rgba(109, 105, 40, 0.28);
    font-size: 0.9rem;
    font-weight: 600;
    font-style: italic;
    line-height: 1.35;
    color: #6D6928;
}

/*
==============================================================================
 IDX 17 EDIT — EXPLORE MORE HOMES TEASER CARD SYSTEM

 PURPOSE
 - Restyles the existing Explore More Homes cards without changing template
   routes, Java data, compare behavior, map behavior, or IDX wiring.
 - Keeps the existing Bootstrap card markup working.
 - Makes the teaser cards feel closer to the modern result-card language above.
 - Avoids narrow cramped 4-across cards inside the left results column.
 - Uses one teaser card per row because this section sits beside the sticky map
   inside the left results column.

 HOW TO TWEAK
 - Number of cards per row on desktop:
     change .results-category-teasers .col-md-3 flex/max-width values.
 - Image height:
     change height on .results-category-teasers .card-img-top.
 - Card background:
     change background on .results-category-teasers .card.
 - Card spacing:
     change padding on .results-category-teasers .card-body.
==============================================================================
*/

.results-category-teasers {
    padding: 1.5rem 0 0.25rem;
}

.results-category-teasers .row {
    --bs-gutter-x: 1rem;
    --bs-gutter-y: 1rem;
}

.results-category-teasers .col-md-3 {
    flex: 0 0 100%;
    max-width: 100%;
}

.results-category-teasers a {
    display: block;
    height: 100%;
    color: #111111;
}

.results-category-teasers .card {
    display: grid;
    grid-template-columns: minmax(180px, 42%) minmax(0, 1fr);
    height: 100%;
    min-height: 210px;
    border: 1px solid rgba(20, 20, 20, 0.12);
    border-radius: 0;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.84);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.055);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.results-category-teasers .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.085);
}

.results-category-teasers .card-img-top {
    width: 100%;
    height: 100%;
    min-height: 210px;
    object-fit: cover;
    border-radius: 0;
}

.results-category-teasers .card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1rem, 2vw, 1.35rem);
}

.results-category-teasers h3 {
    margin-bottom: 0.65rem;
    color: #111111;
    font-size: clamp(1.05rem, 1.5vw, 1.35rem);
    font-weight: 900;
    line-height: 1.08;
    letter-spacing: -0.015em;
    word-break: normal;
}

.results-category-teasers p {
    color: rgba(0, 0, 0, 0.68);
    font-size: 0.92rem;
    font-weight: 500;
    line-height: 1.55;
}

@media (max-width: 1180px) {
    .results-category-teasers .col-md-3 {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

@media (max-width: 768px) {
    .results-category-teasers .card {
        grid-template-columns: 1fr;
    }

    .results-category-teasers .card-img-top {
        height: 220px;
        min-height: 220px;
    }
}

/*
========================================================
 COMPARE PAGE — BACK LINK + HERO SPACING
 PURPOSE:
 - Forces the back link onto its own line.
 - Adds clear breathing room between:
   "Back to Search Results" and "Compare Selected Properties".
 - Replaces default browser blue link styling with brand-friendly styling.

 TWEAK NOTES:
 - To move "Compare Selected Properties" lower:
   increase margin-bottom on .idx-compare-back-link.
 - To make the link darker/lighter:
   change color on .idx-compare-back-link.
 - To change hover color:
   change color on .idx-compare-back-link:hover.
 - To increase/decrease link font size:
   adjust font-size.
========================================================
*/

.idx-compare-back-link {
    display: block;
    margin-bottom: 3.25rem;
    color: var(--brand-green, #6f7335);
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-decoration: none;
}

.idx-compare-back-link:hover {
    color: var(--heading-gold, #8a7a3c);
    text-decoration: underline;
}

.idx-compare-hero .idx-kicker {
    margin-top: 0;
}

/*
========================================================
 COMPARE PAGE — SIDE-BY-SIDE GRID
 PURPOSE:
 - Turns compare rows into a true side-by-side comparison grid.
 - Keeps categories readable on the left.
 - Supports a sticky top property header and sticky left category column.
 - Supports selected-column highlighting through data attributes + JS.

 TWEAK NOTES:
 - Property column width:
   change repeat(3, minmax(220px, 1fr)).
 - Category column width:
   change minmax(190px, 230px).
 - Overall minimum table width:
   change min-width on .idx-compare-table.
 - Cell spacing:
   adjust padding on .idx-compare-cell.
========================================================
*/

.idx-compare-shell {
    width: 100%;
    overflow-x: auto;
    background: #F3F0DF;
}

.idx-compare-table {
    min-width: 980px;
    border: 1px solid rgba(20, 20, 20, 0.12);
    background: #F3F0DF;
}

.idx-compare-row {
    display: grid;
    grid-template-columns: minmax(190px, 230px) repeat(3, minmax(220px, 1fr));
}

.idx-compare-cell {
    padding: 1rem;
    border-bottom: 1px solid rgba(20, 20, 20, 0.1);
    border-right: 1px solid rgba(20, 20, 20, 0.08);
    background: #F3F0DF;
}

/*
 ATTRIBUTION TEXT — SMARTMLS / IDX COMPARE DISCLOSURE

 PURPOSE
 - Styles the small attribution line at the bottom of each compare column.
 - Keeps required attribution visible but quiet.
 - This should feel like a disclosure note, not a main compare-row value.

 HOW TO ADJUST
 - Smaller text: decrease font-size.
 - Larger text: increase font-size.
 - Lighter stroke: decrease font-weight.
 - Heavier stroke: increase font-weight.
 - Lighter color: lower the last rgba number.
 - Darker color: raise the last rgba number.
 - More vertical breathing room: increase line-height.

 CURRENT SETTINGS
 - font-size: 0.68rem;
 - font-weight: 400;
 - color opacity: 0.46;
*/

.idx-compare-attribution-text {
    display: block;
    font-size: 0.68rem;
    font-weight: 400;
    line-height: 1.35;
    color: rgba(0, 0, 0, 0.46);
}
/*
 STICKY LEFT CATEGORY COLUMN
 - Keeps row labels visible when horizontally scrolling.
 - Increase z-index if the left column ever appears behind selected cells.
*/

.idx-compare-label-cell {
    position: sticky;
    left: 0;
    z-index: 4;
    font-weight: 700;
    background: #f7f4e8;
}

/*
 STICKY TOP PROPERTY HEADER
 - Keeps property image/address/select row visible when scrolling down.
 - If it overlaps your global site header, increase top value.
*/

.idx-compare-top-row .idx-compare-cell {
    position: sticky;
    top: 0;
    z-index: 5;
    background: #f3f0df;
}

/*
 TOP-LEFT STICKY CELL
 - Needs highest z-index because it is sticky both vertically and horizontally.
*/

.idx-compare-top-row .idx-compare-label-cell {
    z-index: 8;
}

/*
 SECTION BARS
 - These are the black bars separating row groups such as Pricing / Taxes.
 - To change black bar color, change background below.
*/

.idx-compare-section-heading {
    padding: 0.9rem 1rem;
    background: #222222;
    color: #f3f0df;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/*
========================================================
 COMPARE PAGE — SMART COMPARE ACTION SYSTEM
 PURPOSE:
 - Uses one clean action bar instead of multiple buttons in every column.
 - User selects listings first, then chooses Schedule / Save / Share / Remove / PDF.
 - Buttons are enabled/disabled by compare.html JavaScript.

 TWEAK NOTES:
 - Action bar background:
   change background on .idx-compare-action-bar.
 - Button background:
   change background on .idx-compare-action-buttons button.
 - Button text color:
   change color on .idx-compare-action-buttons button.
 - Button spacing:
   change gap on .idx-compare-action-buttons.
========================================================
*/

.idx-compare-action-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin: 1.5rem 0;
    padding: 0.9rem 1rem;
    background: rgba(121, 156, 175, 0.18);
    border: 1px solid rgba(20, 20, 20, 0.12);
}

.idx-compare-action-copy {
    display: grid;
    gap: 0.25rem;
}

.idx-compare-action-summary {
    font-weight: 700;
    font-size: 0.9rem;
}

.idx-compare-limit-note {
    display: none;
    font-size: 0.8rem;
    color: #c1141c;
    font-weight: 700;
}

.idx-compare-action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.idx-compare-action-buttons button {
    border: 1px solid rgba(20, 20, 20, 0.2);
    background: #f3f0df;
    color: #222222;
    padding: 0.45rem 0.7rem;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

.idx-compare-action-buttons button:hover:not(:disabled) {
    background: #ffffff;
}

.idx-compare-action-buttons button:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/*
========================================================
 COMPARE PAGE — PROPERTY HEADER CARDS
 PURPOSE:
 - Keeps each property header calm and readable.
 - Uses image, full address, and a select control.
 - Avoids cluttered per-column action buttons.

 TWEAK NOTES:
 - Property image height:
   change height on .idx-compare-card-image img.
 - Address background:
   change background on .idx-compare-card-address.
 - Address size:
   change font-size on .idx-compare-card-address.
 - Select row spacing:
   change padding on .idx-compare-select-control.
========================================================
*/

.idx-compare-property-cell {
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

.idx-compare-card-image img {
    width: 100%;
    height: 105px;
    object-fit: cover;
    display: block;
}

.idx-compare-card-address {
    padding: 0.7rem;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.25;
    background: #f3f0df;
    border-bottom: 1px solid rgba(20, 20, 20, 0.08);
}

.idx-compare-select-control {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.65rem 0.7rem;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    background: #F3F0DF;
}

.idx-compare-select-control input {
    width: 1rem;
    height: 1rem;
}

/*
========================================================
 COMPARE — SELECTED COLUMN COLOR CONTROLS

 WHERE THIS GOES:
 - Keep this block in search.css near the compare page CSS.
 - Place it ABOVE:
   .idx-compare-cell.is-selected-column

 HOW TO CHANGE COLOR:
 - Edit --compare-selected-bg for the fill color.
 - Edit --compare-selected-border for the outline color.

 HOW OPACITY WORKS:
 - Last rgba number controls strength.
 - 0.10 = very light
 - 0.18 = soft
 - 0.25 = medium
 - 0.39 = stronger
 - 0.50+ = bold/darker

 CURRENT GREEN / SAGE OPTION:
 - Hex: #A3A656
 - RGB: 163, 166, 86
========================================================
*/

:root {
    --compare-selected-bg: rgba(163, 166, 86, 0.18);
    --compare-selected-border: rgba(163, 166, 86, 0.55);
}

/*
 FULL SELECTED COLUMN HIGHLIGHT
 IMPORTANT:
 - This expects compare.html to add .is-selected-column through JavaScript.
 - Header cells and row cells must have matching data-compare-column values.
 - The !important is intentional because normal cells have their own background.
*/

.idx-compare-cell.is-selected-column {
    background: var(--compare-selected-bg) !important;
}

.idx-compare-property-cell.is-selected-column {
    outline: 2px solid var(--compare-selected-border);
    outline-offset: -2px;
}

.idx-compare-property-cell.is-selected-column .idx-compare-card-address,
.idx-compare-property-cell.is-selected-column .idx-compare-select-control {
    background: transparent !important;
}

/*
 OPTIONAL SELECTED TEXT POLISH
 - Makes selected property label feel slightly more intentional.
*/

.idx-compare-property-cell.is-selected-column .idx-compare-select-control span {
    font-weight: 850;
}

/*
========================================================
 COMPARE PAGE — MOBILE / SMALL SCREEN REFINEMENTS
 PURPOSE:
 - Keeps compare actions readable on smaller screens.
 - Horizontal compare scrolling remains enabled by .idx-compare-shell.
========================================================
*/

@media (max-width: 768px) {
    .idx-compare-action-bar {
        align-items: flex-start;
        flex-direction: column;
    }

    .idx-compare-action-buttons {
        width: 100%;
    }

    .idx-compare-action-buttons button {
        flex: 1 1 auto;
    }
}

/*
==============================================================================
 IDX FORM SYSTEM — MODERN CLEAN UI (INTER FONT)

 PURPOSE
 - Styles schedule-showing.html and future IDX forms.
 - Keeps form styling centralized in search.css instead of inline template CSS.
 - Provides a clean, high-end, minimal IDX aesthetic.
 - Reusable for showing requests, contact forms, and account forms later.

 FONT
 - Current form font uses Inter.
 - To test another font later, change font-family in .idx-contact-form.
 - Examples:
     font-family: "EB Garamond", Georgia, serif;
     font-family: "Helvetica Neue", Arial, sans-serif;

 COLOR TWEAK NOTES
 - Page background: change background on .idx-form-page.
 - Card background: change background on .idx-contact-form.
 - Input background: change background on .idx-contact-form input / textarea.
 - Button color: change background on .idx-primary-action.
 - Focus color: change border-color and box-shadow on focus rules.
==============================================================================
*/

.idx-form-page {
    max-width: 880px;
    margin: 0 auto;
    padding: 2.5rem 1.5rem 4rem;
    background: #F3F0DF;
}

.idx-form-page h1 {
    font-size: clamp(2rem, 3vw, 2.75rem);
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1f2328;
}

.idx-form-page p {
    max-width: 720px;
    color: #555555;
    line-height: 1.75;
}

/*
==============================================================================
 FORM CONTAINER

 HOW TO TWEAK
 - Wider/narrower form: change max-width on .idx-form-page above.
 - More/less inner space: change padding.
 - Rounder/sharper corners: change border-radius.
 - Stronger/lighter shadow: change box-shadow.
==============================================================================
*/

.idx-contact-form {
    margin-top: 2rem;
    padding: 2rem;
    background: #ffffff;
    border: 1px solid rgba(20, 20, 20, 0.12);
    border-radius: 14px;
    font-family: "Inter", Arial, sans-serif;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.06);
}

/*
==============================================================================
 FORM GRID

 HOW TO TWEAK
 - Two columns are controlled by grid-template-columns.
 - More/less space between fields: change gap.
==============================================================================
*/

.idx-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/*
==============================================================================
 LABELS + INPUTS

 HOW TO TWEAK LABELS
 - Softer labels: lower font-weight.
 - More formal labels: add text-transform: uppercase.
 - More spacing between label text and input: change input margin-top.

 HOW TO TWEAK INPUTS
 - Taller fields: increase vertical padding, first value in padding.
 - Wider text inset: increase horizontal padding, second value in padding.
 - Lighter/darker input background: change background.
==============================================================================
*/

.idx-contact-form label {
    display: flex;
    flex-direction: column;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.025em;
    text-transform: none;
    color: #555555;
}

.idx-contact-form input,
.idx-contact-form textarea {
    margin-top: 0.4rem;
    padding: 0.65rem 0.7rem;
    border: 1px solid rgba(0, 0, 0, 0.22);
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 500;
    background: #fafafa;
    color: #222222;
    transition: all 0.15s ease;
}

/*
 FOCUS STATE
 - This is what users see when they click into a field.
 - Change #6D6928 to adjust the focus border color.
*/

.idx-contact-form input:focus,
.idx-contact-form textarea:focus {
    outline: none;
    border-color: #6D6928;
    box-shadow: 0 0 0 2px rgba(109, 105, 40, 0.18);
    background: #ffffff;
}

.idx-contact-form textarea {
    width: 100%;
    resize: vertical;
}

/*
==============================================================================
 FIELDSET — YES / NO BROKER QUESTION

 HOW TO TWEAK
 - Box background: change background.
 - Border strength: change rgba alpha in border.
 - Disclosure text: edit broker-disclosure-note below.
==============================================================================
*/

.idx-form-fieldset {
    border: 1px solid rgba(0, 0, 0, 0.18);
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 10px;
    background: rgba(243, 240, 223, 0.45);
}

.idx-form-fieldset legend {
    font-weight: 800;
    font-size: 0.9rem;
}

.idx-form-fieldset label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-right: 1rem;
    font-size: 0.9rem;
    text-transform: none;
}

.broker-disclosure-note {
    margin-top: 0.6rem;
    font-size: 0.75rem;
    line-height: 1.5;
    color: #6a6a6a;
}

/*
==============================================================================
 PRIMARY ACTION BUTTON

 HOW TO TWEAK
 - Button color: change background.
 - Hover color: change .idx-primary-action:hover background.
 - Button height: change min-height.
 - Roundness: change border-radius.
==============================================================================
*/

.idx-primary-action {
    margin-top: 1.5rem;
    width: 100%;
    min-height: 52px;
    border: none;
    border-radius: 999px;
    background: #c1141c;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.18s ease;
}

.idx-primary-action:hover {
    background: #a30f16;
    transform: translateY(-1px);
}

.idx-primary-action:active {
    transform: scale(0.98);
}

/*
==============================================================================
 RESPONSIVE FORM RULES
==============================================================================
*/

@media (max-width: 768px) {
    .idx-form-grid {
        grid-template-columns: 1fr;
    }

    .idx-contact-form {
        padding: 1.5rem;
    }
}

/*
==============================================================================
 IDX 17 SAFE MODERN RESULT CARD OVERRIDE
 Revision Date: 2026-05-13

 PURPOSE
 - Reintroduces only the successful modern/search-result-card styling from the
   prior experiment without deleting existing CSS or affecting map, teaser,
   pagination, compare page, brochure, email, controller, or Java behavior.
 - Keeps search.css as the single shared stylesheet loaded from layout.html.
 - Keeps current Thymeleaf / ListingCardView / compare workflow architecture.

 IMPORTANT SAFETY NOTE
 - This block is intentionally append-only.
 - It overrides the earlier Phase 2 result-card rules without removing them.
 - If this visual direction needs to be rolled back, remove only this block.

 HOW TO TWEAK
 - Image width on desktop: change 42% in .result-card grid-template-columns.
 - Image height on desktop: change min-height on .result-card-media.
 - Card body space: change padding on .result-card-body.
 - Price size: change font-size on .result-card-price.
==============================================================================
*/

.idx-search-compare-entry {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin: 0 0 1rem;
    padding: 0.9rem 1rem;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(20, 20, 20, 0.12);
}

.idx-search-compare-copy {
    display: grid;
    gap: 0.2rem;
    font-size: 0.9rem;
}

#searchCompareLimitNote {
    color: #c1141c;
    font-weight: 700;
    font-size: 0.82rem;
}

.results-grid {
    grid-template-columns: 1fr;
    gap: 1.1rem;
}

.result-card-shell {
    display: grid;
    gap: 0.45rem;
}

.result-card {
    display: grid;
    grid-template-columns: 1fr;
    border-radius: 0;
    border: 1px solid rgba(20, 20, 20, 0.12);
    background: rgba(255, 255, 255, 0.84);
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.result-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.09);
}

.result-card-media {
    min-height: 310px;
}

.result-card-media img,
.result-card img {
    width: 100%;
    height: 100%;
    min-height: 310px;
    object-fit: cover;
    display: block;
    border-radius: 0;
}

.result-card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1rem, 2vw, 1.45rem);
}

.result-card-body > .d-flex:first-child {
    align-items: center;
    justify-content: space-between !important;
    margin-bottom: 1rem !important;
}

.result-card-compare-control {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    margin-right: auto;
    padding: 0.4rem 0.58rem;
    border: 1px solid rgba(20, 20, 20, 0.16);
    background: rgba(243, 240, 223, 0.65);
    color: #222222;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.result-card-compare-control input {
    width: 1rem;
    height: 1rem;
    margin: 0;
}

.result-card-price {
    font-size: clamp(1.65rem, 2.35vw, 2.25rem);
    line-height: 1;
    font-weight: 900;
    letter-spacing: -0.035em;
    margin-bottom: 0.8rem;
    color: #000000;
}

.result-card-facts-row {
    justify-content: flex-start;
    gap: clamp(0.75rem, 1.4vw, 1.35rem);
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 0.82rem;
    font-weight: 850;
    letter-spacing: 0.06em;
}

.result-card-address {
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.35;
    margin-top: 0;
    margin-bottom: 3rem;   /* Controls space between address and Listed / Days on Market row. Increase for more space; decrease for tighter spacing. */
    color: #202020;
}

.result-card-market-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: 0.90rem;               /* Leave at 0; spacing above this row is controlled by .result-card-address margin-bottom. */
    margin-bottom: 0.85rem;   /* Increase for more space above the green feature divider; decrease for tighter spacing */
    font-family: "Inter", Arial, sans-serif;
    font-size: 0.74rem;
    font-weight: 850;
    letter-spacing: 0.06em;
    text-transform: uppercase;

    color: rgba(0, 0, 0, 0.72);
}

.result-card-market-divider {
    color: #6D6928;
    font-weight: 900;
    padding: 0 0.75rem;
}

.result-card-features {
    margin-top: 0.35rem;
    padding-top: 0.7rem;
    border-top: 1px solid rgba(109, 105, 40, 0.28);
    color: #6D6928;
    font-size: 0.9rem;
    font-weight: 800;
    font-style: italic;
    line-height: 1.42;
}

.result-card-learn-more {
    width: fit-content;
    color: #000000;
    font-size: 0.9rem;
    font-weight: 800;
    text-decoration: underline;
    text-underline-offset: 0.22em;
}

@media (max-width: 1180px) {
    .result-card {
        grid-template-columns: 1fr;
    }

    .result-card-media,
    .result-card-media img,
    .result-card img {
        min-height: 260px;
        height: 260px;
    }
}

@media (max-width: 768px) {
    .idx-search-compare-entry {
        align-items: flex-start;
        flex-direction: column;
    }

    #searchCompareButton {
        width: 100%;
    }
}

/*
==============================================================================
 IDX 20 — PERSONAL QUESTION LINKS / END-OF-PAGE RESOURCES
 Revision Date: 2026-05-16

 PURPOSE
 - Styles the quiet personal question-link section in search-shell.html.
 - Replaces browser-default bright blue links with calm neutral gray links.
 - Keeps the section seasonal-brand friendly: if crest/footer colors change for
   spring, summer, fall, or winter, these links still harmonize.
 - Keeps typography inherited from the page so this does not introduce a second
   visual language or a competing font system.

 SINGLE SOURCE OF TRUTH NOTES
 - Link colors are controlled by the variables below.
 - To make every personal question link lighter or darker, change only:
     --site-soft-link
     --site-soft-link-hover
     --site-soft-link-muted
     --site-soft-link-border
 - Do not hardcode colors on individual links unless intentionally creating a
   one-off exception.

 HOW TO EDIT LINKS IN search-shell.html
 - To change the question:
     edit the text inside .results-helpful-resource-question.
 - To change the small supporting sentence:
     edit the text inside the <em> line.
 - To change where a line goes:
     edit the th:href route on that one <a> tag.
 - To change "More ↓" globally:
     edit the text in each .results-helpful-resource-more span.
 - To add a new line:
     copy one full <a class="results-helpful-resource-link">...</a> block.
 - To remove a line:
     delete one full <a class="results-helpful-resource-link">...</a> block.
 - To change the public email everywhere:
     update site.email in application.properties, not this CSS.

 HOW TO TWEAK SPACING
 - More space above the section:
     increase margin-top on .results-helpful-resources.
 - More space between link rows:
     increase padding on .results-helpful-resource-link.
 - Longer/shorter divider lines:
     adjust max-width on .results-helpful-resources.
==============================================================================
*/

:root {
    --site-soft-link: #5f6368;
    --site-soft-link-hover: #242629;
    --site-soft-link-muted: rgba(0, 0, 0, 0.55);
    --site-soft-link-border: rgba(95, 99, 104, 0.30);
}

.results-helpful-resources {
    max-width: 760px;
    margin-top: 2.75rem;
    margin-bottom: 2.75rem;
    padding-top: 0.35rem;
    font-family: inherit;
}

.results-helpful-resources-list {
    display: grid;
    border-top: 1px solid var(--site-soft-link-border);
}

.results-helpful-resource-link {
    display: grid;
    gap: 0.24rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--site-soft-link-border);
    color: var(--site-soft-link);
    text-decoration: none;
    transition: color 0.16s ease, padding-left 0.16s ease, border-color 0.16s ease;
}

.results-helpful-resource-link:hover,
.results-helpful-resource-link:focus {
    color: var(--site-soft-link-hover);
    padding-left: 0.28rem;
    border-bottom-color: rgba(36, 38, 41, 0.48);
    text-decoration: none;
}

.results-helpful-resource-topline {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    color: inherit;
}

.results-helpful-resource-question {
    color: inherit;
    font-size: clamp(1.05rem, 1.35vw, 1.28rem);
    font-style: italic;
    font-weight: 520;
    line-height: 1.25;
    letter-spacing: -0.015em;
}

.results-helpful-resource-more {
    flex: 0 0 auto;
    color: var(--site-soft-link-muted);
    font-size: 0.72rem;
    font-style: normal;
    font-weight: 800;
    letter-spacing: 0.09em;
    line-height: 1;
    text-transform: uppercase;
}

.results-helpful-resource-link em {
    display: block;
    max-width: 640px;
    color: var(--site-soft-link-muted);
    font-size: 0.92rem;
    font-style: normal;
    font-weight: 400;
    line-height: 1.5;
}

.results-helpful-resource-link strong {
    color: inherit;
    font-weight: 750;
}

@media (max-width: 768px) {
    .results-helpful-resources {
        max-width: 100%;
        margin-top: 2.25rem;
    }

    .results-helpful-resource-topline {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .results-helpful-resource-link:hover,
    .results-helpful-resource-link:focus {
        padding-left: 0;
    }
}

/*
==============================================================================
 IDX 21 — EDITORIAL LINKS CLEAN ROW SYSTEM

 PURPOSE
 - First official CSS block for fragments/editorial-links.html.
 - Renders bottom personal/editorial links as clean stacked rows.
 - Prevents browser-default jumbled blue inline links.
 - Keeps links text-based for SEO and accessibility.
 - No icons.

 HOW TO TWEAK
 - Overall width: change max-width on .editorial-links-shell.
 - Space above/below section: change margin on .editorial-links-shell.
 - Row spacing: change padding on .editorial-link-row.
 - Divider strength: change rgba alpha in border colors.
 - Right-side link color: change #6D6928 on .editorial-link-more.
==============================================================================
*/

.editorial-links-shell {
    margin: 2.5rem auto 1.5rem;
    max-width: 980px;
}

.editorial-links-list {
    display: grid;
    gap: 0;
    border-top: 1px solid rgba(20, 20, 20, 0.14);
}

.editorial-link-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.25rem;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(20, 20, 20, 0.14);
    color: #111111;
}

.editorial-link-copy {
    flex: 1 1 auto;
    min-width: 0;
}

.editorial-link-question {
    margin: 0;
    font-weight: 500;
    line-height: 1.45;
}

.editorial-link-question + .editorial-link-question {
    margin-top: 0.75rem;
}

.editorial-link-actions {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.5rem;
}

.editorial-link-more {
    display: inline-flex;
    justify-content: flex-end;
    gap: 0.35rem;
    color: #6D6928;
    font-weight: 800;
    text-align: right;
    white-space: normal;
    text-decoration: none;
}

.editorial-link-more:hover,
.editorial-link-more:focus-visible {
    color: #6D6928;
    text-decoration: underline;
}

@media (max-width: 640px) {
    .editorial-link-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.35rem;
    }

    .editorial-link-actions {
        align-items: flex-start;
        width: 100%;
    }

    .editorial-link-more {
        justify-content: flex-start;
        text-align: left;
    }
}

/*
==============================================================================
 IDX 22 — SEARCH DISCOVERY ARCHITECTURE SYSTEM
 Revision Date: 2026-05-21

 PURPOSE
 - Creates the new professional search discovery architecture layer.
 - Powers:
     • Featured Town ecosystems
     • Discovery search categories
     • Shoreline exploration
     • Lifestyle navigation
     • Future editorial clustering
 - Keeps SearchDiscoveryRegistry as the single source of truth.
 - Designed to scale cleanly without nav clutter.

 ARCHITECTURE NOTES
 - This section intentionally lives BELOW the Phase 1 hero.
 - The hero remains the fast-entry experience.
 - This system becomes the guided discovery layer.
 - Editorial checkerboards remain below this section.

 DESIGN GOALS
 - Calm luxury editorial feel.
 - Easy scanning.
 - No overwhelming mega-menu feeling.
 - Strong spacing rhythm.
 - Future-proof for dozens of search ecosystems.

 HOW TO TWEAK
 - Wider discovery shell:
     change max-width on .search-discovery-shell
 - More/less columns:
     change grid-template-columns
 - More luxury spacing:
     increase padding values
 - Softer cards:
     reduce border opacity
 - Darker headings:
     change heading color values
==============================================================================
*/

.search-discovery-shell {
    max-width: 1320px;
    margin: 0 auto;
    padding: 4rem 1.5rem 2rem;
}

.search-discovery-header {
    max-width: 760px;
    margin-bottom: 2.5rem;
}

.search-discovery-eyebrow {
    color: #6D6928;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.9rem;
}

.search-discovery-title {
    font-size: clamp(2.2rem, 4vw, 4rem);
    line-height: 1.02;
    font-weight: 600;
    color: #1f2328;
    margin-bottom: 1.1rem;
}

.search-discovery-copy {
    font-size: 1.02rem;
    line-height: 1.85;
    color: #5f5f5f;
    max-width: 720px;
}

.search-discovery-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.4rem;
}

.search-discovery-card {
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(20, 20, 20, 0.10);
    padding: 1.6rem;
    transition:
            transform 0.18s ease,
            box-shadow 0.18s ease,
            border-color 0.18s ease;
}

.search-discovery-card:hover {
    transform: translateY(-2px);

    box-shadow:
            0 18px 36px rgba(0, 0, 0, 0.06);

    border-color:
            rgba(109, 105, 40, 0.28);
}

.search-discovery-card-title {
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.2;
    color: #111111;
    margin-bottom: 0.95rem;
}

.search-discovery-links {
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.search-discovery-links a {
    color: rgba(0, 0, 0, 0.78);
    text-decoration: none;
    font-weight: 600;
    line-height: 1.45;
    transition:
            color 0.18s ease,
            transform 0.18s ease;
}

.search-discovery-links a:hover {
    color: #6D6928;
    transform: translateX(2px);
}

.search-discovery-divider {
    height: 1px;
    background:
            linear-gradient(
                    to right,
                    rgba(109, 105, 40, 0),
                    rgba(109, 105, 40, 0.24),
                    rgba(109, 105, 40, 0)
            );

    margin: 4rem 0 1rem;
}

@media (max-width: 980px) {

    .search-discovery-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {

    .search-discovery-shell {
        padding-top: 2.75rem;
    }

    .search-discovery-title {
        font-size: 2.3rem;
    }
}

/*
==============================================================================
 IDX 22 PATCH — SEARCH DISCOVERY MENU ACTUAL FRAGMENT SELECTORS
 PURPOSE
 - Styles the actual classes used by fragments/search-discovery-menu.html.
 - Fixes mismatch between earlier concept CSS and implemented fragment names.
==============================================================================
*/

.search-discovery-menu {
    max-width: 1320px;
    margin: 0 auto;
    padding: 4rem 1.5rem 2rem;
    background: #F3F0DF;
}

.search-discovery-menu__intro {
    max-width: 780px;
    margin-bottom: 2.5rem;
}

.search-discovery-menu__eyebrow,
.search-discovery-menu__section-label {
    color: #6D6928;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.9rem;
}

.search-discovery-menu__title {
    font-size: clamp(2.2rem, 4vw, 4rem);
    line-height: 1.02;
    font-weight: 600;
    color: #1f2328;
    margin-bottom: 1.1rem;
}

.search-discovery-menu__summary,
.search-discovery-menu__panel-note {
    font-size: 1.02rem;
    line-height: 1.75;
    color: #5f5f5f;
}

.search-discovery-menu__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
}

.search-discovery-menu__panel,
.search-discovery-menu__towns {
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(20, 20, 20, 0.10);
    padding: 1.6rem;
}

.search-discovery-menu__panel--primary {
    border-color: rgba(109, 105, 40, 0.32);
    background: rgba(255, 255, 255, 0.86);
}

.search-discovery-menu__panel h3,
.search-discovery-menu__town-heading h3 {
    font-size: 1.35rem;
    font-weight: 800;
    line-height: 1.15;
    color: #111111;
    margin-bottom: 0.85rem;
}

.search-discovery-menu__list,
.search-discovery-menu__town-group ul {
    list-style: none;
    padding-left: 0;
    margin: 1rem 0 0;
}

.search-discovery-menu__list li,
.search-discovery-menu__town-group li {
    border-top: 1px solid rgba(20, 20, 20, 0.10);
}

.search-discovery-menu__list a,
.search-discovery-menu__town-group a {
    display: block;
    padding: 0.75rem 0;
    color: rgba(0, 0, 0, 0.82);
    text-decoration: none;
    font-weight: 650;
    line-height: 1.4;
}

.search-discovery-menu__list a:hover,
.search-discovery-menu__town-group a:hover {
    color: #6D6928;
    text-decoration: none;
}

.search-discovery-menu__towns {
    margin-top: 1.4rem;
}

.search-discovery-menu__town-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.35rem;
    margin-top: 1.5rem;
}

.search-discovery-menu__town-group h4 {
    color: #6D6928;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 0.8rem;
}

@media (max-width: 980px) {
    .search-discovery-menu__grid,
    .search-discovery-menu__town-grid {
        grid-template-columns: 1fr;
    }
}

/*
==============================================================================
 IDX 22 — DISCOVERY VISUAL REFINEMENT PASS
 Revision Date: 2026-05-21

 PURPOSE
 - Refines the Search Discovery architecture visually.
 - Moves experience away from “Bootstrap application.”
 - Moves experience toward:
      editorial
      luxury
      discovery-first
      shoreline lifestyle
      EEAT-oriented navigation UX

 IMPORTANT
 - This is a refinement layer ONLY.
 - No architecture changes occur here.
 - No route changes occur here.
 - No registry changes occur here.

 DESIGN GOALS
 - Softer luxury visual tone
 - Better typography hierarchy
 - More elegant serif contrast
 - More breathing room
 - Cleaner editorial rhythm

 FUTURE
 - After this pass:
      • hover animation refinement
      • active-state refinement
      • featured-town route wiring
      • dynamic registry rendering
      • nav flyout consumption
==============================================================================
*/

:root {

    --discovery-bg:
            #F3F0DF;

    --discovery-card-bg:
            #F8F6ED;

    --discovery-border:
            rgba(109, 105, 40, 0.14);

    --discovery-accent:
            #6D6928;

    --discovery-heading:
            #6D6928;

    --discovery-body:
            #5D5A52;

    --discovery-link:
            #232323;
}

/*
==============================================================================
 MAIN DISCOVERY WRAPPER
==============================================================================
*/

.search-discovery-menu {

    background:
            var(--discovery-bg);

    padding-top:
            5.5rem;

    padding-bottom:
            5rem;
}

/*
==============================================================================
 EYEBROW
==============================================================================
*/

.search-discovery-menu__eyebrow {

    text-align:
            center;

    color:
            var(--discovery-accent);

    font-size:
            0.88rem;

    font-weight:
            700;

    letter-spacing:
            0.24em;

    text-transform:
            uppercase;

    margin-bottom:
            1.25rem;
}

/*
==============================================================================
 MAIN HERO TITLE
==============================================================================
*/

.search-discovery-menu__title {

    font-family:
            "EB Garamond",
            serif;

    font-size:
            clamp(4.3rem, 7vw, 6.9rem);

    line-height:
            0.95;

    letter-spacing:
            -0.03em;

    text-align:
            center;

    color:
            var(--discovery-heading);

    font-weight:
            500;

    max-width:
            1180px;

    margin:
            0 auto 2.25rem auto;
}

/*
==============================================================================
 INTRO COPY
==============================================================================
*/

.search-discovery-menu__summary {

    max-width:
            860px;

    margin:
            0 auto 4.5rem auto;

    text-align:
            center;

    color:
            var(--discovery-body);

    font-size:
            1.16rem;

    line-height:
            1.95;

    font-weight:
            400;
}

/*
==============================================================================
 PRIMARY CARD GRID
==============================================================================
*/

.search-discovery-menu__grid {

    gap:
            2rem;

    margin-bottom:
            2.75rem;
}

/*
==============================================================================
 DISCOVERY PANELS
==============================================================================
*/

.search-discovery-menu__panel,
.search-discovery-menu__towns {

    background:
            var(--discovery-card-bg);

    border:
            1px solid var(--discovery-border);

    padding:
            2.4rem 2.2rem 2.4rem;

    box-shadow:
            0 10px 30px rgba(0,0,0,0.025);
}

/*
==============================================================================
 PANEL EYEBROWS
==============================================================================
*/

.search-discovery-menu__section-label {

    color:
            var(--discovery-accent);

    font-size:
            0.84rem;

    font-weight:
            800;

    letter-spacing:
            0.18em;

    text-transform:
            uppercase;

    margin-bottom:
            1.3rem;
}

/*
==============================================================================
 PANEL HEADINGS
==============================================================================
*/

.search-discovery-menu__panel h3,
.search-discovery-menu__town-heading h3 {

    font-family:
            "EB Garamond",
            serif;

    font-size:
            3rem;

    line-height:
            0.98;

    font-weight:
            500;

    color:
            #232323;

    margin-bottom:
            1.3rem;
}

/*
==============================================================================
 PANEL COPY
==============================================================================
*/

.search-discovery-menu__panel-note,
.search-discovery-menu__town-copy {

    color:
            var(--discovery-body);

    font-size:
            1.03rem;

    line-height:
            1.9;

    font-weight:
            400;

    margin-bottom:
            1.6rem;
}

/*
==============================================================================
 LISTS
==============================================================================
*/

.search-discovery-menu__list li,
.search-discovery-menu__town-group li {

    border-top:
            1px solid rgba(109,105,40,0.10);
}

/*
==============================================================================
 LINKS
==============================================================================
*/

.search-discovery-menu__list a,
.search-discovery-menu__town-group a {

    color:
            var(--discovery-link);

    font-size:
            1.02rem;

    font-weight:
            650;

    padding:
            1rem 0;

    transition:
            color 0.18s ease,
            transform 0.18s ease;
}

.search-discovery-menu__list a:hover,
.search-discovery-menu__town-group a:hover {

    color:
            var(--discovery-accent);

    transform:
            translateX(2px);
}

/*
==============================================================================
 FEATURED TOWNS BLOCK
==============================================================================
*/

.search-discovery-menu__towns {

    margin-top:
            3rem;
}

/*
==============================================================================
 FEATURED TOWNS GRID
==============================================================================
*/

.search-discovery-menu__town-grid {

    gap:
            2rem;

    margin-top:
            2.4rem;
}

/*
==============================================================================
 TOWN GROUP HEADINGS
==============================================================================
*/

.search-discovery-menu__town-group h4 {

    color:
            var(--discovery-accent);

    font-size:
            0.88rem;

    font-weight:
            900;

    letter-spacing:
            0.16em;

    text-transform:
            uppercase;

    margin-bottom:
            1rem;
}

/*
==============================================================================
 RESPONSIVE
==============================================================================
*/

@media (max-width: 1200px) {

    .search-discovery-menu__title {

        font-size:
                clamp(3.6rem, 6vw, 5.4rem);
    }
}

@media (max-width: 980px) {

    .search-discovery-menu__title {

        font-size:
                3.5rem;

        line-height:
                1;
    }

    .search-discovery-menu__summary {

        font-size:
                1rem;
    }
}

@media (max-width: 768px) {

    .search-discovery-menu {

        padding-top:
                3.5rem;
    }

    .search-discovery-menu__title {

        font-size:
                2.8rem;
    }

    .search-discovery-menu__panel h3,
    .search-discovery-menu__town-heading h3 {

        font-size:
                2.2rem;
    }
}

.search-discovery-menu__intro {
    max-width: 1180px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.search-discovery-menu__title {
    display: block;
    max-width: 1050px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    text-wrap: balance;
}

@media (max-width: 768px) {
    .search-discovery-menu__title {
        max-width: 92%;
        font-size: clamp(3rem, 13vw, 4.4rem);
        line-height: 0.95;
    }

    .search-discovery-menu__summary {
        max-width: 88%;
    }
}


/*
==============================================================================
 IDX 24 EDIT — CURATED RAIL TARGET DESIGN PASS

 PURPOSE
 - Styles Explore More Homes as the IDX-ready horizontal discovery rail.
 - Keeps SearchDiscoveryRegistry labels/routes/CTA text as SOT.
 - Keeps the shared listing-card fragment as the card renderer.
 - Uses ivory #F3F0DF as the page/section background.
==============================================================================
*/

.idx-curated-card-rail {
    margin-top: 2.75rem;
    padding: 0;
    background: #F3F0DF;
    border: 0;
}

.idx-curated-card-rail__title {
    margin: 0 0 0.35rem;
    color: #263d18;
    font-size: clamp(2.25rem, 4vw, 3.75rem);
    font-weight: 900;
    letter-spacing: -0.045em;
    line-height: 0.95;
}

.idx-curated-card-rail__summary {
    margin: 0 0 1.35rem;
    color: #011640;
    font-size: 0.98rem;
    font-weight: 750;
}

.idx-curated-card-rail__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.idx-curated-card-rail__item {
    display: grid;
    grid-template-columns: minmax(245px, 0.8fr) minmax(330px, 1.12fr) minmax(330px, 1fr);
    align-items: stretch;
    background: #ffffff;
    border: 1px solid rgba(1, 22, 64, 0.12);
    border-radius: 0.55rem;
    overflow: hidden;
}

.idx-curated-card-rail__heading {
    grid-column: 2;
    grid-row: 1;
    margin: 0;
    padding: 1.15rem 1.65rem 0;
    color: #011640;
    font-size: clamp(1.05rem, 1.3vw, 1.32rem);
    font-weight: 900;
    line-height: 1.15;
}

.idx-curated-card-rail__item .result-card-shell--curated,
.idx-curated-card-rail__item .result-card--curated {
    display: contents;
}

.idx-curated-card-rail__item .result-card-media--curated {
    grid-column: 1;
    grid-row: 1 / 4;
    min-height: 180px;
    background: #f7f6ed;
    border-right: 1px solid rgba(1, 22, 64, 0.08);
}

.idx-curated-card-rail__item .result-card-media--curated img {
    display: block;
    width: 100%;
    height: 180px;
    min-height: 180px;
    object-fit: cover;
}

.idx-curated-card-rail__item .result-card-body--curated {
    grid-column: 2;
    grid-row: 2;
    min-height: 0;
    padding: 0.55rem 1.65rem 1.15rem;
    justify-content: flex-start;
}

.idx-curated-card-rail__item .result-card-body--curated > .d-flex:first-child {
    display: none !important;
}

.idx-curated-card-rail__item .result-card-actions--curated {
    grid-column: 3;
    grid-row: 1 / 3;
    display: flex !important;
    flex-direction: column;
    align-items: flex-start !important;
    justify-content: center !important;
    gap: 1.15rem;
    min-height: 180px;
    padding: 1.15rem 1.9rem;
    border-left: 1px solid rgba(1, 22, 64, 0.1);
}

.idx-curated-card-rail__search-link {
    grid-column: 3;
    grid-row: 3;
    align-self: start;
    margin: 0;
    padding: 0 1.9rem 1.15rem;
    border-left: 1px solid rgba(1, 22, 64, 0.1);
}

.idx-curated-card-rail__item .result-card-actions--curated .result-card-learn-more,
.idx-curated-card-rail__search-link {
    color: #2f3f13;
    font-size: 0.92rem;
    font-weight: 900;
    line-height: 1.3;
    text-decoration: none;
}

.idx-curated-card-rail__item .result-card-actions--curated .result-card-learn-more::after,
.idx-curated-card-rail__search-link::after {
    content: " →";
    padding-left: 0.55rem;
}

@media (max-width: 1180px) {
    .idx-curated-card-rail__item {
        grid-template-columns: minmax(230px, 0.85fr) minmax(0, 1.15fr);
    }

    .idx-curated-card-rail__heading,
    .idx-curated-card-rail__item .result-card-body--curated {
        grid-column: 2;
    }

    .idx-curated-card-rail__item .result-card-actions--curated,
    .idx-curated-card-rail__search-link {
        grid-column: 1 / -1;
        grid-row: auto;
        border-left: 0;
        border-top: 1px solid rgba(1, 22, 64, 0.08);
    }
}

@media (max-width: 700px) {
    .idx-curated-card-rail__item {
        grid-template-columns: 1fr;
    }

    .idx-curated-card-rail__item .result-card-media--curated,
    .idx-curated-card-rail__heading,
    .idx-curated-card-rail__item .result-card-body--curated,
    .idx-curated-card-rail__item .result-card-actions--curated,
    .idx-curated-card-rail__search-link {
        grid-column: 1;
        grid-row: auto;
        border-left: 0;
        border-right: 0;
    }
}

/*
==============================================================================
 IDX 24 EDIT — MAP RESULT / SUGGESTION LEGEND

 PURPOSE
 - Adds a visible buyer-friendly legend for future IDX map marker logic.
 - Red dots represent homes matching the current search.
 - Blue dots represent suggested homes from Explore/curated search logic.
==============================================================================
*/

.map-pin--suggestion {
    background: #1f5fae;
    box-shadow: 0 0 0 6px rgba(31, 95, 174, 0.18);
}

.map-legend {
    display: grid;
    gap: 0.45rem;
    margin-top: 0.85rem;
    padding: 0.85rem 0.95rem;
    background: #ffffff;
    border: 1px solid rgba(1, 22, 64, 0.12);
    color: #011640;
    font-size: 0.82rem;
    font-weight: 750;
    line-height: 1.35;
}

.map-legend span {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.map-legend-dot {
    display: inline-block;
    width: 0.68rem;
    height: 0.68rem;
    border-radius: 50%;
    flex: 0 0 auto;
}

.map-legend-dot--result {
    background: #c1141c;
}

.map-legend-dot--suggestion {
    background: #1f5fae;
}


/*
==============================================================================
 IDX 24 EDIT — HERO-FIRST RESULT CARD PASS 1

 PURPOSE
 - Makes the shared listing card hero image dominant on top.
 - Keeps the existing fragment structure intact for low blast radius.
 - Preserves current map, compare, save/share, Explore, and legend behavior.
==============================================================================
*/

.result-card-shell > .d-flex {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 0.42fr);
    align-items: center !important;
    gap: 1rem !important;
    padding: 0.95rem 1.15rem;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(20, 20, 20, 0.12);
    border-top: 0;
}

.result-card-shell > .d-flex .result-card-learn-more {
    margin: 0;
}

@media (max-width: 768px) {
    .result-card-shell > .d-flex {
        grid-template-columns: 1fr;
        align-items: start !important;
    }
}


/*
==============================================================================
 IDX 24 EDIT — UNIFIED CARD DETAILS / ACTIONS BAND

 PURPOSE
 - Places listing details and destination links into two organized columns.
 - Uses the approved navy/olive visual language.
 - Keeps hero/media dominant above the information band.
 - Applies to both standard result cards and curated Explore cards through the
   shared listing-card fragment.
==============================================================================
*/

.result-card-content-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(220px, 0.75fr);
    gap: clamp(1.25rem, 2.6vw, 2.5rem);
    align-items: start;
}

.result-card-content-primary {
    min-width: 0;
}

.result-card-content-links {
    display: grid;
    gap: 0.9rem;
    align-content: start;
    min-width: 0;
    padding-left: clamp(1rem, 2vw, 1.8rem);
    border-left: 1px solid rgba(109, 105, 40, 0.42);
}

.result-card-content-links .result-card-learn-more {
    color: #011640;
    font-size: 0.92rem;
    font-weight: 900;
    line-height: 1.25;
    text-decoration: none;
}

.result-card-content-links .result-card-learn-more::after {
    content: " →";
    padding-left: 0.4rem;
    color: #6D6928;
}

.result-card-icon-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.55rem;
    margin-bottom: 0.25rem;
}

.result-card-content-links .result-card-compare-control {
    justify-self: end;
    margin-top: 0.35rem;
}

@media (max-width: 768px) {
    .result-card-content-grid {
        grid-template-columns: 1fr;
    }

    .result-card-content-links {
        padding-left: 0;
        padding-top: 1rem;
        border-left: 0;
        border-top: 1px solid rgba(109, 105, 40, 0.32);
    }

    .result-card-content-links .result-card-compare-control {
        justify-self: start;
    }
}


/*
==============================================================================
 IDX 24 EDIT — HERO CARD BACKGROUND / COMPARE ALIGNMENT CORRECTION

 PURPOSE
 - Keeps the outer card and hero placeholder aligned with the page ivory.
 - Keeps only the information band softly white for readability.
 - Makes Compare read left-to-right while placing the checkbox on the far right.
==============================================================================
*/

.result-card,
.result-card-media {
    background: #F3F0DF;
}

.result-card-body {
    background: rgba(255, 255, 255, 0.92);
}

.result-card-content-links .result-card-compare-control {
    display: inline-flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    justify-self: end;
    min-width: 8.5rem;
}

.result-card-content-links .result-card-compare-control input {
    margin-left: 0.55rem !important;
}


/*
==============================================================================
 IDX 24 EDIT — CURATED CARDS FOLLOW UNIFIED HERO-FIRST CARD

 PURPOSE
 - Stops Explore More Homes from fighting the unified result-card layout.
 - Lets curated cards inherit the same hero-on-top / details-left / links-right
   pattern as normal result cards.
 - Keeps Explore section typography and spacing intact.
==============================================================================
*/

.idx-curated-card-rail__item {
    display: block;
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: visible;
}

.idx-curated-card-rail__heading {
    display: none;
}

.idx-curated-card-rail__item .result-card-shell--curated,
.idx-curated-card-rail__item .result-card--curated {
    display: grid;
}

.idx-curated-card-rail__item .result-card--curated {
    grid-template-columns: 1fr;
    background: #F3F0DF;
    border: 1px solid rgba(20, 20, 20, 0.12);
    overflow: hidden;
}

.idx-curated-card-rail__item .result-card-media--curated {
    grid-column: auto;
    grid-row: auto;
    min-height: 310px;
    background: #F3F0DF;
    border-right: 0;
}

.idx-curated-card-rail__item .result-card-media--curated img {
    height: 100%;
    min-height: 310px;
    object-fit: cover;
}

.idx-curated-card-rail__item .result-card-body--curated {
    grid-column: auto;
    grid-row: auto;
    padding: clamp(1.35rem, 2.6vw, 2.35rem);
}

.idx-curated-card-rail__item .result-card-actions--curated {
    display: none !important;
}

.idx-curated-card-rail__search-link {
    display: none;
}


/*
==============================================================================
 IDX 24 EDIT — COMPARE ALIGNMENT + EXPLORE CATEGORY TITLES

 PURPOSE
 - Places Compare text on the left and checkbox on the far right.
 - Restores curated Explore category titles above each shared card.
==============================================================================
*/

.result-card-content-links .result-card-compare-control {
    display: inline-grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    justify-self: end;
    gap: 0.75rem;
    min-width: 8.75rem;
}

.result-card-content-links .result-card-compare-control input {
    grid-column: 2;
}

.result-card-content-links .result-card-compare-control .form-check-label {
    grid-column: 1;
    grid-row: 1;
}

.idx-curated-card-rail__heading {
    display: block;
    margin: 0 0 0.55rem;
    color: #011640;
    font-size: clamp(1.05rem, 1.4vw, 1.35rem);
    font-weight: 900;
    line-height: 1.15;
}


/*
==============================================================================
 IDX 24 EDIT — COMPARE FINAL ALIGNMENT
==============================================================================
*/

.result-card-content-links .result-card-compare-control {
    justify-self: end;
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 0.55rem;
}

.result-card-content-links .result-card-compare-control input {
    order: 2;
    margin-left: 0.35rem !important;
}

.result-card-content-links .result-card-compare-control .form-check-label {
    order: 1;
}


/*
==============================================================================
 IDX 24 EDIT — CHECKBOX ACTION ALIGNMENT FIX
==============================================================================
*/

.result-card-content-links .result-card-compare-control,
.result-card-content-links .result-card-schedule-control {
    width: 100%;
    min-width: 0;
    margin: 0 !important;
    padding: 0.48rem 0.65rem;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    justify-self: stretch;
    gap: 0.75rem;
    border: 1px solid rgba(20, 20, 20, 0.16);
    background: rgba(243, 240, 223, 0.65);
}

.result-card-content-links .result-card-compare-control input,
.result-card-content-links .result-card-schedule-control input {
    grid-column: 2;
    justify-self: end;
    margin: 0 !important;
}

.result-card-content-links .result-card-compare-control .form-check-label,
.result-card-content-links .result-card-schedule-control .form-check-label {
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
}


/*
==============================================================================
 IDX 24 EDIT — UNIFIED ACTION CHECKBOX TYPOGRAPHY
==============================================================================
*/

.result-card-content-links .result-card-compare-control,
.result-card-content-links .result-card-schedule-control {
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-size: 1rem !important;
    font-weight: 800 !important;
    color: #111111 !important;
}

.result-card-content-links .result-card-compare-control .form-check-label,
.result-card-content-links .result-card-schedule-control .form-check-label {
    text-transform: none !important;
    letter-spacing: 0 !important;
    font-size: 1rem !important;
    font-weight: 800 !important;
    color: #111111 !important;
}


/*
==============================================================================
 IDX 24 EDIT — FORCE COMPARE LABEL TO MATCH SCHEDULE LABEL
==============================================================================
*/

.result-card-content-links label.result-card-compare-control span.form-check-label.small.fw-semibold,
.result-card-content-links label.result-card-schedule-control span.form-check-label.small.fw-semibold {
    font-size: 1rem !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    color: #111111 !important;
}

.result-card-content-links label.result-card-compare-control,
.result-card-content-links label.result-card-schedule-control {
    font-size: 1rem !important;
    font-weight: 800 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
}

.mary-profile-footer__inner {
    max-width: 980px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 1.5rem;
    align-items: center;
}

.mary-profile-footer__image {
    width: 150px;
    height: 150px;
    object-fit: cover;
    display: block;
}

.mary-profile-footer__copy p {
    margin-bottom: 0;
}

@media (max-width: 700px) {
    .mary-profile-footer__inner {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .mary-profile-footer__image {
        margin: 0 auto;
    }
}

.search-discovery-menu__town-link {
    display: inline-block;
    background: #6f6f2a;
    color: #ffffff;
    text-decoration: none;
    font-weight: 700;
    padding: 0.85rem 1.5rem;
    border-radius: 0.75rem;
}

.search-discovery-menu__town-link:hover,
.search-discovery-menu__town-link:focus {
    background: #5f5f22;
    color: #ffffff;
    text-decoration: none;
}

.curated-landing-town-list {
    list-style-position: outside;
    margin: 1.5rem 0 0;
    padding-left: 1.25rem;
}

.curated-landing-town-list li {
    margin-bottom: 0.45rem;
}

.curated-landing-town-list a {
    color: #707426;
    font-weight: 600;
    text-decoration: none;
}

.curated-landing-town-list a:hover,
.curated-landing-town-list a:focus {
    color: #4f5518;
    text-decoration: underline;
}


/*
==============================================================================
 TESTIMONIAL QUOTE SOT — STATIC PAGE QUOTE BOX SYSTEM

 FILE
 - src/main/resources/static/css/search.css

 USED BY
 - fragments/testimonial-quote.html
 - TestimonialService.java supplies the quote text / attribution SOT.
 - Static page templates only choose where the shared testimonial fragment appears.

 PURPOSE
 - Controls the visual treatment for testimonial quotes dotted across static pages.
 - Also supports the future Testimonials page using the same shared styling.
 - Keeps quote color, spacing, font, boldness, italic treatment, radius, and border
   behavior centralized here instead of repeating styles in individual templates.

 COLOR SOT
 - Current quote background uses crest French blue #799caf at 42% opacity.
 - CSS rgba equivalent: rgba(121, 156, 175, 0.42).
 - To make the quote box darker / stronger, increase the last number:
     rgba(121, 156, 175, 0.55)
 - To make the quote box lighter / softer, decrease the last number:
     rgba(121, 156, 175, 0.28)
 - To change to another brand color, edit only --testimonial-quote-background.

 STROKE / BORDER
 - Current design has no stroke / border.
 - To add a border later, change --testimonial-quote-border from none to:
     1px solid rgba(121, 156, 175, 0.65)
 - For now, keep no stroke because the soft fill is the design treatment.

 TEXT STYLE
 - Italic is controlled by --testimonial-quote-font-style.
 - Boldness / stroke is controlled by --testimonial-quote-font-weight.
 - Text color is controlled by --testimonial-quote-text.
 - Attribution color is controlled by --testimonial-quote-footer-text.

 FONT
 - Current font inherits the site/body font through --testimonial-quote-font-family.
 - To test another quote font later, change --testimonial-quote-font-family only.
   Examples:
     "EB Garamond", Georgia, serif
     "Inter", Arial, sans-serif

 SPACING / POSITION
 - Move the whole quote block up/down by changing --testimonial-quote-margin.
   Example:
     2rem 0 = less vertical space
     4rem 0 = more vertical space
 - Inner breathing room is controlled by --testimonial-quote-padding.
 - Indent from surrounding content can be changed with --testimonial-quote-indent.
   Example:
     1rem adds left/right inset
     0 keeps it aligned with the text column
 - Corner roundness is controlled by --testimonial-quote-radius.

 IMPORTANT SOT RULE
 - Do not add quote-specific Bootstrap classes or inline styles in page templates.
 - Pages should keep using:
     fragments/testimonial-quote :: testimonialQuote(${featuredTestimonial})
 - Change quote design here once; all pages update together.
==============================================================================
*/

:root {
    --testimonial-quote-background: rgba(121, 156, 175, 0.42);
    --testimonial-quote-text: #1f2933;
    --testimonial-quote-footer-text: #5f6f7a;
    --testimonial-quote-border: none;
    --testimonial-quote-radius: 0.5rem;
    --testimonial-quote-margin: 3rem 0;
    --testimonial-quote-padding: 1.5rem;
    --testimonial-quote-indent: 0;
    --testimonial-quote-font-family: inherit;
    --testimonial-quote-font-style: italic;
    --testimonial-quote-font-weight: 700;
    --testimonial-quote-footer-font-weight: 400;
}

.testimonial-quote {
    margin: var(--testimonial-quote-margin);
    padding-left: var(--testimonial-quote-indent);
    padding-right: var(--testimonial-quote-indent);
}

.testimonial-quote__box {
    background-color: var(--testimonial-quote-background);
    border: var(--testimonial-quote-border);
    border-radius: var(--testimonial-quote-radius);
    color: var(--testimonial-quote-text);
    font-family: var(--testimonial-quote-font-family);
    font-style: var(--testimonial-quote-font-style);
    font-weight: var(--testimonial-quote-font-weight);
    margin: 0;
    padding: var(--testimonial-quote-padding);
}

.testimonial-quote__box p:last-of-type {
    margin-bottom: 0;
}

.testimonial-quote__footer {
    color: var(--testimonial-quote-footer-text);
    font-style: normal;
    font-weight: var(--testimonial-quote-footer-font-weight);
    margin-top: 1rem;
}

/*
==============================================================================
 EDITORIAL LINKS INTRO SOT

 PURPOSE
 - Styles the short intro sentence that appears directly above the shared
   editorial-links fragment.
 - Text is supplied by EditorialLinksService.introFor(pageGroup).
 - Do not hardcode this sentence in individual page templates.

 HOW TO TWEAK
 - Vertical spacing above/below: change margin values.
 - Text color: change color.
 - Font size/weight/style: adjust font-size, font-weight, or font-style.
==============================================================================
*/

.editorial-links-intro {
    margin: 1.5rem 0 0.9rem;
    color: rgba(0, 0, 0, 0.72);
    font-size: 0.98rem;
    font-weight: 500;
    line-height: 1.65;
}

/* ==========================================================================
   CURATED LANDING FILTER POLISH
   ========================================================================== */

.curated-landing-page .curated-landing-filter-shell {
    margin: 2rem 0 2.5rem;
    padding: 1rem;
    background: var(--curated-filter-shell-background);
    border: 1px solid var(--curated-filter-shell-border);
    border-radius: 18px;
    box-shadow: var(--curated-filter-shell-shadow);
}

.curated-landing-page .curated-landing-filter-shell .row {
    gap: 0;
}

.curated-landing-page .curated-landing-filter-shell .form-label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--curated-filter-label-color);
}

.curated-landing-page .curated-landing-filter-shell .form-select,
.curated-landing-page .curated-landing-filter-shell .dropdown-toggle.form-select {
    min-height: 74px;
    padding: 1rem;
    background-color: var(--curated-filter-control-background);
    border: 1px solid var(--curated-filter-control-border);
    border-radius: 14px;
    color: var(--curated-filter-control-text);
    font-size: 1rem;
    font-weight: 600;
    box-shadow: none;
}

.curated-landing-page .curated-landing-filter-shell .form-select:focus,
.curated-landing-page .curated-landing-filter-shell .dropdown-toggle.form-select:focus {
    border-color: var(--curated-filter-focus-border);
    box-shadow: var(--curated-filter-focus-ring);
}

.curated-landing-page .dropdown-menu {
    border: 1px solid var(--curated-filter-control-border);
    border-radius: 14px;
    box-shadow: var(--curated-filter-menu-shadow);
}

.curated-landing-page .btn-link,
.curated-landing-page .btn-link:visited {
    color: var(--curated-filter-link-color);
}

.curated-landing-page .btn-link:hover,
.curated-landing-page .btn-link:focus {
    color: var(--curated-filter-link-hover-color);
}

.curated-landing-page a:not(.btn),
.curated-landing-page a:not(.btn):visited {
    color: var(--curated-filter-link-color);
    text-decoration-color: var(--curated-filter-link-decoration);
    text-underline-offset: 0.18em;
}

.curated-landing-page a:not(.btn):hover,
.curated-landing-page a:not(.btn):focus {
    color: var(--curated-filter-link-hover-color);
    text-decoration-color: var(--curated-filter-link-hover-decoration);
}

@media (max-width: 768px) {
    .curated-landing-page .curated-landing-filter-shell {
        padding: 0.85rem;
    }
}

/* ==========================================================================
   SHARED MENU CLOSE CONTROL — SINGLE SOURCE OF TRUTH

   PURPOSE
   - Provides one visual system for the header and Towns-menu close controls.
   - Uses global brand tokens rather than inline or repeated raw colors.
   - Keeps top and bottom Towns-menu placement behavior centralized.
   ========================================================================== */

.menu-close-control {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top:
            var(--bs-border-width)
            var(--bs-border-style)
            var(--bs-border-color);
}

.menu-close-control__action {
    appearance: none;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--site-brand-olive);
    cursor: pointer;
    font: inherit;
    font-weight: 600;
    text-decoration: none;
}

.menu-close-control__action:hover,
.menu-close-control__action:focus {
    background: transparent;
    color: var(--site-brand-olive);
    text-decoration: none;
}

.menu-close-control__action:focus-visible {
    outline: 2px solid rgba(var(--site-brand-olive-rgb), 0.42);
    outline-offset: 0.25rem;
}

/*
 * TOWNS MENU CLOSE-CONTROL PLACEMENT
 *
 * The top control is rendered outside the independently scrollable town grid.
 * It therefore remains available without JavaScript scroll listeners.
 *
 * Both placement variants retain the shared presentation and behavior owned
 * by menu-close-control.
 */
.menu-close-control--town-top {
    margin-top: 0;
    margin-bottom: 1rem;
    padding-top: 0;
    padding-bottom: 0.75rem;
    border-top: 0;
    border-bottom:
            var(--bs-border-width)
            var(--bs-border-style)
            var(--bs-border-color);
}

.menu-close-control--town-bottom {
    margin-top: 1.5rem;
}

/* SHARED TOWN MENU TWO-COLUMN LAYOUT */
.curated-landing-page .curated-town-dropdown-menu,
.results-town-dropdown-menu {
    min-width: min(760px, calc(100vw - 2rem));
    max-height: none;
    overflow: visible;
}

.curated-town-menu-grid {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr);
    gap: 1.25rem;
    align-items: start;
    max-height: 24rem;
    overflow-y: auto;
}

.curated-town-menu-grid__column {
    min-width: 0;
}

.town-menu-column-heading {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.18rem;
}

.town-menu-actions {
    display: inline-flex;
    align-items: center;
    gap: 0.28rem;
    font-size: 0.72rem;
    line-height: 1.2;
}

:root {
    --curated-filter-shell-background: #f8f6f2;
    --curated-filter-shell-border: #e8e1d8;
    --curated-filter-shell-shadow:
            0 8px 24px rgba(20, 20, 20, 0.05);

    --curated-filter-label-color: #7a7f86;

    --curated-filter-control-background: #ffffff;
    --curated-filter-control-border: #ddd7cf;
    --curated-filter-control-text: #1f2328;

    --curated-filter-focus-border:
            rgba(var(--site-french-blue-rgb), 0.78);

    --curated-filter-focus-ring:
            0 0 0 0.18rem rgba(var(--site-french-blue-rgb), 0.18);

    --curated-filter-menu-shadow:
            0 14px 34px rgba(17, 17, 17, 0.10);

    --curated-filter-link-color:
            var(--site-brand-olive);

    --curated-filter-link-hover-rgb: 36, 38, 41;

    --curated-filter-link-hover-color:
            rgb(var(--curated-filter-link-hover-rgb));

    --curated-filter-link-decoration:
            rgba(var(--site-brand-olive-rgb), 0.35);

    --curated-filter-link-hover-decoration:
            rgba(var(--curated-filter-link-hover-rgb), 0.55);

    --town-menu-action-color: #5f7f92;
    --town-menu-action-hover-color: #173f73;
    --town-menu-action-separator-color: #a3a656;
}

.curated-town-dropdown-menu .town-menu-action,
.results-town-dropdown-menu .town-menu-action,
.lifestyle-details-dropdown-menu .town-menu-action {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--town-menu-action-color) !important;
    font: inherit;
    font-weight: 600;
    padding: 0;
    text-decoration: none;
}

.curated-town-dropdown-menu .town-menu-action:hover,
.curated-town-dropdown-menu .town-menu-action:focus-visible,
.results-town-dropdown-menu .town-menu-action:hover,
.results-town-dropdown-menu .town-menu-action:focus-visible,
.lifestyle-details-dropdown-menu .town-menu-action:hover,
.lifestyle-details-dropdown-menu .town-menu-action:focus-visible {
    color: var(--town-menu-action-hover-color) !important;
    text-decoration: underline;
}

.curated-town-dropdown-menu .town-menu-action-separator,
.results-town-dropdown-menu .town-menu-action-separator {
    color: var(--town-menu-action-separator-color) !important;
    font-size: 0.68rem;
    font-weight: 700;
}

@media (max-width: 767.98px) {
    .curated-town-menu-grid {
        grid-template-columns: 1fr;
    }

    .results-town-dropdown-menu {
        min-width: 100%;
    }
}


/*
==============================================================================
 SITEWIDE LISTING SHELF — HORIZONTAL PRESENTATION

 PURPOSE
 - Places one responsive listing shelf between the shared crest/header and each
   page's main heading.
 - Preserves visually balanced breathing room above and below the shelf.
 - Uses native horizontal scrolling and CSS scroll snap before JavaScript.
 - Reuses the existing result-card markup and visual system.
==============================================================================
*/

:root {
    --sitewide-listing-shelf-space-before:
            clamp(1.5rem, 2.5vw, 2.75rem);
    --sitewide-listing-shelf-space-after:
            clamp(1.25rem, 2.25vw, 2.5rem);
    --sitewide-listing-shelf-inline-space:
            clamp(1rem, 3vw, 2.75rem);
    --sitewide-listing-shelf-card-width:
            clamp(19rem, 34vw, 31rem);
    --sitewide-listing-shelf-corner-radius: 0.3rem;
}

.sitewide-listing-shelf {
    width: min(100% - 2rem, 1440px);
    margin-top: var(--sitewide-listing-shelf-space-before);
    margin-right: auto;
    margin-bottom: var(--sitewide-listing-shelf-space-after);
    margin-left: auto;
    padding: clamp(1.15rem, 2vw, 1.75rem)
             var(--sitewide-listing-shelf-inline-space);
    background: #f3f0df;
    border-top: 1px solid rgba(1, 22, 64, 0.1);
    border-bottom: 1px solid rgba(1, 22, 64, 0.1);
}

.sitewide-listing-shelf__intro {
    display: grid;
    gap: 0.4rem;
    margin-bottom: 0.85rem;
}

.sitewide-listing-shelf__title {
    margin: 0;
    color: #263d18;
    font-size: clamp(1.35rem, 2.2vw, 2.1rem);
    font-weight: 900;
    letter-spacing: -0.025em;
    line-height: 1.05;
}

.sitewide-listing-shelf__summary {
    max-width: 62rem;
    margin: 0;
    color: #011640;
    font-size: clamp(0.9rem, 1.1vw, 1rem);
    line-height: 1.5;
}

.sitewide-listing-shelf__preview-label {
    justify-self: start;
    padding: 0.2rem 0.5rem;
    color: #5a5621;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(109, 105, 40, 0.28);
    border-radius: 0.2rem;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.sitewide-listing-shelf__category-links,
.sitewide-listing-shelf__town-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.9rem;
}

.sitewide-listing-shelf__category-links {
    margin-bottom: 0.55rem;
}

.sitewide-listing-shelf__town-links {
    margin-bottom: 1rem;
}

.sitewide-listing-shelf__category-links a,
.sitewide-listing-shelf__town-links a {
    color: #2f3f13;
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1.35;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2rem;
}

.sitewide-listing-shelf__viewport {
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.15rem 0 0.75rem;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-color: rgba(38, 61, 24, 0.55) rgba(1, 22, 64, 0.08);
    scrollbar-width: thin;
}

.sitewide-listing-shelf__viewport:focus-visible {
    outline: 3px solid rgba(47, 63, 19, 0.55);
    outline-offset: 0.35rem;
}

.sitewide-listing-shelf__track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: var(--sitewide-listing-shelf-card-width);
    gap: clamp(0.75rem, 1.5vw, 1.15rem);
    width: max-content;
}

.sitewide-listing-shelf__item {
    min-width: 0;
    scroll-snap-align: start;
}

.sitewide-listing-shelf__item .result-card-shell,
.sitewide-listing-shelf__item .result-card {
    height: 100%;
}

.sitewide-listing-shelf__item .result-card {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(1, 22, 64, 0.14);
    border-radius: var(--sitewide-listing-shelf-corner-radius);
    box-shadow: 0 0.45rem 1.25rem rgba(1, 22, 64, 0.08);
}

.sitewide-listing-shelf__item .result-card-media {
    min-height: 13rem;
}

.sitewide-listing-shelf__item .result-card-media img {
    display: block;
    width: 100%;
    height: 13rem;
    object-fit: cover;
}

.sitewide-listing-shelf__item .result-card-content-grid {
    grid-template-columns: minmax(0, 1fr);
}

.sitewide-listing-shelf__item .result-card-content-links {
    padding-top: 0.85rem;
    border-top: 1px solid rgba(1, 22, 64, 0.1);
}

@media (max-width: 700px) {
    :root {
        --sitewide-listing-shelf-card-width:
                min(82vw, 22rem);
    }

    .sitewide-listing-shelf {
        width: min(100% - 1rem, 1440px);
        padding-right: 0.85rem;
        padding-left: 0.85rem;
    }

    .sitewide-listing-shelf__category-links,
    .sitewide-listing-shelf__town-links {
        gap: 0.4rem 0.7rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sitewide-listing-shelf__viewport {
        scroll-behavior: auto;
    }
}


/*
==============================================================================
 SITEWIDE LISTING SHELF — CLEAN HEADER AND CONTROLS

 PURPOSE
 - Removes visual clutter above the cards.
 - Uses the selected full-opacity pink background.
 - Keeps Previous and Next visible on desktop, tablet and mobile.
 - Preserves current card height for this visual pass.
==============================================================================
*/

:root {
    --sitewide-listing-shelf-background: #FFE9DE;
}

.sitewide-listing-shelf {
    background: var(--sitewide-listing-shelf-background);
    opacity: 1;
}

.sitewide-listing-shelf__header {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1.25rem;
    margin-bottom: clamp(0.9rem, 1.5vw, 1.25rem);
}

.sitewide-listing-shelf__intro {
    flex: 1 1 auto;
    margin-bottom: 0;
}

.sitewide-listing-shelf__controls {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 0.55rem;
}

.sitewide-listing-shelf__control {
    min-height: 2.6rem;
    padding: 0.55rem 0.85rem;
    color: #263d18;
    background: #ffffff;
    border: 1px solid rgba(38, 61, 24, 0.35);
    border-radius: 0.25rem;
    font: inherit;
    font-size: 0.84rem;
    font-weight: 850;
    line-height: 1;
    cursor: pointer;
}

.sitewide-listing-shelf__control:hover:not(:disabled) {
    color: #ffffff;
    background: #263d18;
}

.sitewide-listing-shelf__control:focus-visible {
    outline: 3px solid rgba(1, 22, 64, 0.5);
    outline-offset: 0.2rem;
}

.sitewide-listing-shelf__control:disabled {
    opacity: 0.42;
    cursor: not-allowed;
}

@media (max-width: 700px) {
    .sitewide-listing-shelf__header {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        gap: 0.8rem;
    }

    .sitewide-listing-shelf__controls {
        display: flex;
        width: 100%;
        justify-content: space-between;
    }

    .sitewide-listing-shelf__control {
        min-width: 7.25rem;
    }
}

/*
==============================================================================
 SITEWIDE LISTING SHELF — UNIFIED COLOR SURFACES

 PURPOSE
 - Keeps the shelf, listing-card body, missing-image surface and controls within
   one cohesive color field.
 - Real listing photographs remain fully visible above the pink fallback.
 - search.css remains the single styling source of truth.

 HOW TO CHANGE THE COLOR
 - Edit only --sitewide-listing-shelf-background.
==============================================================================
*/

:root {
    --sitewide-listing-shelf-background: #FFE9DE;
    --sitewide-listing-shelf-card-background:
            var(--sitewide-listing-shelf-background);
}

.sitewide-listing-shelf,
.sitewide-listing-shelf__item .result-card,
.sitewide-listing-shelf__item .result-card-body,
.sitewide-listing-shelf__item .result-card-media,
.sitewide-listing-shelf__item .result-card-media img,
.sitewide-listing-shelf__control {
    background-color: var(--sitewide-listing-shelf-card-background);
}

.sitewide-listing-shelf__item .result-card-media {
    position: relative;
}

.sitewide-listing-shelf__item .result-card-media img {
    position: relative;
    z-index: 1;
}

.sitewide-listing-shelf__item .result-card-media img[hidden] {
    display: none;
}

/* One fallback declaration for the existing shelf error handler and all shared
   cards whose Java view model already knows that no photograph was supplied. */
.sitewide-listing-shelf__item
.result-card-media.sitewide-listing-shelf__media--unavailable,
.result-card-media.result-card-media--unavailable {
    background-color: var(--sitewide-listing-shelf-card-background);
}

.sitewide-listing-shelf__control:hover:not(:disabled) {
    color: #ffffff;
    background-color: #263d18;
}
