/* h1: ページタイトル */
h1 {
  font-size: 1.75rem;
  font-weight: 900;
  color: var(--text-main);
  border-bottom: 2px solid var(--line-gold-hi);
  padding-bottom: 0.65rem;
  margin: 1.8rem 0 1.4rem 0;
  line-height: 1.5;
  letter-spacing: 0.02em;
}

/* ============================================
   見出しデザイン h2-h6 
   (h2:スラッシュ / h3:黄色マーカー[span対応] / 全見出し折り返し対応)
   ============================================ */

/* 共通設定：すべての見出しで折り返しを有効化 */
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* h2: ゴールド左ボーダー */
h2 {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--text-main);
  padding: 0.65rem 1.2rem;
  margin: 2.5rem 0 1.2rem 0;
  background-image: none;
  background: linear-gradient(90deg, rgba(245,184,0,0.07) 0%, transparent 70%);
  border-left: 5px solid var(--gold);
  border-bottom: none;
  width: auto;
  line-height: 1.5;
  font-family: var(--font-base);
}

/* ライトモード時はゴールドアクセントを強調 */
:root[data-theme="light"] h2 {
  background: linear-gradient(90deg, rgba(245,184,0,0.18) 0%, transparent 70%);
}

/* h3: マゼンタ左ライン */
h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 2rem 0 1rem 0;
  border: none;
  padding-left: 1rem;
  position: relative;
  line-height: 1.7;
}

h3::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.25em;
  bottom: 0.25em;
  width: 3px;
  background: var(--magenta);
  border-radius: 2px;
}

h3 span {
  background: linear-gradient(transparent 65%, rgba(255,46,126,0.25) 65%);
  padding: 0 0.3rem;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

/* h4: シアン下線 */
h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  border-bottom: 1px solid rgba(69,226,255,0.28);
  padding-bottom: 0.3rem;
  margin: 1.8rem 0 0.9rem 0;
  line-height: 1.6;
}

/* h5: ゴールドドット */
h5 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 1.4rem 0 0.7rem 0;
  padding-left: 1.2rem;
  position: relative;
  line-height: 1.6;
}

h5::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.6em;
  transform: translateY(-50%);
  width: 7px;
  height: 7px;
  background-color: var(--gold);
  border-radius: 50%;
}

/* h6: ミュートテキスト */
h6 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-light);
  margin: 1.2rem 0 0.5rem 0;
  line-height: 1.6;
}

/* スマホ対応 (600px以下) */
/* h1を大きくしたため、h2以降もバランス調整 */
@media (max-width: 600px) {
  h1 {
    font-size: 1.25rem;
    margin: 1.5rem 0 1rem 0;
  }

  h2 {
    font-size: 1.1rem;
    /* 1.2rem */
    padding: 0.5rem 0.8rem;
    /* パディングもコンパクトに */
    margin: 1.0rem 0 0.5rem 0;
    /* 余白をさらに短縮 */
  }

  h3 {
    font-size: 1rem;
    /* 1rem */
    margin: 0.8rem 0 0.4rem 0;
    /* 余白を大幅に短縮 (1.4 -> 0.8) */
  }

  h4 {
    font-size: 0.8rem;
    /* 0.8rem */
    margin: 0.8rem 0 0.3rem 0;
    /* 余白を短縮 (1.2 -> 0.8) */
  }

  h5 {
    font-size: 0.7rem;
    /* 0.7rem */
    margin: 0.6rem 0 0.2rem 0;
    /* 余白を短縮 (1.0 -> 0.6) */
  }

  h6 {
    font-size: 0.5rem;
    /* 0.5rem */
    margin: 0.5rem 0 0.2rem 0;
    /* 余白を短縮 (0.8 -> 0.5) */
  }
}

