:root {
  color-scheme: dark;
  --bg: #07100d;
  --bg-2: #0b1713;
  --surface: #101d18;
  --surface-2: #14241e;
  --border: #284138;
  --text: #f1f7ef;
  --muted: #9fb0a8;
  --accent: #b8e986;
  --accent-2: #72c6b2;
  --second: #f2c45d;
  --warning: #f4c95d;
  --danger: #ff8d76;
  --shadow: 0 22px 80px rgba(0, 0, 0, 0.35);
  font-family:
    "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", system-ui,
    sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

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

button {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.display-body {
  min-height: 100vh;
  overflow: hidden;
  background:
    radial-gradient(circle at 72% 10%, rgba(98, 150, 120, 0.14), transparent 30%),
    linear-gradient(135deg, #050a09 0%, #0b1713 52%, #050807 100%);
}

.display-shell {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto auto 1fr;
  padding: clamp(12px, 2vw, 28px);
  gap: clamp(14px, 1.8vw, 22px);
}

.display-top-bar {
  min-height: clamp(54px, 6.4vw, 82px);
  display: grid;
  grid-template-columns: minmax(220px, auto) minmax(0, 1fr);
  align-items: stretch;
  gap: clamp(10px, 1.6vw, 18px);
}

.display-top-bar .tenant-name {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: min(30vw, 420px);
  padding: 10px clamp(16px, 2.4vw, 32px);
  border: 1px solid rgba(242, 196, 93, 0.28);
  border-radius: 8px;
  background: rgba(11, 23, 19, 0.82);
  box-shadow: var(--shadow);
  color: var(--second);
  font-size: clamp(22px, 2.8vw, 42px);
  font-weight: 900;
  line-height: 1.12;
  text-align: center;
}

.display-top-bar .tenant-name.tenant-long {
  font-size: clamp(25px, 2.25vw, 36px);
  line-height: 1.08;
}

.display-top-bar .tenant-name.tenant-extra-long {
  font-size: clamp(21px, 1.85vw, 30px);
  line-height: 1.05;
}

.message-strip {
  min-height: clamp(48px, 6vw, 78px);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 10px clamp(18px, 3vw, 44px);
  border: 1px solid rgba(242, 196, 93, 0.28);
  background: rgba(11, 23, 19, 0.74);
  color: var(--second);
  box-shadow: var(--shadow);
  font-size: clamp(22px, 3.1vw, 46px);
  font-weight: 850;
  line-height: 1.25;
  text-align: center;
  text-shadow: 0 0 22px rgba(242, 196, 93, 0.08);
}

.more-widget {
  position: fixed;
  right: clamp(18px, 2.4vw, 34px);
  bottom: clamp(110px, 12vw, 142px);
  z-index: 20;
  display: grid;
  justify-items: end;
  gap: 10px;
}

.more-button {
  min-width: 74px;
  min-height: 46px;
  border: 1px solid rgba(242, 196, 93, 0.35);
  border-radius: 999px;
  background: rgba(11, 23, 19, 0.86);
  color: var(--second);
  font-weight: 850;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.28);
}

.more-button:hover {
  background: rgba(38, 50, 34, 0.94);
}

.more-menu {
  width: min(320px, calc(100vw - 40px));
  padding: 16px;
  border: 1px solid rgba(242, 196, 93, 0.3);
  border-radius: 8px;
  background: rgba(11, 23, 19, 0.96);
  color: var(--text);
  box-shadow: var(--shadow);
}

.more-menu strong {
  display: block;
  color: var(--second);
  font-size: 16px;
}

.more-menu p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.message-strip span {
  display: block;
  max-width: 100%;
}

.message-strip.scrolling {
  justify-content: flex-start;
  text-align: left;
}

.message-strip.scrolling span {
  max-width: none;
  min-width: max-content;
  padding-left: 100%;
  white-space: nowrap;
  animation: message-scroll var(--message-scroll-duration, 28s) linear infinite;
}

.message-strip.empty {
  color: rgba(242, 196, 93, 0.72);
  border-color: rgba(242, 196, 93, 0.18);
}

.message-strip.empty span {
  padding-left: 0;
  animation: none;
}

.network-warning {
  margin-top: -8px;
  padding: 8px 14px;
  border: 1px solid rgba(255, 141, 118, 0.28);
  border-radius: 8px;
  background: rgba(255, 141, 118, 0.08);
  color: #ffb4a4;
  font-size: 16px;
  text-align: center;
}

@keyframes message-scroll {
  from {
    transform: translateX(0);
  }

  to {
    transform: translateX(-100%);
  }
}

.display-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.select-group {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 16px;
}

.select-group select,
.admin-shell input,
.admin-shell select,
.admin-shell textarea {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #0c1814;
  color: var(--text);
  outline: none;
}

.select-group select {
  min-width: 160px;
  padding: 12px 14px;
}

.select-group select:focus,
.admin-shell input:focus,
.admin-shell select:focus,
.admin-shell textarea:focus {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(114, 198, 178, 0.16);
}

.toolbar-actions,
.form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.icon-button,
.primary-button,
.secondary-button,
.danger-button,
.display-link {
  min-height: 42px;
  border-radius: 8px;
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  transition:
    border-color 0.18s ease,
    background 0.18s ease,
    transform 0.18s ease;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(16, 29, 24, 0.86);
}

.button-icon {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

.icon-button:hover,
.secondary-button:hover,
.danger-button:hover,
.display-link:hover {
  border-color: var(--accent-2);
  background: rgba(31, 56, 47, 0.92);
}

.exam-stage {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: clamp(12px, 1.6vw, 22px);
  min-height: 0;
}

.clock-stage {
  width: 100%;
  display: grid;
  grid-template-rows: auto 1fr;
  align-items: center;
  padding: clamp(24px, 3.8vw, 54px) clamp(24px, 4.4vw, 64px)
    clamp(18px, 2.8vw, 34px);
}

.date-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  font-size: clamp(18px, 1.8vw, 28px);
}

.date-row > span:first-child {
  display: inline-flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.tenant-name {
  color: var(--second);
  font-size: clamp(20px, 2.1vw, 32px);
  font-weight: 850;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 8px 16px;
  border: 1px solid rgba(184, 233, 134, 0.3);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(184, 233, 134, 0.08);
  font-weight: 700;
}

.status-pill.last_15 {
  color: var(--warning);
  border-color: rgba(244, 201, 93, 0.42);
  background: rgba(244, 201, 93, 0.09);
}

.status-pill.ended {
  color: var(--danger);
  border-color: rgba(255, 141, 118, 0.4);
  background: rgba(255, 141, 118, 0.08);
}

.status-pill.not_configured,
.status-pill.not_started {
  color: var(--muted);
  border-color: rgba(159, 176, 168, 0.32);
  background: rgba(159, 176, 168, 0.07);
}

.time-text {
  display: flex;
  align-items: baseline;
  justify-content: center;
  font-variant-numeric: tabular-nums;
  line-height: 0.9;
  color: #eaf5e8;
  text-shadow: 0 0 30px rgba(184, 233, 134, 0.08);
  transform: translateY(clamp(-22px, -1.35vw, -12px));
}

#timeMain {
  font-size: clamp(110px, 16.9vw, 244px);
  font-weight: 880;
}

#timeSeconds {
  margin-left: clamp(10px, 1.4vw, 18px);
  color: var(--second);
  font-size: clamp(62px, 8.75vw, 126px);
  font-weight: 860;
  text-shadow: 0 0 24px rgba(242, 196, 93, 0.12);
}

.subject-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
  color: var(--text);
  font-size: clamp(26px, 3.6vw, 54px);
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent-2);
}

.remaining-block {
  display: grid;
  justify-items: center;
  gap: 8px;
}

.remaining-label {
  color: var(--muted);
  font-size: clamp(18px, 1.8vw, 26px);
}

.remaining-block strong {
  font-variant-numeric: tabular-nums;
  font-size: clamp(42px, 5.3vw, 82px);
  line-height: 1;
  color: var(--accent);
}

.schedule-line {
  color: var(--muted);
  font-size: clamp(18px, 2vw, 30px);
}

.slogan {
  margin: 0;
  color: var(--second);
  font-size: clamp(38px, 4.8vw, 68px);
  font-weight: 900;
  line-height: 1.12;
  text-align: center;
  text-shadow: 0 0 28px rgba(242, 196, 93, 0.1);
  transform: translateY(clamp(-12px, -0.55vw, -6px));
}

.exam-stage.ended .time-text,
.exam-stage.ended .slogan {
  opacity: 0.82;
}

.bottom-info-bar {
  display: grid;
  grid-template-columns: 160px 220px 230px 220px 132px;
  justify-content: space-between;
  gap: 10px;
  align-items: stretch;
}

