@font-face { font-family: Ubuntu; font-style: normal; font-weight: 300; font-display: swap; src: url(fonts/ubuntu-latin-300.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 300; font-display: swap; src: url(fonts/ubuntu-latin-ext-300.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/ubuntu-latin-400.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 400; font-display: swap; src: url(fonts/ubuntu-latin-ext-400.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/ubuntu-latin-500.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/ubuntu-latin-ext-500.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/ubuntu-latin-700.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: Ubuntu; font-style: normal; font-weight: 700; font-display: swap; src: url(fonts/ubuntu-latin-ext-700.woff2) format("woff2"); unicode-range: U+0100-02AF, U+0304, U+0308, U+0329, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
:root {
  color-scheme: light;
  /* Identidade ip77: azul Digital #0A4A80 · verde Humana #009999 · fonte Ubuntu */
  --brand: #0A4A80; --brand-2: #009999; --brand-deep: #06182E;
  --bg: #f3f6f9; --surface: #ffffff; --surface-2: #edf2f7; --surface-3: #e2e9f1; --line: #dde5ee; --line-2: #c8d4e1;
  --text: #0b1b2e; --text-2: #4a5b70; --text-3: #73839a;
  --accent: #0A4A80; --accent-ink: #fff; --accent-soft: #e4eef8; --teal: #009999; --teal-soft: #e0f3f3;
  --good: #0a7d3a; --good-soft: #e3f4ea; --bad: #c0392b; --bad-soft: #fbe9e7; --warn: #a86b00; --warn-soft: #fdf2dc;
  --s1: #0A4A80; --s2: #eb6834; --s3: #009999; --s4: #eda100; --s5: #e87ba4; --s6: #008300; --s7: #6250d6; --s8: #e34948;
  --seq: #0A4A80;
  --other: #c5ced8; --other-strong: #8a97a6;
  --side-bg: linear-gradient(180deg, #0A4A80 0%, #083a66 55%, #06182E 100%);
  --radius: 10px; --shadow: 0 1px 2px rgba(10,74,128,.05), 0 2px 8px rgba(10,74,128,.05);
  font-family: Ubuntu, "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #06182E; --surface: #0C2644; --surface-2: #11304f; --surface-3: #173a5e; --line: #1C3B60; --line-2: #2a4d75;
    --text: #E8F0F7; --text-2: #A9BCD1; --text-3: #7f95ad;
    --accent: #4F9AD9; --accent-ink: #06182E; --accent-soft: #123a62; --teal: #21B8B8; --teal-soft: #0d3a44;
    --good: #4cc27b; --good-soft: #12302a; --bad: #ef7466; --bad-soft: #3a1d22; --warn: #e3a738; --warn-soft: #33290f;
    --s1: #4F9AD9; --s2: #d95926; --s3: #21B8B8; --s4: #c98500; --s5: #d55181; --s6: #2e9b2e; --s7: #9085e9; --s8: #e66767;
    --seq: #4F9AD9;
    --other: #2c4a6c; --other-strong: #7f95ad;
    --side-bg: linear-gradient(180deg, #0A3a66 0%, #08284a 50%, #041120 100%);
    --shadow: none;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #06182E; --surface: #0C2644; --surface-2: #11304f; --surface-3: #173a5e; --line: #1C3B60; --line-2: #2a4d75;
  --text: #E8F0F7; --text-2: #A9BCD1; --text-3: #7f95ad;
  --accent: #4F9AD9; --accent-ink: #06182E; --accent-soft: #123a62; --teal: #21B8B8; --teal-soft: #0d3a44;
  --good: #4cc27b; --good-soft: #12302a; --bad: #ef7466; --bad-soft: #3a1d22; --warn: #e3a738; --warn-soft: #33290f;
  --s1: #4F9AD9; --s2: #d95926; --s3: #21B8B8; --s4: #c98500; --s5: #d55181; --s6: #2e9b2e; --s7: #9085e9; --s8: #e66767;
  --seq: #4F9AD9;
  --other: #2c4a6c; --other-strong: #7f95ad;
  --side-bg: linear-gradient(180deg, #0A3a66 0%, #08284a 50%, #041120 100%);
  --shadow: none;
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.45; }
[hidden] { display: none !important; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 22px; margin: 0; letter-spacing: -.01em; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
h2 { font-size: 15px; margin: 0 0 12px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
h3 { font-size: 13px; margin: 0 0 8px; color: var(--text-2); font-weight: 600; }
code { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }
small { font-size: .75em; color: var(--text-3); font-weight: 500; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--text-2); }
.small { font-size: 12px; color: var(--text-3); }
.center { text-align: center; }
.grow { flex: 1; }
.min0 { min-width: 0; }
.nowrap { white-space: nowrap; }
.t1 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.t2 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.up { color: var(--good); font-weight: 600; white-space: nowrap; }
.down { color: var(--bad); font-weight: 600; white-space: nowrap; }
.warn-t { color: var(--warn); font-weight: 600; }

/* layout */
.shell { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.side { background: var(--side-bg); color: #fff; border-right: 0; padding: 18px 12px; display: flex; flex-direction: column; gap: 16px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 4px 10px 8px; }
.brand img.logo-img { width: 104px; height: auto; display: block; }
.brand .prod { font-size: 12px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: rgba(255,255,255,.78); padding-left: 2px; }
.side .brand { border-bottom: 1px solid rgba(255,255,255,.14); padding-bottom: 14px; }
.brand b { display: block; font-size: 15px; }
.brand small { font-size: 12px; }
nav { display: flex; flex-direction: column; gap: 14px; }
.navgroup { display: flex; flex-direction: column; gap: 1px; }
.navgroup > span { font-size: 11px; font-weight: 500; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.55); padding: 0 10px 4px; }
nav a { color: rgba(255,255,255,.82); position: relative; padding: 7px 10px; border-radius: 8px; font-weight: 500; display: flex; align-items: center; gap: 8px; }
nav a:hover { background: rgba(255,255,255,.08); text-decoration: none; color: #fff; }
nav a.on { background: rgba(255,255,255,.13); color: #fff; }
nav a.on::before { content: ""; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px; border-radius: 2px; background: #21B8B8; }
.dot-live { width: 7px; height: 7px; border-radius: 50%; background: var(--good); animation: pulse 2s infinite; display: inline-block; }
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .3 } }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.theme { display: flex; background: rgba(0,0,0,.22); border-radius: 8px; padding: 3px; }
.theme button { flex: 1; border: 0; background: none; color: rgba(255,255,255,.7); font: inherit; font-size: 12px; padding: 5px; border-radius: 6px; cursor: pointer; }
.theme button.on { background: rgba(255,255,255,.16); color: #fff; }
.me { display: flex; gap: 10px; align-items: center; padding: 6px 8px; border-radius: 8px; color: #fff; }
.side .me small { color: rgba(255,255,255,.6); }
.side .avatar { background: #009999; color: #fff; }
.side .btn.ghost { color: rgba(255,255,255,.85); border-color: rgba(255,255,255,.25); background: transparent; }
.side .btn.ghost:hover { background: rgba(255,255,255,.08); }
.side-simbolo { width: 22px; height: auto; opacity: .55; align-self: flex-end; margin: 2px 6px 0 0; }
.me:hover { background: rgba(255,255,255,.08); text-decoration: none; }
.me b { display: block; font-size: 13px; }
.me small { display: block; font-size: 11.5px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; flex: none; }
main { padding: 24px 28px 56px; min-width: 0; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.page-head p { margin: 4px 0 0; color: var(--text-2); max-width: 760px; }
.back { display: inline-block; margin-bottom: 8px; font-size: 13px; }
.banner { background: var(--warn-soft); color: var(--warn); border: 1px solid color-mix(in srgb, var(--warn) 30%, transparent); padding: 9px 14px; border-radius: 8px; margin-bottom: 16px; font-weight: 500; }
.banner code { background: transparent; border: 1px solid color-mix(in srgb, var(--warn) 30%, transparent); }
.loading { color: var(--text-2); display: flex; align-items: center; gap: 10px; padding: 30px 0; }
.loading span { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--line-2); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* controles */
.btn { font: inherit; font-weight: 500; border: 1px solid var(--line-2); background: var(--surface); color: var(--text); padding: 7px 14px; border-radius: 8px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.small { padding: 4px 10px; font-size: 12.5px; }
.danger-t { color: var(--bad) !important; }
.link { border: 0; background: none; color: var(--accent); cursor: pointer; font: inherit; padding: 0; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters.between { justify-content: space-between; margin-bottom: 12px; }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; background: var(--surface); flex-wrap: wrap; }
.seg button { border: 0; background: none; font: inherit; font-size: 13px; padding: 6px 12px; color: var(--text-2); cursor: pointer; border-right: 1px solid var(--line); }
.seg button:last-child { border-right: 0; }
.seg button small { margin-left: 2px; }
.seg button.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tabs button { border: 0; background: none; font: inherit; font-weight: 500; color: var(--text-2); padding: 9px 14px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs button:hover { color: var(--text); }
.tabs button.on { color: var(--accent); border-bottom-color: var(--accent); }
select, input, textarea { font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line-2); border-radius: 8px; padding: 7px 10px; }
input[type=number] { width: 84px; }
input[type=search] { min-width: 180px; }
textarea { width: 100%; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
label.check { display: inline-flex; gap: 6px; align-items: center; color: var(--text-2); font-size: 13px; cursor: pointer; }
input[type=checkbox], input[type=radio] { accent-color: var(--accent); width: 15px; height: 15px; margin: 0; }

/* cartões */
.grid { display: grid; gap: 16px; }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g2.wide { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
.g2.tight { gap: 12px 20px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; }
.card-head > div:first-child { flex: 1 1 200px; min-width: 0; }
.card-head > .chip { flex: none; }
.stat .label { color: var(--text-2); font-size: 12.5px; font-weight: 500; }
.stat .value { font-size: 26px; font-weight: 650; letter-spacing: -.02em; margin-top: 2px; font-variant-numeric: tabular-nums; line-height: 1.2; }
.stat .value small { font-size: 13px; font-weight: 500; letter-spacing: 0; }
.stat .sub { color: var(--text-3); font-size: 12px; margin-top: 4px; }
.stat.alert { border-color: color-mix(in srgb, var(--bad) 40%, var(--line)); }
.section { margin-top: 20px; }
.catcard { display: block; color: var(--text); transition: border-color .15s, transform .15s; }
.catcard:hover { text-decoration: none; border-color: var(--accent); transform: translateY(-1px); }
.catcard h3 { color: var(--text); font-size: 14px; margin: 0; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; margin: 12px 0 0; }
.kv dt { font-size: 11.5px; color: var(--text-3); }
.kv dd { margin: 0; font-size: 13px; font-weight: 500; }

/* chips e marcas */
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.chip.good { background: var(--good-soft); color: var(--good); }
.chip.bad { background: var(--bad-soft); color: var(--bad); }
.chip.warn { background: var(--warn-soft); color: var(--warn); }
.chip.info { background: var(--accent-soft); color: var(--accent); }
a.chip:hover { text-decoration: none; filter: brightness(.97); }
.btag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 2px 8px 2px 7px; border-radius: 6px; background: var(--surface-2); color: var(--text); white-space: nowrap; }
a.btag:hover { text-decoration: none; background: var(--surface-3); }
.btag .ip { font-size: 9.5px; font-weight: 700; color: #fff; background: linear-gradient(90deg, #009999, #0A4A80); border-radius: 4px; padding: 0 4px; margin-left: 1px; letter-spacing: .02em; }
.ipmini { font-size: 9.5px; font-weight: 700; color: var(--teal); }
.side a.brand:hover { text-decoration: none; }
h1 { color: var(--brand-h, var(--text)); }
:root { --brand-h: #0A4A80; }
:root[data-theme="dark"] { --brand-h: var(--text); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --brand-h: var(--text); } }
.banner { border-left: 4px solid var(--teal); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.brandcell { display: flex; flex-direction: column; gap: 3px; align-items: flex-start; }
.brandhead { display: flex; gap: 14px; align-items: center; }
.brandhead p { margin-top: 6px; display: flex; gap: 6px; flex-wrap: wrap; }
.bdot { width: 14px; height: 40px; border-radius: 4px; flex: none; }
.chips-sel { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.chips-sel button { font: inherit; font-size: 12.5px; border: 1px solid var(--line-2); background: var(--surface); color: var(--text-2); border-radius: 99px; padding: 4px 10px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.chips-sel button.on { border-color: var(--accent); background: var(--accent-soft); color: var(--text); font-weight: 600; }

/* tabelas */
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 12px; font-weight: 600; color: var(--text-3); padding: 7px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
td.r, th.r { text-align: right; }
td.num { white-space: nowrap; }
td.maxw { max-width: 340px; }
.scroll-x { overflow-x: auto; }
.tbl tr.hl td { background: color-mix(in srgb, var(--accent-soft) 55%, transparent); }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--surface-2); }
.tbl tr.open td { background: var(--surface-2); }
.tbl tr.detail > td { background: var(--bg); padding: 14px 16px; }
.caret { color: var(--text-3); display: inline-block; transition: transform .15s; }
tr.open .caret { transform: rotate(90deg); }
.sortable th { cursor: pointer; user-select: none; }
.sortable th:hover, .sortable th.on { color: var(--text); }
.matrix td:not(:first-child), .matrix th:not(:first-child) { text-align: center; }
.pos { width: 28px; height: 28px; border-radius: 7px; background: var(--surface-2); display: grid; place-items: center; font-weight: 650; font-variant-numeric: tabular-nums; flex: none; font-size: 13px; }
.pos.p1 { background: var(--accent); color: #fff; }
.pos.p3 { background: var(--accent-soft); color: var(--accent); }
.thumb { width: 40px; height: 40px; border-radius: 6px; object-fit: contain; background: #fff; border: 1px solid var(--line); flex: none; }
.thumb.empty { background: var(--surface-2); }
.thumb.wide { width: 72px; object-fit: cover; }
.bar { height: 8px; background: var(--surface-2); border-radius: 4px; min-width: 40px; position: relative; overflow: hidden; flex: 1; }
.bar > i { position: absolute; inset: 0 auto 0 0; border-radius: 0 4px 4px 0; }
.barcell { display: flex; align-items: center; gap: 8px; min-width: 120px; }
.barcell span { width: 52px; text-align: right; font-variant-numeric: tabular-nums; flex: none; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; gap: 10px; align-items: center; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.list li.hl { background: color-mix(in srgb, var(--accent-soft) 55%, transparent); border-radius: 6px; }
.list.compact li { padding: 6px 2px; }
.alerts li { flex-wrap: wrap; }
.feed { max-height: 300px; overflow: auto; }
.feed li { font-size: 13px; }
.feed .when { color: var(--text-3); font-size: 12px; width: 42px; flex: none; font-variant-numeric: tabular-nums; }
.feed li.flash { animation: flash 1.2s ease-out; }
@keyframes flash { from { background: var(--accent-soft); } to { background: transparent; } }
.empty-state { color: var(--text-2); padding: 18px; text-align: center; border: 1px dashed var(--line-2); border-radius: 8px; }
.rel { margin: 0; padding-left: 20px; font-size: 13px; }
.rel li { padding: 3px 0; }
.rel li span:first-child { margin-right: 8px; }

/* participação */
.sharebar { display: flex; gap: 2px; height: 14px; border-radius: 4px; overflow: hidden; background: var(--surface-2); }
.sharebar.big { height: 22px; }
.sharebar span { min-width: 2px; }
.sharelegend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; font-size: 12px; color: var(--text-2); }
.sharelegend span { display: inline-flex; align-items: center; gap: 5px; }
.sharelegend i { width: 9px; height: 9px; border-radius: 2px; display: inline-block; }
.sharelegend b.num { color: var(--text); }
.hbars { display: flex; flex-direction: column; gap: 7px; }
.hb { display: grid; grid-template-columns: minmax(80px, 140px) 1fr auto; gap: 10px; align-items: center; font-size: 13px; }
.hb-l { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-b { height: 10px; background: var(--surface-2); border-radius: 3px; position: relative; overflow: hidden; }
.hb-b i { position: absolute; inset: 0 auto 0 0; border-radius: 0 3px 3px 0; }
.hb-v { text-align: right; white-space: nowrap; }

/* gráficos */
.chart { position: relative; width: 100%; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart .grid line { stroke: var(--line); stroke-width: 1; }
.chart .axis text { fill: var(--text-3); font-size: 11px; }
.chart .axis .axt { fill: var(--text-2); font-size: 11.5px; font-weight: 500; }
.chart .cross { stroke: var(--line-2); stroke-width: 1; }
.chart .quad line { stroke: var(--line-2); stroke-dasharray: 4 4; }
.chart .quad text { fill: var(--text-3); font-size: 10.5px; }
.chart .lbl { fill: var(--text-2); font-size: 11px; }
.chart .lbl.ip { fill: var(--text); font-weight: 600; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 10px; font-size: 12.5px; }
.legend button, .legend span { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; font: inherit; color: var(--text-2); cursor: pointer; padding: 2px 6px; border-radius: 6px; }
.legend button:hover { background: var(--surface-2); }
.legend button.off { opacity: .35; }
.legend.static span { cursor: default; }
.legend i { width: 14px; height: 3px; border-radius: 2px; display: inline-block; }
.legend i.round { width: 10px; height: 10px; border-radius: 50%; }
.tip { position: fixed; z-index: 60; pointer-events: none; background: var(--surface); border: 1px solid var(--line-2); border-radius: 8px; padding: 8px 10px; font-size: 12px; box-shadow: 0 4px 16px rgba(0,0,0,.14); max-width: 300px; }
.tip .row { display: flex; justify-content: space-between; gap: 14px; }
.tip .row i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px; }
.tip b { display: block; margin-bottom: 4px; }

/* gestão */
.src { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.src:last-child { border-bottom: 0; }
pre.snippet { background: var(--surface-2); padding: 10px 12px; border-radius: 8px; overflow-x: auto; font-size: 12.5px; white-space: pre-wrap; }
.logs { max-height: 280px; overflow: auto; font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
.logs div { padding: 3px 0; border-bottom: 1px solid var(--line); }
.vert-edit { margin-bottom: 12px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.vert-edit .row2 + .row2 { margin-top: 10px; }
.vert-edit label, .row2 > label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--text-2); font-weight: 500; }
.perm-sum { display: flex; flex-direction: column; gap: 8px; }
.perm-sum > div { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.perm-sum > div > .small:first-child { width: 72px; flex: none; }
.tree { display: flex; flex-direction: column; gap: 8px; }
.tree-node { padding-left: 22px; position: relative; }
.tree-node::before { content: ""; position: absolute; left: 8px; top: -6px; bottom: 50%; width: 10px; border-left: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); border-bottom-left-radius: 4px; }
.usercell { display: flex; gap: 10px; align-items: center; }
.usercell.big .avatar { width: 48px; height: 48px; font-size: 20px; }

/* modal, formulários, toast */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,.42); z-index: 50; display: grid; place-items: start center; padding: 6vh 16px 16px; overflow-y: auto; }
.modal-box { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; width: 100%; max-width: 620px; padding: 22px 24px; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.modal-actions.left { justify-content: flex-start; margin-top: 14px; }
.form { display: flex; flex-direction: column; gap: 12px; }
.form > label, .form .row2 > label, #subBox > label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--text-2); font-weight: 500; }
.form label.check { flex-direction: row; align-items: center; gap: 6px; font-weight: 400; }
.row2 > label.check { align-self: end; padding-bottom: 8px; }
#subBox { display: flex; flex-direction: column; gap: 12px; }
.form input[readonly] { background: var(--surface-2); color: var(--text-2); }
fieldset { border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px 12px; margin: 0; display: flex; flex-direction: column; gap: 8px; }
legend { font-size: 12.5px; font-weight: 600; color: var(--text-2); padding: 0 4px; }
label.radio { display: flex; gap: 8px; align-items: flex-start; cursor: pointer; }
label.radio input { margin-top: 3px; }
label.radio span b { display: block; font-size: 13px; }
label.radio span small { display: block; font-size: 12px; }
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 12px; }
#vBox { padding-left: 23px; }
.inline { display: flex; gap: 6px; }
.inline input { flex: 1; font-family: ui-monospace, Consolas, monospace; }
.toast { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 70; background: var(--text); color: var(--bg); padding: 10px 16px; border-radius: 8px; font-weight: 500; box-shadow: 0 6px 20px rgba(0,0,0,.2); max-width: calc(100vw - 32px); }
.toast.good { background: var(--good); color: #fff; }
.toast.bad { background: var(--bad); color: #fff; }

/* login */
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; position: relative; overflow: hidden; background: linear-gradient(135deg, #009999 0%, #0A4A80 62%, #06182E 100%); }
.login::before { content: ""; position: absolute; right: -8vmin; bottom: -14vmin; width: 78vmin; height: 82vmin; background: url(brand/ip77-grafismo-77.png) no-repeat right bottom / contain; opacity: .14; pointer-events: none; }
.login::after { content: ""; position: absolute; right: 28px; bottom: 24px; width: 28px; height: 36px; background: url(brand/ip77-simbolo-branco.png) no-repeat center / contain; opacity: .8; }
.login-logo { width: 150px; height: auto; display: block; margin: 0 auto 18px; }
.login-wrap { position: relative; z-index: 1; width: 100%; max-width: 370px; }
.login-card { background: var(--surface); border: 0; border-radius: 14px; box-shadow: 0 18px 50px rgba(3,15,30,.35) !important; padding: 28px; width: 100%; max-width: 370px; display: flex; flex-direction: column; gap: 14px; box-shadow: var(--shadow); }
.login-card .brand { padding: 0 0 6px; }
.login-card h1 { font-size: 19px; font-weight: 500; color: var(--text); }
.login-card .sub { margin: -8px 0 4px; font-size: 13px; color: var(--text-2); }
.login-card label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: var(--text-2); font-weight: 500; }
.erro { color: var(--bad); margin: 0; min-height: 1em; font-size: 13px; }

@media (max-width: 1200px) { .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g2, .g2.wide { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; height: auto; padding: 12px 16px; gap: 10px; border-right: 0; border-bottom: 0; }
  .side .brand { flex-direction: row; align-items: center; border-bottom: 0; padding: 0; gap: 10px; }
  .brand img.logo-img { width: 72px; }
  .side-simbolo { display: none; }
  nav { flex-direction: row; overflow-x: auto; gap: 4px; }
  .navgroup { flex-direction: row; }
  .navgroup > span { display: none; }
  nav a { white-space: nowrap; }
  .side-foot { flex-direction: row; align-items: center; justify-content: space-between; flex-wrap: wrap; }
  main { padding: 16px 16px 40px; }
  .g3 { grid-template-columns: minmax(0, 1fr); }
  .g4 { grid-template-columns: 1fr 1fr; }
  .row2 { grid-template-columns: 1fr; }
  .kv { grid-template-columns: 1fr; }
  input[type=search] { min-width: 0; width: 100%; }
}

/* modelos */
.model { display: inline-block; font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 12px; font-weight: 600; letter-spacing: .01em; color: var(--text); background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 5px; padding: 0 6px; line-height: 1.6; white-space: nowrap; }
.model.big { font-size: 13px; padding: 1px 8px; }
.model.guess { border-style: dashed; color: var(--text-2); }
.mline { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
a.sub-link { color: var(--text-2); }
a.sub-link:hover { color: var(--accent); }
.pos.inline { display: inline-grid; width: 24px; height: 24px; font-size: 12px; vertical-align: middle; }

/* cadastro de marcas */
.order { list-style: none; margin: 0; padding: 0; counter-reset: o; }
.order li { display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-bottom: 1px solid var(--line); counter-increment: o; }
.order li::before { content: counter(o) "º"; width: 26px; color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; }
.order li:last-child { border-bottom: 0; }
.order .btn[disabled] { opacity: .3; cursor: default; }
.seglist { display: flex; flex-direction: column; gap: 6px; }
.segrow { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 4px 0; border-bottom: 1px solid var(--line); }
.segrow:last-child { border-bottom: 0; }
.testres { border-radius: 8px; padding: 10px 12px; font-size: 13px; }
.testres.ok { background: var(--good-soft); color: var(--good); }
.testres.no { background: var(--warn-soft); color: var(--warn); }
.testres ul { margin: 6px 0 0; padding-left: 18px; color: var(--text-2); }
.chips-wrap { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0 8px; }

/* compras */
.modal-box.wide { max-width: 980px; }
.onboarding ol { padding-left: 20px; line-height: 1.7; }
.ctbl td { padding: 7px 6px; }
.ctbl th { padding: 7px 6px; }
.cobbar { position: relative; width: 64px; height: 8px; background: var(--surface-2); border-radius: 4px; display: inline-block; vertical-align: middle; margin-right: 6px; overflow: visible; }
.cobbar i { position: absolute; inset: 0 auto 0 0; border-radius: 4px; }
.cobbar b { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--text); border-radius: 1px; }
.spark svg { display: block; }
.qin { width: 78px; text-align: right; padding: 4px 6px; font-variant-numeric: tabular-nums; }
.qin[data-edit] { border-color: var(--accent); background: var(--accent-soft); }
.why { background: var(--accent-soft); color: var(--text); border-radius: 8px; padding: 10px 14px; font-size: 13.5px; line-height: 1.55; }
.kv.four { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 14px; }
.big-acc { display: flex; align-items: baseline; gap: 12px; margin: 4px 0 10px; flex-wrap: wrap; }
.big-acc .num { font-size: 44px; font-weight: 700; letter-spacing: -.03em; }
.tips { margin: 0; padding-left: 18px; line-height: 1.6; font-size: 13.5px; }
.tips li { margin-bottom: 6px; }
.matrixgrid { width: 100%; border-collapse: separate; border-spacing: 6px; }
.matrixgrid th { text-align: center; border: 0; color: var(--text-2); font-size: 12.5px; }
.matrixgrid th small { display: block; font-weight: 500; }
.matrixgrid tbody th { text-align: left; width: 110px; }
.mx { text-align: center; border-radius: 8px; padding: 12px 6px; border: 0; }
.mx b { display: block; font-size: 18px; font-variant-numeric: tabular-nums; }
.mx span { font-size: 11.5px; color: var(--text-2); }
.mx.good { background: var(--good-soft); } .mx.warn { background: var(--warn-soft); } .mx.bad { background: var(--bad-soft); } .mx.neutral, .mx.empty { background: var(--surface-2); color: var(--text-3); }
.mapgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 14px; }
.mapgrid label { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--text-2); font-weight: 500; }
.form label small { font-weight: 400; }
@media (max-width: 760px) { .kv.four { grid-template-columns: 1fr 1fr; } }

.ctbl td.maxw { min-width: 200px; max-width: 260px; }
.ctbl .chip { font-size: 11px; padding: 2px 6px; }
.ctbl .mline { flex-wrap: nowrap; }
.ctbl .mline .btag { flex: none; }

/* regiões */
.tilemap { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); grid-template-rows: repeat(8, auto); gap: 4px; max-width: 470px; margin: 0 auto 12px; }
.tile { aspect-ratio: 1; border: 0; border-radius: 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; font: inherit; cursor: pointer; padding: 2px; transition: transform .1s, box-shadow .1s; }
.tile b { font-size: 13px; letter-spacing: .02em; }
.tile span { font-size: 11px; font-variant-numeric: tabular-nums; opacity: .92; }
.tile:hover { transform: scale(1.06); box-shadow: 0 2px 10px rgba(0,0,0,.18); }
.tile.sel { outline: 3px solid var(--text); outline-offset: 1px; }
.seqleg { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--text-2); max-width: 470px; margin: 0 auto; }
.seqleg i { flex: 1; height: 10px; border-radius: 3px; background: linear-gradient(90deg, color-mix(in srgb, var(--s1) 12%, var(--surface-2)), var(--s1)); }
.rankbox { max-height: 560px; overflow-y: auto; }

body { font-feature-settings: "calt" 0; }

.section-sm { margin-bottom: 18px; }
.list.cols2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 20px; }
@media (max-width: 900px) { .list.cols2 { grid-template-columns: minmax(0, 1fr); } }

/* produtos por marca */
.prodfil { display: flex; flex-direction: column; gap: 12px; }
.pf-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.pf-l { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 500; color: var(--text-2); }
.pf-l select, .pf-l input { min-width: 180px; }
.pf-l.grow { flex: 1 1 260px; }
.pf-l.grow input { width: 100%; }
.pf-chk { padding-bottom: 8px; }
#pp button { white-space: nowrap; }
#pp .dot-live { vertical-align: middle; }
.ptbl td { vertical-align: middle; }
.ptbl .pmod { min-width: 200px; }
.ptbl .pprod { min-width: 240px; max-width: 360px; }
.ptbl .perp { min-width: 130px; max-width: 170px; }
.ptbl .perp a { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ptbl .perp .chip { white-space: nowrap; }
.ptbl th { white-space: nowrap; }
.ptbl .barcell { min-width: 96px; }
.pmore { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.muted-row { opacity: .55; }
.banner.info-b { background: var(--accent-soft); color: var(--text); border-left-color: var(--accent); }

.fontes-leg { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 12px; color: var(--text-2); }
.fontes-leg .chip { margin-right: 4px; }

.diag { display: flex; flex-direction: column; gap: 2px; }
.diag-i { display: flex; gap: 10px; align-items: flex-start; padding: 8px 4px; border-bottom: 1px solid var(--line); }
.diag-i:last-child { border-bottom: 0; }
.diag-s { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 12px; flex: none; }
.diag-i.ok .diag-s { background: var(--good-soft); color: var(--good); }
.diag-i.nok .diag-s { background: var(--warn-soft); color: var(--warn); }
