:root {
  color-scheme: light;
  --bg: #edf8fb;
  --shell: #0b5f9e;
  --shell-2: #074a7d;
  --surface: #ffffff;
  --surface-soft: #f7fbff;
  --ink: #123048;
  --muted: #5f7385;
  --muted-2: #8aa0b2;
  --line: #cfe1ee;
  --line-soft: #dcebf4;
  --accent: #0b6fb3;
  --accent-strong: #07558d;
  --cyan: #0a8fb8;
  --violet: #c22c83;
  --green: #148b6a;
  --orange: #f47a13;
  --red: #d43a46;
  --amber: #fff4e5;
  --navy: #123048;
  --blue: #0b6fb3;
  --teal: #0a8fb8;
  --brand-blue: #005e9e;
  --brand-orange: #f47a13;
  --brand-plum: #5b4a62;
  --brand-coral: #ff5a3d;
  --brand-rose: #d92f85;
  --brand-yellow: #ffbf3d;
  --brand-sky: #e9f6ff;
  --brand-warm: #fff5e9;
  --brand-gradient: linear-gradient(110deg, #005e9e 0%, #0879bd 31%, #7e4f7a 57%, #f47a13 100%);
  --brand-gradient-soft: linear-gradient(135deg, rgba(0, 94, 158, 0.08), rgba(255, 191, 61, 0.1) 46%, rgba(244, 122, 19, 0.12));
  --brand-hot-gradient: linear-gradient(135deg, #f47a13 0%, #ff5a3d 54%, #d92f85 100%);
  --shadow: 0 18px 48px rgba(12, 86, 139, 0.12);
  --shadow-soft: 0 1px 2px rgba(12, 86, 139, 0.06);
  --radius: 8px;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    "Microsoft YaHei",
    "PingFang SC",
    sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  background:
    linear-gradient(116deg, rgba(0, 94, 158, 0.12) 0%, rgba(0, 94, 158, 0) 32%),
    linear-gradient(242deg, rgba(244, 122, 19, 0.14) 0%, rgba(244, 122, 19, 0) 34%),
    var(--bg);
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.56), rgba(255, 255, 255, 0) 260px),
    linear-gradient(116deg, rgba(0, 94, 158, 0.12) 0%, rgba(0, 94, 158, 0) 28%),
    linear-gradient(244deg, rgba(244, 122, 19, 0.18) 0%, rgba(244, 122, 19, 0) 29%),
    linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 245, 233, 0.72) 100%),
    var(--bg);
}

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

button,
select {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

.login-screen {
  display: grid;
  min-height: 100dvh;
  place-items: center;
  padding: calc(22px + env(safe-area-inset-top)) 16px calc(34px + env(safe-area-inset-bottom));
}

.login-card {
  position: relative;
  display: grid;
  gap: 18px;
  width: min(100%, 480px);
  overflow: hidden;
  padding: 24px;
  border: 1px solid rgba(207, 225, 238, 0.9);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 250, 245, 0.92)),
    var(--brand-gradient-soft);
  box-shadow: 0 26px 70px rgba(12, 86, 139, 0.17);
}

.login-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 7px;
  background: var(--brand-gradient);
}

.login-brand {
  display: grid;
  gap: 7px;
  padding-top: 8px;
  text-align: center;
}

.login-brand p,
.login-brand span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.login-brand h1 {
  color: var(--ink);
  font-size: 34px;
  font-weight: 900;
  line-height: 1.08;
}

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

.login-form label {
  display: grid;
  gap: 7px;
}

.login-form span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.login-error {
  min-height: 18px;
  color: var(--red);
  font-size: 12px;
  font-weight: 800;
}

.demo-accounts {
  display: grid;
  gap: 8px;
  padding-top: 6px;
}

.demo-account {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 800;
}

.demo-account strong {
  min-width: 0;
  overflow: hidden;
  color: var(--ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.app-shell {
  width: 100%;
  max-width: 1180px;
  min-height: 100dvh;
  margin: 0 auto;
  overflow: hidden;
  padding: calc(18px + env(safe-area-inset-top)) 14px calc(42px + env(safe-area-inset-bottom));
}

.topbar {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-height: 132px;
  position: relative;
  overflow: hidden;
  padding: 32px 72px;
  border: 0;
  border-radius: 22px;
  color: #fff;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 42%),
    var(--brand-gradient);
  box-shadow: 0 22px 54px rgba(12, 86, 139, 0.18);
}

.topbar::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(168deg, transparent 0 21%, rgba(255, 255, 255, 0.16) 21% 27%, transparent 27% 100%),
    linear-gradient(22deg, transparent 0 57%, rgba(255, 191, 61, 0.22) 57% 64%, transparent 64% 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.12), transparent 48%);
  pointer-events: none;
}

.topbar::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: inherit;
  pointer-events: none;
}

.hero-brand {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 8px;
  min-width: 0;
  text-align: center;
}

.hero-brand h1 {
  color: #fff;
  font-size: clamp(32px, 4vw, 46px);
  font-weight: 850;
  line-height: 1.05;
  letter-spacing: 0;
  text-shadow: 0 2px 12px rgba(15, 23, 42, 0.22);
}

