/*
 * Nhựa Style Branch Map v1.6.3
 * Approved dark/gold multisite branch locator.
 */

.nsbm {
	--nsbm-accent: #d7a05d;
	--nsbm-accent-rgb: 215, 160, 93;
	--nsbm-bg: #070b0a;
	--nsbm-panel: #0b100f;
	--nsbm-card: #0d1211;
	--nsbm-text: #f4ede3;
	--nsbm-muted: rgba(244, 237, 227, 0.72);
	--nsbm-line: rgba(var(--nsbm-accent-rgb), 0.28);
	--nsbm-list-width: 34%;
	--nsbm-map-height: 720px;
	--nsbm-item-min-height: 96px;
	--nsbm-map-link-offset: 24px;

	position: relative;
	display: grid;
	grid-template-columns: minmax(330px, var(--nsbm-list-width)) minmax(0, 1fr);
	height: var(--nsbm-map-height);
	min-height: 560px;
	overflow: hidden;
	color: var(--nsbm-text);
	background: var(--nsbm-bg);
	border: 1px solid rgba(var(--nsbm-accent-rgb), 0.55);
	border-radius: 22px;
	box-shadow: 0 28px 72px rgba(0, 0, 0, 0.44), inset 0 0 0 1px rgba(255, 255, 255, 0.018);
	isolation: isolate;
}

.nsbm--list-right {
	grid-template-columns: minmax(0, 1fr) minmax(330px, var(--nsbm-list-width));
}

.nsbm * {
	box-sizing: border-box;
}

.nsbm-icon {
	display: block;
	width: 1em;
	height: 1em;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
	flex: 0 0 auto;
}

