:root {
  --text: #1f2937;
  --muted: #6b7280;
  --line: #e5e7eb;
  --bg: #ffffff;
  --soft: #f8fafc;
  --link: #1d4ed8;
  --link-hover: #1e40af;
  --max-width: 1000px;
}

* {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  font-size: 18px;
}

.container {
  width: min(var(--max-width), calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 0 20px 0;
  gap: 20px;
}

.nav-right {
  justify-content: flex-end;
}

.site-title {
  margin: 0;
  font-size: 2.2rem;
  font-weight: 700;
}

.site-title a {
  color: inherit;
  text-decoration: none;
}

.menu {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.menu a {
  text-decoration: none;
  color: var(--text);
  font-size: 1rem;
}

.menu a:hover,
.menu a.active {
  color: var(--link);
}

.hero {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 36px;
  padding: 48px 0;
  align-items: start;
}

.profile-image {
  width: 220px;
}

.profile-image img {
  width: 200px;
  max-width: 200px;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--line);
  display: block;
}

.profile-text p {
  margin-top: 0;
  margin-bottom: 1.2em;
}

.contact {
  margin-top: 32px;
}

.contact h2,
.page-content h2 {
  font-size: 2rem;
  margin-bottom: 18px;
}

.page-content {
  padding: 48px 0 60px 0;
}

.section-block {
  margin-bottom: 48px;
}

.section-block h3 {
  font-size: 1.45rem;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

.paper,
.teaching-block {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 20px 22px;
  margin-bottom: 22px;
}

.paper-header {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: start;
}

.paper h4,
.teaching-block h4 {
  margin: 0 0 8px 0;
  font-size: 1.2rem;
  line-height: 1.35;
}

.authors,
.meta,
.simple-paper p {
  margin: 0 0 8px 0;
}

.meta {
  color: var(--muted);
  font-size: 0.95rem;
}

.paper-link a,
.paper-link span {
  white-space: nowrap;
  font-weight: 600;
}

details {
  margin-top: 14px;
}

summary {
  cursor: pointer;
  font-weight: 600;
}

a {
  color: var(--link);
}

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

ul {
  margin-top: 8px;
}

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 20px;
  padding: 20px 0 28px 0;
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.socials {
  display: flex;
  gap: 12px;
}

.socials img {
  width: 24px;
  height: 24px;
  display: block;
}

@media (max-width: 760px) {
  body {
    font-size: 17px;
  }

  .nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .profile-image img {
    max-width: 180px;
  }

  .paper-header,
  .footer-content {
    flex-direction: column;
    align-items: flex-start;
  }

  .menu {
    gap: 16px;
  }
}
