:root {
  color-scheme: light;
  font-family: Arial, "Microsoft YaHei", sans-serif;
  background: #f4f6f8;
  color: #1f2933;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

.shell {
  width: min(1180px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
  overflow: hidden;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-end;
  margin-bottom: 18px;
}

h1 {
  margin: 0 0 8px;
  font-size: clamp(24px, 3vw, 36px);
  line-height: 1.12;
}

p {
  margin: 0;
  color: #617080;
}

.controls {
  display: flex;
  gap: 10px;
}

input,
select {
  height: 40px;
  border: 1px solid #c8d1db;
  border-radius: 6px;
  padding: 0 12px;
  background: #fff;
  color: #1f2933;
  font-size: 14px;
}

input {
  width: 220px;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.stats div {
  background: #fff;
  border: 1px solid #d9e1e8;
  border-radius: 8px;
  padding: 14px 16px;
}

.stats span {
  display: block;
  margin-bottom: 6px;
  color: #617080;
  font-size: 13px;
}

.stats strong {
  display: block;
  min-height: 24px;
  font-size: 20px;
}

.table-wrap {
  width: 100%;
  max-width: 100%;
  overflow: visible;
  background: #fff;
  border: 1px solid #d9e1e8;
  border-radius: 8px;
}

table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid #e6edf2;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
}

th {
  background: #eef3f7;
  color: #435466;
  font-size: 13px;
}

td:nth-child(1),
td:nth-child(5),
td:nth-child(6) {
  text-align: right;
  white-space: nowrap;
}

th:nth-child(1),
td:nth-child(1) {
  width: 62px;
}

th:nth-child(2),
td:nth-child(2) {
  width: 34%;
}

th:nth-child(3),
td:nth-child(3) {
  width: 96px;
}

th:nth-child(4),
td:nth-child(4) {
  width: 76px;
}

th:nth-child(5),
td:nth-child(5) {
  width: 82px;
}

th:nth-child(6),
td:nth-child(6) {
  width: 130px;
}

tr:last-child td {
  border-bottom: 0;
}

.company {
  display: block;
  font-weight: 700;
  line-height: 1.35;
}

.symbol-link {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  color: #155e75;
  font-weight: 700;
  text-decoration: none;
}

.symbol-link:hover {
  text-decoration: underline;
}

.symbol-menu {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.symbol-popover {
  position: absolute;
  left: 50%;
  top: calc(100% + 6px);
  z-index: 20;
  display: grid;
  gap: 4px;
  width: 112px;
  padding: 6px;
  background: #ffffff;
  border: 1px solid #d8e2ea;
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
}

.symbol-popover::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -8px;
  height: 8px;
}

.symbol-menu:hover .symbol-popover,
.symbol-menu:focus-within .symbol-popover {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

.symbol-popover a {
  display: block;
  padding: 7px 8px;
  border-radius: 6px;
  color: #0f172a;
  font-size: 12px;
  line-height: 1.1;
  text-align: left;
  text-decoration: none;
  white-space: nowrap;
}

.symbol-popover a:hover,
.symbol-popover a:focus {
  background: #eaf5f8;
  color: #155e75;
  outline: none;
}

.subtle {
  display: block;
  margin-top: 4px;
  color: #69798a;
  font-size: 12px;
}

.description,
.products {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  line-height: 1.35;
}

.description {
  color: #3f6f68;
}

.products {
  color: #596779;
}

.cap-detail {
  display: block;
  margin-top: 4px;
  color: #69798a;
  font-size: 12px;
  line-height: 1.35;
  white-space: normal;
}

.quality {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 5px;
  border-radius: 5px;
  background: #fff3cd;
  color: #7a5b00;
  font-size: 11px;
}

.description span,
.products span {
  color: #617080;
}

.name-zh {
  display: block;
  margin-top: 4px;
  color: #1f2933;
  font-size: 13px;
}

.name-zh::before {
  content: "中文名：";
  color: #617080;
}


@media (max-width: 720px) {
  .topbar {
    display: block;
  }

  .controls {
    margin-top: 16px;
    flex-direction: column;
  }

  input,
  select {
    width: 100%;
  }

  .stats {
    grid-template-columns: 1fr;
  }

  .shell {
    width: min(100vw - 20px, 1180px);
    padding-top: 18px;
    overflow: visible;
  }

  .table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  table {
    min-width: 620px;
  }

  th,
  td {
    padding: 10px 12px;
  }

  th:nth-child(2),
  td:nth-child(2) {
    width: 220px;
  }
}
