/* ============================================
   象随陪诊官网首页样式
   基于视觉规范 v1.0
   ============================================ */

/* ---- CSS Variables (Design Tokens) ---- */
:root {
  --eleph-primary: #0E9C8C;
  --eleph-primary-hover: #0B7D70;
  --eleph-primary-active: #095C52;
  --eleph-primary-light: #E6F7F5;
  --eleph-primary-gradient: linear-gradient(135deg, #0E9C8C, #0B7D70);
  --eleph-gray-900: #1A1A2E;
  --eleph-gray-800: #2D2D3A;
  --eleph-gray-700: #4A4A5A;
  --eleph-gray-600: #6B6B7B;
  --eleph-gray-500: #8A8A9A;
  --eleph-gray-400: #A8A8B8;
  --eleph-gray-300: #C8C8D4;
  --eleph-gray-200: #E8E8EE;
  --eleph-gray-100: #F5F5F8;
  --eleph-white: #FFFFFF;
  --eleph-success: #10B981;
  --eleph-warning: #F59E0B;
  --eleph-error: #EF4444;
  --eleph-info: #3B82F6;

  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;
  --space-10: 128px;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  font-size: 16px; line-height: 1.6; color: var(--eleph-gray-700);
  background: var(--eleph-white); -webkit-font-smoothing: antialiased;
}
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; }
:focus-visible { outline: 2px solid var(--eleph-primary); outline-offset: 2px; }

/* ---- Utility ---- */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--space-5); }
.section { padding: var(--space-9) 0; }
.section-title {
  font-size: 36px; font-weight: 700; line-height: 1.25;
  color: var(--eleph-gray-900); text-align: center; margin-bottom: var(--space-3);
}
.section-subtitle {
  font-size: 18px; font-weight: 400; line-height: 1.6;
  color: var(--eleph-gray-600); text-align: center; margin-bottom: var(--space-8);
}
.highlight { color: var(--eleph-primary); }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 600; border-radius: var(--radius-full);
  transition: all 0.25s ease; white-space: nowrap;
}
.btn-primary {
  background: var(--eleph-primary); color: var(--eleph-white);
  height: 52px; padding: 0 40px; font-size: 18px;
}
.btn-primary:hover { background: var(--eleph-primary-hover); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-primary:active { background: var(--eleph-primary-active); transform: translateY(0); }
.btn-secondary {
  background: transparent; color: var(--eleph-primary);
  border: 1px solid var(--eleph-primary); height: 52px; padding: 0 40px; font-size: 18px;
}
.btn-secondary:hover { background: var(--eleph-primary-light); border-color: var(--eleph-primary-hover); color: var(--eleph-primary-hover); }
.btn-sm { height: 44px; padding: 0 32px; font-size: 16px; }
.btn-placeholder {
  background: var(--eleph-gray-200); color: var(--eleph-gray-500);
  height: 52px; padding: 0 40px; font-size: 18px; cursor: not-allowed;
}

/* ---- Header / Nav ---- */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: 72px; background: var(--eleph-white);
  transition: box-shadow 0.3s ease;
}
.header.scrolled { box-shadow: var(--shadow-sm); }
.header .container {
  display: flex; align-items: center; justify-content: space-between; height: 100%;
}
.logo { display: flex; align-items: center; height: 36px; }
.logo img { height: 100%; width: auto; }
.nav-desktop { display: flex; align-items: center; gap: var(--space-6); }
.nav-desktop a {
  font-size: 15px; font-weight: 500; color: var(--eleph-gray-700);
  padding: var(--space-2) 0; position: relative; transition: color 0.2s;
}
.nav-desktop a:hover, .nav-desktop a.active { color: var(--eleph-primary); }
.nav-desktop a.active::after {
  content: ''; position: absolute; bottom: -2px; left: 0; right: 0;
  height: 2px; background: var(--eleph-primary); border-radius: 1px;
}
.nav-cta { display: flex; gap: var(--space-3); }
.menu-toggle { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: var(--space-2); }
.menu-toggle span {
  display: block; width: 24px; height: 2px; background: var(--eleph-gray-900);
  border-radius: 1px; transition: all 0.3s ease;
}

