/* SDGs総合情報サイト - ブログ専用スタイル */

:root {
  --primary-color: #00a0dc;
  --secondary-color: #56c02b;
  --accent-color: #fd6925;
  --text-dark: #2c3e50;
  --text-light: #5a6c7d;
  --bg-light: #f8f9fa;
  --bg-white: #ffffff;
  --border-color: #e1e8ed;
  --transition: all 0.3s ease;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.16);
  --gradient-primary: linear-gradient(135deg, #00a0dc 0%, #56c02b 100%);
  --gradient-accent: linear-gradient(135deg, #fd6925 0%, #fbb03b 100%);
}

/* ブログ一覧ページ */
.blog-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
}

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

.blog-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

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

.blog-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-content h2 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.blog-content h2 a {
  color: var(--text-dark);
  text-decoration: none;
  transition: color 0.3s;
}

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

.blog-content time {
  display: block;
  color: var(--text-light);
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
}

.article-summary {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1rem;
  flex-grow: 1;
}

.read-more {
  display: inline-block;
  color: var(--primary-color);
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s;
  font-size: 0.95rem;
}

.read-more:hover {
  color: var(--secondary-color);
  transform: translateX(4px);
}

/* ブログ記事ページ - 2カラムレイアウト */
.blog-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 3rem;
  align-items: start;
}

/* メインコンテンツ */
.blog-main-content {
  background: var(--bg-white);
  border-radius: 8px;
  overflow: hidden;
}

.blog-hero-image {
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
}

.blog-article-header {
  padding: 2rem;
  background: var(--bg-white);
}

.blog-article-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dark);
  line-height: 1.3;
}

.post-meta {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-light);
  padding-bottom: 1.5rem;
  border-bottom: 2px solid var(--border-color);
}

.post-meta time {
  color: var(--text-light);
}

.post-meta .category {
  background: var(--gradient-primary);
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  color: white;
}

.article-intro {
  background: var(--bg-light);
  border-left: 4px solid var(--primary-color);
  padding: 1.5rem;
  margin: 2rem;
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-dark);
}

.blog-main-content article {
  padding: 0 2rem 2rem;
}

.blog-main-content h2 {
  font-size: 1.75rem;
  font-weight: 600;
  margin: 2.5rem 0 1.25rem;
  color: var(--text-dark);
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.blog-main-content h3 {
  font-size: 1.35rem;
  font-weight: 600;
  margin: 2rem 0 1rem;
  color: var(--text-dark);
}

.blog-main-content p {
  margin-bottom: 1.25rem;
  line-height: 1.8;
  color: var(--text-light);
}

.blog-main-content ul {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.blog-main-content li {
  margin-bottom: 0.75rem;
  line-height: 1.7;
  color: var(--text-light);
}

.blog-main-content strong {
  color: var(--text-dark);
  font-weight: 600;
}

/* ソーシャルシェアボタン */
.social-share {
  display: flex;
  gap: 1rem;
  margin: 2rem 0;
  padding: 1.5rem;
  background: var(--bg-light);
  border-radius: 8px;
  align-items: center;
}

.social-share span {
  font-weight: 600;
  color: var(--text-dark);
}

.social-share a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: var(--transition);
  color: white;
}

.social-share .twitter {
  background: #1da1f2;
}

.social-share .twitter:hover {
  background: #0d8bd9;
}

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

.social-share .facebook:hover {
  background: #0c63d4;
}

/* 広告バナー */
.ad-banner {
  background: var(--bg-light);
  border: 1px dashed var(--border-color);
  border-radius: 8px;
  padding: 2rem;
  text-align: center;
  margin: 2rem 0;
  color: #a0aec0;
}

/* サイドバー */
.blog-sidebar {
  position: sticky;
  top: 100px;
}

/* 目次 */
.toc {
  background: var(--bg-white);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-sm);
}

.toc h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-dark);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
}

.toc ul {
  list-style: none;
  padding: 0;
}

.toc > ul > li {
  margin-bottom: 0.75rem;
}

.toc a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.95rem;
  line-height: 1.6;
  transition: color 0.3s;
  display: block;
  padding: 0.25rem 0;
}

