:root {
  --ycm-navy: #42546a;
  --ycm-navy-soft: #52657b;
  --ycm-sea: #000000;
  --ycm-coral: #dc5848;
  --ycm-red: #d40000;
  --ycm-menu-red: #d32826;
  --ycm-sand: #d8d5ce;
  --ycm-paper: #ffffff;
  --ycm-ink: #000000;
  --ycm-muted: #000000;
  --ycm-line: #dce2e5;
  --ycm-radius: 16px;
  --ycm-shadow: 0 18px 45px rgba(13, 34, 54, .12);
}

html { background: var(--ycm-navy); }
body {
  color: var(--ycm-ink);
  background: var(--ycm-navy);
  font-size: 20px;
  line-height: 1.65;
}

a,
a:visited { color: #292929; text-underline-offset: .18em; }
a:hover,
a:focus,
a:active { color: var(--ycm-menu-red); }
h1, h2, h3, h4, h5, h6 { color: #000; line-height: 1.15; }
h1, .ycm-display { font-family: Georgia, "Times New Roman", serif; font-style: italic; font-weight: 700; }

/* Helix header and menu */
#sp-top-bar { display: none; }
.body-wrapper {
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
  background: #fff;
  border: 0;
  outline: 0;
  box-shadow: none;
}
#sp-header {
  /* v5.27: rosso opaco comune a menu e sottomenu, equivalente al vecchio rosso sull'header. */
  --ycm-red: #d32826;
  --ycm-menu-red: var(--ycm-red);
  width: 100%;
  height: auto;
  min-height: 104px;
  margin: 0;
  background: #cdc8bd !important;
  box-shadow: none;
}
#sp-header.header-sticky {
  left: max(0px, calc((100vw - 1040px) / 2));
  right: auto;
  width: min(1040px, 100%);
  margin: 0;
  /* Stesso colore opaco su desktop e mobile, anche durante lo scroll. */
  background: #cdc8bd !important;
}
#sp-header .logo { height: 104px; padding-left: 34px; }
#sp-header .logo-image { max-height: 58px; }
.sp-megamenu-parent > li > a,
.sp-megamenu-parent > li > span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  color: #292929;
  background: transparent;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .02em;
  line-height: 1.15;
  text-align: center;
  text-transform: uppercase;
}
#sp-header .sp-megamenu-parent > li:not(.active):not(.current) > a,
#sp-header .sp-megamenu-parent > li:not(.active):not(.current) > span { color: #292929; background: transparent; }
#sp-header .sp-megamenu-parent > li.active > a,
#sp-header .sp-megamenu-parent > li.active > span,
#sp-header .sp-megamenu-parent > li.current > a,
#sp-header .sp-megamenu-parent > li.current > span { color: #fff; background: var(--ycm-menu-red); }
#sp-header .sp-megamenu-parent > li:not(.active):not(.current):hover > a,
#sp-header .sp-megamenu-parent > li:not(.active):not(.current):hover > span,
#sp-header .sp-megamenu-parent > li:not(.active):not(.current):focus-within > a,
#sp-header .sp-megamenu-parent > li:not(.active):not(.current):focus-within > span { color: #fff; background: var(--ycm-menu-red); }

