/* 容量単価ボード。主役は「1TBあたり」「1,000mAhあたり」の数字(等幅・大きく)。スマホ優先・ドライブのラベルのような見た目 */
:root {
  color-scheme: light dark;
  --bg: #f3f5f8; --surface: #fff; --surface-2: #e9edf3; --ink: #0f1a2a; --muted: #4a5568; --faint: #5d6878;
  --line: #d6dce5; --line-strong: #9aa5b5;
  --accent: #1f4fd1; --accent-2: #173ea6; --accent-soft: #e3eaff; --bar: #1f4fd1; --bar-bg: #dfe5ee;
  --in: #0e6a7e; --in-bg: #e0f3f6; --out: #9a3412; --out-bg: #fbeee6;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Segoe UI Mono", Consolas, "BIZ UDGothic", monospace;
  --sans: system-ui, -apple-system, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "BIZ UDPGothic", "Yu Gothic UI", Meiryo, "Noto Sans JP", sans-serif;
  --r: 3px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d131c; --surface: #151d29; --surface-2: #1c2635; --ink: #e6ebf2; --muted: #a3afc0; --faint: #8e9aac;
    --line: #263244; --line-strong: #4a586d; --accent: #7aa2ff; --accent-2: #a5c0ff; --accent-soft: #1b2a4d; --bar: #7aa2ff; --bar-bg: #243042;
    --in: #67d0e2; --in-bg: #0f2e35; --out: #f4a37a; --out-bg: #3a2216;
  }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.7 var(--sans); }
a { color: var(--accent); }
a:hover { color: var(--accent-2); }
img { max-width: 100%; }
.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 8px; top: 8px; z-index: 9; background: var(--surface); padding: 6px 10px; }
[hidden] { display: none !important; }   /* .row・.filters の display より優先(絞り込みで隠した行を確実に消す) */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* PR・非公式の表示: ヘッダーの中の「銘板」(ドライブの仕様ラベルのような枠。12px以上・どのページでも最初に見える位置) */
.plate { display: flex; gap: 8px; align-items: flex-start; margin: 0; padding: 5px 8px; max-width: 420px; font-size: 12px; line-height: 1.55;
  color: var(--muted); border: 1px dashed var(--line-strong); border-radius: var(--r); background: var(--surface-2); }
.plate strong { color: var(--ink); }
.pr { display: inline-block; flex: none; font: 700 12px/1 var(--mono); letter-spacing: .06em; padding: 3px 5px; border: 1.5px solid currentColor;
  border-radius: var(--r); color: var(--ink); }

/* ヘッダー: 白地・上に太い青線。1段目にロゴと銘板(PR・非公式)、2段目にカテゴリ */
.hdr { background: var(--surface); border-top: 4px solid var(--accent); border-bottom: 1px solid var(--line); }
.hdr-top { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; padding-top: 10px; padding-bottom: 8px; }
.logo { display: inline-flex; gap: 10px; align-items: center; color: var(--ink); text-decoration: none; }
.logo-mark { width: 34px; height: 34px; flex: none; }
.logo-mark rect:first-child { fill: none; stroke: var(--ink); stroke-width: 2; }
.logo-mark .b1, .logo-mark .b2 { fill: var(--line-strong); }
.logo-mark .b3 { fill: var(--accent); }
.logo-t { display: grid; line-height: 1.25; }
.logo-name { font-weight: 800; font-size: 18px; letter-spacing: .02em; }
.logo-sub { font-size: 12px; color: var(--muted); }
.nav { border-top: 1px solid var(--line); }
.nav-in { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.nav-in::-webkit-scrollbar { display: none; }
.nav a { flex: none; padding: 8px 10px 9px; font-size: 14px; color: var(--muted); text-decoration: none; border-bottom: 3px solid transparent; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current] { color: var(--ink); font-weight: 700; border-bottom-color: var(--accent); }

main { padding-top: 14px; padding-bottom: 32px; }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 4px; list-style: none; margin: 0 0 10px; padding: 0; font-size: 12.5px; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 4px; color: var(--line-strong); }
.crumbs a { color: var(--muted); }

