.widget-space {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  width: 100%;
  gap: 10px;
  align-items: center;
}

/* Footer / offcanvas-right → widget impilati in colonna */
.footer-col.widget-space,
.offcanvas-right.widget-space {
  flex-direction: column;
  align-items: flex-start;
}

/* In column direction l'allineamento orizzontale usa align-items, non justify-content */
.footer-col.widget-space.align-mobile-left,
.offcanvas-right.widget-space.align-mobile-left   { align-items: flex-start; }
.footer-col.widget-space.align-mobile-center,
.offcanvas-right.widget-space.align-mobile-center { align-items: center; }
.footer-col.widget-space.align-mobile-right,
.offcanvas-right.widget-space.align-mobile-right  { align-items: flex-end; }

.is-tablet .footer-col.widget-space[class*="align-tablet-"],
.is-tablet .offcanvas-right.widget-space[class*="align-tablet-"],
.is-desktop .footer-col.widget-space[class*="align-tablet-"],
.is-desktop .offcanvas-right.widget-space[class*="align-tablet-"] {
  align-items: initial;
}
.is-tablet .footer-col.widget-space.align-tablet-left,
.is-tablet .offcanvas-right.widget-space.align-tablet-left,
.is-desktop .footer-col.widget-space.align-tablet-left,
.is-desktop .offcanvas-right.widget-space.align-tablet-left  { align-items: flex-start; }
.is-tablet .footer-col.widget-space.align-tablet-center,
.is-tablet .offcanvas-right.widget-space.align-tablet-center,
.is-desktop .footer-col.widget-space.align-tablet-center,
.is-desktop .offcanvas-right.widget-space.align-tablet-center { align-items: center; }
.is-tablet .footer-col.widget-space.align-tablet-right,
.is-tablet .offcanvas-right.widget-space.align-tablet-right,
.is-desktop .footer-col.widget-space.align-tablet-right,
.is-desktop .offcanvas-right.widget-space.align-tablet-right  { align-items: flex-end; }

.is-desktop .footer-col.widget-space[class*="align-desktop-"],
.is-desktop .offcanvas-right.widget-space[class*="align-desktop-"] { align-items: initial; }
.is-desktop .footer-col.widget-space.align-desktop-left,
.is-desktop .offcanvas-right.widget-space.align-desktop-left  { align-items: flex-start; }
.is-desktop .footer-col.widget-space.align-desktop-center,
.is-desktop .offcanvas-right.widget-space.align-desktop-center { align-items: center; }
.is-desktop .footer-col.widget-space.align-desktop-right,
.is-desktop .offcanvas-right.widget-space.align-desktop-right { align-items: flex-end; }

.widget-space.align-mobile-left   { justify-content: flex-start; }
.widget-space.align-mobile-center { justify-content: center; }
.widget-space.align-mobile-right  { justify-content: flex-end; }

.is-tablet .widget-space[class*="align-tablet-"],
.is-desktop .widget-space[class*="align-tablet-"] {
  justify-content: initial;
}

.is-tablet .widget-space.align-tablet-left,
.is-desktop .widget-space.align-tablet-left {
  justify-content: flex-start;
}

.is-tablet .widget-space.align-tablet-center,
.is-desktop .widget-space.align-tablet-center {
  justify-content: center;
}

.is-tablet .widget-space.align-tablet-right,
.is-desktop .widget-space.align-tablet-right {
  justify-content: flex-end;
}

.is-desktop .widget-space[class*="align-desktop-"] {
  justify-content: initial;
}

.is-desktop .widget-space.align-desktop-left   { justify-content: flex-start; }
.is-desktop .widget-space.align-desktop-center { justify-content: center; }
.is-desktop .widget-space.align-desktop-right  { justify-content: flex-end; }


/* =====================================================
   WIDGET SOCIAL ICONS
===================================================== */

.widget-social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--si-size);
  height: var(--si-size);
  background: var(--si-bg);
  color: var(--si-color);
  text-decoration: none;
  flex-shrink: 0;
  transition: background 0.2s ease, color 0.2s ease;
}

.social-icon i {
  font-size: calc(var(--si-size) * 0.55);
  line-height: 1;
}

/* Tonda */
.widget-social-icons--round .social-icon {
  border-radius: 50%;
}

.widget-social-icons--round .social-icon:hover,
.widget-social-icons--square .social-icon:hover {
  background: var(--si-hover-color);
}

/* Quadrata */
.widget-social-icons--square .social-icon {
  border-radius: 6px;
}

/* Senza sfondo */
.widget-social-icons--none .social-icon {
  background: transparent;
  width: auto;
  height: auto;
}

.widget-social-icons--none .social-icon:hover {
  background: transparent;
  color: var(--si-hover-color);
}


/* =====================================================
   WIDGET LOGO
===================================================== */

.widget-logo-link {
  display: inline-block;
  line-height: 0;
}

.widget-logo-img {
  display: block;
  height: auto;
  max-width: 100%;
  width: var(--logo-w-m);
}

.is-tablet .widget-logo-img  { width: var(--logo-w-t); }
.is-desktop .widget-logo-img { width: var(--logo-w-d); }


/* =====================================================
   CUSTOMIZER PREVIEW — una sola matitina per sidebar
   (il JS in preview.js rimuove dinamicamente quelle per-widget)
===================================================== */

/* il JS in preview.js mantiene solo la prima pencil per ogni sidebar */
