* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: #e0e0e0;
  color: #374151;
  min-height: 100vh;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
  gap: 24px;
  padding: 20px 20px 8px 20px;
}

.header h1 {
  font-size: 24px;
  font-weight: 600;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.header h1 .dashboard-title { font-weight: 600; color: #469168; }

.header-stats { display: flex; gap: 12px; flex: 1; justify-content: center; }
#app-main .header-stats { justify-content: flex-start; flex: 0 0 auto; flex-wrap: wrap; }
.account-menu { position: relative; }
.account-menu-toggle { background: #e5e7eb; border: 0; border-radius: 8px; padding: 8px 14px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; color: #1f2937; font: 600 14px 'Wix Madefor Display', system-ui, -apple-system, 'Wix Madefor Text', sans-serif; white-space: nowrap; transition: background 0.2s ease, box-shadow 0.2s ease; }
.account-menu-toggle:hover { background: #dfe3e9; box-shadow: 0 2px 4px rgba(15, 23, 42, 0.12); }
.account-menu-toggle:focus-visible { outline: 2px solid #469168; outline-offset: 2px; }
.account-menu-toggle-icon { font-size: 12px; line-height: 1; }
.account-menu-avatar { width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0; }
.account-menu-dropdown { position: absolute; top: calc(100% + 6px); right: 0; background: #fff; border: 1px solid #d1d5db; border-radius: 10px; box-shadow: 0 12px 32px rgba(15, 23, 42, 0.18); min-width: 190px; padding: 8px 0; display: flex; flex-direction: column; z-index: 1200; }
.account-menu-dropdown[hidden] { display: none; }
.account-menu-item { padding: 8px 16px; text-decoration: none; color: #111827; font: 500 14px 'Wix Madefor Text', system-ui, -apple-system, sans-serif; display: flex; align-items: center; gap: 8px; background: transparent; border: 0; cursor: pointer; width: 100%; text-align: left; }
.account-menu-item:hover { background: #f3f4f6; }

.mini-stat { text-align: center; padding: 6px 10px; background: white; border-radius: 6px; border: 1px solid #e5e7eb; min-width: 70px; }
.mini-stat.clickable-tile { cursor: default; transition: none; border-color: #e5e7eb !important; }
.mini-stat.clickable-tile:hover { background: inherit !important; border-color: #e5e7eb !important; transform: none !important; box-shadow: none !important; outline: none !important; }
.mini-stat.clickable-tile.active { cursor: default; background: #10b981; border-color: #10b981; color: white; }
.mini-stat.clickable-tile.active .mini-stat-number, .mini-stat.clickable-tile.active .mini-stat-label { color: white; }
.mini-stat-number { font-size: 16px; font-weight: 600; margin: 0; color: #111827; line-height: 1.2; }
.mini-stat-label { font-size: 9px; color: #6b7280; text-transform: uppercase; font-weight: 500; margin: 2px 0 0; line-height: 1.1; }

.header-buttons { display: flex; gap: 12px; flex-shrink: 0; align-items: center; }
.btn { padding: 12px 16px; border-radius: 8px; text-decoration: none; font-weight: 500; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid; transition: all 0.2s ease; height: 45px; min-width: 120px; }
.btn-primary { background: #469168; color: white; border-color: #469168; }
.btn-secondary { background: white; color: #6b7280; border-color: #d1d5db; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); }
.btn-primary:hover { background: #3d7957; border-color: #3d7957; }
.btn-secondary:hover { background: #f9fafb; border-color: #9ca3af; color: #374151; }
#triggerAllBtn[disabled]{ opacity: .6; cursor: not-allowed; }

.main-content { padding: 8px 20px 20px 20px; }
.view-toggle { display: flex; background: white; border-radius: 8px; border: 1px solid #e5e7eb; overflow: hidden; margin-right: 24px; flex-shrink: 0; }
.toggle-btn { padding: 12px 24px; background: white; border: none; font-size: 14px; font-weight: 500; cursor: pointer; text-decoration: none; color: #6b7280; display: flex; align-items: center; gap: 8px; transition: all 0.2s ease; }
.toggle-btn.active { background: #469168 !important; color: white !important; }
.toggle-btn:hover:not(.active) { background: #f9fafb; color: #374151; }

.filters { background: white; padding: 16px; border-radius: 8px; border: 1px solid #e5e7eb; margin-bottom: 16px; margin-top: 8px; padding-top: 8px; display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.filter-inputs { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; min-width: 0; }
.left-controls { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.search-controls { display: flex; align-items: center; gap: 12px; }
.filter-input, .filter-select { padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 14px; background: white; min-width: 0; }
.filter-input { width: 135px; min-width: 90px; }
.filter-select { width: 140px; min-width: 120px; }
body[data-dashboard-view="sites-to-plugins"] #statusFilter {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}
@media (max-width: 1400px) {
  .filters { justify-content: center; text-align: center; }
  .filters .left-controls,
  .filters .filter-inputs { justify-content: center; }
  #app-main .header-stats { justify-content: center; }
  .view-toggle { margin-right: 0; }
}
@media (max-width: 768px) {
  .filters { flex-direction: column; align-items: stretch; }
  .filter-inputs { justify-content: stretch; }
  .filter-input { flex: 1; min-width: 0; width: auto; }
  .filter-select { flex: 1; min-width: 120px; }
}
.filter-checkbox { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: #6b7280; padding: 6px 12px; background: white; border: 1px solid #e5e7eb; border-radius: 6px; }
.cap-indicator { background: #fef3c7; border: 1px solid #fcd34d; color: #92400e; border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 500; line-height: 1; display: inline-flex; align-items: center; gap: 4px; }

.progress-box { background: #fff; border: 1px solid #e2e8f0; border-radius: 8px; padding: 12px 16px; margin-bottom: 16px; display: none; }
.progress-title { display:flex; align-items:center; justify-content:space-between; margin-bottom:8px; }
.progress-bar-wrap { height: 10px; background: #f3f4f6; border-radius: 9999px; overflow: hidden; }
.progress-bar { height: 10px; width: 0%; background: #10b981; transition: width .3s ease; }
.small { font-size: 12px; color: #6b7280; }
.results-list { margin-top: 8px; max-height: 160px; overflow: auto; font-size: 12px; color: #374151; }
.result-ok { color: #166534; }
.result-fail { color: #b91c1c; }

.count-badge { display: inline-block; padding: 6px 10px; border-radius: 14px; font-size: 15px; font-weight: 500; min-width: 30px; text-align: center; cursor: pointer; position: relative; }
th.count-col,
td.count-col { text-align: center !important; }
td.count-col > .tooltip { display: inline-flex; justify-content: center; align-items: center; width: 100%; }
td.count-col .count-badge { margin: 0 auto; }
#addedFilterBadge .count-badge,
#removedFilterBadge .count-badge,
#updatesFilterBadge .count-badge,
#inactiveFilterBadge .count-badge { font-size: 12px; padding: 4px 10px; min-width: 28px; }
.change-badge { font-size: 12px; padding: 4px 10px; min-width: 28px; }

body[data-dashboard-view="plugins-to-sites"] .data-table th:nth-child(2),
body[data-dashboard-view="plugins-to-sites"] .data-table th:nth-child(3),
body[data-dashboard-view="plugins-to-sites"] .data-table th:nth-child(4),
body[data-dashboard-view="plugins-to-sites"] .data-table th:nth-child(5),
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(2),
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(3),
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(4),
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(5) {
  text-align: center !important;
}
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(2) .tooltip,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(3) .tooltip,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(4) .tooltip,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(5) .tooltip {
  display: inline-flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100%;
}
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(2) .count-badge,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(3) .count-badge,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(4) .count-badge,
body[data-dashboard-view="plugins-to-sites"] .data-table td:nth-child(5) .count-badge {
  margin-left: auto !important;
  margin-right: auto !important;
}
.count-badge:hover { opacity: 0.8; }
.tooltip { position: relative; display: inline-block; }
.tooltip .tooltip-content { visibility: hidden; opacity: 0; position: fixed; background-color: #1f2937; color: white; text-align: left; padding: 8px 12px; border-radius: 6px; font-size: 12px; font-weight: normal; min-width: 200px; max-width: 300px; z-index: 1000; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); transition: opacity 0.2s, visibility 0.2s; pointer-events: none; }
.tooltip .tooltip-content.above::after { content: ""; position: absolute; width: 0; height: 0; border-width: 5px; border-style: solid; }
.tooltip .tooltip-content.above::after { top: 100%; left: 50%; margin-left: -5px; border-color: #1f2937 transparent transparent transparent; }
.tooltip .tooltip-content.below::after { bottom: 100%; left: 50%; margin-left: -5px; border-color: transparent transparent #1f2937 transparent; }
.tooltip:hover .tooltip-content { visibility: visible; opacity: 1; }
.tooltip-list { list-style: none; margin: 0; padding: 0; }
.tooltip-list li { padding: 2px 0; border-bottom: 1px solid rgba(255, 255, 255, 0.1); }
.tooltip-list li:last-child { border-bottom: none; }
.count-active { background: #dcfce7; color: #166534; }
.count-inactive { background: #f3f4f6; color: #878787; }
.count-updates { background: #fef3c7; color: #92400e; }
.count-neutral { background: #e5e7eb; color: #1f2937; }
.count-total { background: #dbeafe; color: #1e40af; }
.pagination { display: flex; justify-content: space-between; align-items: center; background: white; padding: 16px; border-radius: 8px; border: 1px solid #e5e7eb; }
.pagination-info { font-size: 14px; color: #6b7280; }
.pagination-controls { display: flex; gap: 16px; align-items: center; }
.page-select { display: flex; align-items: center; gap: 8px; font-size: 14px; color: #374151; }
.page-select select { padding: 6px 10px; border: 1px solid #d1d5db; border-radius: 4px; font-size: 14px; background: white; }
.pagination-buttons { display: flex; gap: 4px; }
.page-btn { padding: 6px 12px; border: 1px solid #d1d5db; background: white; color: #374151; text-decoration: none; border-radius: 4px; font-size: 14px; cursor: pointer; display: flex; align-items: center; justify-content: center; min-width: 40px; }
.page-btn:hover { background: #f9fafb; }
.page-btn.active { background: #469168; color: white; border-color: #469168; }
.page-btn.disabled { color: #9ca3af; cursor: not-allowed; pointer-events: none; }

.table-header {
  position: sticky;
  top: 0;
  background: #f9fafb;
  z-index: 5;
}

.data-table table thead th {
  position: sticky;
  top: 0;
  background: #f9fafb;
  z-index: 5;
}

.table-header.sortable {
  cursor: pointer;
  user-select: none;
  position: sticky;
  top: 0;
  padding-right: 20px;
  font-weight: 500;
}

.table-header.sortable:hover {
  color: #111827;
}

.table-header.sortable::after {
  content: "⇅";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 11px;
  color: #9ca3af;
  opacity: 0.7;
}

.table-header.sortable.sorted-asc::after {
  content: "▲";
  font-size: 10px;
  color: #4b5563;
  opacity: 1;
}

.table-header.sortable.sorted-desc::after {
  content: "▼";
  font-size: 10px;
  color: #4b5563;
  opacity: 1;
}

/* Notes column – compact, scannable, clickable */
.notes-cell {
  width: 230px;
  max-width: 260px;
  font-size: 13px;
}

/* Make the whole cell clickable but still look lightweight */
.notes-button {
  display: block;
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  padding: 6px 8px;
  margin: -4px -6px;
  border-radius: 8px;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.08s ease;
}

.notes-button:hover {
  background-color: #f3f4f6;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
  transform: translateY(-1px);
}

.notes-button:focus-visible {
  outline: 2px solid #469168;
  outline-offset: 2px;
}

/* Main text line – single line with ellipsis */
.note-text,
.note-empty {
  display: block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.note-empty {
  color: #9ca3af;
  font-style: italic;
}

.notes-button:hover .note-empty {
  text-decoration: underline;
}

/* Reminder pill – tidy, right-ish, and small */
.note-reminder {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background-color: #fee2e2;
  color: #991b1b;
  font-size: 11px;
}

.note-reminder .reminder-icon {
  font-size: 13px;
  line-height: 1;
}
.no-data { text-align: center; padding: 48px; color: #64748b; }
div.no-data h3 {
  font-family: 'Wix Madefor Text';
  color: #6b7280;
  font-size: 1.5em;
}
div.no-data p {
  color: #6b7280;
  margin-top: 15px;
}
.no-data .no-data-illustration {
  width: 12vw;
  max-width: 220px;
  min-width: 100px;
  margin-bottom: 5px;
}
.row-status { margin-left: 6px; font-size: 12px; vertical-align: middle; }
.row-status.ok { color: #166534; }
.row-status.fail { color: #b91c1c; }
.trigger-options { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.trigger-dropdown { position: relative; display: inline-block; }
.dropdown-content { display: none; position: absolute; background-color: white; min-width: 200px; box-shadow: 0px 8px 16px rgba(0,0,0,0.1); border: 1px solid #e5e7eb; border-radius: 6px; z-index: 1000; right: 0; top: 100%; margin-top: 4px; }
.dropdown-content.show { display: block; }
.dropdown-item { color: #374151; padding: 10px 16px; text-decoration: none; display: block; cursor: pointer; border-bottom: 1px solid #f3f4f6; font-size: 14px; }
.dropdown-item:hover { background-color: #f9fafb; }
.dropdown-item:last-child { border-bottom: none; }
.modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.35); display: none; align-items: center; justify-content: center; z-index: 2000; }
.modal-backdrop.show { display: flex; }
.modal-card { width: 100%; max-width: 460px; background: #fff; border-radius: 10px; border: 1px solid #e5e7eb; box-shadow: 0 10px 30px rgba(0,0,0,.15); }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid #eef2f7; }
.modal-title { font: 600 16px/1.2 system-ui, -apple-system, 'Inter', sans-serif; color: #111827; }
.modal-close { border: none; background: transparent; cursor: pointer; font-size: 18px; line-height: 1; color: #6b7280; padding: 4px 6px; border-radius: 6px; }
.modal-close:hover { background: #f3f4f6; color: #111827; }
.modal-body { padding: 16px; color: #374151; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; padding: 12px 16px; border-top: 0px solid #eef2f7; }
.btn-danger { background: #ef4444; color: #fff; border-color: #ef4444; }
.btn-danger:hover { background: #dc2626; border-color: #dc2626; }


/* Manual Changes by Jacob - Nov 8 2025 (updated to keep gradient visible) */
body[data-dashboard-view="plugins-to-sites"] .main-content,
body[data-dashboard-view="sites-to-plugins"] .main-content {
  background-color: transparent;
}
.count-inactive { color: #878787 !important; }
