/*
 * JAPOC TOP Manager - layout bridge, section overrides and custom footer.
 * The original TOP design CSS is stored in WordPress settings and printed after this file.
 */

body.japoc-top-page .c-pageTitle,
body.japoc-top-page .l-sidebar {
	display: none !important;
}

body.japoc-top-page .l-container,
body.japoc-top-page .l-content,
body.japoc-top-page .l-mainContent,
body.japoc-top-page .l-mainContent__inner,
body.japoc-top-page .post_content {
	float: none !important;
	display: block !important;
	grid-column: 1 / -1 !important;
	width: 100% !important;
	max-width: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

body.japoc-top-page.jtm-hide-theme-footer .l-footer,
body.japoc-top-page.jtm-hide-theme-footer #footer {
	display: none !important;
}

.japoc-home,
.japoc-home .jtm-section {
	width: 100%;
	max-width: none;
}

/*
 * SWELL側の見出し装飾・透明色指定より必ず優先する。
 * 各見出し本来の色は現行TOP CSSで指定し、ここでは表示状態のみ固定する。
 */
.post_content .japoc-home h1,
.post_content .japoc-home h2,
.post_content .japoc-home h3,
.post_content .japoc-home h4,
.post_content .japoc-home h5,
.post_content .japoc-home h6 {
	visibility: visible !important;
	opacity: 1 !important;
	-webkit-text-fill-color: currentColor !important;
	text-indent: 0 !important;
}

.jtm-section.jtm-has-background-override > section,
.jtm-section.jtm-has-background-override > aside,
.jtm-section.jtm-has-background-override > nav,
.jtm-section.jtm-has-background-override > footer,
.jtm-section.jtm-has-background-override > div {
	background: var(--jtm-section-background) !important;
	background-color: var(--jtm-section-background) !important;
}

.jtm-section.jtm-has-text-override h1,
.jtm-section.jtm-has-text-override h2,
.jtm-section.jtm-has-text-override h3,
.jtm-section.jtm-has-text-override h4,
.jtm-section.jtm-has-text-override h5,
.jtm-section.jtm-has-text-override h6,
.jtm-section.jtm-has-text-override p,
.jtm-section.jtm-has-text-override li,
.jtm-section.jtm-has-text-override small,
.jtm-section.jtm-has-text-override time,
.jtm-section.jtm-has-text-override summary {
	color: var(--jtm-section-text) !important;
	-webkit-text-fill-color: var(--jtm-section-text) !important;
}

