/* ==========================================================================
   Kampreneur — UI styles
   Builds on brand tokens in tokens.css + fonts.css
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  /* Belt-and-braces: prevent any child from causing horizontal scroll. */
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* Contain horizontal overflow so no element creates a scroll at 375px. */
  overflow-x: clip;
}

/* Subtle paper texture via layered gradients — feels like kraft, not noise */
body::before {
  content: '';
  position: fixed; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 0%, rgba(187, 138, 69, 0.04), transparent),
    radial-gradient(ellipse 70% 50% at 100% 100%, rgba(95, 111, 58, 0.03), transparent);
  pointer-events: none;
  z-index: 0;
}

main, header, footer { position: relative; z-index: 1; }

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

a { color: inherit; text-decoration: none; }

/* Focus ring — non-negotiable per BRAND.md */
:focus-visible {
  outline: 2px solid var(--brand-sand);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- Typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--brand-mud);
  margin: 0;
  line-height: 1.08;
}

h1 { font-size: clamp(2rem, 4vw + 1rem, 3.25rem); letter-spacing: 0.04em; }
h2 { font-size: clamp(1.5rem, 2vw + 0.8rem, 2.25rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1rem; }

.kicker {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand-sand);
}

.brush {
  font-family: var(--font-brush);
  font-weight: 400;
  letter-spacing: 0.01em;
  text-transform: none;
}

/* ---------- Container ---------- */

.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 20px;
}

@media (min-width: 768px) {
  .container { padding-inline: 32px; }
}

/* ---------- Nav ---------- */

