
/* 全局样式设置 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* 设定主体字体和背景色 */
body {
  font-family: 'Roboto', sans-serif;
  color: #fff;
  background: linear-gradient(135deg, #0D47A1 70%, #616161 25%, #FF9800 5%);
  line-height: 1.6;
  padding-top: 80px; /* 为固定导航栏预留空间 */
}

/* 导航栏样式 */
.navbar {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: rgba(13, 71, 161, 0.9);
  padding: 15px 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.navbar ul {
  display: flex;
  justify-content: center;
  list-style: none;
}

.navbar li {
  margin: 0 20px;
}

.navbar a {
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.navbar a:hover {
  color: #FF9800;
}

/* 标题样式 */
h2, h3, h4 {
  margin-bottom: 20px;
  color: #fff;
}

h2 {
  font-size: 2em;
  font-weight: 700;
}

h3 {
  font-size: 1.5em;
  font-weight: 600;
}

h4 {
  font-size: 1.2em;
  font-weight: 500;
}

/* 段落样式 */
p {
  font-size: 16px;
  margin-bottom: 15px;
}

/* 强调文字 */
strong {
  color: #FF9800;
}

/* 按钮样式 */
.btn-primary {
  background: linear-gradient(45deg, #FF9800, #FFA726);
  border: none;
  color: #fff;
  padding: 12px 24px;
  border-radius: 4px;
  transition: background 0.3s ease, transform 0.3s ease;
  cursor: pointer;
  text-decoration: none;
}

.btn-primary:hover {
  background: linear-gradient(45deg, #FFA726, #FB8C00);
  transform: scale(1.05);
}

/* 卡片样式 */
.card {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-10px);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.2);
}

/* 图片样式 */
img.decorative {
  width: 100%;
  max-width: 320px;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: block;
  margin: 20px auto;
}

img.decorative:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
}

/* 代码块样式 */
pre code {
  background-color: #f5f5f5;
  padding: 15px;
  border-radius: 4px;
  display: block;
  overflow-x: auto;
  font-family: 'Courier New', Courier, monospace;
  color: #d32f2f;
}

pre code.language-css {
  background-color: #e3f2fd;
  border-left: 4px solid #0D47A1;
}

/* 表格样式 */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 20px;
}

thead {
  background-color: #0D47A1;
  color: #fff;
}

th, td {
  padding: 12px 15px;
  border: 1px solid #ddd;
  text-align: left;
}

th {
  font-weight: 600;
}

/* 面包屑导航样式 */
.breadcrumb {
  display: flex;
  list-style: none;
  padding: 10px 0;
  background-color: #f5f5f5;
  border-radius: 4px;
  margin-bottom: 20px;
}

.breadcrumb li + li:before {
  content: ">";
  padding: 0 8px;
  color: #616161;
}

.breadcrumb a {
  text-decoration: none;
  color: #0D47A1;
  font-weight: 500;
  transition: color 0.3s ease;
}

.breadcrumb a:hover {
  color: #FF9800;
}

/* 加载动画样式 */
.loading-spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid #0D47A1;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 50px auto;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* AI聊天机器人样式 */
.chatbot {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  background-color: #FF9800;
  border-radius: 50%;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: bounce 2s infinite;
}

.chatbot:hover {
  background-color: #FFA726;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-10px); }
  60% { transform: translateY(-5px); }
}

/* 视差滚动效果 */
.parallax {
  background-image: url('https://images.gptkong.com/demo/sample1.png');
  height: 500px;
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  transition: transform 0.5s ease;
}

.parallax.scrolled {
  transform: translateY(-50px);
}

/* 渐显效果 */
.fade-in-section {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-section.visible {
  opacity: 1;
  transform: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .navbar ul {
    flex-direction: column;
  }
  
  .navbar li {
    margin: 10px 0;
  }
}

@media (max-width: 480px) {
  h2 {
    font-size: 1.5em;
  }
  
  h3 {
    font-size: 1.2em;
  }
  
  p {
    font-size: 15px;
  }
  
  .breadcrumb {
    flex-direction: column;
  }
}

