/* Layout: 1120px column on warm light grey. White "sheets" carry content; the ink band and the blue accent give the page its rhythm.
   Motif: a prompt is a sheet of paper — thumbnails and the hero show product sheets resting on category-colored ground. */
:root {
  --bg: #F7F7F5;
  --surface: #FFFFFF;
  --surface-2: #EFEFEB;
  --fg: #16161A;
  --ink: #16161A;
  --ink-soft: #2A2A31;
  --on-ink: #F7F7F5;
  --on-ink-muted: #A9A9B2;
  --muted: #5E5E66;
  --subtle: #8A8A92;
  --line: #E3E3DF;
  --line-strong: #CFCFC9;
  --accent: #3B5BDB;
  --accent-hover: #2F4CC0;
  --accent-weak: #EDF1FC;
  --accent-on-ink: #8FA6F5;
  --star: #E0A100;
  --ok: #2B7A3D;
  --ok-weak: #E7F4EA;
  --wait: #9A5B00;
  --wait-weak: #FCF1DE;
  --danger: #C02B2B;
  --danger-weak: #FCEBEB;

  /* カテゴリの地の色（落ち着いた中間色） */
  --thumb-work: #DCE6F5;
  --thumb-writing: #EAD9D3;
  --thumb-doc: #E9E3CD;
  --thumb-image: #E2D9EC;
  --thumb-video: #F2DCDA;
  --thumb-sns: #F5E3CF;
  --thumb-code: #D7E7E4;
  --thumb-sales: #D7DFF3;
  --thumb-ec: #D6E4DA;
  --thumb-study: #E5E9D0;
  --mark-work: #2F5BB7;
  --mark-writing: #9C4F3D;
  --mark-doc: #7A6420;
  --mark-image: #6B4A93;
  --mark-video: #A8392F;
  --mark-sns: #9A5210;
  --mark-code: #2B6A62;
  --mark-sales: #3B5BDB;
  --mark-ec: #2F6B45;
  --mark-study: #5A6A1C;

  --font: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, system-ui, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Noto Sans JP", monospace;

  --fs-xs: 0.75rem;
  --fs-sm: 0.8125rem;
  --fs-base: 0.9375rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.375rem;
  --fs-xl: 1.875rem;
  --fs-2xl: clamp(1.625rem, 1.2rem + 1.4vw, 2.25rem);
  --fs-hero: clamp(2rem, 1.1rem + 3vw, 3.25rem);

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(22, 22, 26, .06);
  --shadow: 0 2px 4px rgba(22, 22, 26, .04), 0 12px 28px -8px rgba(22, 22, 26, .16);
  --shadow-lg: 0 4px 8px rgba(22, 22, 26, .05), 0 28px 56px -16px rgba(22, 22, 26, .28);
  --maxw: 1120px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: 1.75;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-feature-settings: "palt" 0;
}
main { flex: 1; outline: none; }
img { max-width: 100%; }
[hidden] { display: none !important; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3 { line-height: 1.4; text-wrap: balance; margin: 0; font-weight: 800; letter-spacing: 0.01em; }
p { margin: 0; }

.wrap {
  width: 100%;
  max-width: calc(var(--maxw) + 2 * 24px);
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) {
  .wrap { padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-size: var(--fs-sm); font-weight: 700;
  padding: 9px 18px; border-radius: 999px;
  border: 1px solid transparent; cursor: pointer; white-space: nowrap;
  text-decoration: none; line-height: 1.5;
  transition: background-color .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--accent); color: #FFFFFF; box-shadow: 0 1px 0 rgba(22, 22, 26, .12); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: var(--surface); color: var(--fg); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--fg); }
.btn-ink { background: var(--ink); color: var(--on-ink); }
.btn-ink:hover { background: var(--ink-soft); }
.btn-lg { font-size: var(--fs-base); padding: 13px 26px; }
.btn-block { width: 100%; }
.arrow::after { content: ""; width: 7px; height: 7px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); margin-left: 4px; }

/* Header */
.site-header {
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line);
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--surface); }
.header-inner { display: flex; align-items: center; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.logo { display: inline-flex; align-items: center; gap: 8px; font-weight: 900; font-size: 1.25rem; color: var(--fg); letter-spacing: -0.01em; }
.logo::before {
  content: ""; width: 22px; height: 26px; border-radius: 4px; background: var(--accent);
  box-shadow: 5px -4px 0 -1px var(--ink);
  clip-path: polygon(0 0, 70% 0, 100% 24%, 100% 100%, 0 100%);
}
.logo span { color: var(--accent); margin-left: -6px; }
.logo:hover { text-decoration: none; }
.global-nav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.global-nav > a:not(.btn) { color: var(--fg); font-size: var(--fs-sm); font-weight: 500; padding: 8px 12px; border-radius: 999px; }
.global-nav > a:not(.btn):hover, .global-nav > a.is-current { background: var(--surface-2); text-decoration: none; }
.menu-btn { display: none; margin-left: auto; font: inherit; font-size: var(--fs-sm); font-weight: 700; background: none; border: 1px solid var(--line-strong); border-radius: 999px; padding: 6px 14px; color: var(--fg); cursor: pointer; }

@media (max-width: 959px) {
  .menu-btn { display: inline-block; }
  .global-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 4px; padding-bottom: 12px; margin-left: 0; }
  .global-nav.is-open { display: flex; }
  .global-nav > a:not(.btn) { padding: 10px 12px; font-size: var(--fs-base); border-radius: var(--radius-sm); }
  .global-nav .btn { padding: 11px; font-size: var(--fs-base); }
}

/* Sections */
.section { padding-block: 64px; }
.section + .section { padding-top: 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 24px; flex-wrap: wrap; }
.section-head h2 { font-size: var(--fs-2xl); letter-spacing: 0; }
.section-head p { color: var(--muted); font-size: var(--fs-sm); margin-top: 4px; }
.section-head > a { font-size: var(--fs-sm); font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: var(--fs-xs); font-weight: 700; color: var(--accent); letter-spacing: 0.12em; margin-bottom: 8px; }
.eyebrow::before { content: ""; width: 18px; height: 2px; background: currentColor; }

