/*
Theme Name: DM I.T. Consulting
Theme URI: https://nexcore.ca
Author: DM I.T. Consulting Inc.
Author URI: https://nexcore.ca
Description: A block-based, security-first WordPress theme for Managed Service Providers. Single theme with light and dark modes, built on the Harbour Steel design tokens.
Version: 2.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: nexcore
Tags: managed-services, technology, cybersecurity, business, blog, block-styles, custom-menu, featured-images, full-width-template, translation-ready
*/

/* ─────────────────────────────────────────────
   CASCADE LAYER

   This whole stylesheet sits in a named layer, and that is load-bearing rather
   than tidy-minded. Unlayered CSS beats layered CSS outright, whatever the
   specificity — so while this file was unlayered, its global reset
   (`* { margin: 0; padding: 0 }`) and its `a { color: inherit }` silently
   defeated every Tailwind utility on the block markup: buttons lost their
   padding and their text colour.

   `nexcore-legacy` is declared here, in the stylesheet WordPress loads first,
   so it is registered ahead of Tailwind's own layers and therefore ranks below
   them. Utilities now win, which is what lets a block override this layer.
───────────────────────────────────────────── */
@layer nexcore-legacy {


/* Base layer: the hand-written system. Tailwind (assets/css/app.css) is
   enqueued alongside it and carries the block-based components. The two share
   the same tokens, so they agree by construction. */


/* ─────────────────────────────────────────────
   NEXCORE IT — THEME STYLESHEET
   All base styles live here. Page-specific
   styles are enqueued via functions.php.
───────────────────────────────────────────── */

:root {
  /* The legacy hand-written layer derives its palette from the token layer in
     src/css/tokens.css rather than hardcoding one. Custom properties resolve
     lazily, so referencing tokens defined in a later stylesheet is fine — and
     it means the `dark` class on <html> now drives BOTH systems from a single
     switch, instead of Tailwind going light while these components stayed dark.

     Names are `--nc-` prefixed because shadcn uses --accent and --border for
     different roles (a subtle hover surface, and a hairline), and the two
     layers were silently overwriting each other. */

  --nc-bg-base:        var(--background);
  --nc-bg-surface:     var(--muted);
  --nc-bg-card:        var(--card);
  --nc-bg-card-hover:  var(--accent);
  --nc-border:         var(--border);

  --nc-text-primary:   var(--foreground);
  --nc-text-secondary: var(--muted-foreground);
  --nc-text-muted:     var(--muted-foreground);

  /* Brand — Harbour Steel #5489AF. The tiering (fill / ground-under-white-text
     / accented text) is preserved; only the source of the values moved. */
  --nc-accent:         var(--brand);
  --nc-accent-solid:   var(--primary);
  --nc-accent-hover:   oklch(57% 0.081 241);
  --nc-accent-text:    var(--brand-text);
  --nc-accent-dim:     color-mix(in oklch, var(--brand) 15%, transparent);
  --nc-border-accent:  color-mix(in oklch, var(--brand) 35%, transparent);

  /* Secondary — Beacon Amber. Categorical only, never a call to action. */
  --nc-accent2:        var(--secondary);
  --nc-accent2-text:   var(--secondary-text);
  --nc-accent2-dim:    color-mix(in oklch, var(--secondary) 14%, transparent);

  --font-head:      'Barlow', sans-serif;
  --font-body:      'DM Sans', sans-serif;
  --radius:         10px;
  --radius-lg:      16px;
  --container:      1280px;
  --nav-h:          56px;   /* the ported header's bar is h-14 */

  /* Tuned per mode: a shadow that reads as depth on #0B0F1A reads as dirt on
     #FAFAF8. */
  --nc-shadow-card: 0 18px 40px oklch(17.8% 0.012 285 / 0.10);

  /* Outlined headline word. A dark stroke on a near-white ground reads thinner
     than a light stroke on a dark one at the same width, so light mode needs
     more weight to hold the same presence. */
  --nc-outline-stroke: 0.042em;

  /* Tile bevel. A white top highlight alone does nothing on a light tile, so
     light mode adds a soft bottom shade to give the edge somewhere to fall.
     Dark mode keeps the highlight only, which is where it actually reads. */
  --nc-tile-bevel: inset 0 1px 0 oklch(100% 0 0 / 0.9), inset 0 -1px 0 oklch(17.8% 0.012 285 / 0.10);
}

.dark {
  --nc-shadow-card: 0 20px 60px oklch(0% 0 0 / 0.40);
  --nc-outline-stroke: 0.028em;
  --nc-tile-bevel: inset 0 1px 0 oklch(100% 0 0 / 0.5);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--nc-bg-base);
  color: var(--nc-text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--nc-bg-base); }
::-webkit-scrollbar-thumb { background: var(--nc-border-accent); border-radius: 3px; }

/* ─── LAYOUT ─── */
.nc-container { max-width: var(--container); margin: 0 auto; padding: 0 40px; }
.nc-section    { padding: 100px 0; }
.nc-section-sm { padding: 60px 0; }

/* ─── TYPOGRAPHY ─── */
.nc-section-label {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-size: 11px; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--nc-accent-text); margin-bottom: 18px;
}
.nc-section-label::before { content: ''; display: block; width: 24px; height: 2px; background: var(--nc-accent); }

.nc-section-title {
  font-family: var(--font-head); font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800; line-height: 1.1; letter-spacing: -0.02em;
  color: var(--nc-text-primary); text-wrap: pretty;
}
.nc-section-title em { font-style: normal; color: var(--nc-accent-text); }
.nc-section-body { font-size: 1.05rem; color: var(--nc-text-secondary); max-width: 560px; margin-top: 16px; text-wrap: pretty; }
.nc-section-head { margin-bottom: 60px; }

