/* ==========================================================================
   Insight Nova Solutions — design system
   Hand-written CSS. No framework, no build step.
   Edit tokens in :root to restyle the whole site.
   ========================================================================== */

:root {
  /* Brand */
  --indigo:        #4f46e5;
  --indigo-dark:   #4338ca;
  --indigo-soft:   #eef2ff;
  --fuchsia:       #c026d3;

  /* Neutrals */
  --slate-950:     #020617;
  --slate-900:     #0f172a;
  --slate-800:     #1e293b;
  --slate-700:     #334155;
  --slate-600:     #475569;
  --slate-500:     #64748b;
  --slate-300:     #cbd5e1;
  --slate-200:     #e2e8f0;
  --slate-100:     #f1f5f9;
  --slate-50:      #f8fafc;
  --white:         #ffffff;

  --emerald:       #059669;
  --red:           #dc2626;

  /* Semantic */
  --bg:            var(--slate-50);
  --text:          var(--slate-900);
  --text-muted:    var(--slate-600);
  --border:        var(--slate-200);
  --card:          var(--white);

  /* Type — 16px base, 1.5 line-height */
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, "Noto Sans", sans-serif;

  --step-0:  1rem;        /* 16px body */
  --step-1:  1.125rem;    /* 18px lead */
  --step-2:  1.5rem;      /* 24px h3   */
  --step-3:  2rem;        /* 32px h2   */
  --step-4:  2.75rem;     /* 44px h1   */
  --step-5:  3.5rem;      /* 56px hero */

  /* Spacing */
  --space-1: 0.5rem;
  --space-2: 0.75rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2rem;
  --space-6: 3rem;
  --space-7: 4rem;
  --space-8: 6rem;

  --radius:    1rem;
  --radius-lg: 1.5rem;
  --radius-xl: 1.75rem;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, .06);
  --shadow:    0 4px 16px rgba(15, 23, 42, .07);
  --shadow-lg: 0 18px 48px rgba(15, 23, 42, .14);

  --container: 1200px;
  --transition: 200ms cubic-bezier(.4, 0, .2, 1);
}

/* --------------------------------------------------------------- reset -- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { line-height: 1.15; margin: 0; letter-spacing: -.02em; font-weight: 800; }
p  { margin: 0; }
ul { margin: 0; padding: 0; }

/* Visible focus on every interactive control (WCAG 2.4.7) */
:focus-visible {
  outline: 3px solid var(--indigo);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ----------------------------------------------------------- utilities -- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--space-3);
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: var(--space-3); top: -100px; z-index: 100;
  background: var(--slate-900); color: var(--white);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius); font-weight: 700; text-decoration: none;
  transition: top var(--transition);
}
.skip-link:focus { top: var(--space-3); }

.eyebrow {
  font-size: .8125rem; font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; color: var(--indigo); margin-bottom: var(--space-2);
}
.eyebrow--light { color: rgba(255,255,255,.72); }

.lead { font-size: var(--step-1); color: var(--text-muted); line-height: 1.7; }
.lead--light { color: rgba(255,255,255,.82); }

.text-center { text-align: center; }
.gradient-text {
  background: linear-gradient(120deg, #a5b4fc, #f0abfc);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ------------------------------------------------------------- buttons -- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 48px;                 /* 44px+ touch target */
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius);
  font-weight: 700; font-size: var(--step-0);
  text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition), transform var(--transition),
              box-shadow var(--transition);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn--primary { background: var(--indigo); color: var(--white); box-shadow: var(--shadow-sm); }
.btn--primary:hover { background: var(--indigo-dark); box-shadow: var(--shadow); }

.btn--dark { background: var(--slate-900); color: var(--white); }
.btn--dark:hover { background: var(--slate-800); }

.btn--light { background: var(--white); color: var(--slate-950); box-shadow: var(--shadow-sm); }
.btn--light:hover { background: var(--slate-100); }

.btn--ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,.28); }
.btn--ghost:hover { background: rgba(255,255,255,.12); }

.btn--outline { background: var(--white); color: var(--slate-900); border-color: var(--border); }
.btn--outline:hover { border-color: var(--slate-300); background: var(--slate-50); }

