:root {
  --bg: #f9fafb;
  --surface: #fff;
  --text: #111827;
  --muted: #6b7280;
  --primary: #5b21b6;
  --gradient: linear-gradient(135deg, #667eea, #764ba2);
  --line: #e5e7eb;
  --regular: #5b21b6;
  --urgent: #e77732;
  --check: #16897e;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 14px;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: inherit;
  padding: 8px 13px;
}
button:hover {
  background: #f0f4ff;
}
button:disabled {
  opacity: 0.5;
  cursor: default;
}
button:focus-visible,
a:focus-visible {
  outline: 3px solid #b8a3ef;
  outline-offset: 2px;
}
input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  padding: 10px;
  color: inherit;
}
textarea {
  resize: vertical;
  min-height: 85px;
}
label {
  display: block;
  line-height: 1.5;
  margin: 14px 0 0;
  font-size: 13px;
}
label input,
label select,
label textarea {
  display: block;
  margin-top: 6px;
}
h1 {
  font-size: 28px;
  margin: 4px 0;
  letter-spacing: -0.8px;
}
h2 {
  font-size: 18px;
  margin: 0;
}
h3 {
  font-size: 16px;
}
p {
  line-height: 1.6;
}
small,
.small {
  font-size: 12px;
}
.muted {
  color: var(--muted);
}
.eyebrow {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 2px;
  font-weight: 600;
  margin: 0 0 7px;
}
.primary {
  background: var(--gradient);
  color: white;
  border: 0;
  font-weight: 600;
}
.primary:hover {
  background: #5b21b6;
}
.error {
  color: #c24137;
}
.danger {
  color: #b42318;
  background: white;
}
.sidebar {
  position: fixed;
  width: 220px;
  top: 0;
  bottom: 0;
  left: 0;
  background: var(--surface);
  border-right: 1px solid var(--line);
  padding: 30px 18px;
  display: flex;
  flex-direction: column;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  font-weight: 700;
  font-size: 18px;
  padding: 0 8px 35px;
}
.brand span {
  display: block;
  font-size: 12px;
  font-weight: 400;
  color: var(--muted);
  margin-top: 4px;
  letter-spacing: 4px;
}
.sidebar nav {
  display: grid;
  gap: 8px;
}
.sidebar nav button {
  border: 0;
  text-align: left;
  padding: 13px 17px;
}
.sidebar nav .active {
  background: #f0eafd;
  color: var(--primary);
  font-weight: 600;
}
.sidebar-bottom {
  margin-top: auto;
  display: grid;
  gap: 12px;
  color: var(--muted);
}
main {
  margin-left: 220px;
  max-width: 1640px;
  padding: 28px 32px;
}
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 26px;
  gap: 12px;
}
.calendar-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin: 0 0 18px;
}
.date-nav {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}
.date-title {
  border: 0;
  background: transparent;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.5px;
}
#jump-date {
  width: 142px;
  padding: 6px;
  font-size: 12px;
  min-height: 36px;
}
.segmented {
  display: flex;
  background: #eceef2;
  border-radius: 9px;
  padding: 3px;
}
.segmented button {
  background: transparent;
  border: 0;
  min-width: 48px;
  min-height: 32px;
  padding: 6px 12px;
  color: var(--muted);
}
.segmented button.active {
  background: white;
  color: var(--primary);
  box-shadow: 0 2px 5px #11182710;
}
.filters {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.filters select {
  width: auto;
  min-height: 36px;
  padding: 6px 24px 6px 10px;
}
.legend {
  display: flex;
  gap: 15px;
  align-items: center;
  margin-left: auto;
  font-size: 12px;
  color: var(--muted);
}
.legend span:before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--regular);
  margin-right: 6px;
}
.legend .urgent:before {
  background: var(--urgent);
}
.legend .check:before {
  background: var(--check);
}
#counts {
  font-size: 12px;
}
footer {
  display: flex;
  justify-content: space-between;
  color: #a0a6b1;
  font-size: 11px;
  padding: 24px 0;
}
.mobile-nav {
  display: none;
}
#notice {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  padding: 12px 20px;
  box-shadow: 0 8px 30px #0002;
  border: 1px solid var(--line);
  border-radius: 10px;
  z-index: 30;
  width: max-content;
  max-width: 90vw;
}
