/* ==== CSS RESET (simplified) ==== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  color: #111827;
  background-color: var(--color-bg);
  line-height: 1.6;
}

/* ==== CSS VARIABLES ==== */
:root {
  /* Backgrounds (grayscale only) */
  --color-bg: #f4f4f5;          /* very light gray, page background */
  --color-surface: #ffffff;     /* white for cards */
  --color-surface-alt: #e5e7eb; /* slightly darker gray for alt sections */

  /* Borders & text */
  --color-border: #d4d4d8;
  --color-text: #111827;
  --color-text-muted: #6b7280;

  /* Accent (blue kept only for links, etc.) */
  --color-primary: #2563eb;
  --color-primary-soft: rgba(37, 99, 235, 0.12);
  --color-primary-dark: #1d4ed8;

  --shadow-soft: 0 10px 30px rgba(15, 23, 42, 0.07);
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-pill: 999px;
}

/* ==== GLOBAL LINKS ==== */
a {
  color: var(--color-primary-dark);
  text-decoration: none;
}

a:hover,
a:focus-visible {
  color: color-mix(in srgb, var(--color-primary) 60%, magenta 40%); /*color: var(--color-primary);*/
  text-decoration: none;
}

/* ==== UTILS ==== */
.container {
  width: min(1000px, 100% - 2.5rem);
  margin-inline: auto;
}

.section {
  padding: 3rem 0;
}

.section-compact {
  padding: 2.2rem 0 3rem;
}

.section-alt {
  background-color: var(--color-surface-alt);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section-header {
  text-align: left;
  margin-bottom: 1.8rem;
}

.section-header h2 {
  font-size: 1.6rem;
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
}

.section-header p {
  margin: 0;
  color: var(--color-text-muted);
}

.section-intro {
  margin-top: 0;
  margin-bottom: 1.5rem;
  color: var(--color-text-muted);
}

/* Two-column grid for desktop */
.section-grid {
  display: grid;
  gap: 1.8rem;
}

@media (min-width: 900px) {
  .section-grid {
    grid-template-columns: minmax(0, 2.1fr) minmax(0, 1.5fr);
  }
}

/* Media grid alignment */
.section-grid-media {
  align-items: center;
}

/* ==== SKIP LINK ==== */
.skip-link {
  position: absolute;
  top: -100px;
  left: 0;
  background: #000;
  color: #fff;
  padding: 0.75rem 1rem;
  z-index: 100;
  border-radius: 0 0.75rem 0.75rem 0;
}

.skip-link:focus {
  top: 0;
}

/* ==== HEADER / NAV ==== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(229, 231, 235, 0.96); /* slightly darker gray */
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.6);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 0.6rem;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #111827;
  gap: 0.65rem;
}

.logo-img {
  width: 36px;
  height: auto;
  display: block;
}

.logo-text {
  font-weight: 600;
  letter-spacing: -0.03em;
  font-size: 1rem;
}

/* Nav */
.site-nav ul {
  list-style: none;
  display: flex;
  gap: 1.2rem;
  margin: 0;
  padding: 0;
}

.site-nav a {
  text-decoration: none;
  color: var(--color-text-muted); /*#374151; /* neutral gray for menu items */
  font-size: 0.95rem;
  font-weight: 500;
  position: relative;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.25rem;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #3b82f6, #6366f1); /*#4b5563; /* gray underline */
  border-radius: 999px;
  transition: width 0.2s ease;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: #111827;
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  width: 100%;
}

/* Mobile nav */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.25rem;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 999px;
  background-color: #111827;
  margin: 4px 0;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 900px) {
  .site-nav {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    background-color: rgba(229, 231, 235, 0.98);
    border-bottom: 1px solid rgba(148, 163, 184, 0.6);
    transform-origin: top;
    transform: scaleY(0.8);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease;
  }

  .site-nav.open {
    opacity: 1;
    pointer-events: auto;
    transform: scaleY(1);
  }

  .site-nav ul {
    flex-direction: column;
    padding: 0.75rem 1.5rem 1.25rem;
    gap: 0.9rem;
  }

  .nav-toggle {
    display: inline-block;
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) {
    transform: translateY(-6px) rotate(-45deg);
  }
}

/* ==== HERO ==== */
.hero {
  padding: 3.2rem 0 2.5rem;
}

.hero-inner {
  display: grid;
  gap: 2rem;
  align-items: center;
}

@media (min-width: 900px) {
  .hero-inner {
    grid-template-columns: minmax(0, 2fr) minmax(0, 1.4fr);
  }
}

.hero-kicker-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 0.4rem;
}