/* Mobile drawer */
.nav-drawer {
  position: fixed; top: 0; right: -280px; width: 280px; height: 100vh;
  background: var(--eleph-white); z-index: 1001;
  box-shadow: var(--shadow-lg); transition: right 0.3s ease;
  padding: var(--space-7) var(--space-5);
}
.nav-drawer.open { right: 0; }
.nav-drawer-close {
  position: absolute; top: var(--space-4); right: var(--space-4);
  width: 32px; height: 32px; display: flex; align-items: center; justify-content: center;
  font-size: 24px; color: var(--eleph-gray-700); cursor: pointer;
}
.nav-drawer a {
  display: block; font-size: 16px; font-weight: 500; color: var(--eleph-gray-700);
  padding: var(--space-3) var(--space-2); border-bottom: 1px solid var(--eleph-gray-200);
}
.nav-drawer a:hover { color: var(--eleph-primary); }
.nav-drawer .nav-cta { flex-direction: column; margin-top: var(--space-5); gap: var(--space-3); }
.drawer-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
  z-index: 1000; opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.drawer-overlay.open { opacity: 1; pointer-events: auto; }

/* ---- Hero Section ---- */
.hero {
  min-height: 100vh; display: flex; align-items: center;
  background:
    linear-gradient(180deg, rgba(230,247,245,0.85) 0%, rgba(255,255,255,0.95) 100%),
    url('../images/hero-bg.jpg') center/cover no-repeat;
  padding-top: 72px; position: relative; overflow: hidden;
}
.hero-content { text-align: center; max-width: 800px; margin: 0 auto; padding: var(--space-8) var(--space-5); }
.hero-badge {
  display: inline-flex; align-items: center; gap: var(--space-2);
  background: var(--eleph-white); border: 1px solid var(--eleph-primary-light);
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-full);
  font-size: 14px; color: var(--eleph-primary); margin-bottom: var(--space-6);
  box-shadow: var(--shadow-sm);
}
.hero-badge svg { width: 16px; height: 16px; }
.hero-title {
  font-size: 48px; font-weight: 700; line-height: 1.2; color: var(--eleph-gray-900);
  margin-bottom: var(--space-4);
}
.hero-subtitle {
  font-size: 20px; font-weight: 400; line-height: 1.6; color: var(--eleph-gray-600);
  margin-bottom: var(--space-7);
}
.hero-cta { display: flex; gap: var(--space-4); justify-content: center; flex-wrap: wrap; }
.hero-decoration {
  position: absolute; border-radius: 50%; opacity: 0.08; pointer-events: none;
}
.hero-decoration.d1 { width: 400px; height: 400px; background: var(--eleph-primary); top: -100px; right: -100px; }
.hero-decoration.d2 { width: 300px; height: 300px; background: var(--eleph-primary); bottom: -80px; left: -80px; }
.hero-decoration.d3 { width: 150px; height: 150px; background: var(--eleph-primary); top: 40%; left: 10%; }

/* ---- Pain Points Section ---- */
.painpoints { background: var(--eleph-gray-100); }
.painpoints-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-5);
}
.painpoint-card {
  background: var(--eleph-white); border-radius: var(--radius-lg);
  padding: var(--space-6); box-shadow: var(--shadow-sm);
  border: 1px solid var(--eleph-gray-200); transition: all 0.3s ease;
}
.painpoint-card:hover { box-shadow: var(--shadow-md); border-color: var(--eleph-primary); }
.painpoint-header {
  display: flex; align-items: center; gap: var(--space-3); margin-bottom: var(--space-4);
}
.painpoint-icon {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.painpoint-icon.pain { background: #FEF3C7; color: var(--eleph-warning); }
.painpoint-icon.solution { background: var(--eleph-primary-light); color: var(--eleph-primary); }
.painpoint-icon svg { width: 24px; height: 24px; }
.painpoint-label {
  font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px;
  margin-bottom: var(--space-1);
}
.painpoint-label.pain { color: var(--eleph-warning); }
.painpoint-label.solution { color: var(--eleph-primary); }
.painpoint-title { font-size: 18px; font-weight: 600; color: var(--eleph-gray-900); }
.painpoint-desc { font-size: 15px; color: var(--eleph-gray-600); line-height: 1.6; }
.painpoint-arrow {
  display: flex; justify-content: center; margin: var(--space-2) 0; color: var(--eleph-primary);
}
.painpoint-arrow svg { width: 20px; height: 20px; }

/* ---- Services Section ---- */
.services-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5);
}
.service-card {
  background: var(--eleph-white); border: 1px solid var(--eleph-gray-200);
  border-radius: var(--radius-lg); padding: var(--space-6); text-align: center;
  box-shadow: var(--shadow-sm); transition: all 0.3s ease; cursor: pointer;
}
.service-card:hover { box-shadow: var(--shadow-md); border-color: var(--eleph-primary); transform: translateY(-4px); }
.service-icon {
  width: 64px; height: 64px; border-radius: var(--radius-lg);
  background: var(--eleph-primary-light); color: var(--eleph-primary);
  display: flex; align-items: center; justify-content: center; margin: 0 auto var(--space-4);
}
.service-icon svg { width: 32px; height: 32px; }
.service-name { font-size: 20px; font-weight: 600; color: var(--eleph-gray-900); margin-bottom: var(--space-2); }
.service-desc { font-size: 14px; color: var(--eleph-gray-600); line-height: 1.5; }

