/* Шапка сайта: верхняя полоса (nav#top), header, меню категорий (nav#menu). Подключается после stylesheet.css и переопределяет его */

/* ---------- Верхняя полоса ---------- */
#top {
	background: #f4f6fb;
	border-bottom: 1px solid #e3e6ef;
	margin: 0;
	padding: 0;
	min-height: 0;
	font-size: 13px;
}
#top .container.hdr-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	min-height: 38px;
	padding: 0 15px;
}
.hdr-top:before,
.hdr-top:after {
	content: none;
}
.hdr-top > ul {
	display: flex;
	align-items: center;
	gap: 24px;
	list-style: none;
	margin: 0;
	padding: 0;
}
#top .hdr-top-info li {
	color: #7a7f95;
}
.hdr-top-info .fa {
	color: #1d2371;
	margin-right: 4px;
}
.hdr-top-phone {
	display: none;
}
#top .hdr-top a,
#top-links a {
	color: #3a3f55;
	text-shadow: none;
	text-decoration: none;
	transition: color .15s;
}
#top .hdr-top a:hover,
#top-links a:hover {
	color: #e8322b;
}
#top-links {
	padding-top: 0;
}
#top-links .fa-user {
	color: #1d2371;
	margin-right: 3px;
}
#top-links .fa-angle-down {
	margin-left: 2px;
	color: #7a7f95;
}
#top .dropdown-menu {
	min-width: 190px;
	margin-top: 8px;
	padding: 6px;
	border: 1px solid #e3e6ef;
	border-radius: 12px;
	box-shadow: 0 12px 32px rgba(29,35,113,.12);
}
#top .dropdown-menu li > a {
	padding: 8px 12px;
	border-radius: 8px;
	color: #3a3f55;
}
#top .dropdown-menu li > a:hover {
	background: #f4f6fb;
	background-image: none;
	color: #1d2371;
}

/* ---------- Логотип, поиск, контакты, корзина ---------- */
header.hdr {
	background: #fff;
}
.hdr-main {
	display: flex;
	align-items: center;
	gap: 28px;
	padding-top: 18px;
	padding-bottom: 18px;
}
.hdr-main:before,
.hdr-main:after {
	content: none;
}
.hdr-main #logo {
	flex: 0 0 auto;
	margin: 0;
}
.hdr-main #logo img {
	max-height: 46px;
	width: auto;
}
.hdr-main #logo h1 {
	margin: 0;
	font-size: 24px;
}
.hdr-search {
	flex: 1 1 auto;
	min-width: 0;
}
header #search {
	margin: 0;
	width: 100%;
}
header #search .form-control {
	height: 46px;
	padding: 0 16px;
	font-size: 14px;
	line-height: 46px;
	color: #3a3f55;
	background: #f4f6fb;
	border: 2px solid #f4f6fb;
	border-right: 0;
	border-radius: 12px 0 0 12px;
	box-shadow: none;
	transition: border-color .15s, background .15s;
}
header #search .form-control:focus {
	background: #fff;
	border-color: #1d2371;
}
header #search .form-control::placeholder {
	color: #7a7f95;
}
header #search .btn {
	height: 46px;
	padding: 0 22px;
	font-size: 16px;
	color: #fff;
	background: #e8322b;
	background-image: none;
	border: 0;
	border-radius: 0 12px 12px 0;
	box-shadow: none;
	text-shadow: none;
	transition: background .15s;
}
header #search .btn:hover,
header #search .btn:focus {
	background: #c9241e;
}

.hdr-contacts {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	line-height: 1.35;
}
.hdr-phone {
	font-size: 19px;
	font-weight: 700;
	color: #1d2371;
	white-space: nowrap;
}
.hdr-phone:hover {
	color: #e8322b;
	text-decoration: none;
}
.hdr-hours {
	font-size: 12px;
	color: #7a7f95;
	white-space: nowrap;
}
.hdr-hours a {
	color: #1fa855;
	font-weight: 600;
}
.hdr-hours a:hover {
	color: #168a44;
	text-decoration: none;
}

