/**
 * =====================================================
 * みつピタジョブ関西
 * 共通求人カード
 * -----------------------------------------------------
 * 配置場所：
 * /wp-content/plugins/mitsupita-kansai/assets/front/css/job-card.css
 *
 * 役割：
 * ・全国版求人検索ページの求人カードデザインを共通利用する
 * ・応募区分タグ、NEWタグ、求人画像を整える
 * ・求人タイトル、企業、給与、勤務地、雇用形態を整える
 * ・特徴、福利厚生、休日休暇タグを整える
 * ・お気に入り、求人詳細ボタンを整える
 * ・PC、タブレット、スマートフォンへ対応する
 *
 * @package Mitsupita_Kansai
 * =====================================================
 */

/* =====================================================
 * カード全体
 * ===================================================== */

.mpj-job-card {
	width: 100%;
	margin: 0;
	padding: 0;
	color: #26352f;
	background: #ffffff;
	border: 1px solid #dce7e2;
	border-radius: 20px;
	box-shadow:
		0 8px 24px rgba(25, 76, 59, 0.08),
		0 2px 8px rgba(25, 76, 59, 0.04);
	overflow: hidden;
	transition:
		transform 0.25s ease,
		box-shadow 0.25s ease,
		border-color 0.25s ease;
}

.mpj-job-card:hover {
	transform: translateY(-3px);
	border-color: #b8d5c8;
	box-shadow:
		0 14px 34px rgba(25, 76, 59, 0.13),
		0 4px 12px rgba(25, 76, 59, 0.07);
}

.mpj-job-card * {
	box-sizing: border-box;
}

.mpj-job-card__inner {
	display: grid;
	grid-template-columns: minmax(250px, 32%) minmax(0, 1fr);
	width: 100%;
	min-height: 100%;
}

/* =====================================================
 * 画像エリア
 * ===================================================== */

.mpj-job-card__media {
	position: relative;
	display: flex;
	flex-direction: column;
	width: 100%;
	min-width: 0;
	background: #eef5f1;
	overflow: hidden;
}

.mpj-job-card__image-link {
	display: block;
	flex: 1 1 auto;
	width: 100%;
	height: 100%;
	min-height: 360px;
	color: inherit;
	text-decoration: none;
	overflow: hidden;
}

.mpj-job-card__image {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 360px;
	object-fit: cover;
	object-position: center;
	transition: transform 0.35s ease;
}

.mpj-job-card:hover .mpj-job-card__image {
	transform: scale(1.035);
}

.mpj-job-card__image--empty {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	min-height: 360px;
	color: #6f897e;
	background:
		linear-gradient(
			135deg,
			#eef5f1 0%,
			#e4efe9 100%
		);
}

.mpj-job-card__image--empty svg {
	display: block;
	fill: currentColor;
}

/* =====================================================
 * 画像上部タグエリア
 * ===================================================== */

.mpj-job-card__top-tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	flex: 0 0 auto;
	width: 100%;
	min-height: 54px;
	margin: 0;
	padding: 11px 14px;
	background: #ffffff;
	border-bottom: 1px solid #e1ebe6;
}

/* =====================================================
 * 応募区分タグ
 * ===================================================== */

.mpj-job-card__application-tag {
	position: static;
	z-index: auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	max-width: 100%;
	min-height: 32px;
	padding: 6px 11px;
	color: #ffffff;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.35;
	letter-spacing: 0.02em;
	border-radius: 999px;
	box-shadow: none;
}

.mpj-job-card__application-tag svg {
	display: block;
	flex: 0 0 auto;
	fill: currentColor;
}

.mpj-job-card__application-tag--referral {
	background: #176247;
}

.mpj-job-card__application-tag--direct {
	background: #b87820;
}

/* =====================================================
 * NEWタグ
 * ===================================================== */

.mpj-job-card__new-tag {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 58px;
	min-height: 32px;
	padding: 6px 12px;
	color: #ffffff;
	font-size: 12px;
	font-weight: 900;
	line-height: 1;
	letter-spacing: 0.1em;
	background: #cf5a4a;
	border: 1px solid #cf5a4a;
	border-radius: 999px;
	box-shadow: 0 3px 9px rgba(207, 90, 74, 0.18);
}

