:root {
  font: 16px/1.55 system-ui, sans-serif;
  color: #18322a;
  background: #f8f5eb;
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
.shell { width: min(100% - 2rem, 920px); margin-inline: auto; }
header { background: #18382c; color: #fff9ed; border-top: .25rem solid #efbe6d; }
header .shell { display: flex; justify-content: space-between; align-items: center; min-height: 3.7rem; gap: 1rem; }
.brand-home { color: #fff9ed; text-decoration: none; font-size: 1.25rem; font-weight: 760; padding-block: .45rem; }
.brand-home span { color: #efbe6d; }
.brand-home:hover { text-decoration: underline; text-underline-offset: .24em; }
.brand-home:focus-visible { outline-color: #ffcc83; border-radius: .2rem; }
main { padding-block: 1.6rem 3.5rem; }
.auth-shell { max-width: 36rem; }
.auth-shell section { padding: clamp(1rem, 4vw, 2rem); }
.auth-shell h1 { font-size: clamp(1.75rem, 5vw, 2.5rem); }
#member-requests { margin-top: .75rem; }
#member-requests input { margin-bottom: .5rem; }
h1, h2, h3, p { margin: 0 0 .7rem; }
h1 { line-height: 1.1; font-size: clamp(2rem, 5vw, 3.25rem); }
.view-controls { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .65rem; border: 1px solid #b28650; border-radius: .6rem; padding: .65rem .9rem; margin-block: 0 .8rem; background: #ffe5b6; }
.view-controls[data-mode=member] { background: #fffdf5; border-color: #b2b9ad; }
nav, .actions { display: flex; flex-wrap: wrap; gap: .55rem; margin-block: .8rem; }
nav a { align-self: center; padding: .45rem .3rem; }
section, details, .card { padding: 1rem; border: 1px solid #ddd7c6; border-radius: .6rem; margin-block: .6rem; background: #fffdf5; }
.cards { display: grid; gap: .5rem; }
.cards .card { margin: 0; overflow-wrap: anywhere; }
form { display: grid; gap: .7rem; max-width: 35rem; margin-block: .75rem; }
label { display: grid; gap: .25rem; font-weight: 600; }
.check { display: flex; align-items: start; gap: .6rem; font-weight: 400; }
input, textarea, select, button { font: inherit; }
input:not([type=checkbox]), textarea, select { color: inherit; padding: .5rem; border: 1px solid #78877b; background: white; border-radius: .35rem; width: 100%; }
textarea { min-height: 6rem; resize: vertical; }
button { border: 1px solid #254837; background: #254837; color: white; border-radius: .4rem; padding: .45rem .7rem; cursor: pointer; justify-self: start; }
button.secondary, nav button[aria-pressed=false], .history-filters button[aria-pressed=false] { background: #fffdf5; color: #234535; }
button:disabled { cursor: wait; opacity: .6; }
a { color: #23533d; }
summary { cursor: pointer; font-weight: 700; }
.sponsored { display: inline-block; padding: .15rem .4rem; background: #ffe6b7; border-radius: .3rem; font-weight: 700; }
.staff-actions { border-top: 1px solid #ddd7c6; padding-top: .65rem; margin-top: .7rem; }
.staff-actions .actions { margin-block: .35rem 0; }
#home { background: transparent; border: 0; padding: 0; }
.home-search { color: #fff9ed; background: #18382c; border-radius: .65rem; padding: clamp(1rem, 4vw, 2rem); margin-bottom: 1.25rem; }
.home-search .search-form { max-width: 44rem; margin-bottom: 0; }
.home-search input { color: #18322a; }
.home-search button { color: #18322a; background: #efbe6d; border-color: #efbe6d; font-weight: 700; }
.home-search :focus-visible { outline-color: #ffcc83; }
.directory-heading { margin-bottom: .7rem; font-size: clamp(1.25rem, 3vw, 1.75rem); }
.directory-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; align-items: start; }
.directory-block { border: 1px solid #b7c6b7; border-radius: .55rem; background: #fffdf5; }
.directory-block h3 { margin: 0; font-size: 1.15rem; line-height: 1.35; }
.directory-block h3 a { display: block; padding: .72rem .95rem; border-radius: .5rem .5rem 0 0; color: #1d4333; background: #e4ecdf; }
.directory-block h3 a:hover { background: #d5e4d5; }
.directory-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; column-gap: .85rem; list-style: none; margin: 0; padding: .3rem .95rem .65rem; }
.directory-links li { display: flex; border-bottom: 1px solid #e9e4d7; }
.directory-links a { display: flex; flex: 1; align-items: center; padding-block: .35rem; font-size: .9375rem; line-height: 1.35; }
.directory-block a { text-decoration-thickness: 1px; text-underline-offset: .18em; }
.directory-links a:hover { color: #704317; }
button.listing-title { background: transparent; border: 0; color: #23533d; text-align: start; padding: 0; }
button.listing-title:hover { text-decoration: underline; text-underline-offset: .15em; }
.search-form { display: flex; align-items: end; gap: .55rem; }
.search-form label { flex: 1; }
.category-filters { display: flex; gap: .5rem; overflow-x: auto; overscroll-behavior-inline: contain; padding: .25rem .15rem .55rem; }
.category-filters button { flex: none; white-space: nowrap; }
.category-filters button[aria-pressed=true] { background: #254837; color: white; }
.results-toolbar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .45rem .85rem; margin-block: 1rem .65rem; }
.results-toolbar h3 { margin: 0; }
.result-layout { display: inline-flex; gap: .2rem; padding: .2rem; border: 1px solid #d1dacd; border-radius: .55rem; background: #edf1e9; }
.result-layout button { padding: .3rem .6rem; font-size: .9375rem; }
.result-layout button[aria-pressed=false] { color: #254837; background: transparent; border-color: transparent; }
.result-layout button[aria-pressed=false]:hover { background: #dce7d9; }
#listings[data-layout=photos] { grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: .75rem; }
.listing-media { margin: 0 0 .85rem; }
.listing-media-frame { display: grid; place-items: center; width: 100%; padding: 0; border: 1px solid #d8ded1; border-radius: .45rem; background: #edf1e8; overflow: hidden; }
.listing-media-frame:not(.media-placeholder), .listing-card .listing-media-frame { aspect-ratio: 16 / 10; }
.listing-page .listing-media-frame, dialog .listing-media-frame { max-height: min(40svh, 22rem); }
.listing-media img { display: block; width: 100%; height: 100%; object-fit: contain; }
.listing-card .listing-media img { object-fit: cover; }
.listing-card .listing-media-frame:hover { border-color: #789383; }
.listing-media figcaption { margin-top: .3rem; color: #4b5e51; font-size: .875rem; }
.media-placeholder { min-height: 5rem; color: #4b5e51; font-size: .9375rem; }
.listing-card { transition: border-color .16s, box-shadow .16s, transform .16s; }
.listing-card:focus-within { border-color: #789383; box-shadow: 0 4px 12px #1f3f2b16; }
@media (hover: hover) {
  .listing-card:hover { border-color: #789383; box-shadow: 0 6px 16px #1f3f2b19; transform: translateY(-2px); }
}
@media (prefers-reduced-motion: reduce) {
  .listing-card { transition: none; }
  .listing-card:hover { transform: none; }
}
.listing-title { font-weight: 700; }
.listing-meta { color: #4b5e51; }
.listing-description { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
html:has(dialog[open]) { overflow: hidden; scrollbar-gutter: stable; }
dialog { width: min(calc(100% - 2rem), 40rem); max-height: 85svh; color: #18322a; background: #fffdf5; border: 1px solid #b8c5b7; border-radius: .7rem; padding: clamp(1rem, 4vw, 1.6rem); overflow-wrap: anywhere; box-shadow: 0 24px 80px #142d2760; overscroll-behavior: contain; }
dialog::backdrop { background: #12271f99; }
.detail-heading { display: flex; justify-content: space-between; align-items: start; gap: .7rem; }
.detail-description { white-space: pre-wrap; }
.detail-link { background: #254837; color: white; border: 1px solid #254837; border-radius: .4rem; padding: .45rem .7rem; text-decoration: none; }
.detail-link:hover { background: #18382c; }
.listing-page { padding: clamp(1rem, 4vw, 2rem); overflow-wrap: anywhere; }
.listing-page h1 { margin-top: .8rem; }
.listing-page .detail-description { max-width: 68ch; }
.upload-preview { display: block; width: min(100%, 15rem); max-height: 12rem; object-fit: contain; border-radius: .45rem; border: 1px solid #d8ded1; }
.profile-avatar { display: block; width: 7rem; height: 7rem; object-fit: contain; border-radius: .45rem; border: 1px solid #d8ded1; background: #edf1e8; }
#member-profile { display: grid; gap: .55rem; margin-block: .75rem; }
#member-profile p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
#account-role { font-weight: 700; }
.listing-page [role=status]:empty, #detail-feedback:empty { display: none; }
@media (max-width: 36rem) {
  .directory-grid { grid-template-columns: minmax(0, 1fr); }
}
#history-more { margin-block: .7rem; }
#reports { margin-top: .5rem; }
#review + button + h3 { margin-top: 1.2rem; }
:focus-visible { outline: 3px solid #a1570a; outline-offset: 2px; }
