@import url("https://fonts.googleapis.com/css2?family=Crimson+Pro:ital,wght@0,400;0,500;0,600;1,500;1,600&family=Ubuntu+Mono&display=swap");

:root {
  --font-sans: "Crimson Pro", Georgia, serif;
  --font-serif: "Crimson Pro", Georgia, serif;
  --font-mono: "Ubuntu Mono", "SFMono-Regular", Consolas, monospace;
  --ink: #111;
  --muted: #555;
  --subtle: #777;
  --line: #dfe4ea;
  --accent: #12355b;
  --accent-hover: #08233f;
  --accent-muted: #35516d;
  --accent-soft: #f3f7fb;
  --accent-line: #ccdceb;
  --hover-bg: #f2f3f5;
  --link: #1769aa;
  --link-hover: #0c3d67;
  color: var(--ink);
  background: #fff;
  font-family: var(--font-sans);
  font-size: 18px;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background: #fff;
}

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

a:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

.site-shell {
  display: grid;
  grid-template-columns: 240px minmax(0, 680px);
  column-gap: 58px;
  width: min(980px, calc(100% - 56px));
  margin: 0 auto;
  padding: 58px 0 42px;
  align-items: start;
}

.profile {
  position: sticky;
  top: 58px;
  display: block;
  grid-column: 1;
  grid-row: 1 / span 2;
  padding-bottom: 0;
  border-bottom: 0;
  text-align: center;
}

.profile img {
  display: block;
  width: 160px;
  height: 160px;
  margin: 0 auto 18px;
  object-fit: cover;
  border: 1px solid #ccc;
  background: #fff;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-family: var(--font-serif);
  font-size: 1.95rem;
  font-weight: 600;
  line-height: 1;
  color: var(--ink);
}

.role {
  margin-top: 8px;
  font-size: 1rem;
  font-weight: 500;
  color: #222;
}

.tagline {
  margin-top: 10px;
  font-size: 0.98rem;
  line-height: 1.46;
  color: var(--muted);
}

.links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 0.92rem;
}

.icon-link {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--accent-line);
  border-radius: 3px;
  gap: 5px;
  padding: 2px 8px 3px;
  background: transparent;
  color: var(--accent);
  text-decoration: none;
}

.icon-link:hover {
  border-color: #b8c7d6;
  background: var(--hover-bg);
  color: var(--accent-hover);
  text-decoration: none;
}

.icon-link svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.anchor-nav {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  padding: 12px 0 10px;
  border-bottom: 1px solid var(--line);
}

.anchor-nav a {
  display: inline-flex;
  align-items: center;
  border: 1px solid transparent;
  border-radius: 3px;
  background: transparent;
  padding: 2px 10px 3px;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
}

.anchor-nav a:hover {
  border-color: transparent;
  background: var(--hover-bg);
  color: var(--accent-hover);
  text-decoration: none;
}

main {
  grid-column: 2;
  min-width: 0;
}

.section {
  scroll-margin-top: 18px;
  padding: 21px 0;
  border-bottom: 1px solid #edf0f3;
}

.section h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 13px;
  font-size: 1.18rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}

.section h2::before {
  display: inline-block;
  width: 4px;
  height: 0.78em;
  background: var(--accent);
  content: "";
}

.section p {
  font-size: 0.94rem;
  line-height: 1.5;
  color: var(--ink);
}

.section p + p {
  margin-top: 8px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.chips span {
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  padding: 2px 7px;
  font-size: 0.8rem;
  color: var(--accent-muted);
}

.simple-list {
  display: grid;
  gap: 5px;
  margin: 5px 0 0;
  padding-left: 19px;
  font-size: 0.94rem;
  line-height: 1.45;
  color: var(--ink);
}

.publication-list,
.timeline {
  display: grid;
  gap: 13px;
}

.publication,
.timeline-row {
  display: grid;
  gap: 14px;
}

.publication {
  grid-template-columns: 132px 1fr;
}

.timeline-row {
  grid-template-columns: 98px 1fr;
}

.pub-year,
.date {
  color: var(--subtle);
  font-size: 0.86rem;
  line-height: 1.35;
}

.date {
  display: flex;
  flex-direction: column;
  gap: 1px;
  white-space: nowrap;
}

.date-end {
  color: #aaa;
  line-height: 1;
}

.pub-year a {
  color: var(--link);
}

h3 {
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--ink);
}

