.hs-wg-bar { background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.hs-wg-top { display: flex; gap: 12px; align-items: stretch; flex-wrap: wrap; }
.hs-wg-input-wrap { flex: 1 1 260px; max-width: 100%; display: flex; align-items: center; gap: 8px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 4px 12px; min-height: 44px; }
.hs-wg-input { flex: 1; border: 0; background: transparent; font-family: var(--font-hanzi); font-size: 22px; color: var(--text); min-width: 0; outline: none; }
.hs-wg-count { font-family: var(--font-mono); font-size: 12px; color: var(--muted); white-space: nowrap; }
.hs-wg-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.hs-wg-presets { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hs-wg-presets-lbl { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }
.hs-chip { min-height: 32px; padding: 4px 12px; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); color: var(--text); font-family: var(--font-body); font-size: 14px; font-weight: 500; cursor: pointer; }
.hs-chip:hover { border-color: var(--primary); color: var(--primary); }
.hs-wg-options { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.hs-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.hs-field label { font-size: 12px; font-weight: 700; color: var(--muted); }
.hs-field select, .hs-field input[type="text"] { width: 100%; height: 38px; padding: 0 8px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); font-family: var(--font-body); font-size: 14px; font-weight: 500; }
.hs-wg-toggles { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 4px; border-top: 1px solid var(--border); }
.hs-chk-row { display: flex; gap: 16px; flex-wrap: wrap; }
.hs-chk-lbl { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; cursor: pointer; }
.hs-chk-lbl input { width: 16px; height: 16px; accent-color: var(--primary); }
.hs-wg-status { font-size: 14px; color: var(--accent); font-weight: 500; margin: 0; }
.hs-wg-pages { margin-top: 24px; display: flex; flex-direction: column; gap: 24px; align-items: center; }
.hs-sheet-paper { width: 100%; max-width: 820px; background: #ffffff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-md); padding: 28px 32px; color: #18221e; }
.hs-sheet-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; padding-bottom: 12px; margin-bottom: 16px; border-bottom: 2px solid #18221e; flex-wrap: wrap; }
.hs-sheet-title { font-family: var(--font-display); font-size: 22px; font-weight: 700; margin: 0; }
.hs-sheet-meta { display: flex; gap: 24px; font-size: 14px; color: #4b5c55; }
.hs-meta-blank { display: inline-block; width: 110px; border-bottom: 1px solid #4b5c55; margin-left: 4px; }
.hs-sheet-rows { display: flex; flex-direction: column; gap: 16px; }
.hs-entry { display: flex; flex-direction: column; gap: 8px; }
.hs-entry-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 14px; }
.hs-entry-info { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.hs-entry-py { font-weight: 700; color: var(--primary); }
.hs-entry-mean { color: #4b5c55; }
.hs-entry-strokes { font-family: var(--font-mono); font-size: 12px; color: #4b5c55; }
.hs-entry-anim-btn { border: 1px solid var(--border); background: var(--surface-muted); color: var(--text); font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: 8px; cursor: pointer; }
.hs-entry-anim-btn:hover { border-color: var(--primary); color: var(--primary); }
.hs-strip-row { display: flex; flex-wrap: wrap; gap: 4px; }
.hs-strip-box { width: 28px; height: 28px; border: 1px solid #d5dfd7; background: #fafcfa; border-radius: 4px; display: inline-flex; align-items: center; justify-content: center; }
.hs-strip-box svg { width: 24px; height: 24px; display: block; }
.hs-cell-grid { display: grid; gap: 4px; }
.hs-cell-btn { padding: 0; border: 0; background: transparent; cursor: pointer; display: block; width: 100%; aspect-ratio: 1 / 1; border-radius: 4px; }
.hs-cell-btn:hover { box-shadow: 0 0 0 2px var(--primary); }
.hs-cell-box { width: 100%; aspect-ratio: 1 / 1; }
.hs-cell-box svg, .hs-cell-btn svg { width: 100%; height: 100%; display: block; }
.hs-sheet-foot { margin-top: 16px; padding-top: 8px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; font-size: 12px; color: #4b5c55; }
.hs-wg-empty { text-align: center; padding: 32px 16px; color: var(--muted); }
.hs-modal-backdrop { position: fixed; inset: 0; background: rgba(24, 34, 30, 0.52); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 80; }
.hs-modal-card { width: 100%; max-width: 400px; background: var(--surface); border-radius: var(--radius); border: 1px solid var(--border); box-shadow: var(--shadow-md); padding: 24px; }
.hs-modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.hs-modal-head .hs-modal-title { margin: 0; font-size: 22px; font-weight: 700; font-family: var(--font-display); }
.hs-modal-canvas { width: 220px; height: 220px; margin: 12px auto; border: 2px solid var(--primary); border-radius: 8px; background: #fffaf9; position: relative; }
.hs-modal-actions { display: flex; gap: 8px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
@media (max-width: 900px) { .hs-wg-options { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .hs-wg-input-wrap { flex-basis: 100%; }
  .hs-wg-input { min-width: 100px; }
  .hs-wg-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hs-sheet-paper { padding: 16px; }
  .hs-wg-actions { width: 100%; }
  .hs-wg-actions .hs-btn { flex: 1 1 auto; }
}
@media print {
  .hs-wg-pages { margin-top: 0 !important; gap: 0 !important; }
  .hs-sheet-paper { max-width: none !important; border: 0 !important; box-shadow: none !important; border-radius: 0 !important; padding: 8mm 10mm !important; break-after: page; page-break-after: always; }
  .hs-sheet-paper:last-child { break-after: auto; page-break-after: auto; }
  .hs-entry-anim-btn { display: none !important; }
}