/* ===== 微医通官网自定义样式 ===== */

:root {
  --primary: #1677ff;
  --primary-dark: #0958d9;
  --primary-light: #e6f4ff;
  --accent: #00c6a7;
  --accent-light: #e6fffb;
  --text: #0a1f44;
  --text-secondary: #4b5b7c;
  --bg: #ffffff;
  --bg-soft: #f6f9fc;
  --border: #e2e8f0;
  --shadow: 0 10px 40px rgba(22, 119, 255, 0.08);
  --shadow-lg: 0 20px 60px rgba(22, 119, 255, 0.14);
  --radius: 16px;
  --radius-sm: 12px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

/* Utilities */
.gradient-text {
  background: linear-gradient(135deg, #1677ff 0%, #00b4ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-bg {
  background: linear-gradient(135deg, #1677ff 0%, #00b4ff 100%);
}

.gradient-bg-soft {
  background: linear-gradient(180deg, #f0f8ff 0%, #ffffff 100%);
}

.bg-primary {
  background-color: var(--primary);
}

.text-primary {
  color: var(--primary);
}

.bg-soft {
  background-color: var(--bg-soft);
}

.section-padding {
  padding-top: 6rem;
  padding-bottom: 6rem;
}

@media (max-width: 768px) {
  .section-padding {
    padding-top: 4rem;
    padding-bottom: 4rem;
  }
}

/* Buttons */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  background: linear-gradient(135deg, #1677ff 0%, #00b4ff 100%);
  color: white;
  font-weight: 600;
  border-radius: 9999px;
  transition: all 0.3s ease;
  box-shadow: 0 8px 24px rgba(22, 119, 255, 0.28);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(22, 119, 255, 0.36);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  border: 1.5px solid var(--primary);
  color: var(--primary);
  font-weight: 600;
  border-radius: 9999px;
  transition: all 0.3s ease;
  background: white;
}

.btn-outline:hover {
  background: var(--primary-light);
}

/* Cards */
.feature-card {
  background: white;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 1.75rem;
  transition: all 0.35s ease;
  height: 100%;
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(22, 119, 255, 0.15);
}

.icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(226, 232, 240, 0.6);
  transition: all 0.3s ease;
}

.site-header.scrolled {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.nav-link {
  position: relative;
  color: var(--text);
  font-weight: 500;
  padding: 0.5rem 0;
  transition: color 0.3s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
  border-radius: 2px;
}

.nav-link:hover {
  color: var(--primary);
}

.nav-link:hover::after {
  width: 100%;
}

/* Hero */
.hero-section {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #f0f8ff 0%, #e6f7ff 50%, #ffffff 100%);
  padding-top: 8rem;
  padding-bottom: 6rem;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: -10%;
  right: -5%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(22, 119, 255, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-section::after {
  content: "";
  position: absolute;
  bottom: -15%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 196, 167, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: white;
  border: 1px solid rgba(22, 119, 255, 0.15);
  border-radius: 9999px;
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(22, 119, 255, 0.08);
}

.hero-image {
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(22, 119, 255, 0.1);
}

/* Pain points */
.pain-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  border-left: 4px solid var(--primary);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease;
}

.pain-card:hover {
  transform: translateX(6px);
}

/* Process */
.process-step {
  position: relative;
  text-align: center;
}

.process-step::after {
  content: "";
  position: absolute;
  top: 28px;
  right: -50%;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, #1677ff 0%, #00b4ff 100%);
  opacity: 0.3;
}

.process-step:last-child::after {
  display: none;
}

@media (max-width: 1024px) {
  .process-step::after {
    display: none;
  }
}

.step-number {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1677ff 0%, #00b4ff 100%);
  color: white;
  font-weight: 700;
  font-size: 1.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  box-shadow: 0 8px 20px rgba(22, 119, 255, 0.25);
}

/* Stats */
.stat-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.stat-number {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* Section titles */
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
}

.section-title {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 1rem;
}

@media (max-width: 768px) {
  .section-title {
    font-size: 1.75rem;
  }
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1.125rem;
  max-width: 700px;
}

/* AI section */
.ai-flow-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  text-align: center;
  position: relative;
  transition: all 0.3s ease;
}

.ai-flow-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(22, 119, 255, 0.2);
}

.ai-flow-card .step-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
}

/* Company */
.company-card {
  background: white;
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.honor-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--bg-soft);
  border-radius: 9999px;
  color: var(--text);
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid var(--border);
}

/* Footer */
.site-footer {
  background: #06152b;
  color: #a8b6ce;
}

.site-footer h4 {
  color: white;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.site-footer a {
  color: #a8b6ce;
  transition: color 0.3s ease;
}

.site-footer a:hover {
  color: white;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 2rem;
  margin-top: 3rem;
}

.qr-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1rem;
  padding: 1.25rem;
  text-align: center;
}

.qr-image {
  width: 10rem;
  height: 10rem;
  object-fit: contain;
  background: white;
  border-radius: 0.75rem;
  padding: 0.5rem;
  margin: 0 auto 0.875rem;
  display: block;
}

.qr-tip {
  color: white;
  font-weight: 500;
  font-size: 0.9375rem;
  margin-bottom: 0.25rem;
  white-space: nowrap;
}

.qr-sub {
  color: #94a3b8;
  font-size: 0.8125rem;
  line-height: 1.5;
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.98);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu a {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text);
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Image container */
.img-rounded {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.img-rounded img {
  width: 100%;
  height: auto;
  display: block;
}

/* Scroll reveal delays */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }

/* CTA section */
.cta-section {
  background: linear-gradient(135deg, #1677ff 0%, #00b4ff 100%);
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.cta-section::after {
  content: "";
  position: absolute;
  bottom: -50%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 50%;
}

/* Reveal animation utility */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* ===== 防重叠 / 防换行优化 ===== */

/* 关键交互元素保持单行，避免按钮、标签、导航文字折行拥挤 */
.btn-primary,
.btn-outline,
.feature-tab,
.section-label,
.nav-link,
.honor-badge,
.process-step h3 {
  white-space: nowrap;
}

/* flex 文本容器允许收缩，防止长文本把布局挤变形或溢出重叠 */
li.flex,
.flex.items-start,
.feature-panel > div,
.company-card .flex {
  min-width: 0;
}

p,
li p,
.company-card p {
  overflow-wrap: break-word;
  word-break: normal;
}

/* 标题更均衡地换行，避免末行孤字或堆叠 */
.section-title,
.hero-section h1,
#ai h2,
#value h2,
#about h2,
.company-card h3 {
  text-wrap: balance;
}

/* 卡片统一高度，避免同排卡片因文字长短不一而错位 */
.pain-card,
.feature-card,
.ai-flow-card,
.stat-card {
  height: 100%;
}

/* 移动端机构条允许换行但不重叠 */
.bg-white.border-b span {
  white-space: normal;
}
