/* ==========================================================================
   Feng Liu — personal site
   Paper-and-ink palette with a single seismic-red accent.
   ========================================================================== */

@font-face { font-family: "Instrument Serif"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/instrument-serif.woff2") format("woff2"); }
@font-face { font-family: "Instrument Serif"; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/instrument-serif-italic.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("../fonts/inter-var.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 500; font-display: swap; src: url("../fonts/jetbrains-mono-var.woff2") format("woff2"); }

:root {
  --bg: #f3f0e8;
  --surface: #fbfaf6;
  --ink: #17181b;
  --ink-2: #3b3d42;
  --muted: #6b6d72;
  --line: #dcd6c9;
  --line-soft: #e8e3d8;
  --accent: #d1431a;
  --accent-soft: rgba(209, 67, 26, .1);
  --cool: #23708a;
  --cool-soft: rgba(35, 112, 138, .1);
  --olive: #7a6a12;
  --olive-soft: rgba(122, 106, 18, .11);
  --trace: #17181b;
  --grid: rgba(23, 24, 27, .07);
  --figure-bg: #ffffff;
  --shadow: 0 1px 0 rgba(0,0,0,.02), 0 12px 32px -18px rgba(40, 30, 10, .25);

  --serif: "Instrument Serif", "Songti SC", "Noto Serif CJK SC", "Source Han Serif SC", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --wrap: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
  --radius: 14px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1012;
    --surface: #17181b;
    --ink: #ece7dc;
    --ink-2: #c9c4b9;
    --muted: #8f9196;
    --line: #2c2e33;
    --line-soft: #222428;
    --accent: #ff6a3d;
    --accent-soft: rgba(255, 106, 61, .12);
    --cool: #5fb4cf;
    --cool-soft: rgba(95, 180, 207, .12);
    --olive: #d4bf5a;
    --olive-soft: rgba(212, 191, 90, .12);
    --trace: #ece7dc;
    --grid: rgba(236, 231, 220, .06);
    --figure-bg: #f4f2ec;
    --shadow: 0 12px 32px -18px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1012;
  --surface: #17181b;
  --ink: #ece7dc;
  --ink-2: #c9c4b9;
  --muted: #8f9196;
  --line: #2c2e33;
  --line-soft: #222428;
  --accent: #ff6a3d;
  --accent-soft: rgba(255, 106, 61, .12);
  --cool: #5fb4cf;
  --cool-soft: rgba(95, 180, 207, .12);
  --olive: #d4bf5a;
  --olive-soft: rgba(212, 191, 90, .12);
  --trace: #ece7dc;
  --grid: rgba(236, 231, 220, .06);
  --figure-bg: #f4f2ec;
  --shadow: 0 12px 32px -18px rgba(0, 0, 0, .7);
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16.5px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent); color: #fff; }
strong { font-weight: 600; }
h1, h2, h3 { margin: 0; font-weight: 400; }
ol, ul { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--bg); padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

.icon { width: 1em; height: 1em; flex: none; }
.label {
  font: 500 11.5px/1 var(--mono);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.topbar.is-scrolled { border-bottom-color: var(--line); }
.topbar__inner { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; letter-spacing: -.01em; }
.brand__mark { width: 26px; height: 26px; color: var(--accent); }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a {
  font: 500 12.5px/1 var(--mono); letter-spacing: .04em;
  text-decoration: none; color: var(--muted);
  padding: 8px 10px; border-radius: 999px;
  transition: color .2s, background-color .2s;
}
.nav a:hover { color: var(--ink); background: var(--line-soft); }
.nav a.is-active { color: var(--ink); background: var(--line-soft); }
.theme-toggle {
  display: grid; place-items: center;
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  cursor: pointer; transition: transform .3s, border-color .2s;
}
.theme-toggle:hover { border-color: var(--ink); transform: rotate(-20deg); }
.theme-toggle svg { width: 17px; height: 17px; }
.i-moon { display: none; }
:root[data-theme="dark"] .i-sun { display: none; }
:root[data-theme="dark"] .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .i-sun { display: none; }
  :root:not([data-theme="light"]) .i-moon { display: block; }
}

/* ---------- hero ---------- */
.hero { padding-top: clamp(40px, 8vw, 96px); }
.hero__grid {
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: clamp(28px, 5vw, 72px); align-items: end;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font: 500 12.5px/1.4 var(--mono); letter-spacing: .06em; color: var(--muted);
  margin-bottom: 22px;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 var(--accent); animation: pulse 2.4s infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); }
  70%, 100% { box-shadow: 0 0 0 10px transparent; }
}
.hero__name {
  font: 400 clamp(56px, 11vw, 132px)/.92 var(--serif);
  letter-spacing: -.025em;
}
.hero__name .zh {
  display: inline-block;
  font-size: .42em; letter-spacing: .04em; vertical-align: .55em;
  color: var(--accent); margin-left: .15em; font-weight: 600;
}
.hero__tagline {
  margin-top: 22px; max-width: 30ch;
  font: italic 400 clamp(22px, 2.6vw, 30px)/1.25 var(--serif);
  color: var(--ink-2);
}
.links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; }
.links a {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px 9px 12px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 14px; font-weight: 500; text-decoration: none;
  transition: border-color .2s, transform .2s, color .2s;
}
.links a:hover { border-color: var(--ink); color: var(--ink); transform: translateY(-2px); }
.links .icon { width: 16px; height: 16px; }

