@charset "UTF-8";

/* =========================
   Single Post Layout
========================= */
main.single-post {
  text-align: center;
  background: #f0f8ff;
  min-height: 70vh;
  padding: 60px 24px;        /* ← 追加：上下左右の余白 */
}

/* タイトル */
.single-post h1 {
  color: #6594B1;
  font-size: clamp(20px, 4vw, 28px);  /* ← 変更：画面幅に応じて自動スケール */
  margin-bottom: 40px;
  line-height: 1.6;
  font-weight: bold;
}

/* 本文 */
main.single-post p {
  max-width: 680px;
  margin: 0 auto 20px;
  text-align: left;
  line-height: 1.9;
  color: #333;
  word-break: break-word;    /* ← 追加：長いURLなどのはみ出し防止 */
  overflow-wrap: break-word; /* ← 追加 */
}

/* =========================
   投稿ナビゲーション
========================= */
.post-navigation {
  margin-top: 80px;
  padding-top: 40px;
  border-top: 1px solid #E2D6DE;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  font-size: 14px;
  letter-spacing: 0.1em;
  flex-wrap: wrap;           /* ← 追加：狭い画面で折り返す */
}

/* 前・次 */
.prev-post a,
.next-post a {
  text-decoration: none;
  color: #6594B1;
  transition: all 0.3s ease;
}

.prev-post a:hover,
.next-post a:hover {
  opacity: 0.7;
}

/* 一覧ボタン */
.back-to-list a {
  display: inline-block;
  padding: 12px 36px;
  border: 2px solid #E2D6DE;
  color: #6594B1;
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.12em;
  transition: all 0.3s ease;
  background: #FFFFFF;
}

.back-to-list a:hover {
  background: #DDAED3;
  color: #FFFFFF;
}
/* =========================
   Responsive — Desktop (〜1024px)
========================= */
@media (max-width: 1024px) {
  main.single-post {
    padding: 50px 40px;      /* 左右に余裕を持たせる */
  }

  .single-post h1 {
    font-size: clamp(22px, 3.5vw, 28px);
  }

  main.single-post p {
    max-width: 620px;        /* 横幅を少し狭める */
  }

  .post-navigation {
    gap: 32px;
  }
}

/* =========================
   Responsive — Tablet (〜768px)  ← 既存
========================= */
@media (max-width: 768px) {
  main.single-post {
    padding: 40px 20px;
  }

  .post-navigation {
    margin-top: 56px;
    gap: 24px;
  }

  .back-to-list a {
    padding: 10px 28px;
  }
}

/* =========================
   Responsive — Mobile (〜480px)  ← 既存
========================= */
@media (max-width: 480px) {
  main.single-post {
    padding: 32px 16px;
  }

  .post-navigation {
    flex-direction: column;
    gap: 16px;
    margin-top: 40px;
    padding-top: 28px;
  }

  .back-to-list {
    order: -1;
  }

  .back-to-list a {
    padding: 10px 24px;
    font-size: 12px;
    min-width: 140px;
    text-align: center;
  }

  .prev-post a,
  .next-post a {
    font-size: 13px;
  }
}