/* Priorità sulle regole native di Helix Ultimate */
#sp-header .sp-megamenu-wrapper,
#sp-header ul.sp-megamenu-parent { height: 104px; }
#sp-header ul.sp-megamenu-parent { display: flex; flex-flow: row nowrap; align-items: center; }
/* v5.26: prevale sul display:block !important della classe Helix d-lg-block. */
@media (min-width: 992px) {
  #sp-header ul.sp-megamenu-parent {
    display: flex !important;
    flex-flow: row nowrap !important;
    align-items: center !important;
  }
}
#sp-header ul.sp-megamenu-parent > li.sp-menu-item {
  display: flex !important;
  flex: 0 0 auto !important;
  width: auto !important;
  align-items: center !important;
  height: 104px !important;
}
#sp-header ul.sp-megamenu-parent > li.sp-menu-item > a,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item > span {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 52px !important;
  padding: 0 22px !important;
  color: #292929 !important;
  font-size: 16px !important;
  font-weight: 800 !important;
  line-height: 1.15 !important;
  text-align: center !important;
  white-space: nowrap !important;
}
#sp-header ul.sp-megamenu-parent > li.sp-menu-item.active > a,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item.active > span,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item.current > a,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item.current > span {
  color: #fff !important;
  background-color: var(--ycm-menu-red) !important;
}
#sp-header ul.sp-megamenu-parent > li.sp-menu-item:not(.active):not(.current):hover > a,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item:not(.active):not(.current):hover > span,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item:not(.active):not(.current):focus-within > a,
#sp-header ul.sp-megamenu-parent > li.sp-menu-item:not(.active):not(.current):focus-within > span {
  color: #fff !important;
  background-color: var(--ycm-menu-red) !important;
}
/* Nasconde il testo Home lasciando visibile l'icona scelta in Joomla */
#sp-header .sp-megamenu-parent > li > a.ycm-home-only {
  min-width: 52px;
  font-size: 0 !important;
  justify-content: center !important;
}
#sp-header .sp-megamenu-parent > li > a.ycm-home-only > [class*="fa"] {
  display: inline-block !important;
  width: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 22px !important;
  line-height: 1;
}
.sp-megamenu-parent > li:last-child > .sp-dropdown {
  right: 0 !important;
  left: auto !important;
}
.sp-megamenu-parent .sp-dropdown .sp-dropdown-inner {
  padding: 0;
  border-radius: 0;
  background: var(--ycm-red);
  box-shadow: var(--ycm-shadow);
}
.sp-megamenu-parent .sp-dropdown li.sp-menu-item > a,
.sp-megamenu-parent .sp-dropdown li.sp-menu-item > span {
  display: block;
  padding: 13px 20px;
  border-bottom: 1px solid #fff;
  color: #fff !important;
  background: var(--ycm-red) !important;
  font-weight: 700;
  text-transform: uppercase;
  white-space: nowrap;
}
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:last-child > a,
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:last-child > span {
  border-bottom: 0;
}
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:hover > a,
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:hover > span,
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:focus-within > a,
.sp-megamenu-parent .sp-dropdown li.sp-menu-item:focus-within > span {
  color: #fff !important;
  background: #000 !important;
}
.burger-icon > span { background-color: #292929; }
.offcanvas-menu { background: var(--ycm-navy); }
.offcanvas-menu .offcanvas-inner ul.menu > li a,
.offcanvas-menu .offcanvas-inner ul.menu > li span { color: #fff; }

/* Joomla component pages */
#sp-main-body { padding: 0 20px 64px; }
.article-details, .blog, .contact, .login, .registration, .reset, .remind {
  padding: clamp(24px, 4vw, 52px);
  border-radius: var(--ycm-radius);
  background: var(--ycm-paper);
  box-shadow: var(--ycm-shadow);
}
.article-header h1, .article-header h2 { font-family: Georgia, "Times New Roman", serif; font-style: italic; }
.page-item.active .page-link { border-color: var(--ycm-coral); background: var(--ycm-coral); }

/* Shared SP Page Builder design system */
.ycm-section { padding: clamp(64px, 9vw, 112px) 0; }
.ycm-section--compact { padding: clamp(42px, 6vw, 72px) 0; }
.ycm-section--white { background: var(--ycm-paper); }
.ycm-section--sand { background: var(--ycm-sand); }
.ycm-section--navy { color: #dce8ee; background: var(--ycm-navy); }
.ycm-section--navy h1, .ycm-section--navy h2, .ycm-section--navy h3 { color: #fff; }
.ycm-eyebrow { margin-bottom: 12px; color: #000; font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.ycm-title { margin-bottom: 20px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(2rem, 5vw, 4rem); font-style: italic; font-weight: 700; line-height: 1.02; }
.ycm-lead { max-width: 760px; color: var(--ycm-muted); font-size: clamp(1.05rem, 2vw, 1.3rem); }
.ycm-section--navy .ycm-lead { color: #dce8ee; }

.ycm-hero {
  min-height: clamp(460px, 72vh, 760px);
  display: flex;
  align-items: flex-end;
  color: #fff;
  background-image: linear-gradient(90deg, rgba(13,34,54,.92), rgba(13,34,54,.18)), url('../images/ycmare/hero.jpg');
  background-position: center;
  background-size: cover;
}

/* Home ispirata al sito storico */
.ycm-legacy-showcase {
  min-height: 475px;
  margin: 0 30px 48px;
  display: flex;
  align-items: flex-end;
  background: linear-gradient(rgba(224,223,219,.22), rgba(224,223,219,.22)), url('../images/ycmare/hero.jpg') center/cover no-repeat;
}
.ycm-legacy-showcase .sppb-row-container { width: 100%; padding: 42px; background: linear-gradient(transparent, rgba(13,34,54,.55)); }
.ycm-legacy-showcase h1 { margin: 0; color: #fff; font: italic 700 clamp(2.4rem, 6vw, 4.8rem)/1 Georgia, serif; }
.ycm-legacy-showcase p { max-width: 650px; color: #fff; }
.ycm-legacy-courses { margin: 0 0 48px; padding: 0; background: #e0dfdb; }
.ycm-legacy-courses .sppb-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  background: #e0dfdb;
}
.ycm-legacy-courses .sppb-row > * {
  width: 100% !important;
  max-width: none !important;
}
.ycm-legacy-courses .sppb-row-column,
.ycm-legacy-courses .sppb-column,
.ycm-legacy-courses .sppb-column-addons { height: 100%; background: #e0dfdb; }
.ycm-legacy-course {
  height: 100%;
  min-height: 480px;
  padding: 34px 0;
  border-right: 1px solid #fff;
  background: #e0dfdb;
}
.ycm-legacy-courses .ycm-legacy-course { border-right: 1px solid #fff !important; }
.ycm-legacy-courses .sppb-row > :first-child.ycm-legacy-course,
.ycm-legacy-courses .sppb-row > :first-child .ycm-legacy-course { padding-left: 0 !important; }
.ycm-legacy-courses .sppb-row > :nth-child(3).ycm-legacy-course,
.ycm-legacy-courses .sppb-row > :nth-child(3) .ycm-legacy-course { border-right: 0 !important; }
.ycm-legacy-course h3 { color: #000; font: normal 700 clamp(1.65rem, 3vw, 2.2rem)/1.16 Georgia, serif; }
.ycm-legacy-course .sppb-addon-text-block { color: #242424; font-size: 20px; line-height: 1.45; }
.ycm-legacy-info { margin: 0; padding: 0; }
.ycm-legacy-info .sppb-row > * {
  padding-left: 0 !important;
  padding-right: 0 !important;
}
.ycm-legacy-info-column { min-height: 0; padding: 0; border-right: 1px solid #e6e6e6; }
.ycm-legacy-info-column:last-child { border-right: 0; }
.ycm-legacy-info-column h2, .ycm-legacy-info-column h3 { color: #000; font-family: Arial, sans-serif; font-style: normal; font-weight: 500; }
.ycm-legacy-info-column .ycm-script { color: #000; font: italic 700 1.25rem Georgia, serif; }
/* Link nel contenuto delle pagine, inclusi i link-contenitore degli addon.
   Lo stato :visited esplicito evita il blu predefinito di Safari/iPadOS. */
#sp-main-body a:not(.sppb-btn),
#sp-main-body a:not(.sppb-btn):visited {
  color: #292929 !important;
  transition: color .2s ease;
}
#sp-main-body a:not(.sppb-btn):hover,
#sp-main-body a:not(.sppb-btn):focus,
#sp-main-body a:not(.sppb-btn):active {
  color: var(--ycm-menu-red) !important;
}
.ycm-hero .sppb-row-container { width: 100%; padding-top: clamp(90px, 13vw, 160px); padding-bottom: clamp(70px, 10vw, 120px); }
.ycm-hero h1 { max-width: 820px; margin-bottom: 22px; color: #fff; font: italic 700 clamp(2.8rem, 8vw, 6rem)/.96 Georgia, serif; }
.ycm-hero p { max-width: 680px; color: #edf4f6; font-size: clamp(1.1rem, 2.2vw, 1.42rem); }

.ycm-card { height: 100%; padding: clamp(24px, 3vw, 36px); border: 1px solid var(--ycm-line); border-radius: var(--ycm-radius); background: #fff; box-shadow: 0 10px 28px rgba(13,34,54,.07); transition: transform .2s ease, box-shadow .2s ease; }
.ycm-card:hover { transform: translateY(-4px); box-shadow: var(--ycm-shadow); }
.ycm-card h3 { font-family: Georgia, "Times New Roman", serif; font-style: normal; }
.ycm-card img { border-radius: 12px; }

/* Allineamento forzato a sinistra per gli addon SP Page Builder */
.ycm-text-left,
.ycm-text-left .sppb-addon,
.ycm-text-left .sppb-addon-content,
.ycm-text-left .sppb-addon-title,
.ycm-text-left h1,
.ycm-text-left h2,
.ycm-text-left h3,
.ycm-text-left h4,
.ycm-text-left p,
.ycm-text-left ul,
.ycm-text-left ol,
.ycm-text-left li {
  text-align: left !important;
}
.ycm-text-left .sppb-addon-content { align-items: flex-start !important; }
.ycm-text-left ul,
.ycm-text-left ol {
  width: 100%;
  margin-left: 0 !important;
  padding-left: 26px !important;
}
.ycm-text-left li { display: list-item !important; }
.ycm-text-left * { text-align: left !important; }
.ycm-text-left .sppb-addon-content,
.ycm-text-left li,
.ycm-text-left [class*="list"] {
  justify-content: flex-start !important;
  align-items: flex-start !important;
}
.ycm-text-left .sppb-addon-title,
.ycm-text-left [class*="price"],
.ycm-text-left [class*="pricing"] {
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* Accordion SP Page Builder coerente con il testo generale del sito */
.sppb-addon-accordion .sppb-panel-title,
.sppb-addon-accordion .sppb-panel-title a,
.sppb-addon-accordion .sppb-panel-heading,
.sppb-addon-accordion .sppb-panel-body {
  font-family: inherit !important;
  font-size: 20px !important;
  line-height: 1.65 !important;
}

/* Tutti i bottoni SP Page Builder usano la dimensione del testo generale */
.sppb-btn,
a.sppb-btn,
button.sppb-btn {
  font-size: 20px !important;
}
.sppb-sp-slider-button .sp-slider-btn-text {
  font-size: 20px !important;
}

.sppb-btn.ycm-btn, .ycm-btn .sppb-btn {
  padding: 13px 22px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--ycm-coral);
  font-size: 20px;
  font-weight: 750;
  box-shadow: 0 8px 18px rgba(220,88,72,.24);
}
.sppb-btn.ycm-btn:hover, .ycm-btn .sppb-btn:hover { transform: translateY(-1px); }
.sppb-btn.ycm-btn-outline, .ycm-btn-outline .sppb-btn { border: 1px solid currentColor; border-radius: 999px; color: #000; background: transparent; }

.ycm-stats .sppb-addon-number { color: #000; font-family: Georgia, serif; font-size: clamp(2.2rem, 5vw, 4rem); font-weight: 700; }
.ycm-gallery img { aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; }
.ycm-contact-panel { padding: clamp(30px, 5vw, 64px); border-radius: var(--ycm-radius); color: #fff; background: var(--ycm-navy); box-shadow: var(--ycm-shadow); }
.ycm-contact-panel h2, .ycm-contact-panel h3 { color: #fff; }

/* Contact section on the home page. */
#Contatto .addon-root-feature .sppb-icon,
#Contatto .addon-root-feature .sppb-icon-container,
#Contatto .addon-root-feature .sppb-icon-container i,
#Contatto .addon-root-feature .sppb-addon-text,
#Contatto .addon-root-feature .sppb-addon-text a {
  color: #000 !important;
}
#Contatto .addon-root-feature .sppb-addon-text a:hover,
#Contatto .addon-root-feature .sppb-addon-text a:focus,
#Contatto .addon-root-feature .sppb-addon-text a:active {
  color: var(--ycm-menu-red) !important;
}
#Contatto .sppb-addon-text-block .sppb-addon-content,
#Contatto .addon-root-feature .sppb-addon-text,
#Contatto .addon-root-feature .sppb-addon-text a,
#Contatto .sppb-addon-form-builder,
#Contatto .sppb-addon-form-builder .sppb-form-control,
#Contatto .sppb-addon-form-builder .sppb-form-label,
#Contatto .sppb-addon-form-builder .sppb-form-builder-required,
#Contatto .sppb-addon-form-builder altcha-widget {
  font-family: inherit !important;
  font-size: 20px !important;
  line-height: 1.65 !important;
}
#Contatto .addon-root-feature .sppb-icon-container,
#Contatto .addon-root-feature .sppb-icon-container i {
  font-size: 26px !important;
  line-height: 1 !important;
}
#Contatto .addon-root-feature .sppb-addon-feature > .sppb-addon-content {
  display: flex !important;
  flex-flow: row nowrap !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 14px !important;
}
#Contatto .addon-root-feature .sppb-icon,
#Contatto .addon-root-feature .sppb-media-content {
  flex: 0 0 auto !important;
  margin: 0 !important;
  padding: 0 !important;
}
#Contatto .addon-root-feature .sppb-addon-text { margin: 0 !important; }
#Contatto .sppb-addon-form-builder .sppb-form-control {
  min-height: 52px;
  padding: 10px 12px !important;
}
#Contatto .sppb-addon-form-builder textarea.sppb-form-control { min-height: 148px; }
#Contatto .sppb-form-builder-btn .sppb-btn-success,
#Contatto .sppb-form-builder-btn .sppb-btn-success:disabled,
#Contatto .sppb-form-builder-btn .sppb-btn-success[disabled] {
  color: #fff !important;
  background-color: #1cab5b !important;
  border-color: #1cab5b !important;
  opacity: 1 !important;
}
#Contatto .sppb-form-builder-btn .sppb-btn-success:hover,
#Contatto .sppb-form-builder-btn .sppb-btn-success:focus,
#Contatto .sppb-form-builder-btn .sppb-btn-success:active {
  color: #fff !important;
  background-color: #000 !important;
  border-color: #000 !important;
}
#Contatto .sppb-form-builder-btn .sppb-btn-success span { color: inherit !important; }
#Contatto .addon-root-feature .sppb-btn { display: none !important; }

#sp-footer, #sp-bottom { color: #fff; background: var(--ycm-navy); }
#sp-footer {
  clear: both;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0 28px 30px;
  border: 0;
  box-shadow: none;
}
#sp-main-body + #sp-footer { margin-top: 0; }
#sp-footer a, #sp-bottom a { color: #fff; }
#sp-footer a:hover, #sp-bottom a:hover { color: var(--ycm-coral); }
#sp-footer .container,
#sp-footer .container-inner,
#sp-footer .row,
#sp-footer .sp-module,
#sp-bottom .container,
#sp-bottom .container-inner,
#sp-bottom .row,
#sp-bottom .sp-module { border: 0 !important; box-shadow: none !important; }
#sp-footer .container::before,
#sp-footer .container::after,
#sp-footer .container-inner::before,
#sp-footer .container-inner::after,
#sp-bottom .container::before,
#sp-bottom .container::after,
#sp-bottom .container-inner::before,
#sp-bottom .container-inner::after { display: none !important; border: 0 !important; }
#sp-footer hr, #sp-bottom hr { display: none !important; }
.ycm-footer-content, #sp-footer .row { align-items: flex-start; }
.ycm-footer-info { display: grid; gap: 3px; }
.ycm-footer-info strong { color: #fff; }
.ycm-footer-nav { display: flex !important; flex-flow: row nowrap !important; align-items: flex-start; justify-content: flex-end; width: 100%; overflow-x: auto; }
ul.ycm-footer-nav,
.ycm-footer-nav ul.menu,
#sp-footer .ycm-footer-nav ul.menu { display: flex !important; flex-flow: row nowrap !important; align-items: flex-start; justify-content: flex-end; width: auto; margin: 0 !important; padding: 0 !important; list-style: none; }
ul.ycm-footer-nav > li,
.ycm-footer-nav ul.menu > li,
#sp-footer .ycm-footer-nav ul.menu > li { display: block !important; flex: 0 0 auto; width: auto !important; margin: 0 !important; padding: 0 !important; }
ul.ycm-footer-nav > li > a,
.ycm-footer-nav ul.menu > li > a { display: block !important; padding: 0 12px; border: 0; border-right: 1px solid rgba(255,255,255,.5); white-space: nowrap !important; }
ul.ycm-footer-nav > li:last-child > a,
.ycm-footer-nav ul.menu > li:last-child > a { padding-right: 0; border-right: 0; }
.ycm-footer-nav > li > ul,
.ycm-footer-nav ul ul,
.ycm-footer-nav .mod-menu__sub,
.ycm-footer-nav .nav-child,
#sp-footer ul.ycm-footer-nav > li > ul,
#sp-footer .ycm-footer-nav ul.menu > li > ul {
  display: flex !important;
  flex-flow: column nowrap !important;
  align-items: flex-start;
  justify-content: flex-start !important;
  gap: 6px;
  width: 100% !important;
  margin: 8px 0 0 !important;
  padding: 0 12px !important;
  list-style: none;
}
.ycm-footer-nav > li > ul > li,
.ycm-footer-nav ul ul li,
.ycm-footer-nav .mod-menu__sub li,
.ycm-footer-nav .nav-child li { display: block !important; width: 100% !important; margin: 0 !important; padding: 0 !important; }
.ycm-footer-nav > li > ul a,
.ycm-footer-nav ul ul a,
.ycm-footer-nav .mod-menu__sub a,
.ycm-footer-nav .nav-child a {
  display: block !important;
  width: 100%;
  padding: 2px 0 !important;
  border: 0 !important;
  white-space: normal !important;
}

/* Footer menu generated by the Helix footer2 module position. */
#sp-footer2 ul.menu {
  display: flex !important;
  flex-flow: row nowrap !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}
#sp-footer2 .sp-column,
#sp-footer2 .sp-module,
#sp-footer2 .sp-module-content { text-align: left !important; }
#sp-footer2 ul.menu > li {
  display: block !important;
  flex: 0 0 auto !important;
  width: auto !important;
  margin: 0 !important;
  padding: 0 !important;
}
#sp-footer2 ul.menu > li > a {
  display: block !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-right: 1px solid rgba(255,255,255,.5) !important;
  white-space: nowrap !important;
}
#sp-footer2 ul.menu > li:last-child > a { padding-right: 0 !important; border-right: 0 !important; }
#sp-footer2 ul.menu > li > ul.mod-menu__sub,
#sp-footer2 ul.menu > li > ul.menu-child {
  display: flex !important;
  flex-flow: column nowrap !important;
  align-items: flex-start !important;
  justify-content: flex-start !important;
  gap: 6px !important;
  position: static !important;
  float: none !important;
  width: 100% !important;
  min-width: 0 !important;
  margin: 8px 0 0 !important;
  padding: 0 12px !important;
  list-style: none !important;
  transform: none !important;
}
#sp-footer2 ul.menu > li > ul.menu-child > li {
  display: block !important;
  float: none !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
}
#sp-footer2 ul.menu > li > ul.menu-child > li > a {
  display: block !important;
  width: 100% !important;
  padding: 2px 0 !important;
  border: 0 !important;
  white-space: normal !important;
}

/* Credito +media nel footer */
#sp-footer a[href="https://www.piumedia.ch/"],
#sp-footer a[href="https://www.piumedia.ch"] {
  color: #ccc !important;
  transition: color .2s ease;
}
#sp-footer a[href="https://www.piumedia.ch/"]:hover,
#sp-footer a[href="https://www.piumedia.ch/"]:focus,
#sp-footer a[href="https://www.piumedia.ch"]:hover,
#sp-footer a[href="https://www.piumedia.ch"]:focus {
  color: #fff !important;
}

/* Email e menu del footer */
#sp-footer a[href^="mailto:"],
#sp-footer ul.menu a {
  color: #fff !important;
  transition: color .2s ease;
}
#sp-footer a[href^="mailto:"]:hover,
#sp-footer a[href^="mailto:"]:focus,
#sp-footer ul.menu a:hover,
#sp-footer ul.menu a:focus {
  color: #ccc !important;
}