h1, h2, h3, h4, h5, h6 { font-family: var(--font-head); font-weight: 700; line-height: 1.2; color: var(--nc-text-primary); }
h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); font-weight: 900; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.8rem, 3vw, 2.8rem); font-weight: 800; letter-spacing: -0.02em; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }
p  { color: var(--nc-text-secondary); line-height: 1.75; }

/* ─── BUTTONS ─── */
.btn, .wp-block-button__link {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-size: 14px; font-weight: 700;
  letter-spacing: 0.03em; padding: 13px 28px; border-radius: 6px;
  transition: all 0.2s ease; white-space: nowrap; cursor: pointer; text-decoration: none;
}
.btn-primary, .wp-block-button.is-style-primary .wp-block-button__link {
  background: var(--nc-accent-solid); color: #fff !important;
  box-shadow: 0 0 24px oklch(61% 0.081 241 / 0.35);
}
.btn-primary:hover { background: var(--nc-accent-hover); box-shadow: 0 0 36px oklch(61% 0.081 241 / 0.5); transform: translateY(-1px); }
.btn-ghost {
  background: transparent; color: var(--nc-text-primary) !important;
  border: 1px solid var(--nc-border);
}
.btn-ghost:hover { border-color: var(--nc-border-accent); color: var(--nc-accent-text) !important; background: var(--nc-accent-dim); }
.btn-outline {
  background: transparent; color: var(--nc-accent-text) !important;
  border: 1px solid oklch(61% 0.081 241 / 0.5);
}
.btn-outline:hover { background: var(--nc-accent-dim); border-color: var(--nc-accent); }
.btn-sm { padding: 9px 18px; font-size: 13px; }

/* ─── CARDS ─── */
.nc-card {
  background: var(--nc-bg-card); border: 1px solid var(--nc-border);
  border-radius: var(--radius-lg); padding: 28px; position: relative;
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s; overflow: hidden;
}
.nc-card::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at top left, oklch(61% 0.081 241 / 0.06) 0%, transparent 70%);
  opacity: 0; transition: opacity 0.3s; pointer-events: none;
}
.nc-card:hover { border-color: var(--nc-border-accent); transform: translateY(-3px); box-shadow: var(--nc-shadow-card); }
.nc-card:hover::before { opacity: 1; }

/* ─── BADGE ─── */
.nc-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--nc-accent-dim); color: var(--nc-accent-text);
  border: 1px solid oklch(61% 0.081 241 / 0.25);
  font-size: 12px; font-weight: 600; padding: 4px 12px; border-radius: 100px;
  font-family: var(--font-head); letter-spacing: 0.05em;
}
.nc-badge-cyan {
  background: var(--nc-accent2-dim); color: var(--nc-accent2-text);
  border-color: oklch(72% 0.16 65 / 0.25);
}

/* ─── DIVIDER ─── */
hr, .nc-divider { border: none; border-top: 1px solid var(--nc-border); margin: 0; }

