/* ---------- Base & Variables ---------- */
:root {
  --navy-900: #0b1220;
  --navy-800: #101a2e;
  --navy-700: #16223c;
  --ink: #10182b;
  --paper: #f7f8fb;
  --paper-alt: #eef1f7;
  --line: #e3e7f0;
  --text: #1c2436;
  --text-soft: #55617a;
  --text-invert: #eef1f7;
  --accent: #c9a24a;
  --accent-soft: #f0e2bd;
  --blue: #2f5df5;
  --radius: 14px;
  --max: 1120px;
  --shadow: 0 20px 50px -25px rgba(16, 24, 43, 0.35);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

h1, h2, h3 { font-weight: 700; letter-spacing: -0.02em; margin: 0; }

a { color: inherit; text-decoration: none; }

ul { margin: 0; padding: 0; list-style: none; }

img { max-width: 100%; display: block; }

/* ---------- Accessibility ---------- */
.skip-link {
  position: fixed;
  top: -60px;
  left: 16px;
  z-index: 1100;
  background: var(--accent);
  color: var(--navy-900);
  font-weight: 700;
  padding: 12px 20px;
  border-radius: 8px;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 16px; }

a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
  .ambient-field { display: none; }
  .hero-particle, .contact-particle { animation: none !important; fill: rgba(255, 255, 255, 0.06) !important; }
}

/* ---------- Ambient particle field (persists across all sections) ---------- */
.ambient-field {
  position: fixed;
  inset: 0;
  z-index: 40;
  overflow: hidden;
  pointer-events: none;
}
.ambient-particle {
  position: absolute;
  left: var(--l);
  bottom: -20px;
  width: var(--sz);
  height: var(--sz);
  border-radius: 50%;
  background: rgba(85, 97, 122, 0.5);
  box-shadow: 0 0 6px rgba(85, 97, 122, 0.3);
  opacity: 0;
  animation: ambientDrift var(--dur) linear infinite;
  animation-delay: var(--delay);
}
.ambient-particle-accent {
  background: var(--accent);
  box-shadow: 0 0 7px rgba(201, 162, 74, 0.55);
}
.ambient-particle-blue {
  background: var(--blue);
  box-shadow: 0 0 7px rgba(47, 93, 245, 0.5);
}
@keyframes ambientDrift {
  0%   { transform: translate(0, 0); opacity: 0; }
  10%  { opacity: 0.4; }
  50%  { transform: translate(var(--sway), -60vh); }
  90%  { opacity: 0.4; }
  100% { transform: translate(calc(var(--sway) * -1), -120vh); opacity: 0; }
}

