[hidden] { display: none !important; }
h1, h2, h3 { overflow-wrap: anywhere; max-inline-size: 100%; }
.flush { margin-top: 0; }
.alert { background: var(--surface); border: 2px solid var(--warn); color: var(--warn); border-radius: 10px; padding: 10px 12px; margin: 0 0 16px; font-weight: 600; overflow-wrap: anywhere; }
.jump { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 8px; }
.jump a { display: inline-flex; align-items: center; min-height: 44px; padding: 6px 12px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); color: var(--ink); text-decoration: none; font-size: 14px; }
section { margin-bottom: 10px; }
h2 { scroll-margin-top: 12px; }

.fgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 140px), 1fr)); gap: 10px 12px; margin: 0 0 10px; }
.fgrid > * { min-width: 0; }
.f.wide { grid-column: 1 / -1; }
.f label { display: block; font-size: 13px; color: var(--muted); margin: 0 0 2px; }
.f textarea { resize: vertical; }
label.btn { display: inline-flex; align-items: center; }
#import-file:focus-visible + label.btn { outline: 3px solid var(--accent); outline-offset: 2px; }
h3.flush { margin: 0 0 8px; }
form.card { margin-top: 12px; }

.list { list-style: none; padding: 0; margin: 12px 0 0; }
.list li { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 8px; align-items: start; }
.list .t { font-weight: 600; overflow-wrap: anywhere; }
.list .meta { grid-column: 1 / -1; font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.list .acts { display: flex; gap: 4px; align-items: start; flex-wrap: wrap; justify-content: flex-end; }
.list .acts button { min-height: 44px; padding: 6px 12px; font-size: 14px; }
.list .pk { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; font-size: 13px; color: var(--muted); }
.list .pk .pill { margin: 0; }

.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.badge { display: inline-block; padding: 1px 7px; border-radius: 99px; font-size: 12px; font-weight: 600; border: 1px solid var(--line); }
.badge.good { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.badge.fair { background: var(--chip); color: var(--ink); border-color: var(--line); }
.badge.poor { background: var(--surface); color: var(--warn); border-color: var(--warn); }

.tbl-scroll { overflow-x: auto; max-width: 100%; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); margin: 8px 0; }
.tbl { width: 100%; border-collapse: collapse; margin: 0; }
.tbl th, .tbl td { padding: 5px 8px; border-bottom: 1px solid var(--line); font-size: 13px; white-space: nowrap; vertical-align: middle; }
.tbl tbody tr:last-child th, .tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tr.selected { box-shadow: inset 4px 0 0 var(--accent); font-weight: 700; }
.tbl td button { min-height: 44px; min-inline-size: 44px; padding: 6px 12px; font-size: 14px; }

#share-url, #share-text { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 16px; margin-bottom: 8px; }
button, .btn, input, select, textarea { min-height: 44px; font-size: 16px; max-inline-size: 100%; }
body .language-control select { font-size: 16px; }
button, .btn, .jump a, summary { overflow-wrap: anywhere; }
input[type="date"], input[type="time"] { min-inline-size: 0; direction: ltr; }
.check { display: flex; gap: 10px; align-items: center; margin-block: 16px; }
.check input { width: 22px; min-height: 22px; height: 22px; flex: 0 0 22px; }
.check { min-height: 44px; }
.preview { border: 2px solid var(--accent); margin-block: 20px; }
.preview p, [role="status"] { overflow-wrap: anywhere; }
.recovery { margin-block: 18px; }
summary { min-height: 44px; padding-block: 8px; cursor: pointer; }
summary:focus-visible, .tbl-scroll:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.tbl th, .tbl td { text-align: start; }
[dir="rtl"] .tbl tr.selected { box-shadow: inset -4px 0 0 var(--accent); }
@media (max-width: 420px) { .fgrid { grid-template-columns: minmax(0, 1fr); } .list li { grid-template-columns: minmax(0, 1fr); } .list .acts { justify-content: flex-start; } }
@media screen { header.top .brand { display: inline-flex; align-items: center; min-block-size: 44px; } }
