/*
 * banglao フロントページ（トップpage）専用スタイル。
 *
 * 土台: .local/top-design-prototype/（現在案 = styles.css）。
 * front-page.php でのみ読み込む（inc/enqueue.php / is_front_page）。
 * すべて .bl-front-page 配下にスコープし、他ページ・legacy CSS に影響させない。
 * 地図本体（#blmap-root）のデザインはショートコード側が持つのでここでは触らない。
 */

.bl-front-page {
	--bl-red: #d7282f;
	--bl-red-dark: #a91822;
	--bl-navy: #102a43; /* ヒーロー背景に使用 */
	--bl-blue: #185a8d;
	--bl-amber: #f0a51a;
	--bl-cream: #f7f4ee;
	--bl-ink: #17212b;
	--bl-muted: #65717d;
	--bl-line: #e2e4e7;
	--bl-shell: min(1180px, calc(100% - 48px));
}

/* --- 全幅レイアウト（このページだけ、祖先の横幅制限をすべて外す） ---------
   #container 〜 .content-in.wrap まで 100% に揃えるので、中の .bl-hero /
   .bl-section は width:100% がそのまま「画面いっぱい」になる。
   overflow-x:clip で万一のはみ出しを抑える（#container には掛けない＝ sticky ナビのため）。 */
.bl-front-page #container,
.bl-front-page #content,
.bl-front-page #content-in,
.bl-front-page .content-in.wrap {
	width: 100%;
	max-width: none;
	margin-left: 0;
	margin-right: 0;
	padding-left: 0;
	padding-right: 0;
}

.bl-front-page #content,
.bl-front-page #content-in,
.bl-front-page .content-in.wrap {
	overflow-x: clip;
}

/* フロントはヒーローがヘッダー。空になったヘッダー枠（ロゴ帯）は隠す。 */
.bl-front-page #header-container {
	display: none;
}

/* --- グローバルナビ：画面最上部に固定、群青（#102a43）基調 ------------- */
.bl-front-page #navi {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--bl-navy);
	border-bottom: 0;
	box-shadow: 0 2px 14px rgba(0, 0, 0, .22);
}

.bl-front-page #navi,
.bl-front-page #navi a,
.bl-front-page #navi .navi-menu-button,
.bl-front-page #navi .item-label,
.bl-front-page #navi .caption-wrap {
	color: #fff;
}

.bl-front-page #navi #banglao-global-menu > li > a {
	transition: color .15s;
}

.bl-front-page #navi #banglao-global-menu > li > a:hover,
.bl-front-page #navi #banglao-global-menu > li:hover > a {
	color: var(--bl-amber);
	background: transparent;
}

/* ドロップダウン（下層メニュー）も群青系で揃える */
.bl-front-page #navi .sub-menu {
	background: #17324e;
	box-shadow: 0 12px 30px rgba(0, 0, 0, .3);
}

.bl-front-page #navi .sub-menu a {
	color: #eaf0f6;
}

.bl-front-page #navi .sub-menu a:hover {
	background: rgba(255, 255, 255, .08);
	color: #fff;
}

/* Leaflet 地図の内部 z-index が sticky ナビを越えないよう、地図カードで stacking context を作る */
.bl-front-page .blmap-mapcard {
	isolation: isolate;
}

/* アンカーリンク（#map 等）で飛んだとき、固定ナビの下に見出しが隠れないように */
.bl-front-page .bl-section[id],
.bl-front-page .bl-hero {
	scroll-margin-top: 72px;
}

.bl-front-page #main.bl-front {
	padding: 0;
	overflow-x: clip;
	color: var(--bl-ink);
	font-feature-settings: "palt";
	line-height: 1.7;
}

.bl-front-page .bl-shell {
	width: var(--bl-shell);
	margin-inline: auto;
}

.bl-front-page .bl-front a {
	text-decoration: none;
}

/* --- ヒーロー --------------------------------------------------------
   バナー画像は 1000 x 313px（約3.2:1）。ヒーローの高さはこの比率に追従させ、
   広い/狭い画面では min/max で頭打ちにする（＝リサイズしても高さがブレない）。
   比率が合わない画面では背景 cover・中央基準で上下がトリミングされる。 */
.bl-hero {
	position: relative;
	overflow: hidden;
	width: 100%;
	aspect-ratio: 1000 / 313;
	min-height: 340px;
	max-height: 460px;
	background: var(--bl-navy);
}

.bl-hero__photo {
	position: absolute;
	inset: 0;
	background-image: url("img/hero-banner.jpg");
	background-repeat: no-repeat;
	background-position: center center;
	background-size: cover;
}