.topbar {
  background: var(--brand-mud);
  color: var(--brand-lilac);
  font-size: 12px;
  padding: 6px 0;
}
.topbar .container {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.topbar a { color: var(--brand-lilac); opacity: 0.85; }
.topbar a:hover { opacity: 1; }
.topbar .dot { opacity: 0.5; }

.nav {
  background: var(--paper);
  border-bottom: 1px solid var(--stone-300);
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(120%);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px;
  padding: 14px 0;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: 22px;
  letter-spacing: 0.06em;
  font-weight: 700;
  min-width: 0;
}
.logo .k { color: var(--brand-khaki); }
.logo .r { color: var(--brand-mud); }
.logo img { width: 32px; height: 32px; border-radius: 6px; }

.nav-links {
  display: none;
  gap: 28px;
  list-style: none;
  margin: 0; padding: 0;
  font-size: 14px;
  font-weight: 500;
}
.nav-links a {
  color: var(--ink);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: border-color .15s ease, color .15s ease;
}
.nav-links a:hover,
.nav-links a.active {
  border-color: var(--brand-sand);
  color: var(--brand-khaki);
}
@media (min-width: 900px) { .nav-links { display: flex; } }

.nav-actions { display: flex; align-items: center; gap: 10px; }

.lang-switch {
  display: inline-flex;
  background: var(--stone-100);
  border-radius: 999px;
  padding: 2px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.lang-switch button,
.lang-switch a,
.lang-switch span {
  appearance: none; border: 0; background: transparent;
  padding: 4px 10px; border-radius: 999px;
  cursor: pointer;
  color: var(--stone-600);
  font-family: inherit; font-weight: inherit; font-size: inherit; letter-spacing: inherit;
  text-decoration: none;
  display: inline-block;
}
.lang-switch span { cursor: default; }
.lang-switch button.is-active,
.lang-switch a.is-active,
.lang-switch span.is-active {
  background: var(--brand-khaki); color: white;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 8px;
  font: 600 14px/1 var(--font-body);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: transform .08s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--brand-khaki);
  color: white;
  box-shadow: var(--shadow-card);
}
.btn-primary:hover { background: #536230; box-shadow: var(--shadow-lift); }

.btn-ghost {
  background: transparent;
  color: var(--brand-mud);
  border-color: var(--brand-mud);
}
.btn-ghost:hover { background: var(--brand-mud); color: var(--paper); }

.btn-sand {
  background: var(--brand-sand); color: white;
  box-shadow: var(--shadow-card);
}
.btn-sand:hover { background: #a87a39; }

.btn-sm { padding: 8px 12px; font-size: 12px; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  background: var(--brand-khaki);
  color: var(--brand-lilac);
  overflow: hidden;
  isolation: isolate;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 60% 45% at 80% 0%, rgba(187, 138, 69, 0.25), transparent 70%),
    radial-gradient(ellipse 70% 50% at 10% 100%, rgba(28, 26, 20, 0.35), transparent 65%);
  pointer-events: none;
  z-index: 0;
}
.hero-inner {
  position: relative; z-index: 1;
  padding: 72px 0 120px;
  display: grid; gap: 24px;
}
@media (min-width: 900px) {
  .hero-inner { padding: 110px 0 160px; }
}

.hero .kicker { color: #f5e1b9; opacity: 0.85; }
.hero h1 {
  color: white;
  font-family: var(--font-brush);
  text-transform: none;
  font-weight: 400;
  font-size: clamp(2.6rem, 6vw + 1rem, 5.25rem);
  letter-spacing: 0;
  line-height: 1;
  max-width: 18ch;
  /* subtle brush feel via text-shadow */
  text-shadow: 0 1px 0 rgba(0,0,0,.05);
}
.hero .tagline {
  font-family: var(--font-brush);
  font-weight: 400;
  color: #f5e1b9;
  font-size: clamp(1.1rem, 1.2vw + 0.8rem, 1.6rem);
  max-width: 40ch;
  line-height: 1.3;
}
.hero .sub {
  color: rgba(245, 225, 185, 0.85);
  font-size: clamp(1rem, 0.4vw + 0.9rem, 1.125rem);
  max-width: 52ch;
  font-family: var(--font-body);
}

.hero-stats {
  display: flex; flex-wrap: wrap; gap: 28px;
  margin-top: 24px;
  font-size: 14px;
  color: rgba(245, 225, 185, 0.9);
}
.hero-stats strong {
  display: block;
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: white;
  letter-spacing: 0.03em;
}

/* Torn edge at bottom of hero */
.torn-edge {
  position: absolute; bottom: -1px; left: 0; right: 0;
  height: 90px;
  z-index: 2;
  pointer-events: none;
}
.torn-edge svg { width: 100%; height: 100%; }

/* ---------- Search card ---------- */

.search-card {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--stone-300);
  border-radius: 16px;
  box-shadow: 0 20px 40px -16px rgba(28, 26, 20, 0.25);
  padding: 14px;
  margin-top: -72px;
  z-index: 3;
}
@media (min-width: 900px) {
  .search-card { padding: 20px; margin-top: -100px; }
}

.search-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}
@media (min-width: 768px) {
  .search-row { grid-template-columns: 1.3fr 1fr auto; gap: 0; }
}

.search-field {
  display: flex; align-items: center; gap: 10px;
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 10px;
  padding: 10px 14px;
  min-height: 56px;
}
@media (min-width: 768px) {
  .search-field {
    border-radius: 0;
    border-right-width: 0;
  }
  .search-field:first-child { border-top-left-radius: 10px; border-bottom-left-radius: 10px; }
  .search-field + .search-field { }
}

.search-field label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--stone-600);
  display: block;
}
.search-field input,
.search-field select {
  border: 0; outline: 0; background: transparent;
  font: 500 15px/1.2 var(--font-body);
  color: var(--ink);
  width: 100%;
  padding: 2px 0 0;
}
.search-field .ico {
  width: 22px; height: 22px; color: var(--brand-mud);
  flex: 0 0 22px;
}
.search-field .stack { flex: 1; min-width: 0; }

.search-submit {
  height: 56px;
  padding-inline: 24px;
  border-radius: 10px;
  font-family: var(--font-display);
  letter-spacing: 0.1em;
  font-size: 14px;
  font-weight: 700;
  background: var(--brand-sand);
  color: white; border: 0;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  justify-content: center;
}
.search-submit:hover { background: #a87a39; }
@media (min-width: 768px) {
  .search-submit {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
  }
}

.chip-row {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 14px;
  padding-inline: 4px;
  font-size: 13px;
}
.chip-row .label {
  color: var(--stone-600);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
  margin-right: 4px;
  align-self: center;
}
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(187, 138, 69, 0.12);
  color: var(--brand-mud);
  border: 1px solid rgba(187, 138, 69, 0.3);
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s ease;
}
.chip:hover { background: var(--brand-sand); color: white; border-color: var(--brand-sand); }

