/* ═══════════════════════════════════════════════════════════════════════════
   COMPOSE — Sidebar v6
   Cohesive design system across all panels.
   Consistent 16px edge padding. CSS variables throughout. No shadows.
   Material 3 + Tolstoy website design language.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Design constants ────────────────────────────────────────────────── */
:root {
  --sp-pad: 16px;
  --sp-item-h: 36px;
  --sp-item-r: 8px;
  --sp-section-gap: 20px;
}

/* ── Sidebar shell ───────────────────────────────────────────────────── */
#sidebar {
  display: flex;
  flex-direction: column;
  background: var(--sidebar-bg);
  position: relative;
  overflow: hidden;
}

/* ── Panel stack ─────────────────────────────────────────────────────── */
.sp {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: var(--sidebar-bg);
  opacity: 0;
  pointer-events: none;
  transform: translateX(8px);
  transition: opacity var(--t) var(--ease), transform var(--t) var(--ease);
}
.sp.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

/* ── Panel header ────────────────────────────────────────────────────── */
.sp-header {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  padding: 0 var(--sp-pad);
  height: var(--topbar-h);
  background: var(--bg-chrome);
  border-bottom: 1px solid var(--sidebar-border);
  gap: 8px;
}

.sp-title {
  flex: 1;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.015em;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-close {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: var(--sp-item-r);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.sp-close svg { width: 13px; height: 13px; }
.sp-close:hover { background: var(--fill-muted); color: var(--text); }

/* ── Panel body ──────────────────────────────────────────────────────── */
.sp-body {
  flex: 1 1 0;
  overflow-y: auto;
  overflow-x: hidden;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.sp-body::-webkit-scrollbar { width: 4px; }
.sp-body::-webkit-scrollbar-track { background: transparent; }
.sp-body::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 99px; }
.sp-body::-webkit-scrollbar-thumb:hover { background: var(--text-disabled); }

/* ── Section wrapper ─────────────────────────────────────────────────── */
.sp-section {
  padding: var(--sp-section-gap) var(--sp-pad) 0;
}
.sp-section + .sp-section { padding-top: var(--sp-section-gap); }
.sp-section:last-child { padding-bottom: var(--sp-section-gap); }

/* ── Eyebrow label ───────────────────────────────────────────────────── */
.sp-eyebrow {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.sp-eyebrow::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── Divider ─────────────────────────────────────────────────────────── */
.sp-divider {
  height: 1px;
  background: var(--border);
  margin: var(--sp-pad) 0;
}

/* ── Empty state ─────────────────────────────────────────────────────── */
.sp-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 36px var(--sp-pad);
  text-align: center;
  gap: 8px;
}
.sp-empty-icon {
  width: 36px; height: 36px;
  background: var(--fill-muted);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.sp-empty-icon svg { width: 18px; height: 18px; color: var(--text-muted); }
.sp-empty-title { font-size: 13px; font-weight: 600; color: var(--text-sec); }
.sp-empty-sub { font-size: 12px; color: var(--text-muted); line-height: 1.6; max-width: 180px; }


/* ═══════════════════════════════════════════════════════════════════════
   PANEL 1 — FILES
   ═══════════════════════════════════════════════════════════════════════ */

.files-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: var(--sp-pad);
  border-bottom: 1px solid var(--sidebar-border);
}

.files-new-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: var(--sp-item-h);
  border-radius: var(--sp-item-r);
  background: var(--accent);
  color: var(--text-on-accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: background var(--t-fast) var(--ease);
}
.files-new-btn svg { width: 14px; height: 14px; flex-shrink: 0; }
.files-new-btn:hover { background: #2645d4; }

.files-row { display: flex; gap: 6px; }

.files-sec-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 32px;
  border-radius: var(--sp-item-r);
  background: var(--fill-muted);
  color: var(--text-sec);
  font-size: 12px;
  font-weight: 500;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  white-space: nowrap;
}
.files-sec-btn svg { width: 13px; height: 13px; color: var(--text-muted); flex-shrink: 0; }
.files-sec-btn:hover { background: var(--fill-active); color: var(--text); }

.files-save-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 var(--sp-pad);
  border-radius: var(--sp-item-r);
  background: var(--fill-muted);
  color: var(--text-sec);
  font-size: 12px;
  font-weight: 500;
  width: 100%;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.files-save-btn svg { width: 13px; height: 13px; color: var(--text-muted); }
.files-save-btn:hover { background: var(--fill-active); color: var(--text); }

.files-export-wrap { position: relative; }
.files-export-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0; right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  z-index: 50;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  transition: opacity var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.files-export-dropdown.is-open { opacity: 1; transform: none; pointer-events: auto; }
.files-export-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px var(--sp-pad);
  font-size: 13px;
  color: var(--text-sec);
  text-align: left;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.files-export-item svg { width: 14px; height: 14px; color: var(--text-muted); flex-shrink: 0; }
.files-export-item:hover { background: var(--fill-hover); color: var(--text); }
.files-export-item + .files-export-item { border-top: 1px solid var(--border); }

.files-doc-list { padding: 8px 0; }

.doc-item {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 10px;
  border-radius: 0;
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
  position: relative;
  width: 100%;
}
.doc-item:hover { background: var(--fill-hover); }
.doc-item.is-active { background: var(--fill-selected); }

.doc-icon {
  width: 28px; height: 28px;
  border-radius: 7px;
  background: var(--fill-muted);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: background var(--t-fast) var(--ease);
}
.doc-item.is-active .doc-icon { background: rgba(var(--accent-rgb), .14); }
.doc-icon svg { width: 14px; height: 14px; color: var(--text-muted); }
.doc-item.is-active .doc-icon svg { color: var(--accent); }

.doc-meta { flex: 1; min-width: 0; }
.doc-name {
  font-size: 13px;
  font-weight: 400;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.4;
}
.doc-item.is-active .doc-name { color: var(--accent); font-weight: 500; }

.doc-dirty {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--status-dirty);
  flex-shrink: 0;
}

.doc-close, .doc-rename-btn, .doc-save-btn {
  width: 24px; height: 24px;
  border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  flex-shrink: 0;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.doc-close svg { width: 13px; height: 13px; }
.doc-rename-btn svg { width: 13px; height: 13px; }
.doc-save-btn svg { width: 13px; height: 13px; }
.doc-close:hover, .doc-rename-btn:hover, .doc-save-btn:hover { background: var(--fill-active); color: var(--text); }

.doc-rename-input {
  flex: 1;
  font-size: 13px;
  color: var(--text);
  background: var(--bg-card);
  border: 1.5px solid var(--accent);
  border-radius: 5px;
  outline: none;
  padding: 2px 6px;
  min-width: 0;
  font-family: inherit;
}


/* ═══════════════════════════════════════════════════════════════════════
   PANEL 2 — OUTLINE
   ═══════════════════════════════════════════════════════════════════════ */

.outline-list { padding: 8px 0; }

.outline-entry {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px var(--sp-pad);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
  min-height: 30px;
}
.outline-entry:hover { background: var(--fill-hover); }
.outline-entry[data-level="1"] { padding-left: var(--sp-pad); }
.outline-entry[data-level="2"] { padding-left: calc(var(--sp-pad) + 14px); }
.outline-entry[data-level="3"] { padding-left: calc(var(--sp-pad) + 28px); }
.outline-entry[data-level="4"] { padding-left: calc(var(--sp-pad) + 40px); }
.outline-entry[data-level="5"],
.outline-entry[data-level="6"] { padding-left: calc(var(--sp-pad) + 52px); }

.outline-pip {
  width: 4px; height: 4px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--border-strong);
}
.outline-entry[data-level="1"] .outline-pip { background: var(--accent); width: 5px; height: 5px; }
.outline-entry[data-level="2"] .outline-pip { background: var(--text-disabled); }
.outline-entry[data-level="3"] .outline-pip { background: var(--border-strong); }

/* All levels use the same base text style — no visual hierarchy shock */
.outline-text {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 13px;
  font-weight: 400;
  color: var(--text-sec);
  line-height: 1.4;
}
/* H1 only gets a subtle weight bump, not a size change */
.outline-entry[data-level="1"] .outline-text { font-weight: 500; color: var(--text); }
.outline-entry[data-level="3"] .outline-text { color: var(--text-muted); }
.outline-entry[data-level="4"] .outline-text,
.outline-entry[data-level="5"] .outline-text,
.outline-entry[data-level="6"] .outline-text { font-size: 12px; color: var(--text-muted); }


/* ═══════════════════════════════════════════════════════════════════════
   PANEL 3 — FIND & REPLACE
   ═══════════════════════════════════════════════════════════════════════ */

.find-zone {
  padding: 14px var(--sp-pad) 12px;
  border-bottom: 1px solid var(--sidebar-border);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Labelled input group */
.find-input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.find-input-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.find-field-wrap {
  position: relative;
}

.find-field-icon {
  position: absolute;
  left: 10px; top: 50%;
  transform: translateY(-50%);
  width: 13px; height: 13px;
  color: var(--text-muted);
  pointer-events: none;
}

.find-field {
  width: 100%;
  height: var(--sp-item-h);
  padding: 0 32px 0 32px;
  border-radius: var(--sp-item-r);
  font-size: 13px;
  font-family: var(--font-ui);
  color: var(--text);
  background: var(--bg-card);
  border: 1.5px solid var(--border-strong);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  transition: border-color var(--t-fast) var(--ease);
}
.find-field:focus { border-color: var(--accent); }
.find-field::-webkit-search-cancel-button { display: none; }
.find-field::placeholder { color: var(--text-muted); }

.find-field-clear {
  position: absolute;
  right: 8px; top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 18px;
  border-radius: 50%;
  background: var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-sec);
  transition: background var(--t-fast) var(--ease);
}
.find-field-clear svg { width: 8px; height: 8px; }
.find-field-clear:hover { background: var(--text-disabled); }

/* Options row — inline with count badge */
.find-options-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.find-count-wrap { margin-left: auto; }

/* Checkbox variant */
.find-opt-check {
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  user-select: none;
}
.find-opt-check input[type="checkbox"] {
  position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none;
}
.find-opt-check-box {
  width: 14px; height: 14px;
  border-radius: 3px;
  border: 1.5px solid var(--border-strong);
  background: var(--bg-card);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  transition: background var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
  position: relative;
}
.find-opt-check-box::after {
  content: '';
  display: block;
  width: 7px; height: 4px;
  border-left: 1.5px solid #fff;
  border-bottom: 1.5px solid #fff;
  transform: rotate(-45deg) translate(1px, -1px);
  opacity: 0;
  transition: opacity var(--t-fast) var(--ease);
}
.find-opt-check input:checked ~ .find-opt-check-box { background: var(--accent); border-color: var(--accent); }
.find-opt-check input:checked ~ .find-opt-check-box::after { opacity: 1; }
.find-opt-check:hover .find-opt-check-box { border-color: var(--accent); }
.find-opt-check-label { font-size: 11.5px; color: var(--text-sec); }
.find-opt-check input:checked ~ .find-opt-check-label { color: var(--text); }

/* Nav row — full-width pair of buttons */
.find-nav-row {
  display: flex;
  gap: 6px;
}

.find-nav-btn {
  flex: 1;
  height: 32px;
  border-radius: var(--sp-item-r);
  display: flex; align-items: center; justify-content: center;
  gap: 5px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-sec);
  background: var(--fill-muted);
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  white-space: nowrap;
}
.find-nav-btn svg { width: 11px; height: 11px; flex-shrink: 0; }
.find-nav-btn:hover { background: var(--fill-active); color: var(--text); }
.find-nav-btn:disabled { opacity: 0.35; cursor: default; }