/* Hero */
.hero { background: var(--surface); border-bottom: 1px solid var(--line); overflow: hidden; position: relative; }
.hero::before {
  /* 方眼紙のような細い罫線（単色の線を重ねたもの） */
  content: ""; position: absolute; top: 0; bottom: 0; left: 52%; right: 0; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32'%3E%3Cpath d='M32 0H0V32' fill='none' stroke='%23E3E3DF' stroke-width='1'/%3E%3C/svg%3E");
  border-left: 1px solid var(--line);
}
@media (max-width: 899px) { .hero::before { left: 0; top: auto; height: 46%; border-left: 0; border-top: 1px solid var(--line); } }
.hero-inner { position: relative; padding-block: 72px 64px; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .8fr); gap: 40px; align-items: center; }
.hero-copy { display: grid; gap: 28px; min-width: 0; }
.hero h1 { font-size: var(--fs-hero); font-weight: 900; letter-spacing: -0.02em; line-height: 1.25; }
.hero h1 .line { display: block; }
.hero h1 .hp { display: inline-block; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-lead { color: var(--muted); font-size: var(--fs-md); max-width: 32em; }
.search {
  display: flex; gap: 6px; max-width: 600px; padding: 6px; background: var(--surface);
  border: 1.5px solid var(--ink); border-radius: 999px; box-shadow: 4px 4px 0 var(--ink);
}
.search:focus-within { box-shadow: 4px 4px 0 var(--accent); border-color: var(--accent); }
.search input {
  flex: 1; min-width: 0; font: inherit; font-size: var(--fs-base);
  padding: 10px 16px; border: 0; background: transparent; color: var(--fg); outline: none;
}
.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: var(--fs-sm); color: var(--muted); }
.chip {
  display: inline-flex; align-items: center; font: inherit; font-size: var(--fs-sm);
  padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--fg); cursor: pointer;
}
.chip:hover { border-color: var(--accent); color: var(--accent); text-decoration: none; }
.hero-figures { display: flex; gap: 32px; flex-wrap: wrap; padding-top: 4px; }
.hero-figures div { display: flex; flex-direction: column; }
.hero-figures b { font-size: 1.75rem; font-weight: 900; line-height: 1.2; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.hero-figures b small { font-size: var(--fs-sm); font-weight: 700; margin-left: 2px; }
.hero-figures span { font-size: var(--fs-xs); color: var(--muted); }

/* ヒーローの見本カード（実際の人気商品をプロンプトのシートとして見せる） */
.showcase { position: relative; padding: 24px 8px 24px 32px; min-width: 0; }
.showcase-back {
  position: absolute; inset: 0 24px 40px 0; border-radius: 18px; transform: rotate(-4deg);
  background: var(--thumb-sales);
}
.showcase-card {
  position: relative; display: block; background: var(--surface); border-radius: 16px; padding: 22px;
  border: 1px solid var(--line); box-shadow: var(--shadow-lg); color: var(--fg); transform: rotate(1.5deg);
  transition: transform .25s;
}
.showcase-card:hover { transform: rotate(0deg) translateY(-4px); text-decoration: none; }
.showcase-tag { position: absolute; top: -14px; right: 20px; background: var(--ink); color: var(--on-ink); font-size: var(--fs-xs); font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.showcase-card h3 { font-size: var(--fs-md); margin: 10px 0 14px; line-height: 1.5; }
.showcase-code { font-family: var(--mono); font-size: var(--fs-xs); line-height: 1.9; background: var(--bg); border-radius: var(--radius-sm); padding: 12px 14px; color: var(--ink-soft); white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
.showcase-code .blur { filter: blur(4px); user-select: none; }
.showcase-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; gap: 12px; }
.showcase-foot .price { font-size: 1.5rem; font-weight: 900; }
.showcase-foot .seller { font-size: var(--fs-xs); color: var(--muted); }
@media (max-width: 899px) {
  .hero-inner { grid-template-columns: minmax(0, 1fr); gap: 40px; padding-block: 48px 48px; }
  .showcase { max-width: 460px; }
}
@media (max-width: 479px) {
  .search { border-radius: 16px; flex-direction: column; box-shadow: 3px 3px 0 var(--ink); }
  .search .btn { width: 100%; }
  .hero-figures { gap: 20px; }
  .showcase { padding-left: 16px; }
}

/* Category list */
.cat-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.cat-card {
  position: relative; display: flex; flex-direction: column; gap: 14px; padding: 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--fg); font: inherit; text-align: left; cursor: pointer; overflow: hidden;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.cat-mark {
  width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center;
  font-weight: 900; font-size: var(--fs-md); letter-spacing: -0.02em;
}
.cat-card strong { font-size: var(--fs-base); font-weight: 800; line-height: 1.4; }
.cat-card .count { font-size: var(--fs-xs); color: var(--muted); display: flex; justify-content: space-between; align-items: center; }
.cat-card .count::after { content: ""; width: 6px; height: 6px; border-top: 2px solid var(--subtle); border-right: 2px solid var(--subtle); transform: rotate(45deg); }
.cat-card:hover .count::after { border-color: var(--accent); }
@media (max-width: 899px) { .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 539px) { .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }



/* カテゴリの色：data-cat ごとに地の色（--cat-bg）と文字の色（--cat-mark）を決める */
[data-cat="work"] { --cat-bg: var(--thumb-work); --cat-mark: var(--mark-work); }
[data-cat="writing"] { --cat-bg: var(--thumb-writing); --cat-mark: var(--mark-writing); }
[data-cat="doc"] { --cat-bg: var(--thumb-doc); --cat-mark: var(--mark-doc); }
[data-cat="image"] { --cat-bg: var(--thumb-image); --cat-mark: var(--mark-image); }
[data-cat="video"] { --cat-bg: var(--thumb-video); --cat-mark: var(--mark-video); }
[data-cat="sns"] { --cat-bg: var(--thumb-sns); --cat-mark: var(--mark-sns); }
[data-cat="code"] { --cat-bg: var(--thumb-code); --cat-mark: var(--mark-code); }
[data-cat="sales"] { --cat-bg: var(--thumb-sales); --cat-mark: var(--mark-sales); }
[data-cat="ec"] { --cat-bg: var(--thumb-ec); --cat-mark: var(--mark-ec); }
[data-cat="study"] { --cat-bg: var(--thumb-study); --cat-mark: var(--mark-study); }
.showcase-back[data-cat] { background: var(--cat-bg); }
[data-cat] .cat-mark, .cat-mark[data-cat] { background: var(--cat-bg); color: var(--cat-mark); }
.thumb[data-cat] { background: var(--cat-bg); --mark: var(--cat-mark); }
.cat-card .cat-desc { font-size: var(--fs-xs); color: var(--muted); line-height: 1.6; }
.cat-card .cat-mark { font-size: var(--fs-sm); }
.cat-intro { margin-top: 6px; font-size: var(--fs-sm); color: var(--muted); }

/* Product cards */
.product-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 899px) { .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 539px) { .product-grid { grid-template-columns: minmax(0, 1fr); } }
.card {
  display: flex; flex-direction: column; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: var(--fg);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; text-decoration: none; }
.thumb {
  position: relative; aspect-ratio: 16 / 10; max-width: 100%; overflow: hidden;
  padding: 14px 16px 0; display: flex; flex-direction: column; gap: 12px;
}
.thumb-top { display: flex; gap: 6px; flex-wrap: wrap; position: relative; z-index: 1; }
/* 紙のシート */
.sheet {
  flex: 1; margin: 0 6% 0 10%; background: var(--surface); border-radius: 8px 8px 0 0;
  padding: 14px 16px 0; box-shadow: 0 -1px 0 rgba(22, 22, 26, .04), 0 10px 24px -6px rgba(22, 22, 26, .22);
  transform: rotate(-2deg) translateY(6px); transform-origin: bottom left;
  display: flex; flex-direction: column; gap: 7px; transition: transform .25s;
}
.card:hover .sheet { transform: rotate(0deg) translateY(0); }
.sheet-head { display: flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 10px; color: var(--mark); font-weight: 700; letter-spacing: .04em; }
.sheet-head::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--mark); }
.thumb-word { font-size: 1.0625rem; font-weight: 900; line-height: 1.45; color: var(--fg); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; letter-spacing: -0.005em; }
.sheet-lines { display: grid; gap: 6px; margin-top: 2px; }
.sheet-lines i { display: block; height: 6px; border-radius: 3px; background: var(--surface-2); }
.sheet-lines i:nth-child(1) { width: 92%; }
.sheet-lines i:nth-child(2) { width: 78%; }
.sheet-lines i:nth-child(3) { width: 85%; }
.badge {
  display: inline-block; font-size: var(--fs-xs); font-weight: 700; line-height: 1.6;
  padding: 1px 9px; border-radius: 999px; background: rgba(255, 255, 255, .82); color: var(--fg); border: 1px solid transparent;
}
.panel .badge, .detail-tags .badge, .profile-tags .badge, .purchase .badge, .table .badge { background: var(--surface-2); }
.badge-skill, .panel .badge-skill, .detail-tags .badge-skill, .purchase .badge-skill { background: var(--ink); color: var(--on-ink); }
.badge-accent, .detail-tags .badge-accent { background: var(--accent); color: #FFFFFF; }
.card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; border-top: 1px solid var(--line); }
.card-title { font-size: var(--fs-base); font-weight: 800; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card:hover .card-title { color: var(--accent); }
.card-seller { font-size: var(--fs-xs); color: var(--muted); display: flex; align-items: center; gap: 6px; }
.mini-avatar { width: 18px; height: 18px; border-radius: 50%; background: var(--surface-2); color: var(--ink-soft); font-size: 10px; font-weight: 700; display: inline-grid; place-items: center; flex: none; }
.card-foot { margin-top: auto; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding-top: 10px; }
.meta { font-size: var(--fs-xs); color: var(--muted); font-variant-numeric: tabular-nums; }
.price { font-weight: 900; font-size: 1.25rem; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.price small { font-size: var(--fs-xs); font-weight: 700; color: var(--muted); margin-left: 2px; }

/* Recruit（黒い帯） */
.recruit-band { background: var(--ink); color: var(--on-ink); margin-top: 32px; }
.recruit { padding-block: 72px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 56px; align-items: start; }
.recruit .eyebrow { color: var(--accent-on-ink); }
.recruit h2 { font-size: var(--fs-2xl); font-weight: 900; margin-bottom: 16px; letter-spacing: -0.01em; line-height: 1.35; }
.recruit p { color: var(--on-ink-muted); }
.recruit .actions { margin-top: 32px; display: flex; gap: 8px; flex-wrap: wrap; }
.fee-row { margin-top: 32px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: rgba(247, 247, 245, .14); border-radius: var(--radius); overflow: hidden; }
.fee-row div { display: flex; flex-direction: column; gap: 2px; padding: 16px; background: var(--ink); font-size: var(--fs-xs); color: var(--on-ink-muted); }
.fee-row b { font-size: 1.75rem; font-weight: 900; font-variant-numeric: tabular-nums; color: var(--on-ink); line-height: 1.3; letter-spacing: -0.01em; }
.fee-row .hl b { color: var(--accent-on-ink); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; counter-reset: step; }
.steps li { display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 16px; padding: 20px; border-radius: var(--radius); background: var(--ink-soft); counter-increment: step; }
.steps li::before {
  content: counter(step); width: 40px; height: 40px; border-radius: 10px; background: var(--accent);
  color: #FFFFFF; font-weight: 900; display: grid; place-items: center; font-size: var(--fs-md);
}
.steps strong { display: block; color: var(--on-ink); font-size: var(--fs-md); margin-bottom: 2px; }
.steps span { color: var(--on-ink-muted); font-size: var(--fs-sm); }
@media (max-width: 859px) { .recruit { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-block: 56px; } }
@media (max-width: 479px) { .fee-row div { padding: 12px; } .fee-row b { font-size: 1.375rem; } .steps li { padding: 16px; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; } .steps li::before { width: 36px; height: 36px; } }

/* Page title band */
.page-head { padding-block: 36px 8px; }
.page-head h1 { font-size: var(--fs-xl); font-weight: 900; letter-spacing: -0.01em; }
.page-head p { color: var(--muted); margin-top: 6px; }
.crumbs { font-size: var(--fs-xs); color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.crumbs a { color: var(--muted); }
.crumbs span[aria-hidden] { color: var(--subtle); }

/* Listing */
.listing { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; padding-block: 24px 64px; align-items: start; }
.filters { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 16px 16px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); }
.filters summary { list-style: none; cursor: pointer; font-weight: 700; padding: 12px 0; display: flex; justify-content: space-between; align-items: center; }
.filters summary::-webkit-details-marker { display: none; }
.filters summary .count { font-weight: 400; font-size: var(--fs-xs); color: var(--muted); }
.filter-group { border: 0; margin: 0; padding: 12px 0; border-top: 1px solid var(--line); min-width: 0; }
.filter-group legend { font-size: var(--fs-sm); font-weight: 700; padding: 0; margin-bottom: 6px; }
.check { display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); padding: 3px 0; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--accent); margin: 0; }
.check .n { margin-left: auto; color: var(--subtle); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.filter-label { display: block; font-size: var(--fs-sm); font-weight: 700; margin-bottom: 6px; }
.filter-reset { margin-top: 8px; }
.toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .result { font-size: var(--fs-sm); color: var(--muted); }
.toolbar .result b { color: var(--fg); font-variant-numeric: tabular-nums; }
.select-wrap { display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); }
.select-wrap select { font: inherit; font-size: var(--fs-sm); padding: 6px 28px 6px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); color: var(--fg); }
.active-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.active-filters .chip::after { content: "×"; margin-left: 6px; color: var(--subtle); }
.empty { background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: 48px 24px; text-align: center; color: var(--muted); }
.empty .btn { margin-top: 16px; }
@media (max-width: 859px) {
  .listing { grid-template-columns: minmax(0, 1fr); gap: 16px; padding-top: 16px; }
  .filters { position: static; }
}

