/* 目次が表示されるようにするためのCSS */
.table-of-contents.show,
ul.table-of-contents.show {
    display: block !important;
}
/* サイト全体の包括的なフォントサイズ調整 */

/* ===== 全体的な設定 ===== */
body {
  font-family: 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', Meiryo, sans-serif !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
}

/* ===== ヘッダー要素 ===== */
/* ブログタイトル */
#title a {
  font-size: 28px !important;
  font-weight: 700 !important;
  line-height: 1.4 !important;
}

/* ブログ説明 */
#blog-description {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

/* パンくずリスト */
.breadcrumb-inner {
  font-size: 14px !important;
  line-height: 1.4 !important;
}

/* ===== 記事一覧・アーカイブページ ===== */
.archive-entry-header .entry-title a {
  font-size: 22px !important;
  line-height: 1.5 !important;
  font-weight: 700 !important;
}

.archive-entry-summary {
  font-size: 16px !important;
  line-height: 1.7 !important;
}

/* ===== 記事ページ要素 ===== */
/* 記事タイトル */
.entry-title {
  font-size: 26px !important;
  line-height: 1.4 !important;
  font-weight: 700 !important;
}

.entry-title a {
  font-size: 26px !important;
  line-height: 1.4 !important;
}

/* カテゴリ */
.entry-categories a {
  font-size: 14px !important;
}

/* 日付 */
.date-time {
  font-size: 14px !important;
}

/* 記事本文 */
.entry-content {
  font-size: 18px !important;
  line-height: 1.8 !important;
}

/* 段落 */
.entry-content p {
  font-size: 18px !important;
  line-height: 1.8 !important;
  margin-bottom: 1.2em !important;
}

/* 見出し */
.entry-content h1 {
  font-size: 2.2em !important;
  line-height: 1.4 !important;
  margin: 1.5em 0 0.8em !important;
  font-weight: 700 !important;
}

.entry-content h2 {
  font-size: 1.8em !important;
  line-height: 1.4 !important;
  margin: 1.8em 0 0.8em !important;
  font-weight: 700 !important;
}

.entry-content h3 {
  font-size: 1.5em !important;
  line-height: 1.4 !important;
  margin: 1.5em 0 0.7em !important;
  font-weight: 600 !important;
}

.entry-content h4, 
.entry-content h5, 
.entry-content h6 {
  font-size: 1.2em !important;
  line-height: 1.4 !important;
  margin: 1.5em 0 0.7em !important;
  font-weight: 600 !important;
}

/* リスト */
.entry-content ul,
.entry-content ol {
  margin-bottom: 1.5em !important;
  padding-left: 2em !important;
}

.entry-content ul li, 
.entry-content ol li {
  font-size: 18px !important;
  line-height: 1.7 !important;
  margin-bottom: 0.8em !important;
}

/* 引用 */
.entry-content blockquote {
  font-size: 17px !important;
  line-height: 1.7 !important;
  padding: 1em 1.5em !important;
}

/* 特殊ボックス */
.entry-content div[style*="background-color"],
.entry-content div.urllist-entry-body {
  font-size: 17px !important;
  line-height: 1.7 !important;
}

/* テーブル */
.entry-content table,
.entry-content th,
.entry-content td {
  font-size: 17px !important;
  line-height: 1.5 !important;
}

/* フィギュアキャプション */
.entry-content figcaption {
  font-size: 14px !important;
  line-height: 1.5 !important;
  margin-top: 0.5em !important;
}

/* コード */
.entry-content pre,
.entry-content code {
  font-size: 15px !important;
  line-height: 1.5 !important;
}

