/* =========================================================
   班级作业管理系统 · 视觉样式
   Pure CSS · 响应式 · 无外部依赖
   ========================================================= */

:root {
  --bg: #f4f5fb;
  --surface: #ffffff;
  --surface-soft: #f8f9fe;
  --ink: #171a2e;
  --ink-soft: #353a55;
  --muted: #737a93;
  --muted-soft: #9aa0b5;
  --line: #e8eaf3;
  --line-strong: #dcdfeb;
  --brand: #4f46e5;
  --brand-dark: #4338ca;
  --brand-soft: #eef0ff;
  --teal: #0f9f8f;
  --teal-soft: #e8f8f4;
  --amber: #d99125;
  --amber-soft: #fff6e6;
  --violet: #8b5cf6;
  --violet-soft: #f3edff;
  --green: #169c6b;
  --green-soft: #e8f8f0;
  --danger: #e35268;
  --danger-soft: #fff0f2;
  --shadow-sm: 0 1px 2px rgba(25, 28, 56, 0.04), 0 4px 14px rgba(25, 28, 56, 0.035);
  --shadow-md: 0 12px 32px -12px rgba(32, 35, 80, 0.18), 0 2px 8px rgba(32, 35, 80, 0.04);
  --shadow-lg: 0 30px 70px -30px rgba(32, 35, 80, 0.32);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  background: var(--bg);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.modal-open {
  overflow: hidden;
}

button,
input,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

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

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid rgba(79, 70, 229, 0.28);
  outline-offset: 2px;
}

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

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
}

[hidden] {
  display: none !important;
}

::selection {
  color: #fff;
  background: var(--brand);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  background: #cdd1e1;
  border: 3px solid var(--bg);
  border-radius: 999px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

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

.icon--sm {
  width: 16px;
  height: 16px;
}

.icon--xs {
  width: 14px;
  height: 14px;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* =========================================================
   背景氛围
   ========================================================= */

.page-atmosphere {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(6px);
  opacity: 0.7;
}

.orb--one {
  width: 620px;
  height: 620px;
  top: -280px;
  right: -100px;
  background: radial-gradient(circle at 40% 40%, rgba(167, 158, 255, 0.32), rgba(167, 158, 255, 0));
}

.orb--two {
  width: 520px;
  height: 520px;
  bottom: -260px;
  left: -140px;
  background: radial-gradient(circle at 50% 50%, rgba(117, 222, 202, 0.2), rgba(117, 222, 202, 0));
}

.orb--three {
  width: 380px;
  height: 380px;
  top: 36%;
  left: 52%;
  background: radial-gradient(circle at 50% 50%, rgba(255, 210, 147, 0.13), rgba(255, 210, 147, 0));
}

#app {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}

/* =========================================================
   视图切换
   ========================================================= */

.view {
  display: none;
}

.view.is-active {
  display: block;
}

.view--landing {
  min-height: 100dvh;
}

.view--landing.is-active {
  display: flex;
}

.view--app {
  min-height: 100dvh;
}

.view--app.is-active {
  display: block;
  animation: viewIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes viewIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================================
   通用品牌 & 按钮
   ========================================================= */

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  position: relative;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 14px;
  color: #fff;
  background:
    radial-gradient(circle at 28% 20%, rgba(255, 255, 255, 0.32), transparent 38%),
    linear-gradient(145deg, #6560f0 0%, #4f46e5 45%, #3f35c8 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.32),
    0 8px 18px -8px rgba(79, 70, 229, 0.7);
}

.brand-mark::after {
  position: absolute;
  inset: 0;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: inherit;
}

.brand-mark .icon {
  width: 24px;
  height: 24px;
  stroke-width: 1.7;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.brand-copy strong {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.brand-copy small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
}

.brand--compact {
  gap: 10px;
}

.brand--compact .brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
}

.brand--compact .brand-mark .icon {
  width: 21px;
  height: 21px;
}

.brand--compact .brand-copy strong {
  font-size: 15.5px;
}

.brand--compact .brand-copy small {
  font-size: 9.5px;
}

.primary-button,
.secondary-button,
.ghost-button,
.outline-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  white-space: nowrap;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    background-color 0.18s ease,
    border-color 0.18s ease,
    color 0.18s ease;
}

.primary-button {
  min-height: 44px;
  padding: 11px 18px;
  color: #fff;
  border-radius: 12px;
  background: linear-gradient(135deg, #5a52ea 0%, #4f46e5 50%, #4338ca 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    0 10px 20px -10px rgba(79, 70, 229, 0.8);
  font-size: 14px;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.primary-button:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    0 15px 26px -12px rgba(79, 70, 229, 0.85);
}

.primary-button:active {
  transform: translateY(0);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  transform: none;
}

.secondary-button {
  min-height: 40px;
  padding: 9px 15px;
  color: var(--ink-soft);
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(23, 26, 46, 0.03);
  font-size: 13px;
  font-weight: 600;
}

.secondary-button:hover {
  color: var(--brand);
  border-color: #c9c5fa;
  background: #fafaff;
}

.ghost-button {
  min-height: 38px;
  padding: 8px 12px;
  color: var(--muted);
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  font-size: 13px;
  font-weight: 550;
}

.ghost-button:hover {
  color: var(--ink);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.8);
}

.outline-button {
  min-height: 38px;
  padding: 8px 13px;
  color: var(--brand);
  border: 1px solid #dcd9fd;
  border-radius: 10px;
  background: #f8f7ff;
  font-size: 12.5px;
  font-weight: 650;
}

.outline-button:hover {
  border-color: #bdb8fa;
  background: #f1efff;
  transform: translateY(-1px);
}

.required {
  color: var(--danger);
}

.field-optional {
  color: var(--muted-soft);
  font-size: 9.5px;
  font-weight: 500;
}

/* =========================================================
   角色选择页
   ========================================================= */

.landing-shell {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 1320px;
  min-height: 100dvh;
  margin: 0 auto;
  padding: 24px 48px 20px;
}

.landing-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 0;
}

.prototype-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  color: var(--muted);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(14px);
  font-size: 11.5px;
  font-weight: 550;
  letter-spacing: 0.02em;
}

.pulse-dot {
  position: relative;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.pulse-dot::after {
  position: absolute;
  inset: -3px;
  content: "";
  border: 1px solid rgba(22, 156, 107, 0.4);
  border-radius: 50%;
  animation: pulse 2s ease-out infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
    transform: scale(0.6);
  }
  80%,
  100% {
    opacity: 0;
    transform: scale(1.5);
  }
}

.landing-main {
  display: flex;
  flex: 1;
  align-items: center;
  padding: 30px 0 24px;
}

.hero {
  display: grid;
  width: 100%;
  grid-template-columns: minmax(0, 1.03fr) minmax(0, 0.97fr);
  align-items: center;
  gap: clamp(36px, 6vw, 92px);
}

.hero-copy {
  max-width: 640px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--brand);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-copy > .eyebrow {
  padding: 7px 11px;
  color: var(--brand);
  border: 1px solid #e1dfff;
  border-radius: 999px;
  background: rgba(246, 245, 255, 0.9);
  letter-spacing: 0.04em;
}

