/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --green: #1a3a4a;
    --green-dark: #0f2a36;
    --green-light: #2d5a6b;
    --gold: #d4a843;
    --text: #333;
    --text-light: #666;
    --bg-light: #f8f7f4;
    --white: #fff;
    --shadow: 0 2px 12px rgba(0,0,0,0.1);
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Montserrat', -apple-system, sans-serif;
}

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-sans);
    color: var(--text);
    line-height: 1.7;
    background: var(--white);
}

a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-dark); }

img { max-width: 100%; display: block; }

.container { max-width: 900px; margin: 0 auto; padding: 0 24px; }
.center { text-align: center; }

/* ===== NAVIGATION ===== */
#site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--white);
    box-shadow: 0 1px 6px rgba(0,0,0,0.12);
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 32px;
    max-width: 1200px;
    margin: 0 auto;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.nav-logo img { height: 80px; width: auto; }

.nav-name {
    font-family: var(--font-serif);
    font-size: 1.1rem;
    color: var(--text);
    font-weight: 400;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 28px;
    align-items: center;
}

.nav-links a {
    font-size: 0.92rem;
    font-weight: 400;
    color: var(--text);
    letter-spacing: 0.02em;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
    transition: color 0.2s, border-color 0.2s;
    cursor: pointer;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--green);
    border-bottom-color: var(--green);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: all 0.3s;
}

/* ===== PAGE SECTIONS ===== */
.page { display: none; }
.page.active { display: block; }

.section { padding: 60px 0; }

.section-title {
    font-family: var(--font-serif);
    font-size: 2.2rem;
    font-weight: 400;
    color: var(--text);
    margin-bottom: 32px;
}

/* ===== HERO ===== */
.hero {
    position: relative;
    height: 520px;
    overflow: visible;
    display: flex;
    align-items: center;
}

.hero-bg, video.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.35);
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 60px;
    color: var(--white);
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 2.6rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-shadow: 0 2px 8px rgba(0,0,0,0.4);
    margin-bottom: 8px;
}

.hero-subtitle {
    font-size: 1.2rem;
    font-style: italic;
    letter-spacing: 0.08em;
    text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.hero-logo-box {
    position: absolute;
    bottom: -40px;
    left: 60px;
    z-index: 3;
    background: var(--white);
    padding: 12px;
    border: 4px solid #000;
    width: 280px;
}

.hero-logo-box img { width: 100%; }

.hero-photo-box {
    position: absolute;
    right: 80px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    border: 6px solid #000;
    width: 240px;
    height: 260px;
    overflow: visible;
    background: #ccc;
}

.hero-photo-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

/* ===== MEET DIANE ===== */
.meet-diane { background: var(--bg-light); padding-top: 100px; }

.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: flex-start;
}

.col-text p { margin-bottom: 16px; color: var(--text-light); }

.col-image img {
    border-radius: 4px;
    box-shadow: var(--shadow);
}

/* ===== TESTIMONIALS ===== */
.testimonials-section { background: var(--white); }

.testimonial-slider { position: relative; overflow: visible; }

.testimonial-track {
    display: flex;
    transition: transform 0.4s ease;
}

.testimonial-card {
    min-width: 100%;
    padding: 32px 48px;
    background: var(--bg-light);
    border-radius: 8px;
}

.testimonial-card h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    color: var(--green);
    margin-bottom: 8px;
}

.testimonial-headline {
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text);
}

.testimonial-card p { color: var(--text-light); }

.slider-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 20px;
}

.slider-btn {
    background: none;
    border: 1px solid var(--green);
    color: var(--green);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s;
}

.slider-btn:hover { background: var(--green); color: var(--white); }

.slider-dots { display: flex; gap: 8px; }

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ccc;
    cursor: pointer;
    transition: background 0.2s;
}

.dot.active { background: var(--green); }

/* ===== PASSION BANNER ===== */
.passion-banner {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
}

.passion-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    position: absolute;
    top: 0; left: 0;
}

.passion-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.25);
}

.passion-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: var(--white);
    z-index: 2;
}

.passion-subtitle {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    font-style: italic;
    letter-spacing: 0.1em;
    margin-bottom: 4px;
    opacity: 0.9;
}

