/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
  }
  
  /* Header Styles */
  header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #333;
    padding: 1rem 2rem;
    color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
  }
  
  .logo {
    font-size: 1.5rem;
  }
  
  .nav-links {
    display: flex;
    gap: 1rem;
  }
  
  .nav-links a {
    color: white;
    text-decoration: none;
    padding: 0.5rem;
  }
  
  .menu-toggle {
    display: none;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
  }
  
  /* Hero Section */
  .hero {
    padding: 4rem 2rem;
    background: #f4f4f4;
    text-align: center;
  }
  
  /* Footer */
  footer {
    text-align: center;
    padding: 1rem;
    background: #222;
    color: white;
  }
  
  /* Responsive Styles */
  @media (max-width: 768px) {
    .nav-links {
      display: none;
      flex-direction: column;
      background: #333;
      position: absolute;
      top: 60px;
      right: 0;
      width: 100%;
    }
  
    .nav-links.active {
      display: flex;
    }
  
    .menu-toggle {
      display: block;
    }
  }

    .intro-section {
        display: flex;
        gap: 5rem;           /* current gap between left and right columns */
        padding: 2rem 0;     /* reduce vertical padding to not double up */
        flex-wrap: wrap;
        justify-content: center; /* centers columns inside the flex container */
      }
  
  /* Left column stacks photo and icons vertically */
  .left-column {
    display: flex;
    flex-direction: column;
    align-items: center;  /* center photo and icons horizontally */
    gap: 1.5rem;
    flex-shrink: 0;       /* prevent shrinking */
    max-width: 320px;     /* optional max width */
    width: 100%;
  }
  
  /* Photo sizing */
  .intro-photo {
    width: 100%;
    max-width: 300px;   /* Keeps it from growing too large */
    height: auto;       /* Maintain aspect ratio */
    border-radius: 8px;
    object-fit: cover;
    display: block;
  }
  
  
  
  
  /* Icons row */
  .icon-links {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
  }
  
  /* Individual icon link container */
  .icon-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    transition: transform 0.2s;
  }
  
  .icon-link:hover {
    transform: translateY(-2px);
  }
  
  /* Icons size and hover */
  .icon-links a img {
    width: 24px;  /* smaller width */
    height: 24px; /* smaller height */
    cursor: pointer;
    transition: transform 0.2s;
  }
  
  /* Icon labels */
  .icon-label {
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
  }
  
  .icon-link:hover .icon-label {
    color: #374151;
  }
  
  .icon-links a img:hover {
    transform: scale(1.2);
  }
  
  /* Right column: intro text takes remaining space */
  .intro-text {
    flex: 1;  /* take remaining width */
    min-width: 0; /* prevent overflow */
  }
  
  /* Responsive for smaller screens */
  @media (max-width: 768px) {
    .intro-section {
      flex-direction: column;
      align-items: center;
      text-align: center;
    }
    
    .left-column {
      max-width: 250px;
    }
  
    .icon-links {
      justify-content: center;
    }
  }
  
  /* Container for both intro and additional sections on the right */
.right-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2rem; /* spacing between intro and additional text */
    min-width: 0;
  }
  
  /* Additional text section */
  .additional-text {
    width: 100%;
  }
  
  /* Make images inside additional text responsive */
  .additional-text img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px; /* Optional: rounded corners */
    margin-top: 1rem;   /* Space from preceding text */
  }
  
  /* Mobile adjustments */
  @media (max-width: 768px) {
    .right-column {
      align-items: center;
      text-align: center;
    }
  
    .additional-text img {
      max-width: 100%; /* Ensures image doesn't overflow on small screens */
    }
  }
  
  .highlight-quote {
    background-color: #f5f5f5;     /* light gray background, adjust as needed */
    padding: 1em;
    margin: 1em 0;
    border-left: 4px solid #0077cc;  /* optional: colored side bar for style */
    border-radius: 6px;
    font-style: italic;
    font-size: 1rem;
    line-height: 1.5;
  }

  /* for timeline viz*/

  .timeline-container {
    max-width: 400px; /* or whatever fits your layout */
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
  }
  
  .timeline-header {
    background-color: #f5faff; /* subtle different background */
    padding: 1rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  }
  
  .timeline-title {
    margin: 0;
    font-size: 1.4rem;
    color: #004080;
  }
  
  .timeline-description {
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: #555;
  }
  
  .timeline-vertical-wrapper {
    max-height: 400px;          /* fixed height for scroll */
    overflow-y: auto;           /* vertical scroll only */
    padding: 1rem 1.5rem;
    border-left: 2px solid #ccc;
  }
  
  /* rest of timeline styles same as before */
  .timeline-vertical {
    display: flex;
    flex-direction: column;
    gap: 2rem;
  }
  
  .timeline-item {
    position: relative;
    padding-left: 1.5rem;
  }
  
  .circle {
    position: absolute;
    left: -10px;
    top: 4px;
    width: 12px;
    height: 12px;
    background-color: #0077cc;
    border-radius: 50%;
    border: 2px solid white;
  }
  
  .timeline-label {
    margin: 0;
    font-size: 0.95rem;
  }
  
  .timeline-label span {
    color: #555;
    font-size: 0.85rem;
  }
  
  .timeline-icon {
    display: block;
    margin-top: 0.5rem;
    max-width: 60px;
    height: auto;
    border-radius: 4px;
  }
  

  @media (max-width: 768px) {
    .timeline-vertical-wrapper {
      max-height: 300px;
    }
  }
  
  /* Wrapper container for intro section to limit width and add side padding */
