/* 登录后头像卡片。身份：admin / lifetime / year / none。格子用 span，避开主题 i{font-family:ceofont}。 */

.hires-site-header .user-down:has(.hires-user-card) {
  width: 300px !important;
  max-width: calc(100vw - 16px) !important;
  padding: 8px 0 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.hires-user-card {
  --red: #C9002B;
  --red-d: #A00025;
  --gold: #F6B800;
  --bg: #fff;
  --warm: #FFF9F1;
  --ink: #161616;
  --ink2: #64615E;
  --line: #E7E0D8;
  --tier: var(--line);
  --sans: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, "Cascadia Mono", "Segoe UI Mono", Consolas, monospace;
  --ease: cubic-bezier(.2, .8, .2, 1);
  width: 300px;
  max-width: 100%;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 24px 48px -24px rgba(0, 0, 0, .35);
  overflow: hidden;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.5;
  text-align: left;
}
.hires-user-card,
.hires-user-card * { box-sizing: border-box; }
.hires-user-card.is-lifetime { --tier: var(--gold); }
.hires-user-card.is-year { --tier: var(--red); }
.hires-user-card.is-admin { --tier: var(--ink); }
.hires-user-card svg { display: block; flex: none; }
.hires-user-card p,
.hires-user-card ul { margin: 0; padding: 0; }

.hires-user-card .user-head {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 20px 18px 22px;
}
.hires-user-card .avatar {
  width: 48px !important;
  height: 48px !important;
  border-radius: 50%;
  flex: none;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--warm);
  box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--tier);
}
.hires-user-card .avatar img {
  width: 100% !important;
  height: 100% !important;
  max-width: none;
  object-fit: cover;
  border-radius: 50%;
}
.hires-user-card .user-meta { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.hires-user-card .user-name {
  max-width: 100%;
  font-size: 17px;
  line-height: 1.3;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hires-user-card .badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 8px;
  border: 1px solid transparent;
  border-radius: 3px;
  font-size: 12px;
  line-height: 1;
  font-weight: 700;
  font-style: normal;
  white-space: nowrap;
}
.hires-user-card .badge svg { width: 12px; height: 12px; }
.hires-user-card .badge.lifetime { background: var(--gold); color: var(--ink); }
.hires-user-card .badge.year { border-color: var(--red); color: var(--red); background: transparent; }
.hires-user-card .badge.admin { background: var(--ink); color: var(--bg); }
.hires-user-card .badge.normal { border-color: var(--line); color: var(--ink2); font-weight: 500; background: transparent; }

.hires-user-card .panel {
  margin: 0 12px 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--warm);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.hires-user-card .panel p { font-size: 13px; line-height: 1.5; color: var(--ink2); }
.hires-user-card .panel strong { display: block; font-size: 15px; line-height: 1.4; font-weight: 800; color: var(--ink); }
.hires-user-card a.cta {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  border-radius: 4px;
  background: var(--red);
  color: var(--bg) !important;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}
.hires-user-card a.cta:hover { background: var(--red-d); color: var(--bg) !important; }

.hires-user-card .quota-head,
.hires-user-card .quota-body { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hires-user-card .quota-body { align-items: baseline; }
.hires-user-card .quota-title {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hires-user-card .quota-title svg { width: 16px; height: 16px; color: var(--red); }
.hires-user-card .quota-tag {
  flex: none;
  height: 22px;
  display: inline-flex;
  align-items: center;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: var(--bg);
  color: var(--ink2);
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.hires-user-card .panel.lifetime .quota-tag { border-color: var(--gold); background: var(--gold); color: var(--ink); font-weight: 700; }
.hires-user-card .quota-num { display: flex; align-items: baseline; gap: 6px; font-size: 13px; color: var(--ink2); white-space: nowrap; }
.hires-user-card .quota-num b { font: 700 34px/1 var(--mono); letter-spacing: -.02em; color: var(--ink); }
.hires-user-card .quota-label { font-size: 13px; color: var(--ink2); white-space: nowrap; }
.hires-user-card .quota-bar { display: flex; gap: 2px; height: 16px; }
.hires-user-card .quota-bar span {
  flex: 1;
  width: auto !important;
  height: 16px !important;
  border-radius: 1px;
  background: rgba(22, 22, 22, .12);
}
.hires-user-card .quota-bar span.on { background: var(--red); }
.hires-user-card .quota-note { font-size: 12px; }

.hires-user-card .upgrade-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
  border-top: 1px dashed rgba(22, 22, 22, .25);
}
.hires-user-card .upgrade-row p { font-size: 12px; }
.hires-user-card .upgrade-row a {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 32px;
  padding: 0 6px 0 10px;
  border: 1px solid var(--red);
  border-radius: 4px;
  background: transparent;
  color: var(--red) !important;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.hires-user-card .upgrade-row a svg { width: 14px; height: 14px; }
.hires-user-card .upgrade-row a:hover { background: var(--red); color: var(--bg) !important; }

.hires-user-card .perks {
  list-style: none;
  display: flex;
  padding-top: 12px;
  border-top: 1px dashed rgba(22, 22, 22, .25);
}
.hires-user-card .perks li {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 1.3;
  white-space: nowrap;
  color: var(--ink);
}
.hires-user-card .perks li + li { border-left: 1px solid var(--line); }
.hires-user-card .perks svg { width: 18px; height: 18px; color: var(--ink); }

.hires-user-card .menu { list-style: none; border-top: 1px solid var(--line); padding: 6px; }
.hires-user-card .menu a {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 44px;
  padding: 0 12px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink) !important;
  text-decoration: none;
}
.hires-user-card .menu a:hover { background: var(--warm); }
.hires-user-card .menu svg { width: 18px; height: 18px; color: var(--ink2); }
.hires-user-card .menu a svg + svg { margin-left: auto; width: 14px; height: 14px; }
.hires-user-card .menu a:hover svg { color: var(--ink); }
.hires-user-card .menu .divider { height: 1px; background: var(--line); margin: 6px; }
.hires-user-card .menu .logout,
.hires-user-card .menu .logout svg,
.hires-user-card .menu .logout:hover,
.hires-user-card .menu .logout:hover svg { color: var(--red) !important; }
