:root {
  color-scheme: light;
  --bg: #f7f5ef;
  --surface: #ffffff;
  --surface-soft: #eef4ea;
  --text: #1d2520;
  --muted: #647067;
  --line: #dbe4dc;
  --accent: #2f7d5b;
  --accent-dark: #215c43;
  --warm: #b86f3c;
  --reserved: #8a5b12;
  --reserved-soft: #fff3cf;
  --sold: #6d3a49;
  --sold-soft: #f4e8ed;
  --focus: #5c85a5;
  --shadow: 0 18px 50px rgba(28, 42, 34, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(255, 250, 240, 0.98), rgba(235, 244, 235, 0.94) 52%, rgba(232, 239, 244, 0.98)),
    repeating-linear-gradient(90deg, rgba(47, 125, 91, 0.035) 0 1px, transparent 1px 54px),
    repeating-linear-gradient(0deg, rgba(184, 111, 60, 0.035) 0 1px, transparent 1px 54px);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

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

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

.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;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.header-inner,
.hero-inner,
.page-section,
.site-footer {
  width: min(1160px, calc(100% - 32px));
  margin-inline: auto;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: var(--text);
  font-weight: 800;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.top-nav a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.top-nav a:last-child {
  background: var(--accent);
  color: #fff;
}

.top-nav a:focus-visible,
.top-nav a:hover {
  outline: 2px solid transparent;
  box-shadow: 0 0 0 3px rgba(92, 133, 165, 0.22);
}

.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(120deg, rgba(255, 250, 240, 0.96), rgba(226, 239, 229, 0.96) 58%, rgba(224, 237, 244, 0.92));
  box-shadow: 0 14px 40px rgba(43, 61, 50, 0.08);
}

.hero::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 6px;
  content: "";
  background: linear-gradient(90deg, var(--accent), #e0a553, #6f93a6);
}

.hero-inner {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  padding: 38px 0 30px;
}

.eyebrow,
.section-kicker,
.contact-kicker {
  margin: 0 0 8px;
  color: var(--warm);
  font-size: 0.84rem;
  font-weight: 900;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 720px;
  margin-bottom: 0;
  font-size: clamp(2rem, 4vw, 3.45rem);
  line-height: 1.06;
  letter-spacing: 0;
}

.intro {
  max-width: 670px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.summary {
  display: grid;
  gap: 8px;
  min-width: 158px;
  padding: 16px;
  border: 1px solid rgba(47, 125, 91, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 10px 28px rgba(34, 51, 40, 0.08);
  color: var(--accent-dark);
  font-weight: 800;
  text-align: right;
  backdrop-filter: blur(8px);
}

.page-section {
  margin-top: 24px;
}

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

.section-heading h2 {
  margin-bottom: 0;
  font-size: 1.24rem;
  line-height: 1.25;
}

.seller-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.seller-card {
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 16px;
  border: 1px solid rgba(29, 37, 32, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(255, 250, 240, 0.72)),
    var(--surface);
  box-shadow: 0 10px 26px rgba(28, 42, 34, 0.08);
  color: var(--muted);
  text-align: left;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.seller-card:hover,
.seller-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(47, 125, 91, 0.45);
  box-shadow: var(--shadow);
  outline: none;
}

.seller-card.is-active {
  border-color: rgba(47, 125, 91, 0.65);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(226, 239, 229, 0.9)),
    var(--surface);
  color: var(--accent-dark);
}

.seller-card-kicker {
  color: var(--warm);
  font-size: 0.84rem;
  font-weight: 900;
  text-transform: uppercase;
}

.seller-card strong {
  color: var(--text);
  font-size: 1.08rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.seller-card span:last-child {
  font-size: 0.9rem;
  font-weight: 800;
}

.toolbar {
  margin-top: 20px;
}

.filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

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

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-weight: 800;
}

.filter-button.is-active,
.filter-button:hover,
.filter-button:focus-visible {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  outline: none;
}

.search-field {
  flex: 0 1 300px;
}

.search-field input {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  outline: none;
}

.search-field input:focus {
  border-color: var(--focus);
  box-shadow: 0 0 0 3px rgba(92, 133, 165, 0.18);
}

.contact-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px;
  border: 1px solid rgba(47, 125, 91, 0.2);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(238, 244, 234, 0.86)),
    var(--surface);
}

.contact-panel[hidden] {
  display: none;
}

.contact-copy h3 {
  margin-bottom: 6px;
  font-size: 1.1rem;
}

.contact-text,
.contact-meta p {
  margin-bottom: 0;
  color: var(--muted);
}

.contact-meta {
  display: grid;
  gap: 4px;
  margin-top: 10px;
  font-size: 0.92rem;
  font-weight: 650;
}

.contact-action {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 0 0 auto;
}

.primary-action,
.secondary-action {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 8px;
  font-weight: 800;
}

.primary-action {
  background: var(--accent);
  color: #fff;
}

.secondary-action {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--accent-dark);
}

.item-region {
  padding-bottom: 48px;
}

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

.item-card {
  overflow: hidden;
  border: 1px solid rgba(29, 37, 32, 0.1);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(28, 42, 34, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.item-card:hover,
.item-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(47, 125, 91, 0.42);
  box-shadow: var(--shadow);
  outline: none;
}

.card-image-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #e7ece5;
}

