:root {
  --parchment: #EFE6D6;
  --parchment-dark: #E4D8C2;
  --ink: #2E2318;
  --saddle: #6B4226;
  --saddle-dark: #4E301B;
  --hunter: #445840;
  --brass: #B8874B;
  --brass-light: #D4A868;
  --barn-red: #8B3A2E;
  --line: rgba(46, 35, 24, 0.14);
  --card-bg: #F7F1E6;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--parchment);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: 'Fraunces', serif; font-weight: 600; margin: 0; letter-spacing: -0.01em; }

.eyebrow {
  font-family: 'Space Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--saddle);
  font-weight: 700;
}

a { color: inherit; text-decoration: none; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 32px; }

/* ---------- Header ---------- */
header.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(239, 230, 214, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 32px; max-width: 1120px; margin: 0 auto;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo svg { width: 30px; height: 30px; flex-shrink: 0; }
.logo-text { font-family: 'Fraunces', serif; font-weight: 600; font-size: 1.15rem; line-height: 1.1; }
.logo-text span {
  display: block; font-family: 'Space Mono', monospace; font-size: 0.62rem;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--saddle);
  font-weight: 400; margin-top: 2px;
}
nav.main-nav { display: flex; align-items: center; gap: 28px; }
nav.main-nav a { font-size: 0.9rem; font-weight: 500; color: var(--ink); opacity: 0.75; transition: opacity 0.15s ease; }
nav.main-nav a:hover, nav.main-nav a.active { opacity: 1; }

.header-search-row {
  display: flex; justify-content: flex-end;
  padding: 10px 32px; max-width: 1120px; margin: 0 auto;
  border-top: 1px solid var(--line);
}
.header-search {
  display: flex; align-items: center; gap: 6px;
  background: var(--parchment-dark); border: 1px solid var(--line); border-radius: 20px;
  padding: 6px 6px 6px 14px;
}
.header-search input {
  border: none; background: transparent; font-family: 'Inter', sans-serif;
  font-size: 0.85rem; color: var(--ink); width: 160px; outline: none;
}
.header-search input::placeholder { color: rgba(46,35,24,0.5); }
.header-search button {
  border: none; background: var(--saddle); color: var(--parchment);
  width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0; transition: background 0.15s ease;
}
.header-search button:hover { background: var(--saddle-dark); }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 0.92rem; padding: 11px 22px; border-radius: 3px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  white-space: nowrap; cursor: pointer; border: none; font-family: inherit;
}
.btn-primary { background: transparent; color: var(--saddle); border: 1.5px solid var(--brass); letter-spacing: 0.02em; }
.btn-primary:hover { background: var(--brass); color: var(--parchment); transform: translateY(-1px); box-shadow: 0 6px 16px rgba(184,135,75,0.28); }
.btn-outline { border: 1.5px solid var(--ink); color: var(--ink); opacity: 0.85; background: transparent; }
.btn-outline:hover { opacity: 1; background: rgba(46,35,24,0.05); }
.btn-solid { background: var(--saddle); color: var(--parchment); }
.btn-solid:hover { background: var(--saddle-dark); transform: translateY(-1px); }
.btn-lg { padding: 14px 28px; font-size: 0.98rem; }
.btn-sm { padding: 8px 16px; font-size: 0.82rem; }

/* ---------- Hero / page header ---------- */
.hero {
  position: relative; padding: 72px 32px 64px; overflow: hidden; border-bottom: 1px solid var(--line);
}
.hero-topo { position: absolute; inset: 0; z-index: 0; opacity: 0.5; }
.hero-content { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; text-align: center; }
.hero h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); margin: 18px 0 20px; line-height: 1.08; max-width: 18ch; margin-left: auto; margin-right: auto; }
.hero p.sub { max-width: 58ch; margin: 0 auto 30px; font-size: 1.02rem; line-height: 1.7; color: rgba(46,35,24,0.78); }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Hero with photo (two-column layout) ---------- */
.hero-grid {
  position: relative; z-index: 1; max-width: 1120px; margin: 0 auto;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center;
  text-align: left;
}
.hero-grid .hero-text { text-align: left; }
.hero-grid .search-panel { margin: 0; max-width: 100%; }
.hero-image-frame {
  border-radius: 10px; overflow: hidden; border: 2px solid var(--brass);
  box-shadow: 0 16px 40px rgba(46,35,24,0.18);
}
.hero-image-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-grid .hero-text { text-align: center; }
  .hero-image-frame { order: -1; max-width: 480px; margin: 0 auto; }
}

