/* ==========================================================================
   Measured Local — design system
   Brand palette matches the postcard + diagnostic report:
     slate blue #3D5A80 (dominant accent: nav, footer, heroes, headings)
     red        #C0392B (CTA buttons only)
     green      #27AE60 (success signals, sparingly)
     light slate #F8FAFC (alternating section backgrounds)
   Inter, 1120px container, 12px radii. Breakpoints: 991 / 767 / 479.
   ========================================================================== */

:root {
  --ink: #0f172a;
  --ink-soft: #334155;
  --ink-link: #111827;
  --muted: #6b7280;
  --slate: #3D5A80;
  --slate-dark: #324b6b;
  --primary: #3D5A80;        /* alias of slate, used by links/accents */
  --primary-hover: #324b6b;
  --red: #C0392B;
  --red-hover: #a23224;
  --green: #27AE60;
  --alt-bg: #EAEFF5;        /* light slate tint — visible rhythm, on-brand */
  --surface: #f8fafc;
  --surface-2: #f9fafb;
  --line: #e2e8f0;
  --line-soft: #e5e7eb;
  --chip: #f1f5f9;
  --max: 1120px;
}

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

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

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: inline-block; vertical-align: middle; }

h1, h2, h3, h4 { margin: 0 0 12px; font-weight: 600; color: var(--slate); }
h1 { margin-bottom: 24px; font-size: 40px; font-weight: 700; line-height: 1.15; }
h2 { margin-bottom: 16px; font-size: 32px; line-height: 1.2; }
h3 { font-size: 22px; line-height: 1.25; }

p { margin: 0 0 20px; color: var(--ink-soft); }
ul, ol { margin: 0 0 16px; padding-left: 20px; }
li { margin-bottom: 6px; }
a { color: var(--ink-link); text-decoration: none; }
strong { font-weight: 600; }

/* ---- Layout primitives ---- */
.section { padding: 64px 0; }
.section--tight { padding: 40px 0; }
.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
  text-align: left;
}
.hero {
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}
.stack { max-width: 760px; }
.stack > * { margin-left: 0; }
.centered { text-align: center; }
.bordered-top { border-top: 1px solid var(--line-soft); }