.bl-hero__overlay {
	position: absolute;
	inset: 0;
	/* 写真のうえで白文字が読めるように、左側を中心に締める。色は --bl-navy 寄り。 */
	background:
		linear-gradient(90deg, rgba(16, 42, 67, .92) 0%, rgba(16, 42, 67, .60) 44%, rgba(16, 42, 67, .12) 82%),
		linear-gradient(0deg, rgba(16, 42, 67, .48), transparent 42%);
}

/* 装飾リング。写真のうえなので白のごく淡いリングで奥行きだけ。 */
.bl-hero::after {
	content: "";
	position: absolute;
	width: 440px;
	height: 440px;
	border: 88px solid rgba(255, 255, 255, .10);
	border-radius: 50%;
	right: -170px;
	top: -190px;
	pointer-events: none;
}

.bl-hero__content {
	position: relative;
	z-index: 2;
	padding-top: clamp(56px, 11vh, 118px);
	color: #fff;
}

.bl-hero__content h1 {
	margin: 0 0 16px;
	font-size: clamp(32px, 4.6vw, 58px);
	line-height: 1.25;
	letter-spacing: -.04em;
	color: #fff;
}

.bl-hero__content h1 em {
	position: relative;
	font-style: normal;
}

.bl-hero__content h1 em::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 2px;
	height: 10px;
	background: var(--bl-red);
	z-index: -1;
}

.bl-hero__sub {
	margin: 0;
	font-size: clamp(15px, 1.4vw, 18px);
	font-weight: 500;
}

.bl-hero__cta {
	display: inline-flex;
	align-items: center;
	gap: 40px;
	margin-top: 22px;
	padding: 15px 22px;
	background: var(--bl-red);
	color: #fff;
	font-weight: 800;
	box-shadow: 0 12px 30px rgba(215, 40, 47, .3);
	transition: background .2s, transform .2s;
}

.bl-hero__cta:hover {
	background: var(--bl-red-dark);
	transform: translateY(-2px);
}

.bl-hero__cta span {
	font-size: 20px;
}

.bl-hero__stats {
	position: absolute;
	z-index: 3;
	right: max(24px, calc((100% - 1180px) / 2));
	bottom: 18px;
	display: flex;
	background: #fff;
	color: var(--bl-navy);
	border-radius: 4px;
	box-shadow: 0 12px 30px rgba(16, 42, 67, .18);
}

.bl-hero__stats div {
	display: flex;
	flex-direction: column;
	padding: 16px 30px;
}

.bl-hero__stats strong {
	font-family: "Outfit", sans-serif;
	font-weight: 800;
	font-size: 24px;
	line-height: 1.1;
}

.bl-hero__stats span {
	font-size: 11px;
	font-weight: 600;
	color: var(--bl-muted);
}

/* --- セクション共通 -------------------------------------------------- */
.bl-section {
	padding: clamp(56px, 8vw, 96px) 0;
	background: #fff;
}

.bl-section--station,
.bl-section--cond {
	background: var(--bl-cream);
}

.bl-heading {
	margin-bottom: clamp(24px, 3vw, 38px);
	border-left: 5px solid var(--bl-red);
	padding-left: 14px;
}

.bl-heading h2,
.bl-heading__title {
	margin: 0;
	font-size: clamp(20px, 2.2vw, 28px);
	line-height: 1.3;
	letter-spacing: -.03em;
	color: var(--bl-ink);
}

.bl-lead {
	margin: 10px 0 0;
	max-width: 640px;
	color: var(--bl-muted);
	font-size: 14px;
}

/* --- 地図（[shop_map] を包むだけ。中身のデザインは触らない） ------------ */
.bl-map-embed {
	border-radius: 20px;
}

/* --- 駅から探す（横向き BTS 路線図） --------------------------------- */
.bl-station-search {
	margin: 0;
}

.bl-station-map {
	--bl-station-color: #6ca342;
	display: block;
}

.bl-station-row {
	position: relative;
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	padding: 44px 12px 14px;
	border-top: 1px solid var(--bl-line);
	border-bottom: 1px solid var(--bl-line);
}

.bl-station-row::before {
	content: "";
	position: absolute;
	left: 10%;
	right: 10%;
	top: 75px;
	height: 6px;
	background: var(--bl-station-color);
}

.bl-station-row--next {
	width: 20%;
	min-width: 190px;
	margin-top: 42px;
	grid-template-columns: 1fr;
	border-bottom: 1px solid var(--bl-line);
}