.find-nav-btn--primary {
  background: rgba(var(--accent-rgb), .1);
  color: var(--accent);
}
.find-nav-btn--primary:hover { background: rgba(var(--accent-rgb), .18); color: var(--accent); }

/* Divider between find and replace */
.find-divider {
  height: 1px;
  background: var(--border);
  margin: 2px 0;
}

.find-replace-field {
  width: 100%;
  height: var(--sp-item-h);
  padding: 0 10px;
  border-radius: var(--sp-item-r);
  font-size: 13px;
  font-family: var(--font-ui);
  color: var(--text);
  background: var(--bg-card);
  border: 1.5px solid var(--border-strong);
  outline: none;
  transition: border-color var(--t-fast) var(--ease);
}
.find-replace-field:focus { border-color: var(--accent); }
.find-replace-field::placeholder { color: var(--text-muted); }

.find-count-badge {
  display: inline-flex;
  align-items: center;
  height: 18px;
  padding: 0 7px;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 600;
  background: var(--fill-selected);
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.find-count-badge:empty { display: none; }

.find-results { flex: 1; overflow-y: auto; padding: 8px; }

.find-result-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 7px 10px;
  border-radius: var(--sp-item-r);
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: background var(--t-fast) var(--ease);
  border: 1.5px solid transparent;
}
.find-result-item:hover { background: var(--fill-hover); }
.find-result-item.is-active { background: var(--fill-selected); border-color: rgba(var(--accent-rgb), .2); }

