/* ============================================================
   home.css — revamp homepage components + the AdviceStudio-style
   craft on Planfocus colours (Fraunces 500, italic-teal accents,
   pill eyebrows, soft shadows, reveal-on-scroll).
   Loaded site-wide; the global tweaks at the top are deliberate.
   ============================================================ */

:root {
  --teal-deep: #13b3a0;     /* readable teal for text accents */
  --teal-soft: #7ce7d9;
  --navy-deep: #1b3644;
  --navy-soft: #506a76;
  --mist: #f3f5f7;
  --mist-deep: #e7ebee;
  --shadow-sm: 0 1px 2px rgba(36,69,84,.04), 0 10px 30px rgba(36,69,84,.07);
  --shadow-lg: 0 30px 80px rgba(36,69,84,.14);
}

/* ---- global craft tweaks ---- */
h1, h2, h3 { font-weight: 500; letter-spacing: -.015em; line-height: 1.08; }
.serif-i { font-style: italic; font-weight: 400; color: var(--teal-deep); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: .78rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--navy-soft); background: var(--mist); border: 1px solid var(--line);
  padding: .45rem .95rem; border-radius: 999px; margin: 0 0 1.2rem;
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); animation: pf-pulse 2.4s infinite; }
@keyframes pf-pulse { 0%,100%{opacity:1} 50%{opacity:.35} }
@media (prefers-reduced-motion: reduce) { .eyebrow .dot { animation: none; } }

[data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity .7s cubic-bezier(.2,.7,.3,1), transform .7s cubic-bezier(.2,.7,.3,1); }
[data-reveal].is-revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1; transform: none; transition: none; } }

/* ---- section shell ---- */
.hm { padding-block: clamp(3.5rem, 7vw, 6rem); }
.hm--mist { background: var(--mist); }
.hm__head { max-width: 62ch; margin-bottom: clamp(1.8rem, 4vw, 2.75rem); }
.hm__head.is-center { margin-inline: auto; text-align: center; }
.hm__head h2 { font-size: clamp(1.9rem, 3.8vw, 2.75rem); max-width: 22ch; text-wrap: balance; margin: 0; }
.hm__head.is-center h2 { margin-inline: auto; }
.hm__sub { font-size: clamp(1.05rem, 1.6vw, 1.18rem); color: var(--navy-soft); line-height: 1.55; margin: 1rem 0 0; max-width: 58ch; }
.hm__head.is-center .hm__sub { margin-inline: auto; }

/* ---- hero (reuses .bl-hero grid + pinned graphic from blog.css) ---- */
.home-hero { padding-block: clamp(3.5rem, 8vw, 6rem) clamp(2.5rem, 6vw, 4rem); }
.home-hero .bl-hero__heading { font-size: clamp(2.5rem, 5.4vw, 3.9rem); max-width: 16ch; font-weight: 500; letter-spacing: -.02em; }
.home-hero .bl-hero__para { font-size: clamp(1.08rem, 1.8vw, 1.25rem); max-width: 52ch; }
.hero-cta { display: flex; gap: .9rem; flex-wrap: wrap; align-items: center; }
.hero-note { font-size: .92rem; color: var(--navy-soft); margin: 0; max-width: 48ch; }
.hero-foot { font-size: .78rem; color: var(--muted); margin: .25rem 0 0; }

/* buttons (extend site.css .btn) */
.btn--teal { background: var(--teal); color: var(--navy-deep); font-weight: 700; }
.btn--teal:hover { background: var(--teal-soft); }
.btn--ghost { background: transparent; color: var(--navy); border: 1px solid var(--line); }
.btn--ghost:hover { border-color: var(--navy-soft); }
.btn--lg { padding: .95rem 1.6rem; font-size: 1.02rem; }

/* ---- card grids ---- */
.hm-grid { display: grid; gap: clamp(1rem, 2.2vw, 1.5rem); }
.hm-grid--3 { grid-template-columns: repeat(3, 1fr); }
.hm-grid--4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .hm-grid--3, .hm-grid--4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .hm-grid--3, .hm-grid--4 { grid-template-columns: 1fr; } }

