/*=========== Material 全局变量 ==========*/
/* 调整 Material 主题左侧目录栏宽度 */
.md-sidebar--primary {
  width: 180px;       /* 左侧导航栏宽度 */
}

.md-sidebar__scrollwrap {
  width: 180px;       /* 同步内部滚动容器宽度 */
}

/* 为了防止内容区域被遮挡，也要调整内容区域的 margin */
.md-main__inner {
  margin-left: 180px;
}

.md-typeset h1 {
  margin-bottom: 0.5em;  /* 原来大约 1.6em，可以改成 0.5em 或 0.8em */
}

/*=========== 自定义布局全局类 ==========*/
.grid-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  row-gap: 20px;
  column-gap: 20px;
}

/*=========== 堆叠卡片 ==========*/
.stack {
  width: 80%;
  /* max-width: 400px; */ 
  transition: 0.25s ease;
  padding: 0;
  &:hover {
    transform: rotate(5deg);
    .nav-card:before {
      transform: translatey(-2%) rotate(-4deg);
    }
    .nav-card:after {
      transform: translatey(2%) rotate(4deg);
    }
  }
}

.stack-card {
  aspect-ratio: 3 / 2;
  border: 2px solid #585858;
  background-color: #fff;
  position: relative;
  transition: 0.15s ease;
  cursor: pointer;
  padding: 5% 5% 15% 5%;
  &:before,
  &:after {
    content: "";
    display: block;
    position: absolute;
    height: 100%;
    width: 100%;
    border: 2px solid #585858;
    background-color: #fff;
    transform-origin: center center;
    z-index: -1;
    transition: 0.15s ease;
    top: 0;
    left: 0;
  }

  &:before {
    transform: translatey(-2%) rotate(-6deg);
  }

  &:after {
    transform: translatey(2%) rotate(6deg);
  }
}

/*=========== 个人介绍卡片 ==========*/
.person-card {
  width: 540px;
  height:300px;
  background: linear-gradient(#f8f8f8, #fff);
  box-shadow: 0 8px 16px -8px rgba(0, 0, 0, 0.4);
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  margin: 1.5rem;
}

.person-card .pc_left {
  position: absolute;
  width: 180px;
  height: 100%;
  background: linear-gradient(#de685e, #ef786e);
  transition: width 0.4s, z-index 0s 0.4s;
  overflow: hidden;
  z-index: 1;
}

.person-card:hover .pc_left {
  width: 100%;
  border-radius: 0 5px 5px 0;
  z-index: 3;
  transition: width 0.4s, z-index 0s 0s;
}

.person-card .pc_left .pc_l_avator {
  width: 180px;
  height: 100%;
  position: relative;
  float: left;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding-top: 1rem;
}

/* 浅色分隔线 */
.person-card .pc_left .pc_l_avator::after {
  content: "";
  position: absolute;
  top: 10%;
  right: -2px;
  height: 80%;
  border-left: 2px solid rgba(0,0,0,0.025);
}

.person-card .pc_left .pc_l_info {
  width: 360px;
  float: left;
  position: absolute;
  left: 180px;
  height: 100%;
}

.person-card .pc_right {
  width: 360px;
  height: 100%;
  position: absolute;
  top: 0;
  right: 0;
  z-index: 2;
  padding: 1rem;
}

.avator {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  position: relative;
  border: 3px solid rgba(255, 255, 255, 0.8);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.3),
    0 4px 8px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.avator:hover {
  transform: scale(1.05);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.5),
    0 6px 12px rgba(0, 0, 0, 0.2);
}

.avator-name {
  color: white;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  letter-spacing: 0.05em;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.pc_l_avator a {
  display: block;
  line-height: 0;
  cursor: pointer;
}

/* 左侧信息样式 */
.person-card .pc_left .pc_l_info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.5rem;
  color: white;
}

.info-university {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.info-name-en {
  font-size: 0.85rem;
  font-weight: 400;
  opacity: 0.9;
  line-height: 1.3;
}

/* 右侧信息样式 */
.person-card .pc_right {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
}

.info-item {
  display: flex;
  align-items: flex-start;
  line-height: 1.6;
}

.info-label {
  font-weight: 600;
  color: #555;
  min-width: 80px;
  flex-shrink: 0;
}

.info-value {
  color: #333;
  flex: 1;
}

/*========== 导航卡片 ==========*/
.nav-container {
  width: 100%;
  max-width: 780px;
  min-height: 160px;
  background-color: #fff;
  border-radius: 4px;
  display: flex;
  overflow: hidden;
  flex-direction: column;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.19), 0 6px 6px rgba(0, 0, 0, 0.23);
}

.navbar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem 0.5rem;
  background-color: #fff;
}