.hero-brand p {
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(17px, 2vw, 24px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0;
  text-shadow: 0 2px 10px rgba(15, 23, 42, 0.2);
}

.topbar-actions {
  position: absolute;
  z-index: 2;
  top: 14px;
  right: 14px;
  display: flex;
  gap: 8px;
}

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

.brand-mark {
  position: relative;
  display: grid;
  flex: 0 0 60px;
  width: 60px;
  height: 42px;
  place-items: center;
  border: 1px dashed rgba(255, 255, 255, 0.48);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.brand-mark::after {
  content: "LOGO";
  color: #cbd5e1;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-block > div {
  min-width: 0;
}

.eyebrow,
h1,
h2,
h3,
p {
  margin: 0;
}

.eyebrow {
  color: #a5b4fc;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.3;
}

h1 {
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: 0;
}

h2 {
  color: var(--ink);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.3;
}

h3 {
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
}

.ghost-button,
.primary-button,
.plain-button,
.danger-button {
  min-height: 40px;
  border-radius: var(--radius);
  font-weight: 800;
  letter-spacing: 0;
  transition:
    background 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    transform 160ms ease;
}

.ghost-button {
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: rgba(255, 255, 255, 0.86);
  background: rgba(255, 255, 255, 0.11);
  padding: 0 14px;
  white-space: nowrap;
  backdrop-filter: blur(12px);
}

.ghost-button:hover {
  background: rgba(255, 255, 255, 0.14);
}

.primary-button {
  width: 100%;
  border: 0;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--cyan) 48%, var(--brand-orange));
  padding: 0 16px;
  box-shadow: 0 8px 18px rgba(11, 111, 179, 0.2);
}

.primary-button:hover {
  background: linear-gradient(135deg, var(--accent-strong), #087aa0 48%, #e8670d);
  transform: translateY(-1px);
}

.plain-button {
  border: 1px solid var(--line);
  color: var(--ink);
  background: #fff;
  padding: 0 13px;
}

.plain-button:hover {
  border-color: #a9cadf;
  background: #f4fbff;
  transform: translateY(-1px);
}

.plain-button.is-selected {
  border-color: transparent;
  color: #fff;
  background: var(--brand-hot-gradient);
  box-shadow: 0 10px 22px rgba(244, 122, 19, 0.18);
}

.danger-button {
  border: 1px solid #ffd0d6;
  color: var(--red);
  background: #fff7f8;
  padding: 0 13px;
}

.danger-button:hover {
  border-color: #f1a6af;
  background: #fff0f2;
  transform: translateY(-1px);
}

button:disabled {
  cursor: default;
  opacity: 0.58;
  transform: none !important;
}

.control-strip {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  gap: 10px;
  margin-top: 12px;
  overflow: hidden;
  padding: 14px 12px 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 251, 255, 0.95)),
    var(--brand-gradient-soft);
  box-shadow: var(--shadow-soft);
}

.session-strip {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(207, 225, 238, 0.92);
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: var(--shadow-soft);
}

.session-strip strong {
  color: var(--ink);
}

.session-strip span {
  min-width: 0;
  overflow: hidden;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.session-action {
  min-height: 28px;
  border: 1px solid rgba(0, 94, 158, 0.18);
  border-radius: 999px;
  padding: 0 10px;
  color: var(--brand-blue);
  background: #fff;
  font-size: 11px;
  font-weight: 850;
}

.session-action:hover:not(:disabled) {
  border-color: rgba(244, 122, 19, 0.34);
  color: #9e4d0f;
  background: #fff8ef;
}

.session-action:disabled {
  cursor: default;
  opacity: 0.48;
}

.nav-back-action {
  border-color: rgba(244, 122, 19, 0.25);
  color: #a65010;
  background: linear-gradient(180deg, #fffaf4, #ffffff);
}

.session-badge {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 9px;
  color: #fff;
  background: var(--brand-hot-gradient);
  font-size: 11px;
  font-weight: 850;
}

.cloud-badge {
  background: #697386;
}

.cloud-badge.is-online {
  background: linear-gradient(135deg, #0f9f6e, #19b6a4);
}

.cloud-badge.is-error {
  background: linear-gradient(135deg, #cf2f2f, #ef7b45);
}

.locked-control {
  opacity: 0.72;
}

.control-strip::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-yellow), var(--brand-orange));
}

.control-strip label,
.summary-panel,
.tabs,
.latest-news-panel,
.item-card,
.form-panel,
.profile-panel {
  min-width: 0;
  max-width: 100%;
}

.control-strip label,
.form-grid label,
.field-block {
  display: grid;
  gap: 6px;
}

.control-strip span,
.form-grid span,
.field-block span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

select,
input,
textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

select,
input {
  min-height: 42px;
  padding: 0 12px;
}

.student-multi-select {
  min-height: 116px;
  padding: 8px 10px;
}

.student-multi-select option {
  padding: 7px 8px;
}

.student-checkbox-grid {
  display: grid;
  max-height: 260px;
  overflow: auto;
  gap: 6px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
}

.student-checkbox-grid label {
  display: grid;
  grid-template-columns: 18px 1fr;
  align-items: start;
  gap: 8px;
  padding: 7px 8px;
  border-radius: 6px;
}

.student-checkbox-grid label:has(input:checked) {
  background: rgba(0, 94, 158, 0.1);
}

.student-checkbox-grid input {
  width: 16px;
  min-height: 16px;
  margin-top: 2px;
}

.student-checkbox-grid span {
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.student-checkbox-grid.is-empty {
  color: var(--muted);
  font-size: 13px;
}

textarea {
  min-height: 112px;
  resize: vertical;
  padding: 11px 12px;
  line-height: 1.55;
}

select:focus,
input:focus,
textarea:focus,
button:focus-visible {
  outline: 3px solid rgba(0, 94, 158, 0.2);
  outline-offset: 2px;
}

.summary-panel {
  position: relative;
  overflow: hidden;
  margin-top: 12px;
  padding: 17px 16px 16px;
  border: 1px solid var(--line-soft);
  border-left: 4px solid var(--brand-coral);
  border-radius: var(--radius);
  background:
    linear-gradient(110deg, rgba(255, 90, 61, 0.08), rgba(255, 255, 255, 0) 36%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 251, 246, 0.9)),
    var(--surface);
  box-shadow: var(--shadow);
}

.summary-panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-orange), var(--brand-rose), var(--brand-blue));
}