/* ===== 目次 ===== */
.table-of-contents {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

.table-of-contents li {
  margin-bottom: 0.5em !important;
}

/* ===== 記事フッター ===== */
/* タグ */
.entry-tags-wrapper {
  font-size: 14px !important;
  line-height: 1.6 !important;
}

/* 投稿者・日付 */
.entry-footer-section {
  font-size: 14px !important;
  line-height: 1.6 !important;
}

/* コメント欄 */
.comment-box {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

.comment-user-name {
  font-size: 15px !important;
  font-weight: 600 !important;
}

.comment-content {
  font-size: 16px !important;
  line-height: 1.6 !important;
}

/* ===== サイドバー要素 ===== */
/* モジュールタイトル */
.hatena-module-title {
  font-size: 18px !important;
  font-weight: 700 !important;
  line-height: 1.4 !important;
  margin-bottom: 10px !important;
}

/* モジュール内リスト */
.hatena-module-body {
  font-size: 15px !important;
  line-height: 1.5 !important;
}

/* 関連記事・最新記事 */
.urllist-title-link {
  font-size: 15px !important;
  line-height: 1.5 !important;
}

.urllist-entry-body {
  font-size: 14px !important;
  line-height: 1.5 !important;
}

/* 日付 */
.urllist-date-link time {
  font-size: 13px !important;
}

/* ===== 記事間のページャー ===== */
.pager {
  font-size: 16px !important;
  line-height: 1.5 !important;
}

/* ===== フッター ===== */
#bottom-editarea {
  font-size: 14px !important;
  line-height: 1.5 !important;
}

.copyright {
  font-size: 13px !important;
}

/* ===== モバイル向け設定 ===== */
@media screen and (max-width: 768px) {
  /* ヘッダー要素 */
  #title a {
    font-size: 24px !important;
  }
  
  #blog-description {
    font-size: 14px !important;
  }
  
  /* 記事タイトル */
  .entry-title, 
  .entry-title a {
    font-size: 22px !important;
    line-height: 1.3 !important;
  }
  
  /* 記事本文 */
  .entry-content {
    font-size: 16px !important;
    line-height: 1.6 !important;
  }
  
  .entry-content p {
    font-size: 16px !important;
    line-height: 1.6 !important;
  }
  
  /* 見出し */
  .entry-content h1 {
    font-size: 1.8em !important;
  }
  
  .entry-content h2 {
    font-size: 1.5em !important;
  }
  
  .entry-content h3 {
    font-size: 1.3em !important;
  }
  
  /* リスト */
  .entry-content ul li, 
  .entry-content ol li {
    font-size: 16px !important;
    line-height: 1.6 !important;
  }
  
  /* 特殊ボックス */
  .entry-content div[style*="background-color"],
  .entry-content blockquote {
    font-size: 15px !important;
  }
  
  /* サイドバー */
  .hatena-module-title {
    font-size: 16px !important;
  }
  
  .hatena-module-body {
    font-size: 14px !important;
  }
  
  .urllist-title-link {
    font-size: 14px !important;
  }
}

/* スマートフォン向け（さらに小さめ） */
@media screen and (max-width: 480px) {
  /* ヘッダー要素 */
  #title a {
    font-size: 20px !important;
  }
  
  /* 記事タイトル */
  .entry-title, 
  .entry-title a {
    font-size: 20px !important;
  }
  
  /* 記事本文 */
  .entry-content p {
    font-size: 15px !important;
    line-height: 1.5 !important;
    margin-bottom: 1em !important;
  }
  
  /* 見出し */
  .entry-content h2 {
    font-size: 1.4em !important;
    margin: 1.5em 0 0.7em !important;
  }
  
  .entry-content h3 {
    font-size: 1.2em !important;
  }
  
  /* リスト */
  .entry-content ul li, 
  .entry-content ol li {
    font-size: 15px !important;
    line-height: 1.5 !important;
    margin-bottom: 0.6em !important;
  }
  
  /* モジュール */
  .hatena-module-title {
    font-size: 15px !important;
  }
  
  /* パンくず */
  .breadcrumb-inner {
    font-size: 12px !important;
  }
}

/* ===== 読みやすさ向上のための追加調整 ===== */
.entry-content {
  max-width: 760px !important;
  margin: 0 auto !important;
  word-wrap: break-word !important;
}

/* 画像のレスポンシブ対応 */
.entry-content img {
  max-width: 100% !important;
  height: auto !important;
}

/* テキスト要素の調整 */
.entry-content strong {
  font-weight: 700 !important;
}

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

/* リンクの視認性向上 */
.entry-content a {
  text-decoration: underline !important;
  color: #3366cc !important;
}

.entry-content a:hover {
  opacity: 0.8 !important;
}

/* コントラスト向上 */
.entry-content {
  color: #333333 !important;
}

/* トレンドネット 最終最適化版CSS - 2025年3月版
 * important削除・スタイル優先度調整版
 * モバイル改善・読みやすさ向上版
 * 色の汎用性向上・変数整理版
 */

/* ===== 1. 基本設定 - 汎用性向上のための変数構造 ===== */
:root {
  /* プライマリカラー - サイト全体のメインカラー */
  --primary-hue: 280;
  --primary-sat: 70%;
  --primary-base: #6a1b9a;
  --primary-light: #9c27b0;
  --primary-dark: #4a148c;
  
  /* アクセントカラー - 強調用 */
  --accent-hue: 340;
  --accent-sat: 100%;
  --accent-base: #ff4081;
  --accent-light: #ff80ab;
  --accent-dark: #c51162;
  
  /* テキストカラー */
  --text-base: #333;
  --text-light: #666;
  --text-lighter: #888;
  --text-dark: #111;
  
  /* 背景カラー */
  --bg-base: #f9f9fa;
  --card-base: #fff;
  --border-color: #e0e0e0;
  
  /* エフェクト */
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.08);
  --shadow-md: 0 3px 6px rgba(0,0,0,0.1);
  --shadow-lg: 0 8px 20px rgba(0,0,0,0.15);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
  --gradient-overlay: linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.7));
  
  /* タイポグラフィ */
  --font-heading: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", sans-serif;
  
  /* スペーシング */
  --spacing-xs: 0.25em;
  --spacing-sm: 0.5em;
  --spacing-md: 1em;
  --spacing-lg: 2em;
  --spacing-xl: 3em;
  
  /* レイアウト */
  --content-width-sm: 650px;
  --content-width-md: 800px;
  --content-width-lg: 1200px;
}

/* リセット */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body * {
  max-width: 100%;
  box-sizing: border-box;
}

