/* Nunito Sans (variable, latin + latin-ext) — self-hosted.
   Closest freely-licensed match to Avenir. Self-hosted rather than pulled from
   Google Fonts so no visitor IP is sent to a third party, which would otherwise
   contradict the privacy policy. */
@font-face {
  font-family: 'Nunito Sans';
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
  src: url('/assets/fonts/nunito-sans-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: 'Nunito Sans';
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
  src: url('/assets/fonts/nunito-sans-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;
}

/* Evidentia Med — site styles */

:root {
  /* Palette derived from the EvidentiaMed logo:
     #133455 navy (wordmark "Evidentia" + hexagon outline)
     #297D99 teal (wordmark "Med")
     #1D659B blue (hexagon badge)
     #B2D2E3 pale blue (hexagon fill) */
  --ink:        #16304d;   /* deep navy — headings and body text */
  --ink-soft:   #5b6b7d;
  --accent:     #297d99;   /* teal — links, buttons, rules */
  --accent-dk:  #1f6178;
  --hl:         #b2d2e3;   /* pale blue — highlights on dark bands */
  --hl-dark:    #297d99;   /* teal — highlights on light backgrounds */
  --line:       #dde5ec;
  --bg:         #ffffff;
  --bg-alt:     #f2f7fa;   /* pale blue tint */
  --bg-dark:    #133455;   /* navy — hero and dark bands */
  --max:        1120px;
  --font: "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.25; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-size: 3.1rem; font-weight: 800; letter-spacing: -0.03em; }
h2 { font-size: 2.1rem; font-weight: 800; }
h3 { font-size: 1.15rem; font-weight: 700; }
p  { margin: 0 0 1.1em; }

/* ---------- header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  position: sticky; top: 0; z-index: 50;
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 76px; gap: 24px;
}
.brand { display: flex; align-items: center; flex-shrink: 0; }
.brand:hover { text-decoration: none; }
.brand img {
  height: 54px; width: auto; display: block;
}
@media (max-width: 860px) {
  .brand img { height: 42px; }
}

.nav { display: flex; gap: 30px; align-items: center; }
.nav a {
  color: var(--ink-soft); font-size: .95rem; font-weight: 500;
  padding: 6px 0; border-bottom: 2px solid transparent;
}
.nav a:hover { color: var(--ink); text-decoration: none; }
.nav a.active { color: var(--ink); border-bottom-color: var(--accent); }

.nav-toggle {
  display: none; background: none; border: 0; cursor: pointer;
  font-size: 1.5rem; color: var(--ink); padding: 4px 8px;
}

/* ---------- hero ---------- */
.hero {
  background: var(--bg-dark);
  color: #fff;
  padding: 104px 0 92px;
  border-bottom: 4px solid var(--accent);
}
.hero h1 {
  max-width: 22ch;
  color: #fff;
  font-size: 3.4rem;
  line-height: 1.12;
}
.hero .lede {
  font-size: 1.22rem;
  color: #c2d4e2;
  max-width: 62ch;
  margin-top: 22px;
}
/* Pale-blue highlight on key words — the signature accent, from the logo. */
.hl { color: var(--hl); }


/* ---------- buttons ---------- */
.btn {
  display: inline-block; background: var(--accent); color: #fff;
  padding: 13px 26px; border-radius: 6px; font-weight: 600;
  font-size: .97rem; border: 0; cursor: pointer; font-family: var(--font);
}
.btn:hover { background: var(--accent-dk); text-decoration: none; }
.btn-ghost {
  background: transparent; color: var(--accent);
  box-shadow: inset 0 0 0 1.5px var(--accent);
}
.btn-ghost:hover { background: var(--accent); color: #fff; }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 30px; }

/* ---------- sections ---------- */
section { padding: 76px 0; }
section.alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-head { max-width: 64ch; margin-bottom: 44px; }
.section-head p { color: var(--ink-soft); margin-bottom: 0; }

/* ---------- cards ---------- */
.grid { display: grid; gap: 26px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 30px;
}
.card h3 { margin-bottom: .4em; }
.card p { color: var(--ink-soft); font-size: .97rem; margin-bottom: 0; }
.card .role {
  color: var(--accent); font-size: .85rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .06em; margin-bottom: .8em;
}

.avatar {
  width: 76px; height: 76px; border-radius: 50%;
  background: var(--bg-alt); border: 1px solid var(--line);
  margin-bottom: 18px; object-fit: cover;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-weight: 700; font-size: 1.5rem;
}

/* ---------- contact form ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .9rem; font-weight: 600; }
.field input, .field textarea {
  font-family: var(--font); font-size: 1rem; padding: 12px 14px;
  border: 1px solid var(--line); border-radius: 6px; background: #fff;
  color: var(--ink);
}
.field input:focus, .field textarea:focus {
  outline: 2px solid var(--accent); outline-offset: -1px; border-color: var(--accent);
}
.field textarea { min-height: 150px; resize: vertical; }
.consent {
  grid-column: 1 / -1; display: flex; gap: 11px;
  align-items: flex-start; font-size: .92rem; color: var(--ink-soft);
}
.consent input { margin-top: 4px; flex-shrink: 0; }
/* honeypot — hidden from humans, bots fill it in */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.notice { padding: 15px 18px; border-radius: 6px; margin-bottom: 26px; font-size: .95rem; }
.notice-ok  { background: #e6f4ef; border: 1px solid #a8d5c4; color: #16543f; }
.notice-err { background: #fdecea; border: 1px solid #f2b8b2; color: #8a231a; }

/* ---------- footer ---------- */
.site-footer {
  background: var(--ink); color: #b3c0cb;
  padding: 56px 0 30px; font-size: .93rem;
}
.site-footer h4 {
  color: #fff; font-size: .82rem; text-transform: uppercase;
  letter-spacing: .09em; margin: 0 0 16px;
}
.site-footer a { color: #b3c0cb; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; }
.footer-brand { color: #fff; font-size: 1.2rem; font-weight: 700; margin-bottom: 12px; }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: 9px; }
.footer-bottom {
  border-top: 1px solid #2a3946; margin-top: 44px; padding-top: 22px;
  display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  font-size: .87rem;
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .grid-3, .grid-2, .footer-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.55rem; }
  .hero { padding: 60px 0 52px; }
  section { padding: 56px 0; }
  .nav-toggle { display: block; }
  .nav {
    display: none; position: absolute; top: 76px; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line);
    flex-direction: column; gap: 0; padding: 10px 24px 18px; align-items: stretch;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav a.active { border-bottom-color: var(--line); }
}

/* ---------- services ---------- */
.service {
  border-top: 3px solid var(--accent);
  padding-top: 28px;
  margin-bottom: 62px;
}
.service:last-child { margin-bottom: 0; }
.service > .lead {
  color: var(--ink-soft); max-width: 68ch; font-size: 1.05rem;
}
.service-num {
  display: inline-block; color: var(--accent); font-weight: 700;
  font-size: .82rem; letter-spacing: .1em; text-transform: uppercase;
  margin-bottom: .6em;
}
.subservices {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px; margin-top: 32px;
}
.subservices.two { grid-template-columns: repeat(2, 1fr); }
.sub {
  background: var(--bg-alt); border: 1px solid var(--line);
  border-radius: 10px; padding: 24px;
}
.sub h4 {
  margin: 0 0 14px; font-size: 1rem; font-weight: 650; color: var(--ink);
}
.caps { list-style: none; margin: 0; padding: 0; }
.caps li {
  position: relative; padding-left: 20px; margin-bottom: 8px;
  font-size: .93rem; color: var(--ink-soft); line-height: 1.5;
}
.caps li::before {
  content: ""; position: absolute; left: 0; top: .55em;
  width: 7px; height: 7px; border-radius: 50%; background: var(--accent);
}
.caps li:last-child { margin-bottom: 0; }

/* service teaser cards on the homepage */
.card.linked { display: flex; flex-direction: column; }
.card.linked .more {
  margin-top: auto; padding-top: 16px; font-weight: 600; font-size: .92rem;
}

@media (max-width: 860px) {
  .subservices, .subservices.two { grid-template-columns: 1fr; }
  .service { margin-bottom: 44px; }
}

/* ---------- capability strip ---------- */
/* Uppercase run of capability keywords directly under the hero. */
.capstrip {
  background: var(--hl);
  color: var(--bg-dark);
  padding: 20px 0;
}
.capstrip .wrap {
  display: flex; flex-wrap: wrap; gap: 10px 34px;
  justify-content: center; text-align: center;
}
.capstrip span {
  font-size: .82rem; font-weight: 800;
  letter-spacing: .13em; text-transform: uppercase;
}

/* ---------- dark band ---------- */
section.dark {
  background: var(--bg-dark); color: #fff; border: 0;
}
section.dark h2 { color: #fff; }
section.dark .section-head p,
section.dark p { color: #c2d4e2; }
section.dark .card {
  background: #1b4066; border-color: #2a5580;
}
section.dark .card h3 { color: #fff; }
section.dark .card p  { color: #b6c8d8; }
section.dark .card .role { color: var(--hl); }
section.dark a { color: var(--hl); }

/* Brand accents on existing components */
.service { border-top-color: var(--hl); }
.service-num { color: var(--accent); }
.caps li::before { background: var(--hl); }
.nav a.active { border-bottom-color: var(--hl); }
.btn { border-radius: 2px; letter-spacing: .02em; }
.btn-accent { background: var(--hl); color: var(--bg-dark); }
.btn-accent:hover { background: #9dc4da; color: var(--bg-dark); }
.avatar { color: var(--accent); }

/* On light backgrounds a highlighted word uses teal, which reads at 4.5:1 on white. */
.hl-dark { color: var(--hl-dark); font-weight: 800; }

@media (max-width: 860px) {
  .hero { padding: 64px 0 56px; }
  .hero h1 { font-size: 2.1rem; }
  .capstrip .wrap { gap: 8px 20px; }
  .capstrip span { font-size: .7rem; letter-spacing: .1em; }
}

/* .avatar doubles as an initials chip (div) and a photo (img). As an img the
   flex centring is inert, but object-fit and the border radius still apply. */
img.avatar { object-fit: cover; object-position: center top; }