/* ---------- Progress bar ---------- */
#progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--blue));
  z-index: 1000;
  transition: width 0.1s ease-out;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 900;
  background: rgba(11, 18, 32, 0.0);
  transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
  padding: 6px 0;
}
.site-header.scrolled {
  background: rgba(11, 18, 32, 0.85);
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 30px -20px rgba(0,0,0,0.6);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 0.02em;
}
.logo span { color: var(--accent); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  color: rgba(255,255,255,0.82);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.nav-links a:hover { color: #fff; border-color: var(--accent); }
.nav-links a.active { color: #fff; border-color: var(--accent); }

.nav-cta {
  background: var(--accent);
  color: var(--navy-900) !important;
  padding: 8px 16px !important;
  border-radius: 999px;
  border-bottom: none !important;
}
.nav-cta:hover { background: #d8b665; }

/* Mobile section quick-nav: hidden by default, shown as a fixed pill strip
   only below the 720px breakpoint (see the matching @media block). */
.mobile-section-nav { display: none; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: #fff;
  display: block;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
  cursor: pointer;
  border: 1.5px solid transparent;
}
.btn-primary {
  background: var(--accent);
  color: var(--navy-900);
  position: relative;
  overflow: hidden;
}
.btn-primary::before {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(115deg, transparent, rgba(255,255,255,0.55), transparent);
  transform: skewX(-20deg);
  transition: left 0.65s ease;
}
.btn-primary:hover::before { left: 130%; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 24px -10px rgba(201,162,74,0.6); }

.btn-ghost {
  border-color: rgba(255,255,255,0.4);
  color: #fff;
}
.btn-ghost:hover { border-color: #fff; background: rgba(255,255,255,0.08); transform: translateY(-2px); }

/* ---------- Icons ---------- */
/* Base rule for every <svg class="icon"><use href="#i-..."></svg> instance.
   Color comes from `color`, not a `stroke` override here -- each sprite
   symbol already sets stroke="currentColor" directly. */
.icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: radial-gradient(circle at 20% 20%, #182747 0%, var(--navy-900) 55%, #060a13 100%);
  color: #fff;
  overflow: hidden;
  padding: 140px 0 80px;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 30% 30%, black, transparent 70%);
  opacity: 0.6;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -10%;
  background: radial-gradient(circle at 25% 30%, rgba(201,162,74,0.16), transparent 55%),
              radial-gradient(circle at 75% 70%, rgba(47,93,245,0.14), transparent 55%);
  animation: heroDrift 22s ease-in-out infinite alternate;
  z-index: 0;
  pointer-events: none;
}
@keyframes heroDrift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(3%, -4%) scale(1.06); }
}
.hero-grid {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.hero-inner { max-width: 680px; flex-shrink: 0; }

.hero-visual { display: none; flex: 1; max-width: 360px; }
@media (min-width: 980px) {
  .hero-visual { display: block; }
}
.hero-visual.reveal { opacity: 1; transform: none; transition: none; }
.hero-visual-svg { width: 100%; height: auto; overflow: visible; }

.hero-particle {
  fill: rgba(255, 255, 255, 0.10);
  stroke: rgba(255, 255, 255, 0.16);
  stroke-width: 1;
  transform-box: fill-box;
  transform-origin: 50% 50%;
  transform: translate(var(--sx), var(--sy)) rotate(var(--sr));
  opacity: 0.5;
  transition: transform 1s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.7s ease, fill 0.7s ease, stroke 0.7s ease;
  transition-delay: var(--sd, 0ms);
}
.hero-visual.in-view .hero-particle {
  transform: translate(0, 0) rotate(0deg);
  opacity: 1;
  stroke: rgba(255, 255, 255, 0.22);
  animation: travelPulse 6s ease-in-out infinite;
  animation-delay: var(--pd, 0s);
}

/* Traveling highlight: sweeps bottom-to-top through the settled grid,
   staggered per tile via --pd (row + column offset, computed so the
   lowest row fires first). */
@keyframes travelPulse {
  0%, 8%, 100% { fill: rgba(255, 255, 255, 0.06); stroke: rgba(255, 255, 255, 0.22); }
  2.5%, 5% { fill: var(--accent); stroke: var(--accent); }
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  margin: 0 0 18px;
}

.hero h1 {
  font-size: clamp(2.4rem, 5.5vw, 3.8rem);
  line-height: 1.08;
  margin-bottom: 20px;
}
.hero h1 .accent { color: var(--accent); }

.hero-lede {
  font-size: 1.15rem;
  color: rgba(255,255,255,0.78);
  max-width: 560px;
  margin: 0 0 24px;
}

/* Compact editorial highlight row -- deliberately not a pill/chip (no
   border-radius:999px, no background fill): the site already leans on
   pill shapes elsewhere (.cs-scope-tag, .cs-filter-btn, .msn-pill), so
   this uses the existing .stat visual family (icon anchor + text, thin
   divider) as its model instead. flex-wrap is load-bearing: .hero-inner
   has no explicit width above the 900px breakpoint (only max-width:680px
   + flex-shrink:0), so an unwrapped row here could reintroduce the same
   class of horizontal-overflow bug the .eyebrow/.hero-inner fix addressed
   earlier -- this must wrap instead of forcing hero-inner wider. */
.hero-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 0;
  margin: 0 0 40px;
  padding: 0;
}
.hero-highlights li {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
  padding: 0 20px;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.78);
  border-left: 1px solid rgba(255, 255, 255, 0.14);
}
.hero-highlights li:first-child { padding-left: 0; border-left: none; }
.hero-highlights .icon { color: var(--accent); }

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, auto);
  gap: 36px;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.14);
}
.stat { display: flex; flex-direction: column; }
.stat-number {
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
}
.stat-label {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.6);
  margin-top: 2px;
}
.stat-label-only {
  align-self: center;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  max-width: 160px;
  line-height: 1.4;
}

