/* Oloyede David: geospatial research portfolio.
   One stylesheet, built on tokens. Introduction, index map, studies. */

@font-face { font-family: 'Range Dash'; src: url(assets/fonts/range-dash.woff) format('woff'); unicode-range: U+2013; font-weight: 100 599; font-display: swap; }
@font-face { font-family: 'Range Dash'; src: url(assets/fonts/range-dash-bold.woff) format('woff'); unicode-range: U+2013; font-weight: 600 900; font-display: swap; }
@font-face { font-family: 'Satoshi'; src: url(assets/fonts/Satoshi-400.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Satoshi'; src: url(assets/fonts/Satoshi-500.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Satoshi'; src: url(assets/fonts/Satoshi-700.woff2) format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Zodiak'; src: url(assets/fonts/Zodiak-700.woff2) format('woff2'); font-weight: 400 800; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url(assets/fonts/GeistMono-400.woff2) format('woff2'); font-weight: 400; font-display: swap; }

/* ---------- tokens ---------- */
:root {
    /* colour */
    --paper: #ffffff;
    --paper-2: #f4f4f2;
    --ink: #141412;
    --ink-2: #55544e;      /* 8.0:1 on paper */
    --ink-3: #6a6963;      /* 4.9:1 on paper */
    --rule: #e4e4e0;
    --line: #bdbdb8;      /* the stronger grey for frames and section rules */
    --accent: #1f5fae;     /* links and focus only */

    /* type */
    --display: 'Zodiak', 'Iowan Old Style', Georgia, serif;
    --text: 'Range Dash', 'Satoshi', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
    --fs-meta: .75rem;
    --fs-small: .9375rem;
    --fs-body: 1.0625rem;
    --fs-lead: clamp(1.1875rem, 1.6vw, 1.375rem);
    --fs-h3: clamp(1.625rem, 2.7vw, 2.25rem);
    --fs-h2: clamp(2rem, 4vw, 3.25rem);
    --fs-display: clamp(2.25rem, 5vw, 3.5rem);

    /* space: a 4px base */
    --s-1: .25rem; --s-2: .5rem; --s-3: .75rem; --s-4: 1rem; --s-5: 1.5rem;
    --s-6: 2rem; --s-7: 3rem; --s-8: 4rem; --s-9: 6rem; --s-10: 9rem;

    /* layout */
    --max: 1240px;
    --gutter: 24px;
    --margin: clamp(20px, 4.4vw, 56px);
    --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
body {
    margin: 0; background: var(--paper); color: var(--ink);
    font-family: var(--text); font-size: var(--fs-body); line-height: 1.6;
    -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 500; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
.skip { position: absolute; left: var(--margin); top: -80px; background: var(--ink); color: var(--paper); padding: var(--s-3) var(--s-4); z-index: 10; font-size: var(--fs-small); }
.skip:focus { top: var(--s-4); }
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--margin)); margin: 0 auto; padding: 0 var(--margin); }

/* the 12-column grid, used by both sections */
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }

/* metadata voice: small, mono, upper case */
.meta { font-family: var(--mono); font-size: var(--fs-meta); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); line-height: 1.5; }

/* links: text underline that draws in */
.link { position: relative; display: inline-flex; align-items: baseline; gap: .35em; font-weight: 500; padding-block: var(--s-1); }
.link::after { content: ''; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: currentColor; transform-origin: left; transition: transform .35s var(--ease); }
.link:hover::after { transform: scaleX(.0); transform-origin: right; }
.link .arrow { display: inline-block; transition: transform .3s var(--ease); }
.link:hover .arrow { transform: translate(2px, -2px); }

/* ---------- header ---------- */

.brand { font-weight: 700; font-size: 1.0625rem; letter-spacing: -.005em; }
.site-nav { display: flex; gap: var(--s-6); align-items: baseline; }
.site-nav a { font-size: var(--fs-small); color: var(--ink-2); padding-block: var(--s-2); transition: color .2s ease; }
.site-nav a:hover { color: var(--ink); }
.site-nav a[aria-current="true"] { color: var(--ink); }


/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--rule); padding-block: var(--s-6) var(--s-7); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-3) var(--s-6); font-size: var(--fs-small); color: var(--ink-3); }
.site-footer nav { display: flex; gap: var(--s-6); }
.site-footer a { color: var(--ink-2); }
.site-footer a:hover { color: var(--ink); }

