/* 飞壳打票机网站样式 - 黑灰色主题 */
:root {
  /* 主色调 */
  --primary-color: #333333;
  --primary-dark: #222222;
  --secondary-color: #555555;
  --accent-color: #888888;
  
  /* 中性色 */
  --white: #ffffff;
  --light: #f8f8f8;
  --gray-100: #f1f1f1;
  --gray-200: #e2e2e2;
  --gray-300: #d0d0d0;
  --gray-400: #a0a0a0;
  --gray-500: #757575;
  --gray-600: #606060;
  --gray-700: #404040;
  --gray-800: #303030;
  --dark: #202020;
  --black: #101010;
  
  /* 渐变色 */
  --gradient-primary: linear-gradient(135deg, #333333, #555555);
  --gradient-dark: linear-gradient(135deg, #222222, #444444);
  
  /* 阴影 */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  
  /* 圆角 */
  --radius-xs: 0.25rem;
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;
  
  /* 间距 */
  --spacer-1: 0.25rem;
  --spacer-2: 0.5rem;
  --spacer-3: 0.75rem;
  --spacer-4: 1rem;
  --spacer-5: 1.25rem;
  --spacer-6: 1.5rem;
  --spacer-8: 2rem;
  --spacer-10: 2.5rem;
  --spacer-12: 3rem;
  --spacer-16: 4rem;
  --spacer-20: 5rem;
  --spacer-24: 6rem;
  --spacer-32: 8rem;
  
  /* 断点 */
  --breakpoint-sm: 640px;
  --breakpoint-md: 768px;
  --breakpoint-lg: 1024px;
  --breakpoint-xl: 1280px;
  
  /* 字体 */
  --font-family-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  --font-family-serif: 'Playfair Display', serif;
  
  /* 字体大小 */
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
  --font-size-5xl: 3rem;
  --font-size-6xl: 3.75rem;
  --font-size-7xl: 4.5rem;
  
  /* 字体粗细 */
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;
  
  /* 行高 */
  --line-height-none: 1;
  --line-height-tight: 1.25;
  --line-height-snug: 1.375;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.625;
  --line-height-loose: 2;
  
  /* 宽度 */
  --width-container: 1200px;
}

/* 重置样式 */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family-sans);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  color: var(--gray-700);
  background-color: var(--white);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
  overflow-wrap: break-word;
}

a {
  text-decoration: none;
  color: var(--primary-color);
}

a:hover {
  color: var(--primary-dark);
}

/* 基础样式 */
.container {
  width: 100%;
  max-width: var(--width-container);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--spacer-4);
  padding-right: var(--spacer-4);
}

/* Header样式 */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  padding: var(--spacer-3) 0;
  transition: all 0.3s ease;
}

.hero-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--spacer-2);
  flex-shrink: 0;
}

.logo a {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.logo-img {
  height: 40px;
  width: 40px;
  object-fit: contain;
  display: block;
}

.logo-text {
  font-family: var(--font-family-serif);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  color: var(--gray-700);
  margin: 0;
  white-space: nowrap;
  line-height: 1;
}

/* 导航菜单 */
.nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: var(--spacer-6);
}

.nav-link {
  color: var(--gray-700);
  font-weight: var(--font-weight-medium);
  transition: all 0.3s ease;
  position: relative;
  padding: var(--spacer-2) 0;
}

.nav-link:hover {
  color: var(--gray-700);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--gray-500);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

/* 登录和注册按钮 */
.auth-buttons {
  display: flex;
  gap: var(--spacer-3);
  margin-left: var(--spacer-6);
}

.btn {
  display: inline-block;
  padding: var(--spacer-2) var(--spacer-4);
  border-radius: var(--radius-sm);
  font-weight: var(--font-weight-medium);
  text-align: center;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-login {
  color: var(--gray-700);
  background-color: transparent;
  border: 1px solid var(--gray-300);
}

.btn-login:hover {
  background-color: var(--gray-100);
  color: var(--gray-800);
  border-color: var(--gray-400);
}

.btn-register {
  color: var(--white);
  background-color: var(--gray-700);
  border: 1px solid var(--gray-700);
}

.btn-register:hover {
  background-color: var(--gray-800);
  border-color: var(--gray-800);
}

/* 移动端菜单按钮 */
.menu-toggle {
  display: none;
  flex-direction: column;
  cursor: pointer;
  padding: var(--spacer-2);
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--gray-700);
  margin: 3px 0;
  transition: 0.3s;
  border-radius: var(--radius-full);
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(-45deg) translate(-6px, 6px);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(45deg) translate(-6px, -6px);
}