/* タグが1個だけでも高さを一定に保つ */
.mpj-job-card__top-tags:has(
	.mpj-job-card__application-tag:only-child
),
.mpj-job-card__top-tags:has(
	.mpj-job-card__new-tag:only-child
) {
	min-height: 54px;
}

/* =====================================================
 * 本文エリア
 * ===================================================== */

.mpj-job-card__content {
	display: flex;
	flex-direction: column;
	min-width: 0;
	padding: 27px 29px 25px;
	background: #ffffff;
}

/* =====================================================
 * キャッチコピー
 * ===================================================== */

.mpj-job-card__catch-copy {
	margin: 0 0 9px;
	padding: 0;
	color: #176247;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.65;
	letter-spacing: 0.02em;
}

/* =====================================================
 * 求人タイトル
 * ===================================================== */

.mpj-job-card__title {
	margin: 0;
	padding: 0;
	color: #21342d;
	font-size: clamp(20px, 1.8vw, 26px);
	font-weight: 800;
	line-height: 1.48;
	letter-spacing: 0.01em;
	word-break: break-word;
}

.mpj-job-card__title a {
	color: inherit;
	text-decoration: none;
	transition: color 0.2s ease;
}

.mpj-job-card__title a:hover,
.mpj-job-card__title a:focus-visible {
	color: #176247;
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 4px;
}

/* =====================================================
 * 掲載企業
 * ===================================================== */

.mpj-job-card__company {
	display: grid;
	grid-template-columns: 22px auto minmax(0, 1fr);
	align-items: start;
	gap: 8px;
	margin: 15px 0 0;
	padding: 12px 14px;
	color: #30483e;
	background: #f3f8f5;
	border: 1px solid #e5efea;
	border-radius: 12px;
}

.mpj-job-card__info-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	margin-top: 1px;
	color: #176247;
}

.mpj-job-card__info-icon svg {
	display: block;
	fill: currentColor;
}

.mpj-job-card__info-label {
	color: #5b7168;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.7;
	white-space: nowrap;
}

.mpj-job-card__info-value {
	min-width: 0;
	color: #26352f;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.7;
	word-break: break-word;
}

/* =====================================================
 * 求人情報一覧
 * ===================================================== */

.mpj-job-card__details {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 11px;
	margin: 18px 0 0;
}

.mpj-job-card__detail {
	display: grid;
	grid-template-columns: 34px minmax(0, 1fr);
	align-items: start;
	gap: 10px;
	min-width: 0;
	padding: 13px 14px;
	background: #ffffff;
	border: 1px solid #dfe9e4;
	border-radius: 13px;
}

.mpj-job-card__detail-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: 34px;
	color: #176247;
	background: #eaf3ee;
	border-radius: 50%;
}

.mpj-job-card__detail-icon svg {
	display: block;
	fill: currentColor;
}

.mpj-job-card__detail-body {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.mpj-job-card__detail-label {
	margin: 0 0 2px;
	color: #6b7d76;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.4;
}

.mpj-job-card__detail-value {
	color: #26352f;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.65;
	word-break: break-word;
}

/* =====================================================
 * 優先タグエリア
 * ===================================================== */

.mpj-job-card__tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 17px 0 0;
	padding: 0;
}

.mpj-job-card__tag {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	max-width: 100%;
	min-height: 32px;
	padding: 6px 10px;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.45;
	border: 1px solid transparent;
	border-radius: 999px;
}

.mpj-job-card__tag-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 17px;
	height: 17px;
}

.mpj-job-card__tag-icon svg {
	display: block;
	width: 100%;
	height: 100%;
	fill: currentColor;
}

.mpj-job-card__tag-category {
	flex: 0 0 auto;
	padding-right: 6px;
	font-size: 10px;
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: 0.03em;
	border-right: 1px solid currentColor;
	opacity: 0.72;
}

.mpj-job-card__tag-name {
	min-width: 0;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.45;
	word-break: break-word;
}

/* 求人の特徴 */

.mpj-job-card__tag--feature {
	color: #176247;
	background: #eaf5ef;
	border-color: #c7dfd2;
}

