

#cc-views[hidden], #cc-call-filters[hidden], #cc-panels[hidden],
#cc-callbacks-count[hidden] { display: none !important; }


.cc-views {
  display: inline-flex; gap: 2px; padding: 3px; margin: 0 0 12px;
  border: 1px solid var(--border); border-radius: 10px; background: var(--bg-subtle);
}
.cc-view-btn {
  appearance: none; border: 0; background: transparent; color: var(--text-secondary);
  font: inherit; font-size: 13px; font-weight: 600; padding: 6px 14px; border-radius: 8px;
  cursor: pointer; min-height: 32px;
}
.cc-view-btn:hover { color: var(--text-primary); }
.cc-view-btn.is-active {
  background: var(--bg-elevated); color: var(--text-primary);
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
}


.cc-call-filters { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }


.cc-panels { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 12px; margin: 4px 0 14px; }
.cc-card {
  border: 1px solid var(--border); border-radius: 12px; background: var(--bg-elevated);
  min-width: 0;
}
.cc-card-head {
  display: flex; align-items: center; gap: 8px; padding: 10px 14px; cursor: pointer;
  list-style: none; font-weight: 600; font-size: 14px; color: var(--text-primary);
}
.cc-card-head::-webkit-details-marker { display: none; }
.cc-card-head::after {
  content: ""; margin-inline-start: auto; width: 7px; height: 7px; border-inline-end: 2px solid var(--text-tertiary);
  border-bottom: 2px solid var(--text-tertiary); transform: rotate(45deg); transition: transform .15s;
}
.cc-card:not([open]) > .cc-card-head::after { transform: rotate(-45deg); }
.cc-card-count {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; display: inline-flex;
  align-items: center; justify-content: center; font-size: 12px; font-weight: 700;
  background: var(--warning-soft, rgba(245,158,11,.18)); color: var(--warning-text, #92400e);
}
.cc-card-body { padding: 0 14px 14px; min-width: 0; }
.cc-empty { color: var(--text-secondary); font-size: 13px; margin: 4px 0; }
.cc-note { color: var(--text-tertiary); font-size: 12px; margin: 10px 0 0; line-height: 1.45; }
.cc-loading { padding: 6px 0; }

.cc-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; }
.cc-tile {
  display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 10px;
  background: var(--bg-subtle); min-width: 0;
}
.cc-tile-value {
  font-size: 20px; font-weight: 700; color: var(--text-primary);
  font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cc-tile-label { font-size: 12px; color: var(--text-secondary); }

.cc-tile.is-wide { grid-column: span 2; }
.cc-tile.is-wide .cc-tile-value { font-size: 17px; white-space: normal; line-height: 1.35; }

.cc-charts { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; margin-top: 14px; }
.cc-chart-title { font-size: 12px; font-weight: 600; color: var(--text-secondary); margin: 0 0 6px; }
.cc-bars {
  display: grid; align-items: end; gap: 2px; height: 84px;
  border-bottom: 1px solid var(--border);
}
.cc-bars.is-hours { grid-template-columns: repeat(24, minmax(0, 1fr)); }
.cc-bars.is-days  { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cc-bar { height: 100%; display: flex; align-items: flex-end; cursor: default; }
.cc-bar:hover .cc-bar-fill { opacity: .75; }
.cc-bar-fill {
  display: block; width: 100%; min-height: 0; background: var(--brand);
  border-radius: 4px 4px 0 0;
}
.cc-axis { display: flex; justify-content: space-between; margin-top: 4px; font-size: 11px; color: var(--text-tertiary); }
.cc-axis.is-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; text-align: center; }


.cc-cb-list { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow: auto; }
.cc-cb-row {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 10px; align-items: center;
  padding: 8px 0; border-top: 1px solid var(--border);
}
.cc-cb-row:first-child { border-top: 0; }
.cc-cb-row .cc-cb-tags { grid-column: 2 / 3; }
.cc-cb-row .cc-link-btn { grid-column: 3; grid-row: 1 / span 2; }
.cc-cb-row.is-done .cc-cb-who { color: var(--text-secondary); }
.cc-cb-main { display: flex; flex-wrap: wrap; gap: 2px 8px; align-items: baseline; min-width: 0; }
.cc-cb-who { font-weight: 600; color: var(--text-primary); overflow-wrap: anywhere; }
.cc-cb-sub, .cc-cb-when, .cc-cb-by { font-size: 12px; color: var(--text-secondary); }
.cc-cb-tags { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; }


.cc-tick { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-primary); cursor: pointer; }
.cc-tick input { width: 18px; height: 18px; margin: 0; accent-color: var(--success, #10b981); cursor: pointer; }
.cc-cb-row .cc-tick span {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}


.cc-row-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.cc-tag {
  display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; line-height: 1.5;
  padding: 0 7px; border-radius: 999px; white-space: nowrap;
  background: var(--bg-subtle); color: var(--text-secondary); border: 1px solid var(--border);
}
.cc-tag.is-mood-happy   { color: var(--success-text, #047857); border-color: transparent; background: var(--success-soft, rgba(16,185,129,.14)); }
.cc-tag.is-mood-unhappy { color: var(--danger-text, #b91c1c); border-color: transparent; background: var(--danger-soft, rgba(239,68,68,.12)); }
.cc-tag.is-repeat       { color: var(--brand-text, #0066cc); border-color: transparent; background: var(--brand-soft, rgba(0,113,227,.10)); }
.cc-tag.is-done         { color: var(--success-text, #047857); }
.cc-tag.is-missed, .cc-tag.is-transfer, .cc-tag.is-ai_unavailable {
  color: var(--warning-text, #92400e); border-color: transparent; background: var(--warning-soft, rgba(245,158,11,.16));
}
.cc-num { font-weight: 700; font-variant-numeric: tabular-nums; }

.cc-link-btn {
  appearance: none; border: 1px solid var(--border-control, var(--border)); background: var(--bg-elevated);
  color: var(--text-primary); font: inherit; font-size: 13px; font-weight: 600;
  padding: 5px 12px; border-radius: 8px; cursor: pointer; min-height: 32px; white-space: nowrap;
}
.cc-link-btn:hover { background: var(--bg-hover); }
.cc-link-btn:disabled { opacity: .55; cursor: default; }


.cc-match { display: flex; gap: 6px; margin-top: 3px; font-size: 12px; color: var(--text-secondary); min-width: 0; }
.cc-match-who { font-weight: 600; flex: none; }
.cc-match-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }


.cc-call-box { display: flex; flex-direction: column; gap: 6px; }
.cc-call-facts { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; }
.cc-call-facts:empty { display: none; }
.cc-consent { margin: 0; font-size: 12.5px; color: var(--text-secondary); }

.cc-player { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.cc-speed { display: inline-flex; gap: 2px; margin-inline-start: auto; }
.cc-pbtn {
  appearance: none; border: 1px solid var(--border-control, var(--border)); background: var(--bg-elevated);
  color: var(--text-primary); font: inherit; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums;
  min-width: 44px; min-height: 32px; padding: 0 8px; border-radius: 8px; cursor: pointer;
}
.cc-pbtn:hover { background: var(--bg-hover); }
.cc-pbtn.is-active { background: var(--brand-soft, rgba(0,113,227,.10)); color: var(--brand-text, #0066cc); border-color: transparent; }

.cc-turn-time {
  appearance: none; border: 0; background: none; padding: 0; margin: 0 0 2px;
  font: inherit; font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums;
  color: var(--text-tertiary); display: block;
}
button.cc-turn-time { color: var(--brand-text, #0066cc); cursor: pointer; }
.cc-turn-time { margin: 3px 0 0; letter-spacing: 0; }
.voice-turn.is-seekable { cursor: pointer; border-radius: 8px; padding-inline-start: 6px; padding-inline-end: 6px; margin: 0 -6px; }
.voice-turn.is-seekable:hover { background: var(--bg-hover); }
.voice-turn.is-playing { background: var(--brand-soft, rgba(0,113,227,.10)); }

.cc-notes .cc-note-form { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.cc-note-input { width: 100%; min-height: 56px; resize: vertical; font: inherit; }
.cc-note-list { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.cc-note-list .cc-note { margin: 0; padding: 8px 10px; border-radius: 8px; background: var(--bg-subtle); }
.cc-note-body { white-space: pre-wrap; color: var(--text-primary); font-size: 13.5px; line-height: 1.45; }
.cc-note-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; font-size: 12px; color: var(--text-secondary); align-items: center; }
.cc-note-del { appearance: none; border: 0; background: none; padding: 0; font: inherit; color: var(--danger-text, #b91c1c); cursor: pointer; margin-inline-start: auto; }

.cc-others-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.cc-other {
  appearance: none; width: 100%; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center;
  text-align: start; font: inherit; font-size: 13px; color: var(--text-primary);
  background: var(--bg-subtle); border: 1px solid transparent; border-radius: 8px; padding: 7px 10px; cursor: pointer;
}
.cc-other:hover:not(:disabled) { border-color: var(--border); }
.cc-other:disabled { cursor: default; }
.cc-other-kind, .cc-other-len { color: var(--text-secondary); font-size: 12px; }


.vcr-outcome[data-outcome="missed"],
.vcr-outcome[data-outcome="ai_unavailable"] { background: rgba(245,158,11,.18); color: #92400e; }
.vcr-outcome[data-outcome="hung_up"],
.vcr-outcome[data-outcome="went_silent"]    { background: rgba(100,116,139,.16); color: #475569; }
html[data-theme="dark"] .vcr-outcome[data-outcome="missed"],
html[data-theme="dark"] .vcr-outcome[data-outcome="ai_unavailable"] { color: #fbbf24; }
html[data-theme="dark"] .vcr-outcome[data-outcome="hung_up"],
html[data-theme="dark"] .vcr-outcome[data-outcome="went_silent"]    { color: #cbd5e1; }


.cc-voice-moved { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.cc-voice-moved-text { margin: 0; color: var(--text-secondary); line-height: 1.5; }


@media (max-width: 1100px) {
  .cc-panels { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .cc-charts { grid-template-columns: minmax(0, 1fr); }
  .cc-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cc-views { display: flex; }
  .cc-view-btn { flex: 1; min-height: 40px; }
  .cc-bars { height: 64px; }
  .cc-speed { margin-inline-start: 0; }
  .cc-pbtn { min-height: 40px; }
  .cc-link-btn { min-height: 40px; }
}
