/* =================================================
   基本設定
================================================= */
html {
  scroll-behavior: smooth;
}

body {
  font-family: Meiryo, "MS PGothic", sans-serif;
  background: url('img/poke.jpg') no-repeat center center fixed;
  background-size: cover;
  margin: 0;
  padding: 0;
  color: #333;
  font-size: 14px;
}

a {
  color: #0077cc;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* =================================================
   レイアウト共通
================================================= */
.container {
  width: 900px;
  max-width: 95%;
  margin: 0 auto 20px;
  background: #fff;
  padding: 15px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  border-radius: 6px;
}

/* =================================================
   ヘッダー
================================================= */
.site-header {
  background: #0077cc;
  color: #fff;
  padding: 12px 0;
  margin-bottom: 15px;
}

.header-inner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.site-logo {
  font-size: 32px;
  font-weight: bold;
  margin: 0;
  text-shadow: 1px 1px 2px #000;
}

.header-logo {
  width: 48px;
  height: 48px;
}

/* =================================================
   グローバル案内（注意・リンク）
================================================= */
.global-notice {
  border: 1px solid #ccc;
  background: #f9f9f9;
  padding: 10px;
  margin-bottom: 15px;
  font-size: 13px;
}

.notice-text {
  line-height: 1.6;
}

.notice-links {
  text-align: right;
}
.notice-links a {
  margin-left: 8px;
}

/* =================================================
   板ナビ
================================================= */
.board-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  padding: 6px 8px;
  margin-bottom: 15px;
  background: #eef6ff;
  border: 1px solid #ccd;
  border-radius: 4px;
  font-size: 13px;
}

.board-nav a {
  padding: 3px 7px;
  border-radius: 4px;
}
.board-nav a:hover {
  background: #cce0ff;
}
.board-nav a.current {
  background: #0077cc;
  color: #fff;
  font-weight: bold;
}

/* =================================================
   板TOP・スレ一覧
================================================= */
.thread-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.thread-list {
  border-top: 1px solid #ccc;
}

.thread-item {
  display: grid;
  grid-template-columns: 1fr 60px 120px; /* 番号列を削除して3列に */
  gap: 8px;
  padding: 8px 6px;
  border-bottom: 1px dotted #ccc;
  align-items: center;
}


.thread-item:hover {
  background: #f5f9ff;
}

.thread-no {
  text-align: right;
  color: #666;
}

.thread-title {
  color: #0077cc;
  font-weight: 500;
  word-break: break-word;
}

.thread-res,
.thread-time {
  text-align: right;
  font-size: 12px;
  color: #555;
}

.thread-board {
  font-size: 12px;
  color: #888;
}

/* 新規スレボタン */
.btn-new-thread {
  background: #0077cc;
  color: #fff;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 13px;
}
.btn-new-thread:hover {
  background: #005fa3;
}

/* =================================================
   ページネーション
================================================= */
.pagination {
  margin: 15px 0;
  text-align: center;
}

.pagination a,
.pagination span {
  display: inline-block;
  margin: 0 3px;
  padding: 4px 8px;
  border-radius: 3px;
  font-size: 13px;
}

.pagination a {
  background: #eef;
  color: #0077cc;
}
.pagination span {
  background: #0077cc;
  color: #fff;
  font-weight: bold;
}

/* =================================================
   レス表示（thread.php）
================================================= */
.post {
  border: 1px solid #bbb;
  border-radius: 4px;
  margin-bottom: 8px;
  overflow: hidden;
}

.post-head {
  background: #eef6ff;
  padding: 4px 8px;
  font-size: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.post-no {
  font-weight: bold;
  color: #000;
}

.post-name {
  color: #008800;
}

.post-date {
  color: #666;
  font-size: 11px;
}

.post-body {
  padding: 10px 12px;
  font-size: 15px;
  line-height: 1.75;
  color: #111;
  word-break: break-word;
}

.post-footer {
  padding: 4px 8px;
  text-align: right;
  font-size: 12px;
}

/* AA（アスキーアート）用 */
.aa {
  font-family: "MS Gothic", monospace;
  white-space: pre;
}

/* =================================================
   フォーム共通（スレ立て・書き込み）
================================================= */
.thread-form label {
  font-weight: bold;
  display: block;
  margin: 10px 0 4px;
}

.input-title,
.input-name,
.input-body {
  width: 100%;
  box-sizing: border-box;
  padding: 6px;
  border-radius: 4px;
  border: 1px solid #ccc;
}

.input-title {
  font-size: 16px;
  font-weight: bold;
}

.input-name {
  font-size: 14px;
}

.input-body {
  width: 100%;
  box-sizing: border-box;
  padding: 8px;
  min-height: 240px;   
  resize: vertical;
  font-size: 15px;
  line-height: 1.7;
  border-radius: 4px;
  border: 1px solid #ccc;
  background: #fdfdfd;
}

.btn-submit {
  margin-top: 10px;
  background: #0077cc;
  color: #fff;
  padding: 6px 16px;
  border-radius: 4px;
  border: none;
  cursor: pointer;
}
.btn-submit:hover {
  background: #005fa3;
}

/* =================================================
   メッセージ類
================================================= */
.notice {
  background: #f9f9f9;
  border: 1px solid #ddd;
  padding: 10px;
  margin-bottom: 15px;
  font-size: 13px;
}

.error-msg {
  background: #ffeeee;
  border: 1px solid #dd9999;
  color: #c00;
  font-weight: bold;
  padding: 8px;
  margin-bottom: 10px;
}

/* 検索ワード強調 */
.hl {
  background: #ffff99;
  font-weight: bold;
}

/* =================================================
   トップページ
================================================= */
.site-desc {
  margin: 20px 0;
  text-align: center;
  color: #444;
}

.board-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
}

.board-item {
  border: 1px solid #ddd;
  padding: 10px;
  text-align: center;
  background: #fff;
}

/* =================================================
   フッター
================================================= */
.site-footer {
  margin: 40px 0 10px;
  text-align: center;
  font-size: 13px;
  color: #777;
}

/* =================================================
   スマホ対応（修正版）
================================================= */
@media (max-width: 600px) {
  /* 基本文字サイズを大きく */
  body {
    font-size: 16px;
    line-height: 1.6;
  }

  .container {
    padding: 12px;
  }

  .site-logo {
    font-size: 28px;
  }

  /* 板ナビのリンクを縦並び */
  .board-nav {
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
  }
  .board-nav a {
    padding: 6px 10px;
  }

  /* スレッド一覧 */
  .thread-item {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 8px 6px;
  }
  .thread-title {
    font-size: 16px;
  }
  .thread-res,
  .thread-time,
  .thread-board {
    text-align: left;
    font-size: 13px;
  }

  /* レス表示 */
  .post-head {
    flex-direction: column;
    align-items: flex-start;
    font-size: 14px;
    gap: 4px;
  }
  .post-no {
    font-size: 14px;
  }
  .post-name {
    font-size: 15px;
  }
  .post-date {
    font-size: 13px;
  }
  .post-body {
    font-size: 16px;
    line-height: 1.8;
  }
  .post-footer {
    font-size: 14px;
  }

  /* フォーム */
  .input-title {
    font-size: 18px;
  }
  .input-name {
    font-size: 16px;
  }
  .input-body {
    font-size: 16px;
    min-height: 240px;
  }
  .btn-submit {
    font-size: 16px;
    padding: 10px 16px;
  }

  /* ページネーション */
  .pagination a,
  .pagination span {
    font-size: 14px;
    padding: 6px 10px;
  }
}

.thread-no {
  display: none;
}
