/* =========================================================================
   GATEFIX — shell theme
   Direzione: strumento tecnico-industriale. Bianco operativo, inchiostro
   freddo, un solo accento: il giallo sicurezza dei bracci dei cancelli.
   Signature: hazard stripe sotto la navigazione.
   ========================================================================= */

:root {
	--gfxt-ink: #14181c;
	--gfxt-steel: #3d4650;
	--gfxt-muted: #6b7683;
	--gfxt-line: #e2e6ea;
	--gfxt-paper: #f5f7f9;
	--gfxt-bg: #ffffff;
	--gfxt-accent: #ffc400;

	--gfxt-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
		"Helvetica Neue", Arial, sans-serif;
	--gfxt-mono: ui-monospace, "SF Mono", "Cascadia Mono", "Roboto Mono",
		Menlo, Consolas, monospace;

	--gfxt-radius: 6px;
	--gfxt-container: 1280px;
	--gfxt-shadow: 0 8px 24px rgba(20, 24, 28, 0.12);
}

/* ---- Reset essenziale ------------------------------------------------- */
*,
*::before,
*::after {
	box-sizing: border-box;
}

body {
	margin: 0;
	font-family: var(--gfxt-font);
	font-size: 16px;
	line-height: 1.55;
	color: var(--gfxt-ink);
	background: var(--gfxt-bg);
	-webkit-font-smoothing: antialiased;
}

img {
	max-width: 100%;
	height: auto;
	display: block;
}

a {
	color: inherit;
	text-decoration-thickness: 1px;
	text-underline-offset: 2px;
}

a:hover {
	text-decoration-color: var(--gfxt-accent);
	text-decoration-thickness: 2px;
}

button {
	font: inherit;
	cursor: pointer;
}

:focus-visible {
	outline: 2px solid var(--gfxt-accent);
	outline-offset: 2px;
	border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		transition: none !important;
		animation: none !important;
	}
}

/* ---- Utility ----------------------------------------------------------- */
.gfxt-container {
	max-width: var(--gfxt-container);
	margin-inline: auto;
	padding-inline: 20px;
}

.gfxt-visually-hidden {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
}

.gfxt-skip {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 999;
	background: var(--gfxt-ink);
	color: #fff;
	padding: 10px 16px;
}

.gfxt-skip:focus {
	left: 0;
}

.gfxt-kicker {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--gfxt-muted);
	margin: 0 0 8px;
}

.gfxt-sku,
.gfxt-mono {
	font-family: var(--gfxt-mono);
	font-size: 0.9em;
	letter-spacing: 0.01em;
}

/* ---- Header ------------------------------------------------------------ */
.gfxt-header {
	background: var(--gfxt-bg);
	border-bottom: 1px solid var(--gfxt-line);
}

.gfxt-header__bar {
	display: grid;
	grid-template-columns: auto auto 1fr auto;
	align-items: center;
	gap: 24px;
	padding-block: 14px;
}

.gfxt-logo .custom-logo {
	max-height: 48px;
	width: auto;
}

.gfxt-logo__text {
	font-size: 24px;
	font-weight: 800;
	letter-spacing: -0.02em;
	text-decoration: none;
}

/* Search — lo strumento principale, sempre in vista */
.gfxt-search {
	position: relative;
	max-width: 640px;
	width: 100%;
	justify-self: center;
}

.gfxt-searchform {
	display: flex;
	border: 2px solid var(--gfxt-ink);
	border-radius: var(--gfxt-radius);
	overflow: hidden;
	background: var(--gfxt-bg);
}

.gfxt-searchform__input {
	flex: 1;
	min-width: 0;
	border: 0;
	padding: 10px 14px;
	font: inherit;
	font-size: 15px;
}

.gfxt-searchform__input:focus {
	outline: none;
}

.gfxt-searchform:focus-within {
	box-shadow: 0 0 0 3px rgba(255, 196, 0, 0.35);
}

.gfxt-searchform__btn {
	border: 0;
	background: var(--gfxt-ink);
	color: #fff;
	padding-inline: 16px;
	display: grid;
	place-items: center;
}

.gfxt-searchform__btn:hover {
	background: var(--gfxt-steel);
}

/* Risultati autocomplete */
.gfxt-search__results {
	position: absolute;
	top: calc(100% + 6px);
	left: 0;
	right: 0;
	background: var(--gfxt-bg);
	border: 1px solid var(--gfxt-line);
	border-radius: var(--gfxt-radius);
	box-shadow: var(--gfxt-shadow);
	z-index: 60;
	max-height: 70vh;
	overflow: auto;
}

.gfxt-sr {
	display: grid;
	grid-template-columns: 44px 1fr auto;
	gap: 12px;
	align-items: center;
	padding: 10px 12px;
	text-decoration: none;
	border-bottom: 1px solid var(--gfxt-line);
}

.gfxt-sr:last-child {
	border-bottom: 0;
}

.gfxt-sr:hover,
.gfxt-sr[aria-selected="true"] {
	background: var(--gfxt-paper);
}

