* { box-sizing: border-box; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  margin: 0;
  color: #1d1d1f;
  background: #f7f7f9;
}
header {
  background: #fff;
  border-bottom: 1px solid #e5e5ea;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.brand {
  font-weight: 600;
  font-size: 18px;
  color: #1d1d1f;
  text-decoration: none;
}
nav#breadcrumbs { color: #6b6b70; font-size: 14px; }
nav#breadcrumbs a { color: #0a66c2; text-decoration: none; }
nav#breadcrumbs a:hover { text-decoration: underline; }
nav#breadcrumbs .sep { margin: 0 6px; color: #c0c0c4; }
main { padding: 24px; max-width: 1200px; margin: 0 auto; }
h1 { margin: 0 0 16px; font-size: 22px; }
h2 { margin: 24px 0 12px; font-size: 18px; }
.card {
  background: #fff;
  border: 1px solid #e5e5ea;
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}
form { display: flex; flex-direction: column; gap: 8px; }
label { font-size: 13px; color: #4a4a50; }
input, textarea, button {
  font: inherit;
  padding: 8px 12px;
  border: 1px solid #d0d0d6;
  border-radius: 6px;
  background: #fff;
}
textarea { resize: vertical; min-height: 80px; }
button {
  background: #0a66c2;
  color: #fff;
  border-color: #0a66c2;
  cursor: pointer;
}
button:hover { background: #084d96; }
button.secondary {
  background: #fff;
  color: #0a66c2;
}
button.danger {
  background: #fff;
  color: #b3261e;
  border-color: #f3c1bd;
  margin-left: 6px;
}
button.danger:hover { background: #fdecea; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 8px 10px; text-align: left; border-bottom: 1px solid #eee; vertical-align: top; }
th { font-weight: 600; color: #4a4a50; background: #fafafc; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tr:hover td { background: #fafafc; }
a.link { color: #0a66c2; text-decoration: none; }
a.link:hover { text-decoration: underline; }
code, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; color: #555; }
.muted { color: #6b6b70; }
.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eef2f6;
  font-size: 12px;
  color: #2a3340;
}
.tag.active { background: #e1f5e6; color: #1b6f30; }
.tag.error { background: #fde2e2; color: #8a1f1f;}
.tag.running { background: #e3edff; color: #1a3d8a; }
.tag.done { background: #e1f5e6; color: #1b6f30; }
.tag.stopped { background: #f3e8ff; color: #5a2d99; }
.tag.queued { background: #fff3d0; color: #7a5b00; }
.progress {
  height: 6px;
  background: #eef2f6;
  border-radius: 3px;
  overflow: hidden;
  margin-top: 6px;
}
.progress > span {
  display: block;
  height: 100%;
  background: #0a66c2;
  width: 0;
  transition: width 0.4s;
}
.creative-preview img, .creative-preview video {
  max-width: 320px; max-height: 320px; border-radius: 6px; border: 1px solid #e5e5ea;
}
.row { display: flex; gap: 16px; flex-wrap: wrap; }
.row > .col { flex: 1 1 280px; min-width: 280px; }
ul.urls { list-style: none; padding: 0; margin: 0; }
ul.urls li { padding: 6px 0; border-bottom: 1px solid #eee; word-break: break-all; }
ul.urls li:last-child { border-bottom: none; }
.statpills { display: flex; gap: 12px; flex-wrap: wrap; margin: 6px 0 14px; }
.statpills .pill { background: #fafafc; border: 1px solid #e5e5ea; border-radius: 6px; padding: 6px 10px; font-size: 13px; }
.statpills .pill b { display: block; font-size: 16px; }
.table-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.table-controls .filter-input {
  flex: 1 1 240px;
  min-width: 180px;
  max-width: 360px;
}
.table-controls .status-select { padding: 8px 12px; }
.table-controls .filter-count { font-size: 13px; }
th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable:hover { background: #f0f1f4; }
.th-arrow { color: #0a66c2; }