.card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}

.item-card:hover .card-image {
  transform: scale(1.025);
}

.image-fallback {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  color: var(--muted);
  font-weight: 800;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.card-image-wrap .status-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  box-shadow: 0 8px 18px rgba(29, 37, 32, 0.12);
}

.status-available {
  background: var(--surface-soft);
  color: var(--accent-dark);
}

.status-reserved {
  background: var(--reserved-soft);
  color: var(--reserved);
}

.status-later {
  background: #fff2d8;
  color: #8a5814;
}

.status-sold {
  background: var(--sold-soft);
  color: var(--sold);
}

.item-card.status-sold .card-image {
  filter: grayscale(0.85);
}

.card-body {
  display: grid;
  gap: 12px;
  padding: 15px;
}

.card-title-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: start;
}

.card-title-row h2 {
  margin-bottom: 0;
  font-size: 1.02rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.price {
  color: var(--accent-dark);
  font-weight: 900;
  white-space: nowrap;
}

.description {
  display: -webkit-box;
  min-height: 44px;
  margin-bottom: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.93rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-facts {
  display: grid;
  gap: 6px;
  color: #4d554d;
  font-size: 0.85rem;
  font-weight: 800;
}

.card-facts span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-meta span {
  padding: 3px 8px;
  border-radius: 999px;
  background: #f4f0e8;
  color: #655f55;
  font-size: 0.76rem;
  font-weight: 800;
}

.empty-state {
  margin: 60px 0;
  color: var(--muted);
  font-size: 1.05rem;
  font-weight: 750;
  text-align: center;
}

.item-dialog {
  width: min(960px, calc(100% - 28px));
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(18, 28, 22, 0.28);
}

.item-dialog::backdrop {
  background: rgba(13, 20, 16, 0.52);
}

.dialog-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  font-size: 1.45rem;
  line-height: 1;
}

.dialog-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  min-height: 520px;
}

.gallery {
  display: grid;
  grid-template-rows: 1fr auto;
  min-width: 0;
  background: #e6ece7;
}

.gallery-stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 420px;
  overflow: hidden;
}

.dialog-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text);
  font-size: 2rem;
  transform: translateY(-50%);
}

.gallery-prev {
  left: 12px;
}

.gallery-next {
  right: 12px;
}

.image-counter {
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(29, 37, 32, 0.72);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 900;
}

.thumb-strip {
  display: flex;
  gap: 8px;
  min-height: 74px;
  padding: 10px;
  overflow-x: auto;
  border-top: 1px solid rgba(29, 37, 32, 0.1);
}

.thumb {
  width: 66px;
  height: 54px;
  flex: 0 0 auto;
  overflow: hidden;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  background: #d9e0da;
}

.thumb.is-active {
  border-color: var(--accent);
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dialog-content {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 34px 30px 30px;
}

.dialog-seller {
  margin-bottom: -4px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.dialog-content h2 {
  margin-bottom: 0;
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  line-height: 1.1;
}

.dialog-price {
  margin-bottom: 0;
  color: var(--accent-dark);
  font-size: 1.5rem;
  font-weight: 900;
}

.dialog-description,
.dialog-notes {
  margin-bottom: 0;
  color: var(--muted);
}

.dialog-details {
  display: grid;
  gap: 10px;
  margin: 2px 0 0;
}

.dialog-details div {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.dialog-details dt {
  color: #5d675f;
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.dialog-details dd {
  min-width: 0;
  margin: 0;
  color: var(--text);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.product-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  background: var(--text);
  color: #fff;
  font-weight: 900;
  text-decoration: none;
}

.product-link:hover,
.product-link:focus-visible {
  background: var(--accent-dark);
  outline: none;
}

.dialog-notes {
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-weight: 700;
}

.site-footer {
  padding: 28px 0 40px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.88rem;
  text-align: center;
}

.site-footer p {
  margin-bottom: 0;
}

@media (max-width: 760px) {
  .header-inner {
    align-items: flex-start;
    flex-direction: column;
    padding: 12px 0;
  }

  .brand {
    width: 100%;
  }

  .top-nav {
    width: 100%;
  }

  .top-nav a {
    flex: 1 1 0;
    justify-content: center;
  }

  .hero-inner {
    align-items: stretch;
    flex-direction: column;
    padding: 28px 0 26px;
  }

  .summary {
    grid-template-columns: repeat(2, 1fr);
    text-align: left;
  }

  .filter-row,
  .contact-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .search-field {
    flex-basis: auto;
  }

  .item-grid {
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  }

  .dialog-layout {
    grid-template-columns: 1fr;
  }

  .gallery-stage {
    min-height: 300px;
  }

  .dialog-content {
    padding: 24px 20px 24px;
  }
}

@media (max-width: 460px) {
  .header-inner,
  .hero-inner,
  .page-section,
  .site-footer {
    width: min(100% - 22px, 1160px);
  }

  h1 {
    font-size: 2rem;
  }

  .seller-grid,
  .item-grid {
    grid-template-columns: 1fr;
  }

  .filter-button {
    flex: 1 1 42%;
  }

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