/* こども海外ノート — 共通スタイル
   Layout: 単一カラム。上に細いナビ、本文は最大760px。ツールは「入力カード → 結果 → ルール」の順。 */
/* フォントはサイト内（assets/fonts/）から配信する。外部のフォント配信サービスは使わない。ライセンス（SIL OFL 1.1）は assets/fonts/OFL-*.txt */
@font-face { font-family: "Zen Maru Gothic"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/ZenMaruGothic-700.woff2") format("woff2"); }
/* 注意：Zen Kaku の -400 と -700 のファイルは中身が逆（-400.woff2 が Bold、-700.woff2 が Regular。2026-12-06 にフォントの情報で確認）。そのため src を入れ替えている */
@font-face { font-family: "Zen Kaku Gothic New"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/ZenKakuGothicNew-700.woff2") format("woff2"); }
@font-face { font-family: "Zen Kaku Gothic New"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/ZenKakuGothicNew-500.woff2") format("woff2"); }
@font-face { font-family: "Zen Kaku Gothic New"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/ZenKakuGothicNew-400.woff2") format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/IBMPlexMono-Regular.ttf") format("truetype"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/IBMPlexMono-Medium.ttf") format("truetype"); }
@font-face { font-family: "DotGothic16"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/DotGothic16-400.woff2") format("woff2"); }
:root {
  --bg: #f5f8f7;
  --surface: #ffffff;
  --fg: #1b2a33;
  --muted: #5e6f78;
  --line: #d6dfdd;
  --accent: #17807a;
  --accent-ink: #ffffff;
  --accent-soft: #e1f2ef;
  --hl: #fff2b8;
  --ok: #1f8a4c;
  --ng: #c2412b;
  --warn: #b7791f;
  --font-display: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Zen Kaku Gothic New", sans-serif;
  --font-body: "Zen Kaku Gothic New", "Hiragino Sans", "Noto Sans JP", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Menlo, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121a1c; --surface: #1a2426; --fg: #e6eeec; --muted: #9fb0ad; --line: #2e3c3e;
    --accent: #5fc8bf; --accent-ink: #0d1a1c; --accent-soft: #1f3334; --hl: #4a3f1a;
    --ok: #5fcf8a; --ng: #ff8a73; --warn: #e2b55a; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #121a1c; --surface: #1a2426; --fg: #e6eeec; --muted: #9fb0ad; --line: #2e3c3e;
  --accent: #5fc8bf; --accent-ink: #0d1a1c; --accent-soft: #1f3334; --hl: #4a3f1a;
  --ok: #5fcf8a; --ng: #ff8a73; --warn: #e2b55a; color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { height: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--font-body); line-height: 1.7; font-size: 15px; }
/* ページ全体が横にはみ出さないように（表の横スクロール .tablewrap はそのまま。clip はスクロールの箱を作らないので position: sticky も効く） */
html, body { overflow-x: clip; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
.wrap {
  max-width: 760px; margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.nav { border-bottom: 1px solid var(--line); background: var(--surface); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 12px; flex-wrap: wrap; }
.launchbar { margin: 28px 0 0; background: var(--bg); border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; line-height: 1.5; padding-block: 5px; }
.launchbar .wrap { display: block; padding-left: max(12px, env(safe-area-inset-left, 0px)); padding-right: max(12px, env(safe-area-inset-right, 0px)); }
.brand { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; color: var(--fg); text-decoration: none; display: flex; align-items: center; gap: 8px; }
.brand .mark { width: 22px; height: 22px; border-radius: 6px; background: var(--accent); position: relative; flex: none; }
.brand .mark::after { content: ""; position: absolute; left: 6px; top: 5px; width: 10px; height: 12px; border-left: 2px solid var(--accent-ink); border-bottom: 2px solid var(--accent-ink); border-radius: 0 0 0 3px; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 16px; font-size: .9rem; }
.nav ul a { color: var(--muted); text-decoration: none; }
.nav ul a:hover { color: var(--accent); }
main.wrap { padding-block: 28px 64px; display: flex; flex-direction: column; gap: 24px; }
h1 { font-family: var(--font-display); font-size: 1.7rem; font-weight: 700; margin: 0 0 6px; text-wrap: balance; line-height: 1.3; }
h2 { font-family: var(--font-display); font-size: 1.15rem; margin: 0 0 10px; }
h3 { font-size: 1rem; margin: 0 0 6px; }
.lead { margin: 0; color: var(--muted); max-width: 42em; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 560px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
label { display: block; font-size: .8rem; font-weight: 500; color: var(--muted); margin-bottom: 6px; }
input[type="date"], input[type="month"], input[type="number"], input[type="text"], select, textarea {
  width: 100%; font: inherit; font-size: 1rem; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--fg);
}
input[type="date"], input[type="month"], input[type="number"], select { font-family: var(--font-mono); }
textarea { min-height: 220px; resize: vertical; line-height: 1.6; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
button { font: inherit; font-weight: 500; padding: 9px 14px; border-radius: 8px; cursor: pointer; border: 1px solid var(--line); background: var(--surface); color: var(--fg); }
button.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
/* 押した瞬間・押せないときの見た目（2026-12 の見た目の点検：ボタンに押した手応えがなかった） */
button:active:not(:disabled) { transform: translateY(1px); }
button:disabled { opacity: .5; cursor: not-allowed; }
.actions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; align-items: center; }
.toast { font-size: .85rem; color: var(--muted); }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 11px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .78rem; font-weight: 500; color: var(--muted); }
td.sys { font-weight: 700; white-space: nowrap; }
td.sys small { display: block; font-weight: 400; color: var(--muted); font-size: .75rem; }
td .num, .notes .num { white-space: nowrap; }
td.grade, .num { font-family: var(--font-mono); font-weight: 500; }
td.grade { font-size: 1.05rem; }
td.stage { color: var(--muted); font-size: .9rem; }
tr.hl td { background: var(--accent-soft); }
tr.hl td:first-child { border-left: 3px solid var(--accent); }
.tablewrap { overflow-x: auto; }
.notes { font-size: .9rem; color: var(--muted); overflow-wrap: anywhere; }   /* 備考に長いURLが入っても、スマホで横にはみ出さない */
.notes h2 { color: var(--fg); }
.notes ul, .prose ul { margin: 0; padding-left: 1.2em; display: flex; flex-direction: column; gap: 6px; }
.prose p { margin: 0 0 12px; max-width: 42em; }
.prose h2 { margin-top: 8px; }
.pill { display: inline-block; font-size: .75rem; font-weight: 500; padding: 2px 9px; border-radius: 999px; line-height: 1.6; }
.pill.ok { background: color-mix(in srgb, var(--ok) 18%, transparent); color: var(--ok); }
.pill.ng { background: color-mix(in srgb, var(--ng) 16%, transparent); color: var(--ng); }
.pill.warn { background: color-mix(in srgb, var(--warn) 18%, transparent); color: var(--warn); }
.pill.check { background: transparent; color: var(--ok); border: 1px dashed var(--ok); text-decoration: none; }   /* 「△要確認」：条件は合いそうだが、一部は学校に確認が必要（○ではない） */
a.pill.check { white-space: nowrap; } a.pill.check:hover { text-decoration: underline; }
.open-points { margin: 10px 0; padding: 10px 14px; border-left: 4px dashed var(--ok); border-radius: 8px; background: color-mix(in srgb, var(--ok) 8%, transparent); }
.open-points h3 { margin: 0 0 6px; font-size: 1rem; }
.open-points .ev { font-size: .8rem; margin-top: 2px; overflow-wrap: anywhere; }
.board .brow .bs .chk { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 4px; background: #f6c66b; color: #13233a; font-family: var(--font-body); font-size: .72rem; font-weight: 700; vertical-align: middle; }
.pill.overseas { background: var(--accent); color: var(--accent-ink); margin-right: 4px; white-space: nowrap; }
.overseas-note { margin: 8px 0 0; padding: 8px 12px; border-left: 4px solid var(--accent); border-radius: 8px; background: var(--accent-soft); font-size: .9rem; overflow-wrap: anywhere; }
.docs-warn { margin: 10px 0; padding: 10px 14px; border-left: 4px solid var(--warn); border-radius: 8px; background: color-mix(in srgb, var(--warn) 14%, transparent); font-weight: 600; }
.docs-warn small { display: block; margin-top: 4px; font-weight: 400; color: var(--muted); }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat .k { font-size: .78rem; color: var(--muted); }
.stat .v { font-family: var(--font-mono); font-size: 1.4rem; font-weight: 500; line-height: 1.2; font-variant-numeric: tabular-nums; }
.stat .v small { font-size: .8rem; color: var(--muted); font-family: var(--font-body); margin-left: 4px; }
.toollist { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.toollist a { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; color: var(--fg); text-decoration: none; min-width: 0; }
.toollist a:hover { border-color: var(--accent); }
.toollist .t { font-family: var(--font-display); font-weight: 700; margin-bottom: 4px; }
.toollist .d { font-size: .85rem; color: var(--muted); }
.toollist .soon { opacity: .55; pointer-events: none; }
.hero { padding-block: 8px 4px; }
.hero .eyebrow { font-size: .78rem; color: var(--accent); font-weight: 500; margin-bottom: 6px; }
footer.site { border-top: 1px solid var(--line); margin-top: 24px; }
footer.site .wrap { padding-block: 20px 36px; font-size: .8rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px 20px; }
footer.site a { color: var(--muted); }
.ad-slot { min-height: 90px; border: 1px dashed var(--line); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: .75rem; }
@media (prefers-reduced-motion: no-preference) { .toollist a { transition: border-color .15s; } }

/* トップページの温度を少し上げる：ノート罫線の帯とツールアイコン */
.hero.home { position: relative; padding: 22px 20px 20px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.hero.home::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(to bottom, transparent 0 27px, color-mix(in srgb, var(--accent) 14%, transparent) 27px 28px); pointer-events: none; }
.hero.home::after { content: ""; position: absolute; left: 44px; top: 0; bottom: 0; width: 2px; background: color-mix(in srgb, var(--ng) 35%, transparent); pointer-events: none; }
.hero.home > * { position: relative; padding-left: 40px; }
.hero.home h1 { font-size: 1.75rem; }
.toollist a { display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: start; }
.toollist a > .ico { width: 40px; height: 40px; border-radius: 10px; background: var(--accent-soft); display: grid; place-items: center; color: var(--accent); }
.toollist a > .ico svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.toollist a > div:not(.ico) { min-width: 0; }
.toollist .badge { display: inline-block; font-size: .7rem; font-weight: 500; color: var(--accent-ink); background: var(--accent); border-radius: 999px; padding: 1px 8px; margin-left: 6px; vertical-align: middle; }

.trust { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.trust .tr { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-left: 3px solid var(--accent); background: var(--surface); border-radius: 0 10px 10px 0; }
.trust .tr b { font-family: var(--font-display); font-size: .98rem; }
.trust .tr span { font-size: .8rem; color: var(--muted); }
.when .wc { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; }
.when .wc .k { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; margin-bottom: 6px; position: relative; padding-left: 14px; }
.when .wc .k::before { content: ""; position: absolute; left: 0; top: .45em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.when .wc p { margin: 0; font-size: .92rem; color: var(--muted); }


.meta2 { display: grid; grid-template-columns: 7em 1fr; gap: 6px 12px; font-size: .95rem; }
.meta2 b { color: var(--muted); font-weight: 500; }
.links2 { display: flex; flex-wrap: wrap; gap: 10px 18px; }
.next2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.next2 a { display: block; border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; text-decoration: none; color: var(--fg); font-weight: 500; }
.next2 a:hover { border-color: var(--accent); }
.chipbtn { display: inline-block; padding: 8px 14px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); text-decoration: none; font-weight: 500; }
/* 送る（LINE・リンクをコピー）と、カレンダーの購読 */
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin: 12px 0 0; font-size: .9rem; }
.share .share-t { color: var(--muted); font-size: .85rem; }
.share-b { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border-radius: 8px; border: 1px solid var(--accent); background: var(--surface); color: var(--accent); font: inherit; font-size: .9rem; font-weight: 500; text-decoration: none; cursor: pointer; }
.share-b.line { background: var(--accent); color: var(--accent-ink); }
.share .share-ok { font-size: .8rem; color: var(--muted); }
.share .share-n { flex-basis: 100%; font-size: .78rem; line-height: 1.5; }
.cal-sub { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 12px 0; background: var(--bg); }
.cal-sub h3 { margin: 0 0 6px; font-size: 1rem; }
.cal-sub .chipbtn { min-height: 40px; display: inline-flex; align-items: center; }
.calurl { overflow-wrap: anywhere; word-break: break-all; font-family: var(--font-mono); font-size: .78rem; user-select: all; }
/* 前に見たときから更新された学校（学校さがし・出願チェックリスト） */
.revisit { border-left: 4px solid var(--accent); }
.revisit .rv-h { font-size: 1rem; margin: 0 0 6px; }
.revisit .rv-l { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; font-size: .9rem; overflow-wrap: anywhere; }
.revisit .rv-n { margin: 8px 0 0; font-size: .78rem; }
.revisit .actions { margin-top: 8px; }
.schoollist { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 6px 16px; }
.schoollist li { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: .92rem; }

/* 利用者の声ウィジェット */
.fbw { position: fixed; right: max(12px, env(safe-area-inset-right, 0px)); bottom: max(12px, env(safe-area-inset-bottom, 0px)); z-index: 50; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.fbw-btn { background: var(--fg); color: var(--bg); border: 0; border-radius: 999px; padding: 9px 14px; font-size: .85rem; font-weight: 500; box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.fbw-i { display: none; }
@media (max-width: 480px) {
  /* スマホ：丸いアイコンだけにして本文に重なりにくくし、ページ末尾に余白を足す（押せる大きさ 44px は保つ） */
  body { padding-bottom: 64px; }
  .fbw-btn { width: 44px; height: 44px; padding: 0; display: inline-flex; align-items: center; justify-content: center; }
  .fbw-i { display: block; }
  .fbw-t { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
.fbw-panel { width: min(360px, calc(100vw - 24px)); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px; display: grid; gap: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.18); }
.fbw-kinds { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: .82rem; }
.fbw-kinds label { display: inline-flex; align-items: center; gap: 4px; margin: 0; color: var(--fg); font-size: .82rem; }
.fbw-panel textarea { min-height: 90px; font-size: .9rem; }
.fbw-panel input[type="url"] { font-family: var(--font-mono); font-size: .85rem; }
.fbw-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.fbw-note { font-size: .72rem; color: var(--muted); }
.fbw-done { font-size: .85rem; color: var(--ok); }
@media print { .fbw { display: none !important; } }
/* 学校ページ：日程表 */
table.sched{width:100%;border-collapse:collapse;font-size:.9rem}
table.sched td{padding:6px 8px;border-top:1px solid var(--line);vertical-align:top}
table.sched td.mono{font-family:var(--font-mono);white-space:nowrap;width:7.5em}
/* 日程一覧・県ページの静的な表：狭い画面では .tablewrap の中だけ横にスクロールする（ページ全体は横にはみ出させない） */
.tablewrap { max-width: 100%; }
table.stbl { font-size: .9rem; min-width: 560px; }
table.stbl td.mono { font-family: var(--font-mono); white-space: nowrap; }
table.stbl td.nm { min-width: 9em; }
table.sched-tbl { min-width: 640px; }
table.hen-tbl { min-width: 860px; }
table.hen-tbl td { vertical-align: top; overflow-wrap: anywhere; }
table.hen-tbl ul.hen-up { margin: 4px 0 0; padding-left: 1.1em; font-size: .86rem; }
.hen-notice { margin: 0 0 12px; }
table.stbl tr.is-past td { opacity: .6; }
/* 日程一覧：月の見出し・中学/高校の切り替え・絞り込み・過ぎた日程のたたみ・「あと○日」 */
.sched-tbl [hidden] { display: none !important; }
table.sched-tbl tr.mh th { padding: 14px 8px 6px; font-size: .95rem; font-weight: 700; color: var(--fg); letter-spacing: 0; border-bottom: 2px solid var(--line); }
table.sched-tbl td .wd { margin-left: 2px; color: var(--muted); }
table.sched-tbl td .left { margin-left: 8px; font-family: var(--font-body); font-weight: 700; font-size: .85rem; color: var(--muted); white-space: nowrap; }
table.sched-tbl td .left.soon { color: var(--warn); }
table.dl-tbl td .wd { margin-left: 2px; color: var(--muted); }
table.dl-tbl td .left { display: block; font-family: var(--font-body); font-weight: 700; font-size: .85rem; color: var(--muted); white-space: nowrap; }
table.dl-tbl td .left.soon { color: var(--warn); }
/* 英語資格で免除・得点換算・加点がある学校の一覧（/ranking/english-benefit/）：列が多いので、表は枠の中で横に動かす。行ごとの「点検中」の注意は小さく */
table.eb-tbl { min-width: 820px; }
table.eb-tbl td.eb-ap { min-width: 7em; }
table.eb-tbl td.eb-q { min-width: 17em; overflow-wrap: anywhere; }
table.eb-tbl td.eb-src { min-width: 12em; overflow-wrap: anywhere; }
.eb-warn { margin: 6px 0 0; padding: 4px 8px; font-size: .78rem; border-left-width: 3px; }
.sswitch { display: flex; gap: 6px; margin: 0 0 8px; }
.sswitch a { flex: 1; text-align: center; padding: 4px 12px; min-height: 40px; line-height: 30px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-weight: 700; color: var(--accent); }
.sswitch a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.sfilter { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 8px; }
.sfilter .sfb { min-height: 40px; padding: 6px 12px; cursor: pointer; font: inherit; font-weight: 700; background: var(--surface); color: var(--accent); border: 1px solid var(--line); }
.sfilter .sfb[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.sfilter .sfn { flex-basis: 100%; font-size: .78rem; color: var(--muted); }
.sfilter .sfn:empty { display: none; }
.sintro { margin: 0; line-height: 1.6; }
.intro-more { margin: 0 0 8px; font-size: .88rem; }
.intro-more summary { cursor: pointer; min-height: 36px; display: flex; align-items: center; font-weight: 700; color: var(--accent); }
.intro-more p { color: var(--muted); }
.sched-card h2 { margin-bottom: 8px; }
@media (max-width: 639px) { .sched-card { padding: 14px 12px; } .sched-card h2 { font-size: 1.05rem; margin-bottom: 8px; } }
.foldbtn { display: block; width: 100%; min-height: 40px; margin: 0 0 4px; padding: 8px 12px; cursor: pointer; font: inherit; font-weight: 700; color: var(--accent); background: var(--surface); border: 1px dashed var(--line); border-radius: 10px; }
@media (max-width: 639px) {
  /* 幅640px未満：表をやめて、1件1枚の小さなカード（日付・曜日とあと○日／学校名／内容／出典）。同じ HTML を CSS だけで並べ替える */
  .sched-wrap { overflow-x: visible; }
  table.sched-tbl { min-width: 0; display: block; font-size: .9rem; }
  table.sched-tbl thead { display: none; }
  table.sched-tbl tbody, table.sched-tbl tr, table.sched-tbl td, table.sched-tbl th { display: block; }
  table.sched-tbl tr.mh th { padding: 12px 2px 6px; border: 0; border-bottom: 2px solid var(--line); margin-bottom: 8px; }
  table.sched-tbl tr[data-date] { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin: 0 0 8px; }
  table.sched-tbl tr[data-date] td { border: 0; padding: 0; min-width: 0; overflow-wrap: anywhere; }
  /* 改修N：1件ずつ縦に読む形。1段目＝日付・時刻（基準つき）と「あと○日」／2段目＝学校名・入試の回／3段目＝何の締切か／4段目＝「条件・書類 →」／最後に確認日と出典（開閉式） */
  table.sched-tbl td.mono { white-space: normal; width: auto; font-weight: 700; display: flex; align-items: baseline; flex-wrap: wrap; gap: 0 8px; }
  table.sched-tbl td.mono .tm { display: inline; font-family: var(--font-body); font-size: .85rem; }
  table.sched-tbl td.mono .left { margin-left: auto; }
  table.sched-tbl td.nm { min-width: 0; margin-top: 2px; font-weight: 700; font-size: 1rem; }
  table.sched-tbl td.nm .sgo { display: none; }
  table.sched-tbl td.nm .rnd-sp { display: inline; margin-left: 6px; font-weight: 400; font-size: .82rem; color: var(--muted); }
  table.sched-tbl td:nth-child(3) { margin-top: 2px; }
  table.sched-tbl td .sub.pc, table.sched-tbl td .rnd { display: none; }
  table.sched-tbl td .sub-sp { display: inline; }
  table.sched-tbl td .sgo-sp { display: block; width: fit-content; padding: 6px 0 4px; font-weight: 700; }
  table.sched-tbl td:nth-child(4) { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 12px; font-size: .78rem; }
  table.sched-tbl td .chk { order: 1; }
  table.sched-tbl td .srcd { order: 2; }
  table.sched-tbl td .srcd[open] { flex-basis: 100%; }
  table.sched-tbl td .srcd > summary { display: inline-block; cursor: pointer; padding: 4px 0; color: var(--accent); }
  table.sched-tbl tr.is-past td { opacity: .6; }
}
/* 改修N：日程一覧の入口（学校さがしへの案内を1つ）・表の前の説明・学校名のリンクに添える「条件・書類 →」・補助の共有ボタン */
.sother { margin: 12px 0 0; }   /* 日程一覧の上部：もう一方（中学⇔高校）の日程一覧へのリンク。下の絞り込みボタン（.sgate-a）より控えめな枠つき */
.sother a { display: block; padding: 11px 16px; border: 2px solid var(--accent); border-radius: 12px; color: var(--accent); font-weight: 700; line-height: 1.5; text-decoration: none; overflow-wrap: anywhere; }
.sother a:hover { text-decoration: underline; }
.sgate { margin: 12px 0; }
.sgate-a { display: block; padding: 14px 16px; border-radius: 12px; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: 1.02rem; line-height: 1.5; text-decoration: none; }
.sgate-a:hover { filter: brightness(1.08); }
.sgate-n { margin: 6px 2px 0; font-size: .8rem; color: var(--muted); }
.spre { margin: 0 0 8px; font-size: .9rem; font-weight: 600; }
table.sched-tbl .sgo { display: block; font-size: .74rem; font-weight: 400; white-space: nowrap; }
table.sched-tbl .tm, table.sched-tbl .rnd-sp, table.sched-tbl .sub-sp, table.sched-tbl .sgo-sp { display: none; }
@media (min-width: 640px) { table.sched-tbl .srcd > summary { display: none; } }
.share-mini .share { margin-top: 8px; gap: 6px 8px; font-size: .8rem; }
.share-mini .share .share-t { font-size: .78rem; }
.share-mini .share-b { min-height: 36px; padding: 4px 10px; font-size: .8rem; font-weight: 400; border-color: var(--line); }
.share-mini .share-b.line { background: var(--surface); color: var(--accent); }
/* 改修N：学校ページの「次の一歩」（日程と提出書類のすぐ後ろ。☆はこの端末のブラウザの中に保存） */
.nstep { margin: 14px 0 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.nstep h3 { margin: 0 0 8px; font-size: .95rem; }
.nstep-b { display: flex; flex-wrap: wrap; gap: 8px; }
.nstep-b > * { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border-radius: 8px; border: 1px solid var(--accent); background: var(--surface); color: var(--accent); font: inherit; font-size: .9rem; font-weight: 600; text-decoration: none; cursor: pointer; }
.nstep-b > .nstar[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }
.nstep small { display: block; margin-top: 6px; font-size: .78rem; color: var(--muted); }
.nstep .nstar-note:empty { display: none; }
.hs-sched-link { margin: 10px 0 0; font-weight: 600; }
/* 改修N：トップの道具の並び（最初の4つ＋「ほかの道具」） */
.toollist .tl2 { display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: start; min-width: 0; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 9%, var(--surface)) 0, var(--surface) 70px); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: 12px; padding: 16px; }
.toollist .tl2 > .ico { width: 40px; height: 40px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 18%, var(--surface)); display: grid; place-items: center; color: var(--accent); }
.toollist .tl2 > .ico svg { width: 22px; height: 22px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.toollist .tl2 > div:not(.ico) { min-width: 0; }
.toollist .tl2 .tl2-l { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.toollist .tl2 .tl2-l a, .toollist .tl2 .tl2-l a:hover { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border: 1px solid var(--accent); border-radius: 8px; background: var(--surface); color: var(--accent); font-size: .9rem; font-weight: 600; text-decoration: none; transform: none; box-shadow: none; }
.tools-more-h { margin: 22px 0 10px; font-size: 1.05rem; }
/* 学校ページ：日程と提出書類の回ごとの開閉（共通の手続きは開閉しない） */
.rd { margin: 8px 0 0; border-top: 1px solid var(--line); }
.rd > summary { cursor: pointer; display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 10px; min-height: 44px; padding: 8px 0; list-style-position: inside; }
.rd > summary .rdh { display: inline; margin: 0; font-size: 1rem; font-weight: 700; }
.rd .rdnext { font-size: .8rem; font-weight: 700; color: var(--warn); }
.rd.rd-common { padding: 8px 0 0; }
.rd.rd-common .rdh { margin: 6px 0; font-size: 1rem; }
/* ツール一覧：ツールごとの色（アイコン・上辺のライン・ほんのり背景） */
.toollist a { --tc: var(--accent); border-top: 4px solid var(--tc); background: linear-gradient(180deg, color-mix(in srgb, var(--tc) 9%, var(--surface)) 0, var(--surface) 70px); }
.toollist a > .ico { background: color-mix(in srgb, var(--tc) 18%, var(--surface)); color: var(--tc); }
.toollist a:hover { border-color: var(--tc); box-shadow: 0 6px 18px color-mix(in srgb, var(--tc) 18%, transparent); transform: translateY(-1px); }
.toollist a .badge { background: var(--tc); }
.toollist a[href*="school-finder"] { --tc: #17807a; }
.toollist a[href*="checklist"] { --tc: #d9772b; }
.toollist a[href*="forms"] { --tc: #7a4fb5; }
.toollist a[href*="essay"] { --tc: #c23b6b; }
.toollist a[href*="schools"] { --tc: #2f6fd1; }
.toollist a[href*="gakunen"] { --tc: #2a9d5c; }
@media (prefers-reduced-motion: no-preference) { .toollist a { transition: border-color .15s, box-shadow .15s, transform .15s; } }
/* 「こんなときに」も段階ごとに色 */
.when .wc { border-top: 4px solid var(--tc, var(--accent)); }
.when .wc:nth-child(1) { --tc: #2a9d5c; } .when .wc:nth-child(2) { --tc: #17807a; } .when .wc:nth-child(3) { --tc: #d9772b; }
.when .wc .k { color: var(--tc, var(--accent)); }
/* 信頼バンドの左線も色分け */
.trust .tr:nth-child(1) { border-color: #2a9d5c; } .trust .tr:nth-child(2) { border-color: #2f6fd1; } .trust .tr:nth-child(3) { border-color: #7a4fb5; } .trust .tr:nth-child(4) { border-color: #d9772b; }

/* トップ：4ステップ図 */
.flow { margin: 6px 0 4px; }
.flow-h { font-size: 1.15rem; margin: 0 0 12px; } .flow-h span { font-weight: 400; color: var(--muted); font-size: .9rem; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 880px) { .steps { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }
.steps li { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 14px 16px; min-width: 0; display: grid; gap: 6px; grid-template-rows: auto auto 1fr auto; align-content: start; }
.steps li:nth-child(1) { --tc: #17807a; } .steps li:nth-child(2) { --tc: #d9772b; } .steps li:nth-child(3) { --tc: #7a4fb5; } .steps li:nth-child(4) { --tc: #2f6fd1; }
.steps svg { width: 100%; height: 110px; display: block; background: color-mix(in srgb, var(--tc) 8%, var(--surface)); border-radius: 10px; padding: 6px 10px; box-sizing: border-box; }
.steps svg * { fill: none; stroke: var(--tc); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.steps svg .paper { fill: var(--surface); } .steps svg .fill { fill: color-mix(in srgb, var(--tc) 35%, var(--surface)); stroke: none; }
.steps svg .ok { fill: color-mix(in srgb, var(--tc) 18%, var(--surface)); } .steps svg .dim { opacity: .35; }
.steps svg .tick { stroke-width: 2.4; } .steps svg .arrow { stroke-width: 2.4; }
.steps svg .dot { stroke: none; } .steps svg .dot.a { fill: #17807a; } .steps svg .dot.b { fill: #d9772b; } .steps svg .dot.c { fill: #c23b6b; }
.steps svg .pen { fill: color-mix(in srgb, var(--tc) 25%, var(--surface)); }
.steps .n { position: absolute; top: 10px; left: 10px; width: 26px; height: 26px; border-radius: 50%; background: var(--tc); color: #fff; font-family: var(--font-mono); font-weight: 500; display: grid; place-items: center; font-size: .85rem; }
.steps h3 { margin: 4px 0 0; font-size: 1.02rem; }
.steps p { margin: 0; font-size: .88rem; color: var(--muted); }
.steps a { font-size: .88rem; font-weight: 500; }


/* 編入（hennyu-view.js）の表示 — 編入さがし・学校さがしで共通 */
  .gradebox { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; }
  .gradebox .big { font-family: var(--font-display); font-size: 1.8rem; font-weight: 700; color: var(--accent); }
  .route { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: var(--surface); }
  .route h3 { margin: 0 0 6px; font-size: 1.02rem; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
  .route ol, .route ul { margin: 6px 0 0; padding-left: 1.3em; font-size: .92rem; display: grid; gap: 4px; }
  .tagok { font-size: .74rem; border-radius: 999px; padding: 1px 9px; background: var(--accent-soft); color: var(--accent); border: 1px solid var(--accent); }
  .src { font-size: .76rem; color: var(--muted); margin-top: 6px; }
  .hs { display: grid; gap: 10px; }
  .hc { border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--surface); display: grid; gap: 4px; font-size: .9rem; }
  .hc.s1 { border-left-color: var(--ok); } .hc.s2 { border-left-color: var(--accent); } .hc.s3 { border-left-color: var(--warn); }
  .hc .hd { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; align-items: baseline; }
  .hc .nm { font-family: var(--font-display); font-weight: 700; font-size: 1rem; }
  .hc .st { font-size: .76rem; border-radius: 999px; padding: 1px 9px; border: 1px solid var(--line); white-space: nowrap; }
  .hc .meta { display: grid; grid-template-columns: 5.5em 1fr; gap: 2px 10px; }
  .hc .meta b { color: var(--muted); font-weight: 500; font-size: .84rem; }
  .hc .up { font-family: var(--font-mono); font-size: .86rem; }
  .hc .up .past { color: var(--muted); text-decoration: line-through; }
  .hc .links { display: flex; gap: 12px; flex-wrap: wrap; font-size: .85rem; align-items: center; }
  .hc .links button { font-size: .8rem; padding: 3px 10px; }
  .offlist { background: var(--accent-soft); border-radius: 10px; padding: 10px 12px; font-size: .9rem; }
  .route, .hc, .offlist, .src { overflow-wrap: anywhere; min-width: 0; }
  @media (max-width: 560px) { .hc .meta { grid-template-columns: 1fr; } }

/* トップ：ヒーローがそのまま判定フォーム（罫線ノートの上に書き込む） */
.quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px 14px; margin-top: 14px; }
.quick .qf { min-width: 0; }
.quick .qf label { font-size: .8rem; color: var(--muted); margin-bottom: 2px; display: block; }
.quick .qf input, .quick .qf select { width: 100%; background: var(--surface); }
.quick .qres { grid-column: 1 / -1; font-size: 1rem; line-height: 1.5; padding: 10px 0 2px; min-height: 3.4em; }
.quick .qres .qmsg { color: var(--muted); font-size: .92rem; }
.quick .qn { font-family: var(--font-display); font-size: 2.2rem; line-height: 1; color: var(--accent); font-variant-numeric: tabular-nums; display: inline-block; min-width: 1.2ch; text-align: right; vertical-align: -.12em; }
.quick .qn.b { color: var(--warn); font-size: 1.6rem; }
.quick .qsub { display: block; font-size: .8rem; color: var(--muted); margin-top: 4px; }
.quick .qgo { grid-column: 1 / -1; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.quick .qgo .quiet { font-size: .8rem; }
@media (max-width: 520px) { .hero.home > * { padding-left: 26px; } .hero.home::after { left: 30px; } .hero.home h1 { font-size: min(1.45rem, 5.2vw); } }   /* 見出しの1句（13字）が、狭い画面でも1行に収まる大きさ */

/* ページ移動を滑らかに（対応ブラウザのみ。動きを減らす設定では無効） */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .22s; }
}

/* トップ2段目：締切の案内板（出発ロビーの発着案内） */
.board { background: #13233a; color: #f5f7fa; border-radius: 16px; padding: 20px 22px 18px; display: grid; gap: 12px; }
.board .bhead { display: flex; justify-content: space-between; align-items: baseline; gap: 8px 16px; flex-wrap: wrap; }
.board h2 { margin: 0; color: #f5f7fa; font-size: 1.2rem; }
.board .bnote { font-size: .8rem; color: #a9b6c8; }
.board .bfilter { display: flex; gap: 8px; flex-wrap: wrap; }
.board .bchip { font: inherit; font-size: .85rem; padding: 6px 14px; min-height: 36px; border-radius: 999px; border: 1px solid #3a4f6e; background: transparent; color: #d7deea; cursor: pointer; }
.board .bchip[aria-pressed="true"] { background: #f0b429; border-color: #f0b429; color: #13233a; font-weight: 700; }
.board .brows { display: grid; gap: 5px; }
.board .brow { display: grid; grid-template-columns: 7em 7.5em minmax(0, 1fr) minmax(0, 1.5fr) 5.2em; gap: 5px; text-decoration: none; color: #f5f7fa; font-family: "DotGothic16", var(--font-mono); font-size: 1.05rem; }
.board .brow > span { background: #1c3150; padding: 9px 10px; border-radius: 4px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.board .brow .bleft { text-align: right; color: #f0b429; }
.board .brow.soon .bleft { background: #f0b429; color: #13233a; }
.board .brow:hover > span, .board .brow:focus-visible > span { background: #26406a; }
.board .brow:focus-visible { outline: 2px solid #f0b429; outline-offset: 2px; border-radius: 4px; }
.board .bempty { margin: 0; color: #a9b6c8; font-size: .9rem; padding: 10px 0; }
.board .bfoot { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; font-size: .78rem; color: #a9b6c8; }
.board .bmore { font: inherit; font-size: .85rem; background: transparent; color: #f0b429; border: 1px solid #f0b429; border-radius: 8px; padding: 6px 12px; cursor: pointer; }
.board .bshort { display: flex; gap: 8px 18px; flex-wrap: wrap; border-top: 1px solid #2a3f5e; padding-top: 12px; font-size: .9rem; }
.board .bshort a { color: #f5f7fa; text-underline-offset: 3px; }
@media (max-width: 600px) {
  .board { padding: 16px 14px; }
  .board .brow { grid-template-columns: auto minmax(0, 1fr) auto; font-size: .95rem; gap: 3px; }
  .board .brow .bd { grid-column: 1; grid-row: 1; }
  .board .brow .bk { grid-column: 2; grid-row: 1; }
  .board .brow .bleft { grid-column: 3; grid-row: 1; }
  .board .brow .bs { grid-column: 1 / -1; grid-row: 2; }
  .board .brow .bl { grid-column: 1 / -1; grid-row: 3; white-space: normal; background: #172a45; font-family: var(--font-body); font-size: .85rem; padding: 6px 10px; }
  .board .brow > span { padding: 7px 8px; }
  .board .brows { gap: 10px; }
}

/* 都道府県から探す：地域タイルの地図 */
.jmap { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-template-rows: repeat(6, 72px); gap: 8px; }
.jmap .tile { display: flex; flex-direction: column; justify-content: space-between; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; text-decoration: none; color: var(--fg); min-width: 0; }
.jmap .tile b { font-size: .92rem; }
.jmap .tile span { font-size: .8rem; color: var(--muted); }
.jmap .tile em { font-style: normal; font-family: var(--font-display); font-size: 1.6rem; color: var(--accent); }
.jmap .tile:hover, .jmap .tile:focus-visible { border-color: var(--accent); background: var(--accent-soft); }
.preflist { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px 14px; }
.preflist li { display: flex; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); padding: 6px 0; }
@media (max-width: 560px) { .jmap { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; } .jmap .tile { grid-column: auto !important; grid-row: auto !important; min-height: 64px; } }

.nav li a { white-space: nowrap; }
@media (max-width: 560px) { .nav ul li:nth-child(n+3) { display: none; } }

.hero.home .qentry { display: flex; gap: 8px 18px; flex-wrap: wrap; margin: 6px 0 0; font-size: .92rem; }
/* トップ最上部：今週の締切（スマホで最初の画面に入れる。1件は2行・タップで学校ページへ） */
.topdue { background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--warn); border-radius: 12px; padding: 12px 14px 10px; }
.topdue .tdhead { display: flex; justify-content: space-between; align-items: baseline; gap: 2px 12px; flex-wrap: wrap; }
.topdue h2 { margin: 0; font-size: 1.05rem; }
.topdue .tdnote { font-size: .75rem; color: var(--muted); }
.topdue .tdrows { list-style: none; margin: 6px 0 0; padding: 0; }
.topdue .tdrows li + li { border-top: 1px solid var(--line); }
.topdue .tdrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "name left" "what date"; gap: 0 10px; align-items: baseline; padding: 7px 0; color: var(--fg); text-decoration: none; line-height: 1.45; }
.topdue .tdrow:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.topdue .tdname { grid-area: name; font-weight: 700; font-size: .95rem; overflow-wrap: anywhere; }
.topdue .tdleft { grid-area: left; font-weight: 700; font-size: .9rem; color: var(--muted); white-space: nowrap; text-align: right; }
.topdue .tdrow.soon .tdleft { color: var(--warn); }
.topdue .tdwhat { grid-area: what; font-size: .8rem; color: var(--muted); overflow-wrap: anywhere; }
.topdue .tdd { grid-area: date; font-size: .8rem; color: var(--muted); font-family: var(--font-mono); white-space: nowrap; text-align: right; }
.topdue .tdstale { margin: 2px 0 0; font-size: .72rem; color: var(--muted); }
.topdue .tdempty { padding: 8px 0; font-size: .85rem; color: var(--muted); }
.topdue .tdmore { margin: 4px 0 0; padding-top: 8px; border-top: 1px solid var(--line); display: flex; gap: 6px 14px; flex-wrap: wrap; align-items: center; font-size: .88rem; }
.topdue .tdmore a { display: inline-block; padding: 5px 14px; min-height: 34px; line-height: 24px; border: 1px solid var(--accent); border-radius: 999px; text-decoration: none; font-weight: 700; }
.hero.home h1 .nb { display: inline-block; }
.quick .qmonth { grid-column: 1 / -1; margin: -4px 0 0; font-size: .75rem; color: var(--muted); line-height: 1.5; }
.quick .qmore { grid-column: 1 / -1; border: 1px dashed var(--line); border-radius: 10px; padding: 0 12px; background: color-mix(in srgb, var(--surface) 70%, transparent); }
.quick .qmore summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-weight: 700; font-size: .92rem; color: var(--accent); }
.quick .qmoregrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px 14px; padding-bottom: 12px; }
.quick .qmid { margin-left: 10px; }
@media (max-width: 520px) { .quick .qmid { display: block; margin: 6px 0 0; } }

.board .brow .bk { font-family: var(--font-body); font-size: .8rem; font-weight: 700; color: #13233a; background: #d7deea; }
.board .brow .bk.k-docs_deadline, .board .brow .bk.k-prescreen_close, .board .brow .bk.k-prereq_deadline { background: #f6c66b; }
/* 期限が過ぎた日程：グレー表示（案内板・学校ページ・書類・カレンダーで共通） */
.board .brow.past > span, .board .brow.past:hover > span { background: #3a4452; color: #a8b2bf; }
.board .brow.past .bleft { color: #a8b2bf; }
.past-tag { display: inline-block; font-size: .72rem; font-weight: 700; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 6px; margin-left: 6px; white-space: nowrap; }
.is-past { color: var(--muted); }
.is-past, .is-past * { text-decoration-color: var(--muted); }
.ev.is-past { opacity: .6; filter: grayscale(1); }
.board .brow .bk.k-exam { background: #9cc7f0; }
.board .brow .bk.k-enroll_deadline { background: #f3a08f; }
/* スマホ：1件ずつを枠（カード）で囲み、どの説明がどの学校のものか分かるようにする。件と件の間はすき間を空ける */
@media (max-width: 480px) {
  .board .brows { gap: 14px; }
  .board .brow { background: #1c3150; border: 1px solid #36507a; border-radius: 12px; padding: 8px; gap: 6px 4px; }
  .board .brow.soon { border-color: #f0b429; }
  .board .brow.past { background: #2b3441; border-color: #3f4a5a; }
  .board .brow:hover, .board .brow:focus-visible { background: #26406a; }
  .board .brow:is(:hover, :focus-visible, .past, .past:hover) > :is(.bd, .bs), .board .brow > :is(.bd, .bs) { background: transparent; }
  .board .brow.past > .bleft { background: transparent; }
  .board .brow .bs { white-space: normal; font-weight: 700; }
}
.board .bscope { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: .82rem; color: #d7deea; }
.board .bscope button { font: inherit; font-size: .8rem; background: transparent; color: #f0b429; border: 1px solid #3a4f6e; border-radius: 8px; padding: 4px 10px; cursor: pointer; }

.offtab { margin-top: 10px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; background: var(--surface); }
.offtab summary { cursor: pointer; font-weight: 700; font-size: .92rem; }
.offrows { display: grid; gap: 6px; margin-top: 6px; }
.offrow { border-top: 1px dashed var(--line); padding-top: 6px; font-size: .86rem; }
.offrow .on { display: flex; flex-wrap: wrap; gap: 4px; align-items: baseline; }
.offrow .rt { margin-left: auto; font-size: .74rem; border: 1px solid var(--line); border-radius: 999px; padding: 0 8px; white-space: nowrap; }
.offrow .rt.soft { color: var(--muted); }
.offrow .od { color: var(--muted); font-size: .82rem; overflow-wrap: anywhere; }
/* データ記事（/data/2027/）の集計表と、よくある質問（<details>）。狭い画面でも表が収まるよう、列を少なく・文字を小さめに */
table.dtbl { width: 100%; font-size: .9rem; }
table.dtbl th, table.dtbl td { padding: 8px 6px; }
table.dtbl .n { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.dnote { margin: 8px 0 0; font-size: .82rem; color: var(--muted); overflow-wrap: anywhere; }
.dlinks { margin: 8px 0 0; font-size: .88rem; }
.dlinks summary { cursor: pointer; min-height: 40px; display: flex; align-items: center; font-weight: 700; color: var(--accent); }
.dlinks dt { margin-top: 8px; font-weight: 700; }
.dlinks dd { margin: 2px 0 0; line-height: 1.8; overflow-wrap: anywhere; }
.dsec h3 { margin: 18px 0 6px; font-size: 1rem; }
/* 都市ごとの入口ページ（/city/<slug>/）：回ごとのカード。狭い画面でもページ全体は横にはみ出さない */
.cityrows { display: grid; gap: 10px; margin-top: 8px; }
.cityrow { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); padding: 12px 14px; display: grid; gap: 6px; min-width: 0; overflow-wrap: anywhere; }
.cityrow .chd { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.cityrow .pill.gen { border: 1px solid var(--line); color: var(--muted); }   /* 帰国生入試でない一般の入試の印 */
.cityrow .cnm { font-family: var(--font-display); font-weight: 700; }
.cityrow .crd { font-size: .9rem; }
.cityrow .meta2 { grid-template-columns: 6em minmax(0, 1fr); font-size: .9rem; }
.cityrow .cev { margin: 0 0 4px; }
.cityrow .cev .mono { font-family: var(--font-mono); white-space: nowrap; }
.cityrow.is-past { opacity: .7; }
.calsl { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.calsl li { display: grid; gap: 4px; padding-top: 8px; border-top: 1px solid var(--line); font-size: .92rem; }
.calsl .actions { margin-top: 2px; }
.faq-i { border-top: 1px solid var(--line); }
.faq-i summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; padding: 6px 0; font-weight: 700; }
.faq-a { padding: 0 0 10px; font-size: .92rem; overflow-wrap: anywhere; }
.faq-a p { margin: 0 0 6px; }

/* ===== 見た目の作り替え（2026-12、Hallmark のテーマ「Almanac」を下敷きにした restyle） =====
   並び・文言・リンク・スクリプトはそのまま。上の各ルールの色や角を、ここで後から上書きしている。色・書体・角・影・ボタンだけを「参考書・年鑑」の見た目に変える。
   紙はうすいスレート、文字は青みの黒、強調色は深いマゼンタ1色（画面の5%以下）。角は四角、影なし、線は2種類の太さ。 */
:root {
  --bg: oklch(90% 0.010 245); --surface: oklch(96% 0.006 245); --fg: oklch(18% 0.020 245); --muted: oklch(40% 0.016 245);
  --line: oklch(80% 0.012 240); --rule-firm: oklch(30% 0.018 240);
  --accent: oklch(45% 0.180 350); --accent-ink: oklch(97% 0.006 245); --accent-soft: oklch(93% 0.025 350);
  --hl: oklch(93% 0.050 95);
  --font-display: "Zen Kaku Gothic New", "Hiragino Sans", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: oklch(17% 0.018 245); --surface: oklch(21% 0.018 245); --fg: oklch(93% 0.008 245); --muted: oklch(72% 0.014 245);
    --line: oklch(32% 0.016 240); --rule-firm: oklch(80% 0.012 240);
    --accent: oklch(68% 0.120 350); --accent-ink: oklch(16% 0.020 245); --accent-soft: oklch(28% 0.050 350);
  }
}
:root[data-theme="dark"] {
  --bg: oklch(17% 0.018 245); --surface: oklch(21% 0.018 245); --fg: oklch(93% 0.008 245); --muted: oklch(72% 0.014 245);
  --line: oklch(32% 0.016 240); --rule-firm: oklch(80% 0.012 240);
  --accent: oklch(68% 0.120 350); --accent-ink: oklch(16% 0.020 245); --accent-soft: oklch(28% 0.050 350);
}
/* 角は四角、影なし。上の各ルールに角の丸み・影が個別に書いてあるので、まとめて上書きする（!important はこの2つだけ） */
*, *::before, *::after { border-radius: 0 !important; box-shadow: none !important; }
button, .chipbtn, .share-b, .sgate-a, .nstep-b > *, .sswitch a, .pill, .badge, .tagok { border-radius: 2px !important; }
/* 見出し：太い角ゴシック、見出しの下に濃い線1本 */
h1 { font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; }
h2 { font-weight: 700; padding-bottom: 6px; border-bottom: 2px solid var(--rule-firm); }
.card h2, .notes h2 { border-bottom-width: 2px; }
/* リンク：文字は黒、下線だけマゼンタ */
a { color: var(--fg); text-decoration-color: var(--accent); text-underline-offset: .15em; }
.nav ul a:hover { color: var(--fg); text-decoration: underline; text-decoration-color: var(--accent); }
/* 上の帯：紙の上に濃い線 */
.nav { background: var(--bg); border-bottom: 2px solid var(--rule-firm); }
.brand .mark { background: var(--fg); }
/* カード＝紙に刷ったページ：上に濃い線、内側は細い線 */
.card, .when .wc, .route, .hc, .topdue, .cityrow, .offtab, .jmap .tile, .steps li, .toollist a, .toollist .tl2, .nstep, .cal-sub {
  background: var(--surface); border: 1px solid var(--line); border-top: 2px solid var(--rule-firm);
}
/* トップの帯：ノート罫線をやめて、無地の紙＋濃い線 */
.hero.home { background: var(--surface); border: 0; border-top: 2px solid var(--rule-firm); border-bottom: 1px solid var(--line); }
.hero.home::before, .hero.home::after { display: none; }
.hero.home > * { padding-left: 0; }
/* ツールの色分け（虹色）をやめて1色に。アイコンは線画のまま */
.toollist a, .toollist a[href] { --tc: var(--fg); background: var(--surface); }
.toollist a > .ico, .toollist .tl2 > .ico { background: var(--bg); color: var(--fg); border: 1px solid var(--line); }
.toollist a:hover { border-color: var(--line); border-top-color: var(--accent); transform: none; }
.when .wc:nth-child(n), .steps li:nth-child(n) { --tc: var(--fg); }
.when .wc .k::before { background: var(--accent); }
.steps svg { background: var(--bg); }
.steps .n { background: var(--fg); color: var(--surface); }
.trust .tr { border-left: 2px solid var(--rule-firm); background: transparent; }
/* 表：見出しの下に濃い線、行は細い線 */
thead th, table th { border-bottom: 2px solid var(--rule-firm); }
tr.hl td { background: var(--accent-soft); }
tr.hl td:first-child { border-left: 2px solid var(--accent); }
/* 数字は等幅で桁をそろえる */
.num, td.grade, .stat .v, .quick .qn, .jmap .tile em, .gradebox .big { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.quick .qn, .jmap .tile em, .gradebox .big { color: var(--fg); }
/* ボタン：主ボタンはマゼンタの塗り、ほかは黒の細枠 */
button { background: transparent; border: 1px solid var(--fg); color: var(--fg); }
button.primary, .chipbtn, .sgate-a { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.sother a, .share-b, .nstep-b > *, .topdue .tdmore a, .toollist .tl2 .tl2-l a, .foldbtn { border: 1px solid var(--fg); color: var(--fg); background: transparent; }
input, select, textarea { border: 1px solid var(--muted); background: var(--surface); }
/* 選んでいる切り替えボタンは黒の塗り（マゼンタは主ボタンと線だけに取っておく） */
.sfilter .sfb[aria-pressed="true"], .nstep-b > .nstar[aria-pressed="true"] { background: var(--fg); border-color: var(--fg); color: var(--surface); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* 注意書きの帯：色の面をやめて、左の線だけ */
.overseas-note, .docs-warn, .open-points { background: transparent; }
/* 締切の案内板（ドット文字）は意味のある見た目なので残す。角だけ四角 */