.passion-title {
    font-family: var(--font-serif);
    font-size: 3.5rem;
    font-weight: 400;
    font-style: italic;
    letter-spacing: 0.02em;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* ===== CTA ===== */
.cta-section { background: var(--bg-light); padding: 40px 0; }
.cta-section .section-title { margin-bottom: 16px; }

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 4px 32px;
    border-radius: 4px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    letter-spacing: 0.03em;
}

.btn-primary {
    background: var(--green);
    color: var(--white);
}

.btn-primary:hover { background: var(--green-dark); color: var(--white); }

.btn-search {
    background: var(--green);
    color: var(--white);
    padding: 10px 28px;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    border: none;
    transition: background 0.2s;
}

.btn-search:hover { background: var(--green-dark); }

/* ===== FEATURED LISTINGS ===== */
.filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: flex-end;
    background: var(--bg-light);
    padding: 20px 24px;
    border-radius: 6px;
    margin-bottom: 20px;
    border: 1px solid #e0ddd8;
}

.filter-group { display: flex; flex-direction: column; gap: 6px; }
.filter-group label { font-size: 0.82rem; color: var(--text-light); font-weight: 600; }

.radio-group {
    display: flex;
    gap: 16px;
    align-items: center;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--text);
    cursor: pointer;
}

.filters-bar select {
    padding: 8px 32px 8px 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9rem;
    background: var(--white);
    color: var(--text);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23666' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    min-width: 110px;
}

.results-count {
    font-size: 0.88rem;
    color: var(--text-light);
    margin-bottom: 24px;
}

.results-count span { font-weight: 700; color: var(--text); }

.listings-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.listings-loading {
    grid-column: 1 / -1;
    text-align: center;
    padding: 48px 16px;
    color: var(--text-light, #6b6b6b);
    font-size: 1rem;
}

.listing-card {
    background: var(--white);
    border: 1px solid #e8e5e0;
    border-radius: 6px;
    overflow: visible;
    transition: box-shadow 0.2s, transform 0.2s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.listing-card:hover {
    box-shadow: 0 6px 24px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.listing-img-wrap {
    position: relative;
    height: 200px;
    overflow: visible;
    background: #e0ddd8;
}

.listing-img-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.listing-card:hover .listing-img-wrap img { transform: scale(1.04); }

.listing-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 12px;
    border-radius: 3px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--white);
}

.badge-sold { background: rgba(60,60,60,0.85); }
.badge-rented { background: rgba(74,124,89,0.9); }
.badge-active { background: rgba(44,95,45,0.9); }

.listing-info { padding: 16px; display: flex; flex-direction: column; flex: 1; }

.listing-agent { font-size: 0.75rem; color: #64748b; margin-top: auto; padding-top: 8px; }

.listing-price {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    color: var(--text);
    margin-bottom: 6px;
}

.listing-address {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 14px;
    line-height: 1.4;
}

.listing-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    border-top: 1px solid #eee;
    padding-top: 12px;
}

.stat-label {
    font-size: 0.72rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.stat-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text);
}

/* ===== SEARCH PAGE ===== */
.search-box {
    max-width: 800px;
    margin: 0 auto;
    background: var(--bg-light);
    padding: 40px;
    border-radius: 8px;
}

.search-box p { color: var(--text-light); margin-bottom: 24px; }

.search-form {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.search-input, .search-select {
    padding: 10px 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9rem;
    flex: 1;
    min-width: 160px;
}

.search-note { font-size: 0.88rem; color: var(--text-light); }

/* ===== SERVICES ===== */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.service-card {
    background: var(--bg-light);
    padding: 32px 24px;
    border-radius: 8px;
    border-top: 3px solid var(--green);
}

.service-icon { font-size: 2rem; margin-bottom: 12px; }

.service-card h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    margin-bottom: 14px;
    color: var(--green-dark);
}

.service-card p { font-size: 0.92rem; color: var(--text-light); margin-bottom: 10px; }

/* ===== ABOUT PAGE ===== */
.about-tagline {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.3rem;
    color: var(--text-light);
    margin-bottom: 40px;
    font-weight: 400;
}