.hero__photo { margin: 0; width: clamp(180px, 22vw, 260px); }
.hero__photo img {
  width: 100%; height: auto; aspect-ratio: 1; object-fit: cover;
  border-radius: 50%;
  outline: 1px solid var(--line); outline-offset: 7px;
  filter: grayscale(.15) contrast(1.02);
}
.hero__photo figcaption {
  display: flex; justify-content: center; gap: 12px;
  margin-top: 20px; font: 400 11px/1.3 var(--mono); color: var(--muted); letter-spacing: .04em;
}

/* the seismogram strip */
.seismo { margin-top: clamp(40px, 6vw, 72px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.seismo__meta {
  display: flex; justify-content: space-between; gap: 16px;
  font: 400 11px/1 var(--mono); letter-spacing: .06em; color: var(--muted);
  padding-top: 12px; padding-bottom: 4px;
  pointer-events: none;
}
.seismo__readout { text-align: right; transition: color .3s; }
.seismo__readout.is-event { color: var(--accent); }
#seismo { display: block; width: 100%; height: clamp(120px, 16vw, 180px); cursor: crosshair; touch-action: pan-y; }

/* ---------- sections ---------- */
.section { padding: clamp(64px, 9vw, 120px) 0 0; }
.section__grid { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 32px; }
.section__head { position: sticky; top: 84px; align-self: start; }
.section__num { display: block; font: 500 12px/1 var(--mono); color: var(--accent); letter-spacing: .1em; margin-bottom: 10px; }
.section__head h2 { font: 400 clamp(34px, 4vw, 46px)/1 var(--serif); letter-spacing: -.015em; }

/* about */
.about { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); }
.prose p { font-size: 18px; line-height: 1.7; color: var(--ink-2); }
.prose p + p { margin-top: 1em; }
.prose p:first-child { font-size: 21px; line-height: 1.55; color: var(--ink); }
.prose strong { color: var(--ink); }
.prose a { color: var(--ink); text-decoration-color: var(--accent); text-decoration-thickness: 1.5px; }
.prose a:hover { color: var(--accent); }

.news { border-left: 1px solid var(--line); padding-left: 24px; }
.news ol { margin-top: 18px; display: grid; gap: 20px; }
.news li { position: relative; }
.news li::before {
  content: ""; position: absolute; left: -29px; top: 7px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--accent);
}
.news li:first-child::before { background: var(--accent); }
.news time { display: block; font: 500 12px/1 var(--mono); color: var(--accent); margin-bottom: 6px; }
.news p { font-size: 15px; line-height: 1.55; color: var(--ink-2); }
.news a { color: var(--ink); font-weight: 500; }

