html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-size: 16px;
  margin: 0;
  padding: 0;
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.55;
  color: #222;
  background: white;
}

main {
  max-width: 1050px;
  margin: 40px auto;
  padding: 0 24px;
}

h1 {
  font-size: 2.1rem;
  margin-bottom: 0.2rem;
}

h2 {
  font-size: 1.35rem;
  margin-top: 2.5rem;
  border-bottom: 1px solid #ddd;
  padding-bottom: 0.25rem;
}

a {
  color: #1772d0;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.intro {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
}

.intro-text {
  flex: 1;
}

.intro-photo {
  margin-top: 10px;
}

.intro-photo img {
  width: 180px;
  height: 220px;

  object-fit: cover;

  border-radius: 50%;
  border: 4px solid #f0f0f0;
}

.links {
  margin-top: 0.5rem;
}

.audience-btn {
  border: none;
  background: none;
  padding: 0;
  font: inherit;
  color: #1772d0;
  cursor: pointer;
}

.audience-btn:hover {
  text-decoration: underline;
}

.audience-btn.active {
  color: #222;
  font-weight: bold;
}

.publication {
  margin: 1rem 0;
  padding-bottom: 1rem;
  border-bottom: 1px solid #ddd;
}

.publication:last-of-type {
  border-bottom: none;
}

.pub-main {
  display: flex;
  gap: 1.2rem;
  align-items: center;
}

.pub-img {
  width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 4px;
  background: #eee;
}

.pub-info {
  flex: 1;
  min-width: 0;
}

.pub-title,
.pub-authors,
.pub-venue,
.pub-links {
  margin: 0.25rem 0;
  font-size: 1rem;
}

.pub-venue {
  color: #555;
}

.summary {
  display: none;
  margin: 0.7rem 0;
}

body[data-audience="academic"] .summary.academic,
body[data-audience="practitioner"] .summary.practitioner,
body[data-audience="general"] .summary.general {
  display: block;
}

@media (max-width: 650px) {
  .pub-main {
    flex-direction: column;
    align-items: stretch;
  }

  .pub-media {
    width: 100%;
    flex: none;
  }
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.audience-toggle {
  font-size: 1.1rem;
  font-weight: normal;
  color: #3a3a3a;
}
.bottom-toggle {
  margin-top: 2rem;
  text-align: right;
}

.pub-award {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  margin-left: 0.6rem;
  letter-spacing: 0.015em;
}

.pub-award a {
  color: #444;
  text-decoration: none;
}

.pub-award a:hover {
  text-decoration: underline;
}

.award-star {
  font-size: 1.05rem;
  margin-right: 0.15rem;
}

.link-button {
  appearance: none;
  -webkit-appearance: none;

  border: none;
  background: none;
  padding: 0;
  margin: 0;

  font: inherit;
  font-size: 1em;
  line-height: inherit;

  color: #1772d0;
  cursor: pointer;
}

.link-button:hover {
  text-decoration: underline;
}

.bibtex-container {
  display: none;
  position: relative;
  margin-top: 0.5rem;
}

.bibtex {
  margin: 0;
  padding: 0.75rem;
  padding-top: 2rem;
  background: #f7f7f7;
  border-left: 3px solid #ddd;
  overflow-x: auto;
  white-space: pre-wrap;
  font-size: 0.85rem;
}

.bibtex-toggle.active {
  font-weight: bold;
}

.copy-bibtex {
  position: absolute;
  top: 8px;
  right: 8px;

  padding: 2px 8px;

  border: 1px solid #ccc;
  border-radius: 4px;

  background: #fafafa;

  color: #444;
  cursor: pointer;

  font-size: 0.8rem;
}
.copy-bibtex:hover {
  background: #f0f0f0;
  border-color: #999;
}

.copy-bibtex:active {
  transform: scale(0.96);
}

.pub-media {
  width: 280px;
  flex: 0 0 280px;
  display: flex;
  gap: 0.5rem;
}

.pub-media img {
  width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  background: white;
}

.pub-media.single {
  flex-direction: column;
  align-items: center;
}

.pub-media.stack {
  flex-direction: column;
  align-items: center;
}

.pub-media.row {
  flex-direction: row;
}

.pub-media.row img {
  width: calc((100% - 0.5rem) / 2);
}

.industry {
  margin-top: 0rem;
}

.industry .pub-title,
.industry .pub-authors,
.industry .pub-venue {
  font-size: 1rem;
}

.industry p {
  font-size: 1rem;
}
.patents {
  font-size: 0.95rem;
  color: #555;
  margin-top: 0.5rem;
}
.small-note {
  font-size: 0.9rem;
  color: #666;
  line-height: 1.45;
  margin-top: 0.6rem;
  margin-bottom: 0.3;
}
.section-note {
  margin: 0.45rem 0 1.5rem;
  font-size: 0.95rem;
  color: #555;
}