/* ==========================================================
   A&A Associate — design tokens
   Warm, grounded palette on white: deep teal-green (trust,
   land) paired with a warm gold accent (the friendly, cafe-
   like ambience). Fraunces for character in headings,
   Work Sans for calm, legible body/UI text.
   ========================================================== */
:root {
    --bg: #FFFFFF;
    --surface: #F7F5F0;
    --surface-alt: #F1EDE3;
    --ink: #20241F;
    --ink-soft: #565A50;
    --primary: #2F5D50;
    --primary-dark: #21453B;
    --accent: #C9922B;
    --accent-dark: #A87A22;
    --border: #E3E0D6;
    --sold: #B54B3A;
    --available: #2F5D50;
    --rented: #8A7A3E;
    --radius: 6px;
    --shadow: 0 1px 3px rgba(32, 36, 31, 0.08);
    --max-width: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: 'Work Sans', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: 'Fraunces', Georgia, serif;
    color: var(--ink);
    margin: 0 0 0.5em;
    line-height: 1.2;
    font-weight: 600;
}

h1 { font-size: clamp(2rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; color: var(--ink-soft); max-width: 65ch; }

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

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

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Buttons */
.btn {
    display: inline-block;
    background: var(--primary);
    color: #fff;
    padding: 12px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    font-family: inherit;
    transition: background 0.15s ease;
}
.btn:hover { background: var(--primary-dark); color: #fff; text-decoration: none; }
.btn-accent { background: var(--accent); }
.btn-accent:hover { background: var(--accent-dark); }
.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 1.5px solid var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-whatsapp { background: #2F5D50; }
.btn-block { width: 100%; text-align: center; }

/* Site header */
.site-header {
    border-bottom: 1px solid var(--border);
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 50;
}
.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    max-width: var(--max-width);
    margin: 0 auto;
}
.site-brand {
    font-family: 'Fraunces', Georgia, serif;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--ink);
}
.site-brand span { color: var(--accent); }
.site-nav { display: flex; gap: 28px; align-items: center; }
.site-nav a { color: var(--ink); font-weight: 500; }
.site-nav a:hover { color: var(--primary); text-decoration: none; }
.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: var(--ink);
}

/* Hero */
.hero {
    padding: 64px 0 56px;
}
.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: center;
}
.hero-eyebrow-free {
    color: var(--accent-dark);
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
}
.hero p.lead { font-size: 1.1rem; max-width: 48ch; }
.hero-actions { display: flex; gap: 14px; margin-top: 24px; flex-wrap: wrap; }
.hero-photo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.hero-photo-grid img {
    border-radius: var(--radius);
    object-fit: cover;
    width: 100%;
    height: 100%;
}
.hero-photo-grid .tall { grid-row: span 2; height: 100%; aspect-ratio: 3/4; object-fit: cover; }
.hero-photo-grid img:not(.tall) { aspect-ratio: 4/3; }

/* Section spacing */
.section { padding: 56px 0; }
.section-alt { background: var(--surface); }
.section-head { margin-bottom: 32px; }
.section-head p { margin: 0; }

