:root {
  --bg: #faf8f4;
  --card: #ffffff;
  --ink: #1d2430;
  --muted: #5b6472;
  --line: #e4dfd5;
  --accent: #1f4f7a;
  --accent-ink: #ffffff;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #12161c;
    --card: #1a2029;
    --ink: #e9ecf1;
    --muted: #a3acb9;
    --line: #2b3441;
    --accent: #8fc1ea;
    --accent-ink: #10202e;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.wrap { max-width: 760px; margin: 0 auto; padding: 0 20px; }
a { color: var(--accent); text-underline-offset: 3px; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; line-height: 1.2; font-weight: 700; }

.hero { padding: 56px 0 40px; display: flex; gap: 28px; align-items: center; }
.photo {
  flex: 0 0 auto; width: 148px; height: 148px; border-radius: 50%;
  overflow: hidden; border: 3px solid var(--card); box-shadow: 0 0 0 1px var(--line);
}
.photo img { width: 100%; height: 100%; display: block; object-fit: cover; transform: scale(1.04); }
h1 { font-size: 2.5rem; margin: 0 0 8px; letter-spacing: -0.01em; }
.headline { margin: 0 0 4px; font-size: 1.08rem; }
.place { margin: 0 0 16px; color: var(--muted); font-size: 0.95rem; }
.btn {
  display: inline-block; background: var(--accent); color: var(--accent-ink);
  padding: 10px 18px; border-radius: 6px; text-decoration: none; font-weight: 600; font-size: 0.98rem;
}
.btn:hover { filter: brightness(1.1); }

section { padding: 34px 0; border-top: 1px solid var(--line); }
h2 { font-size: 1.5rem; margin: 0 0 18px; }
h3 { font-size: 1.15rem; margin: 0 0 2px; }
p { margin: 0 0 14px; }
p:last-child { margin-bottom: 0; }

.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 18px 20px; }
.card .role { color: var(--muted); font-size: 0.93rem; margin: 0 0 8px; }
.card p { font-size: 0.97rem; }

.job { padding: 18px 0; border-top: 1px dashed var(--line); }
.job:first-of-type { border-top: 0; padding-top: 0; }
.job:last-of-type { padding-bottom: 0; }
.meta { color: var(--muted); font-size: 0.93rem; margin: 0 0 8px; }
.job p, .job li { font-size: 0.98rem; }
ul { margin: 0 0 14px; padding-left: 20px; }
li { margin-bottom: 6px; }

.plain { list-style: none; padding: 0; margin: 0; }
.plain li { margin-bottom: 12px; }
.plain li:last-child { margin-bottom: 0; }
.plain span { color: var(--muted); font-size: 0.93rem; display: block; }
.plain span a { color: var(--accent); }