/* ─── GRID BG ─── */
.nc-grid-bg {
  background-image: linear-gradient(var(--nc-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--nc-border) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* Block-built pages: our own blocks are full-bleed sections that carry their
   own container, but core blocks (headings, paragraphs, lists) have no width of
   their own and ran the full width of the viewport. Constrain everything that
   is not one of our sections to a readable measure. */
.nc-blocks > *:not(section) {
  max-width: 760px;
  margin-inline: auto;
  padding-inline: 24px;
}
.nc-blocks > h2 { margin-top: 48px; }
.nc-blocks > h2 + p { margin-top: 12px; }
.nc-blocks > p { margin-bottom: 20px; }
.nc-blocks > :last-child { margin-bottom: 80px; }

.nc-post-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 60px;
  align-items: start;
}
.nc-post-aside { position: sticky; top: calc(var(--nav-h) + 24px); }

/* One column on anything narrower than a small laptop: at 1fr 300px the article
   was squeezed to about a third of a phone screen. */
@media (max-width: 900px) {
  .nc-post-layout { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .nc-post-aside { position: static; }
}

/* Home service cards: icon left, copy right, the same shape as the cards on
   /services/. Stacked, the icon took its own line and the card ran tall for no
   gain. The icon keeps its own margin-bottom for the feature lists elsewhere,
   so it is zeroed here. */
.nc-service-card.nc-card {
  display: flex;
  align-items: flex-start;
  /* Gap matches the card padding, so the icon sits the same distance from the
     text as it does from the card edge. At 28px padding against a 16px gap the
     text crowded the icon while the edges looked generous. */
  padding: 20px;
  gap: 20px;
}
@media (min-width: 640px) {
  .nc-service-card.nc-card { padding: 24px; gap: 24px; }
}
.nc-service-card.nc-card .nc-service-icon { margin-bottom: 0; }
.nc-service-body { min-width: 0; flex: 1; }
.nc-service-body h3 { margin-bottom: 6px; }

/* Hero: copy on the left, the threat dashboard on the right as evidence for the
   claim rather than decoration — the composition from @efferd/hero-3 (21st.dev
   11428), which reserves that side for a product shot. */
.nc-hero__grid {
  display: grid; grid-template-columns: minmax(0,1fr) minmax(0,0.95fr);
  gap: 48px; align-items: center; width: 100%;
}
.nc-hero__panel { position: relative; }
/* Glow behind the panel, and a fade at its foot so it reads as continuing. */
.nc-hero__panel::before {
  content: ""; position: absolute; inset: -10% -14%; border-radius: 999px;
  background: radial-gradient(ellipse at center, var(--nc-accent-dim), transparent 70%);
  filter: blur(48px); z-index: 0;
}
.nc-hero__panel .nc-dashboard {
  position: relative; z-index: 1;
  -webkit-mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
}
.nc-split.nc-split--single { grid-template-columns: 1fr; max-width: 820px; }

@media (max-width: 900px) {
  .nc-hero__grid { grid-template-columns: 1fr; gap: 36px; }
  .nc-hero__panel { display: none; }
}

/* Hero node network: orbs joined by lines. Decorative, so it is aria-hidden and
   inert; `slice` keeps it filling the hero at any width without distorting. */
.nc-hero__net {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none; z-index: 0;
  /* Fade the network out behind the text column. Edges and orbs crossing the
     headline dropped body copy below the 4.5:1 contrast floor. */
  -webkit-mask-image: radial-gradient(ellipse 55% 60% at 50% 50%, transparent 30%, #000 78%);
  mask-image: radial-gradient(ellipse 55% 60% at 50% 50%, transparent 30%, #000 78%);
}
.nc-net__edges { stroke: var(--nc-accent); stroke-width: 1; }
.nc-net__orb   { fill: var(--nc-accent); opacity: 0.75; }
.nc-net__halo  { fill: var(--nc-accent); opacity: 0.07; }

@keyframes nc-net-pulse {
  from { transform: scale(0.8);  opacity: 0.45; }
  to   { transform: scale(1.22); opacity: 0.95; }
}
@keyframes nc-net-breathe {
  from { opacity: 0.03; transform: scale(0.8); }
  to   { opacity: 0.16; transform: scale(1.25); }
}
/* Position is JS's job (assets/js/hero-net.js) — it walks each node and drags
   the lines with it. CSS only pulses, which it can do without moving anything
   the lines are anchored to. */

.nc-net__edges { opacity: 0.22; }

.nc-net__orb, .nc-net__halo {
  transform-box: fill-box; transform-origin: center; will-change: transform, opacity;
}
.nc-net__orb  { animation: nc-net-pulse 5.2s ease-in-out infinite alternate; }
.nc-net__halo { animation: nc-net-breathe 6.4s ease-in-out infinite alternate; }

/* Stagger so they pulse independently rather than as one blinking grid. */
.nc-net__orb:nth-of-type(4n)    { animation-delay: -1s;   animation-duration: 6.8s; }
.nc-net__orb:nth-of-type(4n+1)  { animation-delay: -2.2s; animation-duration: 4.4s; }
.nc-net__orb:nth-of-type(4n+2)  { animation-delay: -3.8s; animation-duration: 6s; }
.nc-net__halo:nth-of-type(3n)   { animation-delay: -1.6s; animation-duration: 7.6s; }
.nc-net__halo:nth-of-type(3n+1) { animation-delay: -4.2s; animation-duration: 5.6s; }

@media (prefers-reduced-motion: reduce) {
  .nc-hero__net, .nc-net__orb, .nc-net__halo, .nc-net__edges { animation: none; }
}
.nc-hero__content { position: relative; z-index: 1; }

/* ─── STATS ─── */
.nc-stat-num { font-family: var(--font-head); font-size: 3rem; font-weight: 900; color: var(--nc-text-primary); letter-spacing: -0.03em; line-height: 1; }
.nc-stat-num span { color: var(--nc-accent-text); }
.nc-stat-label { font-size: 0.875rem; color: var(--nc-text-secondary); margin-top: 6px; font-weight: 500; }

/* ─── NAV ─── */
/* The old fixed, hard-coded-navy #site-header is gone; inc/site-header.php now
   renders a sticky, token-driven header ported from 21st.dev. Its former rules
   set `background: rgba(11,15,26,.6)` unconditionally, which survived the move
   to light mode as a grey band across the top. */

.site-logo {
  display: flex; align-items: center; gap: 10px; margin-right: auto;
  font-family: var(--font-head); font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em;
}
.site-logo .logo-icon {
  width: 32px; height: 32px; border-radius: 8px; background: var(--nc-accent-solid);
  display: flex; align-items: center; justify-content: center;
}
.site-logo .logo-accent { color: var(--nc-accent-text); }

/* Primary Nav */
#primary-menu-wrapper {
  display: flex; align-items: center; gap: 4px;
}
#primary-menu, #primary-menu ul { list-style: none; margin: 0; padding: 0; }
/* The wrapper is flex, but the <ul> is one flex child: without this its
   <li> stay block-level and the nav stacks vertically. */
#primary-menu { display: flex; align-items: center; gap: 2px; }
#primary-menu > li > a {
  display: block; padding: 8px 14px;
  font-family: var(--font-head); font-size: 14px; font-weight: 600;
  color: var(--nc-text-secondary); transition: color 0.2s;
}
#primary-menu > li > a:hover,
#primary-menu > li.current-menu-item > a,
#primary-menu > li.current-menu-parent > a { color: var(--nc-accent-text); }

/* Services mega-menu trigger */
#primary-menu > li.menu-item-has-children { position: relative; }
#primary-menu > li.menu-item-has-children > a::after {
  content: '▾'; margin-left: 4px; font-size: 10px;
  display: inline-block; transition: transform 0.2s;
}
#primary-menu > li.menu-item-has-children:hover > a::after { transform: rotate(180deg); }

/* Mega menu */
.mega-menu {
  display: none; position: fixed; left: 0; right: 0;
  top: var(--nav-h); z-index: 999;
  background: rgba(19, 25, 41, 0.97); backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--nc-border);
  padding: 40px 0 48px;
}
#primary-menu > li.menu-item-has-children:hover .mega-menu { display: block; }
.mega-menu-grid {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px;
}
.mega-menu-item {
  display: flex; flex-direction: column; gap: 10px; padding: 16px;
  background: var(--nc-bg-card); border: 1px solid var(--nc-border);
  border-radius: 10px; transition: all 0.2s; text-decoration: none;
}
.mega-menu-item:hover { border-color: var(--nc-border-accent); background: var(--nc-bg-card-hover); }
.mega-menu-item .icon-wrap {
  width: 36px; height: 36px; border-radius: 8px;
  background: var(--nc-accent-dim); display: flex; align-items: center; justify-content: center;
  border: 1px solid oklch(61% 0.081 241 / 0.22);
}
.mega-menu-item .icon-wrap.cyan { background: var(--nc-accent2-dim); border-color: oklch(72% 0.16 65 / 0.22); }
.mega-menu-item span { font-family: var(--font-head); font-size: 13px; font-weight: 700; color: var(--nc-text-primary); line-height: 1.3; }
.mega-menu-footer { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--nc-border); display: flex; gap: 16px; align-items: center; }
.mega-menu-footer p { font-size: 13px; color: var(--nc-text-muted); }