.find-result-n {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  min-width: 18px;
  padding-top: 1px;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.find-result-item.is-active .find-result-n { color: var(--accent); }

.find-result-ctx {
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--text-sec);
  word-break: break-word;
  flex: 1;
}
.find-result-before, .find-result-after { color: var(--text-muted); }
.find-result-match {
  font-weight: 600;
  color: var(--text);
  background: var(--fill-selected);
  border-radius: 3px;
  padding: 0 2px;
}
.find-result-item.is-active .find-result-match { background: rgba(var(--accent-rgb), .2); color: var(--accent); }

.find-no-results {
  padding: 28px var(--sp-pad);
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}


/* ═══════════════════════════════════════════════════════════════════════
   PANEL 4 — APPEARANCE
   ═══════════════════════════════════════════════════════════════════════ */

.appear-section {
  padding: var(--sp-section-gap) var(--sp-pad) 0;
}
.appear-section:last-child { padding-bottom: var(--sp-section-gap); }

.appear-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: block;
}

.appear-seg {
  display: flex;
  background: var(--fill-muted);
  border-radius: var(--r-md);
  padding: 3px;
  gap: 2px;
}

/* Wrapping variant for citation styles (6 buttons) */
.appear-seg--wrap {
  flex-wrap: wrap;
  background: transparent;
  padding: 0;
  gap: 4px;
}
.appear-seg--wrap .appear-seg-btn {
  flex: 0 0 auto;
  background: var(--fill-muted);
  border-radius: var(--r-md);
}
.appear-seg--wrap .appear-seg-btn.is-active {
  background: var(--fill-selected);
  border: 1px solid rgba(var(--accent-rgb), .3);
  color: var(--accent);
}

