/* ============================================================
   PCP Core — Mobile Bottom Tab Bar (Phase 4)
   ============================================================ */

/* Hide on desktop, show on mobile only */
.pcp-bnav { display: none; }

@media (max-width: 768px) {
	.pcp-bnav {
		display: grid;
		grid-template-columns: repeat(4, 1fr);
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		background: #fff;
		border-top: 1px solid rgba(139,26,26,0.12);
		box-shadow: 0 -2px 12px rgba(0,0,0,0.08);
		z-index: 9998;
		padding-bottom: env(safe-area-inset-bottom, 0);
	}
	.pcp-bnav__tab {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 3px;
		padding: 8px 4px 6px;
		background: transparent;
		border: 0;
		text-decoration: none !important;
		color: var(--pcp-text-muted);
		font-family: inherit;
		font-size: 11px;
		font-weight: 600;
		cursor: pointer;
		min-height: 56px;
		transition: var(--pcp-transition);
		-webkit-tap-highlight-color: transparent;
	}
	.pcp-bnav__tab:hover,
	.pcp-bnav__tab:focus,
	.pcp-bnav__tab.is-active {
		color: var(--pcp-burgundy);
	}
	.pcp-bnav__icon {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		line-height: 1;
	}
	.pcp-bnav__label { line-height: 1; letter-spacing: 0.2px; }

	/* Push page content above the bar so footer & last items aren't hidden */
	body.pcp-has-bottom-nav { padding-bottom: 60px; }
	body.pcp-has-bottom-nav .site-footer,
	body.pcp-has-bottom-nav .pcp-footer { padding-bottom: 60px; }
}

/* ============================================================
   Slide‑up overlays (Search & Browse)
   ============================================================ */
.pcp-overlay {
	position: fixed;
	inset: 0;
	background: rgba(60, 12, 12, 0.55);
	z-index: 9999;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.25s ease;
}
.pcp-overlay[hidden] { display: none; }
.pcp-overlay.is-open {
	opacity: 1;
	pointer-events: auto;
}

.pcp-overlay__panel {
	background: var(--pcp-cream);
	width: 100%;
	max-width: 640px;
	max-height: 92vh;
	border-radius: 18px 18px 0 0;
	box-shadow: 0 -8px 30px rgba(0,0,0,0.25);
	transform: translateY(100%);
	transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.3, 1);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}
.pcp-overlay.is-open .pcp-overlay__panel { transform: translateY(0); }

.pcp-overlay__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 18px;
	background: var(--pcp-burgundy);
	color: var(--pcp-cream);
	border-bottom: 2px solid var(--pcp-gold);
	flex-shrink: 0;
}
.pcp-overlay__title {
	margin: 0;
	font-family: var(--pcp-font-serif);
	font-size: 18px;
	color: var(--pcp-cream);
	font-weight: 600;
}
.pcp-overlay__close {
	background: transparent;
	border: 0;
	color: var(--pcp-cream);
	cursor: pointer;
	padding: 6px;
	border-radius: 50%;
	display: inline-flex;
	transition: var(--pcp-transition);
}
.pcp-overlay__close:hover { background: rgba(255,255,255,0.12); }

.pcp-overlay__body {
	padding: 18px;
	overflow-y: auto;
	flex: 1;
	-webkit-overflow-scrolling: touch;
}

/* Search overlay specifics */
.pcp-overlay__search {
	display: flex;
	align-items: center;
	background: #fff;
	border: 1px solid rgba(139,26,26,0.2);
	border-radius: 999px;
	padding: 4px 4px 4px 14px;
	margin-bottom: 18px;
}
.pcp-overlay__search-icon { color: var(--pcp-burgundy); flex-shrink: 0; }
.pcp-overlay__search input[type="search"] {
	flex: 1;
	border: 0;
	outline: 0;
	background: transparent;
	padding: 12px;
	font-size: 16px;
	color: var(--pcp-text);
	min-width: 0;
	font-family: inherit;
}
.pcp-overlay__search input::placeholder { color: #999; }
.pcp-overlay__search-btn {
	background: var(--pcp-burgundy);
	color: #fff;
	border: 0;
	border-radius: 999px;
	padding: 10px 18px;
	font-weight: 600;
	font-size: 14px;
	font-family: inherit;
	cursor: pointer;
}
.pcp-overlay__search-btn:hover { background: var(--pcp-burgundy-deep); }

.pcp-overlay__lead {
	font-size: 13px;
	color: var(--pcp-text-muted);
	margin: 0 0 10px;
	font-weight: 600;
	letter-spacing: 0.3px;
}
.pcp-overlay__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.pcp-overlay__chip {
	display: inline-block;
	padding: 8px 14px;
	background: #fff;
	border: 1px solid rgba(139,26,26,0.18);
	border-radius: 999px;
	color: var(--pcp-burgundy);
	font-size: 13px;
	font-weight: 600;
	text-decoration: none !important;
	transition: var(--pcp-transition);
}
.pcp-overlay__chip:hover {
	background: var(--pcp-burgundy);
	color: var(--pcp-cream);
	border-color: var(--pcp-burgundy);
}

/* Browse overlay specifics */
.pcp-overlay__list {
	list-style: none;
	margin: 0;
	padding: 0;
	background: #fff;
	border: 1px solid rgba(139,26,26,0.10);
	border-radius: var(--pcp-radius-lg);
	overflow: hidden;
}
.pcp-overlay__list-item {
	margin: 0;
	padding: 0;
	border-bottom: 1px solid rgba(139,26,26,0.08);
	list-style: none;
}
.pcp-overlay__list-item::before { content: none !important; }
.pcp-overlay__list-item:last-child { border-bottom: 0; }
.pcp-overlay__list-link {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px 16px;
	color: var(--pcp-text);
	text-decoration: none !important;
	transition: var(--pcp-transition);
}
.pcp-overlay__list-link:hover { background: rgba(201,168,76,0.08); }
.pcp-overlay__list-icon {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px; height: 36px;
	background: rgba(139,26,26,0.07);
	color: var(--pcp-burgundy);
	border-radius: 50%;
}
.pcp-overlay__list-link:hover .pcp-overlay__list-icon {
	background: var(--pcp-burgundy);
	color: var(--pcp-cream);
}
.pcp-overlay__list-name {
	flex: 1;
	font-family: var(--pcp-font-serif);
	font-size: 16px;
	font-weight: 700;
	color: var(--pcp-burgundy);
	min-width: 0;
}
.pcp-overlay__list-count {
	flex-shrink: 0;
	font-size: 11px;
	font-weight: 700;
	color: var(--pcp-gold-dark);
	background: rgba(201,168,76,0.14);
	padding: 3px 9px;
	border-radius: 999px;
	white-space: nowrap;
}

/* Body scroll lock when overlay is open */
body.pcp-overlay-open { overflow: hidden; }