/* Hero区域 */
.hero {
  padding: var(--spacer-24) 0 var(--spacer-16);
  color: var(--white);
  margin-top: 70px;
  text-align: center;
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
}

.hero-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  /* 桌面端默认背景 */
  background-image: url('../../media/website/1824x576.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-bg-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
  /* 移动端性能优化 */
  -webkit-transform: translate3d(0, 0, 0);
  -webkit-backface-visibility: hidden;
  -webkit-perspective: 1000;
  /* 图片优化 */
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
  /* 在桌面端显示图片元素 */
  display: block;
}

.hero-title {
  font-family: var(--font-family-serif);
  font-size: var(--font-size-5xl);
  font-weight: var(--font-weight-extrabold);
  margin-bottom: var(--spacer-4);
  line-height: var(--line-height-tight);
  text-shadow: 
    -2px -2px 0 #000,  
    2px -2px 0 #000,
    -2px 2px 0 #000,
    2px 2px 0 #000,
    0 2px 4px rgba(0, 0, 0, 0.5);
  /* 向上调整位置 */
  transform: translateY(-20px);
}

.hero-subtitle {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-medium);
  margin-bottom: var(--spacer-8);
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  opacity: 0.9;
  text-shadow: 
    -1px -1px 0 #000,  
    1px -1px 0 #000,
    -1px 1px 0 #000,
    1px 1px 0 #000,
    0 1px 2px rgba(0, 0, 0, 0.5);
  /* 向上调整位置 */
  transform: translateY(-20px);
}

/* 向下指引按钮 */
.scroll-down {
  position: absolute;
  bottom: 120px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
  text-decoration: none;
  animation: bounce 2s infinite;
  z-index: 10;
}

.scroll-down span {
  font-size: var(--font-size-base); /* 增大字体大小 */
  font-weight: var(--font-weight-bold); /* 加粗字体 */
  margin-bottom: 10px; /* 减小间距，使文字和图标更紧凑 */
  display: block;
  text-align: center;
  /* 添加黑色描边效果 */
  text-shadow: 
    -1px -1px 0 #000,  
    1px -1px 0 #000,
    -1px 1px 0 #000,
    1px 1px 0 #000;
}

/* 向下指引标志 */
.scroll-down-icon {
  width: 40px; /* 增大尺寸 */
  height: 40px;
  border: 3px solid white; /* 加粗边框 */
  border-radius: 50%;
  position: relative;
  animation: pulse 2s infinite;
  /* 向右移动两个字的位置 */
  margin-left: 2em;
  /* 添加黑色描边效果 */
  box-shadow: 
    -2px -2px 0 #000,  
    2px -2px 0 #000,
    -2px 2px 0 #000,
    2px 2px 0 #000;
}

.scroll-down-icon::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 12px; /* 增大箭头尺寸 */
  height: 12px;
  /* 修改箭头方向为正下方 */
  border-right: 3px solid white; /* 右边框 */
  border-bottom: 3px solid white; /* 下边框 */
  transform: translate(-50%, -50%) rotate(45deg); /* 旋转45度指向正下方 */
  /* 添加黑色描边效果 */
  text-shadow: 
    -1px -1px 0 #000,  
    1px -1px 0 #000,
    -1px 1px 0 #000,
    1px 1px 0 #000;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  40% {
    transform: translateX(-50%) translateY(-15px); /* 增加弹跳幅度 */
  }
  60% {
    transform: translateX(-50%) translateY(-8px);
  }
}

@keyframes pulse {
  0% {
    transform: translateX(-50%) scale(1);
    opacity: 1;
  }
  50% {
    transform: translateX(-50%) scale(1.15); /* 增加脉冲幅度 */
    opacity: 0.8;
  }
  100% {
    transform: translateX(-50%) scale(1);
    opacity: 1;
  }
}

/* Features区域 */
.features {
  padding: var(--spacer-16) 0;
  background-color: var(--gray-100);
  position: relative;
  z-index: 1;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacer-6);
}