img {
  max-width: 100% !important; /* 画像関連なので!importantを残す */
  height: auto !important; /* 画像関連なので!importantを残す */
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-base);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.4;
  margin: 1.5em 0 0.8em;
}

p {
  margin-bottom: 1em;
  line-height: 1.9; /* 行間を広げて読みやすく */
}

ul, ol {
  margin: 1em 0;
  padding-left: 1.5em;
}

/* コンテナリセット - 位置設定の改善 - 左右スクロール制約 */
#container, 
#container-inner,
#content, 
#content-inner,
#wrapper,
#main,
#main-inner,
.entry,
.entry-content {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 0;
  float: none;
  position: relative; /* static から relative に変更 */
  overflow-x: hidden; /* スマホでの横スクロール防止 */
  transform: none;
}

/* サイドバー非表示 */
#box1, #box2 {
  display: none;
}

/* ===== 3. ヘッダー ===== */
#blog-title {
  background-color: var(--card-base);
  box-shadow: var(--shadow-md);
  text-align: center;
  padding: 40px 20px;
  margin-bottom: 25px;
  position: relative;
  overflow: hidden;
}

#blog-title::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(to right, var(--primary-base), var(--accent-base));
}

#title {
  font-size: 2.2rem;
  margin: 10px 0;
}

#title a {
  color: var(--primary-base);
  display: inline-block;
  position: relative;
  background: linear-gradient(90deg, var(--primary-base), var(--accent-base));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  transition: transform 0.3s ease;
}

#title a:hover {
  transform: translateY(-2px);
}

#blog-description {
  color: var(--text-light);
  font-size: 1rem;
  font-weight: 400;
  margin-top: 10px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== 4. パンくずリスト ===== */
.breadcrumb {
  margin: 0 auto 20px;
  max-width: var(--content-width-md);
  padding: 0 20px;
  width: 100%;
  box-sizing: border-box;
}

.breadcrumb-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-light);
}

.breadcrumb-link, 
.breadcrumb-child-link {
  color: var(--text-light);
}

.breadcrumb-link:hover, 
.breadcrumb-child-link:hover {
  color: var(--primary-base);
}

.breadcrumb-gt {
  margin: 0 8px;
  color: #ccc;
}

/* ===== 5. トップページ記事一覧 (画像全面表示スタイル) ===== */
.archive-entries {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 30px;
  max-width: var(--content-width-lg);
  margin: 0 auto;
  padding: 25px;
}

/* 記事カードスタイル */
.archive-entry {
  background-color: var(--card-base);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  position: relative;
  height: 300px;
  margin-bottom: 20px;
  padding: 0;
}

.archive-entry:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

/* カードカバー画像スタイル */
.entry-thumb-link {
  display: block;
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}

.entry-thumb {
  width: 100% !important; /* 画像関連 */
  height: 100% !important; /* 画像関連 */
  object-fit: cover !important; /* 画像関連 */
  transition: transform 0.5s ease; /* 0.6sから0.5sに軽量化 */
}

.archive-entry:hover .entry-thumb {
  transform: scale(1.05); /* 1.08から1.05に軽量化 */
}

/* グラデーションオーバーレイ */
.entry-thumb-link::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-overlay);
  z-index: 2;
}

/* テキストオーバーレイ */
.archive-entry-header {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 25px;
  z-index: 3;
}

.archive-entry-header .entry-title {
  font-size: 1.8rem;
  margin: 0 0 10px 0;
  line-height: 1.4;
  text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.archive-entry-header .entry-title-link {
  color: white;
  text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.archive-date {
  color: rgba(255,255,255,0.95); /* コントラスト向上のため0.9→0.95 */
  font-size: 1.5rem;
  margin-top: 8px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.9); /* シャドウ強化 */
}

.archive-date a {
  color: rgba(255,255,255,0.95); /* コントラスト向上 */
}

/* 記事説明とカテゴリー非表示 */
.archive-entry-body,
.entry-description,
.categories, 
.entry-category-link, 
.archive-category-link {
  display: none;
}

/* ===== 6. 記事ページ ===== */
.entry {
  background-color: var(--card-base);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  margin: 0 auto 30px;
  max-width: var(--content-width-md);
  padding: 20px;
  width: 100%;
  text-align: left;
  box-sizing: border-box;
  display: block;
  float: none;
}

.entry-header {
  margin-bottom: 35px;
  position: relative;
}

.entry-header::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: linear-gradient(to right, var(--primary-base), var(--primary-light));
  margin-top: 20px;
}

.entry-date {
  color: var(--text-light);
  font-size: 1rem;
  margin-bottom: 15px;
  display: block;
}

.entry-title {
  font-size: 1.9rem;
  margin: 0 0 20px;
  color: var(--text-dark);
  line-height: 1.3;
}

/* 記事本文のスタイル - 余白改善 */
.entry-content {
  font-size: 1.5rem; /* 1.3remから1.5remへサイズアップ */
  line-height: 1.9; /* 行間を広げて読みやすく */
  letter-spacing: 0.01em;
  padding: 0;
  margin: 0;
  text-align: left;
}

