/* =========================
   塾長ノート専用スタイル
   ========================= */

.note-page {
  background: #f7f3eb;
  color: #2f2f2f;
}

.note-page .site-header {
  background: rgba(247, 243, 235, 0.94);
  border-bottom: 1px solid #ddd5c9;
}

.note-page .nav a {
  color: #3d4650;
}

.note-page .nav a:hover {
  color: #596b7a;
}

.note-page .logo-main,
.note-page .logo-sub {
  color: #2f2f2f;
}

/* hero */
.note-hero {
  padding: 92px 0 78px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.36) 0%, rgba(247,243,235,1) 100%);
}

.note-hero-inner {
  max-width: 820px;
}

.note-eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #ece5d9;
  color: #596b7a;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.note-title {
  margin: 0 0 18px;
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.15;
  color: #2f2f2f;
  letter-spacing: 0.02em;
}

.note-lead {
  margin: 0 0 14px;
  font-size: 1.14rem;
  line-height: 1.9;
  color: #3f3f3f;
}

.note-sublead {
  margin: 0;
  font-size: 1rem;
  line-height: 1.9;
  color: #666055;
}

.note-hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 32px;
}

.note-page .btn-primary {
  background: #596b7a;
  border-color: #596b7a;
}

.note-page .btn-primary:hover {
  background: #4b5a67;
  border-color: #4b5a67;
}

.note-page .btn-secondary {
  background: transparent;
  border: 1px solid #bfb5a8;
  color: #4a433b;
}

.note-page .btn-secondary:hover {
  background: #efe7db;
  border-color: #a89d90;
}

/* intro */
.note-intro {
  padding-top: 10px;
}

.note-intro-box {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 28px;
  align-items: start;
}

.note-intro-text,
.note-mini-card,
.note-closing-box {
  background: rgba(255,255,255,0.55);
  border: 1px solid #ddd5c9;
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(70, 60, 45, 0.05);
}

.note-intro-text {
  padding: 30px 28px;
}

.note-intro-text h2,
.note-closing-box h2 {
  margin: 0 0 16px;
  font-size: 1.45rem;
  color: #2f2f2f;
}

.note-intro-text p,
.note-mini-card li,
.note-closing-box p {
  font-size: 1rem;
  line-height: 1.9;
  color: #4f4942;
}

.note-mini-card {
  padding: 24px 22px;
}

.note-mini-card h3 {
  margin: 0 0 12px;
  font-size: 1.05rem;
  color: #596b7a;
}

.note-mini-card ul {
  margin: 0;
  padding-left: 1.2em;
}

/* section head */
.note-section-head {
  margin-bottom: 24px;
}

.note-section-label {
  margin: 0 0 8px;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #7b7368;
}

.note-home-title {
  margin-bottom: 10px;
}

/* featured notes */
.note-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.note-card {
  background: rgba(255,255,255,0.7);
  border: 1px solid #ddd5c9;
  border-radius: 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
}

.note-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(70, 60, 45, 0.08);
  border-color: #cbbfb1;
}

.note-card a {
  display: block;
  color: inherit;
  text-decoration: none;
  height: 100%;
}

.note-card-body {
  padding: 24px 22px;
}

.note-category {
  display: inline-block;
  margin-bottom: 12px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #596b7a;
  background: #ece5d9;
  padding: 5px 10px;
  border-radius: 999px;
}

.note-card h3 {
  margin: 0 0 14px;
  font-size: 1.2rem;
  line-height: 1.55;
  color: #2f2f2f;
}

.note-card p {
  margin: 0;
  font-size: 0.97rem;
  line-height: 1.85;
  color: #55514a;
}

.note-readmore {
  display: inline-block;
  margin-top: 18px;
  font-weight: 700;
  color: #596b7a;
}

/* themes */
.note-theme-section {
  padding-top: 12px;
}

.note-tag-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.note-tag {
  display: inline-block;
  padding: 10px 14px;
  border-radius: 999px;
  background: #efe7db;
  color: #4e463d;
  border: 1px solid #d8d1c7;
  font-size: 0.95rem;
  font-weight: 600;
}