.feature-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--spacer-8);
  text-align: center;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  border: 1px solid var(--gray-200);
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--gray-500);
}

.feature-icon {
  font-size: var(--font-size-4xl);
  margin-bottom: var(--spacer-4);
}

.feature-title {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--spacer-3);
  color: var(--gray-800);
}

.feature-desc {
  font-size: var(--font-size-base);
  color: var(--gray-600);
  margin-bottom: var(--spacer-6);
  line-height: var(--line-height-relaxed);
}

.feature-link {
  display: inline-block;
  padding: var(--spacer-3) var(--spacer-6);
  background: var(--gray-700);
  color: var(--white);
  border-radius: var(--radius-full);
  font-weight: var(--font-weight-semibold);
  transition: all 0.3s ease;
}

.feature-link:hover {
  background: var(--gray-800);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

/* Footer */
.footer {
  background: var(--black);
  color: var(--gray-300);
  padding: var(--spacer-12) 0 var(--spacer-6);
  margin-top: auto;
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--spacer-12);
  margin-bottom: var(--spacer-12);
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--spacer-3);
  margin-bottom: var(--spacer-4);
}

.footer-logo-img {
  height: 40px;
  width: 40px;
  object-fit: contain;
}

.footer-logo-text {
  color: var(--white);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  margin: 0;
}

.footer-desc {
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
  max-width: 500px;
}

.footer-links-title {
  color: var(--white);
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  margin-bottom: var(--spacer-4);
}

.footer-links-grid {
  display: flex;
  flex-direction: column;
  gap: var(--spacer-4);
}

.footer-links-row {
  display: flex;
  justify-content: space-between;
  gap: var(--spacer-6);
}

.footer-link {
  color: var(--gray-400);
  transition: color 0.3s ease;
  text-decoration: none;
  padding: var(--spacer-2);
}

.footer-link:hover {
  color: var(--white);
}

.footer-links-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links-list li {
  margin-bottom: var(--spacer-3);
}

.footer-bottom {
  border-top: 1px solid var(--gray-800);
  padding-top: var(--spacer-6);
  text-align: center;
}

.copyright {
  font-size: var(--font-size-sm);
  color: var(--gray-500);
  margin: 0;
}

/* 响应式设计 */
@media (max-width: 1024px) {
  .hero-title {
    font-size: var(--font-size-4xl);
    transform: translateY(-15px);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-lg);
    transform: translateY(-15px);
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }
  
  .nav {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: var(--white);
    transition: all 0.3s ease;
    z-index: 999;
    padding: var(--spacer-8) var(--spacer-4);
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
  }
  
  .nav.active {
    left: 0;
  }
  
  .nav-list {
    flex-direction: column;
    gap: var(--spacer-4);
    width: 100%;
    order: 1;
  }
  
  .nav-link {
    font-size: var(--font-size-lg);
    padding: var(--spacer-3) var(--spacer-4);
    display: block;
  }
  
  .auth-buttons {
    flex-direction: column;
    width: 100%;
    margin: var(--spacer-6) 0 0 0;
    gap: var(--spacer-3);
    order: 2;
  }
  
  .btn {
    width: 100%;
    padding: var(--spacer-3) var(--spacer-4);
  }
  
  .hero {
    padding: var(--spacer-20) 0 var(--spacer-12);
    min-height: 100vh;
    display: flex;
    align-items: center;
  }
  
  .hero-background {
    position: fixed;
    /* 移动端性能优化 */
    -webkit-transform: translate3d(0, 0, 0);
    transform: translate3d(0, 0, 0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-perspective: 1000;
    perspective: 1000;
    /* 移动端背景图片 */
    background-image: url('../../media/website/832x1280.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
  }
  
  .hero-bg-image {
    /* 在移动端隐藏图片元素，使用背景图片 */
    display: none;
    /* 移动端图片优化 */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    /* 降低图片质量以提高性能 */
    -webkit-transform: translateZ(0) scale(1.05);
    transform: translateZ(0) scale(1.05);
  }
  
  .hero-content {
    padding: var(--spacer-8) var(--spacer-4);
  }
  
  .hero-title {
    font-size: var(--font-size-3xl);
    transform: translateY(-10px);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-base);
    transform: translateY(-10px);
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--spacer-8);
  }
  
  /* Ensure logo and text stay on the same line on mobile */
  .logo a {
    display: flex;
    align-items: center;
  }
  
  .logo-text {
    font-size: var(--font-size-lg);
  }
  
  .scroll-down span {
    font-size: var(--font-size-sm); /* 在移动端适当减小字体 */
  }
  
  .scroll-down-icon {
    width: 35px; /* 在移动端适当减小尺寸 */
    height: 35px;
  }
}

