/**
 * Customer mobile-app shell — bottom navigation.
 *
 * @package OziPlatform\B2B
 */

:root {
	--ozi-app-max: 430px;
	--ozi-bottom-nav-h: 64px;
	--ozi-app-header-h: 56px;
	--ozi-shop-cart-h: 56px;
	--ozi-stepper-btn-size: 44px;
	--ozi-stepper-input-min-width: 52px;
	--ozi-stepper-height: 44px;
	--ozi-customer-bottom-pad: calc(var(--ozi-bottom-nav-h) + env(safe-area-inset-bottom, 0) + 16px);
}

.ozi-app-shell {
	max-width: var(--ozi-app-max);
	margin: 0 auto;
	min-height: 100dvh;
	display: flex;
	flex-direction: column;
	background: var(--ozi-color-background);
}

@media (min-width: 768px) {
	.ozi-app-shell {
		max-width: 960px;
	}
}

.ozi-app-shell__header {
	position: sticky;
	top: 0;
	z-index: 20;
	height: var(--ozi-app-header-h);
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 16px;
	background: var(--ozi-color-primary);
	color: #fff;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.ozi-app-shell__header-brand {
	display: flex;
	flex-direction: column;
	line-height: 1.15;
}

.ozi-app-shell__header-brand strong {
	font-size: 15px;
	font-weight: 700;
}

.ozi-app-shell__header-brand span {
	font-size: 11px;
	opacity: 0.85;
}

.ozi-app-shell__header-action {
	margin: 0;
}

.ozi-app-shell__header-action .ozi-portal-btn {
	min-height: 36px;
	padding: 6px 12px;
	font-size: 12px;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.2);
}

.ozi-portal-body.ozi-app-body {
	min-height: 100dvh;
}

.ozi-app-shell__main {
	flex: 1 1 auto;
	min-height: 0;
	padding: 16px 16px var(--ozi-customer-bottom-pad);
}

.ozi-app-shell__main--shop {
	padding-bottom: calc(var(--ozi-bottom-nav-h) + var(--ozi-shop-cart-h) + env(safe-area-inset-bottom, 0) + 16px);
}

body.ozi-cart-drawer-open .ozi-app-shell__main,
body.ozi-sheet-open .ozi-app-shell__main {
	padding-bottom: 16px;
}

.ozi-app-shell__back-wrap {
	margin: 0 0 8px;
}

.ozi-app-shell__back {
	display: inline-flex;
	align-items: center;
	font-size: 14px;
	font-weight: 600;
	color: var(--ozi-color-primary);
	text-decoration: none;
}

.ozi-app-shell__main .ozi-page-title {
	margin: 0 0 14px;
	font-size: 1.25rem;
	color: var(--ozi-color-primary);
}

.ozi-app-shell__nav {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 30;
	display: flex;
	justify-content: space-around;
	align-items: stretch;
	height: calc(var(--ozi-bottom-nav-h) + env(safe-area-inset-bottom, 0));
	padding-bottom: env(safe-area-inset-bottom, 0);
	background: #fff;
	border-top: 1px solid var(--ozi-color-border);
	box-shadow: 0 -4px 20px rgba(16, 24, 40, 0.08);
}

.ozi-app-shell__nav-link {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 3px;
	min-height: var(--ozi-bottom-nav-h);
	padding: 6px 4px;
	text-decoration: none;
	color: var(--ozi-color-muted);
	font-size: 10px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.ozi-app-shell__nav-link svg,
.ozi-app-shell__nav-icon {
	width: 22px;
	height: 22px;
	opacity: 0.7;
}

.ozi-app-shell__nav-link.is-active {
	color: var(--ozi-color-accent);
}

.ozi-app-shell__nav-link.is-active .ozi-app-shell__nav-icon {
	opacity: 1;
}

body.ozi-cart-drawer-open .ozi-app-shell__nav,
body.ozi-sheet-open .ozi-app-shell__nav {
	visibility: hidden;
	pointer-events: none;
}

body.ozi-cart-drawer-open,
body.ozi-sheet-open {
	overflow: hidden;
}

@media (min-width: 768px) {
	.ozi-app-shell__nav {
		left: 50%;
		transform: translateX(-50%);
		max-width: 960px;
		border-radius: 12px 12px 0 0;
	}
}