.info-box {
  min-height: 86px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 11px 15px;
  border: 1px solid rgba(184, 233, 134, 0.34);
  border-radius: 8px;
  background: rgba(184, 233, 134, 0.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 42px rgba(0, 0, 0, 0.18);
}

.grade-card {
  border-color: rgba(184, 233, 134, 0.44);
  background: rgba(184, 233, 134, 0.13);
}

.info-label {
  color: var(--muted);
  font-size: 16px;
}

.info-value {
  color: var(--text);
  font-size: 30px;
  font-weight: 850;
  line-height: 1.05;
}

.info-value.small {
  font-size: 24px;
}

.schedule-box {
  min-width: 0;
}

.schedule-box .info-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.info-value.remain {
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.grade-select {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 30px;
  font-weight: 850;
  line-height: 1.05;
}

.tool-box {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.round-tool-button {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(242, 196, 93, 0.32);
  border-radius: 15px;
  background: linear-gradient(
    180deg,
    rgba(242, 196, 93, 0.16),
    rgba(9, 22, 18, 0.88)
  );
  color: #fff7dc;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 18px 40px rgba(0, 0, 0, 0.28);
}

.round-tool-button:hover {
  border-color: rgba(242, 196, 93, 0.5);
  background: linear-gradient(
    180deg,
    rgba(242, 196, 93, 0.24),
    rgba(14, 30, 25, 0.92)
  );
}

.round-tool-button .button-icon {
  width: 26px;
  height: 26px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

:fullscreen .display-shell {
  padding: clamp(10px, 1.5vw, 22px);
}

.admin-body {
  min-height: 100vh;
  color-scheme: light;
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-2: #eef5f4;
  --border: #d6e0eb;
  --text: #142033;
  --muted: #637187;
  --accent: #0f766e;
  --accent-2: #2563eb;
  --second: #d97706;
  --warning: #b7791f;
  --danger: #c2410c;
  --shadow: 0 18px 45px rgba(36, 52, 71, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(244, 247, 251, 0.96)),
    radial-gradient(circle at 12% 0%, rgba(37, 99, 235, 0.12), transparent 34%),
    radial-gradient(circle at 88% 8%, rgba(15, 118, 110, 0.12), transparent 28%),
    #f4f7fb;
}

.admin-shell {
  width: min(1480px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 34px;
}

.admin-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.brand-heading {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.brand-logo {
  width: min(360px, 34vw);
  height: 86px;
  object-fit: contain;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(36, 52, 71, 0.12);
}

.admin-header h1,
.auth-card h2,
.grade-list-panel h2,
.subject-bank-panel h2,
.editor-heading h2,
.message-editor h3 {
  margin: 0;
  color: var(--text);
}

.admin-header h1 {
  font-size: clamp(28px, 4vw, 42px);
}

.admin-header p,
.editor-heading p,
.current-message,
.form-message {
  color: var(--muted);
}

.admin-workspace {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 18px;
  min-width: 0;
}

.tenant-info-panel {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.tenant-info-panel h2 {
  margin: 4px 0 6px;
  color: var(--text);
  font-size: 24px;
}

.tenant-info-panel p {
  margin: 0;
  color: var(--muted);
}

.tenant-info-extra {
  display: grid;
  gap: 8px;
  justify-items: end;
  color: var(--muted);
  white-space: nowrap;
}

.admin-side {
  display: grid;
  align-content: start;
  gap: 18px;
  min-width: 0;
}

.login-panel {
  min-height: 54vh;
  display: grid;
  place-items: center;
}

.auth-card,
.grade-list-panel,
.subject-bank-panel,
.editor-panel {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.auth-card {
  width: min(420px, 100%);
  display: grid;
  gap: 18px;
  padding: 28px;
}

.login-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fafc;
}

.login-tab {
  min-height: 38px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
}

.login-tab.active {
  background: var(--surface);
  color: var(--accent);
  box-shadow: 0 6px 18px rgba(36, 52, 71, 0.1);
}

.auth-card form {
  display: grid;
  gap: 16px;
}

.code-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.auth-card label,
.form-grid label,
.exam-setting-row label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 15px;
}

.admin-shell input,
.admin-shell select,
.admin-shell textarea {
  width: 100%;
  padding: 12px 13px;
  resize: vertical;
}

.subject-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.field-help {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.primary-button,
.secondary-button,
.danger-button,
.display-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  font-weight: 700;
}

.primary-button {
  border-color: rgba(15, 118, 110, 0.38);
  background: #0f766e;
  color: #ffffff;
}

.primary-button:hover {
  background: #0d9488;
}

.secondary-button,
.display-link {
  background: rgba(16, 29, 24, 0.9);
}

.admin-body .secondary-button,
.admin-body .display-link {
  background: #ffffff;
  color: var(--text);
}

.danger-button {
  border-color: rgba(194, 65, 12, 0.28);
  background: #fff7ed;
  color: #c2410c;
}

.danger-button:hover {
  border-color: rgba(194, 65, 12, 0.5);
  background: #ffedd5;
}

.admin-body .secondary-button:hover,
.admin-body .display-link:hover {
  border-color: var(--accent-2);
  background: #eef4ff;
}

.admin-body .admin-shell input,
.admin-body .admin-shell select,
.admin-body .admin-shell textarea,
.modal-dialog input,
.modal-dialog select,
.modal-dialog textarea {
  background: #ffffff;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
}

.modal-dialog input,
.modal-dialog select,
.modal-dialog textarea {
  width: 100%;
  padding: 12px 13px;
}

.modal-dialog input:focus,
.modal-dialog select:focus,
.modal-dialog textarea:focus {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.admin-body .auth-card,
.admin-body .grade-list-panel,
.admin-body .subject-bank-panel,
.admin-body .editor-panel {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.94);
}

.grade-list-panel {
  padding: 18px;
}

.subject-bank-panel {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.subject-bank-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.grade-list {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.grade-item {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #0c1814;
  color: var(--text);
  text-align: left;
  padding: 12px 14px;
}

.grade-item.active {
  border-color: var(--accent);
  background: rgba(184, 233, 134, 0.12);
}

.admin-body .grade-item {
  background: #ffffff;
  color: var(--text);
}

.admin-body .grade-item.active {
  border-color: rgba(15, 118, 110, 0.6);
  background: #e8f6f3;
  color: #0f4f47;
}

.editor-panel {
  padding: clamp(16px, 2vw, 24px);
  min-width: 0;
}

.editor-heading {
  position: relative;
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 18px;
  margin-bottom: 20px;
  padding-inline: 150px;
}

.editor-heading .display-link {
  position: absolute;
  top: 0;
  right: 0;
}

.editor-heading p {
  margin: 6px 0 0;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.wide-field {
  grid-column: 1 / -1;
}

.message-editor {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.standalone-message-editor {
  margin-top: 0;
  margin-bottom: 24px;
  padding-top: 0;
  padding-bottom: 22px;
  border-top: 0;
  border-bottom: 1px solid var(--border);
}

.message-hint {
  margin: 6px 0 12px;
  color: var(--muted);
  font-size: 14px;
}

.form-section-title {
  margin: 0;
}

.exam-list-section {
  display: grid;
  gap: 14px;
}

.exam-list-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.heading-actions {
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.exam-list-heading p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.exam-settings-list {
  display: grid;
  gap: 12px;
}

.exam-setting-row {
  display: grid;
  grid-template-columns: 140px 180px 180px minmax(220px, 1fr) 94px;
  gap: 12px;
  align-items: end;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(7, 16, 13, 0.5);
}

.admin-body .exam-setting-row {
  border-color: var(--border);
  background: #ffffff;
}

.exam-setting-row.in_progress,
.exam-setting-row.last_15 {
  border-color: rgba(184, 233, 134, 0.48);
  background: rgba(184, 233, 134, 0.08);
}

.admin-body .exam-setting-row.in_progress,
.admin-body .exam-setting-row.last_15 {
  border-color: rgba(15, 118, 110, 0.42);
  background: #ecf8f4;
}

.exam-setting-row.ended {
  border-color: rgba(255, 141, 118, 0.25);
  background: rgba(255, 141, 118, 0.035);
}

.admin-body .exam-setting-row.ended {
  border-color: rgba(194, 65, 12, 0.24);
  background: #fff7ed;
}

.setting-subject {
  min-height: 58px;
  display: grid;
  align-content: center;
  gap: 6px;
}

.setting-subject strong {
  color: var(--text);
  font-size: 20px;
  line-height: 1.2;
}

.setting-status {
  width: fit-content;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border: 1px solid rgba(159, 176, 168, 0.24);
  border-radius: 999px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.setting-status.in_progress {
  color: var(--accent);
  border-color: rgba(184, 233, 134, 0.34);
  background: rgba(184, 233, 134, 0.08);
}

.setting-status.last_15 {
  color: var(--warning);
  border-color: rgba(244, 201, 93, 0.38);
  background: rgba(244, 201, 93, 0.08);
}

.setting-status.ended {
  color: var(--danger);
  border-color: rgba(255, 141, 118, 0.32);
  background: rgba(255, 141, 118, 0.06);
}

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

.setting-actions .primary-button,
.setting-actions .secondary-button {
  min-height: 45px;
  padding-inline: 13px;
  white-space: nowrap;
}

.setting-empty {
  padding: 16px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  color: var(--muted);
  background: rgba(7, 16, 13, 0.38);
}

.admin-body .setting-empty {
  background: #f8fafc;
}

.current-message {
  min-height: 44px;
  display: flex;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid rgba(159, 176, 168, 0.2);
  background: rgba(7, 16, 13, 0.62);
}

.admin-body .current-message {
  border-color: var(--border);
  background: #f8fafc;
}

.message-form {
  display: grid;
  gap: 14px;
}

.super-workspace {
  display: grid;
  gap: 18px;
}

.super-profile-panel {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
}

.super-profile-panel p {
  margin: 6px 0 0;
  color: var(--muted);
}

.inline-form {
  display: grid;
  grid-template-columns: minmax(220px, 300px) auto minmax(120px, 1fr);
  align-items: end;
  gap: 12px;
}

.inline-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 15px;
}

.filter-panel {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr)) auto;
  gap: 12px;
  align-items: end;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f8fafc;
}

.filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.filter-actions {
  display: flex;
  justify-content: flex-end;
}

.super-create-form {
  display: grid;
  gap: 18px;
}

.tenant-table {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.tenant-row {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(280px, 1fr) auto;
  gap: 14px;
  align-items: end;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
}

.modal-dialog {
  width: min(920px, calc(100vw - 32px));
  max-height: min(86vh, 820px);
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
}

.modal-dialog::backdrop {
  background: rgba(15, 23, 42, 0.46);
  backdrop-filter: blur(2px);
}

.modal-card {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  max-height: min(86vh, 820px);
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 28px 80px rgba(15, 23, 42, 0.22);
  overflow: hidden;
}

.modal-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 24px 16px;
  border-bottom: 1px solid var(--border);
}

.modal-heading p {
  margin: 6px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.modal-body {
  display: grid;
  gap: 16px;
  padding: 20px 24px;
  overflow: auto;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 16px 24px 22px;
  border-top: 1px solid var(--border);
  background: #f8fafc;
}

.icon-close-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
  color: var(--muted);
  font-size: 26px;
  line-height: 1;
}

.icon-close-button:hover {
  border-color: var(--accent-2);
  color: var(--text);
  background: #eef4ff;
}

.tenant-row strong {
  display: inline-block;
  margin-right: 8px;
  color: var(--text);
  font-size: 20px;
}

.tenant-row p {
  margin: 8px 0 0;
  color: var(--muted);
}

.tenant-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.form-message {
  min-height: 22px;
  margin: 0;
}

.form-message.success {
  color: var(--accent);
}

.form-message.error {
  color: var(--danger);
}

@media (max-width: 760px) {
  .display-shell {
    overflow: auto;
  }

  .display-top-bar {
    grid-template-columns: 1fr;
  }

  .display-top-bar .tenant-name {
    min-width: 0;
  }

  .more-widget {
    right: 16px;
    bottom: 96px;
  }

  .display-toolbar,
  .date-row,
  .admin-header,
  .editor-heading {
    align-items: stretch;
    flex-direction: column;
  }

  .brand-heading,
  .tenant-info-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .brand-logo {
    width: min(100%, 320px);
    height: 76px;
  }

  .heading-actions,
  .modal-heading,
  .modal-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .modal-dialog {
    width: calc(100vw - 20px);
    max-height: 92vh;
  }

  .modal-card {
    max-height: 92vh;
  }

  .modal-body,
  .modal-heading,
  .modal-actions {
    padding-inline: 16px;
  }

  .tenant-info-extra {
    justify-items: start;
    white-space: normal;
  }

  .code-input-row {
    grid-template-columns: 1fr;
  }

  .editor-heading {
    display: grid;
    justify-items: start;
    text-align: left;
    padding-inline: 0;
  }

  .editor-heading .display-link {
    position: static;
  }

  .clock-stage {
    padding-inline: 4px;
  }

  .date-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .status-pill {
    min-height: 34px;
    padding: 6px 12px;
  }

  .time-text {
    justify-content: flex-start;
    margin-top: 30px;
  }

  #timeMain {
    font-size: clamp(64px, 19.5vw, 96px);
  }

  #timeSeconds {
    font-size: clamp(34px, 10vw, 52px);
  }

  .bottom-info-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tool-box {
    grid-column: 1 / -1;
  }

  .tool-box {
    justify-content: flex-start;
    min-height: auto;
  }

  .toolbar-actions,
  .select-group {
    width: 100%;
  }

  .select-group select,
  .icon-button {
    flex: 1;
  }

  .clock-panel {
    min-height: auto;
  }

  .admin-workspace,
  .form-grid,
  .subject-picker,
  .inline-form,
  .filter-panel,
  .tenant-row {
    grid-template-columns: 1fr;
  }

  .super-profile-panel {
    align-items: stretch;
    flex-direction: column;
  }
}

/* Rich push content */
.push-field-help {
  display: block;
  margin-top: 6px;
  color: #718198;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
}

.push-form input[type="file"] {
  padding: 9px 10px;
  background: #f8fbfd;
}

.push-content-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(0, 124, 119, 0.09);
  color: #007c77;
  font-size: 11px;
  font-weight: 800;
}

.push-content-badge.is-image {
  background: rgba(145, 94, 21, 0.1);
  color: #87560e;
}

.push-content-badge.is-webpage {
  background: rgba(91, 73, 171, 0.1);
  color: #5b49ab;
}

.more-menu {
  position: fixed;
  right: clamp(16px, 3vw, 42px);
  bottom: clamp(96px, 12vh, 132px);
  width: min(760px, calc(100vw - 32px));
  max-height: min(72vh, 720px);
  overflow: auto;
  padding: 20px;
}

.more-menu > strong {
  position: sticky;
  top: -20px;
  z-index: 2;
  margin: -20px -20px 8px;
  padding: 17px 20px 14px;
  border-bottom: 1px solid rgba(0, 231, 242, 0.18);
  background: rgba(4, 14, 19, 0.98);
  color: var(--display-cyan);
}

.more-menu-item {
  position: relative;
  gap: 9px;
  padding: 16px 0 4px;
}

.more-menu-item > strong {
  padding-right: 56px;
  font-size: clamp(18px, 1.5vw, 24px);
}

.push-content-kind {
  position: absolute;
  top: 16px;
  right: 0;
  padding: 3px 8px;
  border: 1px solid rgba(0, 231, 242, 0.2);
  border-radius: 999px;
  color: rgba(177, 231, 232, 0.78);
  font-size: 11px;
  line-height: 1.4;
}

.push-content-text,
.push-content-caption {
  margin: 0;
  color: #d8e7e5;
  font-size: clamp(15px, 1.15vw, 18px);
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.push-media {
  display: grid;
  gap: 10px;
}

.push-media--image img {
  display: block;
  width: 100%;
  max-height: min(52vh, 520px);
  object-fit: contain;
  border: 1px solid rgba(0, 231, 242, 0.16);
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.2);
}

.push-media--webpage iframe {
  display: block;
  width: 100%;
  height: min(52vh, 520px);
  border: 1px solid rgba(0, 231, 242, 0.18);
  border-radius: 6px;
  background: #ffffff;
}

.display-popup[data-content-kind="image"] .display-popup-card,
.display-popup[data-content-kind="webpage"] .display-popup-card {
  width: min(920px, calc(100vw - 48px));
}

.display-popup-content {
  min-width: 0;
  max-height: 72vh;
  overflow: auto;
}

.display-popup-content .push-media--webpage iframe {
  height: min(62vh, 620px);
}

@media (max-width: 760px) {
  .more-menu {
    right: 12px;
    bottom: 92px;
    width: calc(100vw - 24px);
    max-height: 70vh;
    padding: 16px;
  }

  .more-menu > strong {
    top: -16px;
    margin: -16px -16px 8px;
    padding: 14px 16px 12px;
  }

  .push-media--webpage iframe,
  .display-popup-content .push-media--webpage iframe {
    height: 54vh;
  }
}

@media (max-width: 1320px) {
  .exam-setting-row {
    grid-template-columns: minmax(120px, 0.8fr) repeat(2, minmax(160px, 1fr));
  }

  .setting-slogan-field,
  .setting-actions {
    grid-column: 1 / -1;
  }

  .setting-actions {
    justify-content: flex-start;
  }
}

/* 2026 visual refresh: restrained education dashboard + energy-saving display */
:root {
  --bg: #05090d;
  --bg-2: #0a1118;
  --surface: #0f1921;
  --surface-2: #15232b;
  --border: #243743;
  --text: #edf6f4;
  --muted: #8da1a8;
  --accent: #57d1c7;
  --accent-2: #84c7ff;
  --second: #57d1c7;
  --warning: #eec96a;
  --danger: #ff8a72;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.display-body {
  background:
    radial-gradient(circle at 8% 12%, rgba(87, 209, 199, 0.1), transparent 34%),
    radial-gradient(circle at 88% 2%, rgba(132, 199, 255, 0.08), transparent 32%),
    linear-gradient(150deg, #030609 0%, #071018 48%, #04080b 100%);
}

.display-shell {
  padding: clamp(14px, 2vw, 30px);
  gap: clamp(12px, 1.4vw, 20px);
}

.display-top-bar {
  min-height: clamp(56px, 5.8vw, 78px);
  grid-template-columns: minmax(230px, max-content) minmax(0, 1fr);
}

.display-top-bar .tenant-name,
.message-strip,
.info-box,
.tool-box,
.more-menu {
  border-color: rgba(87, 209, 199, 0.22);
  background:
    linear-gradient(180deg, rgba(17, 30, 39, 0.88), rgba(8, 16, 22, 0.88)),
    rgba(8, 16, 22, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.045),
    0 18px 48px rgba(0, 0, 0, 0.24);
}

.display-top-bar .tenant-name {
  min-width: min(28vw, 440px);
  color: #dffbf8;
  font-size: clamp(22px, 2.5vw, 38px);
  letter-spacing: 0;
}

.message-strip {
  color: var(--accent);
  font-weight: 850;
}

.message-strip span {
  color: var(--accent);
}

.message-strip::before,
.display-top-bar .tenant-name::before {
  content: "";
  width: 6px;
  height: 42%;
  margin-right: 13px;
  border-radius: 999px;
  background: linear-gradient(180deg, #57d1c7, #84c7ff);
  box-shadow: 0 0 18px rgba(87, 209, 199, 0.3);
}

.clock-stage {
  padding-top: clamp(10px, 2.4vw, 34px);
}

.date-row {
  font-size: clamp(17px, 1.35vw, 24px);
  color: #9bb0b7;
}

.status-pill {
  border-color: rgba(87, 209, 199, 0.26);
  color: #dffbf8;
  background: rgba(87, 209, 199, 0.08);
  border-radius: 8px;
}

.time-text {
  margin-top: clamp(-12px, -1vw, -4px);
  filter: drop-shadow(0 16px 42px rgba(0, 0, 0, 0.34));
}

#timeMain {
  color: #f3f8f7;
  font-weight: 760;
}

#timeSeconds {
  color: var(--accent);
  text-shadow: 0 0 26px rgba(87, 209, 199, 0.3);
}

.slogan {
  color: var(--accent);
  font-weight: 850;
  text-shadow: 0 0 22px rgba(87, 209, 199, 0.18);
}

.bottom-info-bar {
  grid-template-columns: minmax(150px, 0.72fr) minmax(210px, 1fr) minmax(230px, 1.14fr) minmax(210px, 1fr) 128px;
  gap: clamp(10px, 1vw, 16px);
}

.info-box {
  min-height: 92px;
  padding: 13px 17px;
  border-radius: 10px;
}

.info-label {
  color: #8ea6ad;
  font-size: 15px;
  font-weight: 700;
}

.info-value {
  color: #eef8f6;
  font-size: clamp(24px, 2vw, 31px);
}

.info-value.remain {
  color: var(--accent);
}

.grade-select {
  border-color: rgba(87, 209, 199, 0.2);
  background: rgba(3, 8, 11, 0.36);
  color: #eef8f6;
}

.round-tool-button,
.more-button {
  border-color: rgba(87, 209, 199, 0.22);
  background: rgba(87, 209, 199, 0.09);
  color: #dffbf8;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.round-tool-button:hover,
.more-button:hover {
  border-color: rgba(87, 209, 199, 0.5);
  background: rgba(87, 209, 199, 0.16);
}

.admin-body {
  --bg: #f5f8fb;
  --surface: rgba(255, 255, 255, 0.94);
  --surface-2: #eef6f7;
  --border: #d9e5ec;
  --text: #10243a;
  --muted: #637388;
  --accent: #0f8f96;
  --accent-2: #256f9f;
  --second: #cc7a24;
  --warning: #b7791f;
  --danger: #c2410c;
  --shadow: 0 18px 48px rgba(18, 38, 63, 0.08);
  background:
    radial-gradient(circle at 8% -8%, rgba(15, 143, 150, 0.13), transparent 36%),
    radial-gradient(circle at 92% 2%, rgba(37, 111, 159, 0.12), transparent 34%),
    linear-gradient(180deg, #fbfdff 0%, #f4f8fb 48%, #eef4f7 100%);
}

.admin-shell {
  width: min(1500px, calc(100% - 36px));
  padding: 26px 0 38px;
}

.admin-header {
  align-items: center;
  margin-bottom: 22px;
  padding: 16px 18px;
  border: 1px solid rgba(217, 229, 236, 0.82);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: 0 14px 44px rgba(18, 38, 63, 0.06);
  backdrop-filter: blur(14px);
}

.brand-heading {
  gap: 20px;
  align-items: flex-end;
}

.brand-heading > div {
  padding-top: 31px;
  padding-bottom: 0;
}

.brand-logo {
  width: min(380px, 33vw);
  height: 72px;
  border: 1px solid rgba(217, 229, 236, 0.72);
  border-radius: 10px;
  background: #f8fbfd;
  box-shadow: none;
}

.admin-header h1 {
  font-size: clamp(26px, 3vw, 38px);
  letter-spacing: 0;
}

.admin-header p {
  margin-top: 6px;
  font-size: 15px;
}

.auth-card,
.grade-list-panel,
.subject-bank-panel,
.editor-panel,
.tenant-info-panel,
.modal-card {
  border-color: rgba(217, 229, 236, 0.94);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 52px rgba(18, 38, 63, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.auth-card {
  width: min(460px, 100%);
  padding: 30px;
}

.login-tabs {
  border-color: #dbe8ee;
  border-radius: 10px;
  background: #eef5f7;
}

.login-tab {
  border-radius: 8px;
}

.login-tab.active {
  color: var(--accent);
  box-shadow: 0 8px 20px rgba(15, 143, 150, 0.1);
}

.admin-shell input,
.admin-shell select,
.admin-shell textarea {
  min-height: 44px;
  border-color: #d6e4eb;
  border-radius: 9px;
  background: #fbfdff;
  color: var(--text);
}

.admin-shell input:focus,
.admin-shell select:focus,
.admin-shell textarea:focus {
  border-color: rgba(15, 143, 150, 0.56);
  box-shadow: 0 0 0 4px rgba(15, 143, 150, 0.12);
}

.primary-button,
.secondary-button,
.danger-button,
.display-link {
  border-radius: 9px;
  font-weight: 800;
}

.primary-button {
  border-color: #0f8f96;
  background: linear-gradient(180deg, #18a9af, #0f8f96);
  box-shadow: 0 12px 26px rgba(15, 143, 150, 0.22);
}

.primary-button:hover {
  background: linear-gradient(180deg, #20b9bf, #0d8188);
}

.admin-body .secondary-button,
.admin-body .display-link {
  border-color: #d6e4eb;
  background: #f8fbfd;
  color: #25435e;
}

.admin-body .secondary-button:hover,
.admin-body .display-link:hover {
  border-color: rgba(15, 143, 150, 0.36);
  background: #eef9f8;
  color: #0f6f76;
}

.tenant-info-panel,
.editor-heading {
  border-left: 4px solid rgba(15, 143, 150, 0.7);
}

.grade-item,
.tenant-row,
.exam-setting-row,
.subject-item,
.current-message,
.filter-panel {
  border-radius: 10px;
  border-color: #dbe8ee;
  background: #ffffff;
}

.admin-body .grade-item.active,
.admin-body .exam-setting-row.in_progress,
.admin-body .exam-setting-row.last_15 {
  border-color: rgba(15, 143, 150, 0.42);
  background: linear-gradient(180deg, #f1fbfa, #ffffff);
}

.tenant-row {
  padding: 16px;
  box-shadow: 0 10px 26px rgba(18, 38, 63, 0.045);
}

.tenant-row strong {
  color: #10243a;
}

.setting-status {
  border-radius: 8px;
}

.setting-status.in_progress {
  color: #08777e;
  border-color: rgba(15, 143, 150, 0.28);
  background: rgba(15, 143, 150, 0.09);
}

.setting-status.last_15 {
  color: #a15c09;
  border-color: rgba(217, 119, 6, 0.24);
  background: #fff7ed;
}

.setting-status.ended {
  color: #b33214;
  border-color: rgba(194, 65, 12, 0.2);
  background: #fff4ef;
}

.modal-dialog,
.modal-card {
  border-radius: 12px;
}

.modal-dialog::backdrop {
  background: rgba(15, 30, 45, 0.38);
  backdrop-filter: blur(5px);
}

@media (max-width: 760px) {
  .admin-header {
    padding: 14px;
  }

  .time-text {
    margin-top: 30px;
    transform: none;
  }

  #timeMain {
    font-size: clamp(64px, 19.5vw, 96px);
  }

  #timeSeconds {
    font-size: clamp(34px, 10vw, 52px);
  }

  .slogan {
    margin-top: 14px;
    transform: none;
    font-size: clamp(32px, 9.5vw, 44px);
    line-height: 1.1;
  }

  .brand-logo {
    width: min(100%, 320px);
    height: 62px;
  }

  .bottom-info-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Concept implementation layer: closer to the approved board, kept as one editable block. */
:root {
  --display-bg: #03080d;
  --display-panel: rgba(9, 20, 27, 0.9);
  --display-panel-2: rgba(13, 28, 36, 0.86);
  --display-line: rgba(68, 231, 221, 0.2);
  --display-line-strong: rgba(68, 231, 221, 0.42);
  --display-text: #f3f4ed;
  --display-muted: #91a8ae;
  --display-cyan: #49d0c8;
  --display-warn: #f5d7a0;
  --admin-bg: #f5f9fc;
  --admin-panel: rgba(255, 255, 255, 0.96);
  --admin-line: #dbe8ef;
  --admin-text: #12263d;
  --admin-muted: #627486;
  --admin-cyan: #119aa2;
}

.display-body {
  background:
    radial-gradient(circle at 18% 14%, rgba(68, 231, 221, 0.08), transparent 28%),
    radial-gradient(circle at 80% 4%, rgba(65, 136, 188, 0.08), transparent 30%),
    linear-gradient(145deg, #020509 0%, #07131b 52%, #03070b 100%);
}

.display-shell {
  position: relative;
  height: 100vh;
  grid-template-rows: auto auto minmax(0, 1fr);
  padding: clamp(10px, 1.1vw, 18px);
  gap: clamp(10px, 1vw, 16px);
}

.display-shell::before {
  content: "";
  position: fixed;
  inset: 4px;
  z-index: 0;
  pointer-events: none;
  border: 1px solid rgba(207, 226, 232, 0.2);
  box-shadow: inset 0 0 0 1px rgba(68, 231, 221, 0.06);
}

.display-shell > * {
  position: relative;
  z-index: 1;
}

.display-top-bar {
  min-height: clamp(58px, 5vw, 76px);
  grid-template-columns: minmax(240px, 0.78fr) minmax(0, 1.9fr);
  gap: clamp(10px, 1.2vw, 18px);
}

.display-top-bar .tenant-name,
.message-strip {
  border: 1px solid var(--display-line);
  border-radius: 4px;
  background:
    linear-gradient(180deg, rgba(14, 31, 40, 0.9), rgba(5, 12, 18, 0.9)),
    var(--display-panel);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 20px 54px rgba(0, 0, 0, 0.2);
}

.display-top-bar .tenant-name {
  justify-content: flex-start;
  min-width: 0;
  padding-inline: clamp(22px, 3vw, 44px);
  color: var(--display-text);
  font-size: clamp(24px, 2.4vw, 38px);
}

.message-strip {
  justify-content: center;
  color: var(--display-cyan);
  font-size: clamp(22px, 2.5vw, 38px);
}

.message-strip span {
  color: var(--display-cyan);
}

.display-top-bar .tenant-name::before,
.message-strip::before {
  width: 5px;
  height: 34%;
  margin-right: 16px;
  background: linear-gradient(180deg, #77f5ee, #119aa2);
}

.network-warning {
  border-color: rgba(245, 215, 160, 0.36);
  border-radius: 4px;
  background: rgba(77, 47, 22, 0.52);
  color: var(--display-warn);
}

.exam-stage {
  grid-row: 3;
  min-height: 0;
  gap: 0;
  border: 1px solid rgba(207, 226, 232, 0.14);
  border-radius: 4px;
  background:
    radial-gradient(circle at 30% 22%, rgba(68, 231, 221, 0.05), transparent 30%),
    linear-gradient(180deg, rgba(5, 13, 19, 0.34), rgba(4, 9, 14, 0.62));
  overflow: hidden;
}

.clock-stage {
  padding: clamp(24px, 3.2vw, 52px) clamp(34px, 4.8vw, 76px) clamp(20px, 2.2vw, 34px);
}

.date-row {
  color: var(--display-muted);
  font-size: clamp(17px, 1.35vw, 24px);
}

.status-pill {
  min-height: 38px;
  border-color: rgba(245, 123, 98, 0.42);
  border-radius: 6px;
  background: rgba(94, 39, 41, 0.42);
  color: #ffd7ca;
}

.status-pill.in_progress {
  border-color: rgba(73, 208, 200, 0.42);
  background: rgba(73, 208, 200, 0.08);
  color: var(--display-cyan);
}

.time-text {
  margin-top: clamp(0px, 0.5vw, 10px);
  transform: none;
  color: var(--display-text);
}

#timeMain {
  font-size: clamp(118px, 17vw, 260px);
  font-weight: 760;
  color: var(--display-text);
  letter-spacing: 0;
}

#timeSeconds {
  font-size: clamp(70px, 8.2vw, 132px);
  color: var(--display-cyan);
}

.slogan {
  margin-top: clamp(8px, 1vw, 18px);
  color: var(--display-cyan);
  font-size: clamp(34px, 4.3vw, 68px);
  font-weight: 850;
  transform: none;
}

.bottom-info-bar {
  grid-template-columns: minmax(150px, 0.8fr) minmax(190px, 1fr) minmax(240px, 1.25fr) minmax(210px, 1.05fr) minmax(132px, 0.6fr);
  gap: 0;
  align-items: stretch;
  border-top: 1px solid rgba(207, 226, 232, 0.16);
  background: rgba(4, 11, 16, 0.82);
}

.info-box,
.tool-box {
  min-height: clamp(78px, 7.2vw, 104px);
  border: 0;
  border-right: 1px solid rgba(207, 226, 232, 0.13);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.info-box {
  padding: clamp(12px, 1.3vw, 22px) clamp(18px, 2vw, 34px);
}

.tool-box {
  padding-inline: clamp(12px, 1vw, 18px);
  justify-content: center;
  background: linear-gradient(180deg, rgba(12, 28, 36, 0.6), rgba(5, 12, 18, 0.72));
}

.info-label {
  color: var(--display-muted);
  font-size: clamp(13px, 1.05vw, 16px);
  font-weight: 700;
}

.info-value,
.grade-select {
  color: var(--display-text);
  font-size: clamp(24px, 2.1vw, 34px);
  font-weight: 850;
}

.info-value.remain {
  color: var(--display-cyan);
}

.grade-select {
  padding: 0;
  border: 0;
  background: transparent;
}

.round-tool-button,
.more-button {
  border-radius: 4px;
  border-color: rgba(68, 231, 221, 0.26);
  background: rgba(68, 231, 221, 0.08);
  color: #dffbf8;
}

.round-tool-button {
  width: 54px;
  height: 54px;
}

.more-widget {
  right: clamp(18px, 2vw, 32px);
  bottom: clamp(118px, 10vw, 136px);
}

.more-button {
  min-width: 72px;
  min-height: 44px;
  border-radius: 999px;
  backdrop-filter: blur(10px);
}

.more-menu {
  border-radius: 6px;
  border-color: rgba(68, 231, 221, 0.24);
  background: rgba(5, 13, 19, 0.96);
}

.admin-body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(245, 249, 252, 0.96)),
    radial-gradient(circle at 0% 0%, rgba(17, 154, 162, 0.12), transparent 32%),
    radial-gradient(circle at 100% 0%, rgba(37, 111, 159, 0.1), transparent 34%),
    var(--admin-bg);
}

.admin-shell {
  width: min(1500px, calc(100% - 40px));
  padding-top: 22px;
}

.admin-header {
  min-height: 118px;
  align-items: center;
  padding: 18px 22px;
  border-radius: 8px;
  border: 1px solid var(--admin-line);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 18px 48px rgba(18, 38, 63, 0.07);
}

.brand-logo {
  width: min(386px, 32vw);
  height: 76px;
  border-radius: 8px;
  object-fit: cover;
  background: #f8fbfd;
}

.admin-header h1 {
  color: var(--admin-text);
  font-size: clamp(30px, 3.3vw, 44px);
  line-height: 1.08;
}

.admin-header p {
  max-width: 760px;
  color: var(--admin-muted);
  font-size: 15px;
}

.login-panel {
  min-height: calc(100vh - 220px);
  align-items: start;
  padding-top: clamp(18px, 3vw, 44px);
}

.auth-card {
  width: min(460px, 100%);
  gap: 18px;
  padding: 30px;
  border-radius: 8px;
}

.auth-card h2 {
  font-size: 26px;
}

.login-tabs {
  border-radius: 8px;
  background: #eef6f8;
}

.login-tab.active {
  color: var(--admin-cyan);
}

.admin-workspace {
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 18px;
}

.tenant-info-panel,
.auth-card,
.grade-list-panel,
.subject-bank-panel,
.editor-panel,
.modal-card {
  border-radius: 8px;
  border: 1px solid var(--admin-line);
  background: var(--admin-panel);
  box-shadow: 0 18px 46px rgba(18, 38, 63, 0.075);
}

.tenant-info-panel {
  padding: 20px 22px;
  border-left: 5px solid var(--admin-cyan);
}

.grade-list-panel,
.subject-bank-panel,
.editor-panel {
  padding: 18px;
}

.editor-heading {
  padding-bottom: 14px;
  border-left: 0;
  border-bottom: 1px solid var(--admin-line);
}

.admin-shell input,
.admin-shell select,
.admin-shell textarea {
  min-height: 44px;
  border-radius: 6px;
  border-color: #d8e6ed;
  background: #fbfdff;
}

.primary-button,
.secondary-button,
.danger-button,
.display-link {
  min-height: 40px;
  border-radius: 6px;
  font-weight: 800;
}

.primary-button {
  background: linear-gradient(180deg, #1caeb5, #119aa2);
  border-color: #119aa2;
  box-shadow: 0 10px 22px rgba(17, 154, 162, 0.22);
}

.admin-body .secondary-button,
.admin-body .display-link {
  background: #f8fbfd;
  color: #27445d;
}

.filter-panel {
  border-radius: 8px;
  background: #f8fbfd;
}

.tenant-table {
  gap: 0;
  overflow: hidden;
  border: 1px solid var(--admin-line);
  border-radius: 8px;
  background: #fff;
}

.tenant-row {
  grid-template-columns: minmax(260px, 1fr) minmax(320px, 1.1fr) minmax(360px, auto);
  gap: 14px;
  align-items: center;
  padding: 16px 18px;
  border: 0;
  border-bottom: 1px solid #e7eef3;
  border-radius: 0;
  box-shadow: none;
}

.tenant-row:last-child {
  border-bottom: 0;
}

.tenant-row strong {
  display: inline-flex;
  align-items: center;
  margin-right: 10px;
  font-size: 18px;
}

.tenant-row p {
  margin-top: 6px;
}

.tenant-actions {
  justify-content: flex-end;
}

.exam-setting-row,
.subject-item,
.grade-item,
.current-message {
  border-radius: 8px;
  border-color: var(--admin-line);
}

.exam-setting-row {
  padding: 16px;
}

.setting-status {
  border-radius: 6px;
}

@media (max-width: 980px) {
  .bottom-info-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 10px;
    border-top: 0;
    background: transparent;
  }

  .info-box,
  .tool-box {
    border: 1px solid var(--display-line);
    border-radius: 8px;
    background: var(--display-panel);
  }

  .tool-box {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .admin-workspace {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .display-shell {
    padding: 14px;
  }

  .display-shell::before {
    display: none;
  }

  .display-top-bar {
    grid-template-columns: minmax(0, 1.75fr) minmax(120px, 0.9fr);
  }

  .display-top-bar .tenant-name,
  .message-strip {
    min-height: 76px;
    padding-inline: 14px;
    font-size: 22px;
  }

  .message-strip {
    line-height: 1.15;
  }

  .display-top-bar .tenant-name::before,
  .message-strip::before {
    margin-right: 10px;
  }

  .exam-stage {
    border: 0;
    background: transparent;
    overflow: visible;
  }

  .clock-stage {
    padding: 12px 4px 14px;
  }

  .date-row {
    gap: 10px;
  }

  .time-text {
    margin-top: 30px;
    transform: none;
  }

  #timeMain {
    font-size: clamp(64px, 19.5vw, 96px);
  }

  #timeSeconds {
    font-size: clamp(34px, 10vw, 52px);
  }

  .slogan {
    margin-top: 14px;
    font-size: clamp(32px, 9.5vw, 44px);
    line-height: 1.1;
  }

  .more-widget {
    bottom: 96px;
  }

  .admin-shell {
    width: min(100% - 24px, 1500px);
  }

  .admin-header {
    min-height: auto;
    align-items: stretch;
  }

  .brand-logo {
    width: min(100%, 320px);
    height: 62px;
  }

  .tenant-row {
    grid-template-columns: 1fr;
  }
}

/* Display redesign from 2026-06-16 reference image. */
.display-top-bar {
  grid-template-columns: minmax(250px, 0.78fr) minmax(0, 3.4fr);
}

.display-top-bar .tenant-name {
  min-height: clamp(76px, 7.4vw, 126px);
  padding: clamp(10px, 1vw, 16px) clamp(14px, 1.45vw, 24px);
  border-color: rgba(0, 220, 235, 0.45);
  border-radius: 10px;
  font-size: clamp(30px, 2.65vw, 44px);
  letter-spacing: 0;
  white-space: normal;
  overflow: hidden;
  text-overflow: clip;
  line-height: 1.12;
  text-align: center;
  word-break: keep-all;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.display-top-bar .tenant-name::before {
  display: none;
}

.message-strip {
  min-height: clamp(76px, 7.4vw, 126px);
  justify-content: flex-start;
  gap: clamp(18px, 2vw, 30px);
  padding: clamp(12px, 1vw, 18px) clamp(26px, 3vw, 50px);
  border-color: rgba(125, 163, 176, 0.28);
  border-radius: 10px;
  text-align: left;
  background: linear-gradient(145deg, rgba(8, 18, 25, 0.96), rgba(2, 8, 12, 0.94));
}

.message-strip::before {
  display: none;
}

.notice-icon {
  width: clamp(78px, 5.8vw, 100px);
  height: clamp(78px, 5.8vw, 100px);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 0;
  background: transparent;
  color: #00e5f0;
}

.notice-icon svg,
.info-icon {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.notice-icon svg {
  width: 66%;
  height: 66%;
  filter: drop-shadow(0 0 16px rgba(0, 220, 235, 0.26));
}

.message-content {
  min-width: 0;
  display: grid;
  align-content: center;
  overflow: hidden;
}

.message-strip.scrolling .notice-icon,
.message-strip.scrolling .message-content {
  min-width: 0;
  max-width: none;
  padding-left: 0;
  white-space: normal;
  animation: none;
}

.message-label {
  display: none;
}

#messageText {
  display: block;
  color: #f8fbfb;
  font-size: clamp(26px, 2.6vw, 46px);
  font-weight: 850;
  line-height: 1.1;
}

.message-strip.empty #messageText {
  color: #f8fbfb;
}

.message-strip.scrolling #messageText {
  width: max-content;
}

.exam-stage {
  border-color: rgba(125, 163, 176, 0.22);
  border-radius: 10px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  min-height: 0;
  overflow: hidden;
}

.clock-stage {
  position: relative;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  min-height: 0;
  padding: clamp(28px, 2.6vw, 48px) clamp(38px, 3.6vw, 64px) clamp(18px, 1.6vw, 28px);
}

.date-row {
  align-items: flex-start;
}

.date-row > span:first-child {
  color: #f5f7f6;
  font-size: clamp(26px, 2.35vw, 44px);
  font-weight: 520;
  text-shadow: 0 0 16px rgba(255, 255, 255, 0.08);
}

.status-pill {
  position: absolute;
  top: clamp(30px, 2.6vw, 48px);
  right: clamp(30px, 3vw, 56px);
  min-height: clamp(50px, 4.2vw, 66px);
  padding: 8px clamp(24px, 2.3vw, 38px);
  border-radius: 999px;
  border-color: rgba(0, 220, 235, 0.5);
  background: rgba(0, 40, 48, 0.58);
  color: #00e5f0;
  font-size: clamp(22px, 2vw, 36px);
  font-weight: 850;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.status-pill::before {
  content: "";
  width: 18px;
  height: 18px;
  margin-right: 16px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 18px currentColor;
}

.status-pill.ended {
  border-color: rgba(245, 123, 98, 0.48);
  background: rgba(96, 38, 40, 0.5);
  color: #ffb09e;
}

.time-text {
  justify-content: center;
  align-self: center;
  margin-top: clamp(8px, 1vw, 18px);
}

#timeMain {
  font-size: clamp(164px, 18vw, 320px);
  color: #f7f8f4;
  font-weight: 760;
  text-shadow:
    0 8px 18px rgba(255, 255, 255, 0.06),
    0 24px 54px rgba(0, 0, 0, 0.35);
}

#timeSeconds {
  margin-left: clamp(8px, 1vw, 16px);
  color: rgba(255, 255, 255, 0.78);
  font-size: clamp(82px, 7.8vw, 140px);
  font-weight: 760;
  text-shadow: none;
}

.slogan {
  position: relative;
  width: min(760px, 58vw);
  min-height: clamp(66px, 5.8vw, 96px);
  display: grid;
  place-items: center;
  margin: clamp(10px, 1.1vw, 18px) auto 0;
  padding: 10px clamp(44px, 4vw, 72px);
  border: 0;
  white-space: nowrap;
  background:
    linear-gradient(135deg, transparent 0 38px, rgba(0, 220, 235, 0.78) 38px 39px, transparent 39px) left top / 50% 50% no-repeat,
    linear-gradient(45deg, transparent 0 38px, rgba(0, 220, 235, 0.78) 38px 39px, transparent 39px) left bottom / 50% 50% no-repeat,
    linear-gradient(225deg, transparent 0 38px, rgba(0, 220, 235, 0.78) 38px 39px, transparent 39px) right top / 50% 50% no-repeat,
    linear-gradient(315deg, transparent 0 38px, rgba(0, 220, 235, 0.78) 38px 39px, transparent 39px) right bottom / 50% 50% no-repeat,
    linear-gradient(90deg, rgba(0, 220, 235, 0.78), rgba(0, 220, 235, 0.78)) center top / calc(100% - 72px) 1px no-repeat,
    linear-gradient(90deg, rgba(0, 220, 235, 0.78), rgba(0, 220, 235, 0.78)) center bottom / calc(100% - 72px) 1px no-repeat,
    linear-gradient(180deg, rgba(0, 34, 43, 0.82), rgba(0, 10, 16, 0.9));
  color: #00e5f0;
  font-size: clamp(31px, 2.95vw, 54px);
  letter-spacing: 0.12em;
  text-indent: 0.12em;
  text-shadow: 0 0 26px rgba(0, 220, 235, 0.25);
  box-shadow: inset 0 0 28px rgba(0, 220, 235, 0.08);
}

.slogan::before,
.slogan::after {
  content: "";
  position: absolute;
  top: 50%;
  width: min(25vw, 420px);
  height: 10px;
  transform: translateY(-50%);
  background:
    radial-gradient(circle at 100% 50%, rgba(0, 220, 235, 0.95) 0 4px, transparent 4.5px),
    linear-gradient(90deg, transparent, rgba(0, 220, 235, 0.72) 72%, rgba(0, 220, 235, 0.72)) center / 100% 1px no-repeat;
}

.slogan::before {
  right: calc(100% + 20px);
}

.slogan::after {
  left: calc(100% + 20px);
  transform: translateY(-50%) scaleX(-1);
}

.slogan .slogan-dot {
  display: none;
}

.slogan::selection {
  background: rgba(0, 220, 235, 0.18);
}

.bottom-info-bar {
  margin: 0 clamp(20px, 1.9vw, 36px) clamp(16px, 1.55vw, 26px);
  grid-template-columns: minmax(150px, 0.82fr) minmax(160px, 0.86fr) minmax(225px, 1.12fr) minmax(252px, 1.16fr) minmax(278px, 1.22fr);
  border: 1px solid rgba(125, 163, 176, 0.26);
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(12, 25, 33, 0.94), rgba(3, 8, 12, 0.94)),
    rgba(3, 8, 12, 0.92);
  overflow: visible;
}

.info-box,
.tool-box {
  min-height: clamp(92px, 7.5vw, 118px);
  border-right: 1px solid rgba(125, 163, 176, 0.22);
}

.info-box {
  align-content: center;
  gap: clamp(9px, 0.8vw, 14px);
  padding: clamp(13px, 1.1vw, 20px) clamp(18px, 1.45vw, 28px);
}

.info-label {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: #00e5f0;
  font-size: clamp(15px, 1.18vw, 22px);
  font-weight: 760;
}

.info-icon {
  width: 1.35em;
  height: 1.35em;
}

.info-value,
.grade-select {
  color: #f7f8f4;
  font-size: clamp(27px, 2.15vw, 40px);
  font-weight: 650;
}

.info-value.small {
  font-size: clamp(24px, 1.9vw, 35px);
}

.info-value.remain {
  color: #00e5f0;
  font-size: clamp(32px, 2.5vw, 47px);
}

.tool-box {
  display: grid;
  grid-template-columns: repeat(3, minmax(76px, 1fr));
  gap: 8px;
  padding: clamp(8px, 0.8vw, 14px);
}

.round-tool-button,
.more-button {
  width: 100%;
  height: 100%;
  min-height: 76px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 8px;
  border-radius: 8px;
  border-color: rgba(125, 163, 176, 0.24);
  background: linear-gradient(180deg, rgba(17, 32, 42, 0.92), rgba(7, 14, 20, 0.92));
  color: #00e5f0;
}

.round-tool-button.voice-off {
  border-color: rgba(125, 163, 176, 0.22);
  color: rgba(116, 205, 213, 0.72);
  background: linear-gradient(180deg, rgba(17, 29, 37, 0.82), rgba(7, 13, 18, 0.9));
}

.round-tool-button.voice-off .tool-label {
  color: rgba(218, 232, 234, 0.78);
}

.round-tool-button.voice-on {
  border-color: rgba(0, 220, 235, 0.58);
  color: #00e5f0;
  background:
    radial-gradient(circle at 50% 18%, rgba(0, 220, 235, 0.22), transparent 62%),
    linear-gradient(180deg, rgba(0, 42, 52, 0.94), rgba(7, 16, 21, 0.96));
  box-shadow: inset 0 0 0 1px rgba(0, 220, 235, 0.12), 0 0 22px rgba(0, 220, 235, 0.1);
}

.round-tool-button.voice-on .tool-label {
  color: #f7ffff;
}

.round-tool-button .button-icon {
  width: clamp(29px, 2.25vw, 43px);
  height: clamp(29px, 2.25vw, 43px);
}

.tool-label {
  color: #f7f8f4;
  font-size: clamp(14px, 1.05vw, 20px);
  font-weight: 560;
  line-height: 1;
}

.more-widget {
  position: relative;
  inset: auto;
  z-index: 5;
  display: grid;
  align-self: stretch;
  min-height: 76px;
}

.more-widget > .more-button {
  min-height: inherit;
}

.more-menu {
  position: absolute;
  right: 0;
  bottom: calc(100% + 12px);
  width: min(340px, 70vw);
}

@media (max-width: 1180px) {
  .display-top-bar {
    grid-template-columns: minmax(220px, 0.9fr) minmax(0, 2fr);
  }

  .display-top-bar .tenant-name {
    grid-template-columns: 1fr;
    justify-items: center;
    align-content: center;
  }

  .bottom-info-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 10px;
    border: 0;
    background: transparent;
  }

  .info-box,
  .tool-box {
    min-height: 102px;
    border: 1px solid rgba(0, 220, 235, 0.2);
    border-radius: 8px;
    background: rgba(9, 20, 27, 0.9);
  }

  .tool-box {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .display-top-bar {
    grid-template-columns: minmax(0, 1.45fr) minmax(126px, 0.9fr);
  }

  .display-top-bar .tenant-name {
    grid-template-columns: 1fr;
    justify-items: center;
    align-content: center;
  }

  .display-top-bar .tenant-name,
  .message-strip {
    min-height: 76px;
    padding-inline: 10px;
    border-radius: 7px;
  }

  .display-top-bar .tenant-name {
    font-size: 25px;
    text-align: center;
  }

  .display-top-bar .tenant-name.tenant-long {
    font-size: 16px;
  }

  .display-top-bar .tenant-name.tenant-extra-long {
    font-size: 14px;
  }

  .message-strip {
    gap: 9px;
  }

  .notice-icon {
    width: 34px;
    height: 34px;
  }

  .message-label {
    font-size: 16px;
  }

  #messageText {
    font-size: 22px;
    line-height: 1.08;
  }

  .clock-stage {
    padding-top: 18px;
  }

  .date-row > span:first-child {
    font-size: 20px;
  }

  .status-pill {
    position: static;
    width: fit-content;
    min-height: 36px;
    padding: 6px 13px;
    font-size: 16px;
  }

  .status-pill::before {
    width: 10px;
    height: 10px;
    margin-right: 8px;
  }

  .time-text {
    margin-top: 30px;
  }

  #timeMain {
    font-size: clamp(72px, 21vw, 96px);
  }

  #timeSeconds {
    font-size: clamp(36px, 10vw, 50px);
  }

  .slogan {
    width: min(100%, 340px);
    min-height: 58px;
    margin-top: 18px;
    font-size: clamp(28px, 8.7vw, 38px);
    letter-spacing: 0.1em;
    text-indent: 0.1em;
  }

  .slogan::before,
  .slogan::after {
    display: none;
  }

  .bottom-info-bar {
    margin: 0;
  }

  .info-box,
  .tool-box {
    min-height: 88px;
  }

  .info-label {
    gap: 9px;
    font-size: 14px;
  }

  .info-value,
  .grade-select {
    font-size: 25px;
  }

  .info-value.small {
    font-size: 21px;
  }

  .info-value.remain {
    font-size: 25px;
  }

  .tool-box {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .round-tool-button,
  .more-button {
    min-height: 72px;
    gap: 7px;
  }

  .round-tool-button .button-icon {
    width: 30px;
    height: 30px;
  }

  .tool-label {
    font-size: 14px;
  }
}

/* Command-screen final pass, 2026-06-16. */
.display-body {
  --command-bg: #02070a;
  --command-panel: rgba(5, 16, 22, 0.9);
  --command-panel-strong: rgba(7, 22, 30, 0.94);
  --command-line: rgba(0, 221, 235, 0.36);
  --command-line-soft: rgba(122, 164, 176, 0.22);
  --command-cyan: #00e7f2;
  --command-cyan-soft: rgba(0, 231, 242, 0.14);
  --command-text: #f6faf9;
  --command-muted: rgba(223, 235, 236, 0.72);
  background:
    radial-gradient(circle at 50% 48%, rgba(0, 58, 70, 0.26), transparent 48%),
    linear-gradient(180deg, #041015 0%, var(--command-bg) 72%);
}

.display-shell {
  width: 100%;
  min-height: 100vh;
  padding: clamp(12px, 1.25vw, 20px);
  gap: clamp(12px, 1.15vw, 18px);
  background:
    linear-gradient(rgba(0, 231, 242, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 231, 242, 0.02) 1px, transparent 1px);
  background-size: 48px 48px;
}

.display-top-bar {
  grid-template-columns: minmax(250px, 0.76fr) minmax(0, 3.45fr);
  gap: clamp(14px, 1.35vw, 22px);
}

.display-top-bar .tenant-name,
.message-strip,
.exam-stage,
.bottom-info-bar {
  border: 1px solid var(--command-line-soft);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 36%),
    linear-gradient(135deg, rgba(0, 231, 242, 0.055), transparent 42%),
    var(--command-panel);
  box-shadow:
    inset 0 0 0 1px rgba(0, 231, 242, 0.035),
    inset 0 0 30px rgba(0, 0, 0, 0.34);
}

.display-top-bar .tenant-name {
  min-height: clamp(86px, 7.2vw, 120px);
  display: grid;
  place-items: center;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding: clamp(10px, 0.85vw, 14px) clamp(16px, 1.15vw, 22px);
  border-color: rgba(0, 231, 242, 0.42);
  color: var(--command-text);
  font-family: "Microsoft YaHei UI", "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  font-size: clamp(21px, 1.55vw, 29px);
  font-weight: 650;
  line-height: 1.12;
  text-align: center;
  white-space: normal;
  overflow: hidden;
  word-break: normal;
  overflow-wrap: anywhere;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.06);
}

.display-top-bar .tenant-name.tenant-one-line {
  white-space: nowrap;
  overflow-wrap: normal;
  line-height: 1;
  letter-spacing: 0.02em;
}

.display-top-bar .tenant-name.tenant-long {
  font-size: clamp(18px, 1.35vw, 24px);
  line-height: 1.1;
}

.display-top-bar .tenant-name.tenant-extra-long {
  font-size: clamp(16px, 1.15vw, 21px);
  line-height: 1.06;
}

.message-strip {
  min-height: clamp(86px, 7.2vw, 120px);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  column-gap: clamp(14px, 1.35vw, 22px);
  padding: clamp(14px, 1.1vw, 18px) clamp(24px, 2.2vw, 38px);
  border-color: var(--command-line-soft);
}

.notice-icon {
  width: clamp(82px, 5.6vw, 96px);
  height: clamp(82px, 5.6vw, 96px);
  display: grid;
  place-items: center;
  align-self: center;
  justify-self: start;
  color: var(--command-cyan);
  opacity: 0.96;
  transform: translate(-20px, 8px);
  padding: 0;
  border: 0;
  background: transparent;
  appearance: none;
  cursor: default;
}

.notice-icon svg {
  width: 68%;
  height: 68%;
  stroke-width: 1.75;
  filter: drop-shadow(0 0 15px rgba(0, 231, 242, 0.28));
  transform-origin: 50% 12%;
}

.notice-icon.is-ringing {
  cursor: pointer;
}

.notice-icon.is-ringing svg {
  animation: notice-bell-ring 1.05s ease-in-out infinite;
}

.notice-icon:focus-visible {
  outline: 2px solid rgba(0, 231, 242, 0.72);
  outline-offset: -8px;
  border-radius: 10px;
}

@keyframes notice-bell-ring {
  0%,
  58%,
  100% {
    transform: rotate(0deg);
  }
  10% {
    transform: rotate(-12deg);
  }
  20% {
    transform: rotate(10deg);
  }
  30% {
    transform: rotate(-8deg);
  }
  40% {
    transform: rotate(6deg);
  }
  50% {
    transform: rotate(-3deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .notice-icon.is-ringing svg {
    animation: none;
  }
}

#messageText {
  color: var(--command-text);
  font-size: clamp(29px, 2.45vw, 42px);
  font-weight: 780;
  line-height: 1.12;
  letter-spacing: 0;
  white-space: nowrap;
  align-self: center;
}

.message-strip.scrolling #messageText {
  width: max-content;
  min-width: max-content;
  max-width: none;
  padding-left: 100%;
  animation: message-scroll var(--message-scroll-duration, 28s) linear infinite;
}

.message-strip.empty #messageText {
  color: var(--command-text);
  opacity: 0.95;
}

.network-warning {
  border-radius: 6px;
  border-color: rgba(255, 179, 104, 0.44);
  background: rgba(72, 43, 18, 0.72);
}

.exam-stage {
  position: relative;
  grid-template-rows: minmax(0, 1fr) auto;
  overflow: hidden;
  border-color: rgba(122, 164, 176, 0.2);
  background:
    radial-gradient(circle at 50% 42%, rgba(0, 56, 66, 0.28), transparent 46%),
    linear-gradient(180deg, rgba(6, 18, 24, 0.96), rgba(2, 8, 12, 0.98));
}

.exam-stage::before {
  content: "";
  position: absolute;
  inset: 12px;
  pointer-events: none;
  border: 1px solid rgba(0, 231, 242, 0.045);
}

.clock-stage {
  position: relative;
  z-index: 1;
  grid-template-rows: auto minmax(0, 1fr) auto;
  padding: clamp(32px, 2.9vw, 50px) clamp(42px, 3.8vw, 66px) clamp(20px, 1.8vw, 32px);
}

.date-row > span:first-child {
  position: relative;
  left: -10px;
  top: -8px;
  color: rgba(246, 250, 249, 0.92);
  font-size: clamp(27px, 2.18vw, 40px);
  font-weight: 520;
}

.status-pill {
  top: clamp(30px, 2.8vw, 50px);
  right: clamp(30px, 3.2vw, 58px);
  min-height: clamp(46px, 3.8vw, 60px);
  padding: 8px clamp(24px, 2.2vw, 36px);
  border-color: rgba(0, 231, 242, 0.5);
  background: linear-gradient(180deg, rgba(0, 54, 63, 0.78), rgba(0, 25, 32, 0.82));
  color: var(--command-cyan);
  font-size: clamp(21px, 1.78vw, 32px);
  box-shadow: inset 0 0 0 1px rgba(0, 231, 242, 0.08), 0 0 28px rgba(0, 231, 242, 0.06);
}

.status-pill::before {
  width: 14px;
  height: 14px;
  margin-right: 14px;
}

.status-pill.ended {
  border-color: rgba(255, 153, 132, 0.5);
  background: linear-gradient(180deg, rgba(87, 39, 42, 0.82), rgba(42, 18, 20, 0.82));
  color: #ffad9d;
}

.time-text {
  align-self: center;
  justify-content: center;
  margin-top: clamp(4px, 0.7vw, 12px);
}

#timeMain {
  color: #f8faf6;
  font-size: clamp(172px, 18.3vw, 326px);
  font-weight: 780;
  line-height: 0.9;
  letter-spacing: 0;
  text-shadow:
    0 8px 16px rgba(255, 255, 255, 0.06),
    0 24px 58px rgba(0, 0, 0, 0.5);
}

#timeSeconds {
  margin-left: clamp(8px, 1vw, 16px);
  color: rgba(238, 242, 240, 0.72);
  font-size: clamp(78px, 7.4vw, 134px);
  font-weight: 760;
  line-height: 0.94;
}

.slogan {
  width: min(820px, 62vw);
  min-height: clamp(78px, 6.2vw, 100px);
  margin-top: clamp(8px, 0.9vw, 16px);
  padding: 14px clamp(72px, 5.4vw, 104px);
  border: 0;
  color: var(--command-cyan);
  font-size: clamp(34px, 3.15vw, 58px);
  font-weight: 850;
  letter-spacing: 0.2em;
  text-indent: 0.2em;
  background: transparent;
  box-shadow: none;
  text-shadow: none;
}

.slogan::before,
.slogan::after {
  display: none;
}

.slogan::before {
  right: calc(100% + 18px);
}

.slogan::after {
  left: calc(100% + 18px);
}

.bottom-info-bar {
  position: relative;
  z-index: 1;
  margin: 0 clamp(20px, 2vw, 38px) clamp(18px, 1.7vw, 30px);
  grid-template-columns: minmax(145px, 0.8fr) minmax(160px, 0.86fr) minmax(230px, 1.12fr) minmax(250px, 1.14fr) minmax(270px, 1.18fr);
  border-color: rgba(122, 164, 176, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(10, 24, 31, 0.92), rgba(4, 11, 15, 0.96)),
    var(--command-panel-strong);
  box-shadow: inset 0 0 0 1px rgba(0, 231, 242, 0.035);
}

.info-box,
.tool-box {
  min-height: clamp(86px, 6.8vw, 110px);
  border-right-color: rgba(122, 164, 176, 0.2);
}

.info-box {
  gap: clamp(8px, 0.68vw, 12px);
  padding: clamp(12px, 0.95vw, 17px) clamp(17px, 1.35vw, 25px);
}

.info-label {
  gap: 12px;
  color: var(--command-cyan);
  font-size: clamp(14px, 1.06vw, 19px);
  font-weight: 760;
}

.info-icon {
  width: 1.22em;
  height: 1.22em;
  stroke-width: 1.9;
}

.info-value,
.grade-select {
  color: var(--command-text);
  font-size: clamp(26px, 2.04vw, 37px);
  font-weight: 720;
}

.grade-select {
  padding-right: 28px;
}

.info-value.small {
  font-size: clamp(23px, 1.75vw, 32px);
  white-space: nowrap;
}

.info-value.remain {
  color: var(--command-cyan);
  font-size: clamp(31px, 2.35vw, 43px);
  letter-spacing: 0.02em;
}

.tool-box {
  grid-template-columns: repeat(3, minmax(72px, 1fr));
  gap: 8px;
  padding: clamp(7px, 0.7vw, 12px);
}

.round-tool-button,
.more-button {
  min-height: 70px;
  gap: 7px;
  border-radius: 7px;
  border-color: rgba(122, 164, 176, 0.24);
  background: linear-gradient(180deg, rgba(13, 28, 36, 0.9), rgba(6, 13, 18, 0.94));
  color: var(--command-cyan);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.015);
}

.round-tool-button .button-icon {
  width: clamp(27px, 2.05vw, 38px);
  height: clamp(27px, 2.05vw, 38px);
  stroke-width: 1.8;
}

.tool-label {
  color: var(--command-text);
  font-size: clamp(13px, 0.96vw, 18px);
  font-weight: 620;
}

.round-tool-button.voice-off {
  border-color: rgba(122, 164, 176, 0.2);
  color: rgba(116, 205, 213, 0.66);
  background: linear-gradient(180deg, rgba(13, 25, 32, 0.74), rgba(6, 12, 16, 0.92));
}

.round-tool-button.voice-off .tool-label {
  color: rgba(218, 232, 234, 0.7);
}

.round-tool-button.voice-on {
  border-color: rgba(0, 231, 242, 0.58);
  color: var(--command-cyan);
  background:
    radial-gradient(circle at 50% 12%, rgba(0, 231, 242, 0.24), transparent 58%),
    linear-gradient(180deg, rgba(0, 45, 54, 0.95), rgba(5, 16, 21, 0.98));
  box-shadow: inset 0 0 0 1px rgba(0, 231, 242, 0.11), 0 0 18px rgba(0, 231, 242, 0.1);
}

.round-tool-button:hover,
.more-button:hover {
  border-color: rgba(0, 231, 242, 0.52);
  transform: translateY(-1px);
}

.more-menu {
  border-radius: 8px;
  border-color: rgba(0, 231, 242, 0.34);
  background: rgba(4, 14, 19, 0.96);
}

@media (max-width: 1180px) {
  .bottom-info-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
    padding: 9px;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .info-box,
  .tool-box {
    border: 1px solid rgba(0, 231, 242, 0.2);
    border-radius: 8px;
    background: rgba(7, 19, 25, 0.92);
  }

  .tool-box {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .display-shell {
    padding: 12px;
  }

  .display-top-bar {
    grid-template-columns: minmax(0, 1.38fr) minmax(128px, 0.88fr);
  }

  .display-top-bar .tenant-name,
  .message-strip {
    min-height: 82px;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 10px;
    padding-inline: 11px;
  }

  .display-top-bar .tenant-name {
    grid-template-columns: 1fr;
    justify-items: center;
    align-content: center;
    text-align: center;
  }

  .display-top-bar .tenant-name {
    font-size: 20px;
  }

  .display-top-bar .tenant-name.tenant-one-line {
    font-size: 18px;
  }

  .display-top-bar .tenant-name.tenant-long {
    font-size: 16px;
  }

  .display-top-bar .tenant-name.tenant-extra-long {
    font-size: 14px;
  }

  .notice-icon {
    width: 34px;
    height: 34px;
    transform: translate(-10px, 5px);
  }

  #messageText {
    font-size: 21px;
  }

  .clock-stage {
    padding: 18px 20px 16px;
  }

  .status-pill {
    position: static;
    width: fit-content;
    min-height: 36px;
    padding: 6px 13px;
    font-size: 16px;
  }

  #timeMain {
    font-size: clamp(74px, 21vw, 96px);
  }

  #timeSeconds {
    font-size: clamp(36px, 10vw, 50px);
  }

  .slogan {
    width: min(100%, 340px);
    min-height: 58px;
    padding-inline: 40px;
    font-size: clamp(26px, 8vw, 36px);
    letter-spacing: 0.06em;
    text-indent: 0.06em;
    white-space: nowrap;
  }

  .slogan::before,
  .slogan::after {
    display: none;
  }

  .bottom-info-bar {
    margin: 0;
  }

  .info-box,
  .tool-box {
    min-height: 82px;
  }
}