/* v5.22: menu laterale, inclusi sottomenu e stati attivi. */
.offcanvas-menu .offcanvas-inner ul.menu > li > a {
  font-size: 22px !important;
}
.offcanvas-menu .offcanvas-inner ul.menu li li > a {
  font-size: 19px !important;
}
.offcanvas-menu .offcanvas-inner ul.menu li > a {
  color: #fff !important;
  white-space: normal;
  overflow-wrap: break-word;
}
.offcanvas-menu .offcanvas-inner ul.menu li > a:hover,
.offcanvas-menu .offcanvas-inner ul.menu li > a:focus,
.offcanvas-menu .offcanvas-inner ul.menu li > a:active,
.offcanvas-menu .offcanvas-inner ul.menu li.active > a {
  color: #b8b8b8 !important;
}
.offcanvas-menu .offcanvas-inner ul.menu li > a span,
.offcanvas-menu .offcanvas-inner ul.menu .menu-toggler {
  color: inherit !important;
}

@media (max-width: 991.98px) {
  /* Specificita maggiore della vecchia regola inline display:flex. */
  #sp-header ul.sp-megamenu-parent {
    display: none !important;
  }
  .body-wrapper { width: calc(100% - 20px); }
  #sp-header { width: 100%; min-height: 80px; margin: 0; }
  #sp-header.header-sticky { left: 0; width: 100%; margin: 0; }
  #sp-header, #sp-header .logo { height: 80px; }
  #sp-header .sp-megamenu-wrapper,
  #sp-header ul.sp-megamenu-parent { height: 80px; }
  #sp-header ul.sp-megamenu-parent > li.sp-menu-item { height: 80px !important; }
  .ycm-hero { min-height: 560px; background-position: 62% center; }
  .ycm-card { margin-bottom: 18px; }
  .ycm-legacy-showcase { min-height: 420px; margin-inline: 12px; }
  .ycm-legacy-showcase .sppb-row-container { padding: 28px; }
  .ycm-legacy-courses { margin-inline: 12px; }
  .ycm-legacy-info { margin-inline: 0; }
  .ycm-legacy-courses .sppb-row { grid-template-columns: 1fr; }
  .ycm-legacy-course, .ycm-legacy-info-column { min-height: 0; border-right: 0; border-bottom: 1px solid #fff; }
  .ycm-legacy-courses .sppb-row > :first-child.ycm-legacy-course,
  .ycm-legacy-courses .sppb-row > :first-child .ycm-legacy-course { padding-left: 0 !important; }
  .ycm-footer-content { flex-direction: column; gap: 22px; }
  .ycm-footer-nav, ul.ycm-footer-nav, .ycm-footer-nav ul.menu { justify-content: flex-start !important; }
  ul.ycm-footer-nav, .ycm-footer-nav ul.menu { flex-wrap: wrap !important; row-gap: 18px; }
  ul.ycm-footer-nav > li:first-child > a, .ycm-footer-nav ul.menu > li:first-child > a { padding-left: 0; }
  #sp-footer2 ul.menu { flex-wrap: wrap !important; justify-content: flex-start !important; row-gap: 18px !important; }
  #sp-footer2 ul.menu > li:first-child > a { padding-left: 0 !important; }
}