/* ---- Process Section ---- */
.process { background: var(--eleph-gray-100); }
.process-steps {
  display: flex; justify-content: space-between; position: relative; max-width: 1000px; margin: 0 auto;
}
.process-steps::before {
  content: ''; position: absolute; top: 28px; left: 60px; right: 60px;
  height: 2px; background: linear-gradient(90deg, var(--eleph-primary), var(--eleph-primary-light));
}
.process-step {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  position: relative; z-index: 1; flex: 1; max-width: 180px;
}
.process-step-num {
  width: 56px; height: 56px; border-radius: 50%; background: var(--eleph-white);
  border: 2px solid var(--eleph-primary); color: var(--eleph-primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 700; margin-bottom: var(--space-4);
  box-shadow: var(--shadow-sm);
}
.process-step-title { font-size: 16px; font-weight: 600; color: var(--eleph-gray-900); margin-bottom: var(--space-1); }
.process-step-desc { font-size: 13px; color: var(--eleph-gray-600); line-height: 1.5; }

/* ---- Advantages Section ---- */
.advantages-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5);
}
.advantage-card {
  background: var(--eleph-white); border-radius: var(--radius-lg);
  padding: var(--space-6); text-align: center; transition: all 0.3s ease;
}
.advantage-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.advantage-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--eleph-primary-light); color: var(--eleph-primary);
  display: flex; align-items: center; justify-content: center; margin: 0 auto var(--space-4);
}
.advantage-icon svg { width: 28px; height: 28px; }
.advantage-name { font-size: 20px; font-weight: 600; color: var(--eleph-gray-900); margin-bottom: var(--space-2); }
.advantage-desc { font-size: 15px; color: var(--eleph-gray-600); line-height: 1.6; }

/* ---- Onboarding Section ---- */
.onboarding { background: var(--eleph-gray-100); }
.onboarding-content {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); align-items: center;
}
.onboarding-info h3 {
  font-size: 28px; font-weight: 700; color: var(--eleph-gray-900); margin-bottom: var(--space-4);
}
.onboarding-info p { font-size: 16px; color: var(--eleph-gray-600); line-height: 1.7; margin-bottom: var(--space-5); }
.onboarding-steps { display: flex; flex-direction: column; gap: var(--space-4); }
.onboarding-step {
  display: flex; align-items: flex-start; gap: var(--space-4);
  background: var(--eleph-white); padding: var(--space-5); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.onboarding-step-num {
  width: 40px; height: 40px; border-radius: 50%; background: var(--eleph-primary);
  color: var(--eleph-white); display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 700; flex-shrink: 0;
}
.onboarding-step-title { font-size: 18px; font-weight: 600; color: var(--eleph-gray-900); margin-bottom: var(--space-1); }
.onboarding-step-desc { font-size: 14px; color: var(--eleph-gray-600); line-height: 1.5; }

/* ---- About Section ---- */
.about-content {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); align-items: center;
}
.about-text h3 {
  font-size: 28px; font-weight: 700; color: var(--eleph-gray-900); margin-bottom: var(--space-4);
}
.about-text p { font-size: 16px; color: var(--eleph-gray-600); line-height: 1.7; margin-bottom: var(--space-4); }
.about-placeholder {
  background: linear-gradient(135deg, var(--eleph-primary-light), var(--eleph-gray-100));
  border: 1px dashed var(--eleph-gray-300); border-radius: var(--radius-lg);
  padding: var(--space-7) var(--space-5); text-align: center;
}
.about-placeholder-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--eleph-white); color: var(--eleph-gray-400);
  display: flex; align-items: center; justify-content: center; margin: 0 auto var(--space-4);
  box-shadow: var(--shadow-sm);
}
.about-placeholder-icon svg { width: 28px; height: 28px; }
.about-placeholder-title { font-size: 18px; font-weight: 600; color: var(--eleph-gray-700); margin-bottom: var(--space-2); }
.about-placeholder-desc { font-size: 14px; color: var(--eleph-gray-500); }

