/*
Theme Name: Bones Child (TANKFUL)
Theme URI: https://tankful.co.jp/
Description: Bones の子テーマ。header.php / footer.php とヘッダー・フッター用CSSのみを上書きします。
Author: TANKFUL
Template: eddiemachado-bones-79c7610
Version: 1.0.0
*/

/* ============================================================
   TANKFUL header/footer alignment
   solution/ ページの実CSS (default.css / contents.css) を基に
   実寸・実画像(共通ドメイン上の /common/img/*)で再現しています。
   ============================================================ */

.header { background: #fff; }

#tankful-header {
	position: relative;
	width: 1000px;
	max-width: 100%;
	margin: 0 auto;
	height: 150px;
}

#site-logo {
	position: absolute;
	top: 5px;
	left: 10px;
	width: 130px;
	height: 131px;
	margin: 0;
}
#site-logo a,
#site-logo img {
	display: block;
	width: 130px;
	height: 131px;
}

#site-msg {
	position: absolute;
	top: 22px;
	left: 170px;
	width: 394px;
	height: 20px;
	margin: 0;
}
#site-msg img {
	display: block;
	width: 394px;
	height: 20px;
}

#site-mail {
	position: absolute;
	top: 16px;
	left: 773px;
	width: 222px;
	height: 14px;
	margin: 0;
}
#site-mail a,
#site-mail img {
	display: block;
	width: 222px;
	height: 14px;
}

#nav {
	position: absolute;
	top: 76px;
	left: 170px;
	width: 792px;
	height: 33px;
}
#nav .top-nav {
	list-style: none;
	margin: 0;
	padding: 0;
}
#nav .top-nav li {
	float: left;
	height: 33px;
}
#nav .top-nav li a {
	display: block;
	height: 33px;
	background: url(https://tankful.co.jp/common/img/bg_nav.gif) no-repeat;
	text-indent: -9999px;
	overflow: hidden;
}
/* 5項目分のスプライト位置(HOME/SOLUTION/MEDIA/COMPANY/CONTACTの順で
   管理画面のメニューが並んでいる前提です) */
#nav .top-nav li:nth-child(1) a { width: 132px; background-position: 0 0; }
#nav .top-nav li:nth-child(2) a { width: 128px; background-position: -132px 0; }
#nav .top-nav li:nth-child(3) a { width: 132px; background-position: -260px 0; }
#nav .top-nav li:nth-child(4) a { width: 138px; background-position: -530px 0; }
#nav .top-nav li:nth-child(5) a { width: 132px; background-position: -668px 0; }

#nav .top-nav li:nth-child(1) a:hover,
#nav .top-nav li:nth-child(1).current-menu-item a { background-position: 0 -33px; }
#nav .top-nav li:nth-child(2) a:hover,
#nav .top-nav li:nth-child(2).current-menu-item a { background-position: -132px -33px; }
#nav .top-nav li:nth-child(3) a:hover,
#nav .top-nav li:nth-child(3).current-menu-item a { background-position: -260px -33px; }
#nav .top-nav li:nth-child(4) a:hover,
#nav .top-nav li:nth-child(4).current-menu-item a { background-position: -530px -33px; }
#nav .top-nav li:nth-child(5) a:hover,
#nav .top-nav li:nth-child(5).current-menu-item a { background-position: -668px -33px; }

/* ---- フッター ---- */
.footer {
	background: #fff;
}
#tankful-footer {
	width: 1000px;
	max-width: 100%;
	margin: 10px auto 20px;
	text-align: left;
}
#tankful-footer::after {
	content: "";
	display: block;
	clear: both;
}
#tankful-footer .footer-nav {
	list-style: none;
	margin: 0 0 10px;
	padding: 0;
}
#footer_contents {
	float: left;
	width: 500px;
}
#footer_contents .copyright {
	margin: 0;
	font-size: 12px;
	color: #333;
}
#footer_contents .copyright a {
	margin-left: 30px;
	color: #333;
}
#footer_logo {
	float: right;
	width: auto;
}
#footer_logo img {
	display: block;
	height: 22px;
	width: auto;
}

/* ============================================================
   レスポンシブ対応
   ヘッダーの設計幅(1000px + 左右の余白)を下回ったら、その時点で
   一気にハンバーガーメニュー版へ切り替えます。中途半端に絶対配置の
   まま縮小される幅を作らないよう、ブレークポイントは1つだけにして
   あります(以前は768pxで切り替えていたため、769〜1040pxの間で
   スプライトナビが箱からはみ出して見づらくなっていました)。
   ============================================================ */