/* Header CTA */
.header-cta { display: flex; align-items: center; gap: 10px; margin-left: 24px; }

/* Mobile toggle */
.menu-toggle {
  display: none; padding: 8px; background: none; border: none;
  color: var(--nc-text-primary); cursor: pointer;
}
.mobile-nav { display: none; }

/* ─── HERO ─── */
.nc-hero {
  position: relative; min-height: 78vh; display: flex; align-items: center;
  overflow: hidden;
  background: radial-gradient(ellipse 80% 60% at 50% 40%, oklch(61% 0.081 241 / 0.08) 0%, transparent 60%), var(--nc-bg-base);
}
.nc-hero__content { position: relative; z-index: 2; max-width: 780px; padding: 60px 0; }
.nc-hero__eyebrow { margin-bottom: 24px; }
.nc-hero__headline {
  font-family: var(--font-head); font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 900; line-height: 1.0; letter-spacing: -0.03em;
  color: var(--nc-text-primary); margin-bottom: 28px; text-wrap: pretty;
}
.nc-hero__headline em { color: var(--nc-accent-text); font-style: italic; }
.nc-hero__headline .outline-text {
  /* Solid by default: where text-stroke is unsupported, a transparent fill
     would erase the word entirely. */
  color: var(--nc-text-primary);
}
@supports (-webkit-text-stroke: 1px currentColor) {
  .nc-hero__headline .outline-text {
    -webkit-text-stroke: var(--nc-outline-stroke) var(--nc-text-primary);
    -webkit-text-fill-color: transparent;
  }
}
.nc-hero__body { font-size: clamp(1rem, 1.5vw, 1.2rem); color: var(--nc-text-secondary); max-width: 560px; margin-bottom: 40px; line-height: 1.7; }
.nc-hero__actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 52px; }
.nc-hero__trust { display: flex; gap: 10px 24px; align-items: center; flex-wrap: wrap; }
.nc-hero__trust-item {
  display: flex; align-items: center; gap: 7px;
  color: var(--nc-text-muted); font-size: 12px; font-weight: 600;
  font-family: var(--font-head); letter-spacing: 0.04em;
}

/* ─── STATS BAR ─── */
.nc-stats-bar {
  background: var(--nc-bg-surface);
  border-top: 1px solid var(--nc-border);
  border-bottom: 1px solid var(--nc-border);
  padding: 52px 0;
}
.nc-stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; }
.nc-stat-item { text-align: center; }

/* ─── SERVICES ─── */
.nc-services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.nc-service-card { cursor: pointer; }
.nc-service-icon {
  width: 44px; height: 44px; border-radius: 10px;
  background: var(--nc-accent-dim); display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px; border: 1px solid oklch(61% 0.081 241 / 0.22);
}
.nc-service-icon.cyan { background: var(--nc-accent2-dim); border-color: oklch(72% 0.16 65 / 0.22); }
.nc-service-card h3 { font-size: 1rem; margin-bottom: 10px; }
.nc-service-card p { font-size: 0.875rem; line-height: 1.6; }
.nc-service-link { margin-top: 18px; display: flex; align-items: center; gap: 6px; color: var(--nc-accent-text); font-size: 13px; font-weight: 600; font-family: var(--font-head); }

/* Services sidebar layout */
.nc-services-layout { display: grid; grid-template-columns: 260px 1fr; gap: 40px; }
.nc-services-sidebar { position: sticky; top: calc(var(--nav-h) + 20px); }

/* On a phone the sidebar stacks above the content, so a visitor scrolled a full
   screen of service links before reaching the service they had already chosen.
   Below 900px the content comes first and the list becomes a footer of other
   services, which is what it actually is once you are on a page. */