/* ---- Brand color: heroes, alternating sections, success checks ---- */
/* Hero banner: slate blue with white text */
.section--hero { background: var(--slate); }
.section--hero h1,
.section--hero h2,
.section--hero h3 { color: #fff; }
.section--hero p,
.section--hero .lead { color: rgba(255, 255, 255, .9); }
.section--hero .overline { color: rgba(255, 255, 255, .8); }
.section--hero .badge { background: rgba(255, 255, 255, .16); color: #fff; }

/* Alternating light-slate section backgrounds for rhythm (heroes excluded) */
main > section:nth-of-type(even):not(.section--hero) { background: var(--alt-bg); }
/* Keep cards readable on the light-slate stripes */
main > section:nth-of-type(even):not(.section--hero) .card,
main > section:nth-of-type(even):not(.section--hero) .kpi,
main > section:nth-of-type(even):not(.section--hero) .tile,
main > section:nth-of-type(even):not(.section--hero) .diff-card,
main > section:nth-of-type(even):not(.section--hero) .program-card { background: #fff; }

/* Green success checks (e.g. pilot inclusions list) */
.check-list { list-style: none; padding-left: 0; }
.check-list li { position: relative; padding-left: 30px; margin-bottom: 10px; }
.check-list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--green);
  font-weight: 800;
}

/* ---- Buttons (CTAs are always red with white text, large + rounded) ---- */
.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.2;
  cursor: pointer;
  text-align: center;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.btn--primary { background: var(--red); color: #fff; border: 1px solid var(--red); }
.btn--primary:hover { background: var(--red-hover); border-color: var(--red-hover); }
.btn--secondary { background: var(--red); color: #fff; border: 1px solid rgba(0, 0, 0, .14); }
.btn--secondary:hover { background: var(--red-hover); border-color: rgba(0, 0, 0, .2); }
/* Outlined slate button = secondary "learn more" action, distinct from red CTAs */
.btn--outline { background: #fff; color: var(--slate); border: 1px solid var(--slate); }
.btn--outline:hover { background: var(--alt-bg); }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  align-items: center;
}

/* ---- Text accents ---- */
.overline {
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.3;
  margin-bottom: 10px;
}
.lead {
  color: var(--ink-soft);
  font-size: 18px;
  line-height: 1.5;
  margin-bottom: 24px;
}
.hero .lead { text-align: center; }
.note { color: var(--ink); font-size: 14px; margin-top: 16px; }
.badge {
  display: inline-block;
  margin-top: 16px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--chip);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 500;
}
.value-line {
  background: #e8f3ff;
  border: 1px solid #d7e9fb;
  border-radius: 12px;
  padding: 16px 18px;
  font-size: 15px;
  color: var(--ink);
  margin: 0 0 20px;
}

/* ---- Grids ---- */
.grid-2, .grid-3, .grid-4, .kpis {
  display: grid;
  gap: 24px;
}
.grid-2 { grid-template-columns: 1fr 1fr; }
.grid-3 { grid-template-columns: 1fr 1fr 1fr; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.kpis  { grid-template-columns: 1fr 1fr 1fr; }

/* ---- Cards ---- */
.card, .kpi {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 24px;
}
.card h3, .kpi h3 { margin-top: 0; }
.card ul:last-child, .card p:last-child { margin-bottom: 0; }

.tile {
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 5px rgba(0,0,0,.18);
}

/* ---- CTA bar ---- */
.cta-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 24px;
}
.cta-bar h3 { margin: 0 0 6px; }
.cta-bar p { margin: 0; }

/* ==========================================================================
   Header
   ========================================================================== */
.header {
  position: sticky;
  top: 0;
  z-index: 500;
  background: var(--slate);
  border-bottom: 1px solid var(--slate-dark);
  padding: 14px 0;
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  color: #fff;
  white-space: nowrap;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-link {
  color: rgba(255, 255, 255, .82);
  font-weight: 500;
  line-height: 1.4;
  transition: color .15s ease;
}
.nav-link:hover, .nav-link.is-current { color: #fff; }
.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, .45);
  border-radius: 8px;
  background: transparent;
  color: #fff;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  cursor: pointer;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  background: var(--slate);
  padding: 56px 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 14px 28px;
  align-items: start;
}
.footer-brand { font-size: 18px; font-weight: 700; color: #fff; }
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: flex-end;
  align-items: center;
}
.footer-link { color: rgba(255, 255, 255, .85); }
.footer-link:hover { color: #fff; text-decoration: underline; }
.footer-legal {
  border-top: 1px solid rgba(255, 255, 255, .18);
  margin-top: 20px;
  padding-top: 14px;
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, .8);
}
.legal-link { color: #fff; text-decoration: underline; }

/* ==========================================================================
   Page-specific blocks
   ========================================================================== */
/* Timeline */
.timeline-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  max-width: 1140px;
  margin: 0 auto;
}
.timeline-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  height: 100%;
}
.timeline-step h3 { margin: 0; }
.timeline-step p { margin: 0; }
.phase-label {
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
}

/* Exclusivity */
.exclusivity-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  max-width: 1140px;
  margin: 0 auto;
}
.exclusivity-card { text-align: center; }
.exclusivity-card h3 { margin: 0 0 4px; }
.exclusivity-card p { margin: 0; }

/* About */
.difference-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px 28px;
}
.diff-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 24px;
}
.diff-card h3, .diff-card p { margin: 0; }
.founder-photo {
  display: block;
  width: 160px;
  border-radius: 50%;
  margin: 24px 0 32px;
}

/* Services programs */
.programs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
  max-width: 1140px;
  margin: 0 auto;
}
.program-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 20px;
}
.program-card h3 { margin: 0; }
.program-price { margin: 0; font-weight: 600; color: var(--primary); }
.program-card ul { margin: 4px 0 0; }