.summary-title {
  display: flex;
  min-width: 0;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.summary-title strong {
  min-width: 0;
  color: var(--ink);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.16;
  word-break: break-word;
}

.summary-title span {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  text-align: right;
  word-break: break-word;
}

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

.metric {
  position: relative;
  overflow: hidden;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.92)),
    var(--brand-gradient-soft);
}

.metric::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, rgba(0, 94, 158, 0.2), rgba(244, 122, 19, 0.38));
}

.metric b {
  display: block;
  color: var(--ink);
  font-size: 22px;
  font-weight: 850;
  line-height: 1.12;
  word-break: break-word;
}

.metric span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.progress-track {
  overflow: hidden;
  height: 8px;
  margin-top: 13px;
  border-radius: 999px;
  background: #dceaf4;
}

.progress-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-orange));
}

.summary-mini {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin-top: 14px;
  padding: 10px;
  border: 1px solid rgba(207, 225, 238, 0.78);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.76);
}

.summary-mini-copy {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.summary-mini-copy strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 850;
  line-height: 1.35;
}

.summary-mini-copy span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.learning-command {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.learning-hero {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(0, 1.42fr) minmax(270px, 0.78fr);
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid rgba(207, 225, 238, 0.9);
  border-radius: var(--radius);
  background:
    linear-gradient(120deg, rgba(0, 94, 158, 0.1), rgba(255, 255, 255, 0.78) 45%),
    linear-gradient(300deg, rgba(244, 122, 19, 0.12), rgba(255, 255, 255, 0) 42%),
    #fff;
  box-shadow: var(--shadow);
}

.learning-hero::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, var(--brand-blue), var(--green), var(--brand-yellow), var(--brand-orange));
}

.learning-hero::after {
  content: "";
  position: absolute;
  inset: 4px 0 0;
  background:
    repeating-linear-gradient(90deg, rgba(11, 111, 179, 0.08) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(180deg, rgba(244, 122, 19, 0.06) 0 1px, transparent 1px 24px),
    linear-gradient(115deg, transparent 0 42%, rgba(255, 255, 255, 0.5) 48%, transparent 54% 100%);
  background-size:
    auto,
    auto,
    220% 100%;
  opacity: 0.45;
  pointer-events: none;
  animation: learning-scan 7s linear infinite;
}

.learning-hero.is-good {
  border-color: rgba(20, 139, 106, 0.25);
}

.learning-hero.is-warn {
  border-color: rgba(255, 191, 61, 0.42);
}

.learning-hero.is-danger {
  border-color: rgba(255, 90, 61, 0.42);
  box-shadow: 0 18px 44px rgba(255, 90, 61, 0.12);
}

@keyframes learning-scan {
  from {
    background-position:
      0 0,
      0 0,
      180% 0;
  }

  to {
    background-position:
      0 0,
      0 0,
      -80% 0;
  }
}

.learning-hero-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 9px;
  min-width: 0;
}

.learning-eyebrow {
  margin: 0;
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.learning-hero h2 {
  margin: 0;
  color: var(--ink);
  font-size: 28px;
  font-weight: 900;
  line-height: 1.14;
}

.learning-hero-copy p:not(.learning-eyebrow),
.learning-hero-copy > span {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.55;
}

.learning-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.learning-action {
  min-height: 36px;
  border: 1px solid rgba(11, 111, 179, 0.24);
  border-radius: var(--radius);
  color: var(--accent-strong);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-soft);
  font-size: 12px;
  font-weight: 850;
  padding: 0 12px;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.learning-action:hover {
  border-color: rgba(244, 122, 19, 0.38);
  background: #fff8ef;
  transform: translateY(-1px);
}

.learning-pulse-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  max-width: 620px;
}

.pulse-badge {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid rgba(207, 225, 238, 0.82);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.pulse-badge::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--accent);
}

.pulse-badge.is-good::before {
  background: var(--green);
}

.pulse-badge.is-warn::before {
  background: var(--brand-yellow);
}

.pulse-badge.is-danger::before {
  background: var(--brand-coral);
}

.pulse-badge.is-muted::before {
  background: var(--muted-2);
}

