/*
Theme Name: Simple Text Theme
Theme URI: https://example.com
Author: Your Name
Author URI: https://example.com
Description: シンプルでテキスト中心の1カラムWordPressテーマ。固定ページとカテゴリページに最適化。
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: simple-text-theme
Tags: one-column, responsive, clean, minimal
*/

/* ==========================================================================
   リセット & ベース
   ========================================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans JP', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', Meiryo, sans-serif;
  line-height: 1.8;
  color: #333;
  background-color: #fff;
  font-size: 1rem;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

a {
  color: #0066cc;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #004499;
  text-decoration: underline;
}

/* ==========================================================================
   ヘッダー（コンパクト）
   ========================================================================== */

.site-header {
  background-color: #fff;
  border-bottom: 1px solid #e0e0e0;
  padding: 0.8rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-branding {
  display: flex;
  align-items: center;
}

.custom-logo {
  max-height: 40px;
  width: auto;
}

.site-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0;
  line-height: 1.2;
}

.site-title a {
  color: #333;
  text-decoration: none;
}

.site-title a:hover {
  color: #0066cc;
  text-decoration: none;
}

/* メインナビゲーション */
.main-navigation {
  flex-grow: 1;
  display: flex;
  justify-content: flex-end;
}

.main-navigation ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.main-navigation li {
  margin: 0;
}

.main-navigation a {
  color: #333;
  font-size: 0.95rem;
  font-weight: 500;
  padding: 0.3rem 0;
  display: inline-block;
}

.main-navigation a:hover {
  color: #0066cc;
}

/* モバイルメニュー */
.menu-toggle {
  display: none;
  background: none;
  border: 1px solid #ddd;
  padding: 0.5rem 1rem;
  cursor: pointer;
  font-size: 0.9rem;
  border-radius: 4px;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  .main-navigation {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    display: none;
  }

  .main-navigation.toggled {
    display: block;
  }

  .main-navigation ul {
    flex-direction: column;
    padding: 1rem 20px;
    gap: 0;
  }

  .main-navigation li {
    border-bottom: 1px solid #f0f0f0;
  }

  .main-navigation li:last-child {
    border-bottom: none;
  }

  .main-navigation a {
    display: block;
    padding: 0.8rem 0;
  }
}

/* ==========================================================================
   メインコンテンツ
   ========================================================================== */

.site-main {
  max-width: 600px;
  margin: 0 auto;
  padding: 3rem 20px;
  min-height: 60vh;
}

.content-area {
  width: 100%;
}

/* ==========================================================================
   記事・固定ページ
   ========================================================================== */

article {
  margin-bottom: 3rem;
}

.entry-header {
  margin-bottom: 2rem;
}

.entry-title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 1rem;
  color: #222;
}

.entry-meta {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 1.5rem;
}

.entry-content {
  font-size: 1.05rem;
  line-height: 1.9;
}

/* ==========================================================================
   見出し（h2～h4）
   ========================================================================== */

.entry-content h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #222;
  margin: 3rem 0 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 3px solid #0066cc;
  line-height: 1.4;
}

.entry-content h2:first-child {
  margin-top: 0;
}

.entry-content h3 {
  font-size: 1.4rem;
  font-weight: 600;
  color: #333;
  margin: 2.5rem 0 1.2rem;
  padding-left: 0.8rem;
  border-left: 4px solid #0066cc;
  line-height: 1.4;
}

.entry-content h4 {
  font-size: 1.2rem;
  font-weight: 600;
  color: #444;
  margin: 2rem 0 1rem;
  padding-left: 0.6rem;
  border-left: 3px solid #66b3ff;
  line-height: 1.4;
}

/* ==========================================================================
   段落・テキスト
   ========================================================================== */

.entry-content p {
  margin-bottom: 1.5rem;
}

.entry-content strong {
  font-weight: 700;
  color: #222;
}

.entry-content em {
  font-style: italic;
}

/* ==========================================================================
   リスト
   ========================================================================== */

.entry-content ul,
.entry-content ol {
  margin: 1.5rem 0 1.5rem 2rem;
  padding: 0;
}

.entry-content li {
  margin-bottom: 0.8rem;
  line-height: 1.8;
}

.entry-content ul li {
  list-style: none;
  position: relative;
  padding-left: 1.5rem;
}

.entry-content ul li::before {
  content: "●";
  color: #0066cc;
  font-size: 0.8em;
  position: absolute;
  left: 0;
  top: 0.3em;
}

.entry-content ol {
  counter-reset: list-counter;
}

.entry-content ol li {
  list-style: none;
  position: relative;
  padding-left: 2rem;
  counter-increment: list-counter;
}

.entry-content ol li::before {
  content: counter(list-counter) ".";
  color: #0066cc;
  font-weight: 700;
  position: absolute;
  left: 0;
}

/* ==========================================================================
   テーブル
   ========================================================================== */

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.95rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.entry-content table th {
  background-color: #0066cc;
  color: #fff;
  font-weight: 600;
  padding: 1rem;
  text-align: left;
  border: 1px solid #0055aa;
}

.entry-content table td {
  padding: 1rem;
  border: 1px solid #ddd;
  background-color: #fff;
}

.entry-content table tr:nth-child(even) td {
  background-color: #f9f9f9;
}

