/* ---- Sign-in panel ---- */
.sign-in-panel {
  position: fixed;
  z-index: 9999;
  width: 320px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.sign-in-header {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  text-align: center;
  margin-bottom: 2px;
}
.sign-in-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: rgba(0,0,0,0.25);
  color: var(--text);
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.15s;
}
.sign-in-input:focus {
  border-color: rgba(255,255,255,0.3);
}
.sign-in-input::placeholder {
  color: var(--text-muted);
}
.sign-in-btn-row {
  display: flex;
  gap: 10px;
}
.sign-in-btn {
  flex: 1;
  padding: 10px 0;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.06);
  color: var(--text);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.sign-in-btn:hover {
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.25);
}
.sign-in-btn:disabled {
  opacity: 0.6;
  cursor: default;
}
.sign-in-btn:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 2px;
}
.sign-in-btn--primary {
  background: rgba(99,179,237,0.2);
  border-color: rgba(99,179,237,0.4);
}
.sign-in-btn--primary:hover {
  background: rgba(99,179,237,0.35);
  border-color: rgba(99,179,237,0.6);
}
.sign-in-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: var(--text-muted);
}
.sign-in-divider > span:first-child,
.sign-in-divider > span:last-child {
  flex: 1;
  height: 1px;
  background: var(--glass-border);
}
.sign-in-providers {
  display: flex;
  justify-content: center;
  gap: 12px;
}
.sign-in-provider-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.04);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.sign-in-provider-icon:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.25);
  color: var(--text);
}
.sign-in-provider-icon:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 2px;
}
.sign-in-provider-icon svg {
  pointer-events: none;
}
.sign-in-message {
  font-size: 12px;
  text-align: center;
  min-height: 16px;
  color: var(--text-muted);
}
.sign-in-message--error {
  color: var(--status-blocked);
}
.sign-in-message--success {
  color: var(--status-in-progress);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 500;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.08);
  color: var(--text);
  cursor: pointer;
  transition: background var(--transition);
  white-space: nowrap;
}
.btn:hover { background: var(--hover-bg); }
.btn:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 2px;
}
.btn-danger { color: #fc8181; border-color: rgba(252,129,129,0.3); }
.btn-danger:hover { background: rgba(252,129,129,0.15); }
.btn-primary { background: var(--critical-path); border-color: var(--critical-path); }
.btn-primary:hover { background: #0055cc; }
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Inputs */
.input {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 4px 8px;
  font-size: 12px;
  font-family: var(--font-main);
  outline: none;
  transition: border-color var(--transition);
}
.input:focus { border-color: rgba(255,255,255,0.25); }

/* Glass panel */
.glass-panel {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* Status dot */
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}

/* Sidebar list items */
.sidebar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 0;
  cursor: pointer;
  font-size: 11px;
  line-height: 1.3;
  position: relative;
  transition: opacity 0.15s ease, max-height 0.18s ease;
  overflow: hidden;
  max-height: 60px;
}
.task-group-header {
  padding: 4px 8px 2px;
  font-size: 10px;
  font-weight: 700;
  color: #94a3b8;
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 2px;
  cursor: pointer;
  overflow: hidden;
  transition: opacity 0.15s ease, max-height 0.18s ease;
  max-height: 40px;
}
.sidebar-item.filtered-out,
.task-group-header.filtered-out {
  opacity: 0;
  max-height: 0;
  padding: 0;
  margin: 0;
  border: none;
  pointer-events: none;
  overflow: hidden;
}

.sidebar-item-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: opacity 0.15s;
}

/* Buttons float over right side of text on hover -- no reserved space */
.item-actions {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 2px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
  background: linear-gradient(to right, transparent, var(--bg-sidebar) 30%);
  padding-left: 18px;
  border-radius: 3px;
}
.sidebar-item:hover .item-actions,
.sidebar-item:focus-within .item-actions {
  opacity: 1;
  pointer-events: auto;
}
/* Fade text slightly under the buttons on hover */
.sidebar-item:hover .sidebar-item-text { opacity: 0.7; }