/* -------------------------------------------------------------- header -- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-3); min-height: 72px;
}

.brand {
  display: inline-flex; align-items: center; gap: .625rem;
  font-weight: 900; font-size: 1.0625rem; text-decoration: none;
  letter-spacing: -.02em; color: var(--slate-900);
}
.brand__mark {
  width: 40px; height: 40px; flex: none;
  display: grid; place-items: center;
  border-radius: 13px; color: var(--white); font-size: .875rem; font-weight: 900;
  background: linear-gradient(135deg, var(--indigo), var(--fuchsia));
  box-shadow: var(--shadow-sm);
}

.nav { display: none; align-items: center; gap: var(--space-4); }
.nav a { font-weight: 600; text-decoration: none; font-size: .9375rem; }
.nav a:not(.btn) { color: var(--slate-700); transition: color var(--transition); }
.nav a:not(.btn):hover { color: var(--indigo); }
.nav a[aria-current="page"] { color: var(--indigo); }

.nav-toggle {
  display: inline-grid; place-items: center;
  width: 46px; height: 46px; flex: none;
  background: var(--white); border: 1px solid var(--border);
  border-radius: 12px; cursor: pointer; color: var(--slate-900);
}
.nav-toggle:hover { background: var(--slate-50); }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }
.nav-toggle[aria-expanded="true"] .icon-open  { display: none; }

.mobile-nav {
  display: none; border-top: 1px solid var(--border); background: var(--white);
}
.mobile-nav.is-open { display: block; }
.mobile-nav ul { list-style: none; padding: var(--space-2) 0 var(--space-4); }
.mobile-nav a {
  display: block; padding: var(--space-2) 0;
  font-weight: 600; text-decoration: none; color: var(--slate-700);
}
.mobile-nav a[aria-current="page"] { color: var(--indigo); }
.mobile-nav .btn { width: 100%; margin-top: var(--space-2); }

/* ------------------------------------------------------------ sections -- */
main { display: block; }
.section { padding-block: var(--space-7); }
.section--tight { padding-block: var(--space-6); }

.section-head { max-width: 46rem; margin-bottom: var(--space-5); }
.section-head h2 { font-size: var(--step-3); }
.section-head p  { margin-top: var(--space-2); }

.split-head {
  display: flex; flex-wrap: wrap; align-items: flex-end;
  justify-content: space-between; gap: var(--space-4);
  margin-bottom: var(--space-5);
}

/* ---------------------------------------------------------------- hero -- */
.hero {
  position: relative; overflow: hidden;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, #1e1b4b 0%, var(--slate-900) 45%, #3b0764 100%);
  color: var(--white);
  padding: var(--space-6) var(--space-4);
  margin-top: var(--space-5);
}
.hero::after {           /* subtle film grain, matches the old design */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  opacity: .22; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.12'/%3E%3C/svg%3E");
}
.hero > * { position: relative; z-index: 1; }

.hero__grid { display: grid; gap: var(--space-6); align-items: center; }
.hero h1 { font-size: var(--step-4); font-weight: 900; }
.hero .lead { margin-top: var(--space-3); max-width: 34rem; }

.pill {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.16);
  padding: .5rem 1rem; border-radius: var(--radius-pill);
  font-size: .8125rem; font-weight: 600; color: rgba(255,255,255,.9);
}
.pill__dot { width: 8px; height: 8px; border-radius: 50%; background: #34d399; flex: none; }

.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-5); }

.hero__stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-3);
  margin-top: var(--space-6); padding-top: var(--space-5);
  border-top: 1px solid rgba(255,255,255,.14);
}
.hero__stats dt { font-size: .8125rem; color: rgba(255,255,255,.65); font-weight: 600; }
.hero__stats dd { margin: .25rem 0 0; font-size: var(--step-2); font-weight: 900; }

/* Dashboard mock panel */
.panel {
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.14);
  border-radius: var(--radius-lg); padding: var(--space-4);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.panel__head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-3); }
