:root {
  color-scheme: light;
  --ink: var(--puze-color-ink);
  --muted: var(--puze-color-muted);
  --line: var(--puze-color-line);
  --paper: var(--puze-color-paper);
  --panel: var(--puze-color-panel);
  --brand-primary: var(--puze-color-primary);
  --brand-accent: var(--puze-color-accent);
  --brand-gold: var(--puze-color-gold);
  --teal: var(--puze-color-accent);
  --blue: var(--puze-color-primary);
  --brand-pink: var(--puze-color-primary);
  --brand-orange: var(--puze-color-accent);
  --brand-soft: var(--puze-color-soft-blue);
  --sidebar: var(--puze-color-sidebar);
  --sidebar-2: var(--puze-color-sidebar-strong);
  --sidebar-line: #d7e1ee;
  --amber: var(--puze-color-gold);
  --rose: #a44455;
  --shadow: var(--puze-shadow-panel);
  --soft-shadow: var(--puze-shadow-soft);
  --login-card-height: 420px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(31, 65, 143, 0.09), transparent 32%),
    linear-gradient(300deg, rgba(22, 158, 156, 0.12), transparent 36%),
    var(--paper);
  color: var(--ink);
  font-family: var(--puze-font-base);
}

button,
input,
select,
textarea {
  font: inherit;
}

.shell {
  width: 100%;
  min-height: 100vh;
  margin: 0;
  padding: 0;
}

.login-panel {
  display: grid;
  width: min(1240px, calc(100% - 64px));
  min-height: 100vh;
  margin: 0 auto;
  align-items: center;
}

.login-frame {
  width: 100%;
  display: grid;
  grid-template-columns: var(--puze-login-frame-columns);
  align-items: stretch;
  gap: var(--puze-login-frame-gap);
  border: 1px solid rgba(219, 227, 239, 0.95);
  border-radius: var(--puze-radius-panel);
  background: #fff;
  padding: var(--puze-login-frame-padding);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transition: background 0.45s ease, box-shadow 0.45s ease;
}

.login-frame::before {
  content: none;
}

.brand {
  min-height: var(--puze-login-brand-min-height);
  border-radius: var(--puze-radius-panel);
  background:
    radial-gradient(circle at 74% 82%, rgba(31, 65, 143, 0.26), transparent 34%),
    radial-gradient(circle at 18% 28%, rgba(74, 115, 181, 0.18), transparent 30%),
    var(--puze-login-brand-bg);
  color: #fff;
  padding: 0;
  display: grid;
  position: relative;
  overflow: hidden;
  transition: background 0.45s ease, box-shadow 0.45s ease;
}

.brand::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: var(--puze-login-brand-band-height);
  background: var(--puze-login-band-bg);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.05), 0 1px 0 rgba(0, 0, 0, 0.62);
  z-index: 0;
  transition: background 0.45s ease, box-shadow 0.45s ease;
}

