/*
 * 跨页面共用组件
 *
 * 这里的每一条规则都在 5 个以上的页面样板里逐字出现过 —— 是数出来的，
 * 不是凭感觉判断「这条看起来像通用组件」。值与样板完全一致，没有改动。
 *
 * 页面专属样式在 page-*.css 里，那些文件会晚于本文件加载。
 */

* { box-sizing:border-box; }
body {
	background:var(--bg);
	color:var(--ink);
	font-family:'Inter',sans-serif;
	-webkit-font-smoothing:antialiased;
}
a {
	color:inherit;
	text-decoration:none;
}
.brand {
	display:flex;
	align-items:center;
	gap:9px;
}
.brand-mark {
	width:28px;
	height:28px;
	border-radius:8px;
	background:var(--ink);
	display:flex;
	align-items:center;
	justify-content:center;
}
.brand-mark svg {
	width:15px;
	height:15px;
}
.brand span {
	font-family:'Fraunces',serif;
	font-size:19px;
	font-weight:600;
}
.lang-opt {
	color:var(--ink-soft);
	font-weight:500;
	cursor:pointer;
	padding:4px 3px;
}
.lang-opt:hover { color:var(--ink); }
.lang-opt.active {
	color:var(--ink);
	font-weight:700;
	cursor:default;
}
@media (prefers-reduced-motion:reduce) {
  * {
  	transition:none !important;
  	animation:none !important;
  }
}
html, body {
	margin:0;
	padding:0;
	height:100%;
}
h1, h2 {
	font-family:'Fraunces',serif;
	font-weight:600;
	margin:0;
}
.lang-switch {
	display:flex;
	align-items:center;
	gap:5px;
	margin-right:2px;
	font-size:13px;
}
.lang-divider { color:#D4D4D8; }
.toast.show {
	opacity:1;
	transform:translateX(-50%) translateY(0);
}
.panel { display:none; }
.panel.active { display:block; }
.field { margin-bottom:16px; }
.field label {
	display:block;
	font-size:12.3px;
	color:var(--ink-soft);
	margin-bottom:6px;
	font-weight:500;
}
.submit-btn:hover { background:#000; }
html, body {
	margin:0;
	padding:0;
}
.avatar-menu { position:relative; }
.avatar-dropdown.open { display:flex; }
.avatar-dropdown .dd-user {
	padding:8px 10px 10px;
	border-bottom:1px solid var(--border);
	margin-bottom:5px;
}
.avatar-dropdown .dd-user .name {
	font-size:13px;
	font-weight:600;
	color:var(--ink);
}
.avatar-dropdown .dd-user .email {
	font-size:11.5px;
	color:var(--ink-soft);
	margin-top:2px;
}
.avatar-dropdown a, .avatar-dropdown .dd-item {
	display:flex;
	align-items:center;
	gap:9px;
	padding:9px 10px;
	border-radius:8px;
	font-size:13px;
	color:var(--ink);
	cursor:pointer;
}
.avatar-dropdown a:hover, .avatar-dropdown .dd-item:hover { background:var(--bg-soft); }
.avatar-dropdown svg {
	width:15px;
	height:15px;
	color:var(--ink-soft);
	flex-shrink:0;
}
.avatar-dropdown .dd-divider {
	height:1px;
	background:var(--border);
	margin:5px 2px;
}
.avatar-dropdown .dd-logout { color:var(--accent); }
.avatar-dropdown .dd-logout svg { color:var(--accent); }
h1, h2, h3 {
	font-family:'Fraunces',serif;
	font-weight:600;
	margin:0;
}
.topbar {
	height:64px;
	display:flex;
	align-items:center;
	justify-content:space-between;
	padding:0 28px;
	border-bottom:1px solid var(--border);
	position:sticky;
	top:0;
	background:#fff;
	z-index:10;
}
.nav {
	display:flex;
	gap:4px;
	margin-left:32px;
}
.nav a {
	font-size:13.5px;
	padding:7px 13px;
	border-radius:8px;
	color:var(--ink-soft);
}
.nav a.active {
	color:var(--ink);
	background:var(--bg-soft);
	font-weight:500;
}
.top-left {
	display:flex;
	align-items:center;
}
.top-right {
	display:flex;
	align-items:center;
	gap:10px;
}
.points-pill {
	display:flex;
	align-items:center;
	gap:5px;
	border:1px solid var(--border);
	border-radius:999px;
	padding:6px 13px;
	font-size:13px;
	color:var(--ink-soft);
}
.points-pill b {
	color:var(--ink);
	font-weight:600;
}
.avatar {
	width:28px;
	height:28px;
	border-radius:50%;
	background:linear-gradient(135deg,#FF9466,#8A4B6B);
	display:block;
}
.avatar-dropdown {
	position:absolute;
	top:calc(100% + 10px);
	right:0;
	width:208px;
	background:#fff;
	border:1px solid var(--border);
	border-radius:12px;
	box-shadow:var(--shadow);
	padding:6px;
	z-index:50;
	display:none;
	flex-direction:column;
	gap:1px;
}
.page-head h1 {
	font-size:26px;
	margin-bottom:8px;
}
thead th {
	text-align:left;
	font-size:11px;
	text-transform:uppercase;
	letter-spacing:.05em;
	color:var(--ink-soft);
	padding:13px 18px;
	border-bottom:1px solid var(--border);
	font-weight:600;
	background:var(--bg-soft);
}
tbody tr:last-child td { border-bottom:none; }
#nys-main .page {
	max-width:940px;
	margin:0 auto;
	padding:44px 28px 90px;
}