/* Scholarly admin refresh, 2026-06-17. */
.admin-body {
  --admin-paper: rgba(255, 253, 248, 0.94);
  --admin-paper-strong: #fffdf9;
  --admin-line: rgba(30, 61, 118, 0.12);
  --admin-line-strong: rgba(18, 78, 100, 0.22);
  --admin-ink: #173056;
  --admin-muted: #66758b;
  --admin-accent: #0f8a83;
  --admin-accent-strong: #0d5d8c;
  --admin-warm: #b88a45;
  --admin-soft: #f6f0e3;
  background:
    radial-gradient(circle at top left, rgba(24, 95, 128, 0.08), transparent 28%),
    radial-gradient(circle at top right, rgba(184, 138, 69, 0.1), transparent 24%),
    linear-gradient(180deg, #f8f4ea 0%, #f5f7fb 40%, #f3f6fa 100%);
  color: var(--admin-ink);
}

.scholarly-shell {
  width: min(1520px, calc(100% - 40px));
  padding: 24px 0 40px;
}

.scholarly-masthead,
.tenant-hero-panel,
.grade-list-panel,
.subject-bank-panel,
.editor-panel,
.auth-card,
.modal-card {
  border: 1px solid var(--admin-line);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 251, 244, 0.94)),
    var(--admin-paper);
  box-shadow:
    0 24px 50px rgba(35, 53, 82, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.scholarly-masthead {
  position: relative;
  overflow: hidden;
  align-items: center;
  gap: 28px;
  padding: 26px 30px;
  margin-bottom: 22px;
}

.scholarly-masthead::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 110px;
  background:
    linear-gradient(180deg, transparent, rgba(20, 56, 96, 0.05)),
    radial-gradient(circle at 78% 22%, rgba(18, 95, 120, 0.18), transparent 30%);
  pointer-events: none;
}