/* ---------- Sections ---------- */

.section {
  padding: 72px 0;
}
.section-head {
  display: flex; align-items: end; justify-content: space-between;
  gap: 20px; flex-wrap: wrap;
  margin-bottom: 32px;
}
.section-head .heading { max-width: 52ch; }
.section-head h2 { margin-top: 6px; }
.section-head p { color: var(--stone-600); margin: 8px 0 0; font-size: 15px; }
.section-head .link {
  font-size: 13px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--brand-khaki);
  display: inline-flex; align-items: center; gap: 6px;
}
.section-head .link:hover { color: var(--brand-sand); }

/* ---------- Category grid ---------- */

.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.cat-card {
  display: flex; flex-direction: column; gap: 10px;
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  padding: 20px 18px;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
  position: relative;
  overflow: hidden;
  min-height: 148px;
}
.cat-card::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 6px;
  background: var(--brand-sand);
  transform: translateY(100%);
  transition: transform .2s ease;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--brand-sand); }
.cat-card:hover::after { transform: translateY(0); }
.cat-card .icon {
  width: 40px; height: 40px;
  background: var(--stone-100);
  border-radius: 10px;
  display: grid; place-items: center;
  color: var(--brand-khaki);
}
.cat-card h3 { font-size: 15px; letter-spacing: 0.04em; color: var(--brand-mud); }
.cat-card .count {
  font-size: 12px;
  color: var(--stone-600);
  font-weight: 600;
  margin-top: auto;
}
.cat-card .count b { color: var(--brand-khaki); font-weight: 700; }

/* ---------- Provinces strip ---------- */

.section-khaki {
  background: var(--brand-khaki);
  color: var(--brand-lilac);
  position: relative;
  padding: 90px 0 100px;
}
.section-khaki h2 { color: white; }
.section-khaki .kicker { color: var(--brand-lilac); opacity: 0.8; }
.section-khaki .section-head p { color: rgba(245, 225, 185, 0.8); }
.section-khaki .section-head .link { color: var(--brand-lilac); }

.provinces {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}
.prov-card {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px;
  padding: 14px 16px;
  background: rgba(251, 246, 234, 0.08);
  border: 1px solid rgba(245, 225, 185, 0.2);
  border-radius: 10px;
  color: var(--brand-lilac);
  font-weight: 600;
  font-size: 14px;
  transition: all .15s ease;
}
.prov-card:hover { background: var(--brand-sand); border-color: var(--brand-sand); color: white; }
.prov-card .num {
  font-family: var(--font-display);
  font-size: 13px;
  letter-spacing: 0.06em;
  opacity: 0.7;
  font-weight: 500;
}
.prov-card:hover .num { opacity: 1; }

/* ---------- Listing cards ---------- */

.listing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}
.listing-grid.compact { gap: 14px; }

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.listing {
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  overflow: hidden;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
  display: flex; flex-direction: column;
}
.listing:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); border-color: var(--stone-600); }

.listing-photo {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--stone-100);
  overflow: hidden;
}
.listing-photo .ph {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
}
.listing-photo .ph-placeholder {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  background:
    repeating-linear-gradient(45deg, var(--stone-100) 0 10px, #e8dfc7 10px 20px);
  color: var(--stone-600);
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
}
.listing-photo .badges {
  position: absolute; top: 10px; left: 10px; right: 10px;
  display: flex; justify-content: space-between;
  pointer-events: none;
}
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  background: rgba(251, 246, 234, 0.95);
  color: var(--brand-mud);
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  backdrop-filter: blur(4px);
}
.badge.claimed { background: var(--success); color: white; }
.badge.unclaimed { background: rgba(90, 80, 52, 0.9); color: var(--brand-lilac); }
.badge.featured { background: var(--brand-sand); color: white; }
.badge-sand { background: var(--brand-sand); color: white; }

