/* 04b-mega-menu.css – hardcoded Commercial mega menu (adapted from LPVI, LGC tokens) */

.site-nav__item--has-mega{position:static;display:flex;align-items:center;}
.site-nav__link--mega{padding-right:var(--space-1) !important;}
.site-nav__mega-toggle{display:inline-flex;align-items:center;justify-content:center;padding:var(--space-2) var(--space-1);background:none;border:0;cursor:pointer;color:var(--color-text-body);border-radius:var(--radius-sm);transition:var(--transition-color);line-height:1.2;}
.site-nav__mega-toggle:hover{color:var(--color-action-text);background:var(--color-action-hover-bg);}
.site-nav__chevron{transition:transform var(--duration-base) var(--ease-out);flex-shrink:0;}
.site-nav__mega-toggle[aria-expanded="true"] .site-nav__chevron{transform:rotate(180deg);}

.mega-menu{
  position:fixed;top:0;left:0;right:0;
  background:#fff;border-bottom:1px solid var(--color-border);
  box-shadow:0 16px 48px rgba(26,43,60,0.12);
  z-index:calc(var(--z-nav) - 1);
  visibility:hidden;opacity:0;pointer-events:none;transform:translateY(-8px);
  transition:opacity .22s var(--ease-out),transform .22s var(--ease-out),visibility 0s linear .22s;
}
.mega-menu--open{
  visibility:visible;opacity:1;pointer-events:auto;transform:translateY(0);
  transition:opacity .22s var(--ease-out),transform .22s var(--ease-out),visibility 0s linear 0s;
}

.mega-menu__inner{
  max-width:var(--container-max);margin-inline:auto;
  padding:var(--space-10) var(--section-pad-x) var(--space-8);
  display:grid;grid-template-columns:repeat(5,1fr);gap:var(--space-6);
}

.mega-col__head{display:flex;align-items:center;gap:var(--space-3);margin-bottom:var(--space-4);}
.mega-col__icon{width:36px;height:36px;border-radius:50%;background:rgba(107,191,154,0.10);display:flex;align-items:center;justify-content:center;flex-shrink:0;color:var(--color-action-text);}
.mega-col__title{font-family:var(--font-heading);font-size:var(--text-base);font-weight:var(--weight-bold);color:var(--color-navy);line-height:1.2;letter-spacing:var(--tracking-tight);}
.mega-col__divider{height:2px;background:var(--color-action);border-radius:var(--radius-full);margin-bottom:var(--space-4);opacity:.60;}
.mega-col__links{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:2px;}
.mega-col__links a{display:block;font-size:var(--text-sm);font-weight:var(--weight-medium);color:var(--color-navy);text-decoration:none;padding:var(--space-2-5) var(--space-3);border-radius:var(--radius-sm);border-left:2px solid transparent;line-height:var(--leading-snug);transition:color var(--duration-fast) var(--ease-out),border-color var(--duration-fast) var(--ease-out),background var(--duration-fast) var(--ease-out),padding-left var(--duration-fast) var(--ease-out);}
.mega-col__links a:hover{color:var(--color-action-text);border-left-color:var(--color-action);background:rgba(107,191,154,0.06);padding-left:var(--space-4);}

.mega-menu__footer{max-width:var(--container-max);margin-inline:auto;padding:var(--space-4) var(--section-pad-x);border-top:0.5px solid var(--color-border);display:flex;align-items:center;gap:var(--space-4);background:var(--color-bg-alt);}
.mega-menu__footer-label{font-size:var(--text-xs);font-weight:var(--weight-medium);letter-spacing:var(--tracking-widest);text-transform:uppercase;color:var(--color-text-muted);}
.mega-menu__footer-link{display:inline-flex;align-items:center;gap:var(--space-2);font-size:var(--text-sm);font-weight:var(--weight-semibold);color:var(--color-text-primary);text-decoration:none;transition:color var(--duration-fast) var(--ease-out),gap var(--duration-base) var(--ease-out);}
.mega-menu__footer-link:hover{color:var(--color-action-text);gap:var(--space-3);}