.brand-heading {
  position: relative;
  z-index: 1;
  align-items: flex-start;
  gap: 22px;
}

.brand-logo {
  width: min(380px, 32vw);
  height: 92px;
  padding: 10px 18px;
  border-radius: 18px;
  border: 1px solid rgba(18, 95, 120, 0.12);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 16px 34px rgba(35, 53, 82, 0.08);
}

.brand-copy {
  display: grid;
  gap: 8px;
  max-width: 700px;
  padding-top: 2px;
}

.brand-tagline {
  margin: 0;
  color: var(--admin-warm);
  font-size: 13px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.admin-header h1 {
  margin: 0;
  color: var(--admin-ink);
  font-size: clamp(34px, 4.2vw, 50px);
  letter-spacing: 0.02em;
}

.admin-header p {
  margin: 0;
  color: var(--admin-muted);
  font-size: 16px;
  line-height: 1.7;
}

.panel-eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(15, 138, 131, 0.09);
  color: var(--admin-accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.login-panel {
  min-height: 58vh;
}

.auth-card {
  width: min(460px, 100%);
  gap: 22px;
  padding: 34px 32px;
}

.auth-card h2 {
  color: var(--admin-ink);
  font-size: 34px;
}

.login-tabs {
  padding: 5px;
  border-radius: 16px;
  background: rgba(15, 138, 131, 0.06);
  border-color: rgba(15, 138, 131, 0.12);
}

.login-tab {
  min-height: 46px;
  border-radius: 12px;
  color: var(--admin-muted);
}

.login-tab.active {
  color: var(--admin-accent);
  box-shadow: 0 12px 24px rgba(37, 59, 95, 0.08);
}

.auth-card label,
.form-grid label,
.exam-setting-row label,
.inline-form label,
.filter-panel label {
  gap: 10px;
  color: var(--admin-muted);
  font-size: 14px;
  font-weight: 600;
}

.admin-body .admin-shell input,
.admin-body .admin-shell select,
.admin-body .admin-shell textarea,
.modal-dialog input,
.modal-dialog select,
.modal-dialog textarea {
  min-height: 52px;
  border-radius: 14px;
  border-color: rgba(20, 56, 96, 0.12);
  background: rgba(255, 255, 255, 0.98);
  color: var(--admin-ink);
  box-shadow: inset 0 1px 2px rgba(18, 36, 64, 0.03);
}

.admin-body .admin-shell textarea,
.modal-dialog textarea {
  min-height: auto;
}

.select-group select:focus,
.admin-shell input:focus,
.admin-shell select:focus,
.admin-shell textarea:focus,
.modal-dialog input:focus,
.modal-dialog select:focus,
.modal-dialog textarea:focus {
  border-color: rgba(15, 138, 131, 0.5);
  box-shadow: 0 0 0 4px rgba(15, 138, 131, 0.12);
}

.primary-button,
.secondary-button,
.danger-button,
.display-link {
  min-height: 46px;
  padding: 11px 18px;
  border-radius: 14px;
  font-weight: 700;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.primary-button {
  border-color: rgba(15, 138, 131, 0.4);
  background: linear-gradient(135deg, #138f87, #0f6f93);
  box-shadow: 0 14px 24px rgba(15, 111, 147, 0.18);
}

.primary-button:hover {
  transform: translateY(-1px);
  background: linear-gradient(135deg, #16a197, #0e6b8b);
}

.admin-body .secondary-button,
.admin-body .display-link {
  border-color: rgba(20, 56, 96, 0.12);
  background: rgba(255, 255, 255, 0.9);
  color: var(--admin-ink);
}

.admin-body .secondary-button:hover,
.admin-body .display-link:hover,
.danger-button:hover {
  transform: translateY(-1px);
  border-color: rgba(15, 138, 131, 0.26);
  box-shadow: 0 10px 18px rgba(35, 53, 82, 0.08);
}

.danger-button {
  border-color: rgba(194, 65, 12, 0.14);
  background: rgba(255, 245, 238, 0.95);
}

.admin-workspace {
  gap: 22px;
  grid-template-columns: 292px minmax(0, 1fr);
}

.tenant-hero-panel {
  align-items: center;
  gap: 22px;
  padding: 26px 30px;
  background:
    linear-gradient(135deg, rgba(14, 138, 132, 0.08), rgba(255, 255, 255, 0.92) 36%),
    linear-gradient(180deg, rgba(255, 252, 247, 0.98), rgba(255, 251, 245, 0.96));
}

.tenant-hero-copy {
  display: grid;
  gap: 8px;
}

.tenant-info-panel h2 {
  margin: 0;
  color: var(--admin-ink);
  font-size: clamp(30px, 3.2vw, 40px);
}

.tenant-info-panel p {
  color: var(--admin-muted);
  font-size: 17px;
  line-height: 1.65;
}

.tenant-info-extra {
  gap: 12px;
  align-items: flex-end;
  color: var(--admin-ink);
  font-size: 15px;
}

.admin-side {
  gap: 20px;
}

.grade-list-panel,
.subject-bank-panel,
.editor-panel {
  border-radius: 22px;
}

.grade-list-panel,
.subject-bank-panel {
  padding: 24px 20px 20px;
}

.grade-list-panel h2,
.subject-bank-panel h2,
.editor-heading h2,
.message-editor h3,
.form-section-title {
  color: var(--admin-ink);
}

.grade-list-panel h2,
.subject-bank-panel h2 {
  margin: 12px 0 8px;
  font-size: 30px;
}

.grade-list-panel p,
.subject-bank-panel p,
.message-hint,
.exam-list-heading p,
.super-profile-panel p {
  color: var(--admin-muted);
  line-height: 1.7;
}

.grade-list {
  margin-top: 18px;
  gap: 12px;
}

.grade-item {
  min-height: 58px;
  border-radius: 16px;
  border-color: rgba(20, 56, 96, 0.12);
  background: rgba(255, 255, 255, 0.92);
  color: var(--admin-ink);
  padding: 0 18px;
  font-size: 20px;
  font-weight: 700;
}

.admin-body .grade-item.active {
  border-color: rgba(15, 138, 131, 0.28);
  background: linear-gradient(135deg, #1c948c, #1576a0);
  color: #ffffff;
  box-shadow: 0 16px 26px rgba(15, 111, 147, 0.18);
}

.subject-bank-panel textarea {
  min-height: 250px;
}

.editor-panel {
  padding: 28px;
}

.admin-main-panel {
  display: grid;
  gap: 24px;
}

.editor-heading {
  justify-items: start;
  text-align: left;
  gap: 10px;
  margin-bottom: 0;
  padding: 0 0 20px;
  border-bottom: 1px solid rgba(20, 56, 96, 0.1);
}

.editor-heading .display-link {
  position: static;
  justify-self: end;
  align-self: start;
}

.editor-heading-copy {
  display: grid;
  gap: 8px;
}

.editor-heading h2 {
  font-size: clamp(34px, 3.4vw, 46px);
}

.editor-heading p {
  margin: 0;
  color: var(--admin-muted);
  font-size: 17px;
}

.broadcast-panel,
.schedule-panel {
  margin: 0;
  padding: 0;
  border: 0;
}

.message-editor h3,
.form-section-title {
  font-size: 30px;
}

.current-message {
  min-height: 56px;
  padding: 16px 18px;
  border-radius: 14px;
  border-color: rgba(20, 56, 96, 0.12);
  background: rgba(245, 248, 251, 0.88);
  color: var(--admin-ink);
}

.message-form,
.exam-list-section {
  gap: 18px;
}

.exam-list-heading {
  align-items: end;
  padding-top: 8px;
}

.exam-settings-list {
  gap: 16px;
}

.exam-setting-row {
  grid-template-columns: minmax(150px, 1fr) 1.1fr 1.1fr minmax(220px, 1.4fr) auto;
  align-items: end;
  gap: 14px;
  padding: 20px;
  border-radius: 18px;
  border-color: rgba(20, 56, 96, 0.1);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(249, 246, 239, 0.94));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.admin-body .exam-setting-row.in_progress,
.admin-body .exam-setting-row.last_15 {
  border-color: rgba(15, 138, 131, 0.18);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 248, 245, 0.96));
}

.admin-body .exam-setting-row.ended {
  border-color: rgba(184, 138, 69, 0.16);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(251, 246, 238, 0.96));
}

.setting-subject strong {
  font-size: 34px;
}

.setting-status {
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.setting-actions {
  justify-content: flex-start;
}

.setting-empty {
  padding: 22px;
  border-radius: 18px;
  border-style: solid;
  border-color: rgba(20, 56, 96, 0.1);
  background: rgba(246, 248, 251, 0.86);
}

.form-message {
  min-height: 24px;
  color: var(--admin-muted);
}

.form-message.success {
  color: var(--admin-accent);
}

.form-message.error {
  color: #bf5b32;
}

.super-workspace {
  gap: 22px;
}

.super-profile-panel {
  align-items: center;
  padding: 26px 30px;
  background:
    linear-gradient(135deg, rgba(14, 93, 140, 0.08), rgba(255, 255, 255, 0.92) 38%),
    linear-gradient(180deg, rgba(255, 252, 247, 0.98), rgba(255, 251, 245, 0.96));
}

.super-profile-copy {
  display: grid;
  gap: 8px;
}

.super-profile-panel .form-section-title {
  font-size: 34px;
}

.inline-form {
  grid-template-columns: minmax(240px, 360px) auto minmax(140px, 1fr);
}

.console-main-panel {
  display: grid;
  gap: 18px;
}

.heading-actions {
  align-items: center;
  gap: 10px;
}

.filter-panel {
  grid-template-columns: repeat(5, minmax(120px, 1fr)) auto;
  gap: 14px;
  margin-top: 0;
  padding: 18px;
  border-radius: 18px;
  background: rgba(246, 248, 251, 0.88);
}

.tenant-table {
  padding: 6px 0 0;
  background: transparent;
}

.tenant-row {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(240px, 1fr) minmax(340px, auto);
  align-items: center;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px solid rgba(20, 56, 96, 0.08);
  background: transparent;
}

.tenant-row:last-child {
  border-bottom: 0;
}

.tenant-row > div:first-child {
  min-width: 0;
}

.tenant-row-main {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.tenant-overview {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.tenant-row strong {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--admin-ink);
  font-size: 24px;
}

.tenant-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 18px;
}

.tenant-meta-item {
  display: grid;
  gap: 4px;
  color: var(--admin-ink);
  font-size: 15px;
}

.tenant-meta-item b {
  color: var(--admin-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.tenant-link-field {
  min-width: 0;
}

.tenant-row label {
  gap: 10px;
  color: var(--admin-muted);
  font-size: 14px;
  font-weight: 600;
}

.tenant-row label input {
  min-height: 48px;
}

.tenant-actions {
  justify-content: flex-end;
  gap: 10px;
}

.tenant-actions .display-link,
.tenant-actions .secondary-button,
.tenant-actions .danger-button {
  min-height: 42px;
  padding-inline: 14px;
}

.modal-dialog {
  width: min(920px, calc(100vw - 40px));
  padding: 0;
  border: 0;
  background: transparent;
}

.modal-card {
  gap: 0;
  overflow: hidden;
}

.modal-heading,
.modal-actions {
  padding: 24px 28px;
}

.modal-body {
  padding: 0 28px 24px;
}

.modal-heading {
  align-items: start;
  gap: 18px;
  border-bottom: 1px solid rgba(20, 56, 96, 0.08);
}

.modal-heading p {
  margin: 8px 0 0;
  color: var(--admin-muted);
  line-height: 1.65;
}

.modal-actions {
  border-top: 1px solid rgba(20, 56, 96, 0.08);
  background: rgba(247, 248, 250, 0.9);
}

.icon-close-button {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(20, 56, 96, 0.12);
  border-radius: 12px;
  background: #ffffff;
  color: var(--admin-ink);
}

@media (max-width: 1180px) {
  .admin-workspace {
    grid-template-columns: 1fr;
  }

  .admin-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .exam-setting-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .setting-subject,
  .setting-slogan-field,
  .setting-actions {
    grid-column: 1 / -1;
  }

  .inline-form {
    grid-template-columns: minmax(220px, 1fr) auto;
  }

  .inline-form .form-message {
    grid-column: 1 / -1;
  }

  .filter-panel {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .tenant-row {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .tenant-meta-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .tenant-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .scholarly-shell {
    width: min(100%, calc(100% - 20px));
    padding-top: 10px;
  }

  .scholarly-masthead,
  .tenant-hero-panel,
  .grade-list-panel,
  .subject-bank-panel,
  .editor-panel,
  .auth-card,
  .modal-card {
    border-radius: 18px;
  }

  .scholarly-masthead,
  .tenant-hero-panel,
  .super-profile-panel,
  .editor-panel,
  .grade-list-panel,
  .subject-bank-panel {
    padding: 20px;
  }

  .brand-logo {
    width: min(100%, 320px);
    height: 82px;
  }

  .admin-header h1,
  .tenant-info-panel h2,
  .editor-heading h2,
  .super-profile-panel .form-section-title {
    font-size: 28px;
  }

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

  .editor-heading .display-link {
    justify-self: stretch;
  }

  .heading-actions,
  .filter-panel,
  .inline-form,
  .tenant-actions,
  .form-actions {
    grid-template-columns: 1fr;
    align-items: stretch;
    justify-content: stretch;
  }

  .heading-actions,
  .tenant-actions,
  .form-actions {
    display: grid;
  }

  .filter-panel {
    grid-template-columns: 1fr;
  }

  .exam-setting-row {
    grid-template-columns: 1fr;
  }

  .tenant-row strong {
    font-size: 21px;
  }

  .tenant-meta-grid {
    grid-template-columns: 1fr;
  }

  .modal-heading,
  .modal-body,
  .modal-actions {
    padding-inline: 18px;
  }
}

/* Concept 1 fidelity pass: match the selected board scale and density. */
.admin-body {
  background:
    linear-gradient(180deg, rgba(248, 245, 238, 0.96), rgba(244, 240, 231, 0.96)),
    #f5f1e8;
}

.scholarly-shell {
  width: min(720px, calc(100% - 28px));
  min-height: calc(100vh - 28px);
  margin: 14px auto;
  padding: 16px;
  border: 1px solid rgba(28, 55, 87, 0.14);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(253, 250, 244, 0.98)),
    #fffdf8;
  box-shadow: 0 18px 44px rgba(28, 43, 66, 0.12);
}

.scholarly-masthead,
.tenant-hero-panel,
.grade-list-panel,
.subject-bank-panel,
.editor-panel,
.auth-card,
.modal-card {
  border-radius: 6px;
  box-shadow: 0 8px 20px rgba(34, 50, 74, 0.06);
}

.scholarly-masthead {
  min-height: 82px;
  padding: 12px 16px;
  margin: 0 0 16px;
  border-color: rgba(28, 55, 87, 0.12);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.98) 0 52%, rgba(233, 241, 244, 0.68) 100%),
    #fffdf9;
}

.scholarly-masthead::after {
  height: 82px;
  background:
    radial-gradient(ellipse at 84% 75%, rgba(37, 77, 112, 0.2), transparent 28%),
    linear-gradient(155deg, transparent 0 58%, rgba(25, 72, 105, 0.12) 59% 61%, transparent 62%),
    linear-gradient(145deg, transparent 0 64%, rgba(25, 72, 105, 0.1) 65% 67%, transparent 68%);
  opacity: 0.72;
}

.brand-heading {
  align-items: center;
  gap: 16px;
}

.brand-logo {
  width: 188px;
  height: 58px;
  padding: 5px 10px;
  border-radius: 4px;
}

.brand-wordmark {
  width: 188px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 4px;
  color: #082a57;
  font-family:
    "STKaiti", "KaiTi", "FangSong", "Microsoft YaHei", serif;
  white-space: nowrap;
}

.brand-wordmark span {
  font-size: 34px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.06em;
}

.brand-wordmark i {
  display: inline-grid;
  place-items: center;
  width: 10px;
  height: 28px;
  border-radius: 2px;
  background: #9c2f24;
  color: #fff7ef;
  font-family: "Microsoft YaHei", sans-serif;
  font-size: 8px;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
}

.brand-copy {
  gap: 4px;
  max-width: 330px;
}

.brand-copy h1 {
  display: none;
}

.brand-tagline {
  color: #586982;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.admin-header p {
  max-width: 360px;
  color: #68778d;
  font-size: 13px;
  line-height: 1.45;
}

.scholarly-masthead .secondary-button {
  position: relative;
  z-index: 2;
  min-height: 36px;
  padding: 7px 12px;
  border-radius: 5px;
  font-size: 15px;
}

.login-panel {
  min-height: 610px;
}

.auth-card {
  width: min(430px, 100%);
  padding: 28px;
}

.auth-card h2 {
  font-size: 26px;
}

.admin-workspace {
  grid-template-columns: 172px minmax(0, 1fr);
  gap: 18px;
}

.admin-side,
.admin-main-panel,
.console-main-panel {
  min-width: 0;
}

.tenant-hero-panel {
  min-height: 102px;
  padding: 20px 18px;
  border-color: rgba(28, 55, 87, 0.14);
  background: #fffdf9;
}

.tenant-hero-copy {
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
}

.super-profile-copy::before {
  content: "";
  grid-row: 1 / span 3;
  width: 50px;
  height: 50px;
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.28), transparent),
    linear-gradient(135deg, #20a48f, #0a6e97);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.tenant-info-panel h2 {
  font-size: 22px;
  line-height: 1.2;
}

.tenant-info-panel p,
.tenant-info-extra,
.super-profile-panel p {
  font-size: 12px;
  line-height: 1.55;
}

.tenant-info-extra {
  gap: 8px;
}

.admin-body .tenant-info-extra {
  font-size: 15px;
  line-height: 1.55;
}

.admin-body .tenant-info-extra #logoutButton {
  justify-self: end;
  margin-bottom: 2px;
}

.panel-eyebrow {
  min-height: auto;
  padding: 0;
  border-radius: 0;
  background: transparent;
  color: #007c77;
  font-size: 14px;
  letter-spacing: 0;
}

.tenant-hero-copy .panel-eyebrow,
.console-main-panel .panel-eyebrow,
.admin-main-panel .panel-eyebrow {
  font-size: 20px;
  font-weight: 800;
}

.super-profile-copy .panel-eyebrow {
  font-size: 20px;
  font-weight: 800;
}

#superProfileText {
  font-size: 15px;
}

.grade-list-panel,
.subject-bank-panel {
  padding: 18px 14px;
}

.grade-list-panel h2,
.subject-bank-panel h2 {
  margin: 8px 0 10px;
  font-size: 17px;
}

.grade-list-panel p,
.subject-bank-panel p,
.message-hint,
.exam-list-heading p {
  font-size: 12px;
  line-height: 1.55;
}

.grade-list {
  gap: 10px;
  margin-top: 14px;
}

.grade-item {
  min-height: 42px;
  border-radius: 5px;
  padding: 9px 14px;
  font-size: 14px;
}

.subject-bank-panel textarea {
  min-height: 260px;
}

.subject-bank-panel .secondary-button {
  width: 100%;
}

.editor-panel {
  padding: 16px;
}

.admin-main-panel {
  gap: 18px;
}

.editor-heading {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
  padding-bottom: 14px;
  min-width: 0;
}

.editor-heading-copy {
  gap: 4px;
}

.editor-heading h2 {
  font-size: 22px;
}

.editor-heading p {
  font-size: 12px;
}

.editor-heading .display-link {
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 5px;
  font-size: 20px;
  white-space: nowrap;
}

.message-editor h3,
.form-section-title {
  font-size: 18px;
}

.current-message,
.admin-body .admin-shell input,
.admin-body .admin-shell select,
.admin-body .admin-shell textarea,
.modal-dialog input,
.modal-dialog select,
.modal-dialog textarea {
  min-height: 38px;
  border-radius: 5px;
  font-size: 13px;
}

.current-message {
  padding: 9px 12px;
}

.message-form,
.exam-list-section {
  gap: 12px;
}

.primary-button,
.secondary-button,
.danger-button,
.display-link {
  min-height: 34px;
  padding: 8px 13px;
  border-radius: 5px;
  font-size: 13px;
}

.exam-list-heading {
  align-items: start;
}

.exam-settings-list {
  gap: 12px;
}

.exam-setting-row {
  grid-template-columns: 108px 144px 144px;
  gap: 10px 11px;
  padding: 16px 12px;
  border-radius: 6px;
  background:
    linear-gradient(180deg, rgba(255, 253, 249, 0.98), rgba(255, 247, 235, 0.92));
}

.setting-subject {
  grid-row: 1 / span 3;
  min-height: 84px;
  align-content: start;
}

.setting-subject strong {
  font-size: 22px;
}

.setting-duration {
  color: #61758c;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
}

.setting-status {
  min-height: 22px;
  padding: 2px 7px;
  font-size: 11px;
}

.setting-slogan-field {
  grid-column: 2 / span 2;
}

.exam-setting-row input[type="datetime-local"] {
  width: 144px;
  min-width: 0;
  padding-inline: 7px;
  font-size: 11px;
}

.exam-setting-row .setting-slogan {
  min-width: 0;
}

.setting-actions {
  grid-column: 1 / span 3;
  justify-content: flex-start;
}

.setting-actions .primary-button,
.setting-actions .secondary-button {
  min-height: 34px;
  padding-inline: 12px;
}

.super-workspace {
  gap: 18px;
}

.super-profile-panel {
  min-height: 102px;
  padding: 20px 18px;
  border-color: rgba(28, 55, 87, 0.14);
  background: #fffdf9;
}

.super-profile-copy {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  column-gap: 0;
}

.super-profile-panel .form-section-title {
  font-size: 22px;
}

.inline-form {
  grid-template-columns: minmax(0, 1fr) auto;
  width: min(360px, 100%);
}

.inline-form .form-message {
  grid-column: 1 / -1;
}

.super-profile-actions {
  width: auto;
  justify-items: end;
  align-content: start;
  row-gap: 10px;
}

.super-profile-copy::before {
  display: none;
}

.console-main-panel {
  padding: 20px 18px 16px;
}

.console-main-panel .exam-list-heading {
  align-items: start;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(28, 55, 87, 0.12);
}

.console-account-heading .form-section-title {
  color: var(--teal);
  font-size: 20px;
}

.console-stats-heading .form-section-title {
  color: var(--teal);
  font-size: 20px;
}



.heading-actions {
  align-items: start;
}

.console-main-panel .filter-panel {
  grid-template-columns: repeat(5, minmax(0, 1fr)) auto;
  gap: 12px 14px;
  padding: 14px 0 0;
  margin-top: 10px;
  border: 0;
  border-radius: 0;
  background: transparent;
  align-items: end;
}

.console-main-panel .filter-panel > label {
  min-width: 0;
}

.console-main-panel .filter-actions {
  align-self: end;
  justify-content: flex-end;
  padding-left: 6px;
}

.tenant-table {
  padding-top: 0;
  overflow-x: auto;
}

.tenant-table-head {
  display: grid;
  grid-template-columns: 1.25fr 0.62fr 0.82fr 0.52fr 0.7fr 2fr;
  min-width: 690px;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  border-bottom: 1px solid rgba(28, 55, 87, 0.12);
  background: rgba(248, 250, 252, 0.9);
  color: #173056;
  font-size: 16px;
  font-weight: 800;
  line-height: 1.2;
}

.tenant-table-head > span {
  display: flex;
  align-items: center;
  white-space: nowrap;
}

.tenant-table-head > span:not(:first-child) {
  justify-content: center;
  text-align: center;
}

.tenant-table-head > span:last-child {
  padding-left: 0;
}

.tenant-row {
  grid-template-columns: 1.25fr 0.62fr 0.82fr 0.52fr 0.82fr 2fr;
  min-width: 690px;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
}

.tenant-row-main,
.tenant-cell,
.tenant-actions {
  align-self: center;
}

.tenant-row-main {
  gap: 8px;
}

.tenant-overview {
  gap: 8px;
}

.tenant-row strong {
  font-size: 13px;
}

.tenant-row p {
  margin: 5px 0 0;
  color: #506077;
  font-size: 12px;
  line-height: 1.45;
}

.tenant-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #173056;
  font-size: 12px;
  line-height: 1.45;
  text-align: center;
}

.tenant-row > .tenant-cell:nth-of-type(1),
.tenant-row > .tenant-cell:nth-of-type(2),
.tenant-row > .tenant-cell:nth-of-type(3),
.tenant-row > .tenant-cell:nth-of-type(4) {
  font-size: 15px;
}

.tenant-row > .tenant-cell:nth-of-type(4) {
  white-space: nowrap;
}

.tenant-actions {
  justify-content: center;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  flex-wrap: wrap;
  text-align: center;
}

/* 学校列表各列单独微调位置 */

/* 1. 学校名称 */
.tenant-table-head > span:nth-of-type(1) {
  transform: translateX(30px);
}

/* 2. 账号 */
.tenant-table-head > span:nth-of-type(2) {
  transform: translateX(-55px);
}

/* 3. 手机号 */
.tenant-table-head > span:nth-of-type(3) {
  transform: translateX(-75px);
}

/* 4. 状态 */
.tenant-table-head > span:nth-of-type(4) {
  transform: translateX(-95px);
}

/* 5. 到期 */
.tenant-table-head > span:nth-of-type(5) {
  transform: translateX(-112px);
}

/* 6. 操作 */
.tenant-table-head > span:nth-of-type(6) {
  transform: translateX(-55px);
}

.tenant-actions {
  transform: translateX(10px);
}

.tenant-actions .display-link,
.tenant-actions .secondary-button,
.tenant-actions .danger-button {
  min-height: 28px;
  padding: 4px 6px;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: #0b4a86;
  font-size: 13px;
}

.modal-dialog {
  width: min(680px, calc(100vw - 28px));
}

@media (max-width: 760px) {
  .scholarly-shell {
    width: min(100%, calc(100% - 16px));
    margin: 8px auto;
    padding: 10px;
  }

  .scholarly-masthead {
    min-height: auto;
    padding: 12px;
  }

  .brand-heading,
  .tenant-hero-panel,
  .super-profile-panel {
    align-items: flex-start;
  }

  .brand-logo {
    width: min(100%, 220px);
    height: 64px;
  }

  .brand-wordmark {
    width: min(100%, 220px);
    height: 64px;
  }

  .brand-wordmark span {
    font-size: 32px;
  }

  .admin-workspace,
  .admin-side,
  .editor-heading,
  .inline-form,
  .filter-panel,
  .exam-setting-row {
    grid-template-columns: 1fr;
  }

  .setting-subject,
  .setting-slogan-field,
  .setting-actions {
    grid-column: auto;
    grid-row: auto;
  }

  .tenant-hero-copy,
  .super-profile-copy {
    grid-template-columns: 1fr;
  }

  .tenant-hero-copy::before,
  .super-profile-copy::before {
    display: none;
  }
}

.more-menu-list {
  display: grid;
  gap: 10px;
}

.more-menu-item {
  display: grid;
  gap: 6px;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 231, 242, 0.14);
}