.hero-copy h1 {
  margin-top: 24px;
  font-size: clamp(52px, 6.3vw, 84px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.055em;
}

.gradient-text {
  display: inline-block;
  padding-right: 0.06em;
  color: transparent;
  background: linear-gradient(115deg, #5147e5 6%, #7b5de8 44%, #1b9e91 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-desc {
  max-width: 540px;
  margin-top: 26px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.85;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 36px;
}

.role-card {
  position: relative;
  display: flex;
  min-width: 0;
  align-items: flex-start;
  gap: 13px;
  padding: 17px;
  overflow: hidden;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow:
    0 2px 4px rgba(36, 39, 80, 0.03),
    0 18px 40px -25px rgba(36, 39, 80, 0.25);
  backdrop-filter: blur(16px);
  cursor: pointer;
  transition:
    transform 0.22s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}

.role-card::after {
  position: absolute;
  width: 100px;
  height: 100px;
  right: -46px;
  bottom: -58px;
  content: "";
  border-radius: 50%;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.role-card--teacher::after {
  background: rgba(112, 103, 243, 0.14);
}

.role-card--student::after {
  background: rgba(15, 159, 143, 0.13);
}

.role-card:hover {
  transform: translateY(-4px);
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 4px 8px rgba(36, 39, 80, 0.03),
    0 26px 48px -26px rgba(36, 39, 80, 0.34);
}

.role-card--teacher:hover {
  border-color: rgba(107, 98, 246, 0.5);
}

.role-card--student:hover {
  border-color: rgba(15, 159, 143, 0.4);
}

.role-card:hover::after {
  opacity: 1;
}

.role-card__icon {
  display: grid;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  border-radius: 14px;
}

.role-card--teacher .role-card__icon {
  background: linear-gradient(145deg, #756ef5, #4f46e5);
  box-shadow: 0 9px 18px -9px rgba(79, 70, 229, 0.8);
}

.role-card--student .role-card__icon {
  background: linear-gradient(145deg, #24b6a5, #0f9385);
  box-shadow: 0 9px 18px -9px rgba(15, 159, 143, 0.72);
}

.role-card__body {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 4px;
}

.role-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.role-card__title {
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.role-card__arrow {
  display: grid;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--muted-soft);
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.8);
  transition:
    color 0.2s ease,
    transform 0.2s ease,
    border-color 0.2s ease;
}

.role-card__arrow .icon {
  width: 13px;
  height: 13px;
}

.role-card:hover .role-card__arrow {
  border-color: transparent;
  color: #fff;
  transform: rotate(8deg);
}

.role-card--teacher:hover .role-card__arrow {
  background: var(--brand);
}

.role-card--student:hover .role-card__arrow {
  background: var(--teal);
}

.role-card__desc {
  overflow: hidden;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.55;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.landing-notes {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: 22px;
  color: var(--muted-soft);
  font-size: 11px;
}

.landing-notes span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.landing-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-top: 18px;
  color: var(--muted-soft);
  border-top: 1px solid rgba(219, 222, 238, 0.75);
  font-size: 10.5px;
  letter-spacing: 0.03em;
}

.landing-footer__dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #c7cad9;
}

/* 首屏预览 */
.hero-visual {
  position: relative;
  width: 100%;
  max-width: 530px;
  justify-self: end;
  padding: 34px 28px 42px;
  perspective: 1200px;
}

.preview-glow {
  position: absolute;
  inset: 6% -10% 2% 2%;
  z-index: -1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 64% 28%, rgba(122, 111, 250, 0.36), transparent 48%),
    radial-gradient(circle at 26% 80%, rgba(62, 202, 181, 0.22), transparent 46%);
  filter: blur(26px);
}

.preview-window {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 25px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow:
    0 40px 80px -36px rgba(41, 42, 98, 0.48),
    0 10px 26px rgba(41, 42, 98, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px);
  transform: rotate(-1.2deg);
  animation: previewFloat 8s ease-in-out infinite;
}

@keyframes previewFloat {
  0%,
  100% {
    transform: rotate(-1.2deg) translateY(0);
  }
  50% {
    transform: rotate(-0.5deg) translateY(-8px);
  }
}

.preview-topbar {
  display: flex;
  height: 46px;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  border-bottom: 1px solid rgba(232, 234, 243, 0.9);
  background: rgba(250, 250, 255, 0.75);
}

.traffic-dots {
  display: flex;
  gap: 5px;
}

.traffic-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e3e5ef;
}

.traffic-dots span:first-child {
  background: #ffb3b3;
}

.traffic-dots span:nth-child(2) {
  background: #f6d28c;
}

.traffic-dots span:nth-child(3) {
  background: #a8dfc5;
}

.preview-url {
  flex: 1;
  color: #a0a5b8;
  font-size: 9.5px;
  text-align: center;
  letter-spacing: 0.05em;
}

.preview-avatar {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  color: #fff;
  border-radius: 50%;
  background: linear-gradient(145deg, #7b74f0, #584fe3);
  font-size: 9px;
  font-weight: 700;
}

.preview-content {
  padding: 22px 22px 24px;
}

.preview-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.preview-heading > div {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.preview-kicker {
  color: var(--muted-soft);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.preview-heading strong {
  font-size: 21px;
  font-weight: 750;
  letter-spacing: -0.03em;
}

.preview-date {
  padding-bottom: 3px;
  color: #9ba0b3;
  font-size: 9px;
}

.preview-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 20px;
}

.preview-stat {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 11px 12px;
  overflow: hidden;
  border: 1px solid #eceef7;
  border-radius: 13px;
  background: #fff;
}

.preview-stat > span {
  color: #969cb2;
  font-size: 8.5px;
}

.preview-stat strong {
  font-size: 19px;
  font-weight: 750;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.preview-spark {
  position: absolute;
  width: 26px;
  height: 26px;
  right: -7px;
  bottom: -7px;
  border-radius: 50%;
  opacity: 0.28;
}

.preview-spark--indigo {
  background: #7067f3;
}

.preview-spark--teal {
  background: #19af9c;
}

.preview-spark--amber {
  background: #e8a638;
}

.preview-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 18px;
  padding: 5px;
  border: 1px solid #eef0f7;
  border-radius: 15px;
  background: rgba(250, 250, 255, 0.7);
}

.preview-item {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  padding: 9px 8px;
  border-radius: 11px;
}

.preview-item:hover {
  background: #fff;
}

.preview-check {
  display: grid;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  place-items: center;
  color: #7169e9;
  border: 1px solid #e4e2fd;
  border-radius: 9px;
  background: #f2f0ff;
}

.preview-check--done {
  color: #1a9f74;
  border-color: #d9f2e7;
  background: #ecfaf4;
}

.preview-check--amber {
  color: #d89733;
  border-color: #f8ead1;
  background: #fff8ea;
}

.preview-check .icon {
  width: 13px;
  height: 13px;
}

.preview-item__copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 1px;
}

.preview-item__copy strong {
  overflow: hidden;
  font-size: 10px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-item__copy span {
  color: #a0a5b7;
  font-size: 8px;
}

.mini-progress {
  width: 38px;
  height: 4px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 999px;
  background: #eeeff5;
}

.mini-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8d86f4, #5c54e8);
}

.float-card {
  position: absolute;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px 10px 10px;
  border: 1px solid rgba(255, 255, 255, 0.96);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow:
    0 18px 30px -18px rgba(36, 39, 80, 0.4),
    0 2px 6px rgba(36, 39, 80, 0.04);
  backdrop-filter: blur(12px);
}

.float-card--submitted {
  bottom: 4px;
  left: -8px;
  animation: floatSoft 7s ease-in-out infinite 0.6s;
}

.float-card--reminder {
  top: 12px;
  right: -18px;
  animation: floatSoft 7s ease-in-out infinite 1.6s;
}

@keyframes floatSoft {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.float-card__icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
}

.float-card__icon .icon {
  width: 17px;
  height: 17px;
}

.float-card__icon--green {
  color: #129a6a;
  background: var(--green-soft);
}

.float-card__icon--amber {
  color: #d18a20;
  background: var(--amber-soft);
}

.float-card > div {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.float-card strong {
  font-size: 12px;
  font-weight: 750;
  line-height: 1.3;
}

.float-card span:not(.float-card__icon) {
  color: var(--muted-soft);
  font-size: 9px;
}

.floating-badge {
  position: absolute;
  z-index: 2;
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: #6d65e8;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 12px 24px -14px rgba(36, 39, 80, 0.35);
  backdrop-filter: blur(12px);
  font-size: 11px;
  font-weight: 700;
}

.floating-badge--one {
  top: 32%;
  left: -14px;
  transform: rotate(-8deg);
}

.floating-badge--two {
  right: -4px;
  bottom: 22%;
  color: #109686;
  transform: rotate(7deg);
}

/* 首屏元素入场 */
.view--landing.is-active .hero-copy > * {
  animation: riseIn 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.view--landing.is-active .hero-copy > .eyebrow {
  animation-delay: 0.04s;
}

.view--landing.is-active .hero-copy > h1 {
  animation-delay: 0.1s;
}

.view--landing.is-active .hero-copy > .hero-desc {
  animation-delay: 0.16s;
}

.view--landing.is-active .hero-copy > .role-grid {
  animation-delay: 0.22s;
}

.view--landing.is-active .hero-copy > .landing-notes {
  animation-delay: 0.28s;
}

.view--landing.is-active .hero-visual {
  animation: riseIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================================
   登录后的应用框架
   ========================================================= */

.app-header {
  position: sticky;
  top: 0;
  z-index: 40;
  border-bottom: 1px solid rgba(225, 228, 240, 0.82);
  background: rgba(246, 247, 252, 0.8);
  backdrop-filter: blur(18px);
}

.app-header__inner {
  display: flex;
  width: 100%;
  max-width: 1200px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 auto;
  padding: 12px 32px;
}

.app-header__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.identity-pill {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 5px 7px 5px 5px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 2px 10px rgba(30, 33, 66, 0.035);
}

.avatar {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
}

.avatar--teacher {
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.25), transparent 42%),
    linear-gradient(145deg, #7770f1, #4f46e5);
  box-shadow: 0 4px 10px -4px rgba(79, 70, 229, 0.6);
}

.avatar--student {
  background:
    radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.25), transparent 42%),
    linear-gradient(145deg, #31b9a7, #0e9285);
  box-shadow: 0 4px 10px -4px rgba(15, 159, 143, 0.55);
}

.identity-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.3;
}

.identity-copy strong {
  font-size: 12.5px;
  font-weight: 650;
}

.identity-copy small {
  color: var(--muted-soft);
  font-size: 9.5px;
}

.role-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 650;
}

.role-badge--teacher {
  color: var(--brand);
  background: var(--brand-soft);
}

.role-badge--student {
  color: var(--teal);
  background: var(--teal-soft);
}

.app-main {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 38px 32px 42px;
}

.welcome-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.welcome-copy h1 {
  margin-top: 10px;
  font-size: clamp(29px, 3.5vw, 37px);
  font-weight: 780;
  line-height: 1.25;
  letter-spacing: -0.035em;
}

.welcome-copy p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 13.5px;
}

