/* PROJECT30 Typography P1.1 — Dark Gray Cleanup (display only, last cascade) */

:root {
  --typo-primary: #fafbfc;
  --typo-secondary: #e8edf4;
  --typo-hint: #d4dce8;
  --typo-disabled: #a8b4c4;
  --typo-legal: #c8d0dc;
}

/* ── 면책/법적 고지 (너무 밝지 않게, 읽을 수 있는 최소 대비) ── */
body > div[style*="color:#b8c0cc"],
body > div[style*="color: #b8c0cc"] {
  color: var(--typo-legal) !important;
  font-size: 12px !important;
  line-height: 1.55 !important;
}

/* ── 1. AI 퍼널 라벨 ── */
.ap2-funnel-lbl,
.ap2-funnel-arrow {
  color: var(--typo-secondary) !important;
}

.ap2-funnel-arrow {
  color: var(--typo-hint) !important;
}

.ap2-funnel-sub {
  color: #8ef0fa !important;
}

/* ── 2. WHY 카드 부제 ── */
.ap2-reason-sub {
  color: var(--typo-secondary) !important;
}

/* ── 3. 설명 문구 ── */
.ap3-er-hint,
.ap3-tip-text p,
.ap3-gold-usage-tip .ap3-tip-text p,
.ap3-gold-status,
.alpha-risk-empty,
.agp-disc,
.alpha-trust-rationale,
.alpha-trust-note,
.alpha-fi-mb-line,
.alpha-fi-news-sub,
.ap2-gold-philosophy p,
.ap2-gold-philosophy-sub,
.ap2-official-analysis,
.ap2-official-slogan,
.ale-disclaimer,
.alpha-v7-disclaimer,
.alpha-v7-ownership-total {
  color: var(--typo-hint) !important;
}

.ap3-stop-advisory {
  color: var(--typo-secondary) !important;
}

/* ── 4. Risk / STOP 설명 ── */
.alpha-risk-subtitle,
.alpha-risk-reasons li,
.alpha-risk-item-reason,
.alpha-risk-item-judge,
.alpha-risk-soft-tier,
.alpha-risk-score-sub,
.alpha-risk-danger-lbl,
.alpha-risk-item-meta,
.alpha-risk-reasons li::before,
.ap3-stop-wrap .alpha-risk-subtitle,
.ap3-stop-wrap .alpha-risk-reasons li,
.ap3-stop-wrap .alpha-risk-item-judge,
.ap3-stop-wrap .alpha-risk-score-sub,
.ap3-stop-wrap .alpha-risk-updated {
  color: var(--typo-hint) !important;
}

.alpha-risk-updated,
.alpha-risk-danger-lbl {
  color: var(--typo-secondary) !important;
}

/* ── 5. 업종 / 주요사업 / 메타 ── */
.ap2-company-facts {
  color: var(--typo-hint) !important;
}

.ap2-company-facts b,
.ap2-tags span,
.agp-code,
.ap3-price-lbl,
.alpha-trust-time,
.alpha-trust-cell .lbl,
.alpha-fi-mb-chip .lbl,
.alpha-trust-chip,
.ap2-official-next-lbl,
.gold-metric-label,
.agp-company-code,
.agp-company-lbl,
.portfolio-row-sub,
.official-gold-sub {
  color: var(--typo-hint) !important;
}

.ap2-company-facts b,
.ap2-tags span {
  color: var(--typo-secondary) !important;
}

/* ── 6. 접힘 summary / 버튼 보조 텍스트 ── */
.ap2-chart-fold summary,
.ap2-gold-deep summary,
.ap2-brief-fold summary,
.ap2-trust-fold summary,
.ap2-below-fold summary,
.ap3-official-more summary,
.gold-watch-accordion > summary,
.agp-explainer-why summary {
  color: var(--typo-hint) !important;
}

.ap2-chart-fold[open] summary,
.ap2-gold-deep[open] summary,
.ap2-brief-fold[open] summary {
  color: var(--typo-secondary) !important;
}

.portfolio-tab,
.portfolio-empty,
.ap2-go-stop-go span,
.ap2-go-stop-stop span {
  color: var(--typo-hint) !important;
}

.portfolio-tab.is-active,
.portfolio-tab.active {
  color: var(--typo-primary) !important;
}

/* ── P0 disabled 토큰 보정 (읽는 텍스트는 Hint 이상) ── */
.agp-code,
.ap3-price-lbl,
.alpha-risk-updated,
.alpha-risk-item-meta,
.alpha-risk-score-sub,
.alpha-risk-danger-lbl,
.alpha-trust-time,
.alpha-trust-cell .lbl,
.alpha-trust-chip,
.market-chip-lbl,
.agp-tick,
.agp-score-lbl,
.agp-ring-num span {
  color: var(--typo-hint) !important;
}

/* ── 비활성 전용 (Disabled 유지) ── */
.official-gold-meta .status-skip,
.gold-metric-value.status-skip,
.gold-metric-value.hold-no,
.f2s-gold-link-meta .hold-no,
.ale-check-idle,
.ale-recent-title,
.ale-stat-lbl,
.ap2-go-stop-arrow {
  color: var(--typo-disabled) !important;
}

/* ── 인라인 어두운 회색 잔재 (모바일 GOLD 영역) ── */
@media (max-width: 600px) {
  .alpha-v7-simple-first [style*="#94a3b8"],
  .alpha-v7-simple-first [style*="#64748b"],
  .alpha-v7-simple-first [style*="#475569"],
  .alpha-v7-simple-first [style*="#6b7280"],
  .alpha-v7-simple-first [style*="#71717a"],
  .ap2-official-announcement [style*="#94a3b8"],
  .ap2-official-announcement [style*="#64748b"],
  .app [style*="color:#94a3b8"],
  .app [style*="color:#64748b"],
  .app [style*="color:#475569"] {
    color: var(--typo-hint) !important;
  }
}

/* alpha_p2 / MAIN_HTML 베이스 회색 덮어쓰기 */
.ap2-funnel-lbl,
.ap2-metric-lbl,
.ap2-reason-sub,
.ap3-price-lbl {
  color: var(--typo-secondary) !important;
}

.ap3-er-hint,
.ap3-tip-text p,
.ap2-official-slogan,
.ap2-official-next-lbl {
  color: var(--typo-hint) !important;
}

@media (prefers-reduced-motion: reduce) {
  .app * {
    transition: none !important;
  }
}