.entry-content h2 {
  font-size: 1.85rem; /* 1.65remから1.85remへ */
  border-bottom: 2px solid var(--primary-base);
  padding-bottom: 0.5em;
  margin-top: 2em;
  text-align: left;
}

.entry-content h3 {
  font-size: 1.6rem; /* 1.4remから1.6remへ */
  border-left: 4px solid var(--primary-base);
  padding-left: 0.8em;
  margin-top: 1.8em;
  color: var(--primary-dark);
  text-align: left;
}

.entry-content p {
  margin-bottom: 1.5em;
  text-align: left;
  line-height: 1.9;
}

.entry-content a {
  color: var(--primary-base);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-bottom var(--transition-base);
  font-weight: 500;
}

.entry-content a:hover {
  border-bottom: 1px solid var(--primary-base);
  color: var(--accent-base);
}

/* 記事内の画像 */
.entry-content img {
  border-radius: var(--radius-md);
  display: block;
  margin: 2.2em auto;
  box-shadow: 0 3px 10px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.entry-content img:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.figure-image {
  margin: 2.5em 0;
}

figcaption {
  color: var(--text-light);
  font-size: 0.9rem;
  text-align: center;
  margin-top: 1em;
}

/* ===== 7. 目次 - ボックス中央表示・テキスト左寄せ ===== */
/* 目次の初期状態 - 非表示 */
ul.table-of-contents {
  display: none;
}

/* 目次が表示される時のスタイル - ボックス中央表示 */
ul.table-of-contents.show {
  display: block;
  background-color: #f9f9f9;
  border: 1px solid #eee;
  border-radius: var(--radius-md);
  padding: 0.6em; /* 0.8emから0.6emに縮小 */
  margin: 1.2em auto 1.8em auto; /* 余白を縮小 */
  max-width: 95%;
  counter-reset: item;
  box-shadow: 0 3px 10px rgba(0,0,0,0.05);
  list-style-type: none;
  position: static;
  text-align: left; /* 内部テキストは左寄せ */
}

/* 目次のタイトル */
ul.table-of-contents.show::before {
  content: "📑 目次";
  display: block;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5em; /* 0.6emから0.5emに縮小 */
  padding-bottom: 0.3em; /* 0.4emから0.3emに縮小 */
  border-bottom: 1px solid #eee;
  color: var(--primary-base);
  letter-spacing: 0.03em;
  background-color: #f5f5f5;
  border-radius: 4px;
  padding: 0.2em;
}

/* 目次の各項目 */
ul.table-of-contents li {
  margin-bottom: 0.4em; /* 0.5emから0.4emに縮小 */
  list-style-type: none;
  position: static;
  padding-left: 0.3em;
  overflow: visible;
  max-width: 100%;
  text-align: left;
}

ul.table-of-contents a {
  color: var(--text-base);
  display: inline-block;
  line-height: 1.3;
  padding-left: 5px;
  border-left: 2px solid transparent;
  transition: all var(--transition-base);
  font-size: 1.1rem; /* 0.95remから1.1remへ */
  font-weight: 500;
  position: static;
  word-break: break-word;
  text-align: left;
}

ul.table-of-contents a:hover {
  color: var(--primary-base);
  border-left-color: var(--primary-base);
  padding-left: 8px;
  background-color: rgba(106, 27, 154, 0.05);
}

/* 目次の階層2以下 */
ul.table-of-contents ul li {
  margin-left: 1em;
  margin-bottom: 0.3em;
  text-align: left;
}

ul.table-of-contents ul li a {
  font-size: 1rem; /* 0.9remから1remへ */
  font-weight: 400;
  text-align: left;
}

/* 目次トグルボタン - 中央表示 */
.toc-toggle-button {
  background: linear-gradient(to right, var(--primary-base), var(--primary-light));
  color: white;
  border: none;
  border-radius: 50px;
  padding: 8px 20px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  margin: 1.2em auto; /* 左右マージンをautoにして中央表示 */
  display: block;
  box-shadow: 0 3px 8px rgba(106,27,154,0.3);
  transition: all var(--transition-base);
  position: static;
  z-index: 5;
}

.toc-toggle-button:hover {
  background: linear-gradient(to right, var(--primary-light), var(--accent-base));
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(106,27,154,0.4);
}

.toc-toggle-button.open {
  background: linear-gradient(to right, #555, #777);
}

.toc-toggle-button::before {
  content: "📑 ";
  margin-right: 5px;
}

/* ===== 8. モジュール（注目記事・最新記事） ===== */
.entry-footer-modules {
  max-width: var(--content-width-md);
  margin: 0 auto;
  width: 100%;
  text-align: left;
  display: block;
  box-sizing: border-box;
}

.hatena-module {
  background-color: var(--card-base);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  margin-bottom: 30px;
  padding: 25px;
  transition: box-shadow var(--transition-base);
  position: relative;
  overflow: hidden;
  display: block;
  font-size: .85rem;
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  width: 100%;
}

.hatena-module::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, var(--primary-base), var(--accent-base));
}

.hatena-module:hover {
  box-shadow: var(--shadow-lg);
}

.hatena-module-title {
  color: var(--primary-base);
  font-size: 1.3rem;
  font-weight: 700;
  margin: 0 0 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid #f0f0f0;
  position: relative;
  display: block;
  border-top: none;
  text-align: left;
}

.hatena-module-title::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background: linear-gradient(to right, var(--primary-base), var(--accent-base));
}

.hatena-module-title a {
  color: var(--primary-base);
  text-decoration: none;
  text-align: left;
}

.hatena-module-title a:hover {
  text-decoration: none;
  color: var(--primary-light);
}

/* モジュール内のリスト */
.hatena-urllist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: block;
  line-height: 1.4;
  text-align: left;
}

.hatena-urllist li {
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 15px;
  padding-bottom: 15px;
  transition: transform var(--transition-base);
  list-style-type: none;
  text-align: left;
}

.hatena-urllist li:hover {
  transform: translateY(-5px);
}

.hatena-urllist li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

/* モジュール画像スタイル - 横並び */
.urllist-with-thumbnails li {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  text-align: left;
}

.urllist-image-link {
  flex: 0 0 120px;
  width: 120px;
  min-width: 120px;
  height: 80px;
  margin-right: 10px;
  overflow: hidden;
  border-radius: var(--radius-md);
  position: relative;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  transition: all var(--transition-base);
  display: block;
  text-decoration: none;
  top: 0;
}

.urllist-image-link:hover {
  box-shadow: 0 5px 15px rgba(0,0,0,0.15);
  transform: translateY(-3px);
  top: 0;
}

.urllist-image {
  width: 100% !important; /* 画像関連 */
  height: 100% !important; /* 画像関連 */
  object-fit: cover !important; /* 画像関連 */
  transition: transform 0.5s ease; /* 軽量化 */
}

.urllist-image-link:hover .urllist-image {
  transform: scale(1.05); /* 1.12から1.05に軽量化 */
}

/* タイトルと日付を右側に配置するためのコンテナ */
.urllist-with-thumbnails .urllist-item-inner {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1px;
  text-align: left;
}

.urllist-title-link {
  color: var(--text-base);
  display: block;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 5px;
  text-decoration: none;
  text-align: left;
}

.urllist-title-link:hover {
  color: var(--primary-base);
  text-decoration: none;
}

.urllist-date-link {
  display: block;
  color: #666;
  font-size: 0.8rem;
  margin-top: 3px;
  text-align: left;
}

.urllist-date-link a {
  color: #666;
  text-decoration: none;
}

/* もっと見るリンク */
.urllist-see-more {
  border-top: 1px solid var(--border-color);
  margin-top: 20px;
  padding-top: 15px;
  text-align: center;
  display: block;
}

.urllist-see-more-link {
  background: linear-gradient(to right, var(--primary-base), var(--primary-light));
  border-radius: 50px;
  color: white;
  display: inline-block;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 8px 20px;
  box-shadow: 0 3px 8px rgba(106,27,154,0.3);
  transition: all var(--transition-base);
  text-decoration: none;
}

.urllist-see-more-link:hover {
  background: linear-gradient(to right, var(--primary-light), var(--accent-base));
  box-shadow: 0 6px 12px rgba(106,27,154,0.4);
  transform: translateY(-3px);
  text-decoration: none;
}

/* ===== 9. 関連記事セクション ===== */
.related-entries {
  margin: 30px auto;
  background-color: #f9f9f9;
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.05);
  display: block;
  max-width: var(--content-width-md);
  width: 100%;
  box-sizing: border-box;
}

.related-entries-title {
  color: var(--primary-base);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid #eee;
  position: relative;
  display: block;
  text-align: left;
}

.related-entries-title::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background: linear-gradient(to right, var(--primary-base), var(--accent-base));
}

.related-entries-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: block;
  text-align: left;
}

.related-entry {
  background-color: white;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  margin-bottom: 15px;
  overflow: hidden;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  list-style-type: none;
  text-align: left;
}

.related-entry:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}

.related-entry:last-child {
  margin-bottom: 0;
}

.related-entry-thumb {
  flex: 0 0 120px;
  width: 120px;
  min-width: 120px;
  height: 80px;
  overflow: hidden;
  position: relative;
  display: block;
}

.related-entry-thumb img {
  height: 100% !important; /* 画像関連 */
  object-fit: cover !important; /* 画像関連 */
  width: 100% !important; /* 画像関連 */
  transition: transform 0.5s ease; /* 軽量化 */
  display: block;
}

.related-entry:hover .related-entry-thumb img {
  transform: scale(1.05); /* 1.12から1.05に軽量化 */
}

.related-entry-content {
  flex: 1;
  padding: 10px 15px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
}

.related-entry-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  margin: 0 0 3px 0;
  display: block;
  text-align: left;
}

.related-entry-title a {
  color: var(--text-base);
  text-decoration: none;
  text-align: left;
}

.related-entry-title a:hover {
  color: var(--primary-base);
  text-decoration: none;
}

.related-entry-date {
  color: var(--text-light);
  font-size: 0.8rem;
  display: block;
  margin-top: 2px;
  text-align: left;
}

