/**
 * 定投效果分析组件样式
 */

/* 弹窗容器 */
.dca-modal-content {
  max-width: 800px !important;
  max-height: 85vh;
  overflow-y: auto;
}

#dcaAnalysisContent {
  padding: 16px 24px 20px;
}

/* 顶部总览 */
.dca-summary {
  display: flex;
  gap: 0;
  margin-bottom: 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  overflow: hidden;
}

.dca-stat {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 8px;
  position: relative;
}

.dca-stat + .dca-stat::before {
  content: '';
  position: absolute;
  left: 0;
  top: 20%;
  height: 60%;
  width: 1px;
  background: rgba(255,255,255,0.08);
}

.dca-stat__label {
  font-size: 11px;
  color: #71717a;
  margin-bottom: 4px;
}

.dca-stat__value {
  font-size: 20px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
}

.dca-stat__sub {
  font-size: 10px;
  color: #a1a1aa;
  margin-top: 2px;
}

/* 区块容器 */
.dca-section {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
}

.dca-section:last-child {
  margin-bottom: 0;
}

.dca-section__title {
  font-size: 13px;
  font-weight: 600;
  color: #d4d4d8;
  margin-bottom: 12px;
}

/* 图表容器 */
.dca-chart-wrap {
  height: 200px;
  position: relative;
}

/* 微笑曲线信息 */
.dca-smile-info {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 10px;
}

.dca-smile-item {
  background: rgba(0,0,0,0.2);
  border-radius: 8px;
  padding: 10px 12px;
}

.dca-smile-label {
  font-size: 11px;
  color: #71717a;
  display: block;
  margin-bottom: 4px;
}

.dca-smile-value {
  font-size: 14px;
  font-weight: 600;
  font-family: 'JetBrains Mono', monospace;
  color: #e4e4e7;
}

.dca-smile-msg {
  font-size: 12px;
  color: #22c55e;
  background: rgba(34,197,94,0.1);
  border-radius: 8px;
  padding: 10px;
}

/* 定投对比 */
.dca-compare {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.dca-compare-item {
  flex: 1;
  background: rgba(0,0,0,0.2);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}

.dca-compare-item--win {
  border: 1px solid rgba(34,197,94,0.3);
  background: rgba(34,197,94,0.05);
}

.dca-compare-title {
  font-size: 12px;
  color: #a1a1aa;
  margin-bottom: 6px;
}

.dca-compare-rate {
  font-size: 20px;
  font-weight: 700;
  font-family: 'JetBrains Mono', monospace;
}

.dca-compare-detail {
  font-size: 11px;
  color: #71717a;
  margin-top: 4px;
}

.dca-compare-vs {
  font-size: 12px;
  font-weight: 600;
  color: #52525b;
}

.dca-compare-msg {
  font-size: 12px;
  text-align: center;
  padding: 8px;
  background: rgba(255,255,255,0.03);
  border-radius: 6px;
}

/* 基金列表 */
.dca-fund-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dca-fund-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background: rgba(0,0,0,0.2);
  border-radius: 8px;
}

.dca-fund-info {
  flex: 1;
  min-width: 0;
}

.dca-fund-name {
  font-size: 13px;
  color: #e4e4e7;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dca-fund-code {
  font-size: 10px;
  color: #52525b;
  margin-top: 2px;
}

.dca-fund-nums {
  text-align: right;
  flex-shrink: 0;
}

.dca-fund-rate {
  font-size: 14px;
  font-weight: 600;
  font-family: 'JetBrains Mono', monospace;
}

.dca-fund-return {
  font-size: 11px;
  color: #71717a;
}

/* 智能洞察 */
.dca-insight {
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 8px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-width: 1px;
  border-style: solid;
}

.dca-insight:last-child { margin-bottom: 0; }

.dca-insight__icon {
  font-size: 16px;
  flex-shrink: 0;
}

.dca-insight__body {
  flex: 1;
  min-width: 0;
}

.dca-insight__title {
  font-size: 12px;
  font-weight: 600;
  color: #e4e4e7;
  margin-bottom: 2px;
}

.dca-insight__desc {
  font-size: 11px;
  color: #a1a1aa;
  line-height: 1.5;
}

.dca-insight__detail {
  font-size: 10px;
  color: #71717a;
  margin-top: 3px;
  padding-top: 3px;
  border-top: 1px solid rgba(255,255,255,0.04);
}

/* 响应式 */
@media (max-width: 600px) {
  .dca-summary {
    flex-wrap: wrap;
  }
  
  .dca-stat {
    flex: 1 1 50%;
  }
  
  .dca-stat:nth-child(2)::before {
    display: none;
  }
  
  .dca-smile-info {
    grid-template-columns: 1fr;
  }
  
  .dca-compare {
    flex-direction: column;
  }
  
  .dca-compare-vs {
    transform: rotate(90deg);
  }
}