/* Property grid + card */
.property-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}
.property-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.property-photo-wrap { position: relative; aspect-ratio: 4/3; background: var(--surface-alt); }
.property-photo-wrap img { width: 100%; height: 100%; object-fit: cover; }
.property-tag {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #fff;
}
.property-tag.Sold, .property-tag.Rented { background: var(--sold); }
.property-tag.Available { background: var(--primary); }
.property-body { padding: 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.property-body h3 { margin: 0; }
.property-body h3 a { color: var(--ink); }
.property-body h3 a:hover { color: var(--primary); }
.property-facts {
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-top: 1px solid var(--border);
    padding-top: 10px;
    font-size: 0.92rem;
}
.property-facts .fact { display: flex; gap: 8px; }
.property-facts .fact-label { color: var(--ink-soft); min-width: 64px; }
.property-facts .fact-value { color: var(--ink); font-weight: 500; }
.property-price { font-size: 1.15rem; font-weight: 600; color: var(--primary-dark); font-family: 'Fraunces', serif; }
.property-actions { margin-top: auto; display: flex; gap: 10px; padding-top: 6px; flex-wrap: wrap; }
.property-actions .btn { flex: 1; text-align: center; padding: 10px 14px; font-size: 0.9rem; }
.property-select {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px 0;
    font-size: 0.9rem;
    color: var(--ink-soft);
}

/* Filters bar */
.filters-bar {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 28px;
    background: var(--surface);
    padding: 16px;
    border-radius: var(--radius);
}
.filters-bar select, .filters-bar input {
    padding: 9px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 0.92rem;
    background: #fff;
}

/* Sticky inquiry bar */
.inquiry-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--primary);
    color: #fff;
    padding: 14px 20px;
    display: none;
    align-items: center;
    justify-content: space-between;
    z-index: 60;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.15);
}
.inquiry-bar.active { display: flex; }
.inquiry-bar-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.inquiry-bar strong { font-family: 'Fraunces', serif; }
.inquiry-bar .btn { background: #fff; color: var(--primary-dark); }
.inquiry-bar .btn:hover { background: var(--surface); }
.inquiry-clear { color: #fff; text-decoration: underline; font-size: 0.9rem; background:none; border:none; cursor:pointer; font-family: inherit; }

/* Detail page */
.detail-grid {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 40px;
    align-items: start;
}
.detail-gallery img { border-radius: var(--radius); margin-bottom: 10px; aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.detail-gallery-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.detail-gallery-thumbs img { aspect-ratio: 1/1; cursor: pointer; opacity: 0.85; }
.detail-gallery-thumbs img:hover { opacity: 1; }
.detail-facts { background: var(--surface); border-radius: var(--radius); padding: 20px; margin: 20px 0; }
.detail-facts .fact { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--border); }
.detail-facts .fact:last-child { border-bottom: none; }
.detail-actions { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 90px; }
.detail-actions .btn { width: 100%; text-align: center; }

/* Forms */
.card-form {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 24px;
}
.card-form label, .admin-form label {
    display: block;
    font-weight: 600;
    margin: 14px 0 6px;
    font-size: 0.92rem;
}
.card-form label:first-child, .admin-form label:first-child { margin-top: 0; }
.card-form input, .card-form select, .card-form textarea,
.admin-form input, .admin-form select, .admin-form textarea {
    width: 100%;
    padding: 11px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 0.95rem;
    background: #fff;
}
.card-form textarea, .admin-form textarea { resize: vertical; }
.field-hint { font-size: 0.82rem; color: var(--ink-soft); margin: 4px 0 0; }

.confirmation-box {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center;
}
.confirmation-box h2 { color: var(--primary-dark); }

/* Office info */
.office-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
}
.office-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 22px;
}
.office-card h3 { margin-bottom: 8px; font-size: 1.05rem; }
.office-card p { margin: 0; }

/* Footer */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 36px 0;
    margin-top: 40px;
}
.site-footer-inner {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
}
.site-footer p { margin: 0; font-size: 0.9rem; }

/* Notices */
.notice { background: #EAF2EF; color: var(--primary-dark); padding: 12px 16px; border-radius: var(--radius); }
.error { background: #F7E9E6; color: var(--sold); padding: 12px 16px; border-radius: var(--radius); }

/* Mobile responsiveness */
@media (max-width: 860px) {
    .hero-inner { grid-template-columns: 1fr; }
    .hero-photo-grid { order: -1; }
    .detail-grid { grid-template-columns: 1fr; }
    .detail-actions { position: static; }
}

@media (max-width: 640px) {
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        flex-direction: column;
        gap: 0;
        border-bottom: 1px solid var(--border);
    }
    .site-nav.open { display: flex; }
    .site-nav a { padding: 14px 20px; border-top: 1px solid var(--border); width: 100%; }
    .nav-toggle { display: block; }
    .hero { padding: 40px 0; }
    .hero-actions .btn { width: 100%; text-align: center; }
    .section { padding: 40px 0; }
    .inquiry-bar-inner { flex-direction: column; align-items: stretch; text-align: center; }
    body { padding-bottom: 0; }
    .filters-bar { flex-direction: column; }
    .filters-bar select, .filters-bar input { width: 100%; }
}
