/* 插件市场详情页专属样式 - 青色/金色主题，与首页统一 */
.market-detail-page {
  min-height: calc(100vh - 200px);
  background: #F8FAFC;
}

/* Hero区域 - 青色渐变，与首页一致 */
.market-detail-hero {
  background: linear-gradient(180deg, #F0FDFA 0%, #F8FAFC 100%);
  padding: 50px 20px 70px;
  position: relative;
  overflow: hidden;
}
.market-detail-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image:
    linear-gradient(rgba(13,148,136,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13,148,136,0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #0D9488;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 24px;
  padding: 8px 16px;
  background: rgba(255,255,255,0.8);
  border-radius: 8px;
  border: 1px solid #99F6E4;
  transition: all 0.25s;
  position: relative;
  z-index: 2;
}
.back-link:hover {
  background: #fff;
  transform: translateX(-4px);
  box-shadow: 0 4px 12px rgba(13,148,136,0.15);
}

/* 商品头部 */
.market-detail-header {
  display: flex;
  gap: 32px;
  position: relative;
  z-index: 2;
}
.market-detail-cover {
  width: 180px;
  height: 180px;
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 30px rgba(13,148,136,0.15);
  flex-shrink: 0;
  border: 3px solid #fff;
}
.market-detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.market-detail-info {
  flex: 1;
}
.market-detail-title {
  font-size: 32px;
  font-weight: 700;
  color: #0F172A;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.market-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}
.tag-version {
  background: linear-gradient(135deg, #F0FDFA, #CCFBF1);
  color: #0F766E;
  border: 1px solid #99F6E4;
}
.tag-official {
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  color: #92400E;
  border: 1px solid #FCD34D;
}
.tag-mode-general {
  background: linear-gradient(135deg, #E0E7FF, #C7D2FE);
  color: #3730A3;
  border: 1px solid #A5B4FC;
}
.tag-mode-self {
  background: linear-gradient(135deg, #D1FAE5, #A7F3D0);
  color: #065F46;
  border: 1px solid #6EE7B7;
}
.tag-mode-api {
  background: linear-gradient(135deg, #FFEDD5, #FED7AA);
  color: #9A3412;
  border: 1px solid #FDBA74;
}
.market-meta {
  color: #64748B;
  font-size: 14px;
  margin-bottom: 16px;
  line-height: 1.8;
}
.market-meta a {
  color: #0D9488;
  text-decoration: none;
  font-weight: 500;
}
.market-meta a:hover {
  text-decoration: underline;
}
.market-price {
  font-size: 28px;
  font-weight: 700;
  color: #D97706;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.market-price .free {
  color: #059669;
  font-size: 22px;
}
.market-price .price-act {
  color: #dc2626;
  font-size: 30px;
}
.market-price .price-orig {
  color: #94a3b8;
  font-size: 16px;
  font-weight: 400;
  text-decoration: line-through;
}
.market-price .tag-discount {
  background: #dc2626;
  color: #fff;
  border: none;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
}
.market-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.points-deduct-check {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  padding: 8px 12px;
  background: #fefce8;
  border: 1px dashed #facc15;
  border-radius: 8px;
  font-size: 13px;
  color: #a16207;
  cursor: pointer;
}
.points-deduct-check input[type="checkbox"] {
  accent-color: #eab308;
  width: 15px;
  height: 15px;
}
.points-deduct-tip {
  color: #d97706;
  font-weight: 500;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 28px;
  background: linear-gradient(135deg, #0D9488, #14B8A6);
  color: #fff;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(13,148,136,0.25);
  transition: all 0.25s;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(13,148,136,0.35);
  color: #fff;
}
.btn-plain {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 24px;
  background: #fff;
  color: #0D9488;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  border: 1.5px solid #99F6E4;
  cursor: pointer;
  transition: all 0.25s;
}
.btn-plain:hover {
  background: #F0FDFA;
  transform: translateY(-2px);
}
.btn-disabled {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 24px;
  background: #F1F5F9;
  color: #64748B;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  border: 1.5px solid #E2E8F0;
  cursor: default;
}
.btn-owned {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 12px 24px;
  background: #ECFDF5;
  color: #059669;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  border: 1.5px solid #A7F3D0;
  cursor: default;
}

/* 内容区域 */
.market-detail-page .container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}
.market-detail-content {
  margin-top: -40px;
  padding-bottom: 60px;
  position: relative;
  z-index: 3;
}
.content-card {
  background: #fff;
  border-radius: 16px;
  padding: 32px;
  margin-bottom: 24px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  border: 1px solid #F1F5F9;
  position: relative;
  overflow: hidden;
}
.content-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #0D9488, #14B8A6);
}
.card-title {
  font-size: 20px;
  font-weight: 700;
  color: #0F172A;
  margin: 0 0 20px;
  padding-bottom: 14px;
  border-bottom: 2px solid #F1F5F9;
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-title::before {
  content: '';
  width: 4px;
  height: 20px;
  background: linear-gradient(180deg, #0D9488, #14B8A6);
  border-radius: 2px;
}
.content-body {
  font-size: 15px;
  line-height: 1.9;
  color: #334155;
}
.content-body img {
  max-width: 100%;
  border-radius: 12px;
  margin: 12px 0;
}

/* 封面图 */
.market-cover-large {
  margin: 20px 0 4px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid #E2E8F0;
}
.market-cover-large img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  display: block;
}

/* 演示截图 */
.screenshots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.screenshot-item {
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #E2E8F0;
  cursor: zoom-in;
  background: #F8FAFC;
  transition: all 0.25s;
}
.screenshot-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(13,148,136,0.15);
  border-color: #99F6E4;
}
.screenshot-item img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  display: block;
}

/* 版本历史表格 */
.version-table {
  width: 100%;
  font-size: 14px;
  border-collapse: collapse;
}
.version-table th {
  color: #64748B;
  text-align: left;
  padding: 10px 12px;
  font-weight: 600;
  border-bottom: 2px solid #F1F5F9;
}
.version-table td {
  padding: 12px;
  border-top: 1px solid #F1F5F9;
  vertical-align: top;
  color: #334155;
}
.version-table tr:hover td {
  background: #F8FAFC;
}
.version-num {
  font-weight: 600;
  color: #0D9488;
  white-space: nowrap;
}
.version-date {
  white-space: nowrap;
  color: #64748B;
}
.empty-text {
  color: #94A3B8;
  font-size: 14px;
  text-align: center;
  padding: 20px 0;
}

/* 响应式 */
@media (max-width: 768px) {
  .market-detail-hero {
    padding: 30px 16px 50px;
  }
  .market-detail-header {
    flex-direction: column;
    text-align: center;
  }
  .market-detail-cover {
    width: 120px;
    height: 120px;
    margin: 0 auto;
  }
  .market-detail-title {
    font-size: 24px;
    justify-content: center;
  }
  .market-tags {
    justify-content: center;
  }
  .market-actions {
    justify-content: center;
  }
  .content-card {
    padding: 22px;
  }
  .version-table {
    font-size: 13px;
  }
}
