/* =========================================================================
   Johnmark Ochieng · "Mission control" theme
   Light paper sections alternate with deep-space navy sections and cards.
   Colours, fonts, radii and motion timings are all set here.
   ========================================================================= */
:root {
  --paper: #f5f3ee;
  --paper-2: #ece8df;
  --white: #ffffff;
  --ink: #0b1626;          /* deep space navy */
  --ink-2: #102038;        /* dark card */
  --ink-3: #1a2d4a;        /* dark card border / hover */
  --muted: #5b6472;
  --muted-dark: #9aa8bd;   /* secondary text on navy */
  --line: #ddd7cc;
  --line-dark: rgba(255, 255, 255, 0.1);
  --accent: #e8521f;       /* mission orange */
  --accent-soft: #ff8a5c;  /* orange for small text on navy */
  --sky: #8fb4ff;          /* starlight blue, for small details on navy */
  --radius: 14px;
  --shadow: 0 1px 2px rgba(11, 22, 38, 0.05), 0 10px 30px rgba(11, 22, 38, 0.07);
  --shadow-lift: 0 2px 4px rgba(11, 22, 38, 0.06), 0 22px 44px rgba(11, 22, 38, 0.14);
  --max: 1180px;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Public Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --fast: 200ms;
  --base: 420ms;
  --slow: 800ms;
  --ease: cubic-bezier(.2, .75, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.12; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h2 { font-size: clamp(2.1rem, 4.4vw, 3.2rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
.mono { font-family: var(--mono); }
main { overflow-x: clip; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }
section[id] { scroll-margin-top: 80px; }

/* ---------- Dark sections ---------- */
.dark { position: relative; background: var(--ink); color: #e8eef7; }
.dark-2 { background: #0e1b2e; color: #e8eef7; }
.dark .intro, .dark p { color: var(--muted-dark); }
.dark h2, .dark h3 { color: var(--white); }
.sky { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 0; }

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 999px; border: 1px solid transparent;
  font: 600 0.95rem var(--sans); text-decoration: none; cursor: pointer;
  transition: background var(--fast), color var(--fast), border-color var(--fast), transform var(--fast) var(--ease), box-shadow var(--fast);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.btn-sm { padding: 9px 18px; font-size: 0.88rem; }
.btn-accent { background: var(--accent); color: var(--white); box-shadow: 0 6px 20px rgba(232, 82, 31, 0.3); }
.btn-accent:hover { background: #ff6a33; box-shadow: 0 10px 28px rgba(232, 82, 31, 0.45); }
.btn-dark { background: var(--ink); color: var(--white); }
.btn-dark:hover { background: var(--accent); }
.btn-ghost, .btn-ghost-light { border-color: rgba(255, 255, 255, 0.3); color: var(--white); }
.btn-ghost:hover, .btn-ghost-light:hover { border-color: var(--white); background: rgba(255, 255, 255, 0.08); }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 0.95rem; text-decoration: none; border-bottom: 1px solid var(--accent); padding-bottom: 2px; }
.link-arrow::after { content: "→"; color: var(--accent); transition: transform var(--fast) var(--ease); }
.link-arrow:hover::after, a:hover > .link-arrow::after, .article:hover .link-arrow::after { transform: translateX(5px); }
.dark .link-arrow::after { color: var(--accent-soft); }

/* ---------- Cards ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); transition: transform var(--base) var(--ease), box-shadow var(--base) var(--ease), border-color var(--base); }
.card-dark { position: relative; background: linear-gradient(160deg, var(--ink-3), var(--ink-2) 55%); border: 1px solid var(--line-dark); border-radius: var(--radius); color: #e8eef7; transition: transform var(--base) var(--ease), border-color var(--base), box-shadow var(--base); }
/* Cursor spotlight on cards (position set by main.js) */
.glow { isolation: isolate; overflow: hidden; }
.glow::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity var(--base); pointer-events: none;
  background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(232, 82, 31, 0.22), transparent 60%); }
.glow:hover::before { opacity: 1; }
.card.glow:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); border-color: rgba(232, 82, 31, 0.4); }
.card.glow::before { background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), rgba(232, 82, 31, 0.08), transparent 60%); }
.card-dark:hover { border-color: rgba(232, 82, 31, 0.45); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35); }