.pulse-badge b {
  overflow: hidden;
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pulse-badge small {
  overflow: hidden;
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.course-donut-card {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.course-donut-card.is-compact {
  grid-template-columns: auto;
  gap: 0;
}

.course-donut {
  position: relative;
  display: grid;
  width: 168px;
  max-width: 100%;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  background: conic-gradient(var(--green) 0 var(--complete), var(--brand-yellow) var(--complete) var(--reserved-end), #dfeaf2 var(--reserved-end) 100%);
  box-shadow:
    inset 0 0 0 1px rgba(18, 48, 72, 0.06),
    0 14px 28px rgba(12, 86, 139, 0.12);
}

.course-donut::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  background:
    linear-gradient(180deg, #ffffff, #f8fbff);
  box-shadow: inset 0 0 0 1px rgba(207, 225, 238, 0.86);
}

.course-donut div {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 3px;
  text-align: center;
}

.course-donut strong {
  color: var(--ink);
  font-size: 34px;
  font-weight: 900;
  line-height: 1;
}

.course-donut span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
}

.course-donut-card.is-compact .course-donut {
  width: 88px;
  box-shadow: inset 0 0 0 1px rgba(18, 48, 72, 0.06);
}

.course-donut-card.is-compact .course-donut::before {
  inset: 11px;
}

.course-donut-card.is-compact .course-donut strong {
  font-size: 21px;
}

.course-donut-card.is-compact .course-donut span {
  font-size: 9px;
}

.course-donut-detail {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.course-donut-detail strong {
  color: var(--ink);
  font-size: 16px;
  font-weight: 900;
  line-height: 1.32;
}

.course-donut-detail > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.course-legend,
.health-legend,
.package-progress-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 10px;
  min-width: 0;
}

.course-legend span,
.health-legend span,
.package-progress-foot span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
}

.course-legend i,
.health-legend i {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
}

.legend-done,
.health-legend .is-reviewed {
  background: var(--green);
}

.legend-booked,
.health-legend .is-submitted {
  background: var(--brand-yellow);
}

.legend-left,
.health-legend .is-open {
  background: #c8d7e4;
}

.health-legend .is-attention {
  background: var(--brand-coral);
}

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

.learning-stat-card {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
}

.learning-stat-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--accent);
}

.learning-stat-card.is-good::before {
  background: var(--green);
}

.learning-stat-card.is-warn::before {
  background: var(--brand-yellow);
}

.learning-stat-card.is-danger::before {
  background: var(--brand-coral);
}

.learning-stat-card.is-muted::before {
  background: var(--muted-2);
}

.learning-stat-card b {
  color: var(--ink);
  font-size: 24px;
  font-weight: 900;
  line-height: 1;
}

.learning-stat-card span {
  color: var(--ink);
  font-size: 12px;
  font-weight: 850;
}

.learning-stat-card small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-prompt-hub {
  position: relative;
  overflow: hidden;
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(207, 225, 238, 0.88);
  border-radius: var(--radius);
  background:
    linear-gradient(120deg, rgba(0, 94, 158, 0.08), rgba(255, 255, 255, 0.74) 46%),
    linear-gradient(300deg, rgba(217, 47, 133, 0.08), rgba(255, 255, 255, 0) 38%),
    rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-soft);
}

.smart-prompt-hub::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-rose), var(--brand-orange));
}

.smart-prompt-head {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.smart-prompt-head strong {
  display: block;
  color: var(--ink);
  font-size: 17px;
  font-weight: 900;
  line-height: 1.25;
}

.smart-prompt-head span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.radar-status {
  flex: 0 0 auto;
  margin-top: 0 !important;
  padding: 5px 9px;
  border: 1px solid rgba(20, 139, 106, 0.24);
  border-radius: 999px;
  color: var(--green) !important;
  background: rgba(236, 251, 245, 0.92);
  font-size: 11px !important;
  font-weight: 900 !important;
  white-space: nowrap;
}

.smart-prompt-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.smart-prompt-card {
  position: relative;
  overflow: hidden;
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
  min-height: 154px;
  padding: 13px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-soft);
}

.smart-prompt-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: var(--accent);
}

.smart-prompt-card.is-good::before {
  background: var(--green);
}

.smart-prompt-card.is-warn::before {
  background: var(--brand-yellow);
}

.smart-prompt-card.is-danger::before {
  background: var(--brand-coral);
}

.smart-prompt-card.is-muted::before {
  background: var(--muted-2);
}

.smart-prompt-card > span {
  color: var(--brand-orange);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.smart-prompt-card strong {
  color: var(--ink);
  font-size: 14px;
  font-weight: 900;
  line-height: 1.32;
}

.smart-prompt-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.smart-prompt-action {
  align-self: end;
  min-height: 32px;
  margin-top: 2px;
  border: 1px solid rgba(11, 111, 179, 0.18);
  border-radius: var(--radius);
  color: var(--accent-strong);
  background: rgba(233, 246, 255, 0.92);
  font-size: 12px;
  font-weight: 850;
  padding: 0 10px;
}

.smart-prompt-action:hover {
  border-color: rgba(244, 122, 19, 0.34);
  color: #9e4d0f;
  background: #fff8ef;
}

.assignment-health {
  display: grid;
  grid-template-columns: minmax(180px, 0.34fr) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 13px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: var(--shadow-soft);
}

.assignment-health strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
}

.assignment-health span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.health-bar {
  display: flex;
  overflow: hidden;
  width: 100%;
  height: 12px;
  border-radius: 999px;
  background: #e2edf4;
}

.health-segment {
  min-width: 0;
  height: 100%;
}

.health-segment.is-reviewed {
  background: var(--green);
}

.health-segment.is-submitted {
  background: var(--brand-yellow);
}

.health-segment.is-open {
  background: #c8d7e4;
}

.health-segment.is-attention {
  background: var(--brand-coral);
}

.health-segment.is-empty {
  background: #e2edf4;
}

