/* home.css - 首页专用样式 */

:root {
  --primary-color: #1677ff;
  --primary-color-hover: #4096ff;
  --text-color: #303133;
  --text-color-secondary: #606266;
  --transition-speed: 0.3s;
  --border-radius: 8px;
  --box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.home-main {
  padding: 0;
  width: 100%;
}

/* 视频轮播区域 */
.video-carousel {
  width: 100%;
  overflow: hidden;
}

.carousel-container {
  width: 100%;
  position: relative;
}

.video-wrapper {
  width: 100%;
  padding-bottom: 45vh; /* 视频高度为视口高度的45% */
  position: relative;
  overflow: hidden;
}

.carousel-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.video-loader {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: opacity 0.3s ease;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: var(--primary-color);
  animation: spin 1s ease-in-out infinite;
  margin-bottom: 10px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-text {
  color: white;
  font-size: 16px;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.7);
}

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: none;
  display: flex;
  align-items: center;
  z-index: 2;
}

.overlay-content {
  padding: 0 10%;
  max-width: 700px;
}

.overlay-content h2 {
  font-size: 44px;
  font-weight: 800;
  margin-bottom: 20px;
  color: var(--primary-color);
  text-shadow: none;
  letter-spacing: 1px;
  white-space: nowrap;
}

.overlay-content p {
  font-size: 20px;
  margin-bottom: 12px;
  color: #000;
  text-shadow: none;
  font-weight: 500;
  line-height: 1.5;
  white-space: nowrap;
}

.overlay-btn {
  display: inline-block;
  margin-top: 30px;
  padding: 12px 36px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 50px;
  font-weight: 600;
  transition: all var(--transition-speed) ease;
  font-size: 18px;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(22, 119, 255, 0.4);
}

.overlay-btn:hover {
  background-color: var(--primary-color-hover);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(22, 119, 255, 0.5);
}

/* 内容区域 */
.section-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px 24px;
}

.section-title {
  font-size: 28px;
  font-weight: 600;
  text-align: center;
  margin-bottom: 40px;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.product-card {
  background-color: #fff;
  border-radius: var(--border-radius);
  padding: 30px;
  box-shadow: var(--box-shadow);
  text-align: center;
  transition: all var(--transition-speed) ease;
}

.product-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.product-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 20px;
  background-color: rgba(22, 119, 255, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-icon svg {
  width: 32px;
  height: 32px;
  color: var(--primary-color);
}

.product-card h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 16px;
}

.product-card p {
  color: var(--text-color-secondary);
}

.advantage-section {
  background-color: #fff;
  padding: 20px 0 60px;
}

.advantage-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.advantage-item {
  position: relative;
  padding: 24px 20px;
  border-radius: var(--border-radius);
  transition: all var(--transition-speed) ease;
  overflow: hidden;
}

.advantage-item:hover {
  background-color: rgba(22, 119, 255, 0.03);
}

.advantage-number {
  font-size: 60px;
  font-weight: 700;
  color: rgba(22, 119, 255, 0.08);
  position: absolute;
  top: 10px;
  right: 20px;
  z-index: 0;
}

.advantage-item h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
}

.advantage-item p {
  color: var(--text-color-secondary);
  position: relative;
  z-index: 1;
}

/* 响应式设计 */
@media screen and (max-width: 992px) {
  .product-grid,
  .advantage-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  .video-wrapper {
    padding-bottom: 60vh;
  }
}

@media screen and (max-width: 768px) {
  .video-wrapper {
    padding-bottom: 45vh;
  }
  .overlay-content h2 {
    font-size: 28px;
  }
  .overlay-content p {
    font-size: 16px;
  }
  .section-container {
    padding: 30px 16px;
  }
  .section-title {
    font-size: 24px;
    margin-bottom: 30px;
  }
}

@media screen and (max-width: 576px) {
  .video-wrapper {
    padding-bottom: 40vh;
  }
  .overlay-content h2 {
    font-size: 26px;
  }
  .overlay-content p {
    font-size: 14px;
  }
  .overlay-btn {
    padding: 8px 24px;
    font-size: 14px;
    margin-top: 16px;
  }
  .product-grid,
  .advantage-grid {
    grid-template-columns: 1fr;
  }
} 