/* Detail */
.detail-head { padding-block: 28px 20px; }
.detail-head h1 { font-size: var(--fs-xl); margin-top: 10px; }
.detail-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.detail-meta { margin-top: 10px; display: flex; gap: 16px; flex-wrap: wrap; font-size: var(--fs-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 32px; align-items: start; padding-bottom: 64px; }
.detail-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; min-width: 0; }
.panel h2 { font-size: var(--fs-md); margin-bottom: 12px; }
.panel p + p { margin-top: 0.8em; }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.check-list li { position: relative; padding-left: 22px; }
.check-list li::before { content: ""; position: absolute; left: 2px; top: 0.55em; width: 10px; height: 6px; border-left: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(-45deg); }
.sample {
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 16px; font-size: var(--fs-sm); line-height: 1.85; white-space: pre-wrap; overflow-wrap: anywhere; margin: 0;
}
.sample-label { font-size: var(--fs-xs); color: var(--muted); margin-bottom: 6px; display: block; }
.locked { position: relative; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.locked-open { padding: 16px 16px 0; font-family: var(--mono); font-size: var(--fs-sm); white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.85; background: var(--bg); margin: 0; }
.locked-blur { padding: 0 16px 16px; font-family: var(--mono); font-size: var(--fs-sm); white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.85; background: var(--bg); filter: blur(5px); user-select: none; -webkit-user-select: none; pointer-events: none; margin: 0; }
.locked-cover {
  position: absolute; inset: auto 0 0 0; top: 4.5em; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  background: rgba(247, 247, 245, 0.55); text-align: center; padding: 16px;
}
.locked-cover p { font-weight: 700; }
.locked-cover .lock { width: 18px; height: 14px; border: 2px solid var(--fg); border-radius: 3px; position: relative; margin-top: 8px; }
.locked-cover .lock::before { content: ""; position: absolute; left: 2px; top: -10px; width: 10px; height: 10px; border: 2px solid var(--fg); border-bottom: 0; border-radius: 6px 6px 0 0; }
.spec { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 16px; margin: 0; font-size: var(--fs-sm); }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; }