.toc a:hover {
  color: var(--primary-color);
}

.toc ul ul {
  padding-left: 1rem;
  margin-top: 0.5rem;
}

.toc ul ul li {
  margin-bottom: 0.5rem;
}

.toc ul ul a {
  font-size: 0.875rem;
  color: var(--text-light);
}

/* 広告スペース */
.ad-space {
  background: var(--bg-light);
  border: 1px dashed var(--border-color);
  border-radius: 8px;
  padding: 1.5rem;
  text-align: center;
  margin-bottom: 2rem;
  color: #a0aec0;
}

.ad-space h4 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--text-light);
}

/* 関連記事 */
.related-articles {
  background: var(--bg-white);
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}

.related-articles h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-dark);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
}

.related-articles ul {
  list-style: none;
  padding: 0;
}

.related-articles li {
  margin-bottom: 0.75rem;
}

.related-articles a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.9rem;
  line-height: 1.5;
  transition: color 0.3s;
  display: block;
}

.related-articles a:hover {
  color: var(--primary-color);
}

/* レスポンシブ対応 */
@media (max-width: 968px) {
  .blog-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .blog-sidebar {
    position: static;
    order: -1;
  }

  .blog-list {
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
  }

  .blog-article-header h1 {
    font-size: 1.75rem;
  }
}

@media (max-width: 768px) {
  .blog-container {
    padding: 1rem;
  }

  .blog-main-content article {
    padding: 0 1rem 1.5rem;
  }

  .article-intro {
    margin: 1.5rem 1rem;
    padding: 1.25rem;
  }

  .blog-main-content h2 {
    font-size: 1.5rem;
  }

  .blog-main-content h3 {
    font-size: 1.2rem;
  }

  .blog-list {
    grid-template-columns: 1fr;
  }

  .blog-thumbnail {
    height: 200px;
  }

  .social-share {
    flex-direction: column;
    align-items: stretch;
  }

  .social-share a {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .blog-hero-image {
    aspect-ratio: 4/3;
  }

  .blog-article-header h1 {
    font-size: 1.5rem;
  }

  .post-meta {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .blog-article-header {
    padding: 1.5rem;
  }
}

/* ===================================
   ヘッダー・フッタースタイル
   (public/sdgs/styles.cssから抽出)
   =================================== */

/* Header Styles */
header {
  background: var(--bg-white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  transition: var(--transition);
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: var(--text-dark);
}

.logo-icon {
  width: 50px;
  height: 50px;
  background: var(--gradient-primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
  box-shadow: var(--shadow-sm);
}

.logo-text h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.logo-text p {
  font-size: 0.85rem;
  color: var(--text-light);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 1.5rem;
  align-items: center;
  flex-wrap: wrap;
  max-width: 900px;
  justify-content: center;
}

.nav-item a {
  font-weight: 500;
  color: var(--text-dark);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  transition: var(--transition);
  font-size: 0.95rem;
  white-space: nowrap;
  text-decoration: none;
}

.nav-item a:hover,
.nav-item a.active,
.nav-item.active a {
  background: var(--gradient-primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}

.hamburger span {
  width: 28px;
  height: 3px;
  background: var(--text-dark);
  border-radius: 2px;
  transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

/* Footer */
footer {
  background: var(--text-dark);
  color: white;
  padding: 3rem 2rem 2rem;
  margin-top: 4rem;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  color: var(--secondary-color);
}

.footer-section p,
.footer-section a {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  line-height: 1.8;
  display: block;
  margin-bottom: 0.5rem;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--secondary-color);
  padding-left: 0.5rem;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 0.9rem;
  color: rgba(255,255,255,0.6);
}

/* Responsive Design for Header/Footer */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--bg-white);
    flex-direction: column;
    padding: 6rem 2rem 2rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    gap: 0;
    max-width: none;
    align-items: flex-start;
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-item {
    width: 100%;
    border-bottom: 1px solid var(--border-color);
  }

  .nav-item a {
    display: block;
    width: 100%;
    padding: 1rem;
    border-radius: 0;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

@media (max-width: 480px) {
  .logo-text h1 {
    font-size: 1.2rem;
  }

  .logo-icon {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }
}