.japoc-home a:focus-visible,
.japoc-home button:focus-visible,
.japoc-home summary:focus-visible {
	outline: 3px solid var(--blue, #1ea6c1);
	outline-offset: 3px;
}

/* Custom academic-association style footer. */
.japoc-custom-footer {
	--jtm-footer-bg: #0d2b54;
	--jtm-footer-text: #fff;
	--jtm-footer-accent: #68d2e5;
	position: relative;
	padding: 76px 0 0;
	background: var(--jtm-footer-bg) !important;
	color: var(--jtm-footer-text) !important;
}

.japoc-custom-footer::before {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	left: 0;
	height: 4px;
	background: linear-gradient(90deg, var(--blue, #1ea6c1) 0 72%, var(--coral, #ef8389) 72%);
}

.japoc-custom-footer,
.japoc-custom-footer * {
	box-sizing: border-box;
}

.japoc-custom-footer .jtm-footer-main {
	display: grid;
	grid-template-columns: minmax(250px, .9fr) minmax(0, 2.1fr);
	gap: 72px;
	padding-bottom: 58px;
}

.japoc-custom-footer .jtm-footer-brand img {
	display: block;
	width: min(100%, 250px);
	max-height: 78px;
	margin: 0 0 27px;
	object-fit: contain;
	object-position: left center;
}

.japoc-custom-footer .jtm-footer-name {
	margin: 0;
	color: var(--jtm-footer-text) !important;
	font-size: 16px;
	font-weight: 750;
	line-height: 1.7;
}

.japoc-custom-footer .jtm-footer-en {
	margin: 8px 0 0;
	color: rgb(255 255 255 / 48%) !important;
	font: 400 9px/1.7 Arial, sans-serif;
	letter-spacing: .06em;
}

.japoc-custom-footer .jtm-footer-slogan {
	margin: 25px 0 0;
	padding-top: 22px;
	border-top: 1px solid rgb(255 255 255 / 14%);
	color: rgb(255 255 255 / 69%) !important;
	font-size: 11px;
	line-height: 1.9;
}

.japoc-custom-footer .jtm-footer-columns {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 34px;
}

.post_content .japoc-custom-footer .jtm-footer-column h2 {
	display: block !important;
	visibility: visible !important;
	margin: 0 0 18px !important;
	padding: 0 0 14px !important;
	border: 0 !important;
	border-bottom: 1px solid rgb(255 255 255 / 20%) !important;
	background: transparent !important;
	color: var(--jtm-footer-text) !important;
	-webkit-text-fill-color: var(--jtm-footer-text) !important;
	font-size: 13px !important;
	font-weight: 750 !important;
	line-height: 1.5 !important;
}

.post_content .japoc-custom-footer .jtm-footer-column h2::before,
.post_content .japoc-custom-footer .jtm-footer-column h2::after {
	content: none !important;
	display: none !important;
}

.japoc-custom-footer .jtm-footer-column ul {
	display: grid;
	gap: 0;
	margin: 0;
	padding: 0;
	list-style: none;
}

.japoc-custom-footer .jtm-footer-column li {
	margin: 0;
	padding: 0;
}

.japoc-custom-footer .jtm-footer-column a {
	min-height: 38px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	border-bottom: 1px solid rgb(255 255 255 / 8%);
	color: rgb(255 255 255 / 72%) !important;
	font-size: 11px;
	line-height: 1.55;
	transition: color .2s, border-color .2s;
}

.japoc-custom-footer .jtm-footer-column a:hover {
	border-color: var(--jtm-footer-accent);
	color: var(--jtm-footer-text) !important;
}

.japoc-custom-footer .jtm-footer-column a span {
	color: var(--jtm-footer-accent);
}

.japoc-custom-footer .jtm-footer-socials {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
	padding-top: 28px;
	padding-bottom: 28px;
	border-top: 1px solid rgb(255 255 255 / 15%);
}

.japoc-custom-footer .jtm-footer-socials > span {
	color: var(--jtm-footer-accent);
	font: 700 9px/1 Arial, sans-serif;
	letter-spacing: .18em;
}

.japoc-custom-footer .jtm-footer-socials > div {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 9px;
}

.japoc-custom-footer .jtm-footer-socials a {
	min-height: 42px;
	display: inline-flex;
	align-items: center;
	gap: 9px;
	padding: 0 15px;
	border: 1px solid rgb(255 255 255 / 23%);
	border-radius: 3px;
	color: var(--jtm-footer-text) !important;
	font-size: 10px;
	font-weight: 700;
}

.japoc-custom-footer .jtm-footer-socials a:hover {
	border-color: var(--jtm-footer-accent);
	background: rgb(255 255 255 / 7%);
}

.japoc-custom-footer .jtm-footer-socials b {
	min-width: 20px;
	color: var(--jtm-footer-accent);
	font: 700 11px/1 Arial, sans-serif;
}

.japoc-custom-footer .jtm-footer-bottom {
	border-top: 1px solid rgb(255 255 255 / 12%);
	background: rgb(0 0 0 / 13%);
}

.japoc-custom-footer .jtm-footer-bottom .jh-shell {
	min-height: 66px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 25px;
}

.japoc-custom-footer .jtm-footer-bottom span {
	padding: 5px 9px;
	border: 1px solid rgb(255 255 255 / 22%);
	color: rgb(255 255 255 / 70%);
	font-size: 9px;
}

.japoc-custom-footer .jtm-footer-bottom small {
	color: rgb(255 255 255 / 45%);
	font: 400 9px/1.5 Arial, sans-serif;
}

.japoc-custom-footer.jtm-footer-custom {
	padding: 0;
}

@media (max-width: 960px) {
	.japoc-custom-footer .jtm-footer-main {
		grid-template-columns: 1fr;
		gap: 48px;
	}

	.japoc-custom-footer .jtm-footer-brand {
		max-width: 480px;
	}
}

@media (max-width: 720px) {
	.japoc-custom-footer {
		padding-top: 58px;
	}

	.japoc-custom-footer .jtm-footer-columns {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 36px 24px;
	}
}

@media (max-width: 560px) {
	.japoc-custom-footer {
		padding-bottom: 64px;
	}

	.japoc-custom-footer .jtm-footer-main {
		gap: 42px;
		padding-bottom: 42px;
	}

	.japoc-custom-footer .jtm-footer-columns {
		grid-template-columns: 1fr;
		gap: 29px;
	}

	.japoc-custom-footer .jtm-footer-socials,
	.japoc-custom-footer .jtm-footer-bottom .jh-shell {
		align-items: flex-start;
		flex-direction: column;
	}

	.japoc-custom-footer .jtm-footer-socials > div {
		justify-content: flex-start;
	}

	.japoc-custom-footer .jtm-footer-bottom .jh-shell {
		min-height: 86px;
		justify-content: center;
		gap: 12px;
	}
}
