/* ===== Reset / Base ===== */
* { box-sizing: border-box; }
body { margin: 0; }

a { color: #b40000; text-decoration: underline; }
a:hover { text-decoration: none; }

/* ===== Page Wrapper ===== */
.page-wrapper {
  width: 100%;
  max-width: none;
  padding: 0 24px;
  margin: 0;
  font-family: Arial, sans-serif;
  line-height: 1.4;
  color: #000;
  font-size: 14px;
}

/* ===== Banner (split images) ===== */
.site-banner{
  width: 100%;
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  background: #fff;
}

/* 左邊文字區：固定高度，不裁切 */
.site-banner .banner-left{
  flex: 1 1 auto;
  height: 160px;
  min-width: 0;
  overflow: hidden;
}

.site-banner .banner-left img{
  width: 100%;
  height: 100%;
  display: block;

  /* ✅ 關鍵：不裁切 */
  object-fit: contain;
  object-position: left top;
  background: #fff;
}

/* 右邊校徽：跟左邊同高度 */
.site-banner .banner-right{
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  background: #fff;
}

.site-banner .banner-right img{
  height: 160px;
  width: auto;
  display: block;
}

@media (max-width: 800px){
  .site-banner .banner-left{ height: 120px; }
  .site-banner .banner-right img{ height: 120px; }
}

/* ===== Layout: sidebar + content ===== */
.main-row{
  display: flex;
  align-items: flex-start;
}

.sidebar{
  width: 200px;
  flex-shrink: 0;
  border-right: 2px solid #b40000;
  padding: 0 16px 24px 10px;
  margin-right: 16px;
}

.sidebar-topspace{ height: 24px; }
.sidebar-gap{ height: 16px; }

.nav-item{ margin-bottom: 16px; }
.nav-item a{
  color: #b40000;
  text-decoration: none;
  font-size: 15px;
  font-weight: bold;
  display: block;
}
.nav-item a:hover{ text-decoration: underline; }

.sidebar-logo-block{
  width: 100%;
  text-align: center;
  margin-bottom: 20px;
}
.sidebar-logo-block img{
  display: inline-block;
  max-width: 95%;
  height: auto;
}
.sidebar-logo-small img{
  width: 45% !important;
  max-width: 90px;
}

.visitor-block{
  text-align: center;
  color: #b40000;
  font-size: 12px;
  border-top: 1px solid #ddd;
  padding-top: 15px;
}

/* ===== Content ===== */
.content{
  flex: 1;
  padding: 24px 0 40px 10px;
  font-size: 14px;
}

.page-name{
  color: #b40000;
  font-size: 24px;
  font-weight: bold;
  margin: 0 0 14px 0;
}

.researchTextcontent{
  text-align: justify;
  margin: 0 0 14px 0;
}

/* Bio page photo */
.bio-photo{
  display: block;
  width: min(520px, 50%);
  height: auto;
  margin: 12px 0 18px 0;
}

/* headings */
.subsubpageName{
  font-size: 18px;
  font-weight: bold;
  margin: 22px 0 8px 0;
  color: #000;
}
.researchName{
  font-weight: bold;
  margin: 16px 0 8px 0;
}

/* images */
.img-center{ text-align: center; margin: 10px 0 18px 0; }
.img-center img{ max-width: 100%; height: auto; display: inline-block; }

/* footer */
.footer-row{
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #666;
  border-top: 1px solid #b40000;
  padding-top: 12px;
  margin-top: 30px;
}

/* Mobile layout */
@media (max-width: 800px){
  .main-row{ flex-direction: column; }
  .sidebar{
    width: auto;
    border-right: 0;
    border-bottom: 2px solid #b40000;
    margin-right: 0;
    padding-bottom: 24px;
  }
  .content{ padding-left: 0; }
}

/* ===== Members page (members.htm) ===== */

.section-title{
  color:#b40000;
  font-size:24px;
  font-weight:bold;
  margin:0 0 20px 0;
}

.section-note{
  font-size:16px;
  margin:0 0 1.5rem 0;
  color:#000;
}

.subheading{
  font-weight:bold;
  font-size:15px;
  color:#000;
  margin:0 0 0.75rem 0;
  border-top:1px solid #b40000;
  padding-top:0.75rem;
}

/* Current members layout (2 columns) */
.members-grid{
  display:flex;
  flex-wrap:wrap;
  gap:2rem;
  max-width:900px;
  margin:0 0 2rem 0;
}
.members-col{
  flex:1 1 360px;
  min-width:300px;
}

/* Alumni layout (3 columns) */
.alumni-grid{
  display:flex;
  flex-wrap:wrap;
  gap:2rem;
  max-width:1200px;
  margin:0 0 2rem 0;
}
.alumni-col{
  flex:1 1 320px;
  min-width:260px;
}

/* Person card */
.member{
  display:flex;
  align-items:flex-start;
  margin:0 0 1.2rem 0;
}
.member img{
  width:75px;
  height:95px;
  object-fit:cover;
  border:1px solid #999;
  margin-right:12px;
  flex-shrink:0;
}
.info{
  font-size:14px;
  color:#000;
  line-height:1.4;
}
.info .name{
  font-weight:bold;
  font-size:15px;
  color:#000;
  margin:0 0 0.4rem 0;
}
.role{ margin:0 0 0.4rem 0; }
.email{ margin:0 0 0.2rem 0; }

/* Mobile tweaks (members cards) */
@media (max-width:800px){
  .members-grid, .alumni-grid{ max-width:none; }
  .member img{ width:68px; height:86px; }
}

/* =========================
   Publications page (legacy -> new look)
   Paste at the END of your main CSS
   ========================= */

/* 1) Make legacy tables behave like your new full-width layout
   (Scoped to Publications page only) */
.page-publications table[width="90%"] {
  width: 100% !important;
  max-width: 1400px;          /* 跟你的 banner max-width 概念一致 */
  margin: 0 auto !important;
}

.page-publications table {
  border-collapse: collapse;
}


/* 2) Banner image consistency */
body img[alt="Header image"] {
  display: block;
  width: 100%;
  height: auto;
}

/* 3) Legacy left nav: match your new sidebar feel */

#navigation .navText {
  padding: 0 !important;
}