@media (max-width: 480px) {
  .container {
    padding-left: var(--spacer-3);
    padding-right: var(--spacer-3);
  }
  
  .hero {
    padding: var(--spacer-16) 0 var(--spacer-8);
    min-height: 100vh;
  }
  
  .hero-background {
    position: fixed;
    /* 移动端性能优化 */
    -webkit-transform: translate3d(0, 0, 0);
    transform: translate3d(0, 0, 0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-perspective: 1000;
    perspective: 1000;
    /* 移动端背景图片 */
    background-image: url('../../media/website/832x1280.webp');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
  }
  
  .hero-bg-image {
    /* 在移动端隐藏图片元素，使用背景图片 */
    display: none;
    /* 移动端图片优化 */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    /* 降低图片质量以提高性能 */
    -webkit-transform: translateZ(0) scale(1.05);
    transform: translateZ(0) scale(1.05);
  }
  
  .hero-content {
    padding: var(--spacer-6) var(--spacer-3);
  }
  
  .hero-title {
    font-size: var(--font-size-2xl);
    transform: translateY(-8px);
  }
  
  .hero-subtitle {
    font-size: var(--font-size-sm);
    transform: translateY(-8px);
  }
  
  .feature-card {
    padding: var(--spacer-6);
  }
  
  .feature-title {
    font-size: var(--font-size-xl);
  }
}

/* Contact Section */
.contact {
  padding: var(--spacer-16) 0;
  background-color: var(--white);
  margin-top: 80px;
}

/* Page content containers */
.video-container,
.software-container {
  margin-top: 80px;
  padding: var(--spacer-8) 0;
}

.section-title {
  text-align: center;
  margin-bottom: var(--spacer-12);
  color: var(--primary-color);
  font-family: var(--font-family-serif);
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-bold);
  padding-top: var(--spacer-4);
  position: relative;
  z-index: 10;
}

.contact-content {
  display: flex;
  justify-content: center;
}

.contact-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacer-8);
  max-width: 1000px;
  width: 100%;
}

.contact-item {
  background: var(--gray-100);
  border-radius: var(--radius-lg);
  padding: var(--spacer-6);
  text-align: center;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.contact-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.contact-item h3 {
  color: var(--gray-800);
  margin-bottom: var(--spacer-4);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
}

.contact-item p {
  color: var(--gray-600);
  margin-bottom: var(--spacer-2);
  line-height: var(--line-height-relaxed);
}

.wechat-qrcode {
  margin-top: var(--spacer-4);
}

.qrcode-img {
  width: 150px;
  height: 150px;
  object-fit: contain;
  margin: 0 auto var(--spacer-3);
  background-color: var(--white);
  padding: var(--spacer-2);
  border-radius: var(--radius-sm);
}

.qrcode-text {
  font-weight: var(--font-weight-semibold);
  color: var(--gray-700);
}

/* 动画效果 */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-content {
  animation: fadeInUp 0.8s ease-out;
}

.feature-card {
  animation: fadeInUp 0.6s ease-out;
}

.feature-card:nth-child(2) {
  animation-delay: 0.1s;
}

.feature-card:nth-child(3) {
  animation-delay: 0.2s;
}

.feature-card:nth-child(4) {
  animation-delay: 0.3s;
}

.feature-card:nth-child(5) {
  animation-delay: 0.4s;
}

.feature-card:nth-child(6) {
  animation-delay: 0.5s;
}

.contact-item {
  animation: fadeInUp 0.6s ease-out;
}

.contact-item:nth-child(2) {
  animation-delay: 0.1s;
}

.contact-item:nth-child(3) {
  animation-delay: 0.2s;
}

.contact-item:nth-child(4) {
  animation-delay: 0.3s;
}