/* 福利厚生 */

.mpj-job-card__tag--benefit {
	color: #8a5717;
	background: #fff5e7;
	border-color: #eed5ad;
}

/* 休日休暇 */

.mpj-job-card__tag--holiday {
	color: #315f79;
	background: #edf6fa;
	border-color: #c7dfe9;
}

/* =====================================================
 * ボタンエリア
 * ===================================================== */

.mpj-job-card__actions {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
	gap: 12px;
	margin-top: auto;
	padding-top: 22px;
}

/* =====================================================
 * お気に入りボタン
 * ===================================================== */

.mpj-job-card__favorite {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 50px;
	margin: 0;
	padding: 11px 16px;
	color: #176247;
	font: inherit;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	background: #ffffff;
	border: 2px solid #176247;
	border-radius: 12px;
	cursor: pointer;
	appearance: none;
	transition:
		color 0.2s ease,
		background-color 0.2s ease,
		border-color 0.2s ease,
		transform 0.2s ease,
		box-shadow 0.2s ease;
}

.mpj-job-card__favorite:hover {
	color: #ffffff;
	background: #176247;
	box-shadow: 0 5px 14px rgba(23, 98, 71, 0.18);
	transform: translateY(-1px);
}

.mpj-job-card__favorite:focus-visible {
	outline: 3px solid rgba(23, 98, 71, 0.25);
	outline-offset: 3px;
}

.mpj-job-card__favorite[aria-pressed="true"],
.mpj-job-card__favorite.is-saved {
	color: #ffffff;
	background: #c64d64;
	border-color: #c64d64;
}

.mpj-job-card__favorite[aria-pressed="true"]:hover,
.mpj-job-card__favorite.is-saved:hover {
	background: #ad3d53;
	border-color: #ad3d53;
}

.mpj-job-card__favorite-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
}

.mpj-job-card__favorite-icon svg {
	display: block;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.mpj-job-card__favorite[aria-pressed="true"]
.mpj-job-card__favorite-icon svg,
.mpj-job-card__favorite.is-saved
.mpj-job-card__favorite-icon svg {
	fill: currentColor;
	stroke: currentColor;
}

.mpj-job-card__favorite-label {
	display: inline-block;
}

/* =====================================================
 * 求人詳細ボタン
 * ===================================================== */

.mpj-job-card__detail-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 50px;
	padding: 11px 16px;
	color: #ffffff;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	text-decoration: none;
	background: #176247;
	border: 2px solid #176247;
	border-radius: 12px;
	box-shadow: 0 5px 14px rgba(23, 98, 71, 0.16);
	transition:
		background-color 0.2s ease,
		border-color 0.2s ease,
		transform 0.2s ease,
		box-shadow 0.2s ease;
}

.mpj-job-card__detail-link:hover {
	color: #ffffff;
	background: #104c37;
	border-color: #104c37;
	text-decoration: none;
	transform: translateY(-1px);
	box-shadow: 0 7px 18px rgba(23, 98, 71, 0.22);
}

.mpj-job-card__detail-link:focus-visible {
	outline: 3px solid rgba(23, 98, 71, 0.25);
	outline-offset: 3px;
}

.mpj-job-card__detail-link svg {
	flex: 0 0 auto;
	display: block;
	fill: currentColor;
	transition: transform 0.2s ease;
}

.mpj-job-card__detail-link:hover svg {
	transform: translateX(3px);
}

/* =====================================================
 * 一覧内のカード間隔
 * ===================================================== */

.mpj-job-card + .mpj-job-card {
	margin-top: 24px;
}

/* =====================================================
 * タブレット
 * ===================================================== */

@media screen and (max-width: 991px) {

	.mpj-job-card__inner {
		grid-template-columns: minmax(220px, 34%) minmax(0, 1fr);
	}

	.mpj-job-card__media {
		height: auto;
		min-height: 0;
	}

	.mpj-job-card__image-link {
		flex: none;
		height: auto;
		min-height: 0;
	}

	.mpj-job-card__image,
	.mpj-job-card__image--empty {
		height: auto;
		min-height: 0;
		aspect-ratio: 4 / 3;
	}

	.mpj-job-card__content {
		position: relative;
		display: flex;
		height: auto;
		min-height: 0;
		padding: 23px 23px 21px;
		visibility: visible;
		opacity: 1;
	}

	.mpj-job-card__details {
		grid-template-columns: 1fr;
	}

	.mpj-job-card__actions {
		grid-template-columns: 1fr;
	}

}

