:root {
  color-scheme: light;
  --ink: #182747;
  --muted: #586478;
  --line: #c9d0d8;
  --paper: #f6f7f4;
  --blue: #243e86;
  --orange: #f36544;
  font: 100%/1.65 "Inter", "Microsoft YaHei", system-ui, sans-serif;
  background: var(--paper);
  color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: inherit; text-underline-offset: .22em; }
a:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid #235bcb; outline-offset: 4px; }
header { border-bottom: 1px solid var(--line); }
.bar, main, footer { width: min(70rem, 90%); margin-inline: auto; }
.bar, nav, footer, .brand { display: flex; align-items: center; }
.bar, footer { justify-content: space-between; }
.bar { min-height: 4.5rem; }
.brand { gap: .65rem; font-weight: 750; }
.brand i { width: 2rem; text-align: center; line-height: 2rem; font: italic bold 1.85rem/2rem Georgia, serif; background: var(--blue); color: white; }
nav { gap: clamp(1rem, 4vw, 2.8rem); }
nav a { padding-block: .7rem; }
.brand, nav a, .entry, .tool { text-decoration: none; }
.skip { position: absolute; left: 1rem; top: -5rem; background: white; padding: .5rem; z-index: 2; }
.skip:focus { top: 1rem; }
.cover { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 2rem; padding: clamp(2.5rem, 6vw, 5rem) 0; }
.kicker, .meta, .entry small { color: var(--muted); font-size: .87rem; }
.kicker { display: flex; align-items: center; gap: .75rem; margin: 0 0 1rem; }
.kicker::before { content: ""; width: 1.8rem; height: 3px; background: var(--orange); }
.cover h1 { margin: 0; font-size: clamp(3.5rem, 7.8vw, 6.7rem); line-height: .98; letter-spacing: -.055em; }
.cover h1 em { font-family: Georgia, "Times New Roman", serif; font-size: 1.14em; font-weight: 500; }
.cover h1 span { color: var(--orange); }
.intro { margin: 1.5rem 0 0; color: var(--muted); }
.art { position: relative; display: grid; place-items: center; aspect-ratio: 1.65; overflow: hidden; background-color: #e2e8ec; background-image: radial-gradient(#a8b4c2 1px, transparent 1px); background-size: 12px 12px; }
.sheet, .shadow-sheet { position: absolute; width: 47%; height: 78%; }
.shadow-sheet { background: var(--orange); transform: translate(10%, 3%) rotate(9deg); }
.sheet { transform: rotate(-10deg); background: var(--blue); box-shadow: 5px 8px 0 #17244c22; color: #fff; display: grid; grid-template-rows: 1fr auto auto; padding: 4% 5% 4% 8%; }
.sheet i { font: italic 600 clamp(4rem, 9vw, 8.6rem)/1 Georgia, serif; align-self: center; }
.spine { position: absolute; inset: 0 auto 0 7%; border-left: 1px solid #aab9da77; }
.rule { height: 3px; background: var(--orange); margin-bottom: 5%; }
.sheet small { font: 600 .8rem/1.3 monospace; letter-spacing: .14em; }
.columns { display: grid; grid-template-columns: 1.55fr 1fr; gap: clamp(2rem, 6vw, 5rem); margin-bottom: 4rem; }
h2 { display: flex; align-items: baseline; gap: .65rem; margin: 0; padding-bottom: .7rem; border-bottom: 2px solid var(--ink); font-size: 1.5rem; }
h2 span { font: .85rem monospace; color: var(--muted); }
.entry, .tool { display: block; padding: 1.2rem 0; border-bottom: 1px solid var(--line); }
h3 { font-size: 1.2rem; margin: .14rem 0; }
.entry p, .tool p { margin: .3rem 0 0; color: var(--muted); }
.tool { display: flex; align-items: center; gap: 1rem; }
.tool b { flex: 0 0 3rem; text-align: center; background: #e4e9f4; color: var(--blue); font: 1.5rem/3rem Georgia, serif; }
.tool:last-child b { color: #9d391f; background: #f7e1d6; }
.entry:hover h3, .tool:hover h3, nav a:hover { text-decoration: underline; }
footer { border-top: 1px solid var(--line); padding-block: 1.2rem; color: var(--muted); font-size: .86rem; }
.reading { max-width: 43rem; margin: clamp(2rem, 7vw, 5rem) auto; min-height: 55vh; }
.reading h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.2; letter-spacing: -.035em; margin: 1rem 0 1.6rem; }
.reading p { line-height: 1.9; }
.meta { margin: 2rem 0 .5rem; }
.reading label, output { display: block; font-weight: 650; margin-block: 1rem .5rem; }
textarea, input { width: 100%; max-width: 100%; font: inherit; color: var(--ink); background: white; padding: .8rem; border: 1px solid #8290a2; border-radius: .2rem; }
textarea { resize: vertical; }
.sample { height: 6rem; border: 1px solid var(--line); }
.help { font-size: .9rem; color: var(--muted); }
.action { display: inline-block; padding: .6rem 1rem; color: white; background: var(--blue); }
.admin button, .admin select { font: inherit; padding: .6rem 1rem; border: 1px solid var(--blue); }
.admin button { cursor: pointer; color: white; background: var(--blue); margin-top: 1rem; }
.admin-actions { display: flex; align-items: baseline; flex-wrap: wrap; gap: 1rem; }
.admin input[readonly] { background: #e7eaf0; }
.admin [role="status"]:empty { display: none; }
@media (max-width: 43rem) {
  .cover { grid-template-columns: 1fr; gap: 1.6rem; }
  .art { aspect-ratio: 2.5; }
  .sheet, .shadow-sheet { width: 32%; }
  .sheet { padding: 2% 3% 2% 5%; }
  .sheet i { font-size: clamp(2.6rem, 10vw, 4rem); }
  .columns { grid-template-columns: 1fr; }
  .bar { min-height: 4rem; }
}
