/*
 * スマホ表示（幅767px以下）用のレスポンシブ調整
 * 既存のスマホ用CSS（幅600px固定の設計）の後に読み込み、固定幅を解除して画面幅に合わせる。
 * viewport は width=device-width。ここに書いた内容は幅767px以下にだけ適用される。
 */
@media screen and (max-width: 767px) {

/* ---------- 共通 ---------- */
html {
	-webkit-text-size-adjust: 100%;
}
body {
	font-size: 105%;
	line-height: 1.5;
	background: none;
	margin-bottom: 0;
}
img {
	max-width: 100%;
	height: auto;
}
.clearfix {
	display: block;
}

.tagArea {
	width: auto !important;
	box-sizing: border-box;
	font-size: 72%;
	line-height: 1.3;
	padding: 4px 8px;
}
#all_wrapper,
#header,
#contents,
#footer,
#menuList {
	width: auto !important;
	box-sizing: border-box;
}

/* ヘッダー（トップ以外）：ロゴと年度画像を横に並べ、狭いときは年度画像を縮小 */
#header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 8px 10px;
	overflow: hidden;
}
#header h1 {
	float: none;
	flex: none;
	margin: 0;
}
#header h2 {
	float: none;
	flex: 1 1 0;
	min-width: 0;
	margin: 0 0 0 10px;
	text-align: right;
}
#header h2 img {
	max-width: 100%;
	height: auto;
}

/* フッターメニュー */
#menuList a {
	width: auto !important;
	box-sizing: border-box;
}
#menuList li a:not(.noListLink):after {
	right: 14px;
}
#footer .address {
	padding: 0.7em 10px 0 10px;
	font-size: 90%;
}
#footer .copyright {
	margin-right: 10px;
	font-size: 80%;
}
.toTop {
	margin: 1.5em 0;
}
.toTop a {
	margin-left: 10px;
	margin-right: 10px;
}
.toTop a:before,
.toTop a:after {
	box-sizing: border-box;
	width: 100%;
}
.toTop a:after {
	width: calc(100% - 6px);
}

.information {
	width: auto !important;
	box-sizing: border-box;
	margin-left: 10px;
	margin-right: 10px;
}
.information p {
	margin-left: 15px;
	margin-right: 15px;
}
.titleBar {
	font-size: 100%;
}

/* ---------- トップページ ---------- */
body.topPage #all_wrapper {
	display: flex;
	flex-direction: column;
}
/* 内容・フッターの子要素を #all_wrapper の直下に並べ替え、メニュー写真を見出しの直後へ */
body.topPage #contents,
body.topPage #footer,
body.topPage #menuList {
	display: contents;
}
body.topPage #all_wrapper > *,
body.topPage #contents > *,
body.topPage #footer > *,
body.topPage #menuList > * {
	order: 20;
}
body.topPage #header { order: 1; }
body.topPage #contents > .catch { order: 2; }
body.topPage #contents > .smtMenu { display: none; }
body.topPage #menuList .topMenu { order: 3; }
body.topPage #contents > .information { order: 4; }
body.topPage #contents > .jukuBtnArea { order: 5; }
body.topPage #schedule { order: 6; }
body.topPage #juku { order: 7; }
body.topPage #contents > .toTop { order: 8; }
body.topPage #menuList > ul:first-child { order: 9; }
body.topPage #menuList > .footerNav { order: 10; display: block !important; }
body.topPage #menuList > ul:last-child { order: 11; }
body.topPage #footer .address { order: 12; }
body.topPage #footer .copyright { order: 13; }
body.topPage #pageStart { order: 0; }
/* フッターの太線（他のページでは #footer と #menuList の枠線） */
body.topPage #menuList > ul:first-child {
	border-top: 2px solid #ffb300;
}
body.topPage #menuList > ul:last-child {
	border-bottom: 2px solid #ffb300;
	margin-bottom: 1em;
}
body.topPage.tokushima #menuList > ul:first-child {
	border-top-color: #aacd06;
}
body.topPage.tokushima #menuList > ul:last-child {
	border-bottom-color: #aacd06;
}
body.topPage .hidden { display: none; }

body.topPage #header {
	background-color: transparent;
	display: block;
	padding: 0;
}
body.topPage #header h1 {
	margin: 14px auto;
	width: 70%;
	max-width: 400px;
}
body.topPage #header h1 a {
	width: 100%;
	height: 0;
	padding-top: 32%;
	background-size: 100% 100%;
}
body.topPage .catch {
	padding: 14px 8px 12px 8px;
	text-align: center;
}
body.topPage .catch .honban,
body.topPage .catch h2 img {
	width: 100%;
	max-width: 594px;
	height: auto;
}
body.topPage .catch h2 {
	margin-top: 3px;
}

/* メニュー写真：写真は背景、リンクはその下に並べる */
body.topPage #menuList .topMenu {
	position: static;
	width: auto;
	height: auto;
	margin: 0;
	padding: 0 10px 0 10px;
	list-style: none;
	background-size: 100% auto;
	background-position: 50% 0;
	background-repeat: no-repeat;
	padding-top: 76.8%;
}
body.topPage #menuList .topMenu li {
	display: block;
	list-style: none;
}
body.topPage #menuList .topMenu a {
	width: auto;
	margin: 0.4em 0;
	padding: 4px 0 4px 15px;
	box-sizing: border-box;
}