/* v5.24: footer verticale solo sui telefoni; tablet orizzontale.
   Dimensioni dei caratteri ereditate dagli stili originali Helix. */
@media (max-width: 767.98px) {
  /* Su smartphone il sito occupa tutta la larghezza, senza fasce blu laterali. */
  .body-wrapper { width: 100%; }

  /* La galleria non conserva le dimensioni fisse impostate per il desktop. */
  .sppb-gallery {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    width: 100% !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
  }
  .sppb-gallery::before,
  .sppb-gallery::after {
    display: none !important;
    content: none !important;
  }
  .sppb-gallery > li {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    margin: 0 !important;
  }
  .sppb-gallery a,
  .sppb-gallery img {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
  }

  #sp-footer #sp-footer2 ul.menu {
    flex-flow: column nowrap !important;
    align-items: stretch !important;
    row-gap: 14px !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }
  #sp-footer #sp-footer2 ul.menu > li {
    width: 100% !important;
    min-width: 0 !important;
    text-align: left !important;
  }
  #sp-footer #sp-footer2 ul.menu > li > a {
    padding: 6px 0 !important;
    border: 0 !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
    line-height: 1.5;
  }
  #sp-footer #sp-footer2 ul.menu > li > ul {
    display: flex !important;
    flex-flow: column nowrap !important;
    position: static !important;
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box;
    margin: 6px 0 0 !important;
    padding: 0 0 0 16px !important;
    gap: 8px !important;
    list-style: none !important;
    transform: none !important;
  }
  #sp-footer #sp-footer2 ul.menu > li > ul > li {
    width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  #sp-footer #sp-footer2 ul.menu > li > ul > li > a {
    display: block !important;
    padding: 6px 0 !important;
    border: 0 !important;
    white-space: normal !important;
    overflow-wrap: anywhere;
    line-height: 1.5;
  }
}