.eyebrow-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.eyebrow-dot--teal {
  background: var(--teal);
  box-shadow: 0 0 0 3px rgba(15, 159, 143, 0.1);
}

.eyebrow-separator {
  width: 1px;
  height: 10px;
  background: var(--line-strong);
}

.wave {
  display: inline-block;
  font-size: 0.8em;
  transform-origin: 70% 70%;
  animation: wave 2.4s ease-in-out infinite;
}

@keyframes wave {
  0%,
  60%,
  100% {
    transform: rotate(0);
  }
  68% {
    transform: rotate(14deg);
  }
  76% {
    transform: rotate(-6deg);
  }
  84% {
    transform: rotate(10deg);
  }
  92% {
    transform: rotate(-2deg);
  }
}

.primary-button--hero {
  flex: 0 0 auto;
  margin-bottom: 2px;
}

/* 统计卡 */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 28px;
}

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

.stat-card {
  position: relative;
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 13px;
  padding: 17px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.96);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow:
    0 1px 2px rgba(24, 27, 54, 0.025),
    0 10px 26px -22px rgba(24, 27, 54, 0.22);
}

.stat-card__icon {
  display: grid;
  width: 43px;
  height: 43px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 13px;
}

.stat-card__icon .icon {
  width: 20px;
  height: 20px;
}

.stat-card--indigo .stat-card__icon {
  color: var(--brand);
  background: var(--brand-soft);
}

.stat-card--teal .stat-card__icon {
  color: var(--teal);
  background: var(--teal-soft);
}

.stat-card--amber .stat-card__icon {
  color: var(--amber);
  background: var(--amber-soft);
}

.stat-card--violet .stat-card__icon {
  color: var(--violet);
  background: var(--violet-soft);
}

.stat-card__body {
  display: flex;
  min-width: 0;
  flex-direction: column;
  line-height: 1.2;
}

.stat-card__label {
  overflow: hidden;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 550;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-card__value {
  margin: 3px 0 2px;
  font-size: 28px;
  font-weight: 780;
  line-height: 1;
  letter-spacing: -0.04em;
}

.stat-card__foot {
  overflow: hidden;
  color: var(--muted-soft);
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stat-card__decor {
  position: absolute;
  width: 72px;
  height: 72px;
  right: -36px;
  bottom: -42px;
  border-radius: 50%;
  opacity: 0.1;
}

.stat-card--indigo .stat-card__decor {
  background: var(--brand);
}

.stat-card--teal .stat-card__decor {
  background: var(--teal);
}

.stat-card--amber .stat-card__decor {
  background: var(--amber);
}

.stat-card--violet .stat-card__decor {
  background: var(--violet);
}

/* 区块标题 */
.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.section-heading h2 {
  margin-top: 5px;
  font-size: 21px;
  font-weight: 750;
  letter-spacing: -0.025em;
}

.section-heading p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12.5px;
}

.section-heading--workspace {
  align-items: center;
  margin-bottom: 16px;
}

.teacher-workspace {
  margin-top: 38px;
}

.soft-count {
  flex: 0 0 auto;
  padding: 5px 10px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  font-size: 10.5px;
  font-weight: 550;
}

/* 标签页 */
.tab-switch {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 3px;
  padding: 4px;
  border: 1px solid rgba(229, 231, 241, 0.95);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.65);
}