.intro-container {
    max-width: 1400px;   /* controls max width of the whole block */
    margin: 0 auto;      /* center horizontally */
    padding: 0 2rem;     /* side padding to add space from edges */
  }

  /* For the research page */
/* Enhanced Control Panel Style */
#filter-panel {
    display: flex;
    align-items: flex-end;
    gap: 1rem;
    background-color: #f9f9f9;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    margin-bottom: 0;
    flex-wrap: nowrap;
    overflow-x: auto; /* Allows scrolling if the screen is too narrow */
  }
  
  
  .filter-group {
    display: flex;
    flex-direction: column;
    flex: 1 1 200px;
    min-width: 180px;
  }
  
  .filter-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    font-size: 0.95rem;
  }
  
  .filter-group select,
  .filter-group input[type="text"] {
    padding: 10px 12px;
    font-size: 0.95rem;
    border: 1px solid #ccc;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.2s ease;
  }
  
  .filter-group select:focus,
  .filter-group input[type="text"]:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
  }
  
  .filter-group input[type="text"]::placeholder {
    color: #aaa;
  }


  @media (max-width: 480px) {
    .control-panel {
      flex-direction: column;
      gap: 0.5rem; /* smaller gap */
      padding: 0.5rem;
    }
  
    .control-panel > * {
      flex: 1 1 auto; /* full width */
      margin: 0;      /* remove extra margin */
    }
  
    input[type="text"],
    select {
      font-size: 0.9rem;
      padding: 0.4rem 0.6rem;
    }
  
    button {
      font-size: 1rem;
      padding: 0.5rem;
    }
  }
  

  .submit-button {
    padding: 10px 20px;
    font-size: 0.95rem;
    background-color: #3b82f6;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease;
  }
  
  .submit-button:hover {
    background-color: #2563eb;
  }
  
  .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1rem;
  }
  
  /* Year heading styles */
  .year-heading {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 2rem;
    margin-top: 0;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #3b82f6;
    display: inline-block;
    position: relative;
  }

  .year-heading::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6 0%, #60a5fa 100%);
    border-radius: 2px;
  }

  #research-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    justify-items: center; /* optional: center cards in each cell */
  }
  
  
  .research-card {
    display: flex;
    flex-direction: column;
    background-color: white;
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    text-decoration: none;
    color: inherit;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }
  
  .research-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
  }
  
  .research-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
  }
  
  .card-content {
    padding: 1rem;
  }
  
  .project-description {
    font-size: 0.95rem;
    margin-bottom: 0.75rem;
    line-height: 1.4;
  }
  
  .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  
  .tag {
    background-color: #e5e7eb;
    padding: 0.3rem 0.6rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    color: #374151;
  }

  .research-card {
    cursor: pointer;
  }
  
  @media (max-width: 1000px) {
    #research-grid {
      grid-template-columns: repeat(2, 1fr);
    }
  }
  
  @media (max-width: 600px) {
    #research-grid {
      grid-template-columns: 1fr;
    }
  }
  
  .project-title {
    margin-top: 0.5rem;  /* space above the title */
    margin-bottom: 1rem; /* space below title before paragraph */
    font-size: 1.2rem;
    font-weight: 600;
    color: #222;  /* adjust color to fit your theme */
    text-align: center;
  }

  /* News Section Styles */
  .news-section {
    margin-bottom: 2rem;
  }

  .news-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #eee;
  }

  .news-item:last-child {
    border-bottom: none;
  }

  .news-date {
    flex-shrink: 0;
    font-weight: 600;
    color: #3b82f6;
    font-size: 0.9rem;
    min-width: 80px;
  }

  .news-content {
    flex: 1;
    line-height: 1.5;
    font-size: 0.95rem;
  }

  /* Featured Publications Styles */
  .additional-text h1:nth-of-type(2) {
    margin-top: 3rem;
  }

  .featured-publications {
    margin-bottom: 2rem;
  }

  .pub-item {
    display: flex;
    gap: 1.5rem;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .pub-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  }

  .pub-image {
    flex-shrink: 0;
    width: 120px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
  }

  .pub-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .pub-content h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.3;
  }

  .pub-content p {
    margin: 0.25rem 0;
    font-size: 0.9rem;
    color: #6b7280;
    line-height: 1.4;
  }

  /* Skills Section Styles */
  .skills-section {
    margin-bottom: 2rem;
  }

  .skill-category {
    margin-bottom: 1.5rem;
  }

  .skill-category h3 {
    margin: 0 0 0.75rem 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #374151;
  }

  .skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .skill-tag {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .skill-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
  }

  /* Responsive adjustments for new sections */
  @media (max-width: 768px) {
    .news-item {
      flex-direction: column;
      gap: 0.5rem;
    }

    .news-date {
      min-width: auto;
    }

    .pub-item {
      flex-direction: column;
      text-align: center;
    }

    .pub-image {
      width: 100%;
      height: 160px;
      align-self: center;
    }

    .skill-tags {
      justify-content: center;
    }
  }

  #partners-list {
    display: grid;
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
  }
  
  .page-header {
    text-align: center;
    margin-bottom: 48px;
    padding: 32px 0;
  }
  
  .page-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 16px 0;
    letter-spacing: -0.025em;
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .page-description {
    font-size: 1.1rem;
    color: #64748b;
    margin: 0;
    line-height: 1.6;
    max-width: 1000px;
    margin: 0 auto;
    white-space: nowrap;
  }
  
  /* 卡片容器：左图右文 */
  .person-card {
    display: flex;
    gap: 20px;
    padding: 24px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 
      0 4px 6px -1px rgba(226, 232, 240, 0.8),
      0 2px 4px -1px rgba(0, 0, 0, 0.06);
    text-decoration: none;
    color: inherit;
    align-items: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
  }
  
  .person-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 0px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #06b6d4);
    opacity: 0;
    transition: opacity 0.3s ease;
  }
  
  .person-card:hover {
    transform: translateY(-4px);
    box-shadow: 
      0 20px 25px -5px rgb(252, 251, 251),
      0 10px 10px -5px rgb(252, 251, 251);
    border-color: rgba(59, 130, 246, 0.2);
  }
  
  .person-card:hover::before {
    opacity: 1;
  }
  
  /* 头像：默认方圆角；移动端变圆形 */
  .person-avatar-container {
    position: relative;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .person-avatar {
    width: 120px;
    height: auto;
    object-fit: contain;
    border-radius: 16px;
    background: none;
    display: block;
  }
  
  .person-card:hover .person-avatar {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgb(255, 254, 254);
  }
  
  /* 文本区域 */
  .person-body {
    flex: 1 1 auto;
    min-width: 0; /* 避免溢出 */
  }
  
  .person-head {
    margin-bottom: 12px;
  }
  
  .person-name {
    margin: 0 0 4px 0;
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.3;
    color: #1e293b;
    letter-spacing: -0.025em;
  }
  
  .person-affil {
    opacity: 0.8;
    font-size: 0.95rem;
    color: #64748b;
    font-weight: 500;
  }
  
  .person-intro {
    margin: 16px 0 20px 0;
    line-height: 1.6;
    color: #475569;
    font-size: 0.95rem;
  }
  
  /* 标签沿用你站点的 .tag，如果没有可用以下兜底 */
  .person-meta .tag {
    display: inline-block;
    font-size: .75rem;
    padding: .2rem .5rem;
    border-radius: 999px;
    background: #eef2ff;
    color: #3843d0;
    margin-right: .35rem;
    margin-bottom: .35rem;
  }
  
  .person-links {
    margin-top: 16px;
    display: flex; 
    gap: 12px; 
    flex-wrap: wrap;
  }
  
  .person-links a { 
    color: #3b82f6; 
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 8px 16px;
    border-radius: 8px;
    background: rgba(59, 130, 246, 0.1);
    transition: all 0.2s ease;
    border: 1px solid transparent;
  }
  
  .person-links a:hover {
    background: rgba(59, 130, 246, 0.15);
    color: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
  }
  
  /* 响应式：窄屏时上下排版，头像改圆形且居中 */
  @media (max-width: 720px) {
    .page-header {
      margin-bottom: 32px;
      padding: 24px 0;
    }
    
    .page-title {
      font-size: 2rem;
    }
    
    .page-description {
      font-size: 1rem;
      padding: 0 16px;
    }
    
    .person-card {
      flex-direction: column;
      align-items: center;
      text-align: center;
      padding: 20px;
      gap: 16px;
    }
    
    .person-avatar-container {
      flex: none;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    
    .person-avatar {
      width: 100px;
      height: 100px;
      border-radius: 50%;
    }
    
    .person-links { 
      justify-content: center; 
      gap: 8px;
    }
    
    .person-links a {
      padding: 6px 12px;
      font-size: 0.85rem;
    }
    
    .person-name {
      font-size: 1.15rem;
    }
    
    .person-intro {
      margin: 12px 0 16px 0;
    }
  }

  .person-card .person-head,
.person-card header.person-head {
  background: transparent !important;
  box-shadow: none !important;
  padding: 0;               /* 需要间距就改成 8px 或 12px */
  margin: 0 0 12px;
}

/* 万一是伪元素画的背景，也一并清掉 */
.person-card .person-head::before,
.person-card .person-head::after {
  content: none !important;
  background: transparent !important;
  box-shadow: none !important;
}