/* ？ヘルプボタン（画面内どこからでも使える共通スタイル）
   HTML側:
     <button class="help-btn help-usage" data-help-key="worklog.usage.overview">?</button>
     <button class="help-btn help-term"  data-help-key="worklog.term.site">i</button>

   class指定なし(.help-btn のみ)は従来互換のグレー「？」。
   help-usage = 青の「？」（使い方）
   help-term  = 緑の「i」（用語説明）
*/
.help-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  margin-left: 4px;
  border-radius: 50%;
  background: #e2e8f0;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: none;
  line-height: 1;
  flex-shrink: 0;
  vertical-align: middle;
  transition: background 0.15s, color 0.15s, transform 0.1s;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.help-btn:hover {
  background: #2563eb;
  color: #fff;
}
.help-btn:active {
  transform: scale(0.92);
}

/* 使い方（青の「？」） */
.help-btn.help-usage {
  background: #2563eb;
  color: #fff;
}
.help-btn.help-usage:hover {
  background: #1d4ed8;
}

/* 用語説明（緑の「i」） */
.help-btn.help-term {
  background: #16a34a;
  color: #fff;
  font-style: italic;
  font-family: Georgia, 'Times New Roman', serif;
}
.help-btn.help-term:hover {
  background: #15803d;
}

.help-tooltip-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.35);
  z-index: 10000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}
.help-tooltip-overlay.show {
  display: flex;
}
.help-tooltip-box {
  background: #fff;
  border-radius: 12px;
  padding: 22px 24px 18px;
  max-width: 560px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
  position: relative;
}
.help-tooltip-box .help-close {
  position: absolute;
  top: 8px;
  right: 12px;
  background: none;
  border: none;
  font-size: 1.6rem;
  cursor: pointer;
  color: #94a3b8;
  line-height: 1;
}
.help-tooltip-box .help-close:hover {
  color: #475569;
}
.help-tooltip-box .help-type-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 10px;
  margin-bottom: 8px;
}
.help-tooltip-box .help-type-badge.help-usage-badge {
  background: #dbeafe;
  color: #1d4ed8;
}
.help-tooltip-box .help-type-badge.help-term-badge {
  background: #dcfce7;
  color: #15803d;
}
.help-tooltip-box .help-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 12px;
  color: #1d4ed8;
  padding-right: 24px;
}
.help-tooltip-box.is-term .help-title {
  color: #15803d;
}
.help-tooltip-box .help-body {
  font-size: 0.92rem;
  line-height: 1.8;
  color: #334155;
  white-space: pre-wrap;
  word-wrap: break-word;
}
.help-tooltip-box .help-category {
  display: inline-block;
  font-size: 0.7rem;
  background: #f1f5f9;
  color: #64748b;
  padding: 2px 8px;
  border-radius: 10px;
  margin-top: 12px;
}