/* closing */
.note-closing-box {
  padding: 34px 30px;
}

.note-closing-links {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.note-footer {
  background: #ede4d7;
  color: #433d36;
}

.note-footer .footer-links a {
  color: #433d36;
}

/* responsive */
@media (max-width: 920px) {
  .note-intro-box {
    grid-template-columns: 1fr;
  }

  .note-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .note-hero {
    padding: 74px 0 58px;
  }

  .note-title {
    font-size: 2.4rem;
  }

  .note-lead {
    font-size: 1rem;
  }

  .note-sublead {
    font-size: 0.95rem;
  }

  .note-intro-text,
  .note-mini-card,
  .note-closing-box,
  .note-card-body {
    padding: 22px 18px;
  }
}

/* =========================
   塾長ノート 記事ページ
   ========================= */

.note-article-page {
  padding: 48px 0 72px;
}

.note-article-wrap {
  max-width: 860px;
}

.note-article-header {
  margin-bottom: 26px;
}

.note-article-category {
  display: inline-block;
  margin-bottom: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #ece5d9;
  color: #596b7a;
  font-size: 0.85rem;
  font-weight: 700;
}

.note-article-title {
  margin: 0 0 18px;
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.35;
  color: #2f2f2f;
}


.note-article-card {
  background: rgba(255,255,255,0.62);
  border: 1px solid #ddd5c9;
  border-radius: 24px;
  box-shadow: 0 10px 28px rgba(70, 60, 45, 0.05);
  padding: 34px 30px;
}

.note-article-body {
  color: #403a34;
}

.note-article-body p {
  margin: 0 0 1.25em;
  font-size: 1.02rem;
  line-height: 2;
}

.note-article-body h2 {
  margin: 2.3em 0 0.8em;
  font-size: 1.45rem;
  line-height: 1.5;
  color: #2f2f2f;
  padding-bottom: 8px;
  border-bottom: 1px solid #ddd5c9;
}

.note-article-body blockquote {
  margin: 1.8em 0;
  padding: 16px 18px;
  border-left: 4px solid #596b7a;
  background: #f1ebe1;
  color: #3d3a36;
  font-size: 1rem;
  line-height: 1.9;
}

.note-article-body ul {
  margin: 0 0 1.4em 1.2em;
  padding: 0;
}

.note-article-body li {
  margin-bottom: 0.55em;
  line-height: 1.85;
  color: #4b463f;
}

.note-related-section {
  margin-top: 44px;
  padding-top: 24px;
  border-top: 1px solid #ddd5c9;
}

.note-related-section h3 {
  margin: 0 0 14px;
  font-size: 1.05rem;
  color: #596b7a;
}

.note-related-list {
  margin: 0;
  padding-left: 1.2em;
}

.note-related-list li {
  margin-bottom: 0.7em;
}

.note-related-list a {
  color: #4d5f6f;
  text-decoration: none;
}

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

.note-article-footer-links {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 32px;
}

@media (max-width: 640px) {
  .note-article-page {
    padding: 28px 0 56px;
  }

  .note-article-card {
    padding: 22px 18px;
    border-radius: 18px;
  }

  .note-article-title {
    font-size: 2rem;
  }

  .note-article-body h2 {
    font-size: 1.28rem;
  }
}

/* =========================
   塾長ノート 一覧セクション
   ========================= */

.note-all-section {
  padding-top: 8px;
}

.note-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.note-list-item {
  background: rgba(255,255,255,0.64);
  border: 1px solid #ddd5c9;
  border-radius: 18px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.note-list-item:hover {
  border-color: #cbbfb1;
  box-shadow: 0 10px 24px rgba(70, 60, 45, 0.06);
  transform: translateY(-2px);
}

.note-list-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "meta meta"
    "main arrow";
  column-gap: 18px;
  row-gap: 10px;
  align-items: center;
  padding: 20px 22px;
  color: inherit;
  text-decoration: none;
}

.note-list-meta {
  grid-area: meta;
  width: auto;
  min-width: 0;
  display: flex;
  justify-content: flex-start;
}

.note-list-main {
  grid-area: main;
  min-width: 0;
}

.note-list-arrow {
  grid-area: arrow;
}

.note-list-meta .note-category {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  max-width: 100%;
  min-width: 0;
  margin-bottom: 0;
  white-space: normal;
  line-height: 1.45;
  text-align: left;
}

.note-card .note-category {
  max-width: 100%;
  min-width: 0;
  white-space: normal;
  line-height: 1.45;
  text-align: left;
}

.note-list-main h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  line-height: 1.6;
  color: #2f2f2f;
}

