/* /fansongs -- Dr. Fan's herb songs, laid out like the Classics site (2026-11-06) */
.fs-page { --fs-red: #a8392c; --fs-red-soft: #f6e9e6; --fs-rule: #dde1df; --fs-muted: #5f686c;
  --fs-zh: "Noto Serif SC", "Songti SC", "STSong", "Noto Serif TC", serif;
  max-width: 1080px; margin: 0 auto; padding: 8px 16px 64px; }
@media (prefers-color-scheme: dark) { .fs-page { --fs-red: #e27a69; --fs-red-soft: #33211e; --fs-rule: #2d3438; --fs-muted: #9aa4a8; } }
.fs-page [lang="zh"] { font-family: var(--fs-zh); }
.fs-intro h1 { margin: 12px 0 8px; font-size: 1.9rem; line-height: 1.3; }
.fs-intro h1 [lang="zh"] { color: var(--fs-red); margin-right: .3em; }
.fs-intro p { line-height: 1.65; }
.fs-note { color: var(--fs-muted); font-size: .9rem; }
.fs-toc { border: 1px solid var(--fs-rule); border-radius: 10px; padding: 12px 20px; margin: 20px 0 28px; }
.fs-toc h2 { margin: 0 0 6px; font-size: 1.05rem; text-align: left; }
.fs-toc ol { margin: 0; padding-left: 1.3em; columns: 2 320px; column-gap: 32px; }
.fs-toc li { break-inside: avoid; margin: 3px 0; }
.fs-toc ul { margin: 2px 0 6px; padding-left: 1.1em; font-size: .92rem; list-style: none; }
.fs-toc a { color: inherit; text-decoration: none; }
.fs-toc a:hover { color: var(--fs-red); text-decoration: underline; }
.fs-toc [lang="zh"] { color: var(--fs-red); margin-right: .25em; }
.fs-section { margin-top: 36px; }
.fs-section h2 { border-bottom: 2px solid var(--fs-red); padding-bottom: 6px; font-size: 1.45rem; }
.fs-section h2 [lang="zh"], .fs-sub h3 [lang="zh"] { color: var(--fs-red); margin-right: .35em; }
.fs-sub h3 { margin: 22px 0 6px; font-size: 1.12rem; }
.fs-h-en { font-weight: 600; }
.fs-song { padding: 8px 0; border-bottom: 1px dashed var(--fs-rule); }
.fs-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); column-gap: 36px; padding: 2px 6px; border-radius: 4px; }
.fs-row:hover, .fs-row:target { background: linear-gradient(90deg, var(--fs-red-soft), transparent 70%); }
.fs-zh { margin: 0; font-size: 1.12rem; line-height: 1.9; letter-spacing: .03em; }
.fs-en { margin: 0; line-height: 1.7; }
.fs-mnemonic .fs-zh { color: var(--fs-red); font-weight: 600; }
.fs-key { display: block; color: var(--fs-muted); font-size: .88rem; line-height: 1.5; margin: 2px 0 6px; }
@media (max-width: 640px) { .fs-row { grid-template-columns: 1fr; padding: 4px 0; } .fs-en { margin-bottom: 4px; } }
/* Back to the Table of Contents (2026-11-07): a "↑ Contents" link on each section heading and a round
   floating ↑ button, shown by public/js/fansongs.js once the contents box has scrolled out of view. */
.fs-up { float: right; margin-top: .35em; font-size: .8rem; font-weight: 400; color: var(--fs-muted); text-decoration: none; white-space: nowrap; }
.fs-up:hover { color: var(--fs-red); text-decoration: underline; }
.fs-top { position: fixed; right: 20px; bottom: 24px; z-index: 50; width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 1.35rem; line-height: 1; text-decoration: none;
  background: var(--fs-red); color: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.25);
  opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .2s, transform .2s; }
.fs-top.is-shown { opacity: .9; pointer-events: auto; transform: none; }
.fs-top:hover, .fs-top:focus-visible { opacity: 1; }
.fs-top { --fs-red: #a8392c; }
@media (prefers-color-scheme: dark) { .fs-top { --fs-red: #c0503f; } }
html { scroll-behavior: smooth; }
#toc, .fs-section, .fs-sub { scroll-margin-top: 12px; }
@media (max-width: 640px) { .fs-top { right: 14px; bottom: 16px; } }
