/* JP marketing shell (header/footer) + blog cards — complements Attila style.css */

/*
 * Fixed header clearance: padding lives on .viewport.jp-layout (not only .jp-main) so it
 * isn’t lost to flex/margin quirks. --jp-header-offset is set in jp-shell.js from the real
 * .l-header height (fallback below if JS is off).
 */
html:has(body.jp-theme) {
	--jp-header-offset: 12rem;
}

.jp-theme {
	font-family: 'Noto Sans JP', sans-serif;
}

.jp-layout {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
}

/* Primary offset — must win over Attila .page-wrapper (load order + !important) */
body.jp-theme .viewport.jp-layout {
	padding-top: var(--jp-header-offset) !important;
	box-sizing: border-box;
}

.jp-main {
	flex: 1;
	width: 100%;
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 1.5rem 3rem;
	padding-top: 0;
	box-sizing: border-box;
}

html:has(body.jp-theme) {
	scroll-padding-top: var(--jp-header-offset);
}

@media screen and (max-width: 767px) {
	html:has(body.jp-theme) {
		scroll-padding-top: max(var(--jp-header-offset), 6.5rem);
	}
}

/* Reading progress bar: sit below fixed JP header (Attila uses top:0; z-index:1000) */
body.jp-theme .progress-container {
	top: var(--jp-header-offset);
	z-index: 40;
}

/* ----- Header (fixed, JP layout) ----- */

.l-header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	padding: 2.5rem 3.75rem;
	z-index: 50;
	transition: padding 0.3s ease, background 0.3s ease;
	box-sizing: border-box;
	background: #fbfbfb;
	background: linear-gradient(180deg, #fbfbfb 0%, #fbfbfb 80%, rgba(251, 251, 251, 0) 100%);
}

.l-header.fixed {
	padding: 0.625rem 3.75rem;
}

.l-header__container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	max-width: 1184px;
	margin: 0 auto;
}

.l-header__main {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
}

.l-header__logo {
	margin: 0;
}

.l-header__logo a {
	display: block;
	width: 150px;
	line-height: 0;
}

.l-header__logo svg .logo-mark,
.l-header__logo svg .logo-type {
	transition: fill 0.3s ease;
}

.l-header[data-color="light-gray"] .l-header__logo a:hover svg .logo-type {
	fill: #fcd72b;
}

.l-header__nav ul {
	display: flex;
	flex-wrap: wrap;
	list-style: none;
	margin: 0;
	padding: 0;
	gap: 0;
}

.l-header__nav li a {
	display: flex;
	align-items: center;
	padding: 1.25rem;
	color: #303030;
	text-decoration: none;
	font-size: 0.9375rem;
	font-weight: 500;
}

.l-header__nav li a[href*="prtimes"],
.l-header__nav li a[href*="hiring"] {
	padding-right: 1rem;
}

.l-header__nav li a[target="_blank"]:after {
	content: "";
	display: block;
	width: 12px;
	height: 12px;
	background: url("../images/icon-blank_dark.svg") 0 / cover;
	margin: 0 0 0 6px;
	transition: background 0.3s ease;
	flex-shrink: 0;
}

.l-header[data-color="light-gray"] .l-header__nav li a:hover {
	color: #fcd72b;
	opacity: 1;
}

.l-header[data-color="light-gray"] .l-header__nav li a[target="_blank"]:hover:after {
	background: url("../images/icon-blank_yellow.svg") 0 / cover;
}

.l-header__hum {
	display: none;
}