.tab-button {
  display: inline-flex;
  min-height: 35px;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  color: var(--muted);
  border: 0;
  border-radius: 9px;
  background: transparent;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.tab-button:hover {
  color: var(--ink-soft);
}

.tab-button.is-active {
  color: var(--brand-dark);
  background: #fff;
  box-shadow:
    0 1px 3px rgba(25, 28, 56, 0.08),
    0 5px 12px -8px rgba(25, 28, 56, 0.3);
}

.tab-panel {
  animation: panelIn 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes panelIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 工作区网格和卡片 */
.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(0, 0.88fr);
  align-items: stretch;
  gap: 16px;
}

.card {
  border: 1px solid rgba(255, 255, 255, 0.98);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 1px 2px rgba(24, 27, 54, 0.02),
    0 14px 38px -32px rgba(24, 27, 54, 0.28);
}

.form-card {
  padding: 25px;
}

.card-heading {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.card-heading__icon {
  display: grid;
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 12px;
}

.card-heading__icon .icon {
  width: 19px;
  height: 19px;
}

.card-heading__icon--indigo {
  color: var(--brand);
  background: var(--brand-soft);
}

.card-heading__icon--teal {
  color: var(--teal);
  background: var(--teal-soft);
}

.card-heading h3 {
  font-size: 16px;
  font-weight: 720;
  letter-spacing: -0.015em;
}

.card-heading p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.card-heading-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.card-heading-row h3 {
  font-size: 16px;
  font-weight: 720;
  letter-spacing: -0.015em;
}

.card-heading-row p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

/* 表单 */
.publish-form {
  margin-top: 22px;
}

.field + .field {
  margin-top: 17px;
}

.field label {
  display: inline-block;
  margin-bottom: 7px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 650;
}

.label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.label-row label {
  margin-bottom: 7px;
}

.char-count {
  margin-bottom: 7px;
  color: var(--muted-soft);
  font-size: 9.5px;
  font-variant-numeric: tabular-nums;
}

.text-input {
  display: block;
  width: 100%;
  min-height: 44px;
  padding: 10px 13px;
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  background: #fcfcff;
  font-size: 13px;
  line-height: 1.5;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

.text-input::placeholder {
  color: #a8adbf;
}

.text-input:hover {
  border-color: #cfd3e3;
}

.text-input:focus {
  border-color: #8b84f4;
  outline: none;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.09);
}

.textarea {
  min-height: 124px;
  resize: vertical;
}

.input-with-icon {
  position: relative;
}

.input-with-icon > .icon {
  position: absolute;
  top: 50%;
  left: 13px;
  z-index: 2;
  color: var(--muted-soft);
  transform: translateY(-50%);
  pointer-events: none;
}

.input-with-icon .text-input {
  padding-left: 38px;
}

.input-with-icon .text-input:focus + .icon,
.input-with-icon:focus-within > .icon {
  color: var(--brand);
}

.field.is-invalid .text-input {
  border-color: #f1a6b2;
  background: #fffafb;
  box-shadow: 0 0 0 3px rgba(227, 82, 104, 0.07);
}

.field-error {
  margin-top: 5px;
  color: var(--danger);
  font-size: 10.5px;
}

.form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.form-hint {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--muted-soft);
  font-size: 10px;
  line-height: 1.5;
}

.form-hint .icon {
  color: var(--brand);
}

.form-hint--center {
  justify-content: center;
  margin-top: 13px;
  text-align: center;
}

/* 提示卡 */
.tips-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 24px;
  overflow: hidden;
  color: #fff;
  border: 0;
  background:
    radial-gradient(circle at 92% 8%, rgba(135, 124, 255, 0.44), transparent 36%),
    radial-gradient(circle at 8% 94%, rgba(30, 188, 166, 0.2), transparent 42%),
    linear-gradient(150deg, #1a1c33 0%, #242443 55%, #292453 100%);
  box-shadow:
    0 24px 46px -30px rgba(25, 27, 54, 0.65),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.tips-card::before {
  position: absolute;
  width: 240px;
  height: 240px;
  top: -150px;
  right: -100px;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
}

.tips-card::after {
  position: absolute;
  width: 160px;
  height: 160px;
  top: -110px;
  right: -60px;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 50%;
}

.tips-card__top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tips-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  color: #dedbff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  font-size: 9.5px;
  font-weight: 650;
}

.local-tag {
  color: rgba(255, 255, 255, 0.44);
  font-size: 9px;
  letter-spacing: 0.04em;
}

.tips-card h3 {
  position: relative;
  z-index: 1;
  margin-top: 18px;
  font-size: 21px;
  font-weight: 700;
  line-height: 1.42;
  letter-spacing: -0.02em;
}

.tips-list {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 13px;
  margin-top: 20px;
}

.tips-list li {
  display: flex;
  gap: 11px;
  align-items: flex-start;
}

.tips-list li > span {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  place-items: center;
  color: #bcb7ff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.055);
  font-size: 8.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.tips-list li div {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.tips-list strong {
  color: rgba(255, 255, 255, 0.9);
  font-size: 12.5px;
  font-weight: 650;
}

.tips-list p {
  color: rgba(255, 255, 255, 0.52);
  font-size: 11px;
  line-height: 1.6;
}

.tips-note {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-top: auto;
  padding-top: 19px;
  color: rgba(255, 255, 255, 0.4);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 9.5px;
  line-height: 1.65;
}

.tips-note .icon {
  margin-top: 1px;
  color: rgba(255, 255, 255, 0.55);
}

/* 上传区 */
.upload-zone {
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  min-height: 276px;
  margin-top: 22px;
  padding: 28px;
  text-align: center;
  border: 1.5px dashed #d5d9e9;
  border-radius: 17px;
  background:
    radial-gradient(circle at 50% 12%, rgba(79, 70, 229, 0.045), transparent 42%),
    #fafbff;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    transform 0.2s ease;
}

.upload-zone:hover,
.upload-zone.is-dragging {
  border-color: #9d97f4;
  background: #f7f6ff;
}

.upload-zone.is-dragging {
  transform: scale(1.008);
}

.upload-zone__icon {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  margin-bottom: 13px;
  color: var(--brand);
  border: 1px solid #e2dfff;
  border-radius: 18px;
  background: linear-gradient(145deg, #faf9ff, #eeecff);
  box-shadow: 0 10px 24px -16px rgba(79, 70, 229, 0.45);
}

.upload-zone__icon .icon {
  width: 27px;
  height: 27px;
}

.upload-zone strong {
  font-size: 14px;
  font-weight: 650;
}

.upload-zone > span:not(.upload-zone__icon) {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10.5px;
}

.upload-zone .secondary-button {
  margin-top: 17px;
}

/* 课件列表 */
.materials-card {
  display: flex;
  flex-direction: column;
  padding: 23px;
}

.count-pill {
  flex: 0 0 auto;
  padding: 4px 9px;
  color: var(--teal);
  border-radius: 999px;
  background: var(--teal-soft);
  font-size: 9.5px;
  font-weight: 650;
}

.courseware-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 17px;
}

.materials-empty {
  display: flex;
  min-height: 215px;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  padding: 20px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  background: #fbfcff;
}

.materials-empty__icon {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  color: var(--muted-soft);
  border-radius: 13px;
  background: #f1f3f9;
}

.materials-empty__icon .icon {
  width: 21px;
  height: 21px;
}

.materials-empty strong {
  margin-top: 10px;
  font-size: 12px;
  font-weight: 650;
}

.materials-empty p {
  max-width: 190px;
  margin-top: 3px;
  color: var(--muted);
  font-size: 9.5px;
  line-height: 1.65;
}

.courseware-item {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 10px;
  padding: 9px;
  border: 1px solid transparent;
  border-radius: 12px;
  transition:
    background 0.18s ease,
    border-color 0.18s ease;
}

.courseware-item:hover {
  border-color: var(--line);
  background: var(--surface-soft);
}

.courseware-item__icon {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 10px;
  font-size: 8px;
  font-weight: 750;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.courseware-item__icon--pdf {
  color: #e44f5e;
  background: #fff0f1;
}

.courseware-item__icon--ppt,
.courseware-item__icon--pptx {
  color: #dd7922;
  background: #fff3e7;
}

.courseware-item__icon--doc,
.courseware-item__icon--docx {
  color: #3977dc;
  background: #edf4ff;
}

.courseware-item__icon--img {
  color: #8a5cdb;
  background: #f4edff;
}

.courseware-item__icon--other {
  color: #5d6b8e;
  background: #eff2f8;
}

.courseware-item__body {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 1px;
}

.courseware-item__name {
  overflow: hidden;
  font-size: 12.5px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.courseware-item__meta {
  color: var(--muted-soft);
  font-size: 10px;
}

.icon-button {
  display: grid;
  width: 29px;
  height: 29px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--muted-soft);
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease;
}

.icon-button:hover {
  color: var(--danger);
  border-color: #f5dce2;
  background: var(--danger-soft);
}

.icon-button--soft:hover {
  color: var(--brand);
  border-color: #e3e0fd;
  background: var(--brand-soft);
}

.icon-button .icon {
  width: 14px;
  height: 14px;
}

/* =========================================================
   作业列表
   ========================================================= */

.assignments-section {
  margin-top: 40px;
}

.assignment-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.assignment-card {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.98);
  border-radius: 19px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow:
    0 1px 2px rgba(24, 27, 54, 0.025),
    0 12px 30px -28px rgba(24, 27, 54, 0.32);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.assignment-card::before {
  position: absolute;
  height: 3px;
  top: 0;
  right: 20px;
  left: 20px;
  content: "";
  border-radius: 0 0 4px 4px;
  background: linear-gradient(90deg, transparent, rgba(79, 70, 229, 0.22), transparent);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.assignment-card:hover {
  transform: translateY(-2px);
  border-color: rgba(226, 226, 248, 0.98);
  box-shadow:
    0 2px 4px rgba(24, 27, 54, 0.025),
    0 24px 40px -30px rgba(24, 27, 54, 0.36);
}

.assignment-card:hover::before {
  opacity: 1;
}

.assignment-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.subject-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 7px;
  font-size: 9.5px;
  font-weight: 650;
  letter-spacing: 0.02em;
}

.subject-chip::before {
  width: 4px;
  height: 4px;
  content: "";
  border-radius: 50%;
  background: currentColor;
}

.subject-chip--chinese {
  color: #b55d45;
  background: #fff1ec;
}

.subject-chip--math {
  color: #3570ce;
  background: #edf4ff;
}

.subject-chip--english {
  color: #7c54bf;
  background: #f3edff;
}

.subject-chip--science {
  color: #188e78;
  background: #eaf8f4;
}

.subject-chip--default {
  color: #5f6883;
  background: #f0f2f8;
}

.status-badge {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 650;
  white-space: nowrap;
}

.status-badge::before {
  width: 5px;
  height: 5px;
  content: "";
  border-radius: 50%;
  background: currentColor;
}

.status-badge--open {
  color: #5370d8;
  background: #eef2ff;
}

.status-badge--urgent {
  color: #ce8318;
  background: #fff4e1;
}

.status-badge--overdue {
  color: #d25267;
  background: #fff0f2;
}

.status-badge--submitted {
  color: #158c63;
  background: #e9f8f0;
}

.assignment-card__title {
  margin-top: 13px;
  overflow: hidden;
  font-size: 16px;
  font-weight: 720;
  line-height: 1.45;
  letter-spacing: -0.015em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.assignment-card__requirement {
  display: -webkit-box;
  margin-top: 6px;
  overflow: hidden;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.7;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.assignment-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin-top: 13px;
  padding: 10px 0;
  border-top: 1px dashed var(--line);
  border-bottom: 1px dashed var(--line);
  color: var(--muted);
  font-size: 11px;
}

.assignment-card__meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.assignment-card__meta .icon {
  color: var(--muted-soft);
}

.assignment-card__meta .meta-urgent {
  color: #cc7f12;
  font-weight: 600;
}

.assignment-card__meta .meta-overdue {
  color: var(--danger);
  font-weight: 600;
}

.assignment-card__meta .meta-relative {
  color: var(--muted-soft);
}

.assignment-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 15px;
}

.submission-summary {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
}

.avatar-stack {
  display: flex;
  flex: 0 0 auto;
  padding-left: 7px;
}

.stack-avatar {
  display: grid;
  width: 24px;
  height: 24px;
  place-items: center;
  margin-left: -7px;
  color: #fff;
  border: 2px solid #fff;
  border-radius: 50%;
  font-size: 8px;
  font-weight: 650;
}

.stack-avatar--count {
  color: var(--muted);
  background: #eff1f7;
}

.submission-summary__copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  color: var(--muted-soft);
  font-size: 10px;
  line-height: 1.45;
}

.submission-summary__copy strong {
  color: var(--ink-soft);
  font-size: 11.5px;
  font-weight: 650;
}

.assignment-card__actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}

/* 学生端 */
.assignments-section--student {
  margin-top: 36px;
}

.section-heading--filters {
  align-items: center;
}

.filter-switch {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 2px;
  padding: 4px;
  border: 1px solid rgba(229, 231, 241, 0.95);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.65);
}

.filter-button {
  display: inline-flex;
  min-height: 31px;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  color: var(--muted);
  border: 0;
  border-radius: 8px;
  background: transparent;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.filter-button span {
  display: grid;
  min-width: 16px;
  height: 16px;
  place-items: center;
  padding: 0 4px;
  border-radius: 999px;
  background: rgba(115, 122, 147, 0.08);
  font-size: 8.5px;
  font-variant-numeric: tabular-nums;
}

.filter-button:hover {
  color: var(--ink-soft);
}

.filter-button.is-active {
  color: var(--brand-dark);
  background: #fff;
  box-shadow:
    0 1px 3px rgba(25, 28, 56, 0.08),
    0 5px 12px -8px rgba(25, 28, 56, 0.3);
}

.filter-button.is-active span {
  color: var(--brand);
  background: var(--brand-soft);
}

.student-assignment-card {
  padding: 22px;
}

.student-assignment-card.is-submitted {
  border-color: rgba(218, 241, 231, 0.98);
  background:
    linear-gradient(180deg, rgba(250, 255, 252, 0.94), rgba(255, 255, 255, 0.92));
}

.student-assignment-card.is-submitted::before {
  background: linear-gradient(90deg, transparent, rgba(21, 140, 99, 0.35), transparent);
  opacity: 1;
}

.student-assignment-card .assignment-card__title {
  margin-top: 14px;
  font-size: 17px;
}

.student-assignment-card .assignment-card__requirement {
  min-height: 39px;
  -webkit-line-clamp: 2;
}

.student-assignment-card .assignment-card__footer {
  align-items: flex-end;
}

.student-due {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 2px;
}

.student-due span {
  color: var(--muted-soft);
  font-size: 9px;
}

.student-due strong {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--ink-soft);
  font-size: 10.5px;
  font-weight: 600;
}

.student-due strong.is-urgent {
  color: #c47d14;
}

.student-due strong.is-overdue {
  color: var(--danger);
}

.student-due .icon {
  color: var(--muted-soft);
}

.student-due strong.is-urgent .icon {
  color: #c47d14;
}

.student-due strong.is-overdue .icon {
  color: var(--danger);
}

.submit-button {
  min-height: 37px;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 12px;
}

.submitted-state {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 10px;
  color: var(--green);
  border: 1px solid #d8f1e5;
  border-radius: 9px;
  background: #f1fbf6;
  font-size: 10.5px;
  font-weight: 650;
  white-space: nowrap;
}

.submitted-state .icon {
  width: 14px;
  height: 14px;
}

.submitted-time {
  display: block;
  margin-top: 2px;
  color: var(--muted-soft);
  font-size: 8.5px;
  font-weight: 400;
}

.submit-button:disabled {
  color: var(--muted-soft);
  border: 1px solid var(--line);
  background: #f5f6fa;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

/* 空状态 */
.empty-state {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  min-height: 220px;
  padding: 32px 24px;
  text-align: center;
  border: 1px dashed var(--line-strong);
  border-radius: 19px;
  background: rgba(255, 255, 255, 0.55);
}

.empty-state__icon {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  color: var(--muted-soft);
  border-radius: 16px;
  background: #f1f3f9;
}

.empty-state__icon .icon {
  width: 24px;
  height: 24px;
}

.empty-state h3 {
  margin-top: 13px;
  font-size: 14px;
  font-weight: 650;
}

.empty-state p {
  max-width: 300px;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

/* 周进度 */
.weekly-progress {
  width: 220px;
  flex: 0 0 auto;
  margin-bottom: 4px;
  padding: 12px 15px;
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 8px 22px -20px rgba(24, 27, 54, 0.3);
}

.weekly-progress__copy {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}

.weekly-progress__copy > span {
  color: var(--muted);
  font-size: 10px;
}

.weekly-progress__copy strong {
  font-size: 16px;
  font-weight: 750;
  line-height: 1;
}

.weekly-progress__copy small {
  color: var(--muted-soft);
  font-size: 10px;
  font-weight: 500;
}

.progress-bar {
  height: 5px;
  margin-top: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #edeef6;
}

.progress-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2db7a5, #148c80);
  transition: width 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

/* =========================================================
   页脚
   ========================================================= */

.app-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 44px;
  padding-top: 18px;
  color: var(--muted-soft);
  border-top: 1px solid var(--line);
  font-size: 9.5px;
  letter-spacing: 0.02em;
}

/* =========================================================
   模态框
   ========================================================= */

.modal-root {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  overflow-y: auto;
  background: rgba(18, 20, 38, 0.52);
  backdrop-filter: blur(7px);
  animation: overlayIn 0.2s ease both;
}

@keyframes overlayIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-card {
  display: flex;
  width: min(600px, 100%);
  max-height: calc(100dvh - 48px);
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: 23px;
  background: #fff;
  box-shadow: 0 40px 90px -30px rgba(10, 12, 30, 0.55);
  animation: modalIn 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.modal-card--wide {
  width: min(740px, 100%);
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.975);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

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

.modal-header__copy {
  min-width: 0;
}

.modal-header__eyebrow {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--brand);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.modal-header h2 {
  margin-top: 4px;
  font-size: 20px;
  font-weight: 750;
  line-height: 1.35;
  letter-spacing: -0.025em;
}

.modal-header p {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11.5px;
}

.modal-close {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  cursor: pointer;
  transition:
    color 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

.modal-close:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: var(--surface-soft);
}

.modal-close .icon {
  width: 16px;
  height: 16px;
}

.modal-body {
  min-height: 0;
  padding: 20px 24px;
  overflow-y: auto;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  padding: 15px 24px;
  border-top: 1px solid var(--line);
  background: #fcfcff;
}

.modal-assignment-brief {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 13px;
  border: 1px solid #eeeefe;
  border-radius: 12px;
  background: #fafaff;
}

.modal-assignment-brief > span {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--brand);
  border-radius: 8px;
  background: var(--brand-soft);
}

.modal-assignment-brief .icon {
  width: 14px;
  height: 14px;
}

.modal-assignment-brief > div {
  min-width: 0;
}

.modal-assignment-brief strong {
  display: block;
  overflow: hidden;
  font-size: 12.5px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.modal-assignment-brief p {
  display: -webkit-box;
  margin-top: 2px;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.modal-form {
  margin-top: 17px;
}

.modal-form .field + .field {
  margin-top: 15px;
}

.modal-upload {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 62px;
  padding: 11px 13px;
  border: 1.5px dashed #d8dbea;
  border-radius: 12px;
  background: #fbfbff;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    background 0.18s ease;
}

.modal-upload:hover,
.modal-upload.is-dragging {
  border-color: #9d97f4;
  background: #f8f7ff;
}

.modal-upload__icon {
  display: grid;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--brand);
  border-radius: 10px;
  background: var(--brand-soft);
}

.modal-upload__icon .icon {
  width: 17px;
  height: 17px;
}

.modal-upload__copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 1px;
}

.modal-upload__copy strong {
  font-size: 12px;
  font-weight: 600;
}

.modal-upload__copy span {
  color: var(--muted-soft);
  font-size: 10px;
}

.modal-upload__action {
  flex: 0 0 auto;
  padding: 5px 9px;
  color: var(--brand);
  border: 1px solid #dfdcfd;
  border-radius: 7px;
  background: #fff;
  font-size: 10px;
  font-weight: 650;
}

.file-selected {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  border: 1px solid #dcefe7;
  border-radius: 10px;
  background: #f7fdf9;
}

.file-selected__icon {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--green);
  border-radius: 8px;
  background: var(--green-soft);
}

.file-selected__icon .icon {
  width: 14px;
  height: 14px;
}

.file-selected__copy {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 1px;
}

.file-selected__copy strong {
  overflow: hidden;
  font-size: 10.5px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-selected__copy span {
  color: var(--muted-soft);
  font-size: 8.5px;
}

.file-selected .icon-button:hover {
  color: var(--danger);
  border-color: #f5dce2;
  background: var(--danger-soft);
}

.modal-tip {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  margin-top: 13px;
  color: var(--muted-soft);
  font-size: 9px;
  line-height: 1.6;
}

.modal-tip .icon {
  margin-top: 1px;
  color: var(--muted-soft);
}

.modal-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
  background: #fbfbfe;
}

.summary-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  font-size: 9.5px;
  font-weight: 550;
}