.more-menu-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.more-menu-item strong {
  color: var(--display-text);
  font-size: 15px;
  font-weight: 800;
}

.more-menu-item p {
  margin: 0;
  color: var(--display-muted);
  font-size: 13px;
  line-height: 1.55;
}

.display-popup {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(2, 8, 14, 0.56);
  backdrop-filter: blur(6px);
}

.display-popup-card {
  position: relative;
  width: min(640px, calc(100vw - 48px));
  display: grid;
  gap: 12px;
  padding: 28px 28px 24px;
  border: 1px solid rgba(0, 231, 242, 0.28);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(7, 19, 25, 0.98), rgba(5, 13, 19, 0.98)),
    rgba(5, 13, 19, 0.98);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

.display-popup-eyebrow {
  color: var(--display-cyan);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.display-popup-title {
  margin: 0;
  color: var(--display-text);
  font-size: clamp(28px, 2.5vw, 40px);
  line-height: 1.15;
}

.display-popup-content {
  margin: 0;
  color: #d8e7e5;
  font-size: clamp(16px, 1.35vw, 22px);
  line-height: 1.7;
  white-space: pre-wrap;
}

.display-popup-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(0, 231, 242, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--display-text);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.push-panel-shell {
  padding-top: 6px;
}

.push-shared-filter {
  display: grid;
  gap: 14px;
  margin-top: 2px;
  margin-bottom: 16px;
  padding: 16px 16px 15px;
  border: 1px solid rgba(28, 55, 87, 0.12);
  border-radius: 6px;
  background: linear-gradient(180deg, rgba(251, 253, 254, 0.98), rgba(245, 249, 251, 0.96));
}

.push-shared-help {
  margin: 0;
  color: #4c6079;
  font-size: 15px;
  line-height: 1.55;
}

.push-shared-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.push-filter-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(104px, 1fr));
  gap: 8px;
  flex: 0 0 auto;
}