.panel__title { font-weight: 800; font-size: var(--step-1); }
.panel__sub { font-size: .8125rem; color: rgba(255,255,255,.65); margin-top: .25rem; }
.badge {
  background: rgba(16,185,129,.18); color: #6ee7b7; border: 1px solid rgba(16,185,129,.3);
  font-size: .75rem; font-weight: 700; padding: .3rem .7rem; border-radius: var(--radius-pill);
  white-space: nowrap;
}
.metric-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); margin-top: var(--space-4); }
.metric {
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius); padding: var(--space-3);
}
.metric dt { font-size: .75rem; color: rgba(255,255,255,.62); font-weight: 600; }
.metric dd { margin: .25rem 0 0; font-size: var(--step-1); font-weight: 800; }
.meter { height: 6px; border-radius: 99px; background: rgba(255,255,255,.14); margin-top: .625rem; overflow: hidden; }
.meter > span { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--indigo), var(--fuchsia)); }
.meter--good > span { background: linear-gradient(90deg, #10b981, #34d399); }

.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: var(--space-3); }
.chip {
  font-size: .75rem; font-weight: 600; padding: .35rem .7rem;
  border-radius: var(--radius-pill);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12);
  color: rgba(255,255,255,.82);
}
.chip--solid { background: var(--slate-100); border-color: var(--border); color: var(--slate-700); }

/* --------------------------------------------------------------- cards -- */
.grid { display: grid; gap: var(--space-4); }
.grid--2 { grid-template-columns: 1fr; }
.grid--3 { grid-template-columns: 1fr; }
.grid--4 { grid-template-columns: 1fr 1fr; }

.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: var(--space-4);
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}
.card--link { text-decoration: none; display: block; color: inherit; }
.card--link:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); border-color: var(--slate-300); }
.card h3 { font-size: var(--step-2); }
.card p  { color: var(--text-muted); margin-top: var(--space-2); }

.card__icon {
  width: 48px; height: 48px; flex: none; display: grid; place-items: center;
  border-radius: 14px; background: var(--indigo-soft); color: var(--indigo);
  margin-bottom: var(--space-3);
}
.card__more { display: inline-flex; align-items: center; gap: .35rem; margin-top: var(--space-3); color: var(--indigo); font-weight: 700; }

.card--dark { background: var(--slate-900); color: var(--white); border-color: transparent; }
.card--dark p { color: rgba(255,255,255,.78); }

/* Numbered process steps */
.steps { counter-reset: step; list-style: none; }
.step { position: relative; padding-left: 3.25rem; }
.step::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 2.25rem; height: 2.25rem; display: grid; place-items: center;
  border-radius: 12px; font-weight: 900; font-size: .875rem;
  background: var(--slate-900); color: var(--white);
}
.step h3 { font-size: var(--step-1); }
.step p  { margin-top: .25rem; font-size: .9375rem; }

/* Checklist */
.checklist { list-style: none; display: grid; gap: var(--space-2); }
.checklist li { display: flex; gap: .625rem; align-items: flex-start; }
.checklist svg { flex: none; margin-top: .2rem; color: var(--emerald); }

/* CTA banner */
.cta {
  border-radius: var(--radius-xl); padding: var(--space-6) var(--space-4);
  background: linear-gradient(120deg, var(--indigo), var(--fuchsia));
  color: var(--white);
  display: flex; flex-wrap: wrap; align-items: center;
  justify-content: space-between; gap: var(--space-4);
}
.cta h2 { font-size: var(--step-3); }
.cta p  { color: rgba(255,255,255,.88); margin-top: var(--space-2); }

/* Page header for interior pages */
.page-head {
  border-radius: var(--radius-xl); background: var(--slate-900); color: var(--white);
  padding: var(--space-6) var(--space-4); margin-top: var(--space-5);
  position: relative; overflow: hidden;
}
.page-head h1 { font-size: var(--step-3); }
.page-head .lead { margin-top: var(--space-3); max-width: 42rem; }

