/* ============================================================
   CMS CROWD Operações — módulo Clientes > Projetos > Tarefas > Horas
   Complementa styles.css (mesmas variáveis de tema).
   ============================================================ */

:root {
  --st-a_fazer: #6b7280;
  --st-fazendo: #4f8cff;
  --st-revisao: #f5b13d;
  --st-concluida: #59c977;
  --prio-urgente: #ff3d6e;
}

/* ---------- Navegação entre módulos ---------- */
.nav-tabs { display: flex; gap: 4px; }
.nav-tab {
  color: var(--text-dim); text-decoration: none; font-size: 13px; font-weight: 600;
  padding: 7px 12px; border-radius: var(--radius-sm); border: 1px solid transparent;
}
.nav-tab:hover { color: var(--text); background: var(--surface); }
.nav-tab.active { color: var(--brand-ink); background: var(--brand); border-color: var(--brand); }

.btn-sm { padding: 7px 10px !important; font-size: 12.5px !important; }

/* ---------- Layout de 3 colunas ---------- */
.ops-layout {
  display: grid;
  grid-template-columns: 250px 290px minmax(0, 1fr);
  flex: 1; min-height: 0; overflow: hidden;
}
.pane { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--border); background: var(--bg); }
.pane-tasks { border-right: none; background: var(--bg-elevated); }
.pane-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 14px 14px 10px; flex-shrink: 0;
}
.pane-head h2 { margin: 0; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-dim); }
.pane-sub { display: block; font-size: 12px; color: var(--text-faint); margin-top: 2px; }
.pane-search { padding: 0 14px 10px; flex-shrink: 0; }
.pane-search input {
  width: 100%; background: var(--surface); border: 1px solid var(--border); color: var(--text);
  padding: 7px 10px; border-radius: var(--radius-sm); font-size: 13px;
}
.pane-body { flex: 1; overflow-y: auto; padding: 0 8px 20px; }

/* ---------- Itens de cliente / projeto ---------- */
.list-item {
  display: block; width: 100%; text-align: left; cursor: pointer;
  background: transparent; border: 1px solid transparent; color: var(--text);
  padding: 9px 10px; border-radius: var(--radius-sm); margin-bottom: 2px; font: inherit;
}
.list-item:hover { background: var(--surface); }
.list-item.selected { background: var(--surface-2); border-color: var(--border-strong); }
.list-item-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.list-item-name { font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-item-meta { display: flex; align-items: center; gap: 8px; margin-top: 3px; font-size: 11.5px; color: var(--text-faint); }
.list-item.archived .list-item-name { color: var(--text-faint); text-decoration: line-through; }

.hours-badge {
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-dim);
  padding: 2px 7px; border-radius: 20px; font-size: 11px; font-weight: 700; white-space: nowrap;
}
.hours-badge.has-time { color: var(--brand); border-color: rgba(255, 210, 0, 0.35); }

.pane-empty { padding: 18px 12px; color: var(--text-faint); font-size: 12.5px; line-height: 1.5; }

/* ---------- Cabeçalho de tarefas ---------- */
.tasks-head { align-items: flex-start; padding: 14px 18px 12px; border-bottom: 1px solid var(--border); }
.tasks-title h2 { font-size: 15px; text-transform: none; letter-spacing: 0; color: var(--text); }
.tasks-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tasks-actions select {
  background: var(--surface); border: 1px solid var(--border); color: var(--text);
  padding: 7px 8px; border-radius: var(--radius-sm); font-size: 12.5px;
}
.tasks-body { padding: 10px 14px 60px; }

/* ---------- Linha de tarefa ---------- */
.task-row {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 9px 12px; margin-bottom: 6px;
}
.task-row:hover { border-color: var(--border-strong); }
.task-row.done .task-title { color: var(--text-faint); text-decoration: line-through; }

.status-dot {
  width: 11px; height: 11px; border-radius: 50%; flex-shrink: 0; border: none; padding: 0; cursor: pointer;
  background: var(--st-a_fazer);
}
.status-dot.fazendo { background: var(--st-fazendo); }
.status-dot.revisao { background: var(--st-revisao); }
.status-dot.concluida { background: var(--st-concluida); }

