:root {
  --color-holiday: #c82333;
  --color-no-lesson: #90EE90;
  --color-school-event: #f0c046;
  --color-weekday: #ffffff;
  --color-weekend: #90EE90;
  --color-orange: #FFA500;
  --color-red: #FF0000;
  --font-stack: system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif;
  --bg: #f5f7fa;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: var(--font-stack);
  background: var(--bg);
  color: #1f1f1f;
}
.page-wrapper {
  max-width:1280px;
  margin:0 auto;
  padding:24px 16px;
}
.page-title {
  font-size:42px;
  margin-bottom:12px;
  font-weight:600;
}
.tabs-wrapper { margin-bottom:12px; }
.tabs {
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  padding-bottom:4px;
  border-bottom:1px solid #dcdcdc;
  overflow-x:auto;
  -webkit-overflow-scrolling:touch;
}
.tabs::-webkit-scrollbar { display:none }
.tab-btn {
  background:transparent;
  border:none;
  padding:10px 12px;
  font-size:13px;
  cursor:pointer;
  color:#555;
  border-radius:4px 4px 0 0;
  white-space:nowrap;
  transition:background .2s,color .2s;
}
.tab-btn.active {
  background:#b08d62;
  color:#fff;
}
.tabs.grid-4x3 {
  display:grid!important;
  grid-template-columns:repeat(4,1fr);
  gap:6px;
}
.tabs.grid-6x2 {
  display:grid!important;
  grid-template-columns:repeat(6,1fr);
  gap:6px;
}
.content-wrapper { display:flex; justify-content:center; }
.inner-layout {
  display:flex;
  gap:32px;
  width:80%;
  max-width:1100px;
  align-items:flex-start;
  flex-wrap:wrap;
}
.calendar-and-sidebar {
  display:flex;
  gap:32px;
  flex:1;
  flex-wrap:wrap;
  align-items:flex-start;
}
.calendar-container {
  flex:1 1 auto;
  display:flex;
  gap:16px;
  min-width:300px;
}
.month-card,
.events,
.legend {
  background:#fff;
  border:1px solid #e3e3e3;
  border-radius:8px;
  box-shadow:0 8px 24px rgba(0,0,0,0.03);
  padding:14px 16px;
  width:100%;
  max-width:420px;
}
.month-title {
  display:flex;
  justify-content:space-between;
  margin-bottom:8px;
  font-weight:600;
  font-size:16px;
}
.small { font-size:11px; opacity:.75; }
.calendar-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
}
.calendar-table th,
.calendar-table td {
  border: 1px solid #e6e6e6;
  padding: 8px 4px;
  text-align: center;
  font-size: 12px;
  line-height: 1;
}
.calendar-table th {
  background: #b2e0d9;
  font-weight: 600;
  color: #333;
}
.calendar-table .kw-cell {
  background: #b2e0d9;
  font-weight: 600;
  color: #333;
  width: 40px;
}
.calendar-table .day {
  min-height: 32px;
  vertical-align: middle;
}
.day.outside {
  background:#f1f1f1;
  color:#aaa;
  border-color:#f1f1f1;
}
.day.weekday { background:var(--color-weekday); color:#1f1f1f; }
.day.weekend { background:var(--color-weekend); color:#fff; }
.day.orange { background:var(--color-orange); color:#1f1f1f; }
.day.red { background:var(--color-red); color:#fff; }
.day.holiday { background:var(--color-holiday); color:#fff; }
.day.no-lesson { background:var(--color-no-lesson); color:#fff; }
.day.school-event { background:var(--color-school-event); color:#1f1f1f; }

.events h3 {
  margin:0 0 8px;
  font-size:16px;
  font-weight:600;
}
.semester { margin-bottom:10px; }
.event-list { list-style:none; padding:0; margin:4px 0; }
.event-list li { display:flex; gap:12px; margin-bottom:6px; }
.event-date { flex:0 0 100px; font-weight:700; font-size:12px; }
.event-desc { flex:1; font-size:13px; }
.footer-note { margin-top:4px; font-size:12px; color:#555; }

.legend-list {
  display:flex;
  gap:16px;
  flex-wrap:wrap;
}
.legend-item {
  display:flex;
  align-items:center;
  gap:6px;
}
.box {
  width:14px;
  height:14px;
  border:1px solid #ccc;
  border-radius:3px;
  display:inline-block;
}
.box.holiday { background:var(--color-holiday); }
.box.no-lesson { background:var(--color-no-lesson); }
.box.school-event { background:var(--color-school-event); }

/* —— 新增：fade 过渡 —— */
.fade-exit {
  opacity: 1;
}
.fade-exit-active {
  opacity: 0;
  transition: opacity .2s ease-out;
}
.fade-enter {
  opacity: 0;
}
.fade-enter-active {
  opacity: 1;
  transition: opacity .2s ease-in;
}

/* @media (max-width:1100px) {
  .inner-layout,
  .calendar-and-sidebar { flex-direction:column; }
  .events,
  .legend,
  .month-card { width:100%; }
} */
@media (max-width: 600px) {
/* 让月视图、事件面板、图例都不再有 max-width 限制，统一撑满父容器 */
.month-card,
.events,
.legend {
max-width: none;
width: 100%;
margin: 10px;
}

/* 可选：强制日历容器不做水平布局，按列排列 */
.calendar-container {
display: block;
}
}