.appear-seg-btn {
  flex: 1;
  height: 28px;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  cursor: pointer;
}
.appear-seg-btn svg { width: 12px; height: 12px; flex-shrink: 0; }
.appear-seg-btn:hover { color: var(--text-sec); }
.appear-seg-btn.is-active {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}

/* Canvas swatch inside the canvas background picker */
.appear-seg-btn--canvas {
  gap: 6px;
  font-size: 11.5px;
}
.canvas-swatch {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  background: var(--canvas-swatch, #fff);
  border: 1px solid rgba(0,0,0,.12);
  flex-shrink: 0;
  display: inline-block;
}

.appear-chips { display: flex; gap: 4px; flex-wrap: wrap; }

.appear-chip {
  height: 28px;
  padding: 0 12px;
  border-radius: var(--sp-item-r);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-sec);
  background: var(--fill-muted);
  border: 1.5px solid transparent;
  transition: all var(--t-fast) var(--ease);
  cursor: pointer;
  white-space: nowrap;
}
.appear-chip:hover { background: var(--fill-active); color: var(--text); }
.appear-chip.is-active {
  background: var(--fill-selected);
  border-color: rgba(var(--accent-rgb), .3);
  color: var(--accent);
  font-weight: 600;
}

.appear-fonts { display: flex; flex-direction: column; gap: 2px; }

.appear-font-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--sp-item-h);
  padding: 0 12px;
  border-radius: var(--sp-item-r);
  font-size: 14px;
  color: var(--text-sec);
  background: transparent;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: all var(--t-fast) var(--ease);
  text-align: left;
  width: 100%;
}
.appear-font-btn:hover { background: var(--fill-hover); }
.appear-font-btn.is-active {
  background: var(--fill-selected);
  border-color: rgba(var(--accent-rgb), .2);
  color: var(--accent);
}
.appear-font-type {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-family: var(--font-ui) !important;
  margin-left: 8px;
  flex-shrink: 0;
}
.appear-font-btn.is-active .appear-font-type { color: rgba(var(--accent-rgb), .6); }

.appear-font-sep { height: 1px; background: var(--border); margin: 6px 0; }

.appear-select-wrap {
  position: relative;
  display: block;
}

.appear-select {
  width: 100%;
  height: var(--sp-item-h);
  padding: 0 32px 0 12px;
  border-radius: var(--sp-item-r);
  border: 1.5px solid var(--border-strong);
  background: var(--bg-card);
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  transition: border-color var(--t-fast) var(--ease);
  outline: none;
  display: block;
}
.appear-select:hover { border-color: var(--border-strong); }
.appear-select:focus { border-color: var(--accent); }

