/* ══════════════════════════════════════════
   ACTIVITIES PAGE — Light Theme
   ══════════════════════════════════════════ */

/* ── Tab Panel — Light Background ── */
#tp-acts {
  background: #FFFFFF;
  min-height: 100%;
  color: #1B1A17;
}

/* ── Page Header ── */
.acts-page-hdr {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 22px 26px 18px;
  border-bottom: 1px solid #E5E7EB;
  background: #FFFFFF;
}

.acts-page-hdr-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.acts-page-label {
  font-size: 9.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  color: #F59E0B;
}

.acts-page-title {
  font-family: 'Syne', sans-serif;
  font-size: 28px;
  font-weight: 800;
  color: #1B1A17;
  margin: 0;
  line-height: 1.1;
}

.acts-page-sub {
  font-size: 12px;
  color: #6B7280;
  margin: 0;
}

.acts-page-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(245, 158, 11, .35);
  background: rgba(245, 158, 11, .08);
  font-size: 11px;
  font-weight: 700;
  color: #B45309;
  white-space: nowrap;
  margin-top: 4px;
}

.acts-badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #F59E0B;
  box-shadow: 0 0 6px rgba(245, 158, 11, .5);
  flex-shrink: 0;
}

/* ── Edit Toolbar ── */
.acts-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 26px;
  background: #FFFFFF;
  border-bottom: 1px solid #E5E7EB;
  flex-wrap: wrap;
}

.acts-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 9px;
  cursor: pointer;
  user-select: none;
}

.acts-toggle-wrap input[type="checkbox"] {
  display: none;
}

.acts-toggle-track {
  width: 38px;
  height: 22px;
  border-radius: 999px;
  background: #E5E7EB;
  border: 1px solid #D1D5DB;
  position: relative;
  transition: all .2s;
  flex-shrink: 0;
}

.acts-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #9CA3AF;
  transition: all .2s;
}

.acts-toggle-wrap input:checked ~ .acts-toggle-track {
  background: #EFF6FF;
  border-color: #93C5FD;
}

.acts-toggle-wrap input:checked ~ .acts-toggle-track .acts-toggle-thumb {
  left: 19px;
  background: #3B82F6;
}

.acts-toggle-label {
  font-size: 12px;
  font-weight: 600;
  color: #374151;
}

.acts-recalc-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid rgba(59, 130, 246, .4);
  background: #EFF6FF;
  color: #1D4ED8;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: all .16s;
  white-space: nowrap;
}

.acts-recalc-btn:hover {
  background: #DBEAFE;
  border-color: rgba(59, 130, 246, .6);
  color: #1E40AF;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, .15);
}

.acts-toolbar-hint {
  font-size: 11px;
  color: #9CA3AF;
  font-style: italic;
  flex: 1;
  min-width: 0;
}

/* ── Filter Bar ── */
.acts-filter-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 26px;
  background: #F9FAFB;
  border-bottom: 1px solid #E5E7EB;
  flex-wrap: wrap;
}

.acts-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #374151;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all .14s;
  white-space: nowrap;
}

.acts-filter-chip:hover {
  border-color: #CBD5E1;
  color: #1F2937;
  background: #F1F5F9;
}

.acts-count-badge {
  padding: 4px 10px;
  border-radius: 999px;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  font-size: 11px;
  font-weight: 600;
  color: #64748B;
  white-space: nowrap;
  font-family: 'JetBrains Mono', monospace;
}

.acts-search-wrap {
  flex: 1;
  min-width: 180px;
  max-width: 320px;
  position: relative;
  display: flex;
  align-items: center;
}

.acts-search-icon {
  position: absolute;
  left: 10px;
  color: #9CA3AF;
  pointer-events: none;
}

.acts-search {
  width: 100%;
  padding: 6px 12px 6px 30px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #1B1A17;
  font-size: 12px;
  font-family: inherit;
  outline: none;
  transition: border .15s;
}

.acts-search::placeholder {
  color: #9CA3AF;
}