/* Eligibility list */
.eligibility-list { margin: 12px 0 20px; padding-left: 20px; }

/* "Coming soon" tag (e.g. Competitive Intelligence) */
.tag-soon {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--alt-bg);
  color: var(--slate);
  font-size: 12px;
  font-weight: 600;
  vertical-align: middle;
  white-space: nowrap;
}
.price-inline { color: var(--slate); font-weight: 600; }

/* ==========================================================================
   Blog
   ========================================================================== */
.blog-list {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 32px;
}
.blog-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,.08);
  height: 100%;
}
.blog-card-body { padding: 24px; display: flex; flex-direction: column; gap: 8px; height: 100%; }
.blog-card-title { color: var(--slate); font-size: 22px; font-weight: 600; line-height: 1.25; margin: 0; }
.blog-card-body p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.blog-card-date { color: var(--muted); font-size: 13px; margin-top: auto; padding-top: 8px; }

/* Blog post */
.post-container { max-width: 720px; margin: 0 auto; }
.post-meta { color: var(--muted); font-size: 14px; margin-bottom: 28px; }
.post-body { font-size: 18px; line-height: 1.62; color: var(--ink-link); }
.post-body p { color: var(--ink-link); font-size: 18px; line-height: 1.62; margin-bottom: 20px; }
.post-body h2 { font-size: 28px; line-height: 1.25; margin: 40px 0 16px; }
.post-body h3 { font-size: 22px; line-height: 1.36; margin: 32px 0 12px; color: #374151; }
.post-body ul, .post-body ol { margin-bottom: 20px; padding-left: 20px; line-height: 1.6; }
.post-body li { margin-bottom: 8px; }
.post-body blockquote {
  margin: 24px 0;
  padding: 4px 0 4px 16px;
  border-left: 4px solid var(--line-soft);
  color: #374151;
  font-style: italic;
}
.post-back { display: inline-block; margin-bottom: 16px; color: var(--primary); font-weight: 500; }
.post-cta { margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--line-soft); text-align: center; }

/* ==========================================================================
   Redirect / utility pages
   ========================================================================== */
.utility-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 60vh;
  gap: 8px;
}
.param-readout {
  display: none;
  margin-top: 16px;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-soft);
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media screen and (max-width: 991px) {
  h1 { font-size: 36px; }
  h2 { font-size: 28px; }
  h3 { font-size: 20px; }
  .section { padding: 48px 0; }
  .grid-3, .grid-4, .kpis { grid-template-columns: 1fr 1fr; }
  .programs-grid, .blog-list { grid-template-columns: 1fr 1fr; }

  .nav-links {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    background: var(--slate);
    border-bottom: 1px solid var(--slate-dark);
    padding: 12px 24px 20px;
    box-shadow: 0 8px 16px rgba(0,0,0,.18);
  }
  .header.nav-open .nav-links { display: flex; }
  .nav-link { padding: 8px 0; color: #fff; width: 100%; }
  .nav-toggle { display: flex; }
  .header .container { position: relative; }
}

@media screen and (max-width: 767px) {
  h1 { font-size: 32px; }
  h2 { font-size: 24px; }
  h3 { font-size: 18px; }
  .container { padding: 0 16px; }
  .grid-2, .grid-3, .grid-4, .kpis { grid-template-columns: 1fr; }
  .difference-grid, .programs-grid, .blog-list { grid-template-columns: 1fr; }
  .cta-bar { flex-direction: column; align-items: flex-start; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-links { justify-content: flex-start; gap: 16px; }
  .post-body, .post-body p { font-size: 16px; line-height: 1.6; }
  .post-body h2 { font-size: 24px; }
  .post-body h3 { font-size: 20px; }
}

@media screen and (max-width: 479px) {
  .timeline-grid { grid-template-columns: 1fr; }
  .footer-links { flex-direction: column; gap: 10px; }
}
