.ry-ar {
  --ry-ink: #1d2633;
  --ry-body: #3d4756;
  --ry-muted: #6b7584;
  --ry-faint: #98a1ae;
  --ry-line: #e3e6ea;
  --ry-line-soft: #eef0f3;
  --ry-canvas: #f4f5f7;
  --ry-brand: #0e8f63;
  --ry-brand-tint: #e9f4ef;
  --ry-amber: #a35a0b;
  --ry-red: #b42318;
  --ry-id-prospect: #b7c1cb;
  --ry-id-communicating: #6aa58a;
  --ry-id-managed: #0e8f63;
  --ry-id-expired: #c58a3e;

  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 100%;
  padding: 20px 24px 24px;
  font-size: 13px;
  color: var(--ry-body);
  background: var(--ry-canvas);
}

.ry-ar .tabular-nums {
  font-variant-numeric: tabular-nums;
}

.ry-ar-ico {
  margin-right: 6px;
  font-size: 15px;
  vertical-align: -3px;
}

.ry-ar-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
}

.ry-ar-head__title {
  display: flex;
  gap: 12px;
  align-items: baseline;
}

.ry-ar-head__title h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
  line-height: 28px;
  color: var(--ry-ink);
}

.ry-ar-head__count {
  font-size: 13px;
  color: var(--ry-muted);
}

.ry-ar-head__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ry-ar .ant-btn {
  border-radius: 6px;
  box-shadow: none;
}

.ry-ar .ant-btn-default {
  color: var(--ry-body);
  border-color: var(--ry-line);
}

.ry-ar .ant-btn-default:not(:disabled):hover {
  color: var(--ry-brand);
  border-color: var(--ry-brand);
}

.ry-ar .ant-btn-primary:not(:disabled) {
  background: var(--ry-brand);
}

.ry-ar .ant-btn-primary:not(:disabled):hover {
  background: #0b7a54;
}

.ry-ar-card {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--ry-line);
  border-radius: 8px;
}

.ry-ar-census {
  padding: 0 20px;
  border-bottom: 1px solid var(--ry-line-soft);
}

.ry-ar-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 28px;
}

.ry-ar-tab {
  position: relative;
  display: inline-flex;
  gap: 6px;
  align-items: center;
  padding: 14px 0 12px;
  font-size: 13.5px;
  color: var(--ry-muted);
  cursor: pointer;
  background: none;
  border: 0;
}

.ry-ar-tab:hover {
  color: var(--ry-ink);
}

.ry-ar-tab:focus-visible {
  outline: 2px solid var(--ry-brand);
  outline-offset: 2px;
  border-radius: 4px;
}

.ry-ar-tab.is-active {
  font-weight: 600;
  color: var(--ry-ink);
}

.ry-ar-tab.is-active::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  content: '';
  background: var(--ry-ink);
}

.ry-ar-tab__num {
  font-weight: 400;
  color: var(--ry-faint);
}

.ry-ar-tab.is-active .ry-ar-tab__num {
  color: var(--ry-muted);
}

.ry-ar-dot {
  display: inline-block;
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--ry-id-prospect);
  border-radius: 2px;
}

.ry-ar-dot.is-communicating,
.ry-ar-census__seg.is-communicating {
  background: var(--ry-id-communicating);
}

.ry-ar-dot.is-managed,
.ry-ar-census__seg.is-managed {
  background: var(--ry-id-managed);
}

.ry-ar-dot.is-expired,
.ry-ar-census__seg.is-expired {
  background: var(--ry-id-expired);
}

.ry-ar-census__bar {
  display: flex;
  gap: 2px;
  height: 4px;
  margin: 0 0 14px;
}

.ry-ar-census__seg {
  flex-basis: 0;
  cursor: pointer;
  min-width: 4px;
  background: var(--ry-id-prospect);
  border-radius: 1px;
  transition: opacity 0.2s;
}

.ry-ar-census__bar.has-focus .ry-ar-census__seg:not(.is-on) {
  opacity: 0.28;
}

.ry-ar-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  padding: 14px 20px;
}

.ry-ar-toolbar--more {
  padding-top: 0;
}

.ry-ar-search.ant-input-affix-wrapper {
  width: 260px;
}

.ry-ar-search__ico {
  color: var(--ry-faint);
}

.ry-ar-range.ant-picker {
  width: 240px;
}

.ry-ar-select.ant-select {
  width: 120px;
}

