:root {
  color-scheme: light dark;
  --bg: #fbfaf8;
  --fg: #17181a;
  --muted: #6b6b6b;
  --border: #e7e3dd;
  --accent-a: #d97a4d;
  --accent-b: #3f6b5e;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121212;
    --fg: #ececec;
    --muted: #9a9a9a;
    --border: #2a2a2a;
    --accent-a: #e58a5c;
    --accent-b: #6fae9b;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  line-height: 1.6;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle, var(--border) 1px, transparent 1.5px);
  background-size: 28px 28px;
  opacity: 0.6;
  pointer-events: none;
  z-index: -1;
}

.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
  min-height: 100vh;
  position: relative;
}

/* ---- Hero ---- */

.hero {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  margin-bottom: 3.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
}

.hero-photo {
  position: relative;
  flex: none;
  width: 168px;
  height: 168px;
}

.hero-blob {
  position: absolute;
  inset: -18px;
  border-radius: 42% 58% 63% 37% / 41% 44% 56% 59%;
  background: linear-gradient(135deg, var(--accent-a), var(--accent-b));
  opacity: 0.35;
  filter: blur(2px);
  animation: blob-morph 12s ease-in-out infinite;
}

@keyframes blob-morph {
  0%, 100% { border-radius: 42% 58% 63% 37% / 41% 44% 56% 59%; }
  50% { border-radius: 58% 42% 39% 61% / 55% 60% 40% 45%; }
}

.orbit {
  position: absolute;
  top: -46px;
  left: -46px;
  width: 260px;
  height: 260px;
  animation: orbit-spin 50s linear infinite;
}

@keyframes orbit-spin {
  to { transform: rotate(360deg); }
}

.orbit-path {
  stroke: var(--accent-b);
  opacity: 0.4;
}

.orbit-link {
  stroke: var(--muted);
  opacity: 0.35;
}

.orbit-node {
  stroke: var(--bg);
  stroke-width: 1.5;
}

.orbit-node.a {
  fill: var(--accent-a);
}

.orbit-node.b {
  fill: var(--accent-b);
}

.avatar {
  position: relative;
  width: 168px;
  height: 168px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  border: 4px solid var(--bg);
  box-shadow: 0 12px 32px -12px rgba(0, 0, 0, 0.35);
}

.hero-text h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: 2.5rem;
  line-height: 1.08;
  margin: 0 0 0.6rem;
  letter-spacing: -0.01em;
}

.hero-text h1 .degree {
  color: var(--muted);
  font-size: 1.5rem;
}

.tagline {
  color: var(--fg);
  font-size: 1.05rem;
  margin: 0;
}

.location {
  color: var(--muted);
  margin: 0.2rem 0 1.1rem;
  font-size: 0.8rem;
  font-family: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  letter-spacing: 0.02em;
}

.navlinks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.6rem;
}

.navlinks a {
  font-family: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  font-size: 0.76rem;
  color: var(--fg);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.3rem 0.75rem;
  text-decoration: none;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.navlinks a:hover {
  border-color: var(--accent-a);
  color: var(--accent-a);
  text-decoration: none;
}

/* ---- Sections ---- */

main {
  flex: 1;
}

section {
  margin-bottom: 3.25rem;
}

section h2 {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 500;
  font-size: 1.4rem;
  margin: 0 0 1.25rem;
}

section h2 .num {
  font-family: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--accent-a);
}

.entry {
  margin-bottom: 1.75rem;
}

.entry:last-child {
  margin-bottom: 0;
}

.entry h3 {
  font-size: 1rem;
  margin: 0 0 0.15rem;
}

.entry .meta {
  color: var(--muted);
  font-size: 0.8rem;
  font-family: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  margin: 0 0 0.5rem;
}

.entry p {
  margin: 0.5rem 0;
}

.links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 0;
}

a {
  color: var(--accent-b);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

footer {
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

/* ---- Responsive ---- */

@media (max-width: 560px) {
  .hero {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }

  .hero-photo {
    width: 128px;
    height: 128px;
  }

  .avatar {
    width: 128px;
    height: 128px;
  }

  .hero-text h1 {
    font-size: 2rem;
  }
}
