/* 万年历 /wnl/ — 页面私有样式（共享基础见 /css/style.css） */

.wnl-body {
  background: linear-gradient(180deg, #eef2ff 0%, var(--gray-50) 260px);
}

/* ---- 今日速览条 ---- */
.wnl-todaybar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #4f46e5, #6366f1);
  color: #fff;
  border-radius: var(--border-radius);
  padding: 14px 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-lg);
}

.wnl-todaybar .wt-date {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.wnl-todaybar .wt-big {
  font-size: 1.25rem;
  font-weight: 700;
}

.wnl-todaybar .wt-week {
  opacity: 0.92;
}

.wnl-todaybar .wt-clock {
  font-variant-numeric: tabular-nums;
  background: rgba(255, 255, 255, 0.16);
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.92rem;
}

.wnl-todaybar .wt-lunar {
  color: #fff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.14);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.92rem;
  transition: background 0.2s;
}

.wnl-todaybar .wt-lunar:hover {
  background: rgba(255, 255, 255, 0.26);
}

/* ---- 面包屑 ---- */
.wnl-crumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.92rem;
  color: var(--gray-500);
  margin-bottom: 16px;
}

.wnl-crumb a {
  color: var(--primary);
  text-decoration: none;
}

.wnl-crumb a:hover {
  text-decoration: underline;
}

.wnl-crumb i {
  font-style: normal;
  color: var(--gray-400);
}

/* ---- 单日详情 ---- */
.wnl-dayhero {
  display: flex;
  gap: 24px;
  align-items: center;
  background: #fff;
  border-radius: var(--border-radius);
  padding: 24px 28px;
  margin-bottom: 16px;
  box-shadow: var(--shadow);
}

.wd-left {
  text-align: center;
  min-width: 132px;
}

.wd-left .wd-d {
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--primary);
}

.wd-left .wd-ym {
  color: var(--gray-500);
  font-size: 0.95rem;
}

.wd-main {
  flex: 1;
  min-width: 0;
}

