/* Shared mega-menu system (desktop: wide centered panel under the navbar; mobile: accordion). Prefix: nm- */
.nm-item { position: static; }
.nm-btn { display: inline-flex; align-items: center; gap: 4px; }
.nm-btn[aria-expanded="true"] { color: var(--color-p-text); }
.nm-panel { position: absolute; left: 50%; top: 100%; z-index: 60; width: min(1120px, 84vw); margin-top: 10px; padding: 44px 56px 48px; border-radius: 28px; background: var(--color-p-bg-secondary); border: 1px solid var(--color-p-border-line); box-shadow: 0 30px 70px -40px rgba(0,0,0,0.55); opacity: 0; visibility: hidden; transform: translate(-50%, -4px); pointer-events: none; transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s; }
.nm-panel.open { opacity: 1; visibility: visible; transform: translate(-50%, 0); pointer-events: auto; transition-delay: 0s; }
.nm-panel::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }   /* hover bridge between the button and the panel */
.nm-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 80px; }
.nm-head { margin: 0 0 18px; font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--color-p-muted); }
.nm-list { display: flex; flex-direction: column; }
.nm-list a { display: block; padding: 9px 0; font-size: 15px; font-weight: 500; line-height: 1.3; color: var(--color-p-text-secondary); transition: color .15s ease, transform .15s ease; }
.nm-list a:hover, .nm-list a:focus-visible { color: var(--color-p-text); transform: translateX(3px); outline: none; }
.nm-list a:hover::after { content: " \2192"; color: var(--color-p-accent-text); }
/* mobile accordion */
.nm-m details { border: 0; }
.nm-m summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; }
.nm-m summary::-webkit-details-marker { display: none; }
.nm-m summary::after { content: "+"; font-size: 18px; font-weight: 300; color: var(--color-p-muted); transition: transform .2s ease; }
.nm-m details[open] > summary::after { transform: rotate(45deg); }
.nm-m-top > summary { padding: 8px 0; margin-top: 8px; font-size: 14px; font-weight: 600; color: var(--color-p-text); }
.nm-m-sub > summary { padding: 8px 0 8px 12px; font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--color-p-muted); }
.nm-m a { display: block; padding: 8px 0 8px 24px; font-size: 14px; color: var(--color-p-muted); }
.nm-m a:hover { color: var(--color-p-text); }
@media (max-width: 1023px) { .nm-panel { display: none; } }
@media (prefers-reduced-motion: reduce) { .nm-panel, .nm-list a { transition: none; } }

/* Producto: four equal editorial columns (same panel as Soluciones) */
.nm-cols--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); column-gap: 40px; }
.nm-prod { display: flex; flex-direction: column; align-items: flex-start; padding: 4px 0; color: inherit; }
.nm-prod-eyebrow { margin: 0 0 12px; font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--color-p-muted); transition: color .18s ease; }
.nm-prod-title { margin: 0 0 12px; font-family: var(--font-geist, inherit); font-size: 18px; font-weight: 700; line-height: 1.25; letter-spacing: -0.01em; color: var(--color-p-text); }
.nm-prod-desc { margin: 0 0 18px; font-size: 14px; line-height: 1.55; color: var(--color-p-text-secondary); }
.nm-prod-cta { display: inline-block; margin-top: auto; font-size: 13.5px; font-weight: 600; color: var(--color-p-muted); transition: color .18s ease, transform .18s ease; }
.nm-prod:hover .nm-prod-eyebrow, .nm-prod:focus-visible .nm-prod-eyebrow { color: var(--color-p-accent-text); }
.nm-prod:focus-visible { outline: none; }
/* Recursos: smaller dropdown, same language */
.nm-item--sm { position: relative; }
.nm-panel--sm { left: auto; right: -40px; width: auto; min-width: 560px; padding: 32px 36px 34px; transform: translateY(-4px); }
.nm-panel--sm.open { transform: translateY(0); }
.nm-cols--sm { grid-template-columns: auto auto auto; column-gap: 48px; }
.nm-sub { margin: 18px 0 8px; }
@media (max-width: 1023px) { .nm-panel--sm { display: none; } }

/* Producto: wider panel so titles take 2 lines and descriptions 4 */
.nm-panel:has(.nm-cols--4) { width: min(1280px, 94vw); padding: 44px 48px 48px; }
.nm-cols--4 { column-gap: 36px; }

