/* NovaCraft Data Services usability audit 2026-11-14.
   Keeps original portfolio layout, data, routes and modal behaviors intact. */
:root{
  --ds-ink-ui:#172338;--ds-sub-ui:#576781;--ds-soft-ui:#7b879e;--ds-accent-ui:#075fd6;
  --ds-radius-s:8px;--ds-radius-m:12px;--ds-radius-l:16px;
  --ds-radius-xl:24px;--ds-radius-xxl:24px;--ds-radius-pill:999px;
  --ds-type-xs:12px;--ds-type-sm:13px;--ds-type-body:14px;--ds-type-lg:16px;
}
:root[data-theme=dark]{--ds-ink-ui:#edf5ff;--ds-sub-ui:#c6d4e9;--ds-soft-ui:#a4b7d2;--ds-accent-ui:#8ebdff}
/* 1: five interaction roles: primary, secondary, text, filters, icon. */
.nav-cta,.button-primary,.inquiry-submit{min-height:44px;border-radius:var(--ds-radius-m);font-size:var(--ds-type-body);font-weight:750}
.button-secondary,.button-outline,.case-all-projects a{min-height:44px;border-radius:var(--ds-radius-m);font-size:var(--ds-type-body);font-weight:750}
.filter-button{min-height:42px;border-radius:var(--ds-radius-pill);font-size:var(--ds-type-sm);font-weight:650}
.project-open,.icon-button{display:inline-grid;place-items:center;width:44px;height:44px;min-width:44px;min-height:44px;
  border-radius:var(--ds-radius-m);background:var(--surface);border:1px solid var(--border-strong);color:var(--ds-accent-ui)}
.project-open:hover,.icon-button:hover{background:var(--paper)}
.project-open svg{display:block;width:19px;height:19px;stroke:currentColor;fill:none}
/* 2: project detail button now contains a standard info icon, not edit/external-link arrow. */
.project-open{cursor:pointer}
/* 3: a reusable type scale for interactive UI, helper text and portfolio copy. */
body,.hero-summary,.section-heading>p,.about-text p:not(.overline),.contact-left>p:not(.overline),
.project-body>p,.service-card p,.process-grid p{font-size:var(--ds-type-body);line-height:1.65}
.hero-caption,.hero-caption span,.visual-disclaimer,.project-foot,.project-category,.form-heading,
.metrics-section .metric span,.window-toolbar,.hero .kpi small,.hero .kpi span,
.contact-right label,.footer-links a,.project-card .sheet-top{font-size:var(--ds-type-xs);line-height:1.45}
.overline,.eyebrow,.filter-button,.workbook-tag{font-size:var(--ds-type-xs)}
.project-body h3{font-size:24px;line-height:1.25}
.section-heading h2,.about-text h2{font-size:clamp(36px,4.2vw,58px)}
.hero h1{font-size:clamp(54px,6vw,88px)}
/* 4: semantic text palette, preserving meaningful chart series color and decorative gradients. */
.section-heading h2,.project-body h3,.service-card h3,.about-text h2,.info-page h1,.process-grid h3{color:var(--ds-ink-ui)}
.project-body>p,.service-card p,.about-text p,.section-heading>p,.process-grid p,.contact-right label{color:var(--ds-sub-ui)}
.project-category,.overline,.section-label{color:var(--ds-soft-ui)}
.case-all-projects a,.case-card-link,.footer-links a{color:var(--ds-accent-ui)}
/* 5: deliberate radius set — cards, containers, pills, controls, art. */
.nav-shell,.project-card,.service-card,.contact-right,.info-page article{border-radius:var(--ds-radius-xl)}
.project-visual,.about-art,.contact-panel{border-radius:var(--ds-radius-xxl)}
.project-open,.button,.filter-button,.nav-cta,.inquiry-submit,.contact-right :is(input,select,textarea),
.case-all-projects a{border-radius:var(--ds-radius-m)}
.filter-button,.project-category span{border-radius:var(--ds-radius-pill)}
/* 6: brand is only top-of-portfolio link in header. Main site link remains in footer. */
.brand{flex-shrink:0}
/* 7: all-eight action appears immediately after grid, not detached between filter and content. */
.case-all-projects{display:flex;justify-content:flex-start;align-items:center;margin:24px 0 4px;gap:10px}
.case-all-projects a{display:inline-flex;align-items:center;padding:11px 19px;min-height:44px;
  background:var(--surface);border:1px solid var(--border-strong);text-decoration:none}
.case-all-projects a:hover{text-decoration:underline}
/* Accessibility, mobile, and contrast. */
.project-open:focus-visible,.filter-button:focus-visible,.case-all-projects a:focus-visible{outline:3px solid #4d94ed;outline-offset:3px}
@media(max-width:650px){
 .hero h1{font-size:clamp(43px,10vw,58px)}
 .project-body>p,.service-card p,.contact-left>p:not(.overline){font-size:14px}
 .filter-button{min-height:44px;font-size:14px}
 .case-all-projects a{width:100%;justify-content:center}
 .nav-shell{border-radius:var(--ds-radius-l)}
}

/* 2026-11-14 mobile header: stop the contact CTA from wrapping into a tall tile.
   Preserves a 44px tap target and the same desktop presentation. */
@media (max-width:650px){
  .site-header .nav-shell{gap:4px}
  .site-header .nav-actions{flex:0 0 auto;gap:4px}
  .site-header .nav-cta{
    flex:0 0 auto;
    width:auto;
    height:44px;
    min-height:44px;
    max-height:44px;
    padding:0 10px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    font-size:12px;
    line-height:1.1;
    white-space:nowrap;
    text-align:center;
  }
  .site-header .nav-cta span[aria-hidden]{display:none}
  .site-header .brand{flex:1 1 auto;min-width:0}
}
@media (max-width:380px){
  .site-header .brand-small{display:none}
  .site-header .brand-wordmark{font-size:14px}
}
@media (max-width:340px){
  /* On very narrow devices retain the accessible brand link without clipping text. */
  .site-header .brand-wordmark{display:none}
}

/* 2026-11-18: reliable mobile dropdown, accessible contrast and tap targets. */
@media(max-width:930px){
  .site-header{z-index:950;isolation:isolate}
  .site-header .nav-shell{position:relative;overflow:visible}
  .site-header .nav-links{position:absolute;top:calc(100% + 9px);left:0;right:0;
    z-index:50;max-height:calc(100dvh - 110px);overflow-y:auto;overscroll-behavior:contain;
    background:var(--surface);border:1px solid var(--border-strong);
    border-radius:16px;padding:9px;box-shadow:0 18px 48px rgba(15,34,73,.23);
    -webkit-backdrop-filter:blur(22px);backdrop-filter:blur(22px)}
  .site-header .nav-links.is-open{display:flex!important;visibility:visible;opacity:1;pointer-events:auto}
  .site-header .nav-links a{display:flex;align-items:center;min-height:46px;padding:11px 14px;
    border-radius:10px;font-size:15px;color:var(--ink);font-weight:680}
  .site-header .nav-links a:hover,.site-header .nav-links a:focus-visible{background:var(--muted-bg)}
  .site-header .menu-button[aria-expanded=true]{background:var(--muted-bg);border-color:var(--accent)}
}
/* Clear 14px+ paragraph and form text, even on mobile. */
body,.project-body>p,.service-card p,.process-grid p,.contact-left>p:not(.overline),
.contact-right :is(input,select,textarea),.form-fallback,.form-hint{font-size:clamp(14px,1.1vw,16px);line-height:1.65}
.contact-methods a{min-height:56px}
.contact-methods a:focus-visible,.form-fallback a:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
html{scroll-padding-top:108px}

.copy-email-action{min-height:42px;border:1px solid var(--border-strong);border-radius:12px;
  padding:8px 12px;background:var(--surface);color:var(--accent);font-size:14px;font-weight:700;line-height:1.2;cursor:pointer}
.copy-email-action:hover{background:var(--muted-bg)}
/* Keep the expanded menu fully opaque; marketing headlines must not bleed through. */
@media(max-width:930px){
  .site-header .nav-links{background:#fbfdff!important;box-shadow:0 22px 55px rgba(14,39,80,.25)!important}
  :root[data-theme="dark"] .site-header .nav-links{background:#0c2350!important}
}

/* Native mobile menu — self-contained and functional even if script.js fails. */
.nova-mobile-nav{display:none;position:relative;z-index:600}
.nova-mobile-nav > summary{list-style:none;cursor:pointer;user-select:none}
.nova-mobile-nav > summary::-webkit-details-marker{display:none}
.nova-mobile-nav > summary::marker{content:''}
.nova-mobile-nav-panel{display:none}
.visually-hidden{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:930px){
  .site-header{z-index:1000}
  .site-header .nav-shell{position:relative;overflow:visible}
  .site-header .nav-links{display:none!important}
  .site-header .nova-mobile-nav{display:block}
  .site-header .nova-mobile-nav > summary{display:grid;place-items:center;width:44px;height:44px;min-height:44px;min-width:44px}
  .site-header .nova-mobile-nav[open] > summary{background:var(--muted-bg);border-color:var(--accent)}
  .site-header .nova-mobile-nav[open] .nova-mobile-nav-panel{
    display:flex;position:absolute;right:0;top:calc(100% + 13px);z-index:1010;
    width:min(304px, calc(100vw - 34px));max-height:min(72vh,540px);overflow:auto;
    flex-direction:column;gap:3px;padding:10px;
    border:1px solid var(--border-strong);border-radius:18px;
    background:#fbfdff;color:#172338;box-shadow:0 24px 60px rgba(6,21,50,.27);
  }
  .site-header .nova-mobile-nav-panel a{display:flex;align-items:center;min-height:46px;padding:12px 14px;border-radius:12px;
    color:#1c3759;text-decoration:none;font-weight:650;font-size:15px;line-height:1.3}
  .site-header .nova-mobile-nav-panel a:hover,.site-header .nova-mobile-nav-panel a:focus-visible{background:#e9f2ff;color:#0c52b7}
  .site-header .nova-mobile-nav > summary:focus-visible,.site-header .nova-mobile-nav-panel a:focus-visible{outline:3px solid #60a5fa;outline-offset:2px}
  :root[data-theme="dark"] .site-header .nova-mobile-nav[open] .nova-mobile-nav-panel{background:#0d2343;border-color:#52749d}
  :root[data-theme="dark"] .site-header .nova-mobile-nav-panel a{color:#ebf3ff}
  :root[data-theme="dark"] .site-header .nova-mobile-nav-panel a:is(:hover,:focus-visible){background:#20416b;color:#fff}
}
