/* Relationship plugins inherit the active application's chart theme. */
.rc-frame {
  --rc-text: var(--ac-text, #d9d9d9);
  --rc-muted: var(--ac-muted, #a6a6a6);
  --rc-surface: var(--ac-surface, #141414);
  --rc-elevated: var(--ac-elevated, #1d1d1d);
  --rc-border: var(--ac-border, #383838);
  --rc-font: var(--ac-font, Roboto, sans-serif);
  display: flex; flex-direction: column; position: relative;
  width: 100%; height: 100%; min-width: 0; min-height: 0;
  color: var(--rc-text); font: 400 12px/1.4 var(--rc-font);
  font-variant-numeric: var(--num-variant, tabular-nums lining-nums); overflow: hidden;
}
.rc-frame, .rc-frame * { box-sizing: border-box; }
.rc-caption { display: flex; align-items: baseline; gap: 8px; flex: 0 0 auto; padding: 6px 10px 3px; min-height: 27px; }
.rc-caption-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--rc-muted); font-weight: 500; }
.rc-sample { margin-left: auto; flex-shrink: 0; font-size: 10px; letter-spacing: .025em; color: var(--rc-muted); opacity: .8; }
.rc-plot-wrap { flex: 1 1 auto; position: relative; min-height: 0; min-width: 0; }
.rc-plot { width: 100%; height: 100%; min-height: 0; position: relative; }
.rc-plot canvas { max-width: none; }
.rc-notes { display: none; flex: 0 0 auto; padding: 3px 10px 5px; color: var(--rc-muted); font-size: 10px; line-height: 1.4; max-height: 34px; overflow: auto; }
.rc-has-notes .rc-notes { display: block; }
.rc-notes.rc-has-warning { color: var(--rc-text); border-top: 1px solid var(--rc-border); }
.rc-tools { position: absolute; z-index: 3; top: 2px; right: 8px; display: flex; border: 1px solid var(--rc-border); border-radius: 3px; overflow: hidden; background: var(--rc-surface); }
.rc-tools button { color: var(--rc-muted); font: inherit; font-size: 11px; min-width: 28px; height: 26px; padding: 0 8px; border: 0; border-right: 1px solid var(--rc-border); background: transparent; cursor: pointer; }
.rc-tools button:last-child { border-right: 0; }
.rc-tools button:hover, .rc-error button:hover { color: var(--rc-text); background: var(--rc-elevated); }
.rc-tools button:focus-visible, .rc-error button:focus-visible { outline: 2px solid var(--ac-focus, #1fa8c9); outline-offset: -2px; }
.rc-loading, .rc-error { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 10px; padding: 16px; color: var(--rc-muted); }
.rc-loading::before { content: ''; width: 20px; height: 20px; border: 2px solid var(--rc-border); border-top-color: var(--rc-muted); border-radius: 50%; animation: rc-spin 1s linear infinite; }
.rc-error strong { color: var(--rc-text); font-weight: 500; }
.rc-error span { max-width: 54ch; font-size: 12px; }
.rc-error button { color: var(--rc-text); background: var(--rc-surface); border: 1px solid var(--rc-border); border-radius: 3px; padding: 5px 12px; cursor: pointer; }
.rc-tooltip-title { font-weight: 500; margin-bottom: 7px; max-width: 40ch; white-space: normal; overflow-wrap: anywhere; }
.rc-tooltip-row { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; padding: 2px 0; }
.rc-tooltip-row span { max-width: 26ch; white-space: normal; }
.rc-tooltip-row strong { font-weight: 500; white-space: nowrap; }
.rc-tooltip-note { max-width: 36ch; margin-top: 7px; opacity: .74; white-space: normal; font-size: 11px; line-height: 1.4; }
/* Gallery labels are intentionally tiny, matching the detailed Preset previews. */
.rc-small { font-size: 8px; }
.rc-small .rc-caption { min-height: 17px; gap: 4px; padding: 3px 5px 1px; }
.rc-small .rc-sample { font-size: 7px; }
.rc-small .rc-notes { padding: 1px 5px 3px; font-size: 7px; max-height: 20px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.rc-small .rc-error { gap: 5px; padding: 8px; }
.rc-small .rc-error span { font-size: 8px; }
.rc-small .rc-error button { font-size: 9px; padding: 3px 7px; }
@keyframes rc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .rc-loading::before { animation: none; } }
@media (pointer: coarse) { .rc-tools button { height: 40px; min-width: 40px; } }
