/* ============================================
   武汉全心联 - 清爽蓝白主题
   ============================================ */

:root {
  /* 主色调 - 清爽蓝色 */
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #3b82f6;
  --primary-ultra-light: #dbeafe;
  --primary-gradient: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
  
  /* 辅助色 */
  --accent: #06b6d4;
  --accent-light: #67e8f9;
  
  /* 状态色 */
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  
  /* 背景 - 白色系 */
  --bg-main: #ffffff;
  --bg-alt: #f8fafc;
  --bg-section: #f1f5f9;
  --bg-card: #ffffff;
  
  /* 文字 */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  
  /* 边框 */
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  
  /* 阴影 */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.12);
  --shadow-blue: 0 4px 16px rgba(37, 99, 235, 0.15);
  
  /* 圆角 */
  --radius-sm: 6px;
  --radius: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  
  /* 间距 */
  --space-xs: 4px;
  --space-sm: 8px;
  --space: 16px;
  --space-md: 24px;
  --space-lg: 32px;
  --space-xl: 48px;
  --space-2xl: 80px;
  --space-3xl: 120px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg-main);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--primary-dark);
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

/* ============================================
   Header - 简洁顶部导航
   ============================================ */
.header {
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: all 0.3s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary) !important;
  letter-spacing: -0.3px;
  white-space: nowrap;
}

.logo:hover {
  color: var(--primary-dark) !important;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0;
  flex: 1;
  justify-content: center;
}

.nav a {
  color: var(--text-secondary) !important;
  font-size: 14px;
  padding: 8px 8px;
  border-radius: var(--radius);
  transition: all 0.2s ease;
  font-weight: 500;
  text-decoration: none !important;
  white-space: nowrap;
  display: inline-block;
}

.nav a:hover,
.nav a.active {
  color: var(--primary) !important;
  background: var(--primary-ultra-light);
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-btn {
  color: var(--text-secondary) !important;
  font-size: 14px;
  padding: 8px 12px;
  border-radius: var(--radius);
  transition: all 0.2s ease;
  font-weight: 500;
  text-decoration: none !important;
  white-space: nowrap;
  cursor: pointer;
  display: inline-block;
}

.nav-dropdown-btn:hover {
  color: var(--primary) !important;
  background: var(--primary-ultra-light);
}

.nav-dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: var(--space-sm);
  min-width: 120px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-dropdown:hover .nav-dropdown-content {
  opacity: 1;
  visibility: visible;
}

.nav-dropdown-content a {
  display: block;
  padding: 8px 12px;
  color: var(--text-secondary) !important;
  font-size: 13px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.nav-dropdown-content a:hover {
  background: var(--primary-ultra-light);
  color: var(--primary) !important;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: var(--space);
}

.user-bar {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 13px;
}

.btn-sm {
  padding: var(--space-xs) var(--space);
  font-size: 13px;
}

.btn-outline {
  background: transparent !important;
  border: 1px solid var(--border) !important;
  color: var(--text-secondary) !important;
  padding: 6px 14px !important;
  border-radius: var(--radius-md) !important;
  font-weight: 500 !important;
  transition: all 0.2s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 14px !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  line-height: 1.4 !important;
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-ultra-light);
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-md);
  font-weight: 600;
  border: none;
  transition: all 0.2s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-blue);
}

@media (max-width: 768px) {
  .nav {
    display: none;
  }
  
  .logo {
    font-size: 14px;
  }
}

/* ============================================
   Hero Section - 左右分栏布局
   ============================================ */
.hero-section {
  background: var(--bg-main);
  padding: var(--space-3xl) 0;
  position: relative;
  overflow: hidden;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
  align-items: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

@media (max-width: 968px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    text-align: center;
  }
}

.hero-text {
  max-width: 600px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  background: var(--primary-ultra-light);
  padding: var(--space-sm) var(--space);
  border-radius: var(--radius-full);
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  margin-bottom: var(--space-lg);
}

.hero-title {
  font-size: 52px;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.15;
  letter-spacing: -1.5px;
  margin-bottom: var(--space);
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 36px;
  }
}

.hero-subtitle {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: var(--space-xl);
  line-height: 1.7;
}

.hero-search {
  display: flex;
  gap: var(--space-sm);
  max-width: 500px;
  margin-bottom: var(--space-lg);
}

@media (max-width: 968px) {
  .hero-search {
    max-width: 100%;
  }
}

.hero-search input {
  flex: 1;
  padding: var(--space) var(--space-md);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 15px;
  transition: all 0.2s ease;
  background: white;
}

.hero-search input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-ultra-light);
}

.hero-search .btn-search {
  background: var(--primary-gradient);
  color: white;
  border: none;
  padding: var(--space) var(--space-xl);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.hero-search .btn-search:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-blue);
}

.hero-stats {
  display: flex;
  gap: var(--space-xl);
  margin-top: var(--space-xl);
}

@media (max-width: 968px) {
  .hero-stats {
    justify-content: center;
  }
}

.stat-item {
  text-align: left;
}

@media (max-width: 968px) {
  .stat-item {
    text-align: center;
  }
}

.stat-number {
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1;
}

.stat-label {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: var(--space-xs);
}

/* Hero 右侧装饰 */
.hero-visual {
  position: relative;
  height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-illustration {
  width: 100%;
  max-width: 500px;
  position: relative;
}

.illustration-bg {
  width: 100%;
  height: 400px;
  background: linear-gradient(135deg, var(--primary-ultra-light) 0%, #e0f2fe 100%);
  border-radius: var(--radius-xl);
  position: relative;
  overflow: hidden;
}

.illustration-card {
  position: absolute;
  background: white;
  border-radius: var(--radius-md);
  padding: var(--space-md);
  box-shadow: var(--shadow-md);
  animation: float 6s ease-in-out infinite;
}

.illustration-card:nth-child(1) {
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.illustration-card:nth-child(2) {
  top: 40%;
  right: 10%;
  animation-delay: 2s;
}

.illustration-card:nth-child(3) {
  bottom: 15%;
  left: 20%;
  animation-delay: 4s;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

.card-icon {
  width: 40px;
  height: 40px;
  background: var(--primary-ultra-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-bottom: var(--space-sm);
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.card-text {
  font-size: 12px;
  color: var(--text-muted);
}

/* ============================================
   分类区域 - 横向滚动卡片
   ============================================ */
.categories-section {
  background: var(--bg-section);
  padding: var(--space-2xl) 0;
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.section-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
  letter-spacing: -0.5px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
}

.categories-scroll {
  display: flex;
  gap: var(--space);
  overflow-x: auto;
  padding: var(--space) 0;
  scrollbar-width: none;
}

.categories-scroll::-webkit-scrollbar {
  display: none;
}

.category-card {
  flex: 0 0 200px;
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  text-align: center;
  transition: all 0.3s ease;
  border: 1px solid var(--border-light);
  cursor: pointer;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-ultra-light);
}

.category-icon {
  font-size: 40px;
  margin-bottom: var(--space);
  display: block;
}

.category-card h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
}

.category-card p {
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================
   CTA Section - 号召性区域
   ============================================ */
.cta-section {
  background: var(--bg-main);
  padding: var(--space-2xl) 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.cta-content {
  position: relative;
  z-index: 1;
}

.cta-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.cta-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
}

.cta-buttons {
  display: flex;
  justify-content: center;
  gap: var(--space);
}

.btn {
  display: inline-block;
  padding: var(--space) var(--space-xl);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 15px;
  text-align: center;
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
}

.btn-white {
  background: var(--primary-gradient);
  color: white;
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-blue);
}

.btn-outline-white {
  background: transparent;
  color: var(--text-secondary);
  border: 2px solid var(--border);
}

.btn-outline-white:hover {
  background: var(--primary-ultra-light);
  border-color: var(--primary);
  color: var(--primary);
}

/* 随机信息展示 */
.random-products {
  margin-top: var(--space-xl);
}

.random-products-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}

@media (max-width: 768px) {
  .random-products-list {
    grid-template-columns: 1fr;
  }
}

.random-product-card {
  display: flex;
  flex-direction: column;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.3s ease;
  text-decoration: none;
}

.random-product-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  border-color: var(--primary-ultra-light);
}

.random-product-image {
  width: 100%;
  height: 200px;
  background: var(--bg-section);
  overflow: hidden;
  flex-shrink: 0;
}

.random-product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.random-product-card .placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
}

.random-product-info {
  padding: var(--space-md);
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.random-product-title {
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.random-product-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
}

.random-product-category {
  display: inline-block;
  color: var(--success);
  font-size: 14px;
  font-weight: 500;
}

.random-product-desc {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.8;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============================================
   Footer
   ============================================ */
.footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: var(--space-xl) 0 var(--space);
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
}

.footer-section h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space);
}

.footer-section p,
.footer-section a {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 2;
}

.footer-section a:hover {
  color: var(--primary);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: var(--space);
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
}

/* ============================================
   通用组件
   ============================================ */

/* 表单 */
input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select {
  width: 100%;
  padding: var(--space) var(--space-md);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 15px;
  transition: all 0.2s ease;
  background: white;
  color: var(--text-primary);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-ultra-light);
}

/* Toast */
.toast {
  position: fixed;
  top: var(--space-lg);
  right: var(--space-lg);
  background: white;
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-lg);
  box-shadow: var(--shadow-lg);
  z-index: 9999;
  animation: slideIn 0.3s ease;
  display: flex;
  align-items: center;
  gap: var(--space);
}

.toast.success {
  border-left: 4px solid var(--success);
}

.toast.error {
  border-left: 4px solid var(--danger);
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* 空状态 */
.empty-state {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-2xl) var(--space);
  text-align: center;
}

.empty-state svg {
  width: 80px;
  height: 80px;
  color: var(--text-muted);
  margin-bottom: var(--space-lg);
}

.empty-state h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: var(--space-sm);
}

.empty-state p {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
}