.appear-select-arrow {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  width: 10px; height: 6px;
  color: var(--text-muted);
  pointer-events: none;
}

.appear-slider-row { display: flex; align-items: center; gap: 12px; }

.appear-slider {
  -webkit-appearance: none;
  appearance: none;
  flex: 1;
  height: 4px;
  border-radius: 99px;
  background: var(--border-strong);
  outline: none;
  cursor: pointer;
}
.appear-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: 2px solid var(--bg-card);
  transition: transform var(--t-fast) var(--ease);
}
.appear-slider::-webkit-slider-thumb:hover { transform: scale(1.15); }
.appear-slider::-moz-range-thumb {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg-card);
  cursor: pointer;
}
.appear-slider-val {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-sec);
  font-variant-numeric: tabular-nums;
  min-width: 36px;
  text-align: right;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════════════════
   PANEL 5 — SUPPORT
   ═══════════════════════════════════════════════════════════════════════ */

.support-avatar-row {
  display: flex;
  justify-content: flex-start;
  padding: 20px var(--sp-pad) 0;
}

.support-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
  background: var(--fill-muted);
}

.support-intro-headline {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.4;
  padding: var(--sp-pad) var(--sp-pad) 0;
  margin: 0;
}

.support-intro-body {
  font-size: 12.5px;
  color: var(--text-sec);
  line-height: 1.65;
  padding: 6px var(--sp-pad) var(--sp-pad);
  margin: 0;
}

.support-contrib-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 0 var(--sp-pad) 10px;
}

.support-panel-wrap {
  margin: 0 var(--sp-pad) var(--sp-pad);
  border: 1.5px solid var(--sidebar-border);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--bg-card);
}

.sp-d-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 var(--sp-pad);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  height: 60px;
  background: transparent;
  transition: background var(--t) var(--ease);
}
.sp-d-row:last-child { border-bottom: none; }
.sp-d-row:hover { background: var(--fill-selected); }
.sp-d-row--featured { background: rgba(var(--accent-rgb), .07); }
.sp-d-row--featured:hover { background: rgba(var(--accent-rgb), .12); }

.sp-d-price {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  flex-shrink: 0;
  min-width: 44px;
  color: var(--text);
}
.sp-d-row--featured .sp-d-price { color: var(--accent); }

.sp-d-body { flex: 1; min-width: 0; }

.sp-d-give {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
  color: var(--text-muted);
  transition: color var(--t) var(--ease);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sp-d-row:hover .sp-d-give { color: var(--accent); }
.sp-d-row--featured .sp-d-give { color: var(--accent); opacity: 0.7; }
.sp-d-row--featured:hover .sp-d-give { opacity: 1; }

.sp-d-arrow {
  flex-shrink: 0;
  color: var(--border-strong);
  transition: color var(--t) var(--ease), transform var(--t) var(--ease);
}
.sp-d-arrow svg { width: 14px; height: 14px; display: block; }
.sp-d-row:hover .sp-d-arrow { color: var(--accent); transform: translateX(3px); }
.sp-d-row--featured .sp-d-arrow { color: var(--accent); opacity: 0.4; }
.sp-d-row--featured:hover .sp-d-arrow { opacity: 1; }

.sp-d-icon {
  flex-shrink: 0;
  min-width: 44px;
  display: flex;
  align-items: center;
  color: var(--text-muted);
}
.sp-d-icon svg { width: 14px; height: 14px; }

.support-shortcuts-link {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 var(--sp-pad) var(--sp-pad);
  padding: 10px 14px;
  border-radius: var(--r-md);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-sec);
  background: var(--fill-muted);
  cursor: pointer;
  border: 1.5px solid var(--border);
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.support-shortcuts-link svg { width: 15px; height: 15px; color: var(--text-muted); flex-shrink: 0; }
.support-shortcuts-link:hover { background: var(--fill-active); color: var(--text); border-color: var(--border-strong); }

.support-note {
  padding: 0 var(--sp-pad) var(--sp-section-gap);
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.6;
  text-align: left;
}
.support-note a { color: var(--accent); text-decoration: none; }

/* ── support-shortcuts-link hidden since it's in sidebar panel ─────── */
