/*
Theme Name: NEXT FRONTIER School
Theme URI: https://polarisinc.jp/
Author: 株式会社POLARIS
Description: スクール NEXT FRONTIER のブロックテーマ（FSE）。見た目だけを持ち、試験システムは nextfrontiersystem プラグインが担当する。
Version: 0.3.0
Requires at least: 6.5
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nextfrontier-school
Tags: full-site-editing, block-patterns, education, one-column

⚠ 色・余白・文字サイズは theme.json が正本。ここには theme.json で書けないものだけ置く。
⚠ このフォルダ名は固定ページ本文に絶対URLとして焼き付く。あとから変えない。
*/

/* ---- theme.json で表現できないもの ---- */

/* 見出しの下の細い罫。装飾ではなく、節の切れ目を示すために使う */
.nf-rule-under {
  padding-bottom: 0.5em;
  border-bottom: 2px solid var(--wp--preset--color--navy);
}

/* 数字を並べるところは等幅に。点数・金額がガタつくと読めない */
.nf-tabular {
  font-variant-numeric: tabular-nums;
}

/* 縦組みのラベル付きリスト（沿革・概要など） */
.nf-deflist {
  display: grid;
  grid-template-columns: minmax(7em, 12em) 1fr;
  gap: 0;
  margin: 0;
}
.nf-deflist > div {
  display: contents;
}
.nf-deflist dt,
.nf-deflist dd {
  border-top: 1px solid var(--wp--preset--color--rule);
  padding: 1em 0.4em;
  margin: 0;
}
.nf-deflist dt {
  color: var(--wp--preset--color--dim);
  font-size: var(--wp--preset--font-size--small);
}
@media (max-width: 600px) {
  .nf-deflist { grid-template-columns: 1fr; }
  .nf-deflist dd { border-top: 0; padding-top: 0; }
}

/* 番号つきの節。実際に順序があるところにだけ使う */
.nf-step {
  counter-increment: nf-step;
  position: relative;
  padding-left: 3.2em;
}
.nf-step::before {
  content: counter(nf-step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0.1em;
  font-size: var(--wp--preset--font-size--small);
  letter-spacing: 0.08em;
  color: var(--wp--preset--color--gold);
}
.nf-steps { counter-reset: nf-step; }

/* キーボード操作でどこにいるか分かるように */
:where(a, button, input, textarea, select):focus-visible {
  outline: 2px solid var(--wp--preset--color--gold);
  outline-offset: 2px;
}

/* 引用の縦罫。ブロックの初期値だと細すぎて紙面で見えない */
.wp-block-quote {
  border-left: 3px solid var(--wp--preset--color--gold);
  padding-left: 1.4em;
  font-style: normal;
}

/* ---- スマホ（0.2.3 / 2026-10-12）----
   中身が始まるまでに画面の上4割が見出しと余白で埋まっていた
   （本文の上 5rem・見出し 1.75rem・見出しと本文の間 3rem・左右 1.75rem）。スマホだけ詰める。
   ⚠ 余白はテンプレートの style 属性に直接入っているので !important が要る */
@media (max-width: 600px) {
  body {
    --wp--style--root--padding-left: 1rem;
    --wp--style--root--padding-right: 1rem;
  }
  main.wp-block-group { padding-top: 1.25rem !important; }
  .wp-block-post-title.has-x-large-font-size { font-size: 1.3rem !important; }
  main .wp-block-post-content { margin-block-start: 1rem !important; }
  footer.wp-block-template-part { margin-block-start: 2rem !important; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
