/* kuwaya main styles extracted from index.html */
body {
	margin: 0;
	overflow: hidden;
	background-color: #ffffff;
	font-family: 'Yu Gothic UI', 'Yu Gothic', 'Meiryo', 'Segoe UI', sans-serif;
}

#three-canvas {
	width: 100vw;
	height: 100vh;
	display: block;
	position: fixed;
	top: 0;
	left: 0;
	z-index: 0;
}

.menu-bar {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	background: rgba(255, 255, 255, 0.75);
	backdrop-filter: blur(10px);
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
	z-index: 100;
	padding: 12px 0;
}

footer {
	position: fixed;
	bottom: 0;
	left: 0;
	width: 100%;
	text-align: center;
	padding: 12px;
	background: rgba(255, 255, 255, 0.75);
	backdrop-filter: blur(10px);
	box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.15);
	z-index: 99;
	font-size: 0.85em;
	color: #666;
}

footer a {
	color: rgb(240, 69, 32);
	text-decoration: none;
}

footer a:hover {
	text-decoration: underline;
}

.menu-container {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 10px;
}

.menu-item {
	cursor: pointer;
	font-size: 13px;
	font-weight: 500;
	color: #333;
	padding: 6px 12px;
	border-radius: 4px;
	transition: all 0.3s ease;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	white-space: nowrap;
	font-family: 'Yu Gothic UI', 'Yu Gothic', 'Meiryo', 'Segoe UI', sans-serif;
}

.menu-item:hover {
	background: rgba(0, 0, 0, 0.05);
	color: #333;
}

.menu-item.active {
	background: rgba(0, 0, 0, 0.1);
	color: #333;
}

.overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 10;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.2s;
}

.overlay.active {
	visibility: visible;
	opacity: 1;
}

.overlay-content {
	background: #fff;
	border-radius: 16px;
	padding: 32px 24px;
	min-width: 320px;
	max-width: 90vw;
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
	text-align: center;
	position: relative;
}

.overlay-close {
	position: absolute;
	top: 8px;
	right: 16px;
	font-size: 2em;
	color: #888;
	cursor: pointer;
}

.overlay-image {
	width: 100%;
	max-width: 320px;
	border-radius: 8px;
	margin-bottom: 16px;
}

.overlay-title {
	font-size: 1.4em;
	font-weight: bold;
	margin-bottom: 8px;
}

.overlay-desc {
	font-size: 1em;
	margin-bottom: 16px;
}

.overlay-link a {
	color: rgb(240, 69, 32);
	text-decoration: none;
	font-weight: bold;
	border-bottom: 1px solid rgb(240, 69, 32);
	transition: color 0.2s;
}

.overlay-link a:hover {
	color: rgb(200, 50, 20);
}

.panel2d-overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.5);
	z-index: 300;
	display: block;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.5s cubic-bezier(.4,0,.2,1);
}

.panel2d-overlay.active {
	opacity: 1;
	pointer-events: auto;
}

.panel2d-container {
	position: fixed;
	left: 50%;
	top: 50%;
	z-index: 301;
	background: #fff;
	border-radius: 16px;
	box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
	overflow: hidden;
	width: min(90vw, calc(100vh * 0.8));
	max-height: 80vh;
	aspect-ratio: 4 / 5;
	opacity: 0;
	pointer-events: none;
	transform: translate(-50%, 50%) scale(1);
	transition: opacity 0.5s cubic-bezier(.4,0,.2,1), transform 0.8s cubic-bezier(.4,0,.2,1);
}

.panel2d-container.active {
	display: block;
	opacity: 1;
	pointer-events: auto;
	transform: translate(-50%, -50%) scale(1);
}

.panel2d-container.hide {
	display: block;
	opacity: 0;
	pointer-events: auto;
	transform: translate(-50%, -100%) scale(1);
}

.panel2d-close {
	position: absolute;
	top: 12px;
	right: 16px;
	font-size: 2em;
	color: #888;
	background: none;
	border: none;
	cursor: pointer;
	z-index: 21;
	line-height: 1;
	padding: 0;
	width: 32px;
	height: 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255,255,255,0.7);
	border-radius: 50%;
	box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.panel2d-close:hover {
	color: #333;
	background: rgba(255,255,255,0.95);
}

.panel2d-content {
	display: flex;
	flex-direction: column;
	height: 100%;
	overflow-y: auto;
}

.panel2d-image {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	flex-shrink: 0;
}
.panel2d-video {
	width: 100%;
	aspect-ratio: 16 / 9;
	flex-shrink: 0;
	display: none;
}
.panel2d-video iframe {
	width: 100%;
	height: 100%;
	border: none;
}

.panel2d-body {
	padding: 24px;
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.panel2d-title {
	font-size: 1.8em;
	font-weight: bold;
	margin: 0;
	color: #222;
}

.panel2d-info {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.panel2d-info-row {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.panel2d-label {
	font-weight: bold;
	color: #666;
	min-width: 60px;
}

.panel2d-value {
	color: #222;
	flex: 1;
	white-space: pre-line;
}

.panel2d-description {
	font-size: 0.95em;
	line-height: 1.6;
	color: #444;
	white-space: pre-line;
}

.panel2d-profile {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.panel2d-profile-section {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.panel2d-profile-section-title {
	font-size: 1.1em;
	font-weight: bold;
	color: #333;
	border-bottom: 2px solid rgb(240, 69, 32);
	padding-bottom: 4px;
	margin-bottom: 4px;
}

.panel2d-profile-item {
	display: flex;
	gap: 12px;
	font-size: 0.9em;
	line-height: 1.6;
}

.panel2d-profile-year {
	font-weight: bold;
	color: #666;
	min-width: 80px;
	flex-shrink: 0;
}

.panel2d-profile-text {
	color: #444;
	flex: 1;
}

.panel2d-profile-basic {
	font-size: 0.95em;
	line-height: 1.6;
	color: #444;
	margin-bottom: 8px;
}

.panel2d-links {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.panel2d-links a {
	color: rgb(240, 69, 32);
	text-decoration: none;
	font-size: 0.9em;
	transition: color 0.2s;
	display: block;
	line-height: 1.6;
	padding: 4px 0;
	-webkit-tap-highlight-color: rgba(240, 69, 32, 0.2);
}

.panel2d-links a:hover {
	color: rgb(200, 50, 20);
	text-decoration: underline;
}

.loading-screen {
	position: fixed;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: #ffffff;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	z-index: 1000;
	transition: opacity 0.5s ease-out;
}

.loading-screen.hidden {
	opacity: 0;
	pointer-events: none;
}

.loading-logo {
	width: 120px;
	height: 120px;
	margin-bottom: 32px;
	opacity: 0.8;
}

.loading-text {
	font-size: 18px;
	color: #666;
	margin-bottom: 24px;
}

.loading-progress-container {
	width: 300px;
	height: 4px;
	background: #e0e0e0;
	border-radius: 2px;
	overflow: hidden;
}

.loading-progress-bar {
	height: 100%;
	background: rgb(240, 69, 32);
	width: 0%;
	transition: width 0.3s ease;
	border-radius: 2px;
}

.loading-percentage {
	margin-top: 12px;
	font-size: 14px;
	color: #999;
}

@media (max-width: 768px) {
	.panel2d-container {
        width: 95vw;
        max-height: 95vh;
	}
	.panel2d-body {
        padding: 16px;
	}
	.panel2d-title {
        font-size: 1.5em;
	}
	.loading-progress-container {
        width: 80%;
        max-width: 300px;
	}
	.menu-item {
        font-size: 11px;
    }
}