/* ---------- motion ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js .reveal { opacity: 1; transform: none; transition: none; }
    .link::after, .link .arrow, .inset-media img, .cta, .cta .arrow { transition: none; }
    .inset:hover .inset-media img { transform: none; }
    .fp-line { animation: none !important; }
}
@media print { .site-footer nav { display: none; } .js .reveal { opacity: 1; transform: none; } }

/* ================= the map sheet ================= */
.collar-top { padding-block: var(--s-4); border-bottom: 1px solid var(--rule); }
.collar-top .wrap { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-5); }
.sheet { padding-block: clamp(1.5rem, 3vw, 2.5rem) var(--s-8); }
.sheet-frame { display: grid; grid-template-columns: minmax(0, 1fr) 340px; border: 1px solid var(--line); background: #fff; }
.mapbox { margin: 0; padding: 30px 28px 14px 48px; border-right: 1px solid var(--line); }
.map-inner { position: relative; }
.sheet-map { display: block; width: 100%; height: auto; }
.ticks { position: absolute; font-family: var(--mono); font-size: .625rem; letter-spacing: .04em; color: var(--ink-3); pointer-events: none; }
.ticks-top { left: 0; right: 0; top: -18px; height: 12px; } .ticks-top span { position: absolute; transform: translateX(-50%); }
.ticks-left { top: 0; bottom: 0; left: -44px; width: 38px; } .ticks-left span { position: absolute; right: 0; transform: translateY(-50%); }
.mapbox figcaption { margin-top: var(--s-3); }

/* map content */
.sea { fill: #eceeef; }
.land { fill: #ffffff; stroke: #8f8d86; stroke-width: .6; }
.borders { fill: none; stroke: #c3c1b9; stroke-width: .55; }
.grat { stroke: #cfcdc5; stroke-width: .5; stroke-dasharray: 2 4; }
.country { font-family: var(--mono); font-size: 7.4px; letter-spacing: .22em; fill: #6b6a63; }
.sea-label { font-family: var(--display); font-style: italic; font-size: 10px; fill: #67655d; }
.neat { fill: none; stroke: var(--line); stroke-width: 1; }
.hatch { stroke-width: 1; }
.hatch-01, .sw-01 { stroke: #1f5fae; } .hatch-02, .sw-02 { stroke: #0f766e; } .hatch-03, .sw-03 { stroke: #a8661b; } .hatch-04, .sw-04 { stroke: #5b6b7a; } .hatch-05, .sw-05 { stroke: #b3361b; } .hatch-06, .sw-06 { stroke: #6b4c9a; } .hatch-07, .sw-07 { stroke: #2e7d4f; } .hatch-08, .sw-08 { stroke: #a3346a; } .sw-09 { stroke: #3d4f9f; }
.fp-01 .fp-line { stroke: #1f5fae; } .fp-02 .fp-line { stroke: #0f766e; } .fp-03 .fp-line { stroke: #a8661b; } .fp-04 .fp-line { stroke: #5b6b7a; } .fp-05 .fp-line { stroke: #b3361b; } .fp-06 .fp-line { stroke: #6b4c9a; stroke-width: 1.6; } .fp-07 .fp-line { stroke: #2e7d4f; stroke-width: 1.6; } .fp-08 .fp-line { stroke: #a3346a; }
.fp-line { fill: none; stroke-width: 1.1; transition: stroke-width .25s ease; }
.fp-fill { opacity: .55; transition: opacity .25s ease; }
.fp, .badge, .leader, .lead-dot { transition: opacity .3s ease; }
.fp-link { cursor: pointer; } .fp-link:focus { outline: none; } .fp-link:focus-visible .fp-line { stroke-width: 2.4; }
.badge circle { fill: #3a3a37; transition: fill .25s ease; } .badge text { font-family: var(--mono); font-size: 9px; fill: #fff; pointer-events: none; }
.leader { stroke: #8a8a85; stroke-width: .7; } .lead-dot { fill: #8a8a85; }
.sheet.focus .fp:not(.on) { opacity: .22; }
.sheet.focus .badge:not(.on), .sheet.focus .leader:not(.on) { opacity: .25; }
.fp.on .fp-line { stroke-width: 2; } .fp.on .fp-fill { opacity: .85; }
.badge.on circle { fill: var(--accent); }

/* north arrow and scale bar, drawn over the map */
.north { position: absolute; right: 10px; top: 10px; display: grid; justify-items: center; font-family: var(--mono); font-size: .625rem; color: var(--ink); background: rgba(250,249,246,.85); padding: 4px 6px 2px; }
.north path { fill: var(--ink); }
.scale { position: absolute; left: 12px; right: 12px; bottom: 12px; height: 26px; pointer-events: none; }
.scale-bar { width: var(--w); height: 6px; display: flex; border: 1px solid var(--line); background: #fff; }
.scale-bar i { flex: 1; } .scale-bar i:first-child { background: var(--ink); }
.scale span { position: absolute; top: 10px; font-family: var(--mono); font-size: .625rem; color: var(--ink-2); transform: translateX(-50%); }
.scale span:first-of-type { left: 0; transform: none; } .scale .mid { left: calc(var(--w) / 2); } .scale .end { left: var(--w); transform: none; margin-left: 4px; }

/* the margin: title block and legend */
.margin { padding: 30px 28px; display: flex; flex-direction: column; gap: var(--s-7); }
.leg-list { list-style: none; padding: 0; margin: var(--s-3) 0 0; border-top: 1px solid var(--rule); }
.leg { display: grid; grid-template-columns: 22px 1.6rem minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 11px 6px 11px 0; border-bottom: 1px solid var(--rule); transition: background .25s ease, padding .25s ease; }
.leg.on { background: #f5f5f4; padding-left: 6px; }
.sw { width: 22px; height: 16px; margin-top: 2px; } .sw-line { fill: none; stroke-width: 1.3; }
.leg-n { font-family: var(--mono); font-size: var(--fs-meta); color: var(--ink); padding-top: 2px; }
.leg-t a { display: block; font-weight: 500; font-size: .9375rem; line-height: 1.3; }
.leg-t a:hover { text-decoration: underline; text-underline-offset: 3px; }
.leg-t small { display: block; margin-top: 2px; font-size: .8125rem; color: var(--ink-3); }
.leg-src { font-family: var(--mono); font-size: var(--fs-meta); color: var(--ink-3); padding-top: 2px; } .leg-src:hover { color: var(--ink); }

/* insets */
.insets { padding-block: var(--s-6) var(--s-9); }

@media (max-width: 1000px) {
    .sheet-frame { grid-template-columns: 1fr; }
    .mapbox { border-right: 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 560px) {
    .mapbox { padding: 24px 12px 12px 34px; }
    .ticks-left { left: -32px; width: 28px; }
    .margin { padding: 22px 16px; }
    .north { transform: scale(.85); transform-origin: top right; }
    .collar-top .site-nav { gap: var(--s-4); }
}

/* sheet layout: map across the full width, title block and legend in the bottom margin */
.sheet-frame { grid-template-columns: 1fr; }
.mapbox { border-right: 0; border-bottom: 1px solid var(--line); padding: 30px 30px 14px 50px; }
.margin { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s-7); padding: 30px; align-items: start; }
.legend .leg-list { display: grid; grid-template-columns: 1fr 1fr; column-gap: var(--s-6); border-top: 0; }
.legend .leg { border-top: 1px solid var(--rule); border-bottom: 0; }
.country { font-size: 8.6px; }
.badge text { font-size: 10.5px; }
.scale { left: auto; right: 14px; width: 40%; }
.scale-bar { width: calc(var(--w) * 2.5); margin-left: auto; }
.scale span:first-of-type { left: auto; right: calc(var(--w) * 2.5); transform: translateX(50%); }
.scale .mid { left: auto; right: calc(var(--w) * 1.25); transform: translateX(50%); }
.scale .end { left: auto; right: 0; margin-left: 0; transform: none; top: 10px; }
.scale span { top: 10px; }
@media (max-width: 1000px) { .margin { grid-template-columns: 1fr; } }
@media (max-width: 700px) { .legend .leg-list { grid-template-columns: 1fr; } .scale { width: 70%; } .scale-bar { width: calc(var(--w) * 1.43); } .scale span:first-of-type { right: calc(var(--w) * 1.43); } .scale .mid { right: calc(var(--w) * .715); } }

.leg-src { display: inline-block; padding: 4px 0; line-height: 16px; min-height: 24px; }
.brand { display: inline-block; padding-block: 4px; }

/* ================= insets: one study per row ================= */
.inset-list { border-bottom: 1px solid var(--rule); }
.inset { position: relative; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: var(--s-8); align-items: center; padding-block: var(--s-6); border-top: 1px solid var(--rule); }
.inset:first-child { border-top: 0; padding-top: var(--s-4); }
.inset-text { min-width: 0; max-width: 34rem; }
.tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s-2); }
.tags li { font-family: var(--mono); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; line-height: 1; color: var(--ink-2); padding: 6px 8px; border: 1px solid var(--rule); }
.inset h3 { font-family: var(--display); font-size: clamp(1.75rem, 2.7vw, 2.375rem); line-height: 1.12; letter-spacing: -.01em; margin-top: var(--s-4); text-wrap: balance; }
.inset-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.inset-link:focus-visible { outline: none; }
.inset:has(.inset-link:focus-visible) { outline: 2px solid var(--accent); outline-offset: 4px; }
.inset-desc { margin-top: var(--s-3); color: var(--ink-2); font-size: var(--fs-small); line-height: 1.65; }
.inset-actions { display: flex; align-items: center; gap: var(--s-4); margin-top: var(--s-5); }
.cta { display: inline-flex; align-items: center; gap: .4em; font-size: var(--fs-small); font-weight: 500; color: var(--paper); background: var(--ink); padding: 11px 18px; transition: background .25s ease; }
.cta .arrow { display: inline-block; transition: transform .3s var(--ease); }
.inset:hover .cta { background: #2b2b28; }
.inset:hover .cta .arrow { transform: translate(2px, -2px); }
.years { font-family: var(--mono); font-size: var(--fs-meta); letter-spacing: .04em; color: var(--ink-3); }
.inset-media { overflow: hidden; border: 1px solid var(--rule); background: #e9e9e6; }
.inset-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform 1.2s var(--ease); }
.inset:hover .inset-media img { transform: scale(1.025); }

/* the study outlines draw themselves once */
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.js .fp-line { stroke-dasharray: 1; stroke-dashoffset: 0; }
.js .sheet.drawn .fp-line { animation: draw 1.6s var(--ease) both; }
.js .sheet.drawn .fp-02 .fp-line { animation-delay: .15s; } .js .sheet.drawn .fp-03 .fp-line { animation-delay: .3s; }
.js .sheet.drawn .fp-04 .fp-line { animation-delay: .45s; } .js .sheet.drawn .fp-05 .fp-line { animation-delay: .6s; } .js .sheet.drawn .fp-06 .fp-line { animation-delay: .75s; }

@media (max-width: 959px) {
    .inset { grid-template-columns: 1fr; gap: var(--s-5); padding-block: var(--s-6); }
    .inset-text { max-width: none; }
    .inset-media { order: -1; }
}

/* ================= header: sticky, a rule appears once the page scrolls ================= */
.collar-top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 92%, transparent); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-bottom: 1px solid transparent; transition: border-color .2s ease; }
.collar-top.scrolled { border-bottom-color: var(--rule); }
.site-nav a[aria-current="true"] { color: var(--ink); text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; }
html { scroll-padding-top: 72px; }

/* ================= introduction ================= */
.hello { padding-block: clamp(3.5rem, 9vw, 7rem) clamp(2.5rem, 6vw, 4.5rem); }
.hello h1 { font-family: var(--display); font-weight: 700; font-size: clamp(2.5rem, 6.2vw, 4.75rem); line-height: 1.02; letter-spacing: -.025em; }
.hello-body { margin-top: var(--s-6); max-width: 40rem; font-size: clamp(1.0625rem, 1.5vw, 1.1875rem); line-height: 1.9; color: var(--ink-2); }
.hello-body strong { color: var(--ink); font-weight: 500; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 1px 8px 1px 6px; border: 1px solid var(--rule); background: #fff; color: var(--ink); font-weight: 500; line-height: 1.6; white-space: nowrap; vertical-align: baseline; }
.chip svg { width: 15px; height: 15px; fill: none; stroke: var(--c); stroke-width: 1.5; stroke-linecap: square; }
.chip svg circle[r="1.2"] { fill: var(--c); stroke: none; }
.chip-01 { --c: #1f5fae; } .chip-02 { --c: #0f766e; } .chip-03 { --c: #a8661b; } .chip-04 { --c: #5b6b7a; }
.hello-actions { margin-top: var(--s-6); display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-4) var(--s-6); }
.hello .cta:hover { background: #2b2b28; }
.hello .cta:hover .arrow { transform: translate(2px, -2px); }

/* title block on the sheet, now secondary to the introduction */


/* ================= footer ================= */
.site-footer .wrap { display: grid; gap: var(--s-5); }
.f-credits { font-size: .8125rem; color: var(--ink-3); }

/* touch: comfortable targets */
@media (pointer: coarse) { .leg-src, .site-nav a { min-height: 44px; display: inline-flex; align-items: center; } }

/* print: a clean sheet */
@media print {
    .collar-top, .skip, .hello-actions, .inset-actions { display: none !important; }
    body { background: #fff; } .inset { break-inside: avoid; } .inset-media img { transform: none !important; }
    a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 9pt; color: #555; word-break: break-all; }
}
.nw { white-space: nowrap; }
.brand, .site-nav a { white-space: nowrap; }
@media (max-width: 520px) { .site-nav a[href="#map"] { display: none; } .collar-top .site-nav { gap: var(--s-4); } }

/* ================= about ================= */
.about { padding-block: var(--s-8) var(--s-9); border-top: 1px solid var(--rule); }
.sec-head { border-top: 1px solid var(--line); padding-top: var(--s-3); margin-bottom: var(--s-6); }
.sec-head h2 { font-family: var(--display); font-size: 1.75rem; font-weight: 700; }
@media (max-width: 420px) { .collar-top .site-nav { gap: var(--s-3); } .site-nav a { font-size: .875rem; } .brand { font-size: 1rem; } }

/* ================= life: motion and small interactions (all off for reduced motion) ================= */
.progress { position: fixed; top: 0; left: 0; height: 2px; width: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); z-index: 40; pointer-events: none; }

/* hero: coordinate grid, a slow satellite swath, and light that follows the cursor */
.hello { position: relative; overflow: hidden; isolation: isolate; }
.hello-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; -webkit-mask-image: linear-gradient(#000 70%, transparent); mask-image: linear-gradient(#000 70%, transparent); }
.hello-bg .grid { position: absolute; inset: -1px; background-image: linear-gradient(var(--rule) 1px, transparent 1px), linear-gradient(90deg, var(--rule) 1px, transparent 1px); background-size: 64px 64px; opacity: .55;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 70% 40%, #000 0%, transparent 75%); mask-image: radial-gradient(ellipse 70% 80% at 70% 40%, #000 0%, transparent 75%); }

/* headline: words rise in */
.js .hello h1 .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; }
.js .hello h1 .w > span { display: inline-block; transform: translateY(105%); animation: rise .9s var(--ease) forwards; animation-delay: calc(var(--i) * 70ms + 100ms); }
@keyframes rise { to { transform: none; } }
.js .hello .hello-body, .js .hello .hello-actions { opacity: 0; transform: translateY(10px); animation: fadeup .8s var(--ease) forwards; } .js .hello .hello-body { animation-delay: .6s; } .js .hello .hello-actions { animation-delay: .85s; }
@keyframes fadeup { to { opacity: 1; transform: none; } }
@keyframes underline { to { background-size: 100% 1px; } }

/* chips: the icon moves a little on hover */
.chip { transition: border-color .2s, transform .2s var(--ease); }
.chip:hover { border-color: var(--c); transform: translateY(-1px); }
.chip:hover svg { animation: nudge .6s var(--ease); }
@keyframes nudge { 30% { transform: rotate(-12deg) scale(1.15); } 70% { transform: rotate(6deg); } }
@keyframes blink { 50% { opacity: .25; } }

/* the main button leans toward the cursor */
.cta { will-change: transform; transition: background .25s ease, transform .35s var(--ease); }

/* map: live coordinates under the cursor */
.map-inner { position: relative; }
.coord { position: absolute; left: 0; top: 0; padding: 3px 6px; font-family: var(--mono); font-size: 11px; color: var(--paper); background: var(--ink); pointer-events: none; opacity: 0; transform: translate(var(--cx, 0), var(--cy, 0)); transition: opacity .15s; white-space: nowrap; z-index: 3; }
.coord.on { opacity: 1; }
.map-inner.crosshair { cursor: crosshair; }
.badge circle { transition: r .25s var(--ease); }
.badge.on circle { r: 16; }

/* study rows: image wipes in */
.js .inset .inset-media { clip-path: inset(0 0 100% 0); transition: clip-path 1.1s var(--ease) .1s; }
.js .inset.in .inset-media { clip-path: inset(0 0 0 0); }
.inset-media { position: relative; }
.inset-media img { transition: transform 1.2s var(--ease); transform: scale(1.06); }
.js .inset.in .inset-media img { transform: scale(1); }
.inset:hover .inset-media img { transform: scale(1.03); }


@media (prefers-reduced-motion: reduce) {
  .js .hello h1 .w > span, .js .hello .hello-body, .js .hello .hello-actions { animation: none; transform: none; opacity: 1; }
  .js .inset .inset-media { clip-path: none; transition: none; } .inset-media img, .js .inset.in .inset-media img { transform: none; transition: none; }
  .cta, .chip { transition: none; } .chip:hover svg { animation: none; }
}

/* ================= wilder: globe, ticker, big study numbers ================= */
.hello-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: var(--s-6); align-items: center; }
.globe { margin: 0; position: relative; }
.globe canvas { display: block; width: 100%; aspect-ratio: 1; cursor: grab; touch-action: pan-y; }
.globe canvas:active { cursor: grabbing; }
.globe figcaption { text-align: center; margin-top: var(--s-2); }
.js .globe { opacity: 0; transform: scale(.94); animation: globein 1.4s .3s var(--ease) forwards; }
@keyframes globein { to { opacity: 1; transform: none; } }
@media (max-width: 899px) { .hello-grid { grid-template-columns: 1fr; } .globe { max-width: 330px; margin: var(--s-4) auto 0; } }

.ticker { overflow: hidden; border-block: 0; padding-block: 14px; margin-bottom: var(--s-7); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.ticker-track { display: flex; width: max-content; animation: tick 60s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-set { display: flex; align-items: center; gap: 28px; padding-right: 28px; }
.ticker span { font-family: var(--display); font-weight: 700; font-size: clamp(1.25rem, 2.4vw, 1.75rem); white-space: nowrap; }
.ticker i { font-style: normal; color: var(--accent); font-size: .875rem; }
@keyframes tick { to { transform: translateX(-50%); } }

.inset { counter-increment: row; }
.inset-list { counter-reset: row; }
.inset-text { position: relative; }
.inset-text::before { content: counter(row, decimal-leading-zero); position: absolute; right: 0; top: -.15em; font-family: var(--display); font-weight: 700; font-size: clamp(5rem, 11vw, 9rem); line-height: 1; color: transparent; -webkit-text-stroke: 1px var(--rule); pointer-events: none; z-index: -1; transition: -webkit-text-stroke-color .4s; }
.inset:hover .inset-text::before { -webkit-text-stroke-color: var(--c); }
.inset { isolation: isolate; }

@media (prefers-reduced-motion: reduce) { .ticker-track { animation: none; } .ticker { overflow-x: auto; } .js .globe { animation: none; opacity: 1; transform: none; } }

/* ================= subtle rounding ================= */
:root { --r: 10px; --r-s: 6px; --r-xs: 4px; }
.inset-media, .mapbox, .sheet-frame { border-radius: var(--r); }
.inset-media { overflow: hidden; }
.cta, .chip, .tags li, .coord, .skip { border-radius: var(--r-s); }
.tags li { border-radius: var(--r-xs); }
.sheet-frame { overflow: hidden; }

/* ================= study recap reels ================= */

@keyframes seg { to { transform: scaleX(1); } }
.inset h3 { font-size: clamp(1.375rem, 1.9vw, 1.75rem); line-height: 1.16; } .tags li { font-size: 10.5px; padding: 5px 7px; }
/* no decorative numbers on rows or themes */
.inset-text::before { content: none !important; }

/* pure white, simpler hero */

.hello-body { margin-top: var(--s-4); max-width: 34rem; font-size: clamp(1.0625rem, 1.5vw, 1.1875rem); line-height: 1.7; }
.hello-body em { font-style: normal; color: var(--accent); background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; animation: underline 1s 1.2s var(--ease) forwards; }

/* ================= hero, take three ================= */

.hello h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); line-height: 1.04; max-width: 13ch; }
.hello-body { margin-top: var(--s-5); max-width: 36rem; font-size: clamp(1.0625rem, 1.5vw, 1.1875rem); line-height: 1.9; }
.js .hello .hello-body { animation-delay: .7s; }

/* map sheet: the legend now has the margin to itself */
.margin { grid-template-columns: 1fr; padding: 26px 30px 30px; }
.legend .leg-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1000px) { .legend .leg-list { grid-template-columns: 1fr 1fr; } }
@media (max-width: 700px) { .legend .leg-list { grid-template-columns: 1fr; } }

/* ================= Lagos: wide row ================= */
.inset--wide { grid-template-columns: 1fr; gap: var(--s-5); }
.inset--wide .inset-text { max-width: 46rem; }
.inset--wide .inset-link::after { content: none; }

/* ================= subtle motion ================= */
.js .inset .tags li { opacity: 0; transform: translateY(6px); transition: opacity .5s var(--ease), transform .5s var(--ease); transition-delay: calc(var(--k) * 60ms + .15s); }
.js .inset.in .tags li { opacity: 1; transform: none; }
.sec-head { position: relative; border-top-color: transparent; }
.sec-head::before { content: ''; position: absolute; left: 0; right: 0; top: -1px; height: 1px; background: var(--line); transform-origin: 0 50%; transform: scaleX(0); transition: transform 1.2s var(--ease); }
.sec-head.in::before { transform: scaleX(1); }
.js .leg { opacity: 0; transform: translateY(8px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.js .legend.in .leg { opacity: 1; transform: none; }
.js .legend.in .leg:nth-child(2) { transition-delay: .06s; } .js .legend.in .leg:nth-child(3) { transition-delay: .12s; } .js .legend.in .leg:nth-child(4) { transition-delay: .18s; } .js .legend.in .leg:nth-child(5) { transition-delay: .24s; } .js .legend.in .leg:nth-child(6) { transition-delay: .3s; }
.js .badge { opacity: 0; transition: opacity .5s var(--ease) 1.3s; }
.js .sheet.drawn .badge { opacity: 1; }
.cta .arrow { transition: transform .3s var(--ease), border-color .2s; }
.leg { transition: background .2s; } .leg:hover { background: #fafafa; }
@media (prefers-reduced-motion: reduce) {
  .js .inset .tags li, .js .leg, .js .badge { opacity: 1 !important; transform: none !important; transition: none !important; }
  .sec-head::before { transform: none; transition: none; }
}

/* ================= Lagos explorer (the 6 Nov explorer, large) ================= */
.lx { display: grid; grid-template-columns: minmax(0, 1fr) 340px; padding: 0; overflow: hidden; border-radius: var(--r); border: 1px solid var(--rule); }
.lx-stage { position: relative; min-height: 470px; background: #e9e9e6; }
.lx-map { position: absolute; inset: 0; font-family: var(--text); }
.lx-tabs { position: absolute; top: 14px; left: 14px; z-index: 500; display: flex; flex-wrap: wrap; gap: 2px; padding: 4px; background: #fff; border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,.08); max-width: calc(100% - 80px); }
.lx-tabs button { font: 500 .8125rem/1 var(--text); color: var(--ink-2); background: transparent; border: 0; border-radius: 7px; padding: 9px 11px; cursor: pointer; position: relative; overflow: hidden; transition: color .2s, background .2s; }
.lx-tabs button:hover { color: var(--ink); background: #f3f3f1; }
.lx-tabs button[aria-selected="true"] { color: #fff; background: #c2470f; }
.lx-tabs button.auto::after { content: ''; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: rgba(255,255,255,.8); transform-origin: 0 50%; animation: seg 3.6s linear forwards; }
.lx-legend { position: absolute; left: 14px; bottom: 14px; z-index: 500; background: #fff; border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,.08); padding: 12px 14px; width: 260px; }
.lx-lt { font-weight: 700; font-size: .8125rem; }
.lx-ramp { display: block; height: 8px; border-radius: 4px; margin-top: 8px; }
.lx-lr { display: flex; justify-content: space-between; margin-top: 4px; font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }
.lx-lab { background: rgba(255,255,255,.94); border-radius: 5px; padding: 2px 6px; font-size: 11px; white-space: nowrap; color: var(--ink-2); transform: translate(-50%, -50%); width: max-content !important; height: auto !important; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.lx-lab b { color: var(--ink); font-weight: 700; margin-right: 3px; }
.lx-tip { font-family: var(--text); font-size: 12.5px; border-radius: 6px; }
.leaflet-path-interactive { transition: fill .8s var(--ease), fill-opacity .3s; }
.lx-panel { border-left: 1px solid var(--rule); padding: 18px; display: flex; flex-direction: column; gap: 10px; background: #fff; }
.lx-k { font-family: var(--mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.lx-sel { font: 400 .9375rem var(--text); padding: 9px 10px; border: 1px solid var(--rule); border-radius: var(--r-s); background: #fff; color: var(--ink); }
.lx-name { font-family: var(--display); font-weight: 700; font-size: 1.5rem; margin: 6px 0 0; }
.lx-sub { font-size: .8125rem; color: var(--ink-3); }
.lx-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 4px; }
.lx-c { border: 1px solid var(--rule); border-radius: 8px; padding: 10px; transition: border-color .3s, background .3s; }
.lx-c.on { border-color: #c2470f; background: #fff8f3; }
.lx-c p { font-size: .75rem; color: var(--ink-2); }
.lx-c b { display: block; font-family: var(--display); font-weight: 700; font-size: 1.375rem; margin: 2px 0; }
.lx-c b small { font-family: var(--text); font-weight: 400; font-size: .75rem; color: var(--ink-3); }
.lx-c span { font-size: .6875rem; color: var(--ink-3); line-height: 1.35; display: block; }
.lx-note { margin-top: auto; font-size: .75rem; color: var(--ink-3); line-height: 1.45; }
.js .lx { opacity: 0; transform: translateY(10px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js .lx.ready { opacity: 1; transform: none; }
@media (max-width: 959px) { .lx { grid-template-columns: 1fr; } .lx-stage { min-height: 440px; } .lx-panel { border-left: 0; border-top: 1px solid var(--rule); max-height: none; } .lx-legend { width: 200px; } }
@media (max-width: 520px) { .lx-tabs button { padding: 8px 8px; font-size: .75rem; } .lx-legend { display: none; } }
@media (prefers-reduced-motion: reduce) { .js .lx { opacity: 1; transform: none; } .lx-tabs button.auto::after { animation: none; } }

/* fewer, quieter lines */
.mapbox { border-bottom: 0 !important; }
.about { border-top: 0; }
.inset-list { border-bottom: 0; }
.legend .leg { border-top-color: var(--rule); }
.site-footer { border-top: 1px solid var(--rule); }
.collar-top.scrolled { border-bottom-color: var(--rule); }

/* Lagos: a self-playing tour */
.lx { position: relative; }
.lx-tab { font: 500 .8125rem/1 var(--text); color: var(--ink-2); border-radius: 7px; padding: 9px 11px; transition: color .3s, background .3s; }
.lx-tab.on { color: #fff; background: #c2470f; }
p.lx-sel { padding: 9px 10px; border: 1px solid var(--rule); border-radius: var(--r-s); font-size: .9375rem; }
.lx-cursor { position: absolute; left: 0; top: 0; width: 22px; height: 22px; z-index: 900; pointer-events: none; opacity: 0; transition: transform 1s cubic-bezier(.45,.05,.2,1), opacity .4s; filter: drop-shadow(0 1px 2px rgba(0,0,0,.25)); }
.lx.touring .lx-cursor { opacity: 1; }
.lx-cursor svg { width: 100%; height: 100%; fill: #141412; stroke: #fff; stroke-width: 1.5; stroke-linejoin: round; transform-origin: 5px 3px; transition: transform .15s; }
.lx-cursor.down svg { transform: scale(.82); }
.lx-cursor::after { content: ''; position: absolute; left: -9px; top: -9px; width: 26px; height: 26px; border-radius: 50%; border: 2px solid #c2470f; opacity: 0; transform: scale(.4); }
.lx-cursor.down::after { animation: ripple .5s ease-out; }
@keyframes ripple { 0% { opacity: .8; transform: scale(.4); } 100% { opacity: 0; transform: scale(1.4); } }
.lx-cover { position: absolute; inset: 0; z-index: 950; display: flex; align-items: flex-end; justify-content: flex-end; padding: 14px; border-radius: var(--r); }
.lx-cover span { background: var(--ink); color: #fff; font-size: .8125rem; font-weight: 500; padding: 8px 12px; border-radius: var(--r-s); opacity: 0; transform: translateY(6px); transition: opacity .25s, transform .25s; }
.lx-cover:hover span, .lx-cover:focus-visible span { opacity: 1; transform: none; }
.lx-cover:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.lx-stage .leaflet-container { cursor: default; }

/* ================= hero globe: Earth through time, with a tick scrubber ================= */
.globe { text-align: center; }
.globe canvas { display: block; width: min(100%, 330px); aspect-ratio: 1; height: auto; margin: 0 auto; }
.globe figcaption { display: block !important; margin-top: -8px; }
.g-cap { font-weight: 600; font-size: 1.1875rem; letter-spacing: -.01em; color: var(--ink); }
.g-line { margin-top: 4px; font-size: .9375rem; color: #6a6963; }
.g-line b { font-weight: 500; color: var(--ink); margin-right: 4px; }
.globe.swap .g-cap, .globe.swap .g-line { animation: gin .6s var(--ease); }
@keyframes gin { from { opacity: 0; filter: blur(3px); } }
.g-rule { position: relative; height: 34px; max-width: 280px; margin: var(--s-4) auto 0; cursor: ew-resize; touch-action: none; }
.g-rule:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.g-ticks i { position: absolute; bottom: 0; width: 1px; height: 9px; background: #c9c8c3; transform: translateX(-.5px); }
.g-ticks i.k { height: 13px; background: #b5b4ae; }
.g-thumb { position: absolute; bottom: 0; width: 2px; height: 34px; background: var(--ink); transform: translateX(-1px); }
.g-ends { display: flex; justify-content: space-between; max-width: 280px; margin: 10px auto 0; font-size: .8125rem; color: var(--ink-3); }
.g-ends span { transition: color .3s, font-weight .3s; }
.g-ends span.on { color: var(--ink); font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .globe.swap .g-cap, .globe.swap .g-line { animation: none; } }

/* ================= about: a written introduction, then skills ================= */
.about { padding-block: var(--s-8) var(--s-9); border-top: 1px solid var(--rule); }
.ab { max-width: 46rem; margin-inline: auto; }
.ab-text { margin-top: var(--s-4); }
.ab-text p { font-size: clamp(1.0625rem, 1.45vw, 1.25rem); line-height: 1.75; color: var(--ink-2); letter-spacing: -.005em; }
.ab-text p + p { margin-top: var(--s-5); }
.ab-text b { font-weight: 500; color: var(--ink); }
.ab-lead { font-size: clamp(1.25rem, 2vw, 1.625rem) !important; line-height: 1.5 !important; color: var(--ink) !important; letter-spacing: -.015em !important; }
.ab-chip { display: inline-flex; align-items: center; gap: 6px; padding: 1px 10px 2px 8px; margin: 0 1px; border-radius: 999px; background: #edf2fa; color: #1d4a8a; font-weight: 500; text-decoration: none; white-space: nowrap; line-height: 1.5; box-shadow: inset 0 0 0 1px rgba(31, 95, 174, .14); transition: background .2s, box-shadow .2s; }
.ab-chip svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.ab-chip:hover { background: #e1eaf7; box-shadow: inset 0 0 0 1px rgba(31, 95, 174, .3); }
.ab-chip:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.sk { position: relative; max-width: 64rem; margin: var(--s-9) auto 0; border-block: 1px dashed #d4d3cd; }
.sk::before, .sk::after { content: ""; position: absolute; top: -40px; bottom: -40px; border-left: 1px dashed #d4d3cd; }
.sk::before { left: 0; } .sk::after { right: 0; }
.sk-x { position: absolute; width: 13px; height: 13px; z-index: 1; }
.sk-x::before, .sk-x::after { content: ""; position: absolute; background: #a9a8a1; }
.sk-x::before { left: 6px; top: 0; width: 1px; height: 13px; } .sk-x::after { top: 6px; left: 0; height: 1px; width: 13px; }
.sk-x1 { left: -6px; top: -7px; } .sk-x2 { right: -6px; top: -7px; } .sk-x3 { left: -6px; bottom: -7px; } .sk-x4 { right: -6px; bottom: -7px; }
.sk-body { padding: var(--s-4) var(--s-6) var(--s-5); }
.sk-row { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: var(--s-4); padding-block: 10px; }
.sk-h { font-family: var(--mono); font-weight: 400; font-size: .6875rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); padding-top: 9px; }
.sk-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sk-list li { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 9px; border: 1px solid #e3e2dc; border-radius: 7px; background: #fff; font-size: .875rem; color: var(--ink); box-shadow: 0 1px 1px rgba(20, 20, 18, .03); transition: border-color .2s, transform .2s var(--ease); }
.sk-list li:hover { border-color: #c9c8c1; transform: translateY(-1px); }
.sk-b { width: 15px; height: 15px; flex: none; }
.sk-g { width: 15px; height: 15px; flex: none; fill: none; stroke: #4b6e9c; stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 720px) { .sk-row { grid-template-columns: 1fr; gap: 8px; } .sk-h { padding-top: 0; } .sk-body { padding-inline: var(--s-4); } .sk { margin-inline: calc(-1 * var(--s-2)); } }
@media (prefers-reduced-motion: reduce) { .sk-list li { transition: none; } .sk-list li:hover { transform: none; } }

/* ================= round 3: skills, projects heading, hero name, Lagos ================= */
.sk-list { align-items: flex-start; align-content: flex-start; }
.sk-list li { height: 32px; padding: 0 11px 0 9px; line-height: 1; white-space: nowrap; }
.sk-row { align-items: start; }
.sk-h { padding-top: 10px; }
.sk-row--next { margin-top: var(--s-3); padding-top: var(--s-4); border-top: 1px dashed #d4d3cd; }
.sk-row--next li { background: transparent; border-style: dashed; color: var(--ink-2); box-shadow: none; }
.sk-row--next .sk-g { stroke: #8a8983; }
@media (max-width: 720px) { .sk-list li { white-space: normal; } }

.hello-me { font-weight: 500; color: var(--ink); }

/* Lagos: line the card up with the text column, as in the reference */
figure.lx { margin: var(--s-2) 0 0; width: 100%; }
@media (max-width: 959px) {
  .lx-stage { min-height: 380px; }
  .lx-tabs { right: 10px; left: 10px; top: 10px; max-width: none; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .lx-tabs::-webkit-scrollbar { display: none; }
  .lx-tabs button { flex: none; }
}
@media (max-width: 520px) { .lx-stage { min-height: 340px; } .lx-tabs button { padding: 8px 10px; font-size: .75rem; } }
@media (max-width: 959px) { .lx-tabs > * { flex: none; white-space: nowrap; } }

/* ================= round 4: one shared column for About, Skills and contact ================= */
.about .wrap > .ab, .about .wrap > .sk { max-width: 76rem; margin-inline: auto; }
.about .ab { padding-inline: var(--s-6); }
.ab-text { margin-top: var(--s-4); max-width: 50rem; }
.ab-text p { font-size: clamp(1.0625rem, 1.35vw, 1.1875rem); line-height: 1.85; color: var(--ink-2); }
.ab-text a { color: var(--ink); text-decoration: underline; text-decoration-color: rgba(31, 95, 174, .45); text-decoration-thickness: 1.5px; text-underline-offset: 4px; transition: text-decoration-color .2s; }
.ab-text a:hover { text-decoration-color: var(--accent); }
.sk { margin-top: var(--s-8); }
.sk-row { grid-template-columns: 11rem minmax(0, 1fr); }
.sk-list { gap: 6px; }
.sk-list li { height: 30px; font-size: .8125rem; padding: 0 10px 0 8px; gap: 6px; }
@media (max-width: 720px) { .about .ab { padding-inline: 0; } .sk-row { grid-template-columns: 1fr; } }
/* Lagos: hide hairline seams between basemap tiles at fractional zoom */
.lx .leaflet-container { background: #e8e8e6; }
.sk-h { padding-top: 8px; line-height: 1.4; }
@media (max-width: 720px) { .sk-h { line-height: 1.4; } }

/* ================= round 5: review fixes ================= */
.inset .inset-text { position: static; }
.about .wrap > .ab, .about .wrap > .sk { max-width: none; }
.about .ab { padding-inline: 0; }
.ab-text { max-width: 44rem; }

/* ================= round 6: About feel — large lead, pill links, bold anchors ================= */
.ab-text { max-width: 46rem; }
.ab-text p { line-height: 1.75; }
.ab-text .ab-lead { font-size: clamp(1.375rem, 2.1vw, 1.75rem); line-height: 1.45; color: var(--ink); letter-spacing: -.015em; }
.ab-text .ab-lead b { font-weight: 500; }
.ab-text p + p { margin-top: var(--s-5); }
.ab-text a.ab-chip { text-decoration: none; color: #1d4a8a; }
.ab-text b { font-weight: 500; color: var(--ink); }
@media (max-width: 560px) { .ab-text a.ab-chip { white-space: normal; display: inline; padding: 1px 6px; box-decoration-break: clone; -webkit-box-decoration-break: clone; } .ab-text a.ab-chip svg { display: none; } .ab-text .nw { white-space: normal; } }

/* ================= round 7: centred About, justified text, review fixes ================= */
.about .wrap > .ab { max-width: 46rem; margin-inline: auto; }
.about .wrap > .sk { max-width: 64rem; margin-inline: auto; }
.ab-text { max-width: none; }
.ab-text p { text-align: justify; hyphens: auto; -webkit-hyphens: auto; text-wrap: pretty; }
.ab-text .ab-lead { text-align: left; }
/* one corner language: small and squared */
:root { --r: 6px; --r-s: 4px; --r-xs: 3px; }
.lx-tabs, .lx-legend { border-radius: 6px; }
.lx-tabs button, .lx-tab, .lx-c { border-radius: 4px; }
.sk-list li { border-radius: 4px; }
.ab-chip { border-radius: 5px; }
/* quieter ticker */
.ticker { padding-block: 10px; }
.ticker span { font-family: var(--text); font-weight: 400; font-size: clamp(1rem, 1.6vw, 1.1875rem); color: var(--ink-2); }
.ticker i { color: var(--ink-3); font-size: .625rem; }
/* touch targets */
.site-nav a { min-height: 44px; display: inline-flex; align-items: center; }
/* index map scale label on phones */
@media (max-width: 560px) { .scale .mid { display: none; } .scale span { font-size: 9px; } }
.ab-text a.ab-chip { display: inline; white-space: normal; padding: 2px 7px 3px; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.ab-text a.ab-chip svg { display: inline-block; vertical-align: -2px; margin-right: 5px; }
.ab-text .nw { white-space: normal; }

/* ================= portrait beside the opening line ================= */
.ab-intro { display: flex; align-items: center; gap: var(--s-5); }
.ab-pic { position: relative; flex: none; width: 76px; height: 76px; margin: 0; transform: rotate(-3deg); transition: transform .5s var(--ease); }
.ab-pic img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 14px; background: #fff; box-shadow: 0 0 0 3px #fff, 0 10px 24px rgba(20, 20, 18, .14); }
.ab-pic svg { position: absolute; inset: -6px; width: calc(100% + 12px); height: calc(100% + 12px); overflow: visible; pointer-events: none; }
.ab-pic rect { fill: none; stroke: #c9c8c2; stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 1; stroke-dashoffset: 1; opacity: .7; }
.ab-pic:hover { transform: rotate(0deg) scale(1.04); }
.js .about .ab-pic { opacity: 0; transform: rotate(-9deg) scale(.85); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .about.in .ab-pic { opacity: 1; transform: rotate(-3deg); }
.js .about.in .ab-pic:hover { transform: rotate(0deg) scale(1.04); }
.about.in .ab-pic rect { animation: abDraw 1.4s .35s var(--ease) forwards; }
@keyframes abDraw { to { stroke-dashoffset: 0; } }
@media (max-width: 560px) { .ab-intro { gap: var(--s-4); } .ab-pic { width: 60px; height: 60px; } }
@media (prefers-reduced-motion: reduce) { .js .about .ab-pic, .js .about.in .ab-pic { opacity: 1; transform: rotate(-3deg); transition: none; } .ab-pic rect { animation: none !important; stroke-dashoffset: 0; } }
.ab-text .ab-lead { hyphens: manual; -webkit-hyphens: manual; margin: 0; }
.ab-intro + p { margin-top: var(--s-5); }
@media (max-width: 560px) { .ab-text .ab-lead { font-size: 1.1875rem; } }
/* pre-push review: keep pills whole, plain left text on phones, even contact buttons */
@media (min-width: 561px) { .ab-text a.ab-chip { white-space: nowrap; display: inline-block; line-height: 1.5; } }
@media (max-width: 560px) {
  .ab-text p { text-align: left; hyphens: manual; -webkit-hyphens: manual; }
}
.hello-body { text-wrap: pretty; }

/* ================= wider, larger About and Skills ================= */
.about .wrap > .ab { max-width: 62rem; }
.about .wrap > .sk { max-width: 80rem; }
.ab-text p { font-size: clamp(1.0625rem, 1.45vw, 1.3125rem); line-height: 1.8; }
.ab-text .ab-lead { font-size: clamp(1.375rem, 2.4vw, 2.125rem); line-height: 1.35; }
.ab-pic { width: 92px; height: 92px; }
.sk-row { grid-template-columns: 13rem minmax(0, 1fr); padding-block: 12px; }
.sk-h { font-size: .75rem; }
.sk-list { gap: 8px; }
.sk-list li { height: 36px; font-size: .9375rem; padding: 0 13px 0 11px; gap: 8px; }
.sk-b, .sk-g { width: 17px; height: 17px; }
.sk-h { padding-top: 10px; }
@media (max-width: 720px) { .sk-row { grid-template-columns: 1fr; } .sk-list li { height: 32px; font-size: .875rem; } .sk-h { padding-top: 0; } }
@media (max-width: 560px) { .ab-pic { width: 64px; height: 64px; } }
/* even wider */
.about .wrap > .ab { max-width: 74rem; }
.about .wrap > .sk { max-width: none; }
@media (min-width: 1100px) { .about .wrap > .sk { margin-inline: calc(-1 * var(--s-6)); } .about .wrap > .ab { max-width: none; } }

/* ================= Projects as cards, two per row; content unchanged ================= */
.inset-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; border-bottom: 0; }
.inset, .inset:first-child { display: flex; flex-direction: column; gap: 0; align-items: stretch; padding: 10px; border: 1px solid #e8e7e2; border-top: 1px solid #e8e7e2; border-radius: 22px; background: #fff; box-shadow: 0 1px 2px rgba(20, 20, 18, .03); transition: box-shadow .35s var(--ease), transform .35s var(--ease); }
.inset:hover { transform: translateY(-3px); box-shadow: 0 16px 36px rgba(20, 20, 18, .09); }
.inset .inset-media { order: -1; border-radius: 15px; border: 1px solid #edece8; }
.inset .inset-text { max-width: none; padding: 20px 14px 10px; }
.inset h3 { font-size: clamp(1.375rem, 1.9vw, 1.75rem); }
.inset--wide { grid-column: 1 / -1; }
.inset--wide .inset-text { order: 1; max-width: 52rem; }
.inset--wide figure.lx { order: -1; margin: 0; border-radius: 15px; }
@media (max-width: 860px) { .inset-list { grid-template-columns: 1fr; gap: 18px; } }
@media (prefers-reduced-motion: reduce) { .inset:hover { transform: none; } }
.inset .inset-text { display: flex; flex-direction: column; flex: 1; }
.inset .inset-actions { margin-top: auto; padding-top: var(--s-5); }

#studies .sec-head { border-top: 0; padding-top: 0; }
#studies .sec-head::before { display: none; }
@media (min-width: 1100px) { #studies .inset-list { margin-inline: calc(-1 * var(--s-6)); } }
.inset-list { gap: 28px; }
.inset .tags { flex-wrap: nowrap; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
.inset .tags li { flex: none; white-space: nowrap; }
.cta { display: inline-flex; align-items: center; gap: 10px; height: 48px; padding: 0 26px; border-radius: 999px; font-family: var(--mono); font-size: .8125rem; font-weight: 400; letter-spacing: .1em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: background .25s, border-color .25s, transform .3s var(--ease); }
.cta { background: #1b1c1f; color: #fff; border: 1px solid #1b1c1f; }
.inset:hover .cta { background: #2c2d31; }
.cta .arrow { color: #6f8fd6; }
.cta:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
@media (max-width: 560px) { .cta { height: 44px; padding: 0 20px; } }
.inset, .inset .inset-text { min-width: 0; }
@media (max-width: 860px) { .inset-list { grid-template-columns: minmax(0, 1fr); } }

@font-face { font-family: 'Newsreader'; src: url(assets/fonts/Newsreader-var.woff2) format('woff2'); font-weight: 200 800; font-display: swap; }

/* ================= modern header ================= */
.collar-top { padding-block: 12px; }
.hd { display: grid !important; grid-template-columns: 1fr auto 1fr; align-items: center !important; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 500; letter-spacing: -.01em; }
.site-nav { justify-self: center; gap: 2px !important; padding: 4px; border: 1px solid #e6e5e0; border-radius: 999px; background: rgba(255, 255, 255, .7); }
.site-nav a { min-height: 34px !important; padding: 0 16px !important; border-radius: 999px; font-size: .875rem; color: var(--ink-2); text-decoration: none !important; transition: background .2s, color .2s; }
.site-nav a:hover { color: var(--ink); background: #f2f1ee; }
.site-nav a[aria-current="true"] { color: #fff; background: #1b1c1f; }
@media (max-width: 860px) { .hd { grid-template-columns: 1fr auto; } .site-nav { display: none !important; } }

/* ================= one section-header style ================= */
.sh { display: flex; align-items: baseline; gap: 14px; margin-bottom: var(--s-6); }
.sh h2 { font-family: 'Newsreader', var(--display); font-weight: 500; font-size: clamp(2rem, 3.6vw, 2.875rem); letter-spacing: -.02em; line-height: 1; }
.sh--in { margin: 0; padding: var(--s-5) var(--s-6); border-bottom: 1px dashed #d4d3cd; }
#studies .sec-head { display: none; }
#map .sh { margin-bottom: var(--s-5); }

/* ================= project cards: wider, more air, Newsreader titles ================= */
@media (min-width: 1100px) { #studies .inset-list { margin-inline: -56px; } }
.inset-list { gap: 40px; }
.inset h3 { font-family: 'Newsreader', var(--display); font-weight: 500; font-size: clamp(1.625rem, 2.2vw, 2.125rem); line-height: 1.12; letter-spacing: -.015em; }

/* ================= About: more line height ================= */
.ab-text p { line-height: 2; }
.ab-text .ab-lead { font-family: 'Newsreader', var(--display); font-weight: 400; line-height: 1.3; letter-spacing: -.01em; }

/* ================= Skills: clearer labels, even two-line rows ================= */
.sk-row { grid-template-columns: 14rem minmax(0, 1fr); align-items: center; padding-block: 18px; border-bottom: 1px solid #f0efeb; }
.sk-row:last-child { border-bottom: 0; }
.sk-h { font-family: var(--text); font-size: .9375rem !important; font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--ink); padding-top: 0 !important; line-height: 1.3 !important; }
.sk-list { display: grid !important; grid-template-columns: repeat(var(--c), max-content); gap: 10px; }
.sk-list li { justify-content: flex-start; }
.sk-row--next { border-top: 1px dashed #d4d3cd; margin-top: 0; padding-top: 18px; }
.sk-row--next .sk-h { color: var(--ink-2); }
@media (max-width: 1100px) { .sk-list { display: flex !important; flex-wrap: wrap; } }
@media (max-width: 720px) { .sk-row { grid-template-columns: 1fr; gap: 10px; } }

/* ================= footer ================= */
.site-footer { border-top: 1px solid var(--rule); padding-block: var(--s-7) var(--s-5); overflow: hidden; }
.site-footer .wrap { display: block !important; }
.ft-nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.ft-nav a { font-size: .875rem; color: var(--ink-2); }
.ft-nav a:hover { color: var(--ink); }
@keyframes ftPan { to { background-position: 100% 50%; } }
.f-credits { margin-top: var(--s-5); font-size: .8125rem; color: var(--ink-3); }
/* tablet and phone: keep the section nav as a scrollable second row */
@media (max-width: 860px) {
  .hd { grid-template-columns: 1fr auto; grid-template-areas: "brand act" "nav nav"; row-gap: 10px; }
  .hd .brand { grid-area: brand; }
  .site-nav { display: flex !important; grid-area: nav; justify-self: stretch; justify-content: space-between; overflow-x: auto; scrollbar-width: none; }
  .site-nav::-webkit-scrollbar { display: none; }
  .site-nav a { flex: 1 0 auto; justify-content: center; padding: 0 12px !important; }
}
@media (max-width: 1100px) { .lx-tabs { right: 10px; max-width: none; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; } .lx-tabs > * { flex: none; white-space: nowrap; } }
.inset .tags { -webkit-mask-image: none; mask-image: none; }
.inset .tags li.off { display: none; }
/* header: name left, nav right */
.hd { display: flex !important; justify-content: space-between; align-items: center !important; grid-template-areas: none !important; }
.site-nav { display: flex !important; justify-self: auto; overflow: visible; }
@media (max-width: 860px) { .site-nav { justify-content: flex-end; } .site-nav a { flex: none; padding: 0 12px !important; } }
@media (max-width: 420px) { .site-nav a { padding: 0 10px !important; font-size: .8125rem; } }
/* card buttons: squared, white arrow */
.cta { border-radius: 6px; }
.cta .arrow { color: #fff; }
/* titles: full width, no balancing */
.inset h3 { max-width: none; text-wrap: wrap; }
.inset .inset-text { max-width: none !important; }
.sh { gap: 0; }
/* header links: plain, hover only */
.site-nav { padding: 0 !important; border: 0 !important; background: none !important; gap: 28px !important; }
.site-nav a, .site-nav a[aria-current="true"] { padding: 0 !important; background: none !important; color: var(--ink-2); border-radius: 0; }
.site-nav a:hover, .site-nav a[aria-current="true"]:hover { color: var(--ink); background: none !important; }
.site-nav a[aria-current="true"] { color: var(--ink); }
@media (max-width: 420px) { .site-nav { gap: 18px !important; } }
/* current section: dark text with a short underline */
.site-nav a { position: relative; }
.site-nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 1.5px; background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.site-nav a[aria-current="true"] { color: var(--ink); font-weight: 500; }
.site-nav a[aria-current="true"]::after { transform: scaleX(1); }
@media (prefers-reduced-motion: reduce) { .site-nav a::after { transition: none; } }
/* current section: a small dot instead of an underline */
.site-nav a::after { display: none; }
.site-nav a[aria-current="true"] { font-weight: 400; }
.site-nav a::before { content: ""; position: absolute; left: -12px; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--accent); opacity: 0; transform: scale(.3); transition: opacity .25s, transform .3s var(--ease); }
.site-nav a[aria-current="true"]::before { opacity: 1; transform: none; }
/* visual review: Lagos labels on small screens, legend size, skills on tablets, learning contrast */
@media (max-width: 1100px) { .lx-legend { width: 200px; padding: 10px 12px; } }
@media (max-width: 700px) { .lx .lx-lab, .lx .leaflet-tooltip { display: none !important; } }
@media (max-width: 1100px) { .sk-row { grid-template-columns: 10rem minmax(0, 1fr); } }
@media (max-width: 720px) { .sk-row { grid-template-columns: 1fr; } }
.sk-row--next li { color: var(--ink-2); border-color: #cfcec8; }
.sk-row--next .sk-g { stroke: #6a6963; }
.sk-row--next .sk-h { color: var(--ink); }
/* language switcher */
.hd { gap: 28px; }
.hd .site-nav { margin-left: auto; }
.lang { display: inline-flex; padding: 3px; border-radius: 999px; background: #efeeea; }
.lang a { min-width: 38px; height: 30px; display: inline-flex; align-items: center; justify-content: center; padding: 0 10px; border-radius: 999px; font-size: .8125rem; font-weight: 500; color: var(--ink-2); text-decoration: none; transition: background .2s, color .2s; }
.lang a:hover { color: var(--ink); }
.lang a[aria-current="true"] { background: #1b1c1f; color: #fff; }
.lang a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (max-width: 560px) { .hd { gap: 14px; } .lang a { min-width: 32px; height: 28px; padding: 0 8px; font-size: .75rem; } .hd .brand { font-size: .9375rem; } }
/* phones: name and language on the first row, sections on the second */
@media (max-width: 640px) {
  .hd { flex-wrap: wrap; row-gap: 6px; }
  .hd .brand { order: 1; }
  .hd .lang { order: 2; margin-left: auto; }
  .hd .site-nav { order: 3; width: 100%; margin-left: 0; justify-content: flex-start; gap: 22px !important; }
}
/* cards: lower, clearer buttons; larger, airier descriptions */
.cta { height: 40px; padding: 0 20px; font-size: .875rem; letter-spacing: .08em; font-weight: 500; }
.inset .inset-desc { font-size: 1.0625rem; line-height: 1.75; color: var(--ink-2); max-width: none; }
@media (max-width: 560px) { .inset .inset-desc { font-size: 1rem; } }
.inset--wide .inset-desc { max-width: 40rem; }
/* cards: no hover shadow; one fixed map with a study-area caption */
.inset:hover { box-shadow: 0 1px 2px rgba(20, 20, 18, .03); }
.map-cap { position: absolute; left: 14px; bottom: 14px; max-width: calc(100% - 28px); margin: 0; padding: 6px 11px; border-radius: 6px; background: rgba(20, 20, 18, .82); color: #fff; font-size: .8125rem; line-height: 1.35; z-index: 2; }
/* About: words darken as the paragraph is read */
.ab-text .rw { color: #c9c8c2; transition: color .35s ease; }
.ab-text .rw.on { color: inherit; }
@media (prefers-reduced-motion: reduce) { .ab-text .rw { color: inherit; transition: none; } }
/* card titles: balanced breaks, up to three lines */
.inset h3 { text-wrap: balance; max-width: 34ch; }
.inset--wide h3 { max-width: 34ch; }
.inset h3 { max-width: none; font-size: clamp(1.4rem, 1.95vw, 1.875rem); line-height: 1.15; }
@media (max-width: 1100px) { .inset h3 { font-size: 1.375rem; } }
@media (max-width: 560px) { .inset h3 { font-size: 1.25rem; } }
.inset--wide h3 { max-width: 30ch; }
.ab-pic:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* contact: centred, short, small buttons */


/* footer: one quiet line of links between copyright and credits */
.site-footer { padding-block: var(--s-6); }
.ft { display: grid !important; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--s-4); }
.ft-copy { font-family: var(--mono); font-size: .75rem; color: var(--ink-3); }
.ft-nav { justify-self: center; display: flex; gap: 0; }
.ft-nav a { font-family: var(--mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); padding: 6px 12px; text-decoration: none; }
.ft-nav a + a { border-left: 1px solid var(--rule); }
.ft-nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.ft .f-credits { justify-self: end; margin: 0; font-size: .75rem; text-align: right; max-width: 22rem; }
@media (max-width: 900px) { .ft { grid-template-columns: 1fr; justify-items: center; text-align: center; } .ft .f-credits { justify-self: center; text-align: center; } .ft-nav { flex-wrap: wrap; justify-content: center; } }
.site-footer .ft { display: grid !important; grid-template-columns: 1fr auto 1fr; align-items: center; }
.site-footer .ft-nav a { min-height: 0; padding: 4px 14px; }
.site-footer .ft .f-credits { max-width: none; white-space: nowrap; }
@media (max-width: 1100px) { .site-footer .ft { grid-template-columns: 1fr; justify-items: center; text-align: center; } .site-footer .ft .f-credits { white-space: normal; justify-self: center; text-align: center; } }
.site-footer .ft-nav { gap: 0 !important; }
@media (max-width: 560px) { .site-footer .ft-nav a { padding: 4px 9px; font-size: .6875rem; } .site-footer .ft-nav { flex-wrap: nowrap; } }
/* About heading row: email on the right */
.sh--row { justify-content: space-between; align-items: baseline; flex-wrap: wrap; row-gap: 10px; }
.about { padding-bottom: var(--s-8); }
@media (max-width: 560px) { .sh--row { flex-direction: column; align-items: flex-start; } }
.sh-cta { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 16px; border-radius: 6px; background: #1b1c1f; color: #fff; font-size: .875rem; font-weight: 500; text-decoration: none; transition: background .2s; }
.sh-cta:hover { background: #2c2d31; }
.sh-cta:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.sh-cta svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round; }
@media (max-width: 560px) { .sh--row { flex-direction: row; align-items: center; } }

/* About: workplaces with a dotted underline */
.ab-text b.org { font-weight: 500; color: var(--ink); text-decoration: underline dotted #a9a8a1; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
/* credentials: a quiet row of tags that settles in when About appears */
.creds { list-style: none; margin: var(--s-5) 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.creds li { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 12px; border: 1px solid #e3e2dc; border-radius: 6px; background: #fff; font-size: .8125rem; color: var(--ink); white-space: nowrap; }
.creds li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex: none; }
.js .about .creds li { opacity: 0; transform: translateY(10px) scale(.96); transition: opacity .45s var(--ease), transform .55s cubic-bezier(.34, 1.4, .64, 1); }
.js .about.in .creds li { opacity: 1; transform: none; }
.js .about.in .creds li:nth-child(2) { transition-delay: .05s; } .js .about.in .creds li:nth-child(3) { transition-delay: .1s; } .js .about.in .creds li:nth-child(4) { transition-delay: .15s; } .js .about.in .creds li:nth-child(5) { transition-delay: .2s; } .js .about.in .creds li:nth-child(6) { transition-delay: .25s; } .js .about.in .creds li:nth-child(7) { transition-delay: .3s; } .js .about.in .creds li:nth-child(8) { transition-delay: .35s; } .js .about.in .creds li:nth-child(9) { transition-delay: .4s; }
@media (max-width: 560px) { .creds li { white-space: normal; height: auto; padding: 6px 10px; } }
@media (prefers-reduced-motion: reduce) { .js .about .creds li { opacity: 1; transform: none; transition: none; } }
.creds { margin-bottom: var(--s-6); }
.sh h3 { font-family: 'Newsreader', var(--display); font-weight: 500; font-size: clamp(2rem, 3.6vw, 2.875rem); letter-spacing: -.02em; line-height: 1; }
/* About: three left-aligned paragraphs; words start at a readable grey (about 4.6:1) and darken as read */
.ab-text p, .ab-text .ab-lead { text-align: left; hyphens: manual; -webkit-hyphens: manual; }
.ab-text p + p { margin-top: var(--s-5); }
.ab-text .rw { color: #6f6e68; }
.ab-text .rw.on { color: var(--ink); }
.ab-text .ab-p1, .ab-text .ab-p2, .ab-text .ab-p3 { max-width: 70ch; }
.ab-text .rw { white-space: nowrap; }
/* visible focus on project title links */
.inset .inset-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 2px; }
/* skills: fall back to wrapping whenever the even grid would not fit (also at large text sizes) */
@media (max-width: 87em) { .sk-list { display: flex !important; flex-wrap: wrap; } }
@media (max-width: 87em) { .about .wrap > .sk { margin-inline: 0 !important; } }
/* without JavaScript: still images instead of the globe and the Lagos tour */
html:not(.js) .globe canvas, html:not(.js) .g-rule, html:not(.js) .g-ends, html:not(.js) .g-cap, html:not(.js) .g-line { display: none; }
.globe-still { display: block; width: min(100%, 330px); height: auto; margin: 0 auto; }
.lx-still { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
html:not(.js) .lx-tabs, html:not(.js) .lx-legend, html:not(.js) .lx-panel { display: none; }
html:not(.js) .lx { grid-template-columns: 1fr; }

/* ================= one design language: 6 px buttons, 14 px cards, solid hairlines ================= */
:root { --line-soft: #e6e5e0; }
/* buttons: same shape and type */
.cta, .sh-cta { border-radius: 6px; height: 40px; padding: 0 18px; font-family: var(--mono); font-size: .8125rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; }
/* language switch: same corner as the buttons */
.lang { border-radius: 8px; } .lang a { border-radius: 6px; }
/* cards: subtle corners */
.inset, .inset:first-child { border-radius: 14px; border-color: var(--line-soft); }
.inset .inset-media, .inset--wide figure.lx { border-radius: 10px; }
/* skills: solid hairline frame, no crosshairs */
.sk { border: 1px solid var(--line-soft) !important; border-radius: 14px; }
.sk::before, .sk::after, .sk-x { display: none !important; }
.sh--in { border-bottom: 1px solid var(--line-soft) !important; }
.sk-row--next { border-top: 1px solid var(--line-soft) !important; }
.sk-row--next li { border-style: solid; }
/* Lagos card: text in two columns under the map on wide screens */
@media (min-width: 1100px) {
  .inset--wide .inset-text { display: grid !important; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); column-gap: var(--s-8); max-width: none !important; }
  .inset--wide .tags, .inset--wide h3 { grid-column: 1; }
  .inset--wide .inset-desc { grid-column: 2; grid-row: 1 / span 2; align-self: end; margin: 0; }
  .inset--wide .inset-actions { grid-column: 2; grid-row: 3; padding-top: var(--s-4); }
}
/* globe about 20% larger */
.globe canvas, .globe-still { width: min(100%, 400px); }
@media (max-width: 899px) { .globe { max-width: 400px; } }
/* small phones: legend rows stack (swatch, title, then source) and use the full width */
@media (max-width: 480px) {
  .sheet-frame .margin { grid-template-columns: 1fr !important; padding-inline: 0 !important; }
  .legend { width: 100%; margin-left: 0 !important; }
  .leg { grid-template-columns: 22px minmax(0, 1fr) !important; row-gap: 4px; }
  .leg .leg-n { display: none; }
  .leg .leg-src { grid-column: 2; justify-self: start; }
}
/* hero tool tags: inline so line spacing stays even and commas sit right after them */
.hello-body .chip { display: inline; padding: 3px 8px 3px 6px; line-height: inherit; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.hello-body .chip svg { display: inline-block; vertical-align: -2px; margin-right: 6px; }
/* Lagos tabs wrap on small phones instead of being cut off */
@media (max-width: 480px) { .lx-tabs { flex-wrap: wrap !important; overflow: visible !important; } .lx-stage { min-height: 380px; } }
@media (max-width: 400px) { .scale span:first-of-type { display: none; } }

/* Leaflet's plus-lighter blend leaves light seams between map tiles at fractional zoom on a light basemap */
.leaflet-container img.leaflet-tile { mix-blend-mode: normal; }

/* project cards: one label on the map */
.inset .inset-media .map-cap { display: none; }

/* ---------- Project areas: one equal panel per project, each at its own scale ---------- */
.at-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.atlas { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.at-cell { border: 1px solid var(--rule); border-radius: var(--r); background: #fff; overflow: hidden; }
.at-map { display: block; width: 100%; height: auto; background: #eef0f1; border-bottom: 1px solid var(--rule); }
.at-land { fill: #f7f7f4; stroke: #c9c8c2; stroke-width: .8; stroke-linejoin: round; }
.at-fill { stroke: none; }
.at-line { fill: none; stroke-width: 1.6; stroke-linejoin: round; }
.at-scale path { stroke: #55554f; stroke-width: 2; }
.at-scale text { font-family: var(--mono); font-size: 11px; fill: #55554f; }
.at-text { display: grid; grid-template-columns: 1.8rem minmax(0, 1fr) auto; gap: 8px; align-items: start; padding: 12px 14px 14px; }
.at-n { font-family: var(--mono); font-size: var(--fs-meta); color: var(--ink); padding-top: 2px; }
.at-note { margin-top: var(--s-3); font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
@media (max-width: 960px) { .atlas { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .atlas { grid-template-columns: 1fr; } }
.at-map.at-local { background: #f7f7f4; }

/* ---------- Projects and tools: one catalogue, filter pills, grid or row view ---------- */
#studies .wrap { max-width: calc(1440px + 2 * var(--margin)); }
@media (min-width: 1100px) { #studies .inset-list { margin-inline: 0; } }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
#studies .anchor { display: block; position: relative; top: -96px; visibility: hidden; }
.pf-bar { display: none; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; margin: 0 0 22px; }
.js .pf-bar { display: flex; }
.pf-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.pf-f { font: inherit; font-size: .875rem; font-weight: 500; color: var(--ink); background: #efefec; border: 0; border-radius: 999px; padding: 8px 15px; min-height: 36px; cursor: pointer; white-space: nowrap; transition: background .2s, color .2s; }
.pf-f:hover { background: #e4e4e0; }
.pf-f .pf-n { margin-left: 3px; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.pf-f[aria-pressed="true"] { background: var(--ink); color: #fff; }
.pf-f[aria-pressed="true"] .pf-n { color: rgba(255, 255, 255, .72); }
.pf-f:focus-visible, .pf-v:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pf-view { display: flex; padding: 3px; border-radius: 999px; background: #efefec; }
.pf-v { display: grid; place-items: center; width: 38px; height: 32px; border: 0; border-radius: 999px; background: none; color: var(--ink-3); cursor: pointer; transition: background .2s, color .2s, box-shadow .2s; }
.pf-v svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linejoin: round; }
.pf-v:hover { color: var(--ink); }
.pf-v[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
#studies .inset.pf-hide { display: none; }
/* what each card is: a study or a tool */
.kind { display: inline-flex; width: fit-content; align-self: flex-start; justify-self: start; align-items: center; gap: 6px; margin: 0 0 12px; padding: 3px 10px 3px 8px; border-radius: 999px; font-size: .75rem; font-weight: 500; letter-spacing: .01em; line-height: 1.5; }
.kind::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.kind--study { background: #f2f2ef; color: #4a4943; }
.kind--tool { background: #eaf1fb; color: #1d4f99; }
/* row view: full-width horizontal cards, picture on the left */
.inset-list.is-row { grid-template-columns: minmax(0, 1fr); }
.is-row .inset { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 0 32px; align-items: center; }
.is-row .inset-media { order: -1; }
.is-row .inset-media img { aspect-ratio: 4 / 3; height: auto; }
.is-row .inset-text { max-width: 44rem; }
@media (max-width: 760px) {
  .pf-bar { gap: 12px; }
  .pf-filters { flex-wrap: nowrap; overflow-x: auto; width: 100%; padding-bottom: 2px; scrollbar-width: none; }
  .pf-filters::-webkit-scrollbar { display: none; }
  .pf-f { flex: none; }
  .is-row .inset { grid-template-columns: minmax(0, 1fr); gap: 16px; }
}

/* ================= City twins: an interactive card on the home page ================= */
.twin { padding-block: 0 var(--s-9); }
.tp { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 600px); align-items: stretch; gap: clamp(32px, 5vw, 80px); position: relative; }
.tp-text { position: relative; z-index: 2; max-width: 32rem; display: flex; flex-direction: column; }
.tp-text .tw-how { margin-top: auto; padding-top: var(--s-5); }
.tw-stage { align-self: start; }
.tp-lead { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink-2); margin-bottom: var(--s-5); }
.js .tp.reveal .tp-text > * { opacity: 0; transform: translateY(10px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .tp.reveal.in .tp-text > * { opacity: 1; transform: none; }
.js .tp.reveal.in .tp-text > :nth-child(2) { transition-delay: .06s; } .js .tp.reveal.in .tp-text > :nth-child(3) { transition-delay: .12s; }
.js .tp.reveal.in .tp-text > :nth-child(4) { transition-delay: .18s; } .js .tp.reveal.in .tp-text > :nth-child(n+5) { transition-delay: .24s; }

/* search */
.tw-find { position: relative; display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 18px; border: 1px solid var(--line); border-radius: 6px; background: #fff; transition: border-color .2s, box-shadow .3s var(--ease); }
.tw-find:focus-within { border-color: var(--ink); box-shadow: 0 10px 30px -14px rgba(20, 20, 18, .25); }
.tw-find > svg { width: 17px; height: 17px; flex: none; fill: none; stroke: var(--ink-3); stroke-width: 1.5; stroke-linecap: round; transition: stroke .2s, transform .3s var(--ease); }
.tw-find:focus-within > svg { stroke: var(--ink); transform: scale(1.08); }
.tw-find input { flex: 1; min-width: 0; height: 100%; border: 0; background: none; font: 500 1rem/1 var(--text); color: var(--ink); }
.tw-find input::placeholder { color: var(--ink-3); font-weight: 400; }
.tw-find input:focus { outline: none; }
.tw-sugg { position: absolute; z-index: 5; left: 0; right: 0; top: calc(100% + 8px); margin: 0; padding: 6px; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 18px 40px rgba(20, 20, 18, .08); animation: twDrop .22s var(--ease); }
.tw-sugg li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 5px; cursor: pointer; font-weight: 500; }
.tw-sugg li span { font-family: var(--mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); align-self: center; }
.tw-sugg li[aria-selected="true"], .tw-sugg li[data-n]:hover { background: var(--paper-2); }
.tw-sugg li.none { cursor: default; font-weight: 400; color: var(--ink-3); }
@keyframes twDrop { from { opacity: 0; transform: translateY(-4px); } }

/* buttons, matching the site */
.tw-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: var(--s-4); }
.tw-actions .cta { cursor: pointer; }
.tw-actions .cta .arrow { transition: transform .3s var(--ease); }
.tw-actions .cta:hover { background: #2c2d31; }
.tw-actions .cta:hover .arrow { transform: translateY(2px); }
.tw-actions .cta.done .arrow { transform: none; }
.tw-btn { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 6px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-family: var(--mono); font-size: .8125rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; transition: border-color .2s, transform .15s; }
.tw-btn:hover { border-color: var(--ink); }
.tw-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.tw-btn:active, .tw-actions .cta:active { transform: translateY(1px); }

.tw-how { margin-top: var(--s-6); }
.tw-how summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; font-family: var(--mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.tw-how summary::-webkit-details-marker { display: none; }
.tw-how summary::after { content: '+'; font-size: 1rem; line-height: 1; transition: transform .3s var(--ease); }
.tw-how[open] summary::after { transform: rotate(45deg); }
.tw-how summary:hover { color: var(--ink); }
.tw-how p { margin-top: var(--s-3); font-size: var(--fs-small); line-height: 1.65; color: var(--ink-2); animation: twDrop .3s var(--ease); }
.tw-err { margin-top: var(--s-4); font-size: var(--fs-small); color: #a3302a; }

/* the comparison table */
.tw-facts { width: 100%; table-layout: fixed; margin-top: var(--s-6); border-collapse: collapse; font-variant-numeric: tabular-nums; }
.tw-facts th, .tw-facts td { padding: 13px 0; border-bottom: 1px solid #efeeea; text-align: left; font-weight: 400; vertical-align: baseline; }
.tw-facts thead th { padding-top: 0; border-bottom-color: #e4e3dd; font-family: var(--mono); font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;  }
.tw-facts tbody th { font-size: var(--fs-small); color: var(--ink-2); width: 40%; padding-right: 12px; }
.tw-facts td { font-family: var(--mono); font-size: .875rem; color: var(--ink); width: 29%; padding-right: 8px; }
.tw-facts tr.hit th { color: var(--ink); font-weight: 500; }
.tw-facts tr.hit th::before { content: ''; display: inline-block; width: 6px; height: 6px; margin: 0 8px 2px 0; border-radius: 50%; background: var(--tw-c); }
.tw-facts tr.hit td { color: var(--ink); font-weight: 600; }
.tw-k { display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: var(--tw-c); vertical-align: 1px; }
.tw-k--a { background: #fff; box-shadow: inset 0 0 0 1.5px var(--ink); }
.tw-facts tbody tr { animation: twRow .5s var(--ease) both; animation-delay: calc(var(--n) * 40ms); }
@media (max-width: 560px) { .tw-facts td { font-size: .8125rem; } .tw-facts tbody th { width: 44%; font-size: .875rem; } .tw-facts thead th { font-size: .6875rem; } }
@keyframes twRow { from { opacity: 0; transform: translateY(4px); } }
@media (prefers-reduced-motion: reduce) { .tw-facts tbody tr { animation: none; } }

/* the card */
.tw-stage { position: relative; z-index: 1; width: 100%; max-width: 600px; justify-self: end; }
.tw-stage canvas { display: block; width: 100%; height: auto; border-radius: 14px; border: 1px solid #e8e7e2; background: #fff; transition: opacity .4s ease; }
.tw-stage::after { content: ''; position: absolute; inset: 0; border-radius: 14px; pointer-events: none; opacity: 0; background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .7) 50%, transparent 70%) 0 0 / 250% 100%; transition: opacity .3s; }
.tw-stage.loading canvas { opacity: .6; }
.tw-stage.loading::after { opacity: 1; animation: twShine 1.4s linear infinite; }
@keyframes twShine { from { background-position: 150% 0; } to { background-position: -100% 0; } }
.tw-stage.swap canvas { animation: twSettle .7s var(--ease); }
@keyframes twSettle { from { transform: scale(.985); } }
.js .tp.reveal .tw-stage { opacity: 0; transform: translateY(24px) rotate(1.5deg); transition: opacity .9s ease .15s, transform 1.1s var(--ease) .15s; }
.js .tp.reveal.in .tw-stage { opacity: 1; transform: none; }

@media (max-width: 860px) {
  .tp { grid-template-columns: minmax(0, 1fr); gap: var(--s-5); }
  .tp-text { display: contents; }
  .tp-text .tw-how { padding-top: 0; }
  .tp-lead, .tw-find { position: relative; z-index: 2; }
  .tw-stage { order: 1; max-width: 520px; justify-self: center; } .tw-actions { order: 2; margin-top: 0; position: relative; z-index: 2; } .tw-facts { order: 3; margin-top: var(--s-2); } .tw-how { order: 4; margin-top: 0; position: relative; z-index: 2; }
  .tp-lead { margin-bottom: calc(-1 * var(--s-2)); }
  #twin .tp-lead { margin-bottom: 0; }
}
@media (max-width: 560px) { .tw-btn, .tw-actions .cta { height: 44px; } .tw-actions .cta { flex: 1; justify-content: center; } .tw-actions .tw-btn { flex: 1; justify-content: center; } }
@media (prefers-reduced-motion: reduce) {
  .js .tp.reveal .tp-text > *, .js .tp.reveal .tw-stage { opacity: 1; transform: none; transition: none; }
  .tw-sugg, .tw-how p, .tw-stage.swap canvas, .tw-stage.loading::after { animation: none; }
  .tw-find > svg, .tw-btn { transition: none; }
}

/* City twins: tighter heading, icons, gentle motion */
#twin .sh { margin-bottom: var(--s-4); }
#twin .tp-lead { margin-bottom: var(--s-5); }
@media (max-width: 860px) { #twin .tp { gap: var(--s-4); } #twin .tp-lead { margin-bottom: 0; } }
.tw-ic { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.tw-actions .cta, .tw-actions .tw-btn { gap: 8px; }
.tw-actions .cta:hover .tw-ic { transform: translateY(2px); }
.tw-actions .tw-btn:hover .tw-ic { transform: translateY(-2px); }
.tw-actions .cta.done .tw-ic { transform: scale(.9); }
.tw-stage.from-r canvas { animation: twFromR .55s var(--ease); }
.tw-stage.from-l canvas { animation: twFromL .55s var(--ease); }
@keyframes twFromR { from { transform: translateX(14px); opacity: .6; } }
@keyframes twFromL { from { transform: translateX(-14px); opacity: .6; } }
.js #twin .sh.reveal h2, .js #twin .sh h2 { transition: opacity .8s var(--ease), transform .8s var(--ease); }
@media (prefers-reduced-motion: reduce) { .tw-stage.from-r canvas, .tw-stage.from-l canvas { animation: none; } .tw-ic { transition: none; } }
.tw-actions .cta[aria-disabled="true"] { opacity: .5; cursor: progress; }

/* City twins: fit the table between tablet and laptop widths, larger targets on phones */
@media (min-width: 861px) and (max-width: 1120px) { #twin .tp { grid-template-columns: minmax(340px, 1fr) minmax(0, 440px); gap: 40px; } }
#twin .tp-lead { text-wrap: balance; }
.tw-facts thead th:first-child { width: 40%; }
@media (max-width: 560px) { .tw-how summary { min-height: 44px; } }
@media (max-width: 400px) { .tw-facts thead th { font-size: .625rem; letter-spacing: .04em; } }
.tw-facts thead th { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.4; vertical-align: bottom; padding-right: 10px; }
.tw-facts thead th .tw-k { margin-right: 6px; }
@media (min-width: 861px) and (max-width: 1120px) { .tw-facts tbody th { font-size: .875rem; } .tw-facts td { font-size: .8125rem; } }

/* City twins on its own page: the heading keeps the section style */
.twin-page .sh h1 { font-family: 'Newsreader', var(--display); font-weight: 500; font-size: clamp(2rem, 3.6vw, 2.875rem); letter-spacing: -.02em; line-height: 1; margin: 0; }
.twin-page main { padding-top: var(--s-6); }
