:root {
  --bg: #f5f6f3;
  --surface: #ffffff;
  --ink: #18242a;
  --muted: #5a6870;
  --line: #dfe3df;
  --soft: #eef1ee;
  --brand: #0f4c5c;
  --brand-2: #1d6f86;
  --accent: #b5452b;
  --ok: #1d7a4f;
  --warn: #c0392b;
  --unk: #6b7680;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(24, 36, 42, .06), 0 4px 14px rgba(24, 36, 42, .05);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #10171a; --surface: #172126; --ink: #e5ecee; --muted: #9fb0b7; --line: #283840; --soft: #1d2a30;
    --brand: #7fc3d4; --brand-2: #9bd3e0; --accent: #ee8a72; --ok: #45b07c; --warn: #ef7a6a; --unk: #8a979f;
    --shadow: none; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #10171a; --surface: #172126; --ink: #e5ecee; --muted: #9fb0b7; --line: #283840; --soft: #1d2a30;
  --brand: #7fc3d4; --brand-2: #9bd3e0; --accent: #ee8a72; --ok: #45b07c; --warn: #ef7a6a; --unk: #8a979f;
  --shadow: none; color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Yu Gothic", Meiryo, system-ui, sans-serif;
  font-size: 16px; line-height: 1.75; letter-spacing: .01em;
}
a { color: var(--brand-2); text-underline-offset: 2px; }
a:hover { color: var(--brand); }
h1, h2, h3 { line-height: 1.4; margin: 0 0 .5em; }
h1 { font-size: clamp(1.4rem, 4.4vw, 1.95rem); letter-spacing: .02em; }
h2 { font-size: 1.18rem; }
h3 { font-size: 1.02rem; }
p { margin: 0 0 .8em; }
small { color: var(--muted); }
.wrap { max-width: 1000px; margin: 0 auto; padding: 0 16px; }

/* header */
.hd { background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.hd-in { display: flex; align-items: center; gap: 12px; min-height: 58px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.logo { display: flex; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; font-weight: 800; letter-spacing: .04em; white-space: nowrap; }
.logo-m { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; background: var(--brand); color: #fff; font-size: .95rem; }
.nv { display: flex; gap: 14px; font-size: .9rem; margin-left: auto; }
.nv a { color: var(--muted); text-decoration: none; white-space: nowrap; }
.nv a:hover { color: var(--ink); }
.sb { position: relative; flex: 1 1 260px; max-width: 400px; }
.sb-i {
  width: 100%; font: inherit; font-size: 16px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--soft); color: var(--ink); outline: none;
}
.sb-i:focus { border-color: var(--brand-2); background: var(--surface); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-2) 20%, transparent); }
.sb-r {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, .14); overflow: hidden; z-index: 30; max-height: 70vh; overflow-y: auto;
}
.sb-r a { display: block; padding: 9px 14px; text-decoration: none; color: var(--ink); border-top: 1px solid var(--line); }
.sb-r a:first-child { border-top: 0; }
.sb-r a:hover, .sb-r a.on { background: var(--soft); }
.sb-r small { display: block; font-size: .78rem; }
.sb-r .sb-none { padding: 10px 14px; color: var(--muted); font-size: .9rem; }
.sb-r .sb-h { padding: 6px 14px 2px; font-size: .72rem; color: var(--muted); background: var(--soft); border-top: 1px solid var(--line); }
@media (max-width: 760px) {
  .nv { order: 3; width: 100%; justify-content: space-between; margin: 0; gap: 8px; font-size: .82rem; overflow-x: auto; }
  .sb { order: 2; flex-basis: 100%; max-width: none; }
  .hd { position: static; }
}

/* page */
main { padding: 18px 0 40px; }
.bc ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 0; margin: 0 0 12px; font-size: .8rem; color: var(--muted); }
.bc li + li::before { content: "›"; margin-right: 4px; }
.bc a { color: var(--muted); }
.ph { margin: 6px 0 18px; }
.eyebrow { color: var(--muted); font-size: .85rem; margin: 0 0 4px; }
.lead { color: var(--muted); font-size: .98rem; }
.lead b { color: var(--ink); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 14px; margin: 0 0 16px; box-shadow: var(--shadow); }
.sec { margin: 26px 0; }
.note { color: var(--muted); font-size: .82rem; }
.sub { font-weight: 700; font-size: .9rem; margin: 14px 0 6px; }
.more { font-size: .92rem; }
.ul { padding-left: 1.2em; margin: 0 0 .6em; }
.ul li { margin: .3em 0; }
.callout { border-left: 4px solid var(--brand-2); background: var(--surface); padding: 10px 14px; border-radius: 0 10px 10px 0; font-size: .92rem; }
.jump { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: .92rem; }