/* Featured card partial (_featured_card.html) */
.featured-card {
  display: flex; flex-direction: column;
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--ink);
  box-shadow: var(--shadow-card);
  transition: box-shadow 0.15s, transform 0.15s;
}
.featured-card:hover, .featured-card:focus {
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
  outline: none;
}
.featured-card:focus-visible { outline: var(--ring); outline-offset: var(--ring-offset); }
.featured-card-media {
  position: relative;
  height: 140px;
  background: repeating-linear-gradient(45deg, #c9bfa6 0 14px, #b8ae96 14px 28px);
}
.featured-card-logo {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
}
.featured-card-monogram {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--brand-mud);
}
.featured-card-monogram span {
  font-family: var(--font-display);
  font-size: 2.5rem;
  color: var(--brand-lilac);
  letter-spacing: 0.05em;
}
.featured-card-badge { position: absolute; top: 10px; left: 10px; }
.featured-card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.featured-card-meta {
  display: flex; align-items: center; gap: 6px;
  font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--stone-600); font-weight: 600;
}
.featured-card-name {
  font-size: 15px; font-weight: 700; line-height: 1.35;
  color: var(--ink); margin: 0;
}
.featured-card-tagline {
  font-size: 13px; color: var(--stone-600); margin: 0;
  line-height: 1.5; overflow: hidden;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical;
}

.listing-body {
  padding: 16px 18px 18px;
  display: flex; flex-direction: column; gap: 8px;
  flex: 1;
}
.listing-meta {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--stone-600);
  font-weight: 600;
}
.listing-meta .dot { opacity: 0.5; }
.listing-title {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 18px;
  font-weight: 600;
  color: var(--brand-mud);
  line-height: 1.15;
}
.listing-desc {
  font-size: 14px;
  color: var(--stone-600);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.listing-amenities {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-top: 4px;
}
.amenity {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 11px;
  color: var(--brand-mud);
  background: var(--stone-100);
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
}
.listing-foot {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed var(--stone-300);
  font-size: 12px;
}
.listing-foot .loc {
  color: var(--stone-600);
  display: inline-flex; align-items: center; gap: 4px;
  font-weight: 500;
}
.listing-foot .arrow {
  font-family: var(--font-display);
  color: var(--brand-khaki);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 4px;
}

/* ---------- Featured spotlight ---------- */

.spotlight {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  border: 1px solid var(--stone-300);
  border-radius: 20px;
  overflow: hidden;
  background: white;
}
@media (min-width: 900px) {
  .spotlight { grid-template-columns: 1.2fr 1fr; }
}
.spotlight-media {
  position: relative;
  min-height: 320px;
  background:
    linear-gradient(160deg, rgba(28, 26, 20, 0.35), rgba(95, 111, 58, 0.15)),
    repeating-linear-gradient(45deg, #8a7a4e 0 16px, #7a6c44 16px 32px);
}
.spotlight-media .ph {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
}
.spotlight-media .quote {
  position: absolute; left: 24px; bottom: 24px; right: 24px;
  color: white;
  font-family: var(--font-brush);
  font-size: 1.4rem;
  line-height: 1.3;
  max-width: 26ch;
  text-shadow: 0 2px 10px rgba(0,0,0,.4);
}
.spotlight-body { padding: 36px; display: flex; flex-direction: column; gap: 14px; }
.spotlight-body h3 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  letter-spacing: 0.04em;
  color: var(--brand-mud);
}
.spotlight-body p { color: var(--stone-600); font-size: 15px; }
.spotlight-tags { display: flex; flex-wrap: wrap; gap: 6px; }

/* ---------- How it works ---------- */

.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step {
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  padding: 24px;
  position: relative;
  display: flex; flex-direction: column; gap: 8px;
}
.step .num {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 700;
  color: var(--brand-sand);
  line-height: 1;
  letter-spacing: 0.02em;
}
.step h3 { font-size: 16px; color: var(--brand-mud); }
.step p { font-size: 14px; color: var(--stone-600); margin: 0; }

/* ---------- Claim CTA banner ---------- */

.claim-banner {
  position: relative;
  background: var(--brand-mud);
  color: var(--brand-lilac);
  border-radius: 20px;
  padding: 48px;
  overflow: hidden;
  isolation: isolate;
  display: grid; gap: 20px;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .claim-banner { grid-template-columns: 1.3fr 1fr; align-items: center; padding: 64px; }
}
.claim-banner::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 50% 60% at 100% 50%, rgba(187, 138, 69, 0.35), transparent 70%);
  z-index: -1;
}
.claim-banner h2 {
  color: white;
  font-family: var(--font-brush);
  text-transform: none;
  font-weight: 400;
  font-size: clamp(2rem, 3vw + 1rem, 3rem);
  line-height: 1.05;
  letter-spacing: 0;
}
.claim-banner p { color: rgba(245, 225, 185, 0.85); font-size: 16px; max-width: 52ch; }
.claim-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- FAQ (FAQPage schema) ---------- */

