/* experts.css — /experts, /experts/<id> 전문가 시황. 색은 전부 tokens.css (견해: 강세 --view-bull 빨강, 약세 --view-bear 파랑,
   중립 --view-neutral 회색 — 국내 관례). 카드·구획 모양은 gap.css·premium.css 와 맞춘다. 390px 에서 가로 스크롤 없게. */
.ex-page { max-width: 960px; }
.ex-page h1 { font-size: 24px; line-height: 1.3; color: var(--text-strong); word-break: keep-all; }
.ex-lead { margin-top: 6px; font-size: 14px; color: var(--text-primary); word-break: keep-all; }
.ex-lead strong { color: var(--accent-text); }
.ex-aff { margin-top: 2px; font-size: 14px; color: var(--text-secondary); }
.ex-back { margin-bottom: 6px; font-size: 13px; }
.ex-back a { color: var(--accent-text); text-decoration: none; }
.ex-back a:hover { text-decoration: underline; }
.ex-note { margin-top: 16px; font-size: 12px; color: var(--text-muted); word-break: keep-all; }
.ex-muted { color: var(--text-muted); }
.ex-empty { padding: 24px 8px; text-align: center; font-size: 14px; color: var(--text-muted); word-break: keep-all; }
.ex-retry { margin-left: 8px; min-height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg-inset); color: var(--text-primary); cursor: pointer; }

/* 전문가 카드 */
.ex-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 16px; }
.ex-card { display: block; padding: 16px; border-radius: var(--radius-lg); background: var(--bg-card); border: 1px solid var(--border); color: inherit; text-decoration: none; min-width: 0; }
.ex-card:hover, .ex-card:focus-visible { border-color: var(--accent); }
.ex-card-name { font-size: 17px; font-weight: 700; color: var(--text-strong); }
.ex-card-aff { margin-top: 2px; font-size: 13px; color: var(--text-secondary); word-break: keep-all; overflow-wrap: anywhere;
    display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ex-card-view { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; margin-top: 12px; font-size: 13px; color: var(--text-secondary); }
.ex-card-meta { margin-top: 10px; font-size: 12px; color: var(--text-muted); }
.ex-card-score { margin-top: 4px; font-size: 12px; color: var(--text-secondary); }

/* 견해 배지·점 */
.ex-badge { display: inline-flex; align-items: center; min-height: 24px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.ex-badge-bull { background: var(--view-bull-bg); color: var(--view-bull-text); }
.ex-badge-bear { background: var(--view-bear-bg); color: var(--view-bear-text); }
.ex-badge-neutral { background: var(--view-neutral-bg); color: var(--view-neutral-text); }
.ex-dot { display: inline-block; width: 10px; height: 10px; margin-right: 4px; border-radius: 50%; vertical-align: middle; }
.ex-dot-bull { background: var(--view-bull); }
.ex-dot-bear { background: var(--view-bear); }
.ex-dot-neutral { background: var(--view-neutral); }

/* 구획 */
.ex-section { margin-top: 16px; padding: 16px; border-radius: var(--radius-lg); background: var(--bg-card); border: 1px solid var(--border); min-width: 0; }
.ex-section-head { display: flex; align-items: baseline; gap: 4px 12px; flex-wrap: wrap; }
.ex-section-head h2 { font-size: 16px; font-weight: 700; color: var(--text-strong); margin-right: auto; }
.ex-sub { font-size: 12px; color: var(--text-muted); }
.ex-legend { display: flex; gap: 12px; margin-top: 8px; font-size: 12px; color: var(--text-secondary); }
.ex-chart { width: 100%; height: 320px; margin-top: 8px; }
.ex-chart .ex-empty { padding-top: 120px; }

/* 견해 바뀜 */
.ex-changes { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 6px; }
.ex-changes li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 8px 10px; border-radius: var(--radius); background: var(--bg-inset); border: 1px solid var(--border-soft); font-size: 13px; min-width: 0; }
.ex-chg-kind { font-weight: 700; color: var(--text-strong); white-space: nowrap; }
.ex-chg-when { color: var(--text-muted); white-space: nowrap; }
.ex-chg-title { color: var(--text-secondary); min-width: 0; overflow-wrap: anywhere; }

/* 영상 타임라인 */
.ex-videos { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 10px; }
.ex-video { padding: 12px 14px; border-radius: var(--radius); background: var(--bg-inset); border: 1px solid var(--border-soft); min-width: 0; }
.ex-video-top { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 12px; color: var(--text-muted); }
.ex-video-title { display: block; margin-top: 4px; font-size: 15px; font-weight: 600; color: var(--accent-text); text-decoration: none; overflow-wrap: anywhere; word-break: keep-all; }
.ex-video-title:hover { text-decoration: underline; }
.ex-video-view { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; margin-top: 8px; font-size: 13px; color: var(--text-primary); }
.ex-video-reason { min-width: 0; overflow-wrap: anywhere; word-break: keep-all; }
.ex-chip { display: inline-flex; align-items: center; min-height: 22px; padding: 0 8px; border-radius: 999px; font-size: 11px; background: var(--bg-card); border: 1px solid var(--border); color: var(--text-secondary); white-space: nowrap; }
.ex-changed { background: var(--warn-bg); border-color: transparent; color: var(--warn); font-weight: 700; }
.ex-pct-up { color: var(--up); font-weight: 600; }
.ex-pct-down { color: var(--down); font-weight: 600; }
.ex-pct-flat { color: var(--flat); font-weight: 600; }

/* 요약 자리 — 프리미엄은 본문, 그 밖에는 잠금·준비 중 */
.ex-summary { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); font-size: 13px; color: var(--text-primary); }
.ex-summary ul { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
.ex-summary li { overflow-wrap: anywhere; word-break: keep-all; }
.ex-summary dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; margin: 10px 0 0; }
.ex-summary dt { color: var(--text-muted); font-size: 12px; }
.ex-summary dd { margin: 0; overflow-wrap: anywhere; }
.ex-quote { margin-top: 8px; padding-left: 10px; border-left: 3px solid var(--border); color: var(--text-secondary); overflow-wrap: anywhere; }
.ex-lock { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; color: var(--text-secondary); }
.ex-lock a { display: inline-flex; align-items: center; min-height: 32px; padding: 0 12px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--accent-soft); color: var(--accent-text); text-decoration: none; }
.ex-lock a:hover { background: var(--bg-hover); }
.ex-pending { color: var(--text-muted); }

@media (max-width: 600px) {
    .ex-chart { height: 260px; }
    .ex-section { padding: 12px; }
    .ex-cards { grid-template-columns: minmax(0, 1fr); }
}

/* 소개 한 줄 — 소속 — 소개. 소개는 굵지 않게, 길면 두 줄까지 */
.ex-spec { font-weight: 400; }
.ex-aff { display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }

/* 전문가 종합 (§9.3) */
.ex-cons { margin-top: 16px; }
.ex-cons-hero { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin-top: 12px; }
.ex-cons-score { font-size: 44px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.ex-cons-bull { color: var(--view-bull); }
.ex-cons-bear { color: var(--view-bear); }
.ex-cons-neutral { color: var(--view-neutral); }
.ex-cons-meta { display: grid; gap: 6px; min-width: 0; flex: 1 1 220px; font-size: 13px; color: var(--text-secondary); }
.ex-dist { display: flex; height: 10px; border-radius: 999px; overflow: hidden; background: var(--bg-inset); }
.ex-dist i { display: block; min-width: 0; }
.ex-dist-bull { background: var(--view-bull); }
.ex-dist-neutral { background: var(--view-neutral); }
.ex-dist-bear { background: var(--view-bear); }
.ex-cons-sub { margin-top: 18px; font-size: 14px; font-weight: 700; color: var(--text-strong); }
.ex-cons .ex-chart { height: 240px; }
.ex-heat-wrap { margin-top: 8px; overflow-x: auto; max-width: 100%; -webkit-overflow-scrolling: touch; }
.ex-heat { border-collapse: separate; border-spacing: 3px; font-size: 12px; }
.ex-heat th { font-weight: 400; color: var(--text-muted); white-space: nowrap; padding: 0 2px; }
.ex-heat th.ex-heat-name { position: sticky; left: 0; z-index: 1; text-align: left; background: var(--bg-card); padding-right: 8px; }
.ex-heat th.ex-heat-name a { color: var(--accent-text); text-decoration: none; font-weight: 600; }
.ex-heat td { width: 34px; height: 26px; min-width: 34px; padding: 0; border-radius: 4px; position: relative; overflow: hidden; }
.ex-heat-fill { position: absolute; inset: 0; display: block; }
.ex-heat-empty { border: 1px dashed var(--border); }
.ex-cons-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 6px; }
.ex-cons-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding: 8px 10px; border-radius: var(--radius); background: var(--bg-inset); border: 1px solid var(--border-soft); font-size: 13px; min-width: 0; }
.ex-cons-list a { color: var(--accent-text); text-decoration: none; }
.ex-top-name { font-weight: 700; color: var(--text-strong); }
.ex-vtable { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 13px; }
.ex-vtable th, .ex-vtable td { padding: 6px 8px; text-align: right; border-bottom: 1px solid var(--border-soft); white-space: nowrap; }
.ex-vtable th:first-child, .ex-vtable td:first-child { text-align: left; }
.ex-vtable th { font-weight: 400; color: var(--text-muted); }
.ex-cons .ex-lock { margin-top: 8px; padding: 10px; border-radius: var(--radius); background: var(--bg-inset); border-top: 0; }

