/* 単価しらべ — X の画像と同じ色（黄色・白・濃いグレー・赤） */
:root {
  --bg: #FFF8E7;
  --card: #FFFFFF;
  --ink: #1F2328;
  --muted: #59606A;
  --line: #EADFC4;
  --yellow: #FFC93C;
  --red: #C8323A;
  --red-soft: #FDECEC;
  --link: #1F5FBF;
  --radius: 14px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15171B;
    --card: #1F2329;
    --ink: #ECEEF1;
    --muted: #A9B0BA;
    --line: #333944;
    --red: #FF7479;
    --red-soft: #3A2224;
    --link: #8DB8FF;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  font-feature-settings: "palt" 0;
}
a { color: var(--link); }
img { max-width: 100%; height: auto; }
.wrap { max-width: 860px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 8px; top: 8px; background: var(--card); padding: 6px 10px; z-index: 10; }

/* ヘッダー */
.site-head { background: var(--yellow); color: #1F2328; }
.head-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 16px; padding-top: 10px; padding-bottom: 10px; }
.logo { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-weight: 800; font-size: 18px; }
.logo img { border-radius: 50%; background: #fff; }
.logo small { font-size: 12px; font-weight: 600; opacity: .8; }
@media (max-width: 560px) { .logo small { display: none; } }
.nav { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 14px; font-weight: 600; }
.nav a { color: inherit; text-decoration: none; }
.nav a:hover { text-decoration: underline; }
.pr { margin: 0; padding: 8px 16px; font-size: 12.5px; line-height: 1.6; color: var(--muted); background: var(--card); border-bottom: 1px solid var(--line); text-align: center; }
.pr-tag { display: inline-block; margin-right: 6px; padding: 0 6px; border: 1px solid currentColor; border-radius: 4px; font-weight: 700; font-size: 11px; }

main { padding-top: 20px; padding-bottom: 48px; }
h1 { font-size: 26px; line-height: 1.35; margin: 8px 0 12px; }
h2 { font-size: 20px; line-height: 1.4; margin: 36px 0 10px; padding-left: 10px; border-left: 5px solid var(--yellow); }
section > p, section > ul { margin: 8px 0; }

/* トップ */
.hero { padding: 8px 0 4px; }
.hero h1 { font-size: 28px; }
.hero p { margin: 6px 0; }
.cats { list-style: none; padding: 0; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.cat { display: grid; grid-template-columns: 72px 1fr; grid-template-rows: auto auto auto auto; column-gap: 12px; padding: 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); color: inherit; text-decoration: none; height: 100%; }
.cat:hover { border-color: var(--yellow); box-shadow: 0 2px 10px rgba(0,0,0,.06); }
.cat img { grid-row: 1 / span 4; align-self: center; background: #fff; border-radius: 50%; padding: 4px; }
.cat-title { font-weight: 800; line-height: 1.4; }
.cat-sub { font-size: 13px; color: var(--muted); }
.cat-top { margin-top: 4px; font-size: 14px; }
.cat-top b { font-size: 22px; color: var(--red); }
.cat-date { font-size: 12px; color: var(--muted); }
.how ul { padding-left: 1.2em; }

/* ランキング */
.crumbs { font-size: 13px; color: var(--muted); display: flex; gap: 6px; flex-wrap: wrap; }
.rank-head { display: flex; align-items: center; gap: 16px; margin-top: 8px; }
.cat-icon { flex: none; width: 104px; height: 104px; background: #fff; border: 4px solid var(--ink); border-radius: 50%; padding: 6px; }
.rank-head h1 { margin: 0; }
.rank-head .sub { display: block; font-size: 17px; font-weight: 700; color: var(--muted); margin-top: 2px; }
.checked { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.lead { margin: 16px 0; }
.lead strong { color: var(--red); }

.ranking { list-style: none; padding: 0; margin: 16px 0 8px; display: grid; gap: 10px; }
.item { display: grid; grid-template-columns: 44px 1fr auto; grid-template-areas: "no body up" "no body btn"; align-items: center; column-gap: 14px; row-gap: 6px; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.item.top { border: 3px solid var(--red); background: linear-gradient(var(--card), var(--card)) padding-box; }
.no { grid-area: no; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: var(--bg); font-weight: 800; font-size: 20px; }
.item.top .no { background: var(--red); color: #fff; }
.item-body { grid-area: body; min-width: 0; }
.item-body p { margin: 0; }
.item-name { font-weight: 800; font-size: 17px; line-height: 1.45; }
.item-spec { font-size: 14px; }
.item-shop { font-size: 12.5px; color: var(--muted); }
.item-up { grid-area: up; margin: 0; text-align: right; white-space: nowrap; }
.item-up b { font-size: 30px; line-height: 1; letter-spacing: -.5px; }
.item.top .item-up b { color: var(--red); }
.item-up span { font-size: 13px; font-weight: 700; margin-left: 2px; }
.btn { grid-area: btn; justify-self: end; display: inline-block; padding: 7px 14px; border-radius: 999px; background: #BF0000; color: #fff; font-size: 13.5px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.btn:hover { background: #9E0000; }
.btn:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
.ref { font-weight: 700; margin: 8px 0; }
.price-note { font-size: 13px; color: var(--muted); }
.formula { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; font-weight: 700; }
.notes { padding-left: 1.2em; font-size: 14px; color: var(--muted); }
.hist { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--card); }
.hist th, .hist td { border-bottom: 1px solid var(--line); padding: 8px; text-align: left; }
.hist .num { white-space: nowrap; font-weight: 700; }
.others { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; }
.others a { display: inline-block; padding: 6px 12px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: inherit; font-size: 14px; }

/* フッター */
.site-foot { border-top: 1px solid var(--line); padding: 20px 0 28px; font-size: 13px; color: var(--muted); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 8px; }
.foot-links a { color: inherit; }
.copy { margin: 0; }

@media (max-width: 560px) {
  h1 { font-size: 22px; }
  .hero h1 { font-size: 23px; }
  .rank-head { gap: 12px; }
  .cat-icon { width: 76px; height: 76px; border-width: 3px; }
  .rank-head .sub { font-size: 15px; }
  .item { grid-template-columns: 36px 1fr auto; grid-template-areas: "no body up" "btn btn btn"; padding: 12px; column-gap: 10px; }
  .no { width: 34px; height: 34px; font-size: 17px; }
  .item-name { font-size: 15.5px; }
  .item-up b { font-size: 24px; }
  .btn { justify-self: stretch; text-align: center; padding: 9px 14px; }
}