/* Soluciones: two lists grouped on the left, a soft separator, and a big Blog card with the latest post */
.nm-panel--sol { padding: 40px 44px 44px; }
.nm-sol { display: flex; align-items: stretch; }
.nm-sol-lists { flex: 0 0 auto; display: flex; gap: 64px; }
.nm-sol-sep { flex: 0 0 1px; margin: 0 48px; background: linear-gradient(to bottom, transparent, var(--color-p-border-hover) 15%, var(--color-p-border-hover) 85%, transparent); }
.nm-blog { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 14px; padding: 28px 28px 26px; border-radius: 22px; background: linear-gradient(140deg, rgba(232,108,93,0.30), rgba(20,184,166,0.16) 75%), var(--color-p-bg-secondary); border: 1px solid rgba(232,108,93,0.45); }
.nm-blog-eyebrow { margin: 0; font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--color-p-text); opacity: .85; }
.nm-blog-title { margin: 0; font-family: var(--font-geist, inherit); font-size: 22px; font-weight: 800; line-height: 1.2; letter-spacing: -0.02em; color: var(--color-p-text); }
.nm-blog-post { display: block; padding: 16px 18px; border-radius: 14px; background: var(--color-p-bg-secondary); border: 1px solid var(--color-p-border-hover); box-shadow: 0 10px 30px -18px rgba(0,0,0,0.6); transition: border-color .18s ease, transform .18s ease; }
.nm-blog-post:hover { border-color: rgba(232,108,93,0.5); transform: translateY(-1px); }
.nm-blog-new { display: inline-block; margin: 0 0 8px; padding: 3px 10px; border-radius: 999px; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: #0F766E; background: transparent; border: 1px solid #0F766E; }
.nm-blog-ptitle { margin: 0 0 6px; font-size: 15.5px; font-weight: 700; line-height: 1.3; color: var(--color-p-text); }
.nm-blog-excerpt { margin: 0 0 8px; font-size: 13px; line-height: 1.5; color: var(--color-p-text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.nm-blog-meta { margin: 0; font-size: 12px; color: color-mix(in srgb, var(--color-p-text) 72%, var(--color-p-bg-secondary)); }
.nm-blog-cta { align-self: flex-end; margin-top: auto; display: inline-flex; align-items: center; gap: 8px; padding: 9px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 700; color: #B4443A; background: transparent; border: 1.5px solid #B4443A; transition: background-color .18s ease, transform .18s ease; }
.nm-blog-cta:hover { background: rgba(180,68,58,0.08); transform: translateX(2px); }
@media (max-width: 1023px) { .nm-panel--sol { display: none; } }

/* Producto: each product keeps its own colour, same code as the Pricing cards */
.nm-prod { --c: #14B8A6; }
.nm-prod:nth-child(2) { --c: #E86C5D; } .nm-prod:nth-child(3) { --c: #EAB308; } .nm-prod:nth-child(4) { --c: #22C55E; }
.nm-prod-eyebrow { display: inline-flex; align-items: center; gap: 9px; color: var(--c); }
.nm-prod-eyebrow::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--c); box-shadow: 0 0 10px var(--c); }
.nm-prod:hover .nm-prod-eyebrow, .nm-prod:focus-visible .nm-prod-eyebrow { color: var(--c); }
.nm-prod:hover .nm-prod-cta, .nm-prod:focus-visible .nm-prod-cta { color: var(--c); transform: translateX(3px); }
.nm-prod:hover .nm-prod-title, .nm-prod:focus-visible .nm-prod-title { text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--c) 60%, transparent); text-underline-offset: 4px; }

/* Navbar: mark where you are (Producto on product pages, Soluciones on /solutions, ...) */
nav .nm-active > .nm-btn, nav a.nm-active { color: var(--color-p-text) !important; font-weight: 600; position: relative; }
nav .nm-active > .nm-btn::after, nav a.nm-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -8px; height: 2px; border-radius: 2px; background: var(--color-p-accent); }
nav .nm-active > .nm-btn::after { right: 14px; }
.nm-m-top.nm-active-m > summary { color: var(--color-p-accent-text); }
#mobileMenu a.nm-active { color: var(--color-p-accent-text); font-weight: 600; }
.nm-list a.nm-current, .nm-prod.nm-current .nm-prod-title { color: var(--color-p-accent-text); font-weight: 700; }