/* Sidebar and title */
.nsbm__sidebar {
	display: flex;
	flex-direction: column;
	min-width: 0;
	min-height: 0;
	height: 100%;
	background:
		radial-gradient(circle at 32% 0%, rgba(var(--nsbm-accent-rgb), 0.075), transparent 31%),
		linear-gradient(180deg, #0b100f 0%, #070b0a 100%);
	border-right: 1px solid rgba(var(--nsbm-accent-rgb), 0.25);
}

.nsbm--list-right .nsbm__sidebar {
	order: 2;
	border-right: 0;
	border-left: 1px solid rgba(var(--nsbm-accent-rgb), 0.25);
}

.nsbm__header {
	flex: 0 0 auto;
	padding: 25px 28px 16px;
	text-align: center;
}

.nsbm__eyebrow {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-bottom: 12px;
	color: var(--nsbm-accent);
	font-size: 12px;
	font-weight: 700;
	line-height: 1.35;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.nsbm__eyebrow .nsbm-icon {
	width: 15px;
	height: 15px;
	stroke-width: 1.9;
}

.nsbm__title {
	margin: 0;
	color: var(--nsbm-text);
	font-family: Georgia, "Times New Roman", serif;
	font-size: clamp(29px, 2.35vw, 43px);
	font-weight: 700;
	line-height: 1.08;
	letter-spacing: -0.025em;
	text-wrap: balance;
}

.nsbm__title-divider {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 11px;
	margin: 17px auto 0;
	color: var(--nsbm-accent);
}

.nsbm__title-divider span {
	width: 72px;
	height: 1px;
	background: linear-gradient(90deg, transparent, rgba(var(--nsbm-accent-rgb), 0.85));
}

.nsbm__title-divider span:last-child {
	background: linear-gradient(90deg, rgba(var(--nsbm-accent-rgb), 0.85), transparent);
}

.nsbm__title-divider .nsbm-icon {
	width: 23px;
	height: 23px;
	stroke-width: 1.65;
}

/* Scrollable list */
.nsbm__list-shell {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
	padding: 0 14px 12px;
}

.nsbm__list {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 8px;
	min-height: 0;
	overflow-x: hidden;
	overflow-y: auto;
	overscroll-behavior: contain;
	scrollbar-gutter: stable;
	scrollbar-width: thin;
	scrollbar-color: var(--nsbm-accent) rgba(255, 255, 255, 0.045);
	padding: 0 7px 0 0;
}

.nsbm__list::-webkit-scrollbar {
	width: 6px;
}

.nsbm__list::-webkit-scrollbar-track {
	background: rgba(255, 255, 255, 0.045);
	border-radius: 999px;
}

.nsbm__list::-webkit-scrollbar-thumb {
	background: var(--nsbm-accent);
	border-radius: 999px;
}

.nsbm__entry {
	position: relative;
	flex: 0 0 auto;
	overflow: hidden;
	background: linear-gradient(145deg, #0d1211 0%, #080c0b 100%);
	border: 1px solid rgba(var(--nsbm-accent-rgb), 0.25);
	border-radius: 13px;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.018);
	transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.nsbm__entry:hover {
	border-color: rgba(var(--nsbm-accent-rgb), 0.5);
}

.nsbm__entry.is-active {
	background:
		radial-gradient(circle at 91% 9%, rgba(255, 222, 170, 0.12), transparent 34%),
		linear-gradient(135deg, #6a4929 0%, #49331f 54%, #231b13 100%);
	border-color: var(--nsbm-accent);
	box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3), inset 0 0 30px rgba(var(--nsbm-accent-rgb), 0.09);
}

.nsbm__item {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr) auto;
	align-items: start;
	gap: 14px;
	width: 100%;
	min-height: var(--nsbm-item-min-height);
	margin: 0;
	padding: 15px 16px;
	appearance: none;
	-webkit-appearance: none;
	color: var(--nsbm-text);
	font: inherit;
	text-align: left;
	background: transparent !important;
	border: 0 !important;
	border-radius: 0;
	box-shadow: none !important;
	cursor: pointer;
}

.nsbm__item:focus-visible {
	outline: 2px solid var(--nsbm-accent);
	outline-offset: -3px;
}

.nsbm__number {
	min-width: 2.05ch;
	padding-top: 2px;
	color: var(--nsbm-accent) !important;
	font-family: Georgia, "Times New Roman", serif;
	font-size: clamp(27px, 2vw, 36px);
	font-weight: 700;
	line-height: 1;
}

.nsbm__content {
	display: flex;
	flex-direction: column;
	gap: 5px;
	min-width: 0;
}

.nsbm__label {
	display: none;
}

.nsbm__name {
	color: var(--nsbm-text) !important;
	font-family: Georgia, "Times New Roman", serif;
	font-size: clamp(16px, 1.1vw, 19px);
	font-weight: 700;
	line-height: 1.22;
	letter-spacing: -0.012em;
	text-wrap: pretty;
}

.nsbm__meta {
	display: grid;
	grid-template-columns: 15px minmax(0, 1fr);
	align-items: start;
	gap: 7px;
	color: var(--nsbm-muted) !important;
	font-size: 11.5px;
	font-weight: 500;
	line-height: 1.45;
}

.nsbm__meta .nsbm-icon {
	width: 14px;
	height: 14px;
	margin-top: 1px;
	color: var(--nsbm-accent);
	stroke-width: 1.9;
}

.nsbm__hours {
	color: var(--nsbm-accent) !important;
	font-weight: 700;
	letter-spacing: 0.01em;
}

.nsbm__arrow {
	display: grid;
	place-items: center;
	align-self: center;
	width: 40px;
	height: 40px;
	color: var(--nsbm-accent) !important;
	background: rgba(4, 7, 6, 0.36);
	border: 1px solid rgba(var(--nsbm-accent-rgb), 0.55);
	border-radius: 50%;
	transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.nsbm__arrow .nsbm-icon {
	width: 19px;
	height: 19px;
}

.nsbm__item:hover .nsbm__arrow,
.nsbm__item.is-active .nsbm__arrow {
	transform: translateX(3px);
	background: rgba(var(--nsbm-accent-rgb), 0.12);
	border-color: var(--nsbm-accent);
}

.nsbm__entry-detail {
	display: none;
	align-items: center;
	justify-content: center;
	gap: 10px;
	margin: 0 13px 13px;
	padding: 12px 15px;
	color: var(--nsbm-accent) !important;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.25;
	text-decoration: none !important;
	background: rgba(5, 8, 7, 0.8);
	border: 1px solid rgba(255, 255, 255, 0.055);
	border-radius: 7px;
	transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.nsbm__entry.is-active .nsbm__entry-detail {
	display: flex;
}

.nsbm__entry-detail .nsbm-icon {
	width: 16px;
	height: 16px;
}

.nsbm__entry-detail:hover,
.nsbm__entry-detail:focus-visible {
	color: #f5c98f !important;
	background: #111613;
	transform: translateY(-1px);
}

.nsbm__scroll-hint {
	display: none;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	gap: 11px;
	padding: 11px 4px 0;
	color: var(--nsbm-accent);
	font-size: 13px;
	font-weight: 500;
	line-height: 1.3;
	text-align: center;
}

.nsbm__scroll-hint.is-visible {
	display: flex;
}

.nsbm__scroll-hint .nsbm-icon {
	width: 17px;
	height: 17px;
	animation: nsbm-bounce 1.8s ease-in-out infinite;
}

.nsbm__scroll-hint .nsbm-icon:last-child {
	animation-delay: 0.18s;
}

@keyframes nsbm-bounce {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(4px); }
}

/* Map. No custom detail card is rendered. */
.nsbm__map {
	position: relative;
	min-width: 0;
	min-height: 0;
	height: 100%;
	overflow: hidden;
	background: #060a09;
}

.nsbm__map::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 2;
	background:
		linear-gradient(180deg, rgba(3, 7, 6, 0.1), rgba(3, 7, 6, 0.2)),
		linear-gradient(90deg, rgba(3, 7, 6, 0.12), transparent 32%);
	pointer-events: none;
}

.nsbm__iframe {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 100%;
	border: 0;
	background: #060a09;
	filter: saturate(0.76) contrast(1.06) brightness(0.76);
}

.nsbm__loader {
	position: absolute;
	z-index: 7;
	inset: 0;
	display: grid;
	place-items: center;
	background: rgba(5, 9, 8, 0.5);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 160ms ease, visibility 160ms ease;
}

.nsbm__map.is-loading .nsbm__loader {
	opacity: 1;
	visibility: visible;
}

.nsbm__loader span {
	width: 38px;
	height: 38px;
	border: 3px solid rgba(255, 255, 255, 0.18);
	border-top-color: var(--nsbm-accent);
	border-radius: 50%;
	animation: nsbm-spin 0.8s linear infinite;
}

@keyframes nsbm-spin {
	to { transform: rotate(360deg); }
}

.nsbm__map-link {
	position: absolute;
	z-index: 5;
	right: var(--nsbm-map-link-offset);
	bottom: var(--nsbm-map-link-offset);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 11px;
	max-width: calc(100% - (var(--nsbm-map-link-offset) * 2));
	padding: 14px 20px;
	color: var(--nsbm-text) !important;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.25;
	text-decoration: none !important;
	background: linear-gradient(135deg, rgba(104, 72, 39, 0.96), rgba(46, 34, 23, 0.97));
	border: 1px solid rgba(var(--nsbm-accent-rgb), 0.76);
	border-radius: 9px;
	box-shadow: 0 13px 30px rgba(0, 0, 0, 0.34);
	transition: transform 180ms ease, filter 180ms ease, border-color 180ms ease;
}

.nsbm__map-link .nsbm-icon:first-child {
	width: 22px;
	height: 22px;
	color: #f3d6ab;
}

.nsbm__map-link .nsbm-icon:last-child {
	width: 15px;
	height: 15px;
}

.nsbm__map-link:hover,
.nsbm__map-link:focus-visible {
	color: #fff6e9 !important;
	filter: brightness(1.08);
	transform: translateY(-2px);
}

.nsbm__map-link.is-hidden {
	display: none;
}

.nsbm-empty {
	padding: 18px 20px;
	border: 1px dashed rgba(var(--nsbm-accent-rgb), 0.45);
	border-radius: 10px;
}

@media (max-width: 1180px) {
	.nsbm {
		--nsbm-list-width: 39%;
		--nsbm-map-height: 680px;
		grid-template-columns: minmax(310px, var(--nsbm-list-width)) minmax(0, 1fr);
	}

	.nsbm--list-right {
		grid-template-columns: minmax(0, 1fr) minmax(310px, var(--nsbm-list-width));
	}

	.nsbm__header {
		padding-inline: 20px;
	}

	.nsbm__item {
		gap: 11px;
		padding-inline: 13px;
	}
}

@media (max-width: 900px) {
	.nsbm {
		--nsbm-list-width: 42%;
		grid-template-columns: minmax(290px, var(--nsbm-list-width)) minmax(0, 1fr);
	}

	.nsbm--list-right {
		grid-template-columns: minmax(0, 1fr) minmax(290px, var(--nsbm-list-width));
	}

	.nsbm__title {
		font-size: 31px;
	}

	.nsbm__number {
		font-size: 28px;
	}

	.nsbm__name {
		font-size: 16px;
	}
}

@media (max-width: 767px) {
	.nsbm,
	.nsbm--list-right {
		display: flex;
		flex-direction: column;
		height: auto;
		min-height: 0;
		border-radius: 17px;
	}

	.nsbm__sidebar,
	.nsbm--list-right .nsbm__sidebar {
		order: 1;
		height: auto;
		border-right: 0;
		border-left: 0;
		border-bottom: 1px solid rgba(var(--nsbm-accent-rgb), 0.28);
	}

	.nsbm__header {
		padding: 22px 17px 14px;
	}

	.nsbm__eyebrow {
		font-size: 10.5px;
	}

	.nsbm__title {
		font-size: clamp(27px, 8vw, 35px);
	}

	.nsbm__title-divider {
		margin-top: 14px;
	}

	.nsbm__list-shell {
		padding: 0 10px 11px;
	}

	.nsbm__list {
		flex: none;
		max-height: 425px;
		padding-right: 5px;
	}

	.nsbm__item {
		grid-template-columns: auto minmax(0, 1fr) auto;
		min-height: 91px;
		gap: 10px;
		padding: 14px 12px;
	}

	.nsbm__number {
		font-size: 27px;
	}

	.nsbm__name {
		font-size: 16px;
	}

	.nsbm__meta {
		font-size: 11px;
	}

	.nsbm__arrow {
		width: 36px;
		height: 36px;
	}

	.nsbm__entry-detail {
		margin-inline: 10px;
		font-size: 13px;
	}

	.nsbm__scroll-hint {
		padding-top: 10px;
		font-size: 12px;
	}

	.nsbm__map,
	.nsbm--list-right .nsbm__map {
		order: 2;
		height: min(460px, 72vh);
		min-height: 390px;
	}

	.nsbm__map-link {
		right: 13px;
		bottom: 13px;
		width: calc(100% - 26px);
		max-width: none;
		padding: 13px 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.nsbm *,
	.nsbm *::before,
	.nsbm *::after {
		scroll-behavior: auto !important;
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
	}
}
