/* ==========================================================================
   Donggeon Lee — academic homepage
   Plain CSS, no build step. Tokens first, then layout, then components.
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  color-scheme: light;

  --bg: #fbfbf9;
  --bg-elev: #ffffff;
  --bg-sunken: #f3f3f0;
  --text: #191b1f;
  --text-2: #3d434c;
  --muted: #6b727d;
  --line: #e6e6e2;
  --line-strong: #d3d4cf;
  --accent: #1f4b8f;
  --accent-ink: #163a70;
  --accent-soft: #eaf0fa;
  --accent-ring: rgba(31, 75, 143, 0.28);
  --selection: #dbe6f7;
  --shadow: 0 1px 2px rgba(20, 22, 26, 0.04), 0 8px 24px -16px rgba(20, 22, 26, 0.18);

  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", "Source Serif Pro", Georgia, serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;

  --sidebar-w: 292px;
  --gutter: clamp(40px, 6vw, 88px);
  --page-max: 1160px;
  --pad-x: clamp(20px, 4vw, 40px);

  --radius: 12px;
  --radius-sm: 7px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0f1115;
    --bg-elev: #151920;
    --bg-sunken: #12151b;
    --text: #e8eaed;
    --text-2: #c2c7cf;
    --muted: #8f98a5;
    --line: #23282f;
    --line-strong: #323841;
    --accent: #8fb4f2;
    --accent-ink: #b7cff7;
    --accent-soft: #182234;
    --accent-ring: rgba(143, 180, 242, 0.35);
    --selection: #243553;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -16px rgba(0, 0, 0, 0.6);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f1115;
  --bg-elev: #151920;
  --bg-sunken: #12151b;
  --text: #e8eaed;
  --text-2: #c2c7cf;
  --muted: #8f98a5;
  --line: #23282f;
  --line-strong: #323841;
  --accent: #8fb4f2;
  --accent-ink: #b7cff7;
  --accent-soft: #182234;
  --accent-ring: rgba(143, 180, 242, 0.35);
  --selection: #243553;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -16px rgba(0, 0, 0, 0.6);
}

/* ---------- Base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 24px;
  -webkit-text-size-adjust: 100%;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  font-feature-settings: "cv11", "ss01", "calt";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--selection);
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in srgb, var(--accent) 35%, transparent);
  text-underline-offset: 0.18em;
  transition: color 0.15s var(--ease), text-decoration-color 0.15s var(--ease);
}

a:hover {
  color: var(--accent-ink);
  text-decoration-color: currentColor;
}

:focus-visible {
  outline: 3px solid var(--accent-ring);
  outline-offset: 3px;
  border-radius: 3px;
}

h1,
h2,
h3,
p,
ul,
ol,
dl {
  margin: 0;
}

img {
  max-width: 100%;
  display: block;
}

button {
  font: inherit;
  color: inherit;
}

a,
button {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

p,
h1,
h2,
h3,
li,
dd {
  overflow-wrap: break-word;
}

sup {
  line-height: 0;
  font-size: 0.72em;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 100;
  padding: 10px 14px;
  background: var(--bg-elev);
  color: var(--text);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: 16px;
}

/* ---------- Layout ---------- */
.layout {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  column-gap: var(--gutter);
  width: min(100% - 2 * var(--pad-x), var(--page-max));
  margin-inline: auto;
}

.sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 28px;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 64px 0 32px;
}

.content {
  padding: 64px 0 24px;
  min-width: 0;
}

/* ---------- Sidebar: identity ---------- */
.identity {
  display: grid;
  gap: 22px;
}

.portrait {
  display: block;
  width: 132px;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-sunken);
  box-shadow: var(--shadow);
}

.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%;
  transform: scale(1.04);
  transition: transform 0.6s var(--ease);
}

@media (hover: hover) {
  .portrait:hover img {
    transform: scale(1.08);
  }
}

.name {
  font-family: var(--font-serif);
  font-optical-sizing: auto;
  font-size: 2.05rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.08;
  margin-bottom: 8px;
}

.role {
  color: var(--text-2);
  font-size: 0.96rem;
  font-weight: 500;
  line-height: 1.45;
}

.affiliation {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.location {
  color: var(--muted);
}

/* ---------- Sidebar: social ---------- */
.social {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
  list-style: none;
}

.social a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 11px 6px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  color: var(--text-2);
  font-size: 0.84rem;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 0.15s var(--ease), color 0.15s var(--ease), background 0.15s var(--ease);
}

.social a:hover {
  border-color: var(--line-strong);
  color: var(--text);
  background: var(--bg-sunken);
}

.social svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  opacity: 0.8;
}

/* ---------- Sidebar: nav ---------- */
.site-nav ul {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 2px;
}

.site-nav a {
  position: relative;
  display: block;
  padding: 6px 0 6px 18px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: color 0.15s var(--ease);
}

.site-nav a::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 6px;
  height: 1.5px;
  background: var(--line-strong);
  transform: translateY(-50%);
  transition: width 0.2s var(--ease), background 0.2s var(--ease);
}

.site-nav a:hover {
  color: var(--text);
}

.site-nav a:hover::before {
  width: 10px;
  background: var(--muted);
}

.site-nav a[aria-current="true"] {
  color: var(--text);
  font-weight: 600;
}

.site-nav a[aria-current="true"]::before {
  width: 12px;
  background: var(--accent);
}

/* ---------- Sidebar: foot ---------- */
.sidebar-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  color: var(--text-2);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), background 0.15s var(--ease);
}

.theme-toggle:hover {
  border-color: var(--line-strong);
  background: var(--bg-sunken);
}

.theme-toggle svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

.theme-toggle .icon-moon {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-sun {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-moon {
  display: inline;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun {
    display: none;
  }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon {
    display: inline;
  }
}

.updated {
  color: var(--muted);
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

/* ---------- Sections ---------- */
.section {
  padding: 56px 0;
  border-top: 1px solid var(--line);
}

.section:first-child {
  padding-top: 0;
  border-top: 0;
}

.section-header {
  display: grid;
  gap: 10px;
  margin-bottom: 28px;
}

.section-header h2 {
  font-family: var(--font-serif);
  font-optical-sizing: auto;
  font-size: 1.75rem;
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
}

.section-lead {
  max-width: 62ch;
  color: var(--text-2);
  font-size: 1rem;
}

.section-lead sup {
  color: var(--muted);
}

/* ---------- About ---------- */
.lead {
  font-family: var(--font-serif);
  font-optical-sizing: auto;
  font-size: clamp(1.5rem, 2.1vw + 0.7rem, 2.05rem);
  font-weight: 400;
  letter-spacing: -0.012em;
  line-height: 1.32;
  max-width: 30ch;
  margin-bottom: 30px;
  text-wrap: balance;
}

.lead em {
  font-style: italic;
  color: var(--accent);
}

.prose {
  display: grid;
  gap: 16px;
  max-width: 66ch;
  color: var(--text-2);
  font-size: 1.02rem;
}

.prose strong {
  color: var(--text);
  font-weight: 600;
}

.facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin-top: 40px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-elev);
  overflow: hidden;
}

.facts > div {
  padding: 16px 18px;
  border-left: 1px solid var(--line);
}

.facts > div:first-child {
  border-left: 0;
}

.facts dt {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.facts dd {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.4;
}

/* ---------- News ---------- */
.news-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0;
}

.news-list li {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 20px;
  padding: 13px 0;
  border-top: 1px dashed var(--line);
}

.news-list li:first-child {
  border-top: 0;
  padding-top: 0;
}

.news-list time {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  padding-top: 2px;
  white-space: nowrap;
}

.news-list p {
  color: var(--text-2);
  font-size: 0.98rem;
}

.news-list strong {
  color: var(--text);
  font-weight: 600;
}

/* ---------- Research ---------- */
.research-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.research-card {
  position: relative;
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 22px 20px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-elev);
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

@media (hover: hover) {
  .research-card:hover {
    border-color: var(--line-strong);
    box-shadow: var(--shadow);
    transform: translateY(-2px);
  }
}

.card-index {
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.research-card h3 {
  font-size: 1.04rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.35;
}

.research-card p {
  color: var(--text-2);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* ---------- Publications / Patents ---------- */
.pub-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 30px;
}

.pub {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 20px;
  scroll-margin-top: 24px;
}

.pub:target .pub-title {
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

.badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  white-space: nowrap;
  transform: translateY(2px);
}

.badge-muted {
  background: var(--bg-sunken);
  color: var(--muted);
  border: 1px solid var(--line);
}

.pub-body {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.pub-title {
  font-size: 1.08rem;
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.4;
  max-width: 60ch;
}

.pub-authors {
  color: var(--text-2);
  font-size: 0.95rem;
}

.pub-authors strong {
  color: var(--text);
  font-weight: 600;
}

.pub-meta {
  color: var(--muted);
  font-size: 0.88rem;
  font-style: italic;
}

.pub-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.pub-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  color: var(--text-2);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), color 0.15s var(--ease), background 0.15s var(--ease);
}

.pub-link:hover {
  border-color: var(--line-strong);
  color: var(--text);
  background: var(--bg-sunken);
}

.pub-link[aria-expanded="true"] {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.bibtex {
  position: relative;
  margin-top: 10px;
}

.bibtex pre {
  margin: 0;
  padding: 14px 16px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-sunken);
  color: var(--text-2);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.55;
  tab-size: 2;
}

.copy-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), color 0.15s var(--ease);
}