/* ハンバーガーボタン(PCでは非表示) */
.nav-toggle {
	display: none;
	appearance: none;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 3px;
	width: 40px;
	height: 40px;
	padding: 0;
	cursor: pointer;
}
.nav-toggle-bar,
.nav-toggle-bar::before,
.nav-toggle-bar::after {
	display: block;
	width: 20px;
	height: 2px;
	background: #333;
	position: relative;
	margin: 0 auto;
	transition: transform .2s ease, opacity .2s ease;
}
.nav-toggle-bar::before,
.nav-toggle-bar::after {
	content: "";
	position: absolute;
	left: 0;
}
.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after  { top: 6px; }

/* ボタンを押した状態(×アイコンに変形) */
body.nav-is-open .nav-toggle-bar {
	background: transparent;
}
body.nav-is-open .nav-toggle-bar::before {
	top: 0;
	transform: rotate(45deg);
}
body.nav-is-open .nav-toggle-bar::after {
	top: 0;
	transform: rotate(-45deg);
}

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

/* ヘッダー設計幅(1000px)+余白を下回ったら可変レイアウト + ハンバーガーメニューに切り替え */
@media screen and (max-width: 1040px) {
	#tankful-header {
		position: relative;
		height: auto;
		display: flex;
		flex-wrap: wrap;
		align-items: center;
		padding: 15px 20px;
	}

	#site-logo {
		position: static;
		width: 90px;
		height: auto;
		margin: 0 15px 0 0;
	}
	#site-logo img {
		width: 90px;
		height: auto;
	}

	/* 固定サイズの画像(タグライン・メール)は狭い画面では崩れるため非表示。
	   メールアドレスはフッターやCONTACTページで確認できる前提です。
	   表示したい場合は display:none を消して幅を可変にしてください。 */
	#site-msg,
	#site-mail {
		display: none;
	}

	.nav-toggle {
		display: flex;
		align-items: center;
		justify-content: center;
		margin-left: auto;
	}

	/* ナビ本体は閉じた状態がデフォルト。ボタンで body.nav-is-open を
	   トグルすると開きます(JS: js/nav-toggle.js) */
	#nav {
		position: static;
		width: 100%;
		height: auto;
		margin-top: 0;
		max-height: 0;
		overflow: hidden;
		transition: max-height .25s ease;
	}
	body.nav-is-open #nav {
		max-height: 400px;
		margin-top: 12px;
	}

	#nav .top-nav {
		display: flex;
		flex-direction: column;
	}
	#nav .top-nav li {
		float: none;
		height: auto;
		border-bottom: 1px solid #eee;
	}
	#nav .top-nav li a {
		background: none !important;
		text-indent: 0;
		overflow: visible;
		width: 100% !important;
		height: auto;
		padding: 12px 4px;
		color: #333;
		font-size: 14px;
	}
	#nav .top-nav li a:hover,
	#nav .top-nav li.current-menu-item a {
		background: #f2f2f2 !important;
	}

	/* フッターも積み上げ表示に */
	#tankful-footer {
		text-align: center;
	}
	#footer_contents,
	#footer_logo {
		float: none;
		width: 100%;
		text-align: center;
	}
	#footer_contents .copyright a {
		display: inline-block;
		margin: 8px 0 0;
	}
	#footer_logo {
		margin-top: 15px;
	}
}

/* スマホ: さらに詰める */
@media screen and (max-width: 480px) {
	#site-logo {
		width: 70px;
	}
	#site-logo img {
		width: 70px;
	}
	#nav .top-nav li a {
		font-size: 12px;
		padding: 6px 10px;
	}
}

/* ---- 投稿の 前へ/次へ/一覧に戻る ナビ (single.php) ---- */
.post-navigation {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px;
	margin: 30px 0 0;
	padding: 15px 0;
	border-top: 1px solid #eee;
	border-bottom: 1px solid #eee;
	font-size: 13px;
}
.post-navigation .nav-previous {
	flex: 1;
	text-align: left;
}
.post-navigation .nav-next {
	flex: 1;
	text-align: right;
}
.post-navigation .nav-index {
	flex: 0 0 auto;
	text-align: center;
	order: 3;
}
.post-navigation a {
	color: #333;
	text-decoration: none;
}
.post-navigation a:hover {
	color: #f01d4f;
}
.post-navigation .nav-index a {
	padding: 4px 12px;
	border: 1px solid #ddd;
	border-radius: 3px;
}

/* 狭い画面では 前へ/一覧に戻る/次へ の順で縦積み */
@media screen and (max-width: 480px) {
	.post-navigation {
		flex-direction: column;
		align-items: stretch;
		text-align: center;
	}
	.post-navigation .nav-previous,
	.post-navigation .nav-next {
		text-align: center;
	}
	.post-navigation .nav-index {
		order: 0;
		margin: 6px 0;
	}
}
