* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "微软雅黑 Light", "Microsoft YaHei", sans-serif;
  background-color: #b6e7db;
  line-height: 1.5;
  min-height: 100vh;
}

/* 导航栏响应式设计 */
.nav-container {
  width: 100%;
  padding: 10px 20px;
  box-sizing: border-box;
  position: relative;
}

nav {
  background-color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  border: 1px solid #eee;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  padding: 8px 0;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  font-family: 'Segoe UI', sans-serif;
}

nav a {
  color: #007bff;
  padding: 12px 20px;
  text-decoration: none;
  border-radius: 5px;
  transition: background-color 0.2s, color 0.2s;
  white-space: nowrap;
  margin: 2px;
}

nav a:hover {
  background-color: #f2f2f2;
  color: #0056b3;
}

/* 主要内容区域 */
header {
  width: 100%;
  max-width: 1200px;
  margin: 20px auto;
  padding: 0 20px;
  box-sizing: border-box;
}

header h2 {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 20px;
  position: relative;
  min-height: 300px;
}

/* 图片容器和图片优化 */
.top_img {
  width: 200px;
  height: 200px;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  background-color: #fff;
  padding: 6px;
  flex-shrink: 0;
  transition: all 0.3s ease;
  /* 确保图片不会变形 */
  object-position: center;
  /* 添加边框效果 */
  border: 2px solid #fff;
}

/* 右侧内容区域 */
.top_right {
  flex: 1;
  background-color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  padding: 16px;
  font-family: 'Segoe UI', sans-serif;
  min-width: 0; /* 允许flex项目收缩 */
}

.top_right table {
  width: 100%;
  border-collapse: collapse;
}

.top_right th {
  text-align: center;
  font-size: 18px;
  padding-bottom: 12px;
  color: #333;
}

.top_right td {
  padding: 8px 0;
}

.top_right a {
  text-decoration: none;
  color: #007bff;
  font-size: 15px;
  transition: color 0.2s;
  display: block;
  padding: 4px 0;
}

.top_right a:hover {
  color: #0056b3;
}

/* 主要内容容器 */
#app {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  box-sizing: border-box;
}

/* 个人介绍区域 */
.profile-section {
  margin-bottom: 40px;
}

.profile-card {
  background: #fff;
  border-radius: 15px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  padding: 30px;
  overflow: hidden;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-bottom: 30px;
}

.profile-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #007bff;
  box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.profile-info h1 {
  font-size: 2.5em;
  color: #333;
  margin-bottom: 8px;
}

.profile-title {
  font-size: 1.2em;
  color: #007bff;
  margin-bottom: 12px;
  font-weight: 500;
}

.profile-bio {
  font-size: 1.1em;
  color: #666;
  line-height: 1.6;
  max-width: 500px;
}

.profile-stats {
  display: flex;
  justify-content: space-around;
  padding-top: 25px;
  border-top: 1px solid #eee;
}

.stat-item {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2em;
  font-weight: bold;
  color: #007bff;
  margin-bottom: 5px;
}

.stat-label {
  font-size: 0.9em;
  color: #666;
}

/* 技能展示区域 */
.skills-section {
  margin-bottom: 40px;
}

.skills-section h2 {
  font-size: 2em;
  color: #333;
  text-align: center;
  margin-bottom: 30px;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
}

