/* =========================================================
   営農型太陽光発電レポート ブログ固有スタイル
   ※ヘッダー/フッター/ナビのスタイルは ../styles.css を使用
   ========================================================= */

/* ---------- ブログ共通 ---------- */
.blog-page-title {
  max-width: 1160px;
  margin: 0 auto;
  padding: 2.2rem 1.2rem 0.4rem;
}

.blog-page-title h1 {
  font-size: clamp(1.5rem, 3.4vw, 2.1rem);
  padding-bottom: 0.5rem;
  border-bottom: 5px solid;
  border-image: repeating-linear-gradient(90deg, var(--green-500) 0 26px, var(--sun-500) 26px 36px) 1;
  display: inline-block;
}

.blog-page-title p {
  color: var(--muted);
  font-size: 0.92rem;
  margin-top: 0.6rem;
}

/* ---------- 記事一覧（index） ---------- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.6rem;
  margin: 1.4rem 0 2.4rem;
}

.blog-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 26px rgba(46, 112, 49, 0.2);
}

.blog-thumbnail {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.blog-content {
  padding: 1.2rem 1.3rem 1.4rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.blog-content h2 {
  font-size: 1.08rem;
  margin-bottom: 0.4rem;
  line-height: 1.5;
}

.blog-content h2 a {
  color: var(--green-900);
}

.blog-content h2 a:hover {
  color: var(--sun-600);
}

.blog-content time {
  font-size: 0.8rem;
  color: var(--sun-600);
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: block;
}

.article-summary {
  font-size: 0.88rem;
  color: var(--muted);
  flex: 1;
  margin-bottom: 0.8rem;
}

.read-more {
  align-self: flex-start;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--green-700);
  border: 2px solid var(--green-500);
  border-radius: 999px;
  padding: 0.35rem 1.1rem;
}

.read-more:hover {
  background: var(--green-700);
  border-color: var(--green-700);
  color: var(--white);
}

/* ---------- 記事ページ ---------- */
.article-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.9rem 2rem;
  box-shadow: var(--shadow);
}

.article-header h1 {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  margin-bottom: 0.7rem;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.2rem;
  align-items: center;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 1.2rem;
}

.article-meta .meta-tag {
  background: var(--green-100);
  color: var(--green-700);
  font-weight: 700;
  border-radius: 999px;
  padding: 0.15rem 0.8rem;
}

.article-hero {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 1.4rem;
  display: block;
}

.article-content h2 {
  font-size: 1.25rem;
  margin: 2rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 4px solid;
  border-image: repeating-linear-gradient(90deg, var(--green-500) 0 26px, var(--sun-500) 26px 36px) 1;
}

.article-content h3 {
  font-size: 1.05rem;
  margin: 1.4rem 0 0.6rem;
  padding-left: 0.7rem;
  border-left: 5px solid var(--sun-500);
}

.article-content p {
  margin-bottom: 1rem;
}

.article-content ul,
.article-content ol {
  margin: 0 0 1rem 0.3rem;
}

.article-content li {
  margin-bottom: 0.35rem;
}

/* ---------- シェアボタン ---------- */
.share-box {
  margin-top: 2rem;
  padding-top: 1.2rem;
  border-top: 1px dashed var(--line);
}

.share-box .share-label {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--green-900);
  margin-bottom: 0.6rem;
  display: block;
}

.share-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.share-buttons a {
  display: inline-block;
  padding: 0.45rem 1.2rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--white);
}

.share-x {
  background: #1a1a1a;
}

.share-facebook {
  background: #1877f2;
}

.share-hatena {
  background: #00a4de;
}

.share-buttons a:hover {
  opacity: 0.8;
  color: var(--white);
}

/* ---------- 記事フッターナビ ---------- */
.article-nav {
  margin-top: 1.6rem;
  display: flex;
  justify-content: center;
}

.article-nav a {
  background: var(--white);
  border: 2px solid var(--green-500);
  border-radius: 999px;
  padding: 0.55rem 1.6rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--green-700);
}

.article-nav a:hover {
  background: var(--green-700);
  border-color: var(--green-700);
  color: var(--white);
}

/* ---------- レスポンシブ ---------- */
@media (max-width: 760px) {
  .blog-grid {
    grid-template-columns: 1fr;
  }

  .article-card {
    padding: 1.3rem 1.1rem;
  }
}

/* Mobile news-commentary readability baseline (shared site-local rule). */
@media (max-width: 768px) {
  .blog-main, .blog-container, .two-col-layout { min-width: 0; }
  .article-detail, .blog-article, .article-body { min-width: 0; }
  .article-detail .article-body, .blog-article { padding-inline: 16px; }
  .article-content {
    font-size: 1rem;
    line-height: 1.85;
    overflow-wrap: anywhere;
  }
  .article-content h2 { font-size: clamp(1.25rem, 6vw, 1.45rem); line-height: 1.4; }
  .article-content h3 { font-size: clamp(1.12rem, 5vw, 1.25rem); line-height: 1.45; }
  .article-content :is(img, iframe, video) { max-width: 100%; height: auto; }
  .article-content table { display: block; max-width: 100%; overflow-x: auto; }
  .sidebar, .blog-sidebar { position: static; order: 2; }
}
/* Mobile article reading width: keep outer page gutters, remove duplicated inner gutters. */
@media (max-width: 768px) {
  .article-content,
  .article-detail .article-body,
  .blog-article,
  .main-content > article.main-content {
    padding-left: 0;
    padding-right: 0;
  }
  /* Cap article-panel padding without removing deliberate card framing. */
  .article-panel,
  .article-main,
  .post-content,
  .article-detail {
    padding-left: min(16px, 4vw);
    padding-right: min(16px, 4vw);
  }
  .article-body { padding-left: 0; padding-right: 0; }
}
