/* ==========================================================================
   CoreStation Article Dedicated Styles (High-Contrast White-Canvas Theme)
   Design: Calm, High-Legibility, Professional Editorial Style
   Theme: Neutral White & Slate (#0f172a / #ffffff) + Steel Blue Accent (#1e40af)
   Accessibility: WCAG 2.1 AA / AAA Contrast Compliant
   ========================================================================== */

body.article-page-body {
  background-color: #f8fafc;
  color: #0f172a;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}

/* Header Navigation Bar */
.article-header-nav {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 12px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.article-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #0f172a;
  font-weight: 700;
  font-size: 1.15rem;
}

.article-brand img {
  width: 32px;
  height: 32px;
}

.article-nav-links {
  display: flex;
  gap: 16px;
  align-items: center;
}

.article-nav-links a {
  color: #475569;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: color 0.15s ease;
}

.article-nav-links a:hover {
  color: #1e40af;
}

/* Main Container & Breadcrumbs */
.article-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 24px;
}

.breadcrumb a {
  color: #1e40af;
  text-decoration: none;
  font-weight: 500;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.breadcrumb span.sep {
  color: #94a3b8;
}

/* Main Article Card */
.article-card-main {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 40px 48px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.04), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
}

@media (max-width: 640px) {
  .article-card-main {
    padding: 24px 18px;
    border-radius: 8px;
  }
}

.article-meta-header {
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 24px;
  margin-bottom: 32px;
}

.article-badge {
  display: inline-block;
  background: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 6px;
  margin-bottom: 14px;
}

.article-main-title {
  font-size: 1.85rem;
  font-weight: 800;
  line-height: 1.45;
  color: #0f172a;
  margin: 0 0 16px;
  letter-spacing: -0.015em;
}

@media (max-width: 640px) {
  .article-main-title {
    font-size: 1.45rem;
  }
}

.article-submeta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.88rem;
  color: #64748b;
  font-weight: 500;
}

/* Typography & Content Body */
.article-content-body {
  color: #1e293b;
  font-size: 1.05rem;
  line-height: 1.95;
}

.article-content-body h2 {
  color: #0f172a;
  font-size: 1.45rem;
  font-weight: 700;
  margin-top: 48px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.article-content-body h3 {
  color: #1e40af;
  font-size: 1.25rem;
  font-weight: 700;
  margin-top: 36px;
  margin-bottom: 14px;
}

.article-content-body h4 {
  color: #0f172a;
  font-size: 1.1rem;
  font-weight: 700;
  margin-top: 24px;
  margin-bottom: 10px;
}

.article-content-body p {
  margin-top: 0;
  margin-bottom: 1.6em;
  color: #1e293b;
}

.article-content-body strong {
  color: #0f172a;
  font-weight: 700;
}

.article-content-body ul, .article-content-body ol {
  margin: 12px 0 24px 24px;
  padding-left: 0;
}

.article-content-body li {
  margin-bottom: 8px;
  color: #1e293b;
}

.article-content-body a {
  color: #1d4ed8;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
  transition: color 0.15s ease;
}

.article-content-body a:hover {
  color: #1e40af;
}

/* Tables in Articles */
.article-content-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 28px 0;
  font-size: 0.95rem;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #cbd5e1;
}

.article-content-body th, .article-content-body td {
  padding: 12px 16px;
  border: 1px solid #cbd5e1;
  text-align: left;
}

.article-content-body th {
  background: #f1f5f9;
  color: #0f172a;
  font-weight: 700;
  border-bottom: 2px solid #94a3b8;
}

.article-content-body td {
  background: #ffffff;
  color: #1e293b;
}

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

/* Code Blocks & Inline Code */
.article-content-body code {
  font-family: var(--font-mono, SFMono-Regular, Menlo, Monaco, Consolas, monospace);
  font-size: 0.88em;
  background: #f1f5f9;
  color: #0f172a;
  padding: 3px 6px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

.article-content-body pre {
  background: #0f172a;
  color: #f8fafc;
  padding: 16px 20px;
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.9rem;
  line-height: 1.6;
  border: 1px solid #334155;
  margin: 20px 0;
}

.article-content-body pre code {
  background: transparent;
  color: inherit;
  padding: 0;
  border: none;
  font-size: inherit;
}

/* Author Profile Card */
.article-author-card {
  margin-top: 48px;
  padding: 24px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.article-author-card img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2px solid #1e40af;
  object-fit: cover;
}

.article-author-card strong {
  font-size: 1.15rem;
  color: #0f172a;
}

.article-author-card p {
  font-size: 0.92rem;
  color: #475569;
  line-height: 1.6;
  margin: 0;
}

/* Bottom Navigation Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1e40af;
  color: #ffffff !important;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none !important;
  border: 1px solid transparent;
  transition: all 0.15s ease;
}

.btn-primary:hover {
  background: #1d4ed8;
  color: #ffffff !important;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  color: #334155 !important;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none !important;
  border: 1px solid #cbd5e1;
  transition: all 0.15s ease;
}

.btn-secondary:hover {
  background: #f1f5f9;
  color: #0f172a !important;
  border-color: #94a3b8;
}

/* Bottom CTA & Related Articles */
.article-bottom-cta {
  margin-top: 48px;
  padding: 28px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  text-align: center;
}

.article-bottom-cta h3 {
  margin-top: 0;
  color: #1e40af;
  font-size: 1.3rem;
  font-weight: 700;
}

.article-bottom-cta p {
  color: #334155;
  font-size: 0.95rem;
}

.article-related-section {
  margin-top: 48px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.related-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 18px;
  text-decoration: none !important;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all 0.15s ease;
}

.related-card:hover {
  border-color: #1e40af;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  transform: translateY(-2px);
}

.related-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.45;
  margin-bottom: 8px;
}

.related-card-date {
  font-size: 0.78rem;
  color: #64748b;
}

/* Footer */
.article-footer {
  border-top: 1px solid #e2e8f0;
  padding: 32px 20px;
  margin-top: 64px;
  text-align: center;
  font-size: 0.88rem;
  color: #64748b;
  background: #ffffff;
}

.article-footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.article-footer-links a {
  color: #475569;
  text-decoration: none;
  font-weight: 500;
}

.article-footer-links a:hover {
  color: #1e40af;
}
