/*
Theme Name: Crazy Web Studio (Divi Child)
Template: Divi
Text Domain: Divi-child
Author: Crazy Web Studio
Author URI: https://www.crazywebstudio.co.th
*/
:root {
	--cws-body-color: #191919;
	--cws-font-family: 'Questrial', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
	--cws-primary-background: #FCF9F8;
	--cws-secondary-background: #DEE7DA;
	--cws-cta-background: #3b4f4c;
	--woocommerce: #3b4f4c;
	--wc-primary: #3b4f4c;
	--wc-secondary: #222;
	--wc-link: #9A9A9A;
}

body {
	font-family: var(--cws-font-family);
	font-weight: normal;
}

/* Fix Divi z-index issues */
.et_builder_inner_content {
	z-index: unset !important;
}

/* Mega Menu */
.dipi-balloon-wrap {
	background-color: var(--cws-primary-background);
}

.mega-menu-row p {
	padding: 0;
}

.mega-menu-row .menu-item a {
	padding-left: 0;
	transition: margin-left 0.3s ease-in-out !important;
}

.mega-menu-row .menu-item a:hover {
	margin-left: .5rem;
}

/* WooCommerce General */
.single-product #main-content .container:before {
	display: none;
}

.single-product #left-area {
	width: 100%;
	padding: 0 !important;
}

.woofc-menu-item-inner-subtotal {
	display: none;
}

.home #cws-section-header-desktop,
.home #cws-section-header-mobile {
	border: 0;
}

.et_pb_menu_1_tb_header.et_pb_menu ul li.menu-item-type-woofc a {
	font-size: 20px;
}

/* Fixing bug slider price */
.wpgb-facet .wpgb-range-facet .wpgb-range-slider div.wpgb-range-progress {
	background-color: var(--wpgb-dark-scheme-1);
}

#gform_submit_button_1 {
	width: 100%;
}

#gform_submit_button_2 {
	width: 100%;
}

#cws-section-header-mobile .et_mobile_menu {
	display: flex;
	flex-direction: row;
	top: 0;
	line-height: 0;
	position: relative;
	border-top: 0;
	box-shadow: none;
	column-gap: 10px;
}

#cws-section-header-mobile .et_mobile_menu li a {
	border-bottom: 0;
	word-wrap: normal;
}

#cws-section-header-mobile .mobile_menu_bar {
	display: none;
}

#cws-section-header-mobile .menu-item-25989419 {
	display: none;
}

.logged-in #cws-section-header-mobile .menu-item-25989419 {
	display: block;
	width: 125px;
}

body.logged-in #cws-section-header-mobile .menu-item-25989415 {
	display: none;
}

.wpgb-facet .wpgb-color-facet .wpgb-color-control {
	box-shadow: none !important;
}

.wpgb-facet .wpgb-color-facet .wpgb-color-control[style="background:#ffffff"],
.wpgb-facet .wpgb-color-facet .wpgb-color-control[style="background:#fff"],
.wpgb-facet .wpgb-color-facet .wpgb-color-control[style="background:white"] {
	border: 1px solid #ccc;
}

body .wpgb-facet .wpgb-facet-title {
	margin-bottom: 12px;
}

#menu-main-menu-desktop>li {
	padding-left: 9px;
	padding-right: 9px;
}

div#et-boc {
	width: 100%;
}

.et-fb-preview--desktop .dipi_balloon {
	display: none;
}

.woofc-area .woofc-suggested .woofc-suggested-product-atc .button {
	line-height: 30px !important;
}

.woofc-area .woofc-suggested .woofc-suggested-product-atc .button:after {
	content: "" !important;
}


@media (max-width: 980px) {

	#cws-mobile-menu #menu-main-menu-mobile>li {
		padding: 6px 0;
		text-align: center;
		margin: 0 !important;
	}

	#cws-mobile-menu #menu-main-menu-mobile .cws-menu-row {
		display: flex;
		justify-content: center;
		align-items: center;
		gap: 5px;
		width: 100%;
		padding-left: 50px;
		box-sizing: border-box;
		font-size: 20px;
	}

	#cws-mobile-menu .cws-menu-row>a {
		display: inline-block;
		text-align: center;
	}

	#cws-mobile-menu .cws-sub-toggle {
		width: 30px;
		height: 30px;
		background: transparent;
		border: none;
		cursor: pointer;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		padding: 0;
		flex: 0 0 50px;
	}

	#cws-mobile-menu .cws-sub-toggle:after {
		content: "▾";
		color: #fff;
		font-size: 30px;
		line-height: 1;
		transition: transform .2s ease;
	}

	#cws-mobile-menu li.cws-open>.cws-menu-row>.cws-sub-toggle:after {
		transform: rotate(180deg);
	}

	#cws-mobile-menu .sub-menu {
		display: none;
		max-height: 0;
		overflow: hidden;
		opacity: 0;
		transform: translateY(-6px);
		transition: max-height .35s ease, opacity .25s ease, transform .25s ease;
		text-align: center;
		margin: 0;
		padding: 0;
		pointer-events: none;
	}

	#cws-mobile-menu li.cws-open>.sub-menu {
		display: block;
		opacity: 1;
		transform: translateY(0);
		margin-top: 4px;
		margin-bottom: 2px;
		pointer-events: auto;
	}

	#cws-mobile-menu .sub-menu li {
		padding: 4px 0;
	}

	#cws-mobile-menu .sub-menu a {
		display: block;
		text-align: center;
	}

	#cws-mobile-menu #menu-main-menu-mobile>li.mobile-menu-cta {
		width: 100% !important;
		display: flex;
		justify-content: center;
		align-items: center;
		padding: 12px 0;
	}

	#cws-mobile-menu #menu-main-menu-mobile>li.mobile-menu-cta>a {
		display: inline-block;
		margin: 0 auto;
	}
}