.live-market {
  min-width: 0;
  border-radius: 16px;
  background: white;
  border: 1px solid #e9e9e9;
  overflow: hidden;
  font-family: Poppins, sans-serif;
}
.market-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 25px 26px;
}
.market-header h2 {
  font-size: 21px;
  font-weight: 500;
  color: #151f6d;
  margin: 5px 0 7px;
}
.market-header p {
  font-size: 11px;
  color: #737373;
  margin: 0;
}
.market-status-area {
  display: flex;
  align-items: center;
  gap: 16px;
}
.market-connection {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 10px;
  color: #737373;
}
.market-connection i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #151f6d;
}
.market-connection[data-state='live'] i {
  background: #a3e635;
  box-shadow: 0 0 0 4px rgb(163 230 53 / 12%);
}
.market-connection[data-state='error'] i,
.market-connection[data-state='stale'] i {
  background: #151f6d;
  box-shadow: none;
}
.market-time {
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  color: #737373;
}
.market-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 26px 22px;
  border-bottom: 1px solid #e9e9e9;
}
.market-groups {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.market-groups button {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 39px;
  border: 1px solid #e9e9e9;
  border-radius: 9px;
  background: white;
  color: #737373;
  padding: 10px 15px;
  font-family: inherit;
  font-size: 11px;
  cursor: pointer;
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}
.market-groups button[aria-current] {
  color: white;
  background: #151f6d;
  border-color: #151f6d;
}
.market-groups small {
  font-size: 9px;
  opacity: 0.7;
}
.market-groups button:hover {
  box-shadow: 0 5px 18px rgb(163 230 53 / 30%);
  transform: translateY(-2px);
}
.market-search {
  display: flex !important;
  align-items: center;
  position: relative;
  flex-shrink: 0;
}
.market-search .i {
  position: absolute;
  left: 12px;
  width: 14px;
  height: 14px;
  color: #737373;
}
.market-search input {
  padding-left: 35px !important;
  width: 220px;
}
.market-focus {
  padding: 25px 26px;
  border-bottom: 1px solid #e9e9e9;
  min-width: 0;
}
.market-focus:empty {
  display: none;
}
.market-focus-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.market-focus-heading > div > span {
  font-size: 10px;
  color: #737373;
}
.market-focus-heading h3 {
  font-size: 20px;
  font-weight: 500;
  color: #151f6d;
  margin: 6px 0 0;
}
.market-change {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  white-space: nowrap;
  padding: 5px 9px;
  border-radius: 6px;
  background: rgb(21 31 109 / 4%);
  color: #151f6d;
  font-variant-numeric: tabular-nums;
}
.market-change.up {
  background: rgb(163 230 53 / 14%);
}
.market-focus-content {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 35px;
  align-items: center;
  margin-top: 18px;
}
.market-focus-prices {
  display: grid;
  gap: 20px;
}
.market-focus-prices > div {
  border-left: 2px solid #a3e635;
  padding: 0 0 0 14px;
}
.market-focus-prices > div:last-child {
  border-left-color: #151f6d;
}
.market-focus-prices span {
  font-size: 10px;
  color: #737373;
  display: block;
}
.market-focus-prices strong {
  display: block;
  font-size: 27px;
  font-weight: 500;
  color: #151f6d;
  margin: 5px 0;
  font-variant-numeric: tabular-nums;
}
.market-focus-prices small {
  font-size: 9px;
  color: #737373;
}
.market-focus-chart {
  min-width: 0;
}
.market-chart {
  display: block;
  width: 112px;
  height: 36px;
}
.market-chart.large {
  width: 100%;
  height: 210px;
}
.market-chart-line {
  fill: none;
  stroke: #151f6d;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.market-chart.large .market-chart-line {
  stroke-width: 2;
}
.market-chart-area {
  fill: rgb(163 230 53 / 12%);
}
.market-chart-grid line {
  stroke: #e9e9e9;
  stroke-width: 1;
  stroke-dasharray: 3 6;
  vector-effect: non-scaling-stroke;
}
.market-chart-time {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 9px;
  color: #737373;
  margin-top: 8px;
}
.market-chart-empty {
  display: grid;
  align-content: center;
  font-size: 9px;
  color: #737373;
  width: 112px;
  min-height: 36px;
  white-space: normal;
}
.market-chart-empty.large {
  width: 100%;
  height: 210px;
  justify-content: center;
  font-size: 11px;
  border: 1px dashed #e9e9e9;
  border-radius: 10px;
}
.market-table {
  width: 100%;
  border-collapse: collapse;
}
.market-table th {
  font-size: 10px;
  font-weight: 500;
  color: #737373;
  text-align: left;
  white-space: nowrap;
  padding: 14px 24px;
  background: #fafafa;
  border-bottom: 1px solid #e9e9e9;
}
.market-table td {
  padding: 15px 24px;
  font-size: 11px;
  border-bottom: 1px solid #f3f3f3;
  white-space: nowrap;
  color: #292929;
}
.market-table td:last-child {
  color: #737373;
  font-size: 10px;
}
.market-table tr:last-child td {
  border-bottom: 0;
}
.market-table tr.selected {
  background: rgb(21 31 109 / 2%);
}
.market-product {
  border: 0;
  background: none;
  color: #151f6d;
  font: inherit;
  font-weight: 500;
  padding: 5px 0;
  cursor: pointer;
  text-align: left;
}
.market-product:hover {
  text-decoration: underline;
}
.market-product small,
.market-number small {
  display: block;
  font-weight: 400;
  color: #737373;
  font-size: 9px;
  margin-top: 6px;
}
.market-table th:nth-child(4),
.market-table th:nth-child(5),
.market-number {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.market-table td.market-number {
  font-size: 14px;
  font-weight: 500;
  color: #151f6d;
}
.market-tick {
  animation: market-tick 1.1s ease-out;
}
.market-footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  border-top: 1px solid #e9e9e9;
  padding: 17px 24px;
  font-size: 9px;
  color: #737373;
  line-height: 1.8;
}
.market-loading {
  padding: 45px 22px;
  font-size: 12px;
  color: #737373;
  text-align: center;
}
.market-loading .btn {
  display: block;
  margin: 15px auto 0;
}
.market-compact-head {
  display: flex;
  justify-content: space-between;
  font-size: 9px;
  color: #737373;
  padding: 0 0 9px;
  border-bottom: 1px solid #e9e9e9;
}
.market-compact-row {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 0 !important;
  border-bottom: 1px solid #e9e9e9;
}
.market-compact-row > span {
  font-size: 10px;
  color: #737373;
}
.market-compact-row > div {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.market-compact-row strong {
  font-size: 12px;
  font-weight: 500;
  color: #151f6d;
  font-variant-numeric: tabular-nums;
}
.market-compact-row strong:last-child {
  font-size: 11px;
  opacity: 0.7;
}
.market-compact-row small {
  display: block;
  font-size: 9px;
}
.market-compact-note {
  font-size: 9px !important;
  color: #737373;
  line-height: 1.8;
  margin: 14px 0 0;
}
.market-groups button:focus-visible,
.market-product:focus-visible {
  outline: 2px solid #a3e635;
  outline-offset: 3px;
}
@keyframes market-tick {
  from {
    background: rgb(163 230 53 / 22%);
  }
  to {
    background: transparent;
  }
}
@media (max-width: 900px) {
  .market-focus-content {
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 20px;
  }
  .market-focus-prices strong {
    font-size: 23px;
  }
  .market-table td,
  .market-table th {
    padding: 14px 18px;
  }
}
@media (max-width: 600px) {
  .market-header {
    padding: 20px;
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
  }
  .market-status-area {
    width: 100%;
    justify-content: space-between;
  }
  .market-toolbar {
    padding: 0 20px 20px;
    flex-direction: column;
    align-items: stretch;
  }
  .market-search input {
    width: 100%;
  }
  .market-groups {
    gap: 6px;
  }
  .market-groups button {
    flex: 1;
    padding: 10px;
    justify-content: center;
    font-size: 10px;
  }
  .market-focus {
    padding: 20px;
  }
  .market-focus-content {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .market-focus-prices {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }
  .market-focus-prices strong {
    font-size: 24px;
  }
  .market-focus-heading h3 {
    font-size: 18px;
  }
  .market-chart.large {
    height: 160px;
  }
  .market-chart-time {
    font-size: 8px;
  }
  .market-footer {
    padding: 15px 20px;
    flex-direction: column;
  }
  .market-table td,
  .market-table th {
    padding: 14px 16px;
  }
  .market-table td.market-number {
    font-size: 12px;
  }
  .market-focus .market-chart-empty.large {
    height: 160px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .live-market * {
    animation: none !important;
    transition: none !important;
  }
}

.market-search {
  flex-direction: row !important;
}
.market-search .i {
  top: 50%;
  transform: translateY(-50%);
}
@media (max-width: 600px) {
  .market-table th:nth-child(3),
  .market-table td:nth-child(3),
  .market-table th:nth-child(6),
  .market-table td:nth-child(6) {
    display: none;
  }
  .market-table {
    table-layout: fixed;
  }
  .market-table th,
  .market-table td {
    padding: 12px 8px;
    white-space: normal;
  }
  .market-table th:first-child {
    width: 30%;
  }
  .market-table th:nth-child(2) {
    width: 20%;
  }
  .market-table th:nth-child(4),
  .market-table th:nth-child(5) {
    width: 25%;
  }
  .market-table td.market-number {
    font-size: 11px;
  }
  .market-table .market-change {
    padding: 4px;
    font-size: 9px;
  }
  .market-product {
    font-size: 10px;
    overflow-wrap: anywhere;
  }
}
