/* UCP 採用トラッカー — 静的 PR サイトのスタイル。
   デザイン方針: 「データ観測所」らしい落ち着いた濃色 + 1 アクセント。素の CSS のみ。 */

:root {
  --bg: #0b0e14;
  --bg-alt: #11151f;
  --surface: #161b27;
  --surface-2: #1d2433;
  --border: #283044;
  --text: #e7ecf3;
  --text-dim: #9aa6b8;
  --accent: #4ade80;       /* UCP green */
  --accent-2: #38bdf8;     /* link blue */
  --shopify: #4ade80;
  --wix: #38bdf8;
  --bigcommerce: #a78bfa;
  --zid: #fbbf24;
  --other: #64748b;
  --radius: 14px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN",
    "Noto Sans JP", Meiryo, sans-serif;
}

* { box-sizing: border-box; }

/* hidden 属性は CSS の display 指定(.badge 等)に負けるため明示的に優先させる。 */
[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.9em;
  background: var(--surface-2);
  padding: 0.1em 0.4em;
  border-radius: 5px;
  color: var(--accent);
}

h1, h2, h3, h4 { line-height: 1.3; margin: 0 0 0.5em; font-weight: 700; }
.muted { color: var(--text-dim); }

/* --- ヘッダ --- */
.site-header {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 24px;
  background: rgba(11, 14, 20, 0.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--text); font-weight: 700; }
.brand-mark {
  background: var(--accent); color: #04240f;
  font-weight: 800; letter-spacing: 0.5px;
  padding: 2px 8px; border-radius: 7px; font-size: 0.85rem;
}
.brand-name { font-size: 0.98rem; }
.site-nav { display: flex; align-items: center; gap: 22px; }
.site-nav a { color: var(--text-dim); text-decoration: none; font-size: 0.92rem; transition: color 0.15s; }
.site-nav a:hover { color: var(--text); }
.nav-cta {
  border: 1px solid var(--border); border-radius: 9px;
  padding: 6px 14px; color: var(--text) !important;
}
.nav-cta:hover { border-color: var(--accent); }

/* --- 共通 --- */
#top { scroll-margin-top: 72px; }
.section { max-width: var(--maxw); margin: 0 auto; padding: 86px 24px; scroll-margin-top: 72px; }
.section-alt { background: var(--bg-alt); max-width: none; }
.section-alt > * { max-width: var(--maxw); margin-left: auto; margin-right: auto; }
.section-head { margin-bottom: 36px; }
.section-head h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
.section-sub { color: var(--text-dim); margin: 0; max-width: 60ch; }

.btn {
  display: inline-block; cursor: pointer;
  font: inherit; font-weight: 600; text-decoration: none;
  padding: 12px 22px; border-radius: 11px; border: 1px solid transparent;
  transition: transform 0.12s, background 0.15s, border-color 0.15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #04240f; }
.btn-primary:hover { background: #5eeb93; }
.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); }
.btn-lg { padding: 15px 32px; font-size: 1.05rem; }