.buy-box { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); display: flex; flex-direction: column; gap: 16px; }
.buy-box .price-big { font-size: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.buy-box .price-big small { font-size: var(--fs-sm); font-weight: 400; color: var(--muted); margin-left: 4px; }
.buy-note { font-size: var(--fs-xs); color: var(--muted); display: grid; gap: 4px; padding: 0; margin: 12px 0 0; list-style: none; }
.seller-mini { display: flex; gap: 12px; align-items: center; color: var(--fg); }
.seller-mini:hover { text-decoration: none; }
.seller-mini:hover strong { color: var(--accent); }
.seller-mini strong { display: block; font-size: var(--fs-base); }
.seller-mini span { font-size: var(--fs-xs); color: var(--muted); }
.seller-bio { font-size: var(--fs-sm); color: var(--muted); margin-top: 12px; }
.avatar {
  flex: none; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-weak); color: var(--accent); font-weight: 700; font-size: var(--fs-md);
}
.avatar-lg { width: 88px; height: 88px; font-size: 2rem; }
@media (max-width: 859px) {
  .detail-grid { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .buy-box { position: static; order: -1; }
}
@media (max-width: 479px) { .panel { padding: 18px 16px; } }

/* Seller page */
.profile { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 24px; align-items: start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; margin-top: 8px; }
.profile h1 { font-size: var(--fs-xl); }
.profile .handle { color: var(--muted); font-size: var(--fs-sm); }
.profile .bio { margin-top: 12px; max-width: 44em; }
.profile-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.stats { display: flex; gap: 32px; flex-wrap: wrap; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.stats div { display: flex; flex-direction: column; }
.stats b { font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }
.stats span { font-size: var(--fs-xs); color: var(--muted); }
@media (max-width: 599px) { .profile { grid-template-columns: minmax(0, 1fr); padding: 20px 16px; gap: 16px; } .avatar-lg { width: 64px; height: 64px; font-size: 1.5rem; } }

/* Legal */
.legal { max-width: 760px; padding-bottom: 64px; }
.legal .panel { padding: 32px; }
.legal h2 { font-size: var(--fs-md); margin: 28px 0 8px; }
.legal h2:first-child { margin-top: 0; }
.legal p, .legal li { color: var(--fg); }
.legal ol { padding-left: 1.4em; margin: 0; display: grid; gap: 4px; }
.legal .updated { font-size: var(--fs-sm); color: var(--muted); margin-top: 28px; }
.legal-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.legal-table th, .legal-table td { text-align: left; vertical-align: top; padding: 12px 8px; border-top: 1px solid var(--line); }
.legal-table tr:first-child th, .legal-table tr:first-child td { border-top: 0; }
.legal-table th { width: 32%; font-weight: 500; color: var(--muted); }
.ph { background: var(--accent-weak); color: var(--accent); padding: 0 4px; border-radius: 3px; }
@media (max-width: 599px) {
  .legal .panel { padding: 20px 16px; }
  .legal-table th, .legal-table td { display: block; width: 100%; padding: 2px 0; border: 0; }
  .legal-table th { padding-top: 12px; border-top: 1px solid var(--line); }
  .legal-table tr:first-child th { border-top: 0; }
}

/* Footer */
.site-footer { background: var(--surface); border-top: 1px solid var(--line); margin-top: 24px; }
.footer-inner { display: flex; justify-content: space-between; gap: 32px; padding-block: 40px 24px; flex-wrap: wrap; }
.footer-brand { max-width: 320px; }
.footer-brand p { color: var(--muted); font-size: var(--fs-sm); margin-top: 8px; }
.footer-links { display: flex; gap: 48px; flex-wrap: wrap; }
.footer-links div { display: flex; flex-direction: column; gap: 6px; }
.footer-links h2 { font-size: var(--fs-xs); color: var(--muted); font-weight: 500; letter-spacing: 0.06em; margin-bottom: 4px; }
.footer-links a { color: var(--fg); font-size: var(--fs-sm); }
.footer-copy { padding-block: 16px 24px; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--subtle); }

/* Toast */
.toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 50;
  background: var(--fg); color: var(--surface); font-size: var(--fs-sm);
  padding: 10px 18px; border-radius: var(--radius-sm); max-width: calc(100% - 32px);
}

/* ===== 会員・出品・管理の画面 ===== */
.min0 { min-width: 0; }
.mt8 { margin-top: 8px; } .mt16 { margin-top: 16px; } .mt20 { margin-top: 20px; } .mb16 { margin-bottom: 16px; }
.pt0 { padding-top: 0; } .pt40 { padding-top: 40px; } .pb64 { padding-bottom: 64px; }
.narrow { max-width: 520px; }
.narrow-wide { max-width: 860px; }
.loading { color: var(--muted); padding-block: 48px; }
.small-note { font-size: var(--fs-sm); color: var(--muted); }
.small-list { margin: 12px 0; padding-left: 1.2em; font-size: var(--fs-sm); color: var(--muted); display: grid; gap: 2px; }
.pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.nav-user { font-size: var(--fs-sm); color: var(--muted); padding: 0 6px; max-width: 12em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 959px) { .nav-user { padding: 8px; max-width: none; } }

.test-banner { background: var(--wait-weak); color: var(--wait); font-size: var(--fs-xs); text-align: center; padding: 6px 16px; border-bottom: 1px solid var(--line); }

