/* Optimal Connections — site styles. Self-hosted assets only; no third-party
   requests. Deliberately unrelated to the fluentic.dev palette: the two are
   separate businesses and must not read as one brand. */

/* ---------- Self-hosted Inter (variable) ---------- */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/inter-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('../fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
/* Palette: cool navy ground, solver blue for the one action that matters,
   emerald for structural marks only. Every pair below was measured, not
   eyeballed; the ratio in each comment is the computed WCAG value. */
:root {
  --ink:        #0c1420;   /* navy-black ground */
  --ink-soft:   #111c2b;
  --paper:      #fbfcfe;   /* cool off-white */
  --paper-alt:  #eff3f9;   /* cool mist */
  --body:       #3f4a5a;   /* 8.75:1 on --paper, 8.06:1 on --paper-alt */
  --body-dark:  #b6c3d4;   /* 10.33:1 on --ink, 9.59:1 on --ink-soft */
  --line:       #dce3ee;
  --line-dark:  #1c283a;

  /* Solver blue — the primary action, and nothing else. */
  --accent:     #1a4fc4;   /* 7.10:1 with #fff text, 6.91:1 on --paper */
  --accent-hov: #16429f;   /* 9.08:1 with #fff */
  --accent-lt:  #7aa2ff;   /* 7.43:1 on --ink — dark-surface text and focus ring */
  --accent-ink: #ffffff;

  /* Emerald — structural marks. The deep value is for light surfaces; the
     lighter pair keeps the header button's own boundary perceivable against
     the bar (WCAG 2.2 SC 1.4.11 wants 3:1 for non-text). */
  --secondary:      #0d7a5f;  /* 5.16:1 on --paper */
  --secondary-dk:   #127a68;  /* on --ink: 3.53:1 vs bar, 5.24:1 with #fff */
  --secondary-hov:  #0f6b5b;  /* 6.41:1 with #fff */
  --secondary-edge: #2fb99a;  /* 7.50:1 vs --ink — carries the boundary */

  --bs-body-font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
  font-family: var(--bs-body-font-family);
  color: var(--body);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { color: var(--ink); letter-spacing: -0.022em; font-weight: 800; line-height: 1.12; }
p { line-height: 1.65; }

/* ---------- Accessibility ---------- */
.skip-link {
  position: absolute; left: 0; top: 0; z-index: 1080;
  transform: translateY(-120%);
  background: var(--ink); color: #fff;
  padding: .75rem 1.25rem; border-radius: 0 0 .5rem 0; font-weight: 600;
}
.skip-link:focus { transform: translateY(0); }

/* The ring must clear 3:1 against the surface it lands on. --accent is 6.91:1
   on --paper and 6.37:1 on --paper-alt but only 2.60:1 on --ink; --accent-lt
   is 7.43:1 on --ink. The two swap per surface. */
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}
.on-dark :focus-visible,
.site-header :focus-visible,
.site-footer :focus-visible,
.skip-link:focus-visible {
  outline-color: var(--accent-lt);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* ---------- Header ---------- */
.site-header {
  background: var(--ink);
  border-bottom: 1px solid var(--line-dark);
}
.wordmark {
  font-weight: 800; font-size: 1.0625rem; letter-spacing: -0.02em;
  color: #fff; text-decoration: none; white-space: nowrap;
}
.wordmark .dot { color: var(--accent-lt); }

/* ---------- Buttons ---------- */
.btn-cta {
  background: var(--accent);
  color: var(--accent-ink);
  border: 1px solid var(--accent);
  font-weight: 600;
  padding: .875rem 1.75rem;
  border-radius: .5rem;
  text-decoration: none;
  display: inline-block;
  transition: background-color .18s ease, transform .18s ease;
}
.btn-cta:hover, .btn-cta:focus { background: var(--accent-hov); border-color: var(--accent-hov); color: var(--accent-ink); transform: translateY(-1px); }
.btn-cta--sm { padding: .55rem 1.15rem; font-size: .9375rem; }

/* Secondary-voice button, used only in the header. A solid --secondary fill
   would reach just 2.2:1 against the bar, so --secondary-edge supplies the
   perceivable boundary and the fill is free to darken on hover. */
.btn-cta--alt { background: var(--secondary-dk); border-color: var(--secondary-edge); }
.btn-cta--alt:hover, .btn-cta--alt:focus { background: var(--secondary-hov); border-color: var(--secondary-edge); }
/* --accent-lt is only 2.4:1 on the emerald fill. The 3px offset puts the ring
   on --ink in practice, but white holds at 5.24:1 against the fill and 18.9:1
   against the bar, so it is correct wherever it lands. */
.btn-cta--alt:focus-visible { outline-color: #ffffff; }

/* Secondary action: deliberately quieter than the primary CTA. */
.link-quiet {
  color: var(--body); font-weight: 500;
  text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px;
}
.link-quiet:hover, .link-quiet:focus { color: var(--ink); }
.on-dark .link-quiet { color: var(--body-dark); }
.on-dark .link-quiet:hover, .on-dark .link-quiet:focus { color: #fff; }

/* ---------- Hero ---------- */
/* The dot grid reads as stops on a map. It is a CSS gradient, so it costs no
   request and no layout work. */
.hero {
  background:
    radial-gradient(circle at 1px 1px, rgba(122,162,255,.16) 1px, transparent 0) 0 0 / 26px 26px,
    radial-gradient(1100px 520px at 12% -12%, rgba(122,162,255,.14), transparent 62%),
    var(--ink);
  color: var(--body-dark);
  padding: clamp(2.5rem, 8vw, 6.5rem) 0 clamp(3rem, 8vw, 6rem);
}
.hero h1 {
  color: #fff;
  font-size: clamp(2.125rem, 6vw, 3.875rem);
  max-width: 17ch;
}
.hero h1 .muted { color: var(--accent-lt); display: block; }
.hero-sub {
  font-size: clamp(1.125rem, 2.4vw, 1.4375rem);
  font-weight: 600;
  color: #fff;
  max-width: 44ch;
  line-height: 1.35;
}
.hero-lead {
  font-size: clamp(1rem, 1.9vw, 1.125rem);
  max-width: 62ch;
  color: var(--body-dark);
}
.eyebrow {
  text-transform: uppercase; letter-spacing: .12em;
  font-size: .75rem; font-weight: 600; color: var(--accent-lt);
}

/* ---------- Sections ---------- */
.section { padding: clamp(3.25rem, 7.5vw, 5.5rem) 0; }
.section--alt { background: var(--paper-alt); border-block: 1px solid var(--line); }
.section h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); max-width: 22ch; }
.section-lead { font-size: 1.0625rem; max-width: 62ch; }

/* ---------- Pillar cards ---------- */
.card-service {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: .875rem;
  padding: 1.75rem;
  height: 100%;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.card-service:hover { border-color: #c3cfe2; box-shadow: 0 12px 32px -18px rgba(12,20,32,.45); }
.card-service h3 { font-size: 1.1875rem; margin-bottom: .625rem; }
.card-service p { font-size: .96875rem; margin-bottom: 0; }
.card-num {
  font-size: .75rem; font-weight: 700; letter-spacing: .1em;
  color: var(--secondary); margin-bottom: .875rem;
}

/* ---------- About ---------- */
.about-grid {
  display: flex; flex-wrap: wrap; align-items: flex-start;
  gap: clamp(1.5rem, 4vw, 2.75rem);
}
.about-portrait {
  flex: none;
  width: clamp(132px, 18vw, 180px);
  height: auto;
  border-radius: .875rem;
  border: 1px solid var(--line);
}
.about-body {
  flex: 1 1 min(100%, 32ch);
  display: flex; flex-direction: column; gap: .75rem;
  max-width: 58ch;
}
.about-name { font-size: 1.375rem; margin: 0; }
.about-role { font-weight: 600; color: var(--ink); }
.about-body p { margin: 0; }

/* ---------- Closing CTA ---------- */
.cta-band { background: var(--ink-soft); color: var(--body-dark); }
.cta-band h2 { color: #fff; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--body-dark);
  font-size: .9375rem;
  padding: 2.75rem 0 2.25rem;
}
.site-footer a { color: #fff; }
