/* =========================================================
   site.css — Wenjun Chen's academic homepage
   Replaces Foundation + inline styles. Visual-identical to
   the pre-refactor single-page index.html.
   ========================================================= */

/* ── Minimal reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: #333;
  background: #fff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: inline-block; vertical-align: middle; }
article, aside, footer, header, nav, section, figure, main { display: block; }
.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;
}

/* ── Theme variables ───────────────────────────────────── */
:root {
  --accent:       #0891b2;
  --accent-dark:  #0e7490;
  --accent-light: #67e8f9;
  --accent-pale:  #ecfeff;
}

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

/* ── Navigation ────────────────────────────────────────── */
#nav-bar {
  background: #fff; border-bottom: 2px solid #e8e8e8;
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  display: flex; align-items: stretch;
}
/* Body padding always matches the rendered nav-bar height (set by
   syncNavBarHeight in main.js). When the mobile menu opens and
   nav-bar grows, body padding grows in lockstep so the banner +
   page content push DOWN instead of being covered. */
body {
  padding-top: var(--nav-bar-h, 52px);
  transition: padding-top .2s;
}
#nav-bar ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; align-items: stretch; flex: 1;
}
#nav-bar li a {
  display: block; padding: 15px 16px; color: #444;
  font-size: 13px; font-weight: 600; letter-spacing: .3px;
  white-space: nowrap;
  transition: background .18s, color .18s;
}
#nav-bar li a:hover { background: #f0f0f0; color: #222; }
#nav-bar li.active a { background: var(--accent); color: #fff; }
#nav-bar li.active a:hover { background: var(--accent-dark); }

#nav-hamburger {
  display: none; background: none; border: 0;
  padding: 0 16px; font-size: 22px; cursor: pointer;
  color: #444; flex-shrink: 0;
}
body.dark #nav-hamburger { color: #ccc; }

/* ─── Mobile (≤640px) ─────────────────────────────────── */
@media (max-width: 640px) {
  /* CRITICAL: switch outer nav-bar from flex to block on mobile.
     The previous flex+flex-wrap approach interacted unpredictably
     with the base `#nav-bar ul { flex:1 }` rule on #nav-links,
     pushing the hamburger and color dots to the center of the
     screen and producing huge empty areas. Block layout makes
     nav-top + nav-links stack predictably. */
  #nav-bar {
    display: block;
    align-items: initial;
    flex-wrap: initial;
  }

  /* Top row — flex within nav-top, NOT within nav-bar */
  .nav-top {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    width: 100%;
    height: 50px;
    padding: 0;
    box-sizing: border-box;
  }
  #dark-toggle-mobile {
    width: 50px; height: 50px;
    display: flex !important;
    align-items: center;
    justify-content: center;
    background: none; border: 0;
    cursor: pointer;
    font-size: 20px; line-height: 1;
    padding: 0;
    flex-shrink: 0;
    color: #444;
  }
  body.dark #dark-toggle-mobile { color: #ccc; }

  #color-picker-mobile {
    position: relative;
    display: flex !important;
    align-items: center;
    padding: 0 12px;
    flex-shrink: 0;
    border-left: 1px solid #e8e8e8;
    height: 50px;
  }
  body.dark #color-picker-mobile { border-left-color: #333; }
  /* The compact toggle: a single accent-colored circle. Tap to
     open the popover with all 5 dots. */
  #color-picker-mobile .cpm-toggle {
    width: 22px; height: 22px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid #fff;
    box-shadow: 0 0 0 1.5px #bbb;
    padding: 0; cursor: pointer;
    transition: box-shadow .15s, transform .15s;
  }
  #color-picker-mobile .cpm-toggle:hover,
  #color-picker-mobile.expanded .cpm-toggle {
    box-shadow: 0 0 0 1.5px var(--accent);
    transform: scale(1.06);
  }
  body.dark #color-picker-mobile .cpm-toggle { box-shadow: 0 0 0 1.5px #555; border-color: #1a1a1a; }
  body.dark #color-picker-mobile.expanded .cpm-toggle { box-shadow: 0 0 0 1.5px var(--accent-light); }
  /* The popover — appears below the toggle when .expanded */
  #color-picker-mobile .cpm-pop {
    display: none;
    position: absolute;
    top: 50px; left: 0;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-top: 0;
    border-radius: 0 0 8px 8px;
    padding: 12px;
    gap: 14px;
    z-index: 1100;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12);
  }
  #color-picker-mobile.expanded .cpm-pop {
    display: flex; flex-direction: row;
    align-items: center;
  }
  #color-picker-mobile .cpm-pop .color-dot {
    flex-shrink: 0;
    width: 24px; height: 24px;   /* larger tap targets inside popover */
    display: block; margin: 0;
  }
  body.dark #color-picker-mobile .cpm-pop {
    background: #1a1a1a; border-color: #333;
  }

  #nav-hamburger {
    display: flex !important;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    min-width: 54px;
    height: 50px;
    font-size: 28px; line-height: 1;
    padding: 0;
    flex-shrink: 0;
  }

  /* Dropdown menu — block child of nav-bar, full width, hidden
     until .open. CRITICAL: `display: none !important` is required
     because the base rule `#nav-bar ul { display: flex }` has
     higher specificity (id+type) than our `#nav-links` (id only)
     and would otherwise WIN — leaving the nav links visible as a
     horizontal row on mobile even before the user taps ☰. The
     hamburger-open path already used !important and worked; the
     closed path needed it too. */
  #nav-links {
    display: none !important;
    /* override base #nav-bar ul { flex: 1 } so flex sizing
       doesn't try to grow/shrink this dropdown weirdly */
    flex: initial !important;
    width: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
    background: #fff;
    border-top: 1px solid #e8e8e8;
    max-height: 70vh;
    overflow-y: auto;
  }
  #nav-links.open { display: block !important; }
  #nav-links li {
    display: block;
    width: 100%;
    margin: 0;
  }
  #nav-links li a {
    display: block;
    padding: 14px 20px;
    border-bottom: 1px solid #f0f0f0;
    /* Long labels wrap instead of overflowing horizontally. */
    white-space: normal;
    word-break: break-word;
    line-height: 1.35;
  }
  body.dark #nav-links { background: #111; border-top-color: #333; }
  body.dark #nav-links li a { border-bottom-color: #222; }
}

