:root {
  --brand: #0f766e;
  --brand-deep: #0b4f57;
  --accent: #2563eb;
  --accent-soft: #eff6ff;
  --sidebar: #111827;
  --sidebar-soft: #1f2937;
  --canvas: #f4f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --line: #d9e2ec;
  --line-strong: #c6d3df;
  --text: #111827;
  --muted: #667085;
  --success: #16803d;
  --danger: #d14343;
  --warning: #b7791f;
  --purple: #6d5bd0;
  --shadow: 0 10px 26px rgba(15, 23, 42, .08);
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html {
  background: var(--canvas);
}

body {
  margin: 0;
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
  font-size: 13px;
  color: var(--text);
  background: var(--canvas);
}

a {
  color: #0b65c2;
  text-decoration: none;
}

a:hover {
  color: #084b93;
}

.topbar {
  height: 64px;
  display: flex;
  align-items: center;
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 30;
  color: var(--text);
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 14px rgba(15, 23, 42, .06);
}

.brand {
  width: 260px;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 20px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand-deep), var(--brand));
  font-size: 18px;
  font-weight: 700;
  white-space: nowrap;
}

.brand:hover {
  color: #fff;
}

.brand i {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, .14);
  font-size: 18px;
}

.topbar-spacer {
  flex: 1;
}

.topbar-chip {
  height: 36px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: 10px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
}

.support {
  color: #0f4c5c;
  background: #e7f6f3;
  border: 1px solid #bee3dc;
}

.clock {
  color: #1f2937;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
}

.user-menu {
  position: relative;
  height: 64px;
  margin-right: 12px;
}

.user-chip {
  height: 42px;
  min-width: 194px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 11px;
  padding: 0 10px;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, .05);
}

.user-chip span {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--accent);
  font-size: 17px;
  font-weight: 700;
}

.user-chip small {
  line-height: 1.15;
  color: #475467;
  font-weight: 700;
}

.user-menu-button {
  border: 0;
}

.user-menu-button .bi-caret-down-fill {
  margin-left: auto;
  color: #98a2b3;
  font-size: 10px;
}

.user-menu-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: 58px;
  width: 245px;
  overflow: hidden;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, .18);
  z-index: 50;
}

.user-menu.open .user-menu-dropdown {
  display: block;
}

.user-menu-dropdown a,
.user-menu-dropdown button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 13px;
  border: 0;
  color: #344054;
  background: #fff;
  text-align: left;
  font-size: 13px;
  font-weight: 600;
}

.user-menu-dropdown a:hover,
.user-menu-dropdown button:hover {
  color: var(--brand-deep);
  background: #f0fdfa;
}

.user-menu-dropdown i {
  width: 17px;
  color: var(--brand);
}

.last-login {
  padding: 10px 13px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: #f8fafc;
  font-size: 12px;
  white-space: nowrap;
}

.sidebar {
  position: fixed;
  top: 64px;
  bottom: 0;
  left: 0;
  width: 260px;
  overflow: auto;
  z-index: 20;
  background: var(--sidebar);
  border-right: 1px solid rgba(255, 255, 255, .06);
  box-shadow: 7px 0 24px rgba(15, 23, 42, .08);
}

.sidebar::-webkit-scrollbar,
.table-wrap::-webkit-scrollbar,
.lead-log-dialog::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

.sidebar::-webkit-scrollbar-thumb,
.table-wrap::-webkit-scrollbar-thumb,
.lead-log-dialog::-webkit-scrollbar-thumb {
  background: #b8c3cf;
  border-radius: 999px;
}

.search {
  height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 0 16px;
  color: #94a3b8;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: #e5e7eb;
  background: transparent;
}

.search input::placeholder {
  color: #94a3b8;
}

.nav-row {
  min-height: 43px;
  display: flex;
  align-items: center;
  gap: 11px;
  margin: 4px 10px;
  padding: 0 12px;
  position: relative;
  color: #d5dce7;
  border: 0;
  border-radius: 8px;
  font-weight: 650;
}