.hero-kicker {
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-primary-dark);
  margin: 0;
}

.hero-badges {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.badge-logo {
  height: 40px;
  width: auto;
  display: block;
}

.hero h1 {
  font-size: clamp(2.2rem, 4vw, 2.8rem);
  letter-spacing: -0.05em;
  margin: 0 0 0.35rem;
}

.hero-subtitle {
  font-size: 1rem;
  color: var(--color-text);
  margin: 0 0 0.9rem;
}

.hero-subtitle a {
  color: var(--color-primary-dark);
}

.hero-subtitle a:hover,
.hero-subtitle a:focus-visible {
  color: var(--color-primary);
}

.hero-lead {
  font-size: 0.9rem;
  color: #4b5563;
  max-width: 40rem;
  margin-bottom: 1.1rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  margin-bottom: 1.3rem;
}

/* External profiles in hero */
.hero-external {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.hero-external-label {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-right: 0.2rem;
}

.hero-ext-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary-dark);
}

.hero-ext-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  transition: color 0.2s ease, transform 0.2s ease;
}

/* Hover: icons become gray */
.hero-ext-link:hover,
.hero-ext-link:focus-visible {
  color: #6b7280; /* gray */
}

.hero-ext-link:hover .hero-ext-icon,
.hero-ext-link:focus-visible .hero-ext-icon {
  transform: translateY(-1px);
}

.hero-ext-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary-dark);
}

.hero-ext-link:hover,
.hero-ext-link:focus-visible {
  color: #6b7280;
}

/* Tooltip text */
.hero-ext-link::after {
  content: attr(data-label);
  position: absolute;
  bottom: -28px;
  opacity: 0;
  background: #111827;
  color: #fff;
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 4px;
  white-space: nowrap;
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
  transform: translateY(4px);
}

/* Show tooltip */
.hero-ext-link:hover::after,
.hero-ext-link:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}


/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font-size: 0.9rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease,
    box-shadow 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
}

.btn.primary {
  background: linear-gradient(135deg, #2563eb, #4f46e5);
  color: #f9fafb;
  box-shadow: var(--shadow-soft);
}

.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 35px rgba(37, 99, 235, 0.25);
}

.btn.secondary {
  background-color: var(--color-surface);
  color: var(--color-text);
  border-color: #cbd5f5;
}

.btn.secondary:hover {
  background-color: #e5edff;
}

/* Hero metrics (grayscale background) */
.hero-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
  padding: 0.55rem 0.8rem;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border: 1px solid rgba(148, 163, 184, 0.35);
  max-width: 24rem;
}

.hero-metrics dt {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.13em;
  color: var(--color-text-muted);
}

.hero-metrics dd {
  margin: 0.15rem 0 0;
  font-weight: 600;
  font-size: 0.95rem;
}

.hero-metrics .metric-source {
  grid-column: 1 / -1;              /* makes it span full width */
  text-align: right;                 /* or left / center if you prefer */
  font-size: 0.6rem;
  color: var(--color-text-muted);
  margin-top: -10px;
  margin-bottom: -10px;
  opacity: 0.85;
}

/* Hero photo */
.hero-photo {
  justify-self: center;
}

.hero-photo img {
  width: min(260px, 80vw);
  border-radius: 26px;
  object-fit: cover;
  border: 1px solid rgba(148, 163, 184, 0.6);
  box-shadow: 0 22px 50px rgba(15, 23, 42, 0.35);
}

/* ==== CARDS & LISTS ==== */
.info-card {
  padding: 1.1rem 1.2rem;
  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-soft);
}


.info-card h3 {
  margin-top: 0;
  margin-bottom: 0.6rem;
  font-size: 1.05rem;
}

.info-list {
  list-style: none;
  margin: 0 0 1.1rem;
  padding: 0;
}

.info-list li + li {
  margin-top: 0.25rem;
}

.info-list strong {
  font-weight: 600;
}

/* Make grants & distinctions visibly itemized */
#grants .info-list {
  list-style: disc;
  padding-left: 1.35rem;
  margin-bottom: 1.4rem;
  font-size: 0.90rem;      /* ⬅ smaller text */
}

#grants .info-list li {
  margin-bottom: 0.65rem;  /* ⬅ more spacing between items */
  line-height: 1.45;        /* optional: improves readability */
}



.link-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.link-list li + li {
  margin-top: 0.3rem;
}

/* External profiles icons (sidebar) */
.external-profiles li a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.ext-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--color-primary-soft);
  color: var(--color-primary-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 600;
  flex-shrink: 0;
}

.ext-label {
  font-size: 0.9rem;
}