/* --- ヒーロー --- */
.hero {
  max-width: var(--maxw); margin: 0 auto;
  padding: 96px 24px 72px; text-align: center;
}
.eyebrow {
  color: var(--accent); font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; font-size: 0.8rem; margin: 0 0 18px;
}
.hero h1 { font-size: clamp(2rem, 5.5vw, 3.4rem); letter-spacing: -0.01em; }
.lede { color: var(--text-dim); font-size: 1.1rem; max-width: 58ch; margin: 22px auto 32px; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-note { margin-top: 26px; font-size: 0.85rem; color: var(--text-dim); }

/* --- stat strip --- */
.stat-strip {
  display: flex; align-items: baseline; gap: 28px; flex-wrap: wrap;
  padding: 26px 28px; margin-bottom: 28px;
  background: linear-gradient(180deg, var(--surface), var(--bg-alt));
  border: 1px solid var(--border); border-radius: var(--radius);
}
.stat-big { display: flex; flex-direction: column; }
.stat-num { font-size: clamp(2.2rem, 6vw, 3.4rem); font-weight: 800; color: var(--accent); line-height: 1; font-variant-numeric: tabular-nums; }
.stat-label { color: var(--text-dim); font-size: 0.9rem; margin-top: 6px; }
.stat-grow { display: flex; flex-direction: column; padding-left: 28px; border-left: 1px solid var(--border); }
.stat-grow-num { font-size: clamp(1.5rem, 3.5vw, 2.1rem); font-weight: 800; color: var(--accent); line-height: 1; font-variant-numeric: tabular-nums; }
.stat-grow .stat-label { margin-top: 6px; }
.stat-meta { margin-left: auto; text-align: right; font-size: 0.88rem; color: var(--text-dim); }

/* 成長カード見出し行 + 増加ピル */
.card-head-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card-head-row h3 { margin: 0; }
.growth-pill {
  font-size: 0.85rem; font-weight: 700; color: var(--accent);
  background: rgba(74, 222, 128, 0.12); border: 1px solid rgba(74, 222, 128, 0.3);
  padding: 3px 11px; border-radius: 999px; white-space: nowrap;
}

/* --- カード --- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-bottom: 22px; }
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px 26px;
}
.card h3 { font-size: 1.1rem; }
.card-sub { color: var(--text-dim); font-size: 0.85rem; margin: 0 0 18px; }

/* --- 横棒グラフ --- */
.bars { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.bar-row { display: grid; grid-template-columns: 92px 1fr 72px; align-items: center; gap: 12px; }
.bar-name { font-size: 0.9rem; }
.bar-track { background: var(--surface-2); border-radius: 6px; height: 12px; overflow: hidden; }
.bar-fill { display: block; width: 0; height: 100%; border-radius: 6px; background: var(--accent); transition: width 0.7s ease; }
.bar-pct { text-align: right; font-variant-numeric: tabular-nums; font-size: 0.88rem; color: var(--text-dim); }

/* --- readiness funnel --- */
.funnel { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; counter-reset: stage; }
.funnel-row { display: grid; grid-template-columns: 128px 1fr 96px; align-items: center; gap: 12px; }
.funnel-name { font-size: 0.9rem; position: relative; padding-left: 22px; }
.funnel-name::before {
  counter-increment: stage; content: counter(stage);
  position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 16px; height: 16px; border-radius: 50%; font-size: 0.7rem; line-height: 16px;
  text-align: center; color: var(--bg); background: var(--text-dim); font-weight: 700;
}
.funnel-track { height: 14px; }
/* tier 色: full=全対応(緑) / partial=Shopify のみ(琥珀) / frontier=AP2(灰・破線) */
.funnel-full .bar-fill { background: var(--accent); }
.funnel-full .funnel-name::before { background: var(--accent); }
.funnel-partial .bar-fill { background: var(--zid); }
.funnel-partial .funnel-name::before { background: var(--zid); }
.funnel-frontier .funnel-track { background: transparent; border: 1px dashed var(--border); }
.funnel-frontier .bar-fill { background: none; }
.funnel-frontier .funnel-name { color: var(--text-dim); }
.funnel-frontier .funnel-name::before { background: var(--other); }
.funnel-frontier .funnel-pct { color: var(--other); font-size: 0.8rem; }

/* --- sparkline --- */
.spark { width: 100%; height: 120px; position: relative; }
.spark svg { width: 100%; height: 100%; overflow: visible; }
.spark .spark-hit { cursor: pointer; }

/* --- checker --- */
.checker { display: flex; gap: 12px; flex-wrap: wrap; max-width: 620px; }
.checker-input {
  flex: 1 1 320px; font: inherit; color: var(--text);
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 11px; padding: 13px 16px;
}
.checker-input:focus { outline: none; border-color: var(--accent); }
.checker-result {
  margin-top: 22px; padding: 22px 26px; max-width: 760px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
}
.checker-result a { color: var(--accent-2); }
.checker-result--error { border-color: rgba(248, 113, 113, 0.4); }

/* 結果: 1 行メッセージ (ローディング / エラー) */
.score-msg { margin: 0; color: var(--text-dim); }
.checker-result--error .score-msg { color: #fca5a5; }

/* 結果ヘッダ: ホスト名 + 総合スコア + バンド */
.score-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 16px;
}
.score-id { display: flex; flex-direction: column; gap: 4px; }
.score-host { font-weight: 700; font-size: 1.05rem; word-break: break-all; }
.score-cap { color: var(--text-dim); font-size: 0.8rem; letter-spacing: 0.04em; }
.score-figure { display: flex; align-items: baseline; gap: 8px; }
.score-num { font-size: clamp(2.4rem, 7vw, 3.2rem); font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.score-max { color: var(--text-dim); font-size: 1rem; font-weight: 600; }
.score-band {
  align-self: center; margin-left: 4px; font-size: 0.78rem; font-weight: 700;
  padding: 3px 10px; border: 1px solid currentColor; border-radius: 999px;
}

/* カテゴリ別スコア */
.score-section-h {
  font-size: 0.78rem; font-weight: 700; color: var(--text-dim);
  letter-spacing: 0.08em; text-transform: uppercase;
  margin: 22px 0 12px; padding-top: 16px; border-top: 1px solid var(--border);
}
.score-cats { display: grid; gap: 10px; }

/* 指摘リスト */
.find-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.find-head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.find-mark { font-weight: 800; line-height: 1; }
.find-mark.is-partial { color: var(--zid); }
.find-mark.is-fail { color: #f87171; }
.find-mark.is-unknown { color: var(--text-dim); }
.find-cat {
  font-size: 0.72rem; font-weight: 700; color: var(--text-dim);
  letter-spacing: 0.03em; padding: 1px 7px; border: 1px solid var(--border); border-radius: 999px;
}
.find-detail { flex: 1 1 240px; font-size: 0.92rem; }
.find-fix { margin: 6px 0 0 24px; color: var(--accent-2); font-size: 0.86rem; }

/* メタ注記 + CTA */
.score-notes {
  list-style: none; margin: 20px 0 0; padding: 14px 0 0; border-top: 1px solid var(--border);
  color: var(--text-dim); font-size: 0.8rem; display: grid; gap: 4px;
}
.score-cta { margin: 18px 0 0; color: var(--text-dim); font-size: 0.95rem; }

.badge {
  display: inline-block; font-size: 0.72rem; font-weight: 700;
  padding: 3px 9px; border-radius: 999px; letter-spacing: 0.03em;
}
.badge-soon { background: rgba(56, 189, 248, 0.16); color: var(--accent-2); }

/* フォーム (.checker, max-width 620px・中央寄せ) と左端を揃える。margin shorthand で
   .section-alt > * の auto 中央寄せを消さないよう、左右は auto を維持する。 */
.checker-error { color: #fca5a5; min-height: 1.2em; max-width: 620px; margin: 10px auto 0; font-size: 0.9rem; }

/* --- できることセクション(HB の提供価値) --- */
.cap-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cap {
  background: var(--surface); border: 1px solid var(--border);
  border-left: 3px solid var(--accent); border-radius: var(--radius); padding: 20px 22px;
}
.cap h3 { font-size: 1rem; margin-bottom: 6px; }
.cap p { color: var(--text-dim); font-size: 0.9rem; margin: 0; }
/* --- できること(2 メニュー) --- */
.offer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.offer {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 28px 30px;
}
.offer-num {
  display: inline-block; font-size: 0.82rem; font-weight: 800; letter-spacing: 0.1em;
  color: var(--accent); margin-bottom: 10px;
}
.offer h3 { font-size: 1.2rem; margin-bottom: 10px; }
.offer > p { color: var(--text-dim); font-size: 0.92rem; margin: 0 0 18px; }
.offer-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.offer-list li { position: relative; padding-left: 16px; font-size: 0.9rem; color: var(--text-dim); line-height: 1.65; }
.offer-list li::before {
  content: ""; position: absolute; left: 0; top: 0.6em;
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
}
.offer-list strong { color: var(--text); font-weight: 700; }

.why-close {
  margin-top: 28px; font-size: 1.05rem; line-height: 1.8;
  padding: 22px 24px; border-radius: var(--radius);
  background: rgba(74, 222, 128, 0.07); border: 1px solid rgba(74, 222, 128, 0.22);
}

/* --- agent stage --- */
.agent-stage { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 28px; align-items: center; margin-top: 44px; }
.agent-window { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.agent-bar { display: flex; gap: 7px; padding: 12px 14px; border-bottom: 1px solid var(--border); background: var(--surface-2); }
.agent-bar span { width: 11px; height: 11px; border-radius: 50%; background: var(--border); }
.agent-body { padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.agent-msg { padding: 10px 14px; border-radius: 12px; max-width: 80%; font-size: 0.92rem; }
.agent-user { align-self: flex-end; background: var(--surface-2); }
.agent-ai { align-self: flex-start; background: rgba(74, 222, 128, 0.12); border: 1px solid rgba(74, 222, 128, 0.25); }
.agent-tool { align-self: flex-start; font-family: ui-monospace, monospace; font-size: 0.8rem; color: var(--accent); }
.agent-copy p { color: var(--text-dim); margin: 12px 0 0; }

/* --- CTA --- */
.section-cta { text-align: center; }
.section-cta h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
.section-cta .section-sub { margin: 0 auto 28px; }

/* --- フッタ --- */
.site-footer { border-top: 1px solid var(--border); padding: 48px 24px; background: var(--bg-alt); }
.footer-cols { max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.footer-cols h4 { font-size: 0.95rem; }
.footer-cols p { font-size: 0.88rem; margin: 8px 0 0; }
.footer-fine { max-width: var(--maxw); margin: 28px auto 0; font-size: 0.8rem; }

/* --- レスポンシブ --- */
@media (max-width: 760px) {
  .site-nav { gap: 14px; }
  .site-nav a:not(.nav-cta) { display: none; }
  .grid-2, .agent-stage, .footer-cols, .cap-grid, .offer-grid { grid-template-columns: 1fr; }
  .stat-meta { margin-left: 0; text-align: left; }
  .stat-grow { padding-left: 0; border-left: none; }
  .section { padding: 60px 20px; }
}