.faq {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
  background: var(--stone-300);
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  overflow: hidden;
}
.faq-item { background: white; }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 20px 24px;
  font-weight: 600;
  color: var(--brand-mud);
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--brand-sand);
  transition: transform .2s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .ans { padding: 0 24px 20px; color: var(--stone-600); font-size: 15px; line-height: 1.6; }

/* ---------- Footer ---------- */

.footer {
  background: var(--ink);
  color: var(--brand-lilac);
  padding: 72px 0 32px;
  margin-top: 80px;
  position: relative;
  overflow: hidden;
}
.footer::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 6px;
  background: linear-gradient(90deg, var(--brand-khaki) 0%, var(--brand-sand) 50%, var(--brand-khaki) 100%);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
@media (min-width: 768px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
}
.footer h4 {
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--brand-sand);
  margin-bottom: 14px;
}
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 14px; }
.footer ul a { color: rgba(245, 225, 185, 0.8); }
.footer ul a:hover { color: white; }
.footer .brand-block .brush {
  font-family: var(--font-brush);
  font-size: 28px;
  color: white;
  display: inline-block;
  margin-bottom: 12px;
}
.footer .brand-block p { color: rgba(245, 225, 185, 0.75); font-size: 14px; max-width: 42ch; }
.footer-bot {
  border-top: 1px solid rgba(245, 225, 185, 0.15);
  margin-top: 48px; padding-top: 24px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 12px; color: rgba(245, 225, 185, 0.6);
}

/* ---------- Breadcrumb ---------- */
.crumbs {
  font-size: 13px;
  color: var(--stone-600);
  display: flex; flex-wrap: wrap; gap: 6px;
  padding: 16px 0;
}
.crumbs a { color: var(--brand-mud); font-weight: 500; }
.crumbs a:hover { color: var(--brand-sand); }
.crumbs .sep { color: var(--stone-300); }

/* ---------- Directory page: filters rail ---------- */

.dir-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding-top: 12px;
}
@media (min-width: 900px) {
  .dir-layout { grid-template-columns: 260px 1fr; gap: 36px; }
}

.filter-rail {
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  background: white;
  padding: 18px;
  position: sticky; top: 88px;
  align-self: start;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
}
.filter-group { padding: 10px 0; border-bottom: 1px solid var(--stone-100); }
.filter-group:last-child { border-bottom: 0; }
.filter-group h4 {
  font-family: var(--font-body);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--stone-600);
  margin-bottom: 10px;
}
.filter-list { display: grid; gap: 4px; font-size: 14px; }
.filter-list label {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 4px;
  border-radius: 6px;
  cursor: pointer;
  color: var(--ink);
}
.filter-list label:hover { background: var(--stone-100); }
.filter-list input[type="checkbox"] {
  appearance: none;
  width: 16px; height: 16px;
  border: 1.5px solid var(--stone-600);
  border-radius: 4px;
  display: grid; place-items: center;
  cursor: pointer;
  flex: 0 0 16px;
}
.filter-list input[type="checkbox"]:checked {
  background: var(--brand-khaki);
  border-color: var(--brand-khaki);
}
.filter-list input[type="checkbox"]:checked::after {
  content: ''; width: 8px; height: 5px;
  border-left: 2px solid white; border-bottom: 2px solid white;
  transform: rotate(-45deg) translate(1px, -1px);
}
.filter-list .cnt { margin-left: auto; color: var(--stone-600); font-size: 12px; font-weight: 600; }

