/* TikTok · Communications créateurs */
.tk-page { display: flex; flex-direction: column; gap: 20px; }

.tk-shopbar { display: flex; flex-wrap: wrap; gap: 8px; }
.tk-chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border: 1px solid #e3e3e6;
  border-radius: 999px; background: #fff; font-size: 13px; color: #3b3b40; text-decoration: none; }
.tk-chip strong { font-variant-numeric: tabular-nums; color: #111; }
.tk-chip.current { border-color: #111; background: #111; color: #fff; }
.tk-chip.current strong { color: #fff; }
.tk-chip:hover { border-color: #111; }

.tk-region { display: inline-block; min-width: 30px; padding: 2px 7px; border-radius: 5px; background: #f1f1f3;
  font-size: 12px; font-weight: 600; letter-spacing: 0.04em; text-align: center; }
.tk-preview { color: #4a4a50; max-width: 520px; }
.tk-from-us { color: #8a8a90; font-style: italic; }
.tk-badge { display: inline-block; margin-left: 8px; padding: 1px 7px; border-radius: 999px;
  background: #d8261c; color: #fff; font-size: 11px; font-weight: 600; }
.tk-count { margin: 12px 2px 0; font-size: 13px; }

.tk-head-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tk-h2 { margin: 0 0 4px; font-size: 16px; }
.tk-h3 { margin: 22px 0 8px; font-size: 14px; color: #55555c; }

.tk-thread { display: flex; flex-direction: column; gap: 12px; max-height: 60vh; overflow-y: auto; }
.tk-msg { max-width: 76%; padding: 10px 14px; border-radius: 14px; border: 1px solid #e6e6ea; background: #fff; }
.tk-msg header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin-bottom: 4px;
  font-size: 12px; color: #80808a; }
.tk-msg header strong { color: #2b2b30; font-size: 12.5px; }
.tk-msg p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.5; }
.tk-msg.in { align-self: flex-start; background: #f6f6f8; }
.tk-msg.out { align-self: flex-end; background: #eef5ff; border-color: #d5e4fb; }
.tk-type { padding: 0 6px; border-radius: 4px; background: #f1f1f3; font-size: 11px; letter-spacing: 0.03em; }
.tk-fr { margin-top: 8px !important; padding-top: 8px; border-top: 1px dashed #d9d9df; color: #444; }
.tk-fr span { display: block; margin-bottom: 2px; font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.06em; color: #90909a; }

.tk-facts { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.tk-facts li { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px solid #ededf1;
  border-radius: 10px; background: #fbfbfc; }
.tk-facts span { font-size: 12px; color: #80808a; }
.tk-facts strong { font-size: 14px; overflow-wrap: anywhere; }

.tk-outbound { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.tk-outbound li { padding: 8px 10px; border: 1px solid #ededf1; border-radius: 8px; font-size: 13px; }
.tk-outbound em { display: block; margin-top: 4px; color: #b3261e; font-style: normal; font-size: 12px; }

@media (max-width: 760px) {
  .tk-msg { max-width: 92%; }
  .tk-thread { max-height: none; }
}

.tk-url { display: inline-block; padding: 8px 10px; border: 1px solid #e0e0e6; border-radius: 8px;
  background: #fafafb; font-size: 13px; overflow-wrap: anywhere; user-select: all; }

/* Communication affiliates */
.tk-inbox, .tk-conversation { min-width: 0; }
.tk-heading { align-items: center; margin: 0; }
.tk-heading h1 { margin: 0; }
.tk-list { padding: 0; overflow: hidden; }
.tk-tabs, .tk-filters, .tk-list-foot, .tk-pagination, .tk-subhead, .tk-thread-tools {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
}
.tk-tabs { gap: 4px; padding: 0 14px; background: #f6f9fd; border-bottom: 1px solid var(--line); }
.tk-tabs a { padding: 12px 10px 9px; border-bottom: 3px solid transparent; color: var(--muted); font-weight: 600; text-decoration: none; }
.tk-tabs a[aria-current] { color: var(--accent); border-bottom-color: var(--accent); }
.tk-filters { align-items: flex-end; padding: 14px 16px 6px; }
.tk-filters .field { margin: 0; }
.tk-filters select, .tk-filters input { min-height: 32px; }
.tk-filters .tk-small-sort { display: none; }
.tk-search { flex: 1 1 160px; max-width: 310px; }
.tk-filters .tk-clear { font-size: 12px; padding: 6px 0; }
.tk-list-count, .tk-list-foot { padding: 8px 16px; color: var(--muted); font-size: 12px; }
.tk-list-count strong { color: var(--ink); }
.tk-list-foot { justify-content: space-between; }
.tk-table-wrap { width: 100%; overflow-x: auto; }
.tk-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-variant-numeric: tabular-nums; font-size: 12px; }
.tk-table th, .tk-table td { border: 0; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tk-table thead th { padding: 8px 6px; background: #f1f5fb; color: #455c77; font-weight: 650; text-align: left; }
.tk-table thead th a { display: inline-block; color: inherit; text-decoration: none; }
.tk-table thead th a:hover, .tk-toggle:hover strong { text-decoration: underline; }
.tk-table thead th[aria-sort] { color: var(--accent); }
.tk-table thead th:first-child { width: 17%; padding-left: 16px; }
.tk-table thead th:nth-child(2) { width: 6%; }
.tk-table thead th:nth-child(3) { width: 11%; }
.tk-table thead th:nth-child(4) { width: 9%; }
.tk-table thead th:nth-child(5) { width: 10%; }
.tk-table thead th:nth-child(6) { width: 6%; }
.tk-table thead th:nth-child(7), .tk-table thead th:nth-child(8) { width: 12%; }
.tk-summary { cursor: pointer; }
.tk-summary:hover, .tk-summary:focus-within, .tk-summary:has([aria-expanded="true"]) { background: #f2f7ff; }
.tk-summary > td, .tk-summary > th { padding: 5px 6px; height: 43px; text-align: left; }
.tk-summary .tk-person { padding-left: 10px; }
.tk-toggle { display: flex; align-items: center; gap: 7px; color: var(--ink); text-decoration: none; }
.tk-chevron { line-height: 20px; font-size: 22px; color: var(--accent); }
.tk-toggle[aria-expanded="true"] .tk-chevron { transform: rotate(90deg); }
.tk-name { min-width: 0; }
.tk-name > *, .tk-activity > * { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tk-name span, .tk-activity span, .tk-unread, .tk-sync { color: var(--muted); font-size: 11px; font-weight: 400; }
.tk-state { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; font-size: 12px; color: #38566c; }
.tk-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #64809b; }
.tk-state.pending { color: #874400; font-weight: 650; }
.tk-state.pending::before { background: #ca7712; }
.tk-state.closed { color: #556475; }
.tk-state.closed::before { background: transparent; border: 1px solid currentColor; }
.tk-unread { display: block; margin: 2px 0 0 11px; }
.tk-detail[hidden] { display: none !important; }
.tk-detail > td { padding: 0; }
.tk-panel-host { padding: 10px; background: #edf3fa; }
.tk-conversation { border: 1px solid #ccdaea; border-radius: 8px; background: white; padding: 14px; overflow-wrap: anywhere; }
.tk-subhead { justify-content: space-between; margin-bottom: 8px; }
.tk-thread { padding: 9px; border: 1px solid var(--line); border-radius: 6px; background: #fafcff; max-height: 370px; overflow-y: auto; gap: 6px; }
.tk-msg { padding: 7px 9px; max-width: 91%; }
.tk-msg p { font-size: 13px; }
.tk-compose { display: grid; gap: 7px; margin: 12px 0 8px; }
.tk-compose label { font-size: 12px; font-weight: 650; }
.tk-compose textarea { width: 100%; resize: vertical; }
.tk-compose .button { justify-self: start; }
.tk-thread-tools { gap: 7px; }
.tk-empty { color: var(--muted); margin: 5px 0; font-size: 12px; }
.tk-sync { margin: 5px 0; }
@media (max-width: 1100px) and (min-width: 761px) {
  .tk-table { font-size: 11px; }
  .tk-table thead th a span { display: none; }
}
@media (max-width: 760px) {
  .tk-page { gap: 12px; }
  .tk-heading { flex-wrap: wrap; row-gap: 6px; }
  .tk-list { border-radius: 8px; }
  .tk-tabs { padding: 0 5px; gap: 0; }
  .tk-tabs a { padding: 11px 7px 8px; font-size: 12px; }
  .tk-filters { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; padding: 10px; }
  .tk-filters .field { min-width: 0; }
  .tk-filters input, .tk-filters select { width: 100%; font-size: 16px; }
  .tk-filters .tk-small-sort { display: flex; }
  .tk-filters .button { justify-self: start; }
  .tk-list-count, .tk-list-foot { padding: 8px 10px; }
  .tk-table, .tk-table tbody { display: block; }
  .tk-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .tk-summary { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); padding: 8px 10px; gap: 5px; border-top: 1px solid var(--line); }
  .tk-summary > th, .tk-summary > td { height: auto; padding: 0; border: 0; }
  .tk-summary .tk-person { padding: 0; grid-column: span 2; }
  .tk-country-cell { justify-self: end; align-self: center; }
  .tk-summary td[data-label]:not(.tk-country-cell)::before { content: attr(data-label); display: block; font-size: 10px; color: var(--muted); }
  .tk-activity { grid-column: 1 / -1; }
  .tk-detail, .tk-detail > td { display: block; }
  .tk-panel-host { padding: 4px; }
  .tk-conversation { padding: 10px; }
  .tk-thread { max-height: 45vh; }
  .tk-compose textarea { font-size: 16px; }
  .tk-thread-tools .button, .tk-compose .button, .tk-pagination .button { min-height: 40px; }
}
@media (max-width: 600px) {
  .tiktok-section .sidebar { padding: 4px 10px; }
  .tiktok-section .sidebar > .workspace-label, .tiktok-section .topbar { display: none; }
  .tiktok-section .sidebar > nav { display: flex; gap: 4px; }
  .tiktok-section .sidebar .nav-main { padding: 5px 8px; min-height: 34px; }
  .tiktok-section .sidebar .nav-icon { display: none; }
  .tiktok-section .main-content { padding: 12px 9px 22px; }
}

.tk-revenue-period { display: inline-block; }

/* La synthèse et les produits occupent toute la largeur, en liste comme en pleine page. */
.tk-collaboration-dashboard {
  container: creator-panel / inline-size;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.4;
  padding: clamp(12px, 1.6vw, 23px);
  text-align: left;
  font-variant-numeric: tabular-nums;
}
.tk-collaboration-dashboard h1, .tk-collaboration-dashboard h2, .tk-collaboration-dashboard h3 {
  color: var(--ink); line-height: 1.25; margin: 0;
}
.tk-collab-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 18px; margin-bottom: 14px; }
.tk-identity h1, .tk-identity h2 { font-size: 24px; letter-spacing: -.025em; }
.tk-identity-meta, .tk-head-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 14px; }
.tk-identity-meta { font-size: 12px; color: var(--muted); margin-bottom: 3px; }
.tk-handle { font-size: 12px; color: var(--muted); }
.tk-collab-head a, .tk-reload { font-size: 12px; color: var(--accent); }
.tk-overview {
  display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.15fr);
  border: 1px solid #c6d8e9; border-radius: 9px; overflow: hidden;
}
.tk-overview h2 { margin-bottom: 6px; font-size: 12px; font-weight: 650; color: #425b78; }
.tk-overview-status, .tk-overview-actions { padding: 12px 15px; }
.tk-overview-status { background: #edf4fd; border-inline-start: 4px solid #416ebb; }
.tk-overview-status p { margin: 0; font-size: clamp(17px,1.6vw,22px); line-height: 1.28; font-weight: 660; letter-spacing: -.025em; }
.tk-overview-actions { background: #fafcff; border-inline-start: 1px solid #d7e2ef; }
.tk-overview-actions ul { display: grid; gap: 5px; padding: 0; margin: 0; list-style: none; }
.tk-overview-actions li { display: flex; gap: 8px; align-items: baseline; font-size: 13px; }
.tk-overview-actions strong { font-weight: 640; }
.tk-owner { flex-shrink: 0; padding: 1px 6px; border-radius: 4px; font-size: 11px; font-weight: 650; background: #e4edf9; color: #2b4b7d; }
.tk-collab-section { min-width: 0; margin-top: 17px; }
.tk-collab-section > h2, .tk-discussion .tk-subhead > h2 { margin-bottom: 7px; font-size: 16px; letter-spacing: -.012em; }
.tk-collab-section h3 { font-size: 14px; }
.tk-collab-section small { color: var(--muted); font-size: 11px; display: block; line-height: 1.36; }
.tk-followup-table { border: 1px solid var(--line); border-radius: 7px; overflow: hidden; }
.tk-followup-labels, .tk-followup-product { display: grid; grid-template-columns: minmax(0,1.45fr) minmax(0,.95fr) minmax(0,1fr) minmax(0,1.13fr); gap: 12px; }
.tk-followup-labels { padding: 7px 11px; color: #445b73; background: #f2f6fa; font-size: 12px; font-weight: 600; }
.tk-followup-product { padding: 10px 11px; border-top: 1px solid var(--line); align-items: start; font-size: 13px; }
.tk-followup-name { display: flex; align-items: flex-start; gap: 8px; min-width: 0; }
.tk-followup-name img { width: 36px; height: 42px; object-fit: contain; flex: none; }
.tk-followup-product strong { font-weight: 640; }
.tk-followup-product p, .tk-observed-total p, .tk-video-entry p { margin: 0 0 2px; }
.tk-followup-name p { font-size: 12px; margin-top: 3px; color: var(--muted); }
.tk-sample-step + .tk-sample-step, .tk-offer + .tk-offer { margin-top: 5px; }
.tk-followup-sample .tk-sample-step strong { color: #28475c; }
.tk-narrow-label { display: none; }
.tk-offer dl { display: grid; gap: 2px; margin: 0; }
.tk-offer dl > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; justify-content: space-between; }
.tk-offer dt, .tk-video-ads dt, .tk-video-metrics dt { color: #4c627a; font-size: 12px; }
.tk-collaboration-dashboard dd { font-weight: 650; margin: 0; }
.tk-observed-commissions { margin: 3px 0; padding: 0; list-style: none; font-size: 12px; }
.tk-results-strip { display: flex; flex-wrap: wrap; padding: 10px 0; gap: 8px 0; border-block: 1px solid var(--line); }
.tk-result { padding: 0 14px; flex: 1 1 120px; border-inline-start: 1px solid var(--line); }
.tk-result:first-child { padding-inline-start: 0; border: 0; }
.tk-result > strong, .tk-result > span { display: block; }
.tk-result > strong { font-size: 18px; letter-spacing: -.02em; }
.tk-result-label { color: #405570; font-size: 12px; margin-bottom: 2px; }
.tk-result .tk-unknown { font-size: 13px; color: var(--muted); }
.tk-result-sales { flex-grow: 1.6; }
.tk-coverage { color: var(--muted); font-size: 12px; margin: 6px 0 0; }
.tk-observed-total { font-size: 13px; margin-top: 6px; }
.tk-collab-lower { display: grid; grid-template-columns: minmax(0,1.2fr) minmax(0,1fr); gap: 20px; }
.tk-discussion .tk-subhead { align-items: baseline; }
.tk-discussion .tk-subhead h2 { margin: 0; }
.tk-msg header, .tk-msg header strong { font-size: 11px; }
.tk-card-label { display: block; font-size: 13px; }
.tk-evidence-log { border-left: 1px solid var(--line); padding-inline-start: 18px; }
.tk-event-list { margin: 8px 0 0 6px; padding: 0 0 0 13px; border-inline-start: 1px solid #bed0df; list-style: none; }
.tk-event-list li { position: relative; padding: 0 0 10px; font-size: 13px; }
.tk-event-list li:last-child { padding-bottom: 0; }
.tk-event-list li::before { content: ""; position: absolute; inset-inline-start: -17px; top: 5px; width: 7px; height: 7px; border-radius: 50%; background: #6989ad; }
.tk-event-meta, .tk-event-list blockquote { margin: 0; font-size: 11px; color: var(--muted); }
.tk-event-list blockquote { margin-top: 2px; }
.tk-evidence-log h3, .tk-other-threads h3, .tk-send-log h3 { margin: 14px 0 5px; }
.tk-audience-history { margin: 0; padding: 0; list-style: none; }
.tk-audience-history li { margin-top: 5px; font-size: 12px; }
.tk-video-entry { display: flex; gap: 11px; padding: 9px 0; border-top: 1px solid var(--line); }
.tk-video-entry img { width: 51px; height: 68px; border-radius: 5px; object-fit: cover; flex: none; }
.tk-video-content { min-width: 0; flex: 1; font-size: 13px; }
.tk-video-content a { color: var(--accent); }
.tk-video-metrics, .tk-video-ads { display: flex; flex-wrap: wrap; gap: 7px 20px; margin: 6px 0 0; }
.tk-video-metrics:empty { display: none; }
.tk-video-ads dd { font-size: 13px; }
.tk-video-ads code { overflow-wrap: anywhere; user-select: all; }
.tk-spark-attach { display: flex; align-items: end; flex-wrap: wrap; gap: 7px; margin-top: 8px; font-size: 12px; }
.tk-spark-attach label { display: grid; gap: 4px; }
@container creator-panel (max-width: 700px) {
  .tk-overview { grid-template-columns: minmax(0,1fr); }
  .tk-overview-actions { border-inline-start: 0; border-top: 1px solid #d7e2ef; }
  .tk-followup-labels { display: none; }
  .tk-followup-product { grid-template-columns: minmax(0, 1fr) minmax(0,1fr); gap: 9px 13px; }
  .tk-followup-product:nth-child(2) { border: 0; }
  .tk-followup-name { grid-column: 1 / -1; align-items: center; }
  .tk-narrow-label { display: block; margin-bottom: 2px; font-size: 11px; color: #4c627a; }
  .tk-followup-terms { grid-column: 1 / -1; background: #f5f8fb; border-radius: 4px; padding: 5px 8px; }
  .tk-offer dl { display: flex; flex-wrap: wrap; gap: 3px 15px; }
  .tk-collab-lower { grid-template-columns: minmax(0,1fr); gap: 0; }
  .tk-evidence-log { border: 0; padding-inline-start: 0; }
}
@container creator-panel (max-width: 440px) {
  .tk-overview-status, .tk-overview-actions { padding: 10px; }
  .tk-head-actions { gap: 3px 10px; }
  .tk-head-actions a { display: inline-flex; align-items: center; min-height: 35px; }
  .tk-head-actions .button { min-height: 36px; }
  .tk-results-strip { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .tk-result { padding: 0 8px; }
  .tk-result:nth-child(odd) { border: 0; padding-inline-start: 0; }
  .tk-overview-actions li { flex-wrap: wrap; gap: 2px 7px; }
  .tk-video-metrics, .tk-video-ads { gap: 5px 10px; }
}
.tk-attributed-sales { margin: 4px 0; font-size: 12px; }
.tk-attributed-sales p { margin: 1px 0; }
.tk-overview-actions small { display: block; color: var(--muted); font-size: 11px; }
.tk-overview-status small { display: block; margin-top: 5px; color: #405570; font-size: 12px; }
