:root {
  --page-bg: #000;
  --ink: #EDEAE4;
  --ink-soft: #BDB7AD;
  --gold: #C6A15D;
  --gold-dim: rgba(198, 161, 93, 0.22);
  --row: #0b0b0b;
  --font-display: "Cormorant Garamond", "Iowan Old Style", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --max: 1180px;
}
* { box-sizing: border-box; }
html, body {
  margin: 0;
  background: var(--page-bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  min-height: 100vh;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gold); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #fff; }
.wrap { width: min(100% - 2rem, var(--max)); margin-inline: auto; }

.site-header {
  padding: 1.6rem 0 1.25rem;
  border-bottom: 1px solid var(--gold-dim);
}
.brand-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.brand-mark {
  font-weight: 700;
  letter-spacing: 0.01em;
  font-size: 1.05rem;
}
.view-only {
  display: inline-block;
  border: 1.5px solid var(--gold);
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  white-space: nowrap;
}
.exhibition {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.45rem, 3.2vw, 2.15rem);
  line-height: 1.2;
  margin: 0.85rem 0 0.45rem;
  max-width: 40rem;
}
.meta, .updated {
  color: var(--ink-soft);
  font-size: 0.92rem;
  margin: 0.15rem 0;
}
.updated { margin-top: 0.55rem; font-size: 0.82rem; letter-spacing: 0.04em; }

.toolbar {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1.1rem 0 0.85rem;
  flex-wrap: wrap;
}
.toolbar label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.toolbar input[type="search"] {
  flex: 1 1 16rem;
  background: #111;
  color: var(--ink);
  border: 1px solid rgba(237, 234, 228, 0.25);
  border-radius: 6px;
  padding: 0.65rem 0.85rem;
  font: inherit;
  min-width: 0;
}
.toolbar input[type="search"]:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  border-color: var(--gold);
}
.count { color: var(--ink-soft); font-size: 0.85rem; white-space: nowrap; }

.table-wrap { overflow-x: auto; padding-bottom: 1.5rem; }
table.register {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
}
thead th {
  text-align: left;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 700;
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--gold-dim);
  background: #000;
  position: sticky;
  top: 0;
  white-space: nowrap;
}
thead th.sortable {
  cursor: pointer;
  user-select: none;
}
thead th.sortable:hover { color: #fff; }
thead th[aria-sort="ascending"]::after { content: " ▲"; font-size: 0.65em; }
thead th[aria-sort="descending"]::after { content: " ▼"; font-size: 0.65em; }
thead th.price, td.price { text-align: right; }
tbody tr {
  background: var(--row);
  border-bottom: 1px solid rgba(198, 161, 93, 0.12);
}
tbody tr:hover { background: #141414; }
tbody tr.is-hidden { display: none; }
td {
  padding: 0.7rem 0.65rem;
  vertical-align: middle;
  font-size: 0.95rem;
}
td.id {
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
  font-size: 0.88rem;
  white-space: nowrap;
}
td.photo { width: 5.5rem; }
td.photo .thumb {
  width: 4.5rem;
  height: 4.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}
td.photo img {
  max-width: 4.5rem;
  max-height: 4.5rem;
  width: auto;
  height: auto;
  object-fit: contain;
  background: #000;
}
td.photo .no-photo {
  width: 4.5rem;
  height: 4.5rem;
  border: 1px dashed rgba(237, 234, 228, 0.18);
  color: #666;
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
td.title { font-weight: 600; }
td.price { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; color: var(--gold); }
td.size { color: var(--ink-soft); white-space: nowrap; }
td.medium, td.framing { color: var(--ink-soft); }
td.medium, td.framing { max-width: 16rem; }

.filter-empty { display: none; color: var(--ink-soft); padding: 2rem 0; text-align: center; }
.filter-empty.show { display: block; }

.site-footer {
  border-top: 1px solid var(--gold-dim);
  padding: 1.4rem 0 2.2rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
}
.site-footer p { margin: 0.2rem 0; }
.note { font-size: 0.8rem; margin-top: 0.7rem !important; }

@media (max-width: 700px) {
  table.register { min-width: 0; }
  thead { display: none; }
  tbody tr {
    display: grid;
    grid-template-columns: 5.2rem 1fr;
    grid-template-areas:
      "photo title"
      "photo id"
      "photo size"
      "photo medium"
      "photo framing"
      "photo price";
    gap: 0.15rem 0.7rem;
    padding: 0.85rem 0.4rem;
    margin-bottom: 0.65rem;
    border: 1px solid var(--gold-dim);
    border-radius: 8px;
    background: var(--row);
  }
  td {
    padding: 0;
    max-width: none;
    border: 0;
  }
  td.photo { grid-area: photo; }
  td.title { grid-area: title; font-size: 1.05rem; }
  td.id { grid-area: id; }
  td.size { grid-area: size; }
  td.medium { grid-area: medium; }
  td.framing { grid-area: framing; }
  td.price { grid-area: price; text-align: left; font-size: 1.05rem; }
  td.id::before,
  td.size::before,
  td.medium::before,
  td.framing::before { 
    color: var(--gold);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-right: 0.4rem;
  }
  td.id::before { content: "ID "; }
  td.size::before { content: "Size "; }
  td.medium::before { content: "Medium "; }
  td.framing::before { content: "Framing "; }
  td.medium:empty, td.framing:empty, td.size:empty { display: none; }
}