.dir-results .results-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px; gap: 12px; flex-wrap: wrap;
}
.results-head .num { font-size: 14px; color: var(--stone-600); }
.results-head .num b { color: var(--ink); font-weight: 700; }
.sort-select {
  appearance: none;
  background: white url("data:image/svg+xml;charset=utf8,%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' fill='none' stroke='%235a5034' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 12px center;
  border: 1px solid var(--stone-300);
  border-radius: 8px;
  padding: 8px 32px 8px 12px;
  font: 500 13px var(--font-body);
  color: var(--ink);
  cursor: pointer;
}

.active-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.active-filter {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(187, 138, 69, 0.15);
  color: var(--brand-mud);
  border: 1px solid rgba(187, 138, 69, 0.35);
  padding: 5px 8px 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
}
.active-filter button {
  appearance: none; border: 0; background: transparent;
  color: var(--brand-mud); cursor: pointer;
  width: 18px; height: 18px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 14px; line-height: 1;
}
.active-filter button:hover { background: var(--brand-sand); color: white; }

/* ---------- Listing detail ---------- */

.detail-hero {
  position: relative;
  aspect-ratio: 21 / 9;
  min-height: 320px;
  background: var(--brand-mud);
  overflow: hidden;
}
.detail-hero .ph {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
}
.detail-hero::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(28,26,20,0.2) 0%, rgba(28,26,20,0) 40%, rgba(28,26,20,0.85) 100%);
}

.detail-head {
  position: relative;
  margin-top: -80px;
  z-index: 2;
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 16px 16px 0 0;
  padding: 28px 32px 20px;
  display: flex; gap: 16px; justify-content: space-between; align-items: flex-end;
  flex-wrap: wrap;
}
.detail-head .chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.detail-head h1 {
  font-family: var(--font-display);
  text-transform: uppercase;
  font-size: clamp(1.75rem, 2vw + 1rem, 2.75rem);
  color: var(--brand-mud);
  margin-bottom: 8px;
}
.detail-head .addr { color: var(--stone-600); font-size: 14px; display: flex; align-items: center; gap: 6px; }

.detail-body {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  background: white;
  border: 1px solid var(--stone-300);
  border-top: 0;
  border-radius: 0 0 16px 16px;
  padding: 28px 32px;
}
@media (min-width: 900px) {
  .detail-body { grid-template-columns: 1fr 340px; gap: 48px; }
}
.detail-main { display: grid; gap: 32px; }
.detail-main h2 { font-size: 20px; color: var(--brand-mud); }
.detail-main p { color: var(--ink); font-size: 16px; line-height: 1.7; }

.facility-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
}
.facility {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  background: var(--stone-100);
  border-radius: 8px;
  font-size: 14px;
  color: var(--brand-mud);
  font-weight: 500;
}
.facility .ico { color: var(--brand-khaki); }

.gallery {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: repeat(2, 180px);
  gap: 6px;
  border-radius: 12px;
  overflow: hidden;
}
.gallery > div {
  background:
    linear-gradient(160deg, rgba(0,0,0,.2), rgba(0,0,0,0)),
    repeating-linear-gradient(45deg, #b49d6a 0 14px, #a08956 14px 28px);
  background-size: cover; background-position: center;
  position: relative;
}
.gallery > div:first-child { grid-row: span 2; }

.info-card {
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  padding: 20px;
  background: var(--stone-100);
  align-self: start;
  position: sticky; top: 88px;
  display: grid; gap: 12px;
}
.info-card .claim-note {
  background: rgba(187, 138, 69, 0.15);
  border: 1px dashed var(--brand-sand);
  padding: 12px 14px;
  border-radius: 10px;
  font-size: 13px;
  color: var(--brand-mud);
}
.info-card .claim-note b { color: var(--brand-sand); }
.info-row {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--stone-300);
  font-size: 14px;
}
.info-row:last-child { border-bottom: 0; }
.info-row .ico { color: var(--brand-khaki); margin-top: 2px; }
.info-row .k { font-size: 11px; color: var(--stone-600); text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; }
.info-row .v { font-size: 14px; color: var(--ink); font-weight: 500; }
.info-row a.v { color: var(--brand-khaki); }
.info-row a.v:hover { color: var(--brand-sand); }

