html, body {
  margin: 0;
  padding: 0;
  font-family: 'Ubuntu', sans-serif;
  font-size: 100%;
  background: #ffffff;
  color: #333;
}
body { min-height: 100vh; }
.top-nav{
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.top-nav__inner{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 24px;
  box-sizing: border-box;
}
.top-nav__brand{
  display: inline-flex;
  align-items: center;
  font-family: 'Varela Round', sans-serif;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #333;
  white-space: nowrap;
}
a.top-nav__brand{
  text-decoration: none;
  cursor: pointer;
}
a.top-nav__brand:focus-visible{
  outline: 2px solid rgba(110, 202, 220, 0.85);
  outline-offset: 3px;
  border-radius: 10px;
}
.top-nav__mark{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 176px;
  height: 38px;
  border-radius: 12px;
  background: transparent;
  box-shadow: 0 10px 26px rgba(0,0,0,0.10);
}
.top-nav__mark svg{
  display: block;
}
.top-nav__links{
  display: flex;
  align-items: center;
  gap: 8px;
}
.top-nav__link{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  text-decoration: none;
  color: #555;
  font-weight: 500;
}
.top-nav__link:hover{
  background: rgba(110, 202, 220, 0.10);
  color: #333;
}
.top-nav__link.is-active{
  background: rgba(110, 202, 220, 0.18);
  color: #1f4a51;
}
.status-dot {
  display: inline-block;
  width: 9px; height: 9px;
  background: #6ecadc;
  border-radius: 50%;
  margin-right: 0;
  transform: translateY(-1px);
}
.status-dot.warning { background: #e78b6d; }
.status-dot.offline { background: #d45b52; }
.status-dot.online {
  background: #6ecadc;
  box-shadow: 0 0 0 0 rgba(110, 202, 220, 0.55);
  animation: statusPulse 1.8s ease-out infinite;
}
@keyframes statusPulse {
  0% { box-shadow: 0 0 0 0 rgba(110, 202, 220, 0.40); }
  70% { box-shadow: 0 0 0 8px rgba(110, 202, 220, 0.00); }
  100% { box-shadow: 0 0 0 0 rgba(110, 202, 220, 0.00); }
}
.main {
  padding: 22px 28px 45px 28px;
  box-sizing: border-box;
}
.intro {
  border-bottom: 1px dotted #cfcfcf;
  padding-bottom: 14px;
  margin-bottom: 18px;
}
.intro h2 {
  font-family: 'Varela Round', sans-serif;
  font-size: 1.55em;
  color: #333;
  margin: 0 0 8px 0;
}
.intro p {
  color: #666;
  font-size: 0.98em;
  line-height: 1.6em;
  max-width: 900px;
  margin: 0;
}
.section { margin-bottom: 36px; }
.section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px dotted #cfcfcf;
  padding-bottom: 12px;
  margin-bottom: 20px;
}
.inline-controls {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.inline-label {
  font-size: 0.82em;
  color: #888;
  letter-spacing: 0.02em;
}
.inline-select {
  font: inherit;
  font-size: 0.88em;
  padding: 6px 34px 6px 12px;
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 999px;
  background: rgba(110, 202, 220, 0.08);
  color: #2b2b2b;
  height: 34px;
  line-height: 22px;
}
.inline-select:focus {
  outline: none;
  border-color: rgba(110, 202, 220, 0.55);
  box-shadow: 0 0 0 3px rgba(110, 202, 220, 0.18);
}
.section-title h3 {
  margin: 0;
  color: #6ecadc;
  font-size: 1.2em;
  letter-spacing: 0.06em;
  font-weight: 700;
}
.section-title span {
  color: #999;
  font-size: 0.9em;
  text-align: right;
}
.data-banner--warn{
  border-color: rgba(255, 193, 7, 0.55);
  background: rgba(255, 193, 7, 0.08);
}
.data-banner{
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(110, 202, 220, 0.08);
  border-radius: 14px;
  padding: 12px 14px;
  margin: 0 0 18px 0;
  box-shadow: 0 10px 22px rgba(0,0,0,0.06);
}
.data-banner.is-hidden{ display: none; }
.data-banner__title{
  font-weight: 700;
  color: #1f4a51;
  margin-bottom: 6px;
}
.data-banner__body{
  color: #2b2b2b;
  font-size: 0.95em;
  line-height: 1.45em;
}
.data-banner__reason{
  color: #4a4a4a;
  margin-bottom: 8px;
}
.data-banner__hint{
  color: #666;
}
.data-banner code{
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 8px;
  padding: 1px 6px;
  font-size: 0.95em;
}
.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}
.cards-six {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}
.cards-five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.card, .panel {
  border: 1px solid #eee;
  background: #fff;
  box-shadow: 0 3px 14px rgba(0,0,0,0.06);
  padding: 22px;
  box-sizing: border-box;
}
.card .label {
  display: block;
  color: #777;
  font-size: 0.85em;
  margin-bottom: 10px;
}
.card strong {
  display: block;
  font-size: 1.45em;
  color: #333;
  margin-bottom: 8px;
}

/* Bot status: dot aligned with text */
#bot-status{
  display: flex;
  align-items: center;
  gap: 8px;
}
.card small { color: #999; }
.positive { color: #299c64 !important; }
.negative { color: #c5564a !important; }
.neutral { color: #333 !important; }
.two-column {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 22px;
}
.chart-wrap {
  height: 310px;
  position: relative;
}
table {
  width: 100%;
  border-collapse: collapse;
}
td {
  padding: 12px 0;
  border-bottom: 1px dotted #ddd;
  color: #555;
  vertical-align: top;
}
td:last-child {
  text-align: right;
  font-weight: 600;
  color: #333;
  max-width: 340px;
  word-break: break-word;
}
.signal-list {
  display: grid;
  gap: 12px;
  max-height: 460px;
  overflow: auto;
  padding-right: 6px;
}
.signal {
  border-left: 4px solid #6ecadc;
  background: #fafafa;
  padding: 12px 14px;
}
.signal.error { border-left-color: #e78b6d; }
.signal-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:12px;
}
.signal-head strong { color: #333; }
.signal-head span {
  color: #999;
  font-size: 0.9em;
  white-space: nowrap;
}
.signal p, .signal-reason {
  margin: 8px 0 0 0;
  color: #666;
  line-height: 1.5em;
}
.reason-bullets{
  margin: 10px 0 0 0;
  padding: 0;
  color: #666;
  line-height: 1.55em;
  font-size: 0.95em;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
}
.reason-bullets li{
  margin: 0;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 999px;
  padding: 5px 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}
.reason-bullets li::before{
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #6ecadc;
  opacity: 0.9;
}
.levels{
  display:flex;
  flex-wrap:wrap;
  gap:8px 10px;
  margin-top:0;
  font-size:0.9em;
  color:#444;
}
.levels span{
  background:#fff;
  border:1px solid #eee;
  border-radius:10px;
  padding:5px 9px;
}
.signal-body{
  display:grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  margin-top: 6px;
}
.signal-levels-block{
  align-self: start;
}
.signal-levels-block .levels{
  justify-content: flex-end;
}

@media (max-width: 900px) {
  .signal-body{ grid-template-columns: 1fr; }
  .signal-levels-block .levels{ justify-content: flex-start; }
}
.levels b{
  font-weight:700;
  color:#333;
  margin-right:6px;
}
.chip{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(255,255,255,0.9);
  font-weight: 700;
  font-size: 0.88em;
  color:#333;
  white-space: nowrap;
}
.chip.good{ border-color: rgba(41,156,100,0.22); background: rgba(41,156,100,0.10); color:#1f7a4a; }
.chip.bad{ border-color: rgba(197,86,74,0.22); background: rgba(197,86,74,0.10); color:#b24b46; }
.chip.neutral{ border-color: rgba(110,202,220,0.22); background: rgba(110,202,220,0.10); color:#1f4a51; }
.chip.muted{ border-color: rgba(0,0,0,0.06); background: rgba(0,0,0,0.03); color:#666; font-weight:600; }
.empty { border-left-color: #ccc; }

@media (max-width: 1450px) {
  .cards-six { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 1100px) {
  .cards, .cards-six { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .two-column { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .top-nav__inner{
    padding: 10px 14px;
  }
  .main {
    padding: 22px 16px 34px 16px;
  }
  .cards, .cards-six { grid-template-columns: 1fr; }
  .section-title {
    display: block;
  }
  .section-title span {
    display: block;
    margin-top: 6px;
    text-align: left;
  }
}