@media (max-width: 900px) {
  /* minmax(0,1fr), not 1fr: a bare 1fr is minmax(auto,1fr) and refuses to
     shrink below its content's min-content width, so the long service names
     forced the column to 372px inside a 320px container and pushed the cards
     and the CTA off the right edge. min-width:0 does the same for the tracks'
     own children. */
  .nc-services-layout { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .nc-services-layout > * { min-width: 0; }
  .nc-services-nav-item { white-space: normal; }
  .nc-services-content { order: 1; }
  .nc-services-sidebar {
    order: 2; position: static;
    border-top: 1px solid var(--nc-border); padding-top: 24px;
  }
  .nc-services-sidebar::before {
    content: "All services";
    display: block; margin-bottom: 12px;
    font-family: var(--font-head); font-size: 0.72rem; font-weight: 700;
    letter-spacing: 0.14em; text-transform: uppercase; color: var(--nc-text-muted);
  }
  /* The current page is already the content above it. */
  .nc-services-sidebar .nc-services-nav-item.active { display: none; }
}
.nc-services-nav-item {
  display: flex; align-items: center; gap: 12px; padding: 12px 16px;
  border-radius: 8px; border: none; cursor: pointer;
  font-family: var(--font-head); font-size: 13px; font-weight: 600;
  text-align: left; transition: all 0.2s; width: 100%;
  background: transparent; color: var(--nc-text-secondary);
  border-left: 3px solid transparent;
}
.nc-services-nav-item.active, .nc-services-nav-item:hover {
  background: var(--nc-accent-dim); color: var(--nc-accent-text);
  border-left-color: var(--nc-accent);
}

/* ─── SPLIT SECTION ─── */
.nc-split { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.nc-split-reverse { direction: rtl; }
.nc-split-reverse > * { direction: ltr; }

/* ─── FEATURE LIST ─── */
.nc-feature-item { display: flex; gap: 16px; margin-bottom: 24px; }
.nc-feature-icon {
  width: 40px; height: 40px; border-radius: 8px; background: var(--nc-accent-dim);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  border: 1px solid oklch(61% 0.081 241 / 0.22);
}
.nc-feature-item h4 { font-size: 0.95rem; margin-bottom: 4px; }
.nc-feature-item p { font-size: 0.875rem; }

/* ─── DASHBOARD WIDGET ─── */
.nc-dashboard {
  background: var(--nc-bg-card); border: 1px solid var(--nc-border);
  border-radius: var(--radius-lg); padding: 32px; position: relative; overflow: hidden;
}
.nc-dashboard-label {
  font-family: var(--font-head); font-size: 11px; font-weight: 700;
  letter-spacing: 0.1em; color: var(--nc-text-muted); text-transform: uppercase; margin-bottom: 20px;
}
.nc-dashboard-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0; border-bottom: 1px solid var(--nc-border);
}
.nc-dashboard-row:last-of-type { border-bottom: none; }
.nc-dashboard-row-label { font-size: 13px; color: var(--nc-text-secondary); }
.nc-dashboard-row-val { font-family: var(--font-head); font-weight: 800; font-size: 1rem; }
.nc-dashboard-row-trend { font-size: 11px; color: var(--nc-text-muted); font-family: var(--font-head); margin-left: 12px; }
.nc-status-pill {
  margin-top: 16px; padding: 14px 16px;
  background: oklch(72% 0.16 65 / 0.08);
  border: 1px solid oklch(72% 0.16 65 / 0.22);
  border-radius: 8px; display: flex; gap: 10px; align-items: center;
}
.nc-status-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--nc-accent2); flex-shrink: 0;
  animation: nc-pulse 1.5s ease-in-out infinite;
}
.nc-status-text { font-size: 12px; color: var(--nc-accent2-text); font-family: var(--font-head); font-weight: 600; }

/* ─── TESTIMONIALS ─── */
.nc-testimonials-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.nc-testimonial-stars { display: flex; gap: 3px; margin-bottom: 14px; }
.nc-star { width: 16px; height: 16px; fill: oklch(75% 0.18 65); }
.nc-testimonial-quote { font-size: 0.95rem; color: var(--nc-text-secondary); line-height: 1.75; margin-bottom: 24px; font-style: italic; }
.nc-testimonial-author { display: flex; gap: 12px; align-items: center; }
.nc-testimonial-avatar {
  width: 40px; height: 40px; border-radius: 50%; background: var(--nc-accent-dim);
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--nc-border-accent); font-family: var(--font-head);
  font-weight: 800; font-size: 15px; color: var(--nc-accent-text); flex-shrink: 0;
}
.nc-testimonial-name { font-family: var(--font-head); font-weight: 700; font-size: 0.9rem; }
.nc-testimonial-title { font-size: 0.8rem; color: var(--nc-text-muted); }

/* ─── BLOG ─── */
.nc-blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.nc-blog-card { cursor: pointer; display: flex; flex-direction: column; }
.nc-blog-thumb {
  height: 160px; border-radius: 8px; overflow: hidden;
  margin-bottom: 18px; border: 1px solid var(--nc-border);
}
.nc-blog-thumb img { width: 100%; height: 100%; object-fit: cover; }
.nc-blog-meta { display: flex; gap: 14px; font-size: 12px; color: var(--nc-text-muted); padding-top: 12px; border-top: 1px solid var(--nc-border); margin-top: auto; }
/* The category pill had no bottom margin, so it sat flush against the title
   while the title had 10px below it. One rhythm now. */
.nc-blog-tag { margin-bottom: 10px; }
.nc-blog-card h3 { font-size: 1.05rem; line-height: 1.35; margin-bottom: 10px; }
.nc-blog-excerpt { font-size: 0.85rem; color: var(--nc-text-muted); line-height: 1.6; margin-bottom: 12px; }
.nc-blog-read-more { color: var(--nc-accent-text); font-size: 13px; font-weight: 600; font-family: var(--font-head); }

/* Blog single */
.nc-post-header { padding: 80px 0 60px; background: var(--nc-bg-surface); border-bottom: 1px solid var(--nc-border); }
.nc-post-content { max-width: 760px; }
.nc-post-content p { margin-bottom: 20px; }
.nc-post-content h2 { margin: 40px 0 16px; }
.nc-post-content h3 { margin: 32px 0 12px; }
.nc-post-content ul, .nc-post-content ol { padding-left: 24px; margin-bottom: 20px; color: var(--nc-text-secondary); line-height: 1.8; }
.nc-post-content blockquote {
  margin: 32px 0; padding: 24px 28px;
  border-left: 3px solid var(--nc-accent); background: var(--nc-bg-card);
  border-radius: 0 8px 8px 0;
}
.nc-post-content blockquote p { color: var(--nc-text-primary); font-size: 1.1rem; }