.tag-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag-list li {
  font-size: 0.85rem;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  background-color: var(--color-primary-soft);
  color: #1d4ed8;
  border: 1px solid rgba(129, 140, 248, 0.55);
}

.card-list {
  display: grid;
  gap: 1rem;
}

.card {
  position: relative;
  background-color: var(--color-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 0.85rem 1rem;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}

.card h4 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

.card-meta {
  margin: 0 0 0.4rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.card-links {
  margin-top: 0.5rem;
  font-size: 0.88rem;
}

/* Project cards with grayscale teaser backgrounds */
.project-card {
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-color: var(--color-border);
  box-shadow: var(--shadow-soft);
}

.project-card .card-layout {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 1rem;
  align-items: stretch;
}

.project-card .card-text {
  flex: 1 1 auto;
}

/*.card-teaser {
  flex: 0 0 140px;
  display: flex;
  align-items: center;
  justify-content: center;
}*/

.card-teaser {
  flex: 0 0 140px;
  display: flex;
  align-items: flex-start;    /* forces image to top */
  justify-content: center;
}

.card-teaser img {
  max-width: 140px;
  max-height: 140px;
  width: 100%;
  height: auto;
  object-fit: contain;    /* fit inside box, preserve aspect */
  border-radius: var(--radius-md);
}

/* Make Research projects 100% width like Databases */
.full-width-projects {
  margin-top: 1rem;
  width: 100%;
  display: block;       /* ensures it spans container width */
}


/* ==== DATABASE CARDS (more compact) ==== */
.db-list {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;              /* smaller vertical gap between cards */
}

.db-card {
  position: relative;
  display: flex;
  gap: 0.7rem;               /* tighter gap between image and text */
  align-items: center;
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-radius: 0.55rem;    /* slightly smaller radius */
  border: 1px solid var(--color-border);
  padding: 0.55rem 0.7rem;   /* less padding = more compact */
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.db-thumb {
  flex: 0 0 130px;           /* was 200px */
  display: flex;
  align-items: center;
  justify-content: center;
}

.db-thumb img {
  max-width: 130px;          /* was 200px */
  max-height: 130px;
  width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 10px;
  border: 0;
}

.db-body {
  flex: 1 1 auto;
}

.db-title {
  margin: 0 0 0.1rem;
  font-weight: 600;
  font-size: 0.95rem;        /* slightly smaller */
}

.db-meta {
  margin: 0 0 0.25rem;
  font-size: 0.8rem;         /* smaller */
  color: var(--color-text-muted);
}

.db-description {
  margin: 0 0 0.25rem;
  font-size: 0.76rem;
  line-height: 1.35;
}

.db-links {
  font-size: 0.82rem;
}

/* Make Selected Projects reuse database card look */
.project-list {
  margin-top: 0.5rem;
}

.project-separator {
  margin: 0 0.7rem;
}

/* Base link: slightly smaller, still with arrow */
.arrow-link {
  font-size: 0.78rem;
  position: relative;
  padding-left: 0.9rem;      /* a bit less indentation */
}

/* Symbol before the text */
.arrow-link::before {
  content: "»";
  position: absolute;
  left: 1px;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 600;
  color: #aa2828;
}

/* Hover: lighter blue */
.arrow-link:hover,
.arrow-link:focus-visible {
  color: color-mix(in srgb, var(--color-primary) 70%, white 30%);
}

/* Optional: stack vertically on very small screens */
@media (max-width: 900px) {
  .db-card {
    flex-direction: column;
    align-items: flex-start;
  }

  .db-thumb {
    flex: 0 0 auto;
    width: 100%;
    max-width: 180px;
  }
}




/* ==== PUBLICATIONS ==== */
.pub-filters,
.project-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.5rem;
}

/* Shared button appearance */
.pub-filter-btn,
.project-filter-btn {
  padding: 0.25rem 0.9rem;
  border-radius: 999px;
  border: 1px solid #d1d5db;
  background-color: #f9fafb;
  font-size: 0.85rem;
  cursor: pointer;
}

/* Independent active states */
.pub-filter-btn.active,
.project-filter-btn.active {
  background-color: #2563eb;
  color: #f9fafb;
  border-color: #1d4ed8;
}


.pub-list {
  list-style: none;       /* no numbering */
  margin: 0;
  padding-left: 0;        /* remove left indent */
}

.pub-item {
  margin-bottom: 0.7rem;
}

.pub-card {
  position: relative;
  display: flex;
  gap: 0.7rem;
  align-items: center;  /* center thumb and text vertically */
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 0.9rem 1rem;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.pub-thumb {
  flex: 0 0 240px;
  display: flex;
  flex-direction: column;    /* stack GIF and badges vertically */
  align-items: center;
  justify-content: center;
  min-height: 140px; /* Minimum height for consistency */
}


.pub-thumb .pub-badges {
    display: flex;
    justify-content: center;
    gap: 1.2rem;
    margin-top: 0.6rem;
}

.pub-thumb img {
  max-width: 240px;
  max-height: 240px;
  width: 100%;
  height: auto;
  object-fit: contain;   /* no distortion */
  border-radius: 12px;
  border: 1px solid var(--color-border);
}

.pub-badges img{
  border: none;
  border-radius: 0; /* remove rounding */
  box-shadow: none; /* optional: ensure no shadow */
}

.pub-body {
  flex: 1 1 auto;
  min-width: 0; /* Important for text truncation on small screens */
}

.pub-title {
  font-weight: 600;
  margin: 0 0 0.1rem;
  font-size: 1rem;
}

.pub-authors {
  margin: 0;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  font-style: italic;          /* authors in italics */
}

.pub-meta {
  margin: 0.15rem 0 0.15rem;
  font-size: 0.85rem;
  color: color-mix(in srgb, var(--color-primary-dark) 60%, black 40%);
}

/* short description for publication */
.pub-description {
  margin: 0 0 0.25rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.pub-links {
  font-size: 0.85rem;
}

.pub-links span {
  margin: 0 0.25rem;
}

/* Publications without images */
.pub-card.no-thumb {
  align-items: flex-start;
}

.pub-card.no-thumb .pub-body {
  flex: 1 1 100%;
  padding-left: 0;
}

/* Remove the gap when there's no thumbnail */
.pub-card.no-thumb {
  gap: 0;
}

/* Optional: Adjust padding for better spacing without images */
.pub-card.no-thumb {
  padding: 1rem 1.2rem;
}

/* Mobile screens (max-width: 768px) */
@media (max-width: 900px) {
  .pub-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
  }
  
  .pub-thumb {
    flex: 0 0 auto;
    width: 100%;
    max-width: 220px; 
    margin: 0;
  }
  
  .pub-thumb img {
    max-width: 100%;
    max-height: 200px;
    width: 100%;
  }
  
  .pub-body {
    width: 100%;
    text-align: flex-start; 
  }
  
  .pub-title {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }
  
  .pub-authors {
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
  }
  
  .pub-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.5rem;
  }
  
  /*
  .pub-links span {
    display: none; /* Hide the separator dots */
  /*}*/
}

/* ==== TEACHING / COURSES – CARDS ==== */

.course-card {
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 0.8rem 0.95rem;
  box-shadow: var(--shadow-soft);
}

.course-card + .course-card {
  margin-top: 0.6rem;
}

.course-title {
  margin: 0 0 0.25rem;
  font-weight: 600;
  font-size: 0.98rem;
}

.course-meta {
  margin: 0 0 0.4rem;
  font-size: 0.78rem;
  color: var(--color-text-muted);
}

.course-semester,
.course-level {
  /* separate classes for easier styling */
}

.course-separator {
  margin: 0 0.3rem;
}

.course-description {
  margin: 0;
  font-size: 0.82rem;      /* smaller font, as requested */
  color: var(--color-text);
}

.course-links {
  margin-top: 0.45rem;
  font-size: 0.82rem;
}

/* Past courses: more compact version of course-card */

.past-course-list .course-card {
  padding: 0.6rem 0.8rem;
}

.past-course-list .course-title {
  font-size: 0.9rem;
}

.past-course-list .course-meta {
  font-size: 0.75rem;
}

/* Dissertation / Thesis topic cards */

.dissertation-block {
  margin-top: 2.2rem;
}

.topic-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.9rem;
}

.topic-card {
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 0.85rem 1rem;
  box-shadow: var(--shadow-soft);
}

.topic-title {
  margin: 0 0 0.25rem;
  font-size: 0.98rem;
  font-weight: 600;
}

.topic-description,
.topic-meta {
  margin: 0 0 0.3rem;
  font-size: 0.82rem;
  color: var(--color-text);
}

.topic-links {
  margin-top: 0.2rem;
  font-size: 0.82rem;
}

/* ===== CURRENT COURSES — with bounding box ===== */

/* ========================== */
/* NO BOX — PAST COURSES      */
/* ========================== */

.past-course-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.past-course-list li {
  margin-bottom: 0.6rem;
}

.past-course-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.past-course-meta {
  font-size: 0.8rem;
  color: #666;
  margin: 0.15rem 0 0;
}

/* =============================== */
/* NO BOX — DISSERTATION TOPICS    */
/* =============================== */

.topic-list-plain {
  list-style: none;
  padding: 0;
  margin-top: 1rem;
}

.topic-list-plain li {
  margin-bottom: 1rem;
}

.topic-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
}