/* 見出しと導入 */
.hero h1 { font-size: 20px; line-height: 1.4; margin: 4px 0 8px; letter-spacing: .01em; }
.hero h1 small { display: block; font-size: 14px; font-weight: 600; color: var(--muted); margin-top: 2px; }
.lead { margin: 0 0 12px; color: var(--ink); }
.lead .at, .at-line { color: var(--muted); font-size: 13px; }
.lead .at { display: block; }
.sh { font-size: 17px; margin: 28px 0 8px; padding-left: 10px; border-left: 4px solid var(--ink); line-height: 1.35; }
.sub { font-size: 13px; color: var(--muted); margin: 0 0 10px; }

/* PR の一文(商品の一覧のそば) */
.pr-note { display: flex; gap: 8px; align-items: flex-start; margin: 14px 0 8px; font-size: 12.5px; color: var(--muted); }

/* 主役の数字 */
.u { font-family: var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.u b { font-weight: 800; letter-spacing: -.02em; }
.u small { font-size: .62em; color: var(--muted); margin-left: 1px; font-weight: 600; }
.u.big b { font-size: 30px; }
.u.sm b { font-size: 15px; }

/* トップのカテゴリのタイル */
.tile-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tile { display: grid; align-content: start; gap: 1px; min-width: 0; padding: 10px 10px 10px 12px; background: var(--surface);
  border: 1px solid var(--line); border-top: 3px solid var(--ink); border-radius: var(--r); color: var(--ink); text-decoration: none; position: relative; }
.tile::after { content: "›"; position: absolute; right: 10px; top: 4px; font-size: 20px; color: var(--line-strong); }
.tile:hover { border-color: var(--accent); color: var(--ink); }
.tile-h { font-weight: 800; font-size: 15px; padding-right: 14px; }
.tile-lbl { font-size: 12px; color: var(--muted); margin-top: 4px; }
.tile .u.big b { color: var(--accent); font-size: 24px; }
.tile-sweet { margin: 4px 0 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
.tile-sweet b { color: var(--ink); font-family: var(--mono); }
.tile-sweet .u b { color: var(--ink); font-size: 14px; }
.tile-f { font-size: 12px; color: var(--faint); font-family: var(--mono); margin-top: 4px; }

/* 種類の比較(横棒) */
.bars, .curve { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.curve { gap: 0; border-top: 1px solid var(--line); }
.bars li { display: grid; grid-template-columns: 92px 1fr; grid-template-areas: "l v" "t t"; gap: 2px 8px; align-items: baseline; }
.bl { grid-area: l; font-weight: 700; font-size: 14px; }
.bl a { color: var(--ink); }
.bl small, .cl small { display: block; font-weight: 400; font-size: 12px; color: var(--muted); font-family: var(--mono); }
.bt, .ct { grid-area: t; display: block; height: 12px; background: var(--bar-bg); border-radius: 2px; position: relative; }
.bf, .cf { display: block; height: 100%; background: var(--bar); border-radius: 2px; }
.bv { grid-area: v; text-align: right; }
.bv .u b { font-size: 18px; }
.bars + .sub { margin-top: 10px; }

/* カテゴリの容量カーブ */
.curve li { display: grid; grid-template-columns: 120px 1fr; grid-template-areas: "l v" "t t"; gap: 6px 8px; align-items: center;
  padding: 8px 0 10px; border-bottom: 1px solid var(--line); }
.cl { grid-area: l; font: 700 14px/1.3 var(--mono); }
.cv { grid-area: v; text-align: right; font-size: 12px; color: var(--muted); }
.cv .u b { font-size: 18px; color: var(--ink); }
.cv > small { display: block; font-family: var(--mono); }
.cm { position: absolute; top: -4px; bottom: -4px; width: 3px; margin-left: -1px; background: var(--ink); border-radius: 1px; }

/* 容量帯の見出し(ラベルのチップ) */
.th2 { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: 15px; margin: 26px 0 8px; }
.chip { font: 800 16px/1 var(--mono); padding: 6px 9px; border: 2px solid var(--ink); border-radius: var(--r); background: var(--surface); }
.th2-s { font-weight: 400; font-size: 13px; color: var(--muted); }
.th2-s .u b { font-size: 15px; color: var(--ink); }
.more { margin: 6px 0 0; font-size: 14px; }
.more a { font-weight: 700; }

/* 商品の行 */
.rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: none; }
.row { position: relative; display: grid; grid-template-columns: 26px 64px 1fr; gap: 0 10px; padding: 12px 12px 12px 8px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r); }
/* 行のどこを押しても商品ページが開く(リンクは名前の1本だけ。::after を行いっぱいに広げる) */
.rl::after { content: ""; position: absolute; inset: 0; border-radius: var(--r); }
.row:hover { border-color: var(--accent); }
.row:hover .rl { text-decoration: underline; }
.rl:focus-visible { outline: none; }
.rl:focus-visible::after { outline: 2px solid var(--accent); outline-offset: 1px; }
.rk { font: 700 13px/1 var(--mono); color: var(--muted); text-align: center; padding-top: 6px; }
.row:first-child .rk { color: var(--accent); }
.th { display: block; width: 64px; height: 64px; border-radius: 2px; overflow: hidden; background: var(--surface-2); }
.th img { width: 64px; height: 64px; object-fit: contain; display: block; background: #fff; }
.rb { min-width: 0; }
.rb p { margin: 0; }
.ru { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.ru .u b { font-size: 24px; }
.tier { font: 700 12px/1 var(--mono); padding: 3px 5px; border: 1px solid var(--line-strong); border-radius: var(--r); }
.rn { font-size: 14px; line-height: 1.5; margin-top: 2px !important; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rn a { color: var(--ink); text-decoration: none; }
.rn a:hover { text-decoration: underline; }
.rm { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px !important; }
.cap { font: 700 12px/1 var(--mono); padding: 4px 6px; background: var(--ink); color: var(--bg); border-radius: var(--r); }
.ship, .tag { font-size: 12px; line-height: 1; padding: 4px 6px; border-radius: var(--r); }
.ship.in { color: var(--in); background: var(--in-bg); font-weight: 700; }
.ship.out { color: var(--out); background: var(--out-bg); font-weight: 700; }
.tag { color: var(--muted); border: 1px solid var(--line); }
.rp { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin-top: 6px !important; font-size: 13px; color: var(--muted); }
.rp b { font: 700 15px var(--mono); color: var(--ink); margin-right: 2px; }
.rv .at::after { content: "・"; }
.rv { font-size: 12.5px; line-height: 1.55; margin-top: 3px !important; color: var(--muted); }
.rv .shop { overflow-wrap: anywhere; }
.rv .shop::before { content: "・"; }
.hist { font-size: 12px; color: var(--faint); margin-top: 2px !important; }
/* 「楽天市場で見る」は見た目だけ(押すと行のリンクが開く)。価格の行の右端に置いて、行を低くする */
.go { margin-left: auto; font-size: 12.5px; font-weight: 700; line-height: 1; padding: 7px 10px; border: 1.5px solid var(--accent);
  border-radius: var(--r); color: var(--accent); white-space: nowrap; }
.row:hover .go { background: var(--accent); color: #fff; }
.chk { margin-top: 6px !important; padding: 4px 8px; font-size: 12px; line-height: 1.5; color: var(--out); background: var(--out-bg); border-radius: var(--r); }

/* 容量帯のページ */
.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 10px 0; }
.stats div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 12px; }
.stats div:first-child { grid-column: 1 / -1; border: 2px solid var(--ink); }
.stats dt { font-size: 12px; color: var(--muted); }
.stats dd { margin: 0; }
.stats .u b { font-size: 20px; }
.stats .u.big b { font-size: 34px; color: var(--accent); }
.stats .n { font: 800 20px var(--mono); }
.stats .lowp.big b { font: 800 34px var(--mono); color: var(--accent); }
.stats .lowu { display: block; font-size: 13px; color: var(--muted); }
.at-line { margin: 0; }
.sibs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 14px 0 0; font-size: 13px; color: var(--muted); }
.sibs a { font: 700 13px/1 var(--mono); padding: 7px 9px; border: 1px solid var(--line-strong); border-radius: var(--r); text-decoration: none; color: var(--ink); background: var(--surface); }
.sibs a[aria-current] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 12px 0 0; }
.fchip { font: 600 13px/1 var(--sans); padding: 8px 11px; border: 1.5px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--ink); cursor: pointer; }
.fchip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.fcount { font-size: 12.5px; color: var(--muted); }
.none { padding: 14px; background: var(--surface); border: 1px dashed var(--line-strong); }