/* ---------- Scroll progress + back to top ---------- */
.scroll-progress { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 30; background: linear-gradient(90deg, var(--accent), var(--accent-soft)); transform: scaleX(0); transform-origin: 0 50%; pointer-events: none; }
.to-top { position: fixed; right: 20px; bottom: 20px; z-index: 25; width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; border: 0; background: var(--ink); color: var(--white); box-shadow: 0 8px 24px rgba(11, 22, 38, 0.3); cursor: pointer; opacity: 0; visibility: hidden; transform: translateY(12px) scale(.9); transition: opacity var(--base) var(--ease), transform var(--base) var(--ease), visibility 0s linear var(--base), background var(--fast); }
.to-top.is-shown { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.to-top:hover { background: var(--accent); }
.to-top:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Navigation (dark glass) ---------- */
.nav { position: sticky; top: 0; z-index: 20; background: rgba(11, 22, 38, 0.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line-dark); color: var(--white); }
.nav-inner { max-width: var(--max); margin: 0 auto; padding: 13px 24px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-mark { width: 34px; height: 34px; filter: invert(1) hue-rotate(180deg); transition: transform var(--base) var(--ease); }
.logo:hover .logo-mark { transform: rotate(-12deg) scale(1.08); }
.logo-word { font-family: var(--serif); font-size: 1.3rem; font-weight: 600; white-space: nowrap; }
.nav nav { display: flex; align-items: center; gap: 24px; }
.nav nav a:not(.btn) { position: relative; text-decoration: none; font-size: 0.92rem; font-weight: 500; color: rgba(255, 255, 255, 0.7); transition: color var(--fast); }
.nav nav a:not(.btn):hover, .nav nav a.active { color: var(--white); }
.nav nav a:not(.btn)::after { content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px; border-radius: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform var(--base) var(--ease); }
.nav nav a.active::after, .nav nav a:not(.btn):hover::after, .nav nav a:not(.btn):focus-visible::after { transform: scaleX(1); }
.nav a:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 3px; }
.nav-toggle { display: none; background: none; border: 1px solid rgba(255, 255, 255, 0.4); color: var(--white); padding: 7px 16px; border-radius: 999px; font: 600 0.9rem var(--sans); cursor: pointer; }

/* ---------- Hero ---------- */
.hero { min-height: calc(100vh - 62px); display: flex; align-items: center; padding: 64px 0 96px; overflow: hidden;
  background: radial-gradient(70% 60% at 78% 40%, #1a3156 0%, transparent 70%), radial-gradient(50% 50% at 0% 100%, rgba(232, 82, 31, 0.14), transparent 70%), var(--ink); }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 72px; align-items: center; width: 100%; }
.kicker { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-soft); margin-bottom: 22px; padding: 7px 14px; border: 1px solid rgba(255, 138, 92, 0.3); border-radius: 999px; background: rgba(232, 82, 31, 0.08); }
.kicker-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(232, 82, 31, 0.6); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(232, 82, 31, 0); } 100% { box-shadow: 0 0 0 0 rgba(232, 82, 31, 0); } }
.hero h1 { font-size: clamp(3.2rem, 7.4vw, 6.2rem); line-height: 1; letter-spacing: -0.03em; color: var(--white); margin-bottom: 20px; }
.hero h1 em { color: var(--accent); background: linear-gradient(90deg, var(--accent), #ffb26b, var(--accent)); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 6s ease-in-out infinite; padding-right: .06em; }
@keyframes shimmer { 50% { background-position: 100% 0; } }
.hero-roles { display: flex; align-items: baseline; gap: 12px; margin-bottom: 18px; font-family: var(--serif); font-size: clamp(1.3rem, 2.4vw, 1.75rem); color: var(--white); }
.hero-roles .mono { font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted-dark); }
.role-rotator { position: relative; display: inline-grid; height: 1.3em; overflow: hidden; color: var(--sky); font-style: italic; }
.role-rotator span { grid-area: 1 / 1; transform: translateY(110%); opacity: 0; transition: transform .6s var(--ease), opacity .6s; white-space: nowrap; }
.role-rotator span.is-on { transform: none; opacity: 1; }
.role-rotator span.is-out { transform: translateY(-110%); opacity: 0; }
html:not(.js) .role-rotator span:first-child { transform: none; opacity: 1; }
.lede { font-size: clamp(1.05rem, 1.5vw, 1.18rem); color: var(--muted-dark); max-width: 33rem; margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Photo with planet, orbit and satellite */
.hero-photo { position: relative; margin: 0 40px 0 auto; width: 100%; max-width: 430px; aspect-ratio: 911 / 1230; }
.planet { position: absolute; left: -10%; right: -10%; top: 10%; aspect-ratio: 1; border-radius: 50%; z-index: 0;
  background: radial-gradient(circle at 32% 28%, #2c4a7c 0%, #16294a 45%, #0d1a30 75%);
  box-shadow: inset -30px -30px 80px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(143, 180, 255, 0.12), 0 0 90px rgba(143, 180, 255, 0.22), 18px -10px 70px -20px rgba(232, 82, 31, 0.5);
  }
@keyframes float { 50% { transform: translateY(-10px); } }
.hero-cutout { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; z-index: 2;
  /* Union of two shapes: everything above the planet's centre line, plus the planet disc itself.
     Planet = 120% of the photo width, top at 10% of its height, so its centre is at 54.4% of the
     height and its radii are 60% (of width) and 44.4% (of height). */
  -webkit-mask-image: linear-gradient(to bottom, #000 54.4%, transparent 54.4%), radial-gradient(ellipse 60% 44.4% at 50% 54.4%, #000 99.4%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 54.4%, transparent 54.4%), radial-gradient(ellipse 60% 44.4% at 50% 54.4%, #000 99.4%, transparent 100%); }
.hero-orbit { position: absolute; left: -24%; width: 148%; top: 27%; aspect-ratio: 2 / 1; pointer-events: none; overflow: visible; }
.orbit-back { z-index: 1; }
.orbit-front { z-index: 3; }
.orbit-path { fill: none; stroke: var(--accent); stroke-width: 1.4; stroke-dasharray: 3 6; animation: dash 30s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -900; } }
.sat-body { fill: var(--accent); }
.sat-panel { fill: #a9c4ff; stroke: var(--white); stroke-width: .6; }
.sat-grid { stroke: var(--ink); stroke-width: .6; opacity: .5; }
.sat-mast { stroke: var(--accent); stroke-width: 1.2; }
.sat-dish { fill: var(--accent); }
.photo-tag { position: absolute; z-index: 4; left: -14%; bottom: 14%; font-size: 0.72rem; letter-spacing: 0.06em; color: var(--white); background: rgba(11, 22, 38, 0.75); border: 1px solid var(--line-dark); padding: 6px 12px; border-radius: 999px; backdrop-filter: blur(6px); }
.scroll-cue { position: absolute; z-index: 2; left: 50%; bottom: 26px; width: 26px; height: 42px; margin-left: -13px; border: 2px solid rgba(255, 255, 255, 0.35); border-radius: 14px; }
.scroll-cue span { position: absolute; top: 8px; left: 50%; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--accent); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* Hero entrance */
.js .hero-copy > *, .js .hero-photo { opacity: 0; transform: translateY(24px); animation: rise 1s var(--ease) forwards; }
.js .hero-copy > *:nth-child(2) { animation-delay: .1s; }
.js .hero-copy > *:nth-child(3) { animation-delay: .2s; }
.js .hero-copy > *:nth-child(4) { animation-delay: .3s; }
.js .hero-copy > *:nth-child(5) { animation-delay: .4s; }
.js .hero-photo { animation-delay: .25s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Trust marquee ---------- */
.trust { padding: 10px 0; border-top: 1px solid var(--line-dark); border-bottom: 1px solid var(--line-dark); }
.trust-row { display: grid; grid-template-columns: max-content 1fr; align-items: center; }
.trust-row + .trust-row { border-top: 1px solid var(--line-dark); }
.trust-label { margin: 0; padding-left: max(24px, calc((100vw - var(--max)) / 2 + 24px)); padding-right: 28px; min-width: 0; font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-soft); white-space: nowrap; }
.marquee { overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee-track { display: flex; width: max-content; animation: marquee 40s linear infinite; }
.marquee-reverse .marquee-track { animation-direction: reverse; animation-duration: 46s; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.trust-list { list-style: none; margin: 0; padding: 14px 0; display: flex; }
.trust-list li { font-family: var(--serif); font-size: 1.15rem; color: #dbe4f1; white-space: nowrap; padding: 0 22px; display: flex; align-items: center; gap: 44px; }
.trust-list li::after { content: "✦"; font-size: 0.7rem; color: var(--accent); margin-right: -22px; }
@keyframes marquee { to { transform: translateX(-50%); } }
html:not(.js) .trust-list { flex-wrap: wrap; }

/* ---------- Stats ---------- */
.stats { padding: 56px 0 80px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.stat { padding: 28px 24px; }
.stat strong { display: block; font-family: var(--serif); font-weight: 500; font-size: clamp(2.8rem, 5vw, 3.8rem); line-height: 1; margin-bottom: 10px; color: var(--ink); font-variant-numeric: tabular-nums; }
.stat strong::after { content: ""; display: block; width: 32px; height: 3px; margin-top: 14px; border-radius: 2px; background: var(--accent); }
.stat span { font-size: 0.92rem; color: var(--muted); }

/* ---------- Sections ---------- */
.section { position: relative; padding: 110px 0; }
.section-alt { background: var(--paper-2); }
.section-head { margin-bottom: 48px; }
.section-head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 0.78rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.eyebrow::before { content: "//"; opacity: .6; }
.dark .eyebrow, .eyebrow-light { color: var(--accent-soft); }
.intro { color: var(--muted); font-size: 1.08rem; max-width: 58ch; margin: 0; }
.split-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 64px; align-items: start; }
.split-grid .section-head { margin: 0; position: sticky; top: 110px; }
.body-lg { font-family: var(--serif); font-size: clamp(1.3rem, 2.2vw, 1.6rem); line-height: 1.45; }
.split-grid p:not(.body-lg):not(.eyebrow) { color: var(--muted); }
.split-grid p a, .extras p a, .intro a { color: inherit; text-decoration-color: var(--accent); text-underline-offset: 3px; transition: color var(--fast), text-underline-offset var(--fast); }
.split-grid p a:hover, .extras p a:hover, .intro a:hover { color: var(--accent); text-underline-offset: 6px; }
.facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin: 32px 0 0; }
.fact { padding: 18px 18px 16px; }
.fact:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.fact dt { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.fact dd { margin: 0; font-weight: 600; line-height: 1.35; }

/* ---------- Services (dark cards) ---------- */
.services { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.service { display: flex; flex-direction: column; align-items: flex-start; padding: 32px; transform-style: preserve-3d; }
.service-top { display: flex; justify-content: space-between; align-items: center; width: 100%; margin-bottom: 20px; }
.service-icon { width: 52px; height: 52px; padding: 10px; border-radius: 12px; background: rgba(232, 82, 31, 0.12); border: 1px solid rgba(232, 82, 31, 0.3); fill: none; stroke: var(--accent-soft); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform var(--base) var(--ease), background var(--base); }
.service-icon * { stroke-dasharray: 160; stroke-dashoffset: 0; }
.js .service:not(.is-visible) .service-icon * { stroke-dashoffset: 160; }
.service.is-visible .service-icon * { transition: stroke-dashoffset 1.6s var(--ease) .3s; }
.service:hover .service-icon { transform: rotate(-8deg) scale(1.08); background: rgba(232, 82, 31, 0.22); }
.service-num { font-size: 0.85rem; color: var(--muted-dark); }
.service h3 { font-size: 1.6rem; margin-bottom: 12px; }
.service > p { color: var(--muted-dark); font-size: 0.98rem; }
.service ul { list-style: none; padding: 0; margin: 8px 0 28px; width: 100%; border-top: 1px solid var(--line-dark); }
.service li { position: relative; padding: 9px 0 9px 22px; font-size: 0.93rem; color: #d7e0ee; border-bottom: 1px solid var(--line-dark); }
.service li::before { content: ""; position: absolute; left: 0; top: 1.05em; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--accent); }
.service .link-arrow { margin-top: auto; color: var(--white); }

/* ---------- Speaking: filters + event cards ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin: -16px 0 28px; }
.filter { font: 600 0.9rem var(--sans); padding: 9px 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--white); color: var(--ink); cursor: pointer; transition: background var(--fast), color var(--fast), border-color var(--fast), transform var(--fast) var(--ease); }
.filter:hover { border-color: var(--ink); transform: translateY(-1px); }
.filter.is-on { background: var(--ink); color: var(--white); border-color: var(--ink); }
.filter:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.filter .count { font-family: var(--mono); font-size: 0.75rem; margin-left: 6px; opacity: .6; }
.events { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.event { display: grid; grid-template-columns: 96px 1fr; grid-template-rows: auto auto; gap: 4px 18px; padding: 20px 22px; align-items: start; }
.event:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); border-color: rgba(232, 82, 31, 0.4); }
.event.is-hidden { display: none; }
.event.is-filtered-in { animation: pop .45s var(--ease); }
@keyframes pop { from { opacity: 0; transform: scale(.96) translateY(8px); } }
.ev-date { grid-row: 1 / 3; align-self: start; display: inline-block; text-align: center; font-size: 0.78rem; line-height: 1.3; padding: 10px 6px; border-radius: 10px; background: var(--ink); color: var(--white); }
.ev-main h3 { font-size: 1.22rem; margin: 0 0 4px; }
.ev-main p { margin: 0; color: var(--muted); font-size: 0.93rem; }
.ev-role { grid-column: 2; justify-self: start; margin-top: 6px; font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.events-more { margin: 30px 0 0; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center; }

/* ---------- Writing: article cards ---------- */
.articles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.article { display: flex; flex-direction: column; overflow: hidden; text-decoration: none; }
.article:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.img-frame { display: block; overflow: hidden; background: var(--line); }
.img-frame img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; transition: transform var(--slow) var(--ease); }
.article:hover .img-frame img { transform: scale(1.06); }
.article-body { padding: 18px 20px 22px; }
.article h3 { font-size: 1.18rem; margin: 0; transition: color var(--fast); }
.article:hover h3 { color: var(--accent); }
.article-meta { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
.article-lead { grid-column: span 2; grid-row: span 2; }
.article-lead .img-frame img { aspect-ratio: 16 / 9.4; }
.article-lead .article-body { padding: 26px 28px 30px; }
.article-lead h3 { font-size: clamp(1.7rem, 3vw, 2.3rem); margin-bottom: 12px; }
.article-lead p:not(.article-meta) { color: var(--muted); }

/* ---------- Experience: mission log ---------- */
.jobs { position: relative; list-style: none; margin: 0; padding: 0 0 0 44px; }
.jobs::before, .jobs::after { content: ""; position: absolute; left: 11px; top: 8px; bottom: 8px; width: 2px; border-radius: 2px; }
.jobs::before { background: var(--line); }
.jobs::after { background: linear-gradient(var(--accent), var(--accent-soft)); transform-origin: top; transform: scaleY(var(--progress, 0)); }
.job { position: relative; margin-bottom: 18px; }
.job-node { position: absolute; left: -44px; top: 26px; width: 24px; height: 24px; border-radius: 50%; background: var(--white); border: 2px solid var(--line); transition: border-color var(--base), box-shadow var(--base); }
.job-node::after { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: var(--line); transition: background var(--base); }
.job.is-reached .job-node { border-color: var(--accent); box-shadow: 0 0 0 6px rgba(232, 82, 31, 0.15), 0 0 20px rgba(232, 82, 31, 0.5); }
.job.is-reached .job-node::after { background: var(--accent); }
.job-card { padding: 26px 28px; }
.js .job-card.glow:hover, .job-card:hover { transform: translateX(6px); }
.job-card p:not(.job-org) { color: var(--muted); }
.job-date { display: inline-block; font-size: 0.75rem; letter-spacing: 0.06em; color: var(--accent); margin-bottom: 10px; }
.jobs h3 { font-size: 1.45rem; margin: 0 0 2px; }
.job-org { color: var(--accent); font-weight: 600; font-size: 0.95rem; margin: 0 0 10px; }
.job-card p:last-child { margin: 0; }
.extras { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 28px; }
.extras > div { padding: 22px 24px; }
.extras h3 { font-family: var(--mono); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
.dark .extras p { margin: 0; color: #d7e0ee; }

/* ---------- Contact ---------- */
.contact { position: relative; padding: 110px 0; color: var(--white); overflow: hidden;
  background: radial-gradient(60% 80% at 100% 0%, rgba(232, 82, 31, 0.25), transparent 60%), radial-gradient(60% 80% at 0% 100%, #1a3156, transparent 70%), var(--ink); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.contact h2 { font-size: clamp(2.3rem, 4.6vw, 3.6rem); color: var(--white); }
.contact .intro { color: var(--muted-dark); }
.contact .eyebrow { color: var(--accent-soft); }
.contact-card { padding: 32px; }
.contact-email { display: block; font-family: var(--serif); font-size: clamp(1.4rem, 2.8vw, 2.2rem); color: var(--white); text-decoration: none; word-break: break-word; margin-bottom: 14px; transition: color var(--fast); }
.contact-email:hover { color: var(--accent-soft); }
.copy-email { font: 500 0.8rem var(--mono); letter-spacing: 0.04em; color: var(--muted-dark); background: none; border: 1px dashed rgba(255, 255, 255, 0.25); border-radius: 999px; padding: 6px 14px; margin-bottom: 26px; cursor: pointer; transition: color var(--fast), border-color var(--fast); }
.copy-email:hover { color: var(--white); border-color: var(--white); }
.copy-email.is-done { color: #7ee2a8; border-color: #7ee2a8; border-style: solid; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 22px; border-top: 1px solid var(--line-dark); }

/* ---------- Footer ---------- */
.footer { background: #08111e; color: rgba(255, 255, 255, 0.55); font-size: 0.88rem; }
.footer-inner { display: flex; justify-content: space-between; gap: 16px; padding: 22px 24px; }
.footer p { margin: 0; }
.footer a { text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: color var(--fast), background-size var(--base) var(--ease); }
.footer a:hover { color: var(--white); background-size: 100% 1px; }

/* ---------- Reveal on scroll ---------- */
.js [data-reveal], .js .reveal { opacity: 0; transform: translateY(28px); transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease); }
.js [data-reveal].is-visible, .js .reveal.visible { opacity: 1; transform: none; }
.js .card[data-reveal].is-visible:hover, .js .event[data-reveal].is-visible:hover { transform: translateY(-4px); }
.js .article[data-reveal].is-visible:hover { transform: translateY(-6px); }
.js .fact:hover { transform: translateY(-4px); }

/* ---------- Rates page ---------- */
.rates-hero { position: relative; padding: 70px 0 80px; overflow: hidden; background: radial-gradient(60% 80% at 85% 20%, #1a3156, transparent 70%), var(--ink); color: var(--white); }
.rates-hero .kicker { display: inline-flex; }
.back-link { display: table; font-size: 0.9rem; font-weight: 600; color: var(--muted-dark); text-decoration: none; margin-bottom: 30px; transition: color var(--fast), transform var(--fast); }
.back-link:hover { color: var(--accent-soft); transform: translateX(-4px); }
.rates-hero h1 { font-size: clamp(2.8rem, 6.5vw, 5rem); line-height: 1.02; letter-spacing: -0.02em; color: var(--white); margin-bottom: 20px; }
.rates-hero h1 em { color: var(--accent); }
.rates-hero .lede { color: var(--muted-dark); }
.rate-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.rate-card { position: relative; display: flex; flex-direction: column; padding: 30px 24px 26px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); transition: transform var(--base) var(--ease), box-shadow var(--base); }
.rate-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.rate-card h3 { font-size: 1.45rem; }
.rate-desc { color: var(--muted); font-size: 0.95rem; flex: 1; }
.rate-prices { display: grid; gap: 10px; margin-top: 14px; padding-top: 16px; border-top: 1px solid var(--line); }
.rate-prices div { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.rate-prices span { color: var(--muted); font-size: 0.85rem; }
.rate-prices strong { font-family: var(--serif); font-weight: 500; font-size: 1.75rem; font-variant-numeric: tabular-nums; }
.rate-prices strong::before { content: "KES "; font-family: var(--mono); font-size: 0.68rem; color: var(--muted); vertical-align: 0.6em; }
.rate-card-best { overflow: visible; background: linear-gradient(160deg, var(--ink-3), var(--ink)); color: var(--white); border-color: rgba(232, 82, 31, 0.5); box-shadow: 0 20px 50px rgba(11, 22, 38, 0.3); }
.rate-card-best .rate-desc, .rate-card-best .rate-prices span, .rate-card-best .rate-prices strong::before { color: var(--muted-dark); }
.rate-card-best .rate-prices { border-color: var(--line-dark); }
.rate-badge { position: absolute; top: -11px; right: 18px; background: var(--accent); color: var(--white); font: 500 0.66rem var(--mono); letter-spacing: 0.08em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; }
.rate-note { margin: 24px 0 0; color: var(--muted); }
.rate-note strong { color: var(--ink); }
.content-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.content-col { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 22px 8px; }
.content-col h3 { font-size: 1.3rem; margin-bottom: 4px; }
.addon-list, .check-list { list-style: none; padding: 0; margin: 16px 0 0; }
.addon-list li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.addon-list li:last-child { border-bottom: 0; }
.addon-list li span { color: var(--muted); }
.addon-list strong { font-variant-numeric: tabular-nums; white-space: nowrap; }
.content-col .addon-list li { flex-direction: column; gap: 2px; }
.content-col .addon-list strong { font-family: var(--serif); font-weight: 500; font-size: 1.1rem; }
.incl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.incl-grid > div { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 30px; }
.incl-grid h2 { font-size: clamp(1.8rem, 3.2vw, 2.4rem); }
.check-list li { position: relative; padding: 12px 0 12px 32px; border-bottom: 1px solid var(--line); }
.check-list li:last-child { border-bottom: 0; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 11px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; background: rgba(232, 82, 31, 0.12); color: var(--accent); font-size: 0.75rem; font-weight: 700; }
.estimator { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: start; }
.est-controls { display: grid; gap: 26px; align-content: start; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 30px; }
.est-controls fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.est-controls fieldset[hidden], .est-panel[hidden] { display: none; }
.est-controls legend { font: 500 0.72rem var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; padding: 0; }
.est-tabs { display: flex; border-bottom: 1px solid var(--line); margin: -8px 0 4px; }
.est-tabs button { flex: 1; background: none; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; padding: 12px 8px; font: 600 0.95rem var(--sans); color: var(--muted); cursor: pointer; transition: color var(--fast), border-color var(--fast); }
.est-tabs button:hover { color: var(--ink); }
.est-tabs button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); }
.tab-count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 6px; margin-left: 6px; border-radius: 10px; background: var(--accent); color: var(--white); font-size: 0.72rem; }
.tab-count[hidden] { display: none; }
.est-panel, #panel-event { display: grid; gap: 26px; }
.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg label, .addons label { cursor: pointer; position: relative; }
.seg input, .addons input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: inline-block; padding: 9px 18px; border: 1px solid var(--line); border-radius: 999px; font-size: 0.93rem; font-weight: 500; transition: background var(--fast), border-color var(--fast), color var(--fast), transform var(--fast) var(--ease); }
.seg label:hover span { border-color: var(--ink); transform: translateY(-1px); }
.seg input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.seg input:focus-visible + span, .addons input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.content-groups b { display: inline-grid; place-items: center; min-width: 18px; height: 18px; margin-left: 6px; border-radius: 9px; background: var(--accent); color: var(--white); font-size: 0.7rem; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.stepper button { width: 44px; height: 44px; background: none; border: 0; color: var(--ink); font-size: 1.3rem; cursor: pointer; transition: background var(--fast); }
.stepper button:hover { background: var(--paper-2); }
.stepper output { min-width: 40px; text-align: center; font-family: var(--serif); font-size: 1.35rem; }
.stepper-sm button { width: 36px; height: 36px; font-size: 1.1rem; }
.stepper-sm output { min-width: 30px; font-size: 1.15rem; }
.addons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.addons span { display: flex; justify-content: space-between; gap: 8px; height: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 0.92rem; transition: border-color var(--fast), background var(--fast); }
.addons em { font-style: normal; color: var(--muted); white-space: nowrap; }
.addons input:checked + span { border-color: var(--accent); background: rgba(232, 82, 31, 0.06); }
.addons input:checked + span em { color: var(--accent); }
.content-items { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.content-items li { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.content-items li.picked .ci-name { color: var(--accent); }
.ci-name { display: block; font-weight: 500; transition: color var(--fast); }
.ci-price { display: block; font-size: 0.85rem; color: var(--muted); }
.est-hint { margin: 0; font-size: 0.85rem; color: var(--muted); }
.est-summary { position: sticky; top: 90px; overflow: hidden; background: radial-gradient(80% 60% at 100% 0%, rgba(232, 82, 31, 0.25), transparent 60%), var(--ink); color: var(--white); border-radius: var(--radius); padding: 30px; box-shadow: 0 20px 50px rgba(11, 22, 38, 0.3); }
.est-label { margin: 0; font: 500 0.72rem var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-dark); }
.est-total { margin: 6px 0 20px; font-family: var(--serif); }
.est-total span { font: 500 0.9rem var(--mono); color: var(--accent-soft); vertical-align: 0.9em; }
.est-total strong { font-weight: 500; font-size: clamp(2.6rem, 6vw, 3.6rem); font-variant-numeric: tabular-nums; }
.est-lines { list-style: none; padding: 0; margin: 0 0 24px; border-top: 1px solid var(--line-dark); }
.est-lines li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-dark); font-size: 0.9rem; color: var(--muted-dark); }
.est-lines li span:last-child { color: var(--white); font-variant-numeric: tabular-nums; }
.est-lines li.est-head { padding-top: 16px; color: var(--white); font: 500 0.72rem var(--mono); letter-spacing: 0.12em; text-transform: uppercase; border-bottom-color: rgba(255, 255, 255, 0.18); }
.est-lines li.est-head:first-child { padding-top: 10px; }
.est-lines li.est-add { justify-content: flex-start; border-bottom: 0; }
.est-lines li.est-empty { color: var(--muted-dark); border-bottom: 0; padding: 14px 0; }
.est-link { background: none; border: 0; padding: 0; font: 600 0.75rem var(--sans); color: var(--accent-soft); cursor: pointer; }
.est-link:hover { color: var(--white); text-decoration: underline; }
.est-send { display: flex; width: 100%; }
.est-fine { margin: 14px 0 0; font-size: 0.8rem; color: var(--muted-dark); }
.terms { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.terms > div { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; border-top: 3px solid var(--accent); }
.terms h3 { font-size: 1.2rem; }
.terms p { color: var(--muted); font-size: 0.95rem; margin: 0; }

/* ---------- Responsive ---------- */
@media (min-width: 761px) and (max-width: 1000px) { .nav nav { gap: 14px; } }
@media (max-width: 1000px) {
  .hero { min-height: 0; }
  .hero-grid, .split-grid, .contact-grid, .estimator { grid-template-columns: 1fr; gap: 56px; }
  .hero-photo { max-width: 380px; margin: 0 auto; }
  .split-grid .section-head { position: static; }
  .stats-grid, .rate-grid, .terms, .content-grid { grid-template-columns: 1fr 1fr; }
  .articles { grid-template-columns: 1fr 1fr; }
  .article-lead { grid-row: auto; }
  .est-summary { position: static; }
  .events { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .wrap, .nav-inner { padding-left: 16px; padding-right: 16px; }
  .nav-toggle { display: block; }
  .nav nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; background: rgba(11, 22, 38, 0.97); border-bottom: 1px solid var(--line-dark); padding: 8px 16px 18px; }
  .nav nav.open { display: flex; }
  .nav nav a:not(.btn) { padding: 13px 0; border-bottom: 1px solid var(--line-dark); }
  .nav nav a:not(.btn)::after { display: none; }
  .nav nav .btn { margin-top: 14px; }
  .logo-word { font-size: 1.15rem; }
  .hero { padding: 40px 0 90px; }
  .kicker { font-size: 0.66rem; }
  .photo-tag { left: 0; }
  .section, .contact { padding: 76px 0; }
  .services, .articles, .incl-grid, .extras, .rate-grid, .terms, .addons, .content-grid, .facts { grid-template-columns: 1fr; }
  .article-lead { grid-column: auto; }
  .service { padding: 24px; }
  .event { grid-template-columns: 80px 1fr; padding: 16px; }
  .jobs { padding-left: 34px; }
  .jobs::before, .jobs::after { left: 8px; }
  .job-node { left: -34px; width: 20px; height: 20px; }
  .job-card { padding: 22px; }
  .trust-row { grid-template-columns: 1fr; }
  .trust-label { padding: 12px 16px 0; }
  .stats-grid { gap: 12px; }
  .stat { padding: 22px 18px; }
  .est-controls, .est-summary { padding: 22px; }
  .to-top { right: 14px; bottom: 14px; width: 42px; height: 42px; }
}

/* ---------- Reduced motion: everything visible, nothing moves ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal], .js .reveal, .js .hero-copy > *, .js .hero-photo { opacity: 1; transform: none; }
  .js .service:not(.is-visible) .service-icon * { stroke-dashoffset: 0; }
  .role-rotator span:first-child { transform: none; opacity: 1; }
}

/* ---------- Print: a clean CV ---------- */
@media print {
  .nav, .hero-actions, .hero-orbit, .planet, .sky, .scroll-cue, .contact-actions, .footer, .stats, .trust, .filters, .to-top, .scroll-progress, .copy-email, .photo-tag { display: none !important; }
  body, .dark, .contact, .section-alt { background: #fff !important; color: #000 !important; }
  .dark h2, .dark h3, .dark p, .contact h2, .contact-email, .hero h1 { color: #000 !important; }
  .js [data-reveal], .js .reveal, .js .hero-copy > *, .js .hero-photo { opacity: 1; transform: none; animation: none; }
  .card, .card-dark { background: none; box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
}

/* ---------- Light cards on dark sections ---------- */
.dark .card h3 { color: var(--ink); }
.dark .card p { color: var(--muted); }
.dark .card { border-color: transparent; box-shadow: 0 10px 34px rgba(0, 0, 0, 0.35); }
.dark .card.glow:hover { box-shadow: 0 0 0 1px rgba(232, 82, 31, 0.5), 0 24px 54px rgba(0, 0, 0, 0.45); }
.dark .service > p { color: var(--muted); }
.service ul { border-top-color: var(--line); }
.service li { color: var(--ink); border-bottom-color: var(--line); }
.service-icon { stroke: var(--accent); background: rgba(232, 82, 31, 0.08); border-color: rgba(232, 82, 31, 0.25); }
.service-num { color: var(--muted); }
.service .link-arrow { color: var(--ink); }
.dark .card .link-arrow::after { color: var(--accent); }
.dark .jobs::before { background: rgba(255, 255, 255, 0.15); }
.dark .job-node { background: var(--ink); border-color: rgba(255, 255, 255, 0.3); }
.dark .job-node::after { background: rgba(255, 255, 255, 0.3); }
.dark .job.is-reached .job-node::after { background: var(--accent); }
.dark .job-card .job-org { color: var(--accent); }
.dark .extras p { color: var(--ink); }
.contact-card .contact-email { color: var(--ink); }
.contact-card .contact-email:hover { color: var(--accent); }
.contact-card .copy-email { color: var(--muted); border-color: var(--line); }
.contact-card .copy-email:hover { color: var(--ink); border-color: var(--ink); }
.contact-card .contact-actions { border-top-color: var(--line); }
.contact-card .btn-ghost { color: var(--ink); border-color: var(--line); }
.contact-card .btn-ghost:hover { border-color: var(--ink); background: var(--paper-2); }
.dark .extras h3 { color: var(--accent); }
.to-top { background: var(--accent); box-shadow: 0 8px 24px rgba(232, 82, 31, 0.35); }
.to-top:hover { background: #ff6a33; }

/* ---------- Mobile: hero fits the screen; careers collapse to a tap-to-open list ---------- */
@media (max-width: 760px) {
  /* the planet is 120% of the photo width, so keep the photo at screen width / 1.2 */
  .hero-photo { max-width: calc((100vw - 40px) / 1.2); }
  .photo-tag { left: -6%; bottom: 10%; font-size: 0.66rem; }
  /* narrower ring on phones so its ends still fit on screen */
  .hero-orbit { left: -16%; width: 132%; top: 30%; }

  .js .job-card { cursor: pointer; padding-right: 54px; }
  .js .job-card::after { content: ""; position: absolute; top: 28px; right: 22px; width: 9px; height: 9px;
    border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(45deg); transition: transform var(--base) var(--ease); }
  .js .job.is-open .job-card::after { transform: rotate(-135deg); top: 33px; }
  .js .job-more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--base) var(--ease); }
  .js .job-more > div { overflow: hidden; }
  .js .job-more p { padding-top: 10px; }
  .js .job.is-open .job-more { grid-template-rows: 1fr; }
  .job-card .job-org { margin-bottom: 0; }
  .job-card:hover, .js .job-card.glow:hover { transform: none; }
}

/* Mid-size screens: two columns but less room, so a slightly narrower ring */
@media (min-width: 1001px) and (max-width: 1240px) {
  .hero-orbit { left: -18%; width: 136%; top: 29.3%; }
}
