/* ============================================================
   AIブレイン ブログ  共通スタイル
   色やフォントを変えたいときは、この一番上の変数だけ
   いじればサイト全体に反映されます。
   ============================================================ */
:root {
  --accent: #f3811f;          /* テーマカラー（オレンジ）*/
  --accent-dark: #c4640f;
  --ink: #e9e7e3;             /* 本文の文字色（暗い背景に映える明るめ）*/
  --sub: #9a9690;             /* 補助テキスト（日付など）*/
  --line: #32302c;            /* 区切り線 */
  --bg: #16140f;             /* 全体の背景（暗め）*/
  --bg-soft: #211e18;        /* 少し明るい背景（カード・リード）*/
  --max: 1080px;              /* コンテンツの最大幅 */
  --radius: 10px;
  --font: "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

/* ---------- ヘッダー ---------- */
.site-header {
  border-bottom: 3px solid var(--accent);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand { display: flex; align-items: baseline; gap: 10px; }
.brand .logo {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: .02em;
}
.brand .logo b { color: var(--accent); }
.brand .tagline { font-size: .78rem; color: var(--sub); }

.nav { display: flex; gap: 18px; font-size: .9rem; font-weight: 600; }
.nav a { padding: 4px 2px; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--accent); border-color: var(--accent); }

/* ---------- 共通レイアウト ---------- */
.container { max-width: var(--max); margin: 0 auto; padding: 28px 20px; }

.section-title {
  font-size: 1.05rem;
  font-weight: 800;
  margin: 0 0 16px;
  padding-left: 12px;
  border-left: 5px solid var(--accent);
}

/* ---------- ヒーロー（注目記事）---------- */
.hero {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 24px;
  align-items: center;
  background: var(--bg-soft);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 12px;
}
.hero .thumb {
  aspect-ratio: 16 / 10;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #2a241a, #f3811f);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 1.1rem; text-align: center; padding: 20px;
}
.hero h2 { font-size: 1.6rem; line-height: 1.45; margin: 8px 0 12px; }
.hero p { color: var(--ink); margin: 0 0 14px; }

/* ---------- 記事カード一覧 ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg);
  transition: transform .15s ease, box-shadow .15s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0,0,0,.08); }
.card .thumb {
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #2a241a, #6b5a3c);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: .95rem; text-align: center; padding: 14px;
}
.card .body { padding: 14px 16px 18px; }
.card h3 { font-size: 1.02rem; line-height: 1.5; margin: 6px 0 8px; }
.card .excerpt { font-size: .85rem; color: var(--sub); margin: 0; }

/* ---------- メタ情報（カテゴリ・日付）---------- */
.tag {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  color: #fff;
  background: var(--accent);
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: .03em;
}
.date { font-size: .76rem; color: var(--sub); }
.meta-row { display: flex; align-items: center; gap: 10px; }

/* ---------- 記事ページ本文 ---------- */
.article {
  max-width: 720px;
  margin: 0 auto;
  padding: 28px 20px 60px;
}
.article .headline {
  font-size: 1.9rem;
  font-weight: 800;
  line-height: 1.45;
  margin: 14px 0 10px;
}
.article .lead {
  font-size: 1.05rem;
  color: var(--ink);
  background: var(--bg-soft);
  border-left: 4px solid var(--accent);
  padding: 14px 18px;
  border-radius: 0 8px 8px 0;
  margin: 18px 0 28px;
}
.article h2 {
  font-size: 1.3rem;
  margin: 38px 0 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--line);
}
.article h3 { font-size: 1.1rem; margin: 26px 0 10px; }
.article p { margin: 0 0 18px; }
.article figure { margin: 24px 0; }
.article figcaption { font-size: .8rem; color: var(--sub); text-align: center; margin-top: 6px; }
.article blockquote {
  margin: 22px 0; padding: 12px 18px;
  background: var(--bg-soft); border-left: 4px solid var(--accent);
  color: var(--ink); border-radius: 0 8px 8px 0;
}
.byline {
  display: flex; align-items: center; gap: 12px;
  color: var(--sub); font-size: .85rem;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 12px 0; margin: 22px 0 30px;
}

/* ---------- インタビュー（対話）形式 ---------- */
.qa { margin: 0 0 22px; }
.qa .speaker {
  display: inline-block;
  font-size: .76rem; font-weight: 700;
  padding: 2px 9px; border-radius: 4px;
  margin-bottom: 6px;
}
.qa.q .speaker { color: var(--accent); border: 1px solid var(--accent); }   /* 聞き手＝クロード */
.qa.a .speaker { color: #fff; background: var(--accent); }                  /* 答える人＝ケン */
.qa.q p { color: var(--sub); margin: 0; font-weight: 600; }                 /* 質問は控えめに */
.qa.a p { color: var(--ink); margin: 0; }                                   /* 回答はしっかり */
.qa.a { border-left: 3px solid var(--line); padding-left: 16px; }
.back-link { display: inline-block; margin-top: 30px; color: var(--accent); font-weight: 700; }
.back-link:hover { text-decoration: underline; }

/* ---------- フッター ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  margin-top: 40px;
}
.footer-inner {
  max-width: var(--max); margin: 0 auto; padding: 26px 20px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
  color: var(--sub); font-size: .82rem;
}

/* ---------- スマホ対応 ---------- */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .nav { display: none; }
}
@media (max-width: 540px) {
  .card-grid { grid-template-columns: 1fr; }
  .hero h2 { font-size: 1.35rem; }
  .article .headline { font-size: 1.5rem; }
}
