:root {
  --ink: #17231f;
  --ink2: #34443e;
  --paper: #f3efe4;
  --paper2: #e9e1cf;
  --red: #ad4433;
  --moss: #5b6d5c;
  --line: rgba(23, 35, 31, 0.14);
  --white: #fffdf7;
  --shadow: 0 20px 60px rgba(29, 38, 32, 0.1);
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Noto Sans SC', 'Microsoft YaHei', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}
body:before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image: radial-gradient(rgba(40, 48, 40, 0.22) 0.6px, transparent 0.7px);
  background-size: 7px 7px;
  mix-blend-mode: multiply;
}
button,
textarea,
input {
  font: inherit;
}
.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 264px 1fr;
  position: relative;
}
.sidebar {
  background: var(--ink);
  color: #e9e3d4;
  padding: 28px 22px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 42px;
}
.seal {
  width: 43px;
  height: 43px;
  border: 1px solid #c46a58;
  color: #e27762;
  display: grid;
  place-items: center;
  border-radius: 4px;
  font-family: serif;
  font-size: 20px;
  transform: rotate(-2deg);
}
.brand b {
  display: block;
  font-family: serif;
  font-size: 19px;
  letter-spacing: 0.12em;
}
.brand span {
  font-size: 12px;
  color: #9eaaa4;
  letter-spacing: 0.08em;
}
.nav-label {
  font-size: 12px;
  color: #82918a;
  margin: 20px 10px 8px;
  letter-spacing: 0.14em;
}
.nav-item {
  width: 100%;
  border: 0;
  background: transparent;
  color: #b9c2bd;
  text-align: left;
  padding: 11px 12px;
  border-radius: 7px;
  margin: 2px 0;
  cursor: pointer;
  display: flex;
  gap: 11px;
  align-items: center;
}
.nav-item:hover,
.nav-item.active {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}
.nav-item.active:before {
  content: '';
  width: 3px;
  height: 18px;
  border-radius: 3px;
  background: #c95a45;
}
.nav-item:not(.active):before {
  content: '';
  width: 3px;
}
.side-note {
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 18px 10px 0;
  font-family: serif;
  color: #9daa9f;
  font-size: 13px;
}
.side-note em {
  color: #e4d8bd;
  font-style: normal;
}
main {
  padding: 34px clamp(24px, 4vw, 66px) 70px;
  max-width: 1500px;
  width: 100%;
  min-width: 0;
  margin: 0 auto;
}
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 28px;
}
.crumb {
  font-size: 14px;
  color: #68746e;
}
.crumb strong {
  color: var(--red);
  font-weight: 600;
}
.top-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.script-toggle {
  border: 1px solid #c8bead;
  background: #fffdf8;
  color: #5d665f;
  border-radius: 99px;
  padding: 5px 12px;
  cursor: pointer;
  font-size: 13px;
}
.script-toggle:hover {
  border-color: var(--red);
  color: var(--red);
}
.status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #65726c;
}
.status i {
  width: 8px;
  height: 8px;
  background: #6e8a72;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(110, 138, 114, 0.12);
}
.intro {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 26px;
}
.eyebrow {
  color: var(--red);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
}
.intro h1 {
  font-family: 'Songti SC', 'STSong', serif;
  font-weight: 600;
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.08;
  margin: 8px 0 10px;
  letter-spacing: 0.05em;
}
.intro p {
  margin: 0;
  color: #4d5a55;
  max-width: 650px;
}
.moon {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  background: #e3d7bb;
  box-shadow: inset -18px -12px 0 #d6c49e;
  position: relative;
}
.moon:after {
  content: '壬戌之秋';
  position: absolute;
  right: -9px;
  top: 15px;
  writing-mode: vertical-rl;
  font: 12px serif;
  letter-spacing: 0.22em;
  color: #755d45;
}
.prompt-card {
  margin-top: 28px;
  background: rgba(255, 253, 247, 0.84);
  border: 1px solid rgba(80, 73, 55, 0.14);
  box-shadow: var(--shadow);
  padding: 26px;
  border-radius: 12px;
}
.prompt-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}
.prompt-head h2 {
  font: 600 22px serif;
  margin: 0 0 5px;
}
.prompt-head p {
  margin: 0;
  color: #6a746f;
  font-size: 14px;
}
.step {
  font-size: 12px;
  color: #8b7468;
}
.textarea-wrap {
  position: relative;
  margin-top: 20px;
}
textarea {
  width: 100%;
  min-height: 126px;
  resize: vertical;
  border: 1px solid #c9c2b2;
  background: #fbf9f2;
  border-radius: 8px;
  padding: 17px 18px 48px;
  color: var(--ink);
  outline: none;
}
textarea:focus {
  border-color: #8b9a8c;
  box-shadow: 0 0 0 3px rgba(86, 108, 91, 0.11);
}
.examples {
  position: absolute;
  left: 14px;
  bottom: 12px;
  display: flex;
  gap: 7px;
}
.chip {
  border: 1px solid #d7d0c1;
  background: transparent;
  border-radius: 99px;
  padding: 4px 9px;
  font-size: 12px;
  color: #756f64;
  cursor: pointer;
}
.chip:hover {
  background: #eee8dc;
}
.action-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  gap: 16px;
}
.options {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  color: #5f6a65;
  font-size: 14px;
}
.options label {
  cursor: pointer;
}
.options input {
  accent-color: var(--red);
  margin-right: 6px;
}
.primary {
  border: 0;
  background: var(--ink);
  color: #fff;
  padding: 11px 20px;
  border-radius: 7px;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(23, 35, 31, 0.18);
}
.primary:hover {
  background: #263832;
}
.primary:disabled {
  opacity: 0.6;
  cursor: wait;
}
.recommend {
  display: none;
  margin-top: 16px;
  padding: 17px 18px;
  border-left: 3px solid var(--red);
  background: #f1eadc;
  animation: rise 0.35s ease;
}
.recommend.show {
  display: block;
}
.recommend b {
  font-family: serif;
}
.recommend button {
  float: right;
  border: 0;
  background: transparent;
  color: var(--red);
  cursor: pointer;
  font-weight: 600;
}
.section-head {
  margin: 38px 0 17px;
  display: flex;
  justify-content: space-between;
  align-items: end;
}
.section-head h2 {
  font: 600 24px serif;
  margin: 0;
}
.section-head p {
  margin: 3px 0 0;
  color: #53615a;
  font-size: 14px;
}
.section-head span {
  font: italic 13px serif;
  color: #8d7f6f;
}
.module-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.module {
  background: rgba(255, 253, 247, 0.7);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 20px;
  min-height: 244px;
  cursor: pointer;
  transition: 0.2s;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.module:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: rgba(92, 108, 94, 0.45);
}
.module:after {
  content: attr(data-num);
  position: absolute;
  right: 12px;
  bottom: -24px;
  font: 72px serif;
  color: rgba(23, 35, 31, 0.045);
}
.module .icon {
  color: var(--red);
  width: 32px;
  height: 32px;
}
.module .icon svg {
  display: block;
  width: 100%;
  height: 100%;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.module h3 {
  font: 600 20px serif;
  margin: 22px 0 5px;
}
.module .modern {
  font-size: 13px;
  color: #7b665b;
  margin-bottom: 12px;
}
.module p {
  font-size: 14px;
  color: #596761;
  margin: 0;
}
.module .enter {
  position: static;
  margin-top: auto;
  padding-top: 20px;
  color: var(--ink);
  font-weight: 600;
  font-size: 13px;
  z-index: 1;
}
.corpus {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.source-card {
  background: #fffdf8;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 19px 20px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
}
.source-card .mark {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #e9e1cf;
  color: var(--red);
  display: grid;
  place-items: center;
  font: 600 17px serif;
}
.source-card h3 {
  font: 600 18px serif;
  margin: 0;
}
.source-card p {
  font-size: 14px;
  color: #5f6b65;
  margin: 5px 0;
}
.source-card small {
  color: #665c53;
}
.source-card a {
  display: inline-block;
  margin-top: 9px;
  color: var(--red);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}
.source-card a:hover {
  text-decoration: underline;
}
.source-card.digital {
  border-style: dashed;
  background: rgba(233, 225, 207, 0.35);
}
.source-note {
  margin-top: 14px;
  padding: 13px 16px;
  background: rgba(173, 68, 51, 0.07);
  border-radius: 7px;
  color: #655e56;
  font-size: 13px;
}
.badge {
  display: inline-block;
  margin-left: 7px;
  padding: 2px 7px;
  border-radius: 99px;
  background: #eee6d7;
  color: #766557;
  font: 12px sans-serif;
  vertical-align: 2px;
}
.library {
  background: rgba(255, 253, 247, 0.7);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
}
.library-bar {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-bottom: 12px;
}
.search {
  flex: 1;
  border: 1px solid #cbc3b3;
  background: #fffdf8;
  border-radius: 7px;
  padding: 10px 13px;
  min-width: 160px;
  outline: none;
}
.search:focus {
  border-color: #879889;
  box-shadow: 0 0 0 3px rgba(86, 108, 91, 0.1);
}
.select-filters {
  display: flex;
  gap: 8px;
}
.select-filters label {
  font-size: 12px;
  color: #756e64;
  display: flex;
  align-items: center;
  gap: 5px;
}
.select-filters select {
  border: 1px solid #cfc7b8;
  background: #fffdf8;
  border-radius: 7px;
  padding: 9px;
  color: #3e4b45;
}
.genre-select {
  display: none !important;
}
.genre-chips {
  display: flex;
  gap: 6px;
  flex-wrap: nowrap;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  margin: 0 0 16px;
  padding-bottom: 6px;
}
.genre-chip {
  border: 1px solid #d8d0c0;
  background: transparent;
  border-radius: 99px;
  padding: 5px 10px;
  color: #66716b;
  cursor: pointer;
  font-size: 13px;
  flex: 0 0 auto;
}
.genre-chip.active,
.genre-chip:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}
.works {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.work {
  border: 1px solid var(--line);
  background: #fffdf8;
  border-radius: 8px;
  padding: 15px 16px;
  text-align: left;
  cursor: pointer;
  color: inherit;
  transition: 0.18s;
}
.work:hover {
  border-color: #809085;
  transform: translateY(-2px);
}
.work h3 {
  font: 600 17px serif;
  line-height: 1.45;
  margin: 0 0 5px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.work .meta {
  color: #8b5b4e;
  font-size: 12px;
}
.work p {
  font-family: serif;
  color: #606b65;
  font-size: 14px;
  margin: 9px 0 0;
}
.empty {
  display: none;
  text-align: center;
  padding: 30px;
  color: #7a837e;
}
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin: 18px 0 4px;
}
.page-btn {
  min-width: 36px;
  height: 36px;
  border: 1px solid #d0c7b8;
  background: #fffdf8;
  border-radius: 6px;
  color: #536159;
  cursor: pointer;
}
.page-btn:hover,
.page-btn.active {
  background: var(--ink);
  border-color: var(--ink);
  color: white;
}
.page-btn:disabled {
  opacity: 0.38;
  cursor: not-allowed;
}
.page-gap {
  color: #8a8175;
  padding: 0 3px;
}
.licence {
  font-size: 12px;
  color: #7b807c;
  margin-top: 12px;
}
.reader-panel {
  width: min(760px, 96vw);
}
.reader-meta {
  color: #786f65;
  font-size: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.reader-navigation {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 12px 0 4px;
}
.reader-navigation button {
  border: 1px solid #c8bead;
  border-radius: 6px;
  background: #fffdf8;
  padding: 7px 12px;
  color: #4e5c55;
  cursor: pointer;
}
.reader-navigation button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}
.reader-hit {
  scroll-margin-top: 22vh;
  border-radius: 2px;
  background: #f3d9a9;
  color: #643428;
  padding: 0 2px;
  animation: readerHit 1.8s ease;
}
@keyframes readerHit {
  0%, 100% { box-shadow: none; }
  35% { box-shadow: 0 0 0 5px rgba(196, 106, 88, 0.2); }
}
.reader-background {
  margin: 16px 0;
  padding: 14px 16px;
  background: #ece5d6;
  border-left: 3px solid #a77d5e;
  color: #675f56;
  font:
    14px/1.75 'Noto Sans SC',
    'Microsoft YaHei',
    sans-serif;
}
.reader-background strong {
  color: #8b4435;
  margin-right: 8px;
}
.edition-meta {
  margin: 0 0 15px;
  padding: 10px 13px;
  border: 1px dashed #c9bca8;
  background: #f4eee2;
  color: #87786a;
  font:
    13px/1.65 'Noto Sans SC',
    'Microsoft YaHei',
    sans-serif;
}
.reader-text {
  font:
    18px/2.05 'Songti SC',
    'STSong',
    serif;
  color: #26332d;
  background: #fffdf8;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  margin: 20px 0;
}
.reader-text p {
  margin: 0.65em 0;
}
.reader-text.prose p {
  margin: 0 0 1em;
  text-indent: 2em;
}
.reader-text.verse p {
  margin: 0.35em 0;
  text-indent: 0;
}
.reader-text .work-heading {
  font-size: 1.18em;
  font-weight: 700;
  color: #243b32;
  margin: 1.5em 0 0.55em;
}
.reader-text .preface {
  font-size: 0.9em;
  line-height: 1.8;
  color: #7a5748;
  background: #f5eee1;
  border-left: 3px solid #b48a69;
  padding: 10px 13px;
  text-indent: 0;
}
.version-block {
  margin: 1.4rem 0;
  overflow: hidden;
  border: 1px solid #d8cbb7;
  border-radius: 8px;
  background: #fffdfa;
}
.version-block .version-title {
  margin: 0;
  border-bottom: 1px solid #d8cbb7;
  background: #eee6d7;
  padding: 10px 14px;
  color: #70493d;
  font: 600 15px/1.5 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
}
.version-block > p,
.version-block > .poem {
  margin: 0;
  padding: 16px 18px;
}
.unpunctuated {
  display: block;
  margin: 8px 0 12px;
  color: #98705d;
  font:
    13px/1.5 'Noto Sans SC',
    'Microsoft YaHei',
    sans-serif;
}
.note-ref {
  display: inline-grid;
  place-items: center;
  min-width: 1.65em;
  height: 1.65em;
  margin: 0 0.18em;
  border: 1px solid #b87862;
  border-radius: 50%;
  background: #fff8ed;
  color: #9d3f2f;
  font: 600 12px sans-serif;
  cursor: pointer;
  vertical-align: 0.35em;
}
.note-ref:hover,
.note-ref:focus {
  background: var(--red);
  color: white;
  outline: none;
}
.reader-notes {
  margin: 18px 0;
  padding: 18px;
  background: #f4efe4;
  border-radius: 9px;
  border: 1px solid #dacdb9;
}
.reader-notes h3 {
  font: 600 20px serif;
  margin: 0 0 12px;
}
.note-item {
  scroll-margin-top: 20px;
  padding: 11px 10px;
  border-top: 1px solid rgba(62, 84, 70, 0.13);
  font:
    13px/1.75 'Noto Sans SC',
    'Microsoft YaHei',
    sans-serif;
}
.note-item:nth-child(4n + 1) {
  color: #6f493e;
}
.note-item:nth-child(4n + 2) {
  color: #426451;
}
.note-item:nth-child(4n + 3) {
  color: #4b577b;
}
.note-item:nth-child(4n) {
  color: #76556f;
}
.note-item:first-child {
  border-top: 0;
}
.note-item.flash {
  animation: noteFlash 1.4s ease;
}
.note-num {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin-right: 8px;
  border-radius: 50%;
  background: #6b7c6c;
  color: white;
  font-size: 12px;
}
.reader-note-jumps {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 10px 0;
}
.source-link {
  color: var(--red);
  text-decoration: none;
  font-weight: 600;
}
.source-link:hover {
  text-decoration: underline;
}
.concordance,
.journey {
  margin-bottom: 54px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 253, 248, 0.72);
  padding: 22px;
}
.concordance-form label {
  display: block;
  margin-bottom: 9px;
  color: #33443d;
  font-weight: 700;
}
.concordance-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}
.concordance-input input {
  width: 100%;
  min-height: 46px;
  border: 1px solid #aeb8b1;
  border-radius: 7px;
  background: #fffef9;
  padding: 0 14px;
  color: #26352f;
  font-size: 16px;
}
.query-examples {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 10px;
  color: #58655f;
  font-size: 13px;
}
.query-examples button,
.journey-controls button {
  border: 1px solid #bdc5bf;
  border-radius: 999px;
  background: transparent;
  padding: 6px 11px;
  color: #3e5148;
  cursor: pointer;
}
.query-examples button:hover,
.journey-controls button:hover,
.journey-controls button.active {
  border-color: var(--red);
  background: #f6e9e2;
  color: #873f31;
}
.concordance-status {
  margin: 18px 0;
  padding: 12px 14px;
  border-left: 3px solid #738375;
  background: #f2f0e7;
  color: #44534c;
  line-height: 1.65;
}
.concordance-pagination {
  margin-top: 18px;
}
.concordance-genres {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}
.concordance-genre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 68px;
  border: 1px solid #c7cfc7;
  border-radius: 8px;
  background: #fffdf7;
  padding: 14px 16px;
  color: #30443a;
  cursor: pointer;
  text-align: left;
}
.concordance-genre:hover {
  border-color: var(--red);
  background: #faf1e9;
}
.concordance-genre b {
  font: 600 20px/1.3 serif;
}
.concordance-genre span {
  color: #7b493d;
  font-size: 13px;
  white-space: nowrap;
}
.concordance-result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}
.concordance-result-head h3 {
  margin: 0;
  font: 600 22px/1.3 serif;
}
.concordance-back {
  border: 0;
  background: transparent;
  padding: 6px 0;
  color: #8a4032;
  cursor: pointer;
}
.concordance-back:hover {
  text-decoration: underline;
}
.concordance-group + .concordance-group {
  margin-top: 24px;
}
.concordance-group h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 10px;
  font: 600 21px/1.3 serif;
}
.concordance-group h3 span {
  border-radius: 99px;
  background: #e8ebe4;
  padding: 3px 8px;
  color: #536158;
  font: 12px/1.3 sans-serif;
}
.hit-card {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: start;
  width: 100%;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  padding: 15px 4px;
  color: inherit;
  text-align: left;
  cursor: pointer;
}
.hit-card:hover {
  background: rgba(241, 235, 220, 0.6);
}
.hit-card b {
  color: #293b33;
  font-family: serif;
}
.hit-context {
  color: #4b5953;
  line-height: 1.75;
}
.hit-context mark {
  border-radius: 2px;
  background: #f3d9a9;
  color: #643428;
  padding: 0 2px;
}
.hit-meta {
  color: #748078;
  font-size: 12px;
  white-space: nowrap;
}
.journey-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.journey-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.75fr);
  gap: 16px;
}
.journey-layout > * {
  min-width: 0;
}
.journey-map {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  border: 1px solid #c8cec5;
  border-radius: 9px;
  background:
    radial-gradient(circle at 76% 34%, rgba(98, 128, 113, 0.14), transparent 23%),
    linear-gradient(145deg, #edf0e8, #e1e8df 62%, #d7e1dc);
}
.journey-map:before {
  content: '';
  position: absolute;
  inset: 15% 9% 11% 8%;
  border-radius: 47% 53% 58% 42% / 49% 39% 61% 51%;
  background: rgba(250, 248, 238, 0.62);
  transform: rotate(-4deg);
}
.journey-map svg {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  min-height: 420px;
}
.china-map-base {
  opacity: 0.28;
  filter: saturate(0.45) sepia(0.18);
}
.map-caption {
  position: absolute;
  z-index: 2;
  top: 14px;
  left: 16px;
}
.map-caption b,
.map-caption span {
  display: block;
}
.map-caption span {
  margin-top: 3px;
  color: #617068;
  font-size: 12px;
}
.route-line {
  fill: none;
  stroke: #8b6c5f;
  stroke-width: 2;
  stroke-dasharray: 5 6;
  opacity: 0.58;
}
.map-point {
  cursor: pointer;
}
.map-point circle {
  fill: #8b3f32;
  stroke: #fffaf0;
  stroke-width: 3;
}
.map-point.active circle {
  r: 8;
  fill: #1f5041;
}
.map-point text {
  fill: #33453d;
  font: 13px sans-serif;
  paint-order: stroke;
  stroke: #eef1e9;
  stroke-width: 4px;
}
.journey-detail {
  min-height: 360px;
  border-radius: 9px;
  background: #263a33;
  padding: 24px;
  color: #f3efe4;
}
.journey-detail .era {
  color: #dfbd92;
  font-size: 12px;
  letter-spacing: 0.12em;
}
.journey-detail h3 {
  margin: 8px 0 12px;
  font: 600 28px/1.25 serif;
}
.journey-detail p {
  color: #e0e5df;
  line-height: 1.8;
}
.journey-work {
  display: block;
  width: 100%;
  margin-top: 8px;
  border: 1px solid rgba(242, 235, 218, 0.3);
  border-radius: 6px;
  background: transparent;
  padding: 9px 10px;
  color: #f3e9d4;
  text-align: left;
  cursor: pointer;
}
.journey-work:hover {
  border-color: #dfbd92;
}
.journey-timeline {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  margin-top: 16px;
  padding: 4px 0 9px;
}
.journey-event {
  flex: 0 0 128px;
  border: 1px solid #c8cfc7;
  border-radius: 7px;
  background: #fffdf7;
  padding: 11px;
  color: #34463e;
  text-align: left;
  cursor: pointer;
}
.journey-event.active {
  border-color: var(--red);
  box-shadow: inset 0 -3px var(--red);
}
.journey-event b,
.journey-event span {
  display: block;
}
.journey-event b {
  color: #8a4032;
  font-family: serif;
  font-size: 17px;
}
.journey-event span {
  margin-top: 4px;
  font-size: 13px;
}
.journey-source {
  margin: 12px 0 0;
  color: #5a6861;
  font-size: 13px;
  line-height: 1.65;
}
@keyframes noteFlash {
  0%,
  100% {
    background: transparent;
  }
  30% {
    background: #fff2bd;
  }
}
.drawer {
  position: fixed;
  inset: 0;
  display: none;
  background: rgba(14, 22, 19, 0.45);
  z-index: 8;
}
.drawer.open {
  display: block;
}
.panel {
  margin-left: auto;
  width: min(620px, 92vw);
  height: 100%;
  background: #f7f3e9;
  padding: 34px;
  overflow: auto;
  box-shadow: -20px 0 60px rgba(0, 0, 0, 0.18);
  animation: slide 0.3s ease;
}
.close {
  float: right;
  background: transparent;
  border: 0;
  font-size: 25px;
  cursor: pointer;
  color: #58645f;
}
.panel .kicker {
  color: var(--red);
  font-size: 13px;
  letter-spacing: 0.15em;
}
.panel h2 {
  font: 600 32px serif;
  margin: 10px 0;
}
.panel .judge {
  margin: 25px 0;
  background: #fffaf0;
  border-left: 4px solid var(--red);
  padding: 18px;
}
.judge strong {
  display: block;
  font-size: 18px;
}
.judge small {
  font: italic 13px serif;
  color: #6f574b;
}
.evidence {
  display: grid;
  gap: 10px;
}
.evidence article {
  background: #fffdf8;
  border: 1px solid var(--line);
  padding: 15px;
  border-radius: 7px;
}
.evidence b {
  font-family: serif;
}
.evidence span {
  display: block;
  font-size: 12px;
  color: #7c8781;
  margin-top: 4px;
}
.mobile-menu {
  display: none;
}
@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}
@keyframes slide {
  from {
    transform: translateX(100%);
  }
}
@media (max-width: 1050px) {
  .module-grid {
    grid-template-columns: 1fr 1fr;
  }
  .shell {
    grid-template-columns: 220px 1fr;
  }
  .moon {
    display: none;
  }
}
@media (max-width: 760px) {
  .shell {
    display: block;
  }
  .sidebar {
    position: relative;
    height: auto;
    padding: 17px 18px;
    display: block;
  }
  .brand {
    margin: 0;
  }
  .sidebar nav,
  .side-note {
    display: none;
  }
  .sidebar nav.nav-open {
    display: block;
  }
  .mobile-menu {
    display: block;
    position: absolute;
    right: 18px;
    top: 20px;
    background: transparent;
    color: #fff;
    border: 1px solid #637069;
    border-radius: 5px;
    padding: 5px 9px;
  }
  main {
    padding: 24px 16px 50px;
  }
  .topbar {
    margin-bottom: 18px;
  }
  .status {
    display: none;
  }
  .intro {
    display: block;
  }
  .intro h1 {
    font-size: 38px;
  }
  .prompt-card {
    padding: 18px;
  }
  .prompt-head {
    display: block;
  }
  .step {
    display: block;
    margin-top: 4px;
  }
  .action-row {
    align-items: flex-end;
  }
  .module-grid,
  .corpus,
  .works {
    grid-template-columns: 1fr;
  }
  .library-bar {
    display: block;
  }
  .select-filters {
    margin-top: 10px;
    flex-wrap: wrap;
  }
  .genre-select {
    display: flex !important;
  }
  .genre-chips {
    display: none;
  }
  .module {
    min-height: 218px;
  }
  .examples {
    display: none;
  }
  .reader-panel {
    padding: 24px 18px;
  }
  .reader-text {
    padding: 18px;
    font-size: 17px;
  }
  .concordance,
  .journey {
    padding: 16px;
  }
  .concordance-input,
  .journey-layout,
  .hit-card {
    grid-template-columns: 1fr;
  }
  .concordance-result-head {
    align-items: flex-start;
    flex-direction: column-reverse;
  }
  .hit-meta {
    white-space: normal;
  }
  .journey-map,
  .journey-detail {
    min-height: 320px;
  }
  .journey-map svg {
    min-height: 350px;
  }
}

.parse-warning {
  display: block;
  margin: 0 0 14px;
  padding: 10px 12px;
  border: 1px solid #c77966;
  border-radius: 6px;
  background: #fff4ea;
  color: #873f31;
  font:
    600 14px/1.55 'Noto Sans SC',
    'Microsoft YaHei',
    sans-serif;
}