.copy-btn:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.copy-btn[data-copied="true"] {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- Teaching ---------- */
.teaching-list {
  list-style: none;
  padding: 0;
  display: grid;
}

.teaching-list li {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 20px;
  padding: 11px 0;
  border-top: 1px dashed var(--line);
}

.teaching-list li:first-child {
  border-top: 0;
  padding-top: 0;
}

.teaching-list li.highlight {
  margin-top: 8px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
}

.term {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  padding-top: 1px;
}

.course {
  color: var(--text-2);
  font-size: 0.97rem;
}

.course-role {
  display: inline-block;
  margin-right: 6px;
  color: var(--text);
  font-weight: 600;
}

.course-role::after {
  content: "·";
  margin-left: 8px;
  color: var(--line-strong);
  font-weight: 400;
}

.course-note {
  color: var(--muted);
  font-size: 0.9rem;
}

/* ---------- Expertise ---------- */
.expertise {
  display: grid;
  gap: 18px;
}

.expertise > div {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 20px;
  align-items: start;
}

.expertise dt {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  padding-top: 5px;
}

.expertise dd {
  margin: 0;
}

.tags {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tags li {
  padding: 5px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-elev);
  color: var(--text-2);
  font-size: 0.86rem;
  font-weight: 500;
}

/* ---------- Education ---------- */
.edu-list {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 18px;
}

.edu-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: start;
}

.edu-list h3 {
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  margin-bottom: 2px;
}

.edu-list p {
  color: var(--muted);
  font-size: 0.92rem;
}

/* ---------- Contact ---------- */
.section-contact .prose {
  margin-bottom: 22px;
}

.contact-list {
  list-style: none;
  padding: 0;
  display: grid;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-elev);
  overflow: hidden;
}

.contact-list li {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: 20px;
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  font-size: 0.95rem;
}

.contact-list li:first-child {
  border-top: 0;
}

.contact-list li > span:first-child {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 500;
  padding-top: 1px;
}

.contact-list a {
  word-break: break-all;
}

/* ---------- Footer ---------- */
.site-footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 24px;
  padding: 26px 0 40px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.82rem;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1080px) {
  :root {
    --sidebar-w: 256px;
  }

  .research-grid {
    grid-template-columns: 1fr;
  }

  .facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .facts > div:nth-child(3) {
    border-left: 0;
  }

  .facts > div:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }
}

