/* ========== Reset & Base ========== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 14px;
  color: #333;
  background: #F5F5F5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body {
  max-width: 750px;
  margin: 0 auto;
  position: relative;
}

img {
  display: block;
  max-width: 100%;
}

button {
  border: none;
  outline: none;
  cursor: pointer;
  font-family: inherit;
}

/* ========== 主题变量 ========== */
:root {
  --primary: #0A8F6C;
  --primary-dark: #0B6E5A;
  --primary-light: #0DBFA0;
  --gradient: linear-gradient(135deg, #0DBFA0 0%, #0A6B58 100%);
  --gradient-h: linear-gradient(90deg, #0DBFA0 0%, #0A8F6C 100%);
  --cta: #FF8C00;
  --cta-gradient: linear-gradient(90deg, #FFA940 0%, #FF8C00 100%);
  --bg: #F5F5F5;
  --white: #FFFFFF;
  --text: #333333;
  --text-sec: #666666;
  --text-hint: #999999;
  --border: #EEEEEE;
  --risk-low: #52C41A;
  --risk-mid: #FAAD14;
  --risk-high: #FF4D4F;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ========== App容器 ========== */
#app {
  min-height: 100vh;
  padding-bottom: 70px;
  background: var(--bg);
}

/* ========== 底部TabBar ========== */
.tabbar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 750px;
  height: calc(56px + var(--safe-bottom));
  padding-bottom: var(--safe-bottom);
  background: var(--white);
  display: flex;
  align-items: center;
  border-top: 1px solid #EAEAEA;
  z-index: 100;
}

.tabbar.hidden {
  display: none;
}

.tab-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 56px;
  cursor: pointer;
  color: var(--text-hint);
  transition: color 0.2s;
  -webkit-tap-highlight-color: transparent;
}

.tab-item.active {
  color: var(--primary);
}

.tab-icon {
  font-size: 22px;
  line-height: 1;
}

.tab-label {
  font-size: 10px;
  margin-top: 3px;
}

/* ========== 通用导航栏 ========== */
.nav-bar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 48px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
}

.nav-bar .back-btn {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #fff;
  font-size: 28px;
  font-weight: 300;
  padding: 4px 12px;
  cursor: pointer;
}

.nav-bar .nav-title {
  font-size: 17px;
  font-weight: 600;
  color: #fff;
}

.nav-bar .close-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255,255,255,0.85);
  font-size: 18px;
  font-weight: 400;
  padding: 4px 10px;
  cursor: pointer;
}

/* ========== 通用样式 ========== */
.card {
  background: var(--white);
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.card-sm {
  background: var(--white);
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.btn-primary {
  display: block;
  width: 100%;
  background: var(--gradient-h);
  color: #fff;
  border-radius: 24px;
  height: 48px;
  line-height: 48px;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
}

.btn-cta {
  display: block;
  width: 100%;
  background: var(--cta-gradient);
  color: #fff;
  border-radius: 24px;
  height: 48px;
  line-height: 48px;
  text-align: center;
  font-size: 16px;
  font-weight: 600;
}

.btn-outline {
  display: block;
  width: 100%;
  background: transparent;
  color: var(--primary);
  border: 1px solid var(--primary);
  border-radius: 24px;
  height: 44px;
  line-height: 42px;
  text-align: center;
  font-size: 14px;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 80px 0;
}

.empty-state .empty-emoji {
  font-size: 64px;
  margin-bottom: 12px;
}

.empty-state .empty-text {
  font-size: 14px;
  color: var(--text-hint);
}

/* ========== 首页 ========== */
.home-banner {
  background: var(--gradient);
  padding: 24px 20px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.home-banner .banner-text .banner-title {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  display: block;
}

.home-banner .banner-text .banner-subtitle {
  font-size: 14px;
  color: rgba(255,255,255,0.85);
  display: block;
  margin: 4px 0 12px;
}

.home-banner .banner-btn {
  display: inline-block;
  background: #fff;
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 18px;
  border-radius: 16px;
  cursor: pointer;
}

.home-banner .banner-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.4);
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
  flex-shrink: 0;
}

.feature-grid {
  display: flex;
  justify-content: space-around;
  margin: -24px 12px 12px;
  position: relative;
  z-index: 10;
  padding: 20px 8px;
}

.feature-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 25%;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 6px;
}

