:root {
  --accent: #4a5568;      /* Slate Gray */
  --text: #2d3748;        /* Charcoal */
  --bg: #f8f9fa;          /* Off-white */
  --link-hover: #718096;  /* Muted gray-blue */
}

/* ---------- Text Selection ---------- */
::selection {
  background-color: #4a5568; /* Slate Gray */
  color: #ffffff;
}

/* ---------- Base ---------- */
body {
  font-family: "Lato", "Segoe UI", Helvetica, Arial, sans-serif;
  color: var(--text);
  background-color: var(--bg);
  margin: 0;
  line-height: 1.65;
  font-size: 16.5px;
}

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

a {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.1s ease;
}

a:hover {
  border-bottom: 1px solid var(--link-hover);
}

/* ---------- Container ---------- */
.container {
  max-width: 950px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}

/* ---------- Header ---------- */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.photo img {
  width: 260px;
  height: auto;
  object-fit: cover;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.intro {
  flex: 1;
  min-width: 320px;
}

.intro h1 {
  color: var(--text);
  font-size: 2rem;
  margin: 0 0 1rem 0;
}

.intro p {
  margin: 0.5rem 0;
}

/* ---------- Sections ---------- */
h2 {
  color: var(--accent);
  font-size: 1.25rem;
  border-bottom: 1px solid var(--accent);
  padding-bottom: 0.3rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.section p {
  margin: 0.4rem 0 1rem 0;
}

/* ---------- Updates ---------- */
.updates {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 4px solid var(--accent);
  padding: 1.2rem 1.8rem;
  margin-bottom: 2.5rem;
}

.updates-header {
  font-family: monospace;
  color: var(--accent);
  font-size: 15px;
  margin-bottom: 0.6rem;
}

.updates ul {
  margin: 0;
  padding-left: 1.2rem;
  list-style-type: disc;
}

/* ---------- Publications ---------- */
.publication {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  margin-top: 1.8rem;
}

.pub-video video, .pub-video img {
  width: 270px;
  height: 190px; /* closer to ratio 3:2 */
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.pub-text {
  flex: 1;
  min-width: 320px;
  line-height: 1.55;
}

.paper-title {
  color: var(--text);
  font-weight: 600;
  font-size: 17px;
  line-height: 1.4;
}

.authors {
  font-size: 14px;
  color: var(--accent);
  display: inline-block;
  margin: 2px 0 4px 0;
}

.pub-text em {
  font-size: 14.5px;
  color: var(--text);
}

.pub-text p {
  margin-top: 0.4rem;
  font-size: 15px;
  line-height: 1.6;
}

/* ---------- Projects ---------- */
.project {
  display: flex;
  align-items: flex-start;
  gap: 1.8rem;
  margin-top: 1.8rem;
}

.project-image img {
  width: 220px;
  height: auto;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.project-text {
  flex: 1;
  min-width: 320px;
}

.project-subtitle {
  font-size: 14.5px;
  color: var(--accent);
  display: inline-block;
  margin-bottom: 6px;
}

.project-text p {
  margin-top: 0.4rem;
  font-size: 15px;
  line-height: 1.6;
}

/* ---------- Lists ---------- */
ul {
  padding-left: 1.2rem;
  margin-top: 0;
}

/* ---------- Footer ---------- */
footer {
  text-align: center;
  font-size: 14px;
  color: #6b7280;
  border-top: 1px solid #e2e8f0;
  margin-top: 3rem;
  padding-top: 1.5rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .header {
    flex-direction: column;
    text-align: center;
  }

  .photo img {
    width: 220px;
    margin-bottom: 1rem;
  }

  .intro h1 {
    font-size: 1.7rem;
  }

  .publication,
  .project {
    flex-direction: column;
    align-items: center;
  }

  .pub-video video, .pub-video img, 
  .project-image img {
    width: 100%;
    height: auto;
    max-width: 360px;
  }

  .pub-text,
  .project-text {
    min-width: unset;
  }

  footer {
    font-size: 13.5px;
  }
}