.push-filter-summary article {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 5px;
  min-width: 104px;
  padding: 9px 11px 8px;
  border: 1px solid rgba(0, 124, 119, 0.16);
  border-radius: 6px;
  background: rgba(239, 249, 248, 0.88);
}

.push-filter-summary span {
  grid-column: 1 / -1;
  color: #60738b;
  font-size: 11px;
  line-height: 1.25;
}

.push-filter-summary strong {
  color: #007c77;
  font-size: 24px;
  line-height: 1;
}

.push-filter-summary small {
  align-self: end;
  padding-bottom: 1px;
  color: #60738b;
  font-size: 11px;
}

.push-composer-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

.push-card {
  display: grid;
  gap: 14px;
  padding: 16px 16px 15px;
  border: 1px solid rgba(28, 55, 87, 0.12);
  border-radius: 6px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(248, 251, 253, 0.96));
  box-shadow: 0 10px 20px rgba(22, 41, 66, 0.04);
}

.push-card:first-of-type {
  border-top: 1px solid rgba(28, 55, 87, 0.12);
  padding-top: 16px;
}

.push-card-heading {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.push-list-heading {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.push-list-heading > div {
  display: grid;
  gap: 6px;
}

.push-list-heading > button {
  flex: 0 0 auto;
}

.push-form {
  display: grid;
  gap: 12px;
}

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

.push-target-grid--shared {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.push-message-list {
  display: grid;
  gap: 0;
}

.push-message-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(28, 55, 87, 0.12);
}

.push-message-row:last-child {
  border-bottom: 0;
}

.push-message-main {
  display: grid;
  gap: 8px;
}

.push-message-overview {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.push-message-overview strong {
  color: #173056;
  font-size: 15px;
}

.push-message-main p {
  margin: 0;
  color: #506077;
  font-size: 13px;
  line-height: 1.6;
}

.push-message-meta {
  color: #6e8195;
  font-size: 12px;
}

.push-type-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(11, 75, 151, 0.08);
  color: #0b4b97;
  font-size: 11px;
  font-weight: 800;
}

.push-type-badge.is-popup {
  background: rgba(191, 91, 50, 0.1);
  color: #bf5b32;
}

.terminal-filter-panel {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px 14px;
  padding: 0;
  margin-top: 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  align-items: stretch;
}

.terminal-filter-panel > label {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 12px 12px 10px;
  border: 1px solid rgba(19, 83, 116, 0.12);
  border-radius: 14px;
  background: rgba(244, 249, 251, 0.96);
  color: #173056;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.terminal-filter-panel > label > input,
.terminal-filter-panel > label > select {
  width: 100%;
  min-height: 44px;
  border-radius: 10px;
  border-color: rgba(28, 55, 87, 0.14);
  background: #ffffff;
  font-size: 14px;
}

.terminal-filter-panel .stats-filter-search {
  grid-column: span 1;
}

.terminal-filter-panel .filter-actions {
  justify-content: flex-end;
  align-self: end;
  padding-top: 2px;
}

.terminal-filter-panel .filter-actions .secondary-button {
  min-width: 108px;
  min-height: 44px;
  border-radius: 12px;
  border-color: rgba(21, 90, 126, 0.18);
  background: #ffffff;
  color: #184a78;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(12, 52, 84, 0.06);
}

.terminal-filter-panel > label:focus-within {
  border-color: rgba(0, 124, 119, 0.36);
  box-shadow: 0 0 0 3px rgba(0, 124, 119, 0.08);
  background: rgba(247, 253, 252, 1);
}

.console-main-panel .terminal-school-list.terminal-stats-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

@media (max-width: 900px) {
  .terminal-filter-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .terminal-filter-panel {
    grid-template-columns: 1fr;
    padding: 14px 12px 12px;
  }

  .terminal-filter-panel .filter-actions {
    grid-column: auto;
    justify-content: flex-start;
  }
}

.push-message-actions {
  display: flex;
  align-items: flex-start;
}

@media (max-width: 760px) {
  .push-composer-grid,
  .push-shared-filter,
  .push-target-grid,
  .push-target-grid--shared,
  .push-message-row {
    grid-template-columns: 1fr;
  }

  .display-popup {
    padding: 16px;
  }

  .display-popup-card {
    width: min(100%, calc(100vw - 32px));
    padding: 22px 18px 18px;
  }

  .push-shared-header {
    align-items: stretch;
    flex-direction: column;
  }

  .push-filter-summary {
    width: 100%;
  }
}

/* Keep rich display content above earlier display-theme overrides. */
.more-widget .more-menu {
  position: fixed;
  right: clamp(16px, 3vw, 42px);
  bottom: clamp(96px, 12vh, 132px);
  width: min(760px, calc(100vw - 32px));
  max-height: min(72vh, 720px);
  overflow: auto;
  padding: 20px;
}

.more-menu .push-content-text,
.more-menu .push-content-caption {
  margin: 0;
  color: #d8e7e5;
  font-size: clamp(15px, 1.15vw, 18px);
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.more-menu .push-media--image img {
  display: block;
  width: 100%;
  max-height: min(52vh, 520px);
  object-fit: contain;
  border: 1px solid rgba(0, 231, 242, 0.16);
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.2);
}

.more-menu .push-media--webpage iframe,
.display-popup-content .push-media--webpage iframe {
  display: block;
  width: 100%;
  height: min(58vh, 580px);
  border: 1px solid rgba(0, 231, 242, 0.18);
  border-radius: 6px;
  background: #ffffff;
}

.display-popup[data-content-kind="image"] .display-popup-card,
.display-popup[data-content-kind="webpage"] .display-popup-card {
  width: min(920px, calc(100vw - 48px));
}

.display-popup-content {
  min-width: 0;
  max-height: 72vh;
  overflow: auto;
}

@media (max-width: 760px) {
  .more-widget .more-menu {
    right: 12px;
    bottom: 92px;
    width: calc(100vw - 24px);
    max-height: 70vh;
    padding: 16px;
  }

  .display-popup[data-content-kind="image"] .display-popup-card,
  .display-popup[data-content-kind="webpage"] .display-popup-card {
    width: min(100%, calc(100vw - 32px));
  }
}
