/* ============================================================
   共通スタイル — てがるツール
   ============================================================ */

/* CSS変数 */
:root {
  --bg:          #f3f4f6;
  --surface:     #ffffff;
  --border:      #e5e7eb;
  --ink:         #111827;
  --sub:         #374151;
  --muted:       #9ca3af;
  --hover:       #f9fafb;
  --accent:      #0891b2;
  --accent-soft: #ecfeff;
  --accent-deep: #0e7490;
  --ok:          #16a34a;
  --ok-soft:     #dcfce7;
  --danger:      #dc2626;
  --danger-soft: #fee2e2;
  --radius:      12px;
  --sb-width:    260px;
}

/* ベースリセット */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow-x: clip; }
body {
  font-family: 'Noto Sans JP', 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* レイアウト */
.app {
  margin-left: var(--sb-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.content { padding: 40px 24px 80px; }
/* max-width は各ツールが個別に指定する */

@media (max-width: 900px) {
  .app     { margin-left: 0; padding-top: 52px; }
  .content { padding: 24px 16px 60px; }
}

/* ============================================================
   説明ゾーン（Page Header）
   ============================================================ */
.page-title-row { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.page-title     { font-size: 18px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
.page-cat {
  font-size: 12px;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 8px;
}
.page-desc { font-size: 13px; color: var(--muted); margin-top: 4px; }

/* ============================================================
   ツールゾーン骨格（新規ツール用）
   ============================================================ */
.tool-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.tool-card-body { padding: 24px; }

/* ============================================================
   アコーディオン
   .accordion-arrow（多数派）と .accordion-icon（一部ツール）両方対応
   ============================================================ */
.accordion {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.accordion-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  cursor: pointer;
  user-select: none;
  transition: background 120ms;
  gap: 10px;
}
.accordion-head:hover { background: var(--hover); }
.accordion-head h2,
.accordion-head .accordion-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
}
.accordion-arrow,
.accordion-icon {
  width: 20px;
  height: 20px;
  color: var(--muted);
  transition: rotate 200ms;
  flex-shrink: 0;
}
.accordion.open .accordion-arrow,
.accordion.open .accordion-icon { rotate: 180deg; }
.accordion-body {
  display: none;
  padding: 0 20px 20px;
  border-top: 1px solid var(--border);
}
.accordion.open .accordion-body { display: block; }

/* ============================================================
   使い方リスト（howto）
   ============================================================ */
.howto {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}
.howto li {
  counter-increment: step;
  padding: 10px 0 10px 36px;
  position: relative;
  border-bottom: 1px solid var(--border);
  color: var(--sub);
  font-size: 14px;
  line-height: 1.85;
}
.howto li:last-child { border-bottom: none; }
.howto li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 12px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--ink);
  color: white;
  font-weight: 600;
  font-size: 12px;
  display: grid;
  place-items: center;
}
.howto b   { color: var(--ink); font-weight: 700; }
.howto .sub { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }

/* ============================================================
   About セクション
   ============================================================ */
.about {
  color: var(--sub);
  font-size: 14px;
  line-height: 1.9;
  margin-top: 16px;
}
.about p               { margin: 0 0 12px; }
.about p:last-child    { margin-bottom: 0; }
.about b               { color: var(--ink); font-weight: 700; }

/* ============================================================
   トースト通知
   ============================================================ */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--ink);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms, transform 200ms;
  z-index: 300;
  box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.3);
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ============================================================
   FAQ
   ============================================================ */
.faq-list { display: flex; flex-direction: column; gap: 16px; }
.faq-item { padding: 12px 0; border-bottom: 1px solid var(--border); }
.faq-item:last-child { border-bottom: none; padding-bottom: 0; }
.faq-q { font-weight: 600; color: var(--ink); margin-bottom: 6px; font-size: 14px; }
.faq-a { color: var(--sub); font-size: 14px; line-height: 1.75; margin: 0; }

/* ============================================================
   広告スロット
   ============================================================ */
.ad-slot {
  width: 100%;
  display: flex;
  justify-content: center;
  overflow: hidden;
}
