/* ===========================================================
   Software Kingdom — /tools/ ツール一覧
   四款工具页共用的设计令牌；本页在此基础上做「板块化」：
   深色 Hero 面板 → 纸色 → 白色带 → 纸色 → 荧光绿带 → 纸色
   不引入 converter / editor 样式，保持轻量。
   =========================================================== */

:root {
  --paper: #f4f1e8;
  --ink: #161714;
  --muted: #66685f;
  --line: #d7d2c5;
  --card: #fbfaf6;
  --acid: #d8ff47;
  --acid-soft: #e6ff88;
  --blue: #2e48ff;
  --dark: #1c1e1a;
  --radius: 24px;

  --font-sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP",
               "Yu Gothic", "YuGothic", Meiryo, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Yu Mincho", "Hiragino Mincho ProN", "Hiragino Mincho Pro",
                "Noto Serif JP", Georgia, serif;
  --fs-h1: clamp(30px, 4.6vw, 56px);
  --fs-h2: clamp(25px, 2.9vw, 38px);
  --fs-h3: clamp(17px, 1.35vw, 19px);
  --fs-lead: 16.5px;

  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; background: var(--paper); font-family: var(--font-sans); }
a { color: inherit; }
img, svg { max-width: 100%; }
.br-sm { display: none; }
.nb { white-space: nowrap; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ---------- 页头 / 页脚 ---------- */
.site-header, footer {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-header { height: 78px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-size: 15px; font-weight: 800; text-decoration: none; letter-spacing: -.02em; }
.brand-mark { width: 28px; height: 28px; display: block; flex: 0 0 auto; }
.site-header nav { display: flex; gap: 26px; }
.site-header nav a { font-size: 13px; text-decoration: none; color: #43453e; }
.site-header nav a:hover, .site-header nav a:focus-visible { color: var(--blue); }
.site-header nav a[aria-current="page"] { color: var(--ink); font-weight: 800; }

main { overflow: hidden; }

/* ---------- パンくず ---------- */
.breadcrumb { width: min(1180px, calc(100% - 40px)); margin: 20px auto 0; }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; padding: 0; list-style: none; font-size: 12px; color: var(--muted); }
.breadcrumb li { display: flex; align-items: center; gap: 8px; }
.breadcrumb li + li::before { content: "›"; color: #a9a89f; }
.breadcrumb a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.breadcrumb a:hover, .breadcrumb a:focus-visible { color: var(--ink); }
.breadcrumb [aria-current="page"] { color: var(--ink); }

/* ---------- 深色 Hero 面板 ---------- */
.hero {
  position: relative;
  width: min(1180px, calc(100% - 40px));
  margin: 18px auto 0;
  padding: 62px 56px 66px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 56px;
  border-radius: 36px;
  background:
    radial-gradient(820px 400px at 92% -14%, rgba(216, 255, 71, .16), transparent 64%),
    radial-gradient(680px 380px at 2% 112%, rgba(46, 72, 255, .22), transparent 62%),
    var(--dark);
  color: #f4f1e8;
  overflow: hidden;
}
.hero-copy-col { min-width: 0; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  margin: 0; padding: 7px 14px 7px 11px;
  border: 1px solid rgba(216, 255, 71, .38);
  border-radius: 100px;
  color: var(--acid);
  font-size: 11.5px; font-weight: 800; letter-spacing: .04em;
}
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--acid); box-shadow: 0 0 0 3px rgba(216, 255, 71, .18); }
.hero h1 {
  margin: 22px 0 20px;
  font-family: var(--font-serif);
  font-size: var(--fs-h1);
  line-height: 1.14;
  letter-spacing: -.02em;
  font-weight: 500;
  color: #f7f4ec;
  text-wrap: balance;
}
.hero h1 em { font-style: normal; color: var(--acid); }
/* 「｜」は 1 行表記のための区切り。改行前提のレイアウトでは不要なので視覚的に隠す */
.h1-pipe { display: none; }
.hero-copy { max-width: 620px; margin: 0; color: #a9aca2; font-size: var(--fs-lead); line-height: 1.85; }

/* Hero 右侧：4 个工具图标拼成的方块阵 */
.hero-visual { display: grid; grid-template-columns: repeat(2, 112px); gap: 14px; }
.hero-tile {
  display: grid; place-items: center;
  width: 112px; height: 112px;
  border: 1px solid rgba(247, 244, 236, .16);
  border-radius: 26px;
  background: rgba(247, 244, 236, .06);
  color: var(--acid);
}
.hero-tile svg { width: 44px; height: 44px; }
.hero-tile:nth-child(1) {
  border-radius: 34px 26px 26px 26px;
  background: var(--acid);
  border-color: var(--acid);
  color: var(--dark);
}
.hero-tile:nth-child(4) { border-radius: 26px 26px 34px 26px; }

/* ---------- 板块（band） ---------- */
.band { padding: 92px 0; }
.band-inner { width: min(1080px, calc(100% - 40px)); margin: 0 auto; }
.band--white { background: var(--card); border-top: 1px solid #e4dfd2; border-bottom: 1px solid #e4dfd2; }
.band--acid { background: var(--acid-soft); }
.band--acid .kicker { color: #4a5a1c; }

.section-head { max-width: 760px; }
.kicker {
  display: inline-flex; align-items: center; gap: 9px;
  margin: 0 0 14px;
  color: var(--blue);
  font-size: 11.5px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase;
}
.kicker span { display: block; width: 20px; height: 2px; border-radius: 2px; background: currentColor; }
.band h2 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: var(--fs-h2);
  line-height: 1.32;
  letter-spacing: -.01em;
  font-weight: 500;
  text-wrap: balance;
}
.section-lead { margin: 18px 0 0; color: var(--muted); font-size: var(--fs-lead); line-height: 1.85; }
.section-note { margin: 20px 2px 0; color: var(--muted); font-size: 12.5px; line-height: 1.75; }

/* ---------- ツールカード ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 40px; }
.tool-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 34px;
  border: 1px solid #e0dacc;
  border-radius: 26px;
  background: var(--card);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 2px 0 rgba(22, 23, 20, .02);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.tool-card:hover, .tool-card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--ink);
  box-shadow: 0 18px 40px rgba(22, 23, 20, .11);
}
.tool-card:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.band--white .tool-card { background: var(--paper); border-color: #d7d2c5; box-shadow: 0 6px 22px rgba(22, 23, 20, .05); }

.tool-icon {
  display: grid; place-items: center;
  width: 64px; height: 64px;
  border-radius: 19px;
  background: var(--ink);
  color: var(--acid);
  transition: background .18s ease;
}
.tool-icon svg { width: 30px; height: 30px; }
.tool-index {
  position: absolute; top: 30px; right: 32px;
  color: #726d5f;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 11px; font-weight: 700; letter-spacing: .12em;
}
.tool-card:hover .tool-icon { background: var(--blue); }
.tool-card h3 { margin: 24px 0 8px; font-family: var(--font-sans); font-size: clamp(20px, 1.9vw, 23px); line-height: 1.4; letter-spacing: -.02em; }
.tool-tagline { margin: 0; color: var(--ink); font-size: 14px; font-weight: 800; letter-spacing: -.01em; }
.tool-desc { margin: 12px 0 0; color: var(--muted); font-size: 13.5px; line-height: 1.85; }
.tool-features { margin: 18px 0 0; padding-top: 16px; border-top: 1px dashed #d9d3c4; color: var(--muted); font-size: 12.5px; line-height: 1.7; }
.tool-features b { color: var(--ink); font-weight: 800; }
.tool-cta { margin-top: auto; padding-top: 22px; color: var(--blue); font-size: 13.5px; font-weight: 800; }
.tool-cta span { display: inline-block; transition: transform .18s ease; }
.tool-card:hover .tool-cta span, .tool-card:focus-visible .tool-cta span { transform: translateX(4px); }

/* ---------- やりたいことから探す ---------- */
.panel {
  margin-top: 40px;
  padding: 10px 32px;
  border: 1px solid #e0dacc;
  border-radius: 26px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(22, 23, 20, .05);
}
.band--white .panel { background: var(--paper); box-shadow: none; border-color: #ddd7c9; }
.need-table { width: 100%; border-collapse: collapse; }
.need-table th { padding: 18px 4px 13px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .1em; text-align: left; width: 36%; }
.need-table td { padding: 19px 4px; border-bottom: 1px solid var(--line); font-size: 14px; line-height: 1.65; word-break: auto-phrase; }
.need-table tr:last-child td { border-bottom: 0; }
.need-table td:first-child { padding-right: 26px; }
.need-table a { color: var(--blue); font-weight: 800; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.need-table a:hover, .need-table a:focus-visible { color: #1931da; text-decoration-thickness: 2px; }

/* ---------- 特長（荧光绿带） ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 40px; }
.feature-card {
  padding: 30px 28px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(74, 90, 28, .12);
}
.feature-icon {
  display: grid; place-items: center;
  width: 46px; height: 46px;
  margin-bottom: 20px;
  border-radius: 15px;
  background: var(--acid-soft);
  color: var(--ink);
}
.feature-icon svg { width: 24px; height: 24px; }
.feature-card h3 { margin: 0 0 16px; font-family: var(--font-sans); font-size: var(--fs-h3); line-height: 1.5; letter-spacing: -.01em; }
.feature-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.85; }
.feature-card p + p { margin-top: 12px; font-size: 12px; color: #6b6d64; }
.band--acid .section-note { color: #55602c; }

/* ---------- 使い方 ---------- */
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; }
.step-card {
  position: relative;
  padding: 30px 28px;
  border: 1px solid #e4dfd2;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(22, 23, 20, .05);
}
.step-card > span {
  display: grid; place-items: center;
  width: 38px; height: 38px;
  border-radius: 12px;
  background: var(--acid);
  font-family: Georgia, serif;
  font-size: 17px; font-weight: 700;
}
.step-card h3 { margin: 22px 0 10px; font-family: var(--font-sans); font-size: var(--fs-h3); line-height: 1.5; letter-spacing: -.01em; }
.step-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.8; }

/* ---------- FAQ ---------- */
.faq-layout { display: grid; grid-template-columns: minmax(200px, 320px) minmax(0, 1fr); gap: 44px; align-items: start; }
.faq-layout .section-head { max-width: none; }
.faq-layout h2 { font-size: clamp(21px, 2vw, 26px); line-height: 1.45; }
.faq-panel { padding: 4px 32px; border: 1px solid #e0dacc; border-radius: 26px; background: #fff; box-shadow: 0 10px 30px rgba(22, 23, 20, .05); }
.band--white .faq-panel { background: var(--paper); box-shadow: none; border-color: #ddd7c9; }
.faq-list details { border-top: 1px solid var(--line); }
.faq-list details:first-child { border-top: 0; }
.faq-list details:last-child { border-bottom: 0; }
.faq-list summary {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 18px;
  padding: 22px 0;
  list-style: none;
  cursor: pointer;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary h3 { margin: 0; font-family: var(--font-sans); font-size: 15.5px; font-weight: 750; line-height: 1.65; letter-spacing: -.01em; }
.faq-toggle { flex: 0 0 auto; color: var(--blue); font-size: 21px; font-weight: 400; line-height: 1.1; transition: transform .2s ease; }
.faq-list details[open] .faq-toggle { transform: rotate(45deg); }
.faq-list summary:hover h3 { color: var(--blue); }
.faq-list summary:focus-visible { outline: 2px solid var(--blue); outline-offset: 4px; border-radius: 4px; }
.faq-answer { padding: 0 0 24px; }
.faq-answer p { max-width: 700px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.85; }
.faq-answer p + p { margin-top: 10px; font-size: 13px; }

/* ---------- 今後追加予定 ---------- */
.future-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 36px; }
.future-card {
  padding: 28px;
  border: 1.5px dashed #c3bdac;
  border-radius: 22px;
  background: rgba(255, 255, 255, .34);
}
.future-badge { display: inline-block; padding: 5px 11px; border-radius: 100px; background: #e7e3d8; color: #5a5c54; font-size: 10.5px; font-weight: 800; letter-spacing: .08em; }
.future-card h3 { margin: 16px 0 8px; font-family: var(--font-sans); font-size: var(--fs-h3); line-height: 1.5; letter-spacing: -.01em; }
.future-card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.8; }

/* ---------- フッター ---------- */
footer { min-height: 132px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
footer .brand { color: var(--ink); }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer-links a { color: var(--muted); font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.footer-links a:hover, .footer-links a:focus-visible { color: var(--ink); }

/* 日文折り返し：Chrome 系は語句単位、Safari は無視して通常改行 */
.hero h1, .band h2, .faq-list summary h3,
.hero-copy, .section-lead, .tool-desc, .tool-features, .feature-card p, .step-card p,
.faq-answer p, .future-card p, .section-note { word-break: auto-phrase; }

/* ---------- レスポンシブ ---------- */
/* 2 カラムを保つには見出し 2 行目（14 文字）が折り返さない幅が要る。
   950px を切ると「編集」だけが次行に落ちるので、そこで 1 カラムに切り替える。 */
@media (max-width: 1120px) {
  .hero { padding: 48px 40px 52px; gap: 36px; border-radius: 32px; }
  .hero-visual { grid-template-columns: repeat(2, 88px); gap: 12px; }
  .hero-tile { width: 88px; height: 88px; border-radius: 22px; }
  .hero-tile svg { width: 36px; height: 36px; }
}

@media (max-width: 1000px) {
  .tool-grid, .feature-grid, .steps-grid, .future-grid { grid-template-columns: 1fr; }
  .faq-layout { grid-template-columns: 1fr; gap: 34px; }
  .band { padding: 76px 0; }
}

@media (max-width: 950px) {
  .hero { grid-template-columns: 1fr; gap: 30px; }
  .hero-visual { grid-template-columns: repeat(4, 92px); gap: 12px; }
  .hero-tile { width: 92px; height: 92px; border-radius: 22px; }
  .hero-tile svg { width: 36px; height: 36px; }
}

@media (max-width: 760px) {
  .site-header { height: 66px; }
  .site-header nav { display: none; }
  .br-sm { display: inline; }
  .breadcrumb { margin-top: 14px; }
  .hero { margin-top: 14px; padding: 34px 22px 38px; border-radius: 24px; }
  .hero h1 { margin: 18px 0 16px; line-height: 1.2; }
  .hero-copy { font-size: 15px; line-height: 1.85; }
  .hero-visual { grid-template-columns: repeat(4, 1fr); gap: 9px; }
  .hero-tile { width: auto; height: auto; aspect-ratio: 1; border-radius: 16px; }
  .hero-tile svg { width: 24px; height: 24px; }
  .band { padding: 62px 0; }
  .tool-card { padding: 24px; border-radius: 22px; }
  .tool-icon { width: 56px; height: 56px; border-radius: 16px; }
  .tool-icon svg { width: 26px; height: 26px; }
  .tool-card h3 { margin-top: 20px; }
  .panel, .faq-panel { padding: 6px 20px; border-radius: 22px; }
  .need-table th { width: 40%; }
  .need-table td { padding: 16px 2px; font-size: 13px; }
  .need-table td:first-child { padding-right: 14px; }
  .feature-card, .step-card, .future-card { padding: 24px 22px; }
  .faq-list summary { padding: 18px 0; }
  footer { padding: 28px 0; gap: 18px; flex-wrap: wrap; }
  footer p { order: 3; width: 100%; margin: 0; }
  /* フッターのリンクを指で押せる高さ（44px 以上）に */
  .footer-links { gap: 0 18px; }
  .footer-links a { display: inline-block; padding: 13px 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