/* ---------- Section divider wedges (bookend cuts around the dark hero/contact sections) ---------- */
.section-divider-top { position: relative; }
.section-divider-top::before {
  content: "";
  position: absolute;
  top: -72px;
  left: 0;
  width: 100%;
  height: 72px;
  clip-path: polygon(0 100%, 100% 0%, 100% 100%);
  pointer-events: none;
}
#about.section-divider-top::before { background: var(--paper); }
#contact.section-divider-top::before {
  background: var(--navy-900);
  clip-path: polygon(0 0%, 100% 100%, 0% 100%);
}
@media (max-width: 720px) {
  .section-divider-top::before { top: -40px; height: 40px; }
}

/* ---------- Sections ---------- */
.section { padding: 110px 0; }
.section-alt { background: var(--paper-alt); }
.section-contact {
  background: var(--navy-900);
  color: var(--text-invert);
}

.section-kicker {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--blue);
  margin: 0 0 12px;
}
.section-contact .section-kicker { color: var(--accent); }

.section-title {
  position: relative;
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  margin-bottom: 20px;
  max-width: 720px;
  padding-bottom: 14px;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 56px;
  background: linear-gradient(90deg, var(--accent), var(--blue));
  border-radius: 999px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1) 0.15s;
}
.section-title.in-view::after { transform: scaleX(1); }

.section-intro {
  font-size: 1.05rem;
  color: var(--text-soft);
  max-width: 640px;
  margin-bottom: 48px;
}
.section-contact .section-intro { color: rgba(238,241,247,0.72); }

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 56px;
  align-items: start;
}
.about-copy {
  font-size: 1.08rem;
  color: var(--text-soft);
}
.about-facts {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.about-facts li {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.about-facts strong {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--blue);
}
.about-facts span { color: var(--text-soft); font-size: 0.95rem; }

.about-copy p { font-size: 1.08rem; color: var(--text-soft); margin: 0 0 18px; }
.about-copy p:last-child { margin-bottom: 0; }

/* About capability chain (Workstream 02): Foundation -> Transformation ->
   Systems -> Delivery. Deliberately not a second Career timeline -- rail is
   segmented (a real gap between items, no border spans it) rather than
   continuous, and the marker/payoff below are independently defined rather
   than reusing .timeline-content li::before / .cs-section-lead directly, so
   this component isn't CSS-coupled to either. */
.about-chain-intro {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-soft);
  margin: 0 0 14px;
}
.about-chain {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
}
.about-chain li {
  position: relative;
  border-left: 1px solid var(--line);
  padding: 0 0 3px 20px;
  margin-bottom: 16px;
}
.about-chain li:last-child { margin-bottom: 0; }
.about-chain li::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 6px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
}
.about-chain strong {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.about-chain span {
  display: block;
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.5;
}
.about-chain-payoff {
  border-left: 3px solid var(--accent);
  padding-left: 20px;
  margin: 0;
  font-size: 1.08rem;
  color: var(--text-soft);
}

/* ---------- Solutions ---------- */
.solutions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.solution-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 26px;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.solution-card:hover { transform: translateY(-4px); box-shadow: 0 26px 55px -25px rgba(16,24,43,0.4); }
.solution-problem {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  font-style: italic;
  margin: 0;
}
.solution-arrow { color: var(--accent); font-size: 1.1rem; }
.solution-service {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--blue);
  margin: 0;
}
/* Icon sits on its own centered line above the text, not inline before it.
   Tried inline-before-text first and measured empirically: with the card's
   existing text-align:center and two of the three service names wrapping to
   2 lines at actual card width, align-items:center on an inline icon+text
   row centers the icon against the whole wrapped block rather than the
   first line -- on the "Tax & Regulatory Compliance / Advisory" card this
   put the icon beside "Advisory" alone, not the heading. Stacking sidesteps
   the problem entirely rather than fighting wrap-alignment on centered text. */
.solution-service .icon { width: 18px; height: 18px; }

