@charset "UTF-8";
/* WP環境限定: 検証サーバーがCSSファイルにUTF-8のCharset宣言を付与しないため、
   →・↗・・ 等のcontent:内の記号やCJK文字がLatin-1/Windows-1252として誤解釈され
   文字化けする(例: "—" が "â€”" として表示される)問題への対策。renewal-test側には
   この宣言は存在しない(ローカルサーバーは問題なく表示されるため不要)。 */
/* 2026-11-25: Google Fonts(Playball / Quicksand 500-700 / Noto Sans JP 400-700)は表示速度のため @import をやめ、
   functions.php(myport_renewal_enqueue_assets)から <head> の link 1本で読み込む。書体・太さ・display=swap は同じ。
   (Playball は「選ばれる3つの理由」の数字などで使用中) */
/* Fable 2026-07-04: 英字キッカー用 Quicksand(幾何学系丸ゴシック・ロゴ準拠)+
   参照済みなのに未読込だった Noto Sans JP(400-700)を追加。
   Playball の import は下の Fable typography ブロックで使用箇所ゼロになったため削除候補(今回は残置) */


/* Nishiki Child legacy style.css compatibility
   mayport_nishiki_child 固有の打ち消し(mayport_renewal には存在しない意図的な差分)。
   mayport_nishiki_child/style.css の旧装飾(h2の葉っぱ・h3の灯台アイコン/黄色マーカー・th黄色背景)を
   renewal対象ページ(body.mp-v2)だけ無効化する。
   :where() で詳細度を旧ルールと同等に保ち、後続のrenewal側ルールを潰さない。
   style.css 本体(2176行)は削除しない。renewal対象外ページには従来どおり効く。 */
:where(body.mp-v2) h2 {
  position: static;
}

:where(body.mp-v2) h2::before,
:where(body.mp-v2) h3::before,
:where(body.mp-v2) h3:not(.home)::before {
  content: none;
}

:where(body.mp-v2) h3:not(.home) {
  background: none;
  padding-left: 0;
  position: static;
}

:where(body.mp-v2) th {
  background-color: transparent;
}
/* /Nishiki Child legacy style.css compatibility */

:root {
  --ink: #333;
  --muted: #617086;
  --green: #5b955a;
  --green-soft: #e7f1e6;
  --yellow: #f6b800;
  --blue: #4f84cd;
  --blue-soft: #e8f0fc;
  --pink: #d46d9f;
  --pink-soft: #fdebf4;
  --yellow-soft: #fff6d8;
  --paper: #ffffff;
  --wash: #f8faf7;
  --line: #e7ebef;
  --shadow: 0 18px 50px rgba(27, 50, 78, 0.11);
  --radius: 8px;
}

/* TOP page missing-element fixes 2026-06-20 */
body:not(.lower-page) .course-card {
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
}

body:not(.lower-page) .course-image {
  width: 100%;
}

body:not(.lower-page) .photo-course-one {
  background-position: center 38%;
}

body:not(.lower-page) .photo-course-two {
  background-position: center 34%;
}

body:not(.lower-page) .photo-course-three {
  background-position: center 36%;
}

body:not(.lower-page) .flow-section {
  min-height: 260vh;
  margin-bottom: 96px !important;
}

body:not(.lower-page) .flow-sticky {
  position: sticky;
  top: 90px;
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
  max-width: 1120px;
  margin: 0 auto;
}


body:not(.lower-page) .flow-photo {
  position: absolute;
  inset: 0;
  display: block;
  opacity: 0;
  transform: scale(1.035);
  background-size: cover;
  background-position: center;
  transition: opacity 0.45s ease, transform 0.7s ease;
}

body:not(.lower-page) .flow-photo.active {
  opacity: 1;
  transform: scale(1);
}

body:not(.lower-page) .flow-panel {
  min-width: 0;
}

/* Yellow CTA buttons: keep text/icons white */

@media (max-width: 980px) {
  body:not(.lower-page) .reasons-sticky-wrap {
    height: 220vh !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reasons {
    position: sticky !important;
    top: 72px !important;
    height: auto !important;
    min-height: 0 !important;
    display: block !important;
    overflow: visible !important;
    padding-top: 2rem !important;
  }

  /* 2026-09-27: タイトル下の余白を20px→50pxへ拡大(ユーザー指定) */
  body:not(.lower-page) .reasons-sticky-wrap .reasons-title {
    position: relative !important;
    margin-bottom: 50px !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.active,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.past,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.fade-up.visible,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.fade-up.visible.active,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.fade-up.visible.past {
    position: absolute !important;
    inset: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translateY(24px) scale(0.97) !important;
    transition: opacity 0.4s ease, transform 0.5s ease !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card.active,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.fade-up.visible.active {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translateY(0) scale(1) !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card.past,
  body:not(.lower-page) .reasons-sticky-wrap .reason-card.fade-up.visible.past {
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translateY(-16px) scale(0.97) !important;
  }

}

/* 2026-11-03: SP(640px以下)のみ「3つの理由」の固定位置(top)を72px→-50pxへ上げる(ユーザー指定)。固定の仕組み・カードの切替は変更しない */
@media (max-width: 640px) {
  body:not(.lower-page) .reasons-sticky-wrap .reasons {
    top: -50px !important;
  }
}

@media (max-width: 640px) {

  body:not(.lower-page) .admission-index {
    padding: 20px;
  }

  body:not(.lower-page) .admission-index-list a {
    display: block;
    border-radius: 18px;
    line-height: 1.65;
  }


}

/* ===== PAGE LOADER ===== */
#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  transition: opacity 1.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#loader.fade-out {
  opacity: 0;
  pointer-events: none;
}

.loader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
}

.loader-heading {
  margin: 0;
  font-size: clamp(34px, 5.5vw, 68px);
  font-weight: 900;
  line-height: 1.25;
  color: var(--ink);
  text-align: center;
  min-height: 4.2em;
}


.loader-cursor {
  display: inline-block;
  margin-left: 3px;
  color: var(--green);
  font-weight: 300;
  animation: loaderBlink 0.6s step-end infinite;
}

@keyframes loaderBlink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

.loader-logo-wrap {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.85s ease, transform 0.85s ease;
}

.loader-logo-wrap.visible {
  opacity: 1;
  transform: translateY(0);
}

.loader-logo-wrap img {
  width: clamp(180px, 24vw, 260px);
}

/* ===== END LOADER ===== */

/* ===== BG PARALLAX BLOBS ===== */
#bgBlobs {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.bg-blob {
  position: absolute;
  filter: blur(88px);
  will-change: transform;
}

main,
footer {
  position: relative;
}

.site-header {
  z-index: 10;
}
/* ===== END BG BLOBS ===== */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Yu Gothic", "Hiragino Kaku Gothic ProN", Meiryo, system-ui, sans-serif;
  background:
    radial-gradient(circle at 4% 26%, rgba(246, 184, 0, 0.22) 0 1px, transparent 1px) 0 0 / 14px 14px,
    linear-gradient(180deg, #fff 0%, #fff 42%, #fbfcfb 100%);
  line-height: 1.85;
  letter-spacing: 0;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 24px clamp(20px, 6vw, 92px);
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 190px;
  color: var(--green);
  line-height: 1.1;
}

.brand img {
  display: block;
  width: 156px;
  height: auto;
}

.desktop-nav {
  display: flex;
  justify-content: flex-end;
  gap: clamp(16px, 2.2vw, 34px);
  flex: 1;
  color: #333; /* 旧 #18273f(紺)。TOPはbody:not(.lower-page) .desktop-navで別途上書きされ無影響、下層ページのみ変更 */
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.desktop-nav a {
  transition: color 0.2s ease;
}

.desktop-nav a:hover {
  color: var(--green);
}

.nav-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

.nav-cta,
.button.primary {
  color: #fff;
  background: var(--yellow);
  border: 1px solid var(--yellow);
  box-shadow: 0 10px 24px rgba(246, 184, 0, 0.24);
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

/* 2026-09-29: 従来はopacity:0.85で薄くするだけで色の変化が分かりにくかったため、
   .button.ghost系と同じ「反転」に統一。通常=黄背景+白文字 → hover=白背景+黄文字。
   境界が白背景に消えないようborder(黄)を追加(通常時は黄背景と同色のため見た目に影響なし)。
   既存のtransform:translateY(-2px)は維持。 */
.nav-cta:hover,
.nav-cta:focus-visible,
.button.primary:hover,
.button.primary:focus-visible {
  color: var(--yellow);
  background: #fff;
  transform: translateY(-2px);
}

.button.ghost {
  color: #315f35;
  background: #fff;
  border: 1px solid #95bf96;
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

/* 2026-09-29: 既定色(カード等で色指定が無い.button.ghost)のhover/focus-visible。
   TOP・下層共通(無スコープ)。他の色指定コンテキスト(course-card--green等)は
   別途各ルール直後によりスコープしたhoverを用意し、詳細度で上書きする。 */
.button.ghost:hover,
.button.ghost:focus-visible {
  color: #fff;
  background: #95bf96;
  transform: translateY(-1px);
}

.button.small {
  min-height: 40px;
  padding: 0 18px;
  font-size: 14px;
}

.hero {
  position: relative;
  display: block;
  max-width: 1260px;
  min-height: 700px;
  margin: 0 auto;
  padding: clamp(42px, 7vw, 96px) clamp(22px, 6vw, 80px) 62px;
  overflow: hidden;
}

.hero::after,
.message::before,
.results-voice::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero::after {
  right: 5%;
  bottom: 68px;
  z-index: 0;
  width: 230px;
  height: 94px;
  background: #a7c6ee;
  transform: rotate(-10deg);
  opacity: 0.9;
}

.hero-copy {
  position: relative;
  z-index: 2;
  max-width: 540px;
}

.hero-visual {
  position: relative;
  z-index: 1;
}

.eyebrow,
.section-kicker {
  margin: 0 0 12px;
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.hero h1 {
  margin: 0;
  font-size: clamp(34px, 4.1vw, 58px);
  line-height: 1.42;
  font-weight: 900;
}

.hero h1 span {
  color: var(--yellow);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.2em;
  font-weight: 400;
}

.lead {
  max-width: 520px;
  margin: 24px 0 28px;
  color: #263653;
  font-size: 18px;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.hero-visual {
  position: absolute !important;
  inset: 0 !important;
  min-height: 0 !important;
  z-index: 0 !important;
  pointer-events: none;
}

.photo {
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow);
}

.lower-page .hero-visual .photo {
  position: absolute;
  inset: 0;
}

.photo-hero {
  position: absolute;
  inset: 0;
  z-index: 1;
  min-height: 0;
  border-radius: 0;
  background-image: url("img/mp-top-fv-03.webp");
  background-position: right bottom;
}

.hero-stats {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.stat-card {
  position: absolute;
  z-index: 2;
  display: grid;
  width: 144px;
  min-height: 110px;
  place-items: center;
  padding: 16px;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid #edf1f2;
  border-radius: 58% 42% 55% 45% / 50% 48% 52% 50%;
  box-shadow: 0 16px 34px rgba(21, 38, 62, 0.12);
  text-align: center;
}

.stat-card small {
  color: #6f7884;
  font-weight: 800;
}

.stat-card strong {
  color: var(--green);
  font-family: Georgia, serif;
  font-size: 42px;
  line-height: 1;
}

.stat-card span {
  color: #536072;
  font-size: 12px;
  font-weight: 700;
}

.stat-a {
  top: 30px;
  right: 54px;
  border-radius: 56% 44% 62% 38% / 48% 56% 44% 52%;
}

.stat-b {
  top: 170px;
  right: 4px;
  border-radius: 42% 58% 38% 62% / 55% 45% 58% 42%;
}

.stat-c {
  top: 310px;
  right: 48px;
  border-radius: 52% 48% 44% 56% / 46% 54% 48% 52%;
}

.message {
  position: relative;
  display: grid;
  grid-template-columns: minmax(260px, 420px) minmax(320px, 560px);
  align-items: center;
  gap: clamp(36px, 7vw, 84px);
  max-width: 1140px;
  margin: 0 auto;
  padding: 36px clamp(22px, 5vw, 56px) 78px;
}

.message::before {
  left: -34px;
  bottom: 74px;
  width: 160px;
  height: 126px;
  background: var(--yellow-soft);
}

.portrait-wrap {
  position: relative;
}

.portrait-wrap::after {
  content: "";
  position: absolute;
  right: 12px;
  bottom: -8px;
  width: 96px;
  height: 72px;
  background: var(--green);
  border-radius: 100% 0 100% 0;
}

.photo-portrait {
  position: relative;
  z-index: 1;
  width: min(100%, 680px);
  aspect-ratio: 1.05;
  border-radius: 40px 8px 92px 8px;
  background-image: url("img/sensei.webp");
  background-position: center 38%;
}

.message-copy h2,
.section-title h2,
.course-intro h2,
.results h2,
.voice h2,
.cta h2 {
  margin: 0;
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.62;
  font-weight: 900;
}

.message-copy h2 {
  font-size: clamp(20px, 2.6vw, 32px);
}

.message-copy {
  position: relative;
  z-index: 1;
}

.message-copy h2 span {
  color: var(--green);
}

.message-copy p {
  color: var(--muted);
  font-weight: 700;
}

/* 2026-09-27: TOP MESSAGE本文のSPフォントサイズを明示(UA既定値16pxへ依存していたのを明文化)。
   .message-copyは下層ページにも共通のクラスのためbody:not(.lower-page)でTOP限定。 */
@media (max-width: 640px) {
  body:not(.lower-page) .message-copy p:not(.section-kicker) {
    font-size: 16px;
  }
}

.signature {
  text-align: right;
}

.signature img {
  width: min(220px, 52vw);
  height: auto;
}

.recommend,
.reasons,
.courses,
.results-voice {
  max-width: 1180px;
  margin: 0 auto;
  padding: 26px clamp(22px, 5vw, 56px) 78px;
}

.recommend {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  align-items: start;
}


.compact h2 {
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.65;
}

.recommend-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.recommend-grid article {
  display: block;
  grid-column: auto;
  min-height: 140px;
  padding: 22px 18px;
  background: #ffffff;
  border: 1px solid rgba(120, 178, 99, 0.1);
  border-radius: 28px;
  box-shadow: 0 10px 24px rgba(21, 38, 62, 0.04);
  text-align: center;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.62;
}

.recommend-grid article:nth-child(n+4):nth-child(-n+7) {
  grid-column: auto;
}

.recommend-grid article:nth-child(4n+1) {
  background: #ffffff;
}

.recommend-grid article:nth-child(4n+2) {
  background: #ffffff;
}

.recommend-grid article:nth-child(4n+3) {
  background: #ffffff;
}

.recommend-grid article:nth-child(4n) {
  background: #ffffff;
}

.recommend-grid span {
  display: block;
  width: 52px;
  height: 52px;
  margin: 0 auto 10px;
  overflow: hidden;
  color: transparent;
  background-color: transparent;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  border-radius: 0;
  font-size: 0;
}

.recommend-grid article:nth-child(1) span {
  background-image: url("img/ico_01.png");
}

.recommend-grid article:nth-child(2) span {
  background-image: url("img/ico_02.png");
}

.recommend-grid article:nth-child(3) span {
  background-image: url("img/ico_03.png");
}

.recommend-grid article:nth-child(4) span {
  background-image: url("img/ico_04.png");
}

.recommend-grid article:nth-child(5) span {
  background-image: url("img/ico_05.png");
}

.recommend-grid article:nth-child(6) span {
  background-image: url("img/ico_06.png");
}

.recommend-grid article:nth-child(7) span {
  background-image: url("img/ico_07.png");
}

.recommend-grid article:nth-child(8) span {
  background-image: url("img/ico_08.png");
}

.recommend-grid article:nth-child(9) span {
  background-image: url("img/ico_09.png");
}

.reasons {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 34px;
  align-items: center;
}

.reasons-title h2 > span:not(.reason-count) {
  display: block;
  margin-bottom: -6px;
  color: var(--ink);
  font-family: Georgia, serif;
  font-size: 112px;
  font-weight: 400;
  line-height: 0.9;
}

.reason-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.reason-card {
  position: relative;
  min-height: 380px;
  padding: 150px 32px 30px;
  background: #fff;
  border: 1px solid #eef0f2;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.reason-card strong {
  position: absolute;
  top: 70px;
  left: 28px;
  font-family: Georgia, serif;
  font-size: 56px;
  font-weight: 400;
  line-height: 1;
}

.reason-card h3 {
  margin: 0 0 12px;
  font-size: 20px;
}

/* 2026-09-27: :not()は詳細度が上がり、後方の.course-card h3,small,p,.chips{margin-left/right:28px}
   より強く効いてしまい横余白が消える回帰を起こしていた。詳細度0の:where()で除外に変更し、
   元のカスケード順(後方の28pxルールが勝つ)を復元。 */
.reason-card p:where(:not(.section-kicker)),
.course-intro p:where(:not(.section-kicker)),
.course-card p:where(:not(.section-kicker)) {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.green strong,
.green h3 {
  color: var(--green);
}

.blue strong,
.blue h3 {
  color: var(--blue);
}

.pink strong,
.pink h3 {
  color: var(--pink);
}

.reason-photo {
  position: absolute;
  top: 0;
  right: 0;
  width: 64%;
  height: 138px;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  border-radius: 0 0 0 54px;
}

.photo-reason-one {
  background-image: url("img/01.webp");
}

.photo-reason-two {
  background-image: url("img/02.webp");
}

.photo-reason-three {
  background-image: url("img/03.webp");
}

.courses {
  position: relative;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 40px;
}

.courses::before {
  content: "COURSE";
  position: absolute;
  left: 0;
  top: -52px;
  z-index: -1;
  color: rgba(7, 24, 51, 0.035);
  font-family: Georgia, serif;
  font-size: clamp(96px, 15vw, 190px);
  line-height: 1;
}

/* 2026-09-28: SPファースト方針により、この透かしをSPでも表示(以前はPC限定)。
   font-sizeのみPC/SPで分岐(SPは375pxで実測調整)。 */
#courses .course-intro:before {
  position: absolute;
  left: 0;
  right: 0;
  z-index: -1;
  color: rgba(31, 63, 54, 0.04);
  content: "COURSE";
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  pointer-events: none;
}

@media (min-width: 641px) {
  #courses .course-intro:before {
    bottom: -2rem;
    font-size: clamp(92px, 14vw, 184px);
  }
}

@media (max-width: 640px) {
  #courses .course-intro:before {
    bottom: 2rem;
    font-size: 88px;
  }
}

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

.course-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid #edf0f2;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* 2026-09-27: SPでcourse-cardのテキスト左揃えを明示(既定値left依存を避け意図を明文化)。 */
@media (max-width: 640px) {
  .course-card {
    text-align: left;
  }
}

.course-card.high {
  background: #faf8f9;
}

.course-card.junior {
  background: #fbfbfb;
}

.course-card.elementary {
  background: #fafafa;
}

.course-image {
  height: 180px;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
}

.photo-course-one {
  background-image: url("img/syou.webp");
}

.photo-course-two {
  background-image: url("img/tyuu.webp");
}

.photo-course-three {
  background-image: url("img/kou.webp");
}

.course-card h3,
.course-card small,
.course-card p,
.chips {
  margin-left: 28px;
  margin-right: 28px;
}

.course-card h3 {
  margin-top: 26px;
  margin-bottom: 0;
  font-size: 20px;
}

.course-card small {
  display: block;
  margin-top: 0;
  margin-bottom: 16px;
  color: #6c94ce;
  font-family: Georgia, serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.elementary h3,
.elementary small {
  color: var(--green);
}

.high h3,
.high small {
  color: var(--pink);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 22px;
  margin-bottom: 28px;
}

.course-card .chips {
  flex-wrap: nowrap;
  gap: 5px;
}

.chips span,
.school-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: #536072;
  background: #f5f7f8;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.results-voice {
  position: relative;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 46px;
  align-items: center;
}

.results,
.voice,
.results-voice > * {
  min-width: 0;
}

.results-voice::after {
  right: 0;
  bottom: 50px;
  z-index: -1;
  width: 520px;
  height: 220px;
}

.extra-sections {
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px clamp(22px, 5vw, 56px) 82px;
}

.extra-head {
  margin-bottom: 28px;
}

.extra-head h2 {
  margin: 0;
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.5;
  font-weight: 900;
}


.note {
  margin: 0 0 12px;
  color: var(--muted);
  font-weight: 700;
}


.school-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.voice-slider {
  position: relative;
  overflow: hidden;
  padding: 0 56px;
}

.voice-cards {
  display: flex;
  gap: 16px;
  align-items: stretch;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.voice-card {
  flex: 0 0 100%;
  min-width: 0;
  padding: 18px;
  background: #fff;
  border: 1px solid #eef0f2;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transform: scale(0.9);
  opacity: 0.68;
  transform-origin: center center;
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.55s ease, box-shadow 0.3s ease;
}

.voice-card.is-active {
  transform: scale(1);
  opacity: 1;
}

.voice-photo {
  width: 86px;
  aspect-ratio: 1;
  margin-bottom: 10px;
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  border-radius: 50%;
}

/* 体験記アイコン差し替え 2026-07-04: voice01〜07.png(破損)→ voice-success-01〜07.png(新規イラスト)。
   07は同日追加分(ChatGPT Image 2026年7月4日 17_54_34.png)で7枚コンプリート */
.photo-voice-1 { background-image: url("img/voice-success-06.webp"); }
.photo-voice-2 { background-image: url("img/voice-success-02.webp"); }
.photo-voice-3 { background-image: url("img/voice-success-03.webp"); }
.photo-voice-4 { background-image: url("img/voice-success-04.webp"); }
.photo-voice-5 { background-image: url("img/voice-success-05.webp"); }
.photo-voice-6 { background-image: url("img/voice-success-01.webp"); }
.photo-voice-7 { background-image: url("img/voice-success-07.webp"); }


.voice-card > p > span {
  display: block;
}

.voice-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
}

.voice-control {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: var(--green);
  background: rgba(255,255,255,0.92);
  border: 1px solid #dbe6dc;
  border-radius: 50%;
  box-shadow: 0 8px 20px rgba(21, 38, 62, 0.12);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
  transition: transform 0.2s ease, background 0.2s ease;
  backdrop-filter: blur(4px);
}

.voice-control.prev,
.voice-control.next {
  position: absolute;
  top: 50%;
  z-index: 10;
  transform: translateY(-50%);
}

.voice-control.prev { left: 6px; }
.voice-control.next { right: 6px; }

.voice-control.prev:hover,
.voice-control.next:hover {
  background: var(--green-soft);
  transform: translateY(calc(-50% - 2px));
}

.voice-dots {
  display: flex;
  gap: 8px;
  align-items: center;
}

.voice-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  background: #d8dde2;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}

.voice-dot.active {
  background: var(--green);
}

/* 2026-09-27: 共通CTA B案(灯台・海の背景1枚カード)。既存の.cta/.cta-photo/.cta-copy/.cta-actions
   構造は維持し、.cta-photoを列から外してカード全体の背景に、.cta-copy/.cta-actionsは
   右寄せの縦積みへ変更(左側の灯台と文字・ボタンが競合しないよう右側に配置)。 */
.cta {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  gap: 14px;
  min-height: 300px;
  margin-top: 20px;
  padding: 40px clamp(24px, 6vw, 72px);
  border-radius: 28px;
  overflow: hidden;
}

/* 2026-09-27: PCでコピーがカード右端に寄りすぎていたため、ACCESSセクションの左ライン
   (.access-grid、max-width:1140px中央寄せ)とコピーの左端がおおよそ揃うようpadding-rightのみ
   拡大(padding-leftは変更しない。.ctaはalign-items:flex-endのためpadding-rightのみが
   コピーの左端位置を左右する)。実測(1440px幅でACCESS左端x≈142.5px、コピー幅480px固定)から
   逆算: padding-right ≈ 50vw + 90px。ただしこの値は1280px未満の幅では.cta-copyの
   min-width:480px(PC)を割り込み左側が.cta{overflow:hidden}でクリップされるため、
   安全な最小幅を確保できる1280px以上のみ適用。 */
@media (min-width: 1280px) {
  .cta {
    padding-right: clamp(72px, calc(22vw + 90px), 1400px);
  }
}

/* 2026-09-27: ユーザー指定、PC限定の追加調整。 */
@media (min-width: 641px) {
  .cta {
    margin: 1rem;
  }
}

/* 2026-09-27: 背景画像が強いため白半透明レイヤーを重ねてトーンを落とす(文字・ボタン自体のopacityは維持)。 */
.cta-photo {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.1)),
    url("img/cta-bg-pc.webp");
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
}

@media (max-width: 640px) {
  .cta-photo {
    background-image:
      linear-gradient(rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.1)),
      url("img/cta-bg-sp.webp");
  }
}

.cta-copy {
  position: relative;
  z-index: 1;
  max-width: 480px;
  text-align: left;
}

/* 2026-09-27: SPでコピー領域を広く取り、見出し・サブテキストの収まりを改善。
   ユーザー指定の min-width:480px は375px幅で-129pxはみ出し(カードのoverflow:hiddenで
   見た目上は左側が欠けて見える)ため採用不可。同じ意図を安全に実現するため、
   SPのみ利用可能幅いっぱいに広げるwidth:100%へ変更(375/390/430pxで横スクロールなし確認済み)。
   PCはSPの指定を引きずらないようmin-width:autoを明示。 */
@media (max-width: 640px) {
  .cta-copy {
    width: 100%;
  }
}

@media (min-width: 641px) {
  .cta-copy {
    min-width: auto;
  }
}

/* 2026-09-27: .fade-up.visibleは全ページ共通のスクロール表示クラスのため、
   他箇所への影響を避けCTA(.cta-copy.fade-up)限定でスコープ。PCのみコピー領域を
   480pxまで広げ、SPはautoに戻す(SP用width:100%は上のブロックで別途対応済み)。 */
@media (min-width: 641px) {
  .cta .fade-up.visible {
    min-width: 480px;
  }
}

@media (max-width: 640px) {
  .cta .fade-up.visible {
    min-width: auto;
  }
}

.cta h2 {
  font-size: clamp(30px, 3.2vw, 46px);
  line-height: 1.3;
  word-break: keep-all;
}

.cta-lead {
  margin: 10px 0 0;
  color: #2c4a5e;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.7;
}

.cta-actions {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  width: 100%;
  max-width: 480px;
}

.phone,
.form {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 82px;
  padding: 12px 20px;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 900;
  text-align: center;
}

/* 2026-09-27: CTA主従ボタン入れ替え(体験授業=主/緑塗り、電話=副/白地緑枠)。ユーザー指定。 */
.form {
  color: #fff;
  background: var(--green);
  border: 1px solid var(--green);
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

/* 2026-09-29: opacity:0.85のみで色変化が無かったため反転に統一。
   通常=緑背景+白文字 → hover=白背景+緑文字。borderは通常時から緑で用意しておき
   (緑背景と同色のため通常時は見た目に影響なし)、hoverで白背景になっても輪郭が消えないようにする。 */
.form:hover,
.form:focus-visible {
  color: var(--green);
  background: #fff;
  transform: translateY(-2px);
}

.phone svg { flex-shrink: 0; }

.form svg { flex-shrink: 0; }

.footer {
  display: grid;
  grid-template-columns: minmax(160px, 0.75fr) minmax(240px, 1.1fr) minmax(420px, 2fr) 42px;
  align-items: start;
  gap: 42px;
  padding: 34px clamp(22px, 6vw, 92px);
  background: #fff;
}

.footer address {
  color: #647084;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 24px;
}

.footer-links h3 {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 12px;
}

.footer-links a {
  display: block;
  margin: 0 0 7px;
  color: #647084;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.footer-links a:hover {
  color: var(--green);
}

.footer .footer-copyright {
  grid-column: 1 / -1;
  margin: 18px 0 0;
  padding-top: 18px;
  border-top: 1px solid rgba(100, 112, 132, 0.15);
  /* 2026-09-27: コピーライト文字色をユーザー指定の#555へ(PC/SP共通) */
  color: #555;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
}

.footer-links h3 > a {
  margin: 0;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  text-decoration: none;
}

body:not(.lower-page) .access-section {
  position: relative;
  padding: clamp(40px, 5vw, 64px) clamp(22px, 5vw, 56px);
  background: #fbfaf3;
  scroll-margin-top: 88px;
}

body:not(.lower-page) .access-info > .extra-head {
  max-width: none;
  margin: 0 0 20px;
  text-align: left;
}

body:not(.lower-page) .access-info > .extra-head .section-kicker {
  margin: 0 0 8px;
}

body:not(.lower-page) .access-section .extra-head h3 {
  margin: 0;
  font-size: clamp(22px, 2.4vw, 32px);
}

body:not(.lower-page) .access-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.62fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 68px);
  align-items: center;
  max-width: 1140px;
  margin: 0 auto;
}

body:not(.lower-page) .access-info-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

body:not(.lower-page) .access-info-list li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 6px 0;
  color: #333;
  font-size: 15px;
  line-height: 1.75;
}

body:not(.lower-page) .access-info-list svg {
  width: 22px;
  height: 22px;
  margin: 0 auto;
  color: var(--green);
}

body:not(.lower-page) .access-map-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(91, 149, 90, 0.18);
  border-radius: 22px;
  box-shadow: 0 14px 34px rgba(31, 63, 54, 0.1);
}

body:not(.lower-page) .access-map-img {
  display: block;
  width: 100%;
  height: auto;
}

body:not(.lower-page) .access-map-logo {
  position: absolute;
  top: 51%;
  left: 31.5%;
  width: 16%;
  height: auto;
  pointer-events: none;
}

/* 2026-09-27: ユーザー指定、PC限定でロゴ位置を微調整。SPはbaseの51%/31.5%を維持。 */
@media (min-width: 641px) {
  body:not(.lower-page) .access-map-logo {
    top: 42%;
    left: 32.5%;
  }
}

/* 2026-09-27: 静的マップ画像の下に「Googleマップで見る」外部リンクを追加(ユーザー指定) */
body:not(.lower-page) .access-map-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  color: var(--green);
  border-top: 1px solid rgba(91, 149, 90, 0.18);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

body:not(.lower-page) .access-map-link:hover,
body:not(.lower-page) .access-map-link:focus-visible {
  background: rgba(91, 149, 90, 0.08);
}

@media (max-width: 700px) {
  body:not(.lower-page) .access-section {
    padding-block: 40px;
    scroll-margin-top: 72px;
  }

  body:not(.lower-page) .access-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  body:not(.lower-page) .access-map-wrap {
    border-radius: 16px;
  }

  /* 2026-09-27: 旧SP専用値(top:37.5%/left:32.5%)は地図画像の吹き出し枠から
     大きく上にズレていた(ピクセル解析で確認: 枠の中心はtop約58.6%/left約40%)。
     image は width:100%;height:auto で比率固定のため、PC/SPで別値にする理由がなく、
     base の top:51%/left:31.5%(吹き出し枠にほぼ一致)へ統一しSP専用上書きを撤去。 */
}

body:not(.lower-page) .footer-links h3 > a,
body.mp-v2 .footer-links h3 > a {
  color: inherit;
  font-weight: inherit;
}

.page-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 200;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  color: #fff;
  background: var(--green);
  border-radius: 50%;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
  transition: opacity 0.3s, transform 0.3s;
}

.page-top:hover {
  opacity: 0.85;
  transform: translateY(-3px);
  color: #ffeb3b;
}

/* ===== HAMBURGER + MOBILE NAV ===== */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 7px;
  flex-shrink: 0;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.32s ease, opacity 0.2s ease;
  transform-origin: center;
}

.nav-hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 9000;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(14px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  transform: translateX(100%);
  transition: transform 0.38s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.mobile-nav.is-open {
  transform: translateX(0);
  pointer-events: auto;
}

.mobile-nav-close {
  position: absolute;
  top: 20px;
  right: 22px;
  background: none;
  border: none;
  font-size: 28px;
  color: var(--ink);
  cursor: pointer;
  line-height: 1;
  padding: 6px;
}

/* 2026-09-27: footerリンクと同じ考え方で、リンク全幅をタップ領域にし、
   上下paddingと区切り線でタップ可能な範囲を明示(ユーザー指定)。 */
.mobile-nav nav {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100%;
  max-width: 320px;
  gap: 0;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 16px 6px;
  min-height: 52px;
  border-bottom: 1px solid rgba(100, 112, 132, 0.15);
  font-size: 16px;
  font-weight: 800;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.2s;
}

.mobile-nav-link::after {
  content: "›";
  margin-left: auto;
  padding-left: 8px;
  color: rgba(100, 112, 132, 0.5);
}

.mobile-nav nav a.mobile-nav-link:last-of-type {
  border-bottom: none;
}

.mobile-nav-link:hover { color: var(--green); }

.mobile-nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 36px;
  border-radius: 999px;
  background: var(--green);
  color: #fff !important;
  font-size: 16px;
  font-weight: 800;
  text-decoration: none;
  margin-top: 4px;
  transition: opacity 0.2s, transform 0.2s;
}

.mobile-nav-cta:hover {
  opacity: 0.85;
  transform: translateY(-2px);
}

@media (max-width: 980px) {
  .nav-hamburger { display: flex; }
  .nav-cta { display: none; }
}
/* ===== END HAMBURGER + MOBILE NAV ===== */

@media (max-width: 980px) {
  .site-header {
    padding: 12px 22px;
  }

  .desktop-nav {
    display: none;
  }

  .nav-cta {
    margin-left: auto;
  }

  .hero,
  .message,
  .recommend,
  .reasons,
  .courses,
  .results-voice,
  .cta {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 34px;
  }

  .hero-visual {
    inset: 0 !important;
    min-height: 0 !important;
  }

  .recommend-grid,
  .reason-cards,
  .course-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .course-intro {
    max-width: 560px;
  }


  .cta {
    gap: 0;
  }

  .cta-copy,
  .cta-actions {
    padding: 28px 22px;
  }

  .cta h2 {
    max-width: 12em;
  }

  .voice-card {
    flex-basis: calc((100% - 16px) / 2);
  }

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

@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons {
    display: grid;
    grid-template-columns: 285px minmax(0, 760px);
    gap: clamp(42px, 7vw, 92px);
    align-content: center;
    align-items: center;
    justify-content: center;
  }

  .reasons-sticky-wrap .reasons-title {
    position: sticky;
    top: 50%;
    width: 285px;
    margin: 0;
    transform: translateY(-50%);
    align-self: center;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    display: block;
    margin: 0 0 2px;
    font-size: 104px;
    line-height: 0.85;
  }

  .reasons-sticky-wrap .reason-cards {
    max-width: 760px;
    height: 440px;
  }


}

@media (max-width: 640px) {





  .hero-visual {
    margin: -64px 0 0 -22px !important;
    height: clamp(278px, 50svh, 360px) !important;
  }

  .photo-hero {
    inset: -76px -14px 0 -14px !important;
    height: calc(100% + 78px) !important;
    background-position: center top !important;
  }



  .hero-actions {
    gap: 14px !important;
  }

  .message:not(.message--video) > .portrait-wrap {
    margin-top: -24px !important;
    margin-bottom: 28px !important;
  }

  .message-copy > p:not(.section-kicker):not(.signature) {
    margin-top: 28px !important;
  }


  .recommend-grid article {
    font-size: 12px !important;
    line-height: 1.55 !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
  }


  .results-voice {
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  .voice-slider-outer {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

}





@media (max-width: 640px) {
  .nav-hamburger {
    margin-left: auto !important;
  }


}

@media (max-width: 640px) {

  .message-copy > p:not(.section-kicker):not(.signature) {
    margin-top: 36px !important;
  }


  .voice-slider-outer:not(.top-voice-slider) .voice-slider {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .voice-card:not(.top-voice-card),
  .voice-card.main:not(.top-voice-card) {
    width: calc(100% - 1rem) !important;
    flex: 0 0 calc(100% - 1rem) !important;
    margin-left: 0.5rem !important;
    margin-right: 0.5rem !important;
  }

  /* 2026-09-29: voice/success.html等、.voice-cardsがgrid化されたページ(PR-TOP22/24)では
     上記のcarousel用margin(0.5rem)が不要な左右ズレとして残るため0に統一。
     あわせて.voice-story(display:grid、列指定なし)がテキストのmax-content分だけ
     親幅を超えて広がり本文だけ右にはみ出す不具合を、minmax(0, 1fr)で親幅にクランプして修正。 */
  .voice-card:not(.top-voice-card),
  .voice-card.main:not(.top-voice-card) {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  .voice-card:not(.top-voice-card) .voice-story,
  .voice-card.main:not(.top-voice-card) .voice-story {
    grid-template-columns: minmax(0, 1fr) !important;
  }

}

/* TOP additional visual fixes 2026-07-03 */
body:not(.lower-page) .hero-copy {
  max-width: min(540px, 48vw);
}

body:not(.lower-page) .hero-stats {
  position: absolute !important;
  inset: 0 !important;
  z-index: 2 !important;
  pointer-events: none !important;
}

/* 2026-10-24: 実績バッジ3つは、FV画像(.photo-hero)の表示領域を基準に置く(画像の幅・位置が変わっても相対位置が保たれる)。
   旧: 画面幅のclampで右・上を指定 → FV画像の差し替え後に顔や右端へずれたため、画像の絵に対する比率で置く。
   女の子の右側に、右へ少し張り出す弧(B=中段が最も右、A=上段・C=下段がやや内側)としてひとまとまりに並べる。
   B(中段)は画像の縦41%、A・Cはそこから上下へ等間隔(画像の高さの23.4%、ただしバッジ高さ+24pxを下回らない)。
   バッジの中心を --fx(横。0〜1=画像の左端〜右端)・上の基準に合わせる。
   画像の表示サイズ --fv-w は .photo-hero の background-size(min(88.6%, 775px) auto)と同じ値、縦位置は 55%(下に寄せている)。
   SP(640px以下)は縦並びのグリッド表示のため対象外 */
@media (min-width: 641px) {
  body:not(.lower-page) .hero-stats {
    --fv-w: min(88.6%, 775px);
    --fv-h: calc(var(--fv-w) / 1.25);
    --fv-step: max(calc(var(--fv-h) * 0.234), 145px);
  }

  body:not(.lower-page) .hero-stats .stat-card {
    left: calc(100% - 9px - var(--fv-w) * (1 - var(--fx))) !important;
    right: auto !important;
    bottom: auto !important;
    top: 55% !important;
    margin-top: calc(var(--fv-h) * (0.41 - 0.55) + var(--dy)) !important;
    transform: translate(-50%, -50%) !important;
  }

  body:not(.lower-page) .stat-a { --fx: 0.84; --dy: calc(var(--fv-step) * -1); }
  body:not(.lower-page) .stat-b { --fx: 0.9; --dy: 0px; }
  body:not(.lower-page) .stat-c { --fx: 0.84; --dy: var(--fv-step); }
}


@media (max-width: 980px) {
  body:not(.lower-page) .hero-copy {
    max-width: min(520px, 60vw);
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) {
    display: grid;
    grid-template-columns: 1fr;
    gap: 28px !important;
  }

  body:not(.lower-page) .results-voice .results,
  body:not(.lower-page) .results-voice .admission-index,
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    grid-column: 1 !important;
  }

}

@media (max-width: 640px) {
  body:not(.lower-page) .hero {
    min-height: 350px !important;
  }

  body:not(.lower-page) .hero-copy {
    max-width: min(290px, 76vw);
  }

  body:not(.lower-page) .stat-card {
    width: clamp(76px, 22vw, 92px) !important;
  }

  body:not(.lower-page) .stat-a {
    top: 18px !important;
    right: clamp(86px, 25vw, 108px) !important;
  }

  body:not(.lower-page) .stat-b {
    top: 108px !important;
    right: 4px !important;
  }

  body:not(.lower-page) .stat-c {
    top: 196px !important;
    right: clamp(72px, 20vw, 96px) !important;
  }

  body:not(.lower-page) .flow-photos {
    background-position: center top;
  }

  /* 2026-09-27: 共通CTA B案(mp-v2と同一デザイン思想)。旧: 写真172px固定+ズーム+
     ::afterで暗幕+ボタンだけ白帯に分離、というTOP独自レイアウトを撤去し、
     下層ページ(body.mp-v2)と同じ「1枚カードに背景・見出し・サブテキスト・
     ボタンを重ねる」構成へ統一。 */
  body:not(.lower-page) .cta {
    overflow: hidden;
    border-radius: 20px;
    margin: 1rem;
  }
}

/* TOP pre-WP visual fixes 2026-07-03 */
body:not(.lower-page) .hero {
  overflow: hidden;
}

body:not(.lower-page) {
  overflow: visible !important;
}

body:not(.lower-page) .hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

body:not(.lower-page) .hero-copy,
body:not(.lower-page) .hero-stats,
body:not(.lower-page) .hero-actions {
  position: relative;
  z-index: 3;
}

body:not(.lower-page) .hero-visual {
  position: relative;
  z-index: 0;
}

body:not(.lower-page) .phone {
  border: 1px solid rgba(7, 24, 51, 0.08);
}

body:not(.lower-page) .mobile-nav {
  width: 100vw;
  max-width: 100vw;
  overflow: hidden;
  contain: paint;
}

body:not(.lower-page) .voice-slider-outer,
body:not(.lower-page) .voice-slider {
  max-width: 100%;
  overflow: hidden;
  contain: paint;
}

body:not(.lower-page) #bgBlobs {
  width: 100vw;
  max-width: 100vw;
  overflow: hidden;
  contain: paint;
}

body:not(.lower-page) .mobile-nav:not(.is-open) {
  visibility: hidden;
  opacity: 0;
  transform: translateX(0);
}

body:not(.lower-page) .mobile-nav.is-open {
  visibility: visible;
  opacity: 1;
}

@media (max-width: 640px) {
  body:not(.lower-page) #bgBlobs {
    display: none;
  }

  body:not(.lower-page) .hero {
    contain: paint;
  }

  body:not(.lower-page) {
    overflow-x: hidden !important;
    overflow-y: auto !important;
  }

  body:not(.lower-page) .flow-photos,
  body:not(.lower-page) .portrait-wrap,
  body:not(.lower-page) .photo-portrait {
    width: 100% !important;
    max-width: 100% !important;
  }

}

/* TOP page final cascade fixes 2026-06-20 */
body:not(.lower-page) .recommend-grid article:nth-child(10) span {
  background-image: url("img/ico_10.png") !important;
}

body:not(.lower-page) .course-image {
  height: clamp(168px, 15vw, 210px) !important;
  background-size: cover;
  background-position: center !important;
}

body:not(.lower-page) .photo-course-one { background-position: center 38% !important; }
body:not(.lower-page) .photo-course-two { background-position: center 34% !important; }
body:not(.lower-page) .photo-course-three { background-position: center 36% !important; }

body:not(.lower-page) .voice-card .voice-photo {
  display: block !important;
  background-size: cover !important;
  background-position: center !important;
  background-color: var(--green-soft) !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
  position: relative !important;
  z-index: 2 !important;
  margin-top: 28px !important;
  padding: 24px !important;
  background: rgba(255, 255, 255, 0.92) !important;
  border: 1px solid rgba(120, 178, 99, 0.2) !important;
  border-radius: 24px !important;
  box-shadow: 0 14px 36px rgba(22, 38, 55, 0.08) !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index > h3 {
  margin: 2px 0 8px !important;
  color: #74364f !important;
  font-size: clamp(22px, 2.1vw, 30px) !important;
  line-height: 1.35 !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index-lead {
  margin: 0 0 16px !important;
  color: var(--muted) !important;
  font-size: 14px !important;
  line-height: 1.8 !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index-list {
  display: grid !important;
  gap: 10px !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked):not(.top-voice-restored) .admission-index-list a {
  display: flex !important;
  justify-content: space-between !important;
  gap: 12px !important;
  padding: 12px 14px !important;
  color: #74364f !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  text-decoration: none !important;
  background: #fff !important;
  border: 1px solid #edf0f2 !important;
  border-radius: 999px !important;
  box-shadow: 0 8px 22px rgba(22, 38, 55, 0.05) !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked):not(.top-voice-restored) .admission-index-list a::after {
  content: "→";
  color: #b85b82;
}



body:not(.lower-page) .flow-photos {
  display: block !important;
  position: relative !important;
  height: min(62svh, 560px) !important;
  min-height: 420px !important;
  overflow: hidden !important;
  border-radius: 34px !important;
  background: var(--green-soft) !important;
  box-shadow: var(--shadow) !important;
}






body:not(.lower-page) .footer-social a::before {
  content: "↗" !important;
  margin-right: 0.35em !important;
  color: var(--green) !important;
}

@media (max-width: 980px) {
  body:not(.lower-page) .reasons-sticky-wrap .reason-cards {
    position: relative !important;
    display: block !important;
    height: 560px !important;
  }

  body:not(.lower-page) .flow-section {
    min-height: 0 !important;
  }

  body:not(.lower-page) .flow-sticky {
    position: relative !important;
    top: auto !important;
    grid-template-columns: 1fr !important;
  }

  body:not(.lower-page) .flow-photos {
    height: auto !important;
    min-height: 260px !important;
    aspect-ratio: 16 / 10 !important;
  }



  body:not(.lower-page) .footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 640px) {

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    padding: 20px !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked):not(.top-voice-restored) .admission-index-list a {
    display: block !important;
    border-radius: 18px !important;
    line-height: 1.65 !important;
  }

  body:not(.lower-page) .footer-links {
    grid-template-columns: 1fr !important;
  }
}





@media (max-width: 640px) {
  .recommend-grid {
    gap: 20px 20px !important;
  }

}



@media (min-width: 981px) {
  .message:not(.message--video) {
    grid-template-columns: minmax(380px, 540px) minmax(360px, 560px) !important;
    gap: clamp(52px, 7vw, 96px) !important;
  }

  .message:not(.message--video) > .portrait-wrap {
    min-height: 470px !important;
  }

  .photo-portrait {
    width: min(112%, 760px) !important;
    min-height: 500px !important;
    margin-left: -42px !important;
  }
}

@media (max-width: 980px) {
  .nav-hamburger {
    margin-left: auto !important;
  }
}

@media (max-width: 640px) {
  .recommend-grid {
    grid-template-columns: repeat(2, 154px) !important;
    gap: 18px 18px !important;
  }

  .recommend-grid article {
    width: 154px !important;
  }


}

/* Absolute smartphone layout fixes */
@media (max-width: 640px) {
  .hero-visual {
    margin: -34px 0 0 -34px !important;
    height: clamp(270px, 48svh, 350px) !important;
  }

  .photo-hero {
    inset: -42px -16px 0 -24px !important;
    height: calc(100% + 44px) !important;
  }

  .message:not(.message--video) {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "kicker"
      "title"
      "portrait"
      "body"
      "body2"
      "sign" !important;
    gap: 0 !important;
    padding-top: 8px !important;
  }

  .message:not(.message--video) .message-copy {
    display: contents !important;
  }

  .message:not(.message--video) .message-copy .section-kicker {
    grid-area: kicker !important;
    position: relative !important;
    z-index: 4 !important;
    margin: 0 0 4px !important;
  }

  /* 2026-09-26: 下層で見出しが画像に-30px重なっていたバグを修正。
     旧: margin:0 0 -30px はTOPのみ body:not(.lower-page)で1remに補正されていたが、
     下層(lower-page)には効いておらず見出し→画像が重なっていた。
     下層・TOP共通でmargin-bottom:1remへ統一(ページスコープなし)。 */
  .message:not(.message--video) .message-copy h2 {
    grid-area: title !important;
    position: relative !important;
    z-index: 4 !important;
    margin: 0 0 1rem !important;
    padding: 0 2px !important;
    text-shadow:
      0 2px 0 rgba(255, 255, 255, 0.96),
      0 0 18px rgba(255, 255, 255, 0.92) !important;
  }

  /* 2026-09-27: translateX(22px)が画像を右へ寄せ、左側に44px・右側0pxの非対称な余白を
     作っていた(横ズレ)。translateX(0)でmessage本文と同じ左右対称の余白に統一。 */
  .message:not(.message--video) > .portrait-wrap {
    grid-area: portrait !important;
    min-height: 306px !important;
    margin: 0 -22px 8px 0 !important;
    transform: translateX(0) !important;
  }

  .photo-portrait {
    min-height: 318px !important;
    background-position: right bottom !important;
  }

  .message:not(.message--video) .message-copy > p:not(.section-kicker):not(.signature) {
    grid-area: body !important;
    position: relative !important;
    z-index: 3 !important;
    margin-top: 0 !important;
  }

  /* 2026-09-26: message本文が2段落あるページ(record/voice-success等)で、
     2段落目も同じ grid-area:body に割り当たり1段落目と完全に重なっていたバグを修正。
     2段落目以降は body2 エリアへ分離し、縦に積む。 */
  .message:not(.message--video) .message-copy > p:not(.section-kicker):not(.signature) ~ p:not(.section-kicker):not(.signature) {
    grid-area: body2 !important;
    margin-top: 16px !important;
  }

  .message:not(.message--video) .message-copy .signature {
    grid-area: sign !important;
  }

  .recommend-grid {
    grid-template-columns: repeat(2, 154px) !important;
    justify-content: center !important;
    gap: 12px !important;
  }

  .recommend-grid article {
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
    font-size: 13px !important;
    line-height: 1.55 !important;
    word-break: keep-all !important;
    overflow-wrap: normal !important;
  }

  .recommend-grid span {
    width: 38px !important;
    height: 38px !important;
    margin-bottom: 5px !important;
  }

  .reasons-sticky-wrap .reasons {
    justify-content: flex-start !important;
    align-items: stretch !important;
    height: 100svh !important;
    padding: 24px 18px 12px !important;
  }

  .reasons-sticky-wrap .reasons-title {
    display: block !important;
    flex: 0 0 auto !important;
    margin-bottom: 12px !important;
  }


  .reasons-sticky-wrap .reason-cards {
    width: 100% !important;
    height: min(59svh, 455px) !important;
    max-height: calc(100svh - 178px) !important;
  }

  .results-voice {
    width: 100% !important;
    max-width: none !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  .voice {
    width: 100% !important;
    margin-top: 48px !important;
  }

  .voice-slider-outer {
    position: relative !important;
    display: block !important;
    gap: 0 !important;
    margin-left: -8px !important;
    margin-right: -8px !important;
  }

  .voice-slider-outer:not(.top-voice-slider) .voice-slider {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }


  .voice-slider-outer .voice-control.prev,
  .voice-slider-outer .voice-control.next {
    position: absolute !important;
    top: 50% !important;
    z-index: 5 !important;
    transform: translateY(-50%) !important;
    background: none !important;
    backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
  }

  .voice-slider-outer .voice-control.prev {
    left: -0.8rem !important;
    margin: 0 !important;
  }

  .voice-slider-outer .voice-control.next {
    right: -0.6rem !important;
    margin: 0 !important;
  }

}





@media (max-width: 640px) {
  .recommend-grid article {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    text-align: center !important;
  }

  .recommend-grid span {
    margin: 0 auto 6px !important;
  }

}

/* Absolute smartphone final overrides */
@media (max-width: 640px) {

  body:not(.lower-page) .reasons-sticky-wrap {
    height: 240vh !important;
  }

  .hero-visual {
    height: clamp(230px, 43svh, 310px) !important;
    margin-left: -20px !important;
    overflow: visible !important;
  }

  .photo-hero {
    inset: -6px -10px 0 -18px !important;
    width: calc(100% + 28px) !important;
    height: calc(100% + 10px) !important;
    background-size: contain !important;
    background-position: center bottom !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .hero-actions .button {
    min-height: 38px !important;
  }

  /* 2026-09-26: 旧margin-bottom:-72pxが本文を画像下部へ重ねていたバグを修正(min-height/margin削除、transformのみ残す) */
  /* 2026-09-27: translateX(0)へ統一(横ズレ修正、詳細は2105行目コメント参照) */
  .message:not(.message--video) > .portrait-wrap {
    transform: translateX(0) !important;
  }



  .message-copy h2 {
    margin-top: 0 !important;
    font-size: clamp(22px, 6.2vw, 28px) !important;
    line-height: 1.55 !important;
  }

  .reasons-sticky-wrap .reasons-title {
    margin-bottom: 8px !important;
  }

  .reasons-sticky-wrap .reason-cards {
    height: min(56svh, 430px) !important;
  }

  .reasons-sticky-wrap .reason-card {
    height: 100% !important;
    min-height: 0 !important;
    padding: 156px 22px 18px !important;
  }



}

/* Smartphone refinements */
@media (max-width: 640px) {

  .hero h1 {
    font-size: clamp(26px, 7.4vw, 32px) !important;
    line-height: 1.3 !important;
  }

  .hero-visual {
    height: clamp(230px, 43svh, 310px) !important;
    margin-left: -20px !important;
    overflow: visible !important;
  }

  .photo-hero {
    inset: -6px -10px 0 -18px !important;
    width: calc(100% + 28px) !important;
    height: calc(100% + 10px) !important;
    background-size: contain !important;
    background-position: center bottom !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }

  .lead {
    margin-top: -4px !important;
  }

  .hero-stats {
    gap: 7px !important;
  }


  .hero-actions {
    gap: 8px !important;
    margin-top: -2px !important;
  }


  /* 2026-09-26: 同上バグ修正(重複ブロック2つ目) */
  /* 2026-09-27: translateX(0)へ統一(横ズレ修正、詳細は2105行目コメント参照) */
  .message:not(.message--video) > .portrait-wrap {
    transform: translateX(0) !important;
  }



  .message-copy h2 {
    margin-top: 0 !important;
    font-size: clamp(22px, 6.2vw, 28px) !important;
    line-height: 1.55 !important;
  }

  .reasons-sticky-wrap .reasons {
    padding: 14px 18px 10px !important;
  }

  .reasons-sticky-wrap .reasons-title h2 {
    font-size: clamp(28px, 8vw, 36px) !important;
    line-height: 1.25 !important;
  }

  .reasons-sticky-wrap .reasons-title h2 .reason-count b {
    font-size: 88px !important;
  }

  .reasons-sticky-wrap .reason-card {
    padding: 156px 22px 18px !important;
  }

  .reasons-sticky-wrap .reason-photo {
    height: 116px !important;
  }


  .reasons-sticky-wrap .reason-card h3 {
    margin-bottom: 8px !important;
  }
}

/* Final request balance tweaks */
body:not(.lower-page) .recommend-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  justify-content: center !important;
  gap: 20px !important;
}

.recommend-grid article {
  width: auto !important;
  min-height: 140px !important;
  padding: 22px 18px !important;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count::first-letter {
  font-size: 104px !important;
  line-height: 0.85 !important;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count b {
  color: var(--green) !important;
}

.results-voice {
  grid-template-columns: 0.72fr 1.28fr;
  gap: 34px;
  max-width: 1240px;
}

.voice-slider-outer {
  gap: 0 !important;
}

.voice-slider-outer .voice-slider {
  margin: 0 -10px !important;
}

.voice-slider-outer .voice-control.prev {
  margin-right: -18px !important;
}

.voice-slider-outer .voice-control.next {
  margin-left: -18px !important;
}



@media (max-width: 980px) {

  .results-voice {
    grid-template-columns: 1fr !important;
    max-width: 760px !important;
  }
}

@media (max-width: 640px) {
  .recommend-grid {
    grid-template-columns: repeat(2, 154px) !important;
    gap: 12px !important;
  }

  .recommend-grid article {
    grid-column: auto;
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
  }

  .reasons-sticky-wrap .reasons-title h2 .reason-count b {
    font-size: 86px !important;
  }

  .voice-slider-outer .voice-slider {
    margin: 0 -6px !important;
  }

  .voice-slider-outer .voice-control.prev {
    margin-right: -14px !important;
  }

  .voice-slider-outer .voice-control.next {
    margin-left: -14px !important;
  }

}

/* Latest balance tweaks */
body:not(.lower-page) .recommend-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  justify-content: center !important;
  gap: 20px !important;
}

.recommend-grid article {
  width: auto !important;
  min-height: 140px !important;
  padding: 22px 18px !important;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count::first-letter {
  color: var(--green) !important;
}

.voice {
  min-width: 0;
}

.voice-slider-outer {
  gap: 0 !important;
}


@media (max-width: 640px) {
  .recommend-grid {
    grid-template-columns: repeat(2, 154px) !important;
  }

  .recommend-grid article {
    grid-column: auto;
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
  }

}

/* Course color tuning */
.course-card.elementary h3,
.course-card.elementary small {
  color: var(--green) !important;
}

.course-card.junior h3,
.course-card.junior small {
  color: var(--blue) !important;
}

.course-card.high h3,
.course-card.high small {
  color: var(--pink) !important;
}

.course-card.elementary .chips span {
  color: var(--green) !important;
  background: rgba(91, 149, 90, 0.1) !important;
  border: 1px solid rgba(91, 149, 90, 0.34) !important;
}

.course-card.junior .chips span {
  color: var(--blue) !important;
  background: rgba(79, 132, 205, 0.1) !important;
  border: 1px solid rgba(79, 132, 205, 0.34) !important;
}

.course-card.high .chips span {
  color: var(--pink) !important;
  background: rgba(212, 109, 159, 0.1) !important;
  border: 1px solid rgba(212, 109, 159, 0.34) !important;
}

/* Flow: photos on the left, fixed vertical steps on the right */
.flow-section {
  max-width: none !important;
  min-height: 240vh;
  margin-bottom: 112px !important;
  padding: 0 clamp(22px, 5vw, 56px) !important;
}

.flow-sticky {
  position: sticky;
  top: 96px;
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(240px, 3fr);
  gap: clamp(34px, 6vw, 80px);
  align-items: center;
  max-width: 1160px;
  min-height: calc(100svh - 132px);
  margin: 0 auto;
}

.flow-photos {
  position: relative;
  height: min(62svh, 560px);
  min-height: 440px;
  overflow: hidden;
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.flow-photo {
  position: absolute;
  inset: 0;
  opacity: 0;
  background-position: center;
  background-size: cover;
  transition: opacity 0.6s ease, transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  transform: scale(1.03);
}

.flow-photo.active {
  opacity: 1;
  transform: scale(1);
}

.flow-photo-one {
  background-image: url("img/L74A0448.JPG");
}

.flow-photo-two {
  background-image: url("img/L74A0448.JPG");
}

.flow-photo-three {
  background-image: url("img/L74A0491.JPG");
}

.flow-panel .extra-head {
  margin: 0 0 34px;
  text-align: left;
}

.flow-panel .extra-head h3 {
  font-size: clamp(30px, 3.2vw, 42px);
}


@media (max-width: 980px) {
  .flow-section {
    min-height: 280vh;
  }

  .flow-sticky {
    position: sticky;
    top: 72px;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    gap: 20px;
    min-height: calc(100svh - 108px);
  }

  .flow-photos {
    height: min(56svh, 500px);
    min-height: 300px;
  }

  .flow-panel .extra-head {
    text-align: left;
    margin-left: 0;
    margin-right: 0;
  }
}

@media (max-width: 640px) {
  .flow-section {
    min-height: 300vh;
    padding: 0 14px !important;
  }

  /* 2026-09-27: 「教室の様子」見出しを「入塾までの流れ」と同じ.extra-head+.section-kicker+h3
     構造へ統一(ユーザー指定)。旧.flow-sp-heading独自スタイルは撤去し、共通.extra-head h3を使用。
     英字kicker「CLASSROOM」は他セクション(FLOW/ACCESS等)の命名慣習に合わせた既定値。
     配置は「入塾までの流れ」(.flow-panel .extra-head{text-align:left})と揃えて左寄せに。 */
  .flow-section > .extra-head {
    margin: 0 0 16px;
    text-align: left;
  }

  .flow-sticky {
    top: 60px;
    grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
    gap: 12px;
    min-height: calc(100svh - 88px);
  }

  .flow-photos {
    height: min(calc(100svh - 120px), 560px);
    min-height: 260px;
    border-radius: 12px;
  }

  /* 2026-09-27: 見出しサイズを可変からflat 22pxへ(ユーザー指定) */
  .flow-panel .extra-head h3 {
    font-size: 22px !important;
  }

}

/* Use cutout images as-is, without parallax or shadow treatment */
.photo-hero,
.photo-portrait {
  background-size: contain !important;
  background-repeat: no-repeat !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.photo-hero {
  background-image: url("img/mp-top-fv-03.webp") !important;
  /* 旧画像(kv_student.png)は絵が枠の約3〜88%(右端に約12%の余白)・上〜80%に収まり、-5rem ずらして右へ寄せていた。
     新画像(mp-top-fv.png)は右端・下端近くまで絵があり、同じ指定だと右側が切れ、かつ左へ張り出してコピーに重なるため、
     絵の幅が旧画像と同じ(約744px)になるよう縦横比を保ったまま約89%に収め、上・右寄せにする(透過・縦横比はそのまま) */
  background-size: min(88.6%, 775px) auto !important;
  background-position: right 9px top 55% !important; /* 少し下へ(上に余白を残す)。バッジの基準位置 .hero-stats と同じ 55% */
}

.photo-portrait {
  background-image: url("img/sensei.webp");
  background-position: center bottom;
}

.portrait-wrap::after {
  display: none !important;
}

.hero-copy,
.hero-visual {
  transform: none !important;
}

/* Reasons card final balance */
.reasons-sticky-wrap .reason-cards {
  width: min(100%, 760px) !important;
  height: 520px !important;
}

.reasons-sticky-wrap .reason-card {
  display: block !important;
  min-height: 520px;
  height: 520px;
  padding: 260px 34px 34px;
  overflow: hidden;
  background: #fff !important;
  border: 1px solid #edf0f2;
  border-radius: 8px !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.reasons-sticky-wrap .reason-photo {
  position: absolute !important;
  inset: 0 0 auto 0 !important;
  width: 100% !important;
  height: 230px;
  border-radius: 8px 8px 0 0 !important;
  background-size: cover !important;
  background-position: center !important;
}

.reasons-sticky-wrap .reason-card strong {
  position: absolute;
  left: 34px;
  z-index: 3;
  color: currentColor;
}

.reasons-sticky-wrap .reason-card h3 {
  margin: 0 0 18px !important;
  font-size: 22px !important;
  font-weight: 900;
  line-height: 1.45;
}

.reasons-sticky-wrap .reason-card p {
  color: #5d6b82 !important;
  font-size: 15px !important;
  font-weight: 800;
  line-height: 2 !important;
}

.reasons-sticky-wrap .reason-card.green {
  color: var(--green);
}

.reasons-sticky-wrap .reason-card.blue {
  color: var(--blue);
}

.reasons-sticky-wrap .reason-card.pink {
  color: var(--pink);
}

.reasons-sticky-wrap .reason-card.green h3 {
  color: var(--green);
}

.reasons-sticky-wrap .reason-card.blue h3 {
  color: var(--blue);
}

.reasons-sticky-wrap .reason-card.pink h3 {
  color: var(--pink);
}

@media (max-width: 980px) {
  .reasons-sticky-wrap .reason-card p {
    font-size: 14px !important;
    line-height: 1.85 !important;
  }
}

@media (max-width: 640px) {
  /* 2026-09-27: 980px時の14pxをそのまま維持(ユーザー指定、これ以上縮小しない) */
  .reasons-sticky-wrap .reason-card p {
    font-size: 14px !important;
    line-height: 1.8 !important;
  }
}

.reasons-sticky-wrap .reason-card > strong {
  left: 34px !important;
  right: auto !important;
  text-align: left !important;
}

@media (max-width: 980px) {
  .reasons-sticky-wrap .reason-card > strong {
    left: 24px !important;
    right: auto !important;
  }
}

@media (max-width: 640px) {
  .reasons-sticky-wrap .reason-card > strong {
    left: 22px !important;
    right: auto !important;
  }
}







/* Final requested refinements */
.section-kicker,
.stat-card strong,
.reason-count b,
.course-card small {
  font-family: "Playball", Georgia, "Times New Roman", serif !important;
}

body:not(.lower-page) .recommend-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
  justify-content: center;
  gap: 20px !important;
}

.recommend-grid article {
  min-height: 140px !important;
  padding: 22px 18px !important;
  font-size: 15px !important;
}

.recommend-grid span {
  width: 52px !important;
  height: 52px !important;
  margin: 0 auto 10px !important;
}

.reasons-sticky-wrap .reasons-title h2 {
  display: block !important;
  white-space: normal;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count {
  display: inline-flex !important;
  align-items: baseline;
  gap: 4px;
  margin: 0 4px 0 0 !important;
  color: var(--ink);
  font-family: inherit !important;
  font-size: inherit !important;
  line-height: 1 !important;
  vertical-align: baseline;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count b {
  display: inline-block;
  color: var(--ink);
  font-size: 104px;
  font-weight: 400;
  line-height: 0.85;
}


.voice-card:not(.top-voice-card),
.voice-card.main:not(.top-voice-card) {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  min-height: 250px;
  text-align: center;
}

.voice-photo {
  flex: 0 0 auto;
  width: 88px;
  height: 88px;
  margin: 0 auto;
}

.voice-card p {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
  margin: 0 !important;
}

.voice-card small {
  margin-top: auto;
}

.voice-slider {
  position: relative;
  overflow: hidden !important;
  padding: 0;
}

.voice-slider-outer {
  display: flex;
  align-items: center;
  gap: 10px;
}

.voice-slider-outer .voice-slider {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  position: relative;
  padding: 0;
}

.voice-slider-outer .voice-control.prev,
.voice-slider-outer .voice-control.next {
  position: static;
  top: auto;
  left: auto;
  right: auto;
  transform: none;
  flex-shrink: 0;
}

.voice-slider-outer .voice-control.prev:hover,
.voice-slider-outer .voice-control.next:hover {
  transform: translateY(-2px);
  background: var(--green-soft);
}

.voice-cards {
  gap: 18px;
}

.voice-card:not(.top-voice-card),
.voice-card.main:not(.top-voice-card) {
  flex: 0 0 100% !important;
  align-items: flex-start !important;
  min-height: 0;
  padding: 28px !important;
  text-align: left !important;
}

.voice-card .voice-photo {
  width: 104px;
  height: 104px;
  margin: 0 0 4px !important;
}

.voice-card > p {
  gap: 8px;
}

.voice-card > p > span {
  font-family: inherit;
}

.voice-card small {
  margin: 0 !important;
}

.voice-story {
  display: grid;
  gap: 14px;
  margin-top: 8px;
}

.voice-story p {
  display: block !important;
  margin: 0 !important;
  font-family: inherit;
}

.voice-story a {
  display: inline-flex;
  width: fit-content;
  margin-top: 4px;
  color: var(--green);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.7;
  text-decoration: none;
  border-bottom: 1px solid rgba(91, 149, 90, 0.35);
}

.voice-story a:hover {
  color: #3f7d45;
  border-bottom-color: currentColor;
}

@media (max-width: 980px) {
  body:not(.lower-page) .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .reasons-sticky-wrap .reasons-title h2 .reason-count b {
    font-size: 82px;
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) .recommend-grid {
    grid-template-columns: repeat(2, 154px) !important;
  }

  .recommend-grid article {
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
  }

  .reasons-sticky-wrap .reasons-title h2 .reason-count b {
    font-size: 70px;
  }

}


/* Lower page sections: airy rhythm update */
.extra-sections {
  max-width: none !important;
  margin: 0 !important;
  padding: 8px 0 0 !important;
}

.lower-section {
  max-width: 1160px;
  margin: 0 auto 104px;
  padding: 0 clamp(22px, 5vw, 56px);
  position: relative;
}

.extra-head {
  max-width: 660px;
  margin: 0 auto 36px;
  text-align: center;
}

.extra-head .section-kicker {
  margin: 0 0 10px;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.extra-head h3 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.35;
}

.extra-head p:not(.section-kicker) {
  margin: 16px auto 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.9;
}




.faq-section {
  max-width: none;
  margin: 0 0 104px;
  padding: 92px clamp(22px, 5vw, 56px);
  background: #f6faf6;
}

.faq-section .extra-head,
.faq-list {
  max-width: 940px;
  margin-left: auto;
  margin-right: auto;
}

/* 2026-09-28: SPファースト方針により、この透かしをSPでも表示(以前はPC限定)。
   font-sizeのみPC/SPで分岐(SPは375pxで実測調整)。 */
.faq-section .extra-head:before {
  position: absolute;
  bottom: -2rem;
  left: 0;
  right: 0;
  z-index: -1;
  color: rgba(31, 63, 54, 0.04);
  content: "FAQ";
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  pointer-events: none;
}

@media (min-width: 641px) {
  .faq-section .extra-head:before {
    font-size: clamp(92px, 14vw, 184px);
  }
}

@media (max-width: 640px) {
  .faq-section .extra-head:before {
    font-size: 105px;
  }
}

.faq-list {
  border-top: 1px solid #e5e7eb;
}

.faq-item {
  border-bottom: 1px solid #e5e7eb;
}

.faq-item summary {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 26px 0;
  color: var(--ink);
  font-weight: 800;
  line-height: 1.7;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  margin-left: auto;
  color: var(--green);
  font-size: 20px;
  font-weight: 700;
}

.faq-item[open] summary::after {
  content: "-";
}

.faq-item summary span {
  color: var(--green);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 16px;
}

.faq-item p {
  margin: -8px 0 28px;
  padding-left: 32px;
  color: #566272;
  font-size: 14px;
  line-height: 1.9;
}

.news-section {
  max-width: 900px;
  margin-bottom: 96px;
}

.news-section .extra-head {
  margin-bottom: 22px;
}

/* 2026-09-29: NEWSセクションの大型ウォーターマーク新設。section.lower-sectionが既にposition:relative
   のため.visible依存にせずこちらの安定セレクタを採用。 */
section.lower-section.news-section .extra-head::before {
  content: "NEWS";
  position: absolute;
  z-index: -1;
  pointer-events: none;
  color: rgba(31, 63, 54, 0.045);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(92px, 15vw, 118px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  top: 0;
  left: 0;
  right: 0;
}

.news-list {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none;
  border-top: 1px solid #e5e7eb;
}

.news-list li {
  display: grid !important;
  grid-template-columns: 112px 96px minmax(0, 1fr) !important;
  align-items: center;
  gap: 14px !important;
  padding: 15px 0 !important;
  border-bottom: 1px solid #e5e7eb;
}

.news-list time {
  color: #7a8797;
  font-size: 13px;
  font-weight: 800;
}

.news-list span {
  display: inline-flex;
  justify-content: center;
  width: fit-content;
  min-width: 78px;
  padding: 3px 10px;
  border-radius: 999px;
  background: #edf6ed;
  color: var(--green);
  font-size: 11px;
  font-weight: 800;
}

.news-list a {
  color: #435168;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.7;
  text-decoration: none;
  transition: color 0.25s ease;
}

.news-list a:hover {
  color: var(--green);
}

html {
  overflow-x: clip;
}

body {
  overflow-x: visible;
}

@supports not (overflow: clip) {
  html,
  body {
    overflow-x: visible;
  }
}

@media (max-width: 900px) {
  .lower-section {
    margin-bottom: 88px;
  }

}

@media (max-width: 640px) {
  .extra-head {
    margin-bottom: 28px;
  }

  .extra-head h3 {
    font-size: 28px;
  }

  .extra-head p:not(.section-kicker) {
    font-size: 14px;
  }


  .faq-section {
    margin-bottom: 88px;
    padding-top: 76px;
    padding-bottom: 76px;
  }

  /* 2026-09-27: FAQ見出しの文字サイズを14px→15pxへ(ユーザー指定) */
  .faq-item summary {
    padding: 22px 0;
    gap: 12px;
    font-size: 15px;
  }

  .faq-item p {
    padding-left: 0;
  }

  .news-list li {
    grid-template-columns: 1fr !important;
    gap: 6px !important;
    padding: 16px 0 !important;
  }
}

/* Final positioning override for the sticky reasons section. */
@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons {
    align-content: start !important;
    align-items: start !important;
    padding-top: clamp(110px, 13vh, 150px) !important;
  }

  .reasons-sticky-wrap .reasons-title,
  .reasons-sticky-wrap .reason-cards {
    align-self: start !important;
  }

  .reasons-sticky-wrap .reasons-title {
    top: auto !important;
  }
}

@media (max-width: 980px) {
  .reasons-sticky-wrap .reasons {
    justify-content: start !important;
    align-items: start !important;
    padding-top: 72px !important;
  }
}

@media (max-width: 640px) {
  .reasons-sticky-wrap .reasons {
    padding-top: 64px !important;
  }
}

/* Final visual tuning */
.recommend {
  text-align: center;
}

.recommend .section-title {
  max-width: none;
  margin: 0 auto;
}

.recommend-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.recommend-grid article {
  display: block;
  grid-column: auto;
  min-height: 140px;
  padding: 22px 18px;
  text-align: center;
  line-height: 1.62;
}

.reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
  color: var(--ink);
  font-family: Georgia, serif;
  font-size: 104px;
  line-height: 0.86;
}

.reasons-sticky-wrap .reason-card {
  padding-top: 164px;
}

.reasons-sticky-wrap .reason-photo {
  width: 78%;
  height: 156px;
}


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

  .recommend-grid article {
    grid-column: auto;
  }

  .reasons-sticky-wrap .reason-card {
    padding-top: 154px;
  }

  .reasons-sticky-wrap .reason-photo {
    width: 80%;
    height: 144px;
  }

}

@media (max-width: 640px) {
  .recommend-grid {
    grid-template-columns: repeat(2, 154px);
    gap: 12px;
  }

  .recommend-grid article {
    display: block;
    grid-column: auto;
    width: 154px;
    min-height: 110px;
    padding: 12px 8px;
    text-align: center;
    line-height: 1.55;
  }

  .recommend-grid span {
    width: 38px;
    height: 38px;
    margin: 0 auto 5px;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    font-size: 76px;
  }

  .reasons-sticky-wrap .reason-card {
    padding-top: 140px;
  }

  .reasons-sticky-wrap .reason-photo {
    width: 82%;
    height: 124px;
  }

}

.reasons-sticky-wrap .reasons-title h2 {
  white-space: normal;
}

@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons-title h2 {
    line-height: 1.35;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    margin: 4px 0 -6px;
  }
}

@media (max-width: 640px) {
  .recommend-grid article {
    display: block !important;
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
    text-align: center !important;
  }

  .recommend-grid span {
    width: 38px !important;
    height: 38px !important;
    margin: 0 auto 5px !important;
  }
}

/* Refined lower content sections */
.extra-sections {
  position: relative;
  max-width: 1120px;
}

.extra-head {
  text-align: center;
}

.extra-head h2 {
  font-size: clamp(26px, 3vw, 36px);
}






.news-list {
  padding: 0 !important;
  list-style: none;
}

.news-list li {
  display: grid;
  grid-template-columns: 86px 68px 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid #edf0f2;
}

.news-list time {
  color: #7a8797;
  font-size: 12px;
  font-weight: 800;
}

.news-list span {
  display: inline-flex;
  justify-content: center;
  padding: 2px 8px;
  color: var(--green);
  background: var(--green-soft);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
}



@media (max-width: 640px) {


  .news-list li {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons {
    align-content: start;
    align-items: start;
    padding-top: clamp(110px, 13vh, 150px);
  }

  .reasons-sticky-wrap .reasons-title,
  .reasons-sticky-wrap .reason-cards {
    align-self: start;
  }
}

@media (max-width: 980px) {
  .reasons-sticky-wrap .reasons {
    justify-content: start;
    align-items: start;
    padding-top: 72px;
  }
}

@media (max-width: 640px) {
  .reasons-sticky-wrap .reasons {
    padding-top: 64px;
  }
}

@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons {
    align-content: start;
    align-items: start;
    padding-top: clamp(110px, 13vh, 150px);
  }

  .reasons-sticky-wrap .reasons-title {
    align-self: start;
  }

  .reasons-sticky-wrap .reason-cards {
    align-self: start;
  }
}

@media (max-width: 980px) {
  .reasons-sticky-wrap .reasons {
    justify-content: start;
    align-items: start;
    padding-top: 72px;
  }

  .reasons-sticky-wrap .reasons-title,
  .reasons-sticky-wrap .reason-cards {
    align-self: stretch;
  }
}

@media (max-width: 640px) {
  .reasons-sticky-wrap .reasons {
    padding-top: 64px;
  }
}

.recommend {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
}

.recommend .section-title {
  max-width: 420px;
}

.recommend-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

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

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

@media (max-width: 640px) {
  .brand {
    min-width: auto;
  }

  .brand img {
    width: 140px;
  }

  .nav-cta {
    min-height: 40px;
    padding: 0 14px;
    font-size: 12px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .lead {
    font-size: 16px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-visual {
    min-height: 386px;
  }

  .photo-hero {
    inset: 0 32px 24px 0;
    min-height: 340px;
  }


  .stat-card strong {
    font-size: 30px;
  }

  .stat-a {
    top: 10px;
  }

  .stat-b {
    top: 120px;
  }

  .stat-c {
    top: 230px;
  }

  .recommend-grid,
  .reason-cards,
  .course-grid,
  .cta-actions {
    grid-template-columns: 1fr;
  }

  /* 2026-09-27: CTA案B SP順序(見出し→サブテキスト→体験授業→電話)。HTML順は電話が先のためCSSで並び替え。 */
  .cta-actions .form {
    order: 1;
  }

  .cta-actions .phone {
    order: 2;
  }

  .voice-card:not(.top-voice-card),
  .voice-card.main:not(.top-voice-card) {
    flex: 0 0 100% !important;
  }

  .voice-slider-outer {
    gap: 6px;
  }

  .extra-sections {
    padding-bottom: 54px;
  }


  .reason-card {
    min-height: 340px;
  }

  .footer {
    display: grid;
    gap: 18px;
  }

  .footer-links {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* 2026-09-27: フッター見出しh3の文字サイズをSPのみ14pxへ(ユーザー指定) */
  .footer-links h3 {
    font-size: 14px;
  }

  /* 2026-09-27: SPでフッターリンクの文字が小さく、タップ領域も狭いため操作しにくい問題を修正。
     paddingでタップ領域を拡大し、区切り線・矢印でタップ可能であることを明示。PC(このmedia外)は変更なし。 */
  .footer-links a {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 12px 4px;
    min-height: 44px;
    border-bottom: 1px solid rgba(100, 112, 132, 0.15);
    font-size: 13px;
  }

  .footer-links a::after {
    content: "›";
    margin-left: auto;
    padding-left: 8px;
    color: rgba(100, 112, 132, 0.6);
  }

  .footer-links > div:last-child a:last-of-type {
    border-bottom: none;
  }

  .page-top {
    margin-left: 0;
  }

  .message::before {
    left: -84px;
    bottom: 148px;
    opacity: 0.7;
  }
}

@media (max-width: 980px) {
  .recommend-grid article,
  .recommend-grid article:nth-child(n+4):nth-child(-n+7) {
    grid-column: auto;
  }
}

/* Animation additions */
.fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}


.fade-up:nth-child(2) {
  transition-delay: 0.1s;
}

.fade-up:nth-child(3) {
  transition-delay: 0.2s;
}

.fade-up:nth-child(4) {
  transition-delay: 0.3s;
}

.site-header {
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 0.3);
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(8px);
}

.reason-card,
.course-card,
.voice-card {
  transition:
    opacity 0.5s ease,
    transform 0.3s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.3s ease;
  cursor: pointer;
}

.reason-card:hover,
.course-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.15);
}

.voice-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
}

.reasons-sticky-wrap {
  max-width: 1180px;
  margin: 0 auto;
}

.reasons-sticky-wrap .reasons {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  max-width: none;
  padding-top: 40px;
  padding-bottom: 40px;
  overflow: hidden;
}

.reasons-sticky-wrap .reasons-title {
  width: min(100%, 820px);
  margin-bottom: 26px;
}

.reasons-sticky-wrap .reasons-title h2 {
  display: flex;
  align-items: baseline;
  gap: 18px;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.35;
}

.reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
  display: inline-block;
  margin-bottom: 0;
  font-size: 82px;
}

.reasons-sticky-wrap .reason-cards {
  position: relative;
  display: block;
  width: 100%;
  max-width: 760px;
  height: 430px;
}

.reasons-sticky-wrap .reason-card {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  min-height: 420px;
  opacity: 0;
  transform: translateY(60px) scale(0.95);
  transition:
    opacity 0.5s ease,
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.3s ease;
  pointer-events: none;
}

.reasons-sticky-wrap .reason-card.active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.reasons-sticky-wrap .reason-card.past {
  opacity: 0;
  transform: translateY(-60px) scale(0.95);
}

.reasons-sticky-wrap .reason-card.active:hover {
  transform: translateY(-10px) scale(1);
}

@media (max-width: 980px) {
  .reasons-sticky-wrap {
    height: 300vh;
    max-width: none;
  }

  .reasons-sticky-wrap .reasons {
    top: 0;
    height: 100svh;
    padding: 22px;
  }

  .reasons-sticky-wrap .reasons-title {
    width: 100%;
    margin-bottom: 18px;
  }

  .reasons-sticky-wrap .reasons-title h2 {
    display: block;
    font-size: clamp(24px, 7vw, 34px);
    line-height: 1.35;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    display: inline-block;
    margin-right: 8px;
    font-size: 64px;
    vertical-align: baseline;
  }

  .reasons-sticky-wrap .reason-cards {
    width: 100%;
    max-width: 520px;
    height: min(58svh, 430px);
  }

  .reasons-sticky-wrap .reason-card {
    min-height: 0;
    height: 100%;
    padding: 132px 24px 24px;
  }
}

@media (max-width: 640px) {

  .hero-copy {
    display: contents;
  }

  .hero-copy .eyebrow {
    order: 1;
    margin-bottom: 0;
    font-size: 9px;
  }

  .hero h1 {
    order: 2;
    font-size: clamp(25px, 7.1vw, 31px);
    line-height: 1.35;
  }

  .hero h1 span {
    font-size: 1.08em;
  }

  .lead {
    order: 3;
    margin: 4px 0 0;
    font-size: 13px;
    line-height: 1.65;
  }

  .hero-visual {
    order: 4;
    min-height: clamp(235px, 36svh, 292px);
    margin-top: 4px;
  }

  .photo-hero {
    inset: 0 50px 0 0;
    min-height: 0;
    height: 100%;
    border-radius: 34% 8% 28% 10% / 18% 8% 22% 10%;
  }

  .stat-card {
    right: 0;
  }

  .stat-card small {
    font-size: 10px;
    line-height: 1.2;
  }

  .stat-card strong {
    font-size: 26px;
  }

  .stat-card span {
    font-size: 10px;
    line-height: 1.2;
  }

  .stat-a {
    top: 4px;
    border-radius: 56% 44% 62% 38% / 48% 56% 44% 52%;
  }

  .stat-b {
    top: 80px;
    border-radius: 42% 58% 38% 62% / 55% 45% 58% 42%;
  }

  .stat-c {
    top: 156px;
    border-radius: 52% 48% 44% 56% / 46% 54% 48% 52%;
  }

  .hero-actions {
    order: 5;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 2px;
  }

  .hero-actions .button {
    min-height: 40px;
    padding: 0 10px;
    font-size: 12px;
  }

  .hero::after {
    right: -16px;
    bottom: 72px;
    width: 150px;
    height: 60px;
  }

  .recommend-grid article {
    display: block;
    width: 154px;
    min-height: 110px;
    padding: 12px 8px;
    text-align: center;
    line-height: 1.55;
  }

  .recommend-grid span {
    width: 38px;
    height: 38px;
    margin: 0 auto 5px;
  }

  .reasons-sticky-wrap .reasons {
    padding: 18px;
  }

  .reasons-sticky-wrap .reasons-title {
    margin-bottom: 14px;
  }

  .reasons-sticky-wrap .reasons-title h2 {
    font-size: 24px;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    font-size: 58px;
  }

  .reasons-sticky-wrap .reason-cards {
    height: min(62svh, 430px);
  }

  .reasons-sticky-wrap .reason-card {
    padding: 122px 22px 22px;
  }


  .reasons-sticky-wrap .reason-photo {
    height: 112px;
  }
}


.faq-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  margin: 30px auto 0;
  padding: 0 28px;
  border: 1px solid #a8c8a7;
  border-radius: 999px;
  background: #fff;
  color: var(--green);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  transition: color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.faq-section {
  text-align: center;
}

.faq-list {
  text-align: left;
}

/* 2026-09-29: 他の枠線ボタン(.button.ghost/.jr-course-more)と同じ「border色→背景反転、
   文字は白」の思想に統一。以前は文字・枠線を暗くするだけで背景変化が無く、挙動が
   バラバラだった。背景色は本ボタンの文字色である var(--green) を使用(新規に色を作らず、
   既存のこのルール内の値を再利用)。 */
.faq-more:hover,
.faq-more:focus-visible {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
  transform: translateY(-1px);
}



/* Mobile hero composition update */
@media (max-width: 640px) {
  .hero {
    align-items: center;
    align-content: start;
  }

  .hero-copy {
    display: contents !important;
  }

  .hero-copy .eyebrow {
    grid-area: eyebrow;
    order: initial !important;
    margin: 0 !important;
    font-size: 9px !important;
  }

  .hero h1 {
    grid-area: copy;
    order: initial !important;
    margin: 0 !important;
    font-size: clamp(25px, 7vw, 31px) !important;
    line-height: 1.32 !important;
    position: relative;
    z-index: 3;
  }

  .hero h1 span {
    font-size: 1.08em !important;
  }

  .lead {
    grid-area: lead;
    order: initial !important;
    max-width: none;
    margin: 0 !important;
    font-size: 13px !important;
    line-height: 1.65 !important;
    position: relative;
    z-index: 3;
  }

  .hero-visual {
    grid-area: visual;
    order: initial !important;
    display: grid;
    min-height: 0 !important;
    height: clamp(255px, 46svh, 340px) !important;
    margin: -4px 0 0 -34px !important;
    position: relative;
    z-index: 0;
  }

  .photo-hero {
    position: absolute !important;
    inset: -8px -16px 0 -24px !important;
    width: calc(100% + 40px) !important;
    height: calc(100% + 12px) !important;
    min-height: 0 !important;
    border-radius: 0 !important;
    background-position: center bottom !important;
    background-size: contain !important;
    box-shadow: none !important;
    z-index: 0 !important;
  }

  .hero-stats {
    grid-area: stats;
    position: static !important;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    z-index: 4;
    pointer-events: auto;
  }

  .stat-card {
    position: static !important;
    width: auto !important;
  }

  .stat-a {
    border-radius: 56% 44% 62% 38% / 48% 56% 44% 52% !important;
  }

  .stat-b {
    border-radius: 42% 58% 38% 62% / 55% 45% 58% 42% !important;
  }

  .stat-c {
    border-radius: 52% 48% 44% 56% / 46% 54% 48% 52% !important;
  }

  .stat-card small {
    font-size: 9px !important;
    line-height: 1.15 !important;
  }

  .stat-card strong {
    font-size: 24px !important;
  }

  .stat-card span {
    font-size: 9px !important;
    line-height: 1.15 !important;
  }

  .hero-actions {
    grid-area: actions;
    order: initial !important;
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    margin-top: -2px !important;
    position: relative !important;
    z-index: 4 !important;
  }

  .hero-actions .button {
    min-height: 38px !important;
    padding: 0 8px !important;
  }

  .hero::after {
    right: -22px !important;
    bottom: 86px !important;
    width: 132px !important;
    height: 56px !important;
  }

  .message:not(.message--video) {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
    padding-top: 26px !important;
  }

  /* 2026-09-26: 旧margin-bottom:-98pxが本文を画像下部へ98px重ねていたバグを修正。
     grid-area指定(上のブロック)側のmargin:0 -22px 8px 0を活かすため、ここでは
     transformのみ残し、min-height/marginの重複指定は削除。 */
  /* 2026-09-27: translateX(0)へ統一(横ズレ修正、詳細は2105行目コメント参照) */
  .message:not(.message--video) > .portrait-wrap {
    transform: translateX(0) !important;
  }

  .photo-portrait {
    width: 100% !important;
    min-height: 292px !important;
    background-position: right bottom !important;
    background-size: contain !important;
    box-shadow: none !important;
  }

  .message-copy {
    position: relative !important;
    z-index: 3 !important;
    margin-top: -18px !important;
    padding: 0 2px !important;
  }

  .message-copy h2 {
    margin-top: 0 !important;
    font-size: clamp(22px, 6.2vw, 28px) !important;
    line-height: 1.55 !important;
  }
}

/* Absolute final polish for latest request */
.fade-up.visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

.reasons-sticky-wrap .reason-card.fade-up.visible {
  opacity: 0 !important;
  transform: translateY(60px) scale(0.95) !important;
  pointer-events: none !important;
}

.reasons-sticky-wrap .reason-card.fade-up.visible.active {
  opacity: 1 !important;
  transform: translateY(0) scale(1) !important;
  pointer-events: auto !important;
}

.reasons-sticky-wrap .reason-card.fade-up.visible.past {
  opacity: 0 !important;
  transform: translateY(-60px) scale(0.95) !important;
}

.recommend-grid article {
  position: relative !important;
  overflow: visible !important;
}

.recommend-grid span {
  position: static !important;
  flex: none !important;
}

.reasons-sticky-wrap .reason-card strong {
  text-shadow:
    0 0 8px rgba(255, 255, 255, 0.98),
    0 0 18px rgba(255, 255, 255, 0.92),
    0 8px 22px rgba(255, 255, 255, 0.72) !important;
}

.reasons-sticky-wrap .reason-card.blue strong {
  text-shadow:
    0 0 8px rgba(255, 255, 255, 0.98),
    0 0 18px rgba(255, 255, 255, 0.92),
    0 8px 22px rgba(255, 255, 255, 0.72) !important;
}

.reasons-sticky-wrap .reason-card.pink strong {
  text-shadow:
    0 0 8px rgba(255, 255, 255, 0.98),
    0 0 18px rgba(255, 255, 255, 0.92),
    0 8px 22px rgba(255, 255, 255, 0.72) !important;
}


.voice-card,
.voice-card.main {
  display: grid !important;
  grid-template-columns: 104px minmax(0, 1fr) !important;
  grid-template-areas:
    "photo title"
    "photo name"
    "story story" !important;
  column-gap: 18px !important;
  row-gap: 6px !important;
  align-items: center !important;
  padding: 34px 38px !important;
}

.voice-card .voice-photo {
  grid-area: photo !important;
  margin: 0 !important;
}

.voice-card > p {
  grid-area: title !important;
  margin: 0 !important;
  align-self: end !important;
}

.voice-card small {
  grid-area: name !important;
  align-self: start !important;
}

.voice-card .voice-story {
  grid-area: story !important;
  width: 100% !important;
  margin-top: 14px !important;
}

.cta {
  background: #eaf4fb;
  color: #245992;
}

.reasons-sticky-wrap .reasons-title h2 .reason-count b {
  display: inline !important;
  font-size: 104px !important;
}

/* 2026-09-27: 旧デザイン(写真を左カラムに収め、右へフェードアウトさせるmask)を撤去。
   新デザインはcta-photoをカード全体の背景として使うため、position/maskの上書きは不要。 */

/* 2026-09-27: CTA見出しtext-shadowをPC/SP・TOP/下層共通化(ユーザー指定値)。
   旧: SP限定でbody:not(.lower-page)/body.mp-v2それぞれに重複定義していたものを
   共通CTA(.cta h2)側に一本化し、PCにも同じ見え方を適用。 */
.cta h2 {
  color: #245992;
  text-shadow:
    2px 2px 1px rgba(255, 255, 255, 0.92),
    0 8px 22px rgba(255, 255, 255, 0.52) !important;
}

/* 2026-09-27: ユーザー指定、PC限定でtext-shadowのぼかしを1px→5pxへ(SPは上のbase値のまま)。
   ここは上のbase .cta h2と同詳細度・!important同士のため、後方に置くことで確実に勝たせる。 */
@media (min-width: 641px) {
  .cta h2 {
    text-shadow:
      2px 2px 5px rgba(255, 255, 255, 0.92),
      0 8px 22px rgba(255, 255, 255, 0.52) !important;
  }
}

.phone {
  color: #fff;
  font-size: 18px;
}

.phone span,
.form span {
  display: grid;
  gap: 2px;
  line-height: 1.2;
}

.phone small,
.form small {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
}

/* 2026-09-29: .phone svg / .form span・.form small はここまで親(.phone/.form)と同じ色を
   個別にも再指定していたが、単なる継承で同じ結果になり実質重複だった。hoverで親のcolorが
   反転しても子要素側の固定colorが上書きされず反転しないバグの原因になっていたため削除し、
   currentColor相当の継承に委ねる(親の色が変われば子も自動で追従する)。 */
.form small {
  font-size: 12px !important;
}

.phone {
  color: var(--green);
  background: #fff;
  border: 1px solid var(--green);
  box-shadow: 0 8px 24px rgba(36, 89, 146, 0.08);
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

/* 2026-09-29: .phoneはhoverしても無反応だった(.button.ghost系と同じ「境界色→背景」の
   考え方で反転を追加)。通常=白背景+緑文字 → hover=緑背景+白文字。受話器アイコン・
   電話番号・リンク先(tel:)は変更なし。アイコン・番号・→矢印は色を個別指定せず親から
   継承する構成にしたため、この1ルールで全て自動的に反転する。 */
.phone:hover,
.phone:focus-visible {
  color: #fff;
  background: var(--green);
  transform: translateY(-2px);
}

@media (max-width: 640px) {
  .recommend-grid article {
    display: block !important;
    width: 154px !important;
    min-height: 110px !important;
    padding: 12px 8px !important;
    text-align: center !important;
  }

  .recommend-grid span {
    margin: 0 auto 5px !important;
  }

  .voice-card,
  .voice-card.main {
    grid-template-columns: 78px minmax(0, 1fr) !important;
    column-gap: 14px !important;
  }

  .voice-card .voice-photo {
    width: 72px !important;
    height: 72px !important;
  }

  .cta-actions {
    grid-template-columns: 1fr !important;
  }
}

@media (min-width: 981px) {
  .reasons-sticky-wrap .reasons {
    display: grid;
    grid-template-columns: 285px minmax(0, 760px);
    gap: clamp(48px, 8vw, 110px);
    align-content: center;
    align-items: center;
    justify-content: center;
  }

  .reasons-sticky-wrap .reasons-title {
    position: relative;
    z-index: 2;
    width: 285px;
    margin: 0;
    transform: none !important;
    align-self: center;
  }

  .reasons-sticky-wrap .reasons-title.visible {
    transform: none !important;
  }

  .reasons-sticky-wrap .reasons-title h2 {
    display: block;
    font-size: clamp(32px, 3.1vw, 44px);
    line-height: 1.45;
  }

  .reasons-sticky-wrap .reasons-title h2 > span:not(.reason-count) {
    display: block;
    margin: 0 0 2px;
    font-size: 104px;
    line-height: 0.85;
  }

  .reasons-sticky-wrap .reason-cards {
    z-index: 1;
    max-width: 760px;
    height: 440px;
  }

  .reasons-sticky-wrap .reason-card {
    min-height: 440px;
  }
}

@media (max-width: 640px) {

  .hero-visual {
    height: clamp(292px, 50svh, 360px) !important;
    margin: -48px 0 0 -24px !important;
    z-index: 0 !important;
  }

  .photo-hero {
    inset: -54px -16px 0 -16px !important;
    height: calc(100% + 56px) !important;
    background-position: center top !important;
    opacity: 0.96 !important;
  }

  .hero h1 {
    font-size: clamp(27px, 7vw, 31px) !important;
  }

  .hero-copy,
  .hero-copy h1,
  .hero-copy .lead,
  .hero-stats,
  .hero-actions {
    position: relative !important;
    z-index: 3 !important;
  }

  .hero-stats {
    gap: 12px !important;
  }

  .stat-card {
    min-height: 72px !important;
    padding: 10px 6px !important;
    border-radius: 58% 42% 55% 45% / 50% 48% 52% 50% !important;
    box-shadow: 0 10px 28px rgba(21, 38, 62, 0.09) !important;
  }


  .hero-actions {
    gap: 16px !important;
  }

  .portrait-wrap {
    margin-top: -38px !important;
    margin-bottom: 34px !important;
  }

  .message-copy > p:not(.section-kicker):not(.signature) {
    margin-top: 36px !important;
  }

  .recommend .recommend-grid article {
    font-size: 12px !important;
    line-height: 1.5 !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

}

/* Latest visible fixes - true EOF override 2026-07-03 */
body:not(.lower-page) .photo-hero {
  opacity: 1 !important;
  filter: none !important;
}

body:not(.lower-page) .flow-photos {
  background: #eef5f7 url("img/Image_20241112_195302_283.jpeg") center / cover no-repeat !important;
}

body:not(.lower-page) .flow-photo-one {
  background-image: url("img/Image_20241112_195302_283.jpeg");
}

body:not(.lower-page) .flow-photo-two {
  background-image: url("img/L74A0448.JPG");
}

body:not(.lower-page) .flow-photo-three {
  background-image: url("img/L74A0491.JPG");
}

body:not(.lower-page) .recommend {
  isolation: isolate;
}

body:not(.lower-page) .recommend::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 52px;
  height: 52px;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(14px);
  opacity: 0.42;
  transform: translate3d(0, 0, 0);
  animation: recommendFloat 1s linear both;
  animation-timeline: view();
  animation-range: entry -18% cover 58%;
}

body:not(.lower-page) .recommend::after {
  right: clamp(18px, 7vw, 104px);
  bottom: clamp(42px, 12%, 110px);
  background: rgba(255, 223, 137, 0.38);
  animation-name: recommendFloatAlt;
  animation-range: entry -8% cover 62%;
}

body:not(.lower-page) .recommend .section-title,
body:not(.lower-page) .recommend-grid {
  position: relative;
  z-index: 1;
}

@keyframes recommendFloat {
  from {
    opacity: 0.08;
    transform: translate3d(-18px, 10px, 0) scale(0.82);
  }
  45% {
    opacity: 0.38;
  }
  to {
    opacity: 0.2;
    transform: translate3d(92px, -8px, 0) scale(1.08);
  }
}

@keyframes recommendFloatAlt {
  from {
    opacity: 0.06;
    transform: translate3d(24px, -8px, 0) scale(0.78);
  }
  45% {
    opacity: 0.26;
  }
  to {
    opacity: 0.14;
    transform: translate3d(-76px, 12px, 0) scale(1.04);
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) .recommend::after {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  body:not(.lower-page) .recommend::after {
    animation: none;
  }
}

@media (min-width: 981px) {
  /* 列指定は「TOP additional visual fixes」内の results-voice 定義に一本化(重複削除) */
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    padding: 24px 24px 28px !important;
    background: rgba(255, 255, 255, 0.92) !important;
    border: 1px solid rgba(91, 149, 90, 0.18) !important;
    border-radius: 26px !important;
    box-shadow: 0 18px 42px rgba(21, 38, 62, 0.08) !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    padding: 18px !important;
    background: rgba(255, 255, 255, 0.92) !important;
    border-color: rgba(120, 178, 99, 0.16) !important;
    border-radius: 18px !important;
    box-shadow: 0 10px 24px rgba(22, 38, 55, 0.045) !important;
  }

  body:not(.lower-page) .admission-index h3 {
    font-size: clamp(19px, 1.55vw, 24px) !important;
  }

  body:not(.lower-page) .admission-index-lead {
    font-size: 13px !important;
    line-height: 1.7 !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index-list a {
    padding: 9px 11px !important;
    border-radius: 14px !important;
    box-shadow: none !important;
    font-size: 12px !important;
  }
}

@media (max-width: 640px) {

  body:not(.lower-page) .hero-visual {
    height: clamp(238px, 43svh, 318px) !important;
    margin: 8px -10px 0 -30px !important;
  }

  body:not(.lower-page) .photo-hero {
    inset: 6px -16px 0 -18px !important;
    height: calc(100% - 2px) !important;
    background-position: center bottom !important;
    background-size: contain !important;
    opacity: 1 !important;
  }

  body:not(.lower-page) .hero-actions {
    grid-area: actions !important;
    margin: 6px 0 0 !important;
    z-index: 5 !important;
  }

  body:not(.lower-page) .hero-stats {
    grid-area: stats !important;
    position: static !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
    height: auto !important;
    margin-top: 2px !important;
    z-index: 4 !important;
  }

  body:not(.lower-page) .stat-card,
  body:not(.lower-page) .stat-a,
  body:not(.lower-page) .stat-b,
  body:not(.lower-page) .stat-c {
    position: static !important;
    inset: auto !important;
    width: auto !important;
  }

  body:not(.lower-page) .courses {
    padding-left: 18px !important;
    padding-right: 18px !important;
    overflow: hidden !important;
  }

  body:not(.lower-page) .course-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 18px !important;
    width: 100%;
  }

  body:not(.lower-page) .course-card {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
  }

  body:not(.lower-page) .course-image {
    height: auto !important;
    aspect-ratio: 16 / 9;
    min-height: 0;
  }

  /* SPの縦積み順: 実績(order:1) → 紹介(order:2) → 探す(order:3) */
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .results {
    order: 1;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    order: 2;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    order: 3;
    margin-top: 0 !important;
  }

}

/* ===== Fable visual fixes 2026-07-03 =====
   SP FVの重なり解消 / FV白飛び調整 / 実績エリア明示配置 / flow画像差し替え / SPコース調整。
   方針: "true EOF override" ブロックのさらに後ろで後勝ち上書き。
   !important は上書き対象の既存指定に !important が付いている場合のみ使用。 */

/* [FV白飛び] 上書き対象: true EOF override の .hero::before。
   ベールを文字側(左)に限定して早めに減衰させ、写真右側は素の写真を見せる */
/* [実績エリア] レイアウト定義は「TOP additional visual fixes」ブロックの
   grid-template-areas("results voice" / "admission voice")に一本化。
   ここにあった grid-column/row の明示配置は競合するため削除(2026-07-03) */

/* [探すの目次化] PC/SP共通。上書き対象: 基底+双子ブロックの
   .admission-index-list a { display:flex; justify-content:space-between }(ピル型)。
   space-betweenで散らさず「学校名+合格」を左に寄せ、矢印だけ右端へ。
   ピル(白背景+枠+丸角)をやめて罫線区切りの目次リストにする */
body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index-list {
  gap: 0 !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked):not(.top-voice-restored) .admission-index-list a {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 8px !important;
  padding: 9px 4px !important;
  background: transparent !important;
  border: 0 !important;
  border-bottom: 1px solid #e9bfd0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  font-weight: 700 !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index-list a:last-child {
  border-bottom: 0 !important;
}

body:not(.lower-page) .results-voice:not(.results-voice--stacked):not(.top-voice-restored) .admission-index-list a::after {
  margin-left: auto !important; /* 矢印だけ右端へ */
}

@media (max-width: 640px) {
  /* [SP FV] 上書き対象: 基底の .hero-visual { position: absolute !important }(重なりの根本原因)と
     true EOF override の .hero-visual / .photo-hero の負マージン・拡張inset。
     写真をグリッドの "visual" セル内に収め、コピー/ボタン/数字カードと分離する */

  /* 写真はカード化せず、テキスト右に「ふわっと」置く装飾扱い。
     contain で切り抜かず、画像自体の水彩(波)のフチをそのまま見せる */
  body:not(.lower-page) .hero-visual {
    position: relative !important;
    inset: auto !important;
    height: clamp(180px, 28svh, 230px) !important;
    margin: 0 !important;
    overflow: visible !important;
    border-radius: 0;
    box-shadow: none;
    z-index: 1 !important;
  }

  body:not(.lower-page) .photo-hero {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    border-radius: 0 !important;
    background-size: contain !important;
    background-position: right center !important;
    box-shadow: none !important;
    opacity: 1 !important;
  }

  /* SPは文字が写真に重ならないため全面ベール不要。写真の白飛びも同時に解消 */
  /* [SPコース] 巨大COURSE飾り文字が overflow:hidden で水平に見切れて不自然 → SPでは非表示。
     カードの影も軽くして背景から浮きすぎないようにする */
  body:not(.lower-page) .courses::before {
    content: none !important;
  }

  body:not(.lower-page) .course-card {
    box-shadow: 0 10px 26px rgba(21, 38, 62, 0.08) !important;
  }
}

/* TOP voice navigation and SP hero scale tweak 2026-07-04 */
body:not(.lower-page) .admission-index-list a {
  cursor: pointer;
}

@media (max-width: 640px) {

  body:not(.lower-page) .hero-visual {
    height: clamp(212px, 33svh, 272px) !important;
    margin: -6px -42px 0 -6px !important;
  }

  body:not(.lower-page) .photo-hero {
    inset: -10px -48px -2px 0 !important;
    width: calc(100% + 48px) !important;
    height: calc(100% + 12px) !important;
    background-size: contain !important;
    background-position: right center !important;
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) .hero {
    position: relative !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-areas:
      "eyebrow"
      "copy"
      "lead"
      "stats"
      "actions" !important;
    gap: 14px !important;
    /* 2026-09-27: header直下の余白が広すぎたためtopを56px→36pxへ調整(ユーザー指定) */
    padding: 36px 18px 30px !important;
    overflow: hidden !important;
  }

  body:not(.lower-page) .hero-copy {
    display: contents !important;
    max-width: none !important;
  }

  body:not(.lower-page) .hero-copy .eyebrow {
    grid-area: eyebrow !important;
  }

  body:not(.lower-page) .hero h1 {
    grid-area: copy !important;
    max-width: min(100%, 9.8em) !important;
  }

  /* 2026-09-27: hero画像の開始位置をtop:72px→3.5rem(56px)へ調整(ユーザー指定) */
  body:not(.lower-page) .hero-visual {
    position: absolute !important;
    inset: 3.5rem -54px auto auto !important;
    width: clamp(210px, 62vw, 252px) !important;
    height: clamp(230px, 36svh, 286px) !important;
    margin: 0 !important;
    z-index: 1 !important;
    pointer-events: none !important;
    overflow: visible !important;
  }

  body:not(.lower-page) .photo-hero {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background-size: contain !important;
    background-position: right top !important;
    opacity: 0.96 !important;
  }

  body:not(.lower-page) .hero-copy .eyebrow,
  body:not(.lower-page) .hero h1,
  body:not(.lower-page) .lead,
  body:not(.lower-page) .hero-stats,
  body:not(.lower-page) .hero-actions {
    position: relative !important;
    z-index: 3 !important;
  }

  body:not(.lower-page) .lead,
  body:not(.lower-page) .hero-stats,
  body:not(.lower-page) .hero-actions {
    max-width: 100% !important;
  }

  /* 2026-09-27: leadの上下余白を0.5remへ調整(ユーザー指定) */
  body:not(.lower-page) .lead {
    grid-area: lead !important;
    margin: 0.5rem 0 !important;
  }

  body:not(.lower-page) .hero-stats {
    grid-area: stats !important;
    position: static !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
    width: 100% !important;
    pointer-events: auto !important;
  }

  body:not(.lower-page) .stat-card,
  body:not(.lower-page) .stat-a,
  body:not(.lower-page) .stat-b,
  body:not(.lower-page) .stat-c {
    position: static !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: 100% !important;
    min-height: 58px !important;
    padding: 7px 3px !important;
  }

  body:not(.lower-page) .hero-actions {
    grid-area: actions !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    width: 100% !important;
  }

  body:not(.lower-page) .hero-actions .button {
    width: 100% !important;
    min-width: 0 !important;
  }
}

@media (min-width: 981px) {
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) {
    grid-template-columns: minmax(0, 1.04fr) minmax(320px, 0.72fr) !important;
    grid-template-areas:
      "results admission"
      "voice admission" !important;
    gap: clamp(24px, 4vw, 48px) !important;
    align-items: start !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    grid-area: voice !important;
    width: 100% !important;
    padding: 24px 24px 28px !important;
  }

  body:not(.lower-page) .voice-slider-outer .voice-slider {
    margin: 0 !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice-card,
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice-card.main {
    grid-template-columns: 104px minmax(0, 1fr) !important;
    padding: 26px 30px !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice-card .voice-photo {
    width: 104px !important;
    height: 104px !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    grid-area: admission !important;
    width: 100% !important;
    max-width: none !important;
    justify-self: stretch !important;
  }
}

@media (min-width: 981px) {
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 0.48fr) !important;
    grid-template-areas:
      "results results"
      "voice admission" !important;
    gap: clamp(24px, 4vw, 46px) clamp(22px, 3.5vw, 40px) !important;
    align-items: start;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    grid-area: voice !important;
    width: 100% !important;
    margin-top: 0 !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    grid-area: admission !important;
    width: 100% !important;
    max-width: none !important;
    margin-top: 0 !important;
    align-self: start !important;
    justify-self: stretch !important;
  }
}

@media (max-width: 980px) {
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) {
    display: grid;
    grid-template-columns: 1fr;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .results {
    order: 1 !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    order: 2 !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    order: 3 !important;
  }
}

@media (min-width: 981px) {
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) {
    grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr) !important;
    grid-template-areas:
      "results voice"
      "admission voice" !important;
    gap: clamp(24px, 4vw, 48px) !important;
    align-items: start;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .results {
    grid-area: results !important;
    width: 100% !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    grid-area: admission !important;
    width: 100% !important;
    max-width: none !important;
    margin-top: 0 !important;
    justify-self: stretch !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    grid-area: voice !important;
    width: 100% !important;
    margin-top: 0 !important;
  }
}

body:not(.lower-page) #voice {
  scroll-margin-top: 118px;
}

@media (min-width: 981px) {
  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index {
    align-self: end !important;
  }

  body:not(.lower-page) .results-voice:not(.results-voice--stacked) .voice {
    align-self: stretch !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: calc(100% + 40px) !important;
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) #voice {
    scroll-margin-top: 86px;
    margin-top: 1rem !important;
    padding-top: 0;
  }
}

body:not(.lower-page) {
  font-family: "Noto Sans JP", system-ui, -apple-system, BlinkMacSystemFont, "Yu Gothic", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
}

body:not(.lower-page) p:not(.section-kicker):not(.eyebrow):not(.footer-copyright),
body:not(.lower-page) address,
body:not(.lower-page) .lead,
body:not(.lower-page) .note,
body:not(.lower-page) .message-copy p:not(.section-kicker),
body:not(.lower-page) .course-card p,
body:not(.lower-page) .voice-story p,
body:not(.lower-page) .admission-index-lead,
body:not(.lower-page) .faq-item p,
body:not(.lower-page) .news-list a {
  color: #333 !important;
}

body:not(.lower-page) .eyebrow,
body:not(.lower-page) .section-kicker {
  color: var(--green);
}

body:not(.lower-page) .button,
body:not(.lower-page) .nav-cta {
  font-family: inherit;
}

body:not(.lower-page) #bgBlobs {
  transform: translateZ(0);
}

body:not(.lower-page) .bg-blob {
  transition: transform 0.18s linear;
}

@media (prefers-reduced-motion: reduce) {
  body:not(.lower-page) .bg-blob {
    transition: none;
    transform: none !important;
  }
}

@media (min-width: 981px) {
  body:not(.lower-page) .reasons-sticky-wrap .reasons {
    top: 160px !important;
    min-height: calc(100svh - 220px) !important;
    padding-top: clamp(24px, 3svh, 40px) !important;
    padding-bottom: clamp(24px, 3svh, 40px) !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-cards {
    height: min(48svh, 390px) !important;
    align-self: center !important;
  }
}

body:not(.lower-page) p:not(.footer-copyright),
body:not(.lower-page) .lead,
body:not(.lower-page) .note,
body:not(.lower-page) address,
body:not(.lower-page) .desktop-nav a,
body:not(.lower-page) .mobile-nav a,
body:not(.lower-page) .button,
body:not(.lower-page) .nav-cta,
body:not(.lower-page) .course-card p,
body:not(.lower-page) .reason-card p,
body:not(.lower-page) .faq-item p,
body:not(.lower-page) .admission-index-lead,
body:not(.lower-page) .admission-index-list a,
body:not(.lower-page) .school-tags span,
body:not(.lower-page) .chips span,
body:not(.lower-page) .voice-story p,
body:not(.lower-page) .news-list a,
body:not(.lower-page) .footer-links > div > a {
  font-weight: 500 !important;
}

body:not(.lower-page) .section-kicker,
body:not(.lower-page) .eyebrow,
body:not(.lower-page) .course-card small,
body:not(.lower-page) .voice-card small,
body:not(.lower-page) .stat-card small {
  font-weight: 600 !important;
}

body:not(.lower-page) .voice-card > p {
  font-weight: 600 !important;
}

body:not(.lower-page) .photo-reason-one {
  background-image: url("img/02.webp");
}

body:not(.lower-page) .photo-reason-two {
  background-image: url("img/03.webp");
}

body:not(.lower-page) .photo-reason-three {
  background-image: url("img/01.webp");
}

@media (max-width: 640px) {
  body:not(.lower-page) .reasons-sticky-wrap .reason-card p {
    display: block !important;
    max-height: none !important;
    overflow: visible !important;
    -webkit-line-clamp: unset !important;
    line-clamp: unset !important;
  }
}

body:not(.lower-page) .hero h1 .hero-accent-line {
  display: inline-block;
  margin-left: -0.08em;
  color: var(--yellow) !important;
  font-family: Georgia, "Times New Roman", serif !important;
}

body:not(.lower-page) .hero h1 .hero-keyword {
  color: inherit !important;
  font-family: inherit !important;
}

body:not(.lower-page) .hero h1 .hero-particle {
  display: inline-block;
  margin-left: 0.02em;
  color: inherit !important;
  font-family: inherit !important;
  font-size: 0.72em !important;
  line-height: 1;
  vertical-align: 0.08em;
}

body:not(.lower-page) .hero h1 .hero-closing {
  display: inline-block;
  margin-left: 0.02em;
  color: var(--ink) !important;
  font-family: inherit !important;
  letter-spacing: 0.08em;
}

@media (max-width: 640px) {
  body:not(.lower-page) .hero h1 .hero-accent-line {
    margin-left: -0.04em;
  }

  body:not(.lower-page) .hero h1 .hero-particle {
    font-size: 0.76em !important;
    vertical-align: 0.06em;
  }

  body:not(.lower-page) .hero h1 .hero-closing {
    letter-spacing: 0.06em;
  }
}

/* ===== Fable typography adjustments 2026-07-04 =====
   目的: (1) 見出しの900/800を600系へ (2) #071833のネイビー感を減らす
        (3) 英字キッカー等のPlayball(筆記体)をQuicksand(幾何学系丸ゴ)へ。
   スコープ: TOPのみ(body:not(.lower-page))。CSS整理・削除はしない方針のため後勝ち上書き。
   !important は上書き対象が!important付きの場合のみ使用。 */

/* [色] var(--ink)#071833 を TOP 全体で深緑チャコールへ。
   var()参照箇所(見出し・FAQ見出し・ハンバーガー・モバイルナビ等)が一括で切替わる。
   --muted も青グレー#617086→緑グレーへ */
body:not(.lower-page) {
  --ink: #1f3f36;
  --muted: #5d685f;
}

/* [色] 個別に紺系hexを持っていた箇所(var未使用のため手動で変更) */
body:not(.lower-page) .desktop-nav {
  color: #1f3f36; /* 旧 #18273f */
}

body:not(.lower-page) .reason-card p {
  color: #333 !important; /* 旧 #5d6b82 !important(青グレー) */
}

body:not(.lower-page) .chips span {
  color: #55635a; /* 旧 #536072 */
}

body:not(.lower-page) .stat-card small {
  color: #6b746c; /* 旧 #6f7884 */
}

body:not(.lower-page) .stat-card span {
  color: #5d685f; /* 旧 #536072 */
}

body:not(.lower-page) .footer-links a,
body:not(.lower-page) .footer address {
  color: #5d685f; /* 旧 #647084 */
}

body:not(.lower-page) .footer-social a {
  color: #5d685f !important; /* 旧 #4e5b6d !important */
}

/* [weight] 見出し 900 → 600(見出しの強さはサイズと色で担保) */
body:not(.lower-page) .message-copy h2,
body:not(.lower-page) .section-title h2,
body:not(.lower-page) .course-intro h2,
body:not(.lower-page) .results h2,
body:not(.lower-page) .voice h2,
body:not(.lower-page) .cta h2,
body:not(.lower-page) .extra-head h2,
body:not(.lower-page) .extra-head h3 {
  font-weight: 600;
}

body:not(.lower-page) .reason-card h3,
body:not(.lower-page) .course-card h3,
body:not(.lower-page) .admission-index h3 {
  font-weight: 600;
}

/* [weight] カード・FAQ・CTAボタン系 800/900 → 500〜600 */
body:not(.lower-page) .recommend-grid article {
  color: #333;
  font-weight: 500; /* 旧 800 */
}

body:not(.lower-page) .faq-item summary {
  font-weight: 600; /* 旧 800 */
}

body:not(.lower-page) .phone,
body:not(.lower-page) .form {
  font-weight: 600; /* 旧 900 */
}

body:not(.lower-page) .phone small,
body:not(.lower-page) .form small {
  font-weight: 600 !important; /* 旧 900 !important */
}

/* [フォント] 英字キッカーの Playball(筆記体)→ Quicksand。
   上書き対象: "Final requested refinements" の Playball 一括指定 */
body:not(.lower-page) .section-kicker,
body:not(.lower-page) .eyebrow,
body:not(.lower-page) .course-card small {
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif !important;
  font-weight: 600 !important;
  font-style: normal;
  letter-spacing: 0.16em;
}

/* [フォント] 装飾数字(実績数値・理由番号・flow番号)も Playball → Quicksand。
   数字の筆記体感を消し、ロゴの幾何学的な丸みに揃える */
body:not(.lower-page) .stat-card strong,
body:not(.lower-page) .reason-count b,
body:not(.lower-page) .reasons-title h2 .reason-count::first-letter {
  font-family: "Quicksand", "Avenir Next", "Century Gothic", sans-serif !important;
  font-weight: 500 !important;
}

/* ===== Fable FV実績丸カラー 2026-07-04(案C採用: 淡ブルー+淡ピンク差し) =====
   参考カンプの緑/桃/青トリオを、ブランドに合わせ彩度を落として適用。
   指導歴(a)=淡ブルーやや強め / カウンセラー歴(b)=ごく淡いブルー / 開校(c)=淡ピンク。
   数字の緑・ラベル色は変更なし(可読性維持)。
   ▼案B(淡ブルー中心)に切り替える場合は c を以下へ:
     background: #f3f8fd; border-color: rgba(79, 132, 205, 0.12);
   ▼案A(白)に戻す場合はこのブロックを丸ごと無効化 */
body:not(.lower-page) .stat-a {
  background: #e5effa;
  border-color: rgba(79, 132, 205, 0.24);
}

body:not(.lower-page) .stat-b {
  background: #f4f9fd;
  border-color: rgba(79, 132, 205, 0.13);
}

body:not(.lower-page) .stat-c {
  background: #f8eef1;
  border-color: rgba(212, 109, 159, 0.16);
}

body:not(.lower-page) .stat-card,
body:not(.lower-page) .stat-a,
body:not(.lower-page) .stat-b,
body:not(.lower-page) .stat-c {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: 0 12px 26px rgba(44, 67, 88, 0.055) !important;
}

body:not(.lower-page) .stat-a strong,
body:not(.lower-page) .stat-a small,
body:not(.lower-page) .stat-a span {
  color: #365c78 !important;
}

body:not(.lower-page) .stat-b strong,
body:not(.lower-page) .stat-b small,
body:not(.lower-page) .stat-b span {
  color: #496679 !important;
}

body:not(.lower-page) .stat-c strong,
body:not(.lower-page) .stat-c small,
body:not(.lower-page) .stat-c span {
  color: #8b5268 !important;
}

body:not(.lower-page) .bg-blob {
  transition: transform 0.28s linear;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(1) {
  background: rgba(255, 226, 128, 0.20) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(2) {
  background: rgba(147, 198, 255, 0.30) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(3) {
  background: rgba(137, 224, 184, 0.30) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(4) {
  background: rgba(255, 204, 142, 0.30) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(5) {
  background: rgba(255, 208, 155, 0.42) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(6) {
  background: rgba(190, 170, 255, 0.38) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(7) {
  background: rgba(255, 180, 204, 0.36) !important;
}

body:not(.lower-page) #bgBlobs .bg-blob:nth-child(8) {
  background: rgba(150, 213, 255, 0.36) !important;
}

@media (max-width: 640px) {
  body:not(.lower-page) .bg-blob {
    transition-duration: 0.12s;
  }

  body:not(.lower-page) #bgBlobs .bg-blob {
    opacity: 0.72;
  }
}

@media (prefers-reduced-motion: reduce) {
  body:not(.lower-page) .bg-blob {
    transition: none !important;
    transform: none !important;
  }
}

body:not(.lower-page) .stat-b {
  background: #fff5d6 !important;
  border: 0 !important;
  outline: 0 !important;
}

body:not(.lower-page) .stat-b strong,
body:not(.lower-page) .stat-b small,
body:not(.lower-page) .stat-b span {
  color: #7d5f1f !important;
}

body:not(.lower-page) .bg-blob {
  transition: transform 0.18s linear;
}

body:not(.lower-page) .reasons-sticky-wrap .reasons-title h2 .reason-count b,
body:not(.lower-page) .reasons-title h2 .reason-count::first-letter {
  font-family: "Quicksand", "Avenir Next", "Century Gothic", sans-serif !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em !important;
  line-height: 0.82 !important;
}

body:not(.lower-page) .voice-card {
  display: grid !important;
  grid-template-columns: 86px minmax(0, 1fr) !important;
  grid-template-rows: auto auto 1fr !important;
  grid-template-areas:
    "photo title"
    "photo name"
    "story story" !important;
  column-gap: 18px !important;
  row-gap: 0 !important;
  align-items: start !important;
  padding: 28px 34px 30px !important;
}

body:not(.lower-page) .voice-card .voice-photo {
  grid-area: photo !important;
  margin: 2px 0 0 !important;
}

body:not(.lower-page) .voice-card > p {
  grid-area: title !important;
  align-self: start !important;
  color: #333;
  font-size: clamp(19px, 1.55vw, 23px);
  font-weight: 600;
  line-height: 1.58 !important;
  min-height: 5.2em;
  margin: 0 !important;
}

body:not(.lower-page) .voice-card > p > span {
  color: var(--green);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45 !important;
  min-height: 2.8em;
  margin-bottom: 4px;
}

body:not(.lower-page) .voice-card > small {
  grid-area: name !important;
  align-self: start !important;
  display: block;
  color: #5d685f;
  font-size: 13px;
  font-weight: 600;
  min-height: 1.4em;
  margin-top: 8px;
}

body:not(.lower-page) .voice-card .voice-story {
  grid-area: story !important;
  margin-top: 18px;
}

body:not(.lower-page) .voice-card .voice-story p {
  color: #333;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.95;
}

@media (max-width: 640px) {
  body:not(.lower-page) .voice-card .voice-story p:first-child {
    position: relative;
    text-align: left;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 5;
    display: -webkit-box !important;
    overflow: hidden;
    padding-right: 1.2em;
  }

  body:not(.lower-page) .voice-card .voice-story p:first-child::after {
    content: "...";
    position: absolute;
    background: #fff;
  }

  body:not(.lower-page) .voice-card .voice-story p:nth-of-type(2) {
    display: none !important;
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) .voice-card:not(.top-voice-card) {
    grid-template-columns: 72px minmax(0, 1fr) !important;
    column-gap: 14px !important;
    padding: 20px 18px 22px !important;
  }

  body:not(.lower-page) .voice-card > p {
    min-height: 6em;
    line-height: 1.5 !important;
  }

  body:not(.lower-page) .voice-card > p > span {
    min-height: 3.1em;
  }

  body:not(.lower-page) .voice-card .voice-story {
    margin-top: 14px;
  }

  body:not(.lower-page) .top-voice-card {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto 1fr !important;
    grid-template-areas: "photo" "title" "name" "story" !important;
    justify-items: center !important;
    text-align: center !important;
    row-gap: 10px !important;
    padding: 22px 20px 24px !important;
  }

  body:not(.lower-page) .top-voice-card .voice-photo {
    margin: 0 auto !important;
  }
}

body:not(.lower-page) .courses,
body:not(.lower-page) .reasons,
body:not(.lower-page) .voice,
body:not(.lower-page) .message {
  position: relative;
}

body:not(.lower-page) .courses::before,
body:not(.lower-page) .reasons::before,
body:not(.lower-page) .results::before {
  position: absolute;
  z-index: -1;
  pointer-events: none;
  color: rgba(31, 63, 54, 0.045);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(92px, 14vw, 184px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
}

/* 2026-09-28: TOPのCOURSE透かしは #courses .course-intro::before (PC限定・新設) と重複するため、
   既存側(.courses::before)はTOP限定で非表示に。下層ページ(mp-v2)の.courses::beforeは対象外。 */
body:not(.lower-page) .courses::before {
  content: none;
}

body:not(.lower-page) .reasons::before {
  content: "REASONS";
  left: clamp(8px, 3vw, 40px);
  top: clamp(10px, 2vw, 28px);
  color: rgba(31, 63, 54, 0.038);
}

body:not(.lower-page) .results::before {
  content: "ACHIEVEMENT";
  left: clamp(8px, 3vw, 40px);
  top: clamp(-6px, 1vw, 12px);
  z-index: 0;
  color: rgba(31, 63, 54, 0.04);
  font-size: clamp(68px, 9vw, 128px);
}

body:not(.lower-page) .courses,
body:not(.lower-page) .results-voice,
body:not(.lower-page) .results {
  overflow: hidden;
}

body:not(.lower-page) .results {
  position: relative;
  isolation: isolate;
}

body:not(.lower-page) .results > * {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .results::after {
  position: absolute;
  top: 4px;
  right: 4px;
  left: auto;
  z-index: 0;
  width: 0;
  height: 0;
  border-top: 20px solid transparent;
  border-bottom: 20px solid transparent;
  border-right: 34px solid var(--yellow);
  content: "";
  transform: rotate(16deg);
  opacity: 0.5;
  pointer-events: none;
  animation: decorTriSpin16 5.2s ease-in-out 4.6s infinite;
}

/* 2026-09-28: SPファースト方針により、REASONS/VOICE/ACHIEVEMENTの透かしをSPでも表示
   (以前は一括displaynoneでSP非表示)。font-sizeのみ375pxで実測調整、位置・色は既存のまま。
   COURSEは#courses .course-intro::before側で別途SP表示に対応済みのため、
   この一括非表示リストから除外(旧.courses::beforeはcontent:noneで別途恒常的に無効化)。 */
@media (max-width: 640px) {
  body:not(.lower-page) .reasons::before {
    font-size: 90px;
  }

  body:not(.lower-page) .results::before {
    font-size: 42px;
  }
}

/* 2026-09-29: MESSAGEセクションの大型ウォーターマーク新設。.message-copy.fade-upは下層ページにも
   共通のクラスのためbody:not(.lower-page)でTOP限定。 */
body:not(.lower-page) .message-copy.fade-up::before {
  content: "MESSAGE";
  position: absolute;
  z-index: -1;
  pointer-events: none;
  color: rgba(31, 63, 54, 0.045);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(82px, 15vw, 124px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  top: 0;
}

body:not(.lower-page) .hero::after {
  display: none !important;
}

body:not(.lower-page) .hero-copy::before {
  content: none !important;
  background: none !important;
}

body:not(.lower-page) .hero::before {
  background:
    radial-gradient(ellipse 54% 48% at 24% 45%, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.12) 36%, rgba(255, 255, 255, 0.04) 58%, rgba(255, 255, 255, 0) 78%) !important;
}

body:not(.lower-page) .hero h1,
body:not(.lower-page) .lead {
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.72),
    0 10px 28px rgba(255, 255, 255, 0.46) !important;
}

.loader-heading {
  font-size: clamp(34px, 4.1vw, 58px) !important;
  font-weight: 900 !important;
  line-height: 1.42 !important;
  letter-spacing: 0 !important;
}

.loader-line-accent {
  display: inline-block !important;
  min-width: max-content;
  white-space: nowrap;
  margin-left: -0.08em !important;
  color: var(--yellow) !important;
  font-family: Georgia, "Times New Roman", serif !important;
  font-size: 1.2em !important;
  font-weight: 400 !important;
}

.loader-keyword {
  display: inline-block;
  min-width: 3.35em;
  white-space: nowrap;
  color: inherit;
  font-family: inherit;
}

.loader-particle {
  display: inline-block !important;
  margin-left: 0.02em !important;
  color: inherit !important;
  font-family: inherit !important;
  font-size: 0.72em !important;
  line-height: 1 !important;
  vertical-align: 0.08em !important;
}

.loader-line-plain,
.loader-closing {
  display: inline-block;
  white-space: nowrap;
  color: var(--ink);
  font-family: inherit;
  letter-spacing: 0.08em;
}

@media (max-width: 640px) {
  body:not(.lower-page) .hero::before {
    background:
      radial-gradient(ellipse 64% 48% at 46% 36%, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0.08) 44%, rgba(255, 255, 255, 0) 74%) !important;
  }

  .loader-heading {
    font-size: clamp(27px, 7vw, 31px) !important;
  }

  .loader-line-accent {
    margin-left: -0.04em !important;
  }

  .loader-particle {
    font-size: 0.76em !important;
    vertical-align: 0.06em !important;
  }

  .loader-line-plain,
  .loader-closing {
    letter-spacing: 0.06em !important;
  }
}

/* FV/loading catch copy optical alignment */
body:not(.lower-page) .hero h1,
.loader-heading {
  line-height: 1.38 !important;
}

body:not(.lower-page) .hero h1 .hero-accent-line,
.loader-line-accent {
  margin-left: -0.06em !important;
  line-height: 1.28 !important;
}

body:not(.lower-page) .hero h1 .hero-particle,
.loader-particle {
  margin-left: -0.035em !important;
  font-size: 0.74em !important;
  letter-spacing: 0 !important;
  vertical-align: 0.07em !important;
}

body:not(.lower-page) .hero h1 .hero-closing,
.loader-line-plain,
.loader-closing {
  margin-left: 0.01em !important;
  margin-top: -0.005em !important;
  font-size: 1.12em !important;
  font-weight: 700 !important;
  letter-spacing: 0.045em !important;
  line-height: 1.24 !important;
}

@media (max-width: 640px) {
  body:not(.lower-page) .hero h1,
  .loader-heading {
    line-height: 1.36 !important;
  }

  body:not(.lower-page) .hero h1 .hero-accent-line,
  .loader-line-accent {
    margin-left: -0.045em !important;
    line-height: 1.26 !important;
  }

  /* 2026-09-27: hero-particle/loader-particleのmargin-leftをユーザー指定値へ更新。
     このブロックが実際に勝つ側のため、ここを直接調整し新規ルールの追加はしない。
     (hero-closing/loader-closing系のfont-sizeは、この後方の「Fable visual fixes」
     ブロック内@media(max-width:640px)が最終的に勝つため、そちら側で調整する。) */
  body:not(.lower-page) .hero h1 .hero-particle,
  .loader-particle {
    margin-left: -0.4em !important;
    font-size: 0.76em !important;
    letter-spacing: 0 !important;
    vertical-align: 0.055em !important;
  }

  body:not(.lower-page) .hero h1 .hero-closing,
  .loader-line-plain,
  .loader-closing {
    margin-left: 0.005em !important;
    margin-top: 0 !important;
    font-size: 1.04em !important;
    font-weight: 700 !important;
    letter-spacing: 0.035em !important;
  }
}

/* Final yellow CTA color override */
/* Final message/results small fixes */
body:not(.lower-page) .signature:empty {
  display: none !important;
  margin: 0 !important;
}

/* Final footer information grouping */
body:not(.lower-page) .footer {
  grid-template-columns: minmax(220px, 0.9fr) minmax(520px, 2fr) 42px !important;
  align-items: start !important;
}

body:not(.lower-page) .footer-info {
  display: grid;
  gap: 14px;
  align-content: start;
}

body:not(.lower-page) .footer-info .brand {
  margin-bottom: 2px;
}

body:not(.lower-page) .footer-info address {
  margin: 0;
}

body:not(.lower-page) .footer-info .footer-social {
  display: grid;
  gap: 6px;
  margin-top: 2px;
}

body:not(.lower-page) .footer-info .footer-social h3 {
  margin: 0 0 2px;
  color: var(--green);
  font-size: 12px;
  line-height: 1.4;
}

body:not(.lower-page) .footer-info .footer-social a {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin: 0;
  color: #5d685f !important;
  font-size: 12px;
  font-weight: 500 !important;
  line-height: 1.5;
}

@media (max-width: 980px) {
  body:not(.lower-page) .footer {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }

  body:not(.lower-page) .footer-info {
    gap: 12px;
  }
}
/* ===== Fable FVキャッチ調整 2026-07-04(カンプ準拠) =====
   1) 「」で始まる行のぶら下げ: 括弧の空白分を引き、
      括弧のインクと「変わる塾」「eyebrow」「リード」の左ラインを揃える
   2) 「変わる塾」はサイズ・太さで主張させない:
      ゴシック700 → 明朝系600+字間広めに(存在感は書体と字間で出す)
   3) 助詞「と」「が」はカンプどおり緑に */
body:not(.lower-page) .hero h1 .hero-accent-line,
.loader-line-accent {
  margin-left: -0.48em !important; /* 上書き対象: -0.06em !important(8876行台の後発ブロック) */
  font-weight: 600 !important; /* 「自分」「未来」 */
}

/* 「と」「が」は黄色のまま(親のアクセント色を継承)。色の上書きはしない */

body:not(.lower-page) .hero h1 .hero-closing,
.loader-line-plain,
.loader-closing {
  font-family: Georgia, "Times New Roman", serif !important; /* 和文は明朝フォールバック */
  font-weight: 600 !important; /* 上書き対象: 700 !important */
  letter-spacing: 0.2em !important; /* 上書き対象: 0.045em !important */
  font-size: 4.8rem !important; /* 上書き対象: 1.12em !important */
}

@media (max-width: 640px) {
  body:not(.lower-page) .hero h1 .hero-accent-line,
  .loader-line-accent {
    margin-left: -0.46em !important;
  }

  body:not(.lower-page) .hero h1 .hero-closing,
  .loader-line-plain,
  .loader-closing {
    letter-spacing: 0.14em !important; /* SPは幅が細いので控えめ */
    font-size: 2.7rem !important; /* 2026-09-27: ユーザー指定値。このブロックが実際に勝つ側 */
  }
}

/* Results section tone adjustment */
body:not(.lower-page) .results-voice {
  background: transparent;
}

body:not(.lower-page) .results-voice::after {
  background: #fbf0f3;
}

body:not(.lower-page) .results-voice .section-kicker {
  color: #b85b82;
}

body:not(.lower-page) .results h2,
body:not(.lower-page) .voice h2,
body:not(.lower-page) .admission-index h3 {
  color: #74364f;
}

body:not(.lower-page) .results .school-tags span {
  padding: 0;
  color: #74364f;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body:not(.lower-page) .results .school-tags span:not(:first-child)::before {
  margin-right: 4px;
  color: #b98aa0;
  content: "・";
}

body:not(.lower-page) .admission-index {
  position: relative;
  overflow: visible;
  background: rgba(255, 255, 255, 0.92);
}

body:not(.lower-page) .admission-index::after {
  position: absolute;
  top: -14px;
  right: -10px;
  z-index: 1;
  width: 46px;
  height: 46px;
  background-image: radial-gradient(circle, #2f7ed4 2.5px, transparent 3px);
  background-size: 14px 14px;
  content: "";
  opacity: 0.6;
  pointer-events: none;
}

body:not(.lower-page) .admission-index-list span {
  color: #1f3f36;
}

body:not(.lower-page) .results .button.ghost.small {
  color: #74364f;
  border-color: #e9bfd0;
}

body:not(.lower-page) .results .button.ghost.small:hover,
body:not(.lower-page) .results .button.ghost.small:focus-visible {
  color: #fff;
  background: #74364f;
  border-color: #74364f;
  transform: translateY(-1px);
}

body:not(.lower-page) .admission-index-list a {
  color: #74364f;
  border-bottom-color: #e9bfd0;
}

body:not(.lower-page) .admission-index-list a::after {
  color: #b85b82;
}

body:not(.lower-page) .voice-story a {
  color: #74364f;
  border-bottom-color: #e9bfd0;
}

body:not(.lower-page) .voice-control {
  color: #74364f;
  border-color: #e9bfd0;
}

body:not(.lower-page) .voice-control.prev:hover,
body:not(.lower-page) .voice-control.next:hover,
body:not(.lower-page) .voice-slider-outer .voice-control.prev:hover,
body:not(.lower-page) .voice-slider-outer .voice-control.next:hover {
  background: #fbf0f3;
}

/* recommendセクション: 320px前後の狭いSP幅の右切れ対応。
   原因は @media (max-width: 640px) 内の固定カード幅 154px(既存 !important)。
   その640px用ブロックは.voice-card/.ctaと共有のため触らず、
   374px以下だけをスコープする新規ブロックで .recommend-grid のみ上書きする。
   375pxは対象外のため2972/2982行目の2列指定(154px固定)のまま変化なし
   (2026-09-13: 2972/2982/本ブロックのセレクタに body:not(.lower-page) を付与し、
   2801行目の全幅5列指定より詳細度を上げて確実に有効化した)。
   既存の !important な固定幅を上書きするには !important が必須のため、
   このブロックに限り新規追加している。 */
@media (max-width: 374px) {
  body:not(.lower-page) .recommend-grid {
    grid-template-columns: 1fr !important;
  }

  .recommend-grid article {
    width: auto !important;
  }
}


/* 中学生コース: 320px前後の狭いSP幅で固定154px×2列が表示領域を超えるため、
   TOPと同じ境界幅だけカードを可変幅にする。下層全体へは広げず、まずpage-jrに限定する。 */
@media (max-width: 374px) {
  body.page-jr.recommend-six .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body.page-jr.recommend-six .recommend-grid article {
    width: auto !important;
    min-width: 0;
  }
}

/* 中学生コース: 6項目をPCでは3列×2行で表示 */
@media (min-width: 981px) {
  body.recommend-six .recommend-grid {
    grid-template-columns: repeat(3, minmax(0, 200px));
    justify-content: center;
  }
}

.lower-page .course-card a[href]:not(.button) {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  margin: 4px 28px 0;
  color: var(--green);
  font-weight: 700;
  text-decoration: none;
}

.lower-page .course-card a[href]:not(.button)::after {
  content: "→";
  transition: transform 0.2s ease;
}

.lower-page .course-card a[href]:not(.button):hover::after,
.lower-page .course-card a[href]:not(.button):focus-visible::after {
  transform: translateX(3px);
}

/* ==========================================================================
   TOP「選ばれる3つの理由」「入塾までの流れ」: SPでもsticky演出を維持する。
   対象: .reasons-sticky-wrap .reasons / .flow-sticky の2箇所のみ。
   既存の @media (max-width: 980px) 内にあるSP解除ルール(いずれも
   position: relative !important 等、980行台・3300行台に重複して存在)を
   上書きするため、このブロックのみ新規 !important を使用する。
   既存のSP解除ルール自体は削除せず、このブロックを後方に追記して
   カスケードで上書きする方式を取っている。
   他セクション(recommendほか)・.site-header/.page-top/.mobile-nav には
   一切影響しない。
   ========================================================================== */

/* ---- 入塾までの流れ(TOP簡易版): 写真の切り替わりをPC同様にsticky内で維持 ---- */
@media (max-width: 980px) {
  body:not(.lower-page) .flow-section {
    min-height: 220vh !important;
  }

  body:not(.lower-page) .flow-sticky {
    position: sticky !important;
    top: 92px !important;
    grid-template-columns: 1fr !important;
  }

  body:not(.lower-page) .flow-photos {
    height: min(48svh, 380px) !important;
    min-height: 240px !important;
    aspect-ratio: auto !important;
  }

  body:not(.lower-page) .flow-photo,
  body:not(.lower-page) .flow-photo:not(.active) {
    display: block !important;
    opacity: 0 !important;
    transform: translateY(24px) scale(0.97) !important;
    transition: opacity 0.4s ease, transform 0.5s ease !important;
  }

  body:not(.lower-page) .flow-photo.active {
    opacity: 1 !important;
    transform: translateY(0) scale(1) !important;
  }
}

@media (max-width: 640px) {
  body:not(.lower-page) .flow-section {
    min-height: 240vh !important;
  }

  body:not(.lower-page) .flow-sticky {
    top: 80px !important;
  }
}

/* ---- sticky復活の前提条件: body の overflow-x:hidden/overflow-y:auto を無効化 ----
   原因調査の結果、@media (max-width: 640px) 内の既存ルール(3062行目付近)
   body:not(.lower-page) { overflow-x: hidden !important; overflow-y: auto !important; }
   が、TOP内の position:sticky を無効化していた
   (bodyが新しいスクロールコンテナ扱いになり、sticky要素が固定されなくなる)。
   overflow-y だけを visible に戻そうとしても、CSSの仕様上
   「片方の軸が hidden 系で他方が visible の場合、visible は自動的に auto に
   変換される」ため無効(実測で確認済み)。
   このプロジェクトの起点で発見された sticky破綻の修正(html の
   overflow-x: hidden → overflow-x: clip、5647行目)と同じ考え方で、
   横のはみ出し防止は維持しつつスクロールコンテナ化しない overflow: clip を
   両軸に使う。既存ルール自体は削除せず、640px以下の範囲だけ上書きする。
   768px(641〜980px)には影響しない。 */
@media (max-width: 640px) {
  body:not(.lower-page) {
    overflow-x: clip !important;
    overflow-y: clip !important;
  }
}

/* Lower-page display breadcrumb */
.lower-page .breadcrumb {
  box-sizing: border-box;
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 18px clamp(18px, 5vw, 56px) 0;
  color: #666;
  font-size: 12px;
  line-height: 1.7;
}

.lower-page .breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lower-page .breadcrumb li {
  min-width: 0;
  overflow-wrap: anywhere;
}

.lower-page .breadcrumb li + li::before {
  content: ">";
  margin-right: 8px;
  color: #a7afa5;
}

.lower-page .breadcrumb a {
  color: var(--green);
  text-decoration: none;
}

.lower-page .breadcrumb a:hover,
.lower-page .breadcrumb a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 3px;
}


.teacher-profile-section {
  max-width: none;
  margin: 0 0 104px;
  padding: 64px clamp(22px, 5vw, 56px);
  background: #f8faf7;
}

.teacher-profile-heading {
  max-width: 1160px;
  margin: 0 auto 28px;
}

.teacher-profile-list {
  max-width: 1160px;
  margin: 0 auto;
  display: grid;
  gap: 28px;
}

.teacher-profile-card {
  display: grid;
  grid-template-columns: minmax(220px, 0.34fr) minmax(0, 1fr);
  gap: 30px;
  padding: 28px;
  background: #fff;
  border: 1px solid #dfe9df;
  border-radius: 22px;
  box-shadow: 0 12px 28px rgba(21, 38, 62, 0.05);
}

.teacher-profile-photo-wrap {
  min-width: 0;
}

.teacher-profile-photo {
  min-height: 320px;
  background-color: #eef3ed;
  background-position: center top;
  background-repeat: no-repeat;
  background-size: cover;
  border-radius: 18px;
}

.teacher-profile-photo.teacher-photo-hirano {
  background-image: url("img/hirano.jpg");
}

.teacher-profile-photo.teacher-photo-zaki {
  background-image: url("img/zaki.jpg");
}

.teacher-profile-body h3 {
  margin: 0;
  color: #333;
  font-size: clamp(24px, 3vw, 32px);
}

.teacher-profile-role {
  margin: 6px 0 18px;
  color: var(--green);
  font-weight: 700;
}

.teacher-profile-lead {
  margin: 0 0 20px;
  color: #333;
  font-weight: 600;
  line-height: 1.85;
}

.teacher-profile-copy {
  color: #5d685f;
  font-size: 14px;
  line-height: 1.85;
}

.teacher-profile-copy p {
  margin: 0;
}

.teacher-profile-copy p + p {
  margin-top: 12px;
}

@media (max-width: 640px) {
  .teacher-profile-card {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 20px;
  }

  .teacher-profile-photo {
    min-height: 280px;
  }
}


@media (min-width: 981px) {
  #primary-learning .course-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* 中学生コース料金表 */
.price-table-intro {
  margin: 12px 0 28px;
  color: #5d685f;
}

.price-table-block + .price-table-block {
  margin-top: 40px;
}

.price-table-block h3 {
  margin: 0 0 14px;
  color: var(--green);
  font-size: clamp(18px, 2vw, 22px);
}

.price-table-scroll {
  overflow: hidden;
  border: 1px solid #dfe9df;
  border-radius: 18px;
  background: #fff;
}

.price-table {
  width: 100%;
  border-collapse: collapse;
  color: #333;
  font-size: 14px;
  line-height: 1.6;
}

.price-table th,
.price-table td {
  padding: 16px 18px;
  border-bottom: 1px solid #e6eee6;
  text-align: left;
  vertical-align: middle;
}

.price-table thead th {
  color: #fff;
  background: var(--green);
  font-weight: 700;
  white-space: nowrap;
}

.price-table tbody th {
  font-weight: 600;
}

.price-table tbody tr:nth-child(even) {
  background: #f5f9f4;
}

.price-table tbody tr:last-child th,
.price-table tbody tr:last-child td {
  border-bottom: 0;
}

.price-table-note {
  margin: 12px 4px 0;
  color: #5d685f;
  font-size: 13px;
  line-height: 1.7;
}

/* 料金表SP表示: カード型(B案採用済み) */
@media (max-width: 640px) {
  .price-table-scroll {
    overflow: visible;
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .price-table {
    display: block;
    min-width: 0;
    background: transparent;
  }

  .price-table thead {
    display: none;
  }

  .price-table tbody {
    display: grid;
    gap: 14px;
  }

  .price-table tbody tr {
    display: block;
    overflow: hidden;
    background: #fff;
    border: 1px solid #dfe9df;
    border-radius: 16px;
  }

  .price-table th[scope="row"] {
    display: block;
    padding: 14px 16px;
    color: var(--green);
    background: #f0f6ef;
    border-bottom: 1px solid #dfe9df;
    font-weight: 700;
  }

  .price-table td {
    display: flex;
    gap: 16px;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid #e6eee6;
    text-align: right;
    overflow-wrap: anywhere;
  }

  .price-table td:last-child {
    border-bottom: 0;
  }

  .price-table td::before {
    flex: 0 0 auto;
    color: #5d685f;
    font-weight: 600;
    text-align: left;
  }

  .price-table td:nth-child(2)::before {
    content: "授業時間";
  }

  .price-table td:nth-child(3)::before {
    content: "月額";
  }

  .price-table td:nth-child(3) {
    color: var(--green);
    font-size: 1.08em;
    font-weight: 700;
  }

  .price-table-scroll[aria-label="オプション料金表"] td:nth-child(2)::before {
    content: "回数・時間";
  }

  .price-table-scroll[aria-label="小学4・5年生の料金表"] td:nth-child(2)::before,
  .price-table-scroll[aria-label="小学6年生の料金表"] td:nth-child(2)::before {
    content: "曜日・時間";
  }

  .price-table-scroll[aria-label="その他費用の料金表"] .price-table tbody {
    gap: 8px;
  }

  .price-table-scroll[aria-label="その他費用の料金表"] .price-table tbody tr {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    align-items: center;
  }

  .price-table-scroll[aria-label="その他費用の料金表"] .price-table th[scope="row"] {
    padding: 11px 12px;
    color: #333;
    background: #fff;
    border-bottom: 0;
    font-size: 13px;
  }

  .price-table-scroll[aria-label="その他費用の料金表"] .price-table td {
    display: block;
    padding: 11px 12px;
    border-bottom: 0;
    font-size: 13px;
  }

  .price-table-scroll[aria-label="その他費用の料金表"] .price-table td::before {
    content: none;
  }
}

/* About: principal message */
.principal-message {
  padding: clamp(64px, 8vw, 100px) clamp(20px, 5vw, 56px);
  background: #f8faf7;
}

.principal-message-heading {
  max-width: 1080px;
  margin: 0 auto 30px;
  text-align: center;
}

.principal-message-heading h2 {
  margin: 0;
  color: #333;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.5;
}

.principal-message-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(28px, 5vw, 54px);
  max-width: 720px;
  margin: 0 auto;
  padding: clamp(24px, 4vw, 44px);
  background: #fff;
  border: 1px solid #dfe9df;
  border-radius: 24px;
  box-shadow: 0 12px 30px rgba(21, 38, 62, 0.06);
}


.principal-message-copy {
  color: #4f5d54;
  line-height: 1.95;
}

.principal-message-copy strong {
  color: #5b955a;
}

.principal-message-copy p {
  margin: 0;
}

.principal-message-copy p + p {
  margin-top: 18px;
}

.principal-message-copy .principal-message-signature {
  margin-top: 28px;
  color: #333;
  font-weight: 700;
  text-align: right;
}

@media (max-width: 640px) {
  .principal-message {
    padding: 56px 18px;
  }

  .principal-message-card {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 20px;
    border-radius: 20px;
  }


  .principal-message-copy {
    line-height: 1.85;
  }
}

/* Coaching and counseling: note for parents */
.parents-note {
  max-width: 1080px;
  margin: 32px auto 0;
  padding: clamp(22px, 4vw, 34px);
  background: #f8faf7;
  border: 1px solid #dfe9df;
  border-radius: 20px;
  box-shadow: 0 10px 24px rgba(21, 38, 62, 0.05);
}

.parents-note h3 {
  margin: 0 0 12px;
  color: #333;
  font-size: clamp(20px, 2.5vw, 26px);
  line-height: 1.5;
}

.parents-note p {
  margin: 0;
  color: #5d685f;
  line-height: 1.85;
}

/* 2026-09-27: .parents-noteはabout/reason.htmlとabout/coaching_counseling.htmlの2ページ共通のため、
   about/reason限定の指示に沿ってbody.page-about-reasonでスコープ。 */
body.page-about-reason .parents-note p {
  color: #333;
}

.parents-note a {
  color: var(--green);
  font-weight: 700;
  text-underline-offset: 0.18em;
}

.foundation-note p + p {
  margin-top: 16px;
}

/* 中学生コース デザイン移植: トーンとアクセント配色 */
body.mp-v2 {
  --jr-blue: #2f7ed4;
  --jr-pink: #ee6d96;
  --jr-yellow: #ffca08;
}

body.mp-v2 .reason-card {
  border-color: rgba(91, 149, 90, 0.18);
  box-shadow: 0 14px 34px rgba(21, 38, 62, 0.08);
  padding: 150px 25px 30px;
}

body.mp-v2 .reason-card.green {
  --jr-card-accent: var(--green);
  background: #eef7e9;
  border-top: 4px solid var(--jr-card-accent);
}

body.mp-v2 .reason-card.blue {
  --jr-card-accent: var(--jr-blue);
  background: #edf5ff;
  border-top: 4px solid var(--jr-card-accent);
}

body.mp-v2 .reason-card.pink {
  --jr-card-accent: var(--jr-pink);
  background: #fdf0f4;
  border-top: 4px solid var(--jr-card-accent);
}

body.mp-v2 .reason-card strong,
body.mp-v2 .reason-card h3 {
  color: var(--jr-card-accent);
}

body.mp-v2 .reason-card h3 {
  position: relative;
}

body.mp-v2 .reason-card h3::after {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 42px;
  height: 3px;
  background: var(--jr-card-accent);
  border-radius: 999px;
  content: "";
}

body.mp-v2 .section-kicker::before {
  display: inline-block;
  width: 1em;
  height: 1px;
  margin-right: 0.55em;
  vertical-align: middle;
  background: var(--jr-yellow);
  content: "";
}

@media (min-width: 641px) {
  body.mp-v2 .price-table-scroll[aria-label="個別カスタマイズコースの料金表"] .price-table td:nth-child(3),
  body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table td:nth-child(3) {
    font-size: 1.05em;
    font-weight: 700;
  }

  body.mp-v2 .price-table-scroll[aria-label="個別カスタマイズコースの料金表"] .price-table td:nth-child(3) {
    color: var(--green);
  }
}

@media (max-width: 640px) {
  body.mp-v2 .price-table-scroll[aria-label="個別カスタマイズコースの料金表"] .price-table tbody tr {
    border-left: 4px solid var(--green);
  }

  body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table tbody tr {
    border-left: 4px solid var(--jr-blue);
  }
}

/* 中学生コース デザイン移植: FV */
body.mp-v2 .hero {
  min-height: 620px;
  overflow: hidden;
}

body.mp-v2 .hero-copy {
  max-width: 48%;
  padding-top: 84px;
}

body.mp-v2 .hero h1 > span {
  color: var(--green);
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
}

body.mp-v2 .hero-visual .jr-hero-photo {
  inset: 52px 74px 58px 50%;
  border-radius: 46% 8% 45% 20% / 45% 22% 46% 18%;
  background-position: center 34%;
  box-shadow: 0 20px 48px rgba(21, 38, 62, 0.15);
}

body.mp-v2 .jr-hero-badges {
  position: absolute;
  top: 45%;
  right: 24px;
  z-index: 3;
  display: grid;
  gap: 14px;
}

body.mp-v2 .jr-hero-badge {
  display: grid;
  width: 94px;
  height: 94px;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 50%;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  box-shadow: 0 12px 28px rgba(21, 38, 62, 0.18);
}

body.mp-v2 .jr-hero-badge--blue {
  background: var(--jr-blue);
}

body.mp-v2 .jr-hero-badge--pink {
  margin-top: 0;
  margin-left: 34px;
  background: var(--jr-pink);
}

body.mp-v2 .hero::after {
  right: auto;
  bottom: 28px;
  left: 3%;
  width: 0;
  height: 0;
  border-top: 42px solid transparent;
  border-bottom: 42px solid transparent;
  border-left: 68px solid var(--jr-pink);
  border-radius: 0;
  background: transparent;
  transform: rotate(-14deg);
  opacity: 0.72;
}

body.mp-v2 .hero-visual::before {
  position: absolute;
  top: 24px;
  right: 20px;
  z-index: 2;
  width: 112px;
  height: 88px;
  background-image: radial-gradient(circle, var(--jr-blue) 2.5px, transparent 3px);
  background-size: 16px 16px;
  content: "";
  opacity: 0.68;
}

@media (max-width: 640px) {
  body.mp-v2 .hero {
    min-height: auto;
    padding-top: 50px;
    padding-bottom: 30px;
  }

  body.mp-v2 .hero-copy {
    max-width: none;
    padding-top: 22px;
  }

  /* 2026-09-27: 下層hero共通基準。h1が1行/2行でもlead位置が大きくズレないよう、
     hero-copyをflex縦積みにし、lead側はmargin-auto押し下げで画像下端に揃える方式へ統一。
     旧: h1にpadding-top:3rem、leadにmargin-top:160px/padding-top:120pxの固定オフセットで
     位置合わせしていたが、h1の行数が変わるとズレていたため撤去。 */
  body.mp-v2 .hero-copy {
    display: flex !important;
    flex-direction: column !important;
    width: 100%;
    min-height: 370px;
  }

  body.mp-v2 .hero-copy .eyebrow {
    margin: 0 0 0.5rem !important;
  }

  body.mp-v2 .hero-copy h1 {
    padding-top: 0 !important;
    margin: 0 !important;
  }

  body.mp-v2 .hero-copy .lead {
    position: static !important;
    padding-top: 0 !important;
    margin: auto 0 0 !important;
  }

  body.mp-v2 .hero h1 {
    max-width: 52%;
  }

  body.mp-v2 .hero .lead {
    max-width: none;
    font-size: 16px !important;
  }

  /* 2026-09-26: about/index.htmlのSP hero画像形状(右上に収まるブロブ型)を
     下層共通のSP heroデフォルトへ昇格。旧・画面幅いっぱいに伸びる形状は廃止。 */
  body.mp-v2 .hero-visual .jr-hero-photo {
    inset: 75px 0 48px 40%;
    height: 250px;
    border-radius: 46% 8% 45% 20% / 45% 22% 46% 18%;
    background-position: center 34%;
    box-shadow: 0 20px 48px rgba(21, 38, 62, 0.15);
  }

  /* 2026-09-26: バッジが画像上部(photo top+3px)に寄りすぎていたため、画像右下側へ移動。
     photoはhero-visual基準でtop:75px/height:250px(bottom≈325px)。
     バッジ2個(68px×2+gap10px=146px)が画像下端付近に収まるようtopを172pxへ。縦並び関係は維持。 */
  body.mp-v2 .jr-hero-badges {
    top: 172px;
    right: 5px;
    gap: 10px;
  }

  body.mp-v2 .jr-hero-badge {
    width: 68px;
    height: 68px;
    border-width: 2px;
    font-size: 11px;
    margin-left: 20px;
  }

  body.mp-v2 .jr-hero-badge--pink {
    margin-top: 0;
    margin-left: 0;
  }

  body.mp-v2 .hero::after {
    right: auto !important;
    bottom: 126px !important;
    left: 0%;
    width: 0 !important;
    height: 0 !important;
    border-top-width: 25px;
    border-bottom-width: 25px;
    border-left-width: 42px;
  }

  body.mp-v2 .hero-visual::before {
    top: 20px;
    right: -28px;
    width: 72px;
    height: 58px;
    background-size: 12px 12px;
  }
}

/* 中学生コース デザイン移植: 2コース概要カード */
body.mp-v2 .courses .course-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

body.mp-v2 .jr-overview-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 14px 34px rgba(21, 38, 62, 0.08);
}

body.mp-v2 .jr-overview-card--green {
  --jr-overview-accent: var(--green);
  --jr-overview-soft: #eef7e9;
  border: 1.5px solid #7fcf76;
}

body.mp-v2 .jr-overview-card--blue {
  --jr-overview-accent: var(--jr-blue);
  --jr-overview-soft: #edf5ff;
  border: 1.5px solid #8cbcf3;
}

body.mp-v2 .jr-overview-card .course-image {
  border-bottom: 1px solid rgba(21, 38, 62, 0.08);
}

body.mp-v2 .jr-overview-heading {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 24px 28px 18px;
}

body.mp-v2 .jr-overview-number {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  color: var(--jr-overview-accent);
  border: 2px solid var(--jr-overview-accent);
  border-radius: 50%;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 700;
}

body.mp-v2 .jr-overview-heading h3 {
  margin: 0;
  color: var(--jr-overview-accent);
}

body.mp-v2 .jr-overview-heading small {
  margin: 3px 0 0;
  color: var(--jr-overview-accent);
}

body.mp-v2 .jr-overview-details {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 16px 12px;
  margin: 0;
  padding: 0 28px;
}

body.mp-v2 .jr-overview-details dt {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  color: var(--jr-overview-accent);
  background: var(--jr-overview-soft);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
}

body.mp-v2 .jr-overview-details dd {
  margin: 0;
  color: #333;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.8;
}

body.mp-v2 .jr-overview-card .chips {
  margin-top: 20px;
  margin-bottom: 0;
}

body.mp-v2 .jr-overview-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: auto 28px 0;
  padding: 20px 0 28px;
}

body.mp-v2 .course-card .jr-overview-links a[href]:not(.button) {
  margin: 0;
  color: var(--jr-overview-accent);
}

body.mp-v2 .course-card .jr-overview-price-link::after {
  content: "→";
}

@media (max-width: 640px) {
  body.mp-v2 .courses .course-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  body.mp-v2 .jr-overview-heading {
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    padding: 20px 20px 16px;
  }

  body.mp-v2 .jr-overview-number {
    width: 48px;
    height: 48px;
    font-size: 17px;
  }

  body.mp-v2 .jr-overview-details {
    gap: 14px 10px;
    padding: 0 20px;
  }

  body.mp-v2 .jr-overview-card .chips {
    margin-right: 20px;
    margin-left: 20px;
  }

  body.mp-v2 .jr-overview-links {
    margin-right: 20px;
    margin-left: 20px;
    padding-bottom: 22px;
  }
}

/* 中学生コース デザイン移植: セクション配色・配置・装飾 */
body.mp-v2 .jr-overview-card .chips span {
  position: relative;
  isolation: isolate;
}

body.mp-v2 .jr-overview-card .chips span::before {
  position: absolute;
  inset: -1px;
  z-index: -1;
  background: var(--jr-overview-soft);
  border: 1px solid var(--jr-overview-accent);
  border-radius: inherit;
  content: "";
}

body.mp-v2 .courses {
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}

body.mp-v2 .courses .course-intro {
  max-width: 100%;
}

body.mp-v2 .reasons {
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
  max-width: none;
  padding: 72px max(22px, calc((100% - 1068px) / 2)) 84px;
  background: #fffcf0;
}

body.mp-v2 .reasons .reasons-title {
  max-width: 760px;
}

body.mp-v2 .reasons .reason-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

body.mp-v2 .reasons .reason-card {
  background: #fff;
}

body.mp-v2 .recommend,
body.mp-v2 .courses,
body.mp-v2 .reasons,
body.mp-v2 .price-section,
body.mp-v2 .faq-section {
  position: relative;
  overflow: hidden;
}

body.mp-v2 .jr-section-decor {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

body.mp-v2 .jr-section-decor::before,
body.mp-v2 .jr-section-decor::after {
  position: absolute;
  content: "";
}

body.mp-v2 .jr-section-decor--recommend::before {
  top: 18px;
  right: 28px;
  width: 78px;
  height: 78px;
  background: repeating-linear-gradient(45deg, rgba(47, 126, 212, 0.52) 0 5px, transparent 5px 11px);
  border-radius: 50%;
  opacity: 0.62;
}

body.mp-v2 .jr-section-decor--recommend::after {
  bottom: 20px;
  left: 18px;
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid var(--jr-pink);
  transform: rotate(16deg);
  opacity: 0.58;
}

body.mp-v2 .jr-section-decor--courses::before {
  top: 14px;
  right: 18px;
  width: 96px;
  height: 72px;
  background-image: radial-gradient(circle, var(--jr-blue) 2.5px, transparent 3px);
  background-size: 15px 15px;
  opacity: 0.55;
}

body.mp-v2 .jr-section-decor--courses::after {
  bottom: 24px;
  left: 20px;
  width: 66px;
  height: 66px;
  background: repeating-linear-gradient(-45deg, rgba(238, 109, 150, 0.5) 0 4px, transparent 4px 10px);
  border-radius: 50%;
  opacity: 0.62;
}

body.mp-v2 .jr-section-decor--reasons::before {
  top: 22px;
  left: 22px;
  border-top: 27px solid transparent;
  border-bottom: 27px solid transparent;
  border-left: 45px solid var(--jr-pink);
  transform: rotate(-18deg);
  opacity: 0.56;
}

body.mp-v2 .jr-section-decor--reasons::after {
  right: 26px;
  bottom: 22px;
  width: 88px;
  height: 66px;
  background-image: radial-gradient(circle, var(--jr-blue) 2.5px, transparent 3px);
  background-size: 14px 14px;
  opacity: 0.52;
}

body.mp-v2 .jr-section-decor--price::before {
  top: 18px;
  right: 22px;
  width: 82px;
  height: 82px;
  background: repeating-linear-gradient(45deg, rgba(255, 202, 8, 0.64) 0 5px, transparent 5px 11px);
  border-radius: 50%;
  opacity: 0.7;
}

body.mp-v2 .jr-section-decor--price::after {
  top: 48%;
  left: 12px;
  border-top: 22px solid transparent;
  border-bottom: 22px solid transparent;
  border-left: 38px solid var(--jr-pink);
  transform: rotate(12deg);
  opacity: 0.55;
}

body.mp-v2 .jr-section-decor--faq::before {
  top: 30px;
  left: 22px;
  width: 82px;
  height: 64px;
  background-image: radial-gradient(circle, var(--jr-blue) 2.5px, transparent 3px);
  background-size: 14px 14px;
  opacity: 0.5;
}

body.mp-v2 .jr-section-decor--faq::after {
  right: 24px;
  bottom: 24px;
  width: 70px;
  height: 70px;
  background: repeating-linear-gradient(-45deg, rgba(238, 109, 150, 0.5) 0 4px, transparent 4px 10px);
  border-radius: 50%;
  opacity: 0.6;
}

body.mp-v2 .recommend > :not(.jr-section-decor),
body.mp-v2 .courses > :not(.jr-section-decor),
body.mp-v2 .reasons > :not(.jr-section-decor),
body.mp-v2 .price-section > :not(.jr-section-decor),
body.mp-v2 .faq-section > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

@media (max-width: 640px) {
  body.mp-v2 .courses {
    gap: 24px;
  }

  body.mp-v2 .reasons {
    gap: 24px;
    padding: 54px 22px 64px;
  }

  body.mp-v2 .reasons .reason-cards {
    grid-template-columns: minmax(0, 1fr);
  }

  body.mp-v2 .jr-section-decor--recommend::before,
  body.mp-v2 .jr-section-decor--price::before {
    width: 58px;
    height: 58px;
  }

  body.mp-v2 .jr-section-decor--courses::before,
  body.mp-v2 .jr-section-decor--reasons::after,
  body.mp-v2 .jr-section-decor--faq::before {
    width: 58px;
    height: 46px;
  }

  body.mp-v2 .jr-section-decor--courses::after,
  body.mp-v2 .jr-section-decor--faq::after {
    width: 48px;
    height: 48px;
  }
}

/* 中学生コース デザイン移植: ボタン・基調文字色 */
body.mp-v2 .jr-overview-card,
body.mp-v2 .jr-overview-card:hover {
  cursor: default;
  transform: none;
  box-shadow: 0 14px 34px rgba(21, 38, 62, 0.08);
}

/* 2026-09-27: border:1.5px solid transparentだったため、後方の7046付近にあった
   「ボタンらしい枠線」指定(border:solid 1px)が同詳細度・先勝ちで無効化されていた。
   このルールが実際に効いている側のため、ここで可視の枠線色(既存のリンク文字色と統一)へ修正し、
   min-width:163pxも追加。7046付近の旧ルールは常に上書きされ死んでいたため削除。 */
body.mp-v2 .course-card .jr-overview-links a[href]:not(.button) {
  justify-content: center;
  min-width: 163px;
  min-height: 44px;
  padding: 11px 20px;
  border: 1.5px solid var(--jr-overview-accent);
  border-radius: 999px;
  font-size: 13px;
  line-height: 1.5;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

body.mp-v2 .jr-overview-card--green .jr-overview-links a.jr-overview-price-link[href]:not(.button) {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
}

body.mp-v2 .jr-overview-card--green .jr-overview-links a.jr-overview-price-link[href]:not(.button):hover,
body.mp-v2 .jr-overview-card--green .jr-overview-links a.jr-overview-price-link[href]:not(.button):focus-visible {
  background: #3f7d45;
  border-color: #3f7d45;
}

body.mp-v2 .jr-overview-card--blue .jr-overview-links a.jr-overview-price-link[href]:not(.button) {
  color: #fff;
  background: var(--jr-blue);
  border-color: var(--jr-blue);
}

body.mp-v2 .jr-overview-card--blue .jr-overview-links a.jr-overview-price-link[href]:not(.button):hover,
body.mp-v2 .jr-overview-card--blue .jr-overview-links a.jr-overview-price-link[href]:not(.button):focus-visible {
  background: #2568b4;
  border-color: #2568b4;
}

/* 2026-09-29: 旧「atama+を見る」「育脳を見る」は無classリンクで、右記a[href]:not(.button)の
   汎用枠線スタイルに依存していたが個別hoverが無い/不揃いだった。HTML側に class="button ghost small"
   を付与し、他の.button.ghostと同じhoverシステムに統合。色は新規に作らずカード側で既に
   定義済みの--jr-overview-accent(green/jr-blue)をそのまま使用。
   旧a[href="ikunou.html"]:not(.button)専用ルールはclass付与により不要になったため削除。 */
body.mp-v2 .jr-overview-card .button.ghost {
  color: var(--jr-overview-accent);
  border-color: var(--jr-overview-accent);
}

body.mp-v2 .jr-overview-card .button.ghost:hover,
body.mp-v2 .jr-overview-card .button.ghost:focus-visible {
  color: #fff;
  background: var(--jr-overview-accent);
  transform: translateY(-1px);
}

body.mp-v2 .jr-overview-links a[href]:focus-visible {
  outline: 3px solid rgba(255, 202, 8, 0.72);
  outline-offset: 3px;
}

body.mp-v2 .hero h1,
body.mp-v2 .message-copy h2,
body.mp-v2 .recommend .section-title h2,
body.mp-v2 .courses .course-intro h2,
body.mp-v2 .reasons .reasons-title h2,
body.mp-v2 .price-section .extra-head h2,
/* 2026-09-27: about/support.htmlの「料金について」見出しがh3のため、このルールに
   含まれず既存の.extra-head h3{color:var(--ink)}へ落ちて色がズレていた。h2と揃えてh3も追加。 */
body.mp-v2 .price-section .extra-head h3,
body.mp-v2 .faq-section .extra-head h3,
/* 2026-09-27: about/flow.html「入塾までの4ステップ」がこのリストに未含有で、
   body.mp-v2の--ink未再定義によりルートの#071833(濃紺)へ落ちて色がズレていた(色は推測せず、
   同種の他見出しと同じ既存#333へ統一)。.lower-section .extra-headは19ページ共通の
   汎用セクションのため、他の同種見出しと矛盾しないようここに追加。 */
body.mp-v2 .lower-section .extra-head h2,
body.mp-v2 .faq-item summary {
  color: #333 !important;
}

body.mp-v2 .faq-item summary {
  font-size: 16px;
}

/* 2026-09-27: 旧: このセレクタ群をcolor:#333/#555の2ブロックに分けて重複指定していた
   (:not(.section-kicker)なしのため.message-copy p等でsection-kickerの緑色を#555が
   意図せず上書きしていた)。下方のfont-weight:400ブロック(:not(.section-kicker)付き、
   ユーザー指定の一覧と同一セレクタ)にcolor:#333を統合し、ここは削除。 */

/* 中学生コース デザイン移植: Webフォント・余白 */
body.mp-v2,
body.mp-v2 button,
body.mp-v2 input,
body.mp-v2 select,
body.mp-v2 textarea,
body.mp-v2 h1,
body.mp-v2 h2,
body.mp-v2 h3,
body.mp-v2 h4,
body.mp-v2 p,
body.mp-v2 a,
body.mp-v2 li,
body.mp-v2 dt,
body.mp-v2 dd,
body.mp-v2 summary,
body.mp-v2 th,
body.mp-v2 td,
body.mp-v2 small {
  font-family: "Noto Sans JP", "Yu Gothic", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
}

body.mp-v2 .eyebrow,
body.mp-v2 .section-kicker,
body.mp-v2 .jr-course-label,
body.mp-v2 .jr-overview-heading small,
body.mp-v2 .jr-overview-number,
body.mp-v2 .faq-item summary span {
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif !important;
}

body.mp-v2 .price-section {
  padding-top: 64px;
}

@media (max-width: 640px) {
  body.mp-v2 .price-section {
    padding-top: 42px;
  }
}

/* 中学生コース デザイン移植: 料金コース詳細ブロック */
body.mp-v2 .jr-course-block {
  padding: 28px;
  background: #fff;
  border: 1.5px solid var(--jr-course-border);
  border-radius: 18px;
}

body.mp-v2 .jr-course-block--green {
  --jr-course-accent: #78bd65;
  --jr-course-border: #7fcf76;
}

body.mp-v2 .jr-course-block--blue {
  --jr-course-accent: #69a9ee;
  --jr-course-border: #8cbcf3;
}

body.mp-v2 .jr-course-block + .jr-course-block,
body.mp-v2 .jr-course-block + .price-table-block {
  margin-top: 40px;
}

body.mp-v2 .jr-course-label {
  margin: 0 0 6px;
  color: var(--jr-course-accent);
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

body.mp-v2 .jr-course-title {
  margin: 0 0 22px;
  color: var(--jr-course-accent);
  line-height: 1.3;
}

body.mp-v2 .jr-course-block .price-table-block h3 {
  color: var(--jr-course-accent);
}

body.mp-v2 .jr-course-more {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
  padding: 9px 22px;
  color: var(--jr-blue);
  background: #fff;
  border: 1.5px solid var(--jr-blue);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

body.mp-v2 .jr-course-more:hover,
body.mp-v2 .jr-course-more:focus-visible {
  color: #fff;
  background: var(--jr-blue);
  transform: translateY(-1px);
}

/* 2026-09-27: 育脳コースの「育脳を詳しく見る」ボタンを単独行・中央寄せへ(ユーザー指定) */
body.mp-v2 .jr-course-more {
  margin: 1rem auto;
  display: block;
  max-width: max-content;
}

body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table thead th {
  background: var(--jr-blue);
}

@media (min-width: 641px) {
  body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table td:nth-child(3) {
    color: var(--jr-blue);
  }
}

@media (max-width: 640px) {
  body.mp-v2 .jr-course-block {
    padding: 16px;
  }

  body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table th[scope="row"] {
    color: var(--jr-blue);
    background: #edf5ff;
    border-bottom-color: #d7e8fb;
  }

  body.mp-v2 .price-table-scroll[aria-label="育脳個別学習コースの料金表"] .price-table td:nth-child(3) {
    color: var(--jr-blue);
  }
}

/* 中学生コース デザイン移植: オプション・その他費用 */
body.mp-v2 .jr-course-block + .jr-fees-grid {
  margin-top: 40px;
}

body.mp-v2 .jr-fees-grid {
  display: grid;
  gap: 40px;
  grid-template-columns: minmax(0, 1fr);
}

body.mp-v2 .jr-fees-grid > .price-table-block {
  min-width: 0;
}

body.mp-v2 .jr-fees-grid > .price-table-block + .price-table-block {
  margin-top: 0;
}

body.mp-v2 .jr-fees-grid > .price-table-block > h3 {
  padding-left: 12px;
  color: var(--jr-pink);
  border-left: 4px solid var(--jr-pink);
}

body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table thead th,
body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table thead th {
  background: var(--jr-pink);
}

@media (min-width: 981px) {
  body.mp-v2 .jr-fees-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table tbody tr,
  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table tbody tr {
    border-left: 4px solid var(--jr-pink);
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table th[scope="row"],
  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table th[scope="row"] {
    color: var(--jr-pink);
    background: #fdf0f4;
    border-bottom-color: #f5d8e1;
  }
}

/* 中学生コース デザイン移植: タイポグラフィ・概要カード整列 */
body.mp-v2 .message-copy h2,
body.mp-v2 .recommend .section-title h2,
body.mp-v2 .courses .course-intro h2,
body.mp-v2 .reasons .reasons-title h2,
body.mp-v2 .price-section .extra-head h2 {
  color: #222222;
  font-size: clamp(28px, 3vw, 32px);
  font-weight: 600;
}

body.mp-v2 .jr-overview-heading h3,
body.mp-v2 .reasons .reason-card h3,
body.mp-v2 .jr-course-title,
body.mp-v2 .jr-fees-grid > .price-table-block > h3 {
  font-weight: 600;
}

body.mp-v2 .jr-course-title {
  font-size: 24px;
}

/* 2026-09-27: font-weight:400のみだったこのブロックにcolor:#333を統合(ユーザー指定一覧と同一セレクタ)。
   旧: 別ブロックでcolor:#333/#555を重複指定しており、:not(.section-kicker)が無かったため
   .message-copy p等でsection-kickerの緑色(.section-kicker{color:var(--green)})を意図せず
   上書きしていた。この統合によりsection-kickerは正しく緑色を保持する。 */
body.mp-v2 .hero .lead,
body.mp-v2 .message-copy p:not(.section-kicker),
body.mp-v2 .recommend-grid article,
body.mp-v2 .courses .course-intro p:not(.section-kicker),
body.mp-v2 .jr-overview-details dd,
body.mp-v2 .reasons .reason-card p,
body.mp-v2 .price-table-intro,
body.mp-v2 .price-table-note,
body.mp-v2 .faq-item p {
  font-weight: 400;
  color: #333;
}

body.mp-v2 .courses {
  row-gap: 40px;
}

body.mp-v2 .courses .course-grid {
  position: relative;
  z-index: 1;
  padding-top: 12px;
}

body.mp-v2 .jr-overview-card {
  --jr-overview-content-inset: 28px;
  --jr-overview-label-width: 50px;
}

body.mp-v2 .jr-overview-heading {
  padding-right: var(--jr-overview-content-inset);
  padding-left: var(--jr-overview-content-inset);
}

body.mp-v2 .jr-overview-details {
  grid-template-columns: var(--jr-overview-label-width) minmax(0, 1fr);
  align-items: start;
  padding-right: var(--jr-overview-content-inset);
  padding-left: var(--jr-overview-content-inset);
}

body.mp-v2 .jr-overview-details dt {
  width: 40px;
  height: 40px;
  font-weight: 600;
}

body.mp-v2 .jr-overview-links {
  justify-content: center;
}

body.mp-v2 .jr-course-block .price-table-block h3 {
  font-size: 16px;
  font-weight: 600;
}

@media (max-width: 640px) {
  body.mp-v2 .courses {
    row-gap: 32px;
  }

  body.mp-v2 .courses .course-grid {
    padding-top: 8px;
  }

  body.mp-v2 .jr-overview-card {
    --jr-overview-content-inset: 20px;
  }
}

/* 中学生コース デザイン移植: CONCEPT仮素材 */
body.mp-v2 .message .photo-portrait::before {
  position: absolute;
  inset: 0;
  z-index: 1;
  background-image: url("img/placeholder-jr-concept.jpg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  content: "";
}

/* 中学生コース デザイン移植: 費用表の金額強調 */
body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table td,
body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table td {
  color: #333;
}

body.mp-v2 .jr-fee-amount {
  color: var(--jr-pink);
  font-weight: 700;
}

/* 中学生コース デザイン移植: 費用表のカード整列・ゼブラ */
body.mp-v2 .price-table tbody tr:nth-child(even) {
  background: #fbfbfb;
}

@media (max-width: 640px) {
  body.mp-v2 .message {
    margin-bottom: -36px;
  }

  body.mp-v2 .message .photo-portrait::before {
    margin-top: 5rem;
  }

  /* 2026-09-27: 小学生/中学生/高校生コースの3ページのみmargin-topを2remへ調整(ユーザー指定)。
     ikunou/atamaplus/reason/voice-successは対象外のため上の共通5remを維持。 */
  body.page-pr .message .photo-portrait::before,
  body.page-jr .message .photo-portrait::before,
  body.page-hs .message .photo-portrait::before {
    margin-top: 2rem;
  }

  body.mp-v2 .price-table tbody tr:nth-child(even) {
    background: #fff;
  }

  body.mp-v2 .price-table tbody tr {
    border-top: 1px solid #eee;
    border-right: 1px solid #eee;
    border-bottom: 1px solid #eee;
  }

  body.mp-v2 .price-table tbody tr:last-child th,
  body.mp-v2 .price-table tbody tr:last-child td {
    border-bottom: 1px solid #eee;
  }

  body.mp-v2 .price-table td {
    background: #fff;
  }

  body.mp-v2 .price-table-scroll[aria-label] .price-table th[scope="row"] {
    border-bottom: 1px solid #eee;
  }

  body.mp-v2 .jr-fees-grid,
  body.mp-v2 .jr-fees-grid > .price-table-block,
  body.mp-v2 .jr-fees-grid .price-table {
    width: 100%;
    min-width: 0;
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table tbody tr,
  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table tbody tr {
    width: 100%;
    min-width: 0;
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table th[scope="row"] {
    overflow-wrap: anywhere;
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table td {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    align-items: baseline;
    color: #333;
    font-size: 14px;
    font-weight: 400;
    text-align: right;
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table td::before {
    display: block;
    flex: 0 0 auto;
    margin-bottom: 0;
    color: var(--jr-pink);
  }

  body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .jr-fee-val {
    flex: 1 1 auto;
    min-width: 0;
    overflow-wrap: normal;
    word-break: keep-all;
    text-align: right;
  }

  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table tbody tr {
    display: block;
    grid-template-columns: none;
  }

  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table th[scope="row"],
  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table td {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table th[scope="row"] {
    padding: 14px 16px;
    font-size: inherit;
  }

  body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table td {
    padding: 12px 16px;
    text-align: left;
  }

  body.mp-v2 .pc-only-br {
    display: none;
  }
}

/* 中学生コース デザイン移植: TOP準拠CTA */
body.mp-v2 .cta h2 {
  font-weight: 600;
}

body.mp-v2 .cta-actions .phone,
body.mp-v2 .cta-actions .form {
  font-weight: 600;
}

body.mp-v2 .cta-actions .phone small,
body.mp-v2 .cta-actions .form small {
  font-weight: 600 !important;
}

body.mp-v2 .cta-actions .phone {
  border: 1px solid rgba(7, 24, 51, 0.08);
}

body.mp-v2 .phone span {
  margin-right: 0.5rem;
}

body.mp-v2 #course01,
body.mp-v2 #course02,
body.mp-v2 #price,
body.mp-v2 #sokudoku,
body.mp-v2 #shinkokugo,
body.mp-v2 #sokudoku-eigo {
  scroll-margin-top: 150px;
}

@media (max-width: 640px) {
  body.mp-v2 .hero h1 {
    max-width: none;
    font-size: 34px !important;
  }

  body.mp-v2 .hero h1 > span {
    display: block;
  }

  body.mp-v2 .message .portrait-wrap {
    max-width: 100%;
  }

  body.mp-v2 .message-copy > * {
    max-width: calc(100% - 24px);
  }

  /* 2026-09-27: 共通CTA B案(TOPと同一デザイン思想)。旧: 写真172px固定+ズーム+
     ボタンだけ白帯に分離、というmp-v2独自レイアウトを撤去し、TOPと同じ
     「1枚カードに背景・見出し・サブテキスト・ボタンを重ねる」構成へ統一。 */
  body.mp-v2 .cta {
    overflow: hidden;
    border-radius: 20px;
    margin: 1rem;
  }
}

@media (max-width: 360px) {
  body.mp-v2 .hero {
    grid-template-columns: minmax(118px, 0.85fr) minmax(0, 1.15fr);
  }
}

/* 中学生コース デザイン移植: TOP構成フッター */
body.mp-v2 .footer {
  grid-template-columns: minmax(220px, 0.9fr) minmax(520px, 2fr) 42px;
  align-items: start;
}

body.mp-v2 .footer-info {
  display: grid;
  gap: 14px;
  align-content: start;
}

body.mp-v2 .footer-info .brand {
  margin-bottom: 2px;
}

body.mp-v2 .footer-info address {
  margin: 0;
}

body.mp-v2 .footer-info .footer-social {
  display: grid;
  gap: 6px;
  margin-top: 2px;
}

body.mp-v2 .footer-info .footer-social h3 {
  margin: 0 0 2px;
  color: var(--green);
  font-size: 12px;
  line-height: 1.4;
}

body.mp-v2 .footer-info .footer-social a {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin: 0;
  color: #5d685f;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}

body.mp-v2 .footer-social a::before {
  content: "↗";
  margin-right: 0.35em;
  color: var(--green);
}

body.mp-v2 .footer-links a,
body.mp-v2 .footer address {
  color: #5d685f;
}

body.mp-v2 .footer-links a {
  font-weight: 500;
}

@media (max-width: 980px) {
  body.mp-v2 .footer {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  body.mp-v2 .footer-info {
    gap: 12px;
  }

  body.mp-v2 .footer-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body.mp-v2 .footer-links {
    grid-template-columns: 1fr;
  }
}

/* 中学生コース デザイン移植: COURSE透かし・おすすめ本文調整 */
body.mp-v2 .courses::before {
  top: 0;
  line-height: 1.1;
}

body.mp-v2 .message-copy > p:not(.section-kicker):not(.signature) {
  margin-top: 0 !important;
}

body.mp-v2 .recommend-grid article {
  font-size: 14px !important;
  font-weight: 700;
  overflow-wrap: anywhere !important;
  word-break: normal !important;
}

/* 2026-09-27: TOP(#recommend)基準に合わせ、下層のSPカードが不自然に大きくなっていた点を調整。
   TOP側SP実測: font-size 12px / padding 12px 16px / gap 20px。
   下層は font-size 14px(!important) / padding 12px 8px / gap 12px で、
   カード高さが145px→193pxと約1.3倍になっていたため、この3値のみTOPへ揃える。
   font-weight(700)は下層側のブランド上の太字表現として維持し、無理に同一化しない。 */
@media (max-width: 640px) {
  body.mp-v2 .recommend-grid article {
    padding: 12px 16px !important;
    font-size: 12px !important;
  }

  body.mp-v2 .recommend-grid {
    gap: 20px !important;
  }
}

body.mp-v2 .recommend-grid span {
  width: 78px !important;
  height: 78px !important;
}

/* 中学生コース デザイン移植: 概要・料金見出しアイコン */
body.mp-v2 .jr-overview-number svg {
  display: block;
  width: 26px;
  height: 26px;
}

body.mp-v2 .jr-course-title {
  display: flex;
  gap: 0.4em;
  align-items: center;
  color: var(--jr-course-accent);
}

body.mp-v2 .jr-course-title svg {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
}

/* 中学生コース デザイン移植: 見出しアイコン微調整 */
body.mp-v2 .jr-course-icon {
  display: grid;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  place-items: center;
  border: none;
  border-radius: 50%;
}

body.mp-v2 .jr-course-block--green .jr-course-icon {
  background: #ecf6e9;
}

body.mp-v2 .jr-course-block--blue .jr-course-icon {
  background: #e9f2fc;
}

body.mp-v2 .jr-overview-card--green .jr-overview-number svg,
body.mp-v2 .jr-course-block--green .jr-course-icon svg {
  transform: rotate(-20deg);
  transform-origin: center;
}

body.mp-v2 .jr-overview-card--blue .jr-overview-number svg,
body.mp-v2 .jr-course-block--blue .jr-course-icon svg {
  width: auto;
  height: 36px;
  stroke-width: 1.35px;
}

/* FAQ: 開いたとき回答をふわっと表示（全ページ共通・動き許容時のみ） */
@media (prefers-reduced-motion: no-preference) {
  .faq-item[open] > *:not(summary) {
    animation: faqReveal 0.3s cubic-bezier(0.22, 0.61, 0.36, 1) both;
  }
}

@keyframes faqReveal {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 中学生コース: オプション/その他費用のセルを14pxに統一(SP行ヘッダ等の13pxを上書き) */
body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table th,
body.mp-v2 .price-table-scroll[aria-label="オプション料金表"] .price-table td,
body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table th,
body.mp-v2 .price-table-scroll[aria-label="その他費用の料金表"] .price-table td {
  font-size: 14px;
}

/* 小学生: 教科カードを色分け＋アイコン(mp-v2) */
body.mp-v2 .courses .course-card {
  background: #fff;
}

body.mp-v2 .course-card--green {
  border-top: 4px solid var(--green);
}

body.mp-v2 .course-card--green h3,
body.mp-v2 .course-card--green small {
  color: var(--green);
}

body.mp-v2 .course-card--green .jr-course-icon {
  color: var(--green);
}

body.mp-v2 .course-card--blue {
  border-top: 4px solid var(--jr-blue);
}

body.mp-v2 .course-card--blue h3,
body.mp-v2 .course-card--blue small {
  color: var(--jr-blue);
}

body.mp-v2 .course-card--blue .jr-course-icon {
  color: var(--jr-blue);
}

body.mp-v2 .course-card--pink {
  border-top: 4px solid var(--jr-pink);
}

body.mp-v2 .course-card--pink h3,
body.mp-v2 .course-card--pink small {
  color: var(--jr-pink);
}

body.mp-v2 .course-card--pink .jr-course-icon {
  color: var(--jr-pink);
}

body.mp-v2 .course-card--yellow {
  border-top: 4px solid var(--yellow);
}

body.mp-v2 .course-card--yellow h3,
body.mp-v2 .course-card--yellow small {
  color: var(--yellow);
}

body.mp-v2 .course-card--yellow .jr-course-icon {
  color: var(--yellow);
}

body.mp-v2 .course-card .jr-course-icon {
  flex-basis: 58px;
  width: 58px;
  height: 58px;
  margin-top: 22px;
  margin-left: 28px;
  margin-bottom: 4px;
  border: 2px solid currentColor;
  background: #fff;
}

body.mp-v2 .course-card .jr-course-icon svg {
  width: 36px;
  height: 36px;
  stroke-width: 1.35px;
}

/* 教科カード: 文字量が多いカードで本文が下端に接触しないよう下余白を確保 */
body.mp-v2 .course-card--green,
body.mp-v2 .course-card--blue,
body.mp-v2 .course-card--pink,
body.mp-v2 .course-card--yellow {
  padding-bottom: 28px;
}

/* 小学生コース: 教科見出し・カード操作感・料金表示の仕上げ調整 */
body.mp-v2 .course-card .course-heading {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 28px 8px;
}

body.mp-v2 .course-card .course-heading .jr-course-icon {
  margin: 0;
}

body.mp-v2 .course-card .course-heading h3 {
  margin: 0 0 2px;
}

body.mp-v2 .course-card .course-heading small {
  margin: 0;
}

body.mp-v2 .course-card,
body.mp-v2 .reason-card {
  cursor: default;
}

body.mp-v2 .course-card:hover {
  transform: none;
  box-shadow: var(--shadow);
}

body.mp-v2 .reason-card:hover {
  transform: none;
  box-shadow: 0 14px 34px rgba(21, 38, 62, 0.08);
}

body.mp-v2 .price-primary .jr-course-block .jr-course-icon svg {
  transform: none;
  width: 26px;
  height: 26px;
  stroke-width: 1.4;
}

body.mp-v2 .price-primary > .price-table-block > h3 {
  color: var(--jr-pink);
}

body.mp-v2 .jr-course-block .price-table tbody th[scope="row"] {
  color: #333;
}

body.mp-v2 .jr-course-block .price-table tbody td:last-child {
  color: var(--jr-course-accent);
  font-weight: 700;
}

/* その他費用(小学生): セルは黒、額面(jr-fee-amount)のみピンク太字 */
body.mp-v2 .price-primary > .price-table-block .price-table tbody td:last-child {
  color: #333;
}

/* 小学生コース: 教科カードの文字組みと学年別料金表の配色を基準ページに統一 */
body.mp-v2 .course-card small {
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif !important;
}

body.mp-v2 .course-card h3 {
  font-weight: 600;
}

body.mp-v2 .course-card p {
  font-weight: 400;
  color: #333;
}

body.mp-v2 .price-primary .jr-course-block .price-table thead th {
  background: var(--jr-course-accent);
}

/* 教科カードのアイコン丸はSPで48px(中学生の概要アイコンと同じ縮小) */
@media (max-width: 640px) {
  body.mp-v2 .course-card .jr-course-icon {
    flex-basis: 48px;
    width: 48px;
    height: 48px;
  }
}

/* コース一覧: カード内ボタンの余白(左右をテキストと揃え、下に余白)+矢印との間隔 */
body.mp-v2 .course-card .button.ghost {
  display: flex;
  width: fit-content;
  max-width: calc(100% - 56px);
  margin: 4px auto 28px;
  gap: 8px;
}

/* コース一覧: ボタン付きカードは card 下paddingを消す(ボタンmarginで足りるため) */
body.mp-v2 .course-card:has(.button.ghost) {
  padding-bottom: 0;
}

/* カード直下の枠線ボタン: 説明文の行数が違っても同じ行のカードでボタンが同じ高さ(カード下端)に揃うようにする */
body.mp-v2 .course-card:has(> .button.ghost) {
  display: flex;
  flex-direction: column;
}

body.mp-v2 .course-card > .button.ghost {
  margin-top: auto;
}

/* コース一覧: CTA崩れ調整(見出しサイズ・説明pの縮小) */
@media (min-width: 641px) {
  body.mp-v2 .cta h2 {
    font-size: 36px;
  }
}
/* 2026-09-27: 新CTAデザインでは.cta-leadを使うため、旧.cta-copy p(14px)の指定は
   .cta-lead以外(万一の他ページ固有pなど)にのみ影響するよう除外。 */
body.mp-v2 .cta-copy p:not(.cta-lead) {
  font-size: 14px;
  margin: 0.25rem 0;
  line-height: 1.4;
}

/* コース一覧: chips を各カードのカラーに(グレー既定を上書き) */
body.mp-v2 .course-card--green .chips span {
  color: var(--green);
  background: rgba(91, 149, 90, 0.1);
  border: 1px solid rgba(91, 149, 90, 0.34);
}
body.mp-v2 .course-card--blue .chips span {
  color: var(--jr-blue);
  background: rgba(47, 126, 212, 0.1);
  border: 1px solid rgba(47, 126, 212, 0.34);
}
body.mp-v2 .course-card--pink .chips span {
  color: var(--jr-pink);
  background: rgba(238, 109, 150, 0.1);
  border: 1px solid rgba(238, 109, 150, 0.34);
}
body.mp-v2 .course-card--yellow .chips span {
  color: #a97b00;
  background: rgba(246, 184, 0, 0.14);
  border: 1px solid rgba(246, 184, 0, 0.42);
}

/* コース一覧: ghostボタンを各カードのカラーに */
body.mp-v2 .course-card--green .button.ghost {
  color: var(--green);
  border-color: var(--green);
}
body.mp-v2 .course-card--blue .button.ghost {
  color: var(--jr-blue);
  border-color: var(--jr-blue);
}
body.mp-v2 .course-card--pink .button.ghost {
  color: var(--jr-pink);
  border-color: var(--jr-pink);
}
body.mp-v2 .course-card--yellow .button.ghost {
  color: #a97b00;
  border-color: var(--yellow);
}

/* 2026-09-29: .button.ghost(枠線ボタン)のhover/focus-visibleを.jr-course-more:hoverと同じ
   考え方(background→自身のborder色、color→#fff、transform:translateY(-1px))に統一。
   カード色指定が無い既定パターンのtransition/hoverは無スコープ.button.ghost側に統一したため
   (TOP・下層共通で重複していたのを整理)、ここではカード色指定ぶんの上書きのみ記述する。
   TOP・CTA・primaryボタンには波及させない(このブロックはcourse-card--色クラスのみが対象)。 */
body.mp-v2 .course-card--green .button.ghost:hover,
body.mp-v2 .course-card--green .button.ghost:focus-visible {
  color: #fff;
  background: var(--green);
  transform: translateY(-1px);
}
body.mp-v2 .course-card--blue .button.ghost:hover,
body.mp-v2 .course-card--blue .button.ghost:focus-visible {
  color: #fff;
  background: var(--jr-blue);
  transform: translateY(-1px);
}
body.mp-v2 .course-card--pink .button.ghost:hover,
body.mp-v2 .course-card--pink .button.ghost:focus-visible {
  color: #fff;
  background: var(--jr-pink);
  transform: translateY(-1px);
}
body.mp-v2 .course-card--yellow .button.ghost:hover,
body.mp-v2 .course-card--yellow .button.ghost:focus-visible {
  color: #fff;
  background: var(--yellow);
  transform: translateY(-1px);
}


/* 2026-09-27: 旧デザイン(写真列に見出しが密着しないための余白)は新CTA(カード全体余白で
   解決済み)により不要になったため削除。 */

/* SP: カードのタグは複数行に折返し可、タグ内テキストは折返さない(一文字だけ改行を防ぐ) */
@media (max-width: 640px) {
  body.mp-v2 .course-card .chips {
    flex-wrap: wrap;
  }
  body.mp-v2 .course-card .chips span {
    white-space: nowrap;
  }
}

/* ===== PR-IMG2: 中学ページ 実画像差し替え(page-jr スコープ・既存グローバル不変) ===== */
/* FV(ヒーロー写真ブロブ)。元: .photo-course-two=img/tyuu.png を page-jr のみ上書き */
body.page-jr .hero-visual .jr-hero-photo {
  background-image: url("img/mp-jr-fv.jpg");
}
/* CONCEPT(message の縦写真)。元: body.mp-v2 …::before=img/placeholder-jr-concept.jpg を page-jr のみ上書き */
body.page-jr .message .photo-portrait::before {
  background-image: url("img/mp-jr-concept.jpg");
}
/* 概要カード 個別カスタマイズ(緑・course-image photo-course-two) */
body.page-jr .jr-overview-card--green .course-image {
  background-image: url("img/mp-jr-kobetsu.jpg");
}
/* 概要カード 育脳個別学習(青・course-image photo-course-one) */
body.page-jr .jr-overview-card--blue .course-image {
  background-image: url("img/mp-jr-ikunou.jpg");
}

/* ===== PR-IMG3: 小学生ページ 実画像差し替え(page-pr スコープ・既存グローバル不変) ===== */
/* FV(ヒーロー写真ブロブ)。元 .photo-course-one=img/syou.png を page-pr のみ上書き */
body.page-pr .hero-visual .jr-hero-photo {
  background-image: url("img/mp-pr-fv.jpg");
}
/* CONCEPT(message 縦写真)。元 body.mp-v2 …::before=img/placeholder-jr-concept.jpg を page-pr のみ上書き */
/* 2026-09-27: border-radius:15pxはPC/SP共通指定(ユーザー明示)。page-pr限定のためリーク無し。 */
body.page-pr .message .photo-portrait::before {
  background-image: url("img/mp-pr-concept.jpg");
  border-radius: 15px;
}
/* 教科カード 算数(緑) */
body.page-pr .course-card--green .course-image {
  background-image: url("img/mp-pr-math.jpg");
}
/* 教科カード 読解(青) */
body.page-pr .course-card--blue .course-image {
  background-image: url("img/mp-pr-reading.jpg");
}
/* 教科カード 速読(桃) */
body.page-pr .course-card--pink .course-image {
  background-image: url("img/mp-pr-sokudoku.jpg");
}
/* 教科カード 英語(黄) */
body.page-pr .course-card--yellow .course-image {
  background-image: url("img/mp-pr-english.jpg");
}

/* ===== PR-IMG4: 高校ページ 実画像差し替え(page-hs スコープ・既存グローバル不変) ===== */
/* FV(ヒーロー写真ブロブ)。元 .photo-course-three=img/kou.png を page-hs のみ上書き */
body.page-hs .hero-visual .jr-hero-photo {
  background-image: url("img/mp-hs-fv.jpg");
}
/* CONCEPT(message 縦写真)。元 body.mp-v2 …::before=img/placeholder-jr-concept.jpg を page-hs のみ上書き */
body.page-hs .message .photo-portrait::before {
  background-image: url("img/mp-hs-concept.jpg");
}
/* サポートカード 大学受験対策(緑) */
body.page-hs .course-card--green .course-image {
  background-image: url("img/mp-hs-exam.jpg");
}
/* サポートカード 学校授業の補完・定期テスト対策(青) */
body.page-hs .course-card--blue .course-image {
  background-image: url("img/mp-hs-school.jpg");
}
/* サポートカード 推薦・総合型選抜(桃) */
body.page-hs .course-card--pink .course-image {
  background-image: url("img/mp-hs-suisen.jpg");
}
/* サポートカード ICT教材(黄) */
body.page-hs .course-card--yellow .course-image {
  background-image: url("img/mp-hs-ict.jpg");
}

/* ===== PR-IMG-POS1: 小学生・高校 カード写真の顔切れ調整(中央→上寄り30%で顔を見せる) ===== */
body.page-pr .course-card .course-image,
body.page-hs .course-card .course-image {
  background-position: center 30%;
}

/* ===== PR-IMG5: 育脳ページ 実画像差し替え(page-ik スコープ・中学画像を流用) ===== */
/* FV(ヒーロー写真ブロブ)。元 .photo-course-two=img/tyuu.png を page-ik のみ上書き。育脳写真を流用 */
body.page-ik .hero-visual .jr-hero-photo {
  background-image: url("img/mp-jr-ikunou.jpg");
}
/* CONCEPT(message 縦写真)。元 body.mp-v2 …::before=placeholder を page-ik のみ上書き。中学CONCEPTを流用 */
body.page-ik .message .photo-portrait::before {
  background-image: url("img/mp-jr-concept.jpg");
  margin-bottom: 1rem;
}

/* ===== atama+ページ: ABOUT縦写真(page-atama スコープ)。元 body.mp-v2 …::before=placeholder を page-atama のみ上書き ===== */
body.page-atama .message .photo-portrait::before {
  background-image: url("img/mp-atama-about.webp");
}
/* 学年別カード(小中高FV流用)の顔切れ調整。他ページの顔切れ調整と同じcenter 30%を採用 */
body.page-atama #atama-grade-usage .course-image {
  background-position: center 30%;
}

/* 「自分専用カリキュラム」カード画像の見切れ調整(#atama-featuresの緑カードのみ) */
body.page-atama #atama-features .course-card--green .course-image {
  background-position: center 30%;
}
/* 「いつでも、どこでも学べる」本文がfaq-list上線に近すぎる問題。
   .price-section .faq-list .faq-item { padding-top: 2rem; }(8925行目)と同じ値を、
   summaryなしfaq-itemの汎用パターンとして流用 */
body.page-atama .lower-section:not(.faq-section) .faq-list .faq-item {
  padding-top: 2rem;
}

/* ===== PR-IMG6: コース一覧 FV＋ナビカードアイキャッチ(page-cs スコープ・描ける4枚のみ) ===== */
/* FV(ヒーロー写真ブロブ)。元 .photo-course-one=img/syou.png を page-cs のみ上書き */
body.page-cs .hero-visual .jr-hero-photo {
  background-image: url("img/mp-course-fv.jpg");
}
/* ナビカード アイキャッチ(color重複回避のため既存class+セクションIDで狙い撃ち) */
body.page-cs #grade-courses .course-card--green .course-image {
  background-image: url("img/mp-pr-fv.jpg");
}
body.page-cs #grade-courses .course-card--blue .course-image {
  background-image: url("img/mp-jr-fv.jpg");
}
body.page-cs #grade-courses .course-card--pink .course-image {
  background-image: url("img/mp-hs-fv.jpg");
}
body.page-cs #program-tools .course-index-fv-ikunou {
  background-image: url("img/mp-jr-ikunou.jpg");
}
/* 顔切れ調整(実写4枚のみ・POS1と同じ上寄せ center 30%)。画像無し4枚には掛けない */
body.page-cs #grade-courses .course-card--green .course-image,
body.page-cs #grade-courses .course-card--blue .course-image,
body.page-cs #grade-courses .course-card--pink .course-image,
body.page-cs #program-tools .course-index-fv-ikunou {
  background-position: center 30%;
}

/* ===== PR-IMG7: about×3 の FV 差し替え(page-about-* スコープ・mp-v2化はしない) ===== */
/* 各 .hero-visual .photo-course-one(元 img/syou.png)を page-about-* のみ上書き */
body.page-about-coaching .hero-visual .photo-course-one {
  background-image: url("img/mp-about-coaching-fv.jpg");
}
body.page-about-flow .hero-visual .photo-course-one {
  background-image: url("img/mp-about-flow-fv.jpg");
}
body.page-about-reason .hero-visual .photo-course-one {
  background-image: url("img/mp-about-reason-fv.jpg");
}

/* ===== PR-HS-DEC1/DEC2(2026-08-26 整理): 高校「授業システム」の番号リストは、
   後方(body.page-hs .system-section .system-steps、page-trと共有)のルールが
   詳細度で勝つため、レイアウト・番号バッジ・連結線はそちらが実際の見た目を決めている。
   ここでは、そちらのルールに存在しない「li本文の行間・文字色」「strongの強調色」のみを残す。 ===== */
body.page-hs .system-steps li {
  line-height: 1.7;
  color: #333;
}
body.page-hs .system-steps strong {
  font-weight: 700;
  color: var(--pink);
}

/* ===== PR-BBY2: FVタイトル白光彩・recommendセンター・見出し行間・仮余白 ===== */

/* ① FVタイトルに白の強い光彩(色被りで視認性が悪い問題の改善)。全mp-v2ページ共通 */
body.mp-v2 .hero-copy h1 {
  text-shadow:
    0 0 3px #ffffff,
    0 0 8px rgba(255, 255, 255, 1),
    0 0 18px rgba(255, 255, 255, 0.95),
    0 0 34px rgba(255, 255, 255, 0.8);
}

/* ② 「〜おすすめです」recommend が4枚のbbyで右が空く → センター寄せ(4枚を中央に) */
/*    ※先のPR-BBY1b(4列fill)を置き換え。Desktopのみ。SP(≤980)は既存2列のまま */
@media (min-width: 981px) {
  body.page-bby .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* ③ 見出しの行間を全体で詰める(mp-v2のh2/h3。FVのh1は除外=①の改行を保つ) */
body.mp-v2 h2,
body.mp-v2 h3 {
  line-height: 1.5;
}

/* ④ 特徴カード見出し(ユーザー指定) */
body.mp-v2 .reason-card h3 {
  padding-bottom: 18px;
  line-height: 1.5;
}

/* ⑤ 料金セクションの仮フォールバックFAQが上要素とくっつく → 余白(ユーザー指定) */
body.mp-v2 .price-section .faq-list .faq-item {
  padding-top: 2rem;
}

/* 2026-09-26: bbyのSP heroは about/index 型の共通レイアウトへ統一。
   旧: display:blockで共通グリッドを離脱し、写真を絶対配置で全幅表示する専用レイアウトだった
   (ユーザー指定・過去実装)が、今回「ページごとにhero本体を別実装にしない」方針のため撤去し、
   他18ページと同じ body.mp-v2 の共通hero(画像は右上ブロブ型)に合わせる。
   h1のbr無効化のみ、bby固有の文言調整として維持。 */
@media (max-width: 640px) {
  body.page-bby .hero-copy h1 br {
    display: none;
  }
}

/* ===== PR-BBY4: BBY「3ステップの学習方法」を ol タイムライン化(高校 授業システムと同型・page-bby) ===== */
body.page-bby .system-steps {
  list-style: none;
  counter-reset: mp-bby-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}
body.page-bby .system-steps li {
  counter-increment: mp-bby-step;
  position: relative;
  padding: 2px 0 30px 74px;
}
body.page-bby .system-steps li:last-child {
  padding-bottom: 0;
}
/* 番号バッジ(丸・青=BBYの識別色) */
body.page-bby .system-steps li::before {
  content: counter(mp-bby-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(79, 132, 205, 0.28);
}
/* 連結の縦ライン(最後以外) */
body.page-bby .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--blue-soft);
}
body.page-bby .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}
body.page-bby .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--blue);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}
body.page-bby .system-steps li p {
  margin: 0;
  color: #333;
  line-height: 1.7;
}

/* ===== PR-TR2-a: 見出し(h2)下の余白を全体で追加(直下pとの詰まり解消・ユーザー指定 全mp-v2) ===== */
body.mp-v2 h2 {
  margin-bottom: 1rem;
}

/* ===== PR-TR3: 「他コースとの組み合わせ」3カードに各コースのFV画像をアイキャッチ表示 =====
   #terrace-skills にも同じ色クラス(green/blue/pink)のカードがあるため、
   #terrace-combination の中だけにスコープして誤爆を防ぐ */
body.page-tr #terrace-combination .course-card--green .course-image {
  background-image: url("img/mp-pr-fv.jpg");
}
body.page-tr #terrace-combination .course-card--blue .course-image {
  background-image: url("img/mp-jr-fv.jpg");
}
body.page-tr #terrace-combination .course-card--pink .course-image {
  background-image: url("img/mp-jr-ikunou.jpg");
}

/* ===== PR-TR4: 「他コースとの組み合わせ」カード写真の顔切れ調整(中央→上寄り30%) ===== */
body.page-tr #terrace-combination .course-image {
  background-position: center 30%;
}

/* ===== PR-ABT1b: about/flow recommend(4項目)をDesktopでセンター寄せ(bbyと同方式) ===== */
@media (min-width: 981px) {
  body.page-about-flow .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* ===== PR-ABT2: about/coaching_counseling recommend(4項目)をDesktopでセンター寄せ ===== */
@media (min-width: 981px) {
  body.page-about-coaching .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* ===== PR-ABT3: about/reason recommend(4項目)をDesktopでセンター寄せ ===== */
@media (min-width: 981px) {
  body.page-about-reason .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* 2026-09-27: about/reason SP限定 recommend見出しサイズ調整。
   .recommend .section-title h2 は14ページ共通セレクタのため、他ページへ波及しないよう
   body.page-about-reasonでスコープ。 */
@media (max-width: 640px) {
  body.page-about-reason .recommend .section-title h2 {
    font-size: 23.25px;
  }
}

/* ===== PR-ABT4: about/support recommend(4項目)をDesktopでセンター寄せ ===== */
@media (min-width: 981px) {
  body.page-about-support .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* ===== PR-TOP2: TOPコース案内カード(#courses)に上帯カラーを追加(about/course系との視覚統一) ===== */
#courses .course-card.elementary {
  border-top: 4px solid var(--green);
}
#courses .course-card.junior {
  border-top: 4px solid var(--blue);
}
#courses .course-card.high {
  border-top: 4px solid var(--pink);
}

/* ===== PR-TOP3: TOP h2見出しの色・行間をabout/course系(mp-v2)に統一(ユーザー指示2026-08-01) =====
   about/course系のh2は一貫して color:#222 / line-height比率1.5 / font-weight:600。
   TOPは既存Fable調整(2026-07-04)でweightのみ600に揃っていたが、色(#1f3f36)と行間(1.62)がまだ別方向だった。
   既存ブロックは削除せず、末尾追記の後勝ちで上書きする(既存運用方針を踏襲)。 */
body:not(.lower-page) .message-copy h2,
body:not(.lower-page) .section-title h2,
body:not(.lower-page) .course-intro h2,
body:not(.lower-page) .voice h2 {
  color: #222;
  line-height: 1.5;
}

/* ===== PR-TOP4: TOP「3つの理由」カード数字・見出し数字のフォントをabout/course系(mp-v2)に統一(ユーザー指示2026-08-01) =====
   about側の.reason-card strongはPlayball/56px/weight400/line-height1。TOP側は複数の重複ルール(Fable調整含む)で
   最終的にQuicksand/weight500/サイズ不揃いになっていた。既存ルールは削除せず、末尾追記の後勝ちで上書きする。
   対象はreason-card strong(01/02/03)とreason-count b・::first-letter(見出し内「3」)のみ。
   stat-card(FV実績カード=保留中)は含めない。 */
body:not(.lower-page) .reason-card strong {
  font-family: "Playball", Georgia, "Times New Roman", serif !important;
  font-weight: 400 !important;
  font-size: 76px !important;
  line-height: 1 !important;
}

body:not(.lower-page) .reason-count b,
body:not(.lower-page) .reasons-title h2 .reason-count::first-letter {
  font-family: "Playball", Georgia, "Times New Roman", serif !important;
  font-weight: 400 !important;
  letter-spacing: normal !important;
}

/* ===== PR-TOP4b: 見出し内「3」(reason-count b)のフォントをPlayballに統一(特異度修正) =====
   既存ルール(8696-8701行)が body:not(.lower-page) .reasons-sticky-wrap .reasons-title h2 .reason-count b という
   高特異度セレクタでQuicksandを指定しており、PR-TOP4の指定(body:not(.lower-page) .reason-count b)では
   特異度不足で上書きできなかった。同じ特異度のセレクタを使い、末尾追記で確実に上回るようにする。 */
body:not(.lower-page) .reasons-sticky-wrap .reasons-title h2 .reason-count b,
body:not(.lower-page) .reasons-title h2 .reason-count::first-letter {
  font-family: "Playball", Georgia, "Times New Roman", serif !important;
  font-weight: 400 !important;
  letter-spacing: normal !important;
}

/* ===== PR-TOP6: TOP recommendセクションにドット・三角装飾を追加(about/course系jr-section-decorをTOP用に移植・パイロット) =====
   about側の値(色・サイズ・位置・opacity)をそのまま流用。既存のmp-v2用ブロック(10289-10407行)は変更しない。 */
body:not(.lower-page) .jr-section-decor {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

body:not(.lower-page) .jr-section-decor::before,
body:not(.lower-page) .jr-section-decor::after {
  position: absolute;
  content: "";
}

@keyframes decorDotSpin {
  0%, 95% {
    transform: rotate(0deg);
  }
  96.5% {
    transform: rotate(45deg);
  }
  98% {
    transform: rotate(-45deg);
  }
  100% {
    transform: rotate(0deg);
  }
}

@keyframes decorDotPulse {
  0%, 82% {
    transform: scale(1);
  }
  91% {
    transform: scale(1.1);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes decorTriSpin18 {
  0%, 85% {
    transform: rotate(18deg);
    filter: none;
  }
  90% {
    filter: brightness(1.35) drop-shadow(0 0 8px rgba(255, 255, 255, 0.7));
  }
  100% {
    transform: rotate(378deg);
    filter: none;
  }
}

@keyframes decorTriSpin16 {
  0%, 85% {
    transform: rotate(16deg);
    filter: none;
  }
  90% {
    filter: brightness(1.35) drop-shadow(0 0 8px rgba(255, 255, 255, 0.7));
  }
  100% {
    transform: rotate(376deg);
    filter: none;
  }
}

@keyframes decorTriSpinNeg18 {
  0%, 82% {
    transform: rotate(-18deg);
    filter: none;
  }
  88% {
    filter: brightness(1.35) drop-shadow(0 0 8px rgba(255, 255, 255, 0.7));
  }
  100% {
    transform: rotate(342deg);
    filter: none;
  }
}

@keyframes decorTriSpin14 {
  0%, 87% {
    transform: rotate(14deg);
    filter: none;
  }
  91% {
    filter: brightness(1.35) drop-shadow(0 0 8px rgba(255, 255, 255, 0.7));
  }
  100% {
    transform: rotate(374deg);
    filter: none;
  }
}

@keyframes decorTriSpinNeg16 {
  0%, 83% {
    transform: rotate(-16deg);
    filter: none;
  }
  89% {
    filter: brightness(1.35) drop-shadow(0 0 8px rgba(255, 255, 255, 0.7));
  }
  100% {
    transform: rotate(344deg);
    filter: none;
  }
}

body:not(.lower-page) .jr-section-decor--recommend::before {
  top: 18px;
  right: 28px;
  width: 78px;
  height: 78px;
  background: repeating-linear-gradient(45deg, rgba(47, 126, 212, 0.52) 0 5px, transparent 5px 11px);
  border-radius: 50%;
  opacity: 0.62;
  animation: decorDotPulse 11s ease-in-out 1.2s infinite;
}

body:not(.lower-page) .jr-section-decor--recommend::after {
  bottom: 20px;
  left: 18px;
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid #d46d9f;
  transform: rotate(16deg);
  opacity: 0.58;
  animation: decorTriSpin16 5.4s ease-in-out 1.6s infinite;
}

body:not(.lower-page) .jr-section-decor--hero::before {
  top: 22px;
  right: 24px;
  width: 92px;
  height: 92px;
  background-image: radial-gradient(circle, var(--yellow) 2.5px, transparent 3px);
  background-size: 15px 15px;
  opacity: 0.48;
  animation: decorDotSpin 6.5s ease-in-out 1.2s infinite;
}

body:not(.lower-page) .jr-section-decor--hero::after {
  bottom: 22px;
  left: 22px;
  width: 0;
  height: 0;
  background: none;
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid #d46d9f;
  border-radius: 0;
  transform: rotate(18deg);
  opacity: 0.56;
  animation: decorTriSpin18 5s ease-in-out 0.5s infinite;
}

body:not(.lower-page) .hero > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .recommend {
  position: relative;
}

body:not(.lower-page) .recommend > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

/* ===== PR-TOP6b: TOP reasons/courses/faq-sectionにドット・三角装飾を追加(PR-TOP6の続き) =====
   about側の値をそのまま流用。jr-section-decorの共通ベース(position/inset等)はPR-TOP6で追加済みのため再定義しない。 */
body:not(.lower-page) .jr-section-decor--reasons::before {
  top: 22px;
  left: 22px;
  border-top: 27px solid transparent;
  border-bottom: 27px solid transparent;
  border-left: 45px solid var(--yellow);
  transform: rotate(-18deg);
  opacity: 0.56;
  animation: decorTriSpinNeg18 4.5s ease-in-out 4s infinite;
}

body:not(.lower-page) .jr-section-decor--reasons::after {
  right: 26px;
  bottom: 22px;
  width: 88px;
  height: 88px;
  background-image: radial-gradient(circle, #2f7ed4 2.5px, transparent 3px);
  background-size: 14px 14px;
  opacity: 0.52;
  animation: decorDotSpin 7.5s ease-in-out 3.6s infinite;
}

body:not(.lower-page) .jr-section-decor--reasons-2::before {
  bottom: 20px;
  left: 20px;
  width: 64px;
  height: 64px;
  background-image: radial-gradient(circle, var(--green) 2.5px, transparent 3px);
  background-size: 14px 14px;
  opacity: 0.5;
  animation: decorDotSpin 7s ease-in-out 2.4s infinite;
}

body:not(.lower-page) .jr-section-decor--reasons-2::after {
  top: 16px;
  right: 16px;
  width: 56px;
  height: 56px;
  background: repeating-linear-gradient(45deg, rgba(47, 126, 212, 0.5) 0 4px, transparent 4px 10px);
  border: 0;
  border-radius: 50%;
  transform: none;
  opacity: 0.5;
  animation: decorDotPulse 13s ease-in-out 3.6s infinite;
}

body:not(.lower-page) .jr-section-decor--courses::before {
  top: 14px;
  right: 18px;
  width: 0;
  height: 0;
  background: none;
  border-top: 22px solid transparent;
  border-right: 38px solid var(--yellow);
  border-bottom: 22px solid transparent;
  transform: rotate(14deg);
  opacity: 0.55;
  animation: decorTriSpin14 6s ease-in-out 0s infinite;
}

body:not(.lower-page) .jr-section-decor--courses::after {
  bottom: 24px;
  left: 20px;
  width: 66px;
  height: 66px;
  background: repeating-linear-gradient(-45deg, rgba(238, 109, 150, 0.5) 0 4px, transparent 4px 10px);
  border-radius: 50%;
  opacity: 0.62;
  animation: decorDotPulse 12s ease-in-out 6.3s infinite;
}

body:not(.lower-page) .jr-section-decor--courses-2::before {
  top: 16px;
  left: 20px;
  width: 0;
  height: 0;
  border-top: 22px solid transparent;
  border-bottom: 22px solid transparent;
  border-left: 38px solid #d46d9f;
  transform: rotate(-16deg);
  opacity: 0.56;
  animation: decorTriSpinNeg16 4.8s ease-in-out 2.4s infinite;
}

body:not(.lower-page) .jr-section-decor--faq::before {
  top: 30px;
  left: 22px;
  width: 82px;
  height: 82px;
  background-image: radial-gradient(circle, #2f7ed4 2.5px, transparent 3px);
  background-size: 14px 14px;
  opacity: 0.5;
  animation: decorDotSpin 8s ease-in-out 4.8s infinite;
}

body:not(.lower-page) .jr-section-decor--faq::after {
  right: 24px;
  bottom: 24px;
  width: 70px;
  height: 70px;
  background: repeating-linear-gradient(-45deg, rgba(238, 109, 150, 0.5) 0 4px, transparent 4px 10px);
  border-radius: 50%;
  opacity: 0.6;
  animation: decorDotPulse 14s ease-in-out 8.7s infinite;
}

body:not(.lower-page) .jr-section-decor--voice::before {
  top: 28px;
  left: 20px;
  width: 72px;
  height: 72px;
  background: repeating-linear-gradient(45deg, rgba(91, 149, 90, 0.48) 0 4px, transparent 4px 10px);
  border-radius: 50%;
  opacity: 0.58;
  animation: decorDotPulse 11.5s ease-in-out 11.1s infinite;
}

body:not(.lower-page) .jr-section-decor--voice::after {
  right: 24px;
  bottom: 26px;
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid var(--yellow);
  transform: rotate(18deg);
  opacity: 0.56;
  animation: decorTriSpin18 5.6s ease-in-out 3.2s infinite;
}

@media (max-width: 980px) {
  body:not(.lower-page) .jr-section-decor--voice::before,
  body:not(.lower-page) .jr-section-decor--voice::after {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  body:not(.lower-page) .jr-section-decor--hero::before,
  body:not(.lower-page) .jr-section-decor--reasons::after,
  body:not(.lower-page) .jr-section-decor--reasons-2::before,
  body:not(.lower-page) .jr-section-decor--faq::before,
  body:not(.lower-page) .flow-panel::after,
  body:not(.lower-page) .jr-section-decor--recommend::before,
  body:not(.lower-page) .jr-section-decor--reasons-2::after,
  body:not(.lower-page) .jr-section-decor--courses::after,
  body:not(.lower-page) .jr-section-decor--faq::after,
  body:not(.lower-page) .jr-section-decor--voice::before,
  body:not(.lower-page) .jr-section-decor--hero::after,
  body:not(.lower-page) .jr-section-decor--recommend::after,
  body:not(.lower-page) .jr-section-decor--reasons::before,
  body:not(.lower-page) .jr-section-decor--courses::before,
  body:not(.lower-page) .jr-section-decor--courses-2::before,
  body:not(.lower-page) .jr-section-decor--voice::after,
  body:not(.lower-page) .results::after {
    animation: none;
  }
}

body:not(.lower-page) .results-voice > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .reasons {
  position: relative;
}

body:not(.lower-page) .reasons > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .faq-section {
  position: relative;
}

body:not(.lower-page) .faq-section > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .courses > :not(.jr-section-decor) {
  position: relative;
  z-index: 1;
}

/* ===== PR-TOP8: フロー丸バッジ化/背景ぼかし非表示/見出し緑→黒/黄色あしらい追加(ユーザー指示2026-08-01) ===== */

/* 2. 背景のぼかしパララックス(#bgBlobs、8個)を一時非表示 */
body:not(.lower-page) #bgBlobs {
  display: none !important;
}

/* 3. h2/h3内の緑文字を黒(#222・PR-TOP3で統一した色)に */
body:not(.lower-page) .message h2 span,
body:not(.lower-page) .reasons-title h2 .reason-count {
  color: #222 !important;
}

/* 4. セクション見出し上の英字ラベル(section-kicker)に黄色いダッシュを追加(about/course系のmp-v2 .section-kicker::beforeを移植) */
body:not(.lower-page) .section-kicker::before {
  display: inline-block;
  width: 1em;
  height: 1px;
  margin-right: 0.55em;
  vertical-align: middle;
  background: #ffca08;
  content: "";
}

/* ===== PR-TOP11: recommendカードのアイコンサイズをabout/course系(78px)に統一(ユーザー承認2026-08-01) ===== */
body:not(.lower-page) .recommend-grid span {
  width: 78px !important;
  height: 78px !important;
}

/* ===== PR-TOP12: VOICE英字グリーン化/ドット黄色化/メッセージ強調カラー/「3」フォント/WHY MY PORT装飾かぶり修正(ユーザー指示2026-08-01) ===== */

/* 1. VOICEセクションの英字ラベルのみ緑に戻す(ACHIEVEMENT/SUCCESS STORIESはピンクのまま) */
body:not(.lower-page) .voice .section-kicker {
  color: var(--green) !important;
}

/* 2. 合格体験記スライダー下部のドット(現在位置)を黄色に */
body:not(.lower-page) .voice-dot.active {
  background: var(--yellow) !important;
}

/* 3. メッセージ見出し内「未来を選べる力」を強調カラー(ヒーロー見出しと同じvar(--yellow))に */
body:not(.lower-page) .message h2 span {
  color: var(--yellow) !important;
}

/* 4. 「選ばれる3つの理由」の「3」をGeorgia serifのみに(Playballを外す) */
body:not(.lower-page) .reasons-sticky-wrap .reasons-title h2 .reason-count b,
body:not(.lower-page) .reasons-title h2 .reason-count::first-letter {
  font-family: Georgia, "Times New Roman", serif !important;
}

/* 5. WHY MY PORT見出しと被っていた左上の▽装飾を見出し下へ移動 */
body:not(.lower-page) .jr-section-decor--reasons::before {
  top: 220px !important;
}

@media (max-width: 980px) {
  body:not(.lower-page) .jr-section-decor--reasons::before {
    top: 235px !important;
    left: 0 !important;
  }
}

/* ===== PR-TOP14: 全ボタンにアローアイコンを一括追加(ユーザー指示2026-08-01) ===== */
/* 対象: Gナビ/モバイルナビのCTA、button(primary/ghost/small)全て。
   対象外: .phone(電話アイコン持ち)、.form(既に矢印SVG持ち)。 */
body:not(.lower-page) .nav-cta::after,
body:not(.lower-page) .mobile-nav-cta::after,
body:not(.lower-page) .button:not(:has(svg))::after,
body:not(.lower-page) .faq-more::after {
  content: "→";
  margin-left: 6px;
}

/* ===== PR-TOP15: コース案内ボタンの色を対象カラーに統一+余白追加(ユーザー指示2026-08-01) ===== */

/* 余白: h3/chips と同じ左右28pxを追加し、カード端への張り付きを解消 */
body:not(.lower-page) .course-card .button.ghost {
  margin: 4px 28px 28px;
}

/* 色: 各カードのh3・chipsと同じ配色に統一(矢印はcurrentColor追従のため自動で揃う) */
body:not(.lower-page) .course-card.elementary .button.ghost {
  color: var(--green);
  border-color: var(--green);
}

body:not(.lower-page) .course-card.junior .button.ghost {
  color: var(--blue);
  border-color: var(--blue);
}

body:not(.lower-page) .course-card.high .button.ghost {
  color: var(--pink);
  border-color: var(--pink);
}

/* 2026-09-29: 上記3色分のhover/focus-visible。下層(body.mp-v2)の.course-card--色と
   同じ考え方(border色→背景、文字は白)。無スコープ.button.ghost:hoverの既定色より
   詳細度が高いためこちらが優先される。 */
body:not(.lower-page) .course-card.elementary .button.ghost:hover,
body:not(.lower-page) .course-card.elementary .button.ghost:focus-visible {
  color: #fff;
  background: var(--green);
  transform: translateY(-1px);
}

body:not(.lower-page) .course-card.junior .button.ghost:hover,
body:not(.lower-page) .course-card.junior .button.ghost:focus-visible {
  color: #fff;
  background: var(--blue);
  transform: translateY(-1px);
}

body:not(.lower-page) .course-card.high .button.ghost:hover,
body:not(.lower-page) .course-card.high .button.ghost:focus-visible {
  color: #fff;
  background: var(--pink);
  transform: translateY(-1px);
}

/* ===== PR-TOP17: 合格体験談ボタンの色修正+フロー接続線のズレ修正(ユーザー指示2026-08-01) ===== */

/* 1. 「合格体験談を読む」ボタンを緑に(旧テキストリンク用ルールの干渉を解消) */
body:not(.lower-page) .voice-story a.button.ghost {
  color: var(--green);
  border-color: var(--green);
}

body:not(.lower-page) .voice-story a.button.ghost:hover,
body:not(.lower-page) .voice-story a.button.ghost:focus-visible {
  color: #fff;
  background: var(--green);
  transform: translateY(-1px);
}



/* ===== PR-TOP18: FAQセクション「Q.」のフォントをabout/course系に統一(ユーザー指示2026-08-01) ===== */
body:not(.lower-page) .faq-item summary span {
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif !important;
  font-weight: 800 !important;
}

/* ===== PR-TOP19d: about/course系(mp-v2)のボタンに矢印アイコンを追加(TOPはPR-TOP14で対応済み) ===== */
body.mp-v2 .nav-cta::after,
body.mp-v2 .mobile-nav-cta::after,
body.mp-v2 .button:not(:has(svg))::after {
  content: "→";
  margin-left: 6px;
}

/* ===== voice/success.html: 「それぞれの合格までの道のり」を横スライダー化(旧PR-TOP22の縦グリッド強制指定を差し替え) =====
   スクロールはCSSのscroll-snap(ネイティブの横スクロール)、補助JSは voice-carousel.js(このページだけで読み込み)。
   PC(981px以上)=ちょうど2枚 / 980px以下=1枚+次のカードが少し見える90%幅。全て #stories 配下に限定。
   カードは grid アイテムなので、共通ルールの flex 指定(!important)は効かず、幅は列幅で決まる。 */
body.page-voice-success #stories .voice-carousel {
  position: relative;
}

body.page-voice-success #stories .voice-cards {
  position: relative; /* JSがカードのoffsetLeftで位置を測る基準 */
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 24px) / 2);
  gap: 24px;
  max-width: 100%;
  padding-bottom: 8px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin; /* JS無効時は横スクロールバーを見せ、7件すべてに届くようにする */
  transition: none;
  will-change: auto;
}

body.page-voice-success #stories .voice-carousel.is-ready .voice-cards {
  scrollbar-width: none;
}

body.page-voice-success #stories .voice-carousel.is-ready .voice-cards::-webkit-scrollbar {
  display: none;
}

body.page-voice-success #stories .voice-cards:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 4px;
}

/* 自動送りで最後→先頭へ戻るとき(全カードを逆走させない): フェードアウト→先頭へ瞬時に移動→フェードイン(JSが .is-rewinding を付け外し) */
body.page-voice-success #stories .voice-carousel.is-ready .voice-cards {
  transition: opacity 0.32s ease;
}

body.page-voice-success #stories .voice-carousel.is-rewinding .voice-cards {
  opacity: 0;
}

/* PCのマウスドラッグ: カードをつかめるカーソル。ドラッグ中は grabbing で、テキスト選択を止める(リンクの通常クリックは従来どおり) */
@media (hover: hover) and (pointer: fine) {
  body.page-voice-success #stories .voice-carousel.is-ready .voice-cards,
  body.page-voice-success #stories .voice-carousel.is-ready .voice-card {
    cursor: grab;
  }
}

body.page-voice-success #stories .voice-carousel.is-dragging .voice-cards,
body.page-voice-success #stories .voice-carousel.is-dragging .voice-cards * {
  cursor: grabbing;
  user-select: none;
}

/* カード: 同じ行の高さは最も高いカードに揃う(gridの既定=stretch)。fade-up・hover演出・影はスライダー内では無効
   (横にはみ出したカードが透明のままになる/影がスクロール領域の端で四角く切れるのを避ける) */
body.page-voice-success #stories .voice-card {
  width: 100% !important; /* 980px以下の共通指定 width: calc(100% - 1rem) !important を打ち消す(列幅=カード幅) */
  min-width: 0;
  scroll-snap-align: start;
  opacity: 1;
  transform: none;
  transition: none;
  box-shadow: none;
  cursor: default;
}

/* 本文エリアを縦flexにして、リンクボタンをカード下端・中央へ(カードごとの文章量の差を吸収。文章は省略しない) */
body.page-voice-success #stories .voice-story {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

@media (max-width: 980px) {
  body.page-voice-success #stories .voice-cards {
    grid-auto-columns: 90%;
    gap: 16px;
  }
}

/* PC(981px以上): 1・2枚目はカード2枚分の本文幅に収め、右側に3枚目を途中まで見せる(次のカードが続くことを示す)。
   スクロール領域(.voice-cards)自体を右へ画面端まで広げる: 親要素はすべて overflow: visible のまま、右マージンを負にして広げ、
   右パディング(領域幅-2枚分)を足して、最終位置で6枚目がぴったり左端に来る(=6・7枚目を表示、右に余白)ようにする。overflow: hidden では隠さない。
   --vc-w / --vc-bleed は voice-carousel.js が実測してセットする(JS無効時は従来どおりカード2枚だけ)。
   カード幅は従来(本文幅-24px)/2を基本とし、右側のチラ見せが最低72px残るよう狭い画面では最大数%だけ細くする。 */
@media (min-width: 981px) {
  body.page-voice-success #stories .voice-carousel.is-ready .voice-cards {
    max-width: none;
    margin-right: calc(var(--vc-bleed, 0px) * -1);
    --vc-card: calc(min(var(--vc-w, 1128px) - 24px, var(--vc-w, 1128px) + var(--vc-bleed, 0px) - 120px) / 2);
    grid-auto-columns: var(--vc-card);
    padding-right: calc(var(--vc-w, 1128px) + var(--vc-bleed, 0px) - 2 * var(--vc-card) - 24px);
  }
}

@media (max-width: 640px) {
  body.page-voice-success #stories .voice-card {
    --vc-pad-y: 28px;
    --vc-pad-x: 20px;
  }
}

/* 操作部(前へ/次へ・ドット): JSが動いたときだけ表示。全PC・SPともカードの下にまとめ、本文に重ねない */
body.page-voice-success #stories .voice-carousel-nav {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 20px;
}

body.page-voice-success #stories .voice-carousel.is-ready:not(.is-static) .voice-carousel-nav {
  display: flex;
}

body.page-voice-success #stories .voice-carousel-btn {
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  place-items: center;
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  background: #fff;
  border: 1px solid #e9bfd0;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.2s ease, opacity 0.2s ease;
}

body.page-voice-success #stories .voice-carousel-btn:hover:not(:disabled) {
  background: #fbf0f3;
}

body.page-voice-success #stories .voice-carousel-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

body.page-voice-success #stories .voice-carousel-btn:focus-visible,
body.page-voice-success #stories .voice-carousel-dot:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

body.page-voice-success #stories .voice-carousel-dots {
  display: flex;
  align-items: center;
}

body.page-voice-success #stories .voice-carousel-dot {
  display: grid;
  width: 24px;
  height: 24px;
  padding: 0;
  place-items: center;
  background: transparent;
  border: 0;
  cursor: pointer;
}

body.page-voice-success #stories .voice-carousel-dot::before {
  width: 8px;
  height: 8px;
  background: #d8dde2;
  border-radius: 50%;
  content: "";
}

body.page-voice-success #stories .voice-carousel-dot[aria-current="true"]::before {
  background: var(--green);
}

@media (max-width: 640px) {
  body.page-voice-success #stories .voice-carousel-nav {
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.page-voice-success #stories .voice-carousel-btn {
    transition: none;
  }
}

/* 読み上げ専用の状態表示(視覚的には非表示) */
body.page-voice-success #stories .voice-carousel-status {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  white-space: nowrap;
  border: 0;
  clip: rect(0 0 0 0);
}

/* ===== PR-TOP23: voice/success.htmlの.results-voiceを1カラムに修正(.voice要素の幅崩れ解消) ===== */
body.page-voice-success .results-voice {
  display: block !important;
}

/* ===== PR-TOP24: voice/index.htmlの合格体験談カード抜粋を縦グリッドに変更(1枚しか見えない不具合の修正) ===== */
body.page-voice-index .voice-cards {
  display: grid !important;
  gap: 18px !important;
}

body.page-voice-index .voice-card,
body.page-voice-index .voice-card.main {
  flex: none !important;
  width: 100% !important;
}

/* ===== PR-TOP25: voice/index.htmlの.results-voiceを1カラムに修正(#voice-excerptの幅崩れ解消) ===== */
body.page-voice-index .results-voice {
  display: block !important;
}

/* ===== PR-TOP27: TOPコース案内カードを全体クリック可能に(stretched link) ===== */
body:not(.lower-page) #courses .course-card {
  position: relative;
  cursor: pointer;
}

/* 2026-09-29 用途確認: stretched-linkパターン。.button.ghost自身はposition:staticのため、
   このinset:0は最も近いposition指定祖先である#courses .course-card(position:relative)を
   基準に展開され、ボタンの疑似要素がカード全体を覆う=カードのどこをクリックしてもボタンの
   リンクが機能する仕組み。疑似要素は生成元要素(<a>)の一部として扱われるため、hover/focus-visible/
   クリックを妨げない(カード上のどこにマウスがあっても<a>自身の:hoverとして扱われ、
   キーボードでのTab移動によるfocus-visibleはマウス位置と無関係に正しく機能する)。
   意図的な実装のため削除せず維持。 */
body:not(.lower-page) #courses .course-card .button.ghost::before {
  content: "";
  position: absolute;
  inset: 0;
}

/* ===== PR-TOP28: CSS重複削除フェーズ1-1(ユーザー承認2026-08-05)
   TOP専用 .nav-cta / .button.primary の白文字ルールが3箇所(244-276, 2961-2974, 8935-8961行)に
   重複していたのを統合。見た目(白文字・text-shadow無し)は一切変更していない。
   .phone / .mobile-nav-cta は別の既存ルールで既に白色が保証されているため、このブロックには含めない。
   2026-09-29: 通常時のcolor:#fffは無scope base(.nav-cta, .button.primary{color:#fff})で
   既に保証されており、このTOP限定コピーは完全な重複だった。かつbody:not(.lower-page)付与により
   詳細度が.button.primary:hoverより高くなり、hover反転(黄文字)が効かなくなるバグの原因に
   なっていたため削除。text-shadowを打ち消す他の指定は見当たらないため実害なし。 ===== */
body:not(.lower-page) .nav-cta svg,
body:not(.lower-page) .nav-cta svg *,
body:not(.lower-page) .button.primary svg,
body:not(.lower-page) .button.primary svg * {
  color: #fff;
  fill: #fff;
  stroke: #fff;
}

/* ===== PR-TOP29: 電話CTAに矢印アイコンを追加(受話器アイコンは維持、右側に→)。全ページ共通CTAのためスコープなし ===== */
/* 2026-09-29: .phoneは白背景+緑文字(var(--green))のボタンのため、白矢印は背景に同化して
   見えなくなっていた。.formボタン(緑背景+白矢印)と同じ考え方で、.phone自身の文字色に合わせる。
   色は明示指定せず継承に委ねることで、.phone:hoverでの反転(緑背景+白文字)時に矢印も
   自動で白へ追従する。 */
.phone::after {
  content: "→";
}

/* 2026-09-29: 体験授業ボタン(.form)側は太いSVGアイコン(stroke-width:2.2)だったため、
   電話ボタン(.phone::after)と太さ・サイズが不揃いだった。SVGを廃止し.phoneと同じ
   文字矢印「→」に統一(実装方式も統一)。色は.form自身の文字色(白)を継承、
   font-sizeのみ.phone(18px)と揃えるため明示指定。右端余白はpadding/gapが.phoneと
   共通のため追加指定なしで一致する。 */
.form::after {
  content: "→";
  font-size: 18px;
}

/* ===== PR-TOP32: 「選ばれる3つの理由」(.reasons-sticky-wrap)CSS整理フェーズA(統合ルールの追記)
   実測・実ファイル確認済みの現在値を再現。既存ルールは削除せず、末尾追記の後勝ちでこれが最終値になる。 ===== */

/* PC(981px以上): stickyでカードが切り替わる演出 */
@media (min-width: 981px) {
  body:not(.lower-page) .reasons-sticky-wrap {
    height: 300vh !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reasons {
    position: sticky !important;
    top: 160px !important;
    display: grid !important;
    grid-template-columns: 285px minmax(0, 760px) !important;
    align-items: center !important;
    align-content: start !important;
    gap: clamp(36px, 6vw, 96px) !important;
    min-height: calc(100svh - 220px) !important;
    padding-top: clamp(24px, 3svh, 40px) !important;
    padding-bottom: clamp(24px, 3svh, 40px) !important;
    overflow: hidden !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reasons-title {
    position: relative !important;
    width: 285px !important;
    margin: 0 !important;
    align-self: start !important;
    top: auto !important;
    transform: none !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-cards {
    position: relative !important;
    display: block !important;
    max-width: 760px !important;
    height: min(48svh, 390px) !important;
    align-self: start !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card {
    position: absolute !important;
    inset: 0 !important;
    min-height: 590px;
    height: 590px;
    padding-top: 330px;
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translateY(60px) scale(0.96) !important;
    transition: opacity 0.45s ease, transform 0.55s ease !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-photo {
    height: 280px;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card strong {
    top: 236px;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card.active {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translateY(0) scale(1) !important;
  }

  body:not(.lower-page) .reasons-sticky-wrap .reason-card.past {
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translateY(-48px) scale(0.96) !important;
  }
}

/* ===== PR-VOICE2: voice/success.html 実画像差し替え(page-voice-success スコープ) ===== */
body.page-voice-success .hero-visual .jr-hero-photo {
  background-image: url("img/mp-voice-success-fv.webp");
}

body.page-voice-success .message .photo-portrait::before {
  content: none;
}

body.page-voice-success .voice-card .voice-headline {
  display: flex;
  flex-direction: column;
  gap: 0;
}

body.page-voice-success .voice-card .voice-headline span {
  margin: 0;
  color: #555;
  font-size: 14px;
  font-weight: 600;
}

body.page-voice-success .voice-card .voice-headline h3 {
  margin: 0;
  color: var(--green);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
}

/* 2026-09-27: h3の文字色は#stories既存のカード色ローテーション(border-top/voice-photoと同じ
   green→blue→pinkの3色サイクル、9930行目付近)に合わせる。ページ固有ハードコード色は追加しない。 */
body.page-voice-success #stories .voice-card:nth-of-type(3n+2) .voice-headline h3 {
  color: var(--blue);
}

body.page-voice-success #stories .voice-card:nth-of-type(3n) .voice-headline h3 {
  color: var(--pink);
}

body.page-voice-success .voice-card small {
  color: #222;
}

body.page-voice-success .voice-story p {
  color: #555;
}

/* (2026-10-22: 横スライダー化に伴い、旧「PCで右寄せ」(justify-self: end)は廃止。リンクボタンはカード下端・中央) */

body.page-voice-success .voice-record-note {
  max-width: 1160px;
  margin: 0 auto 104px;
  padding: 0 clamp(22px, 5vw, 56px);
  text-align: center;
}

body.page-voice-success .voice-record-note p {
  margin: 0 0 20px;
  color: #222;
}

/* ===== PR-FLOW1: 入塾までの4ステップをBBYの3ステップ装飾(タイムライン風)に統一(page-about-flow) ===== */
body.page-about-flow .system-steps {
  list-style: none;
  counter-reset: mp-flow-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-about-flow .system-steps li {
  counter-increment: mp-flow-step;
  position: relative;
  padding: 2px 0 30px 74px;
}

body.page-about-flow .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-about-flow .system-steps li::before {
  content: counter(mp-flow-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-about-flow .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-about-flow .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-about-flow .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

body.page-about-flow .system-steps li p {
  margin: 0;
  color: #333;
  line-height: 1.7;
}

/* ===== PR-COACH1: coaching_counseling.htmlの背景ウォーターマーク文字を個別指定 ===== */
body.page-about-coaching #coaching-approach.courses::before {
  content: "COACHING";
}

body.page-about-coaching #learning-connection.courses::before {
  content: "CONNECTION";
}

body.page-about-coaching .parents-note {
  border: none;
  background: #fff;
}

body.page-about-coaching .parents-note h3 {
  text-align: center;
}

/* 2026-09-27: about/reason.html の .parents-note(foundation-note)調整(ユーザー指定)。
   page-about-coachingの既存border:none/background:#fffと同じ考え方で個別指定。 */
body.page-about-reason .parents-note {
  margin: 0 auto;
  padding: clamp(32px, 4vw, 44px);
  background: #fff;
  border: none;
}

body.page-about-coaching #coaching-approach .course-card--green .course-image {
  background-image: url("img/coaching_counseling01.webp");
  background-position: center 30%;
  height: 180px;
}

body.page-about-coaching #coaching-approach .course-card--blue .course-image {
  background-image: url("img/mp-coaching-step2.webp");
  background-position: center 30%;
  height: 180px;
}

body.page-about-coaching #coaching-approach .course-card--pink .course-image {
  background-image: url("img/coaching_counseling05.webp");
  background-position: center 30%;
  height: 180px;
}

/* ===== PR-MSGUNIFY1: CONCEPT/GUIDE/MESSAGEセクションをテキストのみ・幅広に統一 ===== */
.message.message--text-only {
  grid-template-columns: 1fr !important;
  max-width: 900px;
}

.message.message--text-only .portrait-wrap {
  display: none;
}

/* ===== PR-TEACHER1: about/teacher.htmlの講師写真とウォーターマーク ===== */
body.page-about-teacher #parent-support.courses::before {
  content: "PARENTS";
}

/* ===== PR-BBY1: course/bby.html 実画像差し替え ===== */
body.page-bby .hero-visual .jr-hero-photo {
  background-image: url("img/bby.webp");
}

/* 2026-09-27: BBYヒーロー画像位置調整(SPのみ)。.hero-visual .jr-hero-photoは下層各ページの
   ヒーロー画像で共有されるセレクタのため、他ページへ波及しないよう必ずbody.page-bbyでスコープ。 */
@media (max-width: 640px) {
  body.page-bby .hero-visual .jr-hero-photo {
    background-position: center right 79%;
  }
}

/* ===== PR-ABOUTPACK1: about/index.html・about/support.html の画像とウォーターマーク・背景色 ===== */
body.page-about-index #about-nav.courses::before {
  content: "ABOUT";
}

body.page-about-index .hero-visual .jr-hero-photo {
  background-image: url("img/mp-about-index-fv.webp");
}

body.page-about-support .hero-visual .jr-hero-photo {
  background-image: url("img/mp-about-support-fv.webp");
}

body.page-about-support .faq-section:not(#faq-trial) {
  background: none;
}

body.page-about-support .price-section {
  background: #f6faf6;
}

/* ===== PR-WATERMARK-AUDIT1 (2026-09-29): 下層ページ大型ウォーターマーク英字監査。
   .section-kickerが存在するのに個別指定が無く、既定値(.courses::before "COURSE" /
   .faq-section .extra-head:before "FAQ")へフォールバックしていた箇所へ、既存の
   PR-COACH1/PR-TEACHER1/PR-ABOUTPACK1と同じ方式でページ+id個別指定を追加。 */
body.page-about-teacher #teacher-policy.courses::before {
  content: "POLICY";
}

body.page-about-flow .courses::before {
  content: "PRICE";
}

body.page-cs #grade-courses.courses::before {
  content: "BY GRADE";
}

body.page-cs #program-tools.courses::before {
  content: "PROGRAMS & TOOLS";
}

body.page-atama #atama-features.courses::before {
  content: "FEATURES";
}

body.page-atama #atama-grade-usage.courses::before {
  content: "GRADE";
}

body.page-bby #grade-features.courses::before {
  content: "BY GRADE";
}

body.page-bby #bby-steps.courses::before {
  content: "HOW IT WORKS";
}

body.page-hs #high-support.courses::before {
  content: "SUPPORT";
}

body.page-hs #high-ict.courses::before {
  content: "ICT";
}

body.page-ik #ikunou-flow.courses::before {
  content: "HOW IT WORKS";
}

body.page-pr #primary-learning.courses::before {
  content: "LEARNING";
}

body.page-tr #terrace-combination.courses::before {
  content: "COMBINATION";
}

body.page-record-index #related-pages.courses::before {
  content: "RELATED";
}

body.page-voice-index #related-pages.courses::before {
  content: "RELATED";
}

body.page-voice-success #related-pages.courses::before {
  content: "RELATED";
}

body.page-about-support #faq-trial .extra-head:before {
  content: "TRIAL";
}

body.page-about-support #faq-course .extra-head:before {
  content: "COURSE";
}

body.page-about-support #faq-support .extra-head:before {
  content: "SUPPORT";
}

/* ===== PR-COACH2: 学習指導とのつながり(coaching)・コースの仕組み(ikunou)をタイムライン化 ===== */
body.page-about-coaching #learning-connection .system-steps {
  list-style: none;
  counter-reset: mp-connection-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-about-coaching #learning-connection .system-steps li {
  counter-increment: mp-connection-step;
  position: relative;
  padding: 2px 0 30px 74px;
}

body.page-about-coaching #learning-connection .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-about-coaching #learning-connection .system-steps li::before {
  content: counter(mp-connection-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-about-coaching #learning-connection .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-about-coaching #learning-connection .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-about-coaching #learning-connection .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

body.page-about-coaching #learning-connection .system-steps li p {
  margin: 0;
  color: #333;
  line-height: 1.7;
}

body.page-ik #ikunou-flow .system-steps {
  list-style: none;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-ik #ikunou-flow .system-steps li {
  position: relative;
  padding: 2px 0 30px 74px;
  min-height: 48px;
}

body.page-ik #ikunou-flow .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-ik #ikunou-flow .system-steps li .jr-course-icon {
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  border: none;
  margin: 0;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-ik #ikunou-flow .system-steps li .jr-course-icon svg {
  width: 24px;
  height: 24px;
  stroke-width: 2px;
}

body.page-ik #ikunou-flow .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-ik #ikunou-flow .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-ik #ikunou-flow .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

body.page-ik #ikunou-flow .system-steps li p {
  margin: 0;
  color: #333;
  line-height: 1.7;
}

/* ===== PR-BBYPROP1: 他ページのBBY関連カードに実画像を反映 ===== */
body.page-voice-success .course-card:has(a[href="/course/bby.html"]) .course-image {
  background-image: url("img/bby.webp");
}

body.page-about-index #course-nav .course-card:has(a[href="/course/bby.html"]) .course-image {
  background-image: url("img/bby.webp");
}

/* ===== PR-ABOUT2: about/index.html principal-message・recommend-grid調整、about/flow.html料金カード化 ===== */
@media (min-width: 981px) {
  body.page-about-index .recommend-grid {
    grid-template-columns: repeat(3, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

/* ===== PR-COACH3: coaching_counseling調整、teacher.html講師紹介背景+保護者との関わり方タイムライン化 ===== */
body.page-about-teacher #parent-support .system-steps {
  list-style: none;
  counter-reset: mp-parent-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-about-teacher #parent-support .system-steps li {
  counter-increment: mp-parent-step;
  position: relative;
  padding: 2px 0 30px 74px;
}

body.page-about-teacher #parent-support .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-about-teacher #parent-support .system-steps li::before {
  content: counter(mp-parent-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-about-teacher #parent-support .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-about-teacher #parent-support .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-about-teacher #parent-support .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

body.page-about-teacher #parent-support .system-steps li p {
  margin: 0;
  color: #333;
  font-size: 14px;
  line-height: 1.7;
}

body.page-about-index #about-nav .about-nav-fv-reason {
  background-image: url("img/mp-about-reason-fv.jpg");
}

body.page-about-index #about-nav .about-nav-fv-coaching {
  background-image: url("img/mp-about-coaching-fv.jpg");
}

body.page-about-index #about-nav .course-card--pink .course-image {
  background-image: url("img/mp-about-flow-fv.jpg");
}

body.page-about-index #about-nav .about-nav-fv-support {
  background-image: url("img/mp-about-support-card.jpg?v=2");
}

/* ===== PR-MULTI1: 各ページのカードアイキャッチに実FV画像を反映、余白・幅の調整 ===== */
body.page-about-index #course-nav .course-card--green .course-image {
  background-image: url("img/mp-course-fv.jpg");
}

body.page-about-index #course-nav .course-card:has(a[href="/course/high_school.html"]) .course-image {
  background-image: url("img/mp-hs-fv.jpg");
}

body.page-about-flow .course-card:has(a[href^="/course/primary_school.html"]) .course-image {
  background-image: url("img/mp-pr-fv.jpg");
}

body.page-about-flow .course-card:has(a[href="/course/junior_high_school.html#price"]) .course-image {
  background-image: url("img/mp-jr-fv.jpg");
}

body.page-about-flow .course-card:has(a[href^="/course/high_school.html"]) .course-image {
  background-image: url("img/mp-hs-fv.jpg");
}

body.page-about-support .price-section {
  padding-top: 92px;
  padding-bottom: 92px;
}

@media (max-width: 640px) {
  body.page-about-support .price-section {
    padding-top: 76px;
    padding-bottom: 76px;
  }
}

@media (min-width: 981px) {
  body.page-pr .recommend-grid {
    grid-template-columns: repeat(3, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

body.page-bby #grade-features .course-card--green .course-image {
  background-image: url("img/mp-bby-grade12.webp");
}

body.page-bby #grade-features .course-card--blue .course-image {
  background-image: url("img/mp-bby-grade3.webp");
}

body.page-bby #grade-features .course-card--pink .course-image {
  background-image: url("img/mp-bby-medical.webp");
}

body.page-tr #terrace-skills.courses::before {
  content: "SKILLS";
}

body.page-tr #terrace-skills .system-steps,
body.page-hs .system-section .system-steps {
  list-style: none;
  counter-reset: mp-terrace-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-tr #terrace-skills .system-steps li,
body.page-hs .system-section .system-steps li {
  counter-increment: mp-terrace-step;
  position: relative;
  padding: 2px 0 30px 74px;
}

body.page-tr #terrace-skills .system-steps li:last-child,
body.page-hs .system-section .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-tr #terrace-skills .system-steps li::before,
body.page-hs .system-section .system-steps li::before {
  content: counter(mp-terrace-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-tr #terrace-skills .system-steps li:not(:last-child)::after,
body.page-hs .system-section .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-tr #terrace-skills .system-steps li h3,
body.page-hs .system-section .system-steps li h3 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-tr #terrace-skills .system-steps li small,
body.page-hs .system-section .system-steps li small {
  display: block;
  margin: 0 0 8px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

body.page-tr #terrace-skills .system-steps li p,
body.page-hs .system-section .system-steps li p {
  margin: 0;
  color: #333;
  line-height: 1.7;
}

/* ===== PR-CM2: comiru「Comiruの主な機能」の背景ウォーターマークをFEATURESに ===== */
body.page-cm #comiru-features.courses::before {
  content: "FEATURES";
}

/* ===== PR-VOICE3: 体験談カードの写真拡大+アクセントカラー(reason-card寄せ・軽量版) ===== */
body.page-voice-success #stories .voice-card {
  grid-template-columns: 128px minmax(0, 1fr) !important;
  padding: var(--vc-pad-y, 32px) var(--vc-pad-x, 28px) !important;
  border-top: 4px solid var(--green);
  gap: 1rem !important;
}

body.page-voice-success #stories .voice-card:nth-of-type(3n+2) {
  border-top-color: var(--blue);
}

body.page-voice-success #stories .voice-card:nth-of-type(3n) {
  border-top-color: var(--pink);
}

body.page-voice-success #stories .voice-card .voice-photo {
  width: 128px !important;
  height: 128px !important;
  border: 4px solid var(--green);
  margin: 0 auto !important;
  display: block;
}

body.page-voice-success #stories .voice-card:nth-of-type(3n+2) .voice-photo {
  border-color: var(--blue);
}

body.page-voice-success #stories .voice-card:nth-of-type(3n) .voice-photo {
  border-color: var(--pink);
}

body.page-bby #grade-features .course-card--green .course-image,
body.page-bby #grade-features .course-card--blue .course-image,
body.page-bby #grade-features .course-card--pink .course-image {
  background-position: center top;
}

/* ===== PR-BBY2: 学年別の活用イメージ3枚の顔切れ修正(中央→上寄せ) ===== */
/* ===== PR-VOICE-DEDUP1-FIX: PR-VOICE-DEDUP1で削除した重複の一部が、実は3158行目付近の
   別ブロック(padding-left/right:10px, margin-left/right:-8px)より後方で値を確定させる
   役割を持っていたため、正しい値(8px・0)を復元する ===== */
@media (max-width: 640px) {
  .results-voice {
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  .voice-slider-outer {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* ===== 2026-08-12 page-specific visual adjustments ===== */
/* TOP MESSAGE / about CONCEPT: keep the existing portrait frame while using video. */
.message-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

body.page-about-index .message--video {
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.28fr);
}

/* TOP success stories: match the card treatment used by voice/success.html. */
body:not(.lower-page) .results-voice--stacked {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 42px;
  max-width: 1100px;
}

body:not(.lower-page) .results-voice--stacked .results,
body:not(.lower-page) .results-voice--stacked .admission-index,
body:not(.lower-page) .results-voice--stacked .voice {
  grid-column: 1 / -1;
  width: 100%;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body:not(.lower-page) .results-voice--stacked .admission-index,
body:not(.lower-page) .results-voice--stacked .top-voice-stories {
  max-width: 920px;
  margin-inline: auto;
}

body:not(.lower-page) .results-voice--stacked .admission-index-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin-top: 24px;
}

body:not(.lower-page) .results-voice--stacked .admission-index-list a {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  align-items: center;
  gap: 3px 12px;
  min-width: 0;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body:not(.lower-page) .results-voice--stacked .admission-index-photo {
  grid-row: 1 / span 2;
  display: block;
  width: 88px;
  height: 88px;
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  border-radius: 50%;
}

body:not(.lower-page) .top-voice-stories .voice-cards {
  display: grid;
  gap: 20px;
  transform: none;
}

body:not(.lower-page) .top-voice-stories .voice-card,
body:not(.lower-page) .top-voice-stories .voice-card.main {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr);
  gap: 8px 22px;
  width: 100%;
  padding: 38px 42px;
  border-top: 4px solid var(--green);
  opacity: 1;
  transform: none;
  scroll-margin-top: 118px;
}

body:not(.lower-page) .top-voice-stories .voice-card:nth-child(3n+2) {
  border-top-color: var(--blue);
}

body:not(.lower-page) .top-voice-stories .voice-card:nth-child(3n) {
  border-top-color: var(--pink);
}

body:not(.lower-page) .top-voice-stories .voice-card .voice-photo {
  grid-row: 1 / span 3;
  width: 128px;
  height: 128px;
  margin: 0;
  border: 4px solid var(--green);
}

body:not(.lower-page) .top-voice-stories .voice-card:nth-child(3n+2) .voice-photo {
  border-color: var(--blue);
}

body:not(.lower-page) .top-voice-stories .voice-card:nth-child(3n) .voice-photo {
  border-color: var(--pink);
}

body:not(.lower-page) .top-voice-stories .voice-card > p,
body:not(.lower-page) .top-voice-stories .voice-card > small,
body:not(.lower-page) .top-voice-stories .voice-card > .voice-story {
  grid-column: 2;
}

/* TOP flow: reuse the TERRACE-style vertical timeline. */
body:not(.lower-page) .top-flow-steps {
  max-width: 680px;
  margin: 24px auto 0;
  padding: 0;
  list-style: none;
  counter-reset: mp-top-flow-step;
}

body:not(.lower-page) .top-flow-steps li {
  position: relative;
  padding: 2px 0 30px 74px;
  counter-increment: mp-top-flow-step;
}

body:not(.lower-page) .top-flow-steps li:last-child {
  padding-bottom: 0;
}

body:not(.lower-page) .top-flow-steps li::before {
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  color: #fff;
  background: var(--green);
  border-radius: 50%;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
  content: counter(mp-top-flow-step);
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-size: 20px;
  font-weight: 700;
}

body:not(.lower-page) .top-flow-steps li:not(:last-child)::after {
  position: absolute;
  top: 54px;
  bottom: 2px;
  left: 23px;
  width: 2px;
  background: var(--green-soft);
  content: "";
}

body:not(.lower-page) .top-flow-steps li > span {
  display: none;
}

body:not(.lower-page) .top-flow-steps li > small {
  display: block;
  margin: 0 0 4px;
  color: var(--green);
  font-family: "Quicksand", "Nunito Sans", "Avenir Next", "Century Gothic", sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

body:not(.lower-page) .top-flow-steps strong {
  display: block;
  margin: 0 0 4px;
  color: #333;
  font-size: 18px;
  line-height: 1.5;
}

body:not(.lower-page) .top-flow-steps p {
  margin: 0;
  color: #555;
  line-height: 1.7;
}

/* 2026-09-27: FLOWステップ本文の文字サイズをSPのみ14pxへ(ユーザー指定) */
@media (max-width: 640px) {
  body:not(.lower-page) .top-flow-steps p {
    font-size: 14px;
  }
}

body:not(.lower-page) .flow-panel {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

body:not(.lower-page) .flow-panel::before {
  position: absolute;
  top: clamp(-6px, 1vw, 12px);
  left: clamp(8px, 3vw, 40px);
  z-index: 0;
  color: rgba(31, 63, 54, 0.04);
  content: "FLOW";
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(92px, 14vw, 184px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  white-space: nowrap;
  pointer-events: none;
}

body:not(.lower-page) .flow-panel::after {
  position: absolute;
  right: 4px;
  bottom: 4px;
  z-index: 0;
  width: 24px;
  height: 24px;
  background-image: radial-gradient(circle, #d46d9f 2.5px, transparent 3px);
  background-size: 15px 15px;
  content: "";
  opacity: 0.5;
  pointer-events: none;
  animation: decorDotSpin 6s ease-in-out 0s infinite;
}

body:not(.lower-page) .flow-panel > * {
  position: relative;
  z-index: 1;
}

body:not(.lower-page) .faq-section {
  background: #f6faf6;
}

body:not(.lower-page) .faq-section .extra-head h3,
body:not(.lower-page) .faq-section .faq-item summary {
  color: #333;
}

body:not(.lower-page) .faq-section .faq-item p {
  color: #555;
}

/* Page-scoped image crop adjustments. */
body.page-tr .hero-visual .jr-hero-photo {
  background-image: url("img/mp-pr-sokudoku.jpg");
}

body.page-about-index #course-nav .course-card:has(a[href="/course/high_school.html"]) .course-image {
  background-position: center 35%;
}

body.page-about-flow .courses .course-image {
  background-position: center 35%;
}

body.page-wn .message-copy h2 {
  word-break: keep-all;
}

body.page-jr #course01 .jr-course-title {
  white-space: nowrap;
}

@media (min-width: 981px) {
  body.page-jr.recommend-six .recommend-grid {
    grid-template-columns: repeat(3, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

body.page-about-support .price-section {
  box-shadow: 0 0 0 100vmax #f6faf6;
  clip-path: inset(0 -100vmax);
}

/* ===== 2026-08-12 PR-BATCH11-MISC: page-scoped image replacements ===== */
body.page-about-teacher .mp-teacher-thinking {
  background-image: url("img/mp-teacher-thinking.webp");
}

body.page-about-teacher .mp-teacher-hearing {
  background-image: url("img/mp-teacher-hearing.webp");
}

body.page-about-teacher .mp-teacher-planning {
  background-image: url("img/mp-teacher-planning.webp");
}

body.page-cm .mp-comiru-fv {
  background-image: url("img/mp-comiru-fv.webp");
}

body.page-cm .mp-comiru-notice {
  background-image: none;
}

body.page-wn .mp-wingnet-grade12 {
  background-image: url("img/mp-hs-school.jpg");
}

body.page-wn .mp-wingnet-grade3 {
  background-image: url("img/mp-hs-exam.jpg");
}

body.page-wn .mp-wingnet-super {
  background-image: url("img/mp-hs-ict.jpg");
}

body.page-record-index .mp-record-fv,
body.page-voice-success .related-fv-record {
  background-image: url("img/mp-record-fv.webp");
}

body.page-record-index .related-fv-high-school,
body.page-voice-success .related-fv-high-school {
  background-image: url("img/mp-hs-fv.jpg");
}

body.page-record-index .related-fv-bby,
body.page-voice-success .related-fv-bby {
  background-image: url("img/bby.webp");
}

body.page-record-index .related-fv-reason {
  background-image: url("img/mp-about-reason-fv.jpg");
}

body.page-record-index .related-fv-flow,
body.page-voice-success .related-fv-flow {
  background-image: url("img/mp-about-flow-fv.jpg");
}

body.page-record-index .related-fv-support {
  background-image: url("img/mp-about-support-fv.webp");
}

body.page-jr .jr-course-more::after {
  content: "→";
}

/* ===== 2026-08-12 PR-BATCH11-IMGFIX: page-scoped crop adjustments ===== */
body.page-about-teacher .mp-teacher-thinking,
body.page-about-teacher .mp-teacher-hearing,
body.page-about-teacher .mp-teacher-planning {
  background-position: center 30%;
}

body.page-cm .hero-visual .mp-comiru-fv {
  background-position: 68% 34%;
}

body.page-cm .message .mp-comiru-message-photo,
body.page-cm .message .mp-comiru-message-photo::before {
  background-image: url("img/mp-comiru-message.webp");
  background-position: center;
  background-size: contain;
}

body.page-wn .mp-wingnet-grade12,
body.page-wn .mp-wingnet-grade3,
body.page-wn .mp-wingnet-super {
  background-position: center 30%;
}

body.page-record-index #related-pages .related-fv-high-school,
body.page-record-index #related-pages .related-fv-bby,
body.page-record-index #related-pages .related-fv-reason,
body.page-record-index #related-pages .related-fv-flow,
body.page-record-index #related-pages .related-fv-support {
  background-position: center 30%;
}

body.page-voice-success #related-pages .related-fv-record,
body.page-voice-success #related-pages .related-fv-high-school,
body.page-voice-success #related-pages .related-fv-bby,
body.page-voice-success #related-pages .related-fv-flow {
  background-position: center 30%;
}

/* ===== 2026-08-12 PR-BATCH13-FIXUP: page-scoped adjustments ===== */
/* 2026-09-28: 本体(.mp-terrace-concept)と::beforeの両方に同じ画像を指定していたため、
   SPで画像が二重に見えていた。他ページ(page-pr/jr/hs/ik)と同じ設計(::beforeのみが
   実際に表示される画像レイヤー)に合わせ、本体側の指定を削除。
   (その後、本体に残っていた共通フォールバック .photo-portrait{sensei.png} も、このページでは別ルールで無効化済み) */
body.page-tr .message .mp-terrace-concept::before {
  background-image: url("img/mp-terrace-reading-v2.webp");
  background-position: center;
  background-size: contain;
}

/* 2026-10: TERRACE 3講座カード/詳細セクション。
   body.mp-v2 .courses .course-grid は中学生ページ用の2列固定のため、TERRACEの3講座カードだけ
   PC=3列 / タブレット=2列(余った3枚目は中央) / SP=1列(既存)にする。他ページには影響しない。 */
@media (min-width: 981px) {
  body.page-tr #terrace-courses .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-tr #terrace-courses .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 説明文の行数がカードごとに違っても、ボタンが同じ高さ(カード下端)に揃うようにする */
body.page-tr #terrace-courses .course-card {
  display: flex;
  flex-direction: column;
}

body.page-tr #terrace-courses .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

body.page-tr .terrace-course-detail .course-intro h2 span {
  color: var(--green);
}

body.page-tr #shinkokugo .course-intro h2 span {
  color: var(--jr-blue);
}

body.page-tr #sokudoku-eigo .course-intro h2 span {
  color: var(--jr-pink);
}

/* 詳細セクションの見出し(TRAINING / RECOMMENDED)は、料金・FAQと同じ中央寄せ */
body.page-tr .terrace-course-detail .extra-head {
  max-width: none;
  margin: 24px 0 -16px; /* .courses の row-gap(40px)があるため、見出しと下の要素の間は 40-16=24px */
  text-align: center;
}

body.page-tr .terrace-course-detail .extra-head h3 {
  font-size: 22px;
}

/* 「主なトレーニング」: BBY・育脳等の同種カード(幅200px・中央・gap20px)と同じ寸法で中央に */
body.page-tr .terrace-course-detail .recommend-grid {
  grid-template-columns: repeat(3, minmax(0, 200px));
  justify-content: center;
}

/* SP: 既存の .recommend-grid article{width:154px !important} が3件を2列に割ってしまうため、
   トレーニング3件は1列・全幅で表示する */
@media (max-width: 640px) {
  body.page-tr .terrace-course-detail .recommend-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    justify-items: stretch;
  }

  body.page-tr .terrace-course-detail .recommend-grid article {
    width: 100% !important;
    min-height: 0 !important;
  }
}

/* PR-WATERMARK-AUDIT1と同じ方式: .section-kickerと透かし英字を一致させる。
   2026-10-17: 3講座の透かしを各講座の内容(SPEED READING / JAPANESE LANGUAGE / ENGLISH READING & LISTENING)に変更。
   文字数が増えて既定サイズ(15vw・最大190px)だと折り返し・はみ出しで本文と重なるため、各文字列の幅(em比 8.12 / 10.92 / 16.08)から
   1行に収まるサイズを指定し、折り返しを禁止する(コンテナ幅1180px=PC上限、SPは画面幅に追従)。 */
body.page-tr #terrace-courses.courses::before {
  content: "COURSES";
}

body.page-tr #sokudoku.courses::before {
  content: "SPEED READING";
  font-size: min(139px, calc((100vw - 40px) / 8.2));
  white-space: nowrap;
}

body.page-tr #shinkokugo.courses::before {
  content: "JAPANESE LANGUAGE";
  font-size: min(103px, calc((100vw - 40px) / 11));
  white-space: nowrap;
}

body.page-tr #sokudoku-eigo.courses::before {
  content: "ENGLISH READING & LISTENING";
  font-size: min(70px, calc((100vw - 40px) / 16.2));
  white-space: nowrap;
}

/* 2026-10: 公式サイトへの外部テキストリンク(BBY CONCEPT / TERRACE 4か所)。
   ボタンではなく、本文(14px)より小さい控えめな下線リンク。 */
body.mp-v2 .official-link {
  margin: 14px 0 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}

body.mp-v2 .official-link a {
  color: var(--green);
  font-weight: 400;
  text-decoration: underline;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

body.mp-v2 .official-link a:hover,
body.mp-v2 .official-link a:focus-visible {
  color: #3f7d45;
  text-decoration-thickness: 2px;
}

/* 外部サイトへ移動することが分かるよう、リンク末尾に外部リンクアイコン(currentColorで文字色に追従) */
body.mp-v2 .official-link a::after {
  content: "";
  display: inline-block;
  width: 0.85em;
  height: 0.85em;
  margin-left: 0.35em;
  vertical-align: -0.08em;
  background-color: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 4h6v6M20 4l-9 9M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 4h6v6M20 4l-9 9M18 14v5a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h5'/%3E%3C/svg%3E") center / contain no-repeat;
}

body.page-about-teacher .hero-visual .mp-teacher-fv,
body.page-about-teacher .hero-visual .mp-teacher-fv::before {
  background-image: url("img/mp-teacher-fv.webp");
  background-position: center 32%;
}

body.page-about-index .message--video {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 24px;
  overflow: hidden;
}

body.page-about-index .message--video::before {
  position: absolute;
  top: 18px;
  right: 28px;
  bottom: auto;
  left: auto;
  width: 78px;
  height: 78px;
  content: "";
  background: repeating-linear-gradient(45deg, rgba(47, 126, 212, 0.52) 0 5px, transparent 5px 11px);
  border-radius: 50%;
  opacity: 0.42;
  pointer-events: none;
}

body.page-about-index .message--video::after {
  position: absolute;
  bottom: 20px;
  left: 18px;
  content: "";
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid var(--jr-pink);
  transform: rotate(16deg);
  opacity: 0.38;
  pointer-events: none;
}

body:not(.lower-page) .message#about::before {
  position: absolute;
  top: 18px;
  right: 28px;
  width: 78px;
  height: 78px;
  content: "";
  background: repeating-linear-gradient(45deg, rgba(47, 126, 212, 0.52) 0 5px, transparent 5px 11px);
  border-radius: 50%;
  opacity: 0.42;
  pointer-events: none;
}

body:not(.lower-page) .message#about::after {
  position: absolute;
  bottom: 20px;
  left: 18px;
  content: "";
  border-top: 24px solid transparent;
  border-bottom: 24px solid transparent;
  border-left: 40px solid var(--jr-pink, var(--pink));
  transform: rotate(16deg);
  opacity: 0.38;
  pointer-events: none;
}

body.page-about-index .message--video > * {
  position: relative;
  z-index: 1;
}

body.page-about-index .message--video .message-video-heading,
body.page-about-index .message--video .portrait-wrap,
body.page-about-index .message--video .message-copy {
  width: min(100%, 960px);
  margin-inline: auto;
}

/* 2026-09-27: .fade-up.visible依存(スクロール到達で付与)だと初期表示時に効かないため、
   より安定したページスコープセレクタで指定。 */
body.page-about-index .message-video-heading {
  margin-bottom: 1rem;
}

/* 2026-09-27: .courses .course-intro pは他ページ共通で#555が既に指定されている
   (body.mp-v2 .courses .course-intro p:not(.section-kicker)、詳細度4クラス相当)ため、
   about/index.html限定で同等以上の詳細度・後勝ちで上書き(他ページ非影響)。 */
body.page-about-index .courses .course-intro p:not(.section-kicker) {
  color: #5b955a;
}

body.page-about-index .message--video .message-video {
  width: 100%;
  aspect-ratio: 16 / 9;
}

body.page-about-index .message--video .message-copy {
  display: block;
}

body.page-wn .hero-visual .mp-wingnet-fv {
  background-image: url("img/mp-wingnet-fv.webp");
  background-position: center;
}

body.page-wn #wingnet-about .mp-wingnet-about,
body.page-wn #wingnet-about .mp-wingnet-about::before {
  background-image: url("img/mp-wingnet-about.webp");
  background-position: center;
  background-size: contain;
}

body.page-about-flow .hero-visual .jr-hero-photo {
  background-position: 68% center;
}

body.page-about-support .hero-visual .jr-hero-photo {
  filter: brightness(1.16);
}

body.page-hs .recommend-grid {
  max-width: 980px;
  margin-inline: auto;
}

body.page-ik .price-section .faq-item {
  padding-bottom: 30px;
  text-align: center;
}

body.page-ik .price-section .faq-item p {
  text-align: left;
}

body.page-hs .high-related-pages .course-grid {
  max-width: 980px;
  margin-inline: auto;
}

body.page-hs .high-related-wingnet { background-image: url("img/mp-wingnet-fv.webp"); }
body.page-hs .high-related-bby { background-image: url("img/bby.webp"); }
body.page-hs .high-related-record { background-image: url("img/mp-record-fv.webp"); }

/* 2026-10-28: 本体(.mp-bby-about)と::beforeの両方に同じ画像を指定していたため、画像が二重に見えていた(SPでは::beforeにmargin-topが付き、2枚がずれて重なる)。
   TERRACEと同じく、実際に表示する画像レイヤー(::before)だけに指定し、本体側の指定は削除 */
body.page-bby .message .mp-bby-about::before {
  background-image: url("img/mp-bby-about.webp");
  background-position: center;
  background-size: contain;
}

body.page-bby .message .mp-bby-about {
  background-image: none !important; /* 共通の .photo-portrait{background-image:url(sensei.png)} (旧画像)を外す */
}

body:not(.lower-page) .top-voice-restored .admission-index {
  padding-bottom: 34px;
}

body:not(.lower-page) .top-voice-restored .admission-index .voice {
  width: 100%;
  margin-top: 34px;
  padding-top: 30px;
  border-top: 1px solid rgba(120, 178, 99, 0.24);
}

body:not(.lower-page) .top-voice-restored .top-voice-card {
  border-top: 4px solid var(--green);
}

body:not(.lower-page) .top-voice-restored .top-voice-card:nth-child(3n+2) { border-top-color: var(--blue); }
body:not(.lower-page) .top-voice-restored .top-voice-card:nth-child(3n) { border-top-color: var(--pink); }
body:not(.lower-page) .top-voice-restored .top-voice-card .voice-photo { border: 4px solid var(--green); }
body:not(.lower-page) .top-voice-restored .top-voice-card:nth-child(3n+2) .voice-photo { border-color: var(--blue); }
body:not(.lower-page) .top-voice-restored .top-voice-card:nth-child(3n) .voice-photo { border-color: var(--pink); }

/* ===== 2026-08-12 PR-BATCH15-FIXUP2 ===== */
body:not(.lower-page) #courses {
  grid-template-columns: minmax(0, 1fr);
  max-width: 1240px;
}

body:not(.lower-page) #courses .course-intro {
  width: min(100%, 880px);
  margin-inline: auto;
  text-align: center;
}

body:not(.lower-page) #courses .course-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  width: 100%;
}

body:not(.lower-page) .flow-photo-one {
  filter: brightness(1.14);
}

.top-voice-restored .admission-index-photo {
  border: 4px solid transparent;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.top-voice-restored [data-voice-index].is-active .admission-index-photo {
  border-color: var(--green);
  transform: scale(1.05);
}

.top-voice-restored [data-voice-index]:nth-child(3n+2).is-active .admission-index-photo { border-color: var(--blue); }
.top-voice-restored [data-voice-index]:nth-child(3n).is-active .admission-index-photo { border-color: var(--pink); }

.top-voice-restored .top-voice-card .voice-headline h3 { color: #222; }
.top-voice-restored .top-voice-card .voice-headline span { color: var(--green); }
.top-voice-restored .top-voice-card .button.ghost.small { color: var(--green); border-color: var(--green); }
.top-voice-restored .top-voice-card:nth-child(3n+2) .voice-headline span,
.top-voice-restored .top-voice-card:nth-child(3n+2) .button.ghost.small { color: var(--blue); }
.top-voice-restored .top-voice-card:nth-child(3n+2) .button.ghost.small { border-color: var(--blue); }
.top-voice-restored .top-voice-card:nth-child(3n) .voice-headline span,
.top-voice-restored .top-voice-card:nth-child(3n) .button.ghost.small { color: var(--pink); }
.top-voice-restored .top-voice-card:nth-child(3n) .button.ghost.small { border-color: var(--pink); }

/* 2026-09-29: 「合格体験談を読む」ボタン(3色ローテーション)のhover/focus-visible。
   他の.button.ghostと同じ思想(border色→背景、文字は白)に統一。 */
.top-voice-restored .top-voice-card .button.ghost.small:hover,
.top-voice-restored .top-voice-card .button.ghost.small:focus-visible {
  color: #fff;
  background: var(--green);
  transform: translateY(-1px);
}
.top-voice-restored .top-voice-card:nth-child(3n+2) .button.ghost.small:hover,
.top-voice-restored .top-voice-card:nth-child(3n+2) .button.ghost.small:focus-visible {
  background: var(--blue);
}
.top-voice-restored .top-voice-card:nth-child(3n) .button.ghost.small:hover,
.top-voice-restored .top-voice-card:nth-child(3n) .button.ghost.small:focus-visible {
  background: var(--pink);
}

body.page-about-teacher .hero-visual .mp-teacher-fv,
body.page-about-teacher .hero-visual .mp-teacher-fv::before {
  background-position: 78% 32%;
}

body.page-about-index .message--video .portrait-wrap {
  width: min(70%, 760px);
}

body.page-wn .hero-visual .mp-wingnet-fv {
  background-position: 88% center;
}

body.page-about-flow .hero-visual .jr-hero-photo {
  background-position: 96% center;
}

/* ===== 2026-08-12 PR-BATCH15-FIXUP3 ===== */
body:not(.lower-page) #courses .top-course-fv-primary {
  background-image: url("img/mp-pr-fv.jpg");
}

body:not(.lower-page) #courses .top-course-fv-junior {
  background-image: url("img/mp-jr-fv.jpg");
}

body:not(.lower-page) #courses .top-course-fv-high {
  background-image: url("img/mp-hs-fv.jpg");
}

body.page-cs #program-tools .course-index-fv-bby {
  background-image: url("img/bby.webp");
}

body.page-cs #program-tools .course-index-fv-terrace {
  background-image: url("img/mp-terrace-reading-v2.webp");
}

body.page-cs #program-tools .course-index-fv-wingnet {
  background-image: url("img/mp-wingnet-fv.webp");
}

body.page-cs #program-tools .course-index-fv-comiru {
  background-image: url("img/mp-comiru-fv.webp");
}

body:not(.lower-page) .top-voice-restored .admission-index-list a {
  gap: 4px;
}

body:not(.lower-page) .top-voice-restored .admission-index-list a > span:last-child {
  line-height: 1.3;
}

body:not(.lower-page) .top-voice-restored .admission-index-list a:hover .admission-index-photo,
body:not(.lower-page) .top-voice-restored .admission-index-list a:focus-visible .admission-index-photo {
  opacity: 0.78;
}

body:not(.lower-page) .top-voice-restored .admission-index .voice {
  border-top: 0;
}

.top-voice-restored .top-voice-card .voice-headline h3 {
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.top-voice-restored .top-voice-card .voice-headline span {
  line-height: 1.4;
}

.top-voice-restored .top-voice-card .voice-story .button.ghost.small {
  display: flex;
  width: max-content;
  margin: 18px auto 0;
  font-size: 14px;
}

body.page-hs .high-related-pages > .section-title {
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
}

body.page-hs .system-section .system-steps li::before {
  background: var(--jr-pink);
  box-shadow: 0 6px 16px rgba(212, 109, 159, 0.28);
}

body.page-hs .system-section .system-steps li:not(:last-child)::after {
  background: var(--jr-pink);
  opacity: 0.26;
}

body.page-hs .system-section .system-steps li small {
  color: var(--jr-pink);
}

@media (max-width: 640px) {
  body.page-about-index .message--video .portrait-wrap {
    width: 100%;
  }
}

@media (max-width: 640px) {
  /* 2026-09-28: SPファースト方針により、FLOWの透かしをSPでも表示(以前はdisplay:noneで非表示)。
     font-sizeのみ375pxで実測調整、位置・色は既存のまま。 */
  body:not(.lower-page) .flow-panel::before {
    font-size: 92px;
  }

  body.page-about-index .message--video {
    grid-template-columns: 1fr;
  }

  body:not(.lower-page) .results-voice--stacked .admission-index-list {
    grid-template-columns: 1fr;
  }

  body:not(.lower-page) .top-voice-stories .voice-card,
  body:not(.lower-page) .top-voice-stories .voice-card.main {
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 8px 14px;
    padding: 24px 20px;
    scroll-margin-top: 86px;
  }

  body:not(.lower-page) .top-voice-stories .voice-card .voice-photo {
    width: 88px;
    height: 88px;
  }

  body.page-wn .message-copy h2 {
    font-size: clamp(27px, 8vw, 36px);
  }

  body.page-jr #course01 .jr-course-title {
    font-size: clamp(17px, 5vw, 22px);
  }
}

/* ===== SCROLL BALL (背景演出・スクロール連動) ===== */
#scrollBallLayer {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.6s ease;
}

#scrollBallLayer.is-visible {
  opacity: 1;
}

.scroll-ball {
  position: absolute;
  top: 50%;
  left: 50%;
  width: clamp(64px, 11vw, 120px);
  height: clamp(64px, 11vw, 120px);
  margin: -60px 0 0 -60px;
  will-change: transform;
  transform: translate3d(0, 0, 0) scale(1) rotate(0deg);
}

.scroll-ball-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(
    circle at 50% 50%,
    rgba(255, 255, 255, 0.97) 0%,
    rgba(255, 244, 214, 0.88) 14%,
    rgba(255, 214, 140, 0.62) 38%,
    rgba(255, 193, 102, 0.34) 62%,
    rgba(255, 193, 102, 0) 84%
  );
  filter: blur(6px) brightness(1);
  box-shadow: 0 0 44px 14px rgba(255, 205, 120, 0.4);
  animation: scrollBallBreathe 5s ease-in-out infinite;
}

@keyframes scrollBallBreathe {
  0%, 100% {
    transform: scale(1);
    filter: blur(6px) brightness(1);
  }
  50% {
    transform: scale(1.16);
    filter: blur(7px) brightness(1.22);
  }
}

@media (max-width: 640px) {
  .scroll-ball {
    width: clamp(44px, 14vw, 76px);
    height: clamp(44px, 14vw, 76px);
    margin: -38px 0 0 -38px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-ball {
    transform: none !important;
  }

  .scroll-ball-inner {
    animation: none !important;
  }
}

/* ===== PR-REASONCARD1: TOP「選ばれる3つの理由」の枠・影を削除 ===== */
body:not(.lower-page) .reason-card {
  border: none;
  box-shadow: none;
}

body:not(.lower-page) .reason-card:hover {
  box-shadow: none;
  transform: none;
}


/* ===== PR-TOP-HERO-SP-SCOPE: Astra監査に基づくTOP限定SP実値 ===== */
@media (max-width: 640px) {
  body:not(.lower-page) .hero h1 {
    font-size: clamp(32px, 9.5vw, 40px) !important;
  }

  body:not(.lower-page) .hero .lead {
    font-size: clamp(15px, 4vw, 17px) !important;
    line-height: 1.8 !important;
  }

  body:not(.lower-page) .hero .stat-card small,
  body:not(.lower-page) .hero .stat-card span {
    font-size: clamp(11px, 3vw, 13px) !important;
    display: block !important;
  }

  body:not(.lower-page) .hero .stat-card strong {
    font-size: clamp(28px, 7.4vw, 32px) !important;
  }

  body:not(.lower-page) .hero-actions .button.primary {
    min-height: 56px !important;
  }

  body:not(.lower-page) .hero-actions .button.ghost {
    min-height: 46px !important;
  }

  body:not(.lower-page) .hero-actions .button {
    font-size: 14px !important;
  }

  body:not(.lower-page) .hero-visual {
    width: 20rem !important;
    margin-right: -4rem !important;
  }

  body:not(.lower-page) .stat-card.stat-a,
  body:not(.lower-page) .stat-card.stat-b,
  body:not(.lower-page) .stat-card.stat-c {
    display: block !important;
    padding: 1rem 0 !important;
  }
}


/* ===== PR-TOP-MESSAGE-SP-SCOPE: Astra監査に基づくTOP限定SP実値 ===== */
@media (max-width: 640px) {
  body:not(.lower-page) .message#about > .portrait-wrap {
    margin: 0 !important;
    min-height: auto !important;
    transform: unset !important;
  }

  body:not(.lower-page) .message-video {
    margin-bottom: 2rem !important;
  }

  body:not(.lower-page) .message#about .message-copy > p:not(.section-kicker):not(.signature) {
    font-size: 14px !important;
    line-height: 1.9 !important;
  }
}

/* ===== ERIKO-ADJUST BLOCK6: 下層ページ共通調整 ===== */
body.lower-page .recommend-grid article {
  font-weight: 500 !important;
}

body.lower-page .reason-card strong {
  font-family: "Playball", Georgia, "Times New Roman", serif !important;
  font-weight: 400 !important;
  font-size: 76px !important;
  line-height: 1 !important;
}

body.mp-v2 .courses {
  padding-top: 4rem;
}

body.mp-v2 .course-card p {
  margin-bottom: 1.5rem;
}

/* 2026-09-29: 旧width:80%(不要な固定幅指定)を削除。margin:4px 28px 28px(左右28px)と
   width:80%が同時指定されていたため過剰制約となり、右margin28pxが無視されてボタンの右端が
   本文(h3/p/chips、いずれも左右margin28pxで自然幅)と揃わなくなっていた。widthを外し
   .buttonの既定display:inline-flex(コンテンツ幅)に戻すことで、28pxの左右余白のみで
   本文と自然に揃う。 */
#record-university > p.section-kicker {
  font-size: 15px;
}

body.page-voice-success .message .photo-portrait {
  background-image: url("img/mp-voice-success-concept.webp") !important;
}

/* ===== 2026-09-23: hero見出し左寄せ + main背景ドットパターン(TOP/下層共通・page-scope無し) ===== */
.hero h1,
.hero-copy .eyebrow,
.hero-copy p.lead {
  text-align: left;
}

/* 2026-09-28: 灯台の光演出(#scrollBallLayer, z-index:0)がmainの不透明背景の背面に隠れていたため、
   mainの背景を疑似要素へ分離しz-index:-1へ。mainはposition:relative;z-index:autoのまま
   (新規スタッキングコンテキストを作らない)なので、main::beforeのz-index:-1はルート側の
   スタッキング順で評価され、main背景 < #scrollBallLayer(z-index:0) < mainの子コンテンツ
   (z-index:auto、DOM順で#scrollBallLayerより後)の3層になる。
   #scrollBallLayer・各section/card/CTAのz-indexやDOM位置は無変更。 */
main::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(circle at 4% 26%, rgba(246, 184, 0, 0.22) 0 1px, transparent 1px) 0 0 / 14px 14px, linear-gradient(180deg, #fff 0%, #fff 42%, #fbfcfb 100%);
}

body .hero {
  background: none;
}

/* ===== 2026-09-27: SP専用表示ユーティリティ。PCでは非表示、SP(max-width:640px)でのみ表示。
   br.sp-only(改行)のほか、p等のSP限定案内文(TOP合格体験談スライダーの操作案内等)にも共通利用。
   display:revertでタグ本来の表示形式(br→inline、p→block等)に戻す。 ===== */
.sp-only {
  display: none;
}

@media (max-width: 640px) {
  .sp-only {
    display: revert;
  }
}

/* ===== 2026-10: atama+ページ 原稿・レイアウト更新(body.page-atama専用。他ページには影響しない) ===== */
/* 3特長・学年別の3カード: PC=3列 / タブレット=2列(余った3枚目は中央) / SP=1列(既存)。
   body.mp-v2 .courses .course-grid は2列固定のため、このページの2セクションだけ上書きする */
@media (min-width: 981px) {
  body.page-atama #atama-features .course-grid,
  body.page-atama #atama-grade-usage .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-atama #atama-features .course-card:last-child,
  body.page-atama #atama-grade-usage .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 本文の行数がカードごとに違っても、学年別カードのボタンが同じ高さ(カード下端)に揃うようにする */
body.page-atama #atama-grade-usage .course-card {
  display: flex;
  flex-direction: column;
}

body.page-atama #atama-grade-usage .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

/* CONCEPT本文は3つの文のまとまり。.message のグリッドは本文エリアが2つ(body/body2)しかなく、
   <p>を3つにすると3つ目が2つ目に重なるため、<p>は2つにして最後のまとまりだけ段落として分ける */
body.page-atama .message-copy .concept-para {
  display: block;
  margin-top: 16px;
}

/* SPのhero: リードが長くなるため、写真下端との間隔を少し広げる(写真と文章が重ならないように) */
@media (max-width: 640px) {
  body.page-atama .hero-copy {
    min-height: 382px;
  }
}

/* atama+ページ: 日本語の折り返し調整。文節単位(auto-phrase)で折り返し、最終行に1〜2文字だけ残るのを防ぐ(pretty)。
   非対応ブラウザでは従来の折り返しにフォールバックする */
body.page-atama .hero .lead,
body.page-atama .message-copy > p,
body.page-atama .course-intro > p,
body.page-atama .course-card > p,
body.page-atama .lower-section .faq-item p {
  word-break: auto-phrase;
  text-wrap: pretty;
}

/* 3列表示になって間もない幅(981〜1180px)では、3枚目の見出し「授業中は講師が学習状況を確認」だけが
   2行になり本文の開始位置がずれるため、3カードの見出しを揃えて少し小さくする。
   さらに狭い981〜1110pxでは18pxでも2行になるため、3カードとも2行分の高さを確保して本文の位置を揃える */
@media (min-width: 981px) and (max-width: 1180px) {
  body.page-atama #atama-features .course-card h3 {
    font-size: 18px;
  }
}

@media (min-width: 981px) and (max-width: 1110px) {
  body.page-atama #atama-features .course-card h3 {
    min-height: 54px;
  }
}

/* SPのhero: 左端のピンクの三角装飾は hero 下端基準(bottom:126px)で置かれるため、リードが長くなると
   リード1行目に重なる。写真の左下(h1の下の空き)に収まるよう、上端基準に切り替える */
@media (max-width: 640px) {
  body.page-atama .hero::after {
    top: 228px;
    bottom: auto !important;
  }
}

/* 見出し内の文節単位の折り返し制御(狭い幅で「学べ/る。」のように1文字だけ残らないようにする) */
body.page-atama .nw {
  white-space: nowrap;
}

/* 特長カードの見出しが2行になるとき、「確/認」のような孤立を避けて均等に折り返す */
body.page-atama #atama-features .course-card h3 {
  text-wrap: balance;
}

/* SPのhero: H1「AI教材 atama+」の「+」が写真の左端に触れていたため、H1を少し小さくし、
   写真の左端を最低でも画面左から約148pxの位置に確保する(430px以上では従来どおり40%位置)。
   PC(641px以上)のheroには影響しない */
@media (max-width: 640px) {
  body.page-atama .hero h1 {
    font-size: 29px !important;
  }

  body.page-atama .hero-visual .jr-hero-photo {
    left: max(40%, 172px);
  }
}

/* ===== 2026-10: Comiruページ リニューアル(body.page-comiru専用。他ページには影響しない) ===== */
/* FEATURESの機能カード(3枚): 学習記録・欠席連絡など未確認機能のカードを外し、お知らせ/緊急連絡/請求の3枚に整理。
   画像は既存のComiru写真を流用(進捗グラフ・予定表の写真は使わない) */
body.page-comiru .mp-comiru-urgent {
  background-image: url("img/mp-comiru-fv.webp");
  background-position: 72% 40%;
}

body.page-comiru .mp-comiru-billing {
  background-image: url("img/mp-comiru-message.webp");
  background-position: center 30%;
}

/* PC=3列 / タブレット=2列(余った3枚目は中央) / SP=1列(既存)。body.mp-v2 .courses .course-grid の2列固定をこのセクションだけ上書き */
@media (min-width: 981px) {
  body.page-comiru #comiru-features .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-comiru #comiru-features .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 日本語の折り返し調整(文節単位+最終行に1〜2文字だけ残るのを防ぐ。非対応ブラウザは従来どおり) */
body.page-comiru .hero .lead,
body.page-comiru .message-copy > p,
body.page-comiru .course-intro > p,
body.page-comiru .course-card > p,
body.page-comiru .lower-section .faq-item p {
  word-break: auto-phrase;
  text-wrap: pretty;
}

/* FAQの質問文: 狭い幅で「か？」「ま/す」のように最終行に数文字だけ残らないよう、行を均等に折り返す */
body.page-comiru .faq-item summary {
  word-break: auto-phrase;
  text-wrap: balance;
}

/* SPのhero: H1「塾専用/アプリ/Comiru」の「Comiru」が写真の左端に触れていたため、H1を少し小さくし、
   写真の左端を最低でも画面左から約148pxの位置に確保する(430px以上は従来どおり40%位置)。
   リードが4行になる幅でも写真と重ならないよう、hero下部の余白を確保する。PC(641px以上)には影響しない */
@media (max-width: 640px) {
  body.page-comiru .hero h1 {
    font-size: 29px !important;
  }

  body.page-comiru .hero-visual .jr-hero-photo {
    left: max(40%, 172px);
  }
}

/* ===== 2026-10: ウイングネットページ リニューアル(body.page-wingnet専用。他ページには影響しない) ===== */
/* 透かし英字は.section-kickerに合わせる(PR-WATERMARK-AUDIT1と同じ方式)。ベーシックウイングのkickerは日本語のため英字表記 */
body.page-wingnet #wn-basic.courses::before {
  content: "BASIC";
}

body.page-wingnet #wn-university.courses::before {
  content: "UNIVERSITY";
}

body.page-wingnet #curriculum.courses::before {
  content: "TIMING";
}

/* HERO: 日本語の折り返し調整(文節単位+最終行の孤立防止。非対応ブラウザは従来どおり)、本文の段落、FAQ質問文 */
body.page-wingnet .hero .lead,
body.page-wingnet .message-copy > p,
body.page-wingnet .course-intro > p,
body.page-wingnet .course-card > p,
body.page-wingnet .recommend-grid article,
body.page-wingnet .lower-section .faq-item p {
  word-break: auto-phrase;
  text-wrap: pretty;
}

body.page-wingnet .faq-item summary {
  word-break: auto-phrase;
  text-wrap: balance;
}

/* ABOUT/SUPPORTの本文は3つのまとまり。.messageのグリッドは本文エリアが2つのため、<p>は2つにして最後のまとまりだけ段落として分ける */
body.page-wingnet .message-copy .concept-para {
  display: block;
  margin-top: 16px;
}

/* 「こんな高校生におすすめです」(4項目): PCは200px×4列で中央寄せ、タブレットは2列、SPは2列の可変幅
   (共通の154px固定だと320pxで右列が見切れるため) */
@media (min-width: 981px) {
  body.page-wingnet .hero + .message + section.recommend .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 200px)) !important;
    justify-content: center !important;
  }
}

@media (max-width: 980px) {
  body.page-wingnet .hero + .message + section.recommend .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
    max-width: 420px;
    margin-inline: auto;
  }

  body.page-wingnet .hero + .message + section.recommend .recommend-grid article {
    width: 100% !important;
    min-width: 0;
    padding-left: 10px !important;
    padding-right: 10px !important;
  }
}

/* ベーシックウイングの特長3項目 / 受験の時期・方式5項目: 見出し+説明の2段構成のカード */
body.page-wingnet #wn-basic .recommend-grid article,
body.page-wingnet #curriculum .recommend-grid article {
  min-height: 0 !important;
  font-size: 13px !important;
  font-weight: 500;
  line-height: 1.7 !important;
}

body.page-wingnet #wn-basic .recommend-grid article strong,
body.page-wingnet #curriculum .recommend-grid article strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.5;
}

body.page-wingnet #wn-basic .recommend-grid,
body.page-wingnet #curriculum .recommend-grid {
  grid-template-columns: repeat(3, minmax(0, 300px));
  justify-content: center;
}

/* 5項目(PCのみ): 300px幅のカードを維持し、1段目3つ・2段目2つのどちらも中央寄せ。
   140px×6列+gap20px(狭い画面では等比で縮む)の各カードを2列分(=300px)にまたがらせ、2段目は2列目・4列目から置く */
@media (min-width: 981px) {
  body.page-wingnet #curriculum .recommend-grid {
    grid-template-columns: repeat(6, minmax(0, 140px));
  }

  body.page-wingnet #curriculum .recommend-grid article {
    grid-column: span 2;
  }

  body.page-wingnet #curriculum .recommend-grid article:nth-child(4) {
    grid-column: 2 / span 2;
  }

  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: 4 / span 2;
  }
}

@media (max-width: 980px) {
  body.page-wingnet #wn-basic .recommend-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  body.page-wingnet #curriculum .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.page-wingnet #curriculum .recommend-grid article,
  body.page-wingnet #curriculum .recommend-grid article:nth-child(4),
  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: auto;
  }

  /* 5項目: 余る5つ目はタブレットで中央に置く */
  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: 1 / -1;
    width: calc(50% - 10px);
    justify-self: center;
  }
}

@media (max-width: 640px) {
  body.page-wingnet #wn-basic .recommend-grid,
  body.page-wingnet #curriculum .recommend-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.page-wingnet #wn-basic .recommend-grid article,
  body.page-wingnet #curriculum .recommend-grid article,
  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: auto;
    width: 100% !important;
    justify-self: stretch;
  }
}

/* 大学受験向けの3ライン: PC=3列 / タブレット=2列(余った3枚目は中央) / SP=1列(既存) */
@media (min-width: 981px) {
  body.page-wingnet #wn-university .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-wingnet #wn-university .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* SPのhero: H1「ウイング/ネット」(2行)が写真と重なっていたため、H1を小さくし、写真の左端を最低でも
   画面左から約148pxの位置に確保する(430px以上は従来どおり40%位置)。PC(641px以上)には影響しない */
@media (max-width: 640px) {
  body.page-wingnet .hero h1 {
    font-size: 29px !important;
  }

  body.page-wingnet .hero-visual .jr-hero-photo {
    left: max(40%, 172px);
  }
}

/* SPのhero: リードが5行になる幅(320px)でも写真との間隔を確保する */
@media (max-width: 640px) {
  body.page-wingnet .hero-copy {
    min-height: 382px;
  }
}

/* コース案内: 中学生・高校生カードのchips追加(国語/速読/全科目・難関国立大まで対応 など)で、PC・タブレットの
   nowrap指定のままだとchipが縮んでタグ内の文字が折り返されるため、折り返し可+タグ内テキストは折り返さない
   (SPと同じ挙動)にする。コース案内ページ(page-cs)のみ。 */
body.page-cs #grade-courses .course-card .chips {
  flex-wrap: wrap;
}

body.page-cs #grade-courses .course-card .chips span {
  white-space: nowrap;
}

/* コース案内のSP hero: 冒頭文が1行増え、hero下端基準(bottom:126px)の左端のピンクの三角がリード1行目に重なるため、
   上端基準に切り替えて写真の左下(H1の下の空き)に収める(atama+・Comiru・ウイングネットと同じ調整)。コース案内ページのみ */
@media (max-width: 640px) {
  body.page-cs .hero::after {
    top: 228px;
    bottom: auto !important;
  }
}

/* ===== 2026-10: コース一覧(page-cs)の最終調整。他ページには影響しない ===== */
/* 学年別3カード: PC=3列均等 / タブレット=2列(余った3枚目は中央) / SP=1列(既存)。
   body.mp-v2 .courses .course-grid の2列固定をこのセクションだけ上書きする */
@media (min-width: 981px) {
  body.page-cs #grade-courses .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-cs #grade-courses .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 説明文・chipsの行数がカードごとに違っても、ボタンが同じ高さ(カード下端)に揃うようにする */
body.page-cs #grade-courses .course-card {
  display: flex;
  flex-direction: column;
}

body.page-cs #grade-courses .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

/* SP: H1「コース/案内」の「コース」が写真の左端に触れていたため、H1を少し小さくする(PC・タブレットには影響しない)。
   共通CTAの見出し「どのコースを選べばいいか」は keep-all で折り返せず、320〜400px台で右が切れていたため、
   このページだけ文節単位で折り返し、幅に合わせて文字サイズを調整する */
@media (max-width: 640px) {
  body.page-cs .hero h1 {
    font-size: 29px !important;
  }

  body.page-cs .hero-visual .jr-hero-photo {
    left: max(40%, 172px);
  }

  body.page-cs .cta-copy h2 {
    font-size: clamp(22px, 7.4vw, 30px);
    word-break: auto-phrase;
    overflow-wrap: anywhere;
  }
}

/* コース案内のSP・タブレット: 共通CTAのボタンが窮屈で、電話番号が「0577-77-/9148」と途中で折れ、
   「体験授業を申し込む」も2行になっていたため、ボタン内の余白・間隔・アイコン・文字サイズを詰めて1行で収める。
   電話番号・リンク先・文言は変更しない。コース案内ページ(page-cs)のみ。 */
@media (max-width: 980px) {
  body.page-cs .cta-actions .phone,
  body.page-cs .cta-actions .form {
    padding-left: 10px;
    padding-right: 10px;
    gap: 6px;
  }

  body.page-cs .cta-actions .phone span,
  body.page-cs .cta-actions .form span {
    white-space: nowrap;
  }

  body.page-cs .cta-actions .phone span {
    margin-right: 0;
  }

  body.page-cs .cta-actions .phone svg {
    width: 18px;
    height: 18px;
  }

  body.page-cs .cta-actions .phone {
    font-size: 17px;
  }

  body.page-cs .cta-actions .form {
    font-size: 15px;
  }
}

/* 小学生コース: 読解・速読カードにもTERRACEへのボタンを追加したため、2列表示(タブレット・PC)で
   説明文の長さが違っても、4枚のカードのボタンが同じ高さ(カード下端)に揃うようにする。小学生ページ(page-pr)のみ。 */
body.page-pr #primary-learning .course-card {
  display: flex;
  flex-direction: column;
}

body.page-pr #primary-learning .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

/* 中学生コース: chips追加(国語/英語/数学)により、タブレット幅でchipが縮んでタグ内の文字が折り返されるため、
   折り返し可+タグ内テキストは折り返さない(SPと同じ挙動)にする。中学生ページ(page-jr)のみ。 */
body.page-jr .jr-overview-card .chips {
  flex-wrap: wrap;
}

body.page-jr .jr-overview-card .chips span {
  white-space: nowrap;
}

/* 個別カスタマイズコースの本文中の「atama+」(公式サイトへの外部テキストリンク)。
   本文と区別できるよう下線を付け、ボタン用の共通スタイル(inline-flex・余白・矢印・太字)は打ち消す */
body.page-jr .course-card .jr-overview-details dd a[href]:not(.button) {
  display: inline;
  margin: 0;
  font-weight: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* カード内リンク共通の「→」矢印は、本文中のリンクには付けない */
body.page-jr .course-card .jr-overview-details dd a[href]:not(.button)::after {
  content: none;
}

/* ===== 2026-10: 高校生コース(page-hs)のICT教材ボタン・関連ページ追加 ===== */
/* ICT教材カード: atama+・ウイングネット・ブロードバンド予備校・速読聴英語への内部ボタン(カード内で折り返して並べる) */
body.page-hs .high-ict-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 4px 28px 0;
  padding-bottom: 28px;
}

body.page-hs .high-ict-links .button.ghost {
  max-width: 100%;
  margin: 0;
  color: var(--green);
  border-color: var(--green);
  white-space: nowrap;
}

body.page-hs .high-ict-links .button.ghost:hover,
body.page-hs .high-ict-links .button.ghost:focus-visible {
  color: #fff;
  background: var(--green);
}

@media (max-width: 640px) {
  body.page-hs .high-ict-links {
    margin-right: 20px;
    margin-left: 20px;
    padding-bottom: 22px;
  }
}

/* chips追加(質問対応)により、タブレット幅でchipが縮んでタグ内の文字が折り返されるため、折り返し可+タグ内テキストは折り返さない
   (SPと同じ挙動)にする。高校生ページ(page-hs)のみ。 */
body.page-hs .course-card .chips {
  flex-wrap: wrap;
}

body.page-hs .course-card .chips span {
  white-space: nowrap;
}

/* 関連ページのカード(6枚): 説明・chipsの行数が違っても、ボタンが同じ高さ(カード下端)に揃い、カード内で横方向中央に来るようにする。高校生ページ(page-hs)のみ。 */
body.page-hs .high-related-pages .course-card {
  display: flex;
  flex-direction: column;
}

body.page-hs .high-related-pages .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

/* 関連ページの説明文は左寄せ(タイトルの配置は変更しない)。文節単位+均等に折り返して、「す。」だけが次行に落ちるのを防ぐ(文字は縮めず1行固定もしない) */
body.page-hs .high-related-pages .course-card > p {
  text-align: left;
  word-break: auto-phrase;
  text-wrap: balance;
}

/* 関連ページに追加した3枚のカード画像。色クラス(.course-card--green等)の画像指定が優先されて他カードと同じ写真になるため、
   より詳細度の高いセレクタで、既存画像(atama+紹介ページ・TERRACE紹介ページ・英語学習の既存画像)を指定する。
   既存のウイングネット・BBY・合格実績のカードは変更しない。高校生ページ(page-hs)のみ。 */
body.page-hs .high-related-pages .course-card .course-image.high-related-atama {
  background-image: url("img/mp-atama-hero.webp");
  background-position: center 30%;
}

body.page-hs .high-related-pages .course-card .course-image.high-related-terrace-read {
  background-image: url("img/mp-terrace-reading-v2.webp");
  background-position: center 30%;
}

body.page-hs .high-related-pages .course-card .course-image.high-related-terrace-eigo {
  background-image: url("img/mp-pr-english.jpg");
  background-position: center 30%;
}

/* ===== 2026-10: PCヘッダーのロゴ拡大(256px→2026-10-17に210pxへ縮小)とナビへの「ブログ」追加に伴う調整(共通ヘッダー・全ページ) ===== */
/* ロゴはPC(981px以上)のみ。SP・タブレット(980px以下)は従来のサイズ(156px / 640px以下は118px)のまま。
   フッターのロゴ(.footer-info .brand img)は対象外(.site-header内のみ)。 */
@media (min-width: 981px) {
  .site-header .brand img {
    width: 210px;
  }
}

/* PCの幅が狭い範囲(981〜1279px)では、ロゴ+ナビ6項目+体験ボタンが1行に収まらず、ナビと干渉・横スクロールが出るため、
   ロゴを幅に応じて 180px → 210px に段階的に拡大し、ヘッダーの左右余白とナビの間隔を少し詰める。
   1280px以上は、ロゴ210pxでナビ・ボタンとも余裕をもって収まる。 */
@media (min-width: 981px) and (max-width: 1279px) {
  .site-header {
    gap: 20px;
    padding-right: 3vw;
    padding-left: 3vw;
  }

  .site-header .brand img {
    width: calc(180px + (100vw - 981px) * 0.1);
  }

  .site-header .desktop-nav {
    gap: 10px;
  }
}

/* 2026-10-18: ブログのボタン化でナビが約65px広がったため、981〜1099pxはナビ項目の間隔を10pxに詰め、1100px以上は従来の14pxに戻す */
@media (min-width: 1100px) and (max-width: 1279px) {
  .site-header .desktop-nav {
    gap: 14px;
  }
}

/* 2026-10-18: ブログボタンを体験授業ボタンと同じ高さ・余白(48px / 左右24px)にしたため、ビューポート981〜1012px(スクロールバー込み)だけ、
   ヘッダーの左右余白とナビの間隔をさらに詰めて、体験授業ボタンが右端にはみ出さないようにする */
@media (min-width: 981px) and (max-width: 1012px) {
  .site-header {
    gap: 14px;
    padding-right: 20px;
    padding-left: 20px;
  }

  .site-header .desktop-nav {
    gap: 8px;
  }
}

/* 高校生ページの関連ページ: 「ブロードバンド予備校詳細」が320pxで「ブロードバンド予備校/詳細」と2文字だけ次行に落ちるのを防ぐ */
body.page-hs .high-related-pages .course-card h3 {
  word-break: auto-phrase;
  text-wrap: balance;
}

/* 320px前後では「ブロードバンド予備校詳細」(12文字)が幅に数px足りず「詳細」が次行に落ちるため、タイトルを2pxだけ小さくして1行に収める */
@media (max-width: 360px) {
  body.page-hs .high-related-pages .course-card h3 {
    font-size: 18px;
  }
}

/* ===== 2026-10: 動画の小見出し(TOP・塾紹介ページ)。動画の真上に置く小さめのアクセント見出し。
   メインのH2より目立たせず、見出し階層(h1〜h3)には加えないため<p>で実装。 ===== */
.portrait-wrap > .video-subhead {
  display: block;
  margin: 0 0 12px;
  color: var(--green);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: 0.04em;
  text-align: center;
}

@media (max-width: 640px) {
  .portrait-wrap > .video-subhead {
    margin-bottom: 10px;
    font-size: 13px;
    letter-spacing: 0.02em;
  }
}

/* 塾紹介ページのSP: 動画の上に小見出しを置いたため、.portrait-wrapの上マージン(-38px。従来は動画をH2の余白に重ねていた)を
   0にして、小見出しがH2の2行目に重ならないようにする。 */
@media (max-width: 640px) {
  body.page-about-index .message--video .portrait-wrap {
    margin-top: 0 !important;
  }
}

/* TOPは本文<p>の色・太さを !important で一括指定しているため、動画の小見出しだけ上書きする(TOPの.portrait-wrap内の小見出しのみ) */
body:not(.lower-page) .message#about .portrait-wrap > p.video-subhead {
  color: var(--green) !important;
  font-weight: 800 !important;
}

/* 2026-10-17: TOP「MESSAGE」ウォーターマーク(.message-copy.fade-up::before)が981〜1210px前後で
   ビューポート右端をはみ出し横スクロールになる不具合の修正(TOP限定)。
   透かし文字の左端はグリッド列に依存するため、右端が画面内に収まるようフォントサイズを幅に追従させる。
   1272px以上は従来どおり124px。overflow-x: hiddenでの一括隠しは行わない。 */
@media (min-width: 981px) and (max-width: 1271px) {
  body:not(.lower-page) .message-copy.fade-up::before {
    font-size: min(124px, calc(10.3vw - 7px));
  }
}

/* 2026-10-17: 体験談ページ(success)の「ひだっちブログで体験談の詳細を見る」ボタンが、
   .button の white-space: nowrap のためSP幅(320px等)でカード右へはみ出す不具合の修正。
   カード幅を超える場合のみ折り返し、ボタンはカード内に収める。 */
body.page-voice-success .voice-story a.button {
  max-width: 100%;
  white-space: normal;
  text-align: center;
  line-height: 1.5;
  padding-block: 8px;
  height: auto;
  min-height: 0;
}

/* 2026-10-17: 講師紹介ページ(about/teacher.html)のHEROを教室写真に差し替え。
   .mp-teacher-fv は about/index.html(塾紹介ページ)の講師画像と共通のため、共通ルールは変更せず、
   body.page-about-teacher 限定の上書きで指定する。元画像: assets/Image_20241112_195429_410.jpeg(1600×1200へ縮小のみ・トリミングなし) */
body.page-about-teacher .hero-visual .mp-teacher-fv,
body.page-about-teacher .hero-visual .mp-teacher-fv::before {
  background-image: url("img/mp-teacher-classroom.webp");
  background-position: center 55%;
}

/* 2026-10-17: SPハンバーガーメニュー(.mobile-nav)の最下部にロゴを追加(全ページ共通)。
   ロゴは既存の logo02.png。タップでTOPへ。メニュー項目・開閉の既存動作は変更しない。
   縦に収まらない小さい画面(横向き・低い端末)では、メニュー内でスクロールできるようにする
   (justify-content: safe center で、はみ出す場合は上端から並べて先頭項目が切れないようにする)。 */
.mobile-nav {
  justify-content: safe center;
  padding: 64px 0 24px; /* 先頭項目が右上の閉じるボタンの下に潜らないよう、上に余白を確保 */
  overflow-y: auto;
  overscroll-behavior: contain;
}

body:not(.lower-page) .mobile-nav {
  overflow-x: hidden;
  overflow-y: auto;
}

.mobile-nav-logo {
  display: block;
  flex: 0 0 auto;
  margin-top: 8px;
  padding: 6px 10px;
  line-height: 0;
}

.mobile-nav-logo img {
  display: block;
  width: 170px;
  height: auto;
}


/* ===== 2026-10-17: サポート校ページ(support-school/index.html)専用 ===== */
/* ページ固有CSSはすべて body.page-support-school に限定(他ページ・TOPには影響しない)。
   共通のHERO/カード/FAQ/CTAは既存ルールを再利用し、ここでは差分のみ指定する。 */

/* HERO写真: 既存の教室ラウンジ写真(myport_classroom_lounge.jpeg)を1600×1200に縮小した軽量版 */
body.page-support-school .hero-visual .mp-support-fv,
body.page-support-school .hero-visual .mp-support-fv::before {
  background-image: url("img/mp-support-fv.webp");
  background-position: center 50%;
}

/* HEROの旧FV文字(画像に焼き込まれていた文言)をHTMLテキスト化したもの。1行目のキャッチは緑の太字 */
body.page-support-school .support-hero-tagline {
  color: var(--green);
  font-weight: 800;
}

body.page-support-school .support-hero-badge {
  display: inline-block;
  align-self: flex-start;
  margin: 0 0 10px;
  padding: 8px 18px;
  border: 1px solid rgba(91, 149, 90, 0.45);
  border-radius: 999px;
  background: #fff;
  color: var(--green);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
}

/* SP: バッジは長いため、既存FVの写真(右40%〜)にかからないようH1と同じ幅(52%)で折り返す */
@media (max-width: 640px) {
  body.page-support-school .support-hero-badge {
    max-width: 52%;
    padding: 6px 12px;
    border-radius: 18px;
    font-size: 11.5px;
  }

  /* H1("マイポート／高山学院／サポート校"の3行)は2.2remで大きく表示する(共通の body.mp-v2 .hero h1 { font-size: 34px !important } を上書き)。
     写真は既存のコース系FVの位置・大きさのままで、H1と一部重なるため、文字の可読性を白い縁取りで確保する */
  body.page-support-school .hero h1 {
    font-size: 2.2rem !important;
    text-shadow: 0 0 6px #fff, 0 0 10px #fff, 0 0 14px #fff;
  }

  body.page-support-school .support-hero-tagline {
    font-size: min(18px, 5.2vw); /* 18px。320pxでも1行に収まるよう画面幅で上限 */
  }
}

/* 入校相談の案内(旧: 2025年度バナー) */
body.page-support-school .support-consult {
  margin-top: clamp(24px, 4vw, 48px);
  padding-top: clamp(28px, 4vw, 44px);
  padding-bottom: clamp(28px, 4vw, 44px);
  max-width: 920px;
  border-radius: 28px;
  background: linear-gradient(135deg, #f3f9ef 0%, #fbfaf3 100%);
  border: 1px solid rgba(91, 149, 90, 0.22);
  box-shadow: 0 14px 34px rgba(31, 63, 54, 0.08);
}

body.page-support-school .support-consult .extra-head {
  max-width: 720px;
  margin-bottom: 24px;
}

body.page-support-school .support-consult .extra-head .section-kicker {
  display: inline-block;
  margin-bottom: 12px;
  padding: 3px 14px;
  border-radius: 999px;
  background: var(--yellow, #f4b400);
  color: #333;
  font-size: 13px;
  letter-spacing: 0.08em;
}

body.page-support-school .support-school-name {
  margin: 0 0 10px;
  color: #333;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.6;
}

body.page-support-school .support-school-name strong {
  display: block;
  margin-top: 2px;
  font-size: clamp(20px, 2.4vw, 26px);
  color: var(--green);
}

body.page-support-school .support-consult .extra-head h2 {
  margin: 0 0 14px;
  font-size: clamp(26px, 3.4vw, 38px);
  text-wrap: balance;
}

body.page-support-school .support-consult .extra-head p:not(.section-kicker):not(.support-school-name) {
  margin: 0;
  color: #333;
  font-size: 15px;
  line-height: 1.9;
  text-align: left;
}

body.page-support-school .support-consult-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

body.page-support-school .support-consult-actions .button {
  min-width: 240px;
  justify-content: center;
}

/* 特徴カード3枚の写真(既存の講師ページ用写真・高校生ページ写真を使用。縮小版) */
body.page-support-school .support-card-heart {
  background-image: url("img/mp-support-heart.jpg");
}

body.page-support-school .support-card-study {
  background-image: url("img/mp-support-study.jpg");
}

body.page-support-school .support-card-advance {
  background-image: url("img/mp-hs-exam.jpg");
}

/* 特徴カード: PC=3列 / タブレット=2列(余った3枚目は中央) / SP=1列(コミルページと同じ方針) */
@media (min-width: 981px) {
  body.page-support-school .support-features .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-support-school .support-features .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 各セクション末尾の補足段落 */
body.page-support-school .support-section-note {
  max-width: 820px;
  margin: 32px auto 0;
  color: #333;
  font-size: 15px;
  line-height: 2;
  text-align: left;
}

/* 学びの環境: 写真なしの2カード(中央寄せで2列) */
body.page-support-school .support-environment .course-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 820px;
  margin-inline: auto;
}

@media (max-width: 700px) {
  body.page-support-school .support-environment .course-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  body.page-support-school .support-consult-actions .button {
    width: 100%;
    min-width: 0;
  }
}

/* イベント紹介 */
body.page-support-school .support-events-copy {
  margin: 0 auto;
  max-width: 720px;
  color: #333;
  font-size: clamp(16px, 1.8vw, 19px);
  font-weight: 700;
  line-height: 2;
  text-align: center;
}

/* 親御さんへのメッセージ(段落が2つ) */
body.page-support-school .message-copy > p:not(.section-kicker) {
  color: #333;
  line-height: 2;
}

/* ご案内の4STEP(旧: STEPバッジ付きの1文)。入塾フローと同じタイムライン装飾 */
body.page-support-school .system-steps {
  list-style: none;
  counter-reset: mp-support-step;
  margin: 24px auto 0;
  padding: 0;
  max-width: 680px;
}

body.page-support-school .system-steps li {
  counter-increment: mp-support-step;
  position: relative;
  display: flex;
  flex-direction: column-reverse;
  justify-content: center;
  min-height: 48px;
  padding: 2px 0 30px 74px;
}

body.page-support-school .system-steps li:last-child {
  padding-bottom: 0;
}

body.page-support-school .system-steps li::before {
  content: counter(mp-support-step);
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 6px 16px rgba(91, 149, 90, 0.28);
}

body.page-support-school .system-steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 23px;
  top: 54px;
  bottom: 2px;
  width: 2px;
  background: var(--green-soft);
}

body.page-support-school .system-steps li h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.5;
  color: #333;
}

body.page-support-school .system-steps li small {
  display: block;
  margin: 0 0 4px;
  font-family: "Quicksand", "Nunito Sans", sans-serif;
  color: var(--green);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
}

/* アクセス(TOPのアクセス部品を、このページ限定で下層ページにも適用) */
body.page-support-school .access-section {
  position: relative;
  padding: clamp(40px, 5vw, 64px) clamp(22px, 5vw, 56px);
  background: #fbfaf3;
  scroll-margin-top: 88px;
}

body.page-support-school .access-info > .extra-head {
  max-width: none;
  margin: 0 0 20px;
  text-align: left;
}

body.page-support-school .access-info > .extra-head .section-kicker {
  margin: 0 0 8px;
}

body.page-support-school .access-section .extra-head h2 {
  margin: 0;
  font-size: clamp(22px, 2.4vw, 32px);
}

body.page-support-school .access-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.62fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 68px);
  align-items: center;
  max-width: 1140px;
  margin: 0 auto;
}

body.page-support-school .access-info-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

body.page-support-school .access-info-list li {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 6px 0;
  color: #333;
  font-size: 15px;
  line-height: 1.75;
}

body.page-support-school .access-info-list svg {
  width: 22px;
  height: 22px;
  margin: 0 auto;
  color: var(--green);
}

body.page-support-school .access-map-wrap {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(91, 149, 90, 0.18);
  border-radius: 22px;
  box-shadow: 0 14px 34px rgba(31, 63, 54, 0.1);
}

body.page-support-school .access-map-img {
  display: block;
  width: 100%;
  height: auto;
}

body.page-support-school .access-map-logo {
  position: absolute;
  top: 51%;
  left: 31.5%;
  width: 16%;
  height: auto;
  pointer-events: none;
}

/* 2026-09-27: ユーザー指定、PC限定でロゴ位置を微調整。SPはbaseの51%/31.5%を維持。 */
@media (min-width: 641px) {
  body.page-support-school .access-map-logo {
    top: 42%;
    left: 32.5%;
  }
}

/* 2026-09-27: 静的マップ画像の下に「Googleマップで見る」外部リンクを追加(ユーザー指定) */
body.page-support-school .access-map-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  color: var(--green);
  border-top: 1px solid rgba(91, 149, 90, 0.18);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background-color 0.2s ease;
}

body.page-support-school .access-map-link:hover,
body.page-support-school .access-map-link:focus-visible {
  background: rgba(91, 149, 90, 0.08);
}

@media (max-width: 700px) {
  body.page-support-school .access-section {
    padding-block: 40px;
    scroll-margin-top: 72px;
  }

  body.page-support-school .access-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  body.page-support-school .access-map-wrap {
    border-radius: 16px;
  }

  /* 2026-09-27: 旧SP専用値(top:37.5%/left:32.5%)は地図画像の吹き出し枠から
     大きく上にズレていた(ピクセル解析で確認: 枠の中心はtop約58.6%/left約40%)。
     image は width:100%;height:auto で比率固定のため、PC/SPで別値にする理由がなく、
     base の top:51%/left:31.5%(吹き出し枠にほぼ一致)へ統一しSP専用上書きを撤去。 */
}

body.page-support-school .access-info-list a {
  color: inherit;
  text-decoration: underline;
}

/* FAQ: 質問番号(Q1〜Q7) */
body.page-support-school .faq-item summary span {
  min-width: 2.2em;
}

/* 見出しの折り返し(最終行に「のご案内」だけ等が残らないよう均等に) */
body.page-support-school #support-steps .extra-head h2 {
  text-wrap: balance;
}


/* ===== 2026-10-18: 「ブログ」導線をボタン化(全ページ共通ヘッダー・SPメニュー) ===== */
/* 見た目はTOPの「マイポートを知る」(.button.ghost: 白背景・緑の1px枠・緑文字・ピル型)と同じ配色。
   PCヘッダーに収まるよう高さ・余白だけ小さくする。リンク先・別タブ指定は従来のまま。 */
.site-header .desktop-nav {
  align-items: center;
}

.site-header .desktop-nav a.nav-blog:hover,
.site-header .desktop-nav a.nav-blog:focus-visible {
  color: #fff;
  background: #95bf96;
}

/* SPメニュー: 他のメニュー項目(区切り線つきリスト)とは別に、体験授業ボタンの上へ中央配置 */
html body .mobile-nav a.mobile-nav-blog,
html body .mobile-nav a.mobile-nav-cta {
  box-sizing: border-box;
  flex: 0 0 auto;
  justify-content: center;
  width: 240px;
  max-width: calc(100% - 48px);
  min-height: 56px;
  padding: 0 20px;
  font-size: 16px;
  font-weight: 800;
}

html body .mobile-nav a.mobile-nav-blog {
  margin-bottom: -14px;
}

/* ===== 2026-10-18: サポート校ページ(body.page-support-school)の画面確認後の修正 ===== */
/* 「2025年度」バッジ: 左の黄色いダッシュ装飾を消し、文字を白に */
body.page-support-school .support-consult .extra-head .section-kicker {
  color: #fff;
}

body.page-support-school .support-consult .extra-head .section-kicker::before {
  content: none;
}

/* 「どんな生徒が通っている？」のカード: PC=カード幅(約198px)を保ったまま4枚を中央に。SP=2列を中央に(320pxでも画面内に収める) */
body.page-support-school #support-students .recommend-grid {
  justify-content: center;
}

@media (min-width: 981px) {
  body.page-support-school #support-students .recommend-grid {
    grid-template-columns: repeat(4, minmax(0, 198px));
  }
}

@media (max-width: 640px) {
  body.page-support-school #support-students .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 154px));
  }
}

/* 学びの環境の2カードの写真(既存の別ページ素材): 安心の通学コース=先生と生徒の個別相談 / スタンダード・サポートコース=教室での学習風景 */
body.page-support-school .support-card-flexible {
  background-image: url("img/mp-hs-suisen.jpg");
}

body.page-support-school .support-card-standard {
  background-image: url("img/mp-course-fv.jpg");
}

/* 英字の透かし(他の下層ページの .courses::before と同じ書式)。文字列が短いので1行・SPは画面幅に追従 */
body.page-support-school .support-events::before,
body.page-support-school .message-copy::before {
  position: absolute;
  left: 0;
  top: -0.2em; /* 見出しが透かしの中ほどに来る位置(本文との重なりを減らす) */
  z-index: -1;
  color: rgba(7, 24, 51, 0.035);
  font-family: Georgia, serif;
  font-size: clamp(96px, 15vw, 190px);
  line-height: 1.1;
  white-space: nowrap;
  pointer-events: none;
}

body.page-support-school .support-events::before {
  content: "EVENT";
  right: 0;
  text-align: center; /* 見出しが中央揃えのため、透かしも中央に */
  font-size: min(clamp(96px, 15vw, 150px), calc((100vw - 48px) / 3.5));
}

body.page-support-school .message-copy::before {
  content: "MESSAGE";
  font-size: min(clamp(96px, 15vw, 130px), calc((100vw - 48px) / 4.9));
}

/* SP: 入校相談の案内カードを画面端から離し、見出し・本文が端に接しないようにする(HEROは既存のコース系FVの挙動に任せる) */
@media (max-width: 640px) {
  body.page-support-school .support-consult {
    margin-inline: 14px;
    padding-inline: 18px;
  }

  body.page-support-school .support-consult .extra-head h2 {
    font-size: 24px;
    line-height: 1.4;
  }
}

/* SPのアクセスマップ(TOP・サポート校共通): ロゴの位置はマップ枠(画像+「Googleマップで見る」リンク)の高さ基準のため、SPで画像より下にずれて見えた。
   吹き出しの中心(元画像の座標で横40.7%・縦約56.1%。吹き出しの枠線をピクセル解析して算出)に、画像の幅から計算した位置で合わせる。PC(701px以上)は既存のまま。 */
@media (max-width: 700px) {
  body.page-support-school .access-map-logo,
  body:not(.lower-page) .access-map-logo {
    top: calc((100vw - 2 * clamp(22px, 5vw, 56px)) * 0.2306);
    left: 40.7%;
    transform: translate(-50%, -50%);
  }
}

/* ===== 2026-10-19: ナビのプルダウン(「マイポートについて」「コース案内」。全ページ共通ヘッダー・SPメニュー) ===== */
/* PC: 親項目は従来どおり一覧ページへのリンク。ホバー/フォーカスで白いパネルを表示(緑の上線がアクセント) */
.desktop-nav .nav-item {
  position: relative;
  display: flex;
  align-items: center;
}

/* 矢印(▾)は項目の右の隙間に重ねて描き、ナビの幅(=ヘッダーの収まり)を変えない */
.desktop-nav .has-dropdown > a {
  position: relative;
}

.desktop-nav .has-dropdown > a::after {
  content: "";
  position: absolute;
  top: 50%;
  left: calc(100% + 6px);
  width: 4px;
  height: 4px;
  margin-top: -4px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.55;
}

/* 項目の間隔が10px以下になる狭いPC幅(〜1099px)では、矢印が隣の項目に触れるため非表示にする(プルダウン自体は動作する) */
@media (max-width: 1099px) {
  .desktop-nav .has-dropdown > a::after {
    display: none;
  }
}

.site-header .desktop-nav .nav-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  z-index: 30;
  min-width: 190px;
  margin: 0;
  padding: 8px;
  list-style: none;
  background: #fff;
  border: 1px solid rgba(91, 149, 90, 0.22);
  border-top: 3px solid var(--green);
  border-radius: 0 0 14px 14px;
  box-shadow: 0 16px 36px rgba(31, 63, 54, 0.14);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 6px);
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0s linear 0.16s;
}

/* 親項目とパネルの隙間を埋め、マウスを動かす途中で閉じないようにする */
.site-header .desktop-nav .nav-dropdown::before {
  content: "";
  position: absolute;
  top: -15px;
  right: 0;
  left: 0;
  height: 15px;
}

.site-header .desktop-nav .has-dropdown.is-open > .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  transition-delay: 0s;
}

.site-header .desktop-nav .has-dropdown.is-dismissed > .nav-dropdown {
  visibility: hidden;
  opacity: 0;
}

/* 各リンクの下に薄い区切り線(最後の項目を除く) */
.site-header .desktop-nav .nav-dropdown li + li {
  border-top: 1px solid rgba(91, 149, 90, 0.18);
}

.site-header .desktop-nav .nav-dropdown a {
  display: block;
  padding: 10px 14px;
  border-radius: 8px;
  color: #333;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
}

.site-header .desktop-nav .nav-dropdown a:hover,
.site-header .desktop-nav .nav-dropdown a:focus-visible {
  background: #f3f9ef;
  color: #315f35;
}

.site-header .desktop-nav .nav-dropdown a:focus-visible,
.desktop-nav .has-dropdown > a:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

/* SP: 親リンクと開閉ボタンを分け、子項目はインデント+緑の縦線で表示。開くと矢印が上向きになる */
.mobile-nav-group {
  border-bottom: 1px solid rgba(100, 112, 132, 0.15);
}

.mobile-nav-group-head {
  display: flex;
  align-items: stretch;
}

html body .mobile-nav .mobile-nav-group-head > .mobile-nav-link {
  flex: 1 1 auto;
  width: auto;
  border-bottom: 0;
}

.mobile-nav-group-head > .mobile-nav-link::after {
  content: none;
}

.mobile-nav-toggle {
  position: relative;
  flex: 0 0 56px;
  min-height: 52px;
  padding: 0;
  background: none;
  border: 0;
  border-left: 1px solid rgba(100, 112, 132, 0.15);
  color: var(--green);
  cursor: pointer;
}

.mobile-nav-toggle::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translate(-50%, -70%) rotate(45deg);
  transition: transform 0.2s ease;
}

.mobile-nav-toggle[aria-expanded="true"]::before {
  transform: translate(-50%, -30%) rotate(-135deg);
}

.mobile-nav-sub {
  margin: 0 0 12px 8px;
  padding: 2px 0 2px 12px;
  list-style: none;
  border-left: 3px solid var(--green);
}

.mobile-nav-sub[hidden] {
  display: none;
}

html body .mobile-nav .mobile-nav-sub .mobile-nav-link {
  min-height: 46px;
  padding: 10px 6px;
  border-bottom: 0;
  font-size: 15px;
}


/* ===== 2026-10-21: 全体目視チェックを受けた共通修正 ===== */
/* 3-5/8-3/10-4/11-3: 下層ページのメッセージ部の英字ラベル(CONCEPT・ABOUT・MESSAGE・MY PORT SUPPORTなど)を緑に統一。
   原因は .message-copy p { color: var(--muted) } が .section-kicker の緑より詳細度で勝っていたこと。--muted自体は変更しない */
body.mp-v2 .message-copy .section-kicker {
  color: var(--green);
}

/* 3-4: 「料金(税込)」「月額(税込)」の(税込)だけ小さく表示 */
body.mp-v2 .tax {
  font-size: 0.62em;
  font-weight: inherit;
}

/* 4-1/4-3: マイポートについて「各ページへ」カード: 講師紹介=現在の講師ページFV画像、育脳=育脳のFV画像 */
body.page-about-index #about-nav .about-nav-fv-teacher {
  background-image: url("img/mp-teacher-classroom-card.jpg?v=2");
  background-position: center;
}

body.page-about-index #course-nav .about-nav-fv-ikunou {
  background-image: url("img/mp-jr-ikunou.jpg");
  background-position: center;
}

/* 5-2: 中学生ページの「詳細・料金を見る」を、並ぶ「atama+を見る」等(.button.ghost.small)と同じ寸法に */
body.mp-v2 .course-card .jr-overview-links a.jr-overview-price-link[href]:not(.button) {
  min-width: 0;
  min-height: 40px;
  padding: 0 18px;
  border-width: 1px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
  gap: 8px;
}

body.mp-v2 .course-card .jr-overview-links a.jr-overview-price-link[href]:not(.button)::after {
  margin-left: 6px;
}

/* 8-1: BBY「学年別の特長」・TERRACE「他コースとの組み合わせ」の3枚カードを、Comiru・atama+と同じ「PC=3列/タブレット=2列(3枚目は中央)」に */
@media (min-width: 981px) {
  body.page-bby #grade-features .course-grid,
  body.page-tr #terrace-combination .course-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 641px) and (max-width: 980px) {
  body.page-bby #grade-features .course-card:last-child,
  body.page-tr #terrace-combination .course-card:last-child {
    grid-column: 1 / -1;
    width: calc(50% - 12px);
    justify-self: center;
  }
}

/* 9-1: TERRACE 3講座カードの「詳しく見る」はページ内リンクなので下向き矢印 */
body.page-tr #terrace-courses .course-card .button[href^="#"]::after {
  content: "↓";
}

/* 9-3: TERRACE「こんな方におすすめ」(.faq-itemを流用)で、上の罫線と1行目の文字が重なっていたため上に余白 */
body.page-tr .terrace-course-detail .faq-item > p {
  padding-top: 22px;
  margin-bottom: 8px;
}

/* 「こんな方におすすめ」: 中央見出し→薄い区切り線→本文→右寄せの公式リンク(区切り線の内側)。間隔は詰めすぎず広すぎず */
body.page-tr .terrace-course-detail .faq-item > .official-link {
  padding: 0 0 16px;
}

body.page-tr .terrace-course-detail .faq-item > .official-link a {
  text-wrap: balance;
}

/* 3講座カード: H3の下(説明文との間)に余白 */
body.page-tr #terrace-courses .course-card h3 {
  margin-bottom: 10px;
}

/* 12-2: atama+「学年別の活用」: 塾の各コースでの対応内容(タグ)を、atama+の機能と区別するための見出し */
body.page-atama .course-card .chips {
  flex-wrap: wrap;
}

body.page-atama .chips-label {
  margin: 14px 28px 6px;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

body.page-atama .chips-label + .chips {
  margin-top: 0;
}

/* 13-1/13-2: 合格実績の注記・学校名タグの文字色(--muted / #536072 → #333)。--mutedそのものは変更しない */
body.page-record-index .note,
body.page-record-index .extra-head p:not(.section-kicker),
body.page-record-index .school-tags span {
  color: #333;
}

/* 14-1: 合格体験談のH2を、他の下層ページのH2(32px/600)に揃える */
body.page-voice-success .results-voice h2 {
  font-size: 32px;
  font-weight: 600;
}

@media (max-width: 640px) {
  body.page-voice-success .results-voice h2 {
    font-size: 28px;
  }
}

/* 14-3: 体験談カード内のキャッチコピー・H3・氏名・ボタンを中央揃え(本文は左揃えのまま) */
body.page-voice-success .voice-card .voice-headline {
  align-self: stretch;
  width: 100%;
  align-items: center;
  text-align: center;
}

body.page-voice-success .voice-card small {
  align-self: stretch;
  width: 100%;
  text-align: center;
}

body.page-voice-success .voice-story .button.ghost {
  align-self: center;
  margin-top: auto;
}

/* ===== 2026-10-21: 追加目視チェック対応 ===== */
/* 2 中学生: カード内ボタンは縦並び・同幅・中央。.course-card .button.ghost の margin(4px 28px 28px)を打ち消す
   (カード下の余白は .jr-overview-links の padding-bottom に一本化) */
body.mp-v2 .course-card .jr-overview-links > a[href] {
  width: 100%;
  max-width: 220px;
  height: auto;
  margin: 0;
  padding-top: 6px;
  padding-bottom: 6px;
  white-space: normal;
  text-align: center;
  word-break: auto-phrase;
  text-wrap: balance;
}

/* 5 Comiru: 縮小済みWebPを<img>で表示(背景画像の大幅縮小より鮮明)。元画像 img/mp-comiru-notice.png は保存 */
body.page-cm .mp-comiru-notice img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* 3 ICT 3列イラストカード(TERRACE 3講座・ウイングネット): 文字量でカード高さがばらつかないよう、
   行内の高さを揃え、PCでは最低高さを共通化 */
body.page-tr .terrace-course-detail .recommend-grid,
body.page-wingnet #wn-basic .recommend-grid,
body.page-wingnet #curriculum .recommend-grid {
  grid-auto-rows: 1fr;
}

@media (min-width: 981px) {
  body.page-wingnet #wn-basic .recommend-grid article,
  body.page-wingnet #curriculum .recommend-grid article {
    min-height: 208px !important;
  }
}

/* 3 TERRACE「他コースとの組み合わせ」: 説明・chipsの行数がカードごとに違っても、ボタンが同じ高さ(カード下端)に揃うようにする
   (横方向の中央揃えは .course-card .button.ghost の共通ルール) */
body.page-tr #terrace-combination .course-card {
  display: flex;
  flex-direction: column;
}

body.page-tr #terrace-combination .course-card .button.ghost {
  margin-top: auto;
  align-self: center;
}

/* 3 TERRACE/atama+: 「こんな方におすすめ」等の下の公式サイトリンクは、下の区切り線の内側に右寄せ */
body.mp-v2 .faq-item > .official-link {
  margin: 0;
  padding: 4px 0 18px;
  text-align: right;
}

/* 4 ウイングネット: 英字小見出しのないカードのH3下に余白(他ページは小見出しの下余白16px) */
body.page-wingnet #wn-university .course-card h3 {
  margin-bottom: 16px;
}

/* 7 合格実績: 「合格者の体験談を見る」を中央に */
body.page-record-index #record-university > .button {
  display: flex;
  width: fit-content;
  margin-right: auto;
  margin-left: auto;
}

/* 1-3 TOP「コース案内」: タグ数が増えたため折り返しを許可(既定の nowrap だと縦に潰れる) */
body:not(.lower-page) .course-card .chips {
  flex-wrap: wrap;
}

body:not(.lower-page) .course-card .chips span {
  white-space: nowrap;
}

/* (2026-10-28: 公式サイトへの外部リンクの緑は、上の共通ルール body.mp-v2 .official-link a に統合。BBY・TERRACE・Wingnet・Comiru・atama+ すべて同じ) */

/* 2026-10-21: TOP「合格体験記を探す」エリアの装飾を外す。
   外すもの: ①.admission-index(探すエリア全体)の背景・枠線・影 ②.voice(スライダーを囲む外枠)の背景・枠線・影
   ③スライダー内カードの影(スライダーのoverflowで切れて四角い影の枠に見えていたため全削除)、④前へ/次へボタンの影。
   残すもの: カード自体の白背景・上辺の色付きライン・角丸、前へ/次へボタン(枠線)、ドット、一覧の丸写真と↓ */
body:not(.lower-page) .results-voice.top-voice-restored:not(.results-voice--stacked) .admission-index,
body:not(.lower-page) .results-voice.top-voice-restored:not(.results-voice--stacked) .voice {
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
}

body:not(.lower-page) .results-voice.top-voice-restored .top-voice-card {
  box-shadow: none;
}

/* 前へ/次へボタン: 影を削除(ボタン自体・枠線は維持) */
body:not(.lower-page) .results-voice.top-voice-restored .voice-slider-outer .voice-control {
  box-shadow: none;
}

/* 体験談一覧「体験談カテゴリ」(reason-card)のカード内リンクボタンも、他のカード内リンクボタンと同じく中央に */
body.page-voice-index .reason-card .button.ghost {
  display: flex;
  width: fit-content;
  margin-right: auto;
  margin-left: auto;
}

/* 320px前後: .recommend-grid の共通指定が「154px×2列+gap」の固定幅(328px)で、表示領域(約280px)を超えて右の列が切れていた
   (BBY・育脳・TERRACE・about 5ページ・高校生・小学生・サポート校)。359px以下だけ全ての下層ページで1列・全幅にする。
   360px以上(390pxやPC)は変更なし。TOPは対象外(body.lower-page のみ)。
   中学生(body.page-jr.recommend-six)とウイングネットは、既に320pxで2列の可変幅に対応済みで、より詳細度の高い個別指定が優先されるため従来どおり。 */
@media (max-width: 359px) {
  body.lower-page .recommend-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.lower-page .recommend-grid article {
    width: 100% !important;
    min-height: 0 !important;
  }
}

/* 2026-10-24: TOPのFV画像のSP表示(ユーザー手調整の値)。SPでは画像ボックス(幅320px)の右端が画面の外へ103pxはみ出す配置。
   ボックス幅-43px の縦横比のままの大きさで、左へ18px・上へ23px ずらして女子生徒を大きく見せる(ボックスの位置・大きさは変更しない)。
   PC(641px以上)の画像サイズ・位置には影響しない */
@media (max-width: 640px) {
  body:not(.lower-page) .photo-hero {
    background-size: calc(100% - 43px) auto !important;
    background-position: -18px -23px !important;
  }
}

/* 2026-10-24: TOP「合格体験記」スライダーのPCマウスドラッグ(index.html の既存JSに追加)。通常時 grab、ドラッグ中 grabbing + テキスト選択なし。
   カード内リンク(a)の通常カーソルは変えない(ドラッグ中だけ全体を grabbing) */
@media (hover: hover) and (pointer: fine) {
  body:not(.lower-page) .top-voice-restored .voice-slider,
  body:not(.lower-page) .top-voice-restored .voice-slider .voice-card {
    cursor: grab;
  }
}

body:not(.lower-page) .top-voice-restored .voice-slider.is-dragging,
body:not(.lower-page) .top-voice-restored .voice-slider.is-dragging * {
  cursor: grabbing;
  user-select: none;
}

/* ===== 2026-10-28: 育脳個別学習コース(course/ikunou.html)の文章改訂に伴う、このページ固有の調整 ===== */
/* FVのキャッチコピー「「勉強が苦手」を、「学ぶって楽しい！」に。」: リード文の先頭に、本文より大きく・強調して置く */
body.page-ik .hero .lead .lead-catch {
  display: block;
  margin-bottom: 12px;
  color: var(--green);
  font-size: 1.3em;
  font-weight: 800;
  line-height: 1.5;
}

/* CONCEPT本文は2つの<p>。末尾の1文だけ段落として分ける(.messageのグリッドは本文エリアが2つのため。atama+・ウイングネットと同じ構成) */
body.page-ik .message-copy .concept-para {
  display: block;
  margin-top: 16px;
}

/* 2026-10-28: 育脳ページの本文(リード・CONCEPT・STEP・特徴・FAQ)に付けていた word-break: auto-phrase / text-wrap: pretty は撤去。
   文節単位の折り返しで行の長さがそろわず(「…時間が／かかったり。」のように途中で短く折り返す)不自然だったため、標準の折り返しに戻した */

body.page-ik .recommend-grid article {
  word-break: auto-phrase !important; /* 共通の word-break: normal !important を打ち消す */
  text-wrap: balance;
}

/* 特徴カードの見出し(H3)が長くなり、末尾1文字だけ折り返される(「…学び直せ／る」)のを防ぐ: 文節単位+均等に折り返す */
body.page-ik .reason-card h3,
body.page-ik .system-steps li h3 {
  word-break: auto-phrase;
  text-wrap: balance;
}

/* SP: リード(キャッチコピー+本文)が長くなり、共通の「min-height+リードを下端へ押し下げる」方式だとリードの先頭が写真(下端 約y380)に
   かかるため、リードの先頭を見出しの下から固定距離にして、写真の下に置く(見出しは2行固定なので位置が安定する) */
@media (max-width: 640px) {
  body.page-ik .hero-copy {
    min-height: 0;
  }

  body.page-ik .hero-copy .lead {
    margin-top: 108px !important;
  }

  body.page-ik .hero .lead .lead-catch {
    font-size: 1.2em;
  }
}

/* 「育脳個別学習コースの」(10文字=約9.96em)が、320px付近で本文幅より広く、末尾の「の」だけが次の行へ落ちる(「…コース／の／特徴」)のを防ぐ:
   SPでは見出し(特徴・よくあるご質問)の文字サイズを、本文幅(画面幅-44px)に10文字が収まる大きさまで下げる。上限は従来の28px(360px以上は変化なし) */
@media (max-width: 640px) {
  body.page-ik #features .reasons-title h2,
  body.page-ik .faq-section .extra-head h3 {
    font-size: min(28px, calc((100vw - 44px) / 10.1));
  }
}

/* 中学生コースの育脳カード: 説明が長くなったため、文節単位で折り返し、行末に1〜2文字(「す。」など)だけ残るのを防ぐ(育脳カードのみ) */
body.page-jr .jr-overview-card--blue .jr-overview-details dd {
  word-break: auto-phrase;
  text-wrap: pretty;
}

/* 育脳ページのSP: 左端のピンクの三角装飾が、リード文の1行目にかかっていたため、装飾だけ上げる(共通は bottom:126px → 20px上げた146pxでは三角の先端がまだ本文1行目にかかったため、写真左の空き(見出しの下・リードの上)に収まる266pxまで上げた。育脳ページのみ) */
@media (max-width: 640px) {
  body.page-ik .hero::after {
    bottom: 266px !important;
  }
}

/* 中学生ページのFV導入文: 強制改行を外したため、文節単位(auto-phrase)で折り返し、行頭・行末に1〜2文字だけ残るのを防ぐ(pretty)。中学生ページのみ */
body.page-jr .hero .lead {
  word-break: auto-phrase;
  text-wrap: pretty;
}

/* 導入文の「一人ひとり」が行をまたいで分かれないよう、1語として扱う(文章は変更なし) */
body.page-jr .hero .lead .nw {
  white-space: nowrap;
}

/* ===== 2026-10-28: アクセスマップ画像を最新版(img/map-02.webp。旧 img/map.png は保持)に差し替え。TOP・サポート校ページ共通 =====
   吹き出し(空白)の中心は、画像上で横41.8%・縦53.8%(→2026-10-28 ユーザー指定で、実際に重ねる位置は left:41.3% / margin-top:22.4% に微調整)(旧画像は横40.7%・縦56.1%)。ロゴは吹き出しの中心に合わせる。
   位置の基準を画像の幅に統一: top は margin-top の%(=包含ブロックの幅基準)で指定するため、マップ枠の高さ(画像+「Googleマップで見る」リンク)や
   画面幅(PC/SP)に関係なく、画像の縦横比(1958×803)のまま吹き出しの中心に重なる。ロゴの大きさ(幅16%)は従来どおり */
body:not(.lower-page) .access-map-logo,
body.page-support-school .access-map-logo {
  top: 0;
  left: 41.3%;
  margin-top: 22.4%;
  transform: translate(-50%, -50%);
}

@media (min-width: 641px) {
  body:not(.lower-page) .access-map-logo,
  body.page-support-school .access-map-logo {
    top: 0;
    left: 41.3%;
  }
}

@media (max-width: 700px) {
  body:not(.lower-page) .access-map-logo,
  body.page-support-school .access-map-logo {
    top: 0;
    left: 41.3%;
  }
}

/* ===== 2026-10-28: TOP追加調整 ===== */

/* ① SPハンバーガーメニュー(TOPのみ): 「マイポートについて」「コース案内」の子メニューを、高さ+透明度でふわっと開閉する。
   JS(nav-dropdown.js)が開閉中だけ .is-anim を付け、height/opacity/余白をインラインで動かす。hidden属性・aria-expanded は従来どおり */
body:not(.lower-page) .mobile-nav-sub.is-anim {
  overflow: hidden;
  transition: height 0.32s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.26s ease,
    margin-bottom 0.32s cubic-bezier(0.22, 1, 0.36, 1), padding 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

@media (prefers-reduced-motion: reduce) {
  body:not(.lower-page) .mobile-nav-sub.is-anim {
    transition: none;
  }
}

/* ② SPのFV下ボタン(「体験授業を申し込む」「マイポートを知る」): 横幅いっぱいをやめて80%・中央配置(641px以上は従来どおり) */
@media (max-width: 640px) {
  body:not(.lower-page) .hero-actions .button {
    width: 80% !important;
    margin: 0 auto !important;
  }
}

/* ③ 合格実績(#results)のピンク → 緑系。このセクション(.results)だけに限定(合格体験記を探す等のピンクは変更しない)。
   H2=濃い緑(#1f3f36。ニュース見出しと同じ) / 英字ラベル=サイト標準の緑 var(--green) / 学校名タグ=濃い緑(#315f35。ヒーローの枠線ボタンと同じ)、
   区切りの「・」=標準の緑を薄めた色 / 「実績をもっと見る」=コース案内の枠線ボタンと同じ緑(通常: 白地+緑枠+緑文字、hover/focus: 緑地+白文字) */
body:not(.lower-page) .results .section-kicker {
  color: var(--green);
}

body:not(.lower-page) .results h2 {
  color: #1f3f36;
}

body:not(.lower-page) .results .school-tags span {
  color: #315f35;
}

body:not(.lower-page) .results .school-tags span:not(:first-child)::before {
  color: rgba(91, 149, 90, 0.6);
}

body:not(.lower-page) .results .button.ghost.small {
  display: flex;
  width: fit-content;
  margin-right: auto;
  margin-left: auto;
  color: var(--green);
  border-color: var(--green);
}

body:not(.lower-page) .results .button.ghost.small:hover,
body:not(.lower-page) .results .button.ghost.small:focus-visible {
  color: #fff;
  background: var(--green);
  border-color: var(--green);
}

/* 長い大学名(公立諏訪東京理科大学など)でも、タグの途中で折り返さず、1校ずつ折り返す */
body:not(.lower-page) .results .school-tags span {
  white-space: nowrap;
}

/* ④ 合格体験記「横にスライドできます」: 既存ボタンと同じ文字矢印「→」(.button::after と同じ content / margin-left)を付ける */
body:not(.lower-page) .admission-index-hint::after {
  margin-left: 6px;
  content: "→";
}

/* ⑤ お知らせ(過去ログ一覧): 一覧の高さを固定し、内部で縦スクロール(PC・SP共通)。新しい記事を上に追加していく */
body:not(.lower-page) .news-scroll {
  max-height: 360px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-bottom: 1px solid #e5e7eb;
  scrollbar-width: thin;
  scrollbar-color: rgba(91, 149, 90, 0.45) transparent;
}

body:not(.lower-page) .news-scroll:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
}

body:not(.lower-page) .news-scroll .news-list li:last-child {
  border-bottom: 0;
}

@media (max-width: 640px) {
  body:not(.lower-page) .news-scroll {
    max-height: 420px;
  }
}

/* ① 合格実績・合格体験記を探す のH2: 他セクションのH2と同じ黒系(#222)。キッカー・学校名タグ・ボタンの色は変更しない */
body:not(.lower-page) .results h2 {
  color: #222;
}

/* 「合格体験記を探す」(.admission-index > h3)は既存の color: #74364f !important があるため、同じ詳細度で !important を付けて上書き */
body:not(.lower-page) .results-voice:not(.results-voice--stacked) .admission-index > h3 {
  color: #222 !important;
}

/* ===== 2026-10-28: 下層ページ最終チェック対応 ===== */

/* ① 本文中のテキストリンク(下層ページ共通): サイト標準の緑+下線・太字なし。hover/focusは濃い緑+下線を太く。
   対象は <main> 内の本文(p・dd・td・公式リンク枠)にあるクラスなしの <a> と、クラスなしの電話リンク。
   ナビ・パンくず・フッター・ボタン・カード全体リンクなど、クラスを持つリンクは対象外。 */
body.lower-page main :is(p, dd, td) a[href]:not([class]),
body.lower-page main a[href^="tel:"]:not([class]) {
  color: var(--green);
  font-weight: 400;
  text-decoration: underline;
  text-underline-offset: 3px;
}

body.lower-page main :is(p, dd, td) a[href]:not([class]):hover,
body.lower-page main :is(p, dd, td) a[href]:not([class]):focus-visible,
body.lower-page main a[href^="tel:"]:not([class]):hover,
body.lower-page main a[href^="tel:"]:not([class]):focus-visible {
  color: #3f7d45;
  text-decoration-thickness: 2px;
}

body.lower-page main :is(p, dd, td) a[href]:not([class]):focus-visible,
body.lower-page main .official-link a:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ① FV直下の画像(.photo-portrait): 軽い角丸。本体と、実際に画像を表示している ::before の両方を丸め、はみ出しを隠す。大きさ・配置は変更しない */
body.lower-page .message .photo-portrait {
  border-radius: 16px !important;
  overflow: hidden;
}

body.lower-page .message .photo-portrait::before {
  border-radius: inherit;
}

/* ② about/index.html: 「マイポートを知る」の導入文を、通常の本文と同じ黒系に(「学習コースを見る」側は変更なし) */
body.page-about-index #about-nav .course-intro p:not(.section-kicker) {
  color: #333;
}

/* ⑤ 中学生ページ: FV写真の左側の余白を狭める(写真だけ左へ寄せる。枠・文字・全体レイアウトは変更なし) */
body.page-jr .hero-visual .jr-hero-photo {
  background-position: 78% 34%;
}

/* ⑤ 中学生ページ: 「育脳個別学習コースを詳しく見る」ボタンの行間(2行になったときの間が広い) */
body.page-jr .jr-overview-links > a[href="/course/ikunou.html"] {
  line-height: 1.2;
}

/* ⑥ 高校生ページ: ICT教材ボタン(SP)を同じ幅に揃えて縦に並べる。PC・タブレットは従来どおり */
@media (max-width: 640px) {
  body.page-hs .high-ict-links {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    gap: 10px;
  }

  body.page-hs .high-ict-links .button.ghost {
    justify-content: center;
    width: 100%;
    max-width: 280px;
  }
}

/* ⑧ BBY: SPの冒頭(FV)の文字が多いとリードが写真に被るため、リードの開始位置を見出しの下の一定距離にして、写真の下に置く */
@media (max-width: 640px) {
  body.page-bby .hero-copy {
    min-height: 0;
  }

  body.page-bby .hero-copy .lead {
    margin-top: 104px !important;
  }
}

/* ⑨ TERRACE: CONCEPTの旧背景画像(共通フォールバック sensei.png)を外す。表示される画像は ::before の mp-terrace-reading-v2.png */
body.page-tr .message .mp-terrace-concept {
  background-image: none !important;
}

/* ⑨ TERRACE(SP): CONCEPTの見出しと画像の間が広い(共通の ::before の margin-top: 5rem)ため、中学生・小学生・高校生ページと同じ 2rem に(下の --pp-mt で指定) */

/* ⑨ TERRACE 3講座カードの画像: 旧画像(共通の photo-course-*)を、各講座に対応する既存画像へ。対応は、小学生ページの教科カードが同じ講座へリンクしている画像に合わせた
   (速読解力講座←速読の画像 / 新国語講座←読解(国語)の画像 / 速読聴英語講座←英語の画像) */
body.page-tr #terrace-courses .course-card--green .course-image {
  background-image: url("img/mp-pr-sokudoku.jpg");
}

body.page-tr #terrace-courses .course-card--blue .course-image {
  background-image: url("img/mp-pr-reading.jpg");
}

body.page-tr #terrace-courses .course-card--pink .course-image {
  background-image: url("img/mp-pr-english.jpg");
}

/* ⑨ TERRACE 「主なトレーニング」カード(SP): 全幅に広がらないよう、カード幅を揃えて中央に置く(PCは200px幅で既存のまま) */
@media (max-width: 640px) {
  body.page-tr .terrace-course-detail .recommend-grid {
    grid-template-columns: minmax(0, 320px) !important;
    justify-content: center;
  }
}

/* ⑩ ウイングネット「ベーシックウイング」「必要な対策を、必要なタイミングで。」のカード: タブレット・SPで横に広がりすぎないよう、最大幅320pxで中央に揃える(PCは300px幅で既存のまま) */
@media (max-width: 980px) {
  body.page-wingnet #wn-basic .recommend-grid {
    grid-template-columns: minmax(0, 320px);
    justify-content: center;
  }

  body.page-wingnet #curriculum .recommend-grid {
    grid-template-columns: repeat(2, minmax(0, 320px));
    justify-content: center;
  }

  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: 1 / -1;
    width: min(100%, 320px) !important;
    justify-self: center;
  }
}

@media (max-width: 640px) {
  body.page-wingnet #wn-basic .recommend-grid,
  body.page-wingnet #curriculum .recommend-grid {
    grid-template-columns: minmax(0, 320px) !important;
    justify-content: center;
  }

  body.page-wingnet #curriculum .recommend-grid article:nth-child(5) {
    grid-column: auto;
    width: 100% !important;
  }
}

/* TOP: 「合格体験記を探す」の大学名(一覧の下のラベル)を黒系 #222 に */
body:not(.lower-page) .admission-index-list span {
  color: #222;
}

/* ① 角丸の補足(BBY・TERRACE・Comiru・ウイングネット): この4ページのCONCEPT/ABOUT画像は background-size: contain で、枠(約1.05:1)より横長の画像を中央に表示している。
   そのままだと枠の角が丸くなっても、画像の角は丸く見えない。画像レイヤー(::before)を「画像と同じ縦横比」の枠にして中央に置き(見た目の画像サイズ・位置は従来と同じ)、その枠を丸める。
   SPの ::before の上余白(共通の margin-top)は、中央位置を同じにするため --pp-mt の半分だけ下げる方式に置き換え(画像の位置は変えない)。
   Comiru・ウイングネットは本体にも同じ画像が重なっていたため、BBYと同様に本体側の指定を外す(丸めた角から四角い画像がはみ出さないように) */
body.page-bby .message .mp-bby-about::before,
body.page-tr .message .mp-terrace-concept::before,
body.page-cm .message .mp-comiru-message-photo::before,
body.page-wn #wingnet-about .mp-wingnet-about::before {
  inset: auto 0;
  top: calc(50% + var(--pp-mt, 0px) / 2);
  height: auto;
  margin-top: 0;
  background-size: cover;
  transform: translateY(-50%);
}

body.page-bby .message .mp-bby-about::before { aspect-ratio: 1447 / 1087; }
body.page-tr .message .mp-terrace-concept::before { aspect-ratio: 1448 / 1086; }
body.page-cm .message .mp-comiru-message-photo::before { aspect-ratio: 1447 / 1087; }
body.page-wn #wingnet-about .mp-wingnet-about::before { aspect-ratio: 1672 / 941; }

body.page-cm .message .mp-comiru-message-photo,
body.page-wn #wingnet-about .mp-wingnet-about {
  background-image: none !important;
}

/* 角丸は画像レイヤー自身に付ける。本体の overflow: hidden / 角丸は、この4ページでは画像の外側の余白を切るだけになるため外す */
body.page-bby .message .mp-bby-about,
body.page-tr .message .mp-terrace-concept,
body.page-cm .message .mp-comiru-message-photo,
body.page-wn #wingnet-about .mp-wingnet-about {
  overflow: visible;
  border-radius: 0 !important;
}

body.page-bby .message .mp-bby-about::before,
body.page-tr .message .mp-terrace-concept::before,
body.page-cm .message .mp-comiru-message-photo::before,
body.page-wn #wingnet-about .mp-wingnet-about::before {
  border-radius: 16px;
}

@media (max-width: 640px) {
  body.page-bby .message .photo-portrait,
  body.page-cm .message .photo-portrait,
  body.page-wn #wingnet-about .photo-portrait {
    --pp-mt: 5rem;
  }

  body.page-tr .message .photo-portrait {
    --pp-mt: 2rem;
  }
}

/* ===== 2026-10-29: 旧画像 sensei.png の背景指定を、実画像を ::before で出している5ページから外す =====
   小学生・中学生・高校生・育脳・atama+ は ::before が実画像のため、本体の旧画像だけをページ単位で無効化する。
   共通の .photo-portrait{background-image:url(sensei.png)} と body.mp-v2 …::before{placeholder-jr-concept.jpg} は、
   現在は公開対象外の voice/index.html(ファイルのみ保持)だけが表示に使う。同ファイルを整理する時に、これらと
   上記のページ別 none 指定をまとめて削除できる(画像ファイル自体はまだ削除しない)。 */
body.page-pr .message .photo-portrait,
body.page-jr .message .photo-portrait,
body.page-hs .message .photo-portrait,
body.page-ik .message .photo-portrait,
body.page-atama .message .photo-portrait {
  background-image: none;
}

/* ===== WP環境限定の共通下層ブロック(renewal-test側には存在しない・full-sync対象外) =====
   代表ページ course/high_school.html のWP移植で必要になった、WP側(Nishiki親テーマ/既存CMS)
   由来の要素を打ち消すための最小限のルール。body.mp-v2 スコープのため、TOP(mp-v2クラスなし)
   および mp-v2クラスをまだ持たない未移植ページには影響しない。今後 mp-v2 を付与する下層ページ
   全てに共通で効く想定で、ここへ追加していく。 */
body.mp-v2 .outline {
  display: none;
}

body.mp-v2 .hero {
  background: none;
}

/* 2026-11-02 WP環境限定: 親テーマ(Nishiki)の main.css に `svg { width: 1.4rem; height: 1.4rem; }`(約22px)があり、
   HTMLの width="16" height="16" 属性(CSSより弱い)を上書きして、矢印アイコンが静的版(16px)より大きく表示される。
   静的版の表示に合わせて、属性どおりのサイズに戻す。リニューアル対象ページ(body.mayport-renewal-page)だけに効く。 */
body.mayport-renewal-page svg[width="16"][height="16"] {
  width: 16px;
  height: 16px;
}

/* 2026-11-02 WP環境限定: 親テーマ(Nishiki)の main.css の `.hero { text-align: center }` が、サポート校ヒーローの
   バッジ(inline-block)を中央に寄せてしまう(静的版は左寄せ)。サポート校のヒーローだけ、静的版と同じ開始位置寄せに戻す。 */
body.page-support-school .hero {
  text-align: start;
}
.message-video {
    border: solid #eee;
}



.top-promo-banners {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto 32px;
}

/* バナーの見た目 */
.top-promo-banners a {
  display: block;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(30, 60, 50, 0.16);
  transition: transform 0.25s ease,
              box-shadow 0.25s ease;
}

.top-promo-banners img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.3s ease;
}

/* PC：ホバーで浮き上がる */
@media (hover: hover) {
  .top-promo-banners a:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(30, 60, 50, 0.22);
  }

  .top-promo-banners a:hover img {
    transform: scale(1.025);
  }
}

/* キーボード操作 */
.top-promo-banners a:focus-visible {
  outline: 3px solid #2f8067;
  outline-offset: 4px;
}

/* 1枚バナー：中央寄せ */
.top-promo-banners.single {
  grid-template-columns: minmax(0, 1fr);
  width: min(470px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

/* スマホ */
@media (max-width: 767px) {
  .top-promo-banners {
    width: calc(100% - 32px);
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .top-promo-banners.single {
    width: calc(100% - 32px);
  }
}

/* 動きを減らす設定への対応 */
@media (prefers-reduced-motion: reduce) {
  .top-promo-banners a,
  .top-promo-banners img {
    transition: none;
  }
}