.health-legend {
  grid-column: 2;
}

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

.lesson-rail-item {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.84));
  text-align: left;
  box-shadow: var(--shadow-soft);
}

.lesson-rail-item.is-next {
  border-color: rgba(244, 122, 19, 0.45);
  background: linear-gradient(135deg, #fff8ef, #ffffff 58%);
}

.lesson-rail-item b {
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 900;
}

.lesson-rail-item span {
  overflow: hidden;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lesson-rail-item small {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.course-portfolio {
  display: grid;
  gap: 10px;
}

.course-profile-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(310px, auto);
  align-items: center;
  gap: 16px;
}

.package-progress-grid,
.parent-insight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.package-progress-card {
  display: grid;
  gap: 11px;
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.86));
  box-shadow: var(--shadow-soft);
}

.package-meter {
  display: flex;
  overflow: hidden;
  height: 10px;
  border-radius: 999px;
  background: #e2edf4;
}

.package-meter span {
  height: 100%;
}

.package-meter .is-used {
  background: var(--green);
}

.package-meter .is-reserved {
  background: var(--brand-yellow);
}

.parent-insight-grid {
  margin: 10px 0;
  grid-template-columns: minmax(0, 1.18fr) minmax(280px, 0.82fr);
}

.weekly-report-card .item-desc {
  max-height: 220px;
  overflow: auto;
}

.parent-focus-list {
  display: grid;
  gap: 8px;
}

.parent-focus-list p {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 10px;
  border: 1px solid var(--line-soft);
  border-left: 4px solid var(--brand-orange);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.76);
}

.parent-focus-list b {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
}

.parent-focus-list span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

@media (prefers-reduced-motion: reduce) {
  .learning-hero::after {
    animation: none;
  }

  .learning-action,
  .smart-prompt-action,
  .item-card,
  .tab {
    transition: none;
  }
}

.tabs {
  position: sticky;
  top: calc(8px + env(safe-area-inset-top));
  z-index: 10;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  width: 100%;
  margin: 12px 0 16px;
  padding: 7px 18px 7px 7px;
  border: 1px solid rgba(207, 225, 238, 0.92);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 250, 245, 0.92));
  backdrop-filter: blur(18px);
  scroll-padding-inline: 7px 18px;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar {
  display: none;
}

.tab {
  flex: 1 0 max-content;
  min-width: max-content;
  min-height: 38px;
  border: 0;
  border-radius: 7px;
  color: #c76012;
  background: transparent;
  font-size: 13px;
  font-weight: 800;
  padding: 0 16px;
  white-space: nowrap;
  transition:
    background 160ms ease,
    color 160ms ease,
    transform 160ms ease,
    box-shadow 160ms ease;
}

.tab:hover {
  color: #9e4d0f;
  background: rgba(244, 122, 19, 0.09);
}

.tab.is-active {
  color: #fff;
  background: var(--brand-orange);
  box-shadow: 0 8px 18px rgba(244, 122, 19, 0.22);
  transform: translateY(-1px);
}

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

.section-heading span {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stack {
  display: grid;
  gap: 10px;
}

.item-card,
.form-panel,
.profile-panel {
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.82)),
    var(--surface);
  box-shadow: var(--shadow-soft);
}

.item-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.item-card:hover {
  border-color: rgba(244, 122, 19, 0.26);
  box-shadow: 0 12px 26px rgba(12, 86, 139, 0.09);
  transform: translateY(-1px);
}

.item-topline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.item-title {
  min-width: 0;
  color: var(--ink);
  font-size: 15px;
  font-weight: 850;
  line-height: 1.4;
  word-break: break-word;
}

.item-meta,
.item-desc {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.48;
}

.item-desc {
  color: #4f6576;
  white-space: pre-wrap;
  word-break: break-word;
}

.assignment-image-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 8px;
}

.assignment-image-gallery figure {
  overflow: hidden;
  margin: 0;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.assignment-image-gallery img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: #eef5fa;
}

.assignment-image-gallery figcaption {
  overflow: hidden;
  padding: 6px 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.status-pill {
  flex: 0 0 auto;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.status-open {
  color: var(--accent-strong);
  border-color: #c9e8fa;
  background: #e9f6ff;
}

.status-done,
.status-reviewed {
  color: var(--green);
  border-color: #c7eadc;
  background: #ecfbf5;
}

.status-late,
.status-rework {
  color: var(--red);
  border-color: #ffd0d6;
  background: #fff0f2;
}

.status-submitted {
  color: var(--orange);
  border-color: #ffd7a8;
  background: var(--amber);
}

.action-row,
.payment-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.action-row button,
.payment-actions button,
.payment-actions label {
  flex: 1 1 132px;
}

.mini-action-row button {
  min-height: 32px;
  flex-basis: 96px;
  padding: 0 10px;
  font-size: 12px;
}

.payment-actions .primary-button,
.payment-actions .plain-button {
  width: auto;
}

.payment-channel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  align-items: start;
}

.payment-link-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  text-decoration: none;
}