#navigation .navText a,
#navigation a.navText {
  display: block;
  color: #b40000;
  text-decoration: none;
  font-size: 15px;
  font-weight: bold;
  margin: 0 0 16px 0;
}

/* add a vertical divider like new sidebar */
#navigation {
  width: 200px;
  border-right: 2px solid #b40000;
  padding: 0 16px 24px 10px;
  box-sizing: border-box;
}


/* visitor counter block */
.webCounter {
  text-align: center;
  color: #b40000;
  font-size: 12px;
  border-top: 1px solid #ddd;
  padding-top: 15px;
}

/* 4) Page title: "Publications" (legacy .pageName) */
.pageName {
  color: #b40000;
  font-size: 24px;
  font-weight: bold;
  padding: 24px 0 12px 10px;
}

/* 5) Intro text area (legacy .bodyText) */
.bodyText {
  font-size: 16px;
  line-height: 1.6;
  padding: 0 0 8px 10px;
}

/* publications year nav links */
.bodyText a {
  color: #b40000;
  text-decoration: underline;
}

/* 6) Year headings (legacy .yeartitle) */
.yeartitle {
  display: inline-block;
  color: #b40000;
  font-size: 18px;
  font-weight: bold;
  margin: 18px 0 10px 0;
  padding-top: 10px;
  border-top: 1px solid #b40000;
}

/* 7) Publication list rows (legacy td.bodyTextcontact) */
.bodyTextcontact {
  font-size: 14px;
  line-height: 1.6;
  color: #000;
  padding: 6px 10px 10px 10px;
  vertical-align: top;
}

/* number column (416, 415...) */
td.bodyTextcontact:first-child {
  width: 56px !important;
  color: #555;
  font-weight: bold;
  text-align: right;
  padding-right: 12px;
  white-space: nowrap;
}

/* journal title underline from old HTML <u>... */
.bodyTextcontact u {
  text-decoration: underline;
}

/* make bold Cai W stand out but not too heavy */
.bodyTextcontact strong {
  font-weight: 700;
}

/* tighten extra empty spacer rows from old tables (Publications only) */
.page-publications table tr td:empty {
  padding: 0 !important;
}


/* 8) Mobile: stack nav and content */
@media (max-width: 800px) {
  #navigation {
    width: auto;
    border-right: 0;
    border-bottom: 2px solid #b40000;
    margin-bottom: 16px;
  }
  .pageName,
  .bodyText,
  .bodyTextcontact {
    padding-left: 0;
  }
}
/* ===== Publications ===== */
.pub-years {
  margin: 0 0 24px 0;
  font-size: 13px;
  line-height: 1.6;
}

.pub-year {
  color: #b40000;
  font-size: 18px;
  font-weight: bold;
  margin: 28px 0 10px 0;
  text-align: center;
}

.pub-list {
  margin-bottom: 22px;
}

.pub-item {
  display: flex;
  gap: 12px;
  margin: 8px 0;
  line-height: 1.6;
}

.pub-num {
  width: 40px;
  flex: 0 0 40px;
  text-align: right;
  font-size: 12px;
  color: #000;
}

.pub-text {
  flex: 1;
  font-size: 13px;
  color: #000;
}

