/* J歴史まとめ（rekishi-nanj.com）— thread.css
 *
 * 運用中のLivedoorブログのスマホ版デザインを移植したもの。
 * 元はLivedoorのlite2テンプレート(common.css 100KB + default_2019.css 17KB)と
 * ユーザーCSSの組み合わせだが、あれはLivedoor独自のマークアップ
 * (.article-body-outer / .box / .article-header 等)を飾るものでこの仕組みの
 * 出力には1つも当たらないため、デザイントークンだけ写して組み直してある。
 *
 * 実サイトから採取した値:
 *   ページ背景  #4b6820（オリーブ緑）      ユーザーCSS
 *   ヘッダ      #4b9620 / 文字 #f9f6fe     ユーザーCSS
 *   カード      #fff / radius 4px / box-shadow 0 1px 5px rgba(0,0,0,.1)
 *   本文        Arial 14px / line-height 1.4 / 色 #444・#666
 *   区切り線    #efefef, #e2e2e2
 *   本文リンク  #0088e7 下線
 *   レス欄      border-left 3px solid #eee / padding 10px / margin-bottom 20px
 *   レス番号    81.25%     レス名 rgb(0,128,0)     本文 bold
 *
 * スマホ専用のメディアクエリにはしない（PCでも同じ見た目にする、という要望）。
 * PCでは幅が間延びしないよう max-width で中央寄せするだけに留めている。
 */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: Arial, "Hiragino Sans", "Meiryo", sans-serif;
  background: #4b6820;
  color: #444;
  font-size: 14px;
  line-height: 1.4;
  -webkit-text-size-adjust: 100%;
}

/* --- ヘッダ（実サイトのブログタイトル帯に相当） --- */
.thread-header {
  background: #4b9620;
  padding: 10px;
  text-align: center;
}
.thread-header a {
  color: #f9f6fe;
  font-size: 12px;
  text-decoration: none;
  display: inline-block;
  margin-bottom: 6px;
}
.thread-header a:hover { text-decoration: underline; }
.thread-header h1 {
  font-size: 16px;
  line-height: 1.4;
  color: #f9f6fe;
  font-weight: bold;
}

.thread-tags { margin: 8px 0 0; }
.thread-tag {
  display: inline-block; padding: 2px 8px; margin-right: 4px;
  background: rgba(255,255,255,0.18); color: #f9f6fe;
  border: 1px solid rgba(255,255,255,0.45); border-radius: 4px;
  font-size: 12px; text-decoration: none;
}
.thread-tag:hover { background: rgba(255,255,255,0.32); }

/* --- 本文カード --- */
.thread-body {
  max-width: 800px;
  margin: 10px auto;
  padding: 10px;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
}

.post-container {
  margin-bottom: 20px;
  padding: 10px;
  border-left: 3px solid #eee;
}
.post-container:last-child { margin-bottom: 0; }

.id-line {
  font-size: 81.25%;
  color: #666;
  margin-bottom: 4px;
}
.user-name { color: rgb(0, 128, 0); }

.post-content {
  font-weight: bold;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.5;
}

.anker { color: #0088e7; text-decoration: underline; }
.anker:hover { opacity: 0.75; }

/* --- フッタ（関連記事・前後ナビ） --- */
.thread-footer {
  max-width: 800px;
  margin: 0 auto 10px;
  padding: 0;
  color: #666;
  font-size: 12px;
  text-align: center;
}

.related-articles {
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
  padding: 10px;
  margin-bottom: 10px;
  text-align: left;
}
.related-label {
  color: #666;
  font-weight: normal;
  font-size: 14px;
  margin-bottom: 6px;
}
.related-list { list-style: none; }
.related-list li {
  font-weight: bold;
  border-bottom: 1px solid #efefef;
}
.related-list li:last-child { border-bottom: none; }
.related-list li a {
  display: block;
  padding: 9px 2px;
  color: #0088e7;
  text-decoration: none;
  font-size: 14px;
  line-height: 1.4;
}
.related-list li a:hover { text-decoration: underline; }

.thread-nav {
  display: flex;
  align-items: stretch;
  gap: 10px;
  padding: 0;
  margin-bottom: 10px;
}
.nav-card {
  display: flex; flex-direction: column; justify-content: center;
  flex: 1; min-width: 0;
  padding: 10px;
  background: #fff;
  border: none;
  border-radius: 5px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
  text-decoration: none;
  color: #444;
}
.nav-card:hover:not(.nav-disabled) { background: #f7f7f7; }
.nav-disabled { opacity: 0.35; pointer-events: none; }
.nav-direction { font-size: 12px; color: #666; margin-bottom: 4px; }
.nav-title {
  font-size: 13px; font-weight: bold;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.nav-index { flex: 0 0 90px; align-items: center; text-align: center; }
.nav-index .nav-direction { margin-bottom: 0; }
.nav-next { text-align: right; }

.thread-footer p { padding: 6px 10px; color: #efefef; }

@media (max-width: 600px) {
  .thread-body, .thread-footer { margin-left: 10px; margin-right: 10px; }
  .thread-nav { gap: 6px; }
  .nav-index { flex-basis: 72px; }
  .nav-title { font-size: 12px; }
}