* {
  margin:0; padding:0; box-sizing:border-box;
}
body {
  font-family: system-ui, -apple-system, sans-serif;
  background: #0f172a;
  color: #e2e8f0;
  min-height: 100vh;
  padding: 1.5rem;
}
header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 2rem;
}
h1 { font-size: 1.8rem; }
#live-indicator {
  display: flex; align-items: center; gap: .5rem;
  font-size: .85rem; color: #94a3b8;
}
.dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: #22c55e; display: inline-block;
  animation: pulse 1.5s infinite;
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.4} }

.office-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
.agent-card {
  background: #1e293b;
  border-radius: 1rem;
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
  transition: all .3s ease;
  border: 1px solid #334155;
}
.agent-card.working {
  border-color: #3b82f6;
  box-shadow: 0 0 20px rgba(59,130,246,.2);
}
.agent-card.blocked {
  border-color: #ef4444;
  box-shadow: 0 0 20px rgba(239,68,68,.2);
}
.agent-card.done {
  border-color: #22c55e;
  box-shadow: 0 0 20px rgba(34,197,94,.15);
}
.agent-card.idle {
  border-color: #475569;
  opacity: .8;
}

.agent-header {
  display: flex; align-items: center; gap: .75rem;
  margin-bottom: .75rem;
}
.agent-icon {
  width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
}
.agent-name {
  font-weight: 600; font-size: 1rem;
}
.agent-role {
  font-size: .8rem; color: #94a3b8;
}
.status-badge {
  margin-left: auto;
  font-size: .75rem; font-weight: 600;
  padding: .25rem .75rem;
  border-radius: 1rem;
  text-transform: uppercase;
}
.status-badge.working { background: #1d4ed8; color: #bfdbfe; }
.status-badge.blocked { background: #991b1b; color: #fecaca; }
.status-badge.done    { background: #166534; color: #bbf7d0; }
.status-badge.idle    { background: #334155; color: #cbd5e1; }

.agent-task {
  background: #0f172a;
  border-radius: .5rem;
  padding: .75rem;
  margin-top: .5rem;
  font-size: .85rem;
}
.agent-task .task-title {
  font-weight: 500; color: #e2e8f0; margin-bottom: .25rem;
}
.agent-task .task-status {
  font-size: .75rem; color: #64748b;
}
.agent-stats {
  display: flex; gap: .75rem; margin-top: .75rem;
  font-size: .8rem; color: #94a3b8;
}
.agent-stats span { display: flex; align-items: center; gap: .25rem; }

/* task board */
#board-section h2 {
  margin-bottom: 1rem; font-size: 1.3rem;
}
.task-grid {
  display: flex; flex-wrap: wrap; gap: .75rem;
}
.task-chip {
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: .6rem;
  padding: .6rem .9rem;
  display: flex; align-items: center; gap: .6rem;
  font-size: .85rem;
  transition: all .2s;
}
.task-chip .state {
  display: inline-block;
  width: 8px; height: 8px; border-radius: 50%;
}
.task-chip .state.running { background: #3b82f6; }
.task-chip .state.blocked { background: #ef4444; }
.task-chip .state.done    { background: #22c55e; }
.task-chip .state.idle    { background: #64748b; }

/* animasi working */
.agent-card.working::after {
  content: '';
  position: absolute; bottom: 0; left: 0;
  height: 3px; width: 0;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899);
  animation: progress 3s linear infinite;
}
@keyframes progress { to { width: 100%; } }

@media (max-width: 768px) {
  .office-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .office-grid { grid-template-columns: 1fr; }
}