.gfxt-sr__img {
	width: 44px;
	height: 44px;
	object-fit: contain;
	background: var(--gfxt-paper);
	border-radius: 4px;
}

.gfxt-sr__title {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.3;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.gfxt-sr__sku {
	font-family: var(--gfxt-mono);
	font-size: 12px;
	color: var(--gfxt-muted);
}

.gfxt-sr__price {
	font-weight: 700;
	font-size: 14px;
	white-space: nowrap;
}

.gfxt-sr--empty {
	padding: 14px;
	font-size: 14px;
	color: var(--gfxt-muted);
}

/* Azioni header */
.gfxt-actions {
	display: flex;
	align-items: center;
	gap: 20px;
}

.gfxt-actions__item {
	display: grid;
	justify-items: center;
	gap: 2px;
	text-decoration: none;
	color: var(--gfxt-ink);
	position: relative;
}

.gfxt-actions__label {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--gfxt-steel);
}

.gfxt-actions__phone .gfxt-actions__label {
	text-transform: none;
	font-size: 13px;
	letter-spacing: 0;
}

.gfxt-cart__badge {
	position: absolute;
	top: -6px;
	right: 6px;
	min-width: 18px;
	height: 18px;
	padding-inline: 4px;
	border-radius: 9px;
	background: var(--gfxt-accent);
	color: var(--gfxt-ink);
	font-size: 11px;
	font-weight: 800;
	display: grid;
	place-items: center;
	line-height: 1;
}

/* ---- Nav + hazard stripe (signature) ----------------------------------- */
.gfxt-burger {
	display: none;
	border: 0;
	background: none;
	color: var(--gfxt-ink);
	padding: 6px;
}

.gfxt-nav {
	background: var(--gfxt-ink);
	position: relative;
}

/* La striscia di sicurezza dei bracci dei cancelli automatici */
.gfxt-nav::after {
	content: "";
	display: block;
	height: 5px;
	background: repeating-linear-gradient(
		-45deg,
		var(--gfxt-accent) 0 14px,
		var(--gfxt-ink) 14px 28px
	);
}

.gfxt-nav__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
}

.gfxt-nav__list a {
	display: block;
	padding: 12px 16px;
	color: #fff;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-decoration: none;
	white-space: nowrap;
}

.gfxt-nav__list > li:first-child > a {
	padding-left: 0;
}

.gfxt-nav__list a:hover {
	color: var(--gfxt-accent);
}

/* Dropdown desktop */
.gfxt-nav__list li {
	position: relative;
}

.gfxt-nav__list ul {
	list-style: none;
	margin: 0;
	padding: 6px 0;
	position: absolute;
	top: 100%;
	left: 0;
	min-width: 230px;
	background: var(--gfxt-bg);
	border: 1px solid var(--gfxt-line);
	border-radius: 0 0 var(--gfxt-radius) var(--gfxt-radius);
	box-shadow: var(--gfxt-shadow);
	z-index: 70;
	display: none;
}

.gfxt-nav__list ul a {
	color: var(--gfxt-ink);
	font-weight: 500;
	padding: 9px 16px;
}

.gfxt-nav__list ul a:hover {
	background: var(--gfxt-paper);
	color: var(--gfxt-ink);
}

.gfxt-nav__list ul ul {
	top: 0;
	left: 100%;
	border-radius: var(--gfxt-radius);
}

@media (min-width: 1025px) {
	.gfxt-nav__list li:hover > ul,
	.gfxt-nav__list li:focus-within > ul {
		display: block;
	}
}

/* ---- Contenuto --------------------------------------------------------- */
.gfxt-main {
	padding-block: 32px 64px;
	min-height: 50vh;
}

.gfxt-page-title {
	font-size: clamp(26px, 4vw, 34px);
	font-weight: 800;
	letter-spacing: -0.02em;
	line-height: 1.15;
	margin: 0 0 20px;
}

.gfxt-prose {
	max-width: 760px;
}

.gfxt-prose h2 {
	font-size: 24px;
	font-weight: 700;
	letter-spacing: -0.01em;
	margin: 32px 0 12px;
}

.gfxt-prose h3 {
	font-size: 19px;
	font-weight: 700;
	margin: 24px 0 10px;
}

.gfxt-prose p,
.gfxt-prose ul,
.gfxt-prose ol {
	margin: 0 0 16px;
	color: var(--gfxt-steel);
}

.gfxt-btn {
	display: inline-block;
	background: var(--gfxt-ink);
	color: #fff;
	font-weight: 700;
	font-size: 15px;
	padding: 12px 22px;
	border: 0;
	border-radius: var(--gfxt-radius);
	text-decoration: none;
	transition: background-color 0.15s ease;
}

.gfxt-btn:hover {
	background: var(--gfxt-steel);
}

.gfxt-404 {
	max-width: 640px;
	text-align: left;
	padding-block: 64px;
}

.gfxt-404__search {
	margin-block: 24px;
}

.gfxt-loop__item {
	padding-block: 20px;
	border-bottom: 1px solid var(--gfxt-line);
}

.gfxt-pagination {
	margin-top: 32px;
}

/* ---- Footer ------------------------------------------------------------ */
.gfxt-footer {
	background: var(--gfxt-paper);
	border-top: 1px solid var(--gfxt-line);
	margin-top: 48px;
}

.gfxt-footer__grid {
	display: grid;
	grid-template-columns: 2fr 1fr 1fr;
	gap: 40px;
	padding-block: 44px;
}

.gfxt-footer__brand {
	font-size: 20px;
	font-weight: 800;
	letter-spacing: -0.02em;
	margin: 0 0 8px;
}

.gfxt-footer__logo img {
	max-height: 40px;
	width: auto;
}

.gfxt-footer__tagline {
	color: var(--gfxt-steel);
	max-width: 380px;
}

.gfxt-footer__about p {
	margin: 0 0 8px;
	font-size: 14px;
}

.gfxt-footer__title {
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--gfxt-muted);
	margin: 0 0 12px;
}

.gfxt-footer__menu {
	list-style: none;
	margin: 0;
	padding: 0;
}

.gfxt-footer__menu a {
	display: inline-block;
	padding-block: 5px;
	font-size: 14px;
	color: var(--gfxt-steel);
	text-decoration: none;
}

.gfxt-footer__menu a:hover {
	color: var(--gfxt-ink);
	text-decoration: underline;
	text-decoration-color: var(--gfxt-accent);
	text-decoration-thickness: 2px;
}

.gfxt-footer__legal {
	background: var(--gfxt-ink);
	color: rgba(255, 255, 255, 0.75);
	font-size: 13px;
}

.gfxt-footer__legal-row {
	padding-block: 14px;
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 8px;
}

/* ---- Mobile ------------------------------------------------------------ */
@media (max-width: 1024px) {
	.gfxt-header__bar {
		grid-template-columns: auto auto 1fr;
		grid-template-areas:
			"burger logo actions"
			"search search search";
		row-gap: 12px;
	}

	.gfxt-burger {
		display: grid;
		place-items: center;
		grid-area: burger;
	}

	.gfxt-logo {
		grid-area: logo;
	}

	.gfxt-search {
		grid-area: search;
		max-width: none;
	}

	.gfxt-actions {
		grid-area: actions;
		justify-self: end;
		gap: 16px;
	}

	.gfxt-actions__label,
	.gfxt-actions__phone {
		display: none;
	}

	/* Drawer */
	.gfxt-nav {
		position: fixed;
		inset: 0 auto 0 0;
		width: min(320px, 85vw);
		transform: translateX(-102%);
		transition: transform 0.22s ease;
		overflow-y: auto;
		z-index: 100;
		padding-top: 8px;
	}

	.gfxt-nav.is-open {
		transform: translateX(0);
	}

	.gfxt-nav::after {
		position: absolute;
		top: 0;
		left: 0;
		right: 0;
	}

	.gfxt-nav__list {
		display: block;
		padding-block: 12px;
	}

	.gfxt-nav__list > li:first-child > a {
		padding-left: 16px;
	}

	.gfxt-nav__list li {
		border-bottom: 1px solid rgba(255, 255, 255, 0.08);
	}

	.gfxt-nav__list a {
		white-space: normal;
		padding: 13px 16px;
	}

	.gfxt-nav__list ul {
		position: static;
		display: none;
		background: none;
		border: 0;
		box-shadow: none;
		padding: 0 0 8px;
	}

	.gfxt-nav__list li.is-open > ul {
		display: block;
	}

	.gfxt-nav__list ul a {
		color: rgba(255, 255, 255, 0.85);
		padding: 9px 16px 9px 28px;
		font-size: 14px;
	}

	.gfxt-nav__list ul a:hover {
		background: rgba(255, 255, 255, 0.06);
		color: #fff;
	}

	.gfxt-nav__list ul ul a {
		padding-left: 42px;
	}

	.gfxt-sub-toggle {
		position: absolute;
		top: 4px;
		right: 8px;
		width: 40px;
		height: 40px;
		border: 0;
		background: none;
		color: #fff;
		display: grid;
		place-items: center;
	}

	.gfxt-sub-toggle::before {
		content: "";
		width: 9px;
		height: 9px;
		border-right: 2px solid currentColor;
		border-bottom: 2px solid currentColor;
		transform: rotate(45deg);
		transition: transform 0.15s ease;
	}

	li.is-open > .gfxt-sub-toggle::before {
		transform: rotate(-135deg);
	}

	.gfxt-scrim {
		position: fixed;
		inset: 0;
		background: rgba(20, 24, 28, 0.5);
		z-index: 90;
		opacity: 0;
		pointer-events: none;
		transition: opacity 0.2s ease;
	}

	body.gfxt-nav-open .gfxt-scrim {
		opacity: 1;
		pointer-events: auto;
	}

	body.gfxt-nav-open {
		overflow: hidden;
	}

	.gfxt-footer__grid {
		grid-template-columns: 1fr;
		gap: 28px;
		padding-block: 32px;
	}
}

@media (max-width: 480px) {
	.gfxt-container {
		padding-inline: 14px;
	}

	.gfxt-main {
		padding-block: 20px 48px;
	}
}