.payment-qr-card,
.payment-channel-muted {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.payment-qr-card summary {
  display: flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
}

.payment-qr-card img {
  display: block;
  width: min(100%, 180px);
  aspect-ratio: 1;
  object-fit: contain;
  margin: 10px auto 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: #fff;
}

.payment-qr-placeholder {
  display: grid;
  gap: 6px;
  min-height: 126px;
  margin: 0 10px 10px;
  place-items: center;
  padding: 14px;
  border: 1px dashed #a9cadf;
  border-radius: var(--radius);
  background:
    linear-gradient(90deg, rgba(11, 111, 179, 0.06) 50%, transparent 50%),
    linear-gradient(rgba(11, 111, 179, 0.06) 50%, transparent 50%),
    #fff;
  background-size: 16px 16px;
  text-align: center;
}

.payment-qr-placeholder strong {
  color: var(--ink);
  font-size: 15px;
  font-weight: 900;
}

.payment-qr-placeholder span,
.payment-channel-muted,
.payment-admin-meta {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  word-break: break-word;
}

.payment-channel-muted {
  display: grid;
  place-items: center;
  padding: 8px 12px;
  text-align: center;
}

.payment-admin-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.payment-admin-meta span {
  padding: 5px 8px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface-soft);
}

.payment-admin-meta a {
  color: var(--accent-strong);
  font-weight: 850;
  text-decoration: none;
}

.upload-proof {
  display: grid;
  gap: 6px;
}

.template-card {
  align-content: start;
}

.template-card .plain-button {
  width: 100%;
}

.mini-log-list {
  display: grid;
  gap: 5px;
  padding-top: 7px;
  border-top: 1px solid var(--line-soft);
}

.mini-log-entry {
  display: grid;
  gap: 5px;
}

.check-row {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 11px;
  align-items: start;
}

.task-toggle {
  width: 100%;
  min-height: 0;
  border: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
  font: inherit;
  padding: 0;
  text-align: left;
}

.task-toggle:hover {
  border-color: rgba(0, 94, 158, 0.3);
  background: #f4fbff;
}

.check-box {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1.5px solid #bfd7e8;
  border-radius: var(--radius);
  color: #fff;
  background: #fff;
  font-size: 21px;
  font-weight: 800;
  line-height: 1;
  transition:
    background 150ms ease,
    border-color 150ms ease,
    transform 150ms ease;
}

.check-row.is-done .check-box {
  border-color: transparent;
  background: linear-gradient(135deg, var(--brand-blue), var(--cyan));
  transform: scale(1.02);
}

.check-row.is-done .item-title {
  color: var(--muted-2);
  text-decoration: line-through;
}

.check-row.is-done {
  border-color: rgba(0, 94, 158, 0.25);
  background: #f4fbff;
}

.form-panel,
.profile-panel {
  padding: 14px;
}

.form-grid {
  display: grid;
  gap: 11px;
}

.compact-form-grid {
  margin-top: 12px;
}

.form-subtitle {
  margin-top: 8px;
  padding-top: 11px;
  border-top: 1px solid var(--line-soft);
  color: var(--ink);
  font-size: 14px;
  font-weight: 850;
}

.form-hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

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

.toggle-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #ffffff, var(--surface-soft));
}

.toggle-line input {
  width: 18px;
  min-width: 18px;
  height: 18px;
  min-height: 18px;
  accent-color: var(--accent);
}

.toggle-line span {
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.finance-metrics {
  margin-bottom: 10px;
}

.lead-toolbar {
  margin: 0 0 12px;
}

.lead-toolbar .plain-button,
.lead-actions .primary-button,
.lead-actions .plain-button {
  width: auto;
}

.lead-card {
  gap: 14px;
}

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

.lead-meta-grid span {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--surface-soft);
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

.lead-meta-grid b {
  color: var(--muted);
  font-size: 12px;
}

.lead-message {
  white-space: pre-wrap;
}

.lead-followup-form {
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
}

.notification-banner-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.notification-banner {
  display: grid;
  gap: 3px;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #c9e8fa;
  border-radius: var(--radius);
  background: #f1f9ff;
  cursor: pointer;
  text-align: left;
}

.notification-banner strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.25;
}

.notification-banner span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.notification-banner.is-success {
  border-color: #c7eadc;
  background: #ecfbf5;
}

.notification-banner.is-warning {
  border-color: #ffd7a8;
  background: var(--amber);
}

.notification-banner.is-welcome {
  border-color: rgba(244, 122, 19, 0.24);
  background: linear-gradient(135deg, rgba(233, 246, 255, 0.94), rgba(255, 245, 233, 0.94));
}

.latest-news-panel {
  display: grid;
  gap: 10px;
  margin-bottom: 10px;
  overflow: hidden;
  border: 1px solid rgba(207, 225, 238, 0.92);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(233, 246, 255, 0.94), rgba(255, 245, 233, 0.96)),
    var(--surface);
  box-shadow: var(--shadow-soft);
}

.news-carousel {
  overflow: hidden;
}

.news-track {
  display: flex;
  transition: transform 420ms ease;
  will-change: transform;
}

.news-slide {
  display: grid;
  flex: 0 0 100%;
  grid-template-columns: minmax(180px, 0.44fr) minmax(0, 1fr);
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  gap: 8px 14px;
  min-width: 0;
  min-height: 230px;
  padding: 14px;
  border: 0;
  color: var(--ink);
  background: transparent;
  text-align: left;
}

.news-slide:hover {
  background: rgba(255, 255, 255, 0.52);
}

.news-visual {
  display: grid;
  grid-row: 1 / span 4;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  place-items: center;
  border: 1px solid rgba(207, 225, 238, 0.9);
  border-radius: var(--radius);
  background: var(--brand-gradient-soft);
}

