#wordsPanel .query-bar { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 12px; padding: 22px 30px 16px; }
#wordsPanel .seed-field { display: grid; gap: 7px; width: 340px; max-width: 100%; color: #555d68; font-size: 12px; }
#wordsPanel .seed-field input { width: 100%; font-size: 14px; }
#wordsPanel .check-label { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; white-space: nowrap; font-size: 13px; color: #555d68; }
#wordsPanel .progress-section { padding: 0 30px 20px; }
#wordsPanel .progress-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: 12px; color: var(--muted); min-height: 28px; overflow-wrap: anywhere; }
#wordsPanel #wordsStatus[data-kind="busy"] { color: var(--accent); }
#wordsPanel #wordsStatus[data-kind="error"] { color: #b42318; }
#wordsPanel progress { display: block; width: 100%; height: 5px; border: 0; background: #edf0f4; border-radius: 3px; overflow: hidden; }
#wordsPanel progress::-webkit-progress-bar { background: #edf0f4; }
#wordsPanel progress::-webkit-progress-value { background: var(--accent); }
#wordsPanel .error-box { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; padding: 10px 12px; background: #fff7f5; border-left: 3px solid #d06b55; font-size: 13px; }
#wordsPanel .error-box p { margin: 0; color: #9b3e2f; flex: 1; overflow-wrap: anywhere; }
#wordsPanel .error-box button { font-size: 12px; min-height: 30px; padding: 4px 8px; }
#wordsPanel .summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 20px 30px; border-block: 1px solid var(--line); background: #fafbfc; }
#wordsPanel .summary > div { padding-left: 24px; border-left: 1px solid var(--line); min-width: 0; }
#wordsPanel .summary > div:first-child { padding-left: 0; border: 0; }
#wordsPanel .summary span, #wordsPanel .summary small { display: block; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
#wordsPanel .summary strong { display: block; margin: 6px 0; font-size: 27px; line-height: 1.3; font-weight: 650; font-variant-numeric: tabular-nums; }
#wordsPanel #wordsRisingCount { color: #287253; }
#wordsPanel #wordsUncoveredCount { color: #aa6420; }
#wordsPanel .result-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; padding: 22px 30px 14px; }
#wordsPanel h2 { margin: 0; font-size: 16px; font-weight: 650; }
#wordsPanel h2 span { color: var(--muted); font-size: 13px; font-weight: 400; margin-left: 6px; }
#wordsPanel .scope-note { font-size: 12px; color: var(--muted); }
#wordsPanel .export-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-left: auto; }
#wordsPanel .export-actions button, #wordsPanel .export-actions select { font-size: 12px; }
#wordsPanel .table-filters { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 0 30px 10px; }
#wordsPanel .table-filters input, #wordsPanel .table-filters select, #wordsPanel .table-filters button { font-size: 12px; }
#wordsPanel #wordsFilterSearch { width: 230px; }
#wordsPanel #wordsMinIndex { width: 140px; height:40px; border:1px solid #d6dfe9; border-radius:7px; padding:8px 12px; background:white; color:#35475d; }
#wordsPanel .selection-bar { display: flex; align-items: center; gap: 10px; padding: 0 30px 8px; font-size: 12px; color: var(--muted); min-height: 30px; }
#wordsPanel .selection-bar button { min-height: 28px; padding: 3px 6px; font-size: 12px; }
#wordsPanel #wordsNotice { margin-left: auto; color: #287253; }
#wordsPanel #wordsNotice[data-error="true"] { color: #b42318; }
#wordsPanel .table-scroll { overflow: auto; max-height: 620px; border-block: 1px solid var(--line); }
#wordsPanel table { width: 100%; min-width: 1390px; border-collapse: separate; border-spacing: 0; table-layout: fixed; font-size: 13px; }
#wordsPanel .select-col { width: 44px; }
#wordsPanel .number-col { width: 64px; }
#wordsPanel .keyword-col { width: 300px; }
#wordsPanel .source-col { width: 175px; }
#wordsPanel .metric-col { width: 115px; }
#wordsPanel .coverage-col { width: 93px; }
#wordsPanel .state-col { width: 126px; }
#wordsPanel th { position: sticky; top: 0; z-index: 2; background: #f5f6f8; height: 46px; color: #626975; font-weight: 500; font-size: 12px; border-bottom: 1px solid #e0e3e9; }
#wordsPanel th button { background: transparent; border: 0; padding: 5px 3px; font-size: 12px; color: inherit; }
#wordsPanel th[aria-sort="ascending"] button::after { content: " ↑"; color: var(--accent); }
#wordsPanel th[aria-sort="descending"] button::after { content: " ↓"; color: var(--accent); }
#wordsPanel td { padding: 11px 9px; height: 49px; border-bottom: 1px solid #edf0f3; text-align: center; color: #424952; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; background: #fff; }
#wordsPanel tbody tr:nth-child(even) td { background: #fbfcfd; }
#wordsPanel tbody tr:hover td { background: #f0f5fd; }
#wordsPanel tbody tr[data-selected="true"] td { background: #eef4ff; }
#wordsPanel td.keyword { text-align: left; padding-left: 12px; }
#wordsPanel td.keyword a { color: #243449; text-decoration: none; line-height: 1.6; }
#wordsPanel td.keyword a:hover { color: var(--accent); text-decoration: underline; }
#wordsPanel td.keyword .row-copy { float: right; opacity: 0; min-height: 25px; width: 25px; padding: 4px; margin-left: 5px; border-color: transparent; }
#wordsPanel tr:hover .row-copy, #wordsPanel .row-copy:focus-visible { opacity: 1 !important; }
#wordsPanel td.source { font-size: 12px; color: var(--muted); }
#wordsPanel td.state { font-size: 12px; color: var(--muted); }
#wordsPanel .up { color: #287253; }
#wordsPanel .down { color: #b4523e; }
#wordsPanel .missing { color: #9096a0; }
#wordsPanel .covered { color: #4c725f; }
#wordsPanel .uncovered { color: #9b6325; }
#wordsPanel .state[data-state="pending"], #wordsPanel .state[data-state="loading"] { color: var(--accent); }
#wordsPanel .state[data-state="error"] { color: #b42318; }
#wordsPanel .metric-loader { display: inline-block; width: 34px; height: 7px; border-radius: 4px; background: linear-gradient(90deg, #dfe7f7 20%, #8fb1f2 50%, #dfe7f7 80%); background-size: 220% 100%; animation: metric-loading 1.15s ease-in-out infinite; vertical-align: middle; }
@keyframes metric-loading { 0% { background-position: 100% 0; opacity: .55; } 50% { opacity: 1; } 100% { background-position: -100% 0; opacity: .55; } }
#wordsPanel .empty { height: 230px; color: var(--muted); text-align: center; }
#wordsPanel .pagination { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 16px 30px; font-size: 12px; color: var(--muted); }
#wordsPanel #wordsPageCount { margin-right: auto; }
#wordsPanel #wordsPageLabel { min-width: 55px; text-align: center; }
#wordsPanel #wordsPageSize { height: 34px; font-size: 12px; }
#wordsPanel .data-note { margin: 0; padding: 0 30px 22px; font-size: 12px; color: var(--muted); line-height: 1.7; }
#wordsPanel dialog { width: min(480px, calc(100vw - 32px)); padding: 24px; border: 1px solid var(--line); border-radius: 8px; color: #25262a; box-shadow: 0 18px 60px #0002; }
#wordsPanel dialog::backdrop { background: #20242b66; }
#wordsPanel dialog p { font-size: 14px; color: var(--muted); line-height: 1.8; margin: 16px 0 24px; }
#wordsPanel .dialog-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
#wordsPanel .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
@media (max-width: 760px) {#wordsPanel .page-header, #wordsPanel .query-bar, #wordsPanel .summary, #wordsPanel .result-heading { padding-left: 18px; padding-right: 18px; }
#wordsPanel .page-header { flex-wrap: wrap; }
#wordsPanel .period { width: 100%; margin-left: 48px; }
#wordsPanel .progress-section, #wordsPanel .table-filters, #wordsPanel .selection-bar, #wordsPanel .pagination, #wordsPanel .data-note { padding-left: 18px; padding-right: 18px; }
#wordsPanel .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 0; }
#wordsPanel .summary > div:nth-child(3) { border: 0; padding-left: 0; }
#wordsPanel .seed-field { width: 100%; }
#wordsPanel .export-actions { width: 100%; margin-left: 0; }
#wordsPanel #wordsFilterSearch { width: 100%; }
#wordsPanel .pagination { flex-wrap: wrap; gap: 8px; }
#wordsPanel .selection-bar { flex-wrap: wrap; }
#wordsPanel .progress-heading { align-items: flex-start; flex-direction: column; gap: 3px; padding-bottom: 6px; }
#wordsPanel .empty { text-align: left; padding-left: 20px; }
#wordsPanel button, #wordsPanel .button { min-height: 40px; }
#wordsPanel td.keyword .row-copy { opacity: 1; }

}
@media (prefers-reduced-motion: reduce) {#wordsPanel * { transition: none !important; animation: none !important; }
 }