.sidebar-item .edit-btn {
  font-size: 10px;
  color: var(--text-muted);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 4px;
  opacity: 0;
  transition: opacity var(--transition);
}
.sidebar-item:hover .edit-btn { opacity: 1; }

.item-btn {
  font-size: 9px;
  font-weight: 700;
  font-family: var(--font-main);
  padding: 1px 5px;
  border-radius: 3px;
  border: 1px solid transparent;
  cursor: pointer;
  background: rgba(255,255,255,0.06);
  color: var(--text-muted);
  line-height: 1.4;
  transition: all 0.1s;
}
.item-btn:hover { background: var(--hover-bg); color: var(--text); }
.item-btn.danger { color: #fc8181; }
.item-btn.danger:hover { background: rgba(197,48,48,0.2); color: #fc8181; }

/* Status pill */
.status-pill {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Toggle switch */
.toggle-label {
  font-size: 11px;
  display: flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  color: var(--text);
}
.toggle-label input { cursor: pointer; }

/* Mode bar elements */
.mode-label {
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.mode-hint {
  flex: 1;
  font-size: 11px;
  opacity: 0.7;
  text-align: center;
}

.mode-name-input {
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-sm);
  color: #fff;
  padding: 3px 8px;
  font-size: 12px;
  width: 160px;
}
.mode-name-input:focus { outline: none; border-color: #63b3ed; box-shadow: 0 0 0 2px rgba(99,179,237,0.3); }
.mode-name-input::selection { background: #2b6cb0; color: #fff; }

/* Tooltip */
.node-tooltip {
  position: fixed;
  background: var(--glass-overlay);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 11px;
  color: var(--text);
  pointer-events: none !important;
  user-select: none;
  z-index: 500;
  min-width: 240px;
  max-width: 320px;
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}
.tt-header { display: flex; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.tt-id { color: var(--text-muted); font-size: 10px; font-family: var(--font-mono); }
.tt-name { font-weight: 700; font-size: 13px; flex: 1; }
.tt-status-pill { font-size: 9px; font-weight: 700; padding: 1px 6px; border-radius: 8px; color: #fff; text-transform: uppercase; flex-shrink: 0; }
.tt-desc { color: var(--text-muted); font-size: 10px; margin-bottom: 8px; line-height: 1.4; border-bottom: 1px solid var(--border); padding-bottom: 6px; }
.tt-section { font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); margin: 6px 0 4px; }
.tt-stats { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 4px; margin-bottom: 6px; }
.tt-stat { background: rgba(255,255,255,0.04); border-radius: 4px; padding: 4px 6px; text-align: center; }
.tt-stat-val { font-size: 14px; font-weight: 700; line-height: 1; }
.tt-stat-lbl { font-size: 9px; color: var(--text-muted); margin-top: 1px; }
.tt-hours-row { display: flex; gap: 6px; margin-bottom: 6px; }
.tt-hours-chip { flex: 1; background: rgba(255,255,255,0.04); border-radius: 4px; padding: 3px 6px; text-align: center; }
.tt-hours-chip .v { font-size: 12px; font-weight: 700; }
.tt-hours-chip .l { font-size: 9px; color: var(--text-muted); }
.tt-people { font-size: 10px; color: var(--text-muted); }

/* Vision edit area in sidebar */
#vision-edit-area {
  flex-shrink: 0;
  padding: 6px 14px;
  display: none;
}
#vision-edit-area.active { display: block; }

#vision-add-input {
  width: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 4px 8px;
  font-size: 11px;
}

.create-hint {
  font-size: 11px;
  color: #94a3b8;
  padding: 6px 4px;
  font-style: italic;
  opacity: 0.7;
}

/* Vision selected item */
.vision-selected {
  border-left: 2px solid var(--vision);
  padding-left: 6px;
  background: rgba(246,224,94,0.06);
  border-radius: 3px;
}

.vision-selected-node circle:first-of-type {
  stroke: #ffffff;
  stroke-width: 3;
}

/* Focus-visible outline for action buttons (keyboard accessibility) */
.item-btn:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 1px;
}

/* FIX #157: Resize handle -- larger hit target for touch devices */
.resize-handle {
  height: 12px;
  cursor: row-resize;
  background: transparent;
  flex-shrink: 0;
  transition: background var(--transition);
  touch-action: none;
}
.resize-handle:hover { background: rgba(255,255,255,0.12); }
.resize-handle:focus-visible { background: rgba(255,255,255,0.18); outline: 1px solid rgba(255,255,255,0.3); }

/* Wizard banners */
.wizard-banner {
  position: fixed;
  top: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 400;
  background: rgba(74,82,148,0.97);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 8px;
  padding: 7px 18px;
  font-size: 12px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
  pointer-events: auto;
  white-space: nowrap;
}

.wizard-banner-label {
  font-weight: 600;
}

.wizard-banner-hint {
  font-size: 10px;
  color: rgba(255,255,255,0.45);
}

/* Task panel item layout */
.sidebar-item-row {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  min-width: 0;
  position: relative;
}

.sidebar-item-id {
  font-size: 10px;
  color: #94a3b8;
  flex-shrink: 0;
}

.sidebar-item-meta {
  font-size: 10px;
  color: #94a3b8;
  flex-shrink: 0;
}

/* Kanban card delete button */
.kanban-card-del {
  background: none;
  border: none;
  color: rgba(255,255,255,0.25);
  font-size: 14px;
  cursor: pointer;
  padding: 4px 6px;
  line-height: 1;
  min-width: 24px;
  min-height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s;
}

.kanban-card-del:hover {
  color: #fc8181;
}
.kanban-card-del:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 1px;
}


/* Banner stack container -- all fixed-top banners go here so they stack vertically */
.tol-banner-stack {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  pointer-events: none;
}
.tol-banner-stack > * {
  pointer-events: auto;
}

/* Error banners (sync membership/removal/deletion) */
.tol-error-banner {
  display: block;
  background: #7f1d1d;
  color: #fecaca;
  padding: 12px 20px;
  text-align: center;
  font-size: 13px;
}

/* Empty-state hint for sidebar sections with no items */
.section-list:empty::after {
  content: 'No items yet -- use "+ Add" above or right-click the canvas';
  display: block;
  padding: 12px 4px;
  font-size: 10px;
  color: var(--text-muted);
  font-style: italic;
  opacity: 0.6;
  text-align: center;
  line-height: 1.5;
}

/* Hover affordance: show pointer cursor on clickable sidebar items */
.sidebar-item { cursor: pointer; }
.sidebar-item:hover { background: rgba(255,255,255,0.04); border-radius: 3px; }

/* Improve discoverability of action buttons with subtle underline on focus */
.item-btn:focus-visible {
  text-decoration: underline;
}

/* Status pill pointer cursor */
.status-pill { cursor: pointer; }
.status-pill:focus-visible { outline: 2px solid rgba(255,255,255,0.5); outline-offset: 1px; }

/* ---- Loading animation ---- */
.tol-loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
}

.tol-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.tol-loading-svg {
  overflow: visible;
}

.tol-loading-message {
  font-family: var(--font-main);
  font-size: 12px;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

/* Center node: gentle pulse (delay set inline by JS) */
.tol-loading-center {
  fill: var(--text);
  animation: tol-pulse 2.4s ease-in-out infinite;
}

/* Branch lines: draw-on then fade-pulse.
   animationDuration and animationDelay are set per-element in JS
   to cascade the draw timing level-by-level. */
.tol-loading-branch {
  fill: none;
  stroke: var(--text-muted);
  stroke-linecap: round;
  stroke-dasharray: 60;
  stroke-dashoffset: 60;
  animation-name: tol-draw, tol-branch-fade;
  animation-timing-function: ease, ease;
  animation-fill-mode: forwards, none;
  animation-iteration-count: 1, infinite;
}

/* Terminal dots: pop in after their branch, then pulse.
   animationDelay set per-element in JS. */
.tol-loading-dot {
  fill: var(--text-muted);
  opacity: 0;
  transform-origin: center;
  animation-name: tol-dot-in, tol-dot-pulse;
  animation-duration: 0.35s, 2.4s;
  animation-timing-function: ease, ease;
  animation-fill-mode: forwards, none;
  animation-iteration-count: 1, infinite;
}

@keyframes tol-draw {
  to { stroke-dashoffset: 0; }
}

@keyframes tol-branch-fade {
  0%, 100% { opacity: 0.35; }
  50%      { opacity: 1; }
}

@keyframes tol-dot-in {
  to { opacity: 1; }
}

@keyframes tol-dot-pulse {
  0%, 100% { opacity: 0.4; }
  50%      { opacity: 1; }
}

@keyframes tol-pulse {
  0%, 100% { opacity: 0.6; }
  50%      { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .tol-loading-branch,
  .tol-loading-dot,
  .tol-loading-center {
    animation: none;
    opacity: 1;
    stroke-dashoffset: 0;
  }
}

/* Section add button: clearer affordance */
.section-add-btn:focus-visible {
  outline: 2px solid rgba(255,255,255,0.5);
  outline-offset: 1px;
}

/* ---- Members panel ---- */
.members-panel-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 360px;
  max-width: 460px;
  max-height: 60vh;
  overflow-y: auto;
  z-index: 200;
  padding: 12px;
}

.members-section-header {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}

.members-toggle {
  cursor: pointer;
  user-select: none;
}
.members-toggle:hover { color: var(--text); }

.members-toggle-arrow {
  font-size: 8px;
  margin-right: 4px;
  display: inline-block;
  transition: transform 0.15s;
}

.members-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.members-row-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
}

.members-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.members-meta {
  font-size: 10px;
  color: var(--text-muted);
}

.members-row-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.members-role-badge {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 3px;
  color: #fff;
}

.members-role-owner {
  background: #2563eb;
}

.members-role-collab {
  background: #4a5568;
}

.members-link-active {
  background: #38a169;
}

.members-link-expired {
  background: #718096;
}

.members-you-label {
  font-size: 10px;
  color: var(--text-muted);
  font-style: italic;
}

.members-divider {
  border-top: 1px solid var(--border);
  margin: 6px 0;
}

.members-empty {
  font-size: 11px;
  color: var(--text-muted);
  font-style: italic;
  padding: 8px 0;
}

.members-loading {
  font-size: 11px;
  color: var(--text-muted);
  padding: 12px 0;
  text-align: center;
}

/* ---- MCP tokens panel + one-time-display modal (260425.mcp-server) ---- */

/* List under the tokens dropdown shares typography with the members list. */
.mcp-tokens-empty {
  font-size: 11px;
  color: var(--text-muted);
  font-style: italic;
  padding: 8px 12px;
}
.mcp-tokens-loading {
  font-size: 11px;
  color: var(--text-muted);
  padding: 12px 0;
  text-align: center;
}

/* Modal: shown ONCE at token issuance to display the raw token. The user
 * cannot see it again, so the modal blocks the page (overlay) and centers
 * the content. Built by js/utils/mcp-token-modal.js -- both the tokens
 * panel and the members panel route through that helper. */
.mcp-tokens-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.mcp-tokens-modal {
  background: var(--glass-overlay);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  min-width: 360px;
  max-width: 560px;
  color: var(--text);
  font-family: var(--font-main);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}
.mcp-tokens-modal h3 {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 600;
}

/* Warning strip: this is the user's last chance to copy the secret. */
.mcp-tokens-warn {
  margin: 0 0 12px;
  padding: 8px 10px;
  font-size: 12px;
  color: #fde68a;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-sm);
}

/* The token itself: monospace, selectable, breaks long strings so a 64+
 * char base64 doesn't overflow the modal. */
.mcp-tokens-token-box {
  margin: 0 0 14px;
  padding: 10px 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  user-select: all;
  word-break: break-all;
  white-space: pre-wrap;
}

.mcp-tokens-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* ---- Backup history panel ---- */
.backup-panel-dropdown {
  position: absolute;
  top: 100%;
  right: calc(100% + 8px);
  min-width: 300px;
  max-width: 400px;
  max-height: 60vh;
  overflow-y: auto;
  padding: 12px;
  z-index: 300;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.12) transparent;
}
.backup-panel-dropdown::-webkit-scrollbar {
  width: 4px;
}
.backup-panel-dropdown::-webkit-scrollbar-track {
  background: transparent;
}
.backup-panel-dropdown::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.12);
  border-radius: 2px;
}
.backup-panel-dropdown::-webkit-scrollbar-thumb:hover {
  background: rgba(255,255,255,0.2);
}

