.list-settings input[type="text"], .list-settings select {
  display: block;
  width: 100%;
  margin-top: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #fff;
}

.list-sheet {
  width: min(100%, 794px);
  min-height: 1123px;
  margin: 0 auto 24px;
  padding: 48px 52px;
  background: #fff;
  box-shadow: 0 6px 30px rgba(20, 50, 40, .13);
  break-after: page;
}

.list-sheet:last-child { break-after: auto; }
.list-sheet > header { display: flex; align-items: flex-end; justify-content: space-between; border-bottom: 3px solid var(--green); padding-bottom: 12px; margin-bottom: 18px; }
.list-sheet h1 { margin: 0; font-size: 28px; }
.list-sheet > header span { color: var(--muted); font-size: 12px; }
.selected-list-table { width: 100%; min-width: 0; border: 1px solid var(--line); }
.selected-list-table th { position: static; background: #eaf5ef; color: #315f50; font-size: 12px; }
.selected-list-table th, .selected-list-table td { border: 1px solid #dfe8e4; padding: 8px 10px; }
.selected-list-table td { height: 35px; }
.selected-list-table .number-col { width: 52px; }
.selected-list-table .mora-col { width: 68px; }
.selected-list-table .list-word { font-size: 16px; font-weight: 800; }
.format-hint { margin: 8px 0 2px; padding: 9px; border-radius: 8px; background: var(--green2); text-align: left; line-height: 1.55; }
.position-list-sheet { padding: 34px 38px; }
.position-list-sheet > header { margin-bottom: 12px; }
.position-list-sheet > header > div { min-width: 0; }
.position-list-sheet > header p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.position-list-table { width: 100%; min-width: 0; table-layout: fixed; border: 1.4px solid #45504c; font-size: 10px; line-height: 1.35; }
.position-list-table th { position: static; padding: 6px; border: 1px solid #55605c; background: #f4f7f5; color: var(--ink); text-align: center; font-size: 11px; }
.position-list-table td { height: 58px; padding: 6px 7px; border: 1px solid #68716e; vertical-align: top; overflow-wrap: anywhere; }
.position-list-table thead th:first-child, .position-list-table .sound-col { width: 44px; }
.position-list-table .sound-col { background: #fafbf9; font-size: 17px; font-weight: 800; vertical-align: middle; }
.mora-group { display: flex; align-items: flex-start; gap: 4px; margin-bottom: 3px; }
.mora-group:last-child { margin-bottom: 0; }
.mora-group b { flex: 0 0 auto; color: #1f6551; font-size: 9px; }
.mora-group span { min-width: 0; }
.no-words { color: #a2aaa7; }
.position-empty { margin-top: 80px; padding: 30px; border: 1px dashed var(--line); border-radius: 12px; text-align: center; color: var(--muted); }
.position-empty strong { color: var(--ink); font-size: 16px; }

@media print {
  #selectedListPage .list-settings, #selectedListPage .preview-head { display: none !important; }
  #selectedListPage { padding: 0; margin: 0; max-width: none; }
  #selectedListPreview { display: block; }
  .list-sheet { width: 210mm; min-height: 297mm; margin: 0; padding: 12mm 14mm; box-shadow: none; }
  .selected-list-table th, .selected-list-table td { padding: 2.1mm 2.5mm; }
  .position-list-sheet { padding: 8mm 9mm; }
  .position-list-table { font-size: 8pt; }
  .position-list-table th { padding: 1.5mm; font-size: 8.5pt; }
  .position-list-table td { height: 13mm; padding: 1.4mm 1.8mm; }
  .position-list-table tr { break-inside: avoid; }
  .mora-group b { font-size: 7.5pt; }
}
