/*
Theme Name: JEIS 北海道教習センター
Theme URI:
Description: 株式会社JEIS北海道教習センターのオリジナルテーマ。小型船舶免許の取得・更新をわかりやすく伝えるため、スマートフォン表示を最優先に設計しています。
Author: K2
Version: 0.1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: jeis
*/

/* ==========================================================================
   1. デザイントークン
   ========================================================================== */
:root {
	--deep: #052B47;
	--marine: #0A8BC4;
	--marine-dk: #0876A8;
	--aqua: #22C3C8;
	--aqua-soft: #E2F7F6;
	--sky-soft: #EAF6FC;
	--coral: #FF5E3A;
	--coral-dk: #E84A28;
	--sun: #FFC23C;
	--sun-dk: #F0A81E;
	--teal: #17B89F;
	--ink: #16344C;
	--muted: #5A7488;
	--foam: #F4FBFE;
	--line: #DDE9F0;
	--white: #fff;

	--radius: 18px;
	--radius-sm: 10px;
	--maxw: 1180px;
	--gutter: 24px;
	--header-h: 68px;
	--ease: cubic-bezier(.22, .61, .36, 1);

	--font-ja: "Zen Kaku Gothic New", -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Noto Sans JP", sans-serif;
	--font-en: "Outfit", var(--font-ja);
}

/* ==========================================================================
   2. リセットと基本
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--header-h) + 16px);
	-webkit-text-size-adjust: 100%;
}

body {
	font-family: var(--font-ja);
	color: var(--ink);
	background: var(--foam);
	line-height: 1.9;
	font-size: 16px;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--marine-dk); text-decoration: underline; text-underline-offset: .18em; }
a:hover { color: var(--coral-dk); }
ul, ol { list-style-position: outside; }

:focus-visible {
	outline: 3px solid var(--coral);
	outline-offset: 2px;
	border-radius: 3px;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px; height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
}

.skip-link {
	position: absolute;
	left: 12px; top: -60px;
	z-index: 200;
	background: var(--coral);
	color: #fff;
	padding: 10px 18px;
	border-radius: 0 0 10px 10px;
	font-weight: 700;
	text-decoration: none;
	transition: top .2s;
}
.skip-link:focus { top: 0; color: #fff; }

.wrap {
	max-width: var(--maxw);
	margin-inline: auto;
	padding-inline: var(--gutter);
}

/* ==========================================================================
   3. ボタン
   ========================================================================== */
