:root {
  color-scheme: light;
  font-family: "Source Sans 3", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  color: #192b43;
  background: #f2f5f9;
  font-size: 16px;
  --navy: #172b47;
  --blue: #245cb1;
  --border: #dce4ed;
  --muted: #506680;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
a { color: var(--blue); }
a:hover { text-decoration: underline; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(1.75rem, 3vw, 2.4rem); letter-spacing: -.04em; }
h2 { font-size: 1.125rem; }
p { line-height: 1.55; }
input, button, select { font: inherit; }
button, .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: .64rem .95rem;
  min-height: 2.55rem;
  border: 1px solid #c7d4e3;
  border-radius: .52rem;
  background: white;
  color: #193655;
  text-decoration: none;
  font-weight: 650;
  cursor: pointer;
  white-space: nowrap;
}
button:hover, .button:hover { background: #ebf1fa; text-decoration: none; }
.primary { background: var(--blue); color: white; border-color: var(--blue); }
.primary:hover { background: #1a4589; }
.danger { color: #a02b35; }
:focus-visible { outline: 3px solid #5b97f1; outline-offset: 3px; }
.inside { display: grid; grid-template-columns: 13.25rem minmax(0, 1fr); }
.sidebar {
  padding: 2rem 1rem 1.1rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: #e5eef9;
  background: var(--navy);
}
.brand { font-size: 1.28rem; font-weight: 720; color: white; margin: 0 .65rem 2rem; text-decoration: none; }
.sidebar nav { display: grid; gap: .4rem; }
.sidebar nav a { color: #c6d6e9; padding: .7rem .78rem; border-radius: .45rem; text-decoration: none; }
.sidebar nav a:hover, .sidebar nav a[aria-current="page"] { color: white; background: #2b4566; }
.profile { margin-top: auto; padding: 1rem .65rem 0; display: grid; gap: .6rem; overflow-wrap: anywhere; }
.profile button { color: #ebf3fe; background: transparent; border-color: #5c7090; }
.profile button:hover { background: #2b4566; }
.inside main { max-width: 1440px; padding: clamp(1.1rem, 3.4vw, 3rem); width: 100%; }
.heading, .section-title { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.heading { margin-bottom: 1.45rem; }
.heading .muted { margin-top: .3rem; }
.eyebrow { display: block; margin-bottom: .45rem; font-size: .875rem; font-weight: 650; color: var(--muted); }
.panel, .login { background: #fff; border: 1px solid var(--border); border-radius: .75rem; }
.panel { padding: 1.25rem; margin-bottom: 1rem; }
.panel > h2 { margin-bottom: .9rem; }
.panel > p { margin: .4rem 0 .8rem; }
.muted, small { color: var(--muted); }
small { display: block; font-size: .875rem; }
.period-panel { display: flex; align-items: end; justify-content: space-between; gap: .9rem; flex-wrap: wrap; }
.inline-form { display: flex; align-items: end; gap: .8rem; flex-wrap: wrap; }
.form-grid { display: grid; gap: .9rem 1rem; }
.fields, .detail { grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.fields { margin: 1rem 0; }
.fields .full { grid-column: 1 / -1; }
label { color: #354961; font-weight: 600; display: grid; gap: .35rem; font-size: .9rem; }
input:not([type="checkbox"]), select {
  min-height: 2.65rem;
  width: 100%;
  padding: .55rem .65rem;
  border-radius: .43rem;
  border: 1px solid #bdccdc;
  background: white;
  color: #192b43;
}
input[type="checkbox"] { accent-color: var(--blue); width: 1.15rem; height: 1.15rem; }
.check { display: flex; align-items: center; align-self: end; min-height: 2.7rem; }
.totals { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); gap: 1rem; }
.total { display: block; color: #192b43; text-decoration: none; border-top: 3px solid #7c9ed2; }
.total:hover, .total.selected { text-decoration: none; border-color: var(--blue); }
.total .big { font-size: 2rem; font-weight: 700; font-variant-numeric: tabular-nums; margin: .65rem 0 .85rem; overflow-wrap: anywhere; }
.total .big span { font-size: 1.15rem; color: var(--muted); }
dl { margin: 0; }
.total dl, .detail { display: grid; gap: .9rem; }
.total dl { grid-template-columns: 1fr 1fr; }
.detail { margin-top: 1rem; }
dt { font-size: .875rem; color: var(--muted); margin-bottom: .25rem; }
dd { margin: 0; overflow-wrap: anywhere; }
.pill { display: inline-block; margin-right: .25rem; padding: .2rem .55rem; border-radius: 1rem; background: #eaf0fa; color: #254d80; white-space: nowrap; font-size: .875rem; }
.pill.red { background: #fae9eb; color: #8e303c; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; text-align: left; }
td, th { padding: .72rem .72rem; border-bottom: 1px solid #e5ebf2; vertical-align: middle; }
th { background: #f4f7fb; color: #405772; font-size: .875rem; white-space: nowrap; }
td { font-size: .94rem; }
tbody tr:last-child td { border-bottom: 0; }
.number, .mono { font-variant-numeric: tabular-nums; white-space: nowrap; }
.number { text-align: right; }
.filename, .log { overflow-wrap: anywhere; }
.log { max-width: 29rem; }
.empty { padding: 1.5rem .6rem; color: var(--muted); }
.pagination { display: flex; gap: .85rem; justify-content: end; margin-top: .65rem; }
.notice { padding: .75rem .95rem; margin-bottom: .9rem; border-radius: .45rem; background: #e7f4ec; color: #215632; }
.notice.error { background: #fae9eb; color: #8e303c; }
details { padding: .4rem 0; }
details + details { border-top: 1px solid var(--border); margin-top: .7rem; padding-top: .8rem; }
summary { cursor: pointer; color: var(--blue); font-weight: 650; }
details > form { margin-top: .75rem; }
.account-action { margin-top: .35rem; }
.outside { display: grid; place-items: center; padding: 1.2rem; background: #e8eef7; }
.outside main { width: min(100%, 27rem); }
.login { padding: 2rem; }
.login h1 { margin-bottom: 1.2rem; }
.login .primary { width: 100%; margin-top: .4rem; }
@media (max-width: 750px) {
  .inside { display: block; }
  .sidebar { min-height: 0; padding: .8rem 1rem; gap: .45rem; }
  .brand { margin: 0; }
  .sidebar nav { display: flex; gap: .25rem; flex-wrap: wrap; }
  .sidebar nav a { padding: .38rem .45rem; }
  .profile { display: flex; padding: 0; align-items: center; }
  .profile button { padding: .28rem .55rem; min-height: 2rem; }
  .heading { align-items: flex-start; flex-wrap: wrap; }
  .panel { padding: .8rem; }
}