/* ===== 10. ページネーション ===== */
.pager {
  margin: 35px auto;
  max-width: var(--content-width-md);
  display: flex;
  justify-content: space-between;
  gap: 15px;
}

.pager-prev, .pager-next {
  flex: 1;
}

.pager-prev a, .pager-next a {
  background-color: var(--card-base);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  color: var(--text-base);
  display: block;
  font-size: 0.95rem;
  padding: 15px;
  text-decoration: none;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pager-prev a {
  padding-left: 25px;
  text-align: left;
}

.pager-next a {
  padding-right: 25px;
  text-align: right;
}

.pager-prev a:hover, .pager-next a:hover {
  background-color: #f8f8f8;
  box-shadow: var(--shadow-lg);
  color: var(--primary-base);
  transform: translateY(-3px);
}

.pager-arrow {
  color: var(--primary-base);
  font-weight: bold;
}

/* ===== 11. コメント欄 ===== */
.comment-box {
  margin-top: 30px;
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
  text-align: left;
}

.leave-comment-title {
  color: var(--primary-base);
  cursor: pointer;
  display: inline-block;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 15px;
  position: relative;
  text-align: left;
}

.leave-comment-title::after {
  content: "";
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--primary-base);
  transition: width var(--transition-base);
}

.leave-comment-title:hover::after {
  width: 100%;
}

/* ===== 12. カスタムHTMLボックスの余白調整 ===== */
/* よくある質問ボックス用 - 余白縮小 */
.entry-content div[style*="background-color: #f8f9fa"][style*="border-left: 4px solid"],
.entry-content div[style*="background-color:#f8f9fa"][style*="border-left:4px solid"] {
  padding: 1em; /* 1.2emから1emに縮小 */
  margin: 1.2em 0; /* 1.5emから1.2emに縮小 */
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  text-align: left;
}

/* 質問部分の余白調整 - 縮小 */
.entry-content div[style*="border-left: 4px solid"] p[style*="font-weight: bold"],
.entry-content div[style*="border-left:4px solid"] p[style*="font-weight:bold"] {
  margin: 0.5em 0 0.2em; /* 余白縮小 */
  padding: 0.2em; /* 余白縮小 */
  background-color: #f0f4f8;
  border-radius: 3px;
  text-align: left;
}

/* 回答部分の余白増加 - 縮小 */
.entry-content div[style*="border-left: 4px solid"] div p,
.entry-content div[style*="border-left:4px solid"] div p {
  margin: 0 0 0.6em 0.8em; /* 左マージン縮小 */
  padding-left: 0.4em; /* 左パディング縮小 */
  border-left: 1px solid #e0e0e0;
  line-height: 1.7;
  text-align: left;
}

/* その他のインラインスタイルボックスにも余白を適用 - 縮小 */
.entry-content div[style*="background-color"][style*="border"],
.entry-content div[style*="background-color"][style*="padding"] {
  padding: 1em; /* 1.2emから1emに縮小 */
  margin: 1.2em 0; /* 1.5emから1.2emに縮小 */
  text-align: left;
}

/* 注意喚起系ブロック - 余白縮小 */
.entry-content div[style*="background-color: #fce8e6"],
.entry-content div[style*="background-color:#fce8e6"] {
  padding: 1em; /* 1.2emから1emに縮小 */
  text-align: left;
}

/* 補足情報系ブロック - 余白縮小 */
.entry-content div[style*="background-color: #f8f9fa"][style*="border: 1px dashed"],
.entry-content div[style*="background-color:#f8f9fa"][style*="border:1px dashed"] {
  padding: 1em; /* 1.2emから1emに縮小 */
  text-align: left;
}

/* ポイント系ブロック - 余白縮小 */
.entry-content div[style*="background-color: #e8f0fe"],
.entry-content div[style*="background-color:#e8f0fe"] {
  padding: 1em; /* 1.2emから1emに縮小 */
  text-align: left;
}

/* 引用ブロック - 余白縮小 */
.entry-content blockquote {
  padding: 0.8em; /* 1emから0.8emに縮小 */
  margin: 1.2em 0; /* 1.5emから1.2emに縮小 */
  text-align: left;
}

/* ブログに特有の要素 - 余白を適切に設定 - 縮小 */
.point-box, .success-box, .warning-box, .info-box {
  background-color: #f9f9f9;
  border-left: 4px solid;
  border-radius: var(--radius-md);
  margin: 1.2em 0; /* 1.5emから1.2emに縮小 */
  padding: 1em; /* 1.2emから1emに縮小 */
  font-size: 1.05rem;
  text-align: left;
}

.point-box {
  border-color: var(--primary-base);
  background-color: rgba(106, 27, 154, 0.05);
  position: relative;
  padding-top: 1.8em; /* 2emから1.8emに縮小 */
  text-align: left;
}

.point-box:before {
  position: absolute;
  top: 0;
  left: 0;
  background: var(--primary-base);
  color: white;
  padding: 0.2em 0.8em; /* パディング縮小 */
  font-size: 0.9em;
  font-weight: bold;
  border-radius: 0 0 5px 0;
  text-align: left;
}

