/* ============================================
   PICOUNI 品牌视觉设计系统
   普康智合（成都）生物制品有限公司
   国际级分子诊断品牌视觉规范
   ============================================ */

/* --- CSS 变量：颜色系统 --- */
:root {
  --bg-primary: #F7F5F0;
  --bg-secondary: #F3F1EB;
  --bg-white: #FFFFFF;
  --bg-footer: #2C2C2C;
  --text-primary: #1F1F1F;
  --text-secondary: #2C2C2C;
  --text-muted: #6D6D6D;
  --text-light: #A8A8A8;
  --text-footer: #B0B0B0;
  --accent-start: #F4A261;
  --accent-end: #E76F51;
  --accent-bg: #DDE5EC;
  --border-light: rgba(0,0,0,0.06);
  --shadow-soft: 0 2px 20px rgba(0,0,0,0.04);
  --shadow-card: 0 4px 24px rgba(0,0,0,0.06);
  --shadow-card-hover: 0 8px 40px rgba(0,0,0,0.10);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 980px;
  --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --font-sans: "Inter", "SF Pro Display", "PingFang SC", "Noto Sans SC", system-ui, -apple-system, sans-serif;
  --max-width: 1200px;
  --nav-height: 72px;
}

/* --- 基础重置 --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background: var(--bg-primary);
  line-height: 1.8;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

/* --- 排版系统 --- */
.heading-hero {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.heading-section {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.heading-card {
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text-primary);
}

.text-subtitle {
  font-size: clamp(1rem, 2vw, 1.35rem);
  color: var(--text-muted);
  line-height: 1.8;
  font-weight: 400;
}

.text-body {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

.text-small {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.text-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-light);
}

/* --- 布局容器 --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 100px 0;
  position: relative;
}

.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-header .text-label {
  margin-bottom: 12px;
  display: block;
}

.section-header .heading-section {
  margin-bottom: 16px;
}

.section-header .text-subtitle {
  max-width: 640px;
  margin: 0 auto;
}

/* --- 导航栏 --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  padding: 0 40px;
  transition: background var(--transition-base), box-shadow var(--transition-base), backdrop-filter var(--transition-base);
  background: transparent;
}

.nav.scrolled {
  background: rgba(247, 245, 240, 0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  box-shadow: 0 1px 0 var(--border-light);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  gap: 12px;
  flex-wrap: nowrap;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.nav-logo img {
  height: 36px;
  width: auto;
}

.nav-logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-primary);
}

.nav-logo-sub {
  font-size: 0.65rem;
  color: var(--text-light);
  letter-spacing: 0.02em;
  margin-top: -2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  flex-shrink: 0;
}

.nav-link {
  padding: 8px 12px;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: color var(--transition-base), background var(--transition-base);
  white-space: nowrap;
  flex-shrink: 0;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: rgba(0,0,0,0.04);
}

.nav-lang {
  margin-left: 8px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  transition: all var(--transition-base);
}

.nav-lang:hover {
  color: var(--text-primary);
  border-color: rgba(0,0,0,0.15);
}

/* 导航栏搜索框 */
.nav-search-wrap {
  position: relative;
  flex: 0 1 220px;
  margin: 0 8px;
  min-width: 160px;
}

.nav-search-input {
  width: 100%;
  padding: 8px 14px 8px 36px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-family: var(--font-sans);
  background: rgba(0,0,0,0.03);
  color: var(--text-primary);
  transition: all var(--transition-base);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23A8A8A8' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='8'/%3E%3Cpath d='m21 21-4.35-4.35'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 12px center;
  background-size: 14px;
}

.nav-search-input:focus {
  outline: none;
  border-color: var(--accent-start);
  box-shadow: 0 0 0 3px rgba(244,162,97,0.12);
  background-color: var(--bg-white);
}

.search-suggestions {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  max-height: 320px;
  overflow-y: auto;
  z-index: 1001;
}

.search-suggestions.open {
  display: block;
}

.search-suggestion-item {
  padding: 10px 16px;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
  transition: background var(--transition-base);
}

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

.search-suggestion-item:hover,
.search-suggestion-item.active {
  background: var(--bg-secondary);
}

.search-suggestion-item .suggestion-code {
  font-family: "SF Mono", "Consolas", monospace;
  font-size: 0.75rem;
  color: var(--accent-end);
  margin-right: 8px;
  font-weight: 600;
}

.search-suggestion-item .suggestion-species {
  font-size: 0.7rem;
  color: var(--text-light);
  float: right;
  margin-top: 2px;
}

/* 弹窗内搜索候选词 */
.modal-search {
  position: relative;
}

.modal-suggestions {
  display: none;
  position: absolute;
  top: calc(100% - 4px);
  left: 32px;
  right: 32px;
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  max-height: 240px;
  overflow-y: auto;
  z-index: 10;
}

.modal-suggestions.open {
  display: block;
}

/* 移动端汉堡菜单 */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: all var(--transition-base);
}

