/* YourService — header/footer branding overrides for Avada */

body.ys-branded-site {
	scroll-padding-top: 96px;
}

body.ys-branded-site.admin-bar {
	scroll-padding-top: 128px;
}

body.ys-branded-site .fusion-tb-footer,
body.ys-branded-site .fusion-footer-widget-area,
body.ys-branded-site .fusion-footer-copyright-area,
body.ys-branded-site .fusion-footer-parallax,
body.ys-branded-site .avada-footer-scripts,
body.ys-branded-site .fusion-footer {
	display: none !important;
}

body.ys-branded-site .fusion-tb-header {
	position: sticky !important;
	top: 0 !important;
	z-index: 10050 !important;
	background: #ffffff !important;
	box-shadow: 0 8px 24px rgba(10, 10, 10, 0.06) !important;
	border-bottom: 1px solid rgba(0, 0, 0, 0.06) !important;
	min-height: 80px !important;
}

body.ys-branded-site.admin-bar .fusion-tb-header {
	top: 32px !important;
}

body.ys-branded-site .fusion-tb-header .fusion-fullwidth,
body.ys-branded-site .fusion-tb-header .fusion-builder-row-1,
body.ys-branded-site .fusion-tb-header .fusion-builder-row-2,
body.ys-branded-site .fusion-tb-header .fusion-builder-row-3 {
	background: #ffffff !important;
	--awb-sticky-background-color: #ffffff !important;
	min-height: 80px !important;
	--awb-min-height: 80px !important;
	--awb-sticky-height: 80px !important;
	position: relative !important;
	top: auto !important;
	width: 100% !important;
}

/* Avada Layout: absolute header toglie spazio al contenuto sottostante */
body.ys-branded-site .fusion-tb-header .fusion-absolute-container,
body.ys-branded-site .fusion-tb-header .fusion-absolute-position-large,
body.ys-branded-site .fusion-tb-header .fusion-absolute-position-medium,
body.ys-branded-site .fusion-tb-header .fusion-absolute-position-small {
	position: relative !important;
	top: auto !important;
	width: 100% !important;
}

body.ys-branded-site .fusion-tb-header .fusion-builder-row {
	align-items: center !important;
	min-height: 80px !important;
}

body.ys-branded-site .fusion-tb-header .fusion-layout-column {
	margin-bottom: 0 !important;
	--awb-margin-bottom-large: 0px !important;
	--awb-margin-bottom-medium: 0px !important;
	--awb-margin-bottom-small: 0px !important;
}

body.ys-branded-site .fusion-tb-header .fusion-column-wrapper {
	justify-content: center !important;
}

/* Menu Avada disattivato: usiamo navigazione custom */
body.ys-branded-site .fusion-tb-header .awb-menu,
body.ys-branded-site .fusion-tb-header .awb-menu__flyout-close,
body.ys-branded-site .fusion-tb-header .awb-menu__open-nav-submenu_mobile,
body.ys-branded-site .fusion-tb-header .awb-menu__open-nav-submenu_click {
	display: none !important;
	height: 0 !important;
	min-height: 0 !important;
	overflow: hidden !important;
	visibility: hidden !important;
	margin: 0 !important;
	padding: 0 !important;
}

body.ys-branded-site .ys-desktop-nav,
body.ys-branded-site .ys-mobile-nav {
	display: none;
}

/* Desktop: menu custom nell'header */
@media (min-width: 1101px) {
	body.ys-branded-site .ys-mobile-nav {
		display: none !important;
	}

	body.ys-branded-site .fusion-tb-header .fusion_builder_column_3_4 .fusion-column-wrapper,
	body.ys-branded-site .fusion-tb-header .fusion-builder-column-1 .fusion-column-wrapper,
	body.ys-branded-site .fusion-tb-header .fusion-builder-column-2 .fusion-column-wrapper {
		display: flex !important;
		align-items: center !important;
		justify-content: flex-end !important;
		min-height: 80px !important;
		overflow: visible !important;
	}

	body.ys-branded-site .ys-desktop-nav {
		display: flex !important;
		align-items: center !important;
		justify-content: flex-end !important;
		width: 100% !important;
	}

	body.ys-branded-site .ys-desktop-nav__list {
		display: flex !important;
		align-items: center !important;
		justify-content: flex-end !important;
		flex-wrap: nowrap !important;
		gap: 2px !important;
		list-style: none !important;
		margin: 0 !important;
		padding: 0 !important;
	}

	body.ys-branded-site .ys-desktop-nav__list > li {
		position: relative !important;
	}

	body.ys-branded-site .ys-desktop-nav__list > li > a {
		display: inline-flex !important;
		align-items: center !important;
		padding: 10px 14px !important;
		color: #1a1a1a !important;
		font-size: 0.95rem !important;
		font-weight: 600 !important;
		text-decoration: none !important;
		white-space: nowrap !important;
		border-radius: 10px !important;
	}

	body.ys-branded-site .ys-desktop-nav__item--has-children > a::after {
		content: "▾";
		margin-left: 4px;
		font-size: 0.75em;
		opacity: 0.7;
	}

	body.ys-branded-site .ys-desktop-nav__list > li > a:hover,
	body.ys-branded-site .ys-desktop-nav__item--open > a {
		color: #ff9f40 !important;
	}

	body.ys-branded-site .ys-desktop-nav__sub {
		display: none;
		position: absolute;
		top: calc(100% + 6px);
		left: 0;
		min-width: 220px;
		margin: 0;
		padding: 8px 0;
		list-style: none;
		background: #ffffff;
		border: 1px solid rgba(0, 0, 0, 0.08);
		border-radius: 12px;
		box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
		z-index: 10070;
	}

	body.ys-branded-site .ys-desktop-nav__item--has-children:hover > .ys-desktop-nav__sub,
	body.ys-branded-site .ys-desktop-nav__item--open > .ys-desktop-nav__sub {
		display: block;
	}

	body.ys-branded-site .ys-desktop-nav__sub a {
		display: block;
		padding: 10px 16px;
		color: #1a1a1a;
		font-size: 0.92rem;
		font-weight: 600;
		text-decoration: none;
	}

	body.ys-branded-site .ys-desktop-nav__sub a:hover {
		background: #fff7e6;
		color: #ff9f40;
	}
}