.task-main { flex: 1; min-width: 0; cursor: pointer; }
.task-title { font-size: 13.5px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-meta { display: flex; align-items: center; gap: 8px; margin-top: 3px; font-size: 11.5px; color: var(--text-faint); }
.task-meta .overdue { color: var(--prio-alta); font-weight: 700; }

.assignee-chip {
  display: inline-flex; align-items: center; gap: 6px; background: var(--surface-2);
  border: 1px solid var(--border); border-radius: 20px; padding: 3px 9px 3px 3px; font-size: 11.5px; color: var(--text-dim);
  max-width: 170px; white-space: nowrap; overflow: hidden;
}
.assignee-chip .avatar-xs {
  width: 18px; height: 18px; border-radius: 50%; background: var(--brand); color: var(--brand-ink);
  display: inline-flex; align-items: center; justify-content: center; font-size: 9.5px; font-weight: 800; flex-shrink: 0;
}
.assignee-chip.unassigned .avatar-xs { background: var(--surface); color: var(--text-faint); border: 1px dashed var(--border-strong); }

/* Apontamento inline */
.task-time { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.task-time .time-input {
  width: 62px; background: var(--bg); border: 1px solid var(--border); color: var(--text);
  padding: 5px 7px; border-radius: 6px; font-size: 12px; text-align: center;
}
.task-time .time-input::placeholder { color: var(--text-faint); }
.timer-btn {
  width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--border-strong);
  background: var(--surface-2); color: var(--text-dim); cursor: pointer; font-size: 11px; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.timer-btn:hover { color: var(--brand); border-color: var(--brand); }
.timer-btn.running { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.timer-btn[disabled] { opacity: 0.3; cursor: not-allowed; }

/* ---------- Cronômetro na topbar ---------- */
.timer-widget {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); border: 1px solid var(--brand); border-radius: var(--radius-sm); padding: 5px 8px 5px 12px;
}
.timer-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.25; } }
.timer-info { display: flex; flex-direction: column; line-height: 1.2; }
.timer-info strong { font-size: 13px; font-variant-numeric: tabular-nums; }
.timer-info span { font-size: 11px; color: var(--text-dim); max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Drawer ---------- */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.55); display: flex; justify-content: flex-end; z-index: 60; }
.drawer {
  width: min(560px, 100%); height: 100%; background: var(--bg-elevated); border-left: 1px solid var(--border);
  display: flex; flex-direction: column; box-shadow: var(--shadow);
}
.drawer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 18px 20px 14px; border-bottom: 1px solid var(--border); }
.drawer-head h2 { margin: 4px 0 0; font-size: 17px; }
.drawer-breadcrumb { font-size: 11.5px; color: var(--text-faint); }
.drawer-body { flex: 1; overflow-y: auto; padding: 18px 20px; }
.drawer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 4px; }
.drawer-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 20px; border-top: 1px solid var(--border); }

.drawer-section { margin-top: 20px; border-top: 1px solid var(--border); padding-top: 16px; }
.drawer-section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.drawer-section-head h3 { margin: 0; font-size: 12px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); }
.time-total { font-size: 18px; color: var(--brand); font-variant-numeric: tabular-nums; }

