:root {
  --bg: #0c141b;
  --panel: #14212b;
  --line: #263540;
  --text: #e9f1f5;
  --muted: #93a8b8;
  --accent: #6ce0b6;
  --blue: #68b9ed;
  --danger: #ffa6a6;
  font-family:
    Inter,
    Segoe UI,
    system-ui,
    sans-serif;
  color: var(--text);
  background: var(--bg);
  font-synthesis: none;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  background: #1b2b36;
  color: var(--text);
  border-radius: 9px;
  padding: 10px 15px;
  transition: background 0.15s;
}
button:hover {
  background: #2b414e;
}
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button.primary {
  background: var(--accent);
  color: #0a2b20;
  font-weight: 700;
  border-color: var(--accent);
}
button.danger {
  color: var(--danger);
}
input,
select,
textarea {
  width: 100%;
  margin-top: 8px;
  padding: 13px 14px;
  background: #0d1a23;
  color: var(--text);
  border: 1px solid #354956;
  border-radius: 8px;
}
label {
  display: block;
  margin: 18px 0;
  font-size: 14px;
  color: #bdcdd7;
}
input[type="checkbox"] {
  width: auto;
  margin-right: 10px;
}
a {
  color: inherit;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
p {
  line-height: 1.65;
  color: var(--muted);
}
h1 {
  font-size: 32px;
  letter-spacing: -1px;
}
h2 {
  font-size: 24px;
  letter-spacing: -0.5px;
}
h3 {
  font-size: 16px;
  font-weight: 600;
}
small {
  color: var(--muted);
}
[hidden] {
  display: none !important;
}
.brand {
  display: flex;
  align-items: center;
  gap: 13px;
  text-decoration: none;
  font-size: 18px;
  line-height: 1.2;
}
.brand strong {
  font-weight: 500;
  color: var(--muted);
}
.mark {
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #09271d;
  width: 43px;
  height: 43px;
  border-radius: 14px;
  font-size: 27px;
  font-weight: 800;
}
.eyebrow {
  display: block;
  color: var(--accent);
  font-size: 11px;
  letter-spacing: 2px;
  font-weight: 700;
  margin-bottom: 14px;
}
.login-shell {
  max-width: 1240px;
  margin: auto;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 440px;
  align-items: center;
  gap: 90px;
  padding: 60px 45px;
}
.login-intro .brand {
  margin-bottom: 95px;
}
.login-intro h1 {
  font-size: clamp(36px, 4vw, 59px);
  line-height: 1.08;
  letter-spacing: -2.5px;
}
.login-intro > p {
  max-width: 430px;
  font-size: 17px;
}
.principles {
  display: grid;
  gap: 18px;
  margin: 35px 0 60px;
  color: var(--accent);
  font-size: 13px;
}
.principles b {
  color: #c8d6df;
  font-weight: 500;
  margin-left: 15px;
}
.login-card {
  background: var(--panel);
  padding: 38px;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 20px 100px #0002;
}
.login-card h2 {
  font-size: 28px;
}
.login-card .primary {
  width: 100%;
  display: flex;
  justify-content: space-between;
  margin-top: 28px;
}
.help-note {
  border-top: 1px solid var(--line);
  padding-top: 23px;
  margin-top: 25px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}
#login-message,
#dialog-error {
  font-size: 13px;
  color: var(--danger);
  margin: 15px 0 0;
}
.sidebar {
  width: 242px;
  position: fixed;
  height: 100vh;
  background: #101c25;
  border-right: 1px solid var(--line);
  padding: 32px 20px;
}
.nav-label {
  color: #708796;
  font-size: 10px;
  letter-spacing: 2px;
  margin: 50px 15px 16px;
}
nav {
  display: grid;
  gap: 6px;
}
nav button {
  display: flex;
  gap: 13px;
  text-align: left;
  background: transparent;
  border-color: transparent;
  color: var(--muted);
  font-size: 16px;
  padding: 13px;
}
nav button span {
  font-size: 13px;
}
nav button.selected {
  color: var(--accent);
  background: #6ce0b611;
  border-color: #6ce0b622;
}
.sidebar-bottom {
  position: absolute;
  bottom: 25px;
  font-size: 12px;
  padding-left: 12px;
}
.sidebar-bottom p {
  font-size: 11px;
  margin: 12px 0 0;
}
.live-indicator {
  width: 7px;
  height: 7px;
  display: inline-block;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 6px;
}
main {
  margin-left: 242px;
  padding: 36px 40px 0;
  max-width: 1800px;
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 25px;
  margin-bottom: 28px;
}
.topbar h1 {
  margin: 0;
  font-size: 28px;
}
.topbar .eyebrow {
  font-size: 9px;
  margin: 0 0 9px;
  color: var(--muted);
}
.top-actions {
  display: flex;
  align-items: center;
  gap: 13px;
  font-size: 12px;
}
.top-actions button {
  font-size: 12px;
}
.notice {
  border: 1px solid #ba935b;
  background: #372c1c;
  padding: 14px 18px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 20px;
}
.welcome {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin: 15px 0 24px;
}
.welcome h2 {
  font-size: 23px;
  margin-bottom: 6px;
}
.welcome p {
  font-size: 13px;
  margin: 0;
}
.section-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.section-actions select {
  width: auto;
  margin: 0;
  padding: 9px;
  font-size: 12px;
}
.download-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 255px), 1fr));
  gap: 1rem;
}
.download-card {
  background: #152236;
  border: 1px solid #2a3c55;
  border-radius: 0.85rem;
  padding: 1.2rem;
}
.download-card h2 {
  margin: 0.45rem 0;
}
.download-card p {
  color: #b4c3d8;
}
.download-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}
.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 22px;
}
.card,
.chart-box,
.table-box {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 13px;
}
.card {
  padding: 20px;
}
.card span {
  color: var(--muted);
  font-size: 12px;
}
.card strong {
  display: block;
  font-size: 31px;
  font-weight: 600;
  letter-spacing: -1px;
  margin: 12px 0 6px;
}
.card small {
  font-size: 11px;
}
.charts {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  margin-bottom: 22px;
}
.chart-box {
  padding: 24px;
  min-width: 0;
}
.chart-heading {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 10px;
}
.chart-heading p {
  font-size: 11px;
  margin-bottom: 20px;
}
.chart-heading h3 {
  margin: 0 0 8px;
}
.chart-box canvas {
  display: block;
  width: 100%;
  height: 200px;
}
.legend {
  display: flex;
  gap: 18px;
  color: var(--muted);
  font-size: 11px;
  margin-top: 12px;
}
.legend b {
  color: var(--accent);
}
.legend em {
  color: var(--blue);
  font-style: normal;
}
.table-box {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 13px;
  text-align: left;
}
thead {
  background: #1a2934;
  color: var(--muted);
}
th {
  font-size: 10px;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-weight: 600;
  padding: 15px 20px;
  white-space: nowrap;
}
td {
  padding: 17px 20px;
  border-top: 1px solid var(--line);
  max-width: 320px;
  overflow-wrap: anywhere;
}
td button {
  font-size: 11px;
  margin: 3px;
  padding: 7px 10px;
}
.badge {
  display: inline-block;
  border: 1px solid #6ce0b638;
  background: #6ce0b610;
  color: var(--accent);
  padding: 4px 9px;
  border-radius: 20px;
  font-size: 10px;
  white-space: nowrap;
}
.badge.off {
  color: var(--muted);
  border-color: var(--line);
  background: #21313b;
}
.empty {
  padding: 45px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}
