/* fhc_links — 投影模式與列印學習單（獨立頁面，不套用佈景） */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", system-ui, sans-serif; color: #111827; background: #fff; }
button { font-family: inherit; }

/* ---------- 投影模式 ---------- */
body.present { background: #0f172a; color: #f8fafc; min-height: 100vh; }
.fhcl-present { min-height: 100vh; display: flex; flex-direction: column; font-size: 100%; }
.fhcl-p-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 1.2vh 2.5vw; background: #1e293b; }
.fhcl-p-top h1 { margin: 0; font-size: 2.2em; line-height: 1.2; }
.fhcl-p-tools { display: flex; gap: 8px; }
.fhcl-p-tools button { background: #334155; color: #fff; border: 0; border-radius: 10px; font-size: 1.1em; padding: 8px 14px; cursor: pointer; }
.fhcl-p-tools button:hover { background: #475569; }
.fhcl-p-main { flex: 1 1 auto; display: grid; grid-template-columns: minmax(260px, 34vw) 1fr; gap: 2.5vw; padding: 2.5vh 2.5vw; align-items: start; }
.fhcl-p-side { background: #fff; color: #111827; border-radius: 22px; padding: 2.2vh 1.6vw; text-align: center; position: sticky; top: 2vh; }
.fhcl-p-code small { display: block; font-size: 1.1em; color: #4b5563; }
.fhcl-p-code b { display: block; font-family: Consolas, "Courier New", monospace; font-size: 4em; letter-spacing: .12em; color: #B4267A; line-height: 1.1; }
.fhcl-p-qr { width: 100%; max-width: 60vh; margin: 1.2vh auto; }
.fhcl-p-qr svg { width: 100%; height: auto; display: block; }
.fhcl-p-qrcap { font-size: 1.3em; font-weight: 700; }
.fhcl-p-site { font-size: 1.1em; color: #475569; font-family: Consolas, monospace; margin-top: 4px; word-break: break-all; }
.fhcl-p-back { margin-top: 12px; background: #e2e8f0; border: 0; border-radius: 10px; padding: 8px 16px; font-size: 1em; cursor: pointer; }
.fhcl-p-intro { font-size: 1.5em; background: #1e293b; border-radius: 16px; padding: 1.2em 1.4em; margin-bottom: 1.4vh; line-height: 1.5; }
.fhcl-p-list { display: flex; flex-direction: column; gap: 1.4vh; }
.fhcl-p-item { display: flex; align-items: center; gap: 1.2em; background: #1e293b; border: 3px solid transparent; border-radius: 18px; padding: 1em 1.3em; cursor: pointer; transition: background .15s; }
.fhcl-p-item:hover { background: #273449; }
.fhcl-p-item.on { border-color: #ff91ce; background: #312244; }
.fhcl-p-no { flex-shrink: 0; width: 2.4em; height: 2.4em; border-radius: 50%; background: #B4267A; color: #fff; font-weight: 800; font-size: 1.6em; display: flex; align-items: center; justify-content: center; }
.fhcl-p-txt { flex: 1 1 auto; min-width: 0; }
.fhcl-p-txt b { display: block; font-size: 1.9em; line-height: 1.3; }
.fhcl-p-txt em { display: block; font-style: normal; font-size: 1.3em; color: #bbf7d0; margin-top: .3em; line-height: 1.45; }
.fhcl-p-open { flex-shrink: 0; background: #ff91ce; color: #111827; text-decoration: none; font-weight: 800; padding: .5em 1em; border-radius: 12px; font-size: 1.2em; }
@media (max-width: 800px) {
  .fhcl-p-main { grid-template-columns: 1fr; }
  .fhcl-p-side { position: static; }
}

/* ---------- 列印學習單 ---------- */
body.print { background: #f3f4f6; }
.fhcl-ws-tools { text-align: center; padding: 12px; }
.fhcl-ws-tools button { font-size: 1rem; padding: 8px 18px; border-radius: 8px; border: 1px solid #d1d5db; background: #fff; cursor: pointer; }
.fhcl-ws-tools button:first-child { background: #B4267A; color: #fff; border-color: #B4267A; }
.fhcl-ws { width: 210mm; max-width: 100%; min-height: 297mm; margin: 0 auto 20px; background: #fff; padding: 14mm 14mm 10mm; box-shadow: 0 2px 10px rgba(0,0,0,.08); }
.fhcl-ws-head { display: flex; gap: 16px; justify-content: space-between; align-items: flex-start; border-bottom: 2px solid #111827; padding-bottom: 8px; margin-bottom: 10px; }
.fhcl-ws-head h1 { margin: 0 0 4px; font-size: 1.375rem; }
.fhcl-ws-intro { font-size: 0.813rem; color: #374151; margin-bottom: 6px; }
.fhcl-ws-fields { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 0.875rem; }
.fhcl-ws-setqr { width: 30mm; text-align: center; font-size: 0.688rem; flex-shrink: 0; }
.fhcl-ws-setqr svg { width: 100%; height: auto; display: block; }
.fhcl-ws-table { width: 100%; border-collapse: collapse; font-size: 0.813rem; }
.fhcl-ws-table th, .fhcl-ws-table td { border: 1px solid #9ca3af; padding: 6px 8px; vertical-align: middle; }
.fhcl-ws-table th { background: #f3f4f6; }
.fhcl-ws-table td.no { width: 8mm; text-align: center; font-weight: 700; font-size: 1rem; }
.fhcl-ws-table td.qr { width: 26mm; padding: 3px; }
.fhcl-ws-table td.qr svg { width: 24mm; height: 24mm; display: block; margin: 0 auto; }
.fhcl-ws-table td.done { width: 12mm; text-align: center; font-size: 1.375rem; }
.fhcl-ws-table .tt { font-weight: 700; font-size: 0.875rem; }
.fhcl-ws-table .task { margin: 2px 0; }
.fhcl-ws-table .desc { color: #4b5563; font-size: 0.75rem; }
.fhcl-ws-table .u { font-family: Consolas, monospace; font-size: 0.656rem; color: #374151; word-break: break-all; }
.fhcl-ws-table tr { break-inside: avoid; page-break-inside: avoid; }
.fhcl-ws-foot { text-align: right; color: #4b5563; font-size: 0.688rem; margin-top: 8px; }
@page { size: A4; margin: 0; }
@media print {
  body.print { background: #fff; }
  .noprint { display: none !important; }
  .fhcl-ws { box-shadow: none; margin: 0; width: auto; min-height: 0; }
}

/* 無障礙 */
.fhcl-sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
button:focus-visible, a:focus-visible { outline: 4px solid #ff91ce; outline-offset: 3px; }
body.print button:focus-visible, body.print a:focus-visible { outline-color: #B4267A; }
.fhcl-p-item { width: 100%; text-align: left; font: inherit; color: inherit; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.fhcl-p-sel { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 1.2em; background: transparent; border: 0; padding: 0; margin: 0; color: inherit; font: inherit; text-align: left; cursor: pointer; }