.hm-card {
  background: var(--bg); border: 1px solid var(--line); border-radius: 16px;
  padding: clamp(1.25rem, 2.5vw, 1.75rem); box-shadow: var(--shadow-sm);
  display: flex; flex-direction: column; gap: .5rem;
  transition: transform .25s, box-shadow .25s;
}
.hm-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.hm-card h3 { font-size: 1.2rem; margin: 0; }
.hm-card p { margin: 0; color: var(--body); line-height: 1.6; font-size: .98rem; }
.hm-card__kicker { font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--teal-deep); }
.hm-card__stat { font-family: var(--font-head); font-size: 2.4rem; line-height: 1; color: var(--navy-deep); font-weight: 500; margin-bottom: .35rem; }
.hm-card__link { margin-top: auto; padding-top: .75rem; font-weight: 600; color: var(--teal-ink); }
.hm-card__link small { color: var(--muted); font-weight: 500; margin-left: .3rem; }
.hm-card--rail { border-left: 5px solid var(--teal); }
.hm-card--rail.is-lime { border-left-color: #a4d233; }
.hm-card cite { display: block; font-style: normal; font-size: .85rem; color: var(--muted); margin-top: .6rem; }
.hm-card .cs { font-size: .95rem; }
.hm-card .cs b { color: var(--navy-deep); }

/* ---- pull quote ---- */
.hm-quote {
  margin: clamp(1.8rem, 4vw, 2.5rem) 0 0; padding: 1.3rem 1.5rem;
  border-left: 4px solid var(--coral); background: var(--mist); border-radius: 12px;
  font-family: var(--font-head); font-size: clamp(1.15rem, 2vw, 1.4rem); color: var(--navy-deep); line-height: 1.4;
}
.hm-quote cite { display: block; font-family: var(--font-body); font-style: normal; font-size: .9rem; color: var(--navy-soft); margin-top: .6rem; }

/* ---- partner band ---- */
.hm-band {
  margin-top: clamp(1.8rem, 4vw, 2.5rem); padding: 1rem 1.3rem; border-radius: 12px;
  background: var(--bg); border: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center; font-size: .95rem; color: var(--ink);
}
.hm-band__label { font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--teal-deep); }

/* ---- insights teaser ---- */
.hm-post { text-decoration: none; color: inherit; }
.hm-post:hover { text-decoration: none; }
.hm-post .hm-card__kicker { color: var(--muted); }
.hm-post__more {
  align-self: flex-start; margin-top: auto; padding-top: .2rem;
  font-size: .88rem; font-weight: 600; color: var(--teal-ink);
}
.hm-post:hover .hm-post__more { color: var(--coral); }

/* ---- connect ---- */
.hm-connect { max-width: 760px; margin-inline: auto; }
.hm-connect .contact-form { margin-top: 1.5rem; }
.hm-connect__phone { text-align: center; color: var(--navy-soft); font-size: .95rem; margin: 1.25rem 0 0; }
.hm-connect__phone a { color: var(--teal-ink); font-weight: 600; }

/* ---- logo strip spacing on the revamp home ---- */
.home-logos { padding-block: 0 clamp(2.5rem, 5vw, 3.5rem); }

/* ---- nav button ---- */
.btn--connect { background: var(--teal); color: var(--navy-deep); }
.btn--connect:hover { background: var(--teal-soft); }
/* ---- Services page: index cards + split rows with an at-a-glance panel ---- */
.svc-index { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 700px) { .svc-index { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .svc-index { grid-template-columns: 1fr; } }
.svc-index__card {
  display: flex; flex-direction: column; gap: .35rem; padding: 1.25rem 1.3rem;
  background: var(--bg); border: 1px solid var(--line); border-top: 4px solid var(--acc, var(--teal));
  border-radius: 14px; box-shadow: var(--shadow-sm); color: inherit; text-decoration: none;
  transition: transform .25s, box-shadow .25s;
}
.svc-index__card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); text-decoration: none; }
.svc-index__card .k { font-size: .78rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--acc, var(--teal-deep)); }
.svc-index__card h3 { font-size: 1.15rem; margin: 0; }
.svc-index__card p { margin: 0; font-size: .92rem; color: var(--body); line-height: 1.5; }
.svc-index__card .go { margin-top: auto; padding-top: .5rem; font-size: .85rem; font-weight: 600; color: var(--teal-ink); }