.point-box p, .success-box p, .warning-box p, .info-box p {
  text-align: left;
}

.success-box {
  border-color: #28a745;
  background-color: rgba(40, 167, 69, 0.05);
  text-align: left;
}

.warning-box {
  border-color: #ffc107;
  background-color: rgba(255, 193, 7, 0.05);
  text-align: left;
}

.info-box {
  border-color: #17a2b8;
  background-color: rgba(23, 162, 184, 0.05);
  text-align: left;
}

/* ===== 13. モバイル対応 - 読みやすさ向上版 ===== */
@media (max-width: 767px) {
  /* ヘッダー */
  #blog-title {
    padding: 30px 15px;
  }
  
  #title {
    font-size: 1.8rem;
  }
  
  #blog-description {
    font-size: 0.95rem;
  }
  
  /* 記事一覧 */
  .archive-entries {
    grid-template-columns: 1fr;
    padding: 15px;
    gap: 20px;
  }
  
  .archive-entry {
    height: 250px;
  }
  
  .archive-entry-header .entry-title {
    font-size: 1.3rem;
  }
  
  /* 記事ページ - モバイル余白修正 */
  .entry {
    padding: 15px;
    margin: 0 auto 15px;
    width: 94%;
    max-width: none;
  }
  
  .entry-title {
    font-size: 1.5rem;
  }
  
  /* 本文の読みやすさ向上 */
  .entry-content {
    font-size: 1.3rem; /* 1.05remから1.3remに */
    line-height: 2; /* 1.7から2に増加して読みやすく */
    padding: 0;
    overflow-x: hidden; /* hiddenに変更 - スマホでの横スクロール防止 */
    text-align: left;
  }
  
  /* 段落の余白を増やして読みやすく */
  .entry-content p {
    margin-bottom: 1.8em; /* 1.5emから1.8emに増加 */
    line-height: 2; /* 行間を広げる */
  }
  
  /* 段落内の改行を増やす（読みやすさ向上） */
  .entry-content p br {
    display: block;
    content: "";
    margin-top: 0.8em; /* 改行に余白を追加 */
  }
  
  .entry-content h2 {
    font-size: 1.5rem;
    margin-top: 2.2em; /* 余白増加 */
    margin-bottom: 1em; /* 余白増加 */
    text-align: left;
  }
  
  .entry-content h3 {
    font-size: 1.3rem;
    margin-top: 2em; /* 余白増加 */
    margin-bottom: 0.8em; /* 余白増加 */
    text-align: left;
  }
  
  /* リストの読みやすさ向上 */
  .entry-content ul li,
  .entry-content ol li {
    margin-bottom: 0.8em; /* リスト項目間の余白拡大 */
    line-height: 1.8;
  }
  
  /* カスタムボックス - モバイルでさらに余白縮小 */
  .entry-content div[style*="background-color"][style*="border"],
  .entry-content div[style*="background-color"][style*="padding"] {
    padding: 1em;
    margin: 1.5em 0; /* 余白増加で区切りを明確に */
    text-align: left;
  }
  
  /* 回答部分の余白 - モバイルでさらに調整 */
  .entry-content div[style*="border-left: 4px solid"] div p,
  .entry-content div[style*="border-left:4px solid"] div p {
    margin: 0 0 0.8em 0.6em;
    padding-left: 0.5em;
    line-height: 1.8; /* 行間増加 */
    text-align: left;
  }
  
  /* ポイントボックス等 - 読みやすさ向上 */
  .point-box, .success-box, .warning-box, .info-box {
    padding: 1.2em; /* 内部余白拡大 */
    margin: 1.5em 0; /* 外部余白拡大 */
    font-size: 1.1rem; /* フォントサイズ拡大 */
    text-align: left;
  }
  
  .point-box p, .success-box p, .warning-box p, .info-box p {
    line-height: 1.8; /* 行間増加 */
    margin-bottom: 0.8em; /* 段落間余白 */
    text-align: left;
  }
  
  /* 目次 - モバイルでのアクセシビリティ向上 */
  ul.table-of-contents.show {
    padding: 0.8em; /* 余白拡大 */
    margin: 1.5em auto; /* 余白拡大、中央揃え維持 */
    text-align: left;
  }
  
  ul.table-of-contents.show::before {
    font-size: 1.1rem;
    padding: 0.3em;
  }
  
  ul.table-of-contents li {
    margin-bottom: 0.6em; /* 項目間隔を広げる */
  }
  
  ul.table-of-contents a {
    font-size: 1rem;
    line-height: 1.5; /* 行間を広げる */
    text-align: left;
  }
  
  ul.table-of-contents ul li a {
    font-size: 0.95rem;
    text-align: left;
  }
  
  /* モジュール */
  .hatena-module {
    padding: 20px;
  }
  
  .hatena-module-title {
    font-size: 1.15rem;
    text-align: left;
  }
  
  .urllist-image-link {
    flex: 0 0 90px;
    width: 90px;
    min-width: 90px;
    height: 60px;
  }
  
  /* 関連記事 - モバイル余白修正 */
  .related-entries {
    padding: 15px;
    margin: 15px auto;
    width: 94%;
  }
  
  .related-entry-thumb {
    flex: 0 0 80px;
    width: 80px;
    min-width: 80px;
    height: 55px;
  }
  
  .related-entry-title {
    font-size: 0.95rem;
    text-align: left;
  }
  
  /* ページネーション - モバイル余白修正 */
  .pager {
    flex-direction: column;
    margin: 25px auto;
    width: 94%;
  }
  
  .pager-prev a, .pager-next a {
    font-size: 0.9rem;
    padding: 12px;
  }
}