.topic-description,
.topic-meta {
  margin: 0.1rem 0;
  font-size: 0.85rem;
  color: #555;
}

.topic-email-link {
  font-size: 0.85rem;
  text-decoration: none;
  font-weight: 600;
}
.topic-email-link:hover { text-decoration: underline; }

/* === Teaching lists (remove bullets from current courses) === */
.course-list {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
}

.course-list li + li {
  margin-top: 0.7rem;
}


/* ==== PERSON CARDS (Students & Alumni) ==== */
.person-list {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.person-card {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  /*background-color: var(--color-surface);*/
  background: radial-gradient(circle at top left, #f9fafb, #e5e7eb);
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  padding: 0.55rem 0.75rem;
  /*box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);*/
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.person-photo {
  flex: 0 0 64px; 
}

.person-photo img {
  width: 64px;
  height: 64px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid var(--color-border);
}

.person-body {
  flex: 1 1 auto;
}

.person-name {
  margin: 0 0 0.1rem;
  font-weight: 600;
}

.person-role {
  margin: 0;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.person-links {
  margin-top: 0.25rem;
  display: flex;
  gap: 0.35rem;
}

.person-link {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background-color: #e5e7eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary-dark); /* blue like Academic Profile */
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}

.person-link:hover,
.person-link:focus-visible {
  background-color: #d4d4d8;
  color: #6b7280;               /* gray on hover */
  transform: translateY(-1px);
}

.person-icon {
  width: 16px;
  height: 16px;
}

/* Optional: two-column layout for students on wider screens */

@media (min-width: 900px) {
  #students .person-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* === Alumni role separation on student cards === */
.person-role-main {
  font-weight: 500;
}

.person-role-separator {
  margin: 0 0.3rem;
  color: var(--color-text-muted);
}

.person-role-detail {
  color: var(--color-text-muted);
  font-size: 0.8rem;
}

/* === Service lists (editorial boards & committees) === */
.service-list {
  list-style: none;            /* override bullets for these lists */
  padding-left: 0;
  margin-bottom: 1.4rem;
  font-size: 0.9rem;
}

.service-item {
  margin-bottom: 0.35rem;
}

.service-venue {
  font-weight: 600;
}

.service-separator {
  margin: 0 0.35rem;
  color: var(--color-text-muted);
}

.service-role,
.service-years,
.service-meta {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.service-years {
  margin-left: 0.25rem;
}

/* ==== CONTACT ==== */
.contact-card {
  /* bounding box removed, layout only */
  background-color: transparent;
  border-radius: 0;
  border: none;
  box-shadow: none;
  padding: 0;
}

.contact-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 900px) {
  .contact-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.contact-details h3,
.contact-map h3 {
  margin-top: 0;
  margin-bottom: 0.6rem;
}

/* Map half of the division frame */
.contact-map {
  display: flex;
  flex-direction: column;
}

.map-embed {
  flex: 1 1 auto;
  min-height: 260px;
}

.map-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
}

/* ==== FOOTER ==== */
.site-footer {
  border-top: 1px solid #e5e7eb;
  padding: 1.1rem 0 1.5rem;
  background-color: #f9fafb;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.9rem;
  color: var(--color-text-muted);
}

/* Footer links inherit global styling */
.footer-meta a {
  text-decoration: none;
}

/* ==== RESPONSIVE TWEAKS ==== */
@media (max-width: 900px) {
  .project-card .card-layout {
    flex-direction: column;
  }

  .card-teaser {
    flex: 1 1 auto;
    justify-content: flex-start;
  }

  .pub-card,
  .db-card {
    align-items: flex-start;
  }

  .hero-actions {
    align-items: flex-start;
  }
}

@media (max-width: 900px) {
  .hero {
    padding-top: 2.6rem;
  }

  .hero-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding-inline: 0.75rem;
  }

  .section {
    padding: 2.4rem 0;
  }

  .info-card {
    padding: 1rem 1.05rem;
  }

  .person-card {
    padding: 0.6rem 0.8rem;
  }
}


/* Logo Container */
.lab-logo {
  margin-top: 1rem;
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 15px 0;
}

.lab-logo img {
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

/* mobile */
@media (max-width: 900px) {
  .lab-logo img {
    max-width: 100%;
	height: auto;
  }
}


/* === COMPACT OVERRIDES === */
body {
  font-size: 15px;
  line-height: 1.5;
}