/* ─── CASE STUDIES ─── */
.nc-cases-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.nc-case-tag-label {
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--nc-text-muted); margin-bottom: 8px;
  font-family: var(--font-head);
}
.nc-case-metrics { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.nc-case-metric {
  font-size: 12px; font-weight: 600; padding: 4px 12px;
  border-radius: 100px; font-family: var(--font-head);
  background: var(--nc-accent-dim); color: var(--nc-accent-text);
  border: 1px solid oklch(61% 0.081 241 / 0.22);
}
.nc-case-metric.cyan {
  background: var(--nc-accent2-dim); color: var(--nc-accent2-text);
  border-color: oklch(72% 0.16 65 / 0.22);
}

/* ─── CONTACT ─── */
.nc-contact-layout { display: grid; grid-template-columns: 1fr 480px; gap: 60px; align-items: start; }
.nc-contact-item { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 20px; }
.nc-contact-icon {
  width: 40px; height: 40px; border-radius: 8px; background: var(--nc-accent-dim);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  border: 1px solid oklch(61% 0.081 241 / 0.22);
}
.nc-contact-label { font-family: var(--font-head); font-weight: 600; color: var(--nc-text-primary); font-size: 0.95rem; }
.nc-contact-sub { font-size: 0.8rem; color: var(--nc-text-muted); margin-top: 2px; }

/* ─── FORM ─── */
.nc-form { display: flex; flex-direction: column; gap: 16px; }
.nc-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.nc-label {
  display: block; font-size: 12px; font-weight: 600; font-family: var(--font-head);
  color: var(--nc-text-muted); margin-bottom: 6px; letter-spacing: 0.05em; text-transform: uppercase;
}
.nc-input, .nc-select, .nc-textarea {
  width: 100%; background: var(--nc-bg-card); border: 1px solid var(--nc-border);
  border-radius: 8px; padding: 12px 16px; color: var(--nc-text-primary);
  font-size: 14px; font-family: var(--font-body); outline: none;
  transition: border-color 0.2s;
}
.nc-input:focus, .nc-select:focus, .nc-textarea:focus { border-color: var(--nc-border-accent); }
.nc-input::placeholder, .nc-textarea::placeholder { color: var(--nc-text-muted); }
.nc-textarea { resize: vertical; min-height: 100px; }
.nc-select { cursor: pointer; }
.nc-form-note { font-size: 11px; color: var(--nc-text-muted); text-align: center; margin-top: 4px; }

/* ─── ACCORDION (FAQ) ─── */
.nc-accordion { }
.nc-accordion-item { border-bottom: 1px solid var(--nc-border); }
.nc-accordion-trigger {
  width: 100%; display: flex; align-items: center; justify-content: space-between;
  padding: 22px 0; font-family: var(--font-head); font-size: 1.05rem; font-weight: 600;
  color: var(--nc-text-primary); cursor: pointer; background: none; border: none;
  text-align: left; gap: 16px; transition: color 0.2s;
}
.nc-accordion-trigger:hover { color: var(--nc-accent-text); }
.nc-accordion-icon {
  width: 24px; height: 24px; flex-shrink: 0; display: flex; align-items: center;
  justify-content: center; border: 1px solid var(--nc-border); border-radius: 50%;
  transition: all 0.25s; font-size: 16px; line-height: 1;
}
.nc-accordion-item.open .nc-accordion-icon { background: var(--nc-accent-solid); border-color: var(--nc-accent-solid); transform: rotate(45deg); color: #fff; }
.nc-accordion-body { overflow: hidden; max-height: 0; transition: max-height 0.35s ease; }
.nc-accordion-item.open .nc-accordion-body { max-height: 300px; }
.nc-accordion-body p { color: var(--nc-text-secondary); padding-bottom: 22px; line-height: 1.7; }

/* ─── CTA BAND ─── */
.nc-cta-band {
  position: relative; padding: 100px 0; overflow: hidden; text-align: center;
}
.nc-cta-band::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 80% at 50% 50%, oklch(61% 0.081 241 / 0.1) 0%, transparent 70%);
  pointer-events: none;
}
.nc-cta-band h2 { margin-bottom: 20px; }
.nc-cta-band p { max-width: 500px; margin: 0 auto 40px; font-size: 1.05rem; }
.nc-cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ─── PAGE HEADERS ─── */
.nc-page-header {
  padding: 80px 0 60px;
  background: var(--nc-bg-surface); border-bottom: 1px solid var(--nc-border);
}

/* At 80px top the catalogue header pushed the service itself a third of a
   screen down on a phone, before any of the copy the visitor came for. This
   rule has to sit after the base one: they have equal specificity, and the
   earlier placement silently lost. */
@media (max-width: 900px) {
  .nc-page-header { padding: 32px 0 24px; }
}

/* ─── SOC FEED ─── */
.nc-soc-feed { }
.nc-soc-entry {
  display: flex; gap: 12px; padding: 10px 0;
  border-bottom: 1px solid var(--nc-border); align-items: flex-start;
}
.nc-soc-time { font-family: monospace; font-size: 11px; color: var(--nc-text-muted); flex-shrink: 0; padding-top: 2px; }
.nc-soc-badge {
  font-family: var(--font-head); font-size: 10px; font-weight: 700;
  letter-spacing: 0.05em; padding: 2px 7px; border-radius: 4px; flex-shrink: 0;
}
.nc-soc-badge.info  { background: var(--nc-accent2-dim); color: var(--nc-accent2-text); }
.nc-soc-badge.warn  { background: oklch(75% 0.18 80 / 0.15); color: oklch(75% 0.18 80); }
.nc-soc-badge.crit  { background: oklch(65% 0.22 20 / 0.15); color: oklch(70% 0.22 20); }
.nc-soc-msg { font-size: 12px; color: var(--nc-text-secondary); }
.nc-soc-live {
  margin-top: 14px; display: flex; align-items: center; gap: 8px;
  color: var(--nc-accent2-text); font-size: 12px; font-family: var(--font-head); font-weight: 600;
}