.info {
  border-left: 3px solid var(--accent);
  padding: 12px 18px;
  font-size: 13px;
  margin: 20px 0;
  color: var(--muted);
  line-height: 1.7;
}
.mono {
  font-family: Consolas, monospace;
  font-size: 12px;
}
footer {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 24px 0;
  margin-top: 40px;
  color: #748a99;
  font-size: 11px;
}
dialog {
  background: var(--panel);
  color: var(--text);
  border: 1px solid #3b5261;
  border-radius: 16px;
  padding: 28px;
  width: min(530px, 92vw);
  max-height: 90vh;
}
dialog::backdrop {
  background: #030a10cc;
  backdrop-filter: blur(3px);
}
.dialog-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.dialog-top h2 {
  font-size: 22px;
  margin: 0;
}
.dialog-top button {
  border: 0;
  background: none;
  font-size: 22px;
  padding: 0 5px;
}
.dialog-actions {
  display: flex;
  gap: 10px;
  justify-content: end;
  margin-top: 25px;
}
#dialog-description {
  font-size: 13px;
  margin-top: 15px;
}
.secret {
  display: block;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  padding: 20px;
  border: 1px solid #6ce0b633;
  border-radius: 10px;
  color: var(--accent);
  background: #0d1a23;
  font-size: 14px;
}
.loading {
  padding: 50px;
  color: var(--muted);
}
@media (max-width: 1100px) {
  .sidebar {
    width: 205px;
    padding: 24px 12px;
  }
  main {
    margin-left: 205px;
    padding: 25px;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .charts {
    grid-template-columns: 1fr;
  }
  .login-shell {
    gap: 40px;
    padding: 35px;
    grid-template-columns: 1fr 390px;
  }
  .top-actions {
    flex-wrap: wrap;
    justify-content: end;
  }
}
@media (max-width: 750px) {
  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    padding: 20px;
  }
  .sidebar .brand {
    font-size: 16px;
  }
  .nav-label,
  .sidebar-bottom {
    display: none;
  }
  nav {
    display: flex;
    overflow: auto;
    margin-top: 20px;
  }
  nav button {
    flex-shrink: 0;
    padding: 10px;
  }
  nav button span {
    font-size: 12px;
  }
  main {
    margin: 0;
    padding: 20px;
  }
  .topbar {
    align-items: start;
  }
  .top-actions {
    max-width: 180px;
    gap: 6px;
  }
  #account-name {
    display: none;
  }
  .welcome {
    flex-direction: column;
  }
  .card {
    padding: 16px;
  }
  .card strong {
    font-size: 27px;
  }
  .login-shell {
    display: block;
    padding: 28px 20px;
  }
  .login-intro .brand {
    margin: 0 0 35px;
  }
  .login-intro h1 {
    font-size: 35px;
  }
  .login-intro > p,
  .principles,
  .login-intro > small {
    display: none;
  }
  .login-card {
    padding: 24px;
    margin-top: 30px;
  }
  .login-intro .eyebrow {
    margin-top: 40px;
  }
  .chart-box {
    padding: 18px;
  }
  footer span {
    display: none;
  }
  td,
  th {
    padding: 13px;
  }
}

.brand img {
  height: auto;
  max-width: 100%;
  object-fit: contain;
}
.brand strong {
  white-space: nowrap;
}
.identity {
  display: grid;
  gap: 0.12rem;
  text-align: right;
}
.identity strong {
  color: #f0fafb;
  font-size: 0.88rem;
}
.console-link {
  display: inline-block;
  border: 1px solid #396457;
  border-radius: 8px;
  padding: 8px 12px;
  margin: 2px;
  color: #80edc4;
  text-decoration: none;
  white-space: nowrap;
}
.console-link:hover,
.console-link:focus-visible {
  border-color: #80edc4;
}
@media (max-width: 720px) {
  .brand img {
    width: 100px;
  }
  .identity {
    text-align: left;
  }
}
.info.online {
  color: var(--accent);
}
