:root {
  font:
    14px/1.6 -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    "Microsoft YaHei",
    sans-serif;
  color: #223149;
  background: #f3f5f9;
  --navy: #18263c;
  --accent: #aa7130;
  --muted: #7a879b;
  --line: #e6eaf0;
  --blue: #2c6198;
  --red: #bc4944;
  --green: #318369;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  border: 1px solid #d9dfe8;
  border-radius: 7px;
  background: #fff;
  color: #344860;
  padding: 8px 14px;
  min-height: 38px;
}
button:hover {
  background: #f1f5fa;
}
button:disabled {
  cursor: default;
  opacity: 0.5;
}
button.primary {
  background: var(--blue);
  border-color: var(--blue);
  color: #fff;
}
button.gold {
  background: #aa7130;
  border-color: #aa7130;
  color: #fff;
}
button.danger {
  color: var(--red);
}
a {
  color: var(--blue);
  text-decoration: none;
}
input,
select,
textarea {
  border: 1px solid #d9dfe8;
  border-radius: 7px;
  padding: 9px 12px;
  width: 100%;
  background: #fff;
  color: #223149;
  min-width: 0;
}
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid #88a9ce;
  outline-offset: 1px;
}
input[type="checkbox"] {
  width: auto;
}
select {
  -webkit-appearance: none;
  appearance: none;
  min-height: 44px;
  padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='m4 6 4 4 4-4' stroke='%237a879b' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px 16px;
  text-overflow: ellipsis;
}
label {
  display: grid;
  gap: 6px;
  color: #56657a;
  font-size: 13px;
}
.hint {
  color: var(--muted);
  font-size: 12px;
}
.error {
  color: var(--red);
}
.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 440px;
  gap: 70px;
  align-items: center;
  max-width: 1080px;
  margin: auto;
  padding: 40px;
}
.login-story h1 {
  font-size: 40px;
  color: #aa7130;
  font-weight: 800;
  line-height: 1.3;
  margin: 0;
  letter-spacing: 1px;
}
.login-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 36px;
  box-shadow: 0 15px 45px #2439520c;
}
.login-card h2 {
  margin: 0;
  font-size: 25px;
}
.login-card form {
  display: grid;
  gap: 20px;
  margin-top: 28px;
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 225px;
  background: var(--navy);
  color: #c0cad8;
  z-index: 10;
  display: flex;
  flex-direction: column;
}
.brand {
  padding: 27px 23px 23px;
  border-bottom: 1px solid #ffffff0b;
  color: #f6dfbc;
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 2px;
}
.brand small {
  display: block;
  color: #8998ad;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 3px;
  margin-top: 3px;
}
.sidebar nav {
  padding: 18px 12px;
  overflow: auto;
  flex: 1;
}
.sidebar nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #afbbcd;
  padding: 11px 14px;
  border-radius: 7px;
  margin: 3px 0;
}
.sidebar nav a:hover,
.sidebar nav a.active {
  background: #2b3c54;
  color: #f5d6a7;
}
.nav-symbol {
  width: 22px;
  font-size: 17px;
  text-align: center;
}
.sidebar footer {
  padding: 17px 22px;
  font-size: 11px;
  color: #7688a2;
}
.workspace {
  margin-left: 225px;
}
.topbar {
  height: 75px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 0 35px;
}
.topbar .right {
  display: flex;
  align-items: center;
  gap: 14px;
}
.avatar {
  display: inline-grid;
  place-items: center;
  background: #e7edf4;
  color: #426484;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-weight: 600;
}
.role {
  font-size: 11px;
  color: var(--muted);
}
.content {
  padding: 28px 35px 50px;
  max-width: 1700px;
  margin: auto;
}
.page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 23px;
}
.page-head h1 {
  font-size: 23px;
  margin: 0;
  font-weight: 650;
}
.page-head p {
  margin: 5px 0 0;
  font-size: 12px;
  color: var(--muted);
}
.actions,
.filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.filters {
  align-items: flex-end;
  margin-bottom: 18px;
}
.filters input,
.filters select,
.filters > button {
  height: 44px;
  min-height: 44px;
}
.filters input,
.filters select {
  width: auto;
  max-width: 230px;
  line-height: 1.4;
}
.filters select {
  min-width: 120px;
}
.filters label {
  min-width: 145px;
}
.filters label input,
.filters label select {
  width: 100%;
  font-size: 14px;
}
.bill-order {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  margin: 16px 0;
}
.bill-order .panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.bill-calculations {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.bill-calculations small {
  color: var(--muted);
}
.bill-calculations p {
  font-size: 12px;
  overflow-wrap: anywhere;
}
.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 22px;
}
.card,
.panel {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 3px 8px #32486203;
}
.card {
  padding: 23px;
}
.card .label {
  color: #7d8a9d;
  font-size: 12px;
}
.card .number {
  font-size: 29px;
  letter-spacing: 0.1px;
  font-weight: 650;
  margin: 8px 0;
}
.card .foot {
  font-size: 11px;
  color: #929eb0;
}
.card.gold .number {
  color: #9e6a2f;
}
.card.green .number {
  color: #318369;
}
.grid-two {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 20px;
  margin-bottom: 22px;
}
.panel {
  padding: 22px;
  margin-bottom: 20px;
}
.panel h2 {
  font-size: 16px;
  margin: 0 0 20px;
}
.panel .panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 18px;
}
.panel .panel-head h2 {
  margin: 0;
}
.table-wrap {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  white-space: nowrap;
}
th {
  background: #f7f9fc;
  color: #8190a5;
  font-size: 12px;
  font-weight: 500;
  text-align: left;
}
td,
th {
  padding: 13px 14px;
  border-bottom: 1px solid #edf0f5;
}
td {
  font-size: 12px;
}
tbody tr:last-child td {
  border-bottom: 0;
}
td button {
  padding: 3px 9px;
  min-height: 28px;
  font-size: 12px;
  margin-right: 5px;
}
.empty {
  padding: 50px 16px;
  text-align: center;
  color: #9aa5b5;
}
.tag {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 4px;
  background: #e9f0f8;
  color: #406a98;
  font-size: 11px;
}
.tag.green {
  background: #e8f3ee;
  color: #347d60;
}
.tag.gold {
  background: #fbf1dc;
  color: #9b6b29;
}
.tag.red {
  background: #faeae8;
  color: #a34c47;
}
.mono {
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 12px;
}
.money {
  font-variant-numeric: tabular-nums;
  font-weight: 550;
}
.muted {
  color: #8190a3;
}
.pagination {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 13px;
  margin-top: 18px;
  font-size: 12px;
  color: #8996a7;
}
.notice {
  padding: 13px 17px;
  border-radius: 7px;
  background: #edf3f9;
  color: #5a7899;
  border: 1px solid #dde8f3;
  margin-bottom: 20px;
  font-size: 12px;
}
.notice.gold {
  background: #fbf4e7;
  border-color: #f1e1c4;
  color: #9a773f;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 17px;
}
.form-grid .wide {
  grid-column: 1/-1;
}
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 23px;
}
.form-error {
  min-height: 22px;
  color: #bc4944;
  font-size: 12px;
  margin-top: 12px;
}
.chart {
  height: 230px;
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  gap: 14px;
  padding: 20px 12px 0;
}
.bar-column {
  height: 100%;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-direction: column;
  gap: 8px;
}
.bar-value {
  font-size: 10px;
  color: #8392a7;
}
.bar {
  width: 100%;
  max-width: 40px;
  background: linear-gradient(#6792ba, #345f8c);
  border-radius: 5px 5px 0 0;
  min-height: 3px;
}
.bar-date {
  font-size: 11px;
  color: #8b98ac;
}
.mini-list {
  display: grid;
  gap: 15px;
}
.mini-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #eef0f4;
  padding-bottom: 12px;
  font-size: 12px;
}
.detail-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin: 20px 0;
}
.detail-summary > div {
  background: #f6f8fb;
  padding: 15px;
  border-radius: 7px;
}
.detail-summary small {
  display: block;
  color: #8190a5;
}
.detail-summary strong {
  font-size: 20px;
}
.path-step {
  padding: 16px;
  border: 1px solid #e2e7ef;
  border-radius: 8px;
  margin: 12px 0;
}
.path-step h3 {
  font-size: 14px;
  margin: 0 0 8px;
}
.path-step p {
  font-size: 12px;
  margin: 5px 0;
  color: #6d7b90;
}
.path-step .retained {
  font-weight: 650;
  color: #aa7130;
}
.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  font-size: 13px;
}
.info-grid > div {
  border-bottom: 1px solid #eef0f4;
  padding: 7px 0;
}
.info-grid small {
  color: #8b98aa;
  margin-right: 12px;
}
.settings-form {
  display: grid;
  gap: 17px;
  max-width: 460px;
}
dialog {
  border: 0;
  border-radius: 12px;
  width: min(880px, calc(100vw - 28px));
  max-height: 90vh;
  padding: 0;
  box-shadow: 0 25px 80px #0004;
}
dialog::backdrop {
  background: #13213480;
  backdrop-filter: blur(3px);
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 26px;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 1;
}
.modal-head h2 {
  margin: 0;
  font-size: 19px;
}
.modal-head button {
  font-size: 22px;
  border: 0;
  padding: 0 10px;
}
#modalBody {
  padding: 24px 26px;
}
#toast {
  position: fixed;
  top: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: #203751;
  color: #fff;
  padding: 12px 22px;
  border-radius: 7px;
  box-shadow: 0 6px 20px #0002;
  z-index: 100;
}
textarea {
  min-height: 100px;
  resize: vertical;
}
.mobile-toggle {
  display: none;
}
.topbar-title {
  font-size: 12px;
  color: #8a98aa;
}
.small {
  font-size: 11px;
}
.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.daily-cell {
  font-size: 11px;
}
.footer-note {
  color: #a0aab7;
  text-align: center;
  font-size: 11px;
  margin-top: 25px;
}
@media (max-width: 1200px) {
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-two {
    grid-template-columns: 1fr;
  }
  .content {
    padding: 25px;
  }
  .topbar {
    padding: 0 25px;
  }
}
@media (max-width: 760px) {
  .bill-calculations {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .bill-order .panel-head {
    flex-wrap: wrap;
  }
  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.2s;
  }
  .sidebar.open {
    transform: none;
  }
  .workspace {
    margin-left: 0;
  }
  .mobile-toggle {
    display: inline-block;
  }
  .topbar {
    padding: 0 14px;
    height: 64px;
  }
  .topbar-title {
    display: none;
  }
  .topbar .right {
    gap: 8px;
  }
  .content {
    padding: 20px 13px;
  }
  .page-head {
    align-items: flex-start;
    gap: 12px;
  }
  .page-head h1 {
    font-size: 20px;
  }
  .cards {
    gap: 10px;
  }
  .card {
    padding: 16px;
  }
  .card .number {
    font-size: 24px;
  }
  .panel {
    padding: 15px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
  .detail-summary {
    grid-template-columns: 1fr 1fr;
  }
  .login {
    display: block;
    padding: 28px 18px;
    max-width: 470px;
  }
  .login-story h1 {
    font-size: 26px;
  }
  .login-card {
    padding: 25px;
    margin-top: 25px;
  }
  .info-grid {
    grid-template-columns: 1fr;
  }
  .filters input,
  .filters select,
  .filters label input,
  .filters label select {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    font-size: 16px;
  }
  .filters > input,
  .filters > select,
  .filters > label {
    flex: 1 1 145px;
    min-width: 0;
  }
  .filters > input:first-child,
  .filters > #search,
  .filters > button {
    flex: 1 1 100%;
  }
  .page-head .actions {
    justify-content: flex-end;
  }
  #modalBody {
    padding: 20px;
  }
  td,
  th {
    padding: 10px;
  }
  .sidebar footer {
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
 .copy-helper{position:fixed;left:-10000px;top:0}
.tree-depth-1{padding-left:12px}.tree-depth-2{padding-left:28px}.tree-depth-3{padding-left:44px}.tree-depth-4{padding-left:60px}