/* ---------- Search / filter bar ---------- */
.search-panel {
  max-width: 880px; margin: 0 auto; background: var(--card-bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 22px;
  display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end;
  box-shadow: 0 8px 24px rgba(46,35,24,0.06);
}
.search-field { flex: 1; min-width: 160px; text-align: left; }
.search-field label {
  display: block; font-family: 'Space Mono', monospace; font-size: 0.68rem;
  text-transform: uppercase; letter-spacing: 0.08em; color: var(--saddle); margin-bottom: 6px;
}
.search-field select, .search-field input {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px;
  background: var(--parchment); font-family: 'Inter', sans-serif; font-size: 0.9rem; color: var(--ink);
}
.search-field select:focus, .search-field input:focus { outline: 2px solid var(--brass); outline-offset: 1px; }

/* ---------- Stat strip ---------- */
.stat-strip {
  text-align: center; padding: 28px 32px; font-family: 'Space Mono', monospace;
  font-size: 0.85rem; color: var(--saddle); border-bottom: 1px solid var(--line);
}
.stat-strip strong { color: var(--ink); }

/* ---------- Sections ---------- */
section.page-section { padding: 64px 32px; border-bottom: 1px solid var(--line); }
section.page-section.alt { background: var(--parchment-dark); }
.section-head { max-width: 1120px; margin: 0 auto 40px; text-align: center; }
.section-head h2 { font-size: clamp(1.5rem, 2.8vw, 2rem); margin: 14px 0 0; }
.section-head p { max-width: 52ch; margin: 12px auto 0; color: rgba(46,35,24,0.72); }

/* ---------- Category / neighborhood grids ---------- */
.grid-3 { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }

.cat-card {
  background: var(--card-bg); border: 1px solid var(--line); border-radius: 6px;
  padding: 28px 24px; transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  display: flex; flex-direction: column; gap: 12px;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(46,35,24,0.09); border-color: var(--brass); }
.cat-card h3 { font-size: 1.1rem; }
.cat-card p { margin: 0; font-size: 0.9rem; color: rgba(46,35,24,0.68); flex-grow: 1; }
.cat-count { font-family: 'Space Mono', monospace; font-size: 0.72rem; color: var(--brass); text-transform: uppercase; letter-spacing: 0.06em; }

.hood-card {
  background: var(--card-bg); border: 1px solid var(--line); border-radius: 6px;
  padding: 20px; text-align: center; transition: transform 0.18s ease, border-color 0.18s ease;
}
.hood-card:hover { transform: translateY(-2px); border-color: var(--brass); }
.hood-card h3 { font-size: 0.98rem; margin-bottom: 4px; }

/* ---------- Listing cards ---------- */
.listing-card {
  background: var(--card-bg); border: 1px solid var(--line); border-radius: 6px;
  padding: 24px; margin-bottom: 16px;
}
.listing-card .tag-row { display: flex; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.tag {
  font-family: 'Space Mono', monospace; font-size: 0.68rem; text-transform: uppercase;
  letter-spacing: 0.05em; padding: 3px 8px; border-radius: 3px; background: var(--parchment-dark); color: var(--saddle);
}
.listing-card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.listing-card p.desc { margin: 0 0 12px; color: rgba(46,35,24,0.75); font-size: 0.92rem; }
.listing-meta { font-size: 0.85rem; color: rgba(46,35,24,0.65); display: flex; gap: 18px; flex-wrap: wrap; }

/* ---------- Empty state ---------- */
.empty-state {
  max-width: 1120px; margin: 0 auto; text-align: center; padding: 48px 32px;
  border: 1.5px dashed rgba(46,35,24,0.3); border-radius: 8px; background: rgba(247,241,230,0.5);
}
.empty-state h3 { font-size: 1.2rem; margin-bottom: 10px; }
.empty-state p { color: rgba(46,35,24,0.68); max-width: 46ch; margin: 0 auto 22px; }

/* ---------- Steps ---------- */
.steps-grid { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.step { text-align: center; }
.step .step-num {
  width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--brass);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 16px;
  font-family: 'Fraunces', serif; font-weight: 600; color: var(--saddle);
}
.step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { font-size: 0.9rem; color: rgba(46,35,24,0.68); margin: 0; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 780px; margin: 0 auto; }
.faq-item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq-item summary { font-family: 'Fraunces', serif; font-weight: 600; font-size: 1rem; cursor: pointer; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before { content: "+ "; color: var(--brass); font-weight: 700; }
.faq-item[open] summary::before { content: "– "; }
.faq-item p { margin: 12px 0 0; color: rgba(46,35,24,0.72); font-size: 0.92rem; }

/* ---------- CTA band ---------- */
.cta-band { padding: 60px 32px; text-align: center; }
.cta-band h2 { font-size: clamp(1.4rem, 2.6vw, 1.8rem); margin-bottom: 12px; }
.cta-band p { max-width: 48ch; margin: 0 auto 26px; color: rgba(46,35,24,0.72); }

/* ---------- Forms ---------- */
.form-card {
  max-width: 640px; margin: 0 auto; background: var(--card-bg); border: 1px solid var(--line);
  border-radius: 8px; padding: 36px;
}
.form-row { margin-bottom: 18px; }
.form-row label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; }
.form-row .hint { font-size: 0.78rem; color: rgba(46,35,24,0.55); margin-top: 4px; }
.form-row input, .form-row select, .form-row textarea {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 4px;
  background: var(--parchment); font-family: 'Inter', sans-serif; font-size: 0.92rem; color: var(--ink);
}
.form-row input:focus, .form-row select:focus, .form-row textarea:focus { outline: 2px solid var(--brass); outline-offset: 1px; }
/* Checkboxes and radios should never inherit the full-width text-input styling
   above — without this, a checkbox's actual clickable box stretches to fill
   its container while the small visible square stays pinned to one side,
   pushing any sibling label text away from it. */
.form-row input[type="checkbox"], .form-row input[type="radio"] {
  width: auto; padding: 0; border: none; background: none; flex-grow: 0; flex-shrink: 0;
}
.form-row textarea { resize: vertical; min-height: 100px; }
.form-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.alert-success {
  max-width: 640px; margin: 0 auto; background: rgba(68,88,64,0.1); border: 1.5px solid var(--hunter);
  border-radius: 6px; padding: 22px 24px; text-align: center;
}
.alert-success h3 { color: var(--hunter); margin-bottom: 8px; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { max-width: 1120px; margin: 0 auto; padding: 20px 32px 0; font-size: 0.85rem; color: rgba(46,35,24,0.6); }
.breadcrumb a { color: var(--saddle); }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- Rich text post content ---------- */
.post-body p { margin: 0 0 10px; }
.post-body p:empty { display: none; }
.post-body p:has(> br:only-child) { display: none; }

.post-body h1, .post-body h2, .post-body h3 { margin: 28px 0 14px; }
.post-body ul, .post-body ol { margin: 0 0 18px; padding-left: 28px; }
.post-body li { margin-bottom: 6px; }
.post-body blockquote {
  margin: 20px 0; padding: 4px 20px; border-left: 3px solid var(--brass);
  color: rgba(46,35,24,0.68); font-style: italic;
}
.post-body a { color: var(--saddle); text-decoration: underline; }
.post-body strong { font-weight: 700; }
.post-body em { font-style: italic; }
.post-body u { text-decoration: underline; }
.post-body table { width: 100%; border-collapse: collapse; margin: 24px 0; }
.post-body th, .post-body td { text-align: left; vertical-align: top; padding: 10px 16px 10px 0; }
.post-body thead th { font-family: 'Fraunces', serif; border-bottom: 2px solid var(--saddle); }
.post-body tbody tr { border-bottom: 1px solid var(--line); }
.post-body tbody tr:last-child { border-bottom: none; }

/* ---------- Prose (about/privacy/terms) ---------- */
.prose { max-width: 720px; margin: 0 auto; padding: 56px 32px; }
.prose h2 { margin-top: 36px; margin-bottom: 12px; font-size: 1.3rem; }
.prose p { color: rgba(46,35,24,0.78); line-height: 1.75; margin-bottom: 16px; }
.prose ul { color: rgba(46,35,24,0.78); line-height: 1.75; }

/* ---------- Footer ---------- */
footer.site-footer { border-top: 1px solid var(--line); padding: 48px 32px 32px; }
.footer-grid { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; margin-bottom: 32px; }
.footer-grid h4 { font-family: 'Space Mono', monospace; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--saddle); margin-bottom: 14px; }
.footer-grid p { font-size: 0.88rem; color: rgba(46,35,24,0.65); max-width: 32ch; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer-grid a { font-size: 0.88rem; color: rgba(46,35,24,0.7); }
.footer-grid a:hover { color: var(--ink); }
.footer-bottom {
  max-width: 1120px; margin: 0 auto; padding-top: 24px; border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  font-family: 'Space Mono', monospace; font-size: 0.75rem; color: rgba(46,35,24,0.55);
}
.footer-bottom a { color: rgba(46,35,24,0.55); }
.footer-bottom a:hover { color: var(--ink); }
.social-icon {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--parchment-dark); color: var(--saddle);
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.social-icon:hover { background: var(--brass); color: var(--parchment); transform: translateY(-2px); }

@media (max-width: 900px) {
  .grid-3, .form-two-col { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: 1fr; }
  nav.main-nav { display: none; }
  .header-search-row { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .search-panel { flex-direction: column; align-items: stretch; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; }
