:root {
  color-scheme: light;
  --bg: #f6f1e8;
  --panel: #fffaf1;
  --ink: #17211d;
  --muted: #66706b;
  --accent: #b94d2b;
  --accent-dark: #7d301f;
  --link: #06f;
  --link-dark: #0052cc;
  --search-hit-bg: #ffe45c;
  --search-hit-ink: #c61f1f;
  --line: rgba(23, 33, 29, 0.14);
  --shadow: 0 24px 60px rgba(56, 39, 18, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(185, 77, 43, 0.16), transparent 32rem),
    linear-gradient(135deg, #f8f0df, var(--bg));
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.7;
}

a {
  color: var(--link);
  text-decoration-color: rgba(0, 102, 255, 0.38);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--link-dark);
}

.site-header,
.site-footer,
main {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0;
}

.brand {
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.03em;
  text-decoration: none;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
}

.hero {
  display: grid;
  gap: 22px;
  margin: 54px 0 72px;
  padding: clamp(32px, 7vw, 82px);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 34px;
  box-shadow: var(--shadow);
}

.hero h1,
.page-title h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(2.2rem, 6.4vw, 4.85rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
}

.article-header h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(2.05rem, 5.4vw, 3.45rem);
  line-height: 1.04;
  letter-spacing: -0.05em;
}

.lede {
  max-width: 660px;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2.5vw, 1.32rem);
}

.eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.button {
  width: fit-content;
  padding: 12px 18px;
  color: #fff;
  background: var(--ink);
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
}