.feature-icon.i-test { background: linear-gradient(135deg, #E8F8F5, #D1F2EB); }
.feature-icon.i-book { background: linear-gradient(135deg, #FEF5E7, #FDEBD0); }
.feature-icon.i-med  { background: linear-gradient(135deg, #FDEDEC, #FADBD8); }
.feature-icon.i-edu  { background: linear-gradient(135deg, #EBF5FB, #D6EAF8); }

.feature-item .feature-name {
  font-size: 12px;
  color: var(--text);
}

.dual-cards {
  display: flex;
  gap: 10px;
  padding: 0 12px;
  margin-bottom: 12px;
}

.dual-card {
  flex: 1;
  cursor: pointer;
}

.dual-card .dc-title {
  font-size: 15px;
  font-weight: 700;
  display: block;
}

.dual-card .dc-desc {
  font-size: 11px;
  color: var(--text-hint);
  display: block;
  margin: 4px 0 8px;
}

.dual-card .dc-btn {
  display: inline-block;
  background: #E8F8F5;
  color: var(--primary);
  font-size: 11px;
  padding: 4px 10px;
  border-radius: 8px;
}

.science-section {
  padding: 0 12px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.section-title {
  font-size: 18px;
  font-weight: 700;
}

.section-more {
  font-size: 13px;
  color: var(--text-hint);
  cursor: pointer;
}

.category-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.category-tabs::-webkit-scrollbar { display: none; }

.cat-tab {
  flex-shrink: 0;
  padding: 5px 14px;
  border-radius: 14px;
  background: #F0F0F0;
  font-size: 13px;
  color: var(--text-sec);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.cat-tab.active {
  background: #E8F8F5;
  color: var(--primary);
  font-weight: 600;
}

.article-list {
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
}

.article-card {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid #F5F5F5;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.article-card:last-child { border-bottom: none; }

.article-card .ac-info {
  flex: 1;
  margin-right: 12px;
  overflow: hidden;
}

.article-card .ac-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  line-height: 1.5;
}

.article-card .ac-desc {
  font-size: 12px;
  color: var(--text-hint);
  margin-top: 6px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 1;
  overflow: hidden;
}

/* ========== 自测说明页 ========== */
.intro-container {
  padding: 12px 12px 140px;
}

.intro-card {
  padding: 20px 18px;
}

.intro-card .greeting {
  font-size: 15px;
  display: block;
  margin-bottom: 12px;
}

.intro-card .indent-text {
  font-size: 15px;
  line-height: 1.8;
  text-indent: 2em;
  display: block;
  margin-bottom: 16px;
}

.tip-box {
  background: #F8F9FA;
  border-radius: 6px;
  padding: 12px 14px;
  margin-bottom: 16px;
  font-size: 14px;
  color: var(--text-sec);
  line-height: 1.8;
}

.level-title {
  font-size: 15px;
  font-weight: 700;
  display: block;
  margin-bottom: 4px;
}

.level-desc-text {
  font-size: 14px;
  line-height: 1.8;
  display: block;
  margin-bottom: 12px;
}

.level-box {
  background: #F8F9FA;
  border-radius: 6px;
  padding: 12px 14px;
  margin-bottom: 16px;
}

.level-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 6px;
  font-size: 14px;
  line-height: 1.8;
}

.level-item:last-child { margin-bottom: 0; }

.level-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 8px;
  margin-right: 8px;
}

.level-dot.green { background: var(--risk-low); }
.level-dot.yellow { background: var(--risk-mid); }
.level-dot.red { background: var(--risk-high); }

.level-label {
  font-weight: 600;
  flex-shrink: 0;
}

.recommend-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  line-height: 1.6;
}

.bottom-fixed {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 750px;
  background: #fff;
  padding: 12px 20px calc(12px + var(--safe-bottom));
  box-shadow: 0 -2px 8px rgba(0,0,0,0.06);
  z-index: 60;
}

.history-link {
  display: block;
  text-align: center;
  font-size: 14px;
  color: var(--primary);
  margin-top: 8px;
  padding: 4px;
  cursor: pointer;
  background: none;
  border: none;
  width: 100%;
}

/* ========== 问卷页 ========== */
.progress-bar {
  height: 4px;
  background: #E8E8E8;
}

.progress-fill {
  height: 100%;
  background: var(--gradient-h);
  border-radius: 0 2px 2px 0;
  transition: width 0.3s ease;
}

.progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  font-size: 12px;
}

.progress-step {
  color: var(--primary);
  font-weight: 600;
}

.progress-label {
  color: var(--text-hint);
}

.step-container {
  padding: 6px 16px 140px;
}

.step-header {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.step-num {
  font-size: 18px;
  color: var(--primary);
  margin-right: 6px;
}

.step-title {
  font-size: 17px;
  font-weight: 700;
}

.step-desc {
  font-size: 13px;
  color: var(--text-sec);
  line-height: 1.6;
  margin-bottom: 16px;
  display: block;
}

.question-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.question-item {
  display: flex;
  align-items: flex-start;
  background: #fff;
  border-radius: 8px;
  padding: 14px 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.15s;
}

.question-item:active {
  background: #FAFAFA;
}

.q-check {
  width: 24px;
  height: 24px;
  border: 2px solid #D9D9D9;
  border-radius: 6px;
  flex-shrink: 0;
  margin-right: 10px;
  margin-top: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  font-size: 14px;
  color: transparent;
}

.q-check.checked {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.q-content .q-text {
  font-size: 15px;
  font-weight: 500;
  display: block;
  line-height: 1.5;
}

.q-content .q-desc {
  font-size: 12px;
  color: var(--text-hint);
  margin-top: 4px;
  display: block;
  line-height: 1.5;
}

/* Score questions */
.score-item {
  background: #fff;
  border-radius: 8px;
  padding: 14px 12px;
  margin-bottom: 10px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.score-index {
  font-size: 14px;
  color: var(--primary);
  font-weight: 600;
}

.score-text {
  font-size: 15px;
  display: block;
  line-height: 1.5;
  margin: 4px 0 12px;
}

.score-btns {
  display: flex;
  gap: 12px;
}

.score-btn {
  flex: 1;
  height: 40px;
  border-radius: 6px;
  border: 1px solid #D9D9D9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--text-sec);
  background: #FAFAFA;
  cursor: pointer;
  transition: all 0.2s;
}

.score-btn.active-yes {
  background: #E8F8F5;
  border-color: var(--primary);
  color: var(--primary);
  font-weight: 600;
}

.score-btn.active-no {
  background: #FFF2F0;
  border-color: var(--risk-high);
  color: var(--risk-high);
  font-weight: 600;
}

/* Upload area */
.upload-area {
  background: #fff;
  border: 2px dashed #D9D9D9;
  border-radius: 8px;
  padding: 40px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  cursor: pointer;
  min-height: 160px;
}

.upload-area .upload-icon { font-size: 40px; margin-bottom: 8px; }
.upload-area .upload-text { font-size: 15px; color: var(--text-sec); }
.upload-area .upload-hint { font-size: 12px; color: #ccc; margin-top: 4px; }

.upload-area .uploaded-img {
  max-width: 200px;
  max-height: 150px;
  border-radius: 8px;
}

.ai-coming {
  background: linear-gradient(135deg, #E8F8F5, #D1F2EB);
  border-radius: 8px;
  padding: 14px 12px;
  display: flex;
  align-items: center;
  font-size: 13px;
  color: var(--primary-dark);
}

.ai-coming .ai-badge {
  margin-right: 8px;
  flex-shrink: 0;
}

/* Required Badge */
.required-badge {
  font-size: 11px;
  color: #fff;
  background: #FF4D4F;
  padding: 2px 7px;
  border-radius: 4px;
  margin-left: 8px;
}

/* Fundus Photo Guide */
.fundus-guide {
  background: #fff;
  border-radius: 8px;
  margin-bottom: 16px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.04);
  overflow: hidden;
}

.fundus-guide-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  cursor: pointer;
}

.fundus-guide-title {
  font-size: 15px;
  font-weight: 600;
  color: #333;
}

.fundus-guide-toggle {
  font-size: 13px;
  color: var(--primary);
  font-weight: 500;
}

.fundus-guide-body {
  padding: 0 14px 14px;
}

.fundus-sample {
  margin-bottom: 12px;
}

.fundus-sample-img {
  margin-bottom: 6px;
}

.fundus-placeholder {
  background: radial-gradient(circle at 40% 45%, #FF6B3D 8%, #FF8C00 15%, #D44800 25%, #1a1a2e 35%, #1a1a2e 100%);
  border-radius: 50%;
  width: 180px;
  height: 180px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  box-shadow: 0 2px 12px rgba(0,0,0,0.15);
}

.fp-icon {
  font-size: 36px;
  margin-bottom: 4px;
}

.fp-labels {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.fp-label-item {
  font-size: 10px;
  color: rgba(255,255,255,0.9);
  line-height: 1.6;
}

.fundus-sample-caption {
  font-size: 12px;
  color: #999;
  text-align: center;
  display: block;
  margin-top: 6px;
}

.fundus-desc-box {
  font-size: 13px;
  color: #666;
  line-height: 1.7;
  margin-bottom: 12px;
  padding: 10px 12px;
  background: #F9F9F9;
  border-radius: 6px;
}

.fundus-channels {
  margin-bottom: 10px;
}

.fundus-channels-title {
  font-size: 14px;
  font-weight: 600;
  color: #333;
  display: block;
  margin-bottom: 8px;
}

.fundus-channel-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.fundus-channel-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.fc-num {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.fc-content {
  flex: 1;
}

.fc-name {
  font-size: 14px;
  font-weight: 600;
  color: #333;
  display: block;
  margin-bottom: 2px;
}

.fc-desc {
  font-size: 12px;
  color: #999;
  display: block;
  line-height: 1.5;
}

.fundus-tip {
  font-size: 12px;
  color: var(--primary-dark);
  background: #E8F8F5;
  padding: 8px 12px;
  border-radius: 6px;
  line-height: 1.6;
}

/* AI Analyze Button */
.ai-analyze-btn {
  width: 100%;
  height: 48px;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  margin: 12px 0;
  cursor: pointer;
}

.ai-analyze-btn.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* AI Analyzing Animation */
.ai-analyzing {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 24px 0;
}

.ai-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #E8E8E8;
  border-top: 3px solid #667eea;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.ai-analyzing-text {
  font-size: 15px;
  color: #667eea;
  font-weight: 600;
  margin-bottom: 4px;
}

.ai-analyzing-hint {
  font-size: 12px;
  color: #999;
}

/* AI Result Card */
.ai-result-card {
  background: #fff;
  border-radius: 8px;
  padding: 14px 12px;
  margin-top: 12px;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.12);
  border: 1px solid rgba(102, 126, 234, 0.2);
}

.ai-result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid #F0F0F0;
  margin-bottom: 8px;
}

.ai-result-title {
  font-size: 15px;
  font-weight: 700;
  color: #333;
}

.ai-confidence {
  font-size: 12px;
  color: #667eea;
  background: rgba(102, 126, 234, 0.1);
  padding: 3px 8px;
  border-radius: 10px;
}

.ai-result-item {
  padding: 8px 0;
  border-bottom: 1px solid #F8F8F8;
}

.ai-result-item.highlight {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.06) 0%, rgba(118, 75, 162, 0.06) 100%);
  margin: 8px -12px 0;
  padding: 10px 12px;
  border-bottom: none;
  border-radius: 0 0 8px 8px;
}

.ai-item-label {
  font-size: 13px;
  color: #999;
  display: block;
  margin-bottom: 4px;
}

.ai-item-value {
  font-size: 15px;
  font-weight: 600;
  display: block;
  margin-bottom: 3px;
}

.ai-item-value.normal { color: #52C41A; }
.ai-item-value.warning { color: #FAAD14; }
.ai-item-value.info { color: #1890FF; }

.ai-item-note {
  font-size: 12px;
  color: #999;
  display: block;
  line-height: 1.5;
}

.ai-disclaimer {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #F0F0F0;
  font-size: 11px;
  color: #ccc;
  line-height: 1.6;
}

.ai-risk-text {
  font-size: 13px !important;
}

/* Bottom nav buttons */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 750px;
  background: #fff;
  padding: 10px 16px calc(10px + var(--safe-bottom));
  box-shadow: 0 -2px 8px rgba(0,0,0,0.06);
  display: flex;
  gap: 12px;
  z-index: 60;
}

.nav-btn {
  flex: 1;
  height: 44px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
}

.nav-btn.prev { background: #F5F5F5; color: var(--text-sec); }
.nav-btn.prev.disabled { opacity: 0.4; pointer-events: none; }
.nav-btn.next { background: var(--gradient-h); color: #fff; }
.nav-btn.submit { background: var(--cta-gradient); color: #fff; font-weight: 600; }

/* ========== 结果页 ========== */
.result-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 36px 0 28px;
}

.circle-chart {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 4px solid;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  background: #fff;
}

.circle-level {
  font-size: 24px;
  font-weight: 700;
}

.result-title {
  font-size: 18px;
  font-weight: 700;
}

.stats-row {
  display: flex;
  background: #fff;
  margin: 0 12px 12px;
  border-radius: 8px;
  padding: 16px 0;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

.stat-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-num {
  font-size: 20px;
  font-weight: 700;
}

.stat-label {
  font-size: 12px;
  color: var(--text-hint);
  margin-top: 4px;
}

.stat-divider {
  width: 1px;
  height: 30px;
  background: var(--border);
  align-self: center;
}

.result-card, .suggest-card {
  margin: 0 12px 12px;
}

.result-card .card-title, .suggest-card .card-title {
  font-size: 16px;
  font-weight: 700;
  display: block;
  margin-bottom: 10px;
}

.result-card .card-desc {
  font-size: 14px;
  color: var(--text-sec);
  line-height: 1.8;
}

.suggest-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.suggest-item {
  display: flex;
  align-items: flex-start;
}

.suggest-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 7px;
  margin-right: 8px;
}

.suggest-text {
  font-size: 14px;
  color: #555;
  line-height: 1.6;
}

.disclaimer {
  margin: 0 12px 12px;
  padding: 12px;
  background: #FFF7E6;
  border-radius: 6px;
  font-size: 12px;
  color: #D48806;
  line-height: 1.6;
}

.result-btns {
  padding: 12px 20px 20px;
}

.btn-row {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}

.btn-row .btn-outline {
  flex: 1;
  height: 40px;
  line-height: 38px;
  font-size: 14px;
}

.redo-link {
  display: block;
  text-align: center;
  font-size: 14px;
  color: var(--text-hint);
  margin-top: 12px;
  cursor: pointer;
  background: none;
  border: none;
  width: 100%;
}

/* ========== 自测记录 ========== */
.history-list {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.history-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

.hi-date {
  font-size: 15px;
  font-weight: 600;
  display: block;
}

.hi-info {
  font-size: 12px;
  color: var(--text-hint);
  margin-top: 4px;
  display: block;
}

.hi-right {
  display: flex;
  align-items: center;
}

.hi-level {
  font-size: 15px;
  font-weight: 700;
  margin-right: 4px;
}

.hi-arrow {
  font-size: 16px;
  color: #ccc;
}

/* ========== 用药管理 ========== */
.med-tabs {
  display: flex;
  background: #fff;
  border-bottom: 1px solid var(--border);
}

.med-tab {
  flex: 1;
  text-align: center;
  padding: 14px 0 10px;
  font-size: 15px;
  color: var(--text-sec);
  cursor: pointer;
  position: relative;
  -webkit-tap-highlight-color: transparent;
}

.med-tab.active {
  color: var(--primary);
  font-weight: 600;
}

.med-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

.calendar-card {
  margin: 12px;
}

.cal-header {
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 10px;
}

.cal-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  margin-bottom: 6px;
}

.cal-weekdays span {
  text-align: center;
  font-size: 12px;
  color: var(--text-hint);
}

.cal-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.day-cell {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  border-radius: 6px;
  position: relative;
}

.day-cell.today {
  background: #E8F8F5;
  color: var(--primary);
  font-weight: 600;
}

.day-cell.checked {
  background: var(--primary);
  color: #fff;
}

.day-cell .check-mark {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  bottom: 3px;
}

.med-today {
  padding: 12px;
}

.med-today-title {
  font-size: 16px;
  font-weight: 700;
  display: block;
  margin-bottom: 10px;
}

.med-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.med-name {
  font-size: 15px;
  font-weight: 500;
  display: block;
}

.med-dosage {
  font-size: 12px;
  color: var(--text-hint);
  margin-top: 2px;
  display: block;
}

.med-check-btn {
  padding: 6px 14px;
  border-radius: 14px;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  cursor: pointer;
  border: none;
}

.med-check-btn.done {
  background: #E8F8F5;
  color: var(--primary);
}

/* ========== 疾病百科 ========== */
.wiki-banner {
  background: var(--gradient);
  padding: 20px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wiki-banner .wb-label { font-size: 12px; color: rgba(255,255,255,0.8); display: block; }
.wiki-banner .wb-title { font-size: 19px; font-weight: 700; color: #fff; display: block; margin: 4px 0 6px; }
.wiki-banner .wb-desc { font-size: 11px; color: rgba(255,255,255,0.75); line-height: 1.6; display: block; white-space: pre-line; }
.wiki-banner .wb-avatar { font-size: 48px; }

.wiki-tabs {
  display: flex;
  background: #fff;
  padding: 0 12px;
  border-bottom: 1px solid #F0F0F0;
}

.wiki-tab {
  padding: 12px 10px 8px;
  font-size: 15px;
  color: var(--text-sec);
  cursor: pointer;
  position: relative;
  margin-right: 12px;
  -webkit-tap-highlight-color: transparent;
}

.wiki-tab.active {
  color: var(--primary);
  font-weight: 700;
}

.wiki-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 3px;
  background: var(--primary);
  border-radius: 2px;
}

/* ========== 文章详情 ========== */
.detail-container {
  padding: 16px;
}

.detail-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.4;
  display: block;
  margin-bottom: 12px;
}

.detail-meta {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.meta-tag {
  font-size: 11px;
  color: var(--primary);
  background: #E8F8F5;
  padding: 3px 8px;
  border-radius: 4px;
  margin-right: 8px;
}

.meta-source {
  font-size: 12px;
  color: var(--text-hint);
}

.detail-content {
  font-size: 15px;
  color: #444;
  line-height: 2;
  white-space: pre-wrap;
  margin-bottom: 24px;
}

.detail-footer {
  padding: 12px;
  background: #FFF7E6;
  border-radius: 6px;
  font-size: 12px;
  color: #D48806;
  line-height: 1.6;
  margin-bottom: 20px;
}

/* ========== 个人中心 ========== */
.profile-header {
  background: var(--gradient);
  padding: 40px 16px 24px;
}

.user-row {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.user-avatar {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin-right: 12px;
}

.user-info { flex: 1; }

.user-name {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}

.invite-badge {
  background: rgba(255,255,255,0.25);
  color: #fff;
  font-size: 11px;
  padding: 5px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.5);
  cursor: pointer;
}

.profile-stats {
  display: flex;
  background: rgba(255,255,255,0.15);
  border-radius: 8px;
  padding: 14px 0;
}

.ps-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.ps-label {
  font-size: 12px;
  color: rgba(255,255,255,0.8);
}

.ps-value {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
  margin-top: 4px;
}

.menu-list {
  margin: 12px;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
}

.menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 14px;
  border-bottom: 1px solid #F5F5F5;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

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

.mi-left {
  display: flex;
  align-items: center;
}

.mi-icon {
  font-size: 20px;
  margin-right: 10px;
}

.mi-name {
  font-size: 15px;
}

.mi-arrow {
  font-size: 18px;
  color: #ccc;
}

.version-info {
  text-align: center;
  padding: 20px;
  font-size: 12px;
  color: #ccc;
}

/* ========== 用药管理 - 预约挂号入口 ========== */
.mbs-hospital {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #E8F8F3, #DCEEF8);
}
.mbs-name { font-size: 15px; font-weight: 600; color: #0A6B58; }
.mbs-dept { font-size: 12px; color: #888; }

.mbs-doctor {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  margin: 0 12px;
}
.mbs-avatar { font-size: 32px; }
.mbs-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.mbs-doc-name { font-size: 14px; font-weight: 600; color: #333; }
.mbs-doc-name em { font-style: normal; font-weight: 400; color: #0A8F6C; font-size: 12px; margin-left: 4px; }
.mbs-tags { font-size: 12px; color: #888; }
.mbs-book {
  padding: 6px 16px;
  border: 1px solid #0A8F6C;
  border-radius: 16px;
  background: #fff;
  color: #0A8F6C;
  font-size: 13px;
  cursor: pointer;
}
.mbs-book:active { background: #E8F8F3; }
.mbs-more {
  display: block;
  width: 100%;
  text-align: center;
  padding: 12px;
  font-size: 14px;
  color: #0A8F6C;
  background: none;
  border: none;
  cursor: pointer;
}
.mbs-my { padding: 0 12px 12px; }
.mbs-my-btn {
  width: 100%;
  padding: 11px;
  border: 1px dashed #d9d9d9;
  border-radius: 10px;
  background: #FAFAFA;
  font-size: 14px;
  color: #666;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* ========== 医院卡片 ========== */
.hospital-card .hc-header { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.hc-name { font-size: 16px; font-weight: 700; color: #333; }
.hc-tag { font-size: 11px; color: #0A8F6C; background: #E8F8F3; padding: 2px 8px; border-radius: 10px; }
.hc-info { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: #666; }

/* ========== 医生列表 & 卡片 ========== */
.doctor-list { padding: 0 12px 16px; display: flex; flex-direction: column; gap: 10px; }
.doctor-card { padding: 14px; cursor: pointer; }
.doctor-card:active { background: #F9F9F9; }
.dc-top { display: flex; align-items: center; gap: 10px; }
.dc-avatar { font-size: 36px; }
.dc-info { flex: 1; }
.dc-name-row { display: flex; align-items: baseline; gap: 6px; }
.dc-name { font-size: 16px; font-weight: 700; color: #333; }
.dc-title { font-size: 12px; color: #0A8F6C; }
.dc-dept { font-size: 12px; color: #888; margin-top: 2px; }
.dc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.dc-tag {
  font-size: 11px;
  color: #0A8F6C;
  background: #E8F8F3;
  padding: 3px 8px;
  border-radius: 10px;
}
.dc-schedule { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.dc-slot {
  font-size: 12px;
  color: #555;
  background: #F5F5F5;
  padding: 3px 8px;
  border-radius: 8px;
}
.dc-slot em { font-style: normal; color: #FF8C00; font-weight: 500; }
.dc-bottom { display: flex; align-items: center; justify-content: space-between; }
.dc-intro-short { font-size: 12px; color: #999; flex: 1; }
.dc-book-btn {
  padding: 6px 20px;
  background: #0A8F6C;
  color: #fff;
  border: none;
  border-radius: 18px;
  font-size: 13px;
  cursor: pointer;
}
.dc-book-btn:active { background: #078060; }

/* ========== 医生详情 ========== */
.doc-profile { padding: 16px; }
.dp-top { display: flex; align-items: center; gap: 12px; }
.dp-avatar { font-size: 48px; }
.dp-info { display: flex; flex-direction: column; gap: 3px; }
.dp-name { font-size: 18px; font-weight: 700; color: #333; }
.dp-title { font-size: 13px; color: #0A8F6C; font-weight: 500; }
.dp-dept { font-size: 12px; color: #888; }
.dp-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.dp-tag { font-size: 12px; color: #0A8F6C; background: #E8F8F3; padding: 3px 10px; border-radius: 10px; }

.doc-section { padding: 14px 16px; }
.ds-title { font-size: 14px; font-weight: 600; color: #333; margin-bottom: 8px; display: block; }
.ds-text { font-size: 13px; color: #666; line-height: 1.7; margin: 0; }

.schedule-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.sg-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 4px;
  background: #F8FFFE;
  border: 1px solid #D5EDE7;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.15s;
}
.sg-item:active { background: #D5EDE7; }
.sg-item.full { background: #F5F5F5; border-color: #E8E8E8; cursor: not-allowed; opacity: 0.6; }
.sg-day { font-size: 13px; font-weight: 600; color: #333; }
.sg-period { font-size: 12px; color: #666; }
.sg-slots { font-size: 12px; color: #0A8F6C; font-weight: 500; }
.sg-slots.none { color: #ccc; }

/* ========== 我的预约 ========== */
.apt-section { padding: 0 12px; }
.apt-section-title {
  font-size: 14px;
  font-weight: 600;
  color: #666;
  display: block;
  padding: 14px 4px 8px;
}
.apt-card { padding: 14px; margin-bottom: 10px; }
.apt-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.apt-date { font-size: 14px; font-weight: 600; color: #333; }
.apt-status { font-size: 12px; font-weight: 500; }
.apt-body { display: flex; flex-direction: column; gap: 3px; }
.apt-doctor { font-size: 14px; color: #333; }
.apt-dept { font-size: 12px; color: #888; }
.apt-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 12px; border-top: 1px solid #F0F0F0; padding-top: 10px; }
.apt-btn-cancel {
  padding: 6px 16px;
  background: #fff;
  border: 1px solid #d9d9d9;
  border-radius: 16px;
  font-size: 13px;
  color: #666;
  cursor: pointer;
}
.apt-btn-nav {
  padding: 6px 16px;
  background: #0A8F6C;
  color: #fff;
  border: none;
  border-radius: 16px;
  font-size: 13px;
  cursor: pointer;
}

/* ========== 病历档案 ========== */
.mr-hospital-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: linear-gradient(135deg, #E8F8F3, #DCEEF8);
  margin-bottom: 4px;
}
.mr-hospital-icon { font-size: 18px; }
.mr-hospital-name { font-size: 14px; font-weight: 600; color: #0A6B58; }
.mr-list { padding: 8px 12px; display: flex; flex-direction: column; gap: 10px; }
.mr-card { padding: 14px; cursor: pointer; }
.mr-card:active { background: #F9F9F9; }
.mr-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.mr-date { font-size: 14px; font-weight: 600; color: #333; }
.mr-doctor { font-size: 12px; color: #888; }
.mr-diag { font-size: 13px; color: #444; margin-bottom: 4px; }
.mr-diag-label { color: #999; }
.mr-iop { font-size: 12px; color: #666; margin-bottom: 6px; }
.mr-bottom { display: flex; justify-content: space-between; align-items: center; }
.mr-attach { font-size: 12px; color: #0A8F6C; }
.mr-arrow { font-size: 18px; color: #ccc; }

/* ========== 病历详情 ========== */
.rd-header {
  text-align: center;
  padding: 20px 16px 14px;
  background: linear-gradient(180deg, var(--primary-gradient-start), #F5FAF9);
}
.rd-diag { display: block; font-size: 18px; font-weight: 700; color: #333; margin-bottom: 6px; }
.rd-meta { font-size: 12px; color: #888; }

.rd-section { padding: 14px 16px; }
.rd-label { font-size: 13px; font-weight: 600; color: #999; display: block; margin-bottom: 6px; }
.rd-value { font-size: 14px; color: #333; line-height: 1.7; margin: 0; }
.rd-treatment { white-space: pre-line; }

.rd-iop-row { display: flex; gap: 16px; }
.rd-iop-item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px; background: #F8F8F8; border-radius: 10px; }
.rd-iop-eye { font-size: 12px; color: #888; }
.rd-iop-val { font-size: 18px; font-weight: 700; color: #333; }
.rd-iop-val.high { color: #FF4D4F; }

.rd-exam-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.rd-exam-tag {
  font-size: 12px;
  color: #555;
  background: #F0F0F0;
  padding: 5px 12px;
  border-radius: 14px;
}
.rd-attachments { display: flex; flex-direction: column; gap: 8px; }
.rd-attach-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  background: #F8F8F8;
  border-radius: 8px;
  font-size: 13px;
  color: #333;
}
.rd-next-visit {
  padding: 16px;
  text-align: center;
  font-size: 14px;
  color: #0A8F6C;
  font-weight: 500;
  background: #F8FFFE;
  margin: 12px;
  border-radius: 10px;
  border: 1px dashed #B2DFD4;
}

/* ========== 医院导航 ========== */
.hn-map-area { padding: 12px; }
.hn-map-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 30px 16px;
  background: linear-gradient(135deg, #E8F8F3, #D6EAE5);
  border-radius: 14px;
  text-align: center;
}
.hn-map-icon { font-size: 42px; }
.hn-map-name { font-size: 16px; font-weight: 700; color: #333; }
.hn-map-addr { font-size: 13px; color: #666; }
.hn-map-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; justify-content: center; }
.hn-map-btn {
  padding: 8px 16px;
  background: #fff;
  border: 1px solid #d9d9d9;
  border-radius: 20px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
}
.hn-map-btn:active { background: #F0F0F0; }

.hn-info, .hn-intro, .hn-floor, .hn-dept { padding: 14px 16px; margin: 0 12px 10px; }
.hn-info-title { font-size: 14px; font-weight: 600; color: #333; display: block; margin-bottom: 10px; }
.hn-info-row { display: flex; gap: 10px; padding: 6px 0; border-bottom: 1px solid #F5F5F5; }
.hn-info-row:last-child { border-bottom: none; }
.hn-label { font-size: 13px; color: #999; min-width: 40px; }
.hn-val { font-size: 13px; color: #333; flex: 1; }
.hn-phone { color: #0A8F6C; cursor: pointer; text-decoration: underline; }
.hn-intro-text { font-size: 13px; color: #666; line-height: 1.7; margin: 0; }

.hn-floor-list { display: flex; flex-direction: column; gap: 0; }
.hn-floor-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #F5F5F5;
}
.hn-floor-item:last-child { border-bottom: none; }
.hn-floor-num {
  font-size: 13px;
  font-weight: 700;
  color: #0A8F6C;
  min-width: 36px;
  text-align: center;
  background: #E8F8F3;
  padding: 4px 8px;
  border-radius: 8px;
}
.hn-floor-desc { font-size: 13px; color: #555; line-height: 1.5; }

.hn-dept-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.hn-dept-tag {
  font-size: 13px;
  color: #555;
  background: #F5F5F5;
  padding: 6px 14px;
  border-radius: 18px;
}
.hn-dept-tag.highlight { color: #0A8F6C; background: #E8F8F3; font-weight: 600; border: 1px solid #B2DFD4; }

/* ========== 眼压记录 ========== */
.iop-summary { padding: 16px; }
.iop-sum-row { display: flex; align-items: center; }
.iop-sum-item { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.iop-sum-label { font-size: 12px; color: #888; }
.iop-sum-val { font-size: 18px; font-weight: 700; color: #333; }
.iop-sum-date { font-size: 11px; color: #BBB; }
.iop-sum-divider { width: 1px; height: 40px; background: #E8E8E8; }

.iop-chart { padding: 16px; }
.iop-chart-title { font-size: 14px; font-weight: 600; color: #333; display: block; margin-bottom: 12px; }
.iop-chart-area {
  position: relative;
  height: 180px;
  border-left: 1px solid #E8E8E8;
  border-bottom: 1px solid #E8E8E8;
  padding: 0 0 24px 4px;
  display: flex;
  align-items: flex-end;
}
.iop-danger-zone {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: calc(100% - 60%);
  background: rgba(255, 77, 79, 0.05);
  border-bottom: 1px dashed #FF4D4F;
}
.iop-danger-label {
  position: absolute;
  right: 4px;
  top: calc(40% - 8px);
  font-size: 10px;
  color: #FF4D4F;
}
.iop-bars {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  flex: 1;
  height: 100%;
  padding-bottom: 4px;
}
.iop-bar-group { display: flex; flex-direction: column; align-items: center; flex: 1; gap: 4px; height: 100%; justify-content: flex-end; }
.iop-bar-pair { display: flex; gap: 2px; align-items: flex-end; height: calc(100% - 24px); }
.iop-bar {
  width: 14px;
  border-radius: 4px 4px 0 0;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  min-height: 6px;
  transition: height 0.3s;
}
.iop-bar span { font-size: 9px; color: #fff; margin-top: 2px; }
.iop-bar.left { background: #0A8F6C; }
.iop-bar.right { background: #5EC5AB; }
.iop-bar.over { background: #FF4D4F; }
.iop-bar-date { font-size: 10px; color: #999; text-align: center; }

.iop-legend { display: flex; justify-content: center; gap: 16px; margin-top: 10px; }
.iop-legend-item { display: flex; align-items: center; gap: 4px; font-size: 12px; color: #666; }
.iop-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.iop-dot.left { background: #0A8F6C; }
.iop-dot.right { background: #5EC5AB; }
.iop-dot.over { background: #FF4D4F; }

.iop-add-area { padding: 12px 16px; }
.iop-add-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #0DBFA0, #0A8F6C);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(10,143,108,0.25);
  transition: opacity 0.15s, transform 0.15s;
}
.iop-add-btn:active { opacity: 0.85; transform: scale(0.98); }
.iop-add-icon { font-size: 18px; font-weight: 700; }

/* 眼压测量指导 */
.iop-guide { margin: 0 12px 12px; padding: 0; overflow: hidden; }
.iop-guide-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  cursor: pointer;
}
.iop-guide-title { font-size: 14px; font-weight: 600; color: #333; }
.iop-guide-arrow { font-size: 14px; color: #999; transition: transform 0.2s; }
.iop-guide-body { padding: 0 16px 16px; }
.iop-guide-section { margin-bottom: 14px; }
.iop-guide-section:last-child { margin-bottom: 0; }
.iop-guide-subtitle { font-size: 13px; font-weight: 600; color: #0A8F6C; display: block; margin-bottom: 6px; }
.iop-guide-body p { font-size: 13px; color: #555; line-height: 1.7; margin: 0 0 6px; }
.iop-guide-body strong { color: #333; }
.iop-guide-body ul { margin: 4px 0 0; padding-left: 18px; }
.iop-guide-body li { font-size: 13px; color: #555; line-height: 1.8; }
.iop-guide-nav-btn {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 16px;
  background: #E8F8F3;
  color: #0A8F6C;
  border: 1px solid #B2DFD4;
  border-radius: 16px;
  font-size: 13px;
  cursor: pointer;
}

/* 历史记录操作按钮 */
.iop-record {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  margin-bottom: 6px;
}
.iop-rec-actions { display: flex; gap: 4px; margin-left: 8px; flex-shrink: 0; }
.iop-rec-edit, .iop-rec-del {
  width: 32px;
  height: 32px;
  border: none;
  background: #F5F5F5;
  border-radius: 8px;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.iop-rec-edit:active { background: #E8F8F3; }
.iop-rec-del:active { background: #FFF1F0; }

/* 眼压录入弹窗 */
.iop-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 20px;
  animation: fadeIn 0.2s ease;
}
.iop-modal {
  background: #fff;
  border-radius: 16px;
  width: 100%;
  max-width: 360px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  overflow: hidden;
}
.iop-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px 12px;
  border-bottom: 1px solid #F0F0F0;
}
.iop-modal-title { font-size: 16px; font-weight: 700; color: #333; }
.iop-modal-close {
  width: 28px; height: 28px;
  border: none;
  background: #F5F5F5;
  border-radius: 50%;
  font-size: 14px;
  color: #999;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.iop-modal-body { padding: 16px 18px; }
.iop-modal-field { margin-bottom: 14px; }
.iop-modal-label {
  font-size: 13px;
  font-weight: 600;
  color: #555;
  display: block;
  margin-bottom: 6px;
}
.iop-modal-input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid #E0E0E0;
  border-radius: 10px;
  font-size: 15px;
  color: #333;
  background: #FAFAFA;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  box-sizing: border-box;
}
.iop-modal-input:focus {
  border-color: #0A8F6C;
  box-shadow: 0 0 0 3px rgba(10,143,108,0.1);
  background: #fff;
}
.iop-modal-input::placeholder { color: #C0C0C0; }
.iop-modal-ref {
  text-align: center;
  padding: 8px;
  background: #F8FFFE;
  border-radius: 8px;
  font-size: 12px;
  color: #0A8F6C;
  border: 1px dashed #C8E6DC;
}
.iop-modal-footer {
  display: flex;
  gap: 10px;
  padding: 12px 18px 16px;
}
.iop-modal-cancel {
  flex: 1;
  padding: 12px;
  border: 1px solid #D9D9D9;
  border-radius: 10px;
  background: #fff;
  font-size: 15px;
  color: #666;
  cursor: pointer;
}
.iop-modal-confirm {
  flex: 1.5;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, #0DBFA0, #0A8F6C);
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
}
.iop-modal-confirm:active { opacity: 0.85; }
.iop-confirm-modal { padding: 0; }
.iop-confirm-body { padding: 24px 20px; font-size: 15px; color: #333; text-align: center; line-height: 1.6; }
.iop-confirm-del { background: linear-gradient(135deg, #FF6B6B, #FF4D4F); }

.iop-history { padding: 0 12px 20px; }
.iop-history-title { font-size: 14px; font-weight: 600; color: #666; display: block; padding: 12px 4px 8px; }
.iop-rec-left { display: flex; flex-direction: column; gap: 2px; }
.iop-rec-date { font-size: 14px; font-weight: 500; color: #333; }
.iop-rec-time { font-size: 12px; color: #999; }
.iop-rec-right { display: flex; gap: 12px; }
.iop-rec-val { font-size: 14px; color: #333; font-weight: 600; }
.iop-rec-val.high { color: #FF4D4F; }

.card-sm {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

/* ========== 青小瞳 AI 对话（v2 重设计） ========== */
.chat-nav { background: linear-gradient(135deg, #0DBFA0, #0A8F6C); }
.chat-nav .back-btn { color: #fff; }
.chat-nav-center { display: flex; align-items: center; gap: 8px; }
.chat-nav-avatar { width: 32px; height: 32px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,0.5); }
.chat-nav-info { display: flex; flex-direction: column; }
.chat-nav-name { font-size: 15px; font-weight: 600; color: #fff; }
.chat-nav-status { font-size: 11px; color: rgba(255,255,255,0.8); display: flex; align-items: center; gap: 4px; }
.chat-online-dot { width: 6px; height: 6px; border-radius: 50%; background: #7CFC00; display: inline-block; }
.chat-nav-right { width: 32px; }

.chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 44px - 70px);
  overflow-y: auto;
  background: linear-gradient(180deg, #F0FAF7 0%, #F5F5F5 30%);
}
.chat-welcome-v2 { padding: 16px 14px 8px; }
.cw2-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 20px 16px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(10,143,108,0.08);
}
.cw2-avatar { width: 56px; height: 56px; border-radius: 50%; border: 2px solid #D5EDE7; }
.cw2-name { font-size: 16px; font-weight: 700; color: #333; }
.cw2-desc { font-size: 13px; color: #888; text-align: center; line-height: 1.6; max-width: 300px; }
.cw2-tags { display: flex; gap: 8px; margin-top: 6px; flex-wrap: wrap; justify-content: center; }
.cw2-tag {
  font-size: 12px;
  color: #0A8F6C;
  background: #E8F8F3;
  padding: 4px 10px;
  border-radius: 12px;
}

.chat-quick-section { padding: 4px 14px 10px; }
.cqs-title { font-size: 12px; color: #999; display: block; margin-bottom: 8px; padding-left: 2px; }
.chat-quick-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.cq-tag {
  font-size: 13px;
  color: #0A8F6C;
  background: #fff;
  border: 1px solid #D5EDE7;
  padding: 8px 14px;
  border-radius: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
  transition: all 0.15s;
}
.cq-tag:active { background: #E8F8F3; transform: scale(0.97); }
.cq-icon { font-size: 13px; }

.chat-messages { flex: 1; padding: 8px 12px; display: flex; flex-direction: column; gap: 14px; }
.chat-msg { display: flex; gap: 8px; max-width: 82%; }
.chat-msg.user { align-self: flex-end; flex-direction: row-reverse; }
.chat-msg.bot { align-self: flex-start; }
.cm-avatar { width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0; margin-top: 2px; border: 1.5px solid #D5EDE7; }
.cm-bubble {
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.7;
  word-break: break-word;
}
.cm-bubble.user {
  background: linear-gradient(135deg, #0DBFA0, #0A8F6C);
  color: #fff;
  border-bottom-right-radius: 4px;
  box-shadow: 0 2px 8px rgba(10,143,108,0.2);
}
.cm-bubble.bot {
  background: #fff;
  color: #333;
  border-bottom-left-radius: 4px;
  box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}

.chat-input-bar-v2 {
  padding: 10px 12px 8px;
  background: #fff;
  border-top: 1px solid #F0F0F0;
  box-shadow: 0 -2px 8px rgba(0,0,0,0.03);
}
.chat-input-wrap {
  display: flex;
  gap: 8px;
  align-items: center;
}
.chat-input-v2 {
  flex: 1;
  padding: 12px 16px;
  border: 1.5px solid #E8E8E8;
  border-radius: 22px;
  font-size: 14px;
  outline: none;
  background: #F8F8F8;
  transition: border-color 0.2s, background 0.2s;
}
.chat-input-v2:focus { border-color: #0A8F6C; background: #fff; box-shadow: 0 0 0 3px rgba(10,143,108,0.08); }
.chat-send-btn-v2 {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #0DBFA0, #0A8F6C);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(10,143,108,0.3);
  transition: transform 0.15s;
}
.chat-send-btn-v2:active { transform: scale(0.9); }
.chat-disclaimer { display: block; text-align: center; font-size: 11px; color: #C0C0C0; margin-top: 6px; }

/* ========== AI 浮窗按钮（v2） ========== */
.ai-fab {
  position: fixed;
  bottom: 80px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  background: #fff;
  border-radius: 28px;
  box-shadow: 0 4px 20px rgba(10,143,108,0.25), 0 0 0 1.5px rgba(10,143,108,0.1);
  color: #0A8F6C;
  cursor: pointer;
  z-index: 999;
  transition: transform 0.2s, box-shadow 0.2s;
  overflow: hidden;
  height: 48px;
  padding-right: 14px;
}
.ai-fab:active { transform: scale(0.94); box-shadow: 0 2px 10px rgba(10,143,108,0.2); }
.ai-fab-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(135deg, #E8F8F3, #D0EDE5);
  padding: 6px;
  box-sizing: border-box;
}
.ai-fab-label { font-size: 13px; font-weight: 700; color: #0A8F6C; white-space: nowrap; }

/* ========== 首页 AI 健康洞察卡片 ========== */
.ai-insight-card {
  margin: 0 12px 12px;
  padding: 16px;
  background: linear-gradient(135deg, #F0FBF7 0%, #E8F4FD 100%);
  border: 1px solid #C8E6DC;
  cursor: pointer;
  transition: box-shadow 0.2s;
}
.ai-insight-card:active { box-shadow: 0 2px 12px rgba(10,143,108,0.15); }
.aic-header { margin-bottom: 10px; }
.aic-title-row { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.aic-icon { font-size: 20px; }
.aic-title { font-size: 15px; font-weight: 700; color: #333; }
.aic-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 600;
  margin-left: auto;
}
.aic-badge.good { background: #E8F8F3; color: #0A8F6C; }
.aic-badge.warn { background: #FFF7E6; color: #FF8C00; }
.aic-badge.alert { background: #FFF1F0; color: #FF4D4F; }
.aic-time { font-size: 11px; color: #aaa; }
.aic-summary { font-size: 13px; color: #555; line-height: 1.6; margin-bottom: 12px; }
.aic-insights { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.aic-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 6px;
  background: rgba(255,255,255,0.8);
  border-radius: 10px;
}
.aic-item-icon { font-size: 20px; }
.aic-item-label { font-size: 11px; color: #888; }
.aic-item-value { font-size: 13px; font-weight: 600; }
.aic-item-value.warn { color: #FF8C00; }
.aic-item-value.alert { color: #FF4D4F; }
.aic-item-value.good { color: #0A8F6C; }
.aic-footer { text-align: center; margin-top: 12px; }
.aic-footer-text { font-size: 13px; color: #0A8F6C; font-weight: 500; }

/* ========== AI 用药分析报告 ========== */
.ai-report { padding: 12px; }
.air-header {
  background: linear-gradient(135deg, #0DBFA0, #0A6B58);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 12px;
  color: #fff;
}
.air-header-top { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.air-robot { font-size: 32px; }
.air-header-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.air-header-title { font-size: 16px; font-weight: 700; }
.air-header-time { font-size: 11px; opacity: 0.7; }
.air-score-badge {
  font-size: 16px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,0.2);
}
.air-score-badge.good { background: rgba(82,196,26,0.25); }
.air-score-badge.warn { background: rgba(255,140,0,0.25); }
.air-score-badge.alert { background: rgba(255,77,79,0.25); }
.air-summary { font-size: 13px; line-height: 1.7; opacity: 0.92; }

.air-section { padding: 14px 16px; margin-bottom: 10px; }
.air-section-title {
  font-size: 15px;
  font-weight: 700;
  color: #333;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

/* 用药依从性 */
.air-adherence { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.air-adherence-ring { position: relative; width: 80px; height: 80px; flex-shrink: 0; }
.air-adherence-ring svg { width: 100%; height: 100%; }
.air-adherence-val {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-size: 18px;
  font-weight: 700;
  color: #333;
}
.air-adherence-info { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.air-adherence-level { font-size: 14px; color: #333; }
.air-adherence-level em { font-style: normal; font-weight: 600; }
.air-adherence-tip { font-size: 12px; color: #888; line-height: 1.5; }

/* 药物列表 */
.air-drug-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.air-drug-item {
  padding: 10px 12px;
  background: #F8F9FA;
  border-radius: 10px;
  border-left: 3px solid #D9D9D9;
}
.air-drug-item:has(.air-drug-status[style*="52C41A"]) { border-left-color: #52C41A; }
.air-drug-item:has(.air-drug-status[style*="FF8C00"]) { border-left-color: #FF8C00; }
.air-drug-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
.air-drug-name { font-size: 14px; font-weight: 600; color: #333; }
.air-drug-status { font-size: 12px; font-weight: 500; }
.air-drug-remark { font-size: 12px; color: #888; line-height: 1.5; }

.air-check-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  background: #F0FBF7;
  border-radius: 8px;
  margin-bottom: 6px;
}
.air-check-item.attention { background: #FFF7E6; }
.air-check-icon { font-size: 14px; flex-shrink: 0; margin-top: 1px; }
.air-check-text { font-size: 13px; color: #555; line-height: 1.5; }

/* 眼压分析 */
.air-iop-stats { display: flex; gap: 8px; margin-bottom: 12px; }
.air-iop-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 4px;
  background: #F8F9FA;
  border-radius: 10px;
}
.air-iop-label { font-size: 11px; color: #888; }
.air-iop-val { font-size: 16px; font-weight: 700; color: #333; }
.air-iop-val.high { color: #FF4D4F; }
.air-iop-val.trend-stable { color: #52C41A; }
.air-iop-val.trend-improving { color: #0A8F6C; }
.air-iop-val.trend-worsening { color: #FF4D4F; }
.air-iop-val.trend-fluctuating { color: #FF8C00; }

.air-alert-box {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 12px;
  background: #FFF1F0;
  border: 1px solid #FFD6D6;
  border-radius: 8px;
  font-size: 13px;
  color: #CC4040;
  line-height: 1.5;
  margin-bottom: 8px;
}
.air-alert-icon { flex-shrink: 0; }
.air-suggestion { font-size: 13px; color: #666; line-height: 1.6; padding: 8px 0; }

/* 随访建议 */
.air-followup { border: 1px solid #D5EDE7; }
.air-fu-urgency {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-radius: 10px;
  margin-bottom: 12px;
}
.air-fu-urgency.routine { background: #E8F8F3; }
.air-fu-urgency.soon { background: #FFF7E6; }
.air-fu-urgency.urgent { background: #FFF1F0; }
.air-fu-urgency-text { font-size: 14px; font-weight: 700; }
.air-fu-urgency.routine .air-fu-urgency-text { color: #0A8F6C; }
.air-fu-urgency.soon .air-fu-urgency-text { color: #FF8C00; }
.air-fu-urgency.urgent .air-fu-urgency-text { color: #FF4D4F; }
.air-fu-date { font-size: 12px; color: #888; }

.air-fu-reasons { margin-bottom: 12px; }
.air-fu-reasons-title { font-size: 13px; font-weight: 600; color: #666; display: block; margin-bottom: 6px; }
.air-fu-reason { display: flex; gap: 6px; font-size: 13px; color: #555; line-height: 1.7; }

.air-fu-checks { margin-bottom: 12px; }
.air-fu-checks-title { font-size: 13px; font-weight: 600; color: #666; display: block; margin-bottom: 8px; }
.air-fu-check-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.air-fu-check-tag {
  font-size: 12px;
  padding: 5px 12px;
  background: #E8F8F3;
  color: #0A8F6C;
  border-radius: 14px;
  font-weight: 500;
}
.air-fu-doctor {
  font-size: 13px;
  color: #333;
  padding: 10px 0;
  border-top: 1px solid #F0F0F0;
  margin-bottom: 12px;
}
.air-fu-book-btn {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, #0DBFA0, #0A8F6C);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.air-fu-book-btn:active { opacity: 0.85; }

.air-disclaimer {
  padding: 12px 4px;
  font-size: 11px;
  color: #BBB;
  line-height: 1.5;
  text-align: center;
}

/* ========== 动画 ========== */
.page-enter {
  animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