body.ys-branded-site .fusion-tb-header .fusion-main-menu-cart,
body.ys-branded-site .fusion-tb-header .menu-item-1218,
body.ys-branded-site .fusion-tb-header .fusion-menu-cart {
	display: none !important;
}

body.ys-branded-site .fusion-logo img,
body.ys-branded-site .fusion-tb-header .fusion-empty-dims-img-placeholder,
body.ys-branded-site .fusion-tb-header .fusion-column-inner-bg-image {
	max-height: 52px !important;
	width: auto !important;
}

body.ys-branded-site .fusion-tb-header .fusion_builder_column_1_5 {
	--awb-width-large: 22% !important;
}

body.ys-branded-site .fusion-tb-header .fusion_builder_column_3_4 {
	--awb-width-large: 78% !important;
}

body.ys-branded-site #main,
body.ys-branded-site #content {
	padding-top: 24px !important;
}

body.ys-branded-site.home #main {
	padding-top: 0 !important;
}

body.ys-branded-site .fusion-page-title-bar,
body.ys-branded-site.home h1.entry-title {
	display: none !important;
}

body.ys-branded-site .fusion-header-wrapper .fusion-secondary-menu,
body.ys-branded-site .fusion-header-wrapper .fusion-secondary-header {
	display: none !important;
}

/* Custom footer */
.ys-site-footer {
	background: linear-gradient(180deg, #141414, #0d0d0d);
	color: #f2f2f2;
	padding: 36px 16px 28px;
	margin-top: 48px;
}
.ys-site-footer-inner {
	max-width: 1100px;
	margin: 0 auto;
	display: grid;
	gap: 18px;
}
.ys-footer-brand strong {
	font-size: 1.35rem;
	color: #fff;
	letter-spacing: 0.3px;
}
.ys-footer-brand p {
	margin: 8px 0 0;
	color: rgba(255, 255, 255, 0.72);
	max-width: 420px;
}
.ys-footer-links {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 18px;
}
.ys-footer-links a {
	color: #ff9f40 !important;
	text-decoration: none;
	font-weight: 600;
}
.ys-footer-links a:hover {
	color: #ffc878 !important;
}
.ys-footer-copy {
	margin: 8px 0 0;
	font-size: 0.85rem;
	color: rgba(255, 255, 255, 0.55);
}

/* Hero */
body.ys-branded-site .ys-home-wrap {
	margin-top: -12px;
}

.ys-home-hero-banner {
	position: relative;
	border-radius: 0 0 24px 24px;
	overflow: hidden;
	min-height: 460px;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 88px 20px 72px;
	margin: 0 calc(50% - 50vw) 20px;
	width: 100vw;
	max-width: 100vw;
	background-size: cover;
	background-position: center;
	color: #fff;
}
.ys-home-hero-banner::before {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(8, 8, 10, 0.55), rgba(8, 8, 10, 0.72));
}
.ys-home-hero-content {
	position: relative;
	z-index: 1;
	max-width: 760px;
}
.ys-home-hero-content h1 {
	margin: 0 0 14px;
	font-size: clamp(2rem, 5vw, 3rem);
	line-height: 1.1;
	font-weight: 800;
}
.ys-home-hero-content p {
	margin: 0 auto 26px;
	font-size: 1.1rem;
	line-height: 1.55;
	color: rgba(255, 255, 255, 0.92);
	max-width: 620px;
}
.ys-home-hero-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	justify-content: center;
}
.ys-btn-primary,
.ys-btn-secondary {
	display: inline-block;
	padding: 13px 22px;
	border-radius: 12px;
	text-decoration: none;
	font-weight: 700;
}
.ys-btn-primary {
	background: #ff9f40;
	color: #111 !important;
}
.ys-btn-secondary {
	background: rgba(255, 255, 255, 0.14);
	color: #fff !important;
	border: 1px solid rgba(255, 255, 255, 0.35);
}