/* ─── FOOTER ─── */
#site-footer {
  background: var(--nc-bg-surface); border-top: 1px solid var(--nc-border); padding: 60px 0 32px;
}
.nc-footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 56px; }
.nc-footer-brand p { font-size: 0.875rem; color: var(--nc-text-muted); line-height: 1.7; max-width: 260px; margin: 16px 0 20px; }
.nc-footer-badges { display: flex; gap: 10px; }
.nc-footer-col-title {
  font-family: var(--font-head); font-weight: 700; font-size: 12px;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--nc-text-muted); margin-bottom: 16px;
}
.nc-footer-menu { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.nc-footer-menu a { font-size: 13px; color: var(--nc-text-secondary); transition: color 0.2s; }
.nc-footer-menu a:hover { color: var(--nc-accent-text); }
.nc-footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px; font-size: 12px; color: var(--nc-text-muted); border-top: 1px solid var(--nc-border);
}
.nc-footer-legal { display: flex; gap: 20px; }
.nc-footer-legal a { color: var(--nc-text-muted); transition: color 0.2s; }
.nc-footer-legal a:hover { color: var(--nc-text-primary); }
.nc-footer-address { font-style: normal; font-size: 13px; line-height: 1.7; color: var(--nc-text-secondary); }

/* Custom logo: 215x80 source, constrained by height so the header bar (56px)
   and the footer brand line both stay put regardless of the file swapped in. */
.custom-logo-link { display: inline-flex; align-items: center; }
.custom-logo { height: 36px; width: auto; display: block; }
#site-footer .custom-logo { height: 38px; margin-bottom: 4px; }
.nc-footer-hours { margin-top: 14px; font-size: 12px; line-height: 1.7; color: var(--nc-text-muted); }

/* ─── ANIMATIONS ─── */
@keyframes nc-pulse {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.4); }
}
@keyframes nc-float-up {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
.nc-fade-in { animation: nc-float-up 0.7s ease forwards; }
.nc-delay-1 { animation-delay: 0.1s; opacity: 0; }
.nc-delay-2 { animation-delay: 0.25s; opacity: 0; }
.nc-delay-3 { animation-delay: 0.4s; opacity: 0; }
.nc-delay-4 { animation-delay: 0.6s; opacity: 0; }
.nc-delay-5 { animation-delay: 0.8s; opacity: 0; }

.nc-reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s ease, transform 0.6s ease; }
.nc-reveal.visible { opacity: 1; transform: translateY(0); }

/* ─── GUTENBERG BLOCK COMPAT ─── */
.wp-block-group { margin: 0; }
.wp-block-image img { border-radius: var(--radius); }
.wp-block-quote {
  border-left: 3px solid var(--nc-accent); padding: 20px 24px;
  background: var(--nc-bg-card); border-radius: 0 8px 8px 0; margin: 32px 0;
}
.wp-block-quote p { color: var(--nc-text-primary); }
.wp-block-quote cite { color: var(--nc-text-muted); font-size: 13px; }
.wp-block-separator { border-color: var(--nc-border); }
.wp-block-code { background: var(--nc-bg-card); border: 1px solid var(--nc-border); border-radius: 8px; padding: 20px; color: var(--nc-accent2-text); font-size: 14px; }

/* ─── WOOCOMMERCE (optional) ─── */
.woocommerce #respond input#submit,
.woocommerce a.button,
.woocommerce button.button {
  background: var(--nc-accent-solid) !important; color: #fff !important;
  border-radius: 6px; font-family: var(--font-head); font-weight: 700;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .nc-split { grid-template-columns: 1fr; gap: 48px; }
  /* minmax(0,1fr): a bare 1fr will not shrink below its content's min-content
     width. See the note at the .nc-services-layout mobile block above. */
  .nc-services-layout { grid-template-columns: minmax(0, 1fr); }
  .nc-services-layout > * { min-width: 0; }
  .nc-services-sidebar { position: static; }
  .nc-cases-grid { grid-template-columns: 1fr; }
  .nc-contact-layout { grid-template-columns: 1fr; }
  .nc-testimonials-grid { grid-template-columns: 1fr 1fr; }
  .nc-blog-grid { grid-template-columns: 1fr 1fr; }
  .nc-footer-grid { grid-template-columns: 1fr 1fr; }
  .nc-stats-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .nc-container { padding: 0 20px; }
  .nc-section { padding: 70px 0; }
  #primary-menu-wrapper { display: none; }
  .header-cta { display: none; }
  .menu-toggle { display: flex; }
  .mobile-nav.open { display: block; position: absolute; top: var(--nav-h); left: 0; right: 0; background: var(--nc-bg-surface); border-bottom: 1px solid var(--nc-border); padding: 20px; }
  .nc-testimonials-grid { grid-template-columns: 1fr; }
  .nc-blog-grid { grid-template-columns: 1fr; }
  /* Stacking all four columns made the footer ~1180px on a 390px screen -
     three screenfuls. The link columns pair up instead; only the brand, which
     carries the address, needs the full width. */
  /* Three link groups do not divide into two columns, and three columns are
     too narrow for the phone number and "Remote Support". So Support - the
     longest strings and the reason most people are down here - takes the full
     width with its links in two, and Services pairs with Company below. */
  .nc-footer-grid { grid-template-columns: 1fr 1fr; gap: 26px 20px; margin-bottom: 32px; }
  .nc-footer-brand,
  .nc-footer-support { grid-column: 1 / -1; }
  .nc-footer-support .nc-footer-menu {
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px 20px;
  }
  .nc-footer-hours { margin-top: 12px; }
  /* The tagline restates the hero on a screen that has to scroll past all of
     it; the address it sits above is the part worth the space. */
  .nc-footer-brand p { display: none; }
  #site-footer .custom-logo { height: 32px; margin-bottom: 10px; }
  .nc-footer-bottom { flex-direction: column; align-items: flex-start; gap: 10px; }
  .nc-footer-brand p { margin: 10px 0 14px; }
  .nc-footer-menu { gap: 8px; }
  .nc-footer-col-title { margin-bottom: 12px; }
  #site-footer { padding: 40px 0 24px; }
  .mega-menu-grid { grid-template-columns: repeat(2, 1fr); }
  .nc-form-grid { grid-template-columns: 1fr; }
  .nc-hero__headline { font-size: clamp(2.2rem, 8vw, 3.5rem); }
  .nc-stats-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
}

