/* =========================================================
   articles.css
   読み物・記事ページ専用
   Flat / stylish / PETTE style
   ========================================================= */

/* =========================
   Layout
   ========================= */

.article-page {
  padding-bottom: 8px;
}

.article {
  display: block;
}

/* 記事全体を1つのカードに */
.article-card {
  background: var(--bg-card);
  border: 1px solid rgba(226,232,240,0.95);
  border-radius: 22px;
  padding: 22px 18px 24px;
  box-shadow: 0 10px 28px rgba(15,23,42,0.045);
}

/* =========================
   Hero
   ========================= */

.article-hero {
  margin: 0;
}

.article-title {
  align-items: flex-start;
  margin: 0 0 14px;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.45;
  letter-spacing: -0.035em;
  color: var(--text-main);
}

.article-title .material-symbols-rounded {
  margin-top: 7px;
  font-size: 22px;
  color: var(--accent-main-deep);
  flex: 0 0 auto;
}

.article-lead {
  margin: 0;
  font-size: 14px;
  line-height: 2;
  color: #4b5563;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
  color: var(--text-soft);
  font-size: 12px;
}

.article-meta span {
  display: inline-flex;
  align-items: center;
}

.article-meta span + span::before {
  content: "";
  width: 4px;
  height: 4px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--text-soft);
}

/* =========================
   TOC
   ========================= */

.article-toc {
  margin: 20px 0 34px;
  padding: 14px 16px;
  background: #fbfcfd;
  border: 1px solid #edf0f3;
  border-radius: 16px;
  opacity: 0.95;
}

.article-toc-title {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 900;
  color: var(--text-main);
}

.article-toc ol {
  margin: 0;
  padding-left: 20px;
  font-size: 13px;
  line-height: 1.9;
  color: var(--text-muted);
}

.article-toc li + li {
  margin-top: 4px;
}

.article-toc a {
  color: var(--text-muted);
  text-decoration: none;
}

.article-toc a:hover {
  color: var(--accent-main-deep);
  text-decoration: underline;
}

/* =========================
   Body
   ========================= */

.article-section {
  margin-top: 36px;
}

.article-section:first-of-type {
  margin-top: 0;
}

.article-section h2 {
  position: relative;
  margin: 0 0 16px;
  padding-left: 16px;
  font-size: 21px;
  font-weight: 900;
  line-height: 1.45;
  letter-spacing: -0.025em;
  color: var(--text-main);
}

.article-section h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: .36em;
  width: 5px;
  height: 1.25em;
  border-radius: 999px;
  background: var(--accent-main);
}

.article-section h3 {
  margin: 24px 0 9px;
  font-size: 16px;
  font-weight: 900;
  line-height: 1.55;
  color: var(--text-main);
}

.article-section p {
  margin: 0;
  font-size: 14px;
  line-height: 2.05;
  color: #4b5563;
}

.article-section p + p {
  margin-top: 13px;
}

.article-section ul,
.article-section ol {
  margin: 12px 0 0;
  padding-left: 20px;
  font-size: 14px;
  line-height: 2;
  color: #4b5563;
}

.article-section li + li {
  margin-top: 5px;
}

.article-section a {
  color: var(--accent-main-deep);
  text-decoration: none;
}

.article-section a:hover {
  text-decoration: underline;
}

/* =========================
   Note
   ========================= */

.article-note {
  margin-top: 18px;
  padding: 13px 15px;
  background: #f8fafc;
  border-left: 5px solid var(--accent-main);
  border-radius: 0 14px 14px 0;
}

.article-note p {
  margin: 0;
  font-size: 13px;
  line-height: 1.9;
  color: #4b5563;
}

/* =========================
   PETTE tip
   ========================= */

.article-tip-section {
  margin-top: 34px;
}

.article-tip {
  margin-top: 0;
}

/* =========================
   CTA
   ========================= */

.article-cta-section {
  margin-top: 38px;
}

.article-cta {
  padding: 18px 16px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-border);
  border-radius: 18px;
}

.article-cta h2 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.45;
  color: var(--text-main);
}

.article-cta p {
  margin: 0 0 14px;
  font-size: 14px;
  line-height: 1.85;
  color: #4b5563;
}

.article-cta .btn {
  width: 100%;
}

.article-cta .material-symbols-rounded {
  font-size: 18px;
  line-height: 1;
}

/* =========================
   Related
   ========================= */

.article-related {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border-soft);
}

.article-related h2 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 900;
  color: var(--text-main);
}

.article-related ul {
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
  line-height: 1.9;
  color: var(--text-muted);
}

.article-related li + li {
  margin-top: 4px;
}

.article-related a {
  color: var(--accent-main-deep);
  text-decoration: none;
}

.article-related a:hover {
  text-decoration: underline;
}

/* =========================
   Utility
   ========================= */

html {
  scroll-behavior: smooth;
}

/* =========================
   Desktop
   ========================= */

@media (min-width: 768px) {
  .article-card {
    padding: 34px 38px 38px;
  }

  .article-title {
    font-size: 28px;
  }

  .article-lead {
    font-size: 15px;
  }

  .article-toc {
    margin-bottom: 40px;
  }

  .article-section {
    margin-top: 44px;
  }

  .article-section h2 {
    font-size: 23px;
  }

  .article-section h3 {
    font-size: 17px;
  }

  .article-section p,
  .article-section ul,
  .article-section ol {
    font-size: 15px;
  }

  .article-cta {
    padding: 20px 18px;
  }

  .article-cta .btn {
    width: auto;
  }
}

.article-cover {
  margin: 20px -12px 14px;
}

.article-cover img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px 16px 0 0;
  border: none;
}

@media (min-width: 768px) {
  .article-cover {
    margin-left: -16px;
    margin-right: -16px;
  }
}

/* =========================
   Article List（一覧ページ専用）
   ========================= */

.article-list {
  display: grid;
  gap: 16px;
  margin-top: 18px;
  grid-template-columns: repeat(auto-fit, minmax(300px, 480px));
  justify-content: center;
}

/* タップ領域 */
.article-list-link {
  text-decoration: none;
  color: inherit;
}

/* カード */
.article-list-card {
  background: #fff;
  border-radius: 16px;
  border: 1px solid var(--border-soft);
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease;
  box-shadow: 0 4px 12px rgba(15,23,42,0.04);
}

/* ホバー */
.article-list-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15,23,42,0.06);
}

.article-list-cover {
  aspect-ratio: 1200 / 630;
  background: #f3f7fb;
  overflow: hidden;
}

.article-list-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  object-position: center 55%;
}
/* テキスト */
.article-list-body {
  padding: 16px;
}

.article-list-title {
  font-size: 16px;
  font-weight: 800;
  margin: 0 0 8px;
  line-height: 1.5;
}

.article-list-desc {
  font-size: 14px;
  line-height: 1.8;
  color: #6b7280;
  margin: 0;
}

/* PC広め */
@media (min-width: 1024px) {
  .article-list {
    gap: 20px;
    grid-template-columns: repeat(2, minmax(320px, 480px));
  }
}