:root {
  color-scheme: light dark;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background: Canvas;
  color: CanvasText;
}

body {
  margin: 0;
}

main {
  width: min(680px, calc(100% - 32px));
  margin: 12vh auto 0;
}

h1 {
  margin: 0 0 32px;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  line-height: 1.15;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid GrayText;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
}

th,
td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid GrayText;
}

th:not(:first-child),
td:not(:first-child) {
  text-align: right;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.price {
  font-variant-numeric: tabular-nums;
  min-width: 9ch;
}

.status {
  margin: 12px 0 0;
  color: GrayText;
  font-size: 0.8rem;
  line-height: 1.5;
}

button {
  margin-top: 12px;
  padding: 8px 12px;
  border: 1px solid CanvasText;
  border-radius: 0;
  background: Canvas;
  color: CanvasText;
  font: inherit;
  cursor: pointer;
}

button:hover,
button:focus-visible {
  background: CanvasText;
  color: Canvas;
}

.reference {
  margin: 40px 0 12vh;
  padding-top: 24px;
  border-top: 1px solid GrayText;
}

.reference h2 {
  margin: 0;
  font-size: 0.8rem;
  font-weight: normal;
  color: GrayText;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.reference-row {
  margin: 8px 0 0;
  font-size: 1.25rem;
}

@media (max-width: 520px) {
  main {
    margin-top: 8vh;
  }

  table {
    font-size: 0.85rem;
  }

  th,
  td {
    padding: 10px 8px;
  }

  th {
    white-space: normal;
  }

  td {
    white-space: nowrap;
  }

  th:nth-child(3),
  td:nth-child(3) {
    display: none;
  }
}