/* =====================================================
 * スマートフォン
 * ===================================================== */

@media screen and (max-width: 767px) {

	.mpj-job-card {
		border-radius: 16px;
	}

	.mpj-job-card:hover {
		transform: none;
	}

	.mpj-job-card__inner {
		display: block;
		min-height: 0;
	}

	.mpj-job-card__media {
		display: block;
		height: auto;
		min-height: 0;
	}

	.mpj-job-card__image-link {
		display: block;
		flex: none;
		height: auto;
		min-height: 0;
		aspect-ratio: 16 / 9;
	}

	.mpj-job-card__image,
	.mpj-job-card__image--empty {
		display: block;
		width: 100%;
		height: auto;
		min-height: 0;
		aspect-ratio: 16 / 9;
		object-fit: cover;
	}

	.mpj-job-card__top-tags {
		min-height: 50px;
		gap: 7px;
		padding: 9px 11px;
	}

	.mpj-job-card__application-tag,
	.mpj-job-card__new-tag {
		min-height: 30px;
		padding: 6px 10px;
		font-size: 11px;
	}

	.mpj-job-card__content {
		padding: 20px 17px 19px;
	}

	.mpj-job-card__catch-copy {
		margin-bottom: 8px;
		font-size: 13px;
	}

	.mpj-job-card__title {
		font-size: 21px;
		line-height: 1.5;
	}

	.mpj-job-card__company {
		grid-template-columns: 22px minmax(0, 1fr);
		gap: 3px 8px;
		margin-top: 14px;
		padding: 12px 13px;
	}

	.mpj-job-card__info-label {
		grid-column: 2;
	}

	.mpj-job-card__info-value {
		grid-column: 2;
	}

	.mpj-job-card__details {
		gap: 10px;
		margin-top: 16px;
	}

	.mpj-job-card__detail {
		grid-template-columns: 32px minmax(0, 1fr);
		gap: 9px;
		padding: 12px 13px;
	}

	.mpj-job-card__detail-icon {
		width: 32px;
		height: 32px;
	}

	.mpj-job-card__tags {
		gap: 7px;
		margin-top: 15px;
	}

	.mpj-job-card__tag {
		min-height: 31px;
		padding: 6px 9px;
	}

	.mpj-job-card__actions {
		gap: 10px;
		padding-top: 20px;
	}

	.mpj-job-card__favorite,
	.mpj-job-card__detail-link {
		min-height: 48px;
		padding: 10px 13px;
		font-size: 14px;
	}

}

/* =====================================================
 * 小さいスマートフォン
 * ===================================================== */

@media screen and (max-width: 420px) {

	.mpj-job-card__content {
		padding-right: 15px;
		padding-left: 15px;
	}

	.mpj-job-card__title {
		font-size: 19px;
	}

	.mpj-job-card__detail-value,
	.mpj-job-card__info-value {
		font-size: 13px;
	}

	.mpj-job-card__tags {
		display: grid;
		grid-template-columns: 1fr;
	}

	.mpj-job-card__tag {
		width: 100%;
		justify-content: flex-start;
		border-radius: 10px;
	}

	.mpj-job-card__favorite,
	.mpj-job-card__detail-link {
		width: 100%;
	}

	.mpj-job-card__top-tags {
		align-items: flex-start;
	}

	.mpj-job-card__application-tag {
		white-space: normal;
		text-align: center;
	}

}

/* =====================================================
 * 動きを減らす設定
 * ===================================================== */

@media (prefers-reduced-motion: reduce) {

	.mpj-job-card,
	.mpj-job-card__image,
	.mpj-job-card__favorite,
	.mpj-job-card__detail-link,
	.mpj-job-card__detail-link svg {
		transition: none;
	}

	.mpj-job-card:hover,
	.mpj-job-card__favorite:hover,
	.mpj-job-card__detail-link:hover {
		transform: none;
	}

}

