/* ==========================================================================
   Site Chrome: Announcement Bar, Sticky Header, Mega Menu, Search, Drawers, Footer
   ========================================================================== */
.ms-announcement {
	background: var(--ms-pine);
	color: #F4EFE6;
	font-family: var(--ms-font-mono);
	font-size: 11px;
	letter-spacing: 0.08em;
	text-align: center;
	padding: 9px 0;
}

.ms-header {
	position: sticky;
	top: 0;
	z-index: 900;
	background: rgba(248, 246, 241, 0.94);
	backdrop-filter: blur(14px);
	border-bottom: 1px solid var(--ms-border);
}

.ms-header__inner {
	height: var(--ms-header-h);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.ms-header__left {
	display: flex;
	align-items: center;
	gap: 10px;
}

.ms-brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.ms-brand__mark {
	width: 34px;
	height: 34px;
	border-radius: 9px;
	background: var(--ms-ink);
	color: #F8F6F1;
	display: grid;
	place-items: center;
	font-family: var(--ms-font-display);
	font-weight: 800;
	font-size: 18px;
	letter-spacing: -0.04em;
}

.ms-brand--light .ms-brand__mark {
	background: var(--ms-accent);
	color: #FFFFFF;
}

.ms-brand__word {
	font-family: var(--ms-font-display);
	font-weight: 800;
	font-size: 18px;
	letter-spacing: 0.04em;
	color: var(--ms-ink);
}

.ms-brand__word span {
	color: var(--ms-accent);
}

.ms-brand--light .ms-brand__word {
	color: #FFFFFF;
}

/* Primary Nav */
.ms-nav {
	display: flex;
	align-items: center;
	gap: 26px;
}

.ms-nav__link {
	font-size: 14px;
	font-weight: 600;
	color: var(--ms-ink);
	background: none;
	border: none;
	padding: 8px 0;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 5px;
	transition: color 0.16s ease;
}

.ms-nav__link:hover {
	color: var(--ms-accent);
}

.ms-nav__dropdown {
	position: relative;
}

.ms-mega {
	position: absolute;
	top: calc(100% + 14px);
	left: 50%;
	transform: translateX(-50%) translateY(8px);
	width: 580px;
	background: var(--ms-surface);
	border: 1px solid var(--ms-border);
	border-radius: var(--ms-radius-lg);
	box-shadow: var(--ms-shadow-lg);
	padding: 20px;
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
}

.ms-nav__dropdown:hover .ms-mega,
.ms-nav__dropdown:focus-within .ms-mega {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	transform: translateX(-50%) translateY(0);
}

.ms-mega__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 10px;
}

.ms-mega__item {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 12px;
	border-radius: var(--ms-radius);
	transition: background 0.15s ease;
}

.ms-mega__item:hover {
	background: var(--ms-bg);
}

.ms-mega__dot {
	width: 11px;
	height: 11px;
	border-radius: 50%;
	background: var(--dot, var(--ms-accent));
	margin-top: 5px;
	flex-shrink: 0;
}

.ms-mega__item strong {
	display: block;
	font-size: 14px;
	font-weight: 700;
	margin-bottom: 2px;
}

.ms-mega__item strong em {
	font-style: normal;
	font-family: var(--ms-font-mono);
	font-size: 11.5px;
	color: var(--ms-ink-muted);
	font-weight: 500;
}

.ms-mega__item span {
	display: block;
	font-size: 12.5px;
	color: var(--ms-ink-soft);
	line-height: 1.4;
}

/* Header Actions */
.ms-header__actions {
	display: flex;
	align-items: center;
	gap: 6px;
}

.ms-icon-btn {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid transparent;
	background: transparent;
	display: inline-grid;
	place-items: center;
	cursor: pointer;
	position: relative;
	color: var(--ms-ink);
	transition: background 0.16s ease, border-color 0.16s ease;
}

.ms-icon-btn:hover {
	background: var(--ms-surface-alt);
	border-color: var(--ms-border);
}

.ms-cart-count,
.ms-wishlist-count {
	position: absolute;
	top: 2px;
	right: 2px;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--ms-accent);
	color: #FFFFFF;
	font-family: var(--ms-font-mono);
	font-size: 10.5px;
	font-weight: 700;
	display: none;
	align-items: center;
	justify-content: center;
}

.ms-cart-count.is-visible,
.ms-wishlist-count.is-visible {
	display: inline-flex;
}

.ms-mobile-trigger {
	display: none;
}

/* Search Overlay */
.ms-search-overlay {
	position: fixed;
	inset: 0;
	z-index: 1050;
	display: none;
}

.ms-search-overlay.is-open {
	display: block;
}

.ms-search-overlay__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(24, 26, 24, 0.5);
	backdrop-filter: blur(4px);
}

.ms-search-overlay__panel {
	position: relative;
	background: var(--ms-surface);
	padding: 24px 0 28px;
	border-bottom: 1px solid var(--ms-border);
	box-shadow: var(--ms-shadow-lg);
}

.ms-search-form {
	display: flex;
	align-items: center;
	gap: 12px;
	border: 1.5px solid var(--ms-border-strong);
	border-radius: 999px;
	padding: 8px 14px 8px 20px;
	background: var(--ms-bg);
}

.ms-search-form input[type="search"] {
	flex: 1;
	border: none;
	background: transparent;
	outline: none;
	font-size: 15.5px;
}

.ms-search-quick {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 14px;
	font-size: 12.5px;
	color: var(--ms-ink-muted);
}