.btn {
	font-family: var(--font-ja);
	font-weight: 700;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	padding: 14px 26px;
	border-radius: 999px;
	font-size: 1rem;
	line-height: 1.5;
	cursor: pointer;
	border: none;
	text-decoration: none;
	transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-coral { background: var(--coral); color: #fff; box-shadow: 0 10px 24px -8px rgba(255, 94, 58, .6); }
.btn-coral:hover { transform: translateY(-3px); background: var(--coral-dk); color: #fff; }
.btn-sun { background: var(--sun); color: var(--deep); box-shadow: 0 10px 24px -8px rgba(240, 168, 30, .6); }
.btn-sun:hover { transform: translateY(-3px); background: var(--sun-dk); color: var(--deep); }
.btn-line { background: #fff; color: var(--deep); border: 1.5px solid var(--line); }
.btn-line:hover { transform: translateY(-3px); box-shadow: 0 12px 26px -12px rgba(5, 43, 71, .4); color: var(--deep); }

/* ==========================================================================
   4. ヘッダー / ナビゲーション
   ========================================================================== */
.site-header {
	position: sticky;
	top: 0;
	z-index: 60;
	background: rgba(255, 255, 255, .94);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid var(--line);
}
.site-header .nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	max-width: var(--maxw);
	margin-inline: auto;
	padding: 10px var(--gutter);
	min-height: var(--header-h);
}

.brand { display: flex; flex-direction: column; line-height: 1.15; text-decoration: none; color: var(--deep); }
.brand b { font-family: var(--font-en); font-weight: 800; font-size: 1.35rem; letter-spacing: .04em; }
.brand span { font-size: .68rem; letter-spacing: .1em; color: var(--muted); font-weight: 500; }

.global-nav > ul { display: flex; align-items: stretch; gap: 2px; list-style: none; }
.global-nav li { position: relative; }
.global-nav > ul > li > a {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 2px;
	padding: 8px 14px;
	min-height: 52px;
	font-size: .95rem;
	font-weight: 700;
	letter-spacing: .01em;
}
/* 日本語ラベルの下に小さく英語を添えて、視認性を上げる */
.global-nav > ul > li > a::before {
	font-family: var(--font-en);
	font-size: .58rem;
	font-weight: 600;
	letter-spacing: .12em;
	color: var(--marine);
	opacity: .75;
	order: 2;
}
.global-nav > ul > li:nth-child(1) > a::before { content: "GET LICENSE"; }
.global-nav > ul > li:nth-child(2) > a::before { content: "RENEWAL"; }
.global-nav > ul > li:nth-child(3) > a::before { content: "PROFESSIONAL"; }
.global-nav > ul > li:nth-child(4) > a::before { content: "DOWNLOAD"; }

.global-nav a {
	display: block;
	padding: 10px 12px;
	font-size: .9rem;
	font-weight: 500;
	color: var(--ink);
	text-decoration: none;
	border-radius: 8px;
	transition: color .2s, background .2s;
}
.global-nav a:hover,
.global-nav .current-menu-item > a,
.global-nav .current_page_item > a { color: var(--marine); background: var(--sky-soft); }

.global-nav .sub-menu {
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 250px;
	background: #fff;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	box-shadow: 0 20px 44px -24px rgba(5, 43, 71, .5);
	padding: 8px;
	list-style: none;
	opacity: 0;
	visibility: hidden;
	transform: translateY(8px);
	transition: opacity .22s var(--ease), transform .22s var(--ease), visibility .22s;
}
.global-nav li:hover > .sub-menu,
.global-nav li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.global-nav .sub-menu a { font-size: .88rem; padding: 9px 12px; }
.global-nav .menu-item-has-children > a::after {
	content: "";
	display: inline-block;
	width: 6px; height: 6px;
	margin-left: 7px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: translateY(-2px) rotate(45deg);
}
.global-nav .submenu-toggle { display: none; }

/* --- 「免許を取る」の2列ドロップダウン ------------------------------------ */
.global-nav .has-mega > .sub-menu {
	width: 580px;
	padding: 20px;
	display: grid;
	grid-auto-flow: column;
	grid-template-rows: repeat(3, auto);
	grid-template-columns: 1.25fr 1fr;
	gap: 4px 22px;
}
.global-nav .sub-menu .menu-desc {
	display: block;
	font-family: var(--font-en);
	font-size: .78rem;
	font-weight: 700;
	color: var(--coral);
	margin-top: 2px;
	letter-spacing: .01em;
}
/* グループ見出し（先頭項目に付与した is-head クラスで出す） */
.global-nav .sub-menu .is-head::before {
	display: block;
	font-family: var(--font-en);
	font-size: .62rem;
	font-weight: 700;
	letter-spacing: .14em;
	color: var(--muted);
	padding: 0 12px 8px;
	margin-bottom: 4px;
	border-bottom: 1px solid var(--line);
}
.global-nav .sub-menu .mega-course.is-head::before { content: "COURSE ／ コースを選ぶ"; }
.global-nav .sub-menu .mega-info.is-head::before { content: "GUIDE ／ はじめての方へ"; }

.global-nav .sub-menu .mega-course > a {
	padding: 11px 12px;
	font-weight: 700;
	color: var(--deep);
	font-size: .92rem;
	border-radius: 10px;
}
.global-nav .sub-menu .mega-info > a { font-size: .88rem; color: var(--ink); }
.global-nav .sub-menu .mega-info > a::before {
	content: "・";
	color: var(--marine);
	margin-right: 2px;
}

/* --- ヘッダー右側（電話＋お問い合わせ） ----------------------------------- */
.header-actions { display: flex; align-items: center; gap: 14px; flex: none; }

.header-tel {
	display: flex;
	align-items: center;
	gap: 8px;
	text-decoration: none;
	color: var(--deep);
	white-space: nowrap;
}
.header-tel svg { width: 19px; height: 19px; color: var(--marine); flex: none; }
.header-tel small {
	display: block;
	font-size: .62rem;
	color: var(--muted);
	letter-spacing: .04em;
	line-height: 1.3;
}
.header-tel b {
	display: block;
	font-family: var(--font-en);
	font-size: 1.16rem;
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: .01em;
}
.header-tel:hover { color: var(--marine); }

/* --- スマートフォンのメニュー内ボタン（PCでは非表示） --------------------- */
.nav-foot { display: none; }

.header-cta {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 11px 20px;
	border-radius: 999px;
	background: var(--coral);
	color: #fff !important;
	font-weight: 700;
	font-size: .88rem;
	text-decoration: none;
	white-space: nowrap;
	transition: transform .25s, background .25s;
}
.header-cta:hover { transform: translateY(-2px); background: var(--coral-dk); }

.burger {
	display: none;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 46px; height: 46px;
	background: none;
	border: 1px solid var(--line);
	border-radius: 10px;
	cursor: pointer;
}
.burger .bar {
	display: block;
	width: 22px; height: 2.5px;
	margin-inline: auto;
	background: var(--deep);
	border-radius: 2px;
	transition: transform .3s var(--ease), opacity .2s;
}
.burger[aria-expanded="true"] .bar:nth-of-type(2) { transform: translateY(7.5px) rotate(45deg); }
.burger[aria-expanded="true"] .bar:nth-of-type(3) { opacity: 0; }
.burger[aria-expanded="true"] .bar:nth-of-type(4) { transform: translateY(-7.5px) rotate(-45deg); }

/* ==========================================================================
   5. ページヘッダー
   ========================================================================== */
.page-hero {
	position: relative;
	background: linear-gradient(180deg, rgba(10, 139, 196, .82), rgba(5, 43, 71, .9)),
		#0a6a9c url(assets/img/hero.jpg) center/cover no-repeat;
	color: #fff;
	padding: clamp(38px, 6vw, 68px) 0 clamp(46px, 7vw, 78px);
	overflow: hidden;
}
.page-hero .eyebrow {
	font-family: var(--font-en);
	font-weight: 600;
	letter-spacing: .18em;
	text-transform: uppercase;
	font-size: .74rem;
	color: #fff;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	opacity: .95;
}
.page-hero .eyebrow::before { content: ""; width: 26px; height: 2px; background: var(--sun); display: inline-block; }
.page-hero h1 {
	font-weight: 900;
	font-size: clamp(1.6rem, 4.2vw, 2.7rem);
	line-height: 1.3;
	margin-top: 12px;
	text-shadow: 0 4px 24px rgba(5, 43, 71, .35);
}
.page-hero .waves { position: absolute; left: 0; right: 0; bottom: -1px; line-height: 0; pointer-events: none; }
.page-hero .waves svg { width: 100%; height: 46px; display: block; }

/* ==========================================================================
   6. パンくず
   ========================================================================== */
.breadcrumb { background: #fff; border-bottom: 1px solid var(--line); font-size: .78rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; list-style: none; padding: 11px 0; }
.breadcrumb li { display: flex; align-items: center; gap: 6px; color: var(--muted); }
.breadcrumb li + li::before { content: "›"; color: #a9c2d2; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--marine); text-decoration: underline; }
.breadcrumb [aria-current] { color: var(--deep); font-weight: 700; }

/* ==========================================================================
   7. 本文エリア
   ========================================================================== */
.site-main { padding: clamp(34px, 5vw, 60px) 0 clamp(52px, 7vw, 84px); }

.entry-card {
	background: #fff;
	border-radius: var(--radius);
	box-shadow: 0 26px 60px -44px rgba(5, 43, 71, .5);
	padding: clamp(22px, 4vw, 52px);
}

.entry-content { font-size: 1rem; }
.entry-content > * + * { margin-top: 1.1em; }

.entry-content h1, .entry-content h2, .entry-content h3,
.entry-content h4, .entry-content h5, .entry-content h6 {
	color: var(--deep);
	line-height: 1.45;
	font-weight: 900;
	scroll-margin-top: calc(var(--header-h) + 20px);
}
.entry-content h2 {
	font-size: clamp(1.25rem, 2.6vw, 1.7rem);
	margin-top: 2.2em;
	padding-bottom: .5em;
	border-bottom: 3px solid var(--sky-soft);
	position: relative;
}
.entry-content h2::after {
	content: "";
	position: absolute;
	left: 0; bottom: -3px;
	width: 76px; height: 3px;
	background: var(--coral);
	border-radius: 2px;
}
.entry-content h3 {
	font-size: clamp(1.1rem, 2.1vw, 1.35rem);
	margin-top: 1.9em;
	padding-left: 14px;
	border-left: 5px solid var(--marine);
}
.entry-content h4 {
	font-size: clamp(1.02rem, 1.8vw, 1.16rem);
	margin-top: 1.7em;
	color: var(--marine-dk);
}
.entry-content h5, .entry-content h6 {
	font-size: 1rem;
	margin-top: 1.5em;
	color: var(--marine-dk);
}
.entry-content h2:first-child, .entry-content h3:first-child, .entry-content h4:first-child { margin-top: 0; }

.entry-content p { line-height: 1.95; }
.entry-content strong { font-weight: 700; color: var(--deep); }
.entry-content ul, .entry-content ol { padding-left: 1.4em; }
.entry-content li + li { margin-top: .45em; }
.entry-content ul li::marker { color: var(--marine); }
.entry-content ol li::marker { color: var(--marine); font-weight: 700; }

.entry-content hr {
	border: none;
	border-top: 1px dashed var(--line);
	margin-block: 2.2em;
}

.entry-content figure { margin-block: 1.4em; }
.entry-content .wp-block-image img { border-radius: var(--radius-sm); }
.entry-content .wp-block-image a:hover img { opacity: .88; }
.entry-content figcaption { font-size: .82rem; color: var(--muted); margin-top: .6em; text-align: center; }

.entry-content .wp-block-columns { gap: 20px; }

/* PDF リンク */
.entry-content .jeis-pdf-link {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-weight: 700;
	text-decoration: none;
	color: var(--marine-dk);
	background: var(--sky-soft);
	border: 1px solid #cfe4f0;
	border-radius: 999px;
	padding: 7px 16px;
	transition: background .2s, transform .2s;
}
.entry-content .jeis-pdf-link::before {
	content: "PDF";
	font-family: var(--font-en);
	font-size: .64rem;
	font-weight: 800;
	letter-spacing: .04em;
	background: var(--coral);
	color: #fff;
	padding: 2px 6px;
	border-radius: 4px;
}
.entry-content .jeis-pdf-link:hover { background: #dcecf7; transform: translateY(-2px); color: var(--marine-dk); }

/* ==========================================================================
   8. 表
   --------------------------------------------------------------------------
   現行サイトの日程表は最大10列。まずは破綻せず読めることを担保する。
   ========================================================================== */
.jeis-table-scroll {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	margin-block: 1.4em;
	border-radius: var(--radius-sm);
	border: 1px solid var(--line);
	background:
		linear-gradient(90deg, #fff 30%, rgba(255, 255, 255, 0)) left / 40px 100% no-repeat,
		linear-gradient(270deg, #fff 30%, rgba(255, 255, 255, 0)) right / 40px 100% no-repeat,
		radial-gradient(farthest-side at 0 50%, rgba(5, 43, 71, .16), transparent) left / 14px 100% no-repeat,
		radial-gradient(farthest-side at 100% 50%, rgba(5, 43, 71, .16), transparent) right / 14px 100% no-repeat;
	background-attachment: local, local, scroll, scroll;
}
.jeis-table-scroll:focus-visible { outline: 3px solid var(--coral); }

/* 横スクロールが必要なときだけ案内を出す */
.jeis-table-scroll.is-scrollable { position: relative; }
.jeis-table-scroll.is-scrollable::before {
	content: "← 横にスクロールできます →";
	display: block;
	font-size: .72rem;
	font-weight: 700;
	color: var(--marine-dk);
	background: var(--sky-soft);
	text-align: center;
	padding: 5px;
	border-bottom: 1px solid var(--line);
	position: sticky;
	left: 0;
}
@media (min-width: 901px) {
	.jeis-table-scroll.is-scrollable::before { display: none; }
}

.entry-content table {
	border-collapse: collapse;
	width: 100%;
	min-width: 560px;
	font-size: .88rem;
	background: #fff;
}
.entry-content thead th,
.entry-content tr:first-child th {
	background: var(--deep);
	color: #fff;
	font-weight: 700;
}
.entry-content th, .entry-content td {
	border: 1px solid var(--line);
	padding: 10px 12px;
	vertical-align: middle;
	line-height: 1.7;
}
.entry-content tbody tr:nth-child(even) { background: #fafdff; }
.entry-content tbody tr:hover { background: var(--sky-soft); }
.entry-content table a { font-weight: 700; }

/* 空セルだらけの列が潰れないようにする */
.entry-content td:empty, .entry-content th:empty { min-width: 26px; }

/* ==========================================================================
   9. お問い合わせ導線（本文下）
   ========================================================================== */
.contact-band {
	background: linear-gradient(180deg, var(--marine), var(--deep));
	color: #fff;
	padding: clamp(40px, 6vw, 64px) 0;
	text-align: center;
	position: relative;
	overflow: hidden;
}
.contact-band h2 { font-size: clamp(1.35rem, 3vw, 2rem); font-weight: 900; }
.contact-band p { color: rgba(255, 255, 255, .88); margin-top: 10px; font-size: .95rem; }
.contact-band .actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 24px; }

.office-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 16px;
	margin-top: 28px;
	text-align: left;
}
.office-card {
	background: rgba(255, 255, 255, .08);
	border: 1px solid rgba(255, 255, 255, .18);
	border-radius: var(--radius-sm);
	padding: 18px 20px;
}
.office-card h3 { font-size: 1rem; font-weight: 800; color: var(--sun); }
.office-card p { font-size: .85rem; color: rgba(255, 255, 255, .9); margin-top: 6px; line-height: 1.8; }
.office-card .tel {
	font-family: var(--font-en);
	font-size: 1.3rem;
	font-weight: 800;
	color: #fff;
	text-decoration: none;
	display: inline-block;
	margin-top: 6px;
}
.office-card .tel:hover { color: var(--sun); }

/* ==========================================================================
   10. フッター
   ========================================================================== */
.site-footer { background: #04223a; color: #88a8c0; padding: clamp(38px, 5vw, 54px) 0 26px; font-size: .88rem; }
.site-footer a { color: #b9d2e2; text-decoration: none; }
.site-footer a:hover { color: var(--aqua); text-decoration: underline; }
.footer-top { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 28px; }
.site-footer .brand { color: #fff; }
.site-footer .brand b { color: #fff; }
.site-footer .brand span { color: #88a8c0; }
.footer-nav ul { display: flex; flex-wrap: wrap; gap: 10px 24px; list-style: none; }
.footer-bar {
	margin-top: 32px;
	padding-top: 18px;
	border-top: 1px solid rgba(255, 255, 255, .1);
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 8px;
	font-size: .76rem;
}

/* ==========================================================================
   11. 投稿一覧 / 検索 / 404
   ========================================================================== */
.post-list { display: grid; gap: 14px; }
.post-item {
	background: #fff;
	border: 1px solid var(--line);
	border-radius: var(--radius-sm);
	padding: 18px 22px;
	transition: transform .25s var(--ease), box-shadow .25s;
}
.post-item:hover { transform: translateY(-3px); box-shadow: 0 18px 36px -26px rgba(5, 43, 71, .5); }
.post-item time { font-family: var(--font-en); font-size: .8rem; color: var(--muted); }
.post-item h2 { font-size: 1.1rem; margin-top: 4px; }
.post-item h2 a { color: var(--deep); text-decoration: none; }
.post-item h2 a:hover { color: var(--marine); }

.pagination { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 32px; }
.pagination .page-numbers {
	display: inline-flex; align-items: center; justify-content: center;
	min-width: 42px; height: 42px; padding: 0 12px;
	background: #fff; border: 1px solid var(--line); border-radius: 10px;
	text-decoration: none; color: var(--ink); font-weight: 700;
}
.pagination .current { background: var(--marine); border-color: var(--marine); color: #fff; }

.search-form { display: flex; gap: 8px; max-width: 460px; }
.search-form input[type="search"] {
	flex: 1;
	font-family: inherit; font-size: 1rem;
	padding: 12px 16px;
	border: 1px solid var(--line);
	border-radius: 10px;
	background: #fff;
}

/* ==========================================================================
   12. フォーム（MW WP Form / Contact Form 7 共通）
   ========================================================================== */
.entry-content input[type="text"],
.entry-content input[type="email"],
.entry-content input[type="tel"],
.entry-content input[type="url"],
.entry-content input[type="number"],
.entry-content select,
.entry-content textarea {
	font-family: inherit;
	font-size: 16px; /* iOS で自動ズームさせない */
	color: var(--ink);
	background: #fff;
	border: 1px solid #c9dbe6;
	border-radius: 8px;
	padding: 11px 13px;
	max-width: 100%;
	transition: border-color .2s, box-shadow .2s;
}
.entry-content input:focus, .entry-content select:focus, .entry-content textarea:focus {
	border-color: var(--marine);
	box-shadow: 0 0 0 3px rgba(10, 139, 196, .16);
	outline: none;
}
.entry-content input[type="submit"], .entry-content button[type="submit"] {
	font-family: inherit;
	font-weight: 700;
	font-size: 1rem;
	background: var(--coral);
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 14px 34px;
	cursor: pointer;
	transition: background .2s, transform .2s;
}
.entry-content input[type="submit"]:hover, .entry-content button[type="submit"]:hover {
	background: var(--coral-dk);
	transform: translateY(-2px);
}
.entry-content input[type="checkbox"], .entry-content input[type="radio"] {
	width: 19px; height: 19px;
	accent-color: var(--marine);
	vertical-align: -4px;
	margin-right: 5px;
}
.mwform-checkbox-field, .mwform-radio-field { display: inline-block; margin: 3px 14px 3px 0; }

/* ==========================================================================
   13. レスポンシブ
   ========================================================================== */
@media (max-width: 1180px) {
	:root { --gutter: 18px; }
	.global-nav > ul > li > a { padding: 8px 10px; font-size: .89rem; }
	.header-tel b { font-size: 1.02rem; }
	.header-cta { padding: 10px 16px; font-size: .82rem; }
	.global-nav .has-mega > .sub-menu { width: 500px; }
}

@media (max-width: 1000px) {
	/* 電話番号はアイコンのみに切り詰めて、ナビの幅を確保する */
	.header-tel span { display: none; }
	.header-tel { width: 42px; height: 42px; justify-content: center; border: 1px solid var(--line); border-radius: 10px; }
	.header-tel svg { width: 20px; height: 20px; }
}

@media (max-width: 900px) {
	.burger { display: flex; }
	.header-actions { display: none; }

	/* backdrop-filter は position:fixed の含みブロックを作ってしまい、
	   モバイルのドロワー(.global-nav)の高さが header 内に閉じ込められる。
	   モバイルでは不透明ヘッダーなので blur を外し、ドロワーがビューポート基準で
	   全画面に開くようにする。 */
	.site-header { backdrop-filter: none; background: #fff; }

	.global-nav {
		position: fixed;
		inset: var(--header-h) 0 0 0;
		background: #fff;
		overflow-y: auto;
		padding: 12px var(--gutter) 40px;
		transform: translateX(100%);
		visibility: hidden;
		transition: transform .32s var(--ease), visibility .32s;
		border-top: 1px solid var(--line);
	}
	body.nav-open { overflow: hidden; }
	body.nav-open .global-nav { transform: none; visibility: visible; }

	.global-nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
	.global-nav li { border-bottom: 1px solid var(--line); }
	.global-nav a { padding: 15px 4px; font-size: 1rem; font-weight: 700; border-radius: 0; }
	.global-nav > ul > li > a { min-height: 0; padding: 15px 4px; font-size: 1.02rem; }
	.global-nav > ul > li > a::before { font-size: .56rem; }
	.global-nav .menu-item-has-children > a::after { display: none; }

	/* 2列のドロップダウンは1列に戻す。
	   モバイルでは他のサブメニューと同様、初期は閉じておき、
	   チェブロン(.submenu-toggle)で開閉する（display は .sub-menu の既定=none に従わせる）。 */
	.global-nav .has-mega > .sub-menu {
		width: auto;
		display: none;               /* デスクトップの display:grid を打ち消し、初期は閉じる */
		grid-template-columns: 1fr;  /* 開いたときは1列で縦積み */
		padding: 0 0 8px 14px;
	}
	/* チェブロンで開いたとき（mega/通常とも block で縦に開く） */
	.global-nav .submenu-toggle[aria-expanded="true"] + .sub-menu { display: block; }
	.global-nav .sub-menu .is-head::before { padding-left: 0; padding-right: 0; margin-top: 6px; }
	.global-nav .sub-menu .mega-course > a { padding: 12px 4px; }
	.global-nav .sub-menu .menu-desc { font-size: .8rem; }

	/* メニュー内の行動ボタン */
	.nav-foot { display: grid; gap: 10px; margin-top: 26px; }
	.nav-tel {
		display: flex;
		align-items: center;
		gap: 12px;
		padding: 13px 16px;
		border: 1.5px solid var(--marine);
		border-radius: 12px;
		text-decoration: none;
		color: var(--deep);
		background: var(--sky-soft);
	}
	.nav-tel svg { width: 22px; height: 22px; color: var(--marine); flex: none; }
	.nav-tel small { display: block; font-size: .72rem; color: var(--muted); }
	.nav-tel b { display: block; font-family: var(--font-en); font-size: 1.35rem; font-weight: 800; line-height: 1.2; }
	.nav-contact { width: 100%; }

	.global-nav .submenu-toggle {
		display: flex;
		align-items: center;
		justify-content: center;
		position: absolute;
		top: 4px; right: 0;
		width: 48px; height: 48px;
		background: none; border: none; cursor: pointer;
		color: var(--marine);
	}
	.global-nav .submenu-toggle svg { width: 20px; height: 20px; transition: transform .25s; }
	.global-nav .submenu-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }

	.global-nav .sub-menu {
		position: static;
		opacity: 1;
		visibility: visible;
		transform: none;
		box-shadow: none;
		border: none;
		border-radius: 0;
		padding: 0 0 8px 14px;
		display: none;
		min-width: 0;
	}
	.global-nav .submenu-toggle[aria-expanded="true"] + .sub-menu { display: block; }
	.global-nav .sub-menu li { border-bottom: none; }
	.global-nav .sub-menu a { font-size: .92rem; padding: 10px 4px; color: var(--muted); font-weight: 500; }

	.office-grid { grid-template-columns: 1fr; }
	.entry-content .wp-block-columns { flex-wrap: wrap !important; }
	.entry-content .wp-block-column { flex-basis: 100% !important; }
}

@media (max-width: 600px) {
	body { font-size: 15.5px; line-height: 1.85; }
	.brand b { font-size: 1.15rem; }
	.brand span { font-size: .6rem; }
	.entry-card { padding: 20px 16px; border-radius: 14px; }
	.entry-content table { font-size: .82rem; min-width: 520px; }
	.entry-content th, .entry-content td { padding: 8px 9px; }
	.footer-nav ul { gap: 8px 16px; }
	.footer-bar { flex-direction: column; }
}

/* ==========================================================================
   14. アニメーション抑制設定への対応
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after {
		animation-duration: .01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: .01ms !important;
	}
}

/* ==========================================================================
   15. 印刷
   ========================================================================== */
@media print {
	.site-header, .breadcrumb, .contact-band, .site-footer, .page-hero .waves { display: none !important; }
	body { background: #fff; }
	.entry-card { box-shadow: none; padding: 0; }
	.jeis-table-scroll { overflow: visible; border: none; }
	.entry-content table { min-width: 0; }
}