/* ボタンの追加 */
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.btn-sm { padding: 4px 10px; font-size: var(--fs-xs); }
.btn-danger { background: var(--danger); color: #FFFFFF; }
.btn-danger:hover { filter: brightness(.92); }
.btn-danger-ghost { background: transparent; color: var(--danger); border-color: var(--line); }
.btn-danger-ghost:hover { border-color: var(--danger); }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.btn-row-end { justify-content: flex-end; }

/* お知らせ */
.notice { background: var(--accent-weak); border: 1px solid transparent; border-radius: var(--radius); padding: 14px 18px; font-size: var(--fs-sm); margin-top: 16px; }
.notice strong { display: block; font-size: var(--fs-base); }
.notice a { font-weight: 500; }
.notice-action { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; background: var(--wait-weak); }
.notice-action p { color: var(--fg); }
.status-big { font-size: var(--fs-lg); font-weight: 700; margin: 4px 0 8px; }
.status-big.ok { color: var(--ok); }
.status-big.ng { color: var(--danger); }

/* 状態の表示 */
.pill { display: inline-block; font-size: var(--fs-xs); font-weight: 500; line-height: 1.6; padding: 1px 8px; border-radius: 999px; white-space: nowrap; vertical-align: middle; }
.pill-ok { background: var(--ok-weak); color: var(--ok); }
.pill-wait { background: var(--wait-weak); color: var(--wait); }
.pill-ng { background: var(--danger-weak); color: var(--danger); }
.reason { margin-top: 10px; padding: 10px 14px; border-radius: var(--radius-sm); font-size: var(--fs-sm); }
.reason strong { display: block; font-size: var(--fs-xs); }
.reason p { white-space: pre-wrap; overflow-wrap: anywhere; }
.reason-ng { background: var(--danger-weak); }
.reason-ng strong { color: var(--danger); }

/* フォーム */
.form { display: flex; flex-direction: column; gap: 16px; }
.form-section { display: flex; flex-direction: column; gap: 16px; }
.form-section h2 { margin-bottom: 0; }
.field { display: flex; flex-direction: column; gap: 6px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field > label, .field > legend { font-size: var(--fs-sm); font-weight: 700; padding: 0; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 559px) { .field-row { grid-template-columns: minmax(0, 1fr); } }
.opt { font-weight: 400; color: var(--muted); font-size: var(--fs-xs); margin-left: 8px; }
.hint { font-size: var(--fs-xs); color: var(--muted); }
.hint b { color: var(--fg); }
.input {
  width: 100%; font: inherit; font-size: var(--fs-base); color: var(--fg);
  padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface);
}
.filters .input { font-size: var(--fs-sm); padding: 8px 10px; background: var(--bg); }
textarea.input { resize: vertical; line-height: 1.7; }
.input.mono { font-family: var(--mono); font-size: var(--fs-sm); }
.input:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
input[type=file].input { padding: 8px; background: var(--bg); }
.price-input { display: flex; align-items: center; gap: 8px; max-width: 220px; }
.radio-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 559px) { .radio-row { grid-template-columns: minmax(0, 1fr); } }
.radio { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; font-size: var(--fs-sm); color: var(--muted); }
.radio b { display: block; color: var(--fg); font-size: var(--fs-base); }
.radio input { margin-top: 5px; accent-color: var(--accent); }
.radio:has(input:checked) { border-color: var(--accent); background: var(--accent-weak); }
.current-file { font-size: var(--fs-sm); display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: center; padding: 8px 0; }
.form-error { background: var(--danger-weak); color: var(--danger); padding: 10px 14px; border-radius: var(--radius-sm); font-size: var(--fs-sm); white-space: pre-line; }
.form-switch { text-align: center; font-size: var(--fs-sm); }
.form-submit { display: flex; justify-content: flex-end; gap: 8px; padding-bottom: 64px; flex-wrap: wrap; }
.copy-row { display: flex; gap: 8px; margin-top: 16px; }
.copy-row .input { font-family: var(--mono); font-size: var(--fs-sm); background: var(--bg); }
@media (max-width: 479px) { .copy-row { flex-direction: column; } }

