/* Desktop mega-menu for the navbar dropdowns (Company, Zoho, Odoo, Solutions, Hire IT Resources).
 * Markup comes from tools/mega_nav/mega.py. Panels open with the existing hover rule
 * (div.custom-nav>ul>li:hover .nx-dropdown); this file only sizes, positions and styles them. */
.mm-sr{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
:root{--mm-ink:#0B1220;--mm-mute:#5B6475;--mm-blue:#1b70ae;--mm-accent:#2563EB;--mm-line:#E6EAF2;--mm-tile:#F7F9FC;--mm-card:#EEF4FF}

@media (min-width:992px){
  /* hang the panel off the fixed header instead of the <li>, so it can be wide and centred */
  .custom-nav .nav-list li.mm-li{position:static}
  .custom-nav .nx-dropdown.mm-panel,.main-header.sticky .custom-nav .nx-dropdown.mm-panel{top:var(--mm-top,90px)}
  .custom-nav .nx-dropdown.mm-panel{scrollbar-width:none;-ms-overflow-style:none}
  .custom-nav .nx-dropdown.mm-panel::-webkit-scrollbar{display:none}
  .custom-nav .nx-dropdown.mm-panel{width:min(1240px,calc(100vw - 48px));left:0;right:0;margin:0 auto;padding:0;
    background:#fff;border:1px solid var(--mm-line);border-radius:18px;
    box-shadow:0 30px 60px -20px rgba(15,23,42,.28)}
  .custom-nav .nx-dropdown.mm-panel::before{content:"";position:absolute;left:0;right:0;top:-34px;height:34px}
  /* open/close: closed panels are invisible AND out of the tab order */
  .custom-nav .nx-dropdown.mm-panel{visibility:hidden;transition:opacity .22s ease,transform .22s ease,visibility 0s linear .22s}
  div.custom-nav:not(.mm-js)>ul>li.mm-li:hover .nx-dropdown.mm-panel,
  div.custom-nav:not(.mm-js)>ul>li.mm-li:focus-within .nx-dropdown.mm-panel,
  div.custom-nav.mm-js>ul>li.mm-li.mm-open .nx-dropdown.mm-panel{opacity:1;height:auto;visibility:visible;transform:none;transition-delay:0s;
    max-height:calc(100vh - var(--mm-top,90px) - 12px);overflow-y:auto!important}
  /* with js, hover alone does nothing: mega-nav.js adds .mm-open with hover intent */
  div.custom-nav.mm-js>ul>li.mm-li:hover:not(.mm-open) .nx-dropdown.mm-panel{opacity:0;height:0;visibility:hidden;
    -webkit-transform:perspective(600px) rotateX(-15deg);transform:perspective(600px) rotateX(-15deg)}
  div.custom-nav.mm-js>ul>li.mm-li.mm-open>a.menu-links{color:var(--mm-accent)!important}

  /* style.css gives every <a> a 1.2s transition on ALL properties, which delays inherited visibility (content pops in late,
     links can't take focus). Keep menu links to fast visual transitions only. */
  .custom-nav .mm-panel a{transition-property:color,background-color,border-color,box-shadow,transform,filter;transition-duration:.2s;transition-timing-function:ease}
  div.custom-nav>ul>li.mm-li>a:after{display:none!important}
  .mm-hrow{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 14px}
  .mm-hrow .mm-h{margin:0}
  .mm-all{display:inline-flex;align-items:center;gap:6px;font:700 13px/1 Poppins,system-ui,sans-serif;color:var(--mm-accent)!important;white-space:nowrap}
  .mm-all i{font-size:11px;transition:transform .2s}
  .mm-all:hover i{transform:translateX(3px)}
  .mm-pts{list-style:none;margin:0 2px 18px;padding:0;display:grid;gap:8px}
  .mm-pts li{display:flex;gap:9px;align-items:flex-start;font:600 13px/1.4 system-ui,sans-serif;color:var(--mm-ink)}
  .mm-pts i{color:#16A34A;font-size:14px;margin-top:1px}
  .mm-foot{display:flex;flex-wrap:wrap;align-items:center;gap:10px 26px;padding:13px 30px;background:#F7F9FC;border-top:1px solid var(--mm-line)}
  .mm-foot span{display:inline-flex;align-items:center;gap:8px;font:600 12.5px/1.2 Poppins,system-ui,sans-serif;color:var(--mm-mute)}
  .mm-foot span i{color:var(--mm-accent)}
  .mm-foot a{margin-left:auto;display:inline-flex;align-items:center;gap:8px;font:700 13px/1 Poppins,system-ui,sans-serif;color:var(--mm-accent)!important}
  .mm-panel a:focus-visible{outline:2px solid var(--mm-accent);outline-offset:2px;border-radius:12px}

  .mm-wrap{display:grid;grid-template-columns:minmax(0,1fr) 330px;gap:28px;padding:26px 26px 26px 30px;text-align:left}
  .mm-main{min-width:0}
  .mm-h{margin:0 0 14px;font:800 12px/1.2 Poppins,system-ui,sans-serif;letter-spacing:.12em;text-transform:uppercase;color:var(--mm-accent)}
  .mm-sep{border:0;border-top:1px solid var(--mm-line);margin:20px 0 18px;opacity:1}

  /* app tiles */
  .mm-apps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
  .mm-app{display:flex;align-items:center;height:62px;padding:0 16px;background:var(--mm-tile);border:1px solid var(--mm-line);
    border-radius:14px;transition:border-color .2s,box-shadow .2s,transform .2s,background .2s}
  .mm-app img{height:35px;width:auto;max-width:100%;display:block}
  .mm-app:hover{background:#fff;border-color:#BFD3F5;box-shadow:0 8px 20px -10px rgba(37,99,235,.45);transform:translateY(-1px)}
  .mm-oapp{gap:12px}
  .mm-oapp img{height:32px;width:32px;flex:none;border-radius:8px}
  .mm-oapp span{display:flex;flex-direction:column;font:700 15px/1.1 Poppins,system-ui,sans-serif;color:var(--mm-ink)}
  .mm-oapp small{font:600 10.5px/1.2 Poppins,system-ui,sans-serif;color:#714B67;margin-bottom:2px}

  /* icon + label links */
  .mm-svcs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px 18px}
  .mm-svc{display:flex;align-items:center;gap:12px;padding:6px 8px;border-radius:12px;font:600 14.5px/1.3 Poppins,system-ui,sans-serif;
    color:var(--mm-ink)!important;transition:background .2s}
  .mm-ic{flex:none;display:grid;place-items:center;width:38px;height:38px;border-radius:11px;background:#EEF4FF;color:var(--mm-accent);font-size:15px;
    transition:background .2s,color .2s}
  .mm-svc:hover,.mm-dl:hover{background:var(--mm-tile)}
  .mm-svc:hover .mm-ic,.mm-dl:hover .mm-ic{background:var(--mm-accent);color:#fff}

  /* icon + label + one line */
  .mm-desc{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px 16px}
  .mm-dl{display:flex;align-items:flex-start;gap:12px;padding:10px;border-radius:14px;transition:background .2s}
  .mm-dl b{display:block;font:700 14.5px/1.3 Poppins,system-ui,sans-serif;color:var(--mm-ink)}
  .mm-dl small{display:block;margin-top:2px;font:500 12.5px/1.4 system-ui,sans-serif;color:var(--mm-mute)}

  /* countries */
  .mm-ctry{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px 14px}
  .mm-ctry a{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:10px;font:600 13.5px/1.3 Poppins,system-ui,sans-serif;color:var(--mm-ink)!important}
  .mm-ctry a i{color:var(--mm-accent);font-size:12px}
  .mm-ctry a:hover{background:var(--mm-tile)}

  .mm-regions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px 20px}
  .mm-region{display:flex;flex-direction:column;gap:2px}
  .mm-rh{margin:0 0 6px;padding:0 8px;font:700 12px/1.2 Poppins,system-ui,sans-serif;color:var(--mm-mute);text-transform:uppercase;letter-spacing:.08em}
  .mm-region a{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:10px;font:600 13.5px/1.3 Poppins,system-ui,sans-serif;color:var(--mm-ink)!important;white-space:nowrap}
  .mm-region a i{color:var(--mm-accent);font-size:12px}
  .mm-region a:hover{background:var(--mm-tile)}

  /* bottom strip that fills the space under each panel's lists */
  /* spread sections evenly over the card's height instead of leaving one big gap */
  .mm-main{display:flex;flex-direction:column;justify-content:space-between;gap:14px}
  .mm-main>.mm-sep{margin:0}
  .mm-sec .mm-hrow{margin-bottom:12px}
  .mm-strip{padding-top:0}
  .mm-strip .mm-hrow{margin-bottom:10px}
  .mm-chips{display:flex;flex-wrap:wrap;gap:8px}
  .mm-chip{display:inline-flex;align-items:center;gap:8px;padding:8px 14px;border:1px solid var(--mm-line);border-radius:999px;background:#fff;
    font:600 13px/1.2 Poppins,system-ui,sans-serif;color:var(--mm-ink)!important}
  .mm-chip i{color:var(--mm-accent);font-size:12px}
  .mm-chip:hover{border-color:#BFD3F5;background:#F5F8FF}
  .mm-posts,.mm-steps{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
  .mm-post{display:flex;flex-direction:column;gap:3px;padding:12px 14px;border:1px solid var(--mm-line);border-radius:14px;background:var(--mm-tile)}
  .mm-post:hover{background:#fff;border-color:#BFD3F5;box-shadow:0 8px 20px -12px rgba(37,99,235,.45)}
  .mm-post-k{font:800 10px/1 Poppins,system-ui,sans-serif;letter-spacing:.1em;text-transform:uppercase;color:var(--mm-accent)}
  .mm-post b{font:700 13.5px/1.35 Poppins,system-ui,sans-serif;color:var(--mm-ink)}
  .mm-steps small{display:block;margin-top:2px}
  .mm-post small,.mm-steps small,.mm-office small{font:500 12px/1.35 system-ui,sans-serif;color:var(--mm-mute)}
  .mm-steps{list-style:none;margin:0;padding:0;counter-reset:none}
  .mm-steps li{display:flex;gap:12px;align-items:flex-start;padding:12px 14px;border:1px solid var(--mm-line);border-radius:14px;background:var(--mm-tile)}
  .mm-steps b{display:block;font:700 13.5px/1.3 Poppins,system-ui,sans-serif;color:var(--mm-ink)}
  .mm-step-n{flex:none;display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:var(--mm-accent);color:#fff;font:800 13px/1 Poppins,system-ui,sans-serif}
  .mm-offices{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
  .mm-office{display:flex;align-items:center;gap:8px;padding:9px 12px;border:1px solid var(--mm-line);border-radius:12px;background:var(--mm-tile);min-width:0}
  .mm-office i{color:var(--mm-accent);font-size:13px}
  .mm-office b{font:700 13px/1.2 Poppins,system-ui,sans-serif;color:var(--mm-ink);white-space:nowrap}
  .mm-office small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

  /* right card */
  .mm-card{display:flex;flex-direction:column;background:linear-gradient(180deg,var(--mm-card),#F6F9FF);border:1px solid #DCE6FA;border-radius:20px;padding:16px}
  .mm-shot{display:block;border-radius:14px;overflow:hidden;background:#fff;box-shadow:0 10px 24px -14px rgba(15,23,42,.35)}
  .mm-shot img{display:block;width:100%;height:auto;aspect-ratio:16/10;object-fit:cover}
  .mm-card-t{margin:16px 2px 6px;font:800 19px/1.25 Poppins,system-ui,sans-serif;color:var(--mm-ink)}
  .mm-card-p{margin:0 2px 18px;font:500 14px/1.55 system-ui,sans-serif;color:var(--mm-mute)}
  .mm-cta{margin-top:auto;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:7px 7px 7px 22px;border-radius:999px;
    background:linear-gradient(90deg,#4F8DF7,var(--mm-accent));color:#fff!important;font:700 16px/1 Poppins,system-ui,sans-serif;
    box-shadow:0 12px 24px -12px rgba(37,99,235,.7);transition:filter .2s}
  .mm-cta-ic{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;background:#0B1220;color:#fff;font-size:14px}
  .mm-cta-ic i{transform:rotate(-45deg);transition:transform .2s}
  .mm-cta:hover{filter:brightness(1.05)}
  .mm-cta:hover .mm-cta-ic i{transform:rotate(0)}

  /* Zoho: 18 logos in 6 columns (3 rows) on every desktop width, so the tallest panel fits without scrolling */
  .mm-zoho .mm-apps{grid-template-columns:repeat(6,minmax(0,1fr));gap:8px}
  .mm-zoho .mm-app{height:54px;padding:0 8px;justify-content:center}
  .mm-zoho .mm-app img{height:30px}
  /* smaller desktops */
  @media (max-width:1240px){
    .mm-wrap{grid-template-columns:minmax(0,1fr) 280px;gap:22px;padding:22px}
    .mm-oapp span{font-size:14px}
    .mm-desc{grid-template-columns:repeat(2,minmax(0,1fr))}
  }
}
@media (min-width:992px) and (max-height:820px){
  .mm-strip{padding-top:12px}.mm-post,.mm-steps li{padding:9px 12px}.mm-chip{padding:6px 12px}.mm-office{padding:7px 10px}
  .mm-zoho .mm-svcs,.mm-ai .mm-svcs{grid-template-columns:repeat(4,minmax(0,1fr));gap:2px 10px}
  .mm-zoho .mm-svc,.mm-ai .mm-svc{font-size:13px;gap:9px}
  .mm-app{height:48px}.mm-app img{height:26px}.mm-zoho .mm-app{height:46px}.mm-zoho .mm-app img{height:26px}.mm-wrap{padding-top:16px;padding-bottom:16px}.mm-shot img{aspect-ratio:16/8}
  .mm-sep{margin:14px 0 12px}.mm-svc{padding:4px 8px}.mm-ic{width:34px;height:34px}.mm-pts{gap:5px;margin-bottom:12px}
  .mm-card-t{margin-top:12px}.mm-card-p{margin-bottom:10px}.mm-foot{padding:10px 30px}.mm-dl{padding:7px 10px}
}

/* seven top-level items: keep them on one line and step size down on smaller laptops */
@media (min-width:992px){
  .custom-nav .nav-list li.mm-li a.menu-links{white-space:nowrap}
  .custom-nav .nav-list li.mm-li a.menu-links .dropdown-symbol{margin-left:2px}
}
@media (min-width:992px) and (max-width:1439px){
  .custom-nav .nav-list li.mm-li a.menu-links{font-size:15px;padding:0 10px}
}
@media (min-width:992px) and (max-width:1339px){
  .custom-nav .nav-list li.mm-li a.menu-links{font-size:14px;padding:0 7px}
  .main-header .right-end-btn a,.main-header .right-end-btn .btn{white-space:nowrap}
}
@media (min-width:992px) and (max-width:1219px){
  .custom-nav .nav-list li.mm-li a.menu-links{font-size:13.5px;padding:0 5px}
}
/* dark mode */
.active-dark .custom-nav .nx-dropdown.mm-panel{background:#0F172A;border-color:#1E293B}
.active-dark .mm-post,.active-dark .mm-steps li,.active-dark .mm-office,.active-dark .mm-chip{background:#111C33;border-color:#1E293B}
.active-dark .mm-post b,.active-dark .mm-steps b,.active-dark .mm-office b,.active-dark .mm-chip{color:#E2E8F0!important}
.active-dark .mm-foot{background:#0B1324;border-color:#1E293B}
.active-dark .mm-pts li{color:#CBD5E1}
.active-dark .mm-app,.active-dark .mm-card{background:#111C33;border-color:#1E293B}
.active-dark .mm-oapp span,.active-dark .mm-svc,.active-dark .mm-dl b,.active-dark .mm-ctry a,.active-dark .mm-card-t{color:#E2E8F0!important}
.active-dark .mm-app img[src*="zoho-apps"]{filter:brightness(0) invert(1)}
/* country flags in Locations / Odoo countries / offices */
.mm-flag{flex:none;width:20px;height:14px;object-fit:cover;border-radius:3px;box-shadow:0 0 0 1px rgba(15,23,42,.12)}
