/* Base typography, design tokens, scrollbars & film grain shared by admin.html */
@font-face { font-family: "Shoulders"; src: url(../fonts/big-shoulders-display-latin-800-normal.woff2) format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Shoulders"; src: url(../fonts/big-shoulders-display-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url(../fonts/ibm-plex-mono-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url(../fonts/ibm-plex-mono-latin-600-normal.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Instrument"; src: url(../fonts/instrument-serif-latin-400-italic.woff2) format("woff2"); font-style: italic; font-display: swap; }
@font-face { font-family: "Kaiji Title"; src: url(../fonts/noto-serif-sc-hero-regular.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Kaiji Title"; src: url(../fonts/noto-serif-sc-hero-bold.woff2) format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --ink: #0b0a09;
  --char: #13110f;
  --char2: #1a1714;
  --line: rgba(255, 232, 200, .09);
  --line2: rgba(255, 232, 200, .18);
  --paper: #f1e7d6;
  --dim: #8d8478;
  --faint: #5a534b;
  --tung: #ff8a2b;
  --tung-soft: rgba(255, 138, 43, .14);
  --rec: #ff3b30;
  --ok: #c8e86a;
  --serif-zh: "Noto Serif CJK SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans-zh: "PingFang SC", "Noto Sans CJK SC", "Source Han Sans SC", "Microsoft YaHei", sans-serif;
  --display: "Shoulders", "Arial Narrow", var(--sans-zh);
  --mono: "Plex Mono", ui-monospace, Menlo, monospace;
  --italic: "Instrument", Georgia, serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--ink); color: var(--paper); font-family: var(--sans-zh); -webkit-font-smoothing: antialiased; }
button { font: inherit; color: inherit; cursor: pointer; }
[hidden] { display: none !important; }
em { font-family: var(--italic); font-style: italic; font-weight: 400; }

::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: repeating-linear-gradient(180deg, transparent 0 10px, rgba(255, 232, 200, .035) 10px 14px); }
::-webkit-scrollbar-thumb { background: rgba(255, 138, 43, .45); border-left: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: rgba(255, 138, 43, .75); }
::-webkit-scrollbar-corner { background: transparent; }

.grain {
  position: fixed;
  inset: -50%;
  pointer-events: none;
  z-index: 50;
  opacity: .07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -4%); }
  60% { transform: translate(-4%, -1%); }
  80% { transform: translate(3%, 3%); }
  100% { transform: translate(0, 0); }
}