.nav-hamburger.open span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-hamburger.open span:nth-child(2) {
  opacity: 0;
}

.nav-hamburger.open span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(247, 245, 240, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 32px 24px;
  z-index: 999;
}

.nav-mobile.open {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-mobile .nav-link {
  font-size: 1.1rem;
  padding: 14px 20px;
}

/* --- Hero 区域 --- */
.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  background: var(--bg-primary);
  padding-top: var(--nav-height);
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

/* 微粒子渐变光感 */
.hero-bg::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 60%;
  height: 60%;
  background: radial-gradient(ellipse, rgba(244,162,97,0.06) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-bg::after {
  content: '';
  position: absolute;
  bottom: -10%;
  left: -5%;
  width: 50%;
  height: 50%;
  background: radial-gradient(ellipse, rgba(221,229,236,0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 800px;
  padding: 0 24px;
}

.hero-content .heading-hero {
  margin-bottom: 24px;
}

.hero-content .text-subtitle {
  margin-bottom: 48px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* --- 按钮系统 --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 36px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-pill);
  transition: all var(--transition-base);
  cursor: pointer;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-start), var(--accent-end));
  color: #fff;
  box-shadow: 0 4px 16px rgba(244,162,97,0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(244,162,97,0.4);
}

.btn-secondary {
  background: var(--bg-white);
  color: var(--text-primary);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-soft);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.btn-ghost {
  color: var(--text-muted);
  padding: 10px 20px;
}

.btn-ghost:hover {
  color: var(--text-primary);
  background: rgba(0,0,0,0.03);
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- 数据条 --- */
.data-strip {
  padding: 64px 0;
  background: var(--bg-white);
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.data-strip-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  text-align: center;
}

.data-item {
  padding: 16px;
}

.data-number {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.data-number .accent {
  background: linear-gradient(135deg, var(--accent-start), var(--accent-end));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.data-unit {
  font-size: 0.9rem;
  color: var(--text-light);
  margin-top: 4px;
}

.data-label {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 8px;
  font-weight: 500;
}

/* --- 产品/技术卡片 --- */
.products {
  background: var(--bg-primary);
}

.products-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.product-card {
  position: relative;
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-soft);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-start), var(--accent-end));
  opacity: 0;
  transition: opacity var(--transition-base);
}

.product-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: var(--shadow-card-hover);
  transition: transform 0.2s cubic-bezier(0.34,1.56,0.64,1), box-shadow 0.2s ease;
}

.product-card:hover::before {
  opacity: 1;
}

.product-card-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  font-size: 1.5rem;
  transition: background var(--transition-base);
}

.product-card:hover .product-card-icon {
  background: linear-gradient(135deg, rgba(244,162,97,0.1), rgba(231,111,81,0.1));
}

.product-card .heading-card {
  margin-bottom: 12px;
}

.product-card .text-small {
  margin-bottom: 20px;
}

.product-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 8px;
}

/* 产品卡片数量徽章 */
.product-card-count {
  position: absolute;
  top: 16px;
  right: 16px;
  background: linear-gradient(135deg, var(--accent-start), var(--accent-end));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 12px;
  line-height: 1.4;
}

/* 产品卡片标签 */
.product-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 12px;
}

.product-card-tags .tag {
  font-size: 0.7rem;
  padding: 3px 10px;
  border-radius: 12px;
  background: rgba(244,162,97,0.1);
  color: var(--accent-start);
  white-space: nowrap;
}

.product-card-link {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent-end);
  transition: gap var(--transition-base);
}

.product-card:hover .product-card-link {
  gap: 10px;
}