/* フッター用に複製したメニュー：他のページのフッターと同じ矢印を表示 */
body.topPage #menuList .footerNav li a:not(.noListLink):after,
body.topPage #menuList .footerMenu li a:not(.noListLink):after {
	border-top: solid 3px #979797;
	border-right: solid 3px #979797;
}

body.topPage .information {
	margin-top: 14px;
	margin-bottom: 0.6em;
}
body.topPage .information[style] {
	top: auto !important;
}

body.topPage .jukuBtnArea {
	padding: 0 10px;
	overflow: hidden;
}
body.topPage .jukuBtn {
	float: right;
	margin: 12px 0 8px 0;
	font-size: 90%;
}

body.topPage #schedule {
	width: auto;
	padding-top: 0;
	clear: both;
}
body.topPage #schedule.paddingTop,
body.topPage #schedule.paddingTop_start {
	padding-top: 0;
}
body.topPage #schedule .table {
	width: auto;
}
body.topPage #schedule ul {
	font-size: 110%;
	line-height: 1.4;
}
body.topPage #schedule h4 {
	font-size: 100%;
}
body.topPage #schedule .finishMes {
	font-size: 90%;
}
/* 回の名前と日付：同じ行に収まるときは間隔を狭く並べ、収まらないときは日付を次の行へ */
body.topPage #schedule li {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	column-gap: 1em;
	row-gap: 0.15em;
	width: auto;
	padding: 12px 10px;
	box-sizing: border-box;
	overflow: hidden;
}
body.topPage #schedule h4 {
	float: none;
	width: auto;
	flex: 0 0 auto;
}
body.topPage #schedule .date {
	float: none;
	width: auto;
	flex: 1 1 auto;
}
body.topPage #schedule .note {
	width: auto;
	padding: 0 10px 14px 10px;
	box-sizing: border-box;
}
.rangeBtn a {
	box-sizing: border-box;
}

body.topPage #juku {
	width: auto;
	padding-top: 14px;
}
body.topPage #juku .note {
	margin: 0 10px;
	font-size: 100%;
	font-weight: bold;
}
body.topPage #juku .table,
body.topPage #juku ul {
	width: auto;
}
body.topPage #juku ul {
	font-size: 110%;
	line-height: 1.4;
}
body.topPage #juku h4 {
	font-size: 100%;
	font-weight: bold;
}
body.topPage #juku h5,
body.topPage #juku .tel {
	font-size: 100%;
}
body.topPage #juku li {
	width: auto;
	padding: 8px 10px;
	box-sizing: border-box;
	overflow: hidden;
}
body.topPage #juku h5 {
	float: left;
	width: 62%;
}
body.topPage #juku .tel {
	float: right;
	width: 36%;
	text-align: right;
}

/* ---------- 本文ページ共通：固定幅（600px・720px など）を画面幅に収める ---------- */
#contents,
#contents * {
	box-sizing: border-box;
	max-width: 100%;
}
/* 本文の左右に余白（ヘッダー・メニュー・フッターは画面幅いっぱいのまま）。本文とフッターのメニューの間は2行分あける */
#contents {
	padding-left: 12px;
	padding-right: 12px;
	padding-bottom: 3em;
}
body.topPage #juku {
	margin-bottom: 3em;
}
body.topPage .jukuBtnArea {
	padding-left: 12px;
	padding-right: 12px;
}
body.topPage .information {
	margin-left: 12px;
	margin-right: 12px;
}
.topArea .title img,
.titleImg img {
	max-width: 100%;
}
.link {
	margin-left: 0 !important;
}
.link a {
	margin-left: auto;
	margin-right: auto;
}
.schedule {
	width: auto !important;
	margin-left: 10px;
	margin-right: 10px;
}
.schedule table {
	width: 100% !important;
}
.schedule table th,
.schedule table td {
	width: auto !important;
}
.schedule table th.start,
.schedule table th.end {
	white-space: nowrap;
}
.schedule table td {
	letter-spacing: 1px;
}

.message,
.ready,
.placeArea,
.placeArea .leftArea,
.placeArea .rightArea,
.placeArea .centerArea,
.placeArea .centerArea2,
.topArea,
.siryou,
.tokucyo,
.detail {
	width: auto !important;
}
.placeArea .centerArea,
.placeArea .centerArea2 {
	margin-left: 10px;
	margin-right: 10px;
}

/* 幅600px固定のカードや画像を、表示幅いっぱい（左右の余白を同じ）にする */
.tokucyo ul,
.tokucyo li,
.point,
.point li,
.detail .leftArea,
.detail .rightArea,
.info,
.info .date {
	width: auto !important;
}
.paperArea {
	margin-left: 0;
	margin-right: 0;
}
.paperArea img {
	width: 100% !important;
	height: auto;
}

/* 枠付きの見出しボックスの背景（600px幅の画像）を幅に合わせて伸縮 */
.point {
	background-size: 100% 8px;
}
.point li,
.tokucyo li {
	background-size: 100% 30px;
}
.point h4,
.tokucyo h5 {
	background-size: 100% 30px;
}
.tokucyo ul {
	background-size: 100% 8px;
}

}