.acts-search:focus {
  border-color: #93C5FD;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, .08);
}

.acts-icon-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #6B7280;
  cursor: pointer;
  display: grid;
  place-items: center;
  font-size: 14px;
  transition: all .14s;
}

.acts-icon-btn:hover {
  border-color: #CBD5E1;
  color: #374151;
}

/* ── Table Container ── */
.tbl-wrap {
  overflow: auto;
  max-height: calc(100vh - 300px);
  border-radius: 0 0 var(--r, 16px) var(--r, 16px);
  border: 1px solid #E5E7EB;
  border-top: none;
  background: #FFFFFF;
}

/* ── Activities Table ── */
.acts-tbl {
  width: 100%;
  border-collapse: collapse;
  min-width: 1100px;
}

/* Dark navy header — stays dark per design */
.acts-tbl thead th {
  position: sticky;
  top: 0;
  z-index: 5;
  background: linear-gradient(180deg, #0D1829 0%, #0A1525 100%);
  border-bottom: 2px solid rgba(59, 130, 246, .25);
  padding: 10px 12px;
  font-size: 9.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #7AABCE;
  text-align: left;
  white-space: nowrap;
}

.acts-tbl thead th .th-info {
  display: inline-block;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 1px solid rgba(96, 165, 250, .4);
  background: rgba(59, 130, 246, .12);
  text-align: center;
  line-height: 12px;
  font-size: 9px;
  color: #60A5FA;
  margin-left: 3px;
  cursor: help;
  vertical-align: middle;
}

/* Light table rows */
.acts-tbl tbody tr {
  transition: background .12s;
  background: #FFFFFF;
}

.acts-tbl tbody tr:nth-child(even) {
  background: #F9FAFB;
}

.acts-tbl tbody tr:hover td {
  background: #EFF6FF !important;
}

.acts-tbl td {
  padding: 9px 12px;
  font-size: 12px;
  border-bottom: 1px solid #F0F0F0;
  vertical-align: middle;
  color: #374151;
}

/* ── Activity cell ── */
.act-cell {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 180px;
}

.act-cell-icon {
  font-size: 14px;
  flex-shrink: 0;
  line-height: 1;
}

.act-cell-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.act-cell-name {
  font-size: 12px;
  font-weight: 600;
  color: #1F2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.act-cell-type {
  font-size: 10px;
  color: #9CA3AF;
}

/* ── Type badge ── */
.type-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  border: 1px solid;
  white-space: nowrap;
}

.type-badge.milestone {
  color: #7C3AED;
  background: rgba(124, 58, 237, .08);
  border-color: rgba(124, 58, 237, .25);
}

.type-badge.task {
  color: #059669;
  background: rgba(5, 150, 105, .08);
  border-color: rgba(5, 150, 105, .22);
}

/* ── Row action button ── */
.acts-row-action {
  background: none;
  border: none;
  color: #D1D5DB;
  font-size: 16px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  opacity: 0;
  transition: all .12s;
  line-height: 1;
}

.acts-tbl tbody tr:hover .acts-row-action {
  opacity: 1;
}

.acts-row-action:hover {
  color: #374151;
  background: #F1F5F9;
}

/* ── Float / Critical colours ── */
.float-crit  { color: #DC2626; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.float-near  { color: #D97706; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.float-ok    { color: #059669; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.float-na    { color: #9CA3AF; font-family: 'JetBrains Mono', monospace; }

/* ── Date / mono cells ── */
.mono-cell {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #6B7280;
}

/* ── ID cell ── */
.id-cell {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  color: #2563EB;
}

/* ── Empty state ── */
#tp-acts .empty {
  padding: 60px 20px;
  text-align: center;
}

#tp-acts .empty-icon {
  font-size: 42px;
  margin-bottom: 14px;
  opacity: .4;
}

#tp-acts .empty-t {
  font-size: 14px;
  font-weight: 700;
  color: #6B7280;
}

#tp-acts .empty-s {
  font-size: 12px;
  color: #9CA3AF;
  margin-top: 6px;
}