.note-list-main p {
  margin: 0;
  font-size: 0.96rem;
  line-height: 1.85;
  color: #5a544d;
}

.note-list-arrow {
  font-size: 1.25rem;
  color: #596b7a;
  font-weight: 700;
  line-height: 1;
}

@media (max-width: 720px) {
  .note-list-link {
    grid-template-columns: 1fr;
    grid-template-areas:
      "meta"
      "main";
    gap: 12px;
    padding: 18px 16px;
  }

  .note-list-arrow {
    display: none;
  }
}

@media (max-width: 640px) {
  .note-list-link {
    display: block;
  }

  .note-list-meta {
    width: auto;
    margin-bottom: 10px;
  }

  .note-category {
    min-width: auto;
  }
}

/* =========================
   塾長ノート記事：共通記事構造
   ========================= */

.note-page .article-subtitle,
.note-article-subtitle {
  max-width: 760px;
  margin: 18px auto 0;
  color: #5d564d;
  font-size: 1.05rem;
  line-height: 1.9;
  text-align: left;
}

@media (max-width: 640px) {
  .note-page .article-subtitle,
  .note-article-subtitle {
    margin-top: 16px;
    font-size: 0.98rem;
    line-height: 1.8;
  }
}

.note-figure img {
  display: block;
  width: 100%;
  max-width: 480px;
  height: auto;
  margin: 0 auto;
  border-radius: 10px;
}

/* =========================
   塾長ノート記事：数式・画像
   ========================= */

.math-inline-box {
  margin: 1.4rem 0;
  padding: 16px 18px;
  border-left: 4px solid #596b7a;
  background: #f1ebe1;
  color: #3d3a36;
  font-family: "Times New Roman", "Yu Mincho", "Hiragino Mincho ProN", serif;
  font-size: 1rem;
  line-height: 1.9;
  white-space: nowrap;
  overflow-x: auto;
}

.note-figure {
  margin: 1.8rem 0;
  text-align: center;
}

.note-figure img {
  display: block;
  width: 100%;
  max-width: 620px;
  height: auto;
  margin: 0 auto;
  border-radius: 10px;
}

.note-figure figcaption {
  margin-top: 0.7rem;
  font-size: 0.9rem;
  line-height: 1.7;
  color: #6a6258;
}

.math-figure img {
  max-width: 720px;
  background: #fff;
  border: 1px solid #ddd5c9;
  box-shadow: 0 8px 20px rgba(70, 60, 45, 0.06);
}

@media (max-width: 640px) {
  .math-inline-box {
    font-size: 0.95rem;
    padding: 14px 16px;
  }

  .note-figure {
    margin: 1.5rem 0;
  }

  .note-figure figcaption {
    font-size: 0.86rem;
  }
}

/* =========================
   MathJax 数式表示
   ========================= */

.note-article-body mjx-container[jax="SVG"][display="true"] {
  margin: 1.6rem 0;
  padding: 0.35rem 0;
  overflow-x: auto;
  overflow-y: hidden;
}

.note-article-body mjx-container {
  max-width: 100%;
}

@media (max-width: 640px) {
  .note-article-body mjx-container[jax="SVG"][display="true"] {
    margin: 1.35rem 0;
  }
}

/* =========================
   数学記事：数式ボックス
   ========================= */

.math-box {
  margin: 1.6rem 0;
  padding: 1.1rem 1.2rem;
  background: #f1ebe1;
  border-left: 4px solid #596b7a;
  border-radius: 0 12px 12px 0;
  color: #3d3a36;
  overflow-x: auto;
}

.math-box mjx-container[jax="SVG"][display="true"] {
  margin: 0.7rem 0;
  padding: 0.2rem 0;
}