/* ─── Desktop (≥641px) ────────────────────────────────── */
@media (min-width: 641px) {
  .nav-top { display: none !important; }
  #nav-links { display: flex !important; flex: 1; flex-direction: row; }
  #nav-bar { display: flex; align-items: stretch; }
}

/* ── Banner ────────────────────────────────────────────── */
#banner {
  position: relative; width: 100%;
  height: clamp(160px, 20vw, 260px);
  overflow: hidden; background: #0a0a1a;
}
#banner .banner-bg {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 52%; display: block;
  filter: brightness(1.2);
  /* Inline `object-position` from main.js bannerHtml() overrides the
     52% default per page (editor's "Vertical position" slider). */
}
#banner .banner-overlay {
  position: absolute; inset: 0;
  background: rgba(255,255,255,0.35);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  z-index: 1;
}
#banner .float-name {
  position: absolute; top: 80%; left: 50%;
  transform: translate(-50%, -50%);
  width: 90%; height: 90%; object-fit: contain;
  object-position: center center;
  mix-blend-mode: screen; pointer-events: none;
  z-index: 2;
}
@media (max-width: 480px) {
  #banner .float-name { width: 110%; height: 110%; top: 50%; }
}

/* Slim banner variant for inner pages */
#banner.slim { height: clamp(120px, 14vw, 180px); }
#banner.slim .float-name { width: 80%; height: 80%; top: 50%; }

/* ── Shared section primitives ─────────────────────────── */
.section-inner { max-width: 1020px; margin: 0 auto; padding: 0 28px; }
.section-title {
  font-size: 22px; font-weight: 700; color: #222;
  padding-bottom: 10px; margin: 0.83em 0 32px;
  border-bottom: 3px solid var(--accent); display: inline-block;
}

/* Section backgrounds — unified white site-wide (band-tint kept as
   an alias so old class names still render correctly + so re-enabling
   alternating bands later is a one-line change). */
