.draw-history {
  gap: 16px;
}

.history-column {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: rgba(248, 245, 239, 0.56);
}

.history-pinned-column {
  background: linear-gradient(145deg, rgba(249, 239, 211, 0.72), rgba(255, 255, 255, 0.82));
}

.history-column-head,
.history-item-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.history-column-head {
  justify-content: space-between;
  margin-bottom: 10px;
}

.history-column-head h3 {
  margin: 0;
  font-size: 1rem;
}

.history-column-head span {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.history-list {
  display: grid;
  gap: 10px;
}

.history-pin {
  width: 30px;
  min-width: 30px;
  height: 30px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0;
  background: #fff;
  filter: grayscale(1);
  opacity: 0.62;
  cursor: pointer;
}

.history-pin:hover,
.history-pin:focus-visible,
.history-pin.is-selected {
  border-color: #a76d18;
  background: #fff4d6;
  filter: none;
  opacity: 1;
}

.history-item.is-pinned {
  border-color: rgba(167, 109, 24, 0.42);
}

@media (min-width: 561px) {
  .draw-history {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }

  .history-list {
    max-height: min(560px, 64vh);
    overflow-y: auto;
    padding-right: 8px;
    scrollbar-gutter: stable;
    overscroll-behavior: contain;
  }

  .history-list::-webkit-scrollbar { width: 9px; }
  .history-list::-webkit-scrollbar-track {
    border-radius: 999px;
    background: rgba(18, 18, 18, 0.06);
  }
  .history-list::-webkit-scrollbar-thumb {
    border: 2px solid transparent;
    border-radius: 999px;
    background: rgba(18, 18, 18, 0.3);
    background-clip: padding-box;
  }
}
.history-toolbar {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
}

.history-toolbar-hint {
  color: var(--ink-muted, #6b7280);
  font-size: 0.78rem;
}

.history-toolbar button {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 14px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 900;
  cursor: pointer;
}