/* ---- Footer ---- */
.footer {
  background: var(--eleph-gray-900); color: var(--eleph-gray-400); padding: var(--space-8) 0 var(--space-5);
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--space-6); margin-bottom: var(--space-7);
}
.footer-brand .logo { height: 32px; margin-bottom: var(--space-3); }
.footer-brand .logo img { filter: brightness(0) invert(1); }
.footer-brand p { font-size: 14px; line-height: 1.6; color: var(--eleph-gray-500); }
.footer-col h4 {
  font-size: 14px; font-weight: 600; color: var(--eleph-white); margin-bottom: var(--space-4);
  text-transform: uppercase; letter-spacing: 0.5px;
}
.footer-col a {
  display: block; font-size: 14px; color: var(--eleph-gray-500); margin-bottom: var(--space-3);
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--eleph-primary); }
.footer-bottom {
  border-top: 1px solid var(--eleph-gray-800); padding-top: var(--space-5);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: var(--space-3);
}
.footer-bottom p { font-size: 13px; color: var(--eleph-gray-500); }
.footer-bottom a { color: var(--eleph-gray-400); text-decoration: underline; }
.footer-bottom a:hover { color: var(--eleph-primary); }

/* ---- Modal / Popup ---- */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
  z-index: 2000; display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.3s ease;
}
.modal-overlay.active { opacity: 1; pointer-events: auto; }
.modal {
  background: var(--eleph-white); border-radius: var(--radius-xl);
  padding: var(--space-7) var(--space-6); max-width: 480px; width: 90%;
  box-shadow: var(--shadow-lg); transform: translateY(20px); transition: transform 0.3s ease;
  text-align: center;
}
.modal-overlay.active .modal { transform: translateY(0); }
.modal-icon {
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--eleph-primary-light); color: var(--eleph-primary);
  display: flex; align-items: center; justify-content: center; margin: 0 auto var(--space-4);
}
.modal-icon svg { width: 32px; height: 32px; }
.modal-title { font-size: 22px; font-weight: 700; color: var(--eleph-gray-900); margin-bottom: var(--space-3); }
.modal-desc { font-size: 15px; color: var(--eleph-gray-600); line-height: 1.6; margin-bottom: var(--space-5); }
.modal-close {
  background: var(--eleph-gray-100); color: var(--eleph-gray-700);
  height: 44px; padding: 0 32px; border-radius: var(--radius-full);
  font-size: 15px; font-weight: 600;
}
.modal-close:hover { background: var(--eleph-gray-200); }

/* ---- Scroll to top ---- */
.scroll-top {
  position: fixed; bottom: var(--space-5); right: var(--space-5);
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--eleph-primary); color: var(--eleph-white);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md); z-index: 999;
  opacity: 0; pointer-events: none; transition: all 0.3s ease;
}
.scroll-top.visible { opacity: 1; pointer-events: auto; }
.scroll-top:hover { background: var(--eleph-primary-hover); transform: translateY(-2px); }
.scroll-top svg { width: 20px; height: 20px; }

/* ============================================
   Responsive: Tablet (768px - 1023px)
   ============================================ */
@media (max-width: 1023px) {
  .container { padding: 0 var(--space-4); }
  .section { padding: var(--space-7) 0; }
  .section-title { font-size: 28px; }
  .section-subtitle { font-size: 16px; margin-bottom: var(--space-6); }
  .hero-title { font-size: 36px; }
  .hero-subtitle { font-size: 18px; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .advantages-grid { grid-template-columns: repeat(2, 1fr); }
  .about-content, .onboarding-content { grid-template-columns: 1fr; gap: var(--space-6); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================
   Responsive: Mobile (<= 767px)
   ============================================ */
@media (max-width: 767px) {
  .container { padding: 0 var(--space-4); }
  .section { padding: var(--space-7) 0; }
  .section-title { font-size: 28px; }
  .section-subtitle { font-size: 16px; margin-bottom: var(--space-6); }

  .header { height: 64px; }
  .nav-desktop, .nav-cta { display: none; }
  .menu-toggle { display: flex; }
  .logo { height: 32px; }

  .hero { padding-top: 64px; min-height: auto; }
  .hero-content { padding: var(--space-7) var(--space-4); }
  .hero-title { font-size: 32px; }
  .hero-subtitle { font-size: 16px; }
  .hero-cta { flex-direction: column; align-items: center; }
  .hero-cta .btn { width: 100%; max-width: 280px; }

  .painpoints-grid { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: 1fr; }
  .advantages-grid { grid-template-columns: 1fr; }
  .process-steps { flex-direction: column; gap: var(--space-6); }
  .process-steps::before { display: none; }
  .process-step { max-width: 100%; }

  .about-content, .onboarding-content { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: var(--space-5); }
  .footer-bottom { flex-direction: column; text-align: center; }

  .hero-decoration.d1 { width: 200px; height: 200px; }
  .hero-decoration.d2 { width: 150px; height: 150px; }
  .hero-decoration.d3 { display: none; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important; animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
