:root {
  --bg: #ffffff;
  --bg-alt: #f4f6fa;
  --text: #14202e;
  --muted: #5a6b7e;
  --line: #dde3ec;
  --brand: #06255f;
  --brand-dark: #0a3a8f;
  --brand-ink: #ffffff;
  --accent: #d42c12;
  --card: #ffffff;
  --radius: 12px;
  --max: 1080px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d141d;
    --bg-alt: #121b27;
    --text: #e8eef6;
    --muted: #9bb0c6;
    --line: #243246;
    --brand: #5aa2ff;
    --brand-dark: #82b8ff;
    --brand-ink: #0d141d;
    --accent: #ff6a4d;
    --card: #162130;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; }
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.1rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }
.eyebrow { text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; font-weight: 700; color: var(--accent); margin-bottom: .75em; }

/* header */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 10; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; color: var(--text); text-decoration: none; letter-spacing: -.02em; }
.logo img { width: 40px; height: 40px; display: block; }
.logo span span { color: var(--accent); }
nav ul { list-style: none; display: flex; gap: 22px; margin: 0; padding: 0; align-items: center; }
nav a { text-decoration: none; color: var(--text); font-size: .95rem; }
nav a:hover { color: var(--brand); }

/* buttons */
.btn { display: inline-block; background: var(--brand); color: var(--brand-ink); padding: 12px 22px; border-radius: 8px; font-weight: 700; text-decoration: none; border: 2px solid var(--brand); }
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: var(--brand-ink); }
.btn.ghost { background: transparent; color: var(--brand); }
.btn.ghost:hover { background: var(--bg-alt); color: var(--brand-dark); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 1.5em; }

/* sections */
section { padding: 72px 0; }
section.alt { background: var(--bg-alt); }
.hero { padding: 84px 0 72px; }
.hero p.lead { font-size: 1.2rem; color: var(--muted); max-width: 680px; }
.grid { display: grid; gap: 20px; }
.grid.two { grid-template-columns: repeat(2, 1fr); }
.grid.three { grid-template-columns: repeat(3, 1fr); }
.grid.four { grid-template-columns: repeat(4, 1fr); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.num { display: inline-flex; width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-weight: 800; align-items: center; justify-content: center; margin-bottom: 12px; }
ul.check { list-style: none; padding: 0; margin: 0 0 1em; }
ul.check li { padding-left: 28px; position: relative; margin-bottom: .6em; }
ul.check li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
.callout { border-left: 4px solid var(--accent); background: var(--card); border-radius: 0 var(--radius) var(--radius) 0; padding: 20px 24px; border-top: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin: 1.5em 0; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; text-align: center; }
.stat strong { display: block; font-size: 2rem; color: var(--brand); line-height: 1.1; }
.stat span { font-size: .88rem; color: var(--muted); }
details { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 12px; }
summary { cursor: pointer; font-weight: 700; }
details p { margin: .8em 0 0; color: var(--muted); }
.cta { text-align: center; }
.cta p { max-width: 560px; margin-left: auto; margin-right: auto; color: var(--muted); }

/* footer */
footer { border-top: 1px solid var(--line); padding: 36px 0; font-size: .9rem; color: var(--muted); }
footer a { color: var(--muted); }
.legal { font-size: .82rem; margin-top: 1em; }

/* case study page */
.article { max-width: 760px; }
.article h2 { margin-top: 1.6em; }
.article table { width: 100%; border-collapse: collapse; margin: 1em 0; }
.article th, .article td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }

@media (max-width: 860px) {
  .grid.three, .grid.four { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .grid.two, .grid.three, .grid.four { grid-template-columns: 1fr; }
  nav ul li:not(:last-child) { display: none; }
  section { padding: 52px 0; }
  .hero { padding: 56px 0 48px; }
}

/* case study cards and highlights */
.case-card { display: flex; flex-direction: column; }
.case-card .tag { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--accent); margin-bottom: .5em; }
.case-card p { color: var(--muted); }
.case-card .btn { margin-top: auto; align-self: flex-start; }
.tagline { font-size: 1.25rem; color: var(--muted); margin-bottom: 1.5em; }
.fine { font-size: .9rem; color: var(--muted); }

/* about page bio */
.bio { display: grid; grid-template-columns: 240px 1fr; gap: 28px; align-items: start; margin: 1em 0 1.5em; }
.bio-photo { width: 240px; height: auto; border-radius: var(--radius); border: 1px solid var(--line); display: block; }
@media (max-width: 620px) {
  .bio { grid-template-columns: 1fr; }
  .bio-photo { width: 180px; }
}

/* cookie consent banner */
#consent-banner { position: fixed; left: 16px; right: 16px; bottom: 16px; max-width: 760px; margin: 0 auto; z-index: 50; background: var(--card); color: var(--text); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 30px rgba(0,0,0,.18); padding: 16px 20px; display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
#consent-banner p { margin: 0; font-size: .92rem; flex: 1 1 320px; }
.consent-actions { display: flex; gap: 10px; }
.consent-actions .btn { padding: 8px 16px; font-size: .92rem; }

/* contact form */
.contact-form { display: grid; gap: 16px; max-width: 560px; margin-top: 1.5em; }
.contact-form label { display: grid; gap: 6px; font-weight: 600; font-size: .95rem; }
.contact-form input[type=text], .contact-form input[type=email], .contact-form textarea { font: inherit; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--text); width: 100%; }
.contact-form input:focus, .contact-form textarea:focus { outline: 2px solid var(--brand); outline-offset: 1px; }
.contact-form .btn { justify-self: start; cursor: pointer; font: inherit; font-weight: 700; }

.form-status { margin: 0; min-height: 1.4em; color: var(--accent); font-weight: 600; }

/* landing page trust strip */
.trust { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 24px; padding: 0; margin: 2em 0 0; font-size: .92rem; color: var(--muted); }
.trust li { position: relative; padding-left: 18px; }
.trust li::before { content: "\2713"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }
