/* 261111-gsd: GHL SETTER DIALS tab. Styled after the dialer.io app (Inter, near-black ink, white cards, 8px corners, blue brand). */
#view-ghl-dials {
  --gd-ink: #0f0f0f; --gd-muted: #6b6b70; --gd-faint: #9a9aa0; --gd-line: #ececee; --gd-soft: #f7f7f8;
  --gd-blue: #2b44e6; --gd-blue-soft: #eef0fd; --gd-good: #12805c; --gd-bad: #c4320a;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color: var(--gd-ink);
}
#view-ghl-dials * { box-sizing: border-box; }
.gd { display: grid; gap: 16px; max-width: 1280px; font-variant-numeric: tabular-nums; }
.gd-top { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; justify-content: space-between; }
.gd-top h2 { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; margin: 0; color: var(--gd-ink); }
.gd-top p { margin: 0; font-size: 13px; color: var(--gd-muted); align-self: center; }
#gd-share { min-height: 0; }
.gd-range { display: inline-flex; gap: 2px; padding: 3px; background: var(--gd-soft); border: 1px solid var(--gd-line); border-radius: 8px; flex-wrap: wrap; }
.gd-range button { font: 500 13px/1 Inter, system-ui, sans-serif; padding: 8px 12px; border: 0; border-radius: 6px; background: transparent; color: var(--gd-muted); cursor: pointer; }
.gd-range button:hover { color: var(--gd-ink); }
.gd-range button.on { background: var(--gd-ink); color: #fff; }
.gd-range button:focus-visible, .gd-th:focus-visible { outline: 2px solid var(--gd-blue); outline-offset: 1px; }

.gd-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.gd-card { background: #fff; border: 1px solid var(--gd-line); border-radius: 8px; min-width: 0; }
.gd-kpi { padding: 16px 18px; display: grid; gap: 6px; }
.gd-kpi-l { font-size: 13px; font-weight: 500; color: var(--gd-muted); }
.gd-kpi-v { font-size: 30px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
.gd-kpi-s { font-size: 12px; color: var(--gd-faint); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.gd-delta { font-weight: 600; padding: 2px 6px; border-radius: 999px; font-size: 11px; }
.gd-delta.up { color: var(--gd-good); background: #e8f6f0; }
.gd-delta.down { color: var(--gd-bad); background: #fdeee8; }
.gd-delta.flat { color: var(--gd-muted); background: var(--gd-soft); }

.gd-row2 { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 12px; }
.gd-panel-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 14px 18px 0; flex-wrap: wrap; }
.gd-panel-h h3 { font-size: 14px; font-weight: 600; margin: 0; }
.gd-panel-h span { font-size: 12px; color: var(--gd-faint); }
.gd-chart { position: relative; padding: 8px 12px 10px; min-height: 240px; }
.gd-chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.gd-chart text { font: 11px Inter, system-ui, sans-serif; fill: var(--gd-faint); }
.gd-legend { display: flex; flex-wrap: wrap; gap: 14px; padding: 0 18px 14px; font-size: 12px; color: var(--gd-muted); }
.gd-legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.gd-tip { position: absolute; pointer-events: none; background: #fff; border: 1px solid var(--gd-line); box-shadow: 0 6px 20px rgba(15,15,15,.10); border-radius: 8px; padding: 10px 12px; font-size: 12px; min-width: 150px; z-index: 3; }
.gd-tip b { display: block; font-weight: 600; margin-bottom: 6px; color: var(--gd-ink); }
.gd-tip div { display: flex; justify-content: space-between; gap: 16px; color: var(--gd-muted); line-height: 1.6; }
.gd-tip div span:last-child { color: var(--gd-ink); font-weight: 500; }
.gd-empty { padding: 48px 16px; text-align: center; color: var(--gd-faint); font-size: 13px; }

.gd-tw { overflow-x: auto; }
.gd-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.gd-table th { text-align: right; font-weight: 500; color: var(--gd-muted); font-size: 12px; padding: 10px 14px; border-bottom: 1px solid var(--gd-line); background: var(--gd-soft); white-space: nowrap; }
.gd-table th:first-child, .gd-table td:first-child { text-align: left; }
.gd-th { cursor: pointer; user-select: none; }
.gd-th[aria-sort] { color: var(--gd-ink); }
.gd-th[aria-sort="descending"]::after { content: " ↓"; }
.gd-th[aria-sort="ascending"]::after { content: " ↑"; }
.gd-table td { text-align: right; padding: 12px 14px; border-bottom: 1px solid var(--gd-line); white-space: nowrap; }
.gd-table tbody tr:hover td { background: #fafafb; }
.gd-table tfoot td { font-weight: 600; border-bottom: 0; background: var(--gd-soft); }
.gd-agent { display: flex; align-items: center; gap: 10px; }
.gd-av { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 600; color: #fff; flex: none; }
.gd-name { font-weight: 500; }
.gd-role { font-size: 11px; font-weight: 500; color: var(--gd-muted); background: var(--gd-soft); border: 1px solid var(--gd-line); border-radius: 999px; padding: 2px 8px; }
.gd-rate { display: inline-flex; align-items: center; gap: 8px; }
.gd-bar { width: 56px; height: 6px; border-radius: 3px; background: var(--gd-soft); overflow: hidden; display: inline-block; }
.gd-bar i { display: block; height: 100%; background: var(--gd-blue); border-radius: 3px; }
.gd-foot { font-size: 12px; color: var(--gd-faint); margin: 0; line-height: 1.5; }
.gd-err { padding: 12px 16px; border: 1px solid #f5c2b3; background: #fdf3ef; color: var(--gd-bad); border-radius: 8px; font-size: 13px; }
.gd-load { opacity: .55; transition: opacity .15s; }

@media (max-width: 1100px) { .gd-row2 { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .gd-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } .gd-kpi-v { font-size: 24px; } }