.section.band-white  { background: #fff; }
.section.band-tint   { background: #fff; }
.section { padding: 48px 0 56px; }
.section.first { padding-top: 56px; padding-bottom: 48px; }

/* ── About ─────────────────────────────────────────────── */
#about { padding: 56px 0 48px; }
.about-grid { display: grid; grid-template-columns: 300px 1fr; gap: 52px; align-items: start; }
.about-photo img { width: 100%; border-radius: 4px; box-shadow: 0 4px 18px rgba(0,0,0,0.13); cursor: default; }
.about-photo figcaption { text-align: center; font-size: 13px; color: #999; margin-top: 8px; }
.about-bio h2 { font-size: 27px; font-weight: 700; color: #111; margin: 0 0 4px; }
.about-bio .subtitle { font-size: 14px; color: var(--accent); font-weight: 600; margin-bottom: 18px; }
.about-bio p { font-size: 15px; line-height: 1.78; color: #444; margin-bottom: 13px; }
.about-bio strong { color: #222; }
.about-links { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 9px; }
.about-links a, .about-links button {
  padding: 8px 17px; border-radius: 3px;
  font-size: 13px; font-weight: 600; font-family: inherit;
  transition: all .18s; cursor: pointer;
}
.btn-primary { background: var(--accent); color: #fff !important; border: 1.5px solid var(--accent); }
.btn-primary:hover { background: var(--accent-dark) !important; border-color: var(--accent-dark); }
.btn-outline { border: 1.5px solid var(--accent); color: var(--accent) !important; background: transparent; }
.btn-outline:hover { background: var(--accent); color: #fff !important; }
/* Email copy-to-clipboard feedback */
.email-copy-btn { transition: all .15s; }
.email-copy-btn.email-copy-flash { background: var(--accent) !important; color: #fff !important; border-color: var(--accent) !important; }

/* ── Publications search + filter (Jiang-Lab parity) ────
   Layered look: page is white (band-white), search input and
   filter-bar use a subtle inset grey (#f5f7fa) — the same panel
   color Jiang uses — so the filter UI reads as a quiet panel
   inside the page rather than a high-contrast white card.
   Multi-select chip filters for Category + Year, full-text search
   input, shown/total summary + clear-filters button. */
.pub-search-bar { margin: 16px 0 14px; }
#pub-search {
  width: 100%; padding: 12px 16px; font-size: 15px;
  font-family: inherit; background: #f5f7fa;
  border: 1px solid #ccc; border-radius: 8px; color: #1a1a1a;
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
#pub-search:focus {
  outline: none; border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-pale);
}
#pub-search::placeholder { color: #888; }
body.dark #pub-search { background: #1f1f1f; border-color: #444; color: #eee; }
body.dark #pub-search:focus { border-color: var(--accent-light); box-shadow: 0 0 0 3px rgba(255,255,255,0.05); }

.pub-filter-bar {
  margin: 24px 0 28px;
  padding: 18px 20px;
  border: 1px solid #e8e8e8; border-radius: 8px;
  background: #f5f7fa;
}
body.dark .pub-filter-bar { background: #1f1f1f; border-color: #333; }

.filter-group {
  display: flex; align-items: baseline; gap: 12px;
  margin-bottom: 12px; flex-wrap: wrap;
}
.filter-group:last-of-type { margin-bottom: 14px; }
.filter-group-label {
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.2px;
  color: #888; min-width: 60px; flex-shrink: 0;
}
.filter-chips { display: flex; flex-wrap: wrap; gap: 6px; flex: 1; }
.filter-chips.year-chips { max-height: 80px; overflow-y: auto; }

.filter-chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: 14px;
  border: 1.5px solid var(--line, #ccc); background: #fff;
  font-family: inherit; font-size: 12px; font-weight: 600;
  color: #444; cursor: pointer; transition: all .12s;
  white-space: nowrap;
}
.filter-chip:hover { border-color: var(--accent); color: var(--accent); }
.filter-chip-count {
  display: inline-block; background: #f0f0f0; color: #888;
  padding: 0 7px; border-radius: 9px;
  font-size: 10px; font-weight: 700;
  min-width: 18px; text-align: center;
}
.filter-chip-x { font-size: 11px; line-height: 1; opacity: .85; }

/* Active state: filled with category color (or accent for year) */
.filter-chip.active { color: #fff; border-color: transparent; }
.filter-chip.active .filter-chip-count {
  background: rgba(255,255,255,0.25); color: #fff;
}
.filter-chip.year-chip.active { background: var(--accent); }
/* Category-specific active fills — match the badge colors on each pub */
.filter-chip.cat-journal.active    { background: var(--accent-dark); }
.filter-chip.cat-preprint.active   { background: #b35a00; }
.filter-chip.cat-chinese.active    { background: #b52a2a; }
.filter-chip.cat-conference.active { background: #5a2ab5; }
.filter-chip.cat-other.active      { background: #666; }

body.dark .filter-chip { background: #2a2a2a; border-color: #444; color: #ccc; }
body.dark .filter-chip:hover { border-color: var(--accent-light); color: var(--accent-light); }
body.dark .filter-chip-count { background: #1a1a1a; color: #777; }

.filter-summary {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 12px; border-top: 1px solid #ddd; font-size: 13px;
}
body.dark .filter-summary { border-top-color: #333; }
.filter-summary-text { color: #888; }
.filter-summary-text #pub-shown-count {
  color: var(--accent); font-weight: 700; font-size: 16px;
}
body.dark .filter-summary-text #pub-shown-count { color: var(--accent-light); }
.filter-clear {
  background: none; border: 1px solid #ccc; border-radius: 14px;
  padding: 4px 12px; cursor: pointer;
  color: #888; font-size: 12px; font-weight: 600;
  display: inline-flex; align-items: center; gap: 4px;
  transition: all .12s; font-family: inherit;
}
.filter-clear:hover { color: var(--accent); border-color: var(--accent); }
body.dark .filter-clear { border-color: #444; color: #888; }
body.dark .filter-clear:hover { color: var(--accent-light); border-color: var(--accent-light); }

@media (max-width: 640px) {
  .pub-filter-bar { padding: 14px 14px; }
  .filter-group { flex-direction: column; align-items: stretch; gap: 6px; }
  .filter-chips.year-chips { max-height: 120px; }
}

/* Back-to-top */
#back-to-top {
  position: fixed; bottom: 24px; right: 24px; z-index: 900;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--accent); color: #fff !important; border: 0;
  font-size: 22px; font-weight: 700; line-height: 44px; text-align: center;
  cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,0.18);
  opacity: 0; transform: translateY(20px) scale(0.85); pointer-events: none;
  transition: opacity .25s, transform .25s, background .15s;
}
#back-to-top.visible { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
#back-to-top:hover { background: var(--accent-dark); }
@media (max-width: 640px) {
  #back-to-top { bottom: 16px; right: 16px; width: 40px; height: 40px; line-height: 40px; font-size: 19px; }
}
.pub-filter-btn {
  padding: 6px 16px; border-radius: 20px; font-size: 12px; font-weight: 600;
  cursor: pointer; border: 1.5px solid #ccc; background: #fff; color: #666; transition: all .18s;
}
.pub-filter-btn:hover, .pub-filter-btn.active { border-color: var(--accent); background: var(--accent); color: #fff; }
.pub-filter-btn .count {
  display: inline-block; background: rgba(255,255,255,0.3);
  border-radius: 10px; padding: 0 6px; font-size: 10px; margin-left: 4px;
}
.pub-filter-btn:not(.active) .count { background: #eee; color: #999; }

.pub-item {
  background: #fff; border-radius: 6px; padding: 18px 22px 14px; margin-bottom: 14px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07); border-left: 4px solid var(--accent);
  transition: box-shadow .2s, transform .15s;
}
.pub-item:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.11); transform: translateY(-1px); }
.pub-header { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.pub-year {
  font-size: 11px; font-weight: 700; color: #fff;
  background: var(--accent); padding: 2px 8px; border-radius: 10px; white-space: nowrap;
}
.pub-year.inpress { background: #aaa; }
.pub-cat {
  font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 10px; white-space: nowrap;
}
.cat-journal    { background: #e3f0ff; color: var(--accent-dark); }
.cat-preprint   { background: #fff3e0; color: #b35a00; }
.cat-chinese    { background: #fde8e8; color: #b52a2a; }
.cat-conference { background: #ede8ff; color: #5a2ab5; }
.cat-other      { background: #eee;    color: #666; }
.pub-note {
  font-size: 10px; font-weight: 700; padding: 2px 8px;
  border-radius: 10px; background: var(--accent-pale); color: var(--accent-dark);
  white-space: nowrap;
}

.pub-title { font-size: 15px; font-weight: 700; color: #1a1a1a; line-height: 1.45; margin-bottom: 4px; }
.pub-title a { color: #1a1a1a; }
.pub-title a:hover { color: var(--accent); }
.pub-authors { font-size: 13px; color: #888; margin-bottom: 3px; }
.pub-authors .me { font-weight: 700; color: #555; }
.pub-journal { font-size: 13px; color: #777; font-style: italic; margin-bottom: 10px; }
.pub-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.pub-actions a {
  font-size: 11px; font-weight: 700; padding: 4px 12px; border-radius: 3px;
  letter-spacing: .3px; transition: all .15s; text-transform: uppercase;
}
.btn-view { border: 1.5px solid var(--accent); color: var(--accent); }
.btn-view:hover { background: var(--accent); color: #fff !important; }
.btn-pdf  { border: 1.5px solid #e05a2b; color: #e05a2b; }
.btn-pdf:hover  { background: #e05a2b; color: #fff !important; }
.btn-code { border: 1.5px solid #444; color: #444; }
.btn-code:hover { background: #444; color: #fff !important; }
.btn-video { border: 1.5px solid var(--accent-dark); color: var(--accent-dark); }
.btn-video:hover { background: var(--accent-dark); color: #fff !important; }

/* ── Peer Review ───────────────────────────────────────── */
.pr-summary {
  display: inline-flex; align-items: baseline; gap: 10px;
  background: #f6f6f4; border-radius: 8px; padding: 18px 28px;
  margin-bottom: 28px;
}
.pr-total-num { font-size: 42px; font-weight: 700; color: var(--accent); line-height: 1; }
.pr-total-label { font-size: 14px; color: #888; }
.pr-table { width: 100%; border-collapse: collapse; }
.pr-table th {
  text-align: left; font-size: 11px; font-weight: 700; color: #999;
  letter-spacing: 1px; text-transform: uppercase;
  padding: 0 12px 10px; border-bottom: 2px solid #eee;
}
.pr-table th:last-child { text-align: center; }
.pr-table td { padding: 12px; border-bottom: 1px solid #f0f0f0; font-size: 14px; color: #444; }
.pr-table td:last-child { text-align: center; }
.pr-count {
  display: inline-block; background: var(--accent); color: #fff;
  font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 10px;
}

/* ── Tools (cards grid) ────────────────────────────────── */
.tools-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap: 20px; }
.tool-card {
  border: 1.5px solid #e0e0e0; border-radius: 8px; padding: 24px;
  transition: border-color .2s, box-shadow .2s; background: #fff;
}
.tool-card:hover { border-color: var(--accent); box-shadow: 0 4px 14px rgba(0,0,0,0.08); }
.tool-card h3 { font-size: 16px; font-weight: 700; color: #222; margin: 0 0 8px; }
.tool-card p { font-size: 14px; color: #666; line-height: 1.6; margin: 0 0 16px; }
.tool-card a {
  display: inline-block; padding: 7px 16px; background: var(--accent);
  color: #fff !important; border-radius: 3px; font-size: 12px; font-weight: 700; transition: background .18s;
}
.tool-card a:hover { background: var(--accent-dark); }

.tool-group-header { display: flex; align-items: center; gap: 16px; margin-bottom: 8px; }
.tool-group-header img.tool-group-logo { height: 56px; width: auto; }
.tool-group-header h2.section-title { margin: 0; }
.tool-group-tagline { font-size: 15px; color: #555; line-height: 1.7; margin-bottom: 28px; }

/* ── Logo marquee (configurable horizontal scroller) ─── */
.logo-marquee {
  background: #fff; border-top: 1px solid #eee; border-bottom: 1px solid #eee;
  padding: 18px 0; overflow: hidden;
}
.logo-marquee-title {
  text-align: center; font-size: 12px; color: #888;
  text-transform: uppercase; letter-spacing: 1.5px;
  margin: 0 0 12px;
}
.logo-marquee-viewport { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 60px, #000 calc(100% - 60px), transparent); }
.logo-marquee-track {
  display: flex; gap: 56px; width: max-content;
  animation: logo-marquee-scroll var(--marquee-speed, 40s) linear infinite;
}
.logo-marquee-viewport:hover .logo-marquee-track { animation-play-state: paused; }
.logo-marquee-item {
  display: inline-flex; align-items: center; justify-content: center;
  height: 56px; opacity: .75; transition: opacity .2s;
}
.logo-marquee-item:hover { opacity: 1; }
.logo-marquee-item img { max-height: 56px; max-width: 200px; width: auto; height: auto; }
.logo-marquee-item .logo-text {
  font-size: 14px; color: #555; font-weight: 600;
  padding: 0 12px; border: 1px solid #ddd; border-radius: 4px; line-height: 36px;
}
@keyframes logo-marquee-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
body.dark .logo-marquee { background: #1a1a1a; border-color: #333; }
body.dark .logo-marquee-title { color: #666; }
body.dark .logo-marquee-item .logo-text { color: #aaa; border-color: #444; }
@media (prefers-reduced-motion: reduce) {
  .logo-marquee-track { animation: none; }
  .logo-marquee-viewport { mask-image: none; overflow-x: auto; }
}

/* ── Funders strip ─────────────────────────────────────── */
#funders { background: #fff; border-top: 1px solid #eee; padding: 32px 0; }
#funders .inner { max-width: 1020px; margin: 0 auto; padding: 0 28px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
#funders p { font-size: 13px; color: #999; margin: 0; }
#funders img { height: 80px; opacity: .85; transition: opacity .2s; }
#funders img:hover { opacity: 1; }

/* ── Footer ────────────────────────────────────────────── */
#footer { background: #2c2c2c; color: #bbb; }
#footer-widgets {
  max-width: 1020px; margin: 0 auto; padding: 38px 28px 18px;
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 40px;
}
#footer h5 {
  color: #fff; text-transform: uppercase; font-size: 11px;
  letter-spacing: 1.8px; margin: 0 0 14px; padding-bottom: 8px; border-bottom: 1px solid #444;
}
#footer p { font-size: 13px; line-height: 1.7; margin: 0 0 8px; }
#footer ul { list-style: none; padding: 0; margin: 0; }
#footer ul li { margin-bottom: 7px; font-size: 13px; }
#footer a { color: var(--accent); }
#footer a:hover { color: var(--accent-light); }
#footer-bottom { border-top: 1px solid #3a3a3a; text-align: center; padding: 15px 28px; font-size: 12px; color: #666; }

@media (max-width: 720px) {
  .about-grid { grid-template-columns: 1fr; gap: 28px; }
  .about-photo { max-width: 240px; margin: 0 auto; }
  #footer-widgets { grid-template-columns: 1fr; gap: 24px; }
}

/* ── Toggle button ─────────────────────────────────────── */
#dark-toggle {
  flex-shrink: 0; padding: 0 16px;
  display: flex; align-items: center;
  cursor: pointer; font-size: 18px;
  background: none; border: none;
  border-left: 1px solid #e8e8e8;
  transition: opacity .2s;
}
#dark-toggle:hover { opacity: .7; }
body.dark #dark-toggle { border-left-color: #333; }
@media (max-width: 640px) { #dark-toggle { display: none; } }

/* ── Color picker ──────────────────────────────────────── */
#color-picker {
  flex-shrink: 0; display: flex; align-items: center; gap: 6px;
  padding: 0 14px; border-left: 1px solid #e8e8e8;
}
body.dark #color-picker { border-left-color: #333; }
.color-dot {
  width: 15px; height: 15px; border-radius: 50%; cursor: pointer;
  border: 2px solid transparent; transition: transform .15s, border-color .15s;
}
.color-dot:hover { transform: scale(1.25); }
.color-dot.active { border-color: #fff; box-shadow: 0 0 0 1.5px #999; }
body.dark .color-dot.active { border-color: #222; box-shadow: 0 0 0 1.5px #aaa; }
@media (max-width: 640px) { #color-picker { display: none; } }

/* ── Page intro paragraph (under each h2.section-title) ───
   Shared across News / Publications / Resources / Service /
   Contact. Empty pages get the element with display:none from
   main.js renderPageIntro so the layout collapses cleanly. */
.page-intro {
  font-size: 15px; color: #555; line-height: 1.7;
  margin: -8px 0 32px;
  max-width: 720px;
}
body.dark .page-intro { color: #aaa; }
/* Back-compat: legacy resources-intro selector still styles the
   same way. */
.resources-intro {
  font-size: 15px; color: #555; line-height: 1.7;
  margin: -8px 0 32px;
  max-width: 720px;
}
body.dark .resources-intro { color: #aaa; }
.resources-section {
  margin-bottom: 48px;
  padding: 22px 24px 24px;
  background: #fff;
  border: 1px solid #eee; border-radius: 8px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.resources-section:last-of-type { margin-bottom: 0; }
.resources-subhead {
  font-size: 18px; font-weight: 700; color: #222;
  margin: 0 0 16px; padding: 0 0 8px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
  letter-spacing: .2px;
}
body.dark .resources-section { background: #1f1f1f; border-color: #2f2f2f; box-shadow: none; }
body.dark .resources-subhead { color: #eee; }
/* Inside a Resources section the corpus-block doesn't need its own
   panel chrome — let it sit flush with the parent panel. */
.resources-section .corpus-block {
  background: transparent; border-left: 0; box-shadow: none;
  padding: 0; margin: 0;
}
body.dark .resources-section .corpus-block { background: transparent; }

/* ── Corpora ───────────────────────────────────────────── */
.corpus-block {
  border-left: 4px solid var(--accent);
  padding: 20px 24px; background: #fff;
  border-radius: 0 6px 6px 0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  margin-bottom: 32px;
}
.corpus-name { font-size:17px; font-weight:700; color:#222; margin:0 0 10px; }
.corpus-meta { display:flex; flex-wrap:wrap; gap:6px; margin-bottom:16px; }
.corpus-tag {
  font-size:11px; font-weight:700; padding:2px 10px;
  border-radius:10px; background:var(--accent-pale); color:var(--accent-dark);
}
.corpus-intro {
  font-size:15px;color:#555;line-height:1.75;margin-bottom:24px;
}
.corpus-pub-intro {
  font-size:15px; color:#888; font-style:italic;
  margin-bottom:14px; padding-left:10px;
  border-left: 3px solid var(--accent-light);
}
.corpus-pub {
  font-size: 14px; line-height: 1.75; color: #444;
  padding: 14px 0; border-bottom: 1px solid #eee;
}
.corpus-pub:last-child { border-bottom: none; }
.corpus-pub em { font-style: italic; color: #777; }
.corpus-pub a {
  font-size: 11px; font-weight: 700; padding: 2px 10px;
  border: 1.5px solid var(--accent); color: var(--accent); border-radius: 3px;
  margin-left: 8px; white-space: nowrap; transition: all .15s;
}
.corpus-pub a:hover { background: var(--accent); color: #fff !important; }

/* ── Mentorship ────────────────────────────────────────── */
.mentorship-group-title {
  font-size: 12px; font-weight: 700; color: #999;
  text-transform: uppercase; letter-spacing: 1.5px;
  margin: 0 0 16px; padding-bottom: 6px;
  border-bottom: 1px solid #eee;
}
.mentee-block {
  border-left: 4px solid var(--accent);
  padding: 16px 20px; background: #f6f6f4;
  border-radius: 0 6px 6px 0;
  margin-bottom: 12px;
}
.mentee-name { font-size:15px; font-weight:700; color:#222; margin:0 0 4px; }
.mentee-meta { font-size:13px; color:#888; margin-bottom:10px; }
.mentee-work a { color:var(--accent); font-weight:600; font-size:14px; line-height:1.6; }
.mentee-work a:hover { text-decoration:underline; }
.mentee-now { font-size:13px; color:#555; margin-top:6px; }
.mentee-now::before { content:"→ "; color:var(--accent); font-weight:700; }

/* ── Image gallery (shared by News / Research / Service rich_text) ──
   Two layout modes selectable per item via item.layout:
     · gallery (default): responsive 16:9 grid, 2-4 per row on desktop,
       1 col on mobile. Single-image case: no crop, max-height 420px.
     · stack: full-width, natural aspect ratio, max-height 480px.
       Best for big horizontal hero shots (diagrams, posters, single
       wide photos). On mobile, stack still full width but max 320px.
   Both modes share rounded corners + hover lift + cursor:zoom-in.
   Images carry class="lightbox-target" so they wire to the lightbox. */
.image-gallery { margin: 12px 0; }
.image-gallery img {
  display: block; width: 100%; border-radius: 8px;
  background: #f4f4f4; box-shadow: 0 1px 6px rgba(0,0,0,0.07);
  cursor: zoom-in; transition: transform .15s, box-shadow .15s;
}
.image-gallery img:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(0,0,0,0.12);
}
.image-gallery.layout-gallery {
  display: grid; gap: 12px;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}
.image-gallery.layout-gallery img {
  aspect-ratio: 16 / 9; object-fit: cover;
}
.image-gallery.layout-gallery img:only-child {
  aspect-ratio: auto; max-height: 420px; object-fit: cover;
}
.image-gallery.layout-stack {
  display: flex; flex-direction: column; gap: 16px;
}
.image-gallery.layout-stack img {
  max-height: 480px; object-fit: contain;
}
@media (max-width: 720px) {
  .image-gallery.layout-gallery { grid-template-columns: 1fr; }
  .image-gallery.layout-gallery img { aspect-ratio: auto; max-height: 320px; }
  .image-gallery.layout-stack img { max-height: 320px; }
}
body.dark .image-gallery img { background: #2a2a2a; }

/* ── Lightbox (click any .lightbox-target img to zoom) ─── */
.lightbox {
  position: fixed; inset: 0; z-index: 10000;
  background: rgba(10, 10, 14, 0.92);
  display: flex; align-items: center; justify-content: center;
  padding: 32px; cursor: zoom-out;
}
.lightbox[hidden] { display: none; }
body.lightbox-open { overflow: hidden; }
.lightbox-img {
  max-width: 100%; max-height: calc(100vh - 80px);
  display: block; cursor: zoom-out;
  box-shadow: 0 8px 40px rgba(0,0,0,0.5); border-radius: 4px;
}
.lightbox-caption {
  position: absolute; bottom: 16px; left: 50%;
  transform: translateX(-50%);
  color: #fff; font-size: 13px; opacity: .85;
  padding: 6px 14px; background: rgba(0,0,0,0.4);
  border-radius: 14px; max-width: 80%; text-align: center;
}
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute; background: rgba(0,0,0,0.45); color: #fff;
  border: 0; border-radius: 50%; cursor: pointer;
  font-size: 20px; line-height: 1; width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  transition: background .15s;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: rgba(0,0,0,0.75); }
.lightbox-close { top: 16px; right: 16px; font-size: 18px; }
.lightbox-prev  { left: 24px;  top: 50%; transform: translateY(-50%); font-size: 30px; }
.lightbox-next  { right: 24px; top: 50%; transform: translateY(-50%); font-size: 30px; }
.lightbox-prev[hidden], .lightbox-next[hidden] { display: none; }

/* ── News (narrow card list with summary + expand) ─────
   Cards are max-width 760px centered in the section so the page
   doesn't feel like a wall of full-width blocks. Default state
   shows date/title/summary/tags/thumb. "Read more →" toggles the
   .news-card.expanded class which reveals the full body + image
   gallery below the summary. */
.news-list {
  display: flex; flex-direction: column; gap: 18px;
  max-width: 760px; margin: 0 auto;
}
.news-card {
  background: #fff; border-radius: 8px; padding: 22px 24px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  border-left: 4px solid var(--accent);
  transition: box-shadow .2s, transform .15s;
}
.news-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.10); }
.news-card-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 12px; margin-bottom: 6px;
}
.news-date {
  font-size: 11px; font-weight: 700; color: #999;
  letter-spacing: .8px; text-transform: uppercase;
}
.news-featured-flag {
  font-size: 10px; font-weight: 700;
  color: #fff; background: #e05a2b;
  padding: 2px 8px; border-radius: 10px;
  letter-spacing: .5px; text-transform: uppercase;
}
.news-title {
  font-size: 17px; font-weight: 700; color: #222;
  margin: 0 0 10px; line-height: 1.35;
}
.news-summary {
  font-size: 14.5px; line-height: 1.7; color: #555; margin: 0 0 10px;
}
.news-thumb {
  margin: 12px 0 4px;
  border-radius: 4px; overflow: hidden;
  background: #f4f4f4;
}
.news-thumb img {
  display: block; width: 100%; max-height: 220px;
  object-fit: cover;
}
.news-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.news-tag {
  font-size: 11px; font-weight: 600; padding: 2px 10px;
  border-radius: 10px; background: var(--accent-pale); color: var(--accent-dark);
}
/* Detail (full body + gallery) — hidden until card is expanded.
   Expanded state hides the summary + thumb so the user sees ONE
   clean continuous full body, not summary-then-body duplication. */
.news-detail { display: none; }
.news-card.expanded .news-detail { display: block; margin-top: 6px; }
.news-card.expanded .news-summary { display: none; }
.news-card.expanded .news-thumb { display: none; }
.news-body { font-size: 14.5px; line-height: 1.75; color: #444; }
.news-body p { margin: 0 0 10px; }
.news-body a { color: var(--accent); }
.news-body a:hover { text-decoration: underline; }

/* Read more / Show less: bottom-right corner of card, plain text,
   no arrows. Works for both <button> (inline-toggle on news.html)
   and <a> (navigate-to-detail on homepage's Featured news). */
.news-readmore-wrap { text-align: right; margin-top: 14px; }
.news-readmore {
  background: none; border: 0; cursor: pointer; padding: 4px 0;
  color: var(--accent); font: inherit;
  font-size: 13px; font-weight: 700;
  text-decoration: none;
}
.news-readmore:hover { color: var(--accent-dark); text-decoration: underline; }

/* Button-styled "Read more" used on the homepage Featured news —
   mirrors the .tool-card "Go to …" button so visual language is
   consistent across the homepage CTAs. */
.news-readmore-btn {
  display: inline-block;
  padding: 7px 16px;
  background: var(--accent);
  color: #fff !important;
  border-radius: 3px;
  font-size: 12px; font-weight: 700;
  text-decoration: none;
  transition: background .18s;
}
.news-readmore-btn:hover { background: var(--accent-dark); color: #fff !important; }

/* Compact news cards (homepage Featured news): tighter padding,
   no image/gallery slots — the article points to news.html for
   the full read. */
.news-card.news-card-compact { padding: 18px 22px; }

/* Homepage Featured news: side-by-side grid (mirrors .tool-grid).
   Cards stretch to equal heights; the Read-more button anchors at
   the bottom so cards line up regardless of summary length.
   Scoped to #news-home so news.html keeps its single-column read. */
#news-home .news-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  max-width: 1000px;
}
#news-home .news-card.news-card-compact {
  display: flex; flex-direction: column;
}
#news-home .news-card.news-card-compact .news-readmore-wrap {
  margin-top: auto;
}
@media (max-width: 640px) {
  #news-home .news-list { grid-template-columns: 1fr; }
}
body.dark .news-card { background: #222; box-shadow: none; }
body.dark .news-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.4); }
body.dark .news-title { color: #eee; }
body.dark .news-summary { color: #aaa; }
body.dark .news-body { color: #aaa; }
body.dark .news-date { color: #666; }
body.dark .news-detail { border-top-color: #333; }
body.dark .news-thumb { background: #1a1a1a; }
body.dark .news-readmore { color: var(--accent-light); }
body.dark .news-readmore:hover { color: var(--accent-light); }

/* Legacy .news-item rules (kept for any callers that still emit them) */
.news-item {
  background: #fff; border-radius: 6px; padding: 18px 22px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.07);
  border-left: 4px solid var(--accent);
}

/* ── Research ──────────────────────────────────────────── */
.research-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 22px;
}
.research-card {
  background: #fff; border-radius: 8px; padding: 24px;
  border: 1.5px solid #e0e0e0;
  transition: border-color .2s, box-shadow .2s;
}
.research-card:hover { border-color: var(--accent); box-shadow: 0 4px 14px rgba(0,0,0,0.08); }
.research-card h3 { font-size: 17px; font-weight: 700; color: #222; margin: 0 0 8px; }
.research-card .summary { font-size: 14px; color: #666; line-height: 1.7; margin: 0 0 12px; }
.research-card .body { font-size: 14px; color: #555; line-height: 1.7; }
.research-card .body p { margin: 0 0 8px; }
.research-card .body a { color: var(--accent); }
.research-images { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.research-images img { max-height: 120px; border-radius: 4px; }

/* ── Contact page ──────────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 32px;
  align-items: start;
}
@media (max-width: 720px) {
  .contact-grid { grid-template-columns: 1fr; }
}
.contact-text { font-size: 15px; line-height: 1.75; color: #444; }
.contact-text p { margin: 0 0 12px; }
.contact-dept { font-weight: 700; color: #222; font-size: 16px; margin: 0 0 4px !important; }
.contact-affil { color: var(--accent); font-weight: 600; margin: 0 0 14px !important; }
.contact-email a {
  display: inline-block; padding: 8px 16px; background: var(--accent);
  color: #fff !important; border-radius: 3px; font-weight: 700; font-size: 13px;
  transition: background .18s;
}
.contact-email a:hover { background: var(--accent-dark); }
.contact-email-row { margin-top: 14px; }
.contact-email-row .email-copy-btn {
  padding: 9px 18px; border-radius: 3px; cursor: pointer;
  font: inherit; font-size: 14px; font-weight: 700;
  border: 1.5px solid var(--accent);
  background: var(--accent); color: #fff;
  transition: all .15s;
}
.contact-email-row .email-copy-btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.contact-map { background: #f6f6f4; border-radius: 6px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,0.07); }
.contact-map iframe { display: block; }
.contact-map-label {
  font-size: 12px; color: #888; padding: 8px 12px; background: #fff;
  border-top: 1px solid #eee;
}
body.dark .contact-text { color: #aaa; }
body.dark .contact-dept { color: #eee; }
body.dark .contact-map { background: #222; box-shadow: none; }
body.dark .contact-map-label { background: #1a1a1a; color: #666; border-top-color: #333; }

/* ── CV page ───────────────────────────────────────────── */
.cv-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0; }
.cv-actions a {
  padding: 10px 22px; border-radius: 3px;
  font-size: 14px; font-weight: 600; transition: all .18s;
}
.cv-summary { font-size: 15px; line-height: 1.8; color: #444; max-width: 720px; }
.cv-summary p { margin: 0 0 14px; }
.cv-summary strong { color: #222; }

/* ── Rich-text content (tables, blockquote, code, sub/sup, etc.) ──
   Applied wherever user-authored HTML appears: bio, news body,
   research body, mentee work, service rich_text, etc. */
.about-bio table, .news-body table, .research-card .body table,
.corpus-block table, .svc-rich table {
  border-collapse: collapse; width: 100%; margin: 12px 0;
  font-size: 14px;
}
.about-bio th, .about-bio td,
.news-body th, .news-body td,
.research-card .body th, .research-card .body td,
.svc-rich th, .svc-rich td {
  border: 1px solid #ddd; padding: 8px 12px; text-align: left;
}
.about-bio th, .news-body th, .research-card .body th, .svc-rich th {
  background: #f6f6f4; font-weight: 700;
}
body.dark .about-bio th, body.dark .news-body th,
body.dark .research-card .body th, body.dark .svc-rich th {
  background: #2a2a2a;
}
body.dark .about-bio td, body.dark .about-bio th,
body.dark .news-body td, body.dark .news-body th,
body.dark .research-card .body td, body.dark .research-card .body th,
body.dark .svc-rich td, body.dark .svc-rich th {
  border-color: #3a3a3a;
}

.about-bio blockquote, .news-body blockquote, .research-card .body blockquote,
.svc-rich blockquote {
  border-left: 3px solid var(--accent); padding: 4px 14px;
  margin: 10px 0; color: #555; background: #f9f9f9;
}
body.dark .about-bio blockquote, body.dark .news-body blockquote,
body.dark .research-card .body blockquote, body.dark .svc-rich blockquote {
  background: #222; color: #aaa;
}

.about-bio code, .news-body code, .research-card .body code, .svc-rich code {
  background: #f4f4f4; padding: 1px 6px; border-radius: 3px;
  font-family: Consolas, Menlo, monospace; font-size: .9em;
}
body.dark .about-bio code, body.dark .news-body code,
body.dark .research-card .body code, body.dark .svc-rich code {
  background: #2a2a2a; color: #ddd;
}
.about-bio pre, .news-body pre, .research-card .body pre, .svc-rich pre {
  background: #fafafa; border: 1px solid #eee; border-radius: 4px;
  padding: 12px 14px; overflow-x: auto; font-family: Consolas, Menlo, monospace;
  font-size: 13px; line-height: 1.55; margin: 12px 0;
}
body.dark .about-bio pre, body.dark .news-body pre,
body.dark .research-card .body pre, body.dark .svc-rich pre {
  background: #1f1f1f; border-color: #333; color: #ddd;
}
.about-bio mark, .news-body mark, .research-card .body mark, .svc-rich mark {
  background: #fff3a3; padding: 0 2px; border-radius: 2px;
}
.about-bio hr, .news-body hr, .research-card .body hr, .svc-rich hr {
  border: 0; border-top: 1px solid #eee; margin: 16px 0;
}
body.dark .about-bio hr, body.dark .news-body hr,
body.dark .research-card .body hr, body.dark .svc-rich hr {
  border-top-color: #333;
}

/* Service page extras */
.svc-list { padding-left: 24px; font-size: 15px; line-height: 1.8; color: #444; }
body.dark .svc-list { color: #aaa; }
.svc-rich { font-size: 15px; line-height: 1.78; color: #444; }
body.dark .svc-rich { color: #aaa; }

/* ── Empty state ───────────────────────────────────────── */
.empty-state {
  font-style: italic; color: #aaa;
  padding: 24px 0; text-align: left;
}

/* ── Dark mode (full coverage) ─────────────────────────── */
body.dark { background: #1a1a1a; color: #ccc; }
body.dark a { color: var(--accent-light); }
body.dark a:hover { color: var(--accent-light); }
body.dark #nav-bar { background: #111; border-bottom-color: #333; box-shadow: 0 1px 4px rgba(0,0,0,0.4); }
body.dark #nav-bar li a { color: #aaa; }
body.dark #nav-bar li a:hover { background: #2a2a2a; color: #fff; }
body.dark #banner { background: #000; }

body.dark .section.band-white { background: #1a1a1a; }
body.dark .section.band-tint  { background: #1a1a1a; }
body.dark #about { background: #1a1a1a; }
body.dark .about-bio h2 { color: #eee; }
body.dark .about-bio p { color: #aaa; }
body.dark .about-bio strong { color: #ddd; }
body.dark .about-bio .subtitle { color: var(--accent-light); }
body.dark .section-title { color: #eee; }

body.dark .pub-item { background: #222; box-shadow: none; }
body.dark .pub-title { color: #eee; }
body.dark .pub-title a { color: #eee; }
body.dark .pub-authors { color: #888; }
body.dark .pub-journal { color: #777; }
body.dark .pub-filter-btn { background: #222; border-color: #444; color: #aaa; }
body.dark .pub-filter-btn:hover, body.dark .pub-filter-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }
body.dark .pub-filter-btn:not(.active) .count { background: #333; color: #888; }

body.dark .pr-summary { background: #222; }
body.dark .pr-table th { color: #666; border-bottom-color: #333; }
body.dark .pr-table td { color: #aaa; border-bottom-color: #2a2a2a; background: #1a1a1a; }
body.dark .pr-table tr:nth-child(even) td { background: #222; }

body.dark .tool-card { background: #222; border-color: #333; }
body.dark .tool-card h3 { color: #eee; }
body.dark .tool-card p { color: #999; }
body.dark .tool-group-tagline { color: #aaa; }

body.dark #funders { background: #1a1a1a; border-top-color: #333; }

body.dark .corpus-block { background: #222; box-shadow: none; }
body.dark .corpus-name { color: #eee; }
body.dark .corpus-intro { color: #aaa; }
body.dark .corpus-pub { color: #aaa; border-bottom-color: #2a2a2a; }
body.dark .corpus-pub em { color: #888; }
body.dark .corpus-pub-intro { color: #666; }

body.dark .mentorship-group-title { color: #555; border-bottom-color: #333; }
body.dark .mentee-block { background: #222; }
body.dark .mentee-name { color: #eee; }
body.dark .mentee-meta { color: #666; }
body.dark .mentee-now { color: #aaa; }

body.dark .news-item { background: #222; box-shadow: none; }
body.dark .news-title { color: #eee; }
body.dark .news-body { color: #aaa; }
body.dark .news-date { color: #666; }

body.dark .research-card { background: #222; border-color: #333; }
body.dark .research-card h3 { color: #eee; }
body.dark .research-card .summary { color: #999; }
body.dark .research-card .body { color: #aaa; }

body.dark .cv-summary { color: #aaa; }
body.dark .cv-summary strong { color: #ddd; }