.ms-search-quick button {
	padding: 5px 12px;
	border-radius: 999px;
	border: 1px solid var(--ms-border);
	background: var(--ms-bg);
	cursor: pointer;
	font-size: 12.5px;
	font-weight: 600;
}

.ms-search-quick button:hover {
	border-color: var(--ms-accent);
	color: var(--ms-accent);
}

.ms-search-results {
	margin-top: 18px;
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 14px;
}

.ms-search-hit {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px;
	border: 1px solid var(--ms-border);
	border-radius: var(--ms-radius);
	background: var(--ms-bg);
	transition: border-color 0.15s ease;
}

.ms-search-hit:hover {
	border-color: var(--ms-accent);
}

.ms-search-hit img {
	width: 56px;
	height: 56px;
	border-radius: 8px;
	object-fit: cover;
	background: #FFFFFF;
	flex-shrink: 0;
}

.ms-search-hit strong {
	display: block;
	font-size: 13px;
	line-height: 1.3;
	margin-bottom: 3px;
}

.ms-search-hit span {
	font-size: 12.5px;
	font-weight: 700;
	color: var(--ms-accent);
}

/* Mobile Nav Drawer */
.ms-mobile-drawer {
	position: fixed;
	inset: 0;
	z-index: 1060;
	display: none;
}

.ms-mobile-drawer.is-open {
	display: block;
}

.ms-mobile-drawer__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(24, 26, 24, 0.52);
}

.ms-mobile-drawer__panel {
	position: relative;
	width: min(340px, 88vw);
	height: 100%;
	background: var(--ms-bg);
	display: flex;
	flex-direction: column;
	overflow-y: auto;
	box-shadow: var(--ms-shadow-lg);
}

.ms-mobile-drawer__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 20px;
	border-bottom: 1px solid var(--ms-border);
}

.ms-mobile-drawer__links {
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.ms-mobile-drawer__links a {
	padding: 10px 12px;
	border-radius: 8px;
	font-weight: 600;
	font-size: 15px;
}

.ms-mobile-drawer__links a:hover {
	background: var(--ms-surface-alt);
}

.ms-mnav-primary {
	background: var(--ms-ink);
	color: #FFFFFF;
	text-align: center;
	margin-bottom: 10px;
}

.ms-mnav-label {
	font-family: var(--ms-font-mono);
	font-size: 10.5px;
	letter-spacing: 0.14em;
	color: var(--ms-ink-muted);
	margin: 14px 0 4px 12px;
}

.ms-mnav-niche {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.ms-mnav-niche em {
	font-style: normal;
	font-family: var(--ms-font-mono);
	font-size: 12px;
	color: var(--ms-ink-muted);
}

/* Footer */
.ms-footer {
	background: #171A17;
	color: #D7D3CA;
	padding: 68px 0 32px;
}

.ms-footer__grid {
	display: grid;
	grid-template-columns: 1.55fr 1fr 1fr 1.15fr;
	gap: 40px;
	padding-bottom: 44px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.11);
}

.ms-footer__about {
	margin: 18px 0 20px;
	font-size: 14px;
	color: #B4AFA4;
	max-width: 340px;
	line-height: 1.65;
}

.ms-footer__pills {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ms-footer__pills span {
	font-family: var(--ms-font-mono);
	font-size: 11px;
	padding: 5px 10px;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.16);
	color: #E7E2D8;
}

.ms-footer__col h4 {
	font-family: var(--ms-font-display);
	font-size: 15px;
	font-weight: 700;
	color: #FFFFFF;
	margin: 0 0 16px;
}

.ms-footer__col ul {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.ms-footer__col a {
	font-size: 14px;
	color: #B4AFA4;
	transition: color 0.16s ease;
}

.ms-footer__col a:hover {
	color: #FFFFFF;
}

.ms-footer__email {
	margin-top: 16px;
	font-size: 13px;
	color: #9C978B;
}

.ms-footer__email a {
	color: #F4D5A4;
	text-decoration: underline;
}

.ms-footer__bottom {
	padding-top: 24px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	font-size: 13px;
	color: #969185;
}

.ms-footer__legal {
	display: flex;
	gap: 20px;
}

.ms-footer__legal a:hover {
	color: #FFFFFF;
}

.ms-footer__pay {
	display: flex;
	gap: 6px;
}

.ms-footer__pay span {
	font-family: var(--ms-font-mono);
	font-size: 10px;
	padding: 4px 8px;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.08);
	color: #DDD8CE;
}

@media (max-width: 1024px) {
	.ms-nav {
		display: none;
	}
	.ms-mobile-trigger {
		display: inline-grid;
	}
	.ms-footer__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
	.ms-search-results {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.ms-desktop-only {
		display: none;
	}
	.ms-header__inner {
		height: 62px;
		gap: 6px;
	}
	.ms-header__left {
		gap: 6px;
		min-width: 0;
	}
	.ms-brand {
		gap: 7px;
	}
	.ms-brand__mark {
		width: 28px;
		height: 28px;
		font-size: 15px;
		border-radius: 7px;
	}
	.ms-brand__word {
		font-size: 15px;
		letter-spacing: 0.02em;
	}
	.ms-header__actions {
		gap: 2px;
		flex-shrink: 0;
	}
	.ms-icon-btn {
		width: 34px;
		height: 34px;
	}
	.ms-announcement {
		font-size: 10px;
		padding: 7px 0;
	}
	.ms-footer__grid {
		grid-template-columns: 1fr;
		gap: 28px;
	}
	.ms-search-results {
		grid-template-columns: 1fr;
	}
}
