@font-face {
	font-family: Helvetica;
	font-weight: normal;
	font-style: normal;
	src: local("Helvetica");
}

html {
	font-family: Helvetica, sans-serif;
	font-size: 18px;
}

body {
	margin: 0;
}

body > * {
	padding-left: 20px;
	padding-right: 20px;
}

audio {
	width: 100%;
	max-width: 300px;
	border: 2px solid #a2a9b1;
	border-radius: 27px;
	outline: 1px solid #ffffff;
}

nav {
	position: fixed;
	top: 20px;
    right: 20px;
	display: flex;
    padding: 10px;
    border: 2px solid #444444;
    outline: 2px solid #f7f7f7;
    border-radius: 5px;
	background-color: #f7f7f7;
	z-index: 999;
}

nav a {
	font-weight: bold;
	color: #deb76c;
    text-decoration: none;
    margin: 0 5px;
}

nav a:hover {
	text-decoration: underline;
}

nav > span {
	margin: 0 10px;
}

.section-text {
	width: 100%;
	font-weight: bold;
	overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

header {
	display: flex;
	justify-content: center;
	padding-top: 20px;
	margin-bottom: 20px;
	font-size: 32px;
	font-weight: bold;
}

.image-container {
	display: flex;
	justify-content: center;
	align-items: center;
	max-height: 600px;
	overflow: hidden;
}

.image-container img {
    max-width: 100%;
    max-height: 600px;
    height: auto;
	margin: 0 10px;
	opacity: 1;
	transition: opacity 500ms ease-in-out;
}

section > span {
	display: inline-block;
	margin-top: 40px;
	margin-bottom: 20px;
	font-size: 24px;
	font-weight: bold;
}

section > div {
	display: grid;
	grid-template-columns: fit-content(100%) 319px 1fr;
	border-bottom: 2px solid #a2a9b1;
	border-right: 2px solid #a2a9b1;
}

section > div > div {
	padding: 8px;
	border-top: 2px solid #a2a9b1;
	border-left: 2px solid #a2a9b1;
}

.head {
	font-weight: bold;
	color: #ffffff;
	background-color: #338eaa;
}

.event {
	color: #ffffff;
}

.audio {
	min-height: 56px;
}

.event,
.audio {
	display: flex;
	align-items: center;
}

.transcription {
	align-content: center;
}

.odd {
	background-color: #ffffff;
}

.even {
	background-color: #eeeeee;
}

.event.odd {
	background-color: #666769;
}

.event.even {
	background-color: #555555;
}

.footnote {
	grid-column: 1 / -1;
	font-size: 14.4px;
}

.footnote.head {
	display: none;
	font-size: unset;
	font-weight: bold;
	background-color: #227d99;
}

.footnote a {
	text-decoration: none;
}

.JP-1 a,
.JP-2 a {
	display: inline-block;
	font-size: 10px;
	transform: translateY(-7px);
	text-decoration: none;
}

.footnote a:hover,
.JP-1 a:hover,
.JP-2 a:hover {
	text-decoration: underline;
}

.footnote {
	display: flex;
	flex-direction: column;
}

.footnote span {
	width: fit-content;
}

#footnote-1 {
	margin-bottom: 4px;
}

.highlight {
	transition: background 0.2s;
}

hr {
	width: 100%;
	height: 1px;
	border: 0;
	background-color: #a2a9b1;
	margin: 4.5px 0;
}

.event:has(hr) {
	display: flex;
	flex-direction: column;
	align-items: unset;
	justify-content: center;
}

div:has(.chibi) {
	position: relative;
}

.chibi {
	position: absolute;
	height: 100px;
	right: 0;
	top: -71.27px;
}

.event .chibi {
	display: none;
}

.chibi-1 {
	top: -70.92px;
}

section:last-of-type {
	margin-bottom: 20px;
}

footer {
	padding-top: 26px;
	margin: 32px 0 16px;
	color: #222222;
	text-align: center;
}

/*
header span {
	padding: 0 18.5px;
	background: red;
}
*/

@media (pointer: coarse) {
	body {
		-webkit-tap-highlight-color: transparent;
	}
	nav a:hover,
	section a {
		text-decoration: unset;
	}
	nav a:active,
	section a {
		text-decoration: underline;
	}
}

@media (max-width: 972px) {
	nav {
		position: sticky;
		top: 20px;
		justify-content: space-evenly;
        transform: translateY(-18px);
		border-radius: unset;
	}
	#to-top {
		margin: 0;
		margin-right: 10px;
	}
	#to-bottom {
		margin: 0;
		margin-left: 10px;
	}
    nav > div {
        display: grid;
        grid-template-columns: fit-content(100%) 1fr fit-content(100%);
        justify-items: center;
    }
	nav > span {
		margin: unset;
		align-content: center;
	}
	section > div {
		grid-template-columns: 1fr;
	}
	.head {
		display: none;
	}
	.audio,
	.footnote {
		background-color: #ffffff;
	}
	.transcription {
		background-color: #eeeeee;
	}
	.event {
		align-items: unset;
		font-weight: bold;
	}
	.event.odd,
	.event.even {
		background-color: #338eaa;
	}
	.event .chibi {
		display: unset;
	}
	.footnote.head {
		display: unset;
	}
}

@media (pointer: coarse) and (max-width: 972px) {
	body {
		-webkit-tap-highlight-color: transparent;
	}
	nav {
		display: grid;
		grid-template-columns: 1fr fit-content(100%) 1fr;
		height: 41px;
		padding: 0;
	}
	nav a {
		width: 100%;
		margin: 0;
		text-align: center;
		align-content: center;
		transition: background-color 0.3s;
	}
	#to-top {
		margin: 0;
	}
	#to-bottom {
		margin: 0;;
	}
	nav a:active {
		text-decoration: unset;
		background-color: #e0e0e0;
	}
    nav > div {
        grid-template-columns: 1fr 1fr 1fr;
    }
	.section-text,
	nav > a > span {
		margin: 0 5px;
		text-align: center;
		align-content: center;
	}
}

@media (max-width: 768px) {
	body > *:not(nav) {
		padding-left: 10px;
		padding-right: 10px;
	}
}

@media (max-width: 480px) {  
	body > section {
		padding-left: 0;
		padding-right: 0;
	}
	section > span {
		padding-left: 10px;
	}
}