.tags { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tags li { margin: 0; border: 1px solid var(--line); background: var(--card); border-radius: 999px; padding: 4px 13px; font-size: 0.92rem; }

.connect { text-align: center; }
.connect p { margin-bottom: 18px; }
footer { border-top: 1px solid var(--line); padding: 22px 0 40px; color: var(--muted); font-size: 0.88rem; text-align: center; }

.notfound { padding: 96px 0; text-align: center; }

@media (max-width: 640px) {
  body { font-size: 16px; }
  .hero { flex-direction: column; text-align: center; padding: 40px 0 30px; gap: 18px; }
  h1 { font-size: 2rem; }
  .cards { grid-template-columns: 1fr; }
}
.mono { display: flex; align-items: center; justify-content: center; background: var(--accent); color: var(--accent-ink); font: 700 3rem Georgia, "Times New Roman", serif; }

/* Colour and motion: dark, bold look inspired by future5th.com */
:root { color-scheme: dark; --bg: #000; --card: rgba(255,255,255,.05); --ink: #eeeeee; --muted: #a9adbb; --line: rgba(255,255,255,.14); --accent: #9db4ff; --accent-ink: #060a18; --navy: #0f1f52; --ember: #5a1005; }
html { scroll-behavior: smooth; }
main.wrap:not(.notfound) { max-width: none; padding: 0; }
main > header, main > section { padding-left: max(20px, calc(50% - 400px)); padding-right: max(20px, calc(50% - 400px)); }
h1, h2 { font-family: "Helvetica Neue", Inter, "Segoe UI", Arial, sans-serif; text-transform: uppercase; letter-spacing: -0.035em; font-weight: 800; }
h3 { font-family: "Helvetica Neue", Inter, "Segoe UI", Arial, sans-serif; }
.nav, .btn, .meta, .place, .plain span, .tags li, footer { font-family: "Space Mono", "Cascadia Mono", Consolas, ui-monospace, monospace; }

.nav { position: sticky; top: 0; z-index: 10; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 28px; padding: 15px 20px; background: rgba(13,24,58,.88); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav a { color: var(--ink); text-decoration: none; text-transform: uppercase; font-weight: 700; font-size: .85rem; letter-spacing: .08em; }
.nav a:hover { color: var(--accent); }

.hero { position: relative; overflow: hidden; flex-direction: column; text-align: center; justify-content: center; min-height: 78vh; gap: 26px; padding-top: 64px; padding-bottom: 64px; background: linear-gradient(180deg, #0b0b0d 0%, #121214 55%, var(--navy) 100%); }
.hero > div { position: relative; z-index: 1; }
/* waves that change shape and move corner to corner (drawn by rings.js) */
.wash { position: absolute; top: 0; bottom: 0; left: 0; width: 160%; pointer-events: none; -webkit-mask-image: linear-gradient(90deg, #000 65%, transparent); mask-image: linear-gradient(90deg, #000 65%, transparent); animation: wash 2.8s ease-in-out both; }
@keyframes wash { from { transform: translateX(-100%); } to { transform: translateX(0); } }
.wave { position: absolute; width: 500px; height: 500px; overflow: visible; pointer-events: none; opacity: 0; fill: none; filter: drop-shadow(0 0 12px rgba(157,180,255,.45)); animation: ring 7s linear infinite both; }
.wave * { stroke: rgba(255,255,255,.4); stroke-width: 3; stroke-linejoin: round; }
.wave .outer { stroke: rgba(255,255,255,.2); stroke-width: 2; }
.wave.bl { left: -170px; bottom: -170px; }
.wave.tl { left: -170px; top: -170px; }
.wave.tr { right: -170px; top: -170px; }
.wave.br { right: -170px; bottom: -170px; }
.hero .photo { width: 210px; height: 210px; border: 3px solid #fff; box-shadow: 0 0 40px rgba(157,180,255,.45); animation: pop .9s cubic-bezier(.2,1.3,.4,1) both; }
.hero > div:last-child { animation: rise .9s .2s ease both; }
h1 { font-size: clamp(2.6rem, 9vw, 5.4rem); line-height: .95; margin-bottom: 18px; }
.headline { max-width: 560px; margin: 0 auto 8px; }
.place { margin-bottom: 22px; }

.btn { border-radius: 0; border: 1px solid rgba(255,255,255,.28); background: linear-gradient(180deg, #1b2a63, #0a1030); color: #fff; text-transform: uppercase; letter-spacing: .08em; font-size: .85rem; padding: 13px 24px; transition: transform .2s, box-shadow .2s, background .2s; }
.btn:hover { transform: translateY(-3px); box-shadow: 0 8px 26px rgba(157,180,255,.35); filter: brightness(1.25); }

section { border-top: 0; padding-top: 64px; padding-bottom: 64px; scroll-margin-top: 52px; background-size: 200% 200%; animation: glow 16s ease-in-out infinite; }
#s-about  { background-image: linear-gradient(160deg, #000 35%, #0b1530 75%, #000); }
#s-exp    { background-image: linear-gradient(115deg, #3d0502 0%, var(--ember) 18%, #1c0703 45%, #000 75%, #241008); }
#s-edu    { background-image: linear-gradient(200deg, #000 30%, var(--navy) 75%, #05070f); }
#s-projects, #s-featured  { background-image: linear-gradient(60deg, #000 30%, #2a1206 65%, #000); }
#s-featured { background-image: linear-gradient(115deg, #000 30%, var(--navy) 75%, #05070f); }
#s-skills { background-image: linear-gradient(150deg, #05070f, #101c46 55%, #000); }
h2 { font-size: clamp(2rem, 7vw, 3.8rem); line-height: 1; text-align: center; margin-bottom: 34px; }
#s-about p { text-align: center; font-size: 1.12rem; }

.job, .job:first-of-type, .job:last-of-type { border: 0; border-top: 1px solid var(--line); padding: 22px 14px; transition: background .25s, transform .25s; }
.job:hover { background: var(--card); transform: translateX(6px); }
.meta, .plain span { text-transform: uppercase; font-size: .8rem; letter-spacing: .04em; }
.plain li { border-top: 1px solid var(--line); padding-top: 14px; }

.tags { justify-content: center; gap: 12px; }
.tags li { border-radius: 0; text-transform: uppercase; font-size: .8rem; font-weight: 700; padding: 10px 16px; transition: transform .2s, background .2s, color .2s; }
.tags li:hover { transform: translateY(-4px); background: #fff; color: #000; }

.connect { background: linear-gradient(180deg, #000, var(--navy)); }
footer { border-top: 1px solid var(--line); background: #000; }

/* sections slide in on scroll, where the browser supports it */
@supports (animation-timeline: view()) {
  section:not(.connect) > * { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% entry 110px; }
}
@keyframes ring { 0% { transform: scale(.15); opacity: 0; } 15% { opacity: .9; } 100% { transform: scale(3.6); opacity: 0; } }
@keyframes glow { 0%, 100% { background-position: 0% 0%; } 50% { background-position: 100% 100%; } }
@keyframes pop { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: scale(1); } }
@keyframes rise { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media (max-width: 640px) { .nav { gap: 4px 16px; } .nav a { font-size: .72rem; } .hero .photo { width: 168px; height: 168px; } }
.plain strong { display: block; }
.job h3 a { color: var(--ink); text-decoration-color: var(--accent); }