.bl-station-row--next::before {
	left: 50%;
	right: 0;
}

.bl-station-row--next::after {
	content: "NEXT STATION";
	position: absolute;
	left: calc(100% + 14px);
	top: 66px;
	font-family: "Outfit", sans-serif;
	font-weight: 700;
	font-size: 9px;
	letter-spacing: .12em;
	color: #91a0ab;
	white-space: nowrap;
}

.bl-station-stop {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: 0 5px 28px;
}

.bl-station-stop__dot {
	width: 21px;
	height: 21px;
	margin-bottom: 18px;
	border: 5px solid var(--bl-station-color);
	border-radius: 50%;
	background: #fff;
	transition: transform .2s, background .2s;
	position: relative;
	z-index: 1;
}

.bl-station-stop:hover .bl-station-stop__dot {
	background: var(--bl-amber);
	transform: scale(1.2);
}

.bl-station-stop__code {
	position: absolute;
	top: -32px;
	padding: 3px 5px;
	border-radius: 4px;
	background: var(--bl-station-color);
	color: #fff;
	font-family: "Outfit", sans-serif;
	font-weight: 700;
	font-size: 11px;
}

.bl-station-stop__name {
	font-size: 16px;
	font-weight: 700;
	color: var(--bl-ink);
	transition: color .2s;
}

.bl-station-stop:hover .bl-station-stop__name {
	color: var(--bl-red);
}

.bl-station-stop__en {
	font-family: "Outfit", sans-serif;
	font-weight: 700;
	font-size: 9px;
	letter-spacing: .08em;
	color: var(--bl-muted);
}

/* --- 料理／条件のタイル（英字ラベルなし・矢印は右上） ----------------- */
.bl-cards {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 12px;
}

.bl-card {
	position: relative;
	isolation: isolate;
	aspect-ratio: 3 / 4;
	overflow: hidden;
	border-radius: 4px;
	background: var(--bl-navy);
	color: #fff;
	box-shadow: 0 8px 24px rgba(16, 42, 67, .08);
}

.bl-card::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -2;
	background-image: var(--bl-card-image);
	background-size: cover;
	background-position: center;
	transition: transform .45s ease;
}

.bl-card::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(0deg, rgba(5, 20, 32, .9) 0%, rgba(5, 20, 32, .4) 44%, rgba(5, 20, 32, .04) 76%);
}

.bl-card__label {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 16px 14px;
	font-size: clamp(15px, 1.4vw, 19px);
	font-weight: 700;
	text-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}

.bl-card__arrow {
	position: absolute;
	top: 12px;
	right: 12px;
	font-size: 16px;
	line-height: 1;
	color: #fff;
	transition: transform .25s, color .25s;
}

.bl-card:hover::before {
	transform: scale(1.06);
}

.bl-card:hover .bl-card__arrow {
	color: var(--bl-amber);
	transform: translateX(4px);
}

/* --- レスポンシブ -------------------------------------------------- */
@media (max-width: 900px) {
	.bl-front-page {
		--bl-shell: min(100% - 32px, 720px);
	}

	.bl-hero__stats {
		right: auto;
		left: 16px;
	}

	.bl-station-map {
		overflow-x: auto;
		padding-bottom: 8px;
	}

	.bl-station-row {
		grid-template-columns: repeat(5, 132px);
		width: 700px;
	}

	.bl-station-row--next {
		width: 132px;
		min-width: 132px;
	}

	.bl-station-row--next::after {
		left: auto;
		right: 0;
		top: -30px;
	}

	.bl-cards {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 600px) {
	.bl-front-page {
		--bl-shell: calc(100% - 28px);
	}

	.bl-hero {
		/* スマホは 3.2:1 だと低すぎるので min-height を優先。画像は上下トリミング。 */
		min-height: 460px;
		max-height: none;
	}

	.bl-hero::after {
		width: 280px;
		height: 280px;
		border-width: 56px;
		right: -130px;
		top: -130px;
	}

	.bl-hero__cta {
		gap: 24px;
	}

	.bl-cards {
		grid-template-columns: 1fr 1fr;
		gap: 9px;
	}
}

@media (min-width: 1000px) {
	.bl-cards {
		grid-template-columns: repeat(8, minmax(0, 1fr));
		gap: 9px;
	}

	.bl-card__label {
		padding: 13px;
		font-size: 15px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.bl-front-page .bl-front * {
		transition: none !important;
	}

	.bl-hero__photo {
		transform: none;
	}
}