.product-card-link svg {
  width: 16px;
  height: 16px;
  transition: transform var(--transition-base);
}

.product-card:hover .product-card-link svg {
  transform: translateX(2px);
}

/* --- 品牌理念 --- */
.about {
  background: var(--bg-secondary);
  position: relative;
  overflow: hidden;
}

/* 极淡科技色背景光感层 */
.about::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 40%;
  height: 100%;
  background: radial-gradient(ellipse at right center, rgba(221,229,236,0.4) 0%, transparent 70%);
  pointer-events: none;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.about-text .text-label {
  margin-bottom: 12px;
  display: block;
}

.about-text .heading-section {
  margin-bottom: 24px;
}

.about-text .text-body {
  margin-bottom: 16px;
}

.about-text .text-body:last-of-type {
  margin-bottom: 32px;
}

.about-image {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.about-image img {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

/* 玻璃质感浮层 */
.about-image-overlay {
  position: absolute;
  bottom: 24px;
  left: 24px;
  right: 24px;
  padding: 20px 24px;
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255,255,255,0.5);
}

.about-image-overlay .heading-card {
  font-size: 1rem;
  margin-bottom: 4px;
}

.about-image-overlay .text-small {
  margin: 0;
}

/* --- 优势/资质条 --- */
.strengths {
  background: var(--bg-white);
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.strengths-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}

.strength-item {
  text-align: center;
  padding: 32px 16px;
}

.strength-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
}

.strength-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--accent-end);
}

.strength-item .heading-card {
  font-size: 1rem;
  margin-bottom: 8px;
}

/* --- 联系我们 --- */
.contact {
  background: var(--bg-white);
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.contact-item {
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  text-align: center;
  border: 1px solid var(--border-light);
  transition: all var(--transition-base);
}

.contact-item:hover {
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}

.contact-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: var(--bg-white);
}

.contact-item .heading-card {
  font-size: 1rem;
  margin-bottom: 12px;
}

.contact-item .text-small {
  margin-bottom: 4px;
}

.contact-item .text-small a {
  color: var(--accent-end);
  font-weight: 500;
}

.contact-item .text-small a:hover {
  text-decoration: underline;
}

/* --- Footer --- */
.footer {
  background: var(--bg-footer);
  padding: 64px 0 32px;
  color: var(--text-footer);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand .nav-logo-text {
  color: #fff;
  margin-bottom: 4px;
}

.footer-brand .nav-logo-sub {
  color: var(--text-footer);
  margin-bottom: 16px;
  display: block;
}

.footer-brand .text-small {
  color: var(--text-footer);
  max-width: 300px;
  line-height: 1.7;
}

.footer-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 20px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-link {
  font-size: 0.875rem;
  color: var(--text-footer);
  transition: color var(--transition-base);
}

.footer-link:hover {
  color: #fff;
}

.footer-qr {
  text-align: center;
}

.footer-qr img {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-sm);
  margin: 0 auto 8px;
  background: #fff;
  padding: 4px;
}

.footer-qr .text-small {
  color: var(--text-footer);
  font-size: 0.75rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-copyright {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.35);
}

.footer-copyright a {
  color: rgba(255,255,255,0.45);
  transition: color var(--transition-base);
}

.footer-copyright a:hover {
  color: rgba(255,255,255,0.7);
}

.footer-icp {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.35);
}

.footer-icp a {
  color: rgba(255,255,255,0.45);
  transition: color var(--transition-base);
}

.footer-icp a:hover {
  color: rgba(255,255,255,0.7);
}

/* --- 滚动动画 --- */
.fade-in {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--transition-base), transform var(--transition-base);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 延迟类 */
.delay-1 { transition-delay: 80ms; }
.delay-2 { transition-delay: 160ms; }
.delay-3 { transition-delay: 240ms; }
.delay-4 { transition-delay: 320ms; }
.delay-5 { transition-delay: 400ms; }
.delay-6 { transition-delay: 480ms; }

/* --- SVG 生物科技装饰 --- */
.bio-decoration {
  position: absolute;
  pointer-events: none;
  z-index: 0;
}

.bio-decoration svg {
  width: 100%;
  height: 100%;
}

/* --- 滚动条 --- */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.2); }
::selection { background: rgba(244,162,97,0.2); }

/* --- 产品弹窗 --- */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  justify-content: center;
  align-items: center;
  padding: 24px;
}