.nav-row i:first-child {
  width: 22px;
  color: #9aa8bd;
  font-size: 17px;
  text-align: center;
}

.nav-row:hover {
  color: #fff;
  background: var(--sidebar-soft);
}

.nav-row:hover i:first-child {
  color: #fff;
}

.nav-row.active {
  color: #fff;
  background: var(--brand);
  box-shadow: inset 3px 0 0 rgba(255, 255, 255, .45);
}

.nav-row.active i:first-child {
  color: #fff;
}

.nav-row.active:after {
  display: none;
}

.nav-child {
  display: block;
  margin: 2px 10px 2px 44px;
  padding: 8px 10px;
  color: #bdc8d8;
  border: 0;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}

.nav-child:hover {
  color: #fff;
  background: rgba(255, 255, 255, .08);
}

.content {
  min-height: 100vh;
  margin-left: 260px;
  padding: 84px 24px 32px;
  background: var(--canvas);
}

.page-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  margin: 0 0 18px;
  padding: 0 0 12px;
  color: #155e75;
  border-bottom: 1px solid var(--line);
  font-size: 24px;
  font-weight: 650;
}

.page-title small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.page-title .float-end {
  margin-left: auto;
}

.panel,
.table-wrap,
.tabs,
.login-card,
.invoice-sheet {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel {
  overflow: hidden;
  margin-bottom: 16px;
}

.panel-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 9px 13px;
  color: #155e75;
  background: linear-gradient(#fff, #f8fafc);
  border-bottom: 1px solid var(--line);
  font-size: 16px;
  font-weight: 700;
}

.panel-heading .float-end {
  margin-left: auto;
}

.panel-body {
  padding: 16px;
}

.publisher-leadtype-heading {
  width: 100%;
  border: 0;
  text-align: left;
  cursor: pointer;
}

.publisher-leadtype-heading .bi {
  margin-left: 8px;
  transition: transform .16s ease;
}

.publisher-leadtype-panel.is-open .publisher-leadtype-heading .bi {
  transform: rotate(180deg);
}

.publisher-leadtype-summary {
  margin-left: auto;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
}

.publisher-leadtype-panel.is-collapsed {
  margin-bottom: 8px;
}

.form-box {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.form-box legend {
  float: none;
  width: auto;
  margin: 0 0 12px;
  padding: 0 7px;
  color: #1f2937;
  font-size: 19px;
  font-weight: 700;
}

.form-label {
  margin-bottom: 5px;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
}

.form-control,
.form-select {
  min-height: 34px;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: #1f2937;
  background-color: #fff;
  font-size: 13px;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.mini-input {
  width: 98px !important;
  display: inline-block;
}

.icon-button {
  border: 0;
  color: var(--accent);
  background: transparent;
  padding: 0;
}

.tabs {
  display: flex;
  overflow: auto;
  margin-bottom: 0;
  border-bottom: 0;
  box-shadow: none;
}

.tabs a {
  flex: 1;
  min-width: 160px;
  max-width: 360px;
  padding: 12px 14px;
  color: #667085;
  background: #f8fafc;
  border-right: 1px solid var(--line);
  font-weight: 700;
}

.tabs a.active {
  color: var(--brand-deep);
  background: #fff;
  box-shadow: inset 0 3px 0 var(--brand);
}

.btn {
  min-height: 34px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
}

.btn-sm,
.btn-mini {
  min-height: 26px;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
}

.btn-primary:hover {
  background: #1d4ed8;
  border-color: #1d4ed8;
}

.btn-danger {
  background: var(--danger);
  border-color: var(--danger);
}

.btn-purple {
  color: #fff;
  background: var(--purple);
  border-color: var(--purple);
}

.btn-green {
  color: #fff;
  background: var(--success);
  border-color: var(--success);
}

.btn-secondary {
  color: #fff;
  background: #64748b;
  border-color: #64748b;
}

.table-wrap {
  overflow: auto;
}

.data-table {
  margin: 0;
  color: #1f2937;
  font-size: 12px;
}

.data-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  white-space: nowrap;
  color: #475467;
  background: #f8fafc;
  border-color: var(--line);
  font-weight: 800;
}

.data-table td {
  vertical-align: top;
  border-color: var(--line);
}

.data-table tbody tr:hover td {
  background: #f8fbff;
}

.pager {
  padding: 9px 10px;
  color: #475467;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-top: 0;
}

.toggle {
  min-width: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 3px 8px;
  color: #fff;
  background: var(--accent);
  border: 0;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
}

.toggle.off {
  background: #98a2b3;
}

.toggle-action {
  cursor: pointer;
}

.toggle-action.loading {
  opacity: .65;
}

.action-icons i {
  margin-right: 6px;
  font-size: 14px;
}

.status-ribbon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 72px;
  padding: 4px 10px;
  color: #fff;
  background: var(--success);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.15;
}

.status-ribbon:before,
.status-ribbon:after {
  display: none;
}

.status-ribbon.off {
  background: #98a2b3;
}

.status-ribbon.failed,
.status-ribbon.rejected {
  background: var(--danger);
}

.status-ribbon.uploaded {
  background: var(--accent);
}

.editor-toolbar {
  min-height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 5px;
  background: #eef2f7;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
}

.editor-toolbar button {
  min-width: 28px;
  height: 25px;
  border: 0;
  border-radius: 5px;
  color: #fff;
  background: var(--accent);
  font-weight: 800;
}

.email-template {
  min-height: 238px;
  resize: vertical;
  background: #fbfdff;
  border-radius: 0 0 6px 6px;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
  gap: 14px;
}

.stat {
  padding: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.stat strong {
  display: block;
  font-size: 22px;
}

.welcome {
  margin-bottom: 18px;
  padding: 13px 16px;
  color: #166534;
  background: #dcfce7;
  border: 1px solid #bbf7d0;
  border-radius: 8px;
  text-align: center;
  font-size: 17px;
  font-weight: 700;
}

.dashboard-narrow {
  max-width: 920px;
}

.dashboard-panel {
  min-height: 92px;
}

.report-row {
  font-size: 16px;
}

.report-row div div {
  margin-bottom: 12px;
}

.report-row span,
.report-row a {
  font-size: 16px;
}

.code-editor {
  width: 100%;
  min-height: 320px;
  padding: 14px;
  color: #e5e7eb;
  background: #0b1220;
  border: 1px solid #253047;
  border-radius: 8px;
  font-family: Consolas, monospace;
}

.warning {
  color: var(--danger);
  font-size: 12px;
}

.spec-code {
  min-height: 110px;
  padding: 12px;
  white-space: pre-wrap;
  color: #334155;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 6px;
  font-family: Consolas, monospace;
  font-size: 12px;
}

.field-builder td,
.iframe-field-table td {
  vertical-align: middle;
  background: #f8fafc;
}

.field-builder .form-control,
.field-builder .form-select {
  min-height: 28px;
  padding: 3px 7px;
  font-size: 11px;
}

.field-builder .options-box {
  min-height: 32px;
  height: 32px;
}

.field-builder .drag-cell {
  width: 30px;
  text-align: center;
}

.drag-handle {
  border: 0;
  color: #64748b;
  background: transparent;
  cursor: grab;
  padding: 0 4px;
}

.is-reordering,
.is-reordering * {
  cursor: grabbing !important;
  user-select: none;
}

.field-builder tr.dragging {
  opacity: .45;
  outline: 1px dashed var(--accent);
}

.field-builder .order-input {
  width: 58px;
}

.field-add-band {
  padding: 9px;
  text-align: center;
  background: #e0f2fe;
  border-radius: 6px;
}

.iframe-field-table code {
  font-size: 11px;
}

.step-picker {
  min-width: 250px;
}

.step-picker label {
  margin-right: 9px;
  white-space: nowrap;
  font-size: 11px;
}

.option-editor {
  min-width: 360px;
}

.option-line {
  display: grid;
  grid-template-columns: 1fr 1fr 78px;
  gap: 4px;
  margin-bottom: 4px;
}

.option-toggle {
  min-width: 92px;
}

.btn-mini {
  padding: 0 7px;
  font-size: 12px;
  line-height: 1;
}

.code-copy {
  min-height: 120px;
  font-family: Consolas, monospace;
  background: #f8fafc;
}

.filter-pill {
  min-height: 34px;
  margin-bottom: 5px;
  padding: 7px 9px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.campaign-filter-box {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.publisher-map-row {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 110px 110px 120px;
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}

.response-preview {
  padding: 18px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.response-preview pre {
  padding: 12px;
  white-space: pre-wrap;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.campaign-general label,
.publisher-map-row label {
  font-size: 13px;
}

.auth-screen {
  background: linear-gradient(135deg, #ecfeff, #f8fafc);
}

.login-card {
  max-width: 430px;
  margin: 10vh auto;
  padding: 26px;
}

.login-brand {
  margin-bottom: 18px;
  color: var(--brand-deep);
  font-size: 26px;
  font-weight: 800;
}

.ping-tree-map-grid {
  display: grid;
  grid-template-columns: minmax(420px, 1fr) minmax(360px, .72fr);
  gap: 24px;
}

.ping-tree-column {
  min-height: 560px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.ping-tree-column-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  background: #f8fafc;
  border-bottom: 1px solid var(--line);
}

.ping-tree-column-head h3 {
  margin: 0;
  color: #155e75;
  font-size: 18px;
  font-weight: 750;
  white-space: nowrap;
}

.ping-search {
  max-width: 230px;
  margin-left: auto;
}

.round-robin-toggle {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: #475467;
  font-size: 13px;
  white-space: nowrap;
}

.round-robin-toggle input {
  display: none;
}

.routing-mode-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--line);
}

.routing-mode-row .form-select {
  max-width: 230px;
}

.ping-drop-zone {
  min-height: 475px;
  padding: 12px;
  overflow: auto;
}

.active-zone {
  margin: 8px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
}

.inactive-zone {
  max-height: 520px;
}

.ping-buyer-group {
  margin-bottom: 16px;
  padding: 9px;
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
}

.ping-buyer-group h4 {
  margin: 0 0 9px;
  font-size: 17px;
  font-weight: 700;
}

.ping-campaign-card {
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  padding: 11px 12px;
  cursor: grab;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 2px 9px rgba(15, 23, 42, .04);
}

.ping-campaign-card.dragging {
  opacity: .45;
  border-style: dashed;
}

.ping-campaign-card .drag-icon {
  color: #334155;
  font-size: 18px;
}

.ping-campaign-card .badge {
  font-size: 11px;
}

.save-band {
  margin-top: 16px;
  padding: 20px;
  background: #eef2f7;
  border-radius: 8px;
}

.section-title {
  margin: 24px 0 14px;
  padding-bottom: 9px;
  color: #15803d;
  border-bottom: 1px solid #bbf7d0;
  font-size: 21px;
  font-weight: 700;
}

.report-total td,
.report-total {
  color: #15803d;
  font-size: 18px;
}

.report-summary-grid {
  display: grid;
  grid-template-columns: minmax(360px, 680px) 1fr;
  gap: 36px;
  align-items: start;
}

.report-pie-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 62px;
  padding: 18px 20px 8px;
}

.report-pie {
  width: 240px;
  height: 180px;
  border-radius: 50%;
  background: conic-gradient(#65a30d 0 45%, #dc2626 45% 100%);
  border: 1px solid #e2e8f0;
  transform: scaleY(.68);
}

.report-legend {
  display: grid;
  gap: 18px;
  font-size: 12px;
}

.legend {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
}

.legend.accepted { background: #65a30d; }
.legend.rejected { background: #dc2626; }
.legend.pending { background: #f59e0b; }
.legend.returned { background: #7c3aed; }

.report-total-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 0 12px 10px;
  border-top: 1px solid var(--line);
}

.report-total-row div {
  padding: 9px 10px;
  border-right: 1px solid var(--line);
}

.report-total-row strong {
  display: block;
  margin-top: 5px;
  font-size: 18px;
  font-weight: 600;
}

.report-bars {
  height: 310px;
  display: flex;
  align-items: end;
  gap: 20px;
  padding: 42px 30px 28px;
  position: relative;
}

.report-bars h4 {
  position: absolute;
  top: 12px;
  left: 16px;
  font-size: 16px;
  font-weight: 700;
}

.report-bar {
  width: 110px;
  align-self: end;
  position: relative;
  background: #0e7490;
  border-radius: 6px 6px 0 0;
}

.report-bar span {
  position: absolute;
  top: -22px;
  left: 0;
  right: 0;
  text-align: center;
}

.lead-list-table th,
.lead-list-table td {
  white-space: nowrap;
}

.lead-log-dialog {
  padding: 88px 18px 18px;
}

.lead-log-content {
  min-height: 70vh;
  position: relative;
  border-radius: 8px;
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, .62);
}

.lead-modal-close,
.lead-modal-close.inner {
  width: 30px;
  height: 30px;
  position: absolute;
  right: -13px;
  top: -14px;
  z-index: 10;
  color: #fff;
  background: #0f172a;
  border: 2px solid #fff;
  border-radius: 50%;
  line-height: 24px;
  font-size: 23px;
}

.lead-log-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
  margin: 4px 0 14px;
  padding: 14px 16px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.lead-log-eyebrow {
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.lead-log-header h2 {
  margin: 2px 0;
  font-size: 22px;
}

.lead-log-subtitle {
  color: #64748b;
  font-size: 13px;
}

.lead-log-status {
  min-width: 120px;
  position: relative;
  display: flex;
  justify-content: flex-end;
}

.lead-log-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  color: #854d0e;
  background: #fef3c7;
  border: 1px solid #fde68a;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.lead-log-pill.success {
  color: #166534;
  background: #dcfce7;
  border-color: #bbf7d0;
}

.lead-log-pill.danger {
  color: #991b1b;
  background: #fee2e2;
  border-color: #fecaca;
}

.lead-log-summary,
.lead-log-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.lead-log-summary {
  margin-bottom: 14px;
}

.lead-log-summary div,
.lead-log-grid div {
  min-width: 0;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 7px;
}

.lead-log-summary span,
.lead-log-grid span,
.lead-log-code-block span {
  display: block;
  margin-bottom: 3px;
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.lead-log-summary strong,
.lead-log-grid strong {
  display: block;
  overflow-wrap: anywhere;
  font-size: 13px;
}

.lead-log-tabs {
  display: flex;
  margin-bottom: 0;
  border-bottom: 1px solid var(--line);
}

.lead-log-tabs button {
  padding: 9px 13px;
  color: #667085;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-bottom: 0;
  font-size: 12px;
  font-weight: 700;
}

.lead-log-tabs button.active {
  color: var(--brand-deep);
  background: #fff;
  box-shadow: inset 0 3px 0 var(--brand);
}

.lead-tab-panel {
  display: none;
  padding: 14px 12px;
  border: 1px solid var(--line);
  border-top: 0;
}

.lead-tab-panel.active {
  display: block;
}

.lead-info-table th {
  width: 260px;
}

.lead-info-table th,
.lead-info-table td {
  padding: 9px 8px;
}

.lead-info-table code {
  max-width: 100%;
  display: inline-block;
  padding: 3px 5px;
  white-space: pre-wrap;
  word-break: break-word;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 5px;
}

.lead-log-card {
  margin-bottom: 14px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.lead-log-card-title {
  margin-bottom: 10px;
  color: var(--brand-deep);
  font-size: 15px;
  font-weight: 800;
}

.lead-log-code-block {
  margin-top: 10px;
}

.lead-log-code-block code {
  display: block;
  max-height: 180px;
  overflow: auto;
  padding: 8px;
  white-space: pre-wrap;
  word-break: break-word;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.buyer-log-table th:nth-child(4),
.buyer-log-table td:nth-child(4) {
  min-width: 620px;
}

.buyer-post-detail {
  line-height: 1.75;
}

.buyer-post-detail code {
  display: inline-block;
  max-width: 100%;
  padding: 2px 4px;
  vertical-align: top;
  white-space: pre-wrap;
  word-break: break-word;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 4px;
}

.attempt-inline-log > td {
  padding: 0;
  background: #fff;
}

.attempt-inline-table {
  margin: 0;
  border: 1px solid #d8dde3;
  border-top: 0;
}

.attempt-inline-table th {
  width: 270px;
  padding: 9px 8px;
  font-size: 12px;
  font-weight: 700;
  vertical-align: top;
}

.attempt-inline-table td {
  padding: 9px 8px;
  font-size: 12px;
  vertical-align: top;
}

.attempt-inline-table code {
  display: inline-block;
  max-width: 100%;
  max-height: 74px;
  overflow: auto;
  padding: 2px 4px;
  white-space: pre-wrap;
  word-break: break-word;
}

.lead-log-description {
  margin-top: 10px;
  color: #475569;
  font-size: 13px;
}

@media (max-width: 1100px) {
  .lead-log-summary,
  .lead-log-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .lead-log-header {
    flex-direction: column;
  }
  .lead-log-summary,
  .lead-log-grid {
    grid-template-columns: 1fr;
  }
}

body.publisher-portal {
  --publisher-blue: #3f91b8;
  --publisher-link: #006dcc;
  --publisher-green: #2f8d65;
  --publisher-purple: #8b78bd;
  background: #fff;
  font-family: "Segoe UI", Arial, sans-serif;
  font-size: 13px;
}

body.publisher-portal .topbar {
  height: 48px;
  color: #fff;
  background: var(--publisher-blue);
  border: 0;
  box-shadow: none;
}

body.publisher-portal .brand {
  width: 189px;
  height: 48px;
  padding: 0 20px;
  background: var(--publisher-blue);
  font-size: 21px;
  font-weight: 300;
}

body.publisher-portal .brand i {
  width: auto;
  height: auto;
  background: transparent;
}

body.publisher-portal .topbar-chip {
  height: 48px;
  margin: 0;
  border: 0;
  border-radius: 0;
  color: #fff;
  font-weight: 700;
}

body.publisher-portal .support {
  background: #92276b;
}

body.publisher-portal .clock {
  background: var(--publisher-green);
}

body.publisher-portal .user-menu {
  height: 48px;
  margin: 0;
  background: #6cb1df;
}

body.publisher-portal .user-chip {
  height: 48px;
  min-width: 158px;
  margin: 0;
  border: 0;
  border-radius: 0;
  color: #fff;
  background: transparent;
  box-shadow: none;
}

body.publisher-portal .user-chip span {
  width: 44px;
  height: 44px;
  color: #3f91b8;
  background: #fff;
}

body.publisher-portal .user-chip small,
body.publisher-portal .user-menu-button .bi-caret-down-fill {
  color: #fff;
}

body.publisher-portal .sidebar {
  top: 48px;
  width: 189px;
  background: #f5f5f5;
  border-right: 1px solid #d8d8d8;
  box-shadow: none;
}

body.publisher-portal .search {
  height: 44px;
  background: #fff;
  border-bottom: 1px solid #d9d9d9;
}

body.publisher-portal .search input {
  background: #fff;
}

body.publisher-portal .nav-row {
  height: 37px;
  margin: 0;
  padding: 0 13px;
  color: #4a4a4a;
  background: #f8f8f8;
  border-bottom: 1px solid #ddd;
  border-radius: 0;
  font-weight: 400;
}

body.publisher-portal .nav-row:hover,
body.publisher-portal .nav-row.active {
  color: #006dcc;
  background: #fff;
  box-shadow: inset -4px 0 0 #087bd3;
}

body.publisher-portal .nav-row i:first-child {
  color: inherit;
}

body.publisher-portal .nav-child {
  margin: 0;
  padding: 10px 12px 10px 36px;
  color: #444;
  background: #fff;
  border-left: 1px solid #bad2e5;
  border-bottom: 1px dotted #ddd;
  border-radius: 0;
  font-weight: 400;
}

body.publisher-portal .nav-child:hover {
  color: #006dcc;
}

body.publisher-portal .content {
  margin-left: 189px;
  padding: 60px 20px 30px;
  background: #fff;
}

body.publisher-portal .page-title {
  margin: 0 0 14px;
  padding: 0 0 14px;
  color: #1f7fcd;
  border-bottom: 1px dotted #d8d8d8;
  font-size: 24px;
  font-weight: 300;
}

body.publisher-portal .page-title small {
  color: #667085;
  font-size: 14px;
}

body.publisher-portal .publisher-welcome {
  margin-bottom: 20px;
  padding: 12px 16px;
  color: #3d902e;
  background: #dff2d8;
  border: 1px solid #d3eacb;
  text-align: center;
  font-size: 18px;
}

body.publisher-portal .publisher-welcome span {
  float: right;
  color: #a2b69b;
  font-weight: 700;
}

body.publisher-portal .publisher-card {
  margin-bottom: 10px;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
}

body.publisher-portal .publisher-card-half {
  width: 49%;
  min-width: 600px;
}

body.publisher-portal .publisher-card-heading {
  display: flex;
  justify-content: space-between;
  padding: 12px 10px 9px;
  border-bottom: 1px solid #ccc;
  font-size: 16px;
}

body.publisher-portal .publisher-card-heading span {
  color: #7d8792;
  font-size: 12px;
}

body.publisher-portal .publisher-card-body {
  padding: 13px 10px 20px;
  font-size: 16px;
}

body.publisher-portal .publisher-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 12px 10px 20px;
}

body.publisher-portal .publisher-stats-row span,
body.publisher-portal .publisher-stats-row strong {
  display: block;
  font-size: 16px;
  font-weight: 400;
}

body.publisher-portal .publisher-filter-row {
  display: grid;
  grid-template-columns: 1fr 1.7fr 1.7fr auto;
  gap: 44px;
  align-items: end;
  margin-bottom: 20px;
}

body.publisher-portal .publisher-filter-row.short {
  grid-template-columns: 390px 390px auto;
}

body.publisher-portal .form-control,
body.publisher-portal .form-select {
  height: 30px;
  border-radius: 3px;
  border-color: #bbb;
  font-size: 12px;
}

body.publisher-portal .btn {
  border: 0;
  border-radius: 0;
  font-size: 13px;
}

body.publisher-portal .btn-green {
  color: #fff;
  background: #78ad6e;
}

body.publisher-portal .btn-purple {
  color: #fff;
  background: var(--publisher-purple);
}

body.publisher-portal .btn-primary {
  background: #087bd3;
}

body.publisher-portal .publisher-table-wrap {
  padding: 5px;
  background: #fff;
  border: 1px solid #ddd;
}

body.publisher-portal .data-table {
  margin: 0;
}

body.publisher-portal .data-table th {
  padding: 9px 8px;
  color: #666;
  background: linear-gradient(#f6f6f6, #e9e9e9);
  border: 1px solid #ddd;
}

body.publisher-portal .data-table td {
  padding: 10px 8px;
  border: 1px solid #ddd;
}

body.publisher-portal .pager {
  margin-top: 0;
  padding: 8px;
  background: #edf3f8;
  border-top: 1px solid #d5dde5;
}

body.publisher-portal .publisher-section-title {
  margin: 28px 0 14px;
  padding-bottom: 6px;
  color: #49a336;
  border-bottom: 1px solid #b7ddb0;
  font-size: 23px;
  font-weight: 300;
}

body.publisher-portal .publisher-upload-box {
  border: 1px solid #cfcfcf;
}

body.publisher-portal .publisher-upload-heading {
  display: flex;
  justify-content: space-between;
  padding: 8px 13px;
  color: #4d9ad1;
  background: linear-gradient(#f6f6f6, #e8e8e8);
  border-bottom: 1px solid #cfcfcf;
  font-size: 18px;
}

body.publisher-portal .publisher-upload-body {
  padding: 14px;
  font-size: 16px;
  line-height: 1.65;
}

body.publisher-portal .publisher-small-select {
  width: 385px;
}

body.publisher-portal .publisher-action-bar {
  margin-top: 22px;
  padding: 20px;
  background: #f4f4f4;
}

.lead-attempt-overlay {
  position: absolute;
  inset: 22px;
  z-index: 9;
  overflow: auto;
  padding: 36px 26px;
  background: rgba(15, 23, 42, .72);
}

.lead-attempt-shell {
  min-height: 320px;
  position: relative;
  padding: 14px;
  background: #fff;
  border-radius: 8px;
}

.lead-edit-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 14px 42px;
}

.lead-edit-grid .form-control,
.lead-edit-grid .form-select {
  max-width: 235px;
}

.lead-edit-grid textarea.form-control {
  max-width: 100%;
}

.lead-form-flags {
  grid-column: 1 / -1;
  display: flex;
  gap: 28px;
  align-items: center;
}

.lead-form-flags label {
  margin: 0;
  font-size: 13px;
}

.invoice-sheet {
  max-width: 1140px;
  margin: 0 auto;
  padding: 28px;
}

.invoice-sheet h1 {
  margin: 0 0 18px;
  text-align: center;
  font-size: 30px;
  font-weight: 800;
}

.invoice-sheet .invoice-actions {
  margin-bottom: 12px;
  text-align: right;
}

.invoice-address-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  margin: 22px 0;
}

.invoice-address-grid > div:last-child {
  max-width: 360px;
  margin-left: auto;
  text-align: left;
}

.invoice-totals td:first-child {
  text-align: right;
  font-weight: 700;
}

.invoice-totals td:last-child {
  text-align: right;
}

.simple-heading {
  margin: 22px 0 14px;
  font-size: 28px;
  font-weight: 650;
}

.account-lines p {
  margin-bottom: 12px;
}

.membership-note {
  color: #15803d;
  font-size: 25px;
}

.settings-panel {
  margin-bottom: 12px;
}

.settings-panel .panel-heading {
  font-size: 13px;
}

.settings-group-title {
  margin: 14px 0 6px;
  color: #344054;
  font-size: 16px;
  font-weight: 700;
}

.integration-test-result {
  word-break: break-word;
  font-size: 12px;
  line-height: 28px;
}

.settings-panel .form-text {
  color: #777;
  font-size: 12px;
}

@media (max-width: 1100px) {
  .ping-tree-map-grid,
  .report-summary-grid,
  .lead-edit-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .ping-tree-column {
    min-height: 360px;
  }
}

@media (max-width: 900px) {
  .brand {
    width: 74px;
    padding: 0 20px;
  }

  .brand i {
    flex: 0 0 auto;
  }

  .brand {
    font-size: 0;
  }

  .sidebar {
    width: 74px;
  }

  .search {
    justify-content: center;
  }

  .search input,
  .nav-row span,
  .nav-child,
  .support,
  .user-chip small {
    display: none;
  }

  .nav-row {
    justify-content: center;
    padding: 0;
  }

  .nav-row i:first-child {
    width: auto;
  }

  .content {
    margin-left: 74px;
    padding: 82px 14px 24px;
  }

  .topbar-chip {
    font-size: 11px;
  }

  .user-chip {
    min-width: 50px;
  }

  .tabs a {
    min-width: 170px;
  }
}