.about-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 48px;
    align-items: flex-start;
}

.about-photo img {
    width: 100%;
    border-radius: 4px;
    box-shadow: var(--shadow);
}

.about-specialties { margin-bottom: 12px; }

.about-mission-title {
    font-weight: 700;
    color: var(--green);
    margin-bottom: 12px;
}

.about-details p { margin-bottom: 14px; color: var(--text-light); }

.credentials {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 24px 0;
}

.credential-badge {
    background: var(--green);
    color: var(--white);
    padding: 10px 18px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.4;
}

.contact-details { margin-top: 20px; }
.contact-details p { margin-bottom: 6px; }

/* ===== CONTACT PAGE ===== */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 48px;
    align-items: flex-start;
}

.contact-info-block h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--green-dark);
}

.contact-info-block p { margin-bottom: 10px; color: var(--text-light); }

.contact-form h3 {
    font-family: var(--font-serif);
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--green-dark);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.92rem;
    font-family: var(--font-sans);
    margin-bottom: 14px;
    transition: border-color 0.2s;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--green);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.form-row input { margin-bottom: 0; }

.form-success {
    display: none;
    color: var(--green);
    font-weight: 600;
    margin-top: 12px;
}

/* ===== FOOTER ===== */
footer {
    background: var(--green-dark);
    color: rgba(255,255,255,0.85);
    text-align: center;
    padding: 28px 0;
    font-size: 0.88rem;
}

footer p { margin-bottom: 6px; }
footer a { color: rgba(255,255,255,0.75); }
footer a:hover { color: var(--white); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .listings-grid { grid-template-columns: repeat(2, 1fr); }
    .services-grid { grid-template-columns: 1fr; }
    .two-col { grid-template-columns: 1fr; }
    .about-layout { grid-template-columns: 1fr; }
    .contact-layout { grid-template-columns: 1fr; }
    .hero-title { font-size: 2.2rem; }
    .hero-photo-box { width: 150px; height: 170px; right: 30px; }
    .hero-logo-box { width: 140px; left: 30px; }
    .hero-content { padding-right: 200px; }
}

@media (max-width: 640px) {
    .navbar { padding: 12px 16px; }
    .nav-links { display: none; flex-direction: column; position: absolute; top: 70px; left: 0; right: 0; background: var(--white); padding: 20px; box-shadow: var(--shadow); gap: 16px; }
    .nav-links.open { display: flex; }
    .hamburger { display: flex; }
    .listings-grid { grid-template-columns: 1fr; }
    .hero { height: 400px; }
    .hero-title { font-size: 1.8rem; }
    .hero-content { padding: 0 20px; padding-right: 20px; }
    .hero-logo-box { display: none; }
    .hero-photo-box { width: 100px; height: 120px; right: 16px; top: auto; bottom: 20px; transform: none; }
    .filters-bar { flex-direction: column; }
    .form-row { grid-template-columns: 1fr; }
    .search-box { padding: 24px 16px; }
    .testimonial-card { padding: 24px 20px; }
}

/* ===== IDX EMBED ===== */
.idx-container {
    position: relative;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    background: #ffffff;
}

.idx-iframe {
    width: 100%;
    height: 100vh;
    border: none;
    display: block;
}