.modal-overlay.open {
  display: flex;
}

.modal-content {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 720px;
  height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 80px rgba(0,0,0,0.18);
  animation: modalIn 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 32px 16px;
  border-bottom: 1px solid var(--border-light);
}

.modal-header .heading-section {
  font-size: 1.35rem;
}

.modal-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all var(--transition-base);
}

.modal-close:hover {
  background: rgba(0,0,0,0.06);
  color: var(--text-primary);
}

/* --- 搜索高亮 --- */
.search-hl {
  background: rgba(244,162,97,0.25);
  color: var(--accent-end);
  padding: 0 1px;
  border-radius: 2px;
}

/* --- 虚拟滚动表格 --- */
.modal-body {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  overflow-x: auto;
  padding: 16px 32px;
  display: flex;
  flex-direction: column;
  flex-direction: column;
  min-height: 0;
}

.product-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  table-layout: fixed;
}

.product-table th {
  text-align: left;
  padding: 10px 12px;
  font-weight: 600;
  color: var(--text-muted);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 2px solid var(--border-light);
  position: sticky;
  top: 0;
  background: var(--bg-white);
  z-index: 2;
}

.product-table th:nth-child(4) {
  text-align: center;
}

.product-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-secondary);
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-table tr:hover td {
  background: var(--bg-secondary);
}

/* 列宽分配：编号 / 名称 / 判读 / 物种 */
.product-table { width: 100%; table-layout: fixed; }
.product-table th:nth-child(1),
.product-table td:nth-child(1) { width: 16%; }
.product-table th:nth-child(2),
.product-table td:nth-child(2) { width: 36%; }
.product-table th:nth-child(3),
.product-table td:nth-child(3) { width: 32%; }
.product-table th:nth-child(4),
.product-table td:nth-child(4) { width: 16%; text-align: center; }

.td-reading {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vs-scroller {
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  min-height: 0;
}

.vs-table { margin-bottom: 0; width: 100%; border-collapse: collapse; }
.vs-table thead tr { display: flex; width: 100%; padding-right: 8px; /* 补偿滚动条宽度 */ }
.vs-table th { text-align: left; }
.vs-table th:nth-child(1) { flex: 0 0 16%; }
.vs-table th:nth-child(2) { flex: 0 0 36%; }
.vs-table th:nth-child(3) { flex: 0 0 32%; }
.vs-table th:nth-child(4) { flex: 0 0 16%; text-align: center; }
.vs-table-body { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.vs-table-body tbody { display: block; }
.vs-row { display: flex !important; align-items: center; }
.vs-row td:nth-child(1) { flex: 0 0 16%; }
.vs-row td:nth-child(2) { flex: 0 0 36%; }
.vs-row td:nth-child(3) { flex: 0 0 32%; }
.vs-row td:nth-child(4) { flex: 0 0 16%; text-align: center; }
.vs-table-body td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-secondary);
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
  white-space: nowrap;
  vertical-align: middle;
}
.vs-row { overflow: hidden; }
.vs-row:hover td { background: var(--bg-secondary); }

.modal-search {
  padding: 16px 32px 0;
}

.modal-search-input {
  width: 100%;
  padding: 10px 16px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-family: var(--font-sans);
  background: var(--bg-secondary);
  color: var(--text-primary);
  transition: all var(--transition-base);
}

.modal-search-input:focus {
  outline: none;
  border-color: var(--accent-start);
  box-shadow: 0 0 0 3px rgba(244,162,97,0.12);
  background: var(--bg-white);
}

/* 弹窗子分类标签页 */
.modal-sub-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 32px 0;
}