.summary-chip strong {
  color: var(--ink-soft);
  font-weight: 650;
}

.submission-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.submission-item {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.submission-item__top {
  display: flex;
  align-items: center;
  gap: 9px;
}

.submission-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  place-items: center;
  color: #fff;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 650;
}

.submission-item__who {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 1px;
}

.submission-item__who strong {
  font-size: 12.5px;
  font-weight: 650;
}

.submission-item__who span {
  color: var(--muted-soft);
  font-size: 9.5px;
}

.submission-item__time {
  flex: 0 0 auto;
  padding: 3px 7px;
  color: var(--muted-soft);
  border-radius: 5px;
  background: #f6f7fb;
  font-size: 9px;
}

.submission-item__content {
  margin-top: 9px;
  padding: 10px 12px;
  color: var(--ink-soft);
  border-left: 2px solid #ddd9fe;
  border-radius: 0 8px 8px 0;
  background: #fbfaff;
  font-size: 11.5px;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
}

.submission-item__file {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  padding: 4px 8px;
  color: var(--brand);
  border: 1px solid #e5e2fd;
  border-radius: 6px;
  background: #f8f7ff;
  font-size: 8.5px;
}

.submission-item__file span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.submission-item__file .icon {
  width: 11px;
  height: 11px;
}

.modal-empty {
  display: flex;
  align-items: center;
  flex-direction: column;
  justify-content: center;
  min-height: 210px;
  padding: 24px;
  text-align: center;
}