/* ---------- Timeline ---------- */
.timeline {
  position: relative;
  padding-left: 32px;
  border-left: 2px solid var(--line);
}
.timeline-item { position: relative; padding-bottom: 48px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-marker {
  position: absolute;
  left: -40px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--paper-alt);
  border: 3px solid var(--blue);
}
.timeline-content {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 30px;
  box-shadow: var(--shadow);
}
.timeline-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 4px;
}
.timeline-head h3 { font-size: 1.2rem; }
.timeline-date {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blue);
  white-space: nowrap;
}
.timeline-org {
  font-weight: 600;
  color: var(--text-soft);
  margin: 0 0 16px;
}
.timeline-content ul { display: flex; flex-direction: column; gap: 10px; }
.timeline-content li {
  position: relative;
  padding-left: 18px;
  color: var(--text-soft);
  font-size: 0.96rem;
}
.timeline-content li::before {
  content: "";
  position: absolute;
  left: 0; top: 9px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.timeline-summary { margin: 0; color: var(--text-soft); font-size: 0.96rem; line-height: 1.6; }

/* ---------- Case Studies ---------- */
.cs-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 44px;
}
.cs-filter-btn {
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-soft);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 18px;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.cs-filter-btn:hover { border-color: var(--accent); color: var(--text); }
.cs-filter-btn.is-active {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: #fff;
}

.case-study-group { margin-bottom: 60px; }
.case-study-group:last-child { margin-bottom: 0; }
.case-study-group-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--navy-800);
  margin: 0 0 26px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
}
.case-study-group-count {
  margin-left: 10px;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--blue);
  white-space: nowrap;
}
.case-study-group-count::before {
  content: "\2014\0020";
  color: var(--text-soft);
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
}
.case-study-list { display: flex; flex-direction: column; gap: 16px; }

/* Engagement grouping: a lightweight wrapper around related Projects that
   belong to the same client engagement (Person -> Employer -> Engagement ->
   Project -> Case Study, per Brand Constitution Information Model). Purely
   presentational -- does not alter accordion markup or behavior. */
.engagement-group {
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-alt);
  padding: 18px 18px 2px;
  margin: 8px 0;
}
.engagement-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 14px;
  padding: 2px 6px 16px;
}
.engagement-name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--navy-800);
}
.engagement-meta {
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--blue);
}
.engagement-projects {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-bottom: 16px;
}

.case-study-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.cs-summary-btn {
  width: 100%;
  font-family: inherit;
  color: inherit;
  background: none;
  border: none;
  text-align: left;
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 28px;
}
.cs-summary-btn:hover { background: var(--paper-alt); }

.cs-summary-head { display: flex; flex-direction: column; gap: 4px; }
.cs-name { font-size: 1.1rem; font-weight: 700; color: var(--text); }
.cs-industry { font-size: 0.85rem; color: var(--text-soft); }
.cs-expand-icon {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--paper-alt);
  color: var(--blue);
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease;
}
.case-study-card.is-open .cs-expand-icon { transform: rotate(45deg); }

/* Always-visible scannable preview, sitting between the toggle button and the
   expand-only body. A plain sibling div (not native <details> content), so it
   renders and stays in the accessibility tree regardless of open state. */
.cs-teaser {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 7px;
  padding: 0 28px 20px;
  margin-top: -6px;
}
.case-study-card.is-open .cs-teaser {
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}
.cs-teaser-facts {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 3px 16px;
  font-size: 0.82rem;
  color: var(--text-soft);
}
.cs-teaser-facts strong {
  color: var(--blue);
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-right: 5px;
}
.cs-teaser-line {
  margin: 0;
  max-width: 62ch;
  font-size: 0.92rem;
  line-height: 1.45;
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cs-teaser-outcome {
  color: var(--text-soft);
  font-weight: 600;
}
.cs-teaser-outcome::before { content: "\2192\0020"; color: var(--accent); font-weight: 700; }

.cs-flow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 6px;
  margin: 1px 0 0;
}
.cs-flow-step {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-soft);
  background: var(--paper-alt);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 10px;
  white-space: nowrap;
}
.cs-flow-arrow { color: var(--accent); font-size: 0.72rem; }

.cs-view-btn {
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--blue);
  background: none;
  border: none;
  padding: 0;
  margin-top: 2px;
  cursor: pointer;
}
.cs-view-btn:hover { color: var(--navy-800); text-decoration: underline; }

