
.knowledge-banner .banner-carousel {
  position: relative;
  height: 100%;
  overflow: hidden;
}

.banner-carousel {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  cursor: grab;
  touch-action: pan-y;
  -webkit-user-select: none;
  user-select: none;
  will-change: transform;
  contain: layout style;
}

.banner-carousel.is-dragging {
  cursor: grabbing;
}

.carousel-item {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  pointer-events: none;
  will-change: transform;
}

.carousel-item.is-animating {
  transition: transform 0.45s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.carousel-item.active {
  z-index: 1;
}

.carousel-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

.banner-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.banner-desc {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 12px;
}

.banner-btn {
  background: #fff;
  color: #ff6b6b;
  border: none;
  padding: 8px 24px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.banner-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* 轮播指示器 */
.carousel-indicators {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
  background: transparent;
}

.carousel-indicators .indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
}

.carousel-indicators .indicator.active {
  width: 20px;
  border-radius: 4px;
  background: #fff;
}

/* 轮播导航按钮 */
.carousel-prev,
.carousel-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.3s ease, background 0.3s ease;
  -webkit-tap-highlight-color: transparent;
}

.carousel-prev {
  left: 8px;
}

.carousel-next {
  right: 8px;
}

.knowledge-banner:hover .carousel-prev,
.knowledge-banner:hover .carousel-next {
  opacity: 1;
}

.carousel-prev:hover,
.carousel-next:hover {
  background: rgba(0, 0, 0, 0.55);
}

.carousel-prev:active,
.carousel-next:active {
  background: rgba(0, 0, 0, 0.65);
  transform: translateY(-50%) scale(0.94);
}

/* 移动端始终显示导航按钮 */
@media (hover: none), (max-width: 768px) {
  .carousel-prev,
  .carousel-next {
    opacity: 0.85;
  }
}

/* 通知栏 */
.knowledge-notice {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  background: #fff;
  position: relative;
  z-index: 20;
  border-bottom: 1px solid #f0f0f0;
  border-radius: 12px;
  margin: 0 0 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* 搜索框 */
.knowledge-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: #fff;
  border-radius: 12px;
  margin: 0 0 12px;
  border: 1px solid #ececec;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  position: relative;
  z-index: 20;
}

.knowledge-search-icon {
  flex: 0 0 auto;
  color: #999;
}

.knowledge-search-input {
  flex: 1 1 auto;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  color: #333;
  height: 22px;
  padding: 0;
  -webkit-appearance: none;
  appearance: none;
}

.knowledge-search-input::-webkit-search-cancel-button,
.knowledge-search-input::-webkit-search-decoration {
  -webkit-appearance: none;
  appearance: none;
}

.knowledge-search-input::placeholder {
  color: #bbb;
}

.knowledge-search-clear {
  flex: 0 0 auto;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-tap-highlight-color: transparent;
}

.knowledge-search-clear:active {
  transform: scale(0.9);
}

.notice-left {
  margin-right: 12px;
}

.notice-label {
  font-size: 11px;
  font-weight: 700;
  color: #4ecdc4;
  background: rgba(78, 205, 196, 0.1);
  padding: 4px 8px;
  border-radius: 4px;
}

.notice-text {
  font-size: 14px;
  color: #666;
}

/* 分类导航 */
.knowledge-categories {
  display: flex;
  justify-content: space-around;
  padding: 16px;
  background: #fff;
  border-bottom: 1px solid #f0f0f0;
  border-radius: 12px;
  margin: 0 0 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.category-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.knowledge-categories .category-item:last-child {
  order: -1;
}

.category-item .category-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: 6px;
  font-size: 24px;
  line-height: 1;
  text-align: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, #4ecdc4 0%, #44a3aa 100%);
  box-shadow: none;
  transition: transform 0.3s ease;
}

.category-item .category-icon svg {
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  background: transparent;
  border-radius: 0;
  display: block;
}

.category-item[data-color="#4ecdc4"] .category-icon {
  background: linear-gradient(135deg, #6be7de 0%, #4ecdc4 100%);
}

.category-item[data-color="#ff6b6b"] .category-icon {
  background: linear-gradient(135deg, #ff8e8e 0%, #ff6b6b 100%);
}

.category-item[data-color="#ffd93d"] .category-icon {
  background: linear-gradient(135deg, #ffe66b 0%, #ffd93d 100%);
  color: #fff;
}

.category-item[data-color="#ff9f43"] .category-icon {
  background: linear-gradient(135deg, #ffbe76 0%, #ff9f43 100%);
}

.category-item[data-color="#6c5ce7"] .category-icon {
  background: linear-gradient(135deg, #a29bfe 0%, #6c5ce7 100%);
}

.category-item span {
  font-size: 12px;
  color: #666;
}

.category-item.active {
  background: transparent;
}

.category-item.active .category-icon {
  transform: translateY(-2px) scale(1.05);
}

.category-item.active span {
  color: #4ecdc4;
  font-weight: 600;
}

.category-item:hover .category-icon {
  transform: translateY(-3px) scale(1.08);
}

/* 内容区域 */
.knowledge-section {
  padding: 0;
}

/* 问答列表宽度与上方公告/分类容器保持一致（沿用 pageKnowledge 的外层 16px 内边距） */
.knowledge-section .home-flight-list.knowledge-list {
  padding: 0;
}

/* 最新问答标题与上下容器左对齐 */
.knowledge-section .home-section-header {
  margin-left: 0;
  margin-right: 0;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.section-title {
  display: flex;
  align-items: center;
  font-size: 16px;
  font-weight: 600;
  color: #333;
}

.section-more {
  font-size: 13px;
  color: #999;
}

/* 问答列表 */
.knowledge-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.knowledge-item {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  overflow: hidden;
  transition: all 0.3s ease;
}

.knowledge-question {
  display: flex;
  align-items: center;
  padding: 16px;
  cursor: pointer;
  font-size: 15px;
  color: #333;
  font-weight: 500;
}

.knowledge-arrow {
  margin-left: auto;
  transition: transform 0.3s ease;
}

.knowledge-item.open .knowledge-arrow {
  transform: rotate(90deg);
}

.knowledge-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background: #f8f9fa;
  padding: 0 16px;
}

.knowledge-item.open .knowledge-answer {
  max-height: 500px;
  padding: 16px;
}

.knowledge-answer p {
  font-size: 14px;
  color: #666;
  line-height: 1.8;
  margin-bottom: 8px;
}

.knowledge-answer p:last-child {
  margin-bottom: 0;
}

@media (prefers-color-scheme: dark) {
  .knowledge-notice {
    background: #1a1a2e;
    border-bottom-color: rgba(255, 255, 255, 0.1);
  }
  
  .notice-text {
    color: #b0b0b0;
  }
  
  .knowledge-categories {
    background: #1a1a2e;
    border-bottom-color: rgba(255, 255, 255, 0.1);
  }
  
  .category-item span {
    color: #b0b0b0;
  }
  
  .category-item.active {
    background: rgba(78, 205, 196, 0.15);
  }
  
  .section-title {
    color: #e0e0e0;
  }
  
  .section-more {
    color: #808080;
  }
  
  .knowledge-item {
    background: #1a1a2e;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  }
  
  .knowledge-question {
    color: #e0e0e0;
  }
  
  .knowledge-answer {
    background: #16162a;
  }
  
  .knowledge-answer p {
    color: #b0b0b0;
  }
}

.company-modal-btn.secondary {
  background: #f5f5f5;
  color: var(--text-secondary);
  border: 1px solid #ddd;
}

.company-modal-btn.secondary:hover {
  background: #eee;
}