.entry-content table tr:hover td {
  background-color: #f0f7ff;
}

@media (max-width: 768px) {
  .entry-content table {
    font-size: 0.85rem;
  }

  .entry-content table th,
  .entry-content table td {
    padding: 0.7rem;
  }
}

/* ==========================================================================
   装飾ボックス
   ========================================================================== */

/* ワンポイントボックス */
.point-box {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  padding: 1.5rem 2rem;
  margin: 2rem 0;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  line-height: 1.6;
}

/* インフォボックス */
.info-box {
  background-color: #e3f2fd;
  border-left: 4px solid #2196f3;
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 4px;
}

.info-box p:last-child {
  margin-bottom: 0;
}

/* 警告ボックス */
.warning-box {
  background-color: #fff3e0;
  border-left: 4px solid #ff9800;
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 4px;
}

.warning-box p:last-child {
  margin-bottom: 0;
}

/* 注意ボックス */
.alert-box {
  background-color: #ffebee;
  border-left: 4px solid #f44336;
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 4px;
}

.alert-box p:last-child {
  margin-bottom: 0;
}

/* 成功ボックス */
.success-box {
  background-color: #e8f5e9;
  border-left: 4px solid #4caf50;
  padding: 1.5rem;
  margin: 2rem 0;
  border-radius: 4px;
}

.success-box p:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   トップページ - 更新履歴
   ========================================================================== */

.recent-updates {
  margin: 3rem 0;
  padding: 2rem;
  background-color: #f9f9f9;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
}

.recent-updates h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  padding-bottom: 0.8rem;
  border-bottom: 2px solid #0066cc;
}

.recent-updates ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.recent-updates li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e0e0e0;
}

.recent-updates li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.recent-updates .post-date {
  display: inline-block;
  font-size: 0.9rem;
  color: #666;
  margin-right: 1rem;
  font-weight: 500;
}

.recent-updates .post-title {
  font-size: 1rem;
  color: #333;
}

.recent-updates a:hover .post-title {
  color: #0066cc;
}

/* ==========================================================================
   カテゴリページ - 投稿一覧
   ========================================================================== */

.archive-header {
  margin-bottom: 3rem;
  padding-bottom: 1.5rem;
  border-bottom: 2px solid #0066cc;
}

.archive-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: #222;
}

.archive-description {
  font-size: 1.05rem;
  color: #666;
  line-height: 1.8;
}

.posts-list {
  display: grid;
  gap: 2rem;
}

.post-item {
  background-color: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 1.5rem;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.post-item:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.post-item .entry-title {
  font-size: 1.4rem;
  margin-bottom: 0.8rem;
}

.post-item .entry-title a {
  color: #222;
}

.post-item .entry-title a:hover {
  color: #0066cc;
  text-decoration: none;
}

.post-item .entry-meta {
  margin-bottom: 1rem;
}

.post-item .entry-summary {
  font-size: 0.95rem;
  line-height: 1.7;
  color: #555;
}

/* ==========================================================================
   フッター
   ========================================================================== */

.site-footer {
  background-color: #2c3e50;
  color: #ecf0f1;
  padding: 2.5rem 0 1.5rem;
  margin-top: 4rem;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer-navigation {
  margin-bottom: 2rem;
}

.footer-navigation ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  justify-content: center;
  margin: 0;
  padding: 0;
}

.footer-navigation li {
  margin: 0;
}

.footer-navigation a {
  color: #ecf0f1;
  font-size: 0.9rem;
  transition: color 0.3s ease;
}

.footer-navigation a:hover {
  color: #3498db;
  text-decoration: none;
}

.site-info {
  text-align: center;
  font-size: 0.85rem;
  color: #bdc3c7;
  padding-top: 1.5rem;
  border-top: 1px solid #34495e;
}

@media (max-width: 768px) {
  .footer-navigation ul {
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
  }
}

/* ==========================================================================
   ページネーション
   ========================================================================== */

.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 3rem 0;
  flex-wrap: wrap;
}

.pagination a,
.pagination span {
  padding: 0.6rem 1rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  color: #333;
  background-color: #fff;
  transition: all 0.3s ease;
}

.pagination a:hover {
  background-color: #0066cc;
  color: #fff;
  border-color: #0066cc;
  text-decoration: none;
}

.pagination .current {
  background-color: #0066cc;
  color: #fff;
  border-color: #0066cc;
  font-weight: 600;
}

/* ==========================================================================
   レスポンシブ
   ========================================================================== */

@media (max-width: 768px) {
  .site-main {
    padding: 2rem 15px;
  }

  .entry-title {
    font-size: 1.6rem;
  }

  .entry-content {
    font-size: 1rem;
  }

  .entry-content h2 {
    font-size: 1.5rem;
    margin: 2.5rem 0 1.2rem;
  }

  .entry-content h3 {
    font-size: 1.25rem;
    margin: 2rem 0 1rem;
  }

  .entry-content h4 {
    font-size: 1.1rem;
    margin: 1.5rem 0 0.8rem;
  }

  .entry-content ul,
  .entry-content ol {
    margin-left: 1.5rem;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 15px;
  }

  .site-header {
    padding: 0.6rem 0;
  }

  .site-title {
    font-size: 1.15rem;
  }

  .entry-title {
    font-size: 1.4rem;
  }
}