.modal-empty__icon {
  display: grid;
  width: 50px;
  height: 50px;
  place-items: center;
  color: var(--muted-soft);
  border-radius: 15px;
  background: #f3f4fa;
}

.modal-empty__icon .icon {
  width: 22px;
  height: 22px;
}

.modal-empty h3 {
  margin-top: 12px;
  font-size: 13px;
  font-weight: 650;
}

.modal-empty p {
  max-width: 280px;
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
}

/* 我的提交回看 */
.my-submission {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #dff1e8;
  border-radius: 13px;
  background: #f9fdfb;
}

.my-submission__label {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--green);
  font-size: 9.5px;
  font-weight: 650;
}

.my-submission__label .icon {
  width: 13px;
  height: 13px;
}

.my-submission p {
  margin-top: 7px;
  color: var(--ink-soft);
  font-size: 11.5px;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
}

.my-submission__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 9px;
  color: var(--muted-soft);
  font-size: 8.5px;
}

/* =========================================================
   Toast
   ========================================================= */

.toast-region {
  position: fixed;
  z-index: 120;
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  gap: 8px;
  top: 80px;
  right: 24px;
  max-width: min(420px, calc(100vw - 48px));
  pointer-events: none;
}

.toast {
  display: flex;
  max-width: 420px;
  align-items: center;
  gap: 9px;
  padding: 10px 14px 10px 10px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(24, 26, 45, 0.95);
  box-shadow: 0 18px 35px -18px rgba(10, 12, 28, 0.7);
  backdrop-filter: blur(12px);
  font-size: 11.5px;
  font-weight: 500;
  animation: toastIn 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.toast.is-leaving {
  animation: toastOut 0.22s ease both;
}

.toast__icon {
  display: grid;
  width: 25px;
  height: 25px;
  flex: 0 0 auto;
  place-items: center;
  color: #7ce5bd;
  border-radius: 7px;
  background: rgba(52, 211, 153, 0.12);
}

.toast__icon .icon {
  width: 14px;
  height: 14px;
}

.toast--error .toast__icon {
  color: #ffa2ae;
  background: rgba(244, 63, 94, 0.14);
}

.toast--info .toast__icon {
  color: #b2aaff;
  background: rgba(139, 128, 255, 0.14);
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(-8px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes toastOut {
  to {
    opacity: 0;
    transform: translateY(-5px) scale(0.98);
  }
}

/* =========================================================
   响应式
   ========================================================= */

@media (max-width: 1120px) {
  .landing-shell {
    padding-right: 36px;
    padding-left: 36px;
  }

  .hero {
    gap: 42px;
  }

  .float-card--reminder {
    right: -10px;
  }

  .floating-badge--one {
    left: -6px;
  }

  .app-main {
    padding-right: 26px;
    padding-left: 26px;
  }

  .app-header__inner {
    padding-right: 26px;
    padding-left: 26px;
  }
}

@media (max-width: 940px) {
  .landing-main {
    padding-top: 34px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
  }

  .hero-copy {
    max-width: 700px;
  }

  .hero-visual {
    width: min(100%, 560px);
    max-width: 560px;
    justify-self: center;
    padding-bottom: 34px;
  }

  .role-grid {
    max-width: 620px;
  }

  .float-card--submitted {
    left: -2px;
  }

  .float-card--reminder {
    right: -4px;
  }

  .workspace-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .tips-card {
    min-height: 320px;
  }

  .tips-card h3 br {
    display: none;
  }

  .tips-list {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }

  .tips-note {
    margin-top: 20px;
  }

  .materials-card {
    min-height: 300px;
  }

  .assignment-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .student-assignment-card .assignment-card__requirement {
    -webkit-line-clamp: 3;
  }
}

@media (max-width: 760px) {
  .landing-shell {
    padding: 16px 20px 18px;
  }

  .landing-header .brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }

  .landing-header .brand-copy strong {
    font-size: 16px;
  }

  .landing-header .brand-copy small {
    font-size: 9.5px;
  }

  .prototype-pill {
    padding: 6px 9px;
    font-size: 10px;
  }

  .landing-main {
    align-items: flex-start;
    padding: 30px 0 26px;
  }

  .hero-copy h1 {
    margin-top: 20px;
    font-size: clamp(44px, 12.5vw, 62px);
  }

  .hero-desc {
    margin-top: 18px;
    font-size: 14px;
    line-height: 1.8;
  }

  .role-grid {
    gap: 11px;
    margin-top: 26px;
  }

  .role-card {
    gap: 10px;
    padding: 14px;
    border-radius: 17px;
  }

  .role-card__icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
  }

  .role-card__icon .icon {
    width: 19px;
    height: 19px;
  }

  .role-card__title {
    font-size: 14.5px;
  }

  .role-card__desc {
    font-size: 9.5px;
  }

  .role-card__arrow {
    width: 23px;
    height: 23px;
  }

  .landing-notes {
    gap: 10px 16px;
    margin-top: 18px;
  }

  .hero-visual {
    display: none;
  }

  .landing-footer {
    padding-top: 14px;
    font-size: 9.5px;
  }

  .app-header__inner {
    gap: 8px;
    padding: 9px 14px;
  }

  .brand--compact .brand-mark {
    width: 35px;
    height: 35px;
    border-radius: 10px;
  }

  .brand--compact .brand-mark .icon {
    width: 19px;
    height: 19px;
  }

  .brand--compact .brand-copy strong {
    font-size: 14px;
  }

  .brand--compact .brand-copy small {
    display: none;
  }

  .identity-pill {
    gap: 7px;
    padding: 4px 5px;
  }

  .avatar {
    width: 31px;
    height: 31px;
    font-size: 11px;
  }

  .identity-copy strong {
    font-size: 11.5px;
  }

  .identity-copy small {
    display: none;
  }

  .role-badge {
    display: none;
  }

  .ghost-button {
    min-height: 32px;
    padding: 6px 8px;
  }

  .ghost-button__label {
    display: none;
  }

  .app-main {
    padding: 24px 16px 32px;
  }

  .welcome-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
  }

  .welcome-copy h1 {
    margin-top: 7px;
    font-size: clamp(25px, 7.3vw, 31px);
  }

  .welcome-copy p {
    margin-top: 4px;
    font-size: 11.5px;
  }

  .primary-button--hero {
    width: 100%;
  }

  .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
    margin-top: 20px;
  }

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

  .stat-card {
    gap: 9px;
    padding: 12px;
    border-radius: 14px;
  }

  .stat-card__icon {
    width: 35px;
    height: 35px;
    border-radius: 10px;
  }

  .stat-card__icon .icon {
    width: 17px;
    height: 17px;
  }

  .stat-card__label {
    font-size: 9px;
  }

  .stat-card__value {
    font-size: 22px;
  }

  .stat-card__foot {
    font-size: 8px;
  }

  .stat-grid--student .stat-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    padding: 12px;
  }

  .stat-grid--student .stat-card__icon {
    width: 30px;
    height: 30px;
  }

  .stat-grid--student .stat-card__icon .icon {
    width: 15px;
    height: 15px;
  }

  .teacher-workspace {
    margin-top: 28px;
  }

  .section-heading {
    gap: 12px;
  }

  .section-heading--workspace {
    align-items: flex-start;
    flex-direction: column;
    gap: 13px;
  }

  .section-heading h2 {
    font-size: 19px;
  }

  .section-heading p {
    font-size: 11.5px;
  }

  .tab-switch {
    width: 100%;
  }

  .tab-button {
    flex: 1;
    justify-content: center;
  }

  .form-card,
  .tips-card,
  .materials-card {
    padding: 18px;
    border-radius: 18px;
  }

  .card-heading h3 {
    font-size: 15px;
  }

  .card-heading p {
    font-size: 11px;
  }

  .form-footer {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
  }

  .form-footer .primary-button {
    width: 100%;
  }

  .form-hint {
    font-size: 10px;
  }

  .tips-card {
    min-height: 0;
  }

  .tips-list {
    display: flex;
    gap: 12px;
  }

  .tips-card h3 {
    font-size: 19px;
  }

  .upload-zone {
    min-height: 230px;
    padding: 22px 16px;
  }

  .upload-zone__icon {
    width: 50px;
    height: 50px;
    border-radius: 15px;
  }

  .upload-zone__icon .icon {
    width: 23px;
    height: 23px;
  }

  .upload-zone strong {
    font-size: 13px;
  }

  .materials-card {
    min-height: 0;
  }

  .assignments-section {
    margin-top: 30px;
  }

  .assignments-section--student {
    margin-top: 26px;
  }

  .assignment-list {
    gap: 10px;
    margin-top: 13px;
  }

  .assignment-card {
    padding: 16px;
    border-radius: 16px;
  }

  .assignment-card__title {
    font-size: 15px;
  }

  .assignment-card__requirement {
    font-size: 12px;
  }

  .assignment-card__meta {
    margin-top: 11px;
    padding: 8px 0;
  }

  .assignment-card__footer {
    padding-top: 12px;
  }

  .assignment-card__actions {
    width: 100%;
  }

  .assignment-card__actions .outline-button {
    width: 100%;
  }

  .student-assignment-card .assignment-card__footer {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .student-assignment-card .assignment-card__actions {
    width: 100%;
  }

  .student-assignment-card .submit-button {
    width: 100%;
  }

  .submitted-state {
    justify-content: center;
    width: 100%;
  }

  .weekly-progress {
    width: 100%;
    margin: 0;
  }

  .section-heading--filters {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .filter-switch {
    width: 100%;
  }

  .filter-button {
    flex: 1;
    justify-content: center;
  }

  .app-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
    margin-top: 30px;
    font-size: 9px;
  }

  .modal-root {
    align-items: flex-end;
    padding: 10px;
  }

  .modal-card {
    width: 100%;
    max-height: calc(100dvh - 20px);
    border-radius: 22px;
  }

  .modal-header {
    padding: 19px 18px 15px;
  }

  .modal-header h2 {
    font-size: 18px;
  }

  .modal-body {
    padding: 17px 18px;
  }

  .modal-footer {
    padding: 13px 18px calc(13px + env(safe-area-inset-bottom));
  }

  .modal-footer .primary-button {
    flex: 1;
  }

  .modal-summary {
    padding: 11px 18px;
  }

  .toast-region {
    top: 72px;
    right: 14px;
    left: 14px;
    align-items: center;
    max-width: none;
  }

  .toast {
    max-width: 100%;
    align-self: center;
  }
}