/* 注意・本文 */
.guide ul, .how ul, .prose ul { padding-left: 1.2em; margin: 6px 0; }
.guide li, .how li, .prose li { margin: 4px 0; font-size: 14px; }
.sister { font-size: 14px; margin: 10px 0 0; }
.others-in { display: flex; flex-wrap: wrap; gap: 6px; }
.others-in a { padding: 7px 10px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); text-decoration: none; font-size: 14px; }
.prose { max-width: 720px; }
.prose h1 { font-size: 22px; line-height: 1.4; }
.prose h1 small { display: block; font-size: 14px; color: var(--muted); }
.prose h2 { font-size: 17px; margin: 26px 0 6px; padding-left: 10px; border-left: 4px solid var(--ink); }
.note { font-size: 12.5px; color: var(--muted); }
.nf-code { font: 800 56px/1 var(--mono); color: var(--accent); margin: 16px 0 0; }

/* フッター */
.ftr { border-top: 1px solid var(--line); background: var(--surface); font-size: 13px; color: var(--muted); padding: 18px 0 28px; }
.ftr-name { display: flex; gap: 8px; align-items: center; font-weight: 800; color: var(--ink); font-size: 15px; margin: 0 0 6px; }
.ftr-name .logo-mark { width: 24px; height: 24px; }
.ftr-links { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 8px 0; }
.credit { font-size: 12.5px; }