.entry-org {
  font-size: 1rem;
}

.entry-role {
  margin-top: 1px;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.35;
  color: #333;
}

.entry-role + .muted {
  margin-top: 1px;
}

.subsection + .subsection {
  margin-top: 24px;
}

.subsection {
  padding-left: 14px;
  border-left: 2px solid var(--accent-line);
}

.subsection-title {
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.25;
}

.entry-list {
  display: grid;
  gap: 10px;
}

.expandable-entry {
  padding: 0;
}

.entry-role-title {
  display: block;
  color: var(--ink);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.25;
}

.entry-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0 7px;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.entry-meta span:not(:last-child)::after {
  margin-left: 7px;
  color: #aaa;
  content: "·";
}

.entry-impact {
  display: block;
  margin-top: 4px;
  color: #2f3f4b;
  font-size: 0.92rem;
  line-height: 1.35;
}

.expandable-details {
  margin: 0;
}

.expandable-details summary {
  position: relative;
  display: block;
  border: 1px solid transparent;
  border-radius: 4px;
  background: transparent;
  padding: 7px 10px 8px 26px;
  cursor: pointer;
  list-style: none;
  transition:
    background 140ms ease,
    border-color 140ms ease;
}

.expandable-details summary::-webkit-details-marker {
  display: none;
}

.expandable-details summary::before {
  position: absolute;
  top: 0.9em;
  left: 9px;
  width: 0.75em;
  color: var(--accent-muted);
  content: "▸";
  font-size: 0.82rem;
  line-height: 1;
  transition: transform 120ms ease;
}

.expandable-details[open] summary::before {
  transform: rotate(90deg);
}

.expandable-details summary:hover,
.expandable-details[open] summary {
  border-color: transparent;
  background: var(--hover-bg);
}

.expandable-details p {
  margin-top: 7px;
  padding-left: 18px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.42;
}

.expandable-details .simple-list {
  margin-top: 5px;
  padding-left: 32px;
}

.authors,
.muted,
.small {
  color: var(--muted);
}

.authors {
  margin-top: 3px;
  font-size: 0.92rem;
  line-height: 1.38;
}

.pub-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

.pub-links a {
  border: 1px solid var(--accent-line);
  border-radius: 3px;
  padding: 2px 9px 3px;
  background: transparent;
  color: var(--accent);
  font-size: 0.82rem;
  line-height: 1.4;
  text-decoration: none;
}

.pub-links a:hover {
  border-color: #b8c7d6;
  background: var(--hover-bg);
  color: var(--accent-hover);
  text-decoration: none;
}

.author-highlight {
  color: var(--ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.small {
  font-size: 0.9rem;
}

.skill-language {
  margin-bottom: 9px;
}

.skill-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.skill-card {
  border: 1px solid #e2e2e2;
  border-radius: 2px;
  background: #fafafa;
  padding: 9px 10px;
}

.skill-card h3 {
  margin-bottom: 3px;
  font-size: 0.92rem;
}

.skill-card p {
  font-size: 0.88rem;
  line-height: 1.36;
  color: var(--muted);
}

.award-list {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.award-row {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 9px;
  align-items: baseline;
}

.award-date {
  color: var(--subtle);
  font-size: 0.86rem;
  white-space: nowrap;
}

.award-text {
  line-height: 1.35;
}

footer {
  grid-column: 2;
  font-family: var(--font-mono);
  padding-top: 20px;
  color: var(--subtle);
  font-size: 0.9rem;
}

@media (max-width: 860px) {
  .site-shell {
    display: block;
    width: min(100% - 28px, 800px);
    padding-top: 26px;
  }

  .profile {
    position: static;
    display: grid;
    grid-template-columns: 132px 1fr;
    gap: 18px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--line);
    text-align: left;
  }

  .profile img {
    width: 132px;
    height: 132px;
    margin: 0;
  }

  h1 {
    font-size: 2.1rem;
  }

  .links {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  :root {
    font-size: 17px;
  }

  .site-shell {
    padding-top: 26px;
  }

  .profile {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .profile img {
    width: 132px;
    height: 132px;
  }

  .publication,
  .timeline-row {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .award-row {
    grid-template-columns: 1fr;
    gap: 2px;
  }

  .skill-card-grid {
    grid-template-columns: 1fr;
  }
}