/* v5.25: personalizzazioni trasferite dal campo Custom CSS di Helix. */
.sppb-addon-feature,
.sppb-addon-feature p,
.sppb-addon-feature .sppb-feature-box-title {
  color: #000 !important;
}

.ycm-course-date {
  display: block;
  width: calc(100% - 20px);
  box-sizing: border-box;
  margin: 0 20px 18px 0;
  padding: 12px 20px;
  background-color: #d32826;
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.25;
  cursor: default;
}
.ycm-course-date-pending { background-color: #666666; }

.sppb-btn.ycm-course-pending {
  position: relative;
  left: -20px;
  background: #666666 !important;
  border-color: #666666 !important;
  color: #ffffff !important;
}
.sppb-btn.ycm-course-pending:hover,
.sppb-btn.ycm-course-pending:focus {
  background: #000000 !important;
  border-color: #000000 !important;
  color: #ffffff !important;
}
.ycm-course-active {
  position: relative !important;
  left: -20px !important;
  background: #d32826 !important;
  border-color: #d32826 !important;
  color: #ffffff !important;
}
.ycm-course-active:hover,
.ycm-course-active:focus {
  background: #000000 !important;
  border-color: #000000 !important;
  color: #ffffff !important;
}
@media (max-width: 575px) {
  .sppb-btn.ycm-course-pending { left: 0; }
  .ycm-course-active { left: 0 !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto!important; transition-duration: .01ms!important; animation-duration: .01ms!important; animation-iteration-count: 1!important; }
}