.news-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-visual-placeholder {
  padding: 18px;
  color: #fff;
  text-align: center;
}

.news-visual-placeholder b {
  font-size: 18px;
  font-weight: 950;
  line-height: 1.2;
}

.news-visual-1 {
  background: linear-gradient(135deg, #005e9e, #0a8fb8);
}

.news-visual-2 {
  background: linear-gradient(135deg, #f47a13, #ffbf3d);
}

.news-visual-3 {
  background: linear-gradient(135deg, #5b4a62, #d92f85);
}

.news-visual-4 {
  background: linear-gradient(135deg, #148b6a, #0a8fb8);
}

.news-visual-5 {
  background: linear-gradient(135deg, #123048, #f47a13);
}

.news-kicker,
.news-summary,
.news-footer span,
.news-detail-summary,
.news-read-panel p {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.news-slide strong {
  color: var(--ink);
  font-size: 20px;
  font-weight: 950;
  line-height: 1.22;
  word-break: break-word;
}

.news-summary {
  color: #4f6576;
  font-weight: 750;
}

.news-slide .status-pill {
  justify-self: start;
}

.news-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 14px 12px;
}

.news-dots {
  display: flex;
  gap: 7px;
}

.news-dot {
  width: 9px;
  min-width: 9px;
  height: 9px;
  min-height: 9px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: #bdd2e2;
}

.news-dot.is-active {
  width: 24px;
  background: var(--brand-orange);
}

.news-admin-grid {
  display: grid;
  grid-template-columns: 168px minmax(0, 1fr);
  gap: 12px;
}

.news-admin-grid .news-visual {
  grid-row: auto;
  aspect-ratio: 4 / 3;
}

.news-image-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
  margin-top: 4px;
}

.news-image-form label {
  display: grid;
  gap: 5px;
}

.news-image-form span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.news-dialog-panel {
  width: min(780px, 100%);
}

.news-detail-visual .news-visual {
  grid-row: auto;
  aspect-ratio: 16 / 9;
}

.news-detail-summary {
  padding: 10px 12px;
  border: 1px solid #c9e8fa;
  border-radius: var(--radius);
  background: #f1f9ff;
}

.news-detail-content {
  color: #31495c;
  font-size: 14px;
  line-height: 1.72;
  white-space: pre-wrap;
  word-break: break-word;
}

.news-read-panel {
  display: grid;
  gap: 8px;
  align-items: start;
  padding: 10px 12px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: rgba(247, 251, 255, 0.86);
}

.lesson-reminder-popup {
  position: fixed;
  inset: calc(12px + env(safe-area-inset-top)) 12px auto;
  z-index: 50;
  display: flex;
  justify-content: center;
  pointer-events: none;
}

.edit-dialog {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: calc(18px + env(safe-area-inset-top)) 14px calc(18px + env(safe-area-inset-bottom));
  background: rgba(18, 48, 72, 0.34);
}

.lesson-reminder-panel {
  display: grid;
  gap: 11px;
  width: min(640px, 100%);
  padding: 14px;
  border: 1px solid rgba(244, 122, 19, 0.28);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(255, 246, 235, 0.96)),
    var(--surface);
  box-shadow: 0 18px 42px rgba(12, 86, 139, 0.2);
  pointer-events: auto;
}

.edit-dialog-panel {
  display: grid;
  gap: 12px;
  width: min(720px, 100%);
  max-height: min(86dvh, 760px);
  overflow: auto;
  padding: 15px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.96)),
    var(--surface);
  box-shadow: 0 24px 64px rgba(12, 86, 139, 0.24);
}

.lesson-reminder-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.lesson-reminder-head strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  font-weight: 900;
  line-height: 1.25;
}

.lesson-reminder-head span,
.lesson-reminder-note {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.lesson-reminder-list {
  display: grid;
  gap: 7px;
}

.lesson-reminder-list p {
  padding: 9px 10px;
  border: 1px solid #ffd7a8;
  border-radius: var(--radius);
  color: var(--ink);
  background: #fff8ef;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.45;
}

.icon-button {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  background: #fff;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}

.table-panel {
  overflow-x: auto;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.schedule-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
  font-size: 12px;
}

.schedule-table th,
.schedule-table td {
  padding: 10px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--muted);
  text-align: left;
  vertical-align: top;
}

.schedule-table th {
  color: var(--ink);
  background: var(--surface-soft);
  font-weight: 900;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.student-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.student-name {
  color: var(--ink);
  font-size: 17px;
  font-weight: 850;
  line-height: 1.3;
}

.student-tag {
  display: inline-block;
  margin-left: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.student-detail {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.42;
}

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

.timeline-item {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.72)),
    var(--surface);
}

.timeline-item::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--brand-blue), var(--brand-orange));
}

.timeline-week {
  color: var(--accent);
  font-size: 12px;
  font-weight: 850;
}

.calendar-toolbar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  margin-bottom: 12px;
}

.calendar-toolbar .plain-button {
  min-width: 0;
  padding: 0 6px;
}

.calendar-nav {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}

.calendar-nav strong {
  min-width: 0;
  color: var(--ink);
  font-size: 14px;
  font-weight: 850;
  text-align: center;
  line-height: 1.35;
}

.month-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.month-weekday {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-align: center;
}

.month-cell {
  position: relative;
  overflow: hidden;
  display: grid;
  align-content: start;
  min-width: 0;
  min-height: 78px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 7px 6px;
  color: var(--ink);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.7)),
    var(--surface);
  text-align: left;
}

