/* Responsive overrides for the eshop_table storefront template. */

html {
	box-sizing: border-box;
}

*, *:before, *:after {
	box-sizing: inherit;
}

img,
object,
embed,
iframe {
	max-width: 100%;
}

img {
	height: auto;
}

@media (max-width: 1220px) {
	.wrapper {
		background-size: 1220px auto;
	}

	.pagecenter,
	.banners_on_top {
		width: 100%;
	}

	.banners_on_top {
		display: grid;
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 8px;
		margin: 8px;
		width: auto;
	}

	.banners_on_top .banner {
		float: none;
		margin: 0;
	}

	.banners_on_top .banner img {
		display: block;
		height: auto;
		width: 100%;
	}

	.header_top,
	.footer_top {
		margin-left: 0;
		width: 100%;
	}

	.logo_link {
		left: 50%;
		margin-left: -189px;
	}
}

@media (max-width: 767px) {
	body {
		min-width: 0;
	}

	.wrapper {
		background: #f1f1f1;
		width: 100%;
	}

	.wrapper > tbody > tr:first-child > td:first-child,
	.wrapper > tbody > tr:first-child > td:nth-child(2),
	.wrapper > tbody > tr:first-child > td:nth-child(4),
	.wrapper > tbody > tr:first-child > td:nth-child(5),
	.shadow_left,
	.shadow_right {
		display: none;
	}

	.wrapper > tbody > tr > td {
		display: block;
		width: 100% !important;
		height: auto !important;
	}

	.header_top .header_top_left,
	.header_top .header_top_right,
	.header_top .header_top_center,
	.header_bottom_left,
	.header_bottom_right,
	.main_menu_left,
	.main_menu_right,
	.main_menu_center,
	.footer_top .footer_top_left,
	.footer_top .footer_top_right,
	.footer_top .footer_top_center {
		background-image: none;
		height: auto;
		padding: 0;
	}

	.header_top {
		background: #27344f;
		font-family: Verdana, Arial, sans-serif;
		font-size: 16px;
	}

	.header_top table,
	.header_top tbody,
	.header_top tr,
	.header_top td {
		display: block;
		width: 100% !important;
		height: auto !important;
	}

	.header_top .slogan,
	.header_top .free_delivery,
	.header_top .phone,
	.header_top .email {
		padding: 8px 14px;
		text-align: center;
	}

	.header_top .slogan {
		font-size: 18px;
	}

	.header_top .free_delivery {
		font-size: 16px;
	}

	.logo_link {
		display: block;
		height: 64px;
		left: auto;
		margin: 10px auto;
		position: relative;
		width: 100%;
		max-width: 378px;
	}

	.header_bottom {
		background: #fac04e;
		font-size: 20px;
		line-height: 1.25;
		margin-top: 0;
		padding: 8px 12px;
	}

	.banners_on_top {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}

	.main_menu {
		margin-top: 0;
	}

	.main_menu_center {
		background: #27344f;
		padding: 8px;
	}

	.main_menu table,
	.main_menu tbody,
	.main_menu tr,
	.main_menu td {
		display: block;
		width: 100% !important;
		height: auto !important;
	}

	.main_menu .menu {
		display: flex;
		flex-wrap: wrap;
		gap: 6px;
		justify-content: center;
	}

	.main_menu .menu td:empty,
	.main_menu .menu td[width="160"] {
		display: none;
	}

	.main_menu .menu a {
		display: block;
		padding: 8px 10px;
	}

	.pagecenter > table,
	.pagecenter > table > tbody,
	.pagecenter > table > tbody > tr,
	.pagecenter > table > tbody > tr > td {
		display: block;
		width: 100% !important;
	}

	.pagecenter > table > tbody > tr {
		display: flex;
		flex-direction: column;
	}

	.pagecenter > table > tbody > tr > td:nth-child(2) {
		order: 1;
	}

	.pagecenter > table > tbody > tr > td:first-child {
		order: 2;
	}

	.pagecenter > table > tbody > tr > td:nth-child(3) {
		order: 3;
	}

	.pagecenter > table table {
		width: 100% !important;
	}

	.main_center {
		margin: 10px;
	}

	.box,
	.box2 {
		width: 100%;
	}
}

@media (max-width: 480px) {
	.header_top .slogan {
		font-size: 16px;
	}

	.header_bottom {
		font-size: 18px;
	}

	.banners_on_top {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}

	.main_menu .menu {
		display: block;
	}

	.main_menu .menu a {
		text-align: center;
	}
}