@media (max-width: 860px) {
  html {
    scroll-padding-top: 72px;
  }

  .layout {
    grid-template-columns: minmax(0, 1fr);
    width: min(100% - 2 * var(--pad-x), 720px);
  }

  /* The sidebar dissolves into the page grid so the nav can stick to the
     viewport (a sticky element only sticks within its parent's box). */
  .sidebar {
    display: contents;
  }

  .identity {
    margin-top: 36px;
  }

  .social {
    margin-top: 20px;
  }

  .content {
    order: 20;
  }

  .identity {
    grid-template-columns: 96px minmax(0, 1fr);
    align-items: center;
    gap: 20px;
  }

  .portrait {
    width: 96px;
  }

  .name {
    font-size: 1.8rem;
  }

  .site-nav {
    order: 10;
    position: sticky;
    top: 0;
    z-index: 20;
    margin-inline: calc(-1 * var(--pad-x));
    padding-inline: var(--pad-x);
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    -webkit-backdrop-filter: saturate(160%) blur(12px);
    backdrop-filter: saturate(160%) blur(12px);
    border-bottom: 1px solid var(--line);
  }

  .site-nav ul {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 8px 0;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 32px), transparent);
  }

  .site-nav ul::-webkit-scrollbar {
    display: none;
  }

  .site-nav a {
    padding: 9px 14px;
    border-radius: 999px;
    font-size: 0.92rem;
    white-space: nowrap;
  }

  .social a {
    padding: 8px 13px 8px 11px;
    font-size: 0.88rem;
  }

  .theme-toggle {
    padding: 8px 12px;
    font-size: 0.84rem;
  }

  .pub-link {
    padding: 7px 13px;
    font-size: 0.84rem;
  }

  .copy-btn {
    padding: 5px 11px;
  }

  .site-nav a::before {
    display: none;
  }

  .site-nav a[aria-current="true"] {
    background: var(--accent-soft);
    color: var(--accent);
  }

  .sidebar-foot {
    margin-top: 20px;
    border-top: 0;
    padding-top: 0;
  }

  .site-nav {
    margin-top: 20px;
  }

  .content {
    padding-top: 36px;
  }

  .section {
    padding: 44px 0;
  }

  .lead {
    max-width: none;
  }
}

@media (max-width: 560px) {
  .section {
    padding: 38px 0;
  }

  .section-header {
    margin-bottom: 22px;
  }

  .section-header h2 {
    font-size: 1.55rem;
  }

  .prose,
  .news-list p,
  .course,
  .research-card p {
    font-size: 1rem;
    line-height: 1.7;
  }

  .pub-list {
    gap: 26px;
  }

  .identity {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 16px;
  }

  .portrait {
    width: 76px;
  }

  .name {
    font-size: 1.6rem;
  }

  .facts {
    grid-template-columns: 1fr;
  }

  .facts > div {
    border-left: 0;
  }

  .facts > div:nth-child(n + 2) {
    border-top: 1px solid var(--line);
  }

  .news-list li,
  .teaching-list li,
  .pub,
  .expertise > div,
  .contact-list li {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .badge {
    transform: none;
  }

  .edu-list li {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .site-footer {
    flex-direction: column;
  }
}

/* ==========================================================================
   Print
   ========================================================================== */
@media print {
  :root {
    --bg: #fff;
    --bg-elev: #fff;
    --bg-sunken: #fff;
    --text: #000;
    --text-2: #222;
    --muted: #555;
    --line: #ccc;
    --line-strong: #999;
    --accent: #000;
  }

  body {
    font-size: 11pt;
  }

  .layout {
    display: block;
    width: auto;
  }

  .sidebar {
    position: static;
    min-height: 0;
    padding: 0 0 20px;
    border-bottom: 1px solid var(--line);
  }

  .site-nav,
  .sidebar-foot,
  .skip-link,
  .pub-actions,
  .bibtex,
  .portrait {
    display: none !important;
  }

  .content {
    padding-top: 20px;
  }

  .section {
    padding: 20px 0;
    break-inside: avoid;
  }

  a {
    color: inherit;
    text-decoration: none;
  }

  .research-card,
  .facts,
  .contact-list {
    box-shadow: none;
  }
}