@layer nexcore-legacy {
  /* Animated menu toggle, standing in for the original's MenuToggleIcon. */
  .nc-burger { display: block; width: 18px; height: 12px; position: relative; }
  .nc-burger span {
    position: absolute; left: 0; width: 100%; height: 2px; border-radius: 2px;
    background: currentColor; transition: transform .3s ease, top .3s ease;
  }
  .nc-burger span:first-child { top: 0; }
  .nc-burger span:last-child  { top: 10px; }
  [aria-expanded="true"] .nc-burger span:first-child { top: 5px; transform: rotate(45deg); }
  [aria-expanded="true"] .nc-burger span:last-child  { top: 5px; transform: rotate(-45deg); }
  @media (prefers-reduced-motion: reduce) { .nc-burger span { transition: none; } }
}

/* ─────────────────────────────────────────────
   MOBILE HARDENING (320px – 440px)

   Three tiers are covered: 320-360 compact, 375-393 baseline, 412-440 large.
   The failure this fixes: .btn sets white-space:nowrap with 28px side padding,
   so "Get a Free Managed IT Services Assessment" could not wrap and pushed the
   page 33px wider than a 360px viewport. Nothing here uses a fixed pixel width.
───────────────────────────────────────────── */
/* "What's included" was an inline grid-template-columns:1fr 1fr, which no media
   query can reach. auto-fit + minmax lets it collapse to one column on a phone
   instead of two very narrow ones wrapping every label onto four lines. */
.nc-included-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 12px;
  margin-bottom: 36px;
}
.nc-included-item {
  display: flex; align-items: center; gap: 10px; padding: 14px 16px;
  background: var(--nc-bg-card); border: 1px solid var(--nc-border); border-radius: 8px;
}

@media (max-width: 480px) {
  /* Labels wrap instead of forcing the page wider. Buttons go full width,
     which also guarantees the 44px touch target. */
  .btn, .wp-block-button__link {
    white-space: normal;
    max-width: 100%;
    justify-content: center;
    text-align: center;
    min-height: 44px;
    padding: 0.75rem 1.25rem;
    font-size: 0.875rem;
  }
  .nc-hero__actions .btn,
  .nc-post-content .btn { width: 100%; }

  /* Touch targets: nav rows were ~41px, the header links and menu toggle 36px. */
  .nc-services-nav-item { min-height: 44px; }
  #masthead a[class*="rounded-md"],
  #masthead [data-nav-trigger] { min-height: 44px; }
  #masthead [data-nav-toggle] { min-width: 44px; min-height: 44px; }

  /* The 44px toggle left only 6px above and below inside a 56px bar, against a
     16px inset from the screen edge, so it read as cramped even though it was
     centred. A 64px bar evens that out to 10px. The sheet is anchored to the
     same height, or it would tuck under the header. */
  #masthead nav { height: 4rem; }
  #mobile-menu { top: 4rem; }

  /* Nothing may set an intrinsic width larger than its track. */
  .nc-container { max-width: 100%; }
  img, svg, table, pre { max-width: 100%; }
}

/* Compact tier: trade horizontal padding for content width. */
@media (max-width: 360px) {
  .nc-container { padding-left: 14px; padding-right: 14px; }
  .btn, .wp-block-button__link { padding: 0.75rem 0.875rem; letter-spacing: 0.01em; }
  .nc-page-header { padding: 24px 0 20px; }
}

/* Standard-to-large tier: room to breathe again without looking sparse. */
@media (min-width: 376px) and (max-width: 480px) {
  .nc-container { padding-left: 20px; padding-right: 20px; }
}

@layer nexcore-legacy {
  /* Duotone fill. The filled element inherits currentColor, so tinting it here
     keeps one rule for every icon at every size rather than a colour per glyph. */
  /* Filled with --nc-accent, not currentColor. currentColor makes the fill a
     wash of the stroke colour, which reads flat; the lighter brand against the
     darker brand-text stroke is what makes a duotone mark read as two tones. */
  .nc-icon-fill { fill: color-mix(in oklch, var(--nc-accent) 42%, transparent); }

  /* Icon tile: brand-tinted ground, brand-tinted hairline and a 1px inner
     highlight. This is the treatment that makes a stock glyph look placed
     rather than pasted. */
  .nc-service-icon {
    background: color-mix(in srgb, var(--nc-accent) 9%, var(--nc-bg-card));
    border-color: color-mix(in oklch, var(--nc-accent) 24%, transparent);
    box-shadow: var(--nc-tile-bevel);
  }
  .nc-service-icon.cyan {
    background: color-mix(in srgb, var(--nc-accent2) 9%, var(--nc-bg-card));
    border-color: color-mix(in oklch, var(--nc-accent2) 26%, transparent);
  }
}