.skill-category {
  background: #fff;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.skill-category h3 {
  font-size: 1.3em;
  color: #333;
  margin-bottom: 15px;
  text-align: center;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-tag {
  background: #e3f2fd;
  color: #1976d2;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: 500;
  transition: all 0.2s;
}

.skill-tag:hover {
  background: #007bff;
  color: #fff;
  transform: translateY(-2px);
}

/* 联系方式区域 */
.contact-section {
  margin-bottom: 40px;
}

.contact-section h2 {
  font-size: 2em;
  color: #333;
  text-align: center;
  margin-bottom: 30px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.contact-item {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  gap: 15px;
  transition: transform 0.2s;
}

.contact-item:hover {
  transform: translateY(-5px);
}

.contact-icon {
  font-size: 2em;
  width: 50px;
  text-align: center;
}

.contact-info h4 {
  font-size: 1.1em;
  color: #333;
  margin-bottom: 5px;
}

.contact-info p {
  color: #666;
  font-size: 0.9em;
}

.contact-link {
  color: #007bff;
  text-decoration: none;
  font-size: 0.9em;
  word-break: break-all;
  display: inline-block;
  max-width: 100%;
  transition: color 0.2s;
}

.contact-link:hover {
  color: #0056b3;
  text-decoration: underline;
}

/* 最新动态区域 */
.updates-section {
  margin-bottom: 40px;
}

.updates-section h2 {
  font-size: 2em;
  color: #333;
  text-align: center;
  margin-bottom: 30px;
}

.updates-list {
  background: #fff;
  border-radius: 12px;
  padding: 25px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.update-item {
  display: flex;
  gap: 20px;
  padding: 15px 0;
  border-bottom: 1px solid #eee;
}

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

.update-date {
  color: #007bff;
  font-weight: 500;
  font-size: 0.9em;
  min-width: 100px;
}

.update-content h4 {
  color: #333;
  margin-bottom: 5px;
  font-size: 1.1em;
}

.update-content p {
  color: #666;
  font-size: 0.9em;
  line-height: 1.5;
}

/* 文本内容区域 */
.text {
  font-family: 楷体, serif;
  color: black;
  background-color: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  padding: 20px;
  margin: 20px auto;
  width: 100%;
  max-width: 1200px;
  box-sizing: border-box;
}

/* 页脚 */
footer {
  text-align: center;
  font-size: 14px;
  margin: 40px 0 20px 0;
  color: #666;
  padding: 0 20px;
}

/* 移动端适配 */
@media (max-width: 768px) {
  .nav-container {
    padding: 10px;
  }
  
  nav {
    flex-direction: column;
    padding: 10px;
  }
  
  nav a {
    width: 100%;
    text-align: center;
    margin: 2px 0;
  }
  
  header {
    padding: 0 10px;
  }
  
  header h2 {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 15px;
    min-height: auto;
  }
  
  /* 移动端图片优化 */
  .top_img {
    width: 150px;
    height: 150px;
    padding: 4px;
    border-width: 1px;
  }
  
  .top_right {
    width: 100%;
    max-width: 400px;
  }
  
  .top_right th {
    font-size: 16px;
  }
  
  .top_right a {
    font-size: 14px;
  }
  
  /* 新home页面移动端适配 */
  #app {
    padding: 15px;
  }
  
  .profile-header {
    flex-direction: column;
    text-align: center;
    gap: 20px;
  }
  
  .profile-avatar {
    width: 100px;
    height: 100px;
  }
  
  .profile-info h1 {
    font-size: 2em;
  }
  
  .profile-stats {
    flex-direction: column;
    gap: 15px;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .contact-item {
    padding: 15px;
  }
  
  .update-item {
    flex-direction: column;
    gap: 10px;
  }
  
  .update-date {
    min-width: auto;
  }
}
  
  .text {
    margin: 20px 10px;
    padding: 15px;
  }
  
  footer {
    padding: 0 10px;
  }


/* 小屏幕手机适配 */
@media (max-width: 480px) {
  .nav-container {
    padding: 5px;
  }
  
  nav {
    padding: 8px;
  }
  
  nav a {
    padding: 10px 15px;
    font-size: 14px;
  }
  
  header {
    padding: 0 5px;
  }
  
  header h2 {
    gap: 10px;
  }
  
  /* 小屏幕图片优化 */
  .top_img {
    width: 120px;
    height: 120px;
    padding: 3px;
    border-width: 1px;
  }
  
  .top_right {
    padding: 12px;
  }
  
  .top_right th {
    font-size: 15px;
  }
  
  .top_right a {
    font-size: 13px;
  }
  
  .text {
    padding: 12px;
    font-size: 14px;
    margin: 15px 5px;
  }
}

/* 中等屏幕适配（平板横屏） */
@media (min-width: 769px) and (max-width: 1024px) {
  header h2 {
    gap: 15px;
  }
  
  .top_img {
    width: 180px;
    height: 180px;
  }
  
  .top_right {
    padding: 14px;
  }
}

/* 大屏幕适配 */
@media (min-width: 1200px) {
  .nav-container {
    padding: 10px 40px;
  }
  
  header {
    padding: 0 40px;
  }
  
  header h2 {
    gap: 25px;
  }
  
  .top_img {
    width: 220px;
    height: 220px;
    padding: 8px;
  }
  
  .text {
    margin: 20px auto;
  }
}

/* 超宽屏幕适配 */
@media (min-width: 1600px) {
  .nav-container {
    padding: 10px 60px;
  }
  
  header {
    padding: 0 60px;
  }
  
  header h2 {
    gap: 30px;
  }
  
  .top_img {
    width: 250px;
    height: 250px;
    padding: 10px;
  }
  
  .top_right {
    padding: 20px;
  }
  
  .top_right th {
    font-size: 20px;
  }
  
  .top_right a {
    font-size: 16px;
  }
}

/* 超小屏幕适配（小手机） */
@media (max-width: 360px) {
  .nav-container {
    padding: 3px;
  }
  
  nav {
    padding: 6px;
  }
  
  nav a {
    padding: 8px 12px;
    font-size: 13px;
  }
  
  header {
    padding: 0 3px;
  }
  
  header h2 {
    gap: 8px;
  }
  
  .top_img {
    width: 100px;
    height: 100px;
    padding: 2px;
  }
  
  .top_right {
    padding: 10px;
  }
  
  .top_right th {
    font-size: 14px;
  }
  
  .top_right a {
    font-size: 12px;
  }
  
  .text {
    padding: 10px;
    font-size: 13px;
    margin: 10px 3px;
  }
}

/* 横屏手机适配 */
@media (max-width: 768px) and (orientation: landscape) {
  header h2 {
    flex-direction: row;
    align-items: flex-start;
    gap: 15px;
  }
  
  .top_img {
    width: 120px;
    height: 120px;
  }
  
  .top_right {
    max-width: none;
  }
}

/* 横屏平板适配 */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
  .top_img {
    width: 160px;
    height: 160px;
  }
}