.sub-tab {
  padding: 6px 16px;
  border: 1px solid var(--border-light);
  border-radius: 20px;
  background: transparent;
  color: var(--text-body);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.sub-tab:hover {
  border-color: var(--accent-start);
  color: var(--accent-start);
}

.sub-tab.active {
  background: linear-gradient(135deg, var(--accent-start), var(--accent-end));
  color: #fff;
  border-color: transparent;
}

.modal-body .product-code {
  font-family: "SF Mono", "Consolas", monospace;
  font-size: 0.8rem;
  color: var(--accent-end);
  font-weight: 600;
  white-space: nowrap;
}

.modal-body .product-species {
  font-size: 0.75rem;
  color: var(--text-light);
  background: var(--bg-secondary);
  padding: 2px 8px;
  border-radius: 4px;
  display: inline-block;
  white-space: nowrap;
  min-width: 60px;
  text-align: center;
}

.modal-footer {
  padding: 12px 32px 20px;
  border-top: 1px solid var(--border-light);
  text-align: center;
}

/* 弹窗移动端适配 */
@media (max-width: 767px) {
  .modal-overlay { padding: 8px; }
  .modal-content {
    max-height: 95vh;
    border-radius: var(--radius-md);
  }
  .modal-header { padding: 16px 16px 12px; }
  .modal-header .heading-section { font-size: 1.1rem; }
  .modal-search { padding: 10px 16px 0; }
  .modal-body { padding: 10px 16px; }
  .modal-sub-tabs { padding: 10px 16px 0; gap: 6px; }
  .sub-tab { padding: 5px 12px; font-size: 0.75rem; }
  .modal-footer { padding: 10px 16px 14px; }

  /* 移动端表格：隐藏判读列，防止横向溢出 */
  .product-table th:nth-child(3),
  .product-table td:nth-child(3),
  .vs-table th:nth-child(3),
  .vs-row td:nth-child(3) { display: none; }
  .product-table th:nth-child(1), .product-table td:nth-child(1) { width: 22%; }
  .product-table th:nth-child(2), .product-table td:nth-child(2) { width: 55%; }
  .product-table th:nth-child(4), .product-table td:nth-child(4) { width: 23%; text-align: center; }
  .vs-table th:nth-child(1) { flex: 0 0 22%; }
  .vs-table th:nth-child(2) { flex: 0 0 55%; }
  .vs-table th:nth-child(4) { flex: 0 0 23%; text-align: center; }
  .vs-row td:nth-child(1) { flex: 0 0 22%; }
  .vs-row td:nth-child(2) { flex: 0 0 55%; }
  .vs-row td:nth-child(4) { flex: 0 0 23%; text-align: center; }
  .product-table td, .vs-table-body td { padding: 8px 6px; font-size: 0.78rem; }
  .product-table th, .vs-table th { padding: 8px 6px; font-size: 0.7rem; }
  .modal-body .product-code { font-size: 0.72rem; }
}

/* ============================================
   响应式布局
   ============================================ */

/* Tablet: 768px - 1024px */
@media (max-width: 1024px) {
  .nav { padding: 0 24px; }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .about-image { order: -1; }

  .about-image img { height: 300px; }

  .strengths-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .data-strip-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .contact .products-grid,
  .contact [style*="grid-template-columns"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* Mobile: < 768px */
@media (max-width: 767px) {
  :root {
    --nav-height: 60px;
  }

  .section {
    padding: 64px 0;
  }

  .section-header {
    margin-bottom: 40px;
  }

  .nav { padding: 0 16px; }

  .nav-links { display: none; }
  .nav-lang { display: none; }
  .nav-search-wrap { display: none; }
  .nav-hamburger { display: flex; }

  .hero {
    min-height: 100vh;
    min-height: 100dvh;
    padding-top: calc(var(--nav-height) + 32px);
  }

  .hero-content {
    padding: 0 16px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn {
    width: 100%;
    max-width: 300px;
  }

  .data-strip-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .data-number {
    font-size: 1.75rem;
  }

  .products-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .product-card {
    padding: 28px 24px;
  }

  .about-grid {
    gap: 32px;
  }

  .about-image img {
    height: 240px;
  }

  .strengths-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }

  .strength-item {
    padding: 24px 12px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .container {
    padding: 0 16px;
  }
}

/* ── 按钮 active 反馈 ── */
.btn:active, .nav-link:active, .product-card:active {
  transform: scale(0.95) !important;
  transition-duration: 0.1s;
}

/* ── 返回顶部按钮 ── */
#backToTop {
  display: none;
  align-items: center;
  justify-content: center;
}
#backToTop:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(244,162,97,0.4);
}
#backToTop:active {
  transform: scale(0.92);
}

/* ── GPU 加速弹窗 ── */
.modal-overlay {
  will-change: opacity;
}
.modal-content {
  will-change: transform, opacity;
}

/* ── 减少动画偏好 ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .fade-in { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}
