/*
 * Globals
 */

/* CSSカスタムプロパティ */
 :root {
  /* 背景色 */
  --bs-body-bg: #000000;
  /* 本文テキストの色 */
  --bs-body-color: #CCCCCC;
  /* 区切り線の色 */
  --divider-color: rgba(255, 255, 255, 0.35);
}

/* Custom default button */
.btn-light,
.btn-light:hover,
.btn-light:focus {
  color: #333;
  text-shadow: none; /* Prevent inheritance from `body` */
}

html {
  scrollbar-gutter: stable;
}

/* 全体のフォント設定 */
body {
  font-family: "Noto Sans JP", sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

/* 見出し */
h1, h2, h3, h4, h5, h6 {
  font-family: "ヒラギノ角ゴ Pro W3", "Hiragino Kaku Gothic Pro", serif;
  font-weight: 700;
  margin-top: 1.2em;
  margin-bottom: 0.5em;
}

/* 画像やコードブロックのフォントも指定（必要に応じて） */
pre {
  font-family: "Courier New", monospace;
  font-size: 0.9em;
  text-align: center;
}

/* ヘッダーのSVG設定 */
header svg {
  /* 高さ */
  height: 25px;
  /* 横 */
  width: 40px;
  /* 色 */
  color: #FFFFFF; /* SVGカラーは currentColor なのでこれで指定可能 */
  /* カーソルあてたときの色 n秒かけて色が変わる設定 */
  transition: color 0.3s ease;
  /* 縦位置の調整 */
  transform: translateY(2px);
  /* margin-top: 5.5px; */
}

header a:hover svg {
  color: #CCCCCC;
}

/* フッターのSVG設定 */
.footer-icon {
  color: #CCCCCC;
  transition: color 0.3s ease;
}

.footer-icon:hover {
  color: #FFFFFF;
}

footer svg {
  width: 25px;
  height: 40px;
}


/*
 * Base structure
 */

body {
  /* カスタムプロパティで指定した色を呼び出して使用 */
  background-color: var(--bs-body-bg) !important;
  color: var(--bs-body-color) !important;
}

main {
  padding-top: 4rem;   /* ヘッダーとの距離 */
  padding-bottom: 4rem;
}

/* 
 * 横幅制限 baseof.htmlのdiv classで指定すれば下記が適用される
 */
.cover-container {
  max-width: 52em;
}


/*
 * Header
 */

.nav-masthead .nav-link {
  color: rgba(255, 255, 255, .5);
  border-bottom: .25rem solid transparent;
}

.nav-masthead .nav-link:hover,
.nav-masthead .nav-link:focus {
  color: #ffffffbd;
  transition: color 0.3s ease;
}

.nav-masthead .nav-link + .nav-link {
  margin-left: 1rem;
}

.nav-masthead .active {
  color: #fff;
  /* border-bottom-color: #fff; */
}

.content-narrow {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* プロフィール画像 位置調整 */
.profile-img {
  max-width: 100%;
  width: 640px;
  display: block;
  /* 中央寄せ */
  margin: 0 auto;
  /* 画像下の余白 */
  margin-bottom: 16px; 
}

figure.profile {
  text-align: center;
  margin: 0 auto;
}

figure.profile img {
  max-width: 100%;
  /* width: 640px; */
  display: block;
  /* 中央寄せ */
  margin: 0 auto;
  /* 画像下の余白 */
  margin-bottom: 16px; 
}

figure.profile figcaption {
  color: #ccc;
  font-size: 1.1rem;
}

/* プロフィールのリンクだけカスタマイズ */
.profile figcaption a {
  color: #ccc;       /* お好みの色 */
}

.profile figcaption a:hover {
  color: #fff;       /* ホバー時の色 */
}

.article-image {
  max-width: 100%;
  display: block;
  margin: 20px auto; /* 中央寄せ */
}

/* YouTube埋め込み用 */
.article-video {
  max-width: 100%;
  margin: 20px auto;     /* 画像と同じ中央寄せ */
  position: relative;
  aspect-ratio: 16 / 9; /* ← いま一番シンプルで強い */
}

/* iframe本体 */
.article-video iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
}

.post-title-link {
  text-decoration: none;
  color: #ccc;
  transition: color 0.3s ease;
  font-size: 1.4rem;
}

.post-title-link:hover {
  color: #fff;
}

.post-list {
  /* 記事一覧のレイアウト崩れたらmargin-topで調整 */
  /* margin-top: 3rem; */
  margin: auto 0;
  width: 100%;
  max-width: 800px;
}

.post-item {
  max-width: 500px;
  margin: 0 auto 2.5rem;
  text-align: center;
}

/* .post-item + .post-item {
  margin-top: 1rem;
} */

/* .post-item:first-child {
  border-top: 1px solid var(--divider-color);
  padding-top: 1.5rem; /* 線とタイトルの距離 */
/* }  */

/* 記事ページ */
.post {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  /* text-align: left; */
}

.post-header {
  margin-top: 3rem;
  margin-bottom: 2.5rem;
  text-align: center;
}

.post-title {
  /* font-size: 2rem; */
  font-weight: bold;
  margin-top: 3rem;
  margin-bottom: 0.5rem;
}

.post-date {
  font-size: 0.9rem;
  color: #999;
  margin-bottom: 1.5rem;
}

.post-divider {
  border: none;
  border-bottom: 1px solid var(--divider-color);
  opacity: 0.7;
  margin-bottom: 2rem;
}

/* 本文 */
.post-content {
  text-align: left;
  line-height: 1.8;
  font-size: 1rem;
}

.post-content p {
  margin-bottom: 1.2rem;
}

/* 記事下ナビ */
.post-nav {
  display: flex;
  gap: 1.5rem;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid #444;
  /* display: flex;
  justify-content: space-between;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid #444;
  font-size: 0.9rem; */
}

.post-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #ccc;
  text-decoration: none;
  transition: color 0.3s ease;
  /* color: #ccc;
  text-decoration: none;
  max-width: 45%; */
}

.post-nav a:hover {
  color: #fff;
}

.post-nav-prev {
  margin-left: auto;
}

.post-nav-next {
  margin-right: auto;
}

.post-nav .arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}

/* 前の記事：左へ */
.post-nav-prev:hover .arrow {
  transform: translateX(6px);
}

/* 次の記事：右へ */
.post-nav-next:hover .arrow {
  transform: translateX(-6px);
}
