:root {
  --bg: #fafaf7;
  --ink: #1a1a1a;
  --muted: #6b6b6b;
  --line: #e5e3dc;
  --accent: #8b3a2a;
  --card: #ffffff;
  --maxw: 1200px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Iowan Old Style", "Georgia", "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

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

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  padding: 20px 0;
}
.site-header .container {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.site-title { line-height: 0; }
.site-title a { display: inline-block; }
.site-title img {
  height: 56px;
  width: auto;
  display: block;
}
@media (max-width: 600px) {
  .site-title img { height: 40px; }
}
.site-nav a {
  margin-left: 24px;
  color: var(--ink);
  font-size: 15px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.site-nav a:hover, .site-nav a.active {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
}

/* Footer */
.site-footer {
  margin-top: 80px;
  padding: 32px 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}
.site-footer .container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }

/* Hero / page header */
.page-header {
  padding: 56px 0 32px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 40px;
}
.page-header h1 {
  margin: 0 0 12px;
  font-size: 38px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.page-header .lede {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
  max-width: 720px;
}

/* Home */
.hero {
  padding: 64px 0;
  border-bottom: 1px solid var(--line);
}
.hero h1 {
  margin: 0 0 16px;
  font-size: 44px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.hero p {
  margin: 0;
  font-size: 19px;
  color: var(--muted);
  max-width: 720px;
}
.home-section { margin: 48px 0; }
.home-section h2 {
  font-size: 22px;
  margin: 0 0 20px;
  font-weight: 500;
}

/* Card grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 28px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  overflow: hidden;
  transition: box-shadow 120ms ease;
  display: flex;
  flex-direction: column;
}
.card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.06); }
.card a { color: inherit; display: block; }
.card-img {
  aspect-ratio: 1 / 1;
  background: #f0eee7 center/contain no-repeat;
  border-bottom: 1px solid var(--line);
}
.card-img.placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 13px;
}
.card-body { padding: 14px 16px 18px; }
.card-title {
  font-size: 16px;
  margin: 0 0 4px;
  font-weight: 500;
}
.card-meta {
  font-size: 13px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

/* Status badges */
.badge {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 2px;
  background: #efece4;
  color: #5a5a5a;
  border: 1px solid var(--line);
}
.badge.sold { background: #2c2c2c; color: #fff; border-color: #2c2c2c; }
.badge.consigned { background: #f0e3d4; color: #6b3a14; border-color: #e2cdb1; }
.badge.listed { background: #e0ebd9; color: #3d5a2c; border-color: #c8d9bc; }
.badge.inventory { background: #e3e6ed; color: #2c4070; border-color: #c8cfdb; }

/* Piece detail page */
.piece {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 56px;
  margin-top: 16px;
}
@media (max-width: 800px) {
  .piece { grid-template-columns: 1fr; gap: 32px; }
}
.gallery .hero-photo {
  aspect-ratio: 1 / 1;
  background: #f0eee7 center/contain no-repeat;
  border: 1px solid var(--line);
}
.gallery .thumbs {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.gallery .thumbs a {
  width: 64px;
  height: 64px;
  background: #f0eee7 center/cover no-repeat;
  border: 1px solid var(--line);
}
.gallery .thumbs a.active { outline: 2px solid var(--accent); outline-offset: -2px; }

.detail h1 {
  font-size: 30px;
  font-weight: 500;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.detail .ar {
  color: var(--muted);
  font-size: 15px;
  letter-spacing: 0.04em;
  margin-bottom: 20px;
}
.detail .ar a { color: var(--muted); border-bottom: 1px dotted var(--line); }
.detail .status-row { margin-bottom: 24px; }
.detail dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 8px 20px;
  margin: 24px 0;
  font-size: 15px;
}
.detail dt { color: var(--muted); }
.detail dd { margin: 0; }
.detail .price-block {
  margin: 24px 0;
  padding: 18px 20px;
  background: var(--card);
  border: 1px solid var(--line);
}
.detail .price-block .label {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.detail .price-block .value {
  font-size: 22px;
  font-weight: 500;
}
.detail .price-block .meta {
  color: var(--muted);
  font-size: 14px;
  margin-top: 4px;
}
.detail .provenance {
  margin: 24px 0;
  font-size: 15px;
  color: var(--muted);
}

/* About */
.about-content {
  max-width: 720px;
  font-size: 17px;
}
.about-content h2 { font-size: 22px; font-weight: 500; margin-top: 36px; }

/* Print/sm */
@media (max-width: 600px) {
  .site-nav a { margin-left: 14px; font-size: 13px; }
  .page-header h1, .hero h1 { font-size: 30px; }
  .detail h1 { font-size: 24px; }
}