.hdr-actions {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 8px;
}
.hdr-icon {
	position: relative;
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-width: 64px;
	height: 46px;
	padding: 0 6px;
	color: #1d2371;
	border-radius: 12px;
	transition: background .15s;
}
.hdr-icon:hover,
.hdr-icon:focus {
	color: #1d2371;
	background: #f4f6fb;
	text-decoration: none;
}
.hdr-icon .fa {
	font-size: 20px;
	line-height: 1;
}
.hdr-icon-label {
	margin-top: 4px;
	font-size: 11px;
	font-style: normal;
	color: #7a7f95;
}
.hdr-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

/* Бейдж-счётчик (закладки, корзина): число берётся из data-count */
#wishlist-total[data-count]:after,
#cart[data-count]:after {
	content: attr(data-count);
	position: absolute;
	min-width: 20px;
	height: 20px;
	padding: 0 5px;
	font-size: 11px;
	font-weight: 700;
	line-height: 16px;
	text-align: center;
	color: #fff;
	background: #e8322b;
	border: 2px solid #fff;
	border-radius: 10px;
	box-sizing: border-box;
	pointer-events: none;
}
#wishlist-total[data-count]:after {
	top: -1px;
	left: 50%;
	margin-left: 4px;
}
#cart[data-count]:after {
	top: -7px;
	left: 26px;
	z-index: 3;
}
#wishlist-total[data-count="0"]:after,
#cart[data-count="0"]:after {
	display: none;
}