@media (max-width: 600px) {
    .ex-cons .ex-chart { height: 220px; }
    .ex-cons-score { font-size: 38px; }
}

.ex-rank li { align-items: center; }
.ex-rank-no { min-width: 18px; font-weight: 700; color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* 방송자료(신의자료실 PDF) 행 — 📄 배지는 사이트 강조색(accent) 테두리로 영상 행과 구분, 색은 tokens.css 변수만 */
.ex-chip-pds { border-color: var(--accent-text); color: var(--accent-text); font-weight: 600; }
.ex-pds { border-left: 3px solid var(--accent-text); }
.ex-chart-notes { margin-top: 10px; }
.ex-chart-notes-h { color: var(--text-muted); font-size: 12px; margin-bottom: 4px; }

/* 검사관 배지(§11) — 작게, 누르면 종류별 제외 수 */
.ex-verify { margin-top: 6px; font-size: 12px; color: var(--text-secondary); }
.ex-verify > summary { list-style: none; cursor: pointer; }
.ex-verify > summary::-webkit-details-marker { display: none; }
.ex-verify > summary:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 2px; }
.ex-chip-verify { color: var(--text-secondary); }
.ex-verify-body { margin-top: 6px; padding: 8px 10px; border-radius: 8px; background: var(--bg-card); border: 1px solid var(--border); line-height: 1.5; overflow-wrap: anywhere; }

/* 하루 묶음(docs/experts-day-view-design.md §6) — 날짜 머리줄 아래 그날 항목. 종목 영상 칩은 주의색(--warn), 그 견해 배지는 흐리게 */
.ex-days { list-style: none; margin: 0; padding: 0; }
.ex-day { min-width: 0; }
.ex-day-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px; padding-bottom: 6px; border-bottom: 1px solid var(--border-soft); min-width: 0; }
.ex-day:first-child .ex-day-head { margin-top: 8px; }
.ex-day-date { font-weight: 700; color: var(--text-strong); font-size: 14px; white-space: nowrap; }
.ex-day-tags { flex-basis: 100%; min-width: 0; font-size: 12px; color: var(--text-muted); overflow-wrap: anywhere; word-break: keep-all; }
.ex-chip-stock { background: var(--warn-bg); border-color: transparent; color: var(--warn); }
.ex-badge.ex-muted { opacity: .6; }