.wd-line1 {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.wd-weekday {
  font-size: 1.15rem;
  font-weight: 700;
}

.wd-weekday.wk {
  color: #dc2626;
}

.wd-tag {
  font-size: 0.8rem;
  padding: 2px 10px;
  border-radius: 999px;
  font-weight: 600;
}

.tag-today {
  background: #4f46e5;
  color: #fff;
}

.tag-rest {
  background: #fee2e2;
  color: #b91c1c;
}

.tag-work {
  background: #ffedd5;
  color: #c2410c;
}

.wd-lunar {
  font-size: 1.02rem;
  color: var(--gray-700);
  margin-bottom: 8px;
}

.wd-fests {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.wd-fest {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  border-radius: 999px;
  padding: 3px 12px;
  font-size: 0.88rem;
}

.wd-nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.wd-nav a {
  text-decoration: none;
  font-size: 0.9rem;
  color: var(--gray-600);
  background: var(--gray-100);
  border: 1px solid var(--gray-200);
  border-radius: 999px;
  padding: 5px 14px;
  transition: all 0.15s;
}

.wd-nav a:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.wd-nav a.wd-hl {
  background: #eef2ff;
  border-color: #c7d2fe;
  color: var(--primary);
  font-weight: 600;
}

/* ---- 单日信息卡 ---- */
.wnl-daygrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.wdi-card {
  background: #fff;
  border-radius: var(--border-radius);
  padding: 20px 22px;
  box-shadow: var(--shadow);
}

.wdi-card h3 {
  font-size: 1.05rem;
  margin-bottom: 12px;
  color: var(--gray-900);
}

.wdi-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.94rem;
}

.wdi-table th,
.wdi-table td {
  text-align: left;
  padding: 7px 4px;
  border-bottom: 1px dashed var(--gray-200);
  vertical-align: top;
}

.wdi-table tr:last-child th,
.wdi-table tr:last-child td {
  border-bottom: 0;
}

.wdi-table th {
  color: var(--gray-500);
  font-weight: 500;
  width: 76px;
  white-space: nowrap;
}

.wd-term {
  color: #b91c1c;
}

.wd-tip {
  margin-top: 12px;
  font-size: 0.88rem;
  color: var(--gray-500);
}

.wd-tip a {
  color: var(--primary);
}

.wdi-yy {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.wdi-col {
  border-radius: 8px;
  padding: 10px 12px;
}

.wdi-col b {
  display: inline-block;
  width: 26px;
  height: 26px;
  line-height: 26px;
  text-align: center;
  border-radius: 6px;
  color: #fff;
  margin-bottom: 6px;
  font-size: 0.9rem;
}

.wdi-col.yi {
  background: #f0fdf4;
}

.wdi-col.yi b {
  background: #16a34a;
}

.wdi-col.ji {
  background: #fef2f2;
}

.wdi-col.ji b {
  background: #dc2626;
}

.wdi-col p {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--gray-700);
}

.wdi-note {
  margin-top: 10px;
  font-size: 0.82rem;
  color: var(--gray-400);
}

/* ---- 月历 ---- */
.wnl-cal {
  background: #fff;
  border-radius: var(--border-radius);
  padding: 20px 22px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.wc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.wc-title {
  text-align: center;
}

.wc-title h2 {
  font-size: 1.4rem;
  color: var(--gray-900);
}

.wc-sub {
  font-size: 0.85rem;
  color: var(--gray-400);
}

.wc-btn {
  text-decoration: none;
  font-size: 0.9rem;
  color: var(--primary);
  background: #eef2ff;
  border: 1px solid #c7d2fe;
  border-radius: 999px;
  padding: 6px 14px;
  transition: all 0.15s;
  white-space: nowrap;
}

.wc-btn:hover {
  background: var(--primary);
  color: #fff;
}

.wc-jump {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 0 14px;
  border-bottom: 1px solid var(--gray-100);
  margin-bottom: 14px;
  font-size: 0.92rem;
  color: var(--gray-600);
}

.wc-jump select {
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 0.92rem;
  color: var(--gray-700);
  background: #fff;
}

.wc-jump .wc-go {
  border: 0;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  padding: 6px 16px;
  font-size: 0.9rem;
  cursor: pointer;
}

.wc-jump .wc-go:hover {
  background: var(--primary-hover);
}

.wc-jump .wc-back {
  color: var(--gray-500);
  font-size: 0.88rem;
  text-decoration: none;
  margin-left: auto;
}

.wc-jump .wc-back:hover {
  color: var(--primary);
}

.wc-grid {
  border: 1px solid var(--gray-200);
  border-radius: 10px;
  overflow: hidden;
}

.wc-row {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}

.wc-row + .wc-row {
  border-top: 1px solid var(--gray-100);
}

.wc-weeks {
  background: var(--gray-50);
}

.wc-weeks .we {
  padding: 8px 4px;
  text-align: center;
  font-size: 0.88rem;
  color: var(--gray-500);
  font-weight: 600;
}

.wc-weeks .we.sun {
  color: #dc2626;
}

.wc-d {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-height: 74px;
  padding: 8px 2px;
  text-decoration: none;
  border-left: 1px solid var(--gray-100);
  transition: background 0.12s;
}

.wc-row .wc-d:first-child {
  border-left: 0;
}

.wc-d b {
  font-size: 1.18rem;
  font-weight: 600;
  color: var(--gray-800);
  line-height: 1.2;
}

.wc-d em {
  font-style: normal;
  font-size: 0.74rem;
  color: var(--gray-400);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.wc-d em.st-lfest,
.wc-d em.st-sfest,
.wc-d em.st-term {
  color: #dc2626;
}

.wc-d.weekend b {
  color: #b91c1c;
}

.wc-d.other b,
.wc-d.other em {
  color: var(--gray-300);
}

.wc-d.other {
  background: var(--gray-50);
}

.wc-d.fest {
  background: #fff7f7;
}

.wc-d:hover {
  background: #eef2ff;
}

.wc-d.today {
  background: #eef2ff;
  box-shadow: inset 0 0 0 2px var(--primary);
  border-radius: 4px;
}

.wc-d.today b {
  color: var(--primary);
  font-weight: 800;
}

.wc-d.sel {
  background: var(--primary);
  box-shadow: none;
  border-radius: 4px;
}

.wc-d.sel b {
  color: #fff;
}

.wc-d.sel em {
  color: rgba(255, 255, 255, 0.85);
}

.wc-badge {
  position: absolute;
  top: 3px;
  right: 3px;
  font-style: normal;
  font-size: 0.66rem;
  line-height: 1;
  padding: 2px 4px;
  border-radius: 4px;
  font-weight: 700;
}

.wc-badge.bd-rest {
  background: #dc2626;
  color: #fff;
}

.wc-badge.bd-work {
  background: #ea580c;
  color: #fff;
}

.wc-legend {
  margin-top: 12px;
  font-size: 0.85rem;
  color: var(--gray-500);
}

.wc-legend .lg {
  font-style: normal;
  display: inline-block;
  padding: 1px 5px;
  border-radius: 4px;
  margin-right: 4px;
  font-size: 0.76rem;
}

.lg-rest {
  background: #dc2626;
  color: #fff;
}

.lg-work {
  background: #ea580c;
  color: #fff;
}

.lg-today {
  color: var(--primary);
}

/* ---- 农历公历互转 ---- */
.wnl-conv {
  background: #fff;
  border-radius: var(--border-radius);
  padding: 20px 22px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.wnl-conv h2 {
  font-size: 1.2rem;
  margin-bottom: 14px;
}

.conv-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.conv-tab {
  text-decoration: none;
  font-size: 0.92rem;
  padding: 6px 18px;
  border-radius: 999px;
  border: 1px solid var(--gray-200);
  color: var(--gray-600);
  background: var(--gray-50);
}

.conv-tab.on {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  font-weight: 600;
}

.conv-form {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.94rem;
  color: var(--gray-600);
}

.conv-form input[type="date"],
.conv-form select {
  border: 1px solid var(--gray-300);
  border-radius: 8px;
  padding: 6px 8px;
  font-size: 0.94rem;
  color: var(--gray-700);
}

.conv-form .conv-go {
  border: 0;
  background: var(--primary);
  color: #fff;
  border-radius: 8px;
  padding: 7px 18px;
  font-size: 0.92rem;
  cursor: pointer;
}

.conv-form .conv-go:hover {
  background: var(--primary-hover);
}

.conv-leap {
  margin-left: 8px;
  font-size: 0.88rem;
  color: var(--gray-500);
}

.conv-result {
  margin-top: 14px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 10px;
  padding: 14px 16px;
}

.conv-result .cr-main {
  font-size: 1.02rem;
  color: var(--gray-800);
}

.conv-result .cr-sub {
  color: var(--gray-500);
  font-size: 0.92rem;
  margin: 4px 0;
}

.conv-result .cr-link {
  color: var(--primary);
  font-size: 0.92rem;
  text-decoration: none;
}

.conv-result .cr-link:hover {
  text-decoration: underline;
}

.conv-err {
  margin-top: 12px;
  color: #b91c1c;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.92rem;
}

/* ---- 年度表格 ---- */
.wnl-tables {
  background: #fff;
  border-radius: var(--border-radius);
  padding: 20px 22px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.wnl-tables h2 {
  font-size: 1.2rem;
  margin-bottom: 14px;
}

.wnl-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.wt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
}

.wt-table th,
.wt-table td {
  padding: 9px 10px;
  border-bottom: 1px solid var(--gray-100);
  text-align: left;
}

.wt-table thead th {
  background: var(--gray-50);
  color: var(--gray-500);
  font-weight: 600;
  white-space: nowrap;
}

.wt-table tbody th {
  color: var(--gray-800);
  font-weight: 600;
  white-space: nowrap;
}

.wt-table a {
  color: var(--primary);
  text-decoration: none;
}

.wt-table a:hover {
  text-decoration: underline;
}

.td-rest {
  color: #b91c1c;
}

.td-work {
  color: #c2410c;
}

.wnl-empty {
  color: var(--gray-400);
  font-size: 0.94rem;
}

/* ---- 介绍 ---- */
.wnl-info {
  background: #fff;
  border-radius: var(--border-radius);
  padding: 20px 22px 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
  font-size: 0.95rem;
  color: var(--gray-700);
}

.wnl-info h2 {
  font-size: 1.2rem;
  margin-bottom: 12px;
}

.wnl-info h3 {
  font-size: 1.02rem;
  margin: 16px 0 8px;
  color: var(--gray-800);
}

.wnl-info p,
.wnl-info li {
  line-height: 1.8;
}

.wnl-info ul {
  padding-left: 22px;
}

.wnl-info .disclaimer {
  margin-top: 16px;
  font-size: 0.86rem;
  color: var(--gray-500);
  background: var(--gray-50);
  border-radius: 8px;
  padding: 10px 14px;
}

/* ---- 响应式 ---- */
@media (max-width: 768px) {
  .wnl-dayhero {
    flex-direction: column;
    text-align: center;
    padding: 20px 16px;
  }

  .wd-nav {
    justify-content: center;
  }

  .wc-d {
    min-height: 60px;
  }

  .wc-d b {
    font-size: 1rem;
  }

  .wc-d em {
    font-size: 0.62rem;
  }

  .wnl-two {
    grid-template-columns: 1fr;
  }

  .wnl-tables {
    overflow-x: auto;
  }

  .wt-table {
    min-width: 460px;
  }
}