/* Корзина */
header #cart {
	position: relative;
	display: inline-block;
	width: auto;
	margin: 0;
}
header #cart > .btn,
header #cart.open > .btn {
	display: flex;
	align-items: center;
	gap: 10px;
	width: auto;
	height: 46px;
	padding: 0 18px 0 14px;
	font-size: 13px;
	line-height: 1.2;
	text-align: left;
	color: #fff;
	background: #1d2371;
	background-image: none;
	border: 0;
	border-radius: 12px;
	box-shadow: none;
	text-shadow: none;
	transition: background .15s;
}
header #cart > .btn:hover,
header #cart.open > .btn {
	color: #fff;
	background: #2a319a;
}
header #cart > .btn .fa-shopping-cart {
	font-size: 20px;
}
header #cart-total b,
header #cart-total small {
	display: block;
	white-space: nowrap;
}
header #cart-total b {
	font-size: 13px;
	font-weight: 700;
}
header #cart-total small {
	font-size: 12px;
	opacity: .75;
}
/* ---------- Мини-корзина (выпадает из кнопки «Корзина», шаблон common/cart.tpl) ---------- */
header #cart .dropdown-menu.hc {
	width: 400px;
	min-width: 0;
	margin-top: 10px;
	padding: 0;
	background: #fff;
	border: 1px solid #e3e6ef;
	border-radius: 16px;
	box-shadow: 0 18px 48px rgba(29,35,113,.18);
	overflow: hidden;
}
header #cart .hc > li {
	display: block;
}
/* Перебиваем старое из stylesheet.css (#cart .dropdown-menu li > div { min-width: 427px }) */
header #cart .hc > li > div {
	min-width: 0;
}
header #cart .hc-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	padding: 14px 18px 10px;
	border-bottom: 1px solid #eceef4;
}
header #cart .hc-head b {
	font-size: 16px;
	color: #1d2371;
}
header #cart .hc-head span {
	font-size: 13px;
	color: #7a7f95;
}
header #cart .hc-items {
	max-height: 340px;
	overflow-y: auto;
	overscroll-behavior: contain;
	scrollbar-width: thin;
}
header #cart .hc .hc-item {
	display: grid;
	grid-template-columns: 56px minmax(0, 1fr) 28px;
	gap: 12px;
	align-items: start;
	padding: 12px 14px 12px 18px;
}
header #cart .hc-item + .hc-item {
	border-top: 1px solid #f1f2f7;
}
header #cart .hc-img {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	padding: 4px;
	color: #b4b8c8;
	background: #fff;
	border: 1px solid #eceef4;
	border-radius: 10px;
}
header #cart .hc-img img {
	max-width: 100%;
	max-height: 100%;
	object-fit: contain;
}
header #cart .hc-name,
header #cart .hc-name:focus {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.35;
	color: #1d2371;
}
header #cart a.hc-name:hover {
	color: #e8322b;
	text-decoration: none;
}
header #cart .hc-opt {
	display: block;
	font-size: 12px;
	color: #7a7f95;
}
header #cart .hc-sum {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 8px;
	margin-top: 6px;
}
header #cart .hc-qty {
	font-size: 12px;
	color: #7a7f95;
	white-space: nowrap;
}
header #cart .hc-sum b {
	font-size: 14px;
	color: #1d2371;
	white-space: nowrap;
}
header #cart .hc-remove {
	width: 28px;
	height: 28px;
	padding: 0;
	font-size: 13px;
	color: #9a9eb0;
	background: none;
	border: 0;
	border-radius: 8px;
	transition: color .2s, background .2s;
}
header #cart .hc-remove:hover,
header #cart .hc-remove:focus {
	color: #e8322b;
	background: #fdecea;
	outline: 0;
}
header #cart .hc-foot {
	padding: 14px 18px 18px;
	background: #f8f9fc;
	border-top: 1px solid #eceef4;
}
header #cart .hc-total {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	font-size: 13px;
	color: #7a7f95;
}
header #cart .hc-total + .hc-total {
	margin-top: 4px;
}
header #cart .hc-total-main {
	margin: 6px 0 14px;
	font-size: 15px;
	font-weight: 700;
	color: #1d2371;
}
header #cart .hc-total-main b {
	font-size: 20px;
}
header #cart .hc-btn,
header #cart .hc-btn:focus {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 46px;
	font-size: 15px;
	font-weight: 700;
	border-radius: 12px;
	transition: background .2s, color .2s, border-color .2s;
}
header #cart .hc-btn:hover {
	text-decoration: none;
}
header #cart .hc-btn-checkout,
header #cart .hc-btn-checkout:focus {
	color: #fff;
	background: #e8322b;
	box-shadow: 0 6px 16px rgba(232,50,43,.25);
}
header #cart .hc-btn-checkout:hover {
	color: #fff;
	background: #c9241e;
}
header #cart .hc-btn-cart,
header #cart .hc-btn-cart:focus {
	margin-top: 8px;
	height: 42px;
	font-size: 14px;
	color: #1d2371;
	background: #fff;
	border: 1px solid #d5d9e6;
}
header #cart .hc-btn-cart:hover {
	color: #1d2371;
	border-color: #1d2371;
}
header #cart .hc-empty {
	padding: 28px 24px 22px;
	text-align: center;
}
header #cart .hc-empty > .fa {
	display: block;
	width: 60px;
	height: 60px;
	margin: 0 auto 12px;
	font-size: 24px;
	line-height: 60px;
	color: #1d2371;
	background: #eef0fa;
	border-radius: 50%;
}
header #cart .hc-empty b {
	display: block;
	margin-bottom: 4px;
	font-size: 16px;
	color: #1d2371;
}
header #cart .hc-empty span {
	display: block;
	margin-bottom: 14px;
	font-size: 13px;
	line-height: 1.5;
	color: #7a7f95;
}

/* ---------- Меню категорий ---------- */
.hdr-nav {
	background: #1d2371;
	margin-bottom: 24px;
}
#menu {
	min-height: 0;
	margin: 0;
	background: none;
	border: 0;
	border-radius: 0;
}
#menu .navbar-collapse {
	padding: 0;
}
#menu .nav > li > a {
	padding: 15px 13px;
	font-size: 14px;
	font-weight: 600;
	color: #fff;
	text-shadow: none;
	background: transparent;
	transition: background .15s;
}
#menu .nav > li > a:hover,
#menu .nav > li > a:focus,
#menu .nav > li.open > a {
	background: rgba(255,255,255,.1);
}
#menu .hdr-caret {
	margin-left: 3px;
	opacity: .6;
}
#menu .nav > li.hdr-menu-accent > a,
#menu .nav > li.hdr-menu-accent > a:focus {
	margin: 8px 0 8px 8px;
	padding: 7px 16px;
	background: #e8322b;
	border-radius: 10px;
}
#menu .nav > li.hdr-menu-accent > a:hover {
	background: #c9241e;
}
#menu .hdr-menu-accent .fa {
	margin-right: 4px;
}