.idx-loading {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.idx-loading p {
    color: var(--text-light);
    font-size: 0.95rem;
}

.idx-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e0ddd8;
    border-top-color: var(--green);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.idx-fallback {
    text-align: center;
    padding: 60px 24px;
}

.idx-fallback h3 {
    font-family: var(--font-serif);
    color: var(--text);
    margin-bottom: 12px;
}

.idx-fallback p {
    color: var(--text-light);
    margin-bottom: 16px;
}

@media (max-width: 768px) {
    .idx-container, .idx-iframe { min-height: 600px; }
}

/* ===== SEARCH LAUNCH BUTTON ===== */
.btn-search-launch {
    display: inline-block;
    padding: 16px 48px;
    font-size: 1.1rem;
    margin: 24px 0;
}

/* Constrain Meet Diane award image */
.col-image img {
    max-height: 400px;
    width: auto;
    object-fit: contain;
}


/* Constrain hero content and navbar to same max-width as content */
.hero-content {
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

.hero-logo-box {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.hero-photo-box {
    max-width: 900px;
}

.navbar {
    max-width: 900px;
}

/* Align award image with paragraph text */
.col-image {
    margin-top: 48px;
}

/* Hide non-active testimonials, only show focused one */
.testimonial-slider {
    overflow: hidden;
}

.testimonial-card {
    opacity: 0;
    transition: opacity 0.4s ease;
}

.testimonial-card:first-child {
    opacity: 1;
}

/* ===== LISTING DETAIL VIEW ===== */
#listing-detail-view {
    display: none;
}

.detail-back-btn {
    margin-bottom: 24px;
    background: var(--bg-light);
    border: 1px solid #e0ddd8;
    color: var(--text);
    font-weight: 600;
    cursor: pointer;
}

.detail-back-btn:hover {
    background: var(--green);
    color: var(--white);
    border-color: var(--green);
}

.detail-content {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 36px;
    align-items: flex-start;
}

.detail-left {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.detail-gallery {
    border-radius: 8px;
    overflow: hidden;
}

.gallery-main {
    position: relative;
    width: 100%;
    height: 400px;
    background: #e0ddd8;
    overflow: hidden;
}

.gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.5);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.gallery-nav:hover {
    background: rgba(0,0,0,0.75);
}

.gallery-prev { left: 12px; }
.gallery-next { right: 12px; }

.gallery-counter {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(0,0,0,0.6);
    color: var(--white);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.gallery-thumbs {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.gallery-thumb {
    width: 64px;
    height: 48px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s, border-color 0.2s;
    border: 2px solid transparent;
}

.gallery-thumb.active,
.gallery-thumb:hover {
    opacity: 1;
    border-color: var(--green);
}

.detail-gallery-placeholder {
    width: 100%;
    height: 300px;
    background: #e0ddd8;
    border-radius: 8px;
}

.detail-info {
    padding: 8px 0;
}

.detail-price {
    font-family: var(--font-serif);
    font-size: 2rem;
    color: var(--text);
    margin-bottom: 8px;
}

.detail-address {
    font-size: 1.05rem;
    color: var(--text-light);
    margin-bottom: 20px;
    line-height: 1.5;
}

.detail-stats {
    display: flex;
    gap: 24px;
    margin-bottom: 20px;
    padding: 16px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.detail-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.detail-stat-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text);
}

.detail-stat-label {
    font-size: 0.78rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.detail-meta {
    margin-bottom: 20px;
}

.detail-meta-item {
    font-size: 0.92rem;
    color: var(--text-light);
    margin-bottom: 6px;
}

.detail-meta-item strong {
    color: var(--text);
}

.detail-description {
    margin-bottom: 20px;
}

.detail-description h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 8px;
}

.detail-description p {
    font-size: 0.92rem;
    color: var(--text-light);
    line-height: 1.7;
}

.detail-features {
    margin-bottom: 20px;
}

.detail-features h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 8px;
}

.detail-features ul {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.detail-features li {
    background: var(--bg-light);
    padding: 6px 14px;
    border-radius: 4px;
    font-size: 0.88rem;
    color: var(--text);
    border: 1px solid #e0ddd8;
}

.detail-features .features-more {
    background: transparent;
    border: none;
    color: var(--text-light);
    font-style: italic;
    padding: 6px 0;
}

.detail-map {
    margin-top: 0;
}

.detail-map h3 {
    font-family: var(--font-serif);
    font-size: 1.2rem;
    color: var(--text);
    margin-bottom: 12px;
}

.detail-map iframe {
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.detail-error {
    text-align: center;
    padding: 60px 24px;
    color: var(--text-light);
}

.detail-error p {
    margin-bottom: 16px;
}

@media (max-width: 900px) {
    .detail-content {
        grid-template-columns: 1fr;
    }
    .gallery-main {
        height: 300px;
    }
    .detail-features ul {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .gallery-main {
        height: 220px;
    }
    .detail-stats {
        flex-wrap: wrap;
        gap: 16px;
    }
}