/* research */
.interests { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; counter-reset: i; }
.interest {
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 22px 26px;
  transition: border-color .25s, transform .25s, box-shadow .25s;
}
.interest:hover { border-color: color-mix(in srgb, var(--ink) 40%, var(--line)); transform: translateY(-3px); box-shadow: var(--shadow); }
.interest__code { font: 500 11.5px/1 var(--mono); letter-spacing: .14em; color: var(--accent); }
.interest__trace { display: block; width: 100%; height: 56px; margin: 18px 0 18px; }
.interest h3 { font: 400 27px/1.1 var(--serif); letter-spacing: -.01em; }
.interest p { margin-top: 10px; font-size: 15px; line-height: 1.55; color: var(--muted); }

/* publications */
/* featured carousel: one horizontal card per slide */
.carousel { min-width: 0; }
.carousel__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; margin-bottom: 14px; }
.carousel__tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.carousel__tab {
  font: 500 12.5px/1 var(--mono); letter-spacing: .03em;
  padding: 9px 14px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line); background: transparent; color: var(--muted);
  transition: color .2s, border-color .2s, background-color .2s;
}
.carousel__tab:hover { color: var(--ink); border-color: var(--ink); }
.carousel__tab.is-active { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.carousel__nav { display: flex; align-items: center; gap: 8px; }
.carousel__count { font: 400 12.5px/1 var(--mono); color: var(--muted); margin-right: 6px; font-variant-numeric: tabular-nums; }
.carousel__count b { color: var(--ink); font-weight: 500; }
.carousel__btn {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer;
  transition: border-color .2s, transform .2s;
}
.carousel__btn:hover { border-color: var(--ink); }
.carousel__btn:active { transform: scale(.94); }
.carousel__btn svg { width: 18px; height: 18px; }
.carousel__track {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  overscroll-behavior-x: contain; scrollbar-width: none;
  border-radius: var(--radius);
}
.carousel__track::-webkit-scrollbar { display: none; }
.carousel__track:focus-visible { outline-offset: 4px; }
.paper {
  flex: 0 0 100%; scroll-snap-align: start; scroll-snap-stop: always;
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden;
}
.paper + .paper { margin-left: 16px; }
.paper__cover {
  position: relative; display: block; aspect-ratio: 2 / 1; overflow: hidden;
  background: var(--figure-bg);
  border-bottom: 1px solid var(--line);
}
.paper__cover img { position: absolute; inset: 14px; width: calc(100% - 28px); height: calc(100% - 28px); object-fit: contain; transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.paper:hover .paper__cover img { transform: scale(1.025); }
.paper__badge {
  position: absolute; left: 12px; bottom: 12px; z-index: 1;
  padding: 6px 11px; border-radius: 999px;
  background: var(--accent); color: #fff;
  font: 500 11.5px/1 var(--mono); letter-spacing: .04em;
  box-shadow: 0 4px 14px -6px color-mix(in srgb, var(--accent) 70%, transparent);
}
.paper__body { flex: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; padding: 26px 30px 28px; }
.paper__main { display: flex; flex-direction: column; }
.paper .highlights { padding-left: 28px; border-left: 1px solid var(--line-soft); }
.paper__meta { display: flex; align-items: center; gap: 10px; font: 500 12px/1 var(--mono); color: var(--muted); }
.badge {
  display: inline-block; padding: 5px 8px; border-radius: 6px;
  background: var(--accent-soft); color: var(--accent);
  font: 500 11.5px/1 var(--mono); letter-spacing: .04em;
}
.paper h3 { margin-top: 14px; font: 400 28px/1.12 var(--serif); letter-spacing: -.01em; }
.paper h3 a { text-decoration: none; }
.authors { margin-top: 8px; font-size: 14px; color: var(--muted); }
.authors strong { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: .2em; }
.highlights { display: grid; gap: 7px; align-content: start; }
.highlights li { position: relative; padding-left: 18px; font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.highlights li::before { content: ""; position: absolute; left: 0; top: .68em; width: 8px; height: 1.5px; background: var(--accent); }
.highlights strong { color: var(--ink); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 22px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 13px; border-radius: 8px;
  border: 1px solid var(--line); background: var(--bg);
  font-size: 13.5px; font-weight: 500; text-decoration: none;
  transition: border-color .2s, background-color .2s, color .2s;
}
.btn:hover { border-color: var(--ink); color: var(--ink); }
.btn .icon { width: 15px; height: 15px; }
.stars:empty { display: none; }
.stars {
  display: inline-flex; align-items: center; gap: 4px;
  font: 500 12px/1 var(--mono); color: var(--muted);
  padding-left: 8px; margin-left: 2px; border-left: 1px solid var(--line);
}
.stars .icon { width: 12px; height: 12px; color: #e3a008; }

.publist { margin-top: 56px; }
.publist__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.publist__stats { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin-top: 10px; font-size: 13.5px; color: var(--muted); }
.publist__stats a { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; color: var(--ink); text-decoration: none; }
.publist__stats a:hover { color: var(--accent); }
.publist__stats b { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.publist__updated { font: 400 11.5px/1 var(--mono); }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  font: 500 12px/1 var(--mono); letter-spacing: .04em;
  padding: 7px 12px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line); background: transparent; color: var(--muted);
  transition: all .2s;
}
.chip:hover { color: var(--ink); border-color: var(--ink); }
.chip.is-active { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pub {
  display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 18px;
  padding: 20px 0; border-bottom: 1px solid var(--line-soft);
  transition: opacity .3s;
}
.pub[hidden], .pubs.is-collapsed .pub.is-overflow { display: none; }
.pub__year { font: 500 13px/1.6 var(--mono); color: var(--muted); }
.pub.is-same-year .pub__year { visibility: hidden; }
.pub__cites { display: grid; justify-items: end; align-content: start; font: 400 10.5px/1.2 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.pub__cites b { font: 400 24px/1 var(--serif); letter-spacing: 0; color: var(--ink); }
.pubs__more {
  display: block; width: 100%; margin-top: 4px; padding: 14px;
  font: 500 12.5px/1 var(--mono); letter-spacing: .04em; color: var(--muted);
  background: transparent; border: 0; border-bottom: 1px solid var(--line-soft); cursor: pointer;
  transition: color .2s, background-color .2s;
}
.pubs__more:hover { color: var(--ink); background: var(--line-soft); }
.pubs__more[hidden] { display: none; }
.pub__title { font-weight: 550; font-size: 16.5px; line-height: 1.4; text-decoration: none; }
.pub__title:hover { text-decoration: underline; }
.pub .authors { margin-top: 5px; }
.pub__venue { margin-top: 4px; font-size: 14px; color: var(--muted); }
.pub__venue em { font-style: italic; color: var(--ink-2); }
.tag {
  display: inline-block; align-self: start;
  font: 500 10.5px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 8px; border-radius: 6px;
  background: var(--line-soft); color: var(--muted);
}
.tag--inversion { background: var(--accent-soft); color: var(--accent); }
.tag--monitoring { background: var(--cool-soft); color: var(--cool); }
.tag--ai { background: var(--olive-soft); color: var(--olive); }
.pub__venue .tag { margin-right: 4px; vertical-align: 1px; }

/* open source */
.repos__stats { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin-bottom: 18px; font-size: 13.5px; color: var(--muted); }
.repos__stats a { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; color: var(--ink); text-decoration: none; }
.repos__stats a:hover { color: var(--accent); }
.repos__stats b { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.repos__total[hidden] { display: none; }
.repos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.repo {
  position: relative;
  display: flex; flex-direction: column; gap: 12px;
  padding: 22px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line);
  transition: border-color .25s, transform .25s, box-shadow .25s;
}
.repo:hover { border-color: color-mix(in srgb, var(--ink) 40%, var(--line)); transform: translateY(-3px); box-shadow: var(--shadow); }
.repo__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.repo__kind { font: 500 11px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.repo__top .stars { border-left: 0; padding-left: 0; }
.repo__name { display: flex; align-items: center; gap: 8px; font: 400 34px/1 var(--serif); letter-spacing: -.01em; margin-top: 4px; }
.repo__name a { text-decoration: none; }
.repo__name a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }  /* whole card links to the repo */
.repo__name .icon { width: 18px; height: 18px; color: var(--muted); transition: transform .25s, color .25s; }
.repo:hover .repo__name .icon { transform: translate(2px, -2px); color: var(--accent); }
.repo:hover .repo__name a { color: inherit; }
.repo__text { font-size: 15px; line-height: 1.55; color: var(--muted); }
.repo__links { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 4px; }
.repo__links .btn { position: relative; z-index: 1; padding: 6px 10px; font-size: 13px; }
.repo__links .btn .icon { width: 14px; height: 14px; }
.repo__foot { display: flex; flex-wrap: wrap; gap: 4px 14px; padding-top: 12px; border-top: 1px solid var(--line-soft); font: 400 11.5px/1.3 var(--mono); color: var(--muted); }

/* timeline */
.timeline { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: clamp(28px, 4vw, 56px); }
.edu { margin-top: 20px; position: relative; }
.edu::before { content: ""; position: absolute; left: 4px; top: 8px; bottom: 8px; width: 1px; background: var(--line); }
.edu li { position: relative; padding: 0 0 26px 28px; display: grid; gap: 3px; }
.edu li::before {
  content: ""; position: absolute; left: 0; top: 6px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--ink);
}
.edu li:first-child::before { background: var(--accent); border-color: var(--accent); }
.edu time { font: 500 12px/1.4 var(--mono); color: var(--muted); }
.edu strong { font: 400 23px/1.2 var(--serif); }
.edu span { font-size: 14.5px; color: var(--muted); }

.honors { margin-top: 12px; }
.honors li {
  display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 14px;
  padding: 13px 0; border-bottom: 1px solid var(--line-soft);
}
.honors time { font: 500 12px/1.7 var(--mono); color: var(--muted); }
.honors strong { display: block; font-weight: 550; font-size: 15px; line-height: 1.4; }
.honors em { display: block; font-style: normal; font-size: 13.5px; color: var(--muted); margin-top: 2px; }

/* footer */
.footer { margin-top: clamp(80px, 10vw, 140px); border-top: 1px solid var(--line); }
.footer__inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 24px; padding-bottom: 32px; font: 400 12px/1.4 var(--mono); color: var(--muted); }
.footer a { text-decoration: none; }

/* scroll reveal (only when JS is available) */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .section__grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .section__head { position: static; display: flex; align-items: baseline; gap: 14px; }
  .section__num { margin: 0; }
  .about, .timeline { grid-template-columns: 1fr; }
  .interests { grid-template-columns: 1fr; }
  .interest { display: grid; grid-template-columns: minmax(0, 1fr) 140px; column-gap: 20px; }
  .interest__code { grid-column: 1; }
  .interest__trace { grid-column: 2; grid-row: 1 / span 3; margin: 0; height: 100%; min-height: 70px; }
  .interest h3, .interest p { grid-column: 1; }
  .interest h3 { margin-top: 12px; }
  .paper__cover { aspect-ratio: 16 / 9; }
  .paper__body { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .paper .highlights { padding-left: 0; border-left: 0; }
  .paper h3 { font-size: 24px; }
}
@media (max-width: 720px) {
  .nav { display: none; }
  .theme-toggle { margin-left: auto; }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__photo { grid-row: 1; width: 132px; }
  .hero__photo figcaption { display: none; }
  .links span { display: none; }
  .links a { padding: 11px; }
  .links .icon { width: 18px; height: 18px; }
  .seismo__meta span:first-child { display: none; }
  .seismo__readout { text-align: left; }
  .repos { grid-template-columns: 1fr; }
  .interest { grid-template-columns: 1fr; }
  .interest__trace { grid-column: 1; grid-row: auto; height: 48px; margin: 14px 0; }
  .pub { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; }
  .pub__year { grid-column: 1 / -1; }
  .pub.is-same-year .pub__year { display: none; }
  .paper__body { padding: 22px 20px; }
  .prose p:first-child { font-size: 19px; }
  .prose p { font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