.cs-body { height: 0; padding: 24px 28px 28px; overflow: hidden; transition: height 0.32s cubic-bezier(0.65, 0, 0.35, 1); }
.cs-scope-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy-900);
  background: var(--accent-soft);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.cs-teaser .cs-scope-tag { margin: 0 0 1px; }
.cs-meta {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 0 0 26px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.cs-meta dt {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--blue);
  margin-bottom: 4px;
}
.cs-meta dd { margin: 0; font-size: 0.9rem; color: var(--text); font-weight: 600; }

/* Role leads the metadata block -- it's the fastest answer to "what did
   Rex do here," so it gets its own row above Technology/Methodology/Phase
   rather than sitting as an equal-weight fourth-of-four fact. */
.cs-meta > div:first-child {
  grid-column: 1 / -1;
  padding-bottom: 14px;
  margin-bottom: 4px;
  border-bottom: 1px dashed var(--line);
}
.cs-meta > div:first-child dt { color: var(--accent); }
.cs-meta > div:first-child dd { font-size: 1.05rem; }

.cs-section { margin-bottom: 20px; }
.cs-section:last-child { margin-bottom: 0; }
.cs-section h4 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-soft);
  margin: 0 0 6px;
}
.cs-section p { margin: 0; font-size: 0.96rem; color: var(--text); line-height: 1.6; }

/* Responsibilities = "what Rex actually did" -- the step the visitor
   journey most needs to find quickly between Challenge and Deliverables. */
.cs-section-lead {
  padding-left: 14px;
  border-left: 3px solid var(--accent);
}
.cs-section-lead h4 { color: var(--navy-800); }

/* Lessons Learned is always the last .cs-section in a card -- demoted here
   structurally (no extra class needed) so it reads as secondary to Challenge/
   Responsibilities/Deliverables/Outcome, per the "read if interested" tier. */
.cs-body .cs-section:last-child {
  margin-top: 6px;
  padding-top: 16px;
  border-top: 1px dashed var(--line);
}
.cs-body .cs-section:last-child h4 {
  color: var(--text-soft);
  opacity: 0.85;
}
.cs-body .cs-section:last-child p {
  font-size: 0.87rem;
  font-style: italic;
  color: var(--text-soft);
}

.case-study-card.cs-pending {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 28px;
  background: var(--paper-alt);
  box-shadow: none;
}
.cs-pending-note {
  margin: 0;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--text-soft);
  white-space: nowrap;
}

/* ---------- Skills ---------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.skill-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
}
.skill-card h3 {
  position: relative;
  font-size: 1.02rem;
  margin-bottom: 16px;
  color: var(--navy-800);
}
/* Icon sits at a negative left offset, borrowing space from .skill-card's
   own existing left padding (28px) rather than from the heading's text box.
   Two approaches were tried and measured empirically before landing here:
   (1) flex sibling -- ate into text width, pushed "Business Process &
   Solution Design" from 1 line to 2, which grew the whole first row 23px
   via .skills-grid's default row-stretch; (2) absolute + padding-left on
   the h3 -- same problem, the padding consumes the same width the flex gap
   did. Only a negative offset with zero padding added to the heading itself
   leaves the text box exactly as wide as before icons existed. Verified:
   every .skill-card height is now identical to the pre-icon baseline. */
.skill-card h3 .icon {
  position: absolute;
  left: -24px;
  top: 3px;
  width: 16px;
  height: 16px;
}
.skill-card ul { display: flex; flex-direction: column; gap: 9px; }
.skill-card li {
  position: relative;
  padding-left: 16px;
  font-size: 0.9rem;
  color: var(--text-soft);
}
.skill-card li::before {
  content: "";
  position: absolute;
  left: 0; top: 8px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--blue);
}

/* ---------- Certifications ---------- */
.cred-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.cred-block {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 32px;
}
.cred-block h3 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--blue);
  margin-bottom: 20px;
}
.cred-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.cred-item:last-child { border-bottom: none; padding-bottom: 0; }
.cred-name { font-weight: 600; }
.cred-meta { font-size: 0.85rem; color: var(--text-soft); }