/* ---------- Tweaks panel ---------- */
.tweaks-panel {
  position: fixed;
  bottom: 20px; right: 20px;
  width: 300px;
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 14px;
  box-shadow: 0 20px 60px -20px rgba(28, 26, 20, 0.4);
  padding: 18px;
  z-index: 200;
  font-size: 13px;
  display: none;
  max-height: 85vh;
  overflow-y: auto;
}
.tweaks-panel.open { display: block; }
.tweaks-panel h3 {
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--brand-sand);
  margin-bottom: 12px;
}
.tweaks-panel .tweak { margin-bottom: 14px; }
.tweaks-panel .tweak label {
  display: block;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--stone-600);
  margin-bottom: 6px;
  font-weight: 600;
}
.tweaks-panel .tweak .opts { display: flex; gap: 4px; flex-wrap: wrap; }
.tweaks-panel .tweak .opts button {
  appearance: none;
  border: 1px solid var(--stone-300);
  background: white;
  padding: 6px 10px;
  border-radius: 6px;
  font: 500 12px var(--font-body);
  cursor: pointer;
  color: var(--ink);
}
.tweaks-panel .tweak .opts button.is-active {
  background: var(--brand-khaki); color: white; border-color: var(--brand-khaki);
}
.tweaks-panel .swatches { display: flex; gap: 6px; }
.tweaks-panel .sw {
  width: 28px; height: 28px; border-radius: 6px; cursor: pointer;
  border: 2px solid transparent;
}
.tweaks-panel .sw.is-active { border-color: var(--ink); }

/* ---------- Utilities ---------- */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.mobile-menu-btn {
  display: inline-flex;
  align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border: 1px solid var(--stone-300);
  border-radius: 8px;
  background: white;
  cursor: pointer;
}
@media (min-width: 900px) { .mobile-menu-btn { display: none; } }

/* ---------- Hero accent: handwritten scribble underline ---------- */
.hero h1 .scribble {
  display: inline-block;
  position: relative;
}
.hero h1 .scribble::after {
  content: '';
  position: absolute;
  left: -4px; right: -4px;
  bottom: -6px;
  height: 8px;
  background: var(--brand-sand);
  opacity: 0.9;
  clip-path: polygon(0 40%, 8% 20%, 18% 60%, 28% 30%, 40% 70%, 52% 25%, 64% 60%, 78% 30%, 90% 55%, 100% 40%, 100% 100%, 0 100%);
}

/* ---------- Tag / pill ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  background: rgba(187, 138, 69, 0.15);
  color: var(--brand-mud);
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.pill.khaki { background: rgba(95, 111, 58, 0.12); color: var(--brand-khaki); }
.pill.sand  { background: var(--brand-sand); color: white; }

/* ==========================================================================
   Mobile polish (≤767px). Addresses the audit:
   1  — mobile nav drawer wiring (panel + open state)
   2  — search card field radii reset
   3  — filter-rail collapsed drawer + Filters button
   4  — detail-head padding + min-width bust
   5  — detail-body padding
   6  — gallery reflow to 2-col
   7  — info-card moved to top of detail-body on mobile
   8  — claim-banner side padding + full-width button
   9  — tap-target sizes for chips / active-filters / amenities
   10 — listing-grid collapses to single column
   ========================================================================== */

/* Mobile nav drawer (issue 1). Button already rendered below 900px. */
.mobile-nav {
  display: none;
  background: var(--paper);
  border-top: 1px solid var(--stone-300);
  padding: 8px 0;
}
.mobile-nav.open { display: block; }
.mobile-nav ul { list-style: none; margin: 0; padding: 0; }
.mobile-nav li a {
  display: block;
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  border-bottom: 1px solid var(--stone-100);
}
.mobile-nav li a:hover { background: var(--stone-100); }
@media (min-width: 900px) { .mobile-nav { display: none !important; } }

/* Filter-rail drawer (issue 3). */
.filter-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-mud);
  background: white;
  border: 1px solid var(--stone-300);
  border-radius: 10px;
  padding: 12px 16px;
  cursor: pointer;
  margin-bottom: 12px;
  width: 100%;
  justify-content: space-between;
}
@media (max-width: 899px) { .filter-toggle { display: inline-flex; } }