.time-form {
  display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px;
  padding: 12px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.time-form-row { display: grid; grid-template-columns: 96px 150px 1fr; gap: 8px; }
.tf-field { display: flex; flex-direction: column; gap: 4px; min-width: 0; position: relative; }
.tf-field > span { font-size: 11px; color: var(--text-dim); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.tf-note textarea {
  width: 100%; resize: vertical; min-height: 70px; line-height: 1.45; font-family: inherit;
  background: var(--bg); border: 1px solid var(--border); color: var(--text); padding: 9px 11px; border-radius: var(--radius-sm); font-size: 13px;
}
.tf-note textarea:focus, .time-form input:focus, .time-form select:focus { outline: none; border-color: var(--brand); }
.tf-count { position: absolute; right: 8px; bottom: 6px; font-size: 10.5px; color: var(--text-faint); pointer-events: none; }
.time-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tf-hint { font-size: 11px; color: var(--text-faint); }
.time-form input, .time-form select {
  background: var(--bg); border: 1px solid var(--border); color: var(--text);
  padding: 8px 10px; border-radius: var(--radius-sm); font-size: 13px; min-width: 0;
}

.time-entries { display: flex; flex-direction: column; gap: 4px; }
.time-entry {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 12.5px;
}
.time-entry .te-date { color: var(--text-dim); font-variant-numeric: tabular-nums; flex-shrink: 0; }
.time-entry .te-min { font-weight: 700; color: var(--brand); font-variant-numeric: tabular-nums; flex-shrink: 0; min-width: 52px; }
.time-entry .te-who { color: var(--text-dim); flex-shrink: 0; }
.time-entry .te-note { flex: 1; min-width: 0; color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.time-entry .te-del { background: none; border: none; color: var(--text-faint); cursor: pointer; font-size: 15px; line-height: 1; }
.time-entry .te-del:hover { color: var(--prio-alta); }

/* ---------- Membros / usuários no modal ---------- */
.member-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; max-height: 190px; overflow-y: auto; padding: 4px 2px; }
.member-check { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 5px 7px; border-radius: 6px; background: var(--surface); }
.role-pill { font-size: 10px; text-transform: uppercase; letter-spacing: 0.05em; padding: 2px 6px; border-radius: 20px; background: var(--surface-2); color: var(--text-dim); border: 1px solid var(--border); }
.role-pill.admin { color: var(--brand); border-color: rgba(255, 210, 0, 0.35); }
.role-pill.manager { color: var(--nova); border-color: rgba(79, 140, 255, 0.35); }

.item-actions { display: flex; gap: 4px; }
.mini-btn { background: none; border: none; color: var(--text-faint); cursor: pointer; font-size: 12px; padding: 2px 4px; border-radius: 4px; }
.mini-btn:hover { color: var(--text); background: var(--surface-2); }

@media (max-width: 1000px) {
  .ops-layout { grid-template-columns: 1fr; grid-template-rows: auto auto 1fr; }
  .pane-clients, .pane-projects { max-height: 190px; border-right: none; border-bottom: 1px solid var(--border); }
}

/* ---------- Visibilidade por perfil ---------- */
body:not(.can-manage) .manage-only { display: none !important; }

/* ---------- Rodapé do modal genérico ---------- */
#modal-foot { padding: 0 18px 18px; }
#modal-foot .link-danger { margin-right: auto; }

/* ---------- Fotos de perfil ---------- */
img.avatar-xs, img.avatar-sm { object-fit: cover; display: block; background: var(--surface-2); }
.avatar-sm {
  width: 24px; height: 24px; border-radius: 50%; flex-shrink: 0;
  background: var(--surface-2); color: var(--text-dim);
  display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 800;
}
.avatar-btn { background: none; border: none; padding: 0; cursor: pointer; border-radius: 50%; line-height: 0; }
.avatar-btn:hover { outline: 2px solid var(--brand); outline-offset: 1px; }

.user-badge { overflow: hidden; padding: 0; }
.user-badge img { width: 100%; height: 100%; object-fit: cover; display: block; }
.user-badge.clickable { cursor: pointer; }
.user-badge.clickable:hover { outline: 2px solid var(--brand); outline-offset: 1px; }

.time-entry .te-who { display: inline-flex; align-items: center; gap: 6px; }
.member-check .member-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.photo-box { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.photo-preview {
  width: 116px; height: 116px; border-radius: 50%; overflow: hidden;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  font-size: 34px; font-weight: 800; color: var(--text-dim);
}
.photo-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Input de arquivo real: fica no DOM (invisível) para o label conseguir abrir o seletor. */
.photo-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.photo-preview { cursor: pointer; transition: border-color .15s, transform .1s; }
.photo-preview:hover { border-color: var(--brand); }
.photo-preview.dragging { border-color: var(--brand); border-style: dashed; transform: scale(1.03); }
.no-email { color: var(--prio-alta); font-size: 11.5px; }

/* ---------- Painel de usuários ---------- */
.modal.wide { max-width: 680px; }
.user-rows { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.user-row-ops {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.uo-info { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.uo-info strong { font-size: 13px; }
.uo-mail { font-size: 11.5px; color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-row-ops select {
  background: var(--bg); border: 1px solid var(--border); color: var(--text);
  padding: 5px 7px; border-radius: 6px; font-size: 12px;
}
.uo-actions { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }


/* ---------- Link discreto (login) ---------- */
.link-btn {
  display: block; margin: 12px auto 0; background: none; border: none; color: var(--text-dim);
  font-size: 12.5px; cursor: pointer; padding: 4px 8px; border-radius: 6px;
}
.link-btn:hover { color: var(--brand); background: rgba(255, 210, 0, 0.08); }

/* ---------- Hover dos botões pequenos: amarelo = clicável ---------- */
.mini-btn { transition: color .12s, background .12s; }
.mini-btn:hover:not(:disabled) { color: var(--brand); background: rgba(255, 210, 0, 0.12); }
.mini-btn:disabled { opacity: .35; cursor: not-allowed; }
.list-item:hover .mini-btn { color: var(--text-dim); }
.list-item .mini-btn:hover { color: var(--brand); }
.te-del:hover { background: rgba(255, 90, 90, .12); border-radius: 4px; }
.status-dot:hover { box-shadow: 0 0 0 3px rgba(255, 210, 0, .35); }
.hours-badge { transition: none; }

/* ---------- Pílulas de status ---------- */
.st-pill {
  display: inline-flex; align-items: center; gap: 4px; font-size: 10.5px; font-weight: 700;
  padding: 1px 7px; border-radius: 20px; border: 1px solid transparent; white-space: nowrap; line-height: 1.5;
}
.st-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
/* Cliente e projeto: verde, amarelo, vermelho */
.st-proj-ativo     { color: #59c977; background: rgba(89, 201, 119, .12); border-color: rgba(89, 201, 119, .3); }
.st-proj-pausado   { color: #f5b13d; background: rgba(245, 177, 61, .12); border-color: rgba(245, 177, 61, .3); }
.st-proj-concluido { color: #ff6b6b; background: rgba(255, 107, 107, .12); border-color: rgba(255, 107, 107, .3); }
/* Tarefa: cinza, azul, âmbar, verde */
.st-task-a_fazer   { color: #9aa3b2; background: rgba(154, 163, 178, .12); border-color: rgba(154, 163, 178, .28); }
.st-task-fazendo   { color: #6ea0ff; background: rgba(79, 140, 255, .14); border-color: rgba(79, 140, 255, .32); }
.st-task-revisao   { color: #f5b13d; background: rgba(245, 177, 61, .12); border-color: rgba(245, 177, 61, .3); }
.st-task-concluida { color: #59c977; background: rgba(89, 201, 119, .12); border-color: rgba(89, 201, 119, .3); }
.list-item-meta .st-pill { font-size: 10px; }

/* ---------- Acordeão: Concluídos / Arquivados ---------- */
.acc { margin-top: 10px; border-top: 1px solid var(--border); padding-top: 6px; }
.acc-head {
  display: flex; align-items: center; gap: 6px; width: 100%; background: none; border: none; cursor: pointer;
  color: var(--text-dim); font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  padding: 6px 8px; border-radius: 6px; text-align: left;
}
.acc-head:hover { color: var(--brand); background: rgba(255, 210, 0, .06); }
.acc-arrow { display: inline-block; transition: transform .15s; font-size: 10px; }
.acc.open .acc-arrow { transform: rotate(90deg); }
.acc-count { margin-left: auto; background: var(--surface-2); border: 1px solid var(--border); border-radius: 20px; padding: 0 7px; font-size: 10.5px; }
.acc-body { display: none; padding-top: 4px; }
.acc.open .acc-body { display: block; }
.acc .list-item { opacity: .8; }

/* ---------- Lista de tarefas: colunas alinhadas com o cabeçalho ---------- */
.task-row .tk-check, .task-head-row .tk-check { width: 16px; flex-shrink: 0; display: inline-flex; cursor: pointer; }
.tk-check input { width: 15px; height: 15px; accent-color: var(--brand); cursor: pointer; margin: 0; }
.task-row .assignee-chip { width: 136px; max-width: 136px; flex-shrink: 0; }
.task-row > .hours-badge { width: 56px; text-align: center; flex-shrink: 0; }
.task-row .task-time { width: 112px; justify-content: flex-end; }
.task-row.selected { border-color: var(--brand); background: rgba(255, 210, 0, .05); }
.task-meta .st-pill { font-size: 10px; }
.task-head-row {
  display: flex; align-items: center; gap: 10px; padding: 2px 13px 8px;
  font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-faint);
}
.task-head-row .th-dot { width: 11px; flex-shrink: 0; }
.task-head-row .th-title { flex: 1; }
.task-head-row .th-assignee { width: 136px; flex-shrink: 0; }
.task-head-row .th-hours { width: 56px; text-align: center; flex-shrink: 0; }
.task-head-row .th-log { width: 112px; text-align: right; flex-shrink: 0; cursor: help; color: var(--text-dim); white-space: nowrap; }
.th-help {
  display: inline-grid; place-items: center; width: 14px; height: 14px; border-radius: 50%;
  border: 1px solid var(--border-strong); font-size: 9.5px; margin-left: 2px;
}

/* ---------- Barra de ações em massa ---------- */
.bulk-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 9px 18px;
  background: rgba(255, 210, 0, .08); border-bottom: 1px solid rgba(255, 210, 0, .35); flex-shrink: 0;
}
.bulk-bar strong { font-size: 12.5px; color: var(--brand); margin-right: 4px; }
.bulk-bar select, .bulk-bar input[type="date"] {
  background: var(--surface); border: 1px solid var(--border); color: var(--text);
  padding: 5px 7px; border-radius: 6px; font-size: 12px;
}
.bulk-date { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--text-dim); }
.bulk-bar .link-danger { border-color: rgba(255, 90, 90, .4); }

/* ---------- Lançamentos com "o que foi feito" completo ---------- */
.time-entry.te-block { flex-direction: column; align-items: stretch; gap: 6px; }
.te-top { display: flex; align-items: center; gap: 10px; }
.te-top .te-who { flex: 1; min-width: 0; }
.te-src { font-size: 10.5px; color: var(--text-faint); border: 1px solid var(--border); border-radius: 20px; padding: 0 6px; }
.te-note-full { color: var(--text); font-size: 12.5px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; padding-left: 2px; }

/* ---------- Miniaturas de foto: sempre no tamanho do layout ---------- */
.avatar-xs {
  width: 18px; height: 18px; border-radius: 50%; flex-shrink: 0; object-fit: cover;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--brand); color: var(--brand-ink); font-size: 9.5px; font-weight: 800;
}
.member-check .avatar-xs, .te-who .avatar-xs { width: 20px; height: 20px; }

/* ---------- Avisos dentro de modais ---------- */
.notice {
  margin: 8px 0; padding: 10px 12px; border-radius: var(--radius-sm); font-size: 12.5px; line-height: 1.5;
  background: rgba(245, 177, 61, .1); border: 1px solid rgba(245, 177, 61, .35); color: #f3d59a;
}
.notice-ok { background: rgba(89, 201, 119, .1); border-color: rgba(89, 201, 119, .35); color: #b4e8c3; }
.notice .mini-btn { margin-left: 6px; color: var(--brand); }

/* ---------- Painel de usuários ---------- */
.modal.wide { max-width: 780px; }
.users-toolbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.uo-sub { font-size: 11px; color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uo-actions { flex-wrap: nowrap; justify-content: flex-end; }
.user-row-ops .te-del {
  background: none; border: none; color: var(--text-faint); cursor: pointer; font-size: 16px; line-height: 1; padding: 2px 6px; border-radius: 4px;
}
.user-row-ops .te-del:hover { color: var(--prio-alta); background: rgba(255, 90, 90, .12); }

/* ---------- Projetos liberados por pessoa ---------- */
.up-list { display: flex; flex-direction: column; gap: 10px; max-height: 55vh; overflow-y: auto; }
.up-client { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 8px 10px; background: var(--surface); }
.up-client.is-archived { opacity: .6; }
.up-client-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.up-project { display: flex; align-items: center; gap: 8px; padding: 5px 4px; border-radius: 6px; cursor: pointer; font-size: 13px; }
.up-project:hover { background: var(--surface-2); }
.up-project input { accent-color: var(--brand); width: 15px; height: 15px; }
.up-project.is-archived span:first-of-type { text-decoration: line-through; color: var(--text-faint); }
.up-note { font-size: 10.5px; color: var(--text-faint); border: 1px dashed var(--border-strong); border-radius: 20px; padding: 0 6px; }

/* ---------- Importação ---------- */
.imp-types, .tpl-pick, .cfg-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.imp-type, .cfg-tab {
  background: var(--surface); border: 1px solid var(--border); color: var(--text-dim);
  padding: 7px 12px; border-radius: var(--radius-sm); font-size: 12.5px; font-weight: 600; cursor: pointer;
}
.imp-type:hover, .cfg-tab:hover { color: var(--brand); border-color: var(--brand); }
.imp-type.active, .cfg-tab.active { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.imp-source textarea {
  width: 100%; margin-top: 10px; background: var(--bg); border: 1px dashed var(--border-strong); color: var(--text);
  border-radius: var(--radius-sm); padding: 10px; font-family: ui-monospace, Menlo, monospace; font-size: 12px; resize: vertical;
}
.imp-source textarea:focus { outline: none; border-color: var(--brand); border-style: solid; }
.imp-source-actions { display: flex; gap: 8px; margin-top: 8px; align-items: center; }
.imp-map, .imp-preview table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.imp-map th, .imp-preview th {
  text-align: left; font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-faint);
  padding: 6px 8px; border-bottom: 1px solid var(--border);
}
.imp-map td, .imp-preview td { padding: 6px 8px; border-bottom: 1px solid var(--border); vertical-align: top; }
.imp-map select { background: var(--surface); border: 1px solid var(--border); color: var(--text); padding: 5px 7px; border-radius: 6px; font-size: 12px; }
.imp-map tr.unmapped td:first-child { color: var(--text-faint); }
.imp-sample { color: var(--text-faint); max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.imp-preview { max-height: 260px; overflow-y: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); margin: 6px 0 10px; }
.imp-preview tr.err td { color: #ff9d9d; background: rgba(255, 90, 90, .06); }
.imp-preview tr.warn td { color: #f3d59a; }
.imp-summary { font-size: 12.5px; color: var(--text); margin: 4px 0; }
.ok-dot, .err-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin: 0 4px 0 6px; background: #59c977; }
.err-dot { background: #ff6b6b; }

/* ---------- Configurações ---------- */
#cfg-body { margin-top: 14px; display: flex; flex-direction: column; gap: 12px; }
.cfg-howto, .cfg-advanced { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 10px 12px; font-size: 12.5px; color: var(--text-dim); }
.cfg-howto summary, .cfg-advanced summary { cursor: pointer; color: var(--text); font-weight: 600; }
.cfg-howto summary:hover, .cfg-advanced summary:hover { color: var(--brand); }
.cfg-howto ol { margin: 10px 0 6px; padding-left: 20px; line-height: 1.6; }
.cfg-advanced .field-row { margin-top: 10px; }
.cfg-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cfg-actions input {
  flex: 1; min-width: 180px; background: var(--surface); border: 1px solid var(--border); color: var(--text);
  padding: 7px 10px; border-radius: var(--radius-sm); font-size: 12.5px;
}
.tpl-custom { font-size: 10px; background: rgba(0, 0, 0, .2); border-radius: 20px; padding: 0 6px; margin-left: 4px; }
.tpl-body { font-family: ui-monospace, Menlo, monospace; font-size: 12.5px !important; line-height: 1.5; }
.tpl-vars { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; font-size: 11.5px; color: var(--text-faint); }
.tpl-var {
  background: var(--surface); border: 1px solid var(--border); color: var(--text-dim); border-radius: 6px;
  padding: 2px 7px; font-family: ui-monospace, Menlo, monospace; font-size: 11px; cursor: pointer;
}
.tpl-var:hover { color: var(--brand); border-color: var(--brand); }
.tpl-prev-subject { font-size: 12.5px; color: var(--text-dim); margin: 6px 0; }
.tpl-frame { width: 100%; height: 420px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: #f2f3f5; }
.cron-cmd {
  display: flex; align-items: center; gap: 8px; background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 8px 10px; margin-top: 6px;
}
.cron-cmd code { flex: 1; font-size: 11.5px; color: var(--brand); word-break: break-all; }
.log-err { font-size: 11px; color: #ff9d9d; margin-top: 2px; }

.modal.medium { max-width: 600px; }
.member-check { min-width: 0; }
.member-check .role-pill { flex-shrink: 0; }

.btn-ghost.active { background: var(--brand); color: var(--brand-ink); border-color: var(--brand); }
.field-hint { font-size: 11px; color: var(--text-faint); font-weight: 400; }
