:root {
  font:
    16px/1.48 Inter,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    sans-serif;
  color: #202332;
  background: #f5f5fa;
  --purple: #6443d2;
  --border: #e2e2ec;
  --dim: #616378;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
aside {
  position: fixed;
  inset: 0 auto 0 0;
  width: 220px;
  padding: 32px 16px;
  background: #1c1c31;
  color: white;
  display: flex;
  flex-direction: column;
}
.brand {
  --brand-title: #f4f2fb;
  --brand-subtitle: #b6b4ca;
  --brand-title-hover: #74b4ff;
  --brand-subtitle-hover: #a6dcff;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px 30px;
  text-decoration: none;
}
.brand-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  overflow: hidden;
  border-radius: 9px;
  background: #8bd6e5;
  transition: background-color 160ms ease;
}
.brand-icon img {
  grid-area: 1 / 1;
  display: block;
  height: auto;
  transition: opacity 160ms ease;
}
.brand-icon-default {
  width: 100%;
}
.brand-icon-hover {
  width: 84%;
  opacity: 0;
  /* Hide the PANEL badge in the full logo asset. */
  clip-path: polygon(0 0, 100% 0, 100% 66%, 65% 66%, 65% 100%, 0 100%);
}
.brand-name {
  color: var(--brand-subtitle);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  transition: color 160ms ease;
}
.brand-name strong {
  color: var(--brand-title);
  font-size: 19px;
  font-weight: 750;
  transition: color 160ms ease;
}
.brand:is(:hover, :focus-visible) .brand-icon {
  background: #e1f1fb;
}
.brand:is(:hover, :focus-visible) .brand-icon-default {
  opacity: 0;
}
.brand:is(:hover, :focus-visible) .brand-icon-hover {
  opacity: 1;
}
.brand:is(:hover, :focus-visible) .brand-name {
  color: var(--brand-subtitle-hover);
}
.brand:is(:hover, :focus-visible) .brand-name strong {
  color: var(--brand-title-hover);
}
@media (prefers-reduced-motion: reduce) {
  .brand :is(.brand-icon, img, .brand-name, strong) {
    transition: none;
  }
}
nav {
  display: grid;
  gap: 5px;
}
nav a {
  padding: 11px 13px;
  border-radius: 8px;
  color: #c9c8d8;
  text-decoration: none;
  font-size: 15px;
  display: flex;
  gap: 12px;
  align-items: center;
}
nav a:hover {
  background: #2e2c44;
  color: white;
}
nav a[aria-current='page'] {
  background: #413656;
  color: #f4edff;
  font-weight: 650;
}
nav a span {
  font:
    18px/1.1 ui-monospace,
    monospace;
  width: 22px;
  text-align: center;
  color: #c5b7ef;
}
nav a:nth-last-child(2) {
  margin-top: 24px;
}
.identity {
  margin-top: auto;
  border-top: 1px solid #39384b;
  padding: 20px 8px 0;
  display: flex;
  align-items: center;
  gap: 12px;
}
.identity small,
.identity strong {
  display: block;
}
.identity small {
  color: #b6b4ca;
  font-size: 13px;
}
.avatar {
  width: 36px;
  height: 36px;
  background: #3e3957;
  border: 1px solid #58516f;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 650;
}
main {
  margin-left: 220px;
}
header {
  min-height: 64px;
  padding: 12px clamp(18px, 3vw, 42px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--border);
  background: #fff;
  font-size: 14px;
  color: var(--dim);
}
header i {
  margin: 0 9px;
  color: #b2afbe;
}
header > div,
.row,
.controls,
.sectionTitle,
.titleRow,
.kpiGrid,
.seg {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mode,
.pill {
  display: inline-block;
  border: 1px solid #dcd4fa;
  color: #6444ae;
  background: #f4efff;
  border-radius: 20px;
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 600;
}
.workspace {
  max-width: 1800px;
  margin: auto;
  padding: 30px clamp(18px, 3vw, 42px) 48px;
}
.titleRow,
.sectionTitle {
  justify-content: space-between;
}
.titleRow {
  margin-bottom: 22px;
  flex-wrap: wrap;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: clamp(30px, 3.2vw, 43px);
  letter-spacing: -0.048em;
  font-weight: 710;
}
h2 {
  font-size: 21px;
  letter-spacing: -0.035em;
}
h3 {
  font-size: 16px;
}
.muted,
.help {
  color: var(--dim);
  font-size: 14px;
}
.help {
  margin: 6px 0 12px;
}
.controls {
  flex-wrap: wrap;
  margin: 10px 0 20px;
}
button,
input,
select {
  font: inherit;
  font-size: 14px;
  color: inherit;
}
button,
select,
input {
  border: 1px solid #d8d8e4;
  background: white;
  border-radius: 8px;
  padding: 8px 11px;
  min-height: 38px;
}
button {
  cursor: pointer;
  font-weight: 580;
}
button:hover {
  border-color: #a99aca;
  background: #f6f3ff;
}
button:disabled {
  cursor: wait;
  opacity: 0.62;
}
.primary {
  background: var(--purple);
  border-color: var(--purple);
  color: #fff;
}
.primary:hover {
  background: #5235b4;
  color: white;
}
.flat {
  background: transparent;
  border-color: transparent;
  color: var(--purple);
}
button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible {
  outline: 3px solid #a990fb;
  outline-offset: 2px;
}
.kpiGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: 18px;
  gap: 12px;
}
.kpi,
.panel {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
}
.kpi {
  padding: 17px 20px;
}
.kpi span {
  display: block;
  font-size: 14px;
  color: var(--dim);
}
.kpi strong {
  display: block;
  font-weight: 650;
  font-size: clamp(23px, 2.25vw, 34px);
  letter-spacing: -0.055em;
  margin-top: 7px;
  font-variant-numeric: tabular-nums;
}
.kpi:first-child {
  background: #302745;
  border-color: #302745;
  color: #fff;
}
.kpi:first-child span {
  color: #d8cee7;
}
.panel {
  margin-bottom: 17px;
  padding: 19px 20px;
}
.panel.scroll {
  padding: 0;
  overflow: hidden;
}
.panel .sectionTitle {
  margin-bottom: 12px;
}
.scroll .sectionTitle {
  padding: 16px 18px 0;
}
.sectionTitle {
  gap: 12px;
  flex-wrap: wrap;
}
.bars {
  height: 94px;
  display: flex;
  align-items: flex-end;
  gap: clamp(2px, 0.5vw, 8px);
  padding: 8px 0 2px;
  border-bottom: 1px solid #d8d3e4;
}
.bars div {
  flex: 1;
  min-width: 1px;
  margin: 0;
  background: #c3afea;
  border-radius: 4px 4px 0 0;
  max-width: 90px;
}
.bars div:last-child {
  background: #6944be;
}
.axis {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
  color: var(--dim);
  font-size: 12px;
}
.seg {
  gap: 2px;
  padding: 3px;
  border: 1px solid #e2dfeb;
  background: #f4f3f8;
  border-radius: 10px;
  display: inline-flex;
  flex-wrap: wrap;
}
.seg button {
  min-height: 31px;
  padding: 4px 9px;
  border: 0;
  background: transparent;
  color: var(--dim);
}
.seg button[aria-pressed='true'] {
  color: #5834af;
  background: white;
  box-shadow: 0 1px 3px #29223e24;
}
.tableBox {
  overflow: auto;
}
.tableBox table {
  min-width: 590px;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;
}
th,
td {
  padding: 12px 16px;
  text-align: left;
  white-space: nowrap;
  border-top: 1px solid #ecebf2;
}
td {
  font-variant-numeric: tabular-nums;
}
th {
  color: #5c5c72;
  background: #faf9fc;
  font-weight: 580;
  font-size: 13px;
}
td:first-child {
  font-weight: 560;
}
td.number,
th.number {
  text-align: right;
}
.geo-heat[data-tone]:not([data-tone=""]) {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--geo-heat-bg);
  color: var(--geo-heat-text);
}
.geo-heat[data-tone="better"] {
  --geo-heat-bg: #edf7ee;
  --geo-heat-text: #256047;
}
.geo-heat[data-tone="better-strong"] {
  --geo-heat-bg: #d0efdc;
  --geo-heat-text: #095e39;
  font-weight: 650;
}
.geo-heat[data-tone="worse"] {
  --geo-heat-bg: #fff2cd;
  --geo-heat-text: #765000;
}
.geo-heat[data-tone="worse-strong"] {
  --geo-heat-bg: #fae0e5;
  --geo-heat-text: #9b1831;
  font-weight: 650;
}
.geo-heat[data-palette="contrast"][data-tone="better"] {
  --geo-heat-bg: #eaf3fb;
  --geo-heat-text: #27577c;
}
.geo-heat[data-palette="contrast"][data-tone="better-strong"] {
  --geo-heat-bg: #d2e9fd;
  --geo-heat-text: #0c4d82;
}
.geo-heat[data-palette="contrast"][data-tone="worse"] {
  --geo-heat-bg: #fff1df;
  --geo-heat-text: #814516;
}
.geo-heat[data-palette="contrast"][data-tone="worse-strong"] {
  --geo-heat-bg: #ffdec4;
  --geo-heat-text: #873b09;
}
.empty {
  padding: 22px;
  color: var(--dim);
}
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 14px;
}
.cards .panel {
  margin: 0;
}
.cards p {
  margin: 6px 0 12px;
}
.gridform {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 14px;
}
.gridform label,
.stack label {
  display: grid;
  gap: 4px;
  font-size: 14px;
  font-weight: 550;
}
.gridform input,
.gridform select,
.stack input,
.stack select {
  width: 100%;
  min-width: 0;
}
.stack {
  display: grid;
  gap: 12px;
}
.span {
  grid-column: 1/-1;
}
.row {
  flex-wrap: wrap;
}
.actions {
  margin-top: 16px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.err {
  color: #a33232;
  margin-top: 10px;
}
dialog {
  width: min(610px, 94vw);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: 0 18px 90px #100e2d29;
  padding: 22px;
  max-height: 86vh;
  overflow: auto;
}
dialog::backdrop {
  background: #15132677;
}
.dialogTop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}
.dialogTop button {
  font-size: 21px;
  line-height: 1;
}
pre {
  white-space: pre-wrap;
  word-break: break-word;
  background: #f5f4f8;
  border-radius: 8px;
  padding: 12px;
  font-size: 13px;
}
#notice {
  position: fixed;
  bottom: 20px;
  right: 20px;
  max-width: 460px;
  z-index: 10;
  background: #252239;
  color: white;
  border-radius: 10px;
  padding: 13px 17px;
  box-shadow: 0 5px 22px #211d3226;
}
#content input[type='search'] {
  max-width: 230px;
}
.code {
  font-family: ui-monospace, monospace;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
@media (max-width: 900px) {
  aside {
    width: 168px;
    padding: 25px 9px;
  }
  main {
    margin-left: 168px;
  }
  .kpiGrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .workspace {
    padding-top: 22px;
  }
}
@media (max-width: 650px) {
  aside {
    position: static;
    width: auto;
    padding: 10px;
    gap: 8px;
  }
  .brand {
    padding: 0 5px;
  }
  .identity {
    display: none;
  }
  nav {
    display: flex;
    overflow-x: auto;
    gap: 2px;
  }
  nav a {
    white-space: nowrap;
    padding: 7px 9px;
    font-size: 14px;
  }
  nav a span {
    display: none;
  }
  nav a:nth-last-child(2) {
    margin: 0;
  }
  main {
    margin: 0;
  }
  header {
    padding: 8px 14px;
    min-height: 48px;
  }
  header > span {
    display: none;
  }
  header > div {
    justify-content: space-between;
    width: 100%;
  }
  .workspace {
    padding: 18px 12px;
  }
  .panel {
    padding: 15px;
  }
  .controls {
    gap: 6px;
  }
  .gridform {
    grid-template-columns: 1fr;
  }
  .row {
    align-items: stretch;
  }
  .kpi {
    padding: 12px 14px;
  }
}
