:root {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #20242b;
  background: #f7f8fa;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #20242b;
  --muted: #626c78;
  --line: #dfe3e8;
  --paper: #ffffff;
  --soft: #f1f3f5;
  --focus: #184f91;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; background: #f7f8fa; line-height: 1.5; }
button, input, select { font: inherit; }
a { color: inherit; }
button, select, input { color: var(--ink); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }

.skip-link { position: absolute; top: -48px; left: 12px; z-index: 10; padding: 9px 12px; background: var(--paper); border: 1px solid var(--line); border-radius: 6px; }
.skip-link:focus { top: 10px; }
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.header-inner { width: min(1120px, calc(100% - 40px)); margin: 0 auto; padding: 20px 0 18px; }
.wordmark { display: inline-block; font-size: 1.42rem; font-weight: 760; letter-spacing: -0.045em; text-decoration: none; }
.header-note { margin: 4px 0 0; color: var(--muted); font-size: .93rem; }
.page-shell { width: min(1120px, calc(100% - 40px)); min-height: calc(100vh - 145px); margin: 0 auto; padding: 28px 0 56px; }
.site-footer { border-top: 1px solid var(--line); padding: 15px 20px 22px; color: var(--muted); font-size: .82rem; text-align: center; }
.site-footer p { margin: 0; }
.loading-state, .empty-state { padding: 24px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); color: var(--muted); }

