  :root {
    --maxw: 900px;
    --border: #e6e6e6;
    --text: #222;
    --muted: #666;
    --bg: #fff;
    --soft: #fafafa;

    /* ✅ 固定錨點往下推的距離（桌機） */
    --anchor-offset: 86px;
  }

  @media (max-width: 767px) {
    :root {
      /* ✅ 固定錨點往下推的距離（手機）
   你要「像你圖中那個位置」：通常手機要比桌機再多一點 */
      --anchor-offset: 90px;
    }
  }

  body {
    margin: 0;
    color: var(--text);
    background: var(--bg);
    font-family: "Microsoft JhengHei", "Noto Sans TC", system-ui,
      -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang TC",
      sans-serif;
    line-height: 1.85;
  }

  /* =========================
     基本版面
     ========================= */
  .container {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 18px 20px 50px;
  }

  header.unit-header {
    max-width: var(--maxw);
    margin: 0 auto 18px;
    padding: 16px 20px 0;
  }

  header.unit-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 6px 0;
  }

  header.unit-header .meta {
    color: var(--muted);
    font-size: 0.95rem;
    margin: 0;
  }

  /* =========================
     上方操作
     ========================= */
  .top-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    margin: 12px 0 20px;
  }

  .btn {
    border: 1px solid var(--border);
    background: var(--soft);
    color: var(--text);
    padding: 8px 10px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
  }

  .btn:hover {
    filter: brightness(0.98);
  }

  /* =========================
     信仰核心問答（原 nav.toc）
     ========================= */
  nav.toc {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px;
    background: var(--soft);
    margin: 0 0 18px 0;
  }

  nav.toc h2 {
    font-size: 1.05rem;
    margin: 0 0 8px 0;
  }

  nav.toc ul,
  nav.toc ol {
    list-style: none;
    margin: 0;
    padding-left: 1.2em;
  }

  nav.toc li {
    margin: 4px 0;
  }

  nav.toc li::marker {
    content: "";
  }

  nav.toc a {
      color: inherit;
      text-decoration: none;
      padding: 2px 4px;
      border-radius: 6px;
      transition: color 0.15s ease-out, background-color 0.15s ease-out;
    }
    
    /* 滑過變色（沒有底線） */
    nav.toc a:hover,
    nav.toc a:focus-visible {
      color: #0056b3;
      background: #eef4ff;
    }
    
    /* 點下去那一瞬間顏色再深一點 */
    nav.toc a:active {
      color: #003c82;
    }
    
    /* 目前所在題目（JS 會加上 .is-active） */
    nav.toc a.is-active {
      color: #004085;
      background: #e3ecff;
      font-weight: 700;
    }

  /* =========================
     Q&A 區塊
     ========================= */
  .qa-item {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px 12px;
    margin: 12px 0;
  }

  .qa-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
  }

  .qa-head h2 {
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0;
  }

  .toggle {
    width: 38px;
    height: 32px;
    padding: 0;
    text-align: center;

    font-size: 1.2rem; /* + - 清楚 */
    font-weight: 900;
    line-height: 1;

    border: 1px solid var(--border);
    background: #fff;
    border-radius: 10px;
    cursor: pointer;
  }

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

  .qa-body {
    margin-top: 10px;
  }

  .qa-body p {
    margin: 10px 0;
  }

  .qa-list {
    list-style: none;
    margin: 10px 0 0 0;
    padding-left: 0;
  }

  .qa-list li {
    margin: 6px 0;
  }

  .evidence h3 {
    font-size: 1rem;
    margin: 14px 0 6px;
    font-weight: 800;
  }

  /* =========================
     錨點定位與高亮（✅ 手機/桌機都精準）
     ========================= */
  [id^="q"] {
    scroll-margin-top: var(--anchor-offset);
  }

  h2:target,
  h3:target {
    background: #fff7cc;
    outline: 2px solid #f3d36a;
    border-radius: 10px;
    padding: 6px 8px;
  }

  .flash-highlight {
    animation: flashBg 1.2s ease-in-out 1;
  }

  @keyframes flashBg {
    0% {
      background: #fff7cc;
    }
    50% {
      background: #fff1a8;
    }
    100% {
      background: transparent;
    }
  }

  /* =========================
     頂部導覽列（✅ 取消箭頭版本）
     ========================= */
  .top-nav {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid var(--border);
    background: var(--bg);
  }

  .top-nav__inner {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
  }

  .top-nav__back {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border: 1px solid var(--border);
    border-radius: 10px;
    text-decoration: none;
    color: var(--text);
    background: var(--soft);
    font-weight: 700;
  }

  .top-nav__back::before {
    content: "";
    margin-right: 0;
  }

  .top-nav__link {
    color: var(--text);
    text-decoration: none;
    font-weight: 700;
  }

  .top-nav__sep {
    color: var(--muted);
  }

  .top-nav__current {
    font-weight: 700;
    color: #555;
  }

  .top-nav a:hover {
    text-decoration: underline;
  }

  .top-nav a:focus-visible {
    outline: 2px solid #99c2ff;
    outline-offset: 2px;
    border-radius: 10px;
  }

  /* =========================
     列印（教材用）
     ========================= */
  @media print {
    @page {
      size: A4;
      margin: 20mm 18mm;
    }

    .top-actions,
    nav.toc,
    .top-nav {
      display: none;
    }

    body {
      font-size: 12pt;
    }

    ul,
    li {
      page-break-inside: avoid;
    }
  }

  /* =========================
     手機（≤ 767px）只調字/間距，不再硬猜 offset
     ========================= */
  @media (max-width: 767px) {
    .top-nav__inner {
      padding: 8px 12px;
      gap: 6px;
      font-size: 13px;
      line-height: 1.35;
    }

    .top-nav__back,
    .top-nav__link {
      padding: 4px 8px;
      border-radius: 10px;
    }

    .top-nav__sep {
      opacity: 0.75;
    }
  }
  
/* 小螢幕微調 */
@media (max-width: 520px) {
  header.unit-header {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 6px 20px;
  }
  
  header.unit-header h1 {
    font-size: 1.3rem;
  }
  
  .container {
    padding: 0px 20px 50px;
  }
  
  .top-actions {
    margin: 0px 0 10px;
 }
}
  
  /* =========================
     內容條列：已含（1）（2）…，不需要前面的圓點
     ========================= */
  ul.no-marker,
  ol.no-marker {
    list-style: none;
    margin-left: 0;
    padding-left: 0;
  }

  ul.no-marker > li,
  ol.no-marker > li {
    margin-left: 0;
    padding-left: 0;
  }