.math-box mjx-container[jax="SVG"][display="true"]:first-child {
  margin-top: 0;
}

.math-box mjx-container[jax="SVG"][display="true"]:last-child {
  margin-bottom: 0;
}

.math-box-label {
  margin: 0 0 0.75rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: #596b7a;
  letter-spacing: 0.04em;
}

@media (max-width: 640px) {
  .math-box {
    padding: 1rem;
    margin: 1.4rem 0;
  }
}

/* =========================
   記事内画像・数学図版
   ========================= */

.note-figure {
  margin: 1.8rem 0;
  text-align: center;
}

.note-figure img {
  display: block;
  width: 100%;
  max-width: 620px;
  height: auto;
  margin: 0 auto;
  border-radius: 10px;
}

.note-figure figcaption {
  margin-top: 0.7rem;
  font-size: 0.9rem;
  line-height: 1.7;
  color: #6a6258;
}

.math-figure img {
  max-width: 720px;
  background: #fff;
  border: 1px solid #ddd5c9;
  box-shadow: 0 8px 20px rgba(70, 60, 45, 0.06);
}

@media (max-width: 640px) {
  .note-figure {
    margin: 1.5rem 0;
  }

  .note-figure figcaption {
    font-size: 0.86rem;
  }
}

/* =========================
   数学記事：グラフ図版
   ========================= */

.graph-box {
  margin: 1.8rem 0;
  padding: 1rem 1.1rem;
  background: #f8f4ee;
  border: 1px solid #e2d8cb;
  border-radius: 14px;
  overflow-x: auto;
}

.graph-box-label {
  margin: 0 0 0.8rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: #596b7a;
  letter-spacing: 0.04em;
}

.graph-svg {
  display: block;
  width: 100%;
  max-width: 560px;
  height: auto;
  margin: 0 auto;
}

.graph-caption {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  line-height: 1.7;
  color: #6a6258;
  text-align: center;
}

@media (max-width: 640px) {
  .graph-box {
    padding: 0.9rem;
    margin: 1.5rem 0;
  }

  .graph-caption {
    font-size: 0.86rem;
  }
}

/* =========================
   塾長ノートトップ：カテゴリナビ
   ========================= */

.note-category-section {
  padding-top: 18px;
}

.note-category-nav {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.note-category-tile {
  display: block;
  min-height: 138px;
  padding: 20px 18px;
  border-radius: 18px;
  background: rgba(255,255,255,0.46);
  border: 1px solid #ddd5c9;
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.note-category-tile:hover {
  transform: translateY(-3px);
  background: rgba(255,255,255,0.68);
  border-color: #cbbfb1;
  box-shadow: 0 10px 22px rgba(70, 60, 45, 0.06);
}

.note-category-kicker {
  display: block;
  margin-bottom: 10px;
  color: #7b7368;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.note-category-tile strong {
  display: block;
  margin-bottom: 8px;
  color: #2f2f2f;
  font-size: 1.18rem;
  line-height: 1.35;
}

.note-category-tile small {
  display: block;
  color: #5d564d;
  font-size: 0.9rem;
  line-height: 1.7;
}


/* =========================
   塾長ノートトップ：シリーズリスト
   ========================= */

.note-series-section {
  padding-top: 18px;
}

.note-series-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.note-series-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  min-height: 156px;
  padding: 22px 24px;
  border-radius: 20px;
  background: rgba(255,255,255,0.62);
  border: 1px solid #ddd5c9;
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.note-series-item:hover {
  transform: translateY(-3px);
  border-color: #cbbfb1;
  box-shadow: 0 10px 24px rgba(70, 60, 45, 0.07);
}

.note-series-main {
  grid-column: 1 / -1;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.76), rgba(236,229,217,0.72));
}

.note-series-content h3 {
  margin: 0 0 10px;
  color: #2f2f2f;
  font-size: 1.22rem;
  line-height: 1.5;
}

.note-series-content p {
  margin: 0;
  color: #5a544d;
  font-size: 0.96rem;
  line-height: 1.85;
}