.section,
.page-title,
.article {
  margin: 0 0 72px;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.8rem, 4vw, 3.2rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.post-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.post-card,
.post-row {
  background: rgba(255, 250, 241, 0.78);
  border: 1px solid var(--line);
  border-radius: 24px;
}

.post-card {
  padding: 22px;
}

.post-body {
  display: grid;
  gap: 10px;
}

.post-meta-groups {
  display: grid;
  gap: 10px;
}

.post-card time,
.post-row time,
.article-header time {
  color: var(--muted);
  font-size: 0.9rem;
}

.post-card h3,
.post-row h2 {
  margin: 10px 0 8px;
  line-height: 1.18;
  letter-spacing: -0.03em;
}

.post-card h3 {
  font-size: 1.24rem;
}

.post-card p,
.post-row p {
  margin: 0;
  color: var(--muted);
}

.page-title {
  padding: 48px 0 16px;
}

.post-list {
  display: grid;
  gap: 14px;
  margin-bottom: 72px;
}

.post-row {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  padding: 24px;
}

.article {
  max-width: 780px;
}

.article-header {
  display: grid;
  gap: 14px;
  margin: 48px 0 36px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.taxonomy-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.taxonomy-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid rgba(0, 102, 255, 0.18);
  border-radius: 999px;
  background: rgba(255, 250, 241, 0.86);
  color: var(--link);
  font-size: 0.84rem;
  line-height: 1;
  text-decoration: none;
}

.taxonomy-pill:hover {
  color: var(--link-dark);
  border-color: rgba(0, 102, 255, 0.34);
}

.taxonomy-pill--category {
  background: rgba(185, 77, 43, 0.08);
}

.taxonomy-pill--tag2 {
  border-color: rgba(0, 111, 94, 0.2);
  background: rgba(0, 111, 94, 0.08);
  color: #0a5a4d;
}

.taxonomy-pill--tag3 {
  border-color: rgba(92, 50, 168, 0.18);
  background: rgba(92, 50, 168, 0.08);
  color: #5c32a8;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.filter-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border: 1px solid rgba(23, 33, 29, 0.12);
  border-radius: 999px;
  background: rgba(23, 33, 29, 0.05);
  color: var(--ink);
  font-size: 0.84rem;
  line-height: 1;
}

.filter-pill--price {
  background: rgba(185, 77, 43, 0.12);
  border-color: rgba(185, 77, 43, 0.2);
  color: var(--accent-dark);
}

.filter-pill--location {
  background: rgba(0, 102, 255, 0.08);
  border-color: rgba(0, 102, 255, 0.14);
  color: var(--link-dark);
}

.filter-pill--category {
  background: rgba(23, 33, 29, 0.08);
}

.page-copy,
.page-copy p {
  max-width: 720px;
  color: var(--muted);
}

.content {
  font-size: 1.08rem;
}

.content h2 {
  margin-top: 2.2em;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.content p,
.content ul {
  color: #2d3833;
}

.post-nav {
  display: grid;
  gap: 10px;
  margin-top: 40px;
}

.article-toggle {
  overflow: hidden;
  background: rgba(255, 250, 241, 0.72);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.article-toggle:hover,
.article-toggle[open] {
  border-color: rgba(185, 77, 43, 0.28);
}

.article-toggle summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 16px;
  cursor: pointer;
  background: rgba(255, 250, 241, 0.7);
  color: var(--ink);
  font-weight: 700;
  list-style: none;
  outline: none;
}

.article-toggle[open] summary {
  border-bottom: 1px solid var(--line);
}

.article-toggle summary:focus-visible {
  box-shadow: inset 0 0 0 3px rgba(185, 77, 43, 0.24);
}

.article-toggle summary::-webkit-details-marker {
  display: none;
}

.article-toggle summary::after {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.article-toggle[open] summary::after {
  transform: rotate(225deg) translate(-2px, -2px);
}

.article-toggle ul {
  display: grid;
  margin: 0;
  padding: 6px 16px 12px;
  list-style: none;
}

.article-toggle li {
  color: var(--muted);
  border-bottom: 1px solid rgba(23, 33, 29, 0.09);
}

.article-toggle li:last-child {
  border-bottom: 0;
}

.article-toggle li a {
  display: block;
  padding: 8px 0;
  color: var(--ink);
  text-decoration-color: rgba(185, 77, 43, 0.35);
  transition: color 0.2s ease;
}

.article-toggle li a:hover {
  color: var(--accent-dark);
}

.site-footer {
  padding: 40px 0 52px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.section-split {
  display: grid;
  gap: 22px;
}

.feature-grid,
.term-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.feature-card,
.term-card,
.search-shell {
  background: rgba(255, 250, 241, 0.82);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.feature-card,
.term-card {
  padding: 24px;
}

.feature-card h3,
.term-card h2 {
  margin: 10px 0 8px;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.feature-card p:last-child,
.term-card p:last-child {
  margin-bottom: 0;
  color: var(--muted);
}

.term-card-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.term-preview {
  display: grid;
  gap: 8px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.term-preview a {
  color: var(--ink);
}

.search-shell {
  display: grid;
  gap: 14px;
  padding: 28px;
  margin-bottom: 72px;
}

.filter-shell {
  display: grid;
  gap: 18px;
  padding: 30px;
  margin-bottom: 28px;
}

.filter-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.filter-heading h2 {
  margin: 4px 0 0;
  font-size: clamp(1.7rem, 3.8vw, 2.75rem);
  line-height: 1;
  letter-spacing: -0.05em;
}

.filter-actions {
  display: grid;
  justify-items: end;
  gap: 10px;
}

.filter-button {
  padding: 10px 14px;
  border: 1px solid rgba(23, 33, 29, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.filter-button:disabled {
  opacity: 0.45;
  cursor: default;
}

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

.filter-field {
  display: grid;
  gap: 8px;
}

.filter-field--wide,
.facet-group--price {
  grid-column: 1 / -1;
}

.facet-group {
  min-width: 0;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.56);
}

.facet-group-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.facet-caption {
  color: var(--muted);
  font-size: 0.9rem;
}

.facet-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.facet-option {
  position: relative;
}

.facet-option input {
  position: absolute;
  inset: 0;
  opacity: 0;
}

.facet-option span {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid rgba(23, 33, 29, 0.12);
  border-radius: 999px;
  background: rgba(255, 250, 241, 0.74);
  color: var(--ink);
  font-size: 0.95rem;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
  cursor: pointer;
}

.facet-option input:focus-visible + span {
  outline: 2px solid rgba(185, 77, 43, 0.42);
  outline-offset: 2px;
}

.facet-option input:checked + span {
  border-color: rgba(185, 77, 43, 0.26);
  background: rgba(185, 77, 43, 0.12);
  color: var(--accent-dark);
  transform: translateY(-1px);
}

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

.filter-active {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(23, 33, 29, 0.08);
  color: var(--ink);
  font-size: 0.92rem;
}

.search-label {
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.search-input {
  width: 100%;
  padding: 18px 20px;
  border: 1px solid rgba(23, 33, 29, 0.14);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  font: inherit;
}

.search-input:focus {
  outline: none;
  border-color: rgba(185, 77, 43, 0.48);
  box-shadow: 0 0 0 4px rgba(185, 77, 43, 0.12);
}

.search-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.search-status {
  margin: 0;
  color: var(--muted);
}

.search-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.search-empty {
  padding: 24px;
  border: 1px dashed rgba(23, 33, 29, 0.16);
  border-radius: 20px;
  color: var(--muted);
  text-align: center;
}

.search-hit {
  padding: 0.08em 0.22em;
  color: var(--search-hit-ink);
  background: var(--search-hit-bg);
  border-radius: 0.24em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

@media (max-width: 820px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .hero {
    margin-top: 24px;
    border-radius: 26px;
  }

  .post-grid {
    grid-template-columns: 1fr;
  }

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

  .feature-grid,
  .term-grid {
    grid-template-columns: 1fr;
  }

  .search-shell {
    padding: 22px;
    border-radius: 24px;
  }

  .filter-shell {
    padding: 22px;
    border-radius: 24px;
  }

  .filter-heading,
  .search-meta {
    align-items: flex-start;
    flex-direction: column;
  }

  .filter-actions {
    justify-items: start;
  }

  .filter-grid,
  .price-grid {
    grid-template-columns: 1fr;
  }
}
