/*
 * Preview-only Company kanji-follow prototype.
 * Future WordPress port: enqueue only on page-company.php and preserve the
 * data-company-kanji-follow / data-company-kanji-canvas DOM contract.
 */

.company-kanji-follow {
	position: relative;
	isolation: isolate;
	background: var(--color-washi);
}

.company-kanji-follow::before {
	z-index: 0;
	background-position: 31px 53px;
	opacity: .27;
}

.company-kanji-follow__stage {
	position: sticky;
	top: 0;
	z-index: 1;
	width: 100%;
	height: 100vh;
	height: 100svh;
	margin-bottom: -100vh;
	margin-bottom: -100svh;
	overflow: hidden;
	pointer-events: none;
}

.company-kanji-follow__canvas {
	position: absolute;
	inset: 0;
	opacity: 0;
	transition: opacity 280ms ease-out;
}

.company-kanji-follow__canvas canvas {
	display: block;
	width: 100%;
	height: 100%;
}

.company-kanji-follow__fallback {
	display: none !important;
}

.company-kanji-follow.is-webgl-ready .company-kanji-follow__canvas {
	opacity: 1;
}

.company-kanji-follow.is-webgl-ready .company-kanji-follow__fallback {
	opacity: 0;
}

.company-kanji-follow.is-fallback .company-kanji-follow__fallback {
	opacity: 1;
}

.company-kanji-follow__assembly {
	position: relative;
	z-index: 0;
	height: 100vh;
	height: 100svh;
	pointer-events: none;
}

.company-kanji-preview .company-page {
	position: relative;
	z-index: 2;
	margin-top: -100vh;
	margin-top: -100svh;
	background: transparent !important;
}

/* ============================================
   Company Page Enhanced Design & Layout
   ============================================ */

.company-page__shell {
	max-width: 72rem;
	margin: 0 auto;
	padding: clamp(6.5rem, 12vw, 9.5rem) clamp(1.5rem, 4vw, 3.5rem) clamp(3rem, 6vw, 5rem);
}

.company-page__header {
	position: relative;
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	margin-bottom: clamp(3rem, 6vw, 5rem);
	padding-bottom: 2rem;
	border-bottom: 1px solid rgba(34, 40, 44, .15);
}

.company-page__header::after {
	position: absolute;
	bottom: -1px;
	left: 0;
	width: 4rem;
	height: 3px;
	background: var(--color-wood, #bcae91);
	content: "";
}

.company-page__header .content-entry__title {
	font-size: clamp(2.2rem, 5vw, 3.8rem);
	font-weight: 700;
	letter-spacing: -.02em;
	line-height: 1.2;
}

.company-page__mark {
	width: clamp(4rem, 8vw, 6.5rem);
	opacity: .85;
}

/* Section styling with subtle glassmorphism for 3D Kanji backdrop harmony */
.company-page__section {
	margin-bottom: clamp(4rem, 8vw, 7rem);
	padding: clamp(2rem, 4vw, 3.5rem);
	border: 1px solid rgba(34, 40, 44, .1);
	border-radius: 4px;
	background: rgba(247, 248, 246, .78);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	box-shadow: 0 10px 30px rgba(0, 0, 0, .03);
}

.company-page__section-header {
	margin-bottom: 2rem;
}

.company-page__section-header p {
	color: var(--color-text-sub);
	font-family: var(--font-en);
	font-size: .75rem;
	font-weight: 600;
	letter-spacing: .18em;
}

.company-page__section-header h2 {
	margin-top: .4rem;
	font-size: clamp(1.4rem, 3vw, 2rem);
	font-weight: 600;
}

/* Company Data Table — Clean 2-column grid with warm wood accents */
.company-data {
	display: grid;
	grid-template-columns: 1fr;
	gap: 0;
}

.company-data__row {
	display: grid;
	grid-template-columns: minmax(8rem, 12rem) 1fr;
	gap: 1rem;
	padding: 1.25rem 0;
	border-bottom: 1px solid rgba(34, 40, 44, .08);
	align-items: baseline;
	transition: background 240ms ease;
}

.company-data__row:last-child {
	border-bottom: none;
}

.company-data__row dt {
	position: relative;
	padding-left: .85rem;
	color: var(--color-text-sub);
	font-size: .875rem;
	font-weight: 600;
	letter-spacing: .04em;
}

.company-data__row dt::before {
	position: absolute;
	top: 50%;
	left: 0;
	width: 4px;
	height: 4px;
	background: var(--color-wood, #bcae91);
	border-radius: 50%;
	transform: translateY(-50%);
	content: "";
}

.company-data__row dd {
	margin: 0;
	font-size: clamp(.95rem, 1.6vw, 1.1rem);
	line-height: 1.7;
}

.company-data__row dd a {
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 3px;
	transition: opacity 200ms ease;
}

.company-data__row dd a:hover {
	opacity: .7;
}

/* Licensed Work Types — Responsive 2/3 column card grid */
.company-licensed-list {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(13.5rem, 1fr));
	gap: 1rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.company-licensed-list li {
	display: flex;
	align-items: center;
	gap: .85rem;
	padding: 1rem 1.25rem;
	border: 1px solid rgba(34, 40, 44, .08);
	border-radius: 3px;
	background: rgba(255, 255, 255, .7);
	font-size: .95rem;
	font-weight: 500;
	transition: transform 260ms ease, border-color 260ms ease, background 260ms ease;
}

.company-licensed-list li:hover {
	transform: translateY(-2px);
	border-color: rgba(188, 174, 145, .5);
	background: rgba(255, 255, 255, .95);
}

.company-licensed-list li span {
	color: var(--color-wood, #bcae91);
	font-family: var(--font-en);
	font-size: .75rem;
	font-weight: 700;
	letter-spacing: .08em;
}

@media (max-width: 767px) {
	.company-data__row {
		grid-template-columns: 1fr;
		gap: .35rem;
		padding: 1rem 0;
	}

	.company-page__section {
		padding: 1.5rem 1.25rem;
	}

	.company-licensed-list {
		grid-template-columns: repeat(2, 1fr);
		gap: .65rem;
	}

	.company-licensed-list li {
		padding: .75rem .85rem;
		font-size: .85rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.company-kanji-follow__assembly {
		height: 100vh;
		height: 100svh;
	}

	.company-kanji-follow__canvas {
		display: none;
	}

	.company-kanji-follow__fallback,
	.company-kanji-follow.is-webgl-ready .company-kanji-follow__fallback {
		opacity: .18;
	}
}