#menu .dropdown-menu {
	min-width: 260px;
	margin: 0;
	padding: 10px 8px 0;
	background: #fff;
	border: 0;
	border-radius: 0 0 14px 14px;
	box-shadow: 0 18px 40px rgba(29,35,113,.18);
}
#menu .dropdown-inner a {
	min-width: 220px;
	padding: 8px 14px;
	font-size: 14px;
	line-height: 1.3;
	color: #3a3f55;
	border-radius: 8px;
}
#menu .dropdown-inner li a:hover,
#menu .dropdown-menu ul li a:hover {
	color: #1d2371;
	background: #f4f6fb;
	background-image: none;
}
#menu .see-all,
#menu .see-all:focus {
	display: block;
	margin: 8px -8px 0;
	padding: 12px 22px;
	font-size: 13px;
	font-weight: 600;
	color: #e8322b;
	background: none;
	border-top: 1px solid #e3e6ef;
	border-radius: 0 0 14px 14px;
}
#menu .see-all:hover {
	color: #c9241e;
	background: #f4f6fb;
	background-image: none;
	text-decoration: none;
}
#menu .see-all .fa {
	margin-left: 4px;
}

@media (min-width: 768px) {
	#menu .navbar-nav {
		display: flex;
		float: none;
		width: 100%;
	}
	#menu .navbar-nav:before,
	#menu .navbar-nav:after {
		content: none;
	}
	#menu .navbar-nav > li {
		flex: 0 0 auto;
	}
	#menu .nav > li > a {
		white-space: nowrap;
	}
	#menu .hdr-menu-accent {
		margin-left: auto;
	}
}

/* ---------- Планшеты ---------- */
@media (max-width: 1199px) {
	.hdr-main {
		gap: 18px;
	}
	.hdr-top-info li.hdr-top-wide:last-child {
		display: none;
	}
	#menu .nav > li > a {
		padding: 15px 8px;
		font-size: 13px;
	}
	#menu .hdr-caret {
		display: none;
	}
	#menu .nav > li.hdr-menu-accent > a {
		padding: 7px 12px;
	}
	header #cart > .btn {
		padding: 0 14px 0 12px;
	}
}
@media (max-width: 991px) {
	.hdr-contacts,
	.hdr-top-info li.hdr-top-wide {
		display: none;
	}
	.hdr-top-phone {
		display: list-item;
	}
	.hdr-main #logo img {
		max-height: 36px;
	}
	#menu .navbar-nav {
		flex-wrap: wrap;
	}
	#menu .nav > li > a {
		padding: 12px 9px;
	}
	#menu .nav > li.hdr-menu-accent > a {
		margin: 6px 0 6px 8px;
		padding: 6px 12px;
	}
}