/* 商品詳細の購入まわり */
.buy-actions { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.refund-note { font-size: var(--fs-sm); font-weight: 500; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; }
.locked-cover .refund-note { font-size: var(--fs-xs); padding: 4px 8px; }
.buy-block { font-size: var(--fs-sm); color: var(--muted); }
.panel-label { font-size: var(--fs-sm) !important; color: var(--muted); font-weight: 500 !important; margin-bottom: 12px; }
.mt16.btn-block, .btn-block.mt16 { margin-top: 16px; }

/* ダッシュボード */
.dash-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.stats-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.stats-row-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 899px) { .stats-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stats-row-2 .stat { background: var(--bg); }
.stat-label { font-size: var(--fs-xs); color: var(--muted); }
.stat-value { font-size: var(--fs-lg); font-variant-numeric: tabular-nums; line-height: 1.4; }
.stat-value small { font-size: var(--fs-xs); font-weight: 400; color: var(--muted); margin-left: 2px; }
.stat-note { font-size: var(--fs-xs); color: var(--subtle); line-height: 1.5; }
.tabs { display: flex; gap: 4px; margin-top: 28px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs a { padding: 10px 14px; color: var(--muted); font-size: var(--fs-sm); white-space: nowrap; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs a:hover { color: var(--fg); text-decoration: none; }
.tabs a[aria-current="page"] { color: var(--fg); font-weight: 700; border-bottom-color: var(--accent); }
.tab-body { padding-block: 20px 64px; }
.list { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.list-row { display: flex; gap: 16px; padding: 16px 18px; border-top: 1px solid var(--line); align-items: flex-start; }
.list-row:first-child { border-top: 0; }
.list-main { flex: 1; min-width: 0; }
.list-title { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-weight: 700; }
.list-title a { color: var(--fg); }
.list-actions { flex: none; display: flex; gap: 8px; }
@media (max-width: 599px) { .list-row { flex-direction: column; } }
.checklist { list-style: none; padding: 0; margin: 16px 0; display: grid; gap: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.checklist li { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.checklist li:first-child { border-top: 0; }
.checklist .dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line); flex: none; }
.checklist li.done .dot { border-color: var(--ok); background: var(--ok); }
.checklist .state { margin-left: auto; font-size: var(--fs-xs); color: var(--muted); }
.checklist li.done .state { color: var(--ok); }

/* 表 */
.table-scroll { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.legal .table-scroll { border: 0; }
.table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.table th, .table td { text-align: left; padding: 10px 12px; border-top: 1px solid var(--line); vertical-align: top; }
.table thead th { border-top: 0; font-size: var(--fs-xs); color: var(--muted); font-weight: 500; white-space: nowrap; background: var(--bg); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.ids { font-family: var(--mono); font-size: var(--fs-xs); white-space: nowrap; }
.ids a { margin-right: 8px; font-family: var(--font); }

/* 購入済み */
.purchase-list { display: flex; flex-direction: column; gap: 12px; padding-block: 16px 64px; }
.purchase-head { display: flex; gap: 16px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; }
.purchase-head h2 { font-size: var(--fs-md); margin: 6px 0 2px; }
.purchase-head h2 a { color: var(--fg); }
.purchase-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.purchase-body { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.body-tools { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.body-text { width: 100%; min-height: 200px; font-family: var(--mono); font-size: var(--fs-sm); line-height: 1.85; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg); color: var(--fg); resize: vertical; }
.review-actions p { margin-bottom: 12px; }

/* ダイアログ */
.dialog { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; width: min(480px, calc(100% - 32px)); background: var(--surface); color: var(--fg); }
.dialog::backdrop { background: rgba(22, 22, 26, .4); }
.dialog h2 { font-size: var(--fs-md); }
.ask-text { font-size: var(--fs-sm); color: var(--muted); }
.ask-text:empty { display: none; }

/* ===== 評価・お気に入り・閲覧数 ===== */
.ic { width: 15px; height: 15px; flex: none; vertical-align: -2px; }
.stars { position: relative; display: inline-block; line-height: 0; white-space: nowrap; }
.stars svg { width: 13px; height: 13px; margin-right: 1px; }
.stars-bg svg { fill: var(--line-strong); }
.stars-fg { position: absolute; left: 0; top: 0; overflow: hidden; }
.stars-fg svg { fill: var(--star); }
.stars-lg svg { width: 20px; height: 20px; }
.rating { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-xs); color: var(--muted); }
.rating b { color: var(--fg); font-size: var(--fs-sm); font-weight: 800; font-variant-numeric: tabular-nums; }
.rating-count { margin-left: -4px; font-variant-numeric: tabular-nums; }
.rating-none { color: var(--subtle); }
.card-rating { min-height: 20px; }
.card-stats { display: inline-flex; gap: 12px; font-size: var(--fs-xs); color: var(--muted); font-variant-numeric: tabular-nums; }
.card-stats span { display: inline-flex; align-items: center; gap: 4px; }

/* トップ：AIから探す */
.ai-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.ai-row-label { font-size: var(--fs-sm); font-weight: 800; margin-right: 8px; }
.ai-chip { display: inline-flex; align-items: center; gap: 8px; font: inherit; font-size: var(--fs-sm); font-weight: 700; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--fg); cursor: pointer; transition: border-color .15s, background-color .15s; }
.ai-chip span { font-size: var(--fs-xs); font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; }
.ai-chip:hover { border-color: var(--ink); background: var(--surface-2); }

/* トップ：高評価＋ランキング */
.split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.product-grid.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 899px) { .split { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 539px) { .product-grid.grid-2 { grid-template-columns: minmax(0, 1fr); } }
.leader-list { list-style: none; margin: 0; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.leader-list a { display: grid; grid-template-columns: 28px 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px; border-radius: var(--radius-sm); color: var(--fg); }
.leader-list a:hover { background: var(--surface-2); text-decoration: none; }
.leader-list li + li { border-top: 1px solid var(--line); }
.leader-rank { font-weight: 900; font-size: var(--fs-md); text-align: center; color: var(--subtle); font-variant-numeric: tabular-nums; }
.leader-list li:nth-child(-n+3) .leader-rank { color: var(--accent); }
.leader-list .avatar { width: 40px; height: 40px; font-size: var(--fs-base); }
.leader-main { display: flex; flex-direction: column; min-width: 0; }
.leader-main strong { font-size: var(--fs-base); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.leader-sub { font-size: var(--fs-xs); color: var(--muted); display: inline-flex; align-items: center; gap: 4px; }
.leader-num { font-size: var(--fs-xs); color: var(--muted); text-align: right; white-space: nowrap; }
.leader-num b { display: block; font-size: var(--fs-md); color: var(--fg); font-weight: 900; font-variant-numeric: tabular-nums; }

/* 商品ページ：数字とお気に入り */
.detail-stats { margin-top: 12px; display: flex; gap: 8px 18px; flex-wrap: wrap; align-items: center; font-size: var(--fs-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.detail-stats > span { display: inline-flex; align-items: center; gap: 5px; }
.detail-rating { color: inherit; }
.detail-rating:hover { text-decoration: none; }
.detail-rating .stars svg { width: 15px; height: 15px; }
.fav-btn { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: var(--fs-sm); font-weight: 700; padding: 7px 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--fg); cursor: pointer; }
.fav-btn:hover { border-color: var(--danger); color: var(--danger); }
.fav-btn.is-on { border-color: var(--danger); color: var(--danger); background: var(--danger-weak); }
@media (max-width: 599px) { .fav-btn { margin-left: 0; } }
.seller-figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; margin-top: 14px; }
.seller-figs div { background: var(--surface); padding: 8px 6px; text-align: center; display: flex; flex-direction: column; }
.seller-figs b { font-size: var(--fs-md); font-weight: 900; font-variant-numeric: tabular-nums; }
.seller-figs span { font-size: 11px; color: var(--muted); }

/* レビュー */
.review-summary { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 28px; align-items: center; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.review-score { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.review-score b { font-size: 2.5rem; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.review-score > span:last-child { font-size: var(--fs-xs); color: var(--muted); }
.review-dist { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: var(--fs-xs); color: var(--muted); }
.review-dist li { display: grid; grid-template-columns: 28px minmax(0, 1fr) 24px; gap: 8px; align-items: center; }
.review-dist .bar { height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.review-dist .bar i { display: block; height: 100%; background: var(--star); border-radius: 4px; }
.review-dist .n { text-align: right; font-variant-numeric: tabular-nums; }
.review-list { list-style: none; margin: 0; padding: 0; display: grid; }
.review-list > li { padding: 16px 0; border-top: 1px solid var(--line); display: grid; gap: 6px; }
.review-list > li:first-child { border-top: 0; }
.review-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: var(--fs-sm); }
.review-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding-bottom: 48px; }
.review-cards > li.panel { padding: 18px; border-top: 1px solid var(--line); }
.review-cards > li.panel:first-child { border-top: 1px solid var(--line); }
@media (max-width: 899px) { .review-cards { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 479px) { .review-summary { grid-template-columns: minmax(0, 1fr); gap: 16px; } }

/* 購入済み：レビュー投稿 */
.review-box { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.review-mine { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: var(--fs-sm); }
.review-mine-text { color: var(--muted); max-width: 40em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.review-form { width: 100%; display: grid; gap: 10px; }
.star-input { border: 0; padding: 0; margin: 0; display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; }
.star-row { display: flex; align-items: center; gap: 12px; }
.star-row-label { font-size: var(--fs-sm); font-weight: 700; }
.star-input label { cursor: pointer; position: relative; }
.star-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star-input label > span[aria-hidden] { display: block; width: 28px; height: 28px; background: var(--line-strong);
  clip-path: polygon(50% 4%, 63% 35%, 96% 38%, 71% 59%, 79% 92%, 50% 75%, 21% 92%, 29% 59%, 4% 38%, 37% 35%); }
.star-input label:hover > span[aria-hidden], .star-input label:hover ~ label > span[aria-hidden],
.star-input input:checked + span, .star-input label:has(input:checked) ~ label > span[aria-hidden] { background: var(--star); }
.star-input input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ===== 無料・セット・制作依頼 ===== */
.badge-free, .detail-tags .badge-free { background: var(--ok); color: #FFFFFF; }
.badge-bundle, .detail-tags .badge-bundle, .purchase .badge-bundle { background: var(--accent); color: #FFFFFF; }
.badge-off, .detail-tags .badge-off, .panel .badge-off { background: var(--danger-weak); color: var(--danger); }
.price-free { color: var(--ok); }
.price-was { font-size: var(--fs-xs); font-weight: 500; color: var(--subtle); margin-right: 6px; }
.price-was-big { font-size: var(--fs-sm); color: var(--muted); display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.text-ng { color: var(--danger); }

/* セットのサムネイル：紙を重ねる */
.thumb-bundle .sheet { box-shadow: 8px -6px 0 -1px rgba(255, 255, 255, .7), 16px -12px 0 -2px rgba(255, 255, 255, .45), 0 10px 24px -6px rgba(22, 22, 26, .22); }

.bundle-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.bundle-list li + li { border-top: 1px solid var(--line); }
.bundle-list a { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; color: var(--fg); }
.bundle-list a:hover { background: var(--bg); text-decoration: none; }
.bundle-list .cat-mark { width: 40px; height: 40px; font-size: var(--fs-sm); }
.bundle-list strong { display: block; font-size: var(--fs-base); }
.bundle-price { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bundle-total { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: flex-end; gap: 6px 14px; margin-top: 12px; font-size: var(--fs-sm); color: var(--muted); font-variant-numeric: tabular-nums; }
.bundle-total b { font-size: var(--fs-lg); color: var(--fg); font-weight: 900; }
.in-bundles { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.in-bundles a { display: flex; flex-direction: column; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--fg); }
.in-bundles a:hover { border-color: var(--accent); text-decoration: none; }
.in-bundles span { font-size: var(--fs-xs); color: var(--muted); }

/* セットの作成：商品を選ぶ */
.pick-list { display: grid; gap: 8px; }
.pick { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; }
.pick input { width: 18px; height: 18px; accent-color: var(--accent); }
.pick strong { display: block; font-size: var(--fs-base); }
.pick b { font-variant-numeric: tabular-nums; }
.pick:has(input:checked) { border-color: var(--accent); background: var(--accent-weak); }

/* 購入済み：セットの中の商品 */
.bundle-items { margin-top: 14px; display: grid; gap: 10px; }
.purchase-sub { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px; background: var(--bg); }
.purchase-sub h3 { font-size: var(--fs-base); margin-top: 4px; }
.purchase-sub h3 a { color: var(--fg); }
.purchase-sub .review-box { margin-top: 10px; padding-top: 10px; }

/* 出品者ページ：依頼の案内 */
.request-cta { margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; padding: 24px 28px; border-radius: var(--radius); background: var(--ink); color: var(--on-ink); }
.request-cta .eyebrow { color: var(--accent-on-ink); }
.request-cta h2 { font-size: var(--fs-lg); margin-bottom: 6px; }
.request-cta p { color: var(--on-ink-muted); font-size: var(--fs-sm); }
.request-cta .request-note { margin-top: 10px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--ink-soft); color: var(--on-ink); white-space: pre-wrap; }
.request-cta-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.request-cta-side b { font-size: 1.5rem; font-weight: 900; font-variant-numeric: tabular-nums; margin-bottom: 8px; }
.request-cta-side .meta { color: var(--on-ink-muted); }
@media (max-width: 699px) { .request-cta { grid-template-columns: minmax(0, 1fr); padding: 20px; } .request-cta-side { align-items: flex-start; } }

/* 依頼の進み具合 */
.req-steps { list-style: none; margin: 16px 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; counter-reset: rs; }
.req-steps li { counter-increment: rs; position: relative; padding-top: 10px; border-top: 3px solid var(--line); font-size: var(--fs-xs); color: var(--subtle); }
.req-steps li span::before { content: counter(rs) " "; font-weight: 900; }
.req-steps li.done { border-color: var(--accent); color: var(--muted); }
.req-steps li.now { border-color: var(--accent); color: var(--fg); font-weight: 700; }
.req-action p + p { margin-top: 8px; }
.sub-head { font-size: var(--fs-md); margin: 28px 0 12px; }
.switch { font-size: var(--fs-base); font-weight: 700; }

/* メッセージ */
.messages { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.messages li { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--bg); max-width: 88%; }
.messages li.mine { margin-left: auto; background: var(--accent-weak); }
.msg-head { display: flex; gap: 8px; align-items: center; font-size: var(--fs-sm); margin-bottom: 2px; flex-wrap: wrap; }
.msg-form { display: grid; gap: 8px; }

/* ===== ログイン方法・メール確認・本人確認バッジ ===== */
.btn-google { background: var(--surface); color: var(--fg); border-color: var(--line-strong); gap: 10px; }
.btn-google:hover { border-color: var(--fg); }
.g-logo { width: 18px; height: 18px; }
.or { display: flex; align-items: center; gap: 12px; font-size: var(--fs-xs); color: var(--muted); }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.verify-banner { background: var(--wait-weak); border-bottom: 1px solid var(--line); font-size: var(--fs-sm); }
.verify-inner { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; padding-block: 10px; }
.verify-inner strong { color: var(--wait); }
.verified-badge { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-xs); font-weight: 700; color: var(--accent); vertical-align: middle; white-space: nowrap; }
.verified-badge svg { width: 16px; height: 16px; }
.name-badge { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.name-badge .verified-badge { font-size: var(--fs-sm); background: var(--accent-weak); padding: 2px 10px 2px 6px; border-radius: 999px; }
.seller-mini .verified-badge { margin: 2px 0; }
.spec-wide { grid-template-columns: 9em minmax(0, 1fr); row-gap: 12px; }
.global-nav > a.nav-user { color: var(--muted); }

/* ===== トップ：使えるAIアプリが左から右へ流れる帯 ===== */
.apps-band { background: var(--surface); border-bottom: 1px solid var(--line); padding-block: 28px 32px; overflow: hidden; }
.apps-head { display: flex; align-items: baseline; justify-content: space-between; gap: 6px 24px; flex-wrap: wrap; margin-bottom: 18px; }
.apps-head h2 { font-size: var(--fs-md); font-weight: 800; }
.apps-head p { font-size: var(--fs-sm); color: var(--muted); }
.marquee { overflow: hidden; width: 100%; }
.marquee-track { display: flex; width: max-content; animation: marquee-ltr 48s linear infinite; }
.marquee:hover .marquee-track, .marquee:focus-within .marquee-track { animation-play-state: paused; }
.marquee-group { display: flex; gap: 12px; padding: 0 6px; margin: 0; list-style: none; }
/* 左から右へ：中身を左に半分ずらした位置から、0まで動かす */
@keyframes marquee-ltr { from { transform: translateX(-50%); } to { transform: translateX(0); } }
.app { display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); white-space: nowrap; }
.app-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--app-bg); color: var(--app-fg); font-weight: 900; font-size: var(--fs-sm); letter-spacing: -0.02em; overflow: hidden; }
.app-icon img { width: 100%; height: 100%; object-fit: contain; }
.app-text { display: flex; flex-direction: column; line-height: 1.3; }
.app-text b { font-size: var(--fs-sm); font-weight: 800; }
.app-text small { font-size: 11px; color: var(--muted); }
.app-skill { font-size: 11px; font-weight: 700; color: var(--accent); background: var(--accent-weak); padding: 2px 8px; border-radius: 999px; }
@media (max-width: 599px) { .app-icon { width: 34px; height: 34px; } .marquee-track { animation-duration: 36s; } }
/* 動きを減らす設定の人には、流さずに並べて表示する */
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; width: auto; }
  .marquee-group { flex-wrap: wrap; padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
  .marquee-group[aria-hidden="true"] { display: none; }
}
.app-icon.has-logo { background: #FFFFFF; border: 1px solid var(--line); padding: 8px; }
.apps-note { margin-top: 14px; font-size: 11px; color: var(--subtle); }

/* ===== SNSでシェア ===== */
.head-actions { margin-left: auto; display: inline-flex; gap: 8px; flex-wrap: wrap; }
.head-actions .fav-btn { margin-left: 0; }
@media (max-width: 599px) { .head-actions { margin-left: 0; } }
.share-row { display: flex; align-items: center; gap: 6px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.profile .share-row { border-top: 0; padding-top: 0; margin-top: 12px; }
.share-label { font-size: var(--fs-xs); color: var(--muted); margin-right: 4px; }
.share-icon { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); cursor: pointer; padding: 0; color: var(--fg); }
.share-icon:hover { border-color: var(--fg); }
.share-icon svg { width: 17px; height: 17px; }
.share-dialog { width: min(440px, calc(100% - 32px)); }
.share-target { font-weight: 700; }
.share-notice { margin-top: 0; }
.share-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.share-btn { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 4px; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--fg); font-size: var(--fs-xs); font-weight: 700; }
.share-btn:hover { border-color: var(--fg); text-decoration: none; }
.share-btn svg { width: 26px; height: 26px; }
.owner-share p { font-size: var(--fs-sm); color: var(--muted); }

/* ===== 横にスクロールする列・タグ・フォロー ===== */
.row-section .section-head { align-items: flex-end; }
.row-title { color: var(--fg); display: inline-flex; align-items: center; gap: 6px; }
.row-title::after { content: ""; width: 9px; height: 9px; border-top: 2.5px solid currentColor; border-right: 2.5px solid currentColor; transform: rotate(45deg); }
.row-title:hover { color: var(--accent); text-decoration: none; }
.row-nav { display: flex; gap: 6px; }
.row-btn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--surface); font-size: 20px; line-height: 1; cursor: pointer; color: var(--fg); }
.row-btn:hover { border-color: var(--fg); }
@media (max-width: 599px) { .row-nav { display: none; } }
.row-scroller { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 20px) / 4); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 12px; scrollbar-width: thin; }
.row-scroller > .card { scroll-snap-align: start; }
@media (max-width: 1023px) { .row-scroller { grid-auto-columns: calc((100% - 2 * 16px) / 3); gap: 16px; } }
@media (max-width: 719px) { .row-scroller { grid-auto-columns: 72%; gap: 12px; } }
.card-seller { min-width: 0; }
.card-seller-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.card-ago { color: var(--subtle); white-space: nowrap; margin-left: auto; }

.tag-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.tag-chip { font: inherit; font-size: var(--fs-sm); font-weight: 700; padding: 4px 12px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--muted); cursor: pointer; }
.tag-chip:hover { border-color: var(--accent); color: var(--accent); }
.tag-rank { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 899px) { .tag-rank { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 479px) { .tag-rank { grid-template-columns: minmax(0, 1fr); } }
.tag-rank-item { width: 100%; display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); font: inherit; text-align: left; cursor: pointer; color: var(--fg); transition: border-color .15s, transform .15s; }
.tag-rank-item:hover { border-color: var(--accent); transform: translateY(-2px); }
.tag-rank-no { width: 28px; height: 28px; border-radius: 8px; background: var(--ink); color: var(--on-ink); display: grid; place-items: center; font-weight: 900; font-size: var(--fs-sm); }
.tag-rank li:nth-child(n+4) .tag-rank-no { background: var(--surface-2); color: var(--ink-soft); }
.tag-rank-item strong { display: block; font-size: var(--fs-base); font-weight: 800; }
.tag-rank-sub { display: block; font-size: var(--fs-xs); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tag-rank-count { font-size: var(--fs-xs); color: var(--subtle); white-space: nowrap; }

.follow-btn { min-width: 112px; }
.follow-box { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); padding: 20px 22px; display: grid; gap: 12px; }
.follow-box-lead { font-weight: 800; text-align: center; color: var(--ink-soft); }
.follow-box-body { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: var(--surface); border-radius: var(--radius-sm); padding: 14px 16px; }
.follow-box-body .seller-mini span span { display: block; }
.follow-box .small-note { text-align: center; }
.follow-line { display: flex; align-items: center; gap: 14px; margin-top: 10px; flex-wrap: wrap; font-size: var(--fs-sm); color: var(--muted); }
.follow-line b { color: var(--fg); font-size: var(--fs-md); }
.dash-followers { margin-top: 4px; font-size: var(--fs-sm); color: var(--muted); }
.dash-followers b { color: var(--fg); }

/* 出品者ページのカバー */
.seller-cover { background: var(--cat-bg, var(--surface-2)); height: 140px; border-bottom: 1px solid var(--line); overflow: hidden; }
.seller-cover .wrap { height: 100%; display: flex; align-items: flex-end; justify-content: flex-end; }
.cover-mark { font-size: clamp(2rem, 1rem + 4vw, 4.5rem); font-weight: 900; color: var(--cat-mark, var(--ink-soft)); opacity: .18; letter-spacing: -0.02em; white-space: nowrap; transform: translateY(18%); }
.profile-cover { margin-top: -64px; position: relative; }
.sort-chips { display: flex; gap: 6px; }
.chip.is-on { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }

/* スマホ：画面の下に固定する購入バー */
.buy-bar { display: none; }
@media (max-width: 859px) {
  .buy-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
    padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
    background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px -12px rgba(22, 22, 26, .25); }
  .buy-bar-price { font-size: 1.375rem; font-weight: 900; font-variant-numeric: tabular-nums; }
  .buy-bar-price small { font-size: var(--fs-xs); color: var(--muted); margin-left: 2px; }
  .buy-bar .btn { flex: 1; max-width: 240px; }
  body:has(.buy-bar) .site-footer { padding-bottom: 76px; }
}
@media (max-width: 859px) {
  .buy-bar { transition: transform .2s; }
  .buy-bar.is-hidden { transform: translateY(110%); }
}

/* ===== 転売対策（ライセンス表示・通報・類似チェック） ===== */
.license-note { font-size: var(--fs-xs); color: var(--muted); margin-top: 12px; line-height: 1.7; }
.report-link { display: block; margin: 12px 0 0 auto; font: inherit; font-size: var(--fs-xs); color: var(--subtle); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; }
.report-link:hover { color: var(--danger); }
.report-reasons { display: grid; gap: 4px; }
.sim-box { border-radius: var(--radius); padding: 14px 18px; font-size: var(--fs-sm); display: grid; gap: 4px; }
.sim-box strong { font-size: var(--fs-base); }
.sim-ok { background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.sim-ok strong { color: var(--fg); }
.sim-warn { background: var(--danger-weak); border: 1px solid transparent; }
.sim-warn strong { color: var(--danger); }