@media (max-width: 480px) {
  .landing-shell {
    padding-right: 16px;
    padding-left: 16px;
  }

  .prototype-pill {
    padding: 5px 8px;
  }

  .prototype-pill .pulse-dot {
    display: none;
  }

  .landing-header .brand-mark {
    width: 37px;
    height: 37px;
  }

  .landing-header .brand-copy strong {
    font-size: 15px;
  }

  .landing-header .brand-copy small {
    font-size: 8.5px;
  }

  .hero-copy > .eyebrow {
    padding: 6px 9px;
    font-size: 10px;
  }

  .hero-copy h1 {
    font-size: clamp(40px, 13.5vw, 54px);
  }

  .hero-desc {
    font-size: 13px;
  }

  .role-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .role-card {
    padding: 15px;
  }

  .role-card__desc {
    font-size: 10px;
  }

  .landing-notes {
    font-size: 9.5px;
  }

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

  .stat-grid--student .stat-card {
    padding: 10px;
  }

  .stat-grid--student .stat-card__label {
    font-size: 9px;
  }

  .stat-grid--student .stat-card__value {
    font-size: 21px;
  }

  .stat-grid--student .stat-card__foot {
    font-size: 8px;
  }

  .identity-copy strong {
    max-width: 56px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .assignment-card__top {
    align-items: flex-start;
  }

  .status-badge {
    padding: 3px 7px;
    font-size: 9px;
  }

  .subject-chip {
    padding: 3px 7px;
    font-size: 9px;
  }

  .submission-summary {
    gap: 6px;
  }

  .submission-summary__copy {
    font-size: 9px;
  }

  .submission-summary__copy strong {
    font-size: 10.5px;
  }

  .stack-avatar {
    width: 22px;
    height: 22px;
    font-size: 7px;
  }

  .modal-footer {
    flex-wrap: wrap;
  }

  .modal-footer .secondary-button {
    flex: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