/* Breadcrumb */
.breadcrumb { font-size: .875rem; color: var(--text-muted); margin-bottom: var(--space-3); }
.breadcrumb a { color: var(--indigo); font-weight: 600; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* Prose block for service detail body copy */
.prose h2 { font-size: var(--step-2); margin-top: var(--space-5); }
.prose h3 { font-size: var(--step-1); margin-top: var(--space-4); }
.prose p  { margin-top: var(--space-2); color: var(--text-muted); }
.prose ul { margin-top: var(--space-2); padding-left: 1.15rem; color: var(--text-muted); }
.prose li { margin-top: .35rem; }

/* --------------------------------------------------------------- forms -- */
.field { display: block; margin-bottom: var(--space-3); }
.field > span { display: block; font-weight: 700; font-size: .875rem; margin-bottom: .4rem; }
.req { color: var(--red); }

.input, .textarea {
  width: 100%; font: inherit; color: var(--text);
  padding: .75rem .875rem; min-height: 48px;
  background: var(--white);
  border: 1px solid var(--slate-300); border-radius: var(--radius);
  transition: border-color var(--transition), box-shadow var(--transition);
}
.input:hover, .textarea:hover { border-color: var(--slate-500); }
.input:focus, .textarea:focus {
  outline: none; border-color: var(--indigo);
  box-shadow: 0 0 0 3px rgba(79,70,229,.18);
}
.textarea { min-height: 150px; resize: vertical; }
.hint { font-size: .8125rem; color: var(--slate-500); margin-top: .35rem; }

.form-status {
  border-radius: var(--radius); padding: var(--space-3);
  font-weight: 600; margin-bottom: var(--space-4);
}
.form-status--ok   { background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46; }
.form-status--err  { background: #fef2f2; border: 1px solid #fecaca; color: #991b1b; }
.is-hidden { display: none; }

/* -------------------------------------------------------------- footer -- */
.site-footer { background: var(--slate-950); color: var(--slate-300); margin-top: var(--space-8); }
.footer-grid { display: grid; gap: var(--space-5); padding-block: var(--space-7); }
.site-footer h2, .site-footer h3 { color: var(--white); }
.site-footer h3 { font-size: .9375rem; margin-bottom: var(--space-3); }
.footer-brand { color: var(--white); font-weight: 900; font-size: var(--step-1); }
.site-footer p { color: var(--slate-300); margin-top: var(--space-3); max-width: 34rem; font-size: .9375rem; }
.footer-links { list-style: none; display: grid; gap: .625rem; font-size: .9375rem; }
.footer-links a { color: var(--slate-300); text-decoration: none; transition: color var(--transition); }
.footer-links a:hover { color: var(--white); }
.footer-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-4); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-block: var(--space-3); text-align: center;
  font-size: .8125rem; color: var(--slate-500);
}

/* --------------------------------------------------- scroll reveal ------
   Hidden state is scoped to .js (set by an inline script in <head>). With
   JavaScript disabled or broken the content simply renders, rather than
   staying invisible forever. */
.js .reveal { opacity: 0; transform: translateY(18px); }
.js .reveal.is-visible {
  opacity: 1; transform: none;
  transition: opacity .6s ease-out, transform .6s cubic-bezier(.22,.61,.36,1);
}

/* ---------------------------------------------------------- responsive -- */
@media (min-width: 640px) {
  .grid--2 { grid-template-columns: 1fr 1fr; }
  .hero__actions .btn { min-width: 190px; }
}

@media (min-width: 860px) {
  :root { --step-3: 2.25rem; --step-4: 3.25rem; }
  .container { padding-inline: var(--space-4); }
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
  .hero, .page-head { padding: var(--space-7) var(--space-6); }
  .footer-grid { grid-template-columns: 2fr 1fr 1fr; gap: var(--space-6); }
  .section { padding-block: 4.5rem; }
}

@media (min-width: 1024px) {
  .nav { display: flex; }
  .nav-toggle, .mobile-nav { display: none !important; }
  .hero__grid { grid-template-columns: 1.05fr .95fr; }
  .hero h1 { font-size: var(--step-5); }
  .split-cols { display: grid; grid-template-columns: 1.6fr 1fr; gap: var(--space-6); align-items: start; }
  .sticky-aside { position: sticky; top: 96px; }
}

/* Honour motion preferences — no parallax, no reveal, final state rendered */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .btn:hover, .card--link:hover { transform: none; }
}