.ys-cat-card-media {
	display: block;
	height: 140px;
	border-radius: 12px 12px 0 0;
	margin: -22px -18px 14px;
	background-size: cover;
	background-position: center;
}

/* Icona hamburger menu mobile dedicato */
body.ys-branded-site .ys-hamburger {
	display: block;
	width: 22px;
	height: 2px;
	background: #1a1a1a;
	border-radius: 2px;
	position: relative;
}
body.ys-branded-site .ys-hamburger::before,
body.ys-branded-site .ys-hamburger::after {
	content: "";
	position: absolute;
	left: 0;
	width: 22px;
	height: 2px;
	background: #1a1a1a;
	border-radius: 2px;
}
body.ys-branded-site .ys-hamburger::before {
	top: -7px;
}
body.ys-branded-site .ys-hamburger::after {
	top: 7px;
}

body.ys-branded-site .ys-mobile-nav {
	display: none;
}

/* Menu mobile dedicato — non dipende da Avada */
@media (max-width: 1100px) {
	body.ys-branded-site #wpadminbar {
		display: none !important;
	}
	body.ys-branded-site.admin-bar {
		margin-top: 0 !important;
	}
	body.ys-branded-site.admin-bar .fusion-tb-header {
		top: 0 !important;
	}

	body.ys-branded-site .fusion-tb-header .fusion-builder-column-0 {
		--awb-width-small: 70% !important;
	}
	body.ys-branded-site .fusion-tb-header .fusion-builder-column-1 {
		--awb-width-small: 30% !important;
	}

	body.ys-branded-site .fusion-tb-header .fusion-main-menu-cart,
	body.ys-branded-site .fusion-tb-header .fusion-menu-cart,
	body.ys-branded-site .fusion-tb-header .fusion-secondary-menu {
		display: none !important;
	}

	body.ys-branded-site .ys-mobile-nav {
		display: block;
		position: fixed;
		top: 10px;
		right: 14px;
		z-index: 100080;
	}

	body.ys-branded-site .ys-mobile-nav__toggle {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 44px;
		height: 44px;
		padding: 0;
		border: none;
		border-radius: 12px;
		background: #ffffff;
		box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
		cursor: pointer;
	}

	body.ys-branded-site .ys-mobile-nav__panel {
		position: absolute;
		top: calc(100% + 8px);
		right: 0;
		width: min(320px, 92vw);
		background: #ffffff;
		border-radius: 16px;
		box-shadow: 0 16px 40px rgba(0, 0, 0, 0.14);
		padding: 10px 0;
	}

	body.ys-branded-site .ys-mobile-nav__list,
	body.ys-branded-site .ys-mobile-nav__sub {
		list-style: none;
		margin: 0;
		padding: 0;
	}

	body.ys-branded-site .ys-mobile-nav__item > a,
	body.ys-branded-site .ys-mobile-nav__sub-toggle {
		display: flex;
		align-items: center;
		justify-content: space-between;
		width: 100%;
		padding: 14px 20px;
		color: #1a1a1a;
		font-size: 1rem;
		font-weight: 600;
		text-decoration: none;
		background: transparent;
		border: none;
		cursor: pointer;
		text-align: left;
	}

	body.ys-branded-site .ys-mobile-nav__item > a:hover,
	body.ys-branded-site .ys-mobile-nav__sub-toggle:hover,
	body.ys-branded-site .ys-mobile-nav__sub a:hover {
		color: #ff9f40;
	}

	body.ys-branded-site .ys-mobile-nav__caret::after {
		content: "▾";
		font-size: 0.85rem;
		opacity: 0.7;
	}

	body.ys-branded-site .ys-mobile-nav__sub {
		display: none;
		background: #f7f7f7;
	}

	body.ys-branded-site .ys-mobile-nav__item--open > .ys-mobile-nav__sub {
		display: block;
	}

	body.ys-branded-site .ys-mobile-nav__sub a {
		display: block;
		padding: 12px 28px;
		color: #333;
		font-size: 0.95rem;
		font-weight: 600;
		text-decoration: none;
	}
}

@media (max-width: 768px) {
	body.ys-branded-site .fusion-tb-header .fusion-fullwidth,
	body.ys-branded-site .fusion-tb-header .fusion-builder-row-1 {
		min-height: 64px !important;
		--awb-min-height: 64px !important;
	}
	body.ys-branded-site .fusion-logo img,
	body.ys-branded-site .fusion-tb-header .fusion-empty-dims-img-placeholder {
		max-height: 44px !important;
	}
	.ys-home-hero-banner {
		min-height: 360px;
		padding-top: 56px;
		border-radius: 0 0 18px 18px;
	}
	.ys-site-footer-inner {
		text-align: center;
	}
	.ys-footer-links {
		justify-content: center;
	}
}