/* =========================================================
   FC Sidebar — Ferramenta Facchinetti
   Barra fissa sinistra + toggle "a puntini" sul Dialog YOOtheme
   Teknet Srl — 2026-08
   ========================================================= */

:root {
	--fc-sidebar-w: 88px;          /* larghezza da grafica (~88px @1440) */
	--fc-sidebar-bg: #161715;
	--fc-sidebar-line: rgba(255, 255, 255, .08);

	--fc-dot-size: 5px;
	--fc-dot-gap: 6px;
	--fc-dot-color: #fff;

	--fc-accent: #ffc412;          /* giallo campionato dalla grafica */

	--fc-z-sidebar: 1002;          /* > offcanvas UIkit (1000), < modal (1010) */
}

@media (max-width: 959px) {
	:root {
		--fc-sidebar-w: 64px;
		--fc-dot-size: 4px;
		--fc-dot-gap: 5px;
	}
}

/* ---------------------------------------------------------
   1. Spazio per la barra
   --------------------------------------------------------- */

body {
	padding-left: var(--fc-sidebar-w);
}

/* Evita la scrollbar orizzontale con le sezioni full-width del builder,
   che calcolano la larghezza su 100vw ignorando il padding del body. */
html {
	overflow-x: hidden;
}

/* ---------------------------------------------------------
   2. Barra
   --------------------------------------------------------- */

.fc-sidebar {
	position: fixed;
	top: 0;
	bottom: 0;
	left: 0;
	z-index: var(--fc-z-sidebar);
	display: flex;
	flex-direction: column;
	align-items: center;
	width: var(--fc-sidebar-w);
	background: var(--fc-sidebar-bg);
}

/* La barra resta sopra l'overlay del dialog: il pulsante rimane
   cliccabile e richiude il pannello, come nella grafica. */

/* ---------------------------------------------------------
   3. Toggle a puntini
   --------------------------------------------------------- */

.fc-sidebar__toggle {
	margin-top: 12px;
	padding: 12px;
	border: 0;
	background: none;
	line-height: 0;
	border-radius: 4px;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
}

.fc-sidebar__toggle:focus {
	outline: none;
}

.fc-sidebar__toggle:focus-visible {
	outline: 2px solid var(--fc-accent);
	outline-offset: 2px;
}

/* Griglia 3x3 di punti */
.fc-sidebar__dots {
	display: grid;
	grid-template-columns: repeat(3, var(--fc-dot-size));
	grid-auto-rows: var(--fc-dot-size);
	gap: var(--fc-dot-gap);
}

.fc-sidebar__dots i {
	display: block;
	width: var(--fc-dot-size);
	height: var(--fc-dot-size);
	border-radius: 1px;            /* punti quadrati appena stondati, come da grafica */
	background: var(--fc-dot-color);
	transition:
		background-color .25s ease,
		opacity .25s ease,
		transform .25s ease;
	transition-delay: calc(var(--i, 0) * 20ms);   /* stagger diagonale */
}

.fc-sidebar__toggle:hover .fc-sidebar__dots i,
.fc-sidebar__toggle:focus-visible .fc-sidebar__dots i {
	background: var(--fc-accent);
}

/* Stato aperto: i 4 punti mediani spariscono, i 5 rimasti
   (angoli + centro) disegnano una X. Nessun trucco di rotazione. */
.fc-sidebar__toggle.is-open .fc-sidebar__dots i {
	background: var(--fc-accent);
}

.fc-sidebar__toggle.is-open .fc-sidebar__dots i:nth-child(2n) {
	opacity: 0;
	transform: scale(.3);
}

@media (prefers-reduced-motion: reduce) {
	.fc-sidebar__dots i {
		transition: none;
		transition-delay: 0s;
	}
}

/* ---------------------------------------------------------
   4. Toggle nativo YOOtheme
   Resta nel DOM (il JS lo usa come fallback) ma non si vede:
   l'unico comando visibile è il pulsante a puntini.
   Per riavere l'hamburger standard sotto i 960px, limita
   questa regola con @media (min-width: 960px).
   --------------------------------------------------------- */

.uk-navbar-toggle[href^="#tm-dialog"],
a[href^="#tm-dialog"].uk-navbar-toggle {
	display: none;
}

/* ---------------------------------------------------------
   5. Dialog YOOtheme — layout Offcanvas
   Valido se in Theme Settings → Header → Dialog scegli "Offcanvas".
   Con Dropbar o Modal queste regole non si applicano: in quel caso
   basta il padding-left sul contenuto.
   --------------------------------------------------------- */

#tm-dialog .uk-offcanvas-bar,
#tm-dialog-mobile .uk-offcanvas-bar {
	/* il pannello scorre sotto la barra: recupero lo spazio col padding */
	padding-left: calc(var(--fc-sidebar-w) + 40px);
}
.uk-button.uk-button-primary::after {
	content: "";
	display: inline-block;
	width: 13px;
    height: 13px;
	margin-left: 12px;
	vertical-align: middle;
	background-color: currentColor;   /* eredita il colore testo del bottone */
	-webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'><polyline fill='none' stroke='%23000' stroke-width='1.6' points='4 1 10 7 4 13'/></svg>") no-repeat center / contain;
	mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'><polyline fill='none' stroke='%23000' stroke-width='1.6' points='4 1 10 7 4 13'/></svg>") no-repeat center / contain;
	transition: transform .2s ease;
    margin-top: -3px;
}

.uk-button.uk-button-primary:hover::after {
	transform: translateX(3px);
}
.uk-button.uk-button-default::after {
	content: "";
	display: inline-block;
	width: 13px;
	height: 13px;
	margin-left: 12px;
	vertical-align: middle;
	background-color: #ff9f39;       /* arancio, indipendente dal colore testo */
	-webkit-mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'><polyline fill='none' stroke='%23000' stroke-width='1.6' points='4 1 10 7 4 13'/></svg>") no-repeat center / contain;
	mask: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'><polyline fill='none' stroke='%23000' stroke-width='1.6' points='4 1 10 7 4 13'/></svg>") no-repeat center / contain;
	transition: transform .2s ease;
	margin-top: -3px;
}

.uk-button.uk-button-default:hover::after {
	transform: translateX(3px);
}
.puntidiforza .el-meta{
	font-size: 2rem;
    border-radius: 50%;
    border: 1px solid #ff9f39;
    width: 100px;
    display: flex;
    margin: auto;
    height: 100px;
    justify-content: center;
    align-items: center;
	font-size:2rem;
	margin-bottom:40px;
}
@media (max-width: 639px) {
	#tm-dialog .uk-offcanvas-bar,
	#tm-dialog-mobile .uk-offcanvas-bar {
		padding-left: calc(var(--fc-sidebar-w) + 16px);
	}
}

/* ---------------------------------------------------------
   6. Stampa
   --------------------------------------------------------- */

@media print {
	.fc-sidebar {
		display: none;
	}
	body {
		padding-left: 0;
	}
}

/* ===================== fine FC Sidebar ==================== */
