* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	background: #fff;
	padding: 20px;
	overflow-y: auto;
	min-height: 100vh;
	text-align: left;
	/* indexと同じ fixed footer が重ならないように下余白を確保 */
	padding-bottom: 64px;
}

.detail-container {
	max-width: 900px;
	margin: 0 auto;
	background: #fff;
}

.detail-content {
	display: flex;
	flex-direction: column;
}

.detail-image {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	flex-shrink: 0;
}

/* YouTube動画がある場合の印刷用画像（通常時は非表示） */
.detail-image-print {
	display: none;
}

.detail-video {
	width: 100%;
	aspect-ratio: 16 / 9;
	flex-shrink: 0;
	display: none;
}

.detail-video iframe {
	width: 100%;
	height: 100%;
	border: none;
}

.detail-body {
	padding: 8px 0px;
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.back-to-top {
	padding: 40px 20px;
	max-width: 800px;
	margin: 0 auto;
	text-align: center;
}

.back-to-top a {
	display: inline-block;
	padding: 20px 40px;
	background: rgb(240, 69, 32);
	color: #fff;
	text-decoration: none;
	border-radius: 8px;
	font-size: 1.1em;
	transition: background-color 0.2s;
}

.back-to-top a:hover {
	background: rgb(200, 50, 20);
}

.loading {
	text-align: left;
	padding: 100px 20px;
	font-size: 1.2em;
	color: #666;
}

.error {
	text-align: left;
	padding: 100px 20px;
	color: #d32f2f;
}

/* print.html 内の説明ブロック（desc / descMd 共通） */
#print-desc {
	font-size: 0.95em;
	line-height: 1.6;
	color: #444;
}

#print-desc h1,
#print-desc h2,
#print-desc h3 {
	margin: 1.5em 0 0.75em;
	font-weight: 600;
}

#print-desc p {
	margin: 0.6em 0;
	line-height: 1.7;
}

#print-desc ul,
#print-desc ol {
	margin: 0.6em 0 0.6em 1.4em;
	padding: 0;
}

#print-desc li {
	margin: 0.2em 0;
}

#print-desc img {
	max-width: 100%;
	height: auto;
	display: block;
	margin: 1em 0;
}

#print-desc a {
	color: #0066cc;
	text-decoration: underline;
}

/* print.html 内のテーブル（特定商取引法など） */
#print-desc table {
	width: 100%;
	border-collapse: collapse;
	margin: 1.2em 0;
	font-size: 0.9em;
}

#print-desc thead tr {
	border-bottom: 2px solid rgba(0, 0, 0, 0.15);
}

#print-desc th,
#print-desc td {
	padding: 0.5em 0.9em;
	vertical-align: top;
}

#print-desc th {
	white-space: nowrap;
	font-weight: 600;
	color: #555;
	text-align: left;
}

#print-desc tr + tr {
	border-top: 1px solid rgba(0, 0, 0, 0.08);
}

/* 印刷時のスタイル */
@media print {
	body {
		padding: 20px;
	}
	
	.detail-body {
		padding: 20px;
	}
	
	/* 印刷時は動画を非表示、画像を表示 */
	.detail-video {
		display: none !important;
	}
	
	.detail-image-print {
		display: block !important;
	}
	
	.panel2d-links a::after {
		content: " (" attr(href) ")";
		font-size: 0.9em;
		color: #666;
	}
}
