* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: #eef2f6;
  color: #17202a;
  font-family: Arial, Helvetica, sans-serif;
}
main {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 14px;
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
h1 { margin: 0; font-size: 26px; }
p { margin: 4px 0 0; color: #64748b; }
button, select {
  min-height: 44px;
  border: 1px solid #cbd5e1;
  background: white;
  color: #17202a;
  font: inherit;
}
button {
  padding: 0 16px;
  cursor: pointer;
  font-weight: 700;
}
button.active {
  background: #0f766e;
  border-color: #0f766e;
  color: white;
}
nav {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}
nav button { flex: 1; }
.view-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}
.view-tabs button {
  flex: 1;
}
label {
  display: block;
  margin-bottom: 6px;
  color: #475569;
  font-weight: 700;
}
select {
  width: 100%;
  padding: 0 10px;
  margin-bottom: 14px;
}
.table-scroll {
  position: relative;
}
.table-scroll::before,
.table-scroll::after {
  content: "";
  position: absolute;
  top: 1px;
  bottom: 1px;
  z-index: 2;
  display: none;
  width: 30px;
  pointer-events: none;
}
.table-scroll::before {
  left: 1px;
  background: linear-gradient(to right, rgba(15, 23, 42, 0.22), rgba(15, 23, 42, 0));
}
.table-scroll::after {
  right: 1px;
  background: linear-gradient(to left, rgba(15, 23, 42, 0.22), rgba(15, 23, 42, 0));
}
.table-scroll.can-scroll-left::before,
.table-scroll.can-scroll-right::after {
  display: block;
}
.table-box {
  overflow-x: auto;
  background: white;
  border: 1px solid #cbd5e1;
  -webkit-overflow-scrolling: touch;
}
table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}
th, td {
  padding: 10px 12px;
  border-bottom: 1px solid #dbe3ee;
  text-align: left;
}
th {
  background: #dfe9f3;
  font-size: 14px;
}
td:first-child, th:first-child {
  width: 86px;
  text-align: center;
  font-weight: 700;
}
#empty {
  margin-top: 36px;
  padding: 30px 12px;
  background: white;
  border: 1px solid #cbd5e1;
  text-align: center;
}
#empty h2 { margin: 0; }
.archive-note {
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.45;
}
.archive-note a {
  color: #0f766e;
  font-weight: 700;
}
.error { color: #b42318; }
@media (max-width: 640px) {
  header { align-items: stretch; flex-direction: column; }
  h1 { font-size: 22px; }
  #refresh { width: 100%; }
  nav, .view-tabs { flex-direction: column; }
}
