/* ============================================================
 * マップ画面（修正依頼 No.0402 第4段・2026-11-18）
 * ------------------------------------------------------------
 *   入れ物は php/contents/map.php、動きは js/sp_map.js。
 *   ヘッダー（約64px）と下部メニュー（約73px・css/common.css の --jy-nav-h）のあいだを、地図で埋めます。
 *   ★ このページだけ、サイトの下のフッターは出しません（地図の高さが決まっているため）。
 * ============================================================ */
html:has(.jm-root) footer { display: none; }
.jm-main { padding: 0 !important; margin: 0; }

.jm-root {
	position: relative; display: flex; flex-direction: column;
	height: calc(100vh - 64px - var(--jy-nav-h, 73px) - env(safe-area-inset-bottom, 0px));
	height: calc(100dvh - 64px - var(--jy-nav-h, 73px) - env(safe-area-inset-bottom, 0px));
	background: #e5e7eb; overflow: hidden;
}
@media (min-width: 768px) {
	.jm-root { height: calc(100vh - 64px); height: calc(100dvh - 64px); }
}

/* モードのタブ（ヘッダー直下） */
.jm-tabs { flex: 0 0 auto; display: flex; background: #fff; border-bottom: 1px solid #f3f4f6; }
.jm-tabs button {
	flex: 1 1 0; height: 44px; font-size: 14px; font-weight: 800; color: #6b7280;
	background: none; border: 0; border-bottom: 2px solid transparent;
}
.jm-tabs button[aria-selected="true"] { color: #ea580c; border-bottom-color: #ea580c; }

.jm-stage { position: relative; flex: 1 1 auto; min-height: 0; }
.jm-map { position: absolute; inset: 0; }
/* 現在地が決まるまで隠す（はじめに東京が一瞬見えないように・No.0404 再修正）。3秒たったら必ず出ます */
.jm-map.is-wait { opacity: 0; }
.jm-stage { background: #f3f4f6; }

/* 絞り込みのチップ（横にスクロール） */
.jm-chips {
	position: absolute; top: 10px; left: 0; right: 0; z-index: 5; display: flex; gap: 8px;
	padding: 0 12px; overflow-x: auto; scrollbar-width: none;
}
.jm-chips[hidden] { display: none; }
.jm-chips::-webkit-scrollbar { display: none; }
.jm-chip {
	flex: 0 0 auto; padding: 7px 14px; font-size: 13px; font-weight: 700; color: #374151;
	background: #fff; border: 1px solid #e5e7eb; border-radius: 9999px;
	box-shadow: 0 1px 4px rgba(17, 24, 39, .16); white-space: nowrap;
}
.jm-chip.is-on { color: #fff; background: #ea580c; border-color: #ea580c; }

/* このエリアで検索／ひとこと */
.jm-search-area {
	position: absolute; top: 56px; left: 50%; transform: translateX(-50%); z-index: 6;
	padding: 8px 16px; font-size: 13px; font-weight: 800; color: #ea580c; background: #fff;
	border: 1px solid #fed7aa; border-radius: 9999px; box-shadow: 0 2px 8px rgba(17, 24, 39, .2);
}
.jm-search-area[hidden], .jm-note[hidden], .jm-sheet[hidden], .jm-pane[hidden] { display: none; }
.jm-note {
	position: absolute; top: 100px; left: 50%; transform: translateX(-50%); z-index: 5; margin: 0;
	max-width: calc(100% - 28px); padding: 6px 14px; font-size: 12px; color: #374151;
	background: rgba(255, 255, 255, .95); border-radius: 9999px; box-shadow: 0 1px 4px rgba(17, 24, 39, .15);
	text-align: center;
}

/* 現在地に戻る（右側）・チェックイン（左下） */
.jm-locate {
	position: absolute; right: 14px; bottom: 100px; z-index: 5; width: 46px; height: 46px;
	display: flex; align-items: center; justify-content: center; color: #2563eb;
	background: #fff; border: 0; border-radius: 50%; box-shadow: 0 2px 8px rgba(17, 24, 39, .25);
}
.jm-ci-btn {
	position: absolute; left: 14px; bottom: 20px; z-index: 5; display: inline-flex; align-items: center; gap: 6px;
	height: 44px; padding: 0 16px 0 12px; font-size: 14px; font-weight: 800; color: #111827;
	background: #fff; border: 1px solid #e5e7eb; border-radius: 9999px; box-shadow: 0 2px 8px rgba(17, 24, 39, .25);
}
.jm-ci-btn svg { color: #ea580c; }
.jm-root.has-sheet .jm-ci-btn { display: none; }
.jm-root.has-sheet .jm-locate { bottom: 190px; }

/* ピンの下のスポット名 */
.jm-lbl { text-shadow: -1px -1px 0 #fff, 1px -1px 0 #fff, -1px 1px 0 #fff, 1px 1px 0 #fff, 0 0 4px #fff; white-space: nowrap; }

/* スポットのパネル（小さく・右はClipのボタンを避ける） */
.jm-sheet {
	position: absolute; left: 12px; right: 84px; bottom: 12px; z-index: 6; display: flex; gap: 12px; padding: 12px;
	background: #fff; border-radius: 18px; box-shadow: 0 6px 24px rgba(17, 24, 39, .28);
}
@media (min-width: 768px) { .jm-sheet { right: auto; width: 420px; } }
.jm-sheet-thumb { flex: 0 0 auto; width: 84px; height: 84px; border-radius: 12px; overflow: hidden; background: #f3f4f6; display: block; }
.jm-sheet-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.jm-sheet-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding-right: 18px; }
.jm-sheet-name { font-size: 15px; font-weight: 800; line-height: 1.3; color: #111827; text-decoration: none; overflow-wrap: anywhere; }
.jm-sheet-meta { font-size: 12px; color: #6b7280; }
.jm-sheet-extra { margin: 0; font-size: 12px; color: #374151; }
.jm-sheet-extra a { color: #ea580c; font-weight: 700; margin-left: 4px; }
.jm-sheet-act { display: flex; gap: 8px; margin-top: 6px; }
.jm-btn {
	flex: 1 1 auto; display: inline-flex; align-items: center; justify-content: center; height: 36px; padding: 0 12px;
	font-size: 13px; font-weight: 800; color: #374151; background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; text-decoration: none;
}
.jm-btn.is-main { color: #fff; background: #ea580c; border-color: #ea580c; }
.jm-btn:disabled { opacity: .6; }
.jm-x {
	position: absolute; top: 6px; right: 8px; width: 28px; height: 28px; font-size: 20px; line-height: 1;
	color: #9ca3af; background: none; border: 0;
}

/* チェックイン候補・ログイン案内 */
.jm-pane {
	position: absolute; left: 12px; right: 12px; bottom: 12px; z-index: 6; padding: 14px; background: #fff;
	border-radius: 18px; box-shadow: 0 6px 24px rgba(17, 24, 39, .28); max-height: 62%; overflow: auto;
}
.jm-pane-head { display: flex; align-items: center; justify-content: space-between; }
.jm-pane-head b { font-size: 15px; font-weight: 800; color: #111827; }
.jm-pane-head .jm-x { position: static; }
.jm-pane-hint, .jm-pane-msg { margin: 6px 0 10px; font-size: 12px; color: #6b7280; }
.jm-ci-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-top: 1px solid #f3f4f6; }
.jm-ci-row > div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.jm-ci-row b { font-size: 14px; font-weight: 800; color: #111827; overflow-wrap: anywhere; }
.jm-ci-row span { font-size: 12px; color: #6b7280; }
.jm-ci-row .jm-btn { flex: 0 0 auto; }
.jm-login { text-align: center; }
.jm-login b { font-size: 15px; font-weight: 800; color: #111827; }
.jm-login-sub { margin: 6px 0 12px; font-size: 13px; color: #6b7280; }
.jm-login-btn {
	display: inline-flex; align-items: center; justify-content: center; height: 40px; padding: 0 28px;
	font-size: 14px; font-weight: 800; color: #fff; background: #ea580c; border-radius: 10px; text-decoration: none;
}

/* チェックイン候補：近くの施設（館・モールなど＝親）で、今日まだ未チェックインのものを先頭に（No.0404 ④） */
.jm-ci-row.is-parent { border-left: 3px solid #ea580c; padding-left: 10px; background: #fff7ed; }
