/* ==========================================================
   OMAI UI KIT
   続きをよむ（アコーディオン）

   ・チェックボックスで開閉する「続きをよむ」ブロック
   ・元は「tabcontents」に同居していたものを分離
   ・アイコンはテーマの icomoon フォントに依存しています
     （テーマを変更すると矢印が文字化けします）
   ========================================================== */

.cp_box *, .cp_box *:before, .cp_box *:after {
	-webkit-box-sizing: border-box;
	box-sizing: border-box;
}

.cp_box {
	position: relative;
}

/* 閉じているときの、下部グラデーション + ボタン領域 */
.cp_box label {
	position: absolute;
	z-index: 1;
	bottom: 0;
	width: 100%;
	height: 140px; /* グラデーションの高さ */
	cursor: pointer;
	text-align: center;
	/* 背景色を変えた場合は、下のrgba値も合わせてください */
	background: linear-gradient(to bottom, rgba(250, 252, 252, 0) 0%, rgba(250, 252, 252, 0.95) 90%);
}

/* 開いたときはグラデーションを消す */
.cp_box input:checked + label {
	background: inherit;
	/* 閉じるボタンごと消したい場合は display:none; を追加 */
}

/* ボタンの見た目 */
.cp_box label:after {
	line-height: 2.5rem;
	position: absolute;
	z-index: 2;
	bottom: 20px;
	left: 50%;
	width: 16rem;
	font-family: icomoon;
	content: '\ea45'' 続きをよむ';
	transform: translate(-50%, 0);
	letter-spacing: 0.05em;
	color: #ffffff;
	border-radius: 20px;
	background-color: rgba(27, 37, 56, 1);
}

/* 開いたときのボタン表記 */
.cp_box input:checked + label:after {
	font-family: icomoon;
	content: '\ea43'' 閉じる';
}

/* 開閉のスイッチ本体（非表示） */
.cp_box input {
	display: none;
}

/* 閉じているときの表示範囲 */
.cp_box .cp_container {
	overflow: hidden;
	height: 250px; /* 開く前に見えている部分の高さ */
	transition: all 0.5s;
}

/* 開いたとき */
.cp_box input:checked ~ .cp_container {
	height: auto;
	padding-bottom: 80px; /* 閉じるボタンのbottomからの位置 */
	transition: all 0.5s;
}
