/* ==========================================================================
   移动小程序模拟视口 (iPhone 15 Pro 工效学外壳) (mobile.css) · ≤ 250 行
   ========================================================================== */

.mobile-phone-case {
  width: 390px;
  max-width: calc(100vw - 16px);
  height: 844px;
  max-height: calc(100vh - 96px);
  background: var(--phone-bg);
  border-radius: 50px;
  margin: 24px auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4), 0 0 0 10px #1e293b, 0 0 0 12px #334155;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.phone-notch {
  height: 30px;
  background: var(--phone-bg);
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.phone-cam {
  width: 90px;
  height: 22px;
  background: #000000;
  border-radius: 20px;
  margin-top: 4px;
}

.phone-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 28px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-primary);
  background: var(--bg-surface);
}

.wechat-nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 16px;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
}

.wechat-title { font-size: 15px; font-weight: 800; }
.wechat-capsule {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
}

.mini-content-viewport {
  flex: 1;
  overflow-y: auto;
  background: var(--bg-primary);
  padding: 12px;
}

.mini-tab-pane { display: none; }
.mini-tab-pane.active { display: block; }

.mini-search-bar {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.mini-banner {
  background: linear-gradient(135deg, var(--primary) 0%, #047857 100%);
  color: #ffffff;
  padding: 18px 16px;
  border-radius: var(--radius-lg);
  margin-bottom: 12px;
}

.banner-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.2);
  font-size: 10px;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
}

.banner-headline { font-size: 18px; font-weight: 800; }
.banner-sub { font-size: 11px; opacity: 0.9; }

.anxuan-zone {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  padding: 14px;
  border: 1px solid var(--border);
  margin-bottom: 12px;
}

.zone-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.zone-title { display: flex; align-items: center; gap: 6px; font-size: 14px; }
.zone-tag {
  background: var(--primary-light);
  color: var(--primary);
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: var(--radius-sm);
}
.zone-more { font-size: 11px; color: var(--text-muted); }

.anxuan-pillars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  text-align: center;
  font-size: 11px;
  font-weight: 600;
}

.pillar-item {
  background: var(--bg-subtle);
  padding: 8px 4px;
  border-radius: var(--radius-sm);
}
.p-icon { font-size: 18px; margin-bottom: 2px; }

.mini-category-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 8px;
}

.chip-btn {
  white-space: nowrap;
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  cursor: pointer;
}
.chip-btn.active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
}

.mini-product-card {
  background: var(--bg-surface);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  padding: 12px;
  margin-bottom: 10px;
  display: flex;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}

.mini-prod-img {
  width: 90px;
  height: 90px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  flex-shrink: 0;
}

.mini-prod-meta { flex: 1; display: flex; flex-direction: column; justify-content: space-between; }
.mini-p-title { font-size: 13px; font-weight: 700; line-height: 1.3; }
.mini-p-clean { font-size: 10px; color: var(--primary); font-weight: 600; }
.mini-p-bottom { display: flex; justify-content: space-between; align-items: baseline; }
.mini-p-price { font-size: 16px; font-weight: 900; color: var(--danger); }
.mini-btn-buy {
  background: var(--primary);
  color: #ffffff;
  border: none;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.mini-tab-bar {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 8px 0 16px 0;
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
}

.tab-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 10px;
  color: var(--text-muted);
  cursor: pointer;
}
.tab-btn.active { color: var(--primary); font-weight: 700; }
.tab-icon { font-size: 18px; margin-bottom: 2px; }

.partner-card-header {
  background: var(--bg-surface);
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.partner-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 800;
}

.partner-name { font-size: 14px; font-weight: 800; }
.partner-lvl {
  background: var(--warning-light);
  color: var(--warning);
  font-size: 10px;
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  margin-left: 4px;
}
.partner-id-text { font-size: 10px; color: var(--text-muted); }

.partner-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 16px;
}

.metric-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
}
.m-val { font-size: 16px; font-weight: 800; color: var(--primary); }
.m-lbl { font-size: 10px; color: var(--text-secondary); }

.partner-actions { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.partner-compliance-alert {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  padding: 10px;
  border-radius: var(--radius-md);
  font-size: 11px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.story-item {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 10px;
}

.story-badge {
  display: inline-block;
  background: var(--accent-light);
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
}
.story-item h4 { font-size: 13px; font-weight: 800; margin-bottom: 6px; }
.story-item p { font-size: 11px; color: var(--text-secondary); margin-bottom: 8px; }
.story-meta { font-size: 10px; color: var(--text-muted); }

@media (max-width: 768px) {
  .mobile-phone-case {
    width: 100%;
    max-width: 100%;
    height: auto;
    min-height: calc(100vh - 90px);
    max-height: none;
    border-radius: 0;
    margin: 0;
    box-shadow: none;
    background: var(--bg-primary);
  }
  .phone-notch, .phone-status-bar {
    display: none;
  }
  .banner-badge {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
  }
  .mini-prod-meta, .mini-product-card > div {
    min-width: 0;
    overflow-wrap: anywhere;
  }
}