/* タブレット対応 - 新規追加 */
@media (min-width: 768px) and (max-width: 1023px) {
  .entry-content {
    font-size: 1.4rem; /* タブレット用の最適サイズ */
    line-height: 1.8;
  }
  
  .entry-content h2 {
    font-size: 1.7rem;
  }
  
  .entry-content h3 {
    font-size: 1.5rem;
  }
  
  .archive-entries {
    grid-template-columns: repeat(2, 1fr); /* 2列表示 */
    gap: 25px;
  }
}

/* ===== 14. パフォーマンス最適化 ===== */
/* LCP改善のためのスケルトンローディング */
@keyframes shimmer {
  0% { background-position: -300px 0; }
  100% { background-position: 300px 0; }
}

.entry-thumb.loading,
.urllist-image.loading,
.related-entry-thumb img.loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 300px 100%;
  animation: shimmer 1.5s infinite linear;
}

/* 画像がロードされる前のスペース確保（CLS対策） */
.image-placeholder {
  background-color: #f5f5f5;
  display: block;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%; /* 16:9アスペクト比 */
  position: relative;
}

/* フォント最適化 */
@font-face {
  font-family: 'Hiragino Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: local('Hiragino Sans');
}

/* アニメーション最適化 */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms;
    animation-iteration-count: 1;
    transition-duration: 0.01ms;
    scroll-behavior: auto;
  }
}

/* インアーティクル広告のみに影響するCSSリセット */
ins.adsbygoogle[data-ad-layout="in-article"] {
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 30px;
  margin-top: 30px;
  text-align: center;
  display: block;
  height: 282px; /* 固定高さに戻す */
  overflow: visible; /* オーバーフローを表示 */
}

/* インアーティクル広告のホストのみ - サイドレールには影響しない */
div[id^="aswift_"][id$="_host"]:has(+ ins.adsbygoogle[data-ad-layout="in-article"]),
ins.adsbygoogle[data-ad-layout="in-article"] div[id^="aswift_"][id$="_host"] {
  overflow: visible;
  height: 282px;
  margin: 0 auto;
  text-align: center;
}

/* 「高さ0」の問題対策 - これはそのまま残す */
ins.adsbygoogle[style*="height: 0"] {
  height: 282px; /* 固定高さに変更 */
  min-height: 250px;
}

/* ポイントボックス内の文言が中央寄せにならないようにする */
.point-box *, 
.success-box *, 
.warning-box *, 
.info-box * {
  text-align: left;
}

/* カスタムHTMLブロック内の文字位置調整 */
.entry-content div[style*="background-color"] *,
.entry-content div[style*="border"] * {
  text-align: left;
}

/* テーブルは例外として中央揃えを許可 */
table, th, td {
  text-align: inherit;
}

/* サイト全体のフォント設定 - フォントのみ変更 */
body, p, div, span, h1, h2, h3, h4, h5, h6, a, li, td, th {
  font-family: 
    "Hiragino Sans", 
    "Hiragino Kaku Gothic ProN", 
    "Noto Sans JP", 
    "Yu Gothic", 
    "YuGothic", 
    "Meiryo", 
    sans-serif;
}

/* チェックマークスタイルの修正 */
span[style*="position: absolute"][style*="left: 0"] {
  position: relative;
  left: auto;
  margin-right: 8px;
  display: inline-block;
}

/* チェックマークの位置を親要素内に収める */
p[style*="position: relative"] > span[style*="position: absolute"] {
  left: 0.5em; /* パディング内に配置 */
}

/* パフォーマンス最適化: レンダリングブロッキングの防止 */
body {
  font-display: swap;
  text-rendering: optimizeSpeed;
}

/* アクセシビリティ向上: フォーカス状態のスタイル */
a:focus, button:focus {
  outline: 2px solid var(--primary-light);
  outline-offset: 2px;
}

/* フォントサイズ、行間を改善して段落を読みやすく */
.entry-content p {
  font-size: 1.5rem;
  line-height: 1.9; 
  margin-bottom: 1.5em;
  text-align: left;
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

/* コンテンツの行の長さを制限して読みやすさ向上 */
.entry-content p,
.entry-content li {
  margin-left: auto;
  margin-right: auto;
}

/* モバイル向けの文章の可読性向上 */
@media (max-width: 767px) {
  .entry-content p::after {
    content: "";
    display: block;
    height: 0.2em; /* 段落間のスペース */
    width: 100%;
  }
}