.brand::after {
  content: "";
  position: absolute;
  width: 390px;
  height: 186px;
  right: 42px;
  top: 168px;
  background: linear-gradient(135deg, rgba(74, 235, 226, 0.82) 0%, rgba(58, 219, 213, 0.68) 34%, rgba(186, 168, 96, 0.58) 58%, rgba(118, 177, 255, 0.72) 100%);
  opacity: 0.56;
  transform: none;
  -webkit-mask: var(--puze-logo-auxiliary) center / contain no-repeat;
  mask: var(--puze-logo-auxiliary) center / contain no-repeat;
  z-index: 0;
  pointer-events: none;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.brand:hover {
  background:
    radial-gradient(circle at 78% 78%, rgba(31, 65, 143, 0.42), transparent 36%),
    radial-gradient(circle at 18% 26%, rgba(82, 129, 201, 0.30), transparent 32%),
    linear-gradient(145deg, #0b1424 0%, #14233c 52%, #091426 100%);
  box-shadow: inset 0 0 80px rgba(72, 128, 220, 0.12);
}

.brand:hover::before {
  background: linear-gradient(90deg, #2f43a0 0%, #386fb5 43%, #5599ad 70%, #64b894 100%);
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.06), 0 1px 0 rgba(0, 0, 0, 0.62);
}

.brand:hover::after {
  opacity: 0.66;
  transform: translateY(-4px);
}

.brand-inner {
  position: relative;
  z-index: 2;
  min-height: 500px;
  display: grid;
  grid-template-rows: 156px 1fr;
}

.brand p,
.brand span {
  color: rgba(255, 255, 255, 0.76);
}

.brand-mark {
  display: flex;
  align-items: center;
  height: 156px;
  padding: 0 28px;
  transform: translateY(-8px);
}

.sidebar-logo {
  background: #fff;
  color: var(--brand-primary);
  border: 1px solid rgba(255, 255, 255, 0.48);
  box-shadow: 0 12px 28px rgba(31, 65, 143, 0.22);
}

.brand-symbol {
  width: var(--puze-login-wordmark-width);
  height: var(--puze-login-wordmark-height);
  display: grid;
  place-items: center;
  padding: var(--puze-login-wordmark-padding);
  background: #fff;
  border-radius: var(--puze-radius-panel);
  border: 0;
  box-shadow: var(--puze-shadow-brand-logo);
}

.brand-symbol img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.sidebar-logo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-word {
  display: grid;
  gap: 0;
  color: #fff;
  font-weight: 950;
  letter-spacing: 0.01em;
}

.brand-word small {
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
  font-weight: 800;
}

.brand-content {
  align-self: center;
  padding: 4px 28px 34px;
}

.brand-eyebrow {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 850;
}

.brand h1 {
  margin: 0;
  max-width: 620px;
  display: grid;
  gap: 4px;
  line-height: 1.04;
  letter-spacing: 0;
}

.brand .brand-title-en,
.brand .brand-title-cn {
  color: #fff;
}

.brand-title-en {
  font-family: var(--puze-font-display);
  font-size: 22px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}

.brand-title-cn {
  font-size: 44px;
  font-weight: 950;
  color: #fff;
}

.brand-subtitle {
  display: block;
  margin-top: 16px;
  font-size: 16px;
}

.login-dashboard-preview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.login-dashboard-preview div {
  min-height: 76px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  padding: 14px;
  display: grid;
  align-content: space-between;
}

.login-dashboard-preview span {
  color: #9fe0d6;
  font-size: 13px;
  font-weight: 800;
}

.login-dashboard-preview strong {
  color: #fff;
  font-size: 18px;
  line-height: 1.25;
}

.login-box,
.list,
.detail,
.summary-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.login-box {
  min-height: 500px;
  display: grid;
  gap: 18px;
  align-content: center;
  padding: 30px;
  position: relative;
  z-index: 1;
}

.login-title span {
  display: inline-flex;
  margin-bottom: 12px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-pink);
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 850;
}

.login-title h2 {
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 34px;
  font-weight: 950;
  line-height: 1.15;
}

.login-sso-card {
  border: 1px solid #dedee8;
  border-radius: 8px;
  background: #f7f7fb;
  padding: 12px;
  overflow-wrap: anywhere;
}

.login-sso-card span,
.login-sso-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.login-sso-card strong {
  display: block;
  margin: 4px 0;
  color: #0f766e;
  font-size: 17px;
}

.login-boundary {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 10px 12px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.login-boundary span {
  color: var(--muted);
  font-size: 13px;
}

.login-boundary strong {
  color: var(--ink);
  font-size: 14px;
}

h1,
h2,
p {
  margin-top: 0;
}

.login-box h2,
.list h2,
.detail h2 {
  margin-bottom: 8px;
  font-size: 22px;
}

label {
  display: grid;
  gap: 8px;
  color: #344154;
  font-size: 14px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 42px;
  border: 1px solid #cfd7e2;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 9px 11px;
  outline: none;
}

textarea {
  min-height: 96px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--brand-pink);
  box-shadow: 0 0 0 3px rgba(31, 65, 143, 0.14);
}

button {
  min-height: 42px;
  border: 1px solid var(--brand-pink);
  border-radius: 999px;
  background: var(--brand-pink);
  color: #fff;
  padding: 8px 18px;
  cursor: pointer;
  font-weight: 850;
}

button.secondary {
  border-color: var(--line);
  background: #fff;
  color: var(--ink);
}

button.danger {
  border-color: var(--rose);
  background: var(--rose);
}

button svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-button {
  width: 44px;
  min-width: 44px;
  padding: 8px;
  display: inline-grid;
  place-items: center;
}

.message,
.muted {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.admin-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 0;
  align-items: start;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  min-height: 100vh;
  border: 0;
  border-radius: 0;
  background: var(--sidebar);
  color: var(--ink);
  padding: 22px 18px;
  box-shadow: 12px 0 34px rgba(31, 65, 143, 0.09);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.sidebar-brand {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 4px 4px 18px;
  border-bottom: 1px solid var(--sidebar-line);
}

.sidebar-brand p {
  margin: 0 0 2px;
  color: var(--brand-pink);
  font-size: 12px;
  font-weight: 800;
}

.sidebar-logo {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  padding: 5px;
}

.sidebar-brand strong {
  display: block;
  font-size: 20px;
  letter-spacing: 0;
  color: var(--ink);
}

.sidebar-brand span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.side-nav {
  display: grid;
  gap: 8px;
}

.nav-section-title {
  margin: 8px 10px 2px;
  color: #777985;
  font-size: 12px;
  font-weight: 850;
}

.nav-item {
  position: relative;
  min-height: 48px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #676876;
  text-decoration: none;
  display: grid;
  grid-template-columns: 38px 1fr;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  font-weight: 750;
  background: transparent;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.nav-item::before {
  content: none;
}

.nav-item.active {
  border-color: #cbd8ee;
  background: #dfe8f6;
  color: var(--brand-primary);
}

.nav-item.active::before {
  background: transparent;
}

.nav-item.disabled {
  color: #a4a4ad;
}

.nav-code {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 28px;
  border-radius: 8px;
  background: #fff;
  color: #666874;
  font-size: 12px;
  font-weight: 850;
}

.nav-item.active .nav-code {
  background: var(--brand-primary);
  color: #fff;
}

.nav-submenu {
  display: grid;
  gap: 6px;
  margin: -2px 0 4px 44px;
  padding-left: 12px;
  border-left: 1px solid var(--sidebar-line);
}

.nav-subitem {
  min-height: 38px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #747583;
  text-decoration: none;
  display: grid;
  grid-template-columns: 28px 1fr;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  font-size: 13px;
  font-weight: 750;
  background: transparent;
}

.nav-subitem:hover,
.nav-subitem.active {
  border-color: var(--sidebar-line);
  background: #fff;
  color: var(--ink);
}

.nav-dot {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 22px;
  border-radius: 7px;
  background: #fff;
  color: #777985;
  font-size: 12px;
  font-weight: 850;
}

.nav-subitem.active .nav-dot {
  background: var(--brand-soft);
  color: var(--brand-pink);
}

.sidebar-status {
  margin-top: auto;
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  gap: 3px 10px;
  align-items: center;
  border: 1px solid #dedcea;
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.sidebar-status span {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--brand-accent);
  box-shadow: 0 0 0 5px rgba(22, 158, 156, 0.14);
}

.sidebar-status strong {
  font-size: 13px;
}

.sidebar-status small {
  grid-column: 2;
  color: var(--muted);
  font-size: 12px;
}

.sidebar-logout {
  width: 100%;
  margin-top: 0;
  border-color: var(--sidebar-line);
  background: #fff;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.main-panel {
  min-width: 0;
  min-height: 100vh;
  padding: 0 24px 32px;
  position: relative;
  overflow: hidden;
}

.main-panel > * {
  position: relative;
  z-index: 1;
}

.topbar {
  display: flex;
  min-height: 54px;
  align-items: stretch;
  justify-content: space-between;
  gap: 12px;
  margin: 0 -24px 18px;
  padding: 0 18px 0 24px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.page-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  min-height: 54px;
  margin-bottom: 14px;
}

.page-heading p {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 12px;
}

.page-heading h1 {
  margin: 0;
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.user-card {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px;
  padding: 6px 10px;
}

.user-card img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  background: #edf2f7;
}

.user-card strong,
.user-card span {
  display: block;
  white-space: nowrap;
}

.user-card strong {
  font-size: 14px;
}

.user-card span {
  color: var(--muted);
  font-size: 12px;
}

.summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.summary-card {
  padding: 16px 18px;
  box-shadow: var(--soft-shadow);
}

.summary-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: 26px;
}

.summary-card span {
  color: var(--muted);
  font-size: 13px;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(380px, 0.95fr) minmax(0, 1.05fr);
  gap: 16px;
  align-items: start;
}

.attendance-view {
  display: grid;
  gap: 16px;
}

.tool-frame-view {
  display: grid;
  gap: 16px;
}

.module-banner,
.module-card,
.module-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--soft-shadow);
}