#wordsPanel { --line:#dfe6ef; --muted:#6d7c8f; --accent:#2463d4; min-width:0; }
#wordsPanel .query-bar {padding:20px 0 16px;}
#wordsPanel .progress-section {padding:0 0 20px;}
#wordsPanel .summary {border:1px solid var(--line);border-radius:9px;background:#fff;margin-bottom:20px;}
#wordsPanel .results {border:1px solid var(--line);border-radius:9px;background:#fff;overflow:hidden;}
#wordsPanel th:first-child, #wordsPanel td:first-child, #wordsPanel th:last-child, #wordsPanel td:last-child {width:auto;}
#wordsPanel .icon {width:16px;height:16px;flex-shrink:0;}
#wordsPanel .button {display:inline-flex;align-items:center;border:1px solid var(--line);padding:8px 12px;border-radius:6px;text-decoration:none;}
#wordsPanel .button.primary {background:var(--accent);color:white;}
#wordsPanel .cache-bar {flex-wrap:wrap;}
#wordsPanel .cache-bar label {min-width:0;}
#wordsPanel .cache-bar select {max-width:100%;min-width:0;}
@media(max-width:720px){#wordsPanel .cache-bar label {width:100%;}#wordsPanel .cache-bar select{width:100%;}}
/* Use the same form, cards and status hierarchy as the keyword tools. */
#wordsPanel .query-bar{padding:20px 24px;background:#fff;border:1px solid var(--line);border-radius:10px;margin:0 0 12px}
#wordsPanel .seed-field{flex:1 1 340px;width:auto;max-width:660px;font-size:13px;color:#566b84}
#wordsPanel .query-bar button{min-height:42px}
#wordsPanel .words-query-note{flex-basis:100%;font-size:12px;line-height:1.7;color:#64748b;margin:0}
#wordsPanel .cache-bar{margin:12px 0}
#wordsPanel .progress-section{padding:12px 16px;margin:14px 0;border:1px solid #dce7f8;border-radius:8px;background:#f1f6ff}
#wordsPanel .progress-section[data-state=done]{background:#f3faf7;border-color:#d7ece2}
#wordsPanel .progress-section[data-state=error]{background:#fff8f2;border-color:#f0dcc9}
#wordsPanel .progress-heading{min-height:22px;color:#536c8a}
#wordsPanel #wordsStatus{display:inline-flex;align-items:center;gap:9px}
#wordsPanel #wordsStatus::before{content:"";display:block;width:8px;height:8px;border-radius:50%;background:#7690af;flex-shrink:0}
#wordsPanel .progress-section[data-state=busy] #wordsStatus::before{width:14px;height:14px;background:transparent;border:2px solid #9db9eb;border-right-color:#2463d4;animation:wb-spin .8s linear infinite}
#wordsPanel .progress-section[data-state=done] #wordsStatus::before{background:#159568}
#wordsPanel progress{margin-top:10px;height:4px}
#wordsPanel .summary{padding:0;border:0;border-radius:0;background:transparent;gap:12px;margin:16px 0}
#wordsPanel .summary>div{padding:14px 16px;border:1px solid #e0e7f0;border-top:3px solid #2884f4;border-radius:8px;background:#fff}
#wordsPanel .summary>div:first-child{padding:14px 16px;border:1px solid #e0e7f0;border-top:3px solid #2884f4}
#wordsPanel .summary>div:nth-child(2){border-top-color:#169d70}#wordsPanel .summary>div:nth-child(3){border-top-color:#ef9427}#wordsPanel .summary>div:nth-child(4){border-top-color:#8b68db}
#wordsPanel .summary strong{font-size:26px;color:#243449;margin:5px 0 3px;line-height:1.2}
#wordsPanel .summary small{line-height:1.6;color:#64748b}
#wordsPanel .result-heading{padding:20px 20px 14px}#wordsPanel .result-heading h2{font-size:15px}
#wordsPanel .table-filters{padding:0 20px 12px}#wordsPanel .selection-bar{padding:10px 20px;background:#fbfcfe;border-top:1px solid #edf1f6}
#wordsPanel table{table-layout:auto;min-width:1270px}#wordsPanel .keyword-col{width:290px}#wordsPanel .source-col{width:145px}
#wordsPanel td{height:56px;border-bottom:1px solid #edf1f6;color:#42516a}
#wordsPanel th{background:#f6f8fb;color:#65768d;font-weight:600}
#wordsPanel tbody tr:nth-child(even) td{background:white}#wordsPanel tbody tr:hover td{background:#f3f7ff}
#wordsPanel td.keyword a{font-weight:650;color:#2463d4}
#wordsPanel .word-flag{display:inline-flex;align-items:center;gap:5px;font-size:12px;white-space:nowrap;font-weight:600}
#wordsPanel .word-flag i{display:inline-flex;align-items:center;justify-content:center;flex:none;width:20px;height:20px;border-radius:50%;font-size:11px;font-style:normal;background:#8795a9;color:white}
#wordsPanel .word-flag.covered{color:#14865e}#wordsPanel .word-flag.covered i{background:#149b6d}#wordsPanel .word-flag.uncovered{color:#aa620f}#wordsPanel .word-flag.uncovered i{background:#ed960e}
#wordsPanel .word-flag.missing{color:#748196}#wordsPanel .metric-loader{animation:word-metric-wait 1.2s ease-in-out infinite;background:#dfe7f7}
@keyframes word-metric-wait{50%{opacity:.35}}
@media(max-width:720px){#wordsPanel .query-bar{padding:18px}#wordsPanel .summary>div:nth-child(3){border:1px solid #e0e7f0;border-top:3px solid #ef9427;padding:14px 16px}#wordsPanel .progress-heading{gap:7px}#wordsPanel .selection-bar{padding:10px 16px}#wordsPanel .table-filters{padding:0 16px 12px}#wordsPanel .result-heading{padding:16px}}
#wordsPanel th{white-space:nowrap}#wordsPanel .query-bar button,#wordsPanel .export-actions button{display:inline-flex;align-items:center;justify-content:center;gap:6px}
