    :root {
      --bg: #f5f7fb;
      --card: #ffffff;
      --text: #172033;
      --muted: #667085;
      --line: #e5e7eb;
      --primary: #2563eb;
      --primary-soft: #eaf1ff;
      --shadow: 0 14px 40px rgba(15, 23, 42, 0.08);
      --radius: 22px;
      --sidebar-width: 318px;
      --header-height: 64px;
    }

    * {
      box-sizing: border-box;
    }

    html,
    body {
      width: 100%;
      min-height: 100%;
      scroll-behavior: smooth;
    }

    body {
      margin: 0;
      background: var(--bg);
      color: var(--text);
      font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
      overflow-x: hidden;
    }

    button,
    input {
      font: inherit;
      -webkit-tap-highlight-color: transparent;
    }

    button {
      cursor: pointer;
    }

    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    .mobile-topbar {
      display: none;
      position: sticky;
      top: 0;
      z-index: 40;
      height: var(--header-height);
      padding: 0 14px;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      background: rgba(245, 247, 251, 0.9);
      backdrop-filter: blur(16px);
      -webkit-backdrop-filter: blur(16px);
      border-bottom: 1px solid rgba(229, 231, 235, 0.86);
    }

    .mobile-title {
      min-width: 0;
    }

    .mobile-title strong {
      display: block;
      font-size: 15px;
      line-height: 1.25;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .mobile-title span {
      display: block;
      margin-top: 2px;
      color: var(--muted);
      font-size: 12px;
    }

    .menu-btn,
    .icon-btn {
      width: 42px;
      height: 42px;
      border: 1px solid var(--line);
      border-radius: 999px;
      background: #fff;
      color: var(--text);
      display: grid;
      place-items: center;
      box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
    }

    .menu-btn span,
    .menu-btn::before,
    .menu-btn::after {
      content: "";
      display: block;
      width: 18px;
      height: 2px;
      border-radius: 999px;
      background: currentColor;
    }

    .menu-btn {
      gap: 4px;
    }

    .page {
      width: min(1440px, 100%);
      margin: 0 auto;
      padding: 28px 24px 60px;
      display: grid;
      grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
      gap: 24px;
    }

    .sidebar-shell {
      position: sticky;
      top: 24px;
      align-self: start;
      height: calc(100vh - 48px);
      min-height: 560px;
      display: flex;
      min-width: 0;
    }

    .sidebar {
      width: 100%;
      min-height: 0;
      display: grid;
      grid-template-rows: auto auto auto minmax(0, 1fr);
      gap: 14px;
      background: var(--card);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: var(--shadow);
      padding: 16px;
    }

    .sidebar-head h1 {
      margin: 0;
      font-size: 22px;
      line-height: 1.2;
      letter-spacing: -0.03em;
    }

    .sidebar-head p {
      margin: 7px 0 0;
      color: var(--muted);
      font-size: 13px;
      line-height: 1.5;
    }

    .search-wrap {
      position: relative;
    }

    .search-wrap input {
      width: 100%;
      height: 44px;
      border: 1px solid var(--line);
      border-radius: 999px;
      outline: none;
      padding: 0 40px;
      color: var(--text);
      background: #fff;
      box-shadow: 0 6px 16px rgba(15, 23, 42, 0.04);
    }

    .search-wrap input:focus {
      border-color: rgba(37, 99, 235, 0.42);
      box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.08);
    }

    .search-wrap::before {
      content: "";
      position: absolute;
      left: 16px;
      top: 50%;
      width: 13px;
      height: 13px;
      border: 2px solid #94a3b8;
      border-radius: 50%;
      transform: translateY(-50%);
    }

    .search-wrap::after {
      content: "";
      position: absolute;
      left: 28px;
      top: 28px;
      width: 7px;
      height: 2px;
      border-radius: 999px;
      background: #94a3b8;
      transform: rotate(45deg);
    }

    .quick-section {
      display: grid;
      gap: 10px;
    }

    .quick-row {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 10px;
    }

    .section-title {
      margin: 0;
      font-size: 13px;
      color: var(--muted);
      font-weight: 800;
      letter-spacing: 0.04em;
    }

    .clear-btn {
      border: 0;
      background: transparent;
      color: var(--muted);
      font-size: 12px;
      padding: 4px 0;
    }

    .clear-btn:hover {
      color: var(--primary);
    }

    .quick-list {
      display: grid;
      gap: 6px;
    }

    .quick-list.empty {
      display: none;
    }

    .quick-topic-btn,
    .topic-btn {
      width: 100%;
      min-width: 0;
      border: 0;
      background: transparent;
      color: var(--text);
      border-radius: 14px;
      padding: 9px 10px;
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 8px;
      align-items: center;
      text-align: left;
      transition: 0.18s ease;
    }

    .quick-topic-btn:hover,
    .topic-btn:hover,
    .topic-btn.active {
      background: var(--primary-soft);
      color: var(--primary);
    }

    .quick-topic-btn span,
    .topic-title {
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      font-size: 13px;
      line-height: 1.4;
    }

    .mini-count {
      color: var(--muted);
      font-size: 12px;
      white-space: nowrap;
    }

    .catalog {
      min-height: 0;
      overflow: hidden;
      border-top: 1px solid var(--line);
      padding-top: 14px;
    }

    .catalog-scroll {
      height: 100%;
      overflow-y: auto;
      padding-right: 4px;
      scrollbar-width: thin;
      scrollbar-color: #cbd5e1 transparent;
    }

    .catalog-scroll::-webkit-scrollbar {
      width: 6px;
    }

    .catalog-scroll::-webkit-scrollbar-thumb {
      background: #cbd5e1;
      border-radius: 999px;
    }

    .category-block + .category-block {
      margin-top: 8px;
    }

    .category-toggle {
      width: 100%;
      border: 0;
      background: #f8fafc;
      color: var(--text);
      border-radius: 14px;
      padding: 10px 11px;
      display: grid;
      grid-template-columns: auto minmax(0, 1fr) auto;
      gap: 9px;
      align-items: center;
      text-align: left;
      transition: 0.18s ease;
    }

    .category-toggle:hover {
      background: var(--primary-soft);
      color: var(--primary);
    }

    .caret {
      width: 8px;
      height: 8px;
      border-right: 2px solid currentColor;
      border-bottom: 2px solid currentColor;
      transform: rotate(-45deg);
      transition: transform 0.18s ease;
    }

    .category-block.open .caret {
      transform: rotate(45deg);
    }

    .category-name {
      min-width: 0;
      font-size: 14px;
      font-weight: 800;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .category-num {
      color: var(--muted);
      font-size: 12px;
    }

    .topic-list {
      display: none;
      padding: 7px 0 2px 14px;
    }

    .category-block.open .topic-list {
      display: grid;
      gap: 4px;
    }

    .topic-btn {
      padding: 9px 10px;
      border-radius: 12px;
    }

    .fav-toggle {
      width: 28px;
      height: 28px;
      border: 0;
      border-radius: 999px;
      display: grid;
      place-items: center;
      background: transparent;
      color: #cbd5e1;
      font-size: 16px;
      transition: 0.18s ease;
    }

    .fav-toggle:hover,
    .fav-toggle.active {
      color: #f59e0b;
      background: rgba(245, 158, 11, 0.1);
    }

    .reader {
      min-width: 0;
    }

    .reader-head {
      background: var(--card);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
      padding: 24px;
      margin-bottom: 18px;
    }

    .breadcrumb {
      margin-bottom: 12px;
      color: var(--muted);
      font-size: 13px;
    }

    .reader-title-row {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 16px;
      align-items: start;
    }

    .reader-head h2 {
      margin: 0;
      font-size: 32px;
      line-height: 1.24;
      letter-spacing: -0.04em;
    }

    .reader-desc {
      margin: 12px 0 0;
      color: var(--muted);
      line-height: 1.75;
      font-size: 15px;
    }

    .meta-line {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      margin-top: 16px;
    }

    .pill {
      display: inline-flex;
      align-items: center;
      gap: 5px;
      padding: 7px 11px;
      border-radius: 999px;
      background: #fff;
      border: 1px solid var(--line);
      color: var(--muted);
      font-size: 12px;
    }

    .pill.primary {
      color: var(--primary);
      background: var(--primary-soft);
      border-color: rgba(37, 99, 235, 0.12);
      font-weight: 700;
    }

    .reader-fav {
      width: 44px;
      height: 44px;
      border: 1px solid var(--line);
      border-radius: 999px;
      background: #fff;
      color: #cbd5e1;
      font-size: 20px;
      box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
    }

    .reader-fav.active {
      color: #f59e0b;
      border-color: rgba(245, 158, 11, 0.32);
      background: rgba(245, 158, 11, 0.08);
    }

    .card-stack {
      display: grid;
      gap: 18px;
    }

    .knowledge-card {
      background: var(--card);
      border: 1px solid var(--line);
      border-radius: var(--radius);
      box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
      overflow: hidden;
    }

    .knowledge-card-header {
      padding: 14px 18px;
      border-bottom: 1px solid var(--line);
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 12px;
    }

    .knowledge-card-header h3 {
      margin: 0;
      font-size: 16px;
      line-height: 1.35;
    }

    .knowledge-card-header span {
      color: var(--muted);
      font-size: 13px;
      white-space: nowrap;
    }

    .knowledge-card img {
      width: 100%;
      display: block;
      cursor: zoom-in;
      background: #e5e7eb;
    }

    .reader-nav {
      margin-top: 20px;
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 14px;
    }

    .nav-card {
      border: 1px solid var(--line);
      background: var(--card);
      border-radius: 18px;
      padding: 16px;
      text-align: left;
      color: var(--text);
      box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
      transition: 0.18s ease;
    }

    .nav-card:hover {
      border-color: rgba(37, 99, 235, 0.28);
      transform: translateY(-2px);
    }

    .nav-card small {
      display: block;
      color: var(--muted);
      font-size: 12px;
      margin-bottom: 6px;
    }

    .nav-card strong {
      display: block;
      font-size: 15px;
      line-height: 1.45;
    }

    .nav-card.next {
      text-align: right;
    }

    .lightbox {
      position: fixed;
      inset: 0;
      z-index: 100;
      display: none;
      grid-template-rows: auto minmax(0, 1fr) auto;
      gap: 14px;
      padding: 20px;
      background: rgba(15, 23, 42, 0.86);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
    }

    .lightbox.show {
      display: grid;
    }

    .lightbox-top,
    .lightbox-stage,
    .lightbox-bottom {
      width: min(1180px, 100%);
      margin: 0 auto;
    }

    .lightbox-top {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 16px;
      color: #fff;
    }

    .lightbox-title {
      min-width: 0;
    }

    .lightbox-title strong {
      display: block;
      font-size: 17px;
      line-height: 1.35;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .lightbox-title span {
      display: block;
      margin-top: 4px;
      color: rgba(255, 255, 255, 0.7);
      font-size: 13px;
    }

    .close-btn,
    .lightbox-arrow {
      position: relative;
      border-radius: 999px;
      border: 1px solid rgba(255, 255, 255, 0.22);
      background: rgba(255, 255, 255, 0.1);
      color: #fff;
      box-shadow: 0 14px 34px rgba(0, 0, 0, 0.22);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
      transition: 0.18s ease;
    }

    .close-btn {
      width: 44px;
      height: 44px;
      flex: 0 0 auto;
    }

    .close-btn:hover,
    .lightbox-arrow:hover {
      background: rgba(255, 255, 255, 0.2);
      transform: scale(1.05);
    }

    .close-btn:active,
    .lightbox-arrow:active {
      transform: scale(0.96);
    }

    .close-btn::before,
    .close-btn::after {
      content: "";
      position: absolute;
      left: 50%;
      top: 50%;
      width: 17px;
      height: 2.2px;
      background: currentColor;
      border-radius: 999px;
      transform-origin: center;
    }

    .close-btn::before {
      transform: translate(-50%, -50%) rotate(45deg);
    }

    .close-btn::after {
      transform: translate(-50%, -50%) rotate(-45deg);
    }

    .lightbox-stage {
      position: relative;
      min-height: 0;
      display: grid;
      place-items: center;
      overflow: hidden;
      border-radius: 18px;
    }

    .lightbox-stage img {
      max-width: 100%;
      max-height: 100%;
      object-fit: contain;
      background: #fff;
      border-radius: 18px;
      box-shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
      transition: transform 0.2s ease;
      cursor: zoom-in;
      user-select: none;
    }

    .lightbox-stage img.zoomed {
      transform: scale(1.65);
      cursor: zoom-out;
    }

    .lightbox-arrow {
      position: absolute;
      top: 50%;
      width: 52px;
      height: 52px;
      transform: translateY(-50%);
      z-index: 3;
    }

    .lightbox-arrow:hover {
      transform: translateY(-50%) scale(1.05);
    }

    .lightbox-arrow.prev {
      left: 14px;
    }

    .lightbox-arrow.next {
      right: 14px;
    }

    .lightbox-arrow::before {
      content: "";
      position: absolute;
      left: 50%;
      top: 50%;
      width: 14px;
      height: 14px;
      border-top: 2.6px solid currentColor;
      border-right: 2.6px solid currentColor;
      border-radius: 1px;
    }

    .lightbox-arrow.prev::before {
      transform: translate(-42%, -50%) rotate(-135deg);
    }

    .lightbox-arrow.next::before {
      transform: translate(-58%, -50%) rotate(45deg);
    }

    .lightbox-bottom {
      color: rgba(255, 255, 255, 0.74);
      text-align: center;
      font-size: 13px;
    }

    .drawer-backdrop {
      display: none;
    }

    .no-result {
      padding: 18px 12px;
      color: var(--muted);
      font-size: 13px;
      text-align: center;
    }

    @media (max-width: 1080px) {
      .page {
        grid-template-columns: 290px minmax(0, 1fr);
      }

      :root {
        --sidebar-width: 290px;
      }

      .reader-head h2 {
        font-size: 28px;
      }
    }

    @media (max-width: 860px) {
      .mobile-topbar {
        display: flex;
      }

      .page {
        display: block;
        padding: 16px 12px 36px;
      }

      .sidebar-shell {
        position: fixed;
        inset: 0 auto 0 0;
        z-index: 80;
        width: min(88vw, 340px);
        height: 100vh;
        min-height: 0;
        padding: 12px;
        transform: translateX(-105%);
        transition: transform 0.22s ease;
      }

      body.drawer-open .sidebar-shell {
        transform: translateX(0);
      }

      .sidebar {
        height: 100%;
        border-radius: 20px;
        box-shadow: 0 24px 80px rgba(15, 23, 42, 0.24);
      }

      .drawer-backdrop {
        position: fixed;
        inset: 0;
        z-index: 70;
        background: rgba(15, 23, 42, 0.38);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
      }

      body.drawer-open .drawer-backdrop {
        display: block;
      }

      .reader-head {
        padding: 20px;
        border-radius: 20px;
      }

      .reader-title-row {
        grid-template-columns: 1fr auto;
      }

      .reader-head h2 {
        font-size: 25px;
      }

      .reader-desc {
        font-size: 14px;
      }

      .knowledge-card {
        border-radius: 18px;
      }

      .knowledge-card-header {
        padding: 12px 14px;
      }

      .knowledge-card-header h3 {
        font-size: 15px;
      }

      .reader-nav {
        grid-template-columns: 1fr;
      }

      .nav-card.next {
        text-align: left;
      }
    }

    @media (max-width: 560px) {
      .mobile-title strong {
        max-width: 230px;
      }

      .reader-head {
        padding: 18px;
      }

      .reader-head h2 {
        font-size: 23px;
      }

      .reader-fav {
        width: 40px;
        height: 40px;
      }

      .meta-line {
        gap: 7px;
      }

      .pill {
        padding: 7px 10px;
      }

      .lightbox {
        padding: 10px;
        gap: 10px;
      }

      .lightbox-title strong {
        font-size: 15px;
      }

      .lightbox-title span {
        font-size: 12px;
      }

      .close-btn {
        width: 40px;
        height: 40px;
      }

      .lightbox-arrow {
        width: 44px;
        height: 44px;
      }

      .lightbox-arrow.prev {
        left: 8px;
      }

      .lightbox-arrow.next {
        right: 8px;
      }

      .lightbox-stage img.zoomed {
        transform: scale(1.35);
      }
    }
  
