/* 製品比較表と一覧（器具・消耗品に共通）。すべて .cmp の内側だけに効く。
   色はトップページ（home-modern.css）の濃い青緑・金・淡い緑に合わせる。書体は site.css のものを使う。
   CSPの都合で、画像・インラインスタイルは使わず、模様もCSSのグラデーションで描く。 */
.cmp {
  --cmp-deep: #0d343a;
  --cmp-teal: #076b68;
  --cmp-mint: #e3f5f0;
  --cmp-gold: #e5aa50;
  --cmp-paper: #f6f8f5;
  --cmp-edge: #c9d8d2;
  --cmp-shadow: 0 1px 2px rgba(13, 52, 58, .06), 0 12px 28px rgba(13, 52, 58, .08);
}
.cmp [hidden] { display: none !important; }

/* 見出しの帯 */
.cmp .cmp-hero {
  position: relative; overflow: hidden;
  padding: 34px 36px 30px; border-radius: 18px; color: #fff;
  background:
    radial-gradient(520px 260px at 92% -10%, rgba(229, 170, 80, .22), transparent 70%),
    radial-gradient(420px 300px at 78% 120%, rgba(141, 191, 184, .28), transparent 70%),
    linear-gradient(rgba(141, 191, 184, .09) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(90deg, rgba(141, 191, 184, .09) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(120deg, #0a3037, #10464a);
}
.cmp .cmp-hero::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, var(--cmp-teal) 0 72%, var(--cmp-gold) 72%); }
.cmp .cmp-hero .eyebrow { color: #9fe0d2; }
.cmp .cmp-hero h1 { margin: 0 0 10px; color: #fff; font-size: clamp(28px, 4.2vw, 42px); letter-spacing: .01em; }
/* 見出しは語のまとまりで折り返す */
.cmp .cmp-phrase { display: inline-block; }
.cmp .cmp-lead { max-width: 760px; margin: 0; color: #d6ebe6; }
.cmp .cmp-facts { display: flex; flex-wrap: wrap; gap: 10px; margin: 22px 0 0; padding: 0; list-style: none; }
.cmp .cmp-facts li { display: flex; align-items: baseline; gap: 6px; padding: 7px 14px; border: 1px solid rgba(159, 224, 210, .35); border-radius: 99px; background: rgba(255, 255, 255, .07); font-size: 14px; color: #e6f4f0; }
.cmp .cmp-facts strong { font-size: 18px; color: var(--cmp-gold); }

.cmp h2 { font-size: 20px; margin: 0 0 12px; }
.cmp .cmp-notice { margin: 18px 0 0; padding: 12px 16px; border: 1px solid #e3c98f; border-left-width: 4px; border-radius: 10px; background: #fbf0d9; }
.cmp .cmp-entry { margin: 14px 0 0; font-size: 15px; }
.cmp .cmp-ad-notice { margin: 14px 0 0; font-size: 13px; color: var(--muted); }

/* 絞り込み */
.cmp .cmp-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 18px 30px; margin-top: 22px; padding: 22px 24px; border: 1px solid var(--cmp-edge); border-radius: 16px; background: #fff; box-shadow: var(--cmp-shadow); }
.cmp fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.cmp legend { padding: 0; margin-bottom: 10px; font-size: 12px; font-weight: 750; letter-spacing: .08em; color: var(--cmp-teal); }
.cmp .cmp-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cmp .cmp-chips label { position: relative; cursor: pointer; }
.cmp .cmp-chips input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.cmp .cmp-chips span { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 4px 8px 4px 14px; border: 1px solid var(--cmp-edge); border-radius: 12px; background: #fff; font-size: 14px; line-height: 1.4; transition: background-color .15s ease, border-color .15s ease, box-shadow .15s ease, color .15s ease; }
.cmp .cmp-chips small { min-width: 22px; padding: 1px 6px; border-radius: 99px; background: var(--cmp-paper); font-size: 11px; font-weight: 700; text-align: center; color: var(--muted); }
.cmp .cmp-chips label:hover span { border-color: var(--cmp-teal); background: var(--cmp-mint); }
.cmp .cmp-chips input:checked + span { background: var(--cmp-teal); border-color: var(--cmp-teal); color: #fff; font-weight: 650; box-shadow: 0 4px 12px rgba(7, 107, 104, .28); }
.cmp .cmp-chips input:checked + span small { background: rgba(255, 255, 255, .22); color: #fff; }
.cmp .cmp-chips input:focus-visible + span { outline: 3px solid #bb6b16; outline-offset: 2px; }

.cmp .cmp-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 26px 0 12px; }
.cmp .cmp-status { margin: 0 auto 0 0; font-size: 17px; font-weight: 750; color: var(--cmp-deep); }
.cmp .cmp-sort { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.cmp select, .cmp .cmp-reset { min-height: 38px; padding: 4px 14px; border: 1px solid var(--cmp-edge); border-radius: 99px; background: #fff; color: var(--cmp-deep); font: inherit; font-size: 14px; }
.cmp .cmp-reset { cursor: pointer; }
.cmp .cmp-reset:hover, .cmp select:hover { border-color: var(--cmp-teal); background: var(--cmp-mint); }
.cmp select:focus-visible, .cmp .cmp-reset:focus-visible { outline: 3px solid #bb6b16; outline-offset: 2px; }

/* 一覧：広い画面では表のように列をそろえ、狭い画面ではカードにする */
.cmp .cmp-table { border: 1px solid var(--cmp-edge); border-radius: 16px; background: #fff; box-shadow: var(--cmp-shadow); overflow: hidden; }
.cmp .cmp-head, .cmp .cmp-item > summary { display: grid; grid-template-columns: 1.25fr 1.8fr 1.45fr .7fr .7fr 1.1fr .6fr 28px; gap: 12px; align-items: center; }
.cmp .cmp-head { padding: 12px 18px; background: var(--cmp-deep); color: #cfe9e3; font-size: 12px; font-weight: 750; letter-spacing: .08em; }
.cmp .cmp-item + .cmp-item { border-top: 1px solid #e3ebe8; }
.cmp .cmp-item > summary { padding: 13px 18px; cursor: pointer; list-style: none; font-size: 15px; line-height: 1.5; transition: background-color .15s ease; }
.cmp .cmp-item > summary::-webkit-details-marker { display: none; }
.cmp .cmp-item > summary::after { content: '＋'; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--cmp-mint); color: var(--cmp-teal); font-weight: 800; }
.cmp .cmp-item[open] > summary::after { content: '－'; background: var(--cmp-teal); color: #fff; }
.cmp .cmp-item > summary:hover { background: #f1f8f6; }
.cmp .cmp-item > summary:focus-visible { outline: 3px solid #bb6b16; outline-offset: -3px; }
.cmp .cmp-item[open] > summary { background: var(--cmp-paper); }
.cmp .cmp-maker { color: var(--muted); font-size: 13px; }
.cmp .cmp-name { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; min-width: 0; overflow-wrap: anywhere; }
.cmp .cmp-name strong { color: var(--cmp-deep); font-size: 16px; }
.cmp .cmp-series { font-size: 12px; color: var(--muted); }
.cmp .cmp-cell-label { display: none; }
.cmp .cmp-cell-key > span:last-child { display: inline-block; padding: 2px 10px; border-radius: 99px; background: var(--cmp-mint); color: #0b5450; font-size: 13px; font-weight: 700; }
.cmp .cmp-none { color: #8a9aa0; }
.cmp .cmp-tag { padding: 0 8px; border-radius: 99px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.cmp .cmp-tag.new { background: var(--cmp-gold); color: var(--cmp-deep); }
.cmp .cmp-tag.stale { background: #fbf0d9; color: #8a5a00; }
/* 行の模式図（カテゴリの入口が図を渡したときだけ） */
.cmp .cmp-name.cmp-has-figure { flex-wrap: nowrap; align-items: center; gap: 10px; }
.cmp .cmp-name-text { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; min-width: 0; }
.cmp .cmp-figure { display: block; flex: none; padding: 2px; border-radius: 8px; background: #fff; box-shadow: inset 0 0 0 1px var(--cmp-edge); }
/* 形の見分け方（図の一覧） */
.cmp .cmp-guide { margin-top: 22px; border: 1px solid var(--cmp-edge); border-radius: 16px; background: #fff; box-shadow: var(--cmp-shadow); }
.cmp .cmp-guide > summary { padding: 14px 22px; font-weight: 750; color: var(--cmp-deep); cursor: pointer; }
.cmp .cmp-guide-body { padding: 0 22px 18px; }
.cmp .cmp-guide-title { margin: 12px 0 8px; font-size: 14px; font-weight: 750; color: var(--cmp-teal); }
.cmp .cmp-guide-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.cmp .cmp-guide-row figure { display: grid; justify-items: center; gap: 6px; margin: 0; padding: 12px 8px 10px; border-radius: 12px; background: var(--cmp-paper); text-align: center; }
.cmp .cmp-guide-row figcaption { font-size: 13px; line-height: 1.5; }
.cmp .cmp-guide-row figcaption strong { display: block; color: var(--cmp-deep); word-break: keep-all; overflow-wrap: anywhere; }
.cmp .cmp-guide-row figcaption span { color: var(--muted); font-size: 12px; }
.cmp .cmp-guide-row.cmp-guide-wide { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), max-content)); }
.cmp .cmp-guide-row svg { max-width: 100%; height: auto; }
.cmp .cmp-guide-note { margin: 12px 0 0; font-size: 12px; color: var(--muted); }

.cmp .cmp-detail { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 20px 32px; padding: 6px 18px 20px; background: var(--cmp-paper); font-size: 14px; }
.cmp .cmp-detail dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0 18px; margin: 0; }
.cmp .cmp-detail dt, .cmp .cmp-detail dd { padding: 7px 0; border-top: 1px solid #dfe8e5; }
.cmp .cmp-detail dt { color: var(--muted); font-size: 13px; }
.cmp .cmp-detail dd { margin: 0; overflow-wrap: anywhere; }
.cmp .cmp-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; align-content: start; }
.cmp .cmp-links li { display: flex; align-items: center; overflow-wrap: anywhere; }
.cmp .cmp-links li > a { min-width: 0; }
.cmp .cmp-links li:first-child a { font-size: 13px; }
.cmp .cmp-links a[rel~=sponsored] { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 16px; border-radius: 12px; background: var(--cmp-deep); color: #fff; font-weight: 700; text-decoration: none; box-shadow: 0 6px 16px rgba(13, 52, 58, .2); transition: background-color .15s ease; }
.cmp .cmp-links a[rel~=sponsored]::after { content: '→'; flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--cmp-gold); color: var(--cmp-deep); }
.cmp .cmp-links a[rel~=sponsored]:hover { background: #124850; }
.cmp .cmp-empty { margin: 0; padding: 30px 18px; text-align: center; color: var(--muted); }

/* 掲載の基準と出典 */
.cmp .cmp-about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px; margin-top: 44px; padding: 28px 30px; border-radius: 16px; background: var(--cmp-paper); }
.cmp .cmp-about ul { padding-left: 1.2em; margin: 0; font-size: 14px; line-height: 1.75; }
.cmp .cmp-about li { margin-top: 7px; overflow-wrap: anywhere; }
.cmp .cmp-about li::marker { color: var(--cmp-teal); }
.cmp .cmp-about h3 { font-size: 16px; margin: 0 0 10px; color: var(--cmp-deep); }
.cmp .cmp-about ul + h3 { margin-top: 26px; }
.cmp .cmp-checked { margin-top: 14px; font-size: 13px; color: var(--muted); }

/* カテゴリの一覧 */
.cmp .cmp-categories { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; margin: 26px 0 0; list-style: none; padding: 0; }
.cmp .cmp-category { position: relative; overflow: hidden; border: 1px solid var(--cmp-edge); border-radius: 16px; padding: 24px 24px 18px; background: #fff; box-shadow: var(--cmp-shadow); }
.cmp .cmp-category::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: linear-gradient(90deg, var(--cmp-teal) 0 72%, var(--cmp-gold) 72%); }
.cmp .cmp-category h2 { font-size: 21px; margin: 0 0 6px; }
.cmp .cmp-category p { margin: 0 0 14px; font-size: 14px; color: var(--muted); }
.cmp .cmp-category ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cmp .cmp-category li a { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0 12px; min-height: 56px; padding: 8px 14px; border: 1px solid var(--cmp-edge); border-radius: 12px; color: var(--cmp-deep); font-weight: 700; text-decoration: none; transition: background-color .15s ease, border-color .15s ease; }
.cmp .cmp-category li a span { grid-column: 1; font-size: 11px; font-weight: 700; letter-spacing: .08em; color: var(--cmp-teal); }
.cmp .cmp-category li a::after { content: '→'; grid-column: 2; grid-row: 1 / 3; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--cmp-mint); color: var(--cmp-teal); }
.cmp .cmp-category li a:hover { border-color: var(--cmp-teal); background: var(--cmp-mint); }

@media (max-width: 860px) {
  .cmp .cmp-hero { padding: 26px 22px 24px; border-radius: 14px; }
  .cmp .cmp-filters { padding: 16px; gap: 16px; }
  .cmp .cmp-head { display: none; }
  .cmp .cmp-table { border: 0; border-radius: 0; background: none; box-shadow: none; overflow: visible; }
  .cmp .cmp-list { display: grid; gap: 12px; }
  .cmp .cmp-item, .cmp .cmp-item + .cmp-item { border: 1px solid var(--cmp-edge); border-radius: 14px; overflow: hidden; background: #fff; box-shadow: var(--cmp-shadow); }
  .cmp .cmp-item > summary { position: relative; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 12px; padding: 14px 52px 14px 16px; }
  .cmp .cmp-maker, .cmp .cmp-name { grid-column: 1 / -1; }
  .cmp .cmp-name strong { font-size: 18px; }
  .cmp .cmp-item > summary::after { position: absolute; top: 14px; right: 14px; }
  .cmp .cmp-cell { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; font-size: 14px; }
  .cmp .cmp-cell-label { display: block; font-size: 11px; letter-spacing: .06em; color: var(--muted); }
  .cmp .cmp-detail { grid-template-columns: 1fr; padding: 4px 16px 18px; }
  .cmp .cmp-about { grid-template-columns: 1fr; padding: 22px 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .cmp * { transition: none !important; }
}