/**
 * =====================================================
 * スマートフォン求人カード
 * 画像高さ・本文表示の強制修正
 * =====================================================
 */

@media screen and (max-width: 767px) {

	.mpj-job-card,
	.mpj-job-card__inner {
		display: block !important;
		width: 100% !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		overflow: visible !important;
	}

	.mpj-job-card {
		overflow: hidden !important;
	}

	.mpj-job-card__media {
		position: relative !important;
		display: block !important;
		width: 100% !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		overflow: hidden !important;
	}

	.mpj-job-card__image-link {
		position: relative !important;
		display: block !important;
		width: 100% !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		aspect-ratio: auto !important;
		overflow: hidden !important;
	}

	.mpj-job-card__image {
		position: static !important;
		display: block !important;
		width: 100% !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		aspect-ratio: 16 / 9 !important;
		object-fit: cover !important;
		transform: none !important;
	}

	.mpj-job-card__image--empty {
		display: flex !important;
		width: 100% !important;
		height: auto !important;
		min-height: 200px !important;
		max-height: none !important;
		aspect-ratio: 16 / 9 !important;
	}

	.mpj-job-card__content {
		position: relative !important;
		z-index: 2 !important;
		display: flex !important;
		flex-direction: column !important;
		width: 100% !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		margin: 0 !important;
		padding: 20px 17px 19px !important;
		color: #26352f !important;
		background: #ffffff !important;
		overflow: visible !important;
		visibility: visible !important;
		opacity: 1 !important;
		transform: none !important;
	}

	.mpj-job-card__catch-copy,
	.mpj-job-card__title,
	.mpj-job-card__company,
	.mpj-job-card__details,
	.mpj-job-card__tags,
	.mpj-job-card__actions {
		position: static !important;
		height: auto !important;
		min-height: 0 !important;
		max-height: none !important;
		visibility: visible !important;
		opacity: 1 !important;
		transform: none !important;
	}

	.mpj-job-card__details {
		display: grid !important;
		grid-template-columns: 1fr !important;
	}

	.mpj-job-card__tags {
		display: flex !important;
	}

	.mpj-job-card__actions {
		display: grid !important;
		grid-template-columns: 1fr !important;
	}

}

/**
 * =====================================================
 * 求人カード：キャッチコピー強調
 * =====================================================
 */

.mpj-job-card__catch-copy {
	position: relative;
	margin: 0 0 16px;
	padding: 0 0 14px 14px;
	border-bottom: 2px solid rgba( 13, 111, 78, 0.16 );
	font-size: clamp( 1.05rem, 1.4vw, 1.3rem );
	font-weight: 800;
	line-height: 1.65;
	letter-spacing: 0.02em;
	color: #163d31;
}

.mpj-job-card__catch-copy::before {
	content: "";
	position: absolute;
	top: 0.35em;
	bottom: 0.35em;
	left: 0;
	width: 4px;
	border-radius: 999px;
	background: #08734f;
}

.mpj-job-card__catch-copy a {
	display: block;
	color: inherit;
	text-decoration: none;
	transition:
		color 0.2s ease,
		transform 0.2s ease;
}

.mpj-job-card__catch-copy a:hover,
.mpj-job-card__catch-copy a:focus-visible {
	color: #08734f;
}

.mpj-job-card__catch-copy a:focus-visible {
	outline: 3px solid rgba( 8, 115, 79, 0.22 );
	outline-offset: 4px;
	border-radius: 4px;
}

.mpj-job-card__company {
	margin-top: 0;
	font-size: 0.9rem;
}

.mpj-job-card__company .mpj-job-card__info-label {
	font-size: 0.72rem;
	font-weight: 700;
	color: #6a7d76;
}

.mpj-job-card__company .mpj-job-card__info-value {
	font-weight: 700;
	color: #29463d;
}

@media screen and ( max-width: 767px ) {

	.mpj-job-card__catch-copy {
		margin-bottom: 13px;
		padding-bottom: 12px;
		padding-left: 12px;
		font-size: 1rem;
		line-height: 1.6;
	}

	.mpj-job-card__catch-copy::before {
		width: 3px;
	}
}