/* Mobile / tablet overlay nav — matches JP breakpoint 1120px */
@media only screen and (max-width: 1120px) {
	.l-header {
		padding: 0;
		background: none;
	}

	.l-header.fixed {
		padding: 0;
	}

	.l-header__main {
		padding: 1.25rem 3.75rem;
		z-index: 1;
		background: #fbfbfb;
		background: linear-gradient(180deg, #fbfbfb 0%, #fbfbfb 90%, rgba(251, 251, 251, 0) 100%);
	}

	.l-header__logo a {
		width: 100px;
	}

	.l-header__nav {
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		padding: 5rem 3.75rem 3.75rem;
		overflow-y: auto;
		opacity: 0;
		visibility: hidden;
		transform: translateY(-50%);
		transition: opacity 0.6s ease, visibility 0.6s ease, transform 0.6s ease;
		box-sizing: border-box;
		background: #fbfbfb;
	}

	.l-header__nav ul {
		display: block;
		border-top: 1px solid #171515;
	}

	.l-header__nav ul li {
		border-bottom: 1px solid #171515;
	}

	.l-header__nav ul li a {
		padding: 1.25rem 0;
	}

	.l-header__hum {
		position: relative;
		display: flex;
		align-items: center;
		justify-content: space-between;
		flex-direction: column;
		width: 44px;
		height: 32px;
		padding: 8px 10px;
		border: 2px solid #171515;
		border-radius: 6px;
		cursor: pointer;
		z-index: 1;
		box-sizing: border-box;
		background: transparent;
	}

	.l-header__hum span {
		display: block;
		width: 100%;
		height: 2px;
		background: #171515;
		transition: transform 0.3s ease, opacity 0.3s ease;
	}

	.l-header.active .l-header__nav {
		opacity: 1;
		visibility: visible;
		transform: translateY(0);
	}

	body.active {
		overflow: hidden;
	}
}

@media screen and (max-width: 767px) {
	.l-header__main {
		padding: 15px 20px;
	}

	.l-header__nav {
		padding: 5rem 20px 20px;
	}
}

/* ----- Footer ----- */

.l-footer {
	background: #fbfbfb;
	padding: 5rem 3.75rem;
	margin-top: auto;
}

.l-footer__container {
	max-width: 1200px;
	margin: 0 auto;
}

.l-footer__sitemap {
	display: flex;
	flex-wrap: wrap;
	margin: 0 0 3.75rem;
	gap: 0 2rem;
}

.l-footer__sitemap > ul {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	margin: 0 3.875rem 0 0;
	padding: 0;
	list-style: none;
}

.l-footer__sitemap > ul:last-child {
	margin-right: 0;
}

.l-footer__sitemap > ul > li > p {
	font-weight: 700;
	color: #303030;
	margin: 0 0 0.5rem;
}

.l-footer__sitemap ul ul {
	margin: 0.625rem 0 0;
	padding: 0;
	list-style: none;
}

.l-footer__sitemap ul ul li {
	margin: 0 0 6px;
}

.l-footer__sitemap a {
	display: inline-flex;
	align-items: center;
	color: #303030;
	text-decoration: none;
	font-size: 0.9375rem;
}

.l-footer__sitemap a[target="_blank"]:after {
	content: "";
	display: block;
	width: 12px;
	height: 12px;
	background: url("../images/icon-blank_dark.svg") 0 / cover;
	margin: 0 0 0 6px;
	transition: background 0.3s ease;
}

.l-footer__sitemap a:hover {
	color: #ffd700;
	opacity: 1;
}

.l-footer__sitemap a:hover[target="_blank"]:after {
	background: url("../images/icon-blank_yellow.svg") 0 / cover;
}

.l-footer__company p {
	margin: 0 0 1.25rem;
}

.l-footer__company p:nth-child(1) a {
	display: block;
	width: 90px;
	line-height: 0;
}

.l-footer__legal,
.l-footer__company p:not(:first-child) {
	font-family: 'Noto Sans JP', sans-serif;
	font-size: 1rem;
	font-weight: 400;
	color: #888;
	line-height: 1.6;
}

@media screen and (max-width: 767px) {
	.l-footer {
		padding: 5rem 2.5rem 2.5rem;
	}

	.l-footer__sitemap {
		display: block;
	}

	.l-footer__sitemap > ul {
		margin: 0 0 1.25rem;
	}
}

/* ----- Blog index cards (Alpaca-style) ----- */

.jp-post-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 2rem;
}

.post-card {
	margin: 0;
	border: 1px solid rgba(0, 0, 0, 0.08);
	border-radius: 8px;
	overflow: hidden;
	background: var(--background-primary, #fff);
	transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.post-card:hover {
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
	border-color: rgba(0, 0, 0, 0.12);
}

.post-card__link {
	display: flex;
	flex-direction: row;
	align-items: stretch;
	text-decoration: none;
	color: inherit;
	min-height: 180px;
}

/* No feature image: text-only row like stock Attila (no empty media column) */
.post-card--no-image .post-card__link {
	min-height: 0;
}

.post-card--no-image .post-card__body {
	flex: 1 1 100%;
	max-width: 100%;
	width: 100%;
}

.post-card__media {
	flex: 0 0 42%;
	max-width: 360px;
	min-height: 180px;
	background: #f0f0f0;
	position: relative;
	overflow: hidden;
}

.post-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.post-card__body {
	flex: 1;
	padding: 1.5rem 1.75rem;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 0.75rem;
}

.post-card__title {
	margin: 0;
	font-size: 1.375rem;
	font-weight: 700;
	line-height: 1.35;
	letter-spacing: -0.02em;
}

.post-card__title a {
	color: inherit;
	text-decoration: none;
}

.post-card__title a:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.post-card__excerpt {
	margin: 0;
	font-size: 1rem;
	line-height: 1.55;
	color: var(--color-content-secondary, #555);
	display: -webkit-box;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.post-card__cta {
	font-size: 0.9375rem;
	font-weight: 600;
	color: var(--ghost-accent-color, #f5a623);
	margin-top: auto;
	align-self: flex-start;
}

.post-card__link:hover .post-card__cta {
	text-decoration: underline;
	text-underline-offset: 3px;
}

@media screen and (max-width: 767px) {
	.post-card__link {
		flex-direction: column;
		min-height: 0;
	}

	.post-card__media {
		flex: none;
		max-width: none;
		width: 100%;
		min-height: 200px;
	}
}

/* Compact archive strip (tag/author) */

.jp-archive-strip {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 1.5rem 1.5rem;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.jp-archive-strip__label {
	display: block;
	font-size: 0.75rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: var(--color-content-secondary, #666);
	margin-bottom: 0.35rem;
}

.jp-archive-strip__title {
	margin: 0;
	font-size: 1.75rem;
	font-weight: 700;
	line-height: 1.2;
}

.jp-archive-strip__meta {
	display: block;
	margin-top: 0.35rem;
	font-size: 0.9375rem;
	color: var(--color-content-secondary, #666);
}
