@charset "UTF-8";

:root {
	--ta-green: #008238;
	--ta-lime: #a8e063;
	--ta-light-bg: #f7f7f7;
	--ta-orange: #f39800;
}

body {
	margin: 0;
	font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", sans-serif;
	color: #333;
	line-height: 1.8;
	background-color: #fff;
}

.inner {
	max-width: 1080px;
	margin: 0 auto;
	padding: 0 20px;
	position: relative;
	z-index: 2;
}

/* --- ヘッダー：ロゴの左寄せ修正 --- */
.site-header {
	padding: 24px 0;
	background: #fff;
	position: relative;
	z-index: 10;
	border-bottom: 1px solid #eee;
}

.logo img {
	height: 32px;
	width: auto;
	display: block;
	margin-left: 0;
	margin-right: 0;
}

/* --- 講座紹介セクション (hd-page) --- */
.hd-page {
	position: relative;
	background: linear-gradient(135deg, var(--ta-green) 0%, var(--ta-lime) 100%);
	background-image:
		repeating-linear-gradient(110deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.05) 20%, transparent 20%, transparent 40%),
		linear-gradient(135deg, var(--ta-green) 0%, var(--ta-lime) 100%);
	color: #fff;
	padding: 60px 0 160px;
	/* 文字下の背景を広く確保 */
	overflow: hidden;
}

.hd-page::after {
	content: "";
	position: absolute;
	bottom: -70px;
	left: 50%;
	width: 150%;
	height: 150px;
	background-color: #fff;
	border-radius: 50% 50% 0 0;
	transform: translateX(-50%);
	z-index: 1;
}

.hd-page__title--parent {
	font-size: 16px;
	font-weight: 700;
	margin-bottom: 8px;
	line-height: 1.2;
}

.hd-page__title--self {
	font-size: clamp(32px, 5vw, 48px);
	margin: 0;
	font-weight: 800;
	text-shadow: none;
	line-height: 1.2;
	letter-spacing: 0.05em;
}

.content-main {
	padding-top: 40px;
}

/* --- 見出しスタイル7 --- */
.is-style-hd-style7 {
	background-color: #3C9522 !important;
	color: #ffffff !important;
	border-top-left-radius: 10px;
	border-top-right-radius: 10px;
	text-align: center;
	padding: 15px 20px;
	margin: 0 0 40px;
	font-weight: 700;
	line-height: 1.25;
	font-size: clamp(18px, 3.5vw, 24px);
	box-sizing: border-box;
	display: block;
}

.intro-description {
	text-align: left;
	margin: 40px 0 60px;
	font-size: 1rem;
	line-height: 1.9;
}

/* --- 教材グリッド --- */
.textbook-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 50px;
	margin-bottom: 80px;
}

.textbook-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
}

.textbook-img {
	width: 100%;
	max-width: 260px;
	/* A5/B5共通の比率「1 : 1.414」に固定 */
	aspect-ratio: 1 / 1.414;

	margin: 0 auto 25px;
	background-color: #fff;
	border-radius: 4px;
	box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.textbook-img img {
	width: 100%;
	height: 100%;
	/* 左右の余白を消すための重要設定：
       coverにすることで、数ピクセルの余白の差を無視して枠を埋め尽くします
    */
	object-fit: cover;

	box-shadow: none !important;
	margin-bottom: 0 !important;
}

.textbook-detail h3 {
	display: block;
	text-align: center;
	color: var(--ta-green);
	margin-bottom: 15px;
	font-size: 1.25rem;
	line-height: 1.6;
}

.textbook-detail p {
	text-align: left;
	font-size: 0.95rem;
	margin-bottom: 25px;
}

.btn-retail {
	display: inline-block;
	background: var(--ta-orange);
	color: #fff;
	padding: 12px 40px;
	text-decoration: none;
	border-radius: 30px;
	font-weight: bold;
	transition: 0.3s;
}

.label-category {
	display: inline-block;
	vertical-align: middle;
	font-size: 0.75rem;
	font-weight: bold;
	line-height: 1;
	padding: 3px 6px;
	margin-right: 8px;
	color: #fff;
	border-radius: 2px;
	white-space: nowrap;
}

.label-daisotsu {
	background-color: #00a0e9;
}

.label-kosotsu {
	background-color: #9b7cb6;
}

/* 準備中専用のスタイル */
.btn-retail.is-preparing {
	background-color: #ccc;
	/* グレーアウト */
	cursor: not-allowed;
	/* マウスカーソルを禁止マークに */
	pointer-events: none;
	/* クリックイベントを完全に無効化 */
	opacity: 0.7;
}

/* --- フッター --- */
.site-footer {
	background-color: #d9e4df;
	color: #333;
	text-align: center;
	padding: 40px 0;
}

.footer-logo img {
	height: 32px;
	width: auto;
	margin-bottom: 20px;
}

.footer__copyright {
	font-size: 12px;
	color: #666;
}

/* --- 上に戻るボタン --- */
.page-top {
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 100;
}

.page-top__link {
	display: flex;
	justify-content: center;
	align-items: center;
	width: 50px;
	height: 50px;
	background-color: rgba(0, 130, 56, 0.7);
	border-radius: 50%;
	transition: 0.3s;
}

.arrow-up {
	display: block;
	width: 12px;
	height: 12px;
	border-top: 3px solid #fff;
	border-left: 3px solid #fff;
	transform: rotate(45deg);
	margin-top: 5px;
}

/* --- レスポンシブ設定 --- */
@media (max-width: 900px) {
	.site-header {
		padding: 16px 0;
	}

	.logo img,
	.footer-logo img {
		height: 26px;
	}

	.hd-page {
		padding: 40px 0 80px;
	}

	.hd-page::after {
		height: 80px;
		bottom: -40px;
	}

	.hd-page__title--parent {
		font-size: 14px;
	}

	.hd-page__title--self {
		font-size: 28px;
	}

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

@media print {

	/* 1. ボタンとフッターの間の余白を確保 */
	.content-main::after {
		content: "";
		display: block;
		height: 50px;
	}

	/* 2. もしボタンが途中で切れるのを防ぎたい場合はこれも追加 */
	.textbook-card {
		break-inside: avoid;
	}
}