/* ============================================================
   castyi · 方法論頁樣式（howto.css）
   ============================================================ */
.ht-wrap{max-width:720px; margin:0 auto}
.ht-lead{font-size:var(--text-lg, 18px); line-height:1.95; color:var(--ink); text-align:left;
  padding:0 0 var(--space-6); border-bottom:1px solid var(--line); margin-bottom:var(--space-7)}

.ht-sec{margin-bottom:var(--space-8)}
.ht-sec h2{font-family:var(--serif); font-size:22px; font-weight:500; margin:0 0 var(--space-4);
  line-height:1.5; color:var(--ink); padding-left:16px; position:relative}
.ht-sec h2::before{content:''; position:absolute; left:0; top:.55em; width:6px; height:6px;
  border-radius:50%; background:var(--cinnabar)}

.ht-sec p{font-size:15.5px; line-height:2.05; color:var(--ink2); margin-bottom:var(--space-4); text-align:left}

.ht-list{list-style:none; padding:0; margin:var(--space-4) 0}
.ht-list li{font-size:14.5px; line-height:1.9; color:var(--ink2); padding:9px 0 9px var(--space-5);
  border-bottom:1px dashed var(--line); position:relative}
.ht-list li::before{content:'·'; position:absolute; left:6px; color:var(--cinnabar); font-weight:700}
.ht-list li:last-child{border-bottom:none}

.ht-quote{margin:var(--space-6) 0; padding:var(--space-5) var(--space-6);
  border-left:3px solid var(--cinnabar); background:var(--cinnabar-soft);
  font-family:var(--serif); font-size:17px; line-height:1.85; color:var(--ink); font-style:italic}
.ht-quote cite{display:block; margin-top:var(--space-3); font-family:var(--sans); font-size:12px;
  font-style:normal; color:var(--ink3); letter-spacing:.04em}

.ht-scroll{overflow-x:auto; -webkit-overflow-scrolling:touch; margin:var(--space-5) 0}
.ht-tbl{width:100%; border-collapse:collapse; font-size:14px; table-layout:fixed}
.ht-tbl th{text-align:left; font-weight:500; color:var(--ink); padding:12px 14px 12px 0;
  border-bottom:1px solid var(--line3); vertical-align:top; width:34%; word-break:break-word}
.ht-tbl td{padding:12px 0; border-bottom:1px solid var(--line); color:var(--ink2); line-height:1.85;
  word-break:break-word}
.ht-tbl tr:last-child th,.ht-tbl tr:last-child td{border-bottom:none}
/* 手機：改為堆疊式（名稱在上、說明在下），彻底避免窄欄截斷 */
@media (max-width:560px){
  .ht-tbl,.ht-tbl tbody,.ht-tbl tr,.ht-tbl th,.ht-tbl td{display:block; width:100%}
  .ht-tbl tr{border-bottom:1px solid var(--line); padding:var(--space-3) 0}
  .ht-tbl tr:last-child{border-bottom:none}
  .ht-tbl th{width:auto; border-bottom:none; padding:0 0 4px; font-size:13.5px}
  .ht-tbl td{border-bottom:none; padding:0; font-size:13.5px; line-height:1.9}
  .tg{width:20px; height:auto; margin-right:4px}
}

.ht-qa{margin:var(--space-5) 0}
.ht-q{border:1px solid var(--line); border-radius:5px; background:var(--paper2); margin-bottom:10px; overflow:hidden}
.ht-q summary{cursor:pointer; padding:14px 18px; font-size:15px; color:var(--ink); font-weight:500;
  list-style:none; position:relative; padding-right:40px; min-height:48px; display:flex; align-items:center}
.ht-q summary::-webkit-details-marker{display:none}
.ht-q summary::after{content:'＋'; position:absolute; right:16px; top:50%; transform:translateY(-50%);
  color:var(--cinnabar); font-size:19px; font-weight:400}
.ht-q[open] summary::after{content:'−'}
.ht-q[open] summary{border-bottom:1px solid var(--line)}
.ht-q summary:hover{background:var(--cinnabar-soft)}
.ht-a{padding:16px 18px; font-size:14.5px; line-height:2; color:var(--ink2)}

.ht-check{background:var(--paper2); border:1px solid var(--line); border-radius:6px;
  padding:var(--space-6) var(--space-7); margin-top:var(--space-8)}
.ht-check h2{margin-top:0; padding-left:16px}
.ht-check h2::before{background:var(--jade)}
.ht-checks{list-style:none; padding:0; margin:var(--space-4) 0 0}
.ht-checks li{font-size:15px; line-height:1.9; color:var(--ink); padding:11px 0 11px 30px;
  border-bottom:1px dashed var(--line); position:relative}
.ht-checks li::before{content:'□'; position:absolute; left:0; top:11px; color:var(--jade); font-size:16px}
.ht-checks li:last-child{border-bottom:none}

/* ---------- 學習頁卡片 ---------- */
.ht-learn{margin-top:var(--space-8)}
.learn-cards{display:grid; grid-template-columns:1fr 1fr; gap:var(--space-3); margin-top:var(--space-5)}
@media (max-width:600px){ .learn-cards{grid-template-columns:1fr} }
.learn-card{display:flex; align-items:center; justify-content:space-between; gap:var(--space-3);
  padding:var(--space-4) var(--space-5); border:1px solid var(--line); border-radius:var(--radius-sm);
  background:var(--paper2); min-height:56px; transition:border-color .15s,background .15s}
.learn-card:hover{border-color:var(--cinnabar); background:var(--cinnabar-soft)}
.learn-card .lc-t{font-size:14.5px; color:var(--ink); line-height:1.6}
.learn-card .lc-a{color:var(--cinnabar); font-size:16px; flex:none}

/* ---------- 學習頁 ---------- */
/* 三畫卦符號（SVG 绘制，避免系統缺字） */
.tg{display:inline-block; vertical-align:-4px; margin:0 6px 0 2px; color:var(--ink2)}
.ht-tbl th .tg{color:var(--cinnabar)}

.learn-h1{font-family:var(--serif); font-size:28px; font-weight:500; text-align:center; margin:0 0 var(--space-3)}
.learn-lead{font-size:16.5px; line-height:1.95; color:var(--ink2); text-align:center;
  max-width:600px; margin:0 auto var(--space-7); padding-bottom:var(--space-6);
  border-bottom:1px solid var(--line)}
.learn-tabs{display:flex; flex-wrap:wrap; gap:var(--space-2); justify-content:center;
  margin:var(--space-7) 0 0; padding-top:var(--space-6); border-top:1px solid var(--line)}
.learn-tabs a{font-size:13px; color:var(--ink2); padding:9px 18px; min-height:40px;
  display:inline-flex; align-items:center; border:1px solid var(--line); border-radius:var(--radius-sm);
  background:var(--paper2); transition:border-color .15s,color .15s}
.learn-tabs a:hover{border-color:var(--cinnabar); color:var(--cinnabar)}
.learn-tabs a.on{background:var(--cinnabar); border-color:var(--cinnabar); color:#fff}

@media (max-width:640px){
  .ht-sec h2{font-size:19px}
  .ht-quote{font-size:15.5px; padding:var(--space-4)}
  .ht-check{padding:var(--space-5)}
  .learn-h1{font-size:23px}
  .learn-lead{font-size:15px}
}
