/* Matches the dashboard's summary and account cards. */
.tzr-bybit-card {
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(190px, 1.35fr) minmax(0, 1fr) minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  min-height: 112px;
  margin: 0;
  padding: 21px 22px;
  border: 1px solid rgba(96, 165, 250, .15);
  border-radius: 18px;
  background: linear-gradient(155deg, #151717, #0f1111);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .025);
  color: #edf0f3;
  font-family: inherit;
}

.tzr-bybit-card[hidden],
.tzr-bybit-card [hidden] {
  display: none !important;
}

.tzr-bybit-brand {
  display: flex;
  align-items: center;
  gap: 15px;
  min-width: 0;
}

.tzr-bybit-logo {
  box-sizing: border-box;
  display: grid;
  place-items: center;
  flex: 0 0 55px;
  height: 55px;
  border: 1px solid rgba(96, 165, 250, .18);
  border-radius: 15px;
  background: rgba(59, 130, 246, .075);
  color: #82adf4;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .04em;
}

.tzr-bybit-brand strong {
  display: block;
  color: #edf0f3;
  font-size: 16px;
  font-weight: 850;
  line-height: 1.4;
  letter-spacing: -.02em;
}

.tzr-bybit-brand div > span {
  display: block;
  margin-top: 5px;
  color: #7f8b97;
  font-size: 10px;
  font-weight: 650;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.tzr-bybit-value {
  min-width: 0;
  padding-left: 22px;
  border-left: 1px solid rgba(255, 255, 255, .065);
}

.tzr-bybit-value > span {
  display: block;
  margin-bottom: 10px;
  color: #7f8b97;
  font-size: 11px;
  font-weight: 850;
  line-height: 1.4;
  letter-spacing: .055em;
  text-transform: uppercase;
}

.tzr-bybit-value > strong {
  display: block;
  color: #edf0f3;
  font-size: 27px;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -.035em;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.tzr-bybit-tools {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  min-width: 0;
}

.tzr-bybit-status {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #7f8b97;
  font-size: 10px;
  font-weight: 650;
  line-height: 1.4;
  white-space: nowrap;
}

.tzr-bybit-status::before {
  content: '';
  flex: 0 0 5px;
  height: 5px;
  border-radius: 50%;
  background: #64748b;
}

.tzr-bybit-card[data-state="ok"] .tzr-bybit-status::before {
  background: #39cf88;
  box-shadow: 0 0 7px rgba(57, 207, 136, .2);
}

.tzr-bybit-card[data-state="warning"] .tzr-bybit-status {
  color: #d6b57b;
}

.tzr-bybit-card[data-state="warning"] .tzr-bybit-status::before {
  background: #d6b57b;
}

.tzr-bybit-tools > button {
  padding: 8px 12px;
  border: 1px solid rgba(96, 165, 250, .17);
  border-radius: 9px;
  background: rgba(59, 130, 246, .065);
  color: #98bdf7;
  font-family: inherit;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.4;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s ease, border-color .15s ease;
}

.tzr-bybit-tools > button:hover {
  border-color: rgba(96, 165, 250, .32);
  background: rgba(59, 130, 246, .12);
}

.tzr-bybit-tools > button:focus-visible {
  outline: 2px solid #78aaff;
  outline-offset: 3px;
}

.tzr-bybit-tools > button:disabled {
  opacity: .55;
  cursor: wait;
}

.tzr-bybit-message {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, .065);
  color: #d6b57b;
  font-size: 12px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

@media (max-width: 1200px) {
  .tzr-bybit-card {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px 22px;
  }

  .tzr-bybit-brand {
    grid-column: 1;
    grid-row: 1;
  }

  .tzr-bybit-tools {
    grid-column: 2;
    grid-row: 1;
  }

  .tzr-bybit-value {
    grid-row: 2;
    padding: 17px 0 0;
    border-top: 1px solid rgba(255, 255, 255, .065);
    border-left: 0;
  }
}

@media (max-width: 600px) {
  .tzr-bybit-card {
    gap: 18px 14px;
    padding: 18px;
    border-radius: 16px;
  }

  .tzr-bybit-brand {
    grid-column: 1 / -1;
    gap: 12px;
  }

  .tzr-bybit-logo {
    flex-basis: 44px;
    height: 44px;
    border-radius: 12px;
    font-size: 9px;
  }

  .tzr-bybit-brand strong {
    font-size: 15px;
  }

  .tzr-bybit-value > span {
    min-height: 2.8em;
    margin-bottom: 7px;
    font-size: 9px;
  }

  .tzr-bybit-value > strong {
    font-size: 22px;
  }

  .tzr-bybit-tools {
    grid-column: 1 / -1;
    grid-row: 3;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, .065);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tzr-bybit-tools > button {
    transition: none;
  }
}
