/* ===== Global cross-cutting rules =====
   Formerly inlined at the top of site-header.css (originally /css/site.css).
   Extracted into its own stylesheet and linked from _Layout.cshtml so it
   keeps applying across every template, independent of the header markup. ===== */

/* Border-box sizing. The design source opens with this exact reset
   (package/styles.css:21) and every page stylesheet ported from it was authored
   assuming it. Without it, `min-height` applies to the content box and padding is
   added on top — so the heroes that declare `min-height: 780px; padding: 158px 0
   112px` (Case Studies, Software, Services) each rendered ~274px taller than
   designed, pushing their content far down the viewport. Declared here so it
   reaches every template. */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Base typography. This belongs here, not in a page stylesheet: only home.css,
   footer.css and contact.css ever set a body font-family, so every template
   without one of those in scope inherited the browser default and rendered its
   body copy in Times New Roman — visible on /software/ and the Services page,
   whose headings use --font-display but whose card copy did not. Declared once
   on the stylesheet every template links, so a new page is correct by default.
   Page stylesheets load after this one and still override it where they need to. */
body {
    font-family: var(--font-body);
    color: var(--fg);
    /* Same reasoning as the font: without a body background, any template that
       does not link home.css fell through to the UA default white, so dark mode
       showed white bands wherever a section did not paint its own surface. */
    background: var(--surface);
    /* And the same again for the UA's default 8px body margin, which only
       home.css zeroed — it showed as a white border framing all four edges of
       the Services and Software pages, most obviously against their dark heroes. */
    margin: 0;
}

/* Custom cursor — site-wide, brand green; only on fine+hover pointers.
   Text fields keep the native I-beam (intentionally excluded). 
@media (hover: hover) and (pointer: fine) {
    body {
        cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><circle cx="12" cy="12" r="8" fill="%232E7D32" opacity="0.3"/><circle cx="12" cy="12" r="3" fill="%232E7D32"/></svg>') 12 12, auto;
    }
    a, button, [role="button"], input[type="submit"], input[type="button"],
    label[for], summary, .btn-primary, .btn-secondary, .nav-cta, .gb-contact-cta,
    .gb-contact-modal-close, .search-toggle, .theme-toggle, .mobile-toggle, .social-float a {
        cursor: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><circle cx="12" cy="12" r="10" fill="%232E7D32" opacity="0.5"/><circle cx="12" cy="12" r="4" fill="%232E7D32"/></svg>') 12 12, pointer;
    }
}*/

/* Dark-mode accent contrast (WCAG AA): re-tint green TEXT/icon tokens; keep
   solid green CTAs/icons on the deep gradient so white labels stay readable. */
body.dark-mode {
    --green: #5BD15F;
    --green-2: #7FE3A0;
    --orange: #5BD15F;
    --orange2: #7FE3A0;
}
body.dark-mode .btn-primary,
body.dark-mode .nav-cta,
body.dark-mode .service-icon,
body.dark-mode .security-point-index,
body.dark-mode .cs-hero-btn,
body.dark-mode .btn-apply,
body.dark-mode .leader-linkedin:hover {
    background: linear-gradient(135deg, #2E7D32, #43A047);
}

/* Floating social bar yields to the open mobile nav */
body.nav-open .social-float { display: none !important; }

/* WCAG 2.5.5/2.5.8 minimum touch targets for icon-only controls */
.search-toggle,
.theme-toggle,
.mobile-toggle {
    min-width: 44px;
    min-height: 44px;
}
