/* Gongpad 基础：墨色底、米色字（取自 logo），方角，宋体标题 + 安静的黑体 + 等宽数字 */
:root {
  --ink: #141416;
  --ink-1: #1c1c1e;   /* logo 底色 */
  --ink-2: #232326;
  --ink-3: #2c2c30;
  --cream: #e5e1d8;   /* logo 花瓣 */
  --cream-2: #cfcabf;
  --dim: rgba(229, 225, 216, .62);
  --faint: rgba(229, 225, 216, .38);
  --line: rgba(229, 225, 216, .12);
  --line-2: rgba(229, 225, 216, .22);
  --up: #e5513a;      /* 涨 / 买：朱红 */
  --up-2: #f0664f;
  --down: #35b583;    /* 跌 / 卖 */
  --gut: 28px;
  --serif: "Noto Serif SC", "Songti SC", "STSong", serif;
  --sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --grain: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='256' height='256'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .05 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { background: var(--ink); color: var(--cream); font-family: var(--sans); font-size: 15px; line-height: 1.7; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
::selection { background: var(--cream); color: var(--ink); }
:focus-visible { outline: 1px solid var(--cream); outline-offset: 3px; }
.serif { font-family: var(--serif); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.muted { color: var(--dim); }
.faint { color: var(--faint); }
.up { color: var(--up) !important; }
.down { color: var(--down) !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--cream); color: var(--ink); padding: 6px 12px; }
.skip:focus { left: 8px; }

/* 品牌 */
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand img { width: 22px; height: 22px; }
.brand__en { font-family: var(--mono); font-weight: 500; font-size: 13px; letter-spacing: .32em; }

/* 方形按钮 */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 22px; border: 1px solid var(--cream); background: var(--cream); color: var(--ink); font-weight: 500; letter-spacing: .04em; transition: background-color .15s, color .15s, opacity .15s; white-space: nowrap; }
.btn:hover { background: #fff; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn--line { background: transparent; color: var(--cream); border-color: var(--line-2); }
.btn--line:hover { background: var(--ink-2); border-color: var(--cream); }
.btn--up { background: var(--up); border-color: var(--up); color: #fff; }
.btn--up:hover { background: var(--up-2); }
.btn--down { background: var(--down); border-color: var(--down); color: #0b1a14; }
.btn--sm { height: 34px; padding: 0 14px; font-size: 13px; }
.link { color: var(--cream); border-bottom: 1px solid var(--line-2); padding-bottom: 1px; transition: border-color .15s; }
.link:hover { border-color: var(--cream); }

/* X 按钮（顶栏） */
.xbtn { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border: 1px solid var(--line-2); font-size: 13px; transition: border-color .15s, background-color .15s; }
.xbtn:hover { border-color: var(--cream); background: var(--ink-2); }
.xbtn svg { width: 14px; height: 14px; fill: currentColor; }

/* 椭圆转场幕布 */
.veil { position: fixed; inset: 0; z-index: 90; pointer-events: none; background: var(--ink-1); clip-path: ellipse(0% 0% at 50% 50%); }
.veil.is-close { animation: veilIn .56s cubic-bezier(.7, 0, .3, 1) forwards; pointer-events: auto; }
.is-arriving .veil { clip-path: ellipse(80% 95% at 50% 50%); }
.veil.is-open { animation: veilOut .7s cubic-bezier(.7, 0, .3, 1) forwards; }
@keyframes veilIn { from { clip-path: ellipse(0% 0% at 50% 50%); } to { clip-path: ellipse(80% 95% at 50% 50%); } }
@keyframes veilOut { from { clip-path: ellipse(80% 95% at 50% 50%); } to { clip-path: ellipse(0% 0% at 50% 50%); } }
.veil::after { content: ""; position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; transform: translate(-50%, -50%); background: url(/assets/mark.png) center / contain no-repeat; opacity: .9; }

@media (prefers-reduced-motion: reduce) {
  .veil.is-close, .veil.is-open { animation-duration: .01s; }
}
