/* rc9.8 — stable launchers: the genuine Complianz control stays in its DOM. */
/* Complianz' original control is not a presentation node on the homepage.
 * It stays in place to receive native .click() events; NEVER move it.
 * This mirrors Complianz' official custom-button approach. */
body.vmag-front-page .cmplz-manage-consent { display: none !important; }
/* Avoid misleading buttons before Complianz has loaded its native control. */
html:not(.mep-consent-available) body.vmag-front-page .mep-consent-launcher { display: none !important; }

html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar {
  grid-template-columns: minmax(0,1fr) auto minmax(112px,auto) minmax(0,1fr);
  gap: clamp(7px,1.1vw,17px);
  padding-inline: clamp(10px,1.8vw,28px);
}
body.vmag-front-page .mep-legal-bar__company-compact { display:none; }
@media (min-width:601px) and (max-width:1600px) {
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__company-full {display:none;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__company-compact {display:inline;}
}
/* Empty anchor reserves the previous horizontal position, not a clickable element. */
body.vmag-front-page .mep-legal-bar__consent-anchor {
  width: clamp(106px,9vw,139px);
  min-width:0;
  height:1px;
  pointer-events:none;
}
/* Root-level dock bypasses #app clipping, transformations and stacking contexts. */
html[data-vmag-mode="desktop"] body.vmag-front-page .mep-consent-dock {
  position:fixed;
  right:clamp(112px,14vw,230px); /* visible fallback while X is measured */
  bottom:calc(var(--mep-legal-h,44px) + 10px + env(safe-area-inset-bottom,0px));
  transform:translateX(-50%);
  display:flex;
  justify-content:center;
  align-items:center;
  min-width:115px;
  pointer-events:none;
  z-index:2147483000;
}
html[data-vmag-mode="desktop"] body.vmag-front-page .mep-consent-dock > .mep-consent-launcher {
  position:static !important;
  inset:auto !important;
  transform:none !important;
  width:auto !important;
  max-width:160px !important;
  min-width:112px !important;
  height:29px !important;
  min-height:29px !important;
  max-height:29px !important;
  padding:6px 10px !important;
  margin:0 !important;
  border:1px solid rgba(98,217,236,.46) !important;
  border-left:2px solid #62d9ec !important;
  border-radius:2px !important;
  background:rgba(8,34,43,.97) !important;
  color:#c6f0f5 !important;
  font:700 10px/1.2 'Trebuchet MS',Arial,sans-serif !important;
  letter-spacing:.2px !important;
  white-space:nowrap !important;
  box-shadow:0 3px 12px rgba(0,0,0,.4) !important;
  text-align:center !important;
  pointer-events:auto !important;
  cursor:pointer;
}
/* HOME launchers render only after the real Complianz control is detected. */
html[data-vmag-mode="desktop"] body.vmag-front-page .mep-consent-dock > .mep-consent-launcher:hover {
  color:#fff !important;background:#14414d !important;border-color:#91eaf3 !important;
}
body.vmag-front-page .mep-legal-bar__cookie svg { width:15px;height:15px; }
body.vmag-front-page .mep-legal-bar__cookie:hover,
body.vmag-front-page .mep-legal-bar__cookie:focus-visible {color:#f1c879;}
@media(min-width:601px) and (max-width:1370px) {
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__company {gap:6px;font-size:9.5px;letter-spacing:0;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__legal {gap:2px;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__legal button,
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__legal a {padding-inline:4px;font-size:10px;letter-spacing:0;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__contacts {gap:6px;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__email span {font-size:10px;}
}
@media(min-width:601px) and (max-width:1150px) {
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar {grid-template-columns:minmax(0,1fr) auto auto;gap:8px;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__company {display:none;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__legal {justify-content:start;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__email span {display:none;}
}
@media(min-width:601px) and (max-width:790px) {
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__terms span {display:none;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__legal {gap:0;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-legal-bar__contacts {gap:3px;}
  html[data-vmag-mode="desktop"] body.vmag-front-page .mep-consent-dock > .mep-consent-launcher {min-width:101px!important;font-size:9px!important;padding-inline:5px!important;}
}
/* Smartphone: a native-semantics launcher follows the last HOME card, in flow.
 * It cannot cover the chat, course cards or legal links. */
html[data-vmag-mode="mobile"] body.vmag-front-page .mep-m-consent-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0 0 13px;
  margin: 0;
}
html[data-vmag-mode="mobile"] body.vmag-front-page
.mep-m-consent-slot > .mep-consent-launcher {
  position: static !important;
  inset: auto !important;
  transform: none !important;
  width: auto !important;
  max-width: calc(100% - 24px) !important;
  min-width: 158px !important;
  min-height: 34px !important;
  height: auto !important;
  margin: 0 auto !important;
  padding: 9px 17px !important;
  border: 1px solid rgba(98,217,236,.55) !important;
  border-left: 3px solid #62d9ec !important;
  border-radius: 2px !important;
  background: linear-gradient(105deg,#082a34,#06181f) !important;
  color: #cdf3f5 !important;
  box-shadow: 0 6px 14px rgba(0,0,0,.23) !important;
  font: 700 11px/1.28 'Trebuchet MS',Arial,sans-serif !important;
  letter-spacing: .3px !important;
  text-align: center !important;
  white-space: normal !important;
  z-index: auto !important;
  cursor: pointer;
}
html[data-vmag-mode="mobile"] body.vmag-front-page
.mep-m-consent-slot > .mep-consent-launcher:hover {
  background: #12404b !important;
  color: white !important;
}
/* The launcher exists only in the HOME mobile view. When Corsi or Chi siamo
 * is active, the entire home section (including this button) is hidden.
 * Contact is a full-screen native dialog above the home view. */
html[data-vmag-mode="mobile"] body.vmag-front-page .mep-consent-dock { display:none !important; }

body.vmag-front-page .mep-consent-dock > .mep-consent-launcher:focus-visible,
body.vmag-front-page .mep-m-consent-slot > .mep-consent-launcher:focus-visible {
  outline: 2px solid #a5f4ff !important;
  outline-offset: 2px !important;
}
@media (prefers-reduced-motion: reduce) {
  body.vmag-front-page :is(.mep-consent-dock,.mep-m-consent-slot) > .mep-consent-launcher {
    transition: none !important;
  }
}

/* Non-Complianz DOM control: browser-neutral and clickable even with HUD overlays. */
body.vmag-front-page .mep-consent-launcher {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  line-height: 1.2;
  text-transform: none;
}
html[data-vmag-mode="desktop"] body.vmag-front-page .mep-consent-dock > .mep-consent-launcher {
  z-index: 1;
}
