/* ============ Version history ============ */
.modal.history-modal { width: min(560px, calc(100vw - 32px)); padding: 0; display: flex; flex-direction: column; max-height: min(720px, calc(100dvh - 48px)); }
.hs { display: flex; flex-direction: column; min-height: 0; }
.hs-head { display: flex; align-items: flex-start; gap: 12px; padding: 18px 14px 12px 24px; }
.hs-head > div { flex: 1; min-width: 0; }
.hs-head h3 { display: flex; align-items: center; gap: 9px; margin: 0; font-size: 18px; }
.hs-head h3 svg.i { color: var(--accent); }
.hs-sub { margin-top: 3px; font-size: 12.5px; color: var(--text-3); }
.hs-save { display: flex; gap: 8px; padding: 0 24px 14px; border-bottom: 1px solid var(--border); }
.hs-save input { flex: 1; min-width: 0; height: 36px; padding: 0 11px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text); font-size: 13px; outline: 0; }
.hs-save input:focus { border-color: var(--accent); }
.hs-save .btn { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.hs-save .btn svg.i, .hs-actions .btn svg.i { width: 15px; height: 15px; }
.hs-save.busy { opacity: .6; pointer-events: none; }
.hs-list { overflow-y: auto; padding: 4px 12px 14px; }
.hs-list h4 { margin: 14px 12px 4px; font-size: 11.5px; font-weight: 650; letter-spacing: .05em; text-transform: uppercase; color: var(--text-3); }
.hs-item { display: grid; grid-template-columns: auto 1fr; column-gap: 12px; padding: 9px 12px; border-radius: 11px; cursor: pointer; transition: background-color .15s; }
.hs-item:hover, .hs-item.open { background: var(--hover); }
.hs-dot { width: 9px; height: 9px; margin-top: 6px; border-radius: 50%; background: var(--text-3); }
.hs-dot.manual { background: var(--accent); }
.hs-dot.restore { background: var(--warn, #E9A21F); }
.hs-main { min-width: 0; }
.hs-main b { display: block; font-size: 13.5px; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hs-main span { font-size: 12px; color: var(--text-3); }
.hs-more { grid-column: 2; }
.hs-more:empty { display: none; }
.hs-note { display: block; margin-top: 8px; font-size: 12.5px; color: var(--text-2); line-height: 1.45; }
.hs-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }
.hs-actions .btn { display: inline-flex; align-items: center; gap: 6px; }
.hs-empty { padding: 28px 16px; text-align: center; font-size: 13px; color: var(--text-3); line-height: 1.5; }
@media (max-width: 480px) { .hs-save { flex-direction: column; } }