.ry-ar .ant-input-affix-wrapper,
.ry-ar .ant-picker,
.ry-ar .ant-select:not(.ant-select-customize-input) .ant-select-selector {
  border-color: var(--ry-line);
  border-radius: 6px;
}

.ry-ar-more__n {
  margin-left: 6px;
  font-weight: 600;
  color: var(--ry-brand);
}

.ry-ar-more.is-open {
  color: var(--ry-ink);
  background: var(--ry-line-soft);
}

.ry-ar-clear.ant-btn {
  padding: 0 4px;
  color: var(--ry-muted);
}

.ry-ar-clear.ant-btn:hover {
  color: var(--ry-ink);
}

.ry-ar-field {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  color: var(--ry-muted);
  white-space: nowrap;
}

.ry-ar-field .ant-select {
  width: 140px;
}

.ry-ar-note {
  display: flex;
  gap: 6px;
  align-items: center;
  padding: 8px 20px;
  margin: 0;
  color: var(--ry-body);
  background: #fbf7f1;
  border-top: 1px solid var(--ry-line-soft);
}

.ry-ar-note__ico {
  color: var(--ry-amber);
}

.ry-ar-note button {
  padding: 0;
  margin-left: 4px;
  font-weight: 500;
  color: var(--ry-brand);
  cursor: pointer;
  background: none;
  border: 0;
}

.ry-ar-note button:hover {
  text-decoration: underline;
}

.ry-ar-table .ant-table {
  font-size: 13px;
  color: var(--ry-body);
}

.ry-ar-table .ant-table-thead > tr > th {
  padding-block: 10px;
  font-size: 12px;
  font-weight: 500;
  color: var(--ry-muted);
  background: #fafbfc;
  border-top: 1px solid var(--ry-line-soft);
  border-bottom-color: var(--ry-line-soft);
}

.ry-ar-table .ant-table-thead > tr > th::before {
  display: none;
}

.ry-ar-table .ant-table-tbody > tr > td {
  vertical-align: top;
  border-bottom-color: var(--ry-line-soft);
}

.ry-ar-table .ant-table-tbody > tr:hover > td {
  background: #f8faf9;
}

.ry-ar-table .ant-table-pagination.ant-pagination {
  padding: 0 20px;
  margin: 14px 0;
}

.ry-ar-cust {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  min-width: 0;
}

.ry-ar-cust__avatar {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ry-body);
  background: var(--ry-line-soft);
  border-radius: 6px;
}

