:root {
  font-family: Inter, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: #172b3b;
  background: #f3f6fa;
  font-size: 14px;
  line-height: 1.6;
  --blue: #006caa;
  --line: #e0e7ee;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
[hidden] {
  display: none !important;
}
header {
  background: white;
  border-bottom: 1px solid var(--line);
  height: 76px;
  padding: 0 max(24px, calc((100vw - 1280px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.brand {
  display: flex;
  gap: 16px;
  align-items: center;
  text-decoration: none;
  color: #244254;
}
.brand b {
  font-size: 23px;
  letter-spacing: 0.5px;
  color: #075a85;
}
.brand span {
  border-left: 1px solid var(--line);
  padding-left: 16px;
}
#account {
  display: flex;
  align-items: center;
  gap: 14px;
}
main {
  max-width: 1280px;
  margin: 36px auto;
  padding: 0 24px 40px;
}
h1 {
  font-size: 30px;
  line-height: 1.3;
  margin: 7px 0 12px;
}
h2 {
  font-size: 21px;
  margin: 0 0 16px;
}
h3 {
  font-size: 15px;
  margin: 22px 0 10px;
}
.eyebrow {
  font-size: 12px;
  letter-spacing: 0.9px;
  font-weight: 700;
  color: #437c99;
}
.muted {
  color: #6d7e8c;
  margin: 0 0 20px;
}
.card {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px;
  box-shadow: 0 3px 12px #1d476105;
}
.login {
  max-width: 460px;
  margin: 10vh auto;
  padding: 36px;
}
form {
  display: grid;
  gap: 18px;
}
label {
  display: grid;
  gap: 6px;
  font-weight: 600;
}
input,
select,
textarea {
  font: inherit;
  border: 1px solid #cdd7e1;
  border-radius: 7px;
  padding: 10px 12px;
  color: inherit;
  background: white;
  width: 100%;
  min-width: 0;
}
input:focus,
select:focus,
textarea:focus {
  outline: 3px solid #0090d825;
  border-color: #007bb9;
}
textarea {
  resize: vertical;
}
button {
  font: inherit;
  border: 0;
  border-radius: 7px;
  padding: 10px 18px;
  background: var(--blue);
  color: white;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
}
button:hover {
  filter: brightness(0.94);
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
.secondary {
  background: white;
  color: #33586f;
  border: 1px solid #cdd7e1;
}
.subtle {
  background: transparent;
  color: #547080;
  padding: 7px 10px;
}
.page-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.stats {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin: 22px 0 28px;
}
.stat {
  padding: 18px 22px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
}
.stat strong {
  display: block;
  font-size: 28px;
  font-weight: 650;
}
.stat span {
  color: #728491;
}
.tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
  gap: 10px;
  margin-bottom: 22px;
}
.tabs button {
  background: transparent;
  color: #637c8e;
  border-radius: 0;
  border-bottom: 3px solid transparent;
  padding: 12px 18px;
}
.tabs button.active {
  color: var(--blue);
  border-bottom-color: var(--blue);
}
.filters {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
}
.filters input {
  flex: 1;
}
.filters select {
  width: 150px;
}
.table-wrap {
  padding: 0;
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
th {
  font-size: 12px;
  background: #f8fafc;
  color: #6c8191;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 17px 18px;
  border-bottom: 1px solid #edf1f5;
}
tbody tr:last-child td {
  border: 0;
}
.row-link {
  background: none;
  color: #1c4660;
  padding: 0;
  text-align: left;
  white-space: normal;
  line-height: 1.6;
}
.row-sub {
  font-size: 11px;
  color: #83929e;
}
.badge {
  font-size: 12px;
  border-radius: 20px;
  padding: 4px 10px;
  background: #eaf3f8;
  color: #287395;
  white-space: nowrap;
}
.badge.new {
  background: #fff4d9;
  color: #91691b;
}
.badge.resolved {
  background: #e5f5ee;
  color: #2f8060;
}
.badge.closed {
  background: #edf0f4;
  color: #778390;
}
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #718594;
  margin-top: 18px;
}
.pagination button {
  margin-left: 8px;
}
.empty {
  text-align: center;
  padding: 44px;
  color: #8696a3;
}
.error {
  color: #b63434;
  white-space: pre-wrap;
}
.publish {
  margin-top: 20px;
}
.publish form {
  max-width: 780px;
  margin-top: 22px;
}
.code {
  font:
    12px/1.7 Consolas,
    monospace;
  background: #f6f8fa;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 12px;
  white-space: pre-wrap;
  word-break: break-all;
  max-height: 300px;
  overflow: auto;
}
.code:empty {
  display: none;
}
.release-entry {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.release-entry:last-child {
  border: 0;
}
dialog {
  width: min(780px, calc(100vw - 32px));
  padding: 0;
  border: 0;
  border-radius: 16px;
  box-shadow: 0 20px 80px #102d4e33;
  max-height: 90vh;
}
dialog::backdrop {
  background: #142e4666;
}
.detail-head {
  padding: 24px 28px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--line);
}
.detail-head h2 {
  margin: 5px 0 0;
}
.detail-body {
  padding: 20px 28px 28px;
  overflow: auto;
}
.meta {
  display: grid;
  grid-template-columns: 90px 1fr;
  margin: 0;
  font-size: 13px;
}
.meta dt {
  color: #7b8e9a;
}
.meta dd {
  margin: 0 0 7px;
  word-break: break-word;
}
.message {
  white-space: pre-wrap;
  word-break: break-word;
  background: #f7f9fb;
  border-radius: 8px;
  padding: 18px;
}
.images {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 14px 0 22px;
}
.images a {
  width: calc(50% - 6px);
  color: #477288;
  text-decoration: none;
  word-break: break-word;
}
.images img {
  display: block;
  border: 1px solid var(--line);
  border-radius: 7px;
  width: 100%;
  height: 160px;
  object-fit: contain;
  background: #fafcfd;
}
.images span {
  font-size: 11px;
}
details {
  margin: 16px 0 22px;
}
details summary {
  color: #53748a;
  cursor: pointer;
}
.save-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.save-row span {
  color: #2a865e;
  font-size: 13px;
}
#toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  background: #203d50;
  color: white;
  border-radius: 9px;
  padding: 12px 24px;
  box-shadow: 0 5px 20px #203d5033;
  z-index: 10;
}
@media (max-width: 760px) {
  header {
    padding: 0 18px;
  }
  .brand {
    gap: 10px;
  }
  .brand span {
    font-size: 12px;
  }
  .brand b {
    font-size: 19px;
  }
  main {
    padding: 0 16px;
    margin-top: 24px;
  }
  .stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .stat {
    padding: 12px;
  }
  .filters {
    flex-wrap: wrap;
  }
  .filters input {
    flex-basis: 100%;
  }
  .filters select {
    flex: 1;
  }
  .filters button {
    padding: 8px 12px;
  }
  .page-head {
    align-items: flex-start;
  }
  .page-head button {
    margin-top: 6px;
  }
  h1 {
    font-size: 25px;
  }
  .card {
    padding: 18px;
  }
  .table-wrap {
    padding: 0;
  }
  th,
  td {
    padding: 12px;
  }
  .detail-body,
  .detail-head {
    padding: 18px;
  }
  .images a {
    width: 100%;
  }
  .login {
    margin-top: 6vh;
  }
  .pagination {
    font-size: 12px;
  }
}