.note-series-arrow {
  color: #596b7a;
  font-size: 0.94rem;
  font-weight: 700;
  white-space: nowrap;
}


/* =========================
   塾長ノートトップ：記事カードとの違いを出す
   ========================= */

#featured-notes .note-grid {
  margin-top: 4px;
}

#featured-notes .note-card {
  background: rgba(255,255,255,0.72);
}

.note-latest-section .note-list {
  gap: 12px;
}

.note-latest-section .note-list-item {
  background: rgba(255,255,255,0.56);
}


/* =========================
   responsive：カテゴリ・シリーズ
   ========================= */

@media (max-width: 1020px) {
  .note-category-nav {
    grid-template-columns: repeat(3, 1fr);
  }

  .note-series-list {
    grid-template-columns: 1fr;
  }

  .note-series-main {
    grid-column: auto;
  }
}

@media (max-width: 720px) {
  .note-category-nav {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .note-category-tile {
    min-height: 124px;
    padding: 18px 16px;
  }

  .note-series-item {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 20px 18px;
  }

  .note-series-arrow {
    margin-top: 2px;
  }
}

@media (max-width: 480px) {
  .note-category-nav {
    grid-template-columns: 1fr;
  }

  .note-category-tile {
    min-height: auto;
  }
}

/* =========================
   塾長ノートトップ：JSON描画まわり
   ========================= */

.note-filter-actions {
  margin: 18px 0 22px;
}

.note-filter-reset {
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid #bfb5a8;
  background: transparent;
  color: #4a433b;
  font-weight: 700;
  cursor: pointer;
}

.note-filter-reset:hover {
  background: #efe7db;
}

.note-empty-message {
  margin: 0;
  padding: 22px 20px;
  border: 1px solid #ddd5c9;
  border-radius: 16px;
  background: rgba(255,255,255,0.58);
  color: #5a544d;
  line-height: 1.8;
}

/* =========================
   塾長ノート記事：本文の読みやすさ改善 v2
   見出し・例文・ポイント・表の役割を分ける
   ========================= */

/* 本文幅と基本テキスト */
.note-article-body {
  max-width: 760px;
  margin: 0 auto;
  color: #403a34;
}

.note-article-body p {
  margin: 0 0 1.35em;
  font-size: 1.03rem;
  line-height: 2.05;
  letter-spacing: 0.015em;
}

/* 記事冒頭の最初の段落だけ少しリード文っぽく */
.note-article-body > p:first-child {
  font-size: 1.08rem;
  line-height: 2.05;
  color: #3d3832;
}

/* h2：章見出し。背景ボックスにはせず、見出しとして区別する */
.note-article-body h2 {
  position: relative;
  margin: 2.8em 0 1.1em;
  padding: 0 0 0.55em 0;
  border-bottom: 1px solid #d6ccbe;
  background: transparent;
  border-radius: 0;
  font-size: 1.45rem;
  line-height: 1.55;
  color: #24313d;
}

/* h2の先頭に小さな丸を付けて章見出し感を出す */
.note-article-body h2::before {
  content: "";
  display: inline-block;
  width: 0.55em;
  height: 0.55em;
  margin-right: 0.45em;
  border-radius: 50%;
  background: #596b7a;
  vertical-align: 0.08em;
}

/* h3：小見出し。控えめに区切る */
.note-article-body h3 {
  margin: 2.2em 0 0.9em;
  padding-bottom: 0.35em;
  border-bottom: 1px dashed #d3c9bb;
  font-size: 1.18rem;
  line-height: 1.55;
  color: #3a4650;
}

/* 強調語 */
.note-article-body strong {
  color: #263847;
  font-weight: 800;
}

/* blockquote：英文例文・引用・式の例示ボックス */
.note-article-body blockquote {
  margin: 1.6em 0;
  padding: 16px 18px 16px 20px;
  border-left: 4px solid #8a9aa7;
  background: #f1ebe1;
  border-radius: 12px;
  color: #30343a;
  font-size: 1rem;
  line-height: 1.9;
  box-shadow: 0 5px 14px rgba(70, 60, 45, 0.035);
}

/* blockquote内にpがある場合の余白調整 */
.note-article-body blockquote p {
  margin: 0 0 0.55em;
  line-height: 1.85;
}

.note-article-body blockquote p:last-child {
  margin-bottom: 0;
}

/* 重要ポイントボックス：blockquoteとは別物として少し強めに */
.note-point-box {
  margin: 1.8rem 0 2rem;
  padding: 1.15rem 1.25rem;
  border-radius: 16px;
  background: #f7f1e8;
  border: 1px solid #d8cdbc;
  border-left: 6px solid #596b7a;
  box-shadow: 0 8px 20px rgba(70, 60, 45, 0.05);
}

.note-point-box p {
  margin: 0;
  color: #343b42;
  font-weight: 700;
  line-height: 1.9;
}

/* 箇条書き：整理リストとして軽く囲む */
.note-article-body ul {
  margin: 1.2rem 0 1.7rem;
  padding: 1rem 1.2rem 1rem 2.2rem;
  background: rgba(255,255,255,0.48);
  border: 1px solid #e2d8cb;
  border-radius: 14px;
}

.note-article-body li {
  margin-bottom: 0.65em;
  line-height: 1.85;
  color: #4b463f;
}

.note-article-body li:last-child {
  margin-bottom: 0;
}

/* 表：比較・整理用に見やすく */
.note-article-body table {
  width: 100%;
  margin: 1.8rem 0 2rem;
  border-collapse: collapse;
  background: rgba(255,255,255,0.62);
  border: 1px solid #ddd5c9;
  border-radius: 14px;
  overflow: hidden;
  font-size: 0.96rem;
}

.note-article-body th,
.note-article-body td {
  padding: 0.8rem 0.9rem;
  border-bottom: 1px solid #e2d8cb;
  text-align: left;
  line-height: 1.65;
}

.note-article-body th {
  background: #ece5d9;
  color: #2f3b45;
  font-weight: 800;
}

.note-article-body tr:last-child td {
  border-bottom: none;
}

/* 数式ボックスがある記事用：既存math-boxを少しだけ整える */
.math-box {
  margin: 1.7rem 0 2rem;
  padding: 1.1rem 1.2rem;
  background: #f1ebe1;
  border-left: 5px solid #596b7a;
  border-radius: 0 14px 14px 0;
  color: #3d3a36;
  overflow-x: auto;
}

.math-box-label {
  margin: 0 0 0.75rem;
  font-size: 0.88rem;
  font-weight: 800;
  color: #596b7a;
  letter-spacing: 0.04em;
}

/* スマホ調整 */
@media (max-width: 640px) {
  .note-article-body {
    max-width: 100%;
  }

  .note-article-body p {
    font-size: 0.99rem;
    line-height: 1.95;
  }

  .note-article-body > p:first-child {
    font-size: 1.02rem;
  }

  .note-article-body h2 {
    margin-top: 2.4em;
    padding-bottom: 0.5em;
    font-size: 1.25rem;
  }

  .note-article-body h3 {
    font-size: 1.08rem;
  }

  .note-article-body ul {
    padding: 0.9rem 1rem 0.9rem 1.8rem;
  }

  .note-article-body blockquote {
    padding: 14px 16px;
    font-size: 0.96rem;
  }

  .note-point-box {
    padding: 1rem;
  }

  .note-article-body table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

/* =========================
   塾長ノートトップ：シリーズカードを均等配置
   ========================= */

.note-series-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.note-series-item {
  display: block;
  min-height: 210px;
  padding: 22px 22px;
  border-radius: 18px;
  background: rgba(255,255,255,0.62);
  border: 1px solid #ddd5c9;
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.note-series-main {
  grid-column: auto;
}

.note-series-item:hover {
  transform: translateY(-3px);
  border-color: #cbbfb1;
  box-shadow: 0 10px 24px rgba(70, 60, 45, 0.07);
}

.note-series-content h3 {
  margin: 0 0 10px;
  color: #2f2f2f;
  font-size: 1.15rem;
  line-height: 1.5;
}

.note-series-content p {
  margin: 0 0 16px;
  color: #5a544d;
  font-size: 0.94rem;
  line-height: 1.8;
}

.note-series-arrow {
  display: inline-block;
  margin-top: 4px;
  color: #596b7a;
  font-size: 0.93rem;
  font-weight: 700;
  white-space: nowrap;
}

@media (max-width: 1020px) {
  .note-series-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .note-series-list {
    grid-template-columns: 1fr;
  }

  .note-series-item {
    min-height: auto;
    padding: 20px 18px;
  }
}


/* =========================
   塾長ノート案内図
   ========================= */

.note-map-hero {
  padding: 88px 0 74px;
  background:
    radial-gradient(circle at top right, rgba(89, 107, 122, 0.10), transparent 34%),
    linear-gradient(180deg, rgba(255,255,255,0.44) 0%, rgba(247,243,235,1) 100%);
}

.note-map-hero-inner {
  max-width: 880px;
  text-align: center;
}

.note-map-title {
  margin: 0 0 18px;
  font-size: clamp(2.5rem, 5vw, 4.15rem);
  line-height: 1.18;
  color: #2f2f2f;
  letter-spacing: 0.04em;
}

.note-map-lead {
  margin: 0 0 20px;
  color: #354451;
  font-size: clamp(1.28rem, 2.6vw, 1.68rem);
  font-weight: 700;
  line-height: 1.8;
}

.note-map-description {
  max-width: 760px;
  margin: 0 auto;
  color: #5d564d;
  font-size: 1.02rem;
  line-height: 2;
}

.note-map-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 34px;
}

.note-map-section-head {
  text-align: center;
}

.note-map-route-section {
  padding-top: 60px;
}

.note-route-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.note-route-card {
  padding: 25px 22px 22px;
  border: 1px solid #ddd5c9;
  border-radius: 21px;
  background: rgba(255,255,255,0.62);
  box-shadow: 0 8px 22px rgba(70, 60, 45, 0.045);
}

.note-route-card-accent {
  background:
    linear-gradient(145deg, rgba(236,229,217,0.75), rgba(255,255,255,0.70));
}

.note-route-kicker {
  display: block;
  margin: 0 0 10px;
  color: #7b7368;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.note-route-card h3 {
  margin: 0 0 10px;
  color: #2f2f2f;
  font-size: 1.16rem;
  line-height: 1.6;
}

.note-route-card p {
  margin: 0 0 17px;
  color: #5a544d;
  font-size: 0.94rem;
  line-height: 1.85;
}

.note-route-links {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.note-route-links button,
.note-connection-flow button {
  appearance: none;
  border: 1px solid #d3c8ba;
  background: #f7f1e8;
  border-radius: 999px;
  padding: 7px 11px;
  color: #526575;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.45;
  cursor: pointer;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.note-route-links button:hover,
.note-connection-flow button:hover {
  background: #ebe3d7;
  border-color: #bbaea0;
  transform: translateY(-1px);
}

.note-map-series-section {
  background: rgba(255,255,255,0.26);
}

.note-series-groups {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.note-map-loading {
  margin: 0;
  padding: 22px;
  text-align: center;
  border: 1px solid #ddd5c9;
  border-radius: 18px;
  color: #5a544d;
  background: rgba(255,255,255,0.54);
}

.note-map-domain-head {
  margin-bottom: 18px;
}

.note-map-domain-head h3 {
  margin: 0 0 7px;
  color: #2f2f2f;
  font-size: 1.55rem;
  line-height: 1.45;
}

.note-map-domain-head p:not(.note-route-kicker) {
  margin: 0;
  color: #5d564d;
  font-size: 0.96rem;
  line-height: 1.8;
}

.note-map-series-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.note-map-series-card {
  padding: 22px 21px;
  border-radius: 20px;
  border: 1px solid #ddd5c9;
  background: rgba(255,255,255,0.70);
  box-shadow: 0 7px 20px rgba(70, 60, 45, 0.04);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.note-map-series-card.is-highlighted {
  border-color: #8092a1;
  background: #fffdf9;
  box-shadow: 0 12px 28px rgba(70, 60, 45, 0.10);
}

.note-map-series-card-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 12px;
}

.note-map-series-card-head h4 {
  margin: 0 0 8px;
  color: #2f2f2f;
  font-size: 1.16rem;
  line-height: 1.5;
}

.note-map-series-card-head p {
  margin: 0;
  color: #5d564d;
  font-size: 0.92rem;
  line-height: 1.78;
}

.note-map-count {
  flex-shrink: 0;
  display: inline-block;
  padding: 5px 9px;
  border-radius: 999px;
  background: #ece5d9;
  color: #596b7a;
  font-size: 0.8rem;
  font-weight: 800;
  white-space: nowrap;
}

.note-map-article-details {
  margin-top: 17px;
  border-top: 1px solid #e2d8cb;
  padding-top: 12px;
}

.note-map-article-details summary {
  color: #596b7a;
  font-size: 0.92rem;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.note-map-article-details summary::-webkit-details-marker {
  display: none;
}

.note-map-article-details summary::after {
  content: " ＋";
}

.note-map-article-details[open] summary::after {
  content: " −";
}

.note-map-article-list {
  margin: 13px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px dashed #e2d8cb;
}

.note-map-article-list li {
  border-bottom: 1px dashed #e2d8cb;
}

.note-map-article-list a {
  display: flex;
  gap: 9px;
  padding: 10px 2px;
  color: #414d57;
  font-size: 0.9rem;
  line-height: 1.65;
  text-decoration: none;
}

.note-map-article-list a:hover {
  color: #596b7a;
  text-decoration: underline;
}

.note-map-article-number {
  flex-shrink: 0;
  color: #8b8175;
  font-size: 0.82rem;
  font-weight: 700;
}

.note-map-connections-section {
  padding-top: 64px;
}

.note-connection-grid {
  display: grid;
  gap: 14px;
  max-width: 920px;
  margin: 0 auto;
}

.note-connection-card {
  padding: 20px 22px;
  border-radius: 19px;
  border: 1px solid #ddd5c9;
  background: rgba(255,255,255,0.60);
}

.note-connection-card h3 {
  margin: 0 0 13px;
  color: #2f2f2f;
  font-size: 1.07rem;
}

.note-connection-flow {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

.note-connection-flow span {
  color: #8e8376;
  font-weight: 800;
}

.note-map-bridge-section {
  padding-top: 34px;
  padding-bottom: 80px;
}

.note-map-bridge-box {
  padding: 42px 34px;
  text-align: center;
  border-radius: 27px;
  background:
    linear-gradient(135deg, rgba(236,229,217,0.75), rgba(255,255,255,0.72));
  border: 1px solid #ddd5c9;
  box-shadow: 0 10px 25px rgba(70, 60, 45, 0.05);
}

.note-map-bridge-box h2 {
  margin: 0 0 16px;
  color: #2f2f2f;
  font-size: clamp(1.58rem, 3vw, 2.18rem);
  line-height: 1.6;
}

.note-map-bridge-box > p:not(.note-section-label) {
  max-width: 700px;
  margin: 0 auto;
  color: #5d564d;
  font-size: 0.98rem;
  line-height: 1.95;
}

.note-map-bridge-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 13px;
  margin-top: 29px;
}

@media (max-width: 980px) {
  .note-route-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .note-map-series-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .note-map-hero {
    padding: 66px 0 56px;
  }

  .note-map-title {
    font-size: 2.35rem;
  }

  .note-map-lead {
    font-size: 1.18rem;
  }

  .note-map-description {
    font-size: 0.96rem;
  }

  .note-map-actions,
  .note-map-bridge-actions {
    flex-direction: column;
  }

  .note-map-actions .btn,
  .note-map-bridge-actions .btn {
    width: 100%;
  }

  .note-route-grid {
    grid-template-columns: 1fr;
  }

  .note-route-card,
  .note-map-series-card,
  .note-connection-card {
    padding: 20px 17px;
  }

  .note-map-series-card-head {
    flex-direction: column;
  }

  .note-map-bridge-box {
    padding: 29px 19px;
  }
}

/* 塾長ノートトップ：案内図導線 */
.note-map-guide-link {
  margin-top: 24px;
  text-align: center;
}

.note-map-guide-link .btn {
  min-width: 230px;
}