.backup-section-header {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding: 4px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}

.backup-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  cursor: pointer;
  flex-wrap: wrap;
}

.backup-row-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  flex: 1;
}

.backup-row-summary-main {
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
}

.backup-change-badge {
  font-size: 8px;
  font-weight: 600;
  text-transform: lowercase;
  padding: 0 4px;
  border-radius: 2px;
  background: rgba(255,255,255,0.06);
  color: var(--text-muted);
  border: 1px solid rgba(255,255,255,0.08);
  white-space: nowrap;
}

.backup-row-meta {
  font-size: 10px;
  color: var(--text-muted);
}

.backup-current-badge {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 1px 6px;
  border-radius: 3px;
  color: #fff;
  background: #38a169;
  flex-shrink: 0;
}

.backup-restore-btn {
  font-size: 10px;
  padding: 2px 8px;
  border-radius: 3px;
  border: 1px solid var(--glass-border);
  background: rgba(255,255,255,0.05);
  color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s;
}
.backup-restore-btn:hover {
  background: rgba(255,255,255,0.12);
}
.backup-restore-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.backup-row-summary {
  font-size: 10px;
  color: var(--text-muted);
}

.backup-detail {
  margin-top: 4px;
  padding: 6px 8px 4px;
  border-top: 1px solid rgba(255,255,255,0.06);
  width: 100%;
  text-align: right;
  background: rgba(255,255,255,0.03);
  border-radius: 3px;
  overflow: hidden;
}