.module-banner {
  padding: 22px;
}

.module-banner span,
.module-code {
  display: inline-flex;
  width: fit-content;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-pink);
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 800;
}

.module-banner h2 {
  margin: 14px 0 8px;
  font-size: 28px;
}

.module-banner p,
.module-card p,
.module-panel p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.65;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.module-card {
  display: grid;
  gap: 10px;
  min-height: 190px;
  padding: 18px;
}

.module-card h3,
.module-panel h3 {
  margin: 0;
  font-size: 20px;
}

.module-card strong {
  align-self: end;
  color: var(--ink);
}

.module-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
  gap: 18px;
  padding: 20px;
}

.module-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 10px;
}

.module-link {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 13px;
  text-decoration: none;
  font-weight: 800;
}

.module-link.primary {
  border-color: var(--brand-pink);
  background: var(--brand-pink);
  color: #fff;
}

.module-link:hover {
  border-color: var(--brand-pink);
}

.module-state {
  border-left: 1px solid var(--line);
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  padding-left: 18px;
}

.module-state span {
  color: var(--muted);
}

.module-state strong {
  color: var(--ink);
}

.tool-frame {
  width: 100%;
  min-height: calc(100vh - 220px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.list,
.detail {
  padding: 18px;
}

.list-head {
  display: grid;
  grid-template-columns: 1fr minmax(180px, 240px);
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.candidate-entry-card {
  display: grid;
  gap: 12px;
  margin-bottom: 18px;
  border: 1px solid #cfdcf0;
  border-radius: 8px;
  background: linear-gradient(180deg, #f7fbff, #ffffff);
  padding: 16px;
}

.candidate-entry-card span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.candidate-entry-card h2 {
  margin: 0;
  color: var(--ink);
  font-size: 26px;
  line-height: 1.2;
}

.candidate-entry-card p {
  margin: 4px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.candidate-link-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.disc-test-link {
  display: inline-flex;
  width: fit-content;
  min-height: 34px;
  border: 1px solid var(--brand-pink);
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-pink);
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}

.disc-test-link.copy-link {
  cursor: pointer;
}

.candidate-link-message {
  min-height: 20px;
  margin: 6px 0 0;
}

.disc-test-link:hover {
  background: #edf4ff;
}

.table {
  display: grid;
  gap: 8px;
  max-height: 68vh;
  overflow: auto;
}

.row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  padding: 14px;
  cursor: pointer;
}

.row.active {
  border-color: rgba(31, 65, 143, 0.32);
  background: #edf4ff;
}

.row h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
}

.row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.row-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.row-main strong {
  color: var(--ink);
  font-size: 16px;
  white-space: nowrap;
}

.row-position {
  margin-bottom: 9px !important;
}

.row-result {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0;
}

.row-result span {
  min-height: 34px;
  border: 1px solid #d7e2ee;
  border-radius: 8px;
  background: #f8fbfd;
  color: #344154;
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  font-size: 17px;
  font-weight: 800;
}

.row-result .row-primary {
  border-color: rgba(31, 65, 143, 0.22);
  background: var(--brand-soft);
  color: var(--brand-pink);
}

.row-score b {
  font-size: 20px;
  font-weight: 950;
}

.row-score.d b,
.disc-letter.d,
.primary-score-line .d,
.score-card.d strong span { color: #e11d48; }

.row-score.i b,
.disc-letter.i,
.primary-score-line .i,
.score-card.i strong span { color: #f97316; }

.row-score.s b,
.disc-letter.s,
.primary-score-line .s,
.score-card.s strong span { color: #16a34a; }

.row-score.c b,
.disc-letter.c,
.primary-score-line .c,
.score-card.c strong span { color: #2563eb; }

.row-score.e b,
.primary-score-line .e,
.score-card.e strong span { color: #1f418f; }

.row-score.n b,
.primary-score-line .n,
.score-card.n strong span { color: #7c3aed; }

.row-score.t b,
.primary-score-line .t,
.score-card.t strong span { color: #0f766e; }

.row-score.f b,
.primary-score-line .f,
.score-card.f strong span { color: #db2777; }

.row-score.j b,
.primary-score-line .j,
.score-card.j strong span { color: #887850; }

.row-score.p b,
.primary-score-line .p,
.score-card.p strong span { color: #0891b2; }

.badge {
  border-radius: 999px;
  padding: 4px 9px;
  background: #eef2f6;
  color: #516072;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.badge.warn {
  background: #fff0d4;
  color: var(--amber);
}

.badge.ok {
  background: #eaf7f1;
  color: #26805e;
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.score-card {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}

.score-card strong {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1;
  margin-bottom: 10px;
}

.score-card strong span {
  min-width: 34px;
  font-size: 1.1em;
  font-weight: 950;
}

.score-card strong small {
  color: #6b778c;
  font-size: 0.45em;
  font-weight: 850;
}

.score-card em {
  color: #344154;
  font-style: normal;
  font-size: 18px;
  font-weight: 850;
}

.score-card.d {
  border-color: #fecaca;
  background: #fff7f7;
}

.score-card.i {
  border-color: #fed7aa;
  background: #fff9ed;
}

.score-card.s {
  border-color: #bbf7d0;
  background: #f0fdf4;
}

.score-card.c {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.score-card.e,
.score-card.n,
.score-card.t,
.score-card.f,
.score-card.j,
.score-card.p {
  border-color: #d7e2ee;
  background: #f8fbfd;
}

.detail-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
}

.detail-head span:first-child,
.primary-result span,
.section-title span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.detail-head h2 {
  margin: 4px 0 5px;
  font-size: 28px;
}

.detail-head p {
  margin: 0;
  color: var(--muted);
}

.primary-result {
  border: 1px solid rgba(31, 65, 143, 0.22);
  border-radius: 8px;
  background: var(--brand-soft);
  padding: 16px;
  margin-bottom: 14px;
}

.primary-result strong {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 5px 0;
  color: var(--teal);
  font-size: clamp(34px, 4.6vw, 62px);
  line-height: 1.15;
}

.primary-result strong em {
  font-style: normal;
  font-size: 1.25em;
  font-weight: 950;
}

.primary-result.mbti-result strong {
  display: block;
  color: var(--brand-blue);
  letter-spacing: 0;
}

.primary-score-line {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-top: 10px;
}

.primary-score-line span {
  color: #344154;
  font-size: clamp(20px, 2.2vw, 30px);
  font-weight: 850;
}

.primary-score-line b {
  font-weight: 950;
}

.review-callout {
  border: 1px solid #fbbf24;
  border-radius: 8px;
  background: #fffbeb;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  margin: 0 0 14px;
}

.review-callout strong {
  display: block;
  color: #92400e;
  font-size: 18px;
  margin-bottom: 4px;
}

.review-callout p {
  margin: 0;
  color: #6b7280;
  line-height: 1.5;
}

.review-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.review-actions button {
  min-height: 38px;
  border: 1px solid #f59e0b;
  border-radius: 8px;
  background: #fff;
  color: #92400e;
  padding: 8px 12px;
  font-weight: 850;
}

.review-actions button:first-child {
  border-color: var(--teal);
  background: var(--teal);
  color: #fff;
}

.meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0;
}

.meta div {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 11px;
  background: #fbfcfe;
}

.meta span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.behavior-panel,
.copy-panel,
.manage-panel {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fbfcfe;
  padding: 14px;
  margin: 14px 0;
}

.behavior-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.behavior-grid div {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.behavior-grid span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 12px;
}

.behavior-grid strong {
  color: var(--ink);
  font-size: 18px;
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.section-title h3 {
  margin: 0;
}

.copy-panel textarea {
  min-height: 210px;
  font-family: var(--puze-font-mono);
  font-size: 13px;
  line-height: 1.6;
}

@media (max-width: 900px) {
  .login-frame,
  .admin-layout,
  .workspace,
  .tool-frame-view,
  .module-grid,
  .module-panel,
  .summary,
  .list-head,
  .meta,
  .behavior-grid,
  .score-grid {
    grid-template-columns: 1fr;
  }

  .login-panel {
    width: calc(100% - 32px);
    max-width: 560px;
    padding: 18px 0;
  }

  .login-frame {
    padding: 10px;
  }

  .brand {
    min-height: auto;
  }

  .brand-inner {
    min-height: 282px;
    grid-template-rows: 118px 1fr;
  }

  .brand::before {
    height: 122px;
  }

  .brand::after {
    width: 218px;
    height: 104px;
    right: 20px;
    top: 132px;
    opacity: 0.46;
  }

  .brand-mark {
    height: 118px;
    padding: 0 22px;
    transform: translateY(-6px);
  }

  .brand-symbol {
    width: min(238px, calc(100vw - 96px));
    height: 67px;
    padding: 10px 13px;
  }

  .brand-content {
    padding: 8px 22px 24px;
  }

  .brand-title-en {
    font-size: 17px;
  }

  .brand-title-cn {
    font-size: 34px;
  }

  .brand-eyebrow {
    font-size: 15px;
    margin-bottom: 10px;
  }

  .login-box {
    min-height: auto;
  }

  .login-box {
    padding: 24px;
  }

  .login-title h2 {
    font-size: 30px;
  }

  .login-boundary {
    grid-template-columns: 64px 1fr;
  }

  .module-state {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 16px 0 0;
  }

  .shell {
    width: 100%;
    padding: 0;
  }

  .login-dashboard-preview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: 0;
  }

  .login-dashboard-preview div {
    min-height: 70px;
    padding: 10px;
  }

  .login-dashboard-preview span {
    font-size: 11px;
  }

  .login-dashboard-preview strong {
    font-size: 15px;
  }

  .sidebar {
    position: static;
    min-height: auto;
    border-radius: 0;
  }

  .side-nav {
    grid-template-columns: 1fr;
  }

  .topbar {
    display: grid;
  }

  .tool-frame {
    min-height: 720px;
  }
}

/* PLP-HR workspace: compact typography and stable content rhythm. */
.dashboard {
  background: #fff;
  font-size: 12px;
}

.dashboard h1,
.dashboard h2,
.dashboard h3,
.dashboard h4,
.dashboard strong,
.dashboard button,
.dashboard input,
.dashboard select,
.dashboard textarea,
.dashboard a {
  font-weight: 650;
}

.dashboard h1,
.dashboard h2,
.dashboard h3,
.dashboard h4,
.dashboard .nav-item,
.dashboard .nav-subitem,
.dashboard button,
.dashboard input,
.dashboard select {
  font-size: 14px;
}

.sidebar {
  width: 280px;
  padding: 18px 14px;
  gap: 12px;
  box-shadow: none;
}

.sidebar-brand {
  grid-template-columns: 40px minmax(0, 1fr);
  padding: 2px 4px 14px;
}

.sidebar-logo {
  width: 40px;
  height: 40px;
}

.sidebar-brand strong {
  font-size: 16px;
  font-weight: 700;
}

.side-nav {
  gap: 2px;
}

.nav-section-title {
  margin: 9px 10px 4px;
}

.nav-item,
.nav-subitem {
  min-height: 38px;
  border-radius: 8px;
  padding: 6px 8px;
  font-weight: 600;
}

.nav-item {
  grid-template-columns: 28px 1fr;
}

.nav-code {
  width: 24px;
  height: 22px;
  border-radius: 5px;
  font-size: 11px;
}

.nav-submenu {
  gap: 2px;
  margin: 0 0 2px 28px;
  padding-left: 8px;
}

.nav-subitem {
  grid-template-columns: 22px 1fr;
}

.nav-dot {
  width: 20px;
  height: 20px;
}

/* PLP-HR sidebar follows the SCM navigation structure.
 * Shared tokens own density and state; these rules only remove legacy HR
 * number badges and keep the local shell dimensions aligned. */
body.puze-admin-ui .sidebar {
  width: 280px;
  padding: 24px 20px 18px;
  gap: 4px;
  background: var(--puze-color-sidebar);
  border-right: 1px solid #d7e1ee;
}

body.puze-admin-ui .sidebar-brand {
  display: block;
  min-height: 120px;
  border-bottom: 1px solid #d7e1ee;
}

body.puze-admin-ui .sidebar-brand p {
  margin: 0 0 8px;
  color: #8da0bf;
  font-size: 12px !important;
  font-weight: 800;
  letter-spacing: 0.14em;
}

body.puze-admin-ui .sidebar-brand strong {
  display: block;
  color: #173769;
}

body.puze-admin-ui .side-nav {
  margin-top: 14px;
}

body.puze-admin-ui .nav-section-title {
  margin: 12px 12px 6px;
  color: var(--puze-admin-sidebar-heading);
  font-size: 12px !important;
  font-weight: 700;
}

body.puze-admin-ui .nav-item,
body.puze-admin-ui .nav-subitem {
  font-size: 14px !important;
}

body.puze-admin-ui .nav-item .nav-dot {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: #b8c6dc;
  flex: 0 0 7px;
}

body.puze-admin-ui .nav-item.is-parent {
  color: #173769 !important;
}

body.puze-admin-ui .nav-item.is-parent .nav-dot,
body.puze-admin-ui .nav-item.active .nav-dot {
  background: var(--puze-color-primary);
}

body.puze-admin-ui .nav-submenu {
  display: flex;
  flex-direction: column;
  gap: var(--puze-admin-sidebar-item-gap);
  margin: 0 !important;
  padding: 0 !important;
  border-left: 0;
}

body.puze-admin-ui .nav-subitem {
  grid-template-columns: none;
}

body.puze-admin-ui .sidebar-status {
  margin-top: auto;
}

.summary-card,
.list,
.detail,
.module-banner,
.module-card,
.module-panel {
  box-shadow: none;
}

.summary-card {
  padding: 12px 14px;
}

.summary-card strong {
  margin-bottom: 2px;
  font-size: 14px;
}

.module-banner {
  padding: 16px;
}

.module-banner h2,
.module-card h3,
.module-panel h3 {
  font-size: 14px;
}

@media (max-width: 900px) {
  .admin-layout {
    display: block;
  }

  .sidebar {
    position: fixed;
    width: min(280px, calc(100vw - 44px));
  }

  .main-panel {
    padding: 0 14px 24px;
  }

  .topbar {
    display: flex;
    min-width: 0;
    margin: 0 -14px 14px;
    padding: 0 10px 0 14px;
  }

  .user-card {
    display: none;
  }

}