@media (max-width: 767px) {
  /* Issue 2 — search fields reunify as individual rounded cards */
  .search-field { border-radius: 10px; border-right-width: 1px; }
  .search-field:first-child { border-top-left-radius: 10px; border-bottom-left-radius: 10px; }
  .search-submit { border-radius: 10px; width: 100%; }

  /* Issue 4 — detail head breathing room */
  .detail-head {
    padding: 20px 16px 16px;
    flex-direction: column;
    align-items: flex-start;
  }
  .detail-head > div { min-width: 0 !important; }

  /* Issue 5 — detail body padding */
  .detail-body { padding: 20px 16px; }

  /* Issue 6 — gallery reflow */
  .gallery {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 180px 120px;
  }
  .gallery > div:first-child { grid-row: span 1; }

  /* Issue 8 — claim-banner side padding + full-width button */
  .claim-banner { padding: 24px 16px !important; }
  .claim-banner .btn { width: 100%; }

  /* Issue 9 — tap targets WCAG 2.5.5 */
  .chip { padding: 10px 14px; font-size: 13px; }
  .active-filter { padding: 10px 10px 10px 14px; }
  .amenity { padding: 8px 10px; font-size: 12px; }
  .badge { padding: 6px 11px; font-size: 11px; }

  /* Issue 10 — grid collapses to one column */
  .listing-grid { grid-template-columns: 1fr; }
  .listing-grid.compact { grid-template-columns: 1fr; }

  /* Hero + search card tighter on phones */
  .hero-inner { padding: 56px 0 96px; }
  .search-card { margin-top: -64px; padding: 12px; }
  .section { padding: 56px 0; }
  .section-khaki { padding: 64px 0 72px; }
  .detail-hero { min-height: 220px; }
  .cat-card { min-height: 128px; padding: 18px 16px; }
  .container { padding-inline: 16px; }
}

/* Issue 7 — on tablet + mobile, info-card comes first in detail-body so
   primary actions are above the fold. Also drop the sticky since there is
   no sibling flow to stick against in a single column. */
@media (max-width: 899px) {
  .detail-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }
  .info-card { order: -1; position: static; }
  .filter-rail {
    position: static;
    max-height: 0;
    overflow: hidden;
    padding: 0 18px;
    transition: max-height .3s ease, padding .3s ease;
    border-radius: 14px;
    box-sizing: border-box;
  }
  .filter-rail.open {
    max-height: 1200px;
    padding: 18px;
  }
}

/* ==========================================================================
   Blog post body typography
   Wagtail richtext renders h2/h3/p/ul/ol/blockquote/a into the body.
   The template uses .prose (Tailwind typography) which isn't loaded; these
   rules give the body readable spacing without pulling in the plugin.
   ========================================================================== */
.blog-body {
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--ink);
}
.blog-body > * + * { margin-top: 1.25em; }
.blog-body h2 {
  font-family: var(--font-display, inherit);
  font-size: 1.75rem;
  line-height: 1.25;
  color: var(--kampi-khaki);
  margin-top: 2.25em;
  margin-bottom: 0.6em;
  letter-spacing: 0.01em;
}
.blog-body h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--kampi-mud);
  margin-top: 1.75em;
  margin-bottom: 0.5em;
}
.blog-body h2 + p, .blog-body h3 + p { margin-top: 0; }
.blog-body p { margin: 0; }
.blog-body ul, .blog-body ol { padding-left: 1.5em; }
.blog-body li + li { margin-top: 0.35em; }
.blog-body a {
  color: var(--kampi-sand);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.blog-body a:hover { color: var(--kampi-mud); }
.blog-body blockquote {
  border-left: 3px solid var(--kampi-sand);
  padding: 0.25em 0 0.25em 1em;
  color: var(--stone-600);
  font-style: italic;
  margin: 1.5em 0;
}
.blog-body strong { color: var(--ink); }
.blog-body em { color: var(--stone-600); }
.blog-body code {
  background: var(--stone-100);
  padding: 0.1em 0.35em;
  border-radius: 3px;
  font-size: 0.95em;
}
.blog-body img { max-width: 100%; height: auto; border-radius: 8px; margin: 1.5em 0; }