.nav-decoration {
  position: absolute;
  left: 0;
  height: 2rem;
  width: 0;
  background: #119da4;
  border-radius: 2px;
  transition: transform 0.4s ease, width 0.4s ease;
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}

.nav-decoration.is-active {
  opacity: 1;
}

.nav-item {
  height: 2rem;
  cursor: pointer;
  padding: 0.35rem 0.75rem;
  background: transparent;
  border-radius: 2px;
  border: none;
  font-size: 17px;
  color: #333;
  z-index: 2;
}

.nav-item:hover {
  color: #0d7c82;
}

.nav-item.active {
  background: #119da4;
  color: #fff;
  font-weight: 600;
  transition: color 0.4s ease, background-color 0s ease 0.4s;
}

.content-wrapper {
  flex: 1;
  width: 100%;
  background: #fff;
  padding: 0 1rem 0.9rem;
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
}

.content-item {
  display: none;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.content-item.active {
  display: block;
  opacity: 1;
  transform: scale(1);
}

.content-wrapper p {
  margin: 0.35rem 0;
}

.content-wrapper ul {
  margin: 0.35rem 0 0.35rem 1.2rem;
}

/*========== 广告栏卡片 ==========*/
.adv-card {
  width: 450px;
  height: 250px;
  padding: 50px;
  background: var(--md-default-bg-color);
  border: 1px solid var(--md-default-fg-color--lighter, rgba(0, 0, 0, 0.08));
  border-radius: 12px;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.12);
  transform: rotate(-2deg);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}
.adv-card:active {
  animation: shake 0.5s ease-in-out;
}
.adv-card:hover {
  transform: rotate(0deg) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.16);
}
.banner {
  position: absolute;
  top: 3px;
  right: -95px;
  background: var(--md-accent-fg-color);
  color: var(--md-primary-bg-color, #fff);
  padding: 15px;
  width: 350px;
  text-align: center;
  transform: rotate(45deg);
  font-weight: bold;
  font-size: 18px;
  letter-spacing: 2px;
  overflow: hidden;
  transition: background 0.5s ease;
}
.banner-text {
  display: inline-block;
  transition: opacity 0.5s ease, transform 0.5s ease;
  width: 100%;
  position: absolute;
  left: 13%;
  top: 50%;
  transform: translateY(-50%);
}
.banner:hover .banner-text:first-child {
  opacity: 0;
  transform: translateY(-100%);
}
.banner:hover .banner-text:last-child {
  opacity: 1;
  transform: translateY(-40%);
}
.banner-text:last-child {
  opacity: 0;
  transform: translateY(60%);
}
.banner:hover {
  filter: brightness(1.1);
}
.adv-card_title {
  font-size: 24px;
  font-weight: 700;
  color: var(--md-default-fg-color);
  text-transform: uppercase;
  margin-bottom: 10px;
  display: block;
  border-bottom: 2px solid var(--md-primary-fg-color);
  width: 70%;
}
.adv-card_content {
  font-size: 16px;
  line-height: 1.4;
  color: var(--md-default-fg-color--light);
  margin-bottom: 20px;
  padding-bottom: 10px;
}

@keyframes shake {
  0% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  50% {
    transform: translateX(5px);
  }
  75% {
    transform: translateX(-5px);
  }
  100% {
    transform: translateX(0);
  }
}

/*========== 了解更多按钮 ==========*/
.lm-button {
  width: 300px;
  height: 60px;
  padding: 0 25px;
  margin: 1rem auto 0;
  text-align: center;
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 4px;
  text-decoration: none;
  overflow: hidden;
  position: relative;
  transition: all .2s ease-out 0s;
}
.lm-button:hover > span {
  top: -20px;
  opacity: 0;
}
.lm-button:hover > .button-icon {
  opacity: 1;
  top: 50%;
}

.lm-button .lm-button-name {
  color: white;
}

.lm-button-name,
.button-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  -webkit-transform: translate(-50%, -50%);
          transform: translate(-50%, -50%);
  transition: all .3s ease-out;
  position: absolute;
}

.lm-button-name {
  font-size: 1.2rem;
  font-weight: 600;
  opacity: 1;
}

.button-icon {
  opacity: 0;
  width: 2rem;
  height: 1.5rem;
  fill: #fff;
  transition: all 0.3s ease-out;
}

.lm-button-color {
  background-color: #119da4;
}
