diff --git a/public/admin/index.html b/public/admin/index.html
index aa8fe12..d819a87 100644
--- a/public/admin/index.html
+++ b/public/admin/index.html
@@ -163,9 +163,9 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
diff --git a/public/connettori-discovery.html b/public/connettori-discovery.html
index 4c28646..e222f94 100644
--- a/public/connettori-discovery.html
+++ b/public/connettori-discovery.html
@@ -99,9 +99,9 @@
-
+
-
+
diff --git a/public/controlli-periodici.html b/public/controlli-periodici.html
index f3105db..fcd8dd4 100644
--- a/public/controlli-periodici.html
+++ b/public/controlli-periodici.html
@@ -156,9 +156,9 @@
-
+
-
+
-
+
-
+
-
+
-
+
diff --git a/public/guida.html b/public/guida.html
index fea85d4..99107a1 100644
--- a/public/guida.html
+++ b/public/guida.html
@@ -1178,9 +1178,9 @@
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
-
+
diff --git a/public/js/aria-guide.js b/public/js/aria-guide.js
index 6235701..424daa0 100644
--- a/public/js/aria-guide.js
+++ b/public/js/aria-guide.js
@@ -79,13 +79,15 @@
'.aria-guide-coach .row{margin-top:8px;display:flex;gap:8px;justify-content:flex-end}',
'.aria-guide-coach button{border:none;border-radius:7px;padding:6px 12px;font:600 12px system-ui;cursor:pointer}',
'.aria-guide-go{background:#0066CC;color:#fff}.aria-guide-x{background:#1e3a5f;color:#cbd5e1}',
+ '.nav-item.aria-guide-open .mega,.nav-item.aria-guide-open .mega.no-promo{display:flex!important}',
'@media (prefers-reduced-motion:reduce){.aria-guide-spot,.aria-guide-ptr{transition:none;animation:none}}'
].join('\n');
document.head.appendChild(s);
}
- var _open = null;
+ var _open = null, _openMega = null;
function dismiss() {
+ if (_openMega) { _openMega.classList.remove('aria-guide-open'); _openMega = null; }
if (!_open) return;
_open.forEach(function (el) { if (el && el.parentNode) el.parentNode.removeChild(el); });
document.removeEventListener('keydown', onKey, true);
@@ -100,19 +102,29 @@
*/
function pointTo(nav, label) {
dismiss();
- var el = document.querySelector('.sidebar-nav a[data-nav="' + nav + '"]');
- var href = el ? el.getAttribute('href') : (nav + '.html');
- var rect = el && el.getBoundingClientRect();
- // fallback: niente sidebar visibile → vai diretto
- if (!el || !rect || rect.width === 0 || rect.height === 0) { window.location.href = href; return false; }
-
injectCss();
+ // V3: menu IN ALTO (data-nav su voci dirette e mega-link). Fallback compat sidebar V2.
+ var el = document.querySelector('.bar-nav [data-nav="' + nav + '"]')
+ || document.querySelector('[data-nav="' + nav + '"]')
+ || document.querySelector('.sidebar-nav a[data-nav="' + nav + '"]');
+ var href = el ? (el.getAttribute('href') || (nav + '.html')) : (nav + '.html');
+ // Se la voce è dentro un mega-menu (dropdown chiuso), aprilo per renderla visibile.
+ var megaItem = (el && el.closest && el.closest('.mega')) ? el.closest('.nav-item') : null;
+ if (megaItem) megaItem.classList.add('aria-guide-open');
+ try { window.scrollTo({ top: 0, behavior: 'auto' }); } catch (e) {}
+ var rect = el && el.getBoundingClientRect();
+ // fallback: voce non trovata/visibile → vai diretto
+ if (!el || !rect || rect.width === 0 || rect.height === 0) {
+ if (megaItem) megaItem.classList.remove('aria-guide-open');
+ window.location.href = href; return false;
+ }
+
var ov = document.createElement('div'); ov.className = 'aria-guide-ov';
var spot = document.createElement('div'); spot.className = 'aria-guide-spot';
var ptr = document.createElement('div'); ptr.className = 'aria-guide-ptr';
ptr.innerHTML = '';
var coach = document.createElement('div'); coach.className = 'aria-guide-coach';
- coach.innerHTML = 'Eccolo: ' + (label || nav) + '
È nel menu a sinistra. Vuoi che ti ci porti?'
+ coach.innerHTML = 'Eccolo: ' + (label || nav) + '
È nel menu in alto. Vuoi che ti ci porti?'
+ '