/* ---------- Contact ---------- */
.contact-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}
.contact-inner { max-width: 680px; flex-shrink: 0; }
.contact-visual.hero-visual { display: none; }
@media (min-width: 980px) {
  .contact-visual.hero-visual { display: block; }
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 40px;
}
.contact-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: var(--radius);
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: background 0.2s ease, transform 0.2s ease;
}
.contact-card:not(.contact-card-static):hover {
  background: rgba(255,255,255,0.12);
  transform: translateY(-3px);
}
.contact-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
}
.contact-label .icon { width: 18px; height: 18px; }
/* The LinkedIn mark is a Simple Icons brand glyph (fill="currentColor" on
   its own <symbol>, no stroke) -- .icon-brand exists to keep that treatment
   visually/structurally distinct from the Lucide stroke icons above, even
   though the base .icon rule itself sets no fill/stroke (those live on each
   symbol's own path), so there's no actual property collision to override. */
.contact-label .icon-brand { width: 17px; height: 17px; }
.contact-value {
  font-size: 0.95rem;
  font-weight: 600;
  word-break: break-word;
}
.contact-cta { margin-bottom: 0; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--ink);
  color: rgba(238,241,247,0.55);
  padding: 26px 0;
  font-size: 0.85rem;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
}
.footer-contact {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}
.footer-contact a {
  color: rgba(238,241,247,0.55);
  transition: color 0.2s ease;
}
.footer-contact a:hover { color: var(--accent); }

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; }
  .solutions-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: repeat(2, 1fr); }
  .cred-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: repeat(2, 1fr); }
  .stat-row { grid-template-columns: repeat(2, auto); row-gap: 24px; }
  .cs-meta { grid-template-columns: repeat(2, 1fr); }

  /* .hero-visual / .contact-visual are already display:none below 980px,
     so .hero-inner / .contact-inner are the sole flex child here -- but
     flex-shrink:0 + width:auto still sizes them to their content's
     max-content width (e.g. .eyebrow has no max-width), which can exceed
     the viewport and push the whole page into horizontal overflow. An
     explicit width overrides that sizing outright. */
  .hero-inner, .contact-inner { width: 100%; max-width: none; flex-shrink: 1; }
}

@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--navy-900);
    padding: 8px 24px 20px;
    transform: translateY(-120%);
    transition: transform 0.3s ease;
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links li { width: 100%; }
  .nav-links a { display: block; padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,0.08) !important; }
  .nav-cta { margin-top: 8px; display: inline-block; }

  .skills-grid { grid-template-columns: 1fr; }
  .section { padding: 80px 0; }

  /* Mobile section quick-nav: horizontally-scrolling pill strip fixed under
     the header, mirroring the desktop active-section highlighting so a
     visitor can jump anywhere in one tap instead of opening the hamburger
     menu each time. */
  .mobile-section-nav {
    display: flex;
    position: fixed;
    top: 64px; left: 0; right: 0;
    z-index: 890;
    gap: 8px;
    padding: 10px 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    background: rgba(11, 18, 32, 0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }
  .mobile-section-nav::-webkit-scrollbar { display: none; }

  .msn-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    font-size: 0.78rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.65);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 7px 14px;
    white-space: nowrap;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  }
  .msn-pill::before {
    content: "";
    width: 6px; height: 6px;
    border-radius: 50%;
    background: var(--accent);
    flex-shrink: 0;
  }
  .msn-pill[data-color="blue"]::before { background: var(--blue); }
  .msn-pill.msn-active {
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.32);
  }

  .hero { padding-top: 190px; }
  section[id] { scroll-margin-top: 124px; }

  .hero-highlights { flex-direction: column; align-items: flex-start; gap: 14px; }
  .hero-highlights li { border-left: none; border-top: 1px solid rgba(255, 255, 255, 0.14); padding: 14px 0 0; }
  .hero-highlights li:first-child { border-top: none; padding-top: 0; }
}

@media (max-width: 520px) {
  .contact-grid { grid-template-columns: 1fr; }
  .hero { padding-top: 170px; }
  .cs-meta { grid-template-columns: 1fr; }
  .cs-summary-btn { padding: 20px; }
  .cs-teaser { padding: 0 20px 18px; }
  .cs-body { padding: 20px; }
  .case-study-card.cs-pending {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}