.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 14px; margin: 0 0 14px; }
.section-heading h1, .section-heading h2 { margin: 0; font-size: 1.14rem; letter-spacing: -.02em; }
.result-count { color: var(--muted); font-size: .9rem; white-space: nowrap; }
.count-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin: 0 0 20px; }
.count-chip { min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); text-align: left; cursor: pointer; }
.count-chip:hover { border-color: #9ca5af; }
.count-chip[aria-pressed="true"] { border-color: #424a54; box-shadow: inset 0 0 0 1px #424a54; }
.count-chip-name { min-width: 0; font-size: .86rem; font-weight: 630; }
.count-chip-number { flex: 0 0 auto; min-width: 27px; font-size: 1.2rem; font-weight: 750; text-align: right; }
.count-chip.verdict-winner, .count-chip.verdict-test-lane, .count-chip.verdict-near-miss, .count-chip.verdict-rejected, .count-chip.verdict-auto-rejected, .count-chip.verdict-earlier-reject { background: var(--paper); }

.control-panel { margin: 0 0 20px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.filters-toggle { display: none; }
.filter-grid { display: grid; grid-template-columns: minmax(220px, 1.45fr) minmax(150px, .8fr) minmax(220px, 1.1fr) minmax(180px, .95fr); gap: 14px; }
.field { min-width: 0; }
.field > label, .field-label { display: block; margin: 0 0 6px; color: #424a54; font-size: .82rem; font-weight: 680; }
.text-input, .select-input, .number-input { width: 100%; min-height: 40px; padding: 8px 10px; border: 1px solid #cbd1d8; border-radius: 7px; background: #fff; }
.text-input::placeholder { color: #78818c; }
.type-options { display: grid; grid-template-columns: 1fr; gap: 4px; max-height: 170px; overflow: auto; padding: 2px 4px 2px 0; }
.check-option { display: flex; align-items: flex-start; gap: 8px; color: #39414b; font-size: .82rem; line-height: 1.35; }
.check-option input { flex: 0 0 auto; width: 16px; height: 16px; margin: 1px 0 0; accent-color: #303842; }
.score-range { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.score-range label { display: block; color: var(--muted); font-size: .75rem; }
.score-range .number-input { margin-top: 3px; }
.unscored-option { margin-top: 9px; }
.sort-row { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin: 0 0 12px; }
.sort-row label { color: var(--muted); font-size: .84rem; }
.sort-row .select-input { width: min(230px, 62vw); min-height: 38px; }
.idea-list { display: grid; gap: 9px; }
.idea-card { display: grid; grid-template-columns: minmax(0, 1fr) 112px; align-items: center; gap: 18px; padding: 15px 17px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); text-decoration: none; }
.idea-card:hover { border-color: #aab2bb; box-shadow: 0 2px 8px rgb(20 28 38 / 5%); }
.idea-card:focus-visible { outline-offset: 3px; }
.idea-card-main { min-width: 0; }
.idea-name { display: block; margin: 0 0 3px; font-size: 1rem; font-weight: 690; line-height: 1.35; }
.product-name { display: block; margin-bottom: 7px; color: var(--muted); font-size: .88rem; }
.card-tags, .tag-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.type-badge, .small-tag, .verdict-pill, .quality-tag, .keyword-chip { display: inline-flex; align-items: center; max-width: 100%; border: 1px solid var(--line); border-radius: 999px; padding: 3px 8px; background: #f8f9fa; font-size: .74rem; line-height: 1.35; overflow-wrap: anywhere; }
.type-badge { color: #4b5561; }
.small-tag { color: #5c6672; background: #f1f3f5; }
.verdict-pill { width: fit-content; font-weight: 700; }
.verdict-winner { color: #155b36; background: #e8f4ec; border-color: #bfdfca; }
.verdict-test-lane { color: #815500; background: #fff4d9; border-color: #edcf83; }
.verdict-near-miss { color: #665528; background: #f4f0e6; border-color: #ded5bd; }
.verdict-rejected { color: #4c535b; background: #eceff2; border-color: #d4d9df; }
.verdict-auto-rejected { color: #842a2a; background: #faeaea; border-color: #eac0c0; }
.verdict-earlier-reject { color: #646b73; background: #f2f3f4; border-color: #dfe2e5; }
.card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 8px; color: var(--muted); font-size: .8rem; }
.card-score { display: grid; justify-items: end; align-content: center; gap: 4px; }
.card-score-number { font-size: 2rem; font-weight: 770; letter-spacing: -.06em; line-height: 1; }
.card-score-label { color: var(--muted); font-size: .76rem; text-align: right; }
.built-tag { border-color: #b8c0c8; background: #f1f3f5; color: #3f4852; }

.detail-topline { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 14px; }
.back-link, .nav-button { display: inline-flex; align-items: center; justify-content: center; min-height: 38px; padding: 7px 12px; border: 1px solid #cbd1d8; border-radius: 7px; background: #fff; color: #313943; font-size: .88rem; font-weight: 620; text-decoration: none; }
.back-link:hover, .nav-button:hover { background: #f2f4f6; }
.detail-shell { display: grid; gap: 14px; }
.verdict-banner { padding: 18px 20px; border: 1px solid var(--line); border-left-width: 5px; border-radius: 11px; background: var(--paper); }
.verdict-banner.verdict-winner { border-left-color: #278451; }
.verdict-banner.verdict-test-lane { border-left-color: #c88a0a; }
.verdict-banner.verdict-near-miss, .verdict-banner.verdict-rejected, .verdict-banner.verdict-earlier-reject { border-left-color: #737b84; }
.verdict-banner.verdict-auto-rejected { border-left-color: #bb4545; }
.banner-label { margin: 0 0 7px; font-size: .76rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.verdict-banner .verdict-pill { margin-bottom: 9px; font-size: .86rem; }
.banner-sentence { margin: 0; font-size: 1rem; font-weight: 590; }
.build-status { margin: 8px 0 0; color: var(--muted); font-size: .87rem; }
.detail-title-wrap { margin: 0 0 2px; }
.detail-title { margin: 0; font-size: clamp(1.55rem, 4vw, 2.2rem); line-height: 1.17; letter-spacing: -.04em; overflow-wrap: anywhere; }
.detail-product { margin: 7px 0 0; color: var(--muted); font-size: 1rem; }
.detail-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin-top: 10px; }
.detail-panel { min-width: 0; padding: 19px; border: 1px solid var(--line); border-radius: 11px; background: var(--paper); }
.detail-panel h2 { margin: 0 0 13px; font-size: 1.08rem; letter-spacing: -.02em; }
.score-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 14px; margin-bottom: 15px; }
.detail-score { font-size: 2.65rem; font-weight: 790; letter-spacing: -.07em; line-height: 1; }
.scorecard-label { color: var(--muted); font-size: .84rem; overflow-wrap: anywhere; }
.earlier-score { flex-basis: 100%; color: var(--muted); font-size: .86rem; }
.score-bars { display: grid; gap: 12px; }
.score-bar-item { display: grid; grid-template-columns: minmax(110px, 190px) minmax(70px, 1fr) max-content; align-items: center; gap: 10px; }
.score-bar-label { color: #3b434d; font-size: .85rem; overflow-wrap: anywhere; }
.score-bar-track { height: 9px; overflow: hidden; border-radius: 99px; background: #e6e9ed; }
.score-bar-fill { height: 100%; border-radius: inherit; background: #66717d; }
.score-bar-value { color: #4b535d; font-size: .82rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.older-card-note { margin: 12px 0 0; color: var(--muted); font-size: .82rem; }
.no-scores { margin: 0 0 16px; color: var(--muted); font-size: .88rem; }
.reference-wrap { margin-top: 18px; padding-top: 15px; border-top: 1px solid var(--line); }
.reference-wrap h3 { margin: 0 0 9px; font-size: .88rem; }
.table-scroll { overflow-x: auto; }
.reference-table { width: 100%; border-collapse: collapse; font-size: .8rem; }
.reference-table th, .reference-table td { padding: 7px 9px; border: 1px solid var(--line); text-align: left; white-space: nowrap; }
.reference-table th { background: #f5f6f7; font-weight: 680; }
.reference-bands { margin: 9px 0 0; color: var(--muted); font-size: .8rem; }
.fact-list { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; }
.fact-item { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 8px; align-items: start; }
.fact-marker { font-weight: 800; line-height: 1.5; }
.good-marker { color: #297447; }
.bad-marker { color: #9b3838; }
.fact-content { min-width: 0; overflow-wrap: anywhere; }
.text-content { overflow-wrap: anywhere; white-space: pre-wrap; }
.rich-link { color: #263e59; text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; }
.unverified-tag { display: inline-flex; margin-left: 6px; padding: 1px 6px; border: 1px solid #c8cdd3; border-radius: 999px; background: #f1f3f5; color: #505a65; font-size: .68rem; font-weight: 700; vertical-align: .1em; white-space: nowrap; }
.not-recorded { color: var(--muted); font-style: italic; }
.spec-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.spec-row { min-width: 0; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; }
.spec-label { display: block; margin: 0 0 5px; color: var(--muted); font-size: .75rem; font-weight: 700; letter-spacing: .035em; text-transform: uppercase; }
.spec-value { overflow-wrap: anywhere; }
.spec-row-wide { grid-column: 1 / -1; }
.spec-value-list { margin: 0; padding-left: 19px; }
.spec-value-list li + li { margin-top: 4px; }
.keyword-list { display: flex; flex-wrap: wrap; gap: 6px; }
.keyword-chip { border-color: #d8dde2; background: #f5f6f7; color: #414a54; }
.keyword-volume-label { margin: 8px 0 0; color: var(--muted); font-size: .8rem; }
.contradictions-box { padding: 12px 13px; border: 1px solid #e7cc8d; border-radius: 8px; background: #fff8e8; }
.contradictions-box .spec-label { color: #72540e; }
.detail-nav { display: flex; justify-content: space-between; gap: 8px; margin-top: 2px; }
.nav-button[aria-disabled="true"] { pointer-events: none; opacity: .48; }
.research-details { border: 1px solid var(--line); border-radius: 11px; background: var(--paper); }
.research-details summary { padding: 15px 18px; cursor: pointer; font-weight: 680; }
.research-body { display: grid; gap: 15px; padding: 0 18px 18px; }
.research-body h3 { margin: 0 0 6px; font-size: .86rem; }
.research-body p { margin: 0; }
.research-section { min-width: 0; }
.quality-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.quality-tag { color: #5a636d; background: #f0f2f4; }
.path-value { overflow-wrap: anywhere; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .81rem; }

@media (max-width: 960px) {
  .count-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .header-inner, .page-shell { width: min(100% - 28px, 1120px); }
  .header-inner { padding: 16px 0 15px; }
  .page-shell { padding: 20px 0 40px; }
  .header-note { max-width: 40ch; font-size: .84rem; }
  .count-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; margin-bottom: 12px; }
  .count-chip { padding: 10px; border-radius: 8px; }
  .count-chip-name { font-size: .78rem; }
  .count-chip-number { font-size: 1.08rem; }
  .control-panel { padding: 11px; }
  .filters-toggle { display: inline-flex; align-items: center; justify-content: space-between; width: 100%; min-height: 39px; padding: 7px 9px; border: 1px solid #cbd1d8; border-radius: 7px; background: #fff; font-weight: 650; cursor: pointer; }
  .filter-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 12px; }
  .filter-grid[hidden] { display: none; }
  .type-options { max-height: 150px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sort-row { justify-content: space-between; }
  .sort-row .select-input { width: min(230px, 66vw); }
  .idea-card { grid-template-columns: minmax(0, 1fr) 64px; gap: 9px; padding: 13px 12px; }
  .idea-name { font-size: .94rem; }
  .card-score-number { font-size: 1.65rem; }
  .card-score-label { font-size: .68rem; }
  .card-meta { font-size: .75rem; }
  .verdict-pill, .type-badge, .small-tag { font-size: .69rem; }
  .detail-topline { align-items: stretch; }
  .back-link { width: 100%; }
  .detail-panel { padding: 15px; }
  .score-bar-item { grid-template-columns: minmax(90px, 1fr) minmax(44px, .8fr) max-content; gap: 7px; }
  .score-bar-label { font-size: .78rem; }
  .score-bar-value { font-size: .75rem; }
  .spec-grid { grid-template-columns: minmax(0, 1fr); }
  .spec-row-wide { grid-column: auto; }
  .detail-nav { flex-wrap: wrap; }
  .nav-button { flex: 1 1 42%; }
  .result-count { font-size: .8rem; }
}
@media (max-width: 360px) {
  .header-inner, .page-shell { width: calc(100% - 22px); }
  .count-chip { gap: 4px; padding: 9px 7px; }
  .count-chip-name { font-size: .73rem; }
  .idea-card { grid-template-columns: minmax(0, 1fr) 55px; padding: 11px 9px; }
  .score-bar-item { grid-template-columns: minmax(74px, .95fr) minmax(40px, .65fr) max-content; }
}