/* key figures */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 18px 0 8px; }
.kpis div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; text-align: center; box-shadow: var(--shadow); }
.kpis b { display: block; font-size: 1.45rem; color: var(--brand); font-variant-numeric: tabular-nums; line-height: 1.3; }
.kpis span { font-size: .78rem; color: var(--muted); }
.kpi { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 0 0 12px; }
.kpi div { background: var(--soft); border-radius: 10px; padding: 8px 10px; }
.kpi dt { font-size: .75rem; color: var(--muted); }
.kpi dd { margin: 0; font-size: .85rem; }
.kpi b { font-size: 1.15rem; color: var(--brand); font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { .kpis, .kpi { grid-template-columns: repeat(2, 1fr); } }

/* notice list */
.nl { list-style: none; padding: 0; margin: 6px 0 12px; border-top: 1px solid var(--line); }
.nl li { padding: 10px 2px 9px; border-bottom: 1px solid var(--line); }
.nl-t { font-weight: 600; text-decoration: none; line-height: 1.5; word-break: break-word; }
.nl-t:hover { text-decoration: underline; }
.nl-m { display: block; font-size: .8rem; color: var(--muted); margin-top: 2px; }
.nl-m i { font-style: normal; margin: 0 2px; }
.nl-m b { color: var(--ink); }
.nl-m a { color: var(--muted); }
.nl-s { display: block; font-size: .72rem; line-height: 1.5; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st { display: inline-block; font-size: .72rem; font-weight: 700; line-height: 1; padding: 4px 7px; border-radius: 6px; margin-right: 6px; vertical-align: 2px; white-space: nowrap; }
.st-open { background: color-mix(in srgb, var(--ok) 15%, var(--surface)); color: var(--ok); }
.st-soon { background: color-mix(in srgb, var(--warn) 14%, var(--surface)); color: var(--warn); }
.st-unk { background: var(--soft); color: var(--unk); }
.st-closed { background: transparent; color: var(--muted); border: 1px solid var(--line); }
.ft-b { display: inline-block; font-size: .62rem; font-weight: 700; line-height: 1; padding: 3px 4px; border-radius: 4px; border: 1px solid var(--line); color: var(--muted); margin-left: 6px; vertical-align: 2px; }

/* tables */
.tw { overflow-x: auto; margin: 6px 0 12px; }
.dt, .rt, .at { width: 100%; border-collapse: collapse; font-size: .92rem; font-variant-numeric: tabular-nums; }
.dt { max-width: 680px; }
.dt th, .dt td { border-bottom: 1px solid var(--line); padding: 7px 8px; text-align: left; vertical-align: top; }
.dt thead th { font-size: .78rem; color: var(--muted); font-weight: 600; background: var(--soft); }
.dt td { text-align: right; white-space: nowrap; }
.dt th small { display: block; font-size: .72rem; font-weight: 400; }
.dt td.l { text-align: left; white-space: normal; }
.dt td.l small { display: block; font-size: .72rem; }
code { font-size: .85em; background: var(--soft); padding: 1px 5px; border-radius: 4px; word-break: break-all; }
.dt tbody th { font-weight: 600; }
.at th, .at td { border-bottom: 1px solid var(--line); padding: 8px 6px; vertical-align: top; text-align: left; }
.at thead th { font-size: .78rem; color: var(--muted); font-weight: 600; background: var(--soft); white-space: nowrap; }
.at td:nth-child(1) { white-space: nowrap; color: var(--muted); font-size: .82rem; }
.at td:nth-child(2) { min-width: 14em; line-height: 1.5; }
.at td:nth-child(2) small { display: block; font-size: .7rem; }
.at td:nth-child(3) { min-width: 8em; font-size: .86rem; line-height: 1.5; }
.at td:nth-child(3) a { text-decoration: none; font-weight: 600; }
.at td:nth-child(4) { text-align: right; white-space: nowrap; }
.at td:nth-child(4) small { display: block; font-size: .7rem; }
.num { text-align: right !important; white-space: nowrap; }
.rt th, .rt td { border-bottom: 1px solid var(--line); padding: 8px 6px; vertical-align: middle; }
.rt thead th { font-size: .78rem; color: var(--muted); text-align: left; background: var(--soft); font-weight: 600; }
.rt-n { width: 3em; text-align: center; font-weight: 800; color: var(--muted); }
.rt tbody tr:nth-child(-n+3) .rt-n { color: var(--accent); }
.rt-c a { font-weight: 600; text-decoration: none; }
.rt-c small { display: block; font-size: .75rem; line-height: 1.4; }
.dl { margin: 0; }
.dl div { display: grid; grid-template-columns: 7.5em 1fr; gap: 8px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.dl dt { color: var(--muted); font-size: .88rem; }
.dl dd { margin: 0; word-break: break-all; }
.dl dd .dd-l { display: block; margin-top: 2px; font-size: .88rem; }
.badges { list-style: none; padding: 0; margin: 8px 0 0; }
.badges li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.badges b { color: var(--accent); white-space: nowrap; }
.faq h3 { margin-top: 14px; font-size: .98rem; }
.faq h3::before { content: "Q. "; color: var(--brand-2); }

/* lists & grids */
.grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.grid-w { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.grid-m { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.grid a { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; padding: 8px 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-size: .9rem; line-height: 1.4; height: 100%; }
.grid a:hover { border-color: var(--brand-2); }
.grid small { font-size: .72rem; white-space: nowrap; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.chips a, .chips span { padding: 5px 12px; border-radius: 999px; border: 1px solid var(--line); font-size: .85rem; text-decoration: none; background: var(--surface); }
.chips span { background: var(--brand); color: #fff; border-color: var(--brand); }
.minis { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 12px; }
.mini { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.mini h3 { font-size: .95rem; }
.mini ol { list-style: none; padding: 0; margin: 0 0 6px; }
.mini li { display: grid; grid-template-columns: 1.6em 1fr auto; gap: 6px; padding: 5px 0; border-bottom: 1px dashed var(--line); font-size: .9rem; align-items: baseline; }
.mini li span { color: var(--muted); font-weight: 700; }
.mini li em { font-style: normal; color: var(--muted); font-size: .82rem; white-space: nowrap; }
.mini a { text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pg { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0; }
.pg a, .pg span { padding: 4px 11px; border-radius: 8px; border: 1px solid var(--line); text-decoration: none; }
.pg span[aria-current] { background: var(--brand); color: #fff; border-color: var(--brand); }

/* top */
.hero { padding: 26px 0 6px; text-align: center; }
.hero-k { display: inline-block; font-size: .8rem; padding: 3px 12px; border-radius: 999px; background: color-mix(in srgb, var(--ok) 14%, var(--surface)); color: var(--ok); font-weight: 700; margin-bottom: 10px; }
.hero h1 { font-size: clamp(2.1rem, 8vw, 3.2rem); letter-spacing: .08em; margin-bottom: 10px; }
.hero h1 span { color: var(--brand); }
.hero-l { max-width: 660px; margin: 0 auto 18px; color: var(--muted); }
.hero-l b { color: var(--ink); }
.sb-big { max-width: 560px; margin: 0 auto; flex: none; text-align: left; }
.sb-big .sb-i { padding: 13px 20px; font-size: 1.05rem; background: var(--surface); box-shadow: var(--shadow); }
.sb-page { margin: 0 0 16px; max-width: 560px; }
.hero-ex { font-size: .85rem; color: var(--muted); margin-top: 14px; }
.hero-ex a { margin: 0 6px; white-space: nowrap; }
.why p { font-size: .95rem; }
.results ul { list-style: none; padding: 0; margin: 8px 0; }
.results li { padding: 9px 0; border-bottom: 1px solid var(--line); }
.results li a { font-weight: 600; text-decoration: none; }
.results li small { display: block; }
.results h2 { margin-top: 18px; }

/* share */
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 8px 0 18px; }
.share-l { font-size: .85rem; color: var(--muted); margin-right: 4px; }
.sh { font: inherit; font-size: .85rem; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-decoration: none; cursor: pointer; }
.sh-x { background: #111; color: #fff; border-color: #111; }
.sh-line { background: #06c755; color: #fff; border-color: #06c755; }
.sh-hb { background: #00a4de; color: #fff; border-color: #00a4de; }

/* footer */
.ft { border-top: 1px solid var(--line); background: var(--surface); padding: 22px 0 30px; font-size: .8rem; color: var(--muted); }
.ft a { color: var(--muted); }
.ft-nv { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 10px 0; }
.ft-c { margin-top: 8px; }

/* スマホでは落札の表を1件ずつの縦並びにする（落札額が隠れないように） */
@media (max-width: 600px) {
  .at thead { display: none; }
  .at, .at tbody, .at td { display: block; }
  .at tr { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "t t" "w w" "d y"; gap: 2px 8px; padding: 9px 0; border-bottom: 1px solid var(--line); }
  .at td { border: 0; padding: 0; min-width: 0 !important; }
  .at td:nth-child(1) { grid-area: d; align-self: end; }
  .at td:nth-child(2) { grid-area: t; font-weight: 600; }
  .at td:nth-child(2) small { font-weight: 400; }
  .at td:nth-child(3) { grid-area: w; }
  .at td:nth-child(4) { grid-area: y; font-weight: 700; }
  .at td:nth-child(4) small { display: inline; margin-left: 4px; }
  .tw:has(.at) { overflow-x: visible; }
}
@media (max-width: 520px) {
  .card { padding: 14px 14px 10px; }
  .dl div { grid-template-columns: 6em 1fr; }
  .rt, .at { font-size: .86rem; }
  .rt-n { width: 2.2em; }
}