.month-cell.is-today::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: var(--brand-hot-gradient);
}

.month-cell span {
  min-width: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
}

.month-cell small {
  overflow: hidden;
  min-width: 0;
  max-width: 100%;
  margin-top: 4px;
  color: var(--accent-strong);
  font-size: 9.5px;
  font-weight: 800;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.month-cell.is-muted {
  background: #f5f9fc;
}

.month-cell.is-muted span,
.month-cell.is-muted small {
  color: var(--muted-2);
}

.month-cell.is-today {
  border-color: var(--brand-orange);
  box-shadow: inset 0 0 0 1px rgba(244, 122, 19, 0.28);
}

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

.week-day {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, #ffffff, rgba(247, 251, 255, 0.72)),
    var(--surface);
  box-shadow: var(--shadow-soft);
}

.week-day.is-today {
  border-color: rgba(244, 122, 19, 0.48);
  box-shadow: 0 8px 18px rgba(244, 122, 19, 0.09);
}

.week-day.is-today::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--brand-hot-gradient);
}

.week-date b {
  display: block;
  color: var(--ink);
  font-size: 14px;
  font-weight: 850;
}

.week-date span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

.week-events {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.mini-lesson {
  display: grid;
  gap: 4px;
  padding: 9px;
  border: 1px solid #cfe6f6;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #eef8ff, #fff8ef);
}

.mini-lesson strong {
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.35;
}

.mini-lesson span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 1.35;
}

.empty-state {
  padding: 18px 14px;
  border: 1px dashed #bfd7e8;
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.86);
  font-size: 14px;
  line-height: 1.55;
}

.toast {
  position: fixed;
  right: 16px;
  bottom: calc(18px + env(safe-area-inset-bottom));
  left: 16px;
  z-index: 30;
  max-width: 620px;
  margin: 0 auto;
  padding: 13px 15px;
  border-radius: var(--radius);
  color: #fff;
  background: rgba(7, 74, 125, 0.96);
  box-shadow: 0 18px 38px rgba(12, 86, 139, 0.24);
  font-size: 14px;
  font-weight: 800;
  transform: translateY(140%);
  transition: transform 180ms ease;
}

.toast.is-visible {
  transform: translateY(0);
}

@media (max-width: 640px) {
  .app-shell {
    padding-right: 12px;
    padding-left: 12px;
  }

  .topbar {
    min-height: 118px;
    align-items: center;
    padding: 30px 54px 24px;
    border-radius: 18px;
  }

  .hero-brand {
    gap: 6px;
  }

  .hero-brand h1 {
    font-size: 30px;
  }

  .hero-brand p {
    font-size: 16px;
  }

  .ghost-button {
    min-height: 32px;
    padding: 0 10px;
    font-size: 12px;
  }

  .topbar-actions {
    top: 10px;
    right: 10px;
    gap: 6px;
  }

  .session-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .session-actions {
    flex-wrap: wrap;
  }

  h1 {
    font-size: 25px;
  }

  .control-strip {
    grid-template-columns: 1fr;
  }

  .tab {
    flex: 0 0 auto;
  }

  .news-slide,
  .news-admin-grid,
  .news-image-form {
    grid-template-columns: 1fr;
  }

  .news-slide {
    min-height: 0;
  }

  .news-visual {
    grid-row: auto;
  }

  .news-slide strong {
    font-size: 18px;
  }

  .news-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .lesson-reminder-popup {
    inset: calc(8px + env(safe-area-inset-top)) 8px auto;
  }

  .lesson-reminder-panel {
    max-height: calc(100dvh - 24px - env(safe-area-inset-top));
    overflow: auto;
  }

  .learning-hero,
  .course-profile-panel,
  .parent-insight-grid {
    grid-template-columns: 1fr;
  }

  .course-donut-card {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .learning-insight-grid,
  .package-progress-grid,
  .lesson-rail,
  .smart-prompt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .learning-pulse-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .learning-hero h2 {
    font-size: 23px;
  }
}

@media (max-width: 420px) {
  .metric-grid,
  .two-col,
  .payment-channel-grid,
  .permission-grid,
  .learning-insight-grid,
  .package-progress-grid,
  .lesson-rail,
  .smart-prompt-grid,
  .learning-pulse-strip {
    grid-template-columns: 1fr;
  }

  .summary-mini,
  .assignment-health,
  .course-donut-card {
    grid-template-columns: 1fr;
  }

  .summary-mini .course-donut-card {
    grid-template-columns: auto;
    justify-content: center;
  }

  .health-legend {
    grid-column: auto;
  }

  .course-donut {
    width: 146px;
  }

  .assignment-image-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .smart-prompt-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .smart-prompt-card {
    min-height: 0;
  }

  .student-row,
  .week-day {
    grid-template-columns: 1fr;
  }

  .student-row .plain-button {
    width: 100%;
  }

  .month-cell {
    min-height: 62px;
    padding: 5px 3px;
  }

  .month-cell small {
    font-size: 8.5px;
  }
}

@media (min-width: 760px) {
  .stack.desktop-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1080px) {
  .app-shell {
    padding-top: calc(24px + env(safe-area-inset-top));
  }

  .stack.desktop-grid.template-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.login-secondary-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

@media (max-width: 520px) {
  .login-secondary-actions {
    grid-template-columns: 1fr;
  }
}