.svc-row { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
.svc-row--flip .svc-row__text { order: 2; }
@media (max-width: 900px) { .svc-row { grid-template-columns: 1fr; } .svc-row--flip .svc-row__text { order: 0; } }
.svc-row__text .k { display: inline-flex; align-items: center; gap: .6rem; font-size: .95rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--acc, var(--teal-deep)); margin-bottom: .9rem; }
.svc-row__text .k::before { content: ""; width: 32px; height: 3px; border-radius: 2px; background: var(--acc, var(--teal)); }
.svc-row__text h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); margin: 0 0 .9rem; max-width: 18ch; }
.svc-row__text .lead { font-size: 1.12rem; color: var(--navy-soft); line-height: 1.55; margin: 0 0 1rem; max-width: 52ch; }
.svc-row__text p { max-width: 56ch; }
.svc-row__text .hero-cta { margin-top: 1.25rem; }

.glance {
  background: var(--bg); border: 1px solid var(--line); border-left: 5px solid var(--acc, var(--teal));
  border-radius: 16px; padding: clamp(1.25rem, 2.6vw, 1.75rem); box-shadow: var(--shadow-sm);
  display: grid; gap: 1.1rem;
}
.hm--mist .glance { background: #fff; }
.glance h4 { font-family: var(--font-body); font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 .35rem; }
.glance p { margin: 0; font-size: .96rem; line-height: 1.55; }
.glance .check-list { margin: 0; }
.glance .check-list li { margin: .35rem 0; font-size: .95rem; }
.glance .check-list li::before { color: var(--acc, var(--teal-ink)); }
.glance .outcome { font-family: var(--font-head); font-size: 1.15rem; color: var(--navy-deep); line-height: 1.35; }

/* per-service accents */
.acc-teal  { --acc: var(--teal-deep); }
.acc-navy  { --acc: var(--navy); }
.acc-coral { --acc: var(--coral); }
.acc-lime  { --acc: #7fb31a; }

/* ---- About page ---- */
.about-story { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
@media (max-width: 900px) { .about-story { grid-template-columns: 1fr; } }
.about-story__text h2 { font-size: clamp(1.9rem, 3.6vw, 2.6rem); margin: 0 0 1rem; max-width: 18ch; }
.about-story__text .lead { font-size: 1.15rem; color: var(--navy-soft); line-height: 1.55; margin: 0 0 1rem; max-width: 54ch; }
.about-story__text p { max-width: 58ch; }
.about-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 520px) { .about-stats { grid-template-columns: 1fr; } }
.about-stat { background: var(--mist); border: 1px solid var(--line); border-radius: 14px; padding: 1.2rem 1.25rem; border-top: 4px solid var(--teal); }
.about-stat:nth-child(2) { border-top-color: var(--navy); }
.about-stat:nth-child(3) { border-top-color: var(--coral); }
.about-stat:nth-child(4) { border-top-color: #7fb31a; }
.about-stat b { display: block; font: 500 clamp(2rem, 3.2vw, 2.6rem)/1 var(--font-head); color: var(--navy-deep); margin-bottom: .45rem; }
.about-stat span { font-size: .9rem; color: var(--body); line-height: 1.45; }

/* team as cards on the mist ground */
.team-section .team-grid { max-width: 1000px; }
.team-section .team-member {
  background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.5rem 1.25rem 1.4rem;
  box-shadow: var(--shadow-sm); transition: transform .25s, box-shadow .25s;
}
.team-section .team-member:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.team-section .team-member__photo { box-shadow: 0 0 0 4px #fff, 0 0 0 6px var(--teal-soft); }
.team-section .team-filter { margin-bottom: 2rem; }
.team-section .team-filter__btn.is-active { background: var(--navy); border-color: var(--navy); }

/* partners as cards */
.partner-card { align-items: flex-start; }
.partner-card img { height: 44px; width: auto; max-width: 160px; object-fit: contain; margin-bottom: .6rem; }
.partner-card h3 { font-size: 1.15rem; }

/* Health Check repeated inside the mobile menu (the button itself is hidden ≤860px) */
.site-nav__mobile-cta { display: none; }
@media (max-width: 860px) {
  .site-nav__mobile-cta { display: block; margin-top: .5rem; padding-top: .75rem; border-top: 1px solid rgba(255,255,255,.15); }
  .site-nav__mobile-cta a { color: var(--teal) !important; font-weight: 700; }
}

/* quote attribution with a small avatar */
.hm-quote cite, .hm-card cite { display: flex; align-items: center; gap: .65rem; }
.hm-card cite img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--teal); }
.hm-quote cite img {
  width: 38px; height: 38px; border-radius: 50%; object-fit: cover; flex: none;
  box-shadow: 0 0 0 2px rgba(255,255,255,.9), 0 0 0 4px var(--teal);
}
@media (max-width: 520px) { .hm-quote cite img { width: 32px; height: 32px; } }

/* insights teaser thumbnails: the image spans the card, so drop the card's own
   padding and re-apply it to the text instead of using negative margins. */
.hm-card.hm-post:has(.hm-post__img) { padding: 0 0 clamp(1.25rem, 2.5vw, 1.75rem); overflow: hidden; }
.hm-card.hm-post:has(.hm-post__img) > :not(.hm-post__img) { padding-inline: clamp(1.25rem, 2.5vw, 1.75rem); }
.hm-post__img { display: block; width: 100%; height: 150px; object-fit: cover; margin: 0 0 .9rem; }
@media (max-width: 560px) { .hm-post__img { height: 170px; } }

/* ---- Insights post: bring the article up to the revamp's standard ---- */
.post { max-width: 46rem; }
.post__header { margin-bottom: 1.75rem; }
.post__meta { font-size: .88rem; color: var(--navy-soft); margin: 0 0 .9rem; }
.post__title { font-size: clamp(2rem, 4vw, 2.9rem); line-height: 1.08; letter-spacing: -.02em; margin: 0 0 1rem; }
.post__cats { gap: .45rem; }
.post__cat {
  background: var(--mist); border: 1px solid var(--line); border-radius: 999px;
  padding: .3rem .8rem; font-size: .7rem; font-weight: 700; letter-spacing: .08em;
  color: var(--teal-deep); text-decoration: none;
}
.post__cat:hover { border-color: var(--teal); text-decoration: none; }
.post__hero-img { border-radius: 16px; box-shadow: var(--shadow-lg); margin-bottom: 2.25rem; }

/* lead paragraph */
.post__body > p:first-of-type { font-size: 1.2rem; line-height: 1.65; color: var(--navy-deep); }

/* section headings with a teal rule */
.post__body h2 {
  font-size: clamp(1.5rem, 2.6vw, 1.85rem); margin-top: 2.75rem; padding-top: 1.5rem;
  border-top: 1px solid var(--line); position: relative;
}
.post__body h2::before {
  content: ""; position: absolute; top: -2px; left: 0; width: 44px; height: 3px;
  background: var(--teal); border-radius: 2px;
}

/* numbered steps as teal counters */
.post__body ol { counter-reset: step; list-style: none; padding-left: 0; margin: 1.4rem 0; }
.post__body ol > li {
  counter-increment: step; position: relative; padding-left: 3rem; margin-bottom: 1rem; min-height: 2rem;
}
.post__body ol > li::before {
  content: counter(step); position: absolute; left: 0; top: -.15rem;
  width: 2rem; height: 2rem; border-radius: 50%;
  background: var(--teal); color: var(--navy-deep);
  font: 700 .95rem/2rem var(--font-body); text-align: center;
}

/* caveat list as soft cards */
.post__body ul { list-style: none; padding-left: 0; margin: 1.4rem 0; display: grid; gap: .7rem; }
.post__body ul > li {
  background: var(--mist); border: 1px solid var(--line); border-left: 4px solid var(--teal);
  border-radius: 12px; padding: .9rem 1.1rem; margin: 0;
}
.post__body ul > li strong { color: var(--navy-deep); }

/* closing CTA block (the text after the final rule) */
.post__body hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0 0; }
.post__body hr + p {
  background: linear-gradient(180deg, var(--tint, #e8fbf8), #f3fdfb);
  border: 1px solid #d5f5ef; border-radius: 16px;
  padding: 1.4rem 1.6rem; margin-top: 1.5rem; font-size: 1.05rem;
}
.post__body hr + p a { font-weight: 700; }
.post__footer a { font-weight: 600; color: var(--teal-ink); }

/* ---- Insights: numbered-heading posts (e.g. "Five signs...") ---- */
/* A heading that starts "1." gets a teal numeral badge and no top rule. */
.post__body h2 { counter-increment: pfsec; }
.post__body { counter-reset: pfsec; }
.post__body h2.is-numbered {
  border-top: 0; padding-top: 0; margin-top: 2.5rem;
  display: grid; grid-template-columns: 2.6rem 1fr; align-items: start; gap: .9rem;
}
.post__body h2.is-numbered::before {
  content: attr(data-n); position: static;
  width: 2.6rem; height: 2.6rem; border-radius: 12px;
  background: var(--teal); color: var(--navy-deep);
  font: 500 1.35rem/2.6rem var(--font-head); text-align: center;
}
/* "What it usually means:" paragraphs read as an aside */
.post__body p.is-note {
  background: var(--mist); border-left: 4px solid var(--navy);
  border-radius: 0 12px 12px 0; padding: .95rem 1.15rem; margin: 1rem 0 0;
  font-size: 1rem;
}
.post__body p.is-note strong { color: var(--navy-deep); }

/* ---- Insights: pull-stat callout (a blockquote whose first line is bold) ---- */
.post__body blockquote.is-stat {
  background: linear-gradient(180deg, #e8fbf8, #f3fdfb);
  border: 1px solid #d5f5ef; border-left: 5px solid var(--teal);
  border-radius: 16px; padding: 1.4rem 1.6rem; margin: 1.6rem 0;
  font-style: normal; color: var(--body);
}
.post__body blockquote.is-stat p { margin: 0; }
.post__body blockquote.is-stat strong {
  display: block; font-family: var(--font-head); font-weight: 500;
  font-size: clamp(1.8rem, 3.4vw, 2.4rem); line-height: 1.1;
  color: var(--navy-deep); margin-bottom: .5rem;
}
/* named cost drivers read as compact cards */
.post__body blockquote p.is-driver {
  background: none; border: 0; border-radius: 0; padding: 0; margin: 0;
}
.post__body p.is-driver {
  background: var(--bg); border: 1px solid var(--line); border-top: 3px solid var(--coral);
  border-radius: 12px; padding: 1rem 1.2rem; margin: .8rem 0 0; font-size: 1rem;
}
.post__body p.is-driver strong { color: var(--navy-deep); }

/* ---- Insights: reader-facing scope note (blockquote opening "A note on") ---- */
.post__body blockquote.is-scope {
  background: var(--mist); border: 1px solid var(--line); border-left: 4px solid var(--navy-soft);
  border-radius: 12px; padding: 1rem 1.25rem; margin: 0 0 1.75rem;
  font-style: normal; font-size: .98rem; color: var(--navy-soft);
}
.post__body blockquote.is-scope p { margin: 0; }
.post__body blockquote.is-scope strong { color: var(--navy-deep); }