/* ---------- Телефоны ---------- */
@media (max-width: 767px) {
	#top .hdr-top-links li.hdr-top-wide {
		display: none;
	}
	.hdr-top-phone a {
		font-weight: 700;
	}
	.hdr-main {
		flex-wrap: wrap;
		gap: 12px;
		padding-top: 12px;
		padding-bottom: 12px;
	}
	.hdr-main #logo {
		flex: 1 1 0;
		min-width: 0;
	}
	.hdr-main #logo img {
		max-width: 100%;
		max-height: 34px;
		height: auto;
	}
	.hdr-search {
		order: 3;
		flex-basis: 100%;
	}
	header #search .form-control,
	header #search .btn {
		height: 42px;
	}
	.hdr-icon {
		min-width: 46px;
		height: 42px;
		padding: 0;
	}
	.hdr-icon-label {
		display: none;
	}
	header #cart > .btn,
	header #cart.open > .btn {
		height: 42px;
		padding: 0 13px;
	}
	header #cart-total {
		display: none;
	}
	#cart[data-count]:after {
		left: 24px;
	}
	/* Под кнопкой корзины, во всю ширину экрана минус поля (кнопка стоит у правого края) */
	header #cart .dropdown-menu,
	header #cart .dropdown-menu.hc {
		position: absolute;
		top: 100%;
		left: auto;
		right: 0;
		min-width: 0;
		width: calc(100vw - 30px);
	}
	header #cart .hc-items {
		max-height: 45vh;
	}

	.hdr-nav {
		margin-bottom: 16px;
	}
	#menu .navbar-header {
		float: none;
		margin: 0;
	}
	#menu .btn-navbar,
	#menu .btn-navbar:hover,
	#menu .btn-navbar:focus {
		float: none;
		display: block;
		width: 100%;
		margin: 0;
		padding: 13px 0;
		font-size: 15px;
		font-weight: 600;
		text-align: left;
		color: #fff;
		background: none;
		background-image: none;
		border: 0;
		border-radius: 0;
		box-shadow: none;
	}
	#menu .btn-navbar .fa {
		margin-right: 8px;
	}
	#menu .navbar-collapse {
		margin: 0 -15px;
		border-top: 1px solid rgba(255,255,255,.12);
		box-shadow: none;
	}
	#menu .navbar-nav {
		margin: 0;
	}
	#menu .nav > li > a {
		padding: 12px 15px;
		font-size: 14px;
	}
	#menu .hdr-caret {
		display: inline-block;
		float: right;
		margin-top: 2px;
	}
	#menu .nav > li.hdr-menu-accent > a {
		margin: 8px 15px 12px;
		padding: 10px 15px;
		text-align: center;
	}
	#menu div.dropdown-menu {
		padding: 0 0 6px;
		background: rgba(0,0,0,.15);
		border-radius: 0;
		box-shadow: none;
	}
	#menu .dropdown-inner a {
		padding: 9px 15px 9px 28px;
		color: rgba(255,255,255,.85);
		border-radius: 0;
	}
	#menu .dropdown-inner li a:hover,
	#menu .dropdown-menu ul li a:hover {
		color: #fff;
		background: rgba(255,255,255,.08);
	}
	#menu .see-all,
	#menu .see-all:focus {
		margin: 0;
		padding: 9px 15px 9px 28px;
		color: #ff8a84;
		border: 0;
		border-radius: 0;
	}
	#menu .see-all:hover {
		color: #fff;
		background: rgba(255,255,255,.08);
	}
}

/* ---------- Хлебные крошки (весь сайт, все шаблоны с ul.breadcrumb) ---------- */
.breadcrumb {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 0;
	margin: 0 0 20px;
	padding: 0;
	font-size: 13px;
	line-height: 1.4;
	background: none;
	border: 0;
	border-radius: 0;
}
.breadcrumb:before,
.breadcrumb:after {
	content: none;
}
.breadcrumb > li {
	display: inline-flex;
	align-items: center;
	min-width: 0;
	padding: 0;
	white-space: nowrap;
	text-shadow: none;
}
.breadcrumb > li:after {
	content: none;
	display: none;
}
.breadcrumb > li + li:before {
	content: "\f105";
	padding: 0 10px;
	font-family: FontAwesome;
	font-size: 13px;
	color: #b4b8c8;
}
.breadcrumb > li > a {
	color: #7a7f95;
	transition: color .15s;
}
.breadcrumb > li > a:hover {
	color: #e8322b;
	text-decoration: none;
}
.breadcrumb .fa-home {
	font-size: 15px;
	color: #1d2371;
}
.breadcrumb > li > a:hover .fa-home {
	color: #e8322b;
}
/* Последняя крошка — текущая страница: обычный текст, не ссылка */
.breadcrumb > li:last-child:not(:first-child) {
	flex: 1 1 0;
	align-items: flex-start;
	min-width: 160px;
	white-space: normal;
}
.breadcrumb > li:last-child:not(:first-child) > a {
	font-weight: 600;
	color: #1d2371;
	pointer-events: none;
	cursor: default;
}
@media (max-width: 767px) {
	.breadcrumb {
		margin-bottom: 14px;
		font-size: 12px;
	}
	.breadcrumb > li + li:before {
		padding: 0 8px;
	}
	.breadcrumb > li:last-child:not(:first-child) > a {
		display: -webkit-box;
		-webkit-line-clamp: 2;
		-webkit-box-orient: vertical;
		overflow: hidden;
	}
}
