/* KKGS-32 Articles Stylesheet (main design system compatible) */

:root {
  --main-color: #0f172a;
  --text-sub-color: #475569;
  --text-sub-color-2: #64748b;
  --border: #e2e8f0;
  --bg: #ffffff;
  --bg-sub: #f8fafc;
  --primary: #06b6d4;
  --primary-hover: #0891b2;
}

/* 記事詳細コンテナ */
.article-page-container {
  max-width: 860px;
  margin: 0 auto;
  padding: 40px 20px 80px;
}

.article-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-sub-color-2);
  margin-bottom: 24px;
}

.article-breadcrumb a {
  color: var(--text-sub-color-2);
  text-decoration: none;
  transition: color 0.15s ease;
}

.article-breadcrumb a:hover {
  color: var(--primary);
  text-decoration: underline;
}

.article-breadcrumb span.sep {
  color: #cbd5e1;
}

/* news-post */
.news-post {
  display: grid;
  gap: 28px;
  background: #ffffff;
}

.news-post-header {
  display: grid;
  gap: 16px;
}

.news-post-text {
  display: grid;
  gap: 12px;
}

.news-post-date {
  color: var(--text-sub-color-2);
  font-family: 'JetBrains Mono', 'Roboto', 'Noto Sans JP', sans-serif;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.news-post-title {
  font-weight: 800;
  font-size: clamp(22px, 4vw, 32px);
  line-height: 1.4;
  margin: 0;
  color: var(--main-color);
  letter-spacing: -0.02em;
}

.news-post-subtitle {
  color: var(--text-sub-color);
  font-size: 16px;
  line-height: 1.7;
  border-left: 3px solid var(--primary);
  padding-left: 14px;
  margin: 4px 0 0;
}

.news-post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.category-badge,
.news-post-tag-link {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background-color: #f1f5f9;
  color: #334155;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  border: 1px solid #e2e8f0;
}

.category-badge:hover,
.news-post-tag-link:hover {
  background-color: #e0f2fe;
  color: #0284c7;
  border-color: #bae6fd;
}

/* Hero Image */
.news-post-hero {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.08);
  border: 1px solid var(--border);
}

.news-post-hero img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

/* Body */
.news-post-body {
  font-size: 16.5px;
  line-height: 1.9;
  color: #1e293b;
}

.news-post-body h2 {
  font-size: 22px;
  font-weight: 800;
  color: #0f172a;
  margin: 40px 0 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e2e8f0;
  letter-spacing: -0.01em;
}

.news-post-body h3 {
  font-size: 18.5px;
  font-weight: 700;
  color: #0f172a;
  margin: 32px 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.news-post-body h3::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 18px;
  background: var(--primary);
  border-radius: 3px;
}

.news-post-body h4 {
  font-size: 16.5px;
  font-weight: 700;
  color: #334155;
  margin: 24px 0 8px;
}

.news-post-body p {
  margin-bottom: 20px;
}

.news-post-body strong {
  font-weight: 700;
  color: #0f172a;
  background: linear-gradient(transparent 65%, #cffafe 65%);
}

.news-post-body ul,
.news-post-body ol {
  margin: 16px 0 24px;
  padding-left: 24px;
}

.news-post-body ul {
  list-style: disc;
}

.news-post-body ol {
  list-style: decimal;
}

.news-post-body li {
  margin-bottom: 8px;
}

.news-post-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14.5px;
}

.news-post-body th,
.news-post-body td {
  border: 1px solid #cbd5e1;
  padding: 10px 14px;
  text-align: left;
}

.news-post-body th {
  background: #f1f5f9;
  font-weight: 700;
  color: #0f172a;
}

.news-post-body tr:nth-child(even) td {
  background: #f8fafc;
}

/* 記事フッターナビ */
.article-footer-nav {
  margin-top: 50px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  background-color: #0f172a;
  color: #ffffff;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
}

.btn-back:hover {
  background-color: #334155;
  transform: translateY(-1px);
}

/* 一覧ページ (Articles List) */
.articles-header {
  text-align: center;
  padding: 40px 0 48px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 40px;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.article-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 32px -8px rgba(15, 23, 42, 0.12);
  border-color: #93c5fd;
}

.article-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #f1f5f9;
  overflow: hidden;
}

.article-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.article-card:hover .article-card-thumb img {
  transform: scale(1.04);
}

.article-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  gap: 10px;
}

.article-card-date {
  font-family: 'JetBrains Mono', 'Roboto', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-sub-color-2);
}

.article-card-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--main-color);
  line-height: 1.45;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-subtitle {
  font-size: 13.5px;
  color: var(--text-sub-color);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
  padding-top: 8px;
}

.article-card-tags .category-badge {
  font-size: 11px;
  padding: 2px 8px;
}