.backup-detail-entity {
  font-weight: 600;
  color: var(--text);
  font-size: 10px;
  margin-top: 4px;
}
.backup-detail-entity:first-child {
  margin-top: 0;
}

.backup-detail-field {
  font-size: 9px;
  color: var(--text-muted);
  padding: 1px 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
  white-space: normal;
}

.backup-restore-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  flex-shrink: 0;
}

.backup-danger-btn {
  font-size: 12px;
  font-weight: 800;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: #e53e3e;
  color: #fff;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s;
}
.backup-danger-btn:hover {
  background: #c53030;
}

.backup-confirm-warning {
  font-size: 9px;
  color: #fc8181;
  text-align: right;
  max-width: 140px;
  line-height: 1.3;
}

.backup-confirm-btns {
  display: flex;
  gap: 4px;
}
.backup-confirm-yes,
.backup-confirm-no {
  font-size: 10px;
  padding: 2px 10px;
  border-radius: 3px;
  border: none;
  cursor: pointer;
  font-weight: 600;
}
.backup-confirm-yes {
  background: #e53e3e;
  color: #fff;
}
.backup-confirm-yes:hover {
  background: #c53030;
}
.backup-confirm-no {
  background: rgba(255,255,255,0.08);
  color: var(--text);
}
.backup-confirm-no:hover {
  background: rgba(255,255,255,0.15);
}

.backup-restoring {
  font-size: 10px;
  color: var(--text-muted);
  font-style: italic;
}

.backup-empty,
.backup-loading {
  font-size: 11px;
  color: var(--text-muted);
  padding: 12px 0;
  text-align: center;
}

/* User auth dropdown */
.user-dropdown { padding: 8px 0; }
.user-dropdown-name { font-size: 12px; font-weight: 600; color: var(--text); padding: 4px 14px; }
.user-dropdown-email { font-size: 11px; color: var(--text-muted); padding: 2px 14px 6px; }
.user-dropdown-divider { border: none; border-top: 1px solid var(--border); margin: 4px 0; }
.user-dropdown-signout { margin: 6px 14px 2px; width: calc(100% - 28px); }

/* Cadence-plane CSS (plane-toggle, cadence-band-*, plane-toggle-*) was moved
 * to styles/cadence.css (F37). The cadence subsystem stays removable as a
 * unit -- delete cadence.css + the cadence JS modules + the link tag in
 * index.html, and the cadence feature is gone with no hunting through this
 * shared stylesheet. */