.ry-ar-cust__body {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.ry-ar-cust__name {
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
  line-height: 20px;
  color: var(--ry-ink);
  white-space: nowrap;
  cursor: pointer;
}

.ry-ar-cust__name:hover {
  color: var(--ry-brand);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.ry-ar-cust__remark {
  font-weight: 400;
  color: var(--ry-muted);
}

.ry-ar-cust__meta {
  margin-top: 2px;
  font-size: 12px;
  color: var(--ry-faint);
  white-space: nowrap;
}

.ry-ar-ident {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  line-height: 20px;
  color: var(--ry-ink);
}

.ry-ar-text {
  display: block;
  line-height: 20px;
  color: var(--ry-ink);
}

.ry-ar-none {
  display: block;
  line-height: 20px;
  color: var(--ry-faint);
}

.ry-ar-sub {
  display: block;
  max-width: 100%;
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12px;
  color: var(--ry-faint);
  white-space: nowrap;
}

.ry-ar-sub--join > span + span::before {
  margin: 0 6px;
  color: var(--ry-line);
  content: '|';
}

.ry-ar .is-amber {
  color: var(--ry-amber);
}

.ry-ar .is-red,
.ry-ar .is-risk-critical {
  color: var(--ry-red);
}

.ry-ar .is-risk-high {
  font-weight: 500;
  color: var(--ry-amber);
}

.ry-ar .is-slate {
  color: var(--ry-faint);
}

.ry-ar-sub .is-green {
  color: var(--ry-muted);
}

.ry-ar-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.ry-ar-chip {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  max-width: 120px;
  height: 20px;
  padding: 0 6px;
  overflow: hidden;
  font-size: 12px;
  color: var(--ry-body);
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #f5f6f8;
  border: 1px solid var(--ry-line-soft);
  border-radius: 4px;
}

.ry-ar-chip__dot {
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.ry-ar-chip--more {
  color: var(--ry-muted);
  cursor: default;
}

.ry-ar-actions {
  display: flex;
  gap: 0;
  align-items: center;
  justify-content: flex-end;
}

.ry-ar-actions .ant-btn-link {
  height: 24px;
  padding: 0 6px;
  color: var(--ry-brand);
}

.ry-ar-actions__more.ant-btn {
  width: 24px;
  height: 24px;
  padding: 0;
  color: var(--ry-muted);
}

.ry-ar-empty-state {
  padding: 36px 0;
  color: var(--ry-muted);
}

.ry-ar-empty-state p {
  margin: 0 0 12px;
}

@media (max-width: 768px) {
  .ry-ar {
    padding: 16px;
  }

  .ry-ar-search.ant-input-affix-wrapper,
  .ry-ar-range.ant-picker {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ry-ar-census__seg {
    transition: none;
  }
}

.hc-archive-qr {
  padding: 0 4px 4px;
}

.hc-archive-qr__lead {
  margin: 0 0 18px;
  font-size: 13px;
  line-height: 1.65;
  color: rgb(15 23 42 / 72%);
}

.hc-archive-qr__lead strong {
  font-weight: 600;
  color: #0f172a;
}

.hc-archive-qr__attr {
  display: inline-block;
  margin-top: 6px;
  font-size: 12px;
  color: #64748b;
}

.hc-archive-qr__attr-sep {
  padding: 0 6px;
  color: #cbd5e1;
}

.hc-archive-qr__picker {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.hc-archive-qr__picker-label {
  font-size: 13px;
  color: #64748b;
}

.hc-archive-qr__invite {
  padding: 10px 12px;
  margin-bottom: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.hc-archive-qr__invite-head {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

.hc-archive-qr__invite-label {
  font-size: 13px;
  color: #64748b;
}

.hc-archive-qr__invite-code {
  flex: 1;
  min-width: 96px;
  margin-left: 4px;
  font-family: ui-monospace, sfmono-regular, menlo, monospace;
  font-size: 16px;
  font-weight: 600;
  color: #0f172a;
  letter-spacing: 1.5px;
}

.hc-archive-qr__invite-tip {
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.6;
  color: #64748b;
}

.hc-archive-qr__invite-tip code {
  padding: 0 4px;
  font-size: 11.5px;
  color: #0f172a;
  background: #e2e8f0;
  border-radius: 4px;
}

.hc-archive-qr__switch {
  display: block;
  margin-bottom: 12px;
  text-align: center;
}

/* 与二维码衬板同宽：256 + plate padding 14×2 = 284px */
.hc-archive-qr__stack {
  width: fit-content;
  max-width: 100%;
  margin-right: auto;
  margin-left: auto;
}

.hc-archive-qr__frame {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 12px 0 4px;
}

.hc-archive-qr__caption {
  box-sizing: border-box;
  width: 100%;
  padding: 0 2px;
  margin-top: 10px;
  font-size: 13px;
  line-height: 1.5;
  color: rgb(15 23 42 / 72%);
  text-align: center;
}

.hc-archive-qr__caption-name {
  font-weight: 600;
  color: #0f172a;
}

.hc-archive-qr__caption-sep {
  margin: 0 0.35em;
  font-weight: 400;
  color: rgb(15 23 42 / 28%);
}

.hc-archive-qr__caption-time {
  font-weight: 500;
  color: rgb(15 23 42 / 58%);
}

.hc-archive-qr__glow {
  position: absolute;
  inset: 0 auto auto 50%;
  width: 280px;
  height: 280px;
  pointer-events: none;
  background: radial-gradient(
    circle at 50% 40%,
    rgb(59 130 246 / 22%) 0%,
    rgb(99 102 241 / 8%) 42%,
    transparent 70%
  );
  border-radius: 28px;
  transform: translateX(-50%);
}

.hc-archive-qr__plate {
  position: relative;
  z-index: 1;
  padding: 14px;
  background: linear-gradient(145deg, #fff 0%, #f8fafc 100%);
  border-radius: 20px;
  box-shadow:
    0 0 0 1px rgb(15 23 42 / 6%),
    0 12px 40px -16px rgb(15 23 42 / 25%);
}

.hc-archive-qr__img {
  display: block;
  width: 256px;
  height: 256px;
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px rgb(15 23 42 / 4%);
}

.hc-archive-qr__actions {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 28px;
  margin-bottom: 22px;
}

/* Modal 挂载在 body，用 wrap-class-name 微调圆角与顶栏层次 */
.hc-archive-qr-modal-wrap .ant-modal-content {
  overflow: hidden;
  border-radius: 16px;
}

.hc-archive-qr-modal-wrap .ant-modal-header {
  padding-top: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgb(15 23 42 / 6%);
}