/* 運営者が同じサイト(family.block の layout="list"・prefix="yrs")。ドライブの仕様表のような2列の表 */
.yrs { margin: 18px 0 8px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); }
.yrs-h { margin: 0 0 6px; font-size: 13px; font-weight: 700; color: var(--ink); }
.yrs-list { display: grid; grid-template-columns: 1fr; margin: 0; font-size: 13px; }
.yrs-name { margin: 8px 0 0; padding-top: 8px; border-top: 1px dotted var(--line-strong); font-weight: 700; font-family: var(--mono); }
.yrs-name:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.yrs-desc { margin: 2px 0 0; color: var(--muted); line-height: 1.65; }
.yrs-desc a { display: inline-block; margin-top: 2px; }
.yrs-here { margin-left: 6px; font-size: 12px; font-weight: 400; color: var(--faint); }
.yrs-name.here { color: var(--accent); }

@media (min-width: 640px) {
  body { font-size: 15.5px; }
  .hero h1, .prose h1 { font-size: 27px; }
  .tile-grid { grid-template-columns: repeat(3, 1fr); }
  .tile .u.big b { font-size: 28px; }
  .yrs-list { grid-template-columns: 180px 1fr; column-gap: 14px; }
  .yrs-list .yrs-name, .yrs-list .yrs-desc { margin: 0; padding: 7px 0; border-top: 1px dotted var(--line-strong); }
  .yrs-list .yrs-name:first-child, .yrs-list .yrs-name:first-child + .yrs-desc { border-top: 0; }
  .bars li { grid-template-columns: 120px 1fr 150px; grid-template-areas: "l t v"; align-items: center; }
  .curve li { grid-template-columns: 110px 1fr 190px; grid-template-areas: "l t v"; align-items: center; }
  .row { grid-template-columns: 30px 88px 1fr; padding: 14px; }
  .th, .th img { width: 88px; height: 88px; }
  .stats { grid-template-columns: 2fr 1fr 1fr; }
  .stats div:first-child { grid-column: auto; }
}
@media (min-width: 900px) {
  .tile-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (prefers-reduced-motion: no-preference) { .tile, .go, .fchip, .row { transition: border-color .15s, background-color .15s, color .15s; } }
/* 行のショップ名・一覧の上の注意・容量帯のページのデータの文 */
.rp .shop { font-size: 12px; color: var(--faint); }
.caveat { margin: 12px 0 0; padding: 10px 12px; font-size: 13px; line-height: 1.7; border: 1px solid var(--line-strong);
  border-left: 4px solid var(--out); background: var(--surface); border-radius: var(--r); }
.caveat b { margin-right: 8px; color: var(--out); }
.facts { margin: 16px 0 0; }
.facts ul { margin: 0; padding-left: 1.2em; font-size: 14px; line-height: 1.8; }
.facts li + li { margin-top: 2px; }
.back { margin: 16px 0 0; font-size: 13px; }

/* ---- 2026-11 ブラッシュアップ ---- */
/* ヘッダーのカテゴリ: 横に続きがあるときは端をぼかす(app.js が more-r・more-l を付ける) */
.nav-in.more-r { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
.nav-in.more-l.more-r { -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 85%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 85%, transparent); }
.nav-in.more-l:not(.more-r) { -webkit-mask-image: linear-gradient(90deg, transparent, #000 15%); mask-image: linear-gradient(90deg, transparent, #000 15%); }

/* 取得日時とページの中の移動 */
.upd { margin: -4px 0 10px; font-size: 12.5px; color: var(--muted); }
.upd time { font-family: var(--mono); }
.jump { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 10px 0 0; font-size: 13px; color: var(--muted); }
.jump a { padding: 6px 10px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); text-decoration: none;
  color: var(--ink); font: 600 13px/1.2 var(--mono); }
.jump a:hover { border-color: var(--accent); color: var(--accent); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
h2[id], section[id], div[id] { scroll-margin-top: 12px; }

/* 表(同じ容量で種類を比べる・バッテリー・容量帯ごとの数字)。スマホでは横にスクロールし、1列目は固定 */
.tbl-w { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.tbl-w:focus-visible { outline-offset: 0; }
.tbl-w.more-r { box-shadow: inset -12px 0 10px -10px rgba(0, 0, 0, .25); }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.tbl th, .tbl td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; vertical-align: top; }
.tbl tbody tr:last-child th, .tbl tbody tr:last-child td { border-bottom: 0; }
.tbl thead th { font-size: 12px; font-weight: 700; color: var(--muted); background: var(--surface-2); vertical-align: bottom; line-height: 1.35; }
.tbl thead th small, .tbl td small { display: block; font-weight: 400; font-size: 11.5px; color: var(--faint); }
.tbl th[scope="row"], .tbl thead th:first-child { text-align: left; position: sticky; left: 0; z-index: 1; background: var(--surface); }
.tbl thead th:first-child { background: var(--surface-2); }
.tbl th[scope="row"] { font: 700 13.5px var(--mono); box-shadow: 1px 0 0 var(--line); }
.tbl td { font-family: var(--mono); }
.tbl td a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.tbl td a:hover { color: var(--accent); }
.tbl td.best { background: var(--accent-soft); }
.tbl td.best a { font-weight: 800; color: var(--accent); }
.tbl td.na { color: var(--faint); text-align: center; }
.tbl .u b { font-size: 15px; }
.mx td small { margin-top: 1px; }
.tbl th, .tbl td { padding: 7px 9px; }
.sort { all: unset; cursor: pointer; display: inline-block; text-align: inherit; }
.sort:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sort::after { content: "↕"; margin-left: 3px; color: var(--line-strong); font-size: 11px; }
th[aria-sort="ascending"] .sort::after { content: "↑"; color: var(--accent); }
th[aria-sort="descending"] .sort::after { content: "↓"; color: var(--accent); }

/* 容量カーブで中央値がいちばん低い帯 */
.curve li.best .cf { background: var(--accent); }
.curve li:not(.best) .cf { opacity: .55; }
.cl em { display: inline-block; margin-top: 3px; font: 700 11px/1.2 var(--sans); font-style: normal; color: var(--accent); background: var(--accent-soft);
  padding: 2px 5px; border-radius: var(--r); }

/* 数字から見た選び方・規格の読み方 */
.tips ul { margin: 0; padding-left: 1.2em; font-size: 14px; line-height: 1.8; }
.tips li + li { margin-top: 4px; }
.spl { margin: 0; display: grid; gap: 8px; }
.spl div { padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.spl dt { font: 700 14px/1.4 var(--mono); }
.spl dd { margin: 4px 0 0; font-size: 13.5px; line-height: 1.75; }
.spn { display: block; margin-top: 4px; font-size: 12px; color: var(--faint); font-family: var(--mono); }
.spec-link { margin: 14px 0 0; font-size: 13px; color: var(--muted); }

/* 行: 中央値との差・1個あたり・規格の札 */
.vs { font-size: 12px; color: var(--muted); }
.vs.lo { color: var(--in); font-weight: 700; }
.ex { font: 600 12px/1 var(--mono); padding: 4px 6px; border-radius: var(--r); background: var(--surface-2); color: var(--ink); }
.rs { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 5px !important; }
.sp { font: 600 11.5px/1 var(--mono); padding: 3px 5px; border-radius: 2px; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); }

/* 容量帯のページ: 並べ替え・絞り込み */
.tools { margin: 12px 0 0; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); display: grid; gap: 8px; }
.sorts, .tools .filters { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0; }
.tl { flex: none; width: 100%; font-size: 12px; font-weight: 700; color: var(--muted); }
.schip { font: 600 13px/1 var(--sans); padding: 8px 11px; min-height: 34px; border: 1.5px solid var(--line-strong); border-radius: var(--r); background: var(--surface); color: var(--ink); cursor: pointer; }
.schip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.fchip { min-height: 34px; }
.fchip[aria-pressed="true"]::before, .schip[aria-pressed="true"]::before { content: "✓ "; }
.freset { font: 600 12.5px/1 var(--sans); padding: 8px 6px; border: 0; background: none; color: var(--accent); text-decoration: underline; cursor: pointer; }
.tools .fcount { margin: 0; font-size: 12.5px; }

/* 容量帯の散らばり(1件を1つの点で) */
.dist { margin: 4px 0 10px; }
.dist-t { position: relative; height: 22px; margin: 0 4px; border-bottom: 1px solid var(--line-strong); }
.dist-q { position: absolute; top: 4px; bottom: 4px; background: var(--accent-soft); border-radius: 2px; }
.dist-t i { position: absolute; top: 7px; width: 7px; height: 7px; margin-left: -3.5px; border-radius: 50%; background: var(--accent); opacity: .55; }
.dist-m { position: absolute; top: 0; bottom: -4px; width: 3px; margin-left: -1.5px; background: var(--ink); }
.dist-c { margin: 2px 0 0; font-size: 12px; color: var(--faint); }
.dist-l { display: flex; justify-content: space-between; gap: 8px; margin-top: 4px; font: 12px var(--mono); color: var(--muted); }

/* フッター: カテゴリ・先頭へ・about の目次 */
.ftr-cats { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 8px 0; font-size: 13px; }
.totop { margin: 0 0 12px; text-align: right; font-size: 13px; }
.toc { margin: 10px 0 18px; padding: 10px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); font-size: 14px; }
.toc ol { margin: 0; padding-left: 1.4em; columns: 2; column-gap: 20px; }
.toc li { margin: 2px 0; break-inside: avoid; }

@media (min-width: 640px) {
  .tl { width: auto; margin-right: 4px; }
  .spl { grid-template-columns: 1fr 1fr; }
  .tbl { font-size: 14px; }
}
@media (max-width: 380px) {
  .toc ol { columns: 1; }
  .row { grid-template-columns: 22px 56px 1fr; gap: 0 8px; }
  .th, .th img { width: 56px; height: 56px; }
}

/* 印刷: ヘッダーのカテゴリ・ボタン類を省く */
@media print {
  .nav, .tools, .go, .jump, .totop, .skip, .yrs { display: none !important; }
  body { background: #fff; color: #000; font-size: 12px; }
  .row, .tile, .stats div { break-inside: avoid; }
  .tbl-w { overflow: visible; border: 0; }
}

.bts .tbl-w, .sum .tbl-w { max-width: 720px; }
.fchip small, .sibs a small { margin-left: 5px; font: 600 11px/1 var(--mono); opacity: .75; }
.sibs a small { display: block; margin: 3px 0 0; font-weight: 400; }
.scroll-hint { display: none; margin: 0 0 6px; font-size: 12px; color: var(--faint); }
@media (max-width: 720px) { .scroll-hint { display: block; } }

/* ---- 2026-11 作り込み 2周目 ---- */
/* 容量帯のページの見出しの数字: いちばん低い商品の名前(一覧の1番目へ)と、半分以下のときの注意 */
.stats .lown { display: block; margin-top: 4px; font-size: 13px; line-height: 1.5; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stats .lowchk { display: block; margin-top: 4px; font-size: 12px; line-height: 1.5; color: var(--out); }
/* スマホ: となりの容量・並べ替え・絞り込みは横1列(折り返すと一覧が画面の下へ押し出される) */
@media (max-width: 639px) {
  .sibs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
  .sibs::-webkit-scrollbar { display: none; }
  .sibs a { flex: none; }
  .sibs > span { flex: none; }
  .tools { padding: 8px 10px; gap: 6px; }
  .sorts, .tools .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
  .sorts::-webkit-scrollbar, .tools .filters::-webkit-scrollbar { display: none; }
  .tl { width: auto; }
  .schip, .fchip, .freset { flex: none; }
  .stats { gap: 6px; }
  .stats div { padding: 8px 10px; }
  .stats .u.big b, .stats .lowp.big b { font-size: 30px; }
  .sibs.more-r, .sorts.more-r, .filters.more-r { -webkit-mask-image: linear-gradient(90deg, #000 82%, transparent); mask-image: linear-gradient(90deg, #000 82%, transparent); }
  .sibs.more-l.more-r, .sorts.more-l.more-r, .filters.more-l.more-r { -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 82%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 82%, transparent); }
}
/* 運営者(入口)への戻り道。全ページに1行だけ(family.publisher_line) */
.yrs-by { margin: 8px 0; font-size: 12.5px; }
/* カテゴリのページ: 要点(見出しのすぐ下で、問いに1〜2文で答える)・方式で分けた表・あわせて比べる */
.key { margin: 12px 0 0; padding: 10px 12px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: var(--r); }
.key p { margin: 0; font-size: 14.5px; line-height: 1.75; }
.key b { color: var(--ink); }
.key p + p { margin-top: 6px; }
.key-h { font: 700 12px/1.4 var(--sans) !important; color: var(--accent); letter-spacing: .08em; margin-bottom: 2px !important; }
.key .key-s { margin-top: 4px; font-size: 12px; color: var(--muted); }
.split-k { margin: 0 0 10px; font-size: 14px; }
.split .tbl-w { max-width: 560px; }
.nexts ul { margin: 0; padding-left: 1.2em; font-size: 14px; }
.nexts li { margin: 4px 0; }
.nexts a { font-weight: 700; }
/* PC 幅: 行の右側に数字(1単位あたり・価格・ボタン)、左に名前と札(1行の高さを半分近くに。横に余っていた幅を使う) */
@media (min-width: 900px) {
  .rb { display: grid; grid-template-columns: minmax(0, 1fr) 236px; column-gap: 20px; align-items: start;
    grid-template-areas: "rn ru" "rm rp" "rs rp" "chk rv" "hist hist"; }
  .rn { grid-area: rn; margin-top: 4px !important; }
  .ru { grid-area: ru; justify-content: flex-end; text-align: right; }
  .rm { grid-area: rm; }
  .rs { grid-area: rs; }
  .chk { grid-area: chk; }
  .rp { grid-area: rp; justify-content: flex-end; align-content: flex-start; }
  .rv { grid-area: rv; text-align: right; margin-top: 4px !important; white-space: normal; font-size: 12.5px; line-height: 1.5; }
  .hist { grid-area: hist; }
  .rp .go { margin-left: 0; }
}
/* 押せる大きさ(WCAG 2.2 の 24px): フッター・パンくずの文字だけのリンクに上下の余白 */
.ftr-cats a, .ftr-links a, .yrs-by a, .totop a { display: inline-block; padding: 4px 0; }
.crumbs a { display: inline-block; padding: 3px 0; }
/* 「表は横にスクロールできます」は、本当に横に続きがあるときだけ(app.js が表の枠に more-r を付ける) */
@media (max-width: 720px) { .scroll-hint:has(+ .tbl-w:not(.more-r):not(.more-l)) { display: none; } }
/* 容量帯のページの導入文と、画面の外の行の描画を後回しに(40行・画像つきの一覧を開いたときの重さを減らす) */
.tier-lead { margin: 0 0 8px; font-size: 14px; }
.rows-full .row:nth-child(n+7) { content-visibility: auto; contain-intrinsic-size: auto 190px; }