.mega-backdrop{position:fixed;inset:0;background:rgba(26,43,60,0.25);z-index:calc(var(--z-nav) - 2);backdrop-filter:blur(2px);visibility:hidden;opacity:0;transition:opacity .2s var(--ease-out),visibility 0s linear .2s;}
.mega-backdrop--open{visibility:visible;opacity:1;transition:opacity .2s var(--ease-out),visibility 0s linear 0s;}

@media(max-width:1100px){.mega-menu__inner{grid-template-columns:repeat(3,1fr);}}
@media(max-width:991px){.mega-menu,.mega-backdrop{display:none;}}
/* Note that the industry columns are examples, not the full scope.
   Pushed to the right of the footer strip so it fills the empty space
   without competing with the gallery links. */
.mega-menu__footer{flex-wrap:wrap;}
.mega-menu__footer-note{
  margin:0 0 0 auto;
  font-size:var(--text-sm);
  line-height:var(--leading-normal);
  color:var(--color-text-body);
  text-align:right;
}
.mega-menu__footer-note a{
  color:var(--color-action-text);
  font-weight:var(--weight-semibold);
  text-decoration:none;
}
.mega-menu__footer-note a:hover{text-decoration:underline;}

@media(max-width:1100px){
  .mega-menu__footer-note{margin-left:0;text-align:left;flex-basis:100%;}
}
/* ── Residential mega menu ──
   Same chrome as Commercial, and now the same full-bleed white bar: the
   earlier version capped the panel at 980px and moved the white background
   onto the inner container, because two short columns looked lost across a
   1440px width. With the areas list grown to fourteen entries the panel has
   the content to fill the container, so those overrides are gone and it
   inherits the Commercial styling unchanged.

   Track ratio is 1:2 rather than equal halves. Services holds two
   sub-columns and Areas holds four, so splitting the panel evenly would
   starve the wider group. At 1:2 every sub-column across both groups ends up
   roughly the same width. */
.mega-menu__inner--res{
  grid-template-columns:minmax(0,1fr) minmax(0,2fr);
  gap:var(--space-10);
}

/* Services: two sub-columns, filled top to bottom then across. Seven links
   land as 4 + 3. */
.mega-col__links--split{
  display:grid;
  grid-template-columns:repeat(2,max-content);
  grid-auto-flow:column;
  grid-template-rows:repeat(4,auto);
  gap:2px var(--space-5);
}

/* Areas: four sub-columns. Grid fills each column to the row count before
   moving to the next, so with fourteen entries and four rows the split lands
   at 4 + 4 + 4 + 2. That is deliberate rather than a compromise: it needs no
   per-item placement, so the list can grow or shrink without anyone having
   to retune the CSS. Adding a fifteenth area simply gives 4 + 4 + 4 + 3. */
.mega-col--areas .mega-col__links--split{
  grid-template-columns:repeat(4,max-content);
}

/* "All Service Areas" is the hub link rather than a place, so it is marked
   out from the cities beneath it. It is always first in the array, hence
   :first-child. The hover rule is repeated because the shared
   .mega-col__links a:hover would otherwise reset the colour on hover. */
.mega-col--areas .mega-col__links--split li:first-child a{
  font-weight:var(--weight-bold);
  color:var(--color-cta);
}
.mega-col--areas .mega-col__links--split li:first-child a:hover{
  color:var(--color-cta-hover);
  border-left-color:var(--color-cta);
  background:rgba(220,88,42,0.06);
}

@media(max-width:1100px){
  /* Stack the two groups, and drop the areas list to three sub-columns with
     five rows so the entries stay readable once the panel narrows. */
  .mega-menu__inner--res{grid-template-columns:1fr;gap:var(--space-8);}
  .mega-col--areas .mega-col__links--split{
    grid-template-columns:repeat(3,max-content);
    grid-template-rows:repeat(5,auto);
  }
}