:root {
  --student-bg: #f7f8f4;
  --student-surface: #fffefb;
  --student-line: #dbe5de;
  --student-line-strong: #b9d1c2;
  --student-ink: #18372f;
  --student-text: #304b43;
  --student-muted: #718179;
  --student-green: #3f966c;
  --student-green-soft: #edf6ef;
  --student-blue: #5d85ad;
  --student-blue-soft: #eef4fa;
  --student-amber: #c99031;
  --student-amber-soft: #fff6e6;
  --student-coral: #c97868;
  --student-coral-soft: #fff1ed;
  --student-nav-height: 72px;
}

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

body > .wrong-capture-source-dialog {
  z-index: 2600;
}

.side-nav,
.toolbar,
.tabs,
#homeReturnBar {
  display: none !important;
}

.app,
body.sidebar-collapsed .app,
body.book-notebook-active .app,
body.shop-view-active .app {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0 0 48px;
}

/* Temporary product switch: keep pet data and behavior, hide its student UI. */
.floating-pet,
.floating-pet-bubble,
.floating-pet-status {
  display: none !important;
}

.student-top-nav {
  position: sticky;
  top: 0;
  z-index: 2100;
  min-height: var(--student-nav-height);
  padding: 0 max(24px, calc((100vw - 1280px) / 2));
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  gap: 18px;
  border-bottom: 1px solid rgba(199, 214, 206, 0.82);
  background: rgba(255, 254, 251, 0.96);
  box-shadow: 0 6px 22px rgba(37, 64, 52, 0.04);
  backdrop-filter: blur(16px);
}

.student-brand,
.student-top-profile,
.student-primary-nav button,
.student-parent-entry,
.student-logout-entry,
.student-admin-tools summary {
  min-height: 44px;
  border: 0;
  background: transparent;
  color: var(--student-ink);
}

.student-brand {
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  justify-self: start;
  font-size: 19px;
  letter-spacing: 0;
}

.student-brand img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.student-primary-nav {
  height: 100%;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 14px;
}

.student-primary-nav button {
  position: relative;
  min-width: 78px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: #566a61;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.student-primary-nav button::after {
  content: "";
  position: absolute;
  right: 14px;
  bottom: 0;
  left: 14px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: transparent;
}

.student-primary-nav button.active {
  color: #2e7c58;
}

.student-primary-nav button.active::after {
  background: var(--student-green);
}

.student-nav-icon {
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  display: inline-block;
  border: 0;
  background-color: transparent;
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
  box-shadow: none;
}

.student-nav-profile-icon {
  position: relative;
  width: 20px;
  height: 20px;
  border: 2px solid currentColor;
  border-radius: 50%;
}

.student-nav-profile-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8px;
  width: 18px;
  height: 9px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  transform: translateX(-50%);
}

.student-top-actions {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.student-parent-entry,
.student-logout-entry,
.student-admin-tools summary {
  padding: 8px 12px;
  border: 1px solid var(--student-line);
  border-radius: 7px;
  color: #536b60;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.student-admin-tools {
  position: relative;
}

.student-admin-tools summary {
  display: flex;
  align-items: center;
  list-style: none;
}

.student-admin-tools summary::-webkit-details-marker {
  display: none;
}

.student-admin-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 2300;
  width: 160px;
  padding: 7px;
  display: grid;
  gap: 3px;
  border: 1px solid var(--student-line);
  border-radius: 8px;
  background: #fffefb;
  box-shadow: 0 16px 38px rgba(35, 58, 48, 0.14);
}

.student-admin-menu button {
  min-height: 40px;
  padding: 8px 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--student-text);
  text-align: left;
  cursor: pointer;
}

.student-admin-menu button:hover {
  background: var(--student-green-soft);
}

.student-top-profile {
  padding: 4px 8px 4px 5px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--student-line);
  border-radius: 7px;
  cursor: pointer;
}

.student-top-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: var(--student-green-soft) center/cover no-repeat;
  color: #2f7656;
  font-size: 13px;
  font-weight: 800;
}

.student-top-profile > span:last-child {
  max-width: 76px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 700;
}

.student-home-dashboard {
  width: min(1240px, calc(100% - 48px));
  margin: 28px auto 0;
  display: grid;
  gap: 20px;
}

#homeView > .home-section,
#homeView > .growth-card {
  display: none !important;
}

.student-home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(320px, 0.9fr);
  gap: 18px;
}

.student-home-intro,
.student-continue-card {
  min-height: 272px;
  border: 1px solid var(--student-line);
  border-radius: 8px;
  background: var(--student-surface);
}

.student-home-intro {
  padding: 30px 32px 26px;
}

.student-home-intro > span {
  color: #668076;
  font-size: 15px;
  font-weight: 700;
}

.student-home-intro h1 {
  margin: 8px 0 24px;
  color: var(--student-ink);
  font-size: 30px;
  line-height: 1.25;
  letter-spacing: 0;
}

.student-home-search {
  height: 58px;
  padding: 5px 6px 5px 18px;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 1.5px solid #72a98b;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 8px 18px rgba(48, 91, 70, 0.06);
}

.student-home-search:focus-within {
  border-color: #3f966c;
  box-shadow: 0 0 0 3px rgba(63, 150, 108, 0.12);
}

.student-home-search-icon {
  width: 19px;
  height: 19px;
  border: 2px solid #537068;
  border-radius: 50%;
  position: relative;
}

.student-home-search-icon::after {
  content: "";
  position: absolute;
  right: -7px;
  bottom: -5px;
  width: 8px;
  height: 2px;
  background: #537068;
  transform: rotate(45deg);
}

.student-home-search input {
  min-width: 0;
  height: 44px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--student-ink);
  font: inherit;
  font-size: 16px;
}

.student-home-search input::placeholder {
  color: #8a9891;
}

.student-home-search button {
  min-width: 72px;
  height: 44px;
  border: 0;
  border-radius: 7px;
  background: var(--student-green);
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.student-home-subjects {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.student-home-subjects button {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid var(--student-line);
  border-radius: 6px;
  background: #fbfcfa;
  color: #51675d;
  font-size: 13px;
  cursor: pointer;
}

.student-continue-card {
  padding: 24px;
}

.student-section-title {
  min-height: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.student-section-title > span {
  position: relative;
  padding-left: 12px;
  color: var(--student-ink);
  font-size: 18px;
  font-weight: 800;
}

.student-section-title > span::before {
  content: "";
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 0;
  width: 3px;
  border-radius: 3px;
  background: var(--student-green);
}

.student-section-title button {
  min-height: 32px;
  padding: 4px 6px;
  border: 0;
  background: transparent;
  color: #688078;
  font-size: 12px;
  cursor: pointer;
}

.student-continue-body {
  position: relative;
  min-height: 184px;
  padding: 24px 64px 8px 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.student-subject-chip {
  padding: 4px 8px;
  border-radius: 5px;
  background: var(--student-green-soft);
  color: #357657;
  font-size: 12px;
  font-weight: 800;
}

.student-continue-body strong {
  margin-top: 12px;
  color: var(--student-ink);
  font-size: 17px;
  line-height: 1.5;
}

.student-continue-body small {
  margin-top: 7px;
  color: var(--student-muted);
  font-size: 13px;
  line-height: 1.5;
}

.student-continue-progress {
  width: min(260px, 100%);
  height: 5px;
  margin-top: auto;
  overflow: hidden;
  border-radius: 4px;
  background: #e7ece8;
}

.student-continue-progress span {
  display: block;
  width: 24%;
  height: 100%;
  border-radius: inherit;
  background: var(--student-green);
}

.student-continue-button {
  position: absolute;
  right: 0;
  bottom: 12px;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border: 1px solid #9dc8ae;
  border-radius: 50%;
  background: var(--student-green-soft);
  cursor: pointer;
}

.student-continue-button span {
  width: 0;
  height: 0;
  margin-left: 3px;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid var(--student-green);
}

.student-home-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(300px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.student-home-group {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--student-line);
  border-radius: 8px;
  background: var(--student-surface);
}

.student-practice-group {
  grid-row: span 2;
}

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

/* Keep the practice shortcuts in the intended visual order even when an older
   home-page document is restored from the browser cache. */
#studentPracticeModules .student-feature-card.capture { order: 1; }
#studentPracticeModules .student-feature-card.wrong { order: 2; }
#studentPracticeModules .student-feature-card.practice { order: 3; }
#studentPracticeModules .student-feature-card.challenge { order: 4; }
#studentPracticeModules .student-feature-card.geometry { order: 5; }
#studentPracticeModules .student-feature-card.classical { order: 6; }

.student-feature-card,
.student-lab-card {
  min-width: 0;
  min-height: 112px;
  padding: 18px;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--student-line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--student-text);
  text-align: left;
  cursor: pointer;
  transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.student-feature-card:hover,
.student-lab-card:hover {
  border-color: var(--student-line-strong);
  background: #fbfdfb;
  box-shadow: 0 4px 12px rgba(40, 67, 55, 0.04);
  transform: none;
}

.student-feature-card > span:nth-child(2),
.student-lab-card > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.student-feature-card strong,
.student-lab-card strong {
  color: var(--student-ink);
  font-size: 17px;
  line-height: 1.35;
}

.student-feature-card small,
.student-lab-card small {
  overflow: hidden;
  color: var(--student-muted);
  font-size: 12px;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.student-feature-card i,
.student-lab-card i {
  color: #7e9188;
  font-size: 24px;
  font-style: normal;
}

.student-feature-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background-color: var(--student-green-soft);
  background-position: center;
  background-repeat: no-repeat;
  background-size: 40px;
}

.student-feature-icon.icon-practice {
  background-image: url("/static/assets/icons/desktop5-add-task.png");
  background-size: 50px;
}

.student-feature-icon.icon-wrong {
  background-image: url("/static/assets/icons/desktop6-wrong-review-a.png");
  background-size: 48px;
}

.student-feature-icon.icon-capture {
  background-color: #fff7e9;
  background-image: url("/static/assets/student-home-v3/nav-practice.png");
  background-size: 72px;
}

@media (min-width: 1180px) {
  .student-practice-group .student-feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .student-practice-group .student-feature-card {
    grid-template-columns: 88px minmax(0, 1fr) 16px;
    gap: 13px;
    padding-right: 14px;
  }

  .student-practice-group .student-feature-icon {
    width: 88px;
  }

  .student-practice-group .student-feature-card strong {
    font-size: 17px;
  }
}

.student-feature-icon.icon-book {
  background-size: 38px;
}

.student-feature-card.wrong .student-feature-icon {
  background-color: var(--student-coral-soft);
}

.student-feature-card.reading .student-feature-icon {
  background-color: var(--student-blue-soft);
}

.student-feature-card.books .student-feature-icon {
  background-color: var(--student-amber-soft);
}

.student-icon-english {
  color: var(--student-blue);
  font-size: 23px;
  font-weight: 800;
}

.student-reading-group .student-feature-grid {
  grid-template-columns: 1fr;
}

.student-reading-group .student-feature-card {
  min-height: 88px;
}

.student-recent-group {
  grid-column: 1;
}

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

.student-recent-item {
  min-width: 0;
  min-height: 66px;
  padding: 12px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid #e4eae6;
  border-radius: 7px;
  background: #fbfcfa;
  color: var(--student-text);
  text-align: left;
  cursor: pointer;
}

.student-recent-item > span:first-child {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: var(--student-green-soft);
  color: #347457;
  font-size: 12px;
  font-weight: 800;
}

.student-recent-item > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.student-recent-item strong,
.student-recent-item small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.student-recent-item strong {
  color: var(--student-text);
  font-size: 13px;
}

.student-recent-item small {
  color: var(--student-muted);
  font-size: 11px;
}

.student-recent-item i {
  color: #819188;
  font-size: 18px;
  font-style: normal;
}

.student-recent-empty {
  grid-column: 1 / -1;
  padding: 18px;
  border: 1px dashed var(--student-line-strong);
  border-radius: 7px;
  color: var(--student-muted);
  text-align: center;
  font-size: 13px;
}

.student-lab-group {
  grid-column: 2;
}

.student-lab-card {
  width: 100%;
  min-height: 92px;
  margin-top: 16px;
}

body[data-current-view="parentDashboard"] .home-section-feedback,
body[data-current-view="parentDashboard"] .home-section-record {
  display: block;
  margin-top: 18px;
}

#parentDashboardView > .home-section-feedback,
#parentDashboardView > .home-section-record {
  width: min(1240px, 100%);
  margin-right: auto;
  margin-left: auto;
}

#parentDashboardView .achievement-preview-card {
  display: none;
}

#parentDashboardView .growth-chart-row {
  grid-template-columns: 1fr;
}

.management-mode .student-admin-tools,
.management-mode .student-parent-entry,
.parent-account-mode .student-parent-entry {
  display: block !important;
}

body:not(.management-mode) [data-management-only] {
  display: none !important;
}

body[data-current-view="practice"] .student-top-nav,
body[data-current-view="physicsLab"] .student-top-nav {
  display: none;
}

body[data-current-view="practice"] .app,
body[data-current-view="physicsLab"] .app {
  padding-top: 0;
}

#practice2View,
#wrongReviewView,
#practiceLibraryView,
#questionSearchView,
#englishReadingView,
#booksView,
#parentDashboardView,
#importView,
#qualityView,
#safetyView,
#bankPackView {
  width: min(1240px, calc(100% - 32px));
  margin: 18px auto 0;
}

#practice2View .practice2-hero {
  width: 100%;
  margin: 0 0 14px;
  padding: 4px 2px 8px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  border: 0;
  background: transparent;
  box-shadow: none;
}

#practice2View .practice2-hero span {
  color: #6d8177;
  font-size: 12px;
}

#practice2View .practice2-hero h2 {
  margin: 4px 0 3px;
  color: var(--student-ink);
  font-size: 26px;
  line-height: 1.25;
}

#practice2View .practice2-hero p {
  margin: 0;
  color: var(--student-muted);
  font-size: 13px;
}

#practice2View .practice2-hub-switch,
#practice2View .practice2-hub-content,
#parentDashboardView .parent-dashboard-panel,
#wrongReviewView > section,
#questionSearchView > section,
#practiceLibraryView > section {
  border-radius: 8px;
}

#parentDashboardView .parent-card,
#parentDashboardView .parent-overview-grid > *,
#parentDashboardView .growth-card {
  border-radius: 8px;
}

@media (max-width: 1040px) {
  .student-top-nav {
    padding-right: 18px;
    padding-left: 18px;
    grid-template-columns: auto 1fr auto;
  }

  .student-top-profile > span:last-child,
  .student-parent-entry {
    display: none;
  }

  .student-primary-nav {
    gap: 4px;
  }

  .student-primary-nav button {
    min-width: 66px;
    padding: 0 8px;
  }

  .student-home-dashboard {
    width: min(100% - 32px, 960px);
    margin-top: 18px;
  }

  .student-home-hero {
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.8fr);
  }

  .student-home-grid {
    grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.8fr);
  }

  .student-feature-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  :root {
    --student-nav-height: 62px;
  }

  .student-top-nav {
    padding: 0 10px;
    grid-template-columns: 42px minmax(220px, 1fr) auto;
    gap: 4px;
  }

  .student-brand img {
    width: 38px;
    height: 38px;
  }

  .student-brand strong {
    display: none;
  }

  .student-primary-nav button {
    min-width: 52px;
    padding: 0 5px;
    flex-direction: column;
    gap: 2px;
    font-size: 11px;
  }

  .student-nav-icon {
    width: 19px;
    height: 19px;
    flex-basis: 19px;
  }

  .student-top-profile {
    padding: 3px;
    border: 0;
  }

  .student-top-avatar {
    width: 34px;
    height: 34px;
  }

  .student-parent-entry,
  .student-admin-tools summary {
    width: 34px;
    min-width: 34px;
    height: 36px;
    min-height: 36px;
    padding: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    font-size: 0;
  }

  .management-mode .student-parent-entry,
  .parent-account-mode .student-parent-entry,
  .management-mode .student-admin-tools summary {
    display: grid !important;
  }

  .student-parent-entry::before {
    content: "家";
    font-size: 13px;
  }

  .student-admin-tools summary::before {
    content: "管";
    font-size: 13px;
  }

  .student-admin-tools {
    position: relative;
  }

  .student-home-dashboard {
    width: calc(100% - 24px);
    margin-top: 12px;
    gap: 12px;
  }

  #practice2View,
  #wrongReviewView,
  #practiceLibraryView,
  #questionSearchView,
  #englishReadingView,
  #booksView,
  #parentDashboardView,
  #importView,
  #qualityView,
  #safetyView,
  #bankPackView {
    width: calc(100% - 20px);
    margin-top: 12px;
  }

  .student-home-hero,
  .student-home-grid {
    grid-template-columns: 1fr;
  }

  .student-home-intro,
  .student-continue-card {
    min-height: 0;
  }

  .student-home-intro {
    padding: 22px 18px;
  }

  .student-home-intro h1 {
    margin-bottom: 18px;
    font-size: 25px;
  }

  .student-home-search {
    height: 54px;
  }

  .student-home-search button {
    min-width: 62px;
  }

  .student-continue-card,
  .student-home-group {
    padding: 18px;
  }

  .student-continue-body {
    min-height: 150px;
  }

  .student-practice-group,
  .student-recent-group,
  .student-lab-group {
    grid-row: auto;
    grid-column: auto;
  }

  .student-feature-grid,
  .student-recent-list {
    grid-template-columns: 1fr;
  }

  .student-feature-card,
  .student-lab-card {
    min-height: 88px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .student-feature-card,
  .student-lab-card {
    transition: none;
  }
}

/* Student home visual direction C: warm, calm and study-focused. */
body {
  background-color: #f4f2eb;
  background-image: url("/static/assets/student-home-v3/paper-texture.png");
  background-repeat: repeat;
  background-size: 420px 420px;
}

.student-top-nav {
  min-height: 76px;
  border-bottom-color: #dedfd9;
  background: rgba(255, 255, 252, 0.97);
  box-shadow: 0 4px 18px rgba(46, 62, 54, 0.045);
}

.student-brand {
  font-size: 20px;
  font-weight: 800;
}

.student-brand img {
  width: 45px;
  height: 45px;
}

.student-primary-nav button {
  min-width: 88px;
  color: #596861;
  font-size: 16px;
}

.student-nav-icon {
  width: 24px;
  height: 24px;
  flex-basis: 24px;
}

.student-primary-nav .icon-home {
  background-image: url("/static/assets/student-home-v3/nav-home.png");
}

.student-primary-nav .icon-practice {
  background-image: url("/static/assets/student-home-v3/nav-practice.png");
}

.student-primary-nav .icon-book {
  background-image: url("/static/assets/student-home-v3/nav-reading.png");
}

.student-primary-nav .student-nav-profile-icon {
  border: 0;
  border-radius: 0;
  background-image: url("/static/assets/student-home-v3/nav-profile.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: contain;
}

.student-primary-nav .student-nav-profile-icon::after {
  display: none;
}

.student-home-dashboard {
  width: min(1320px, calc(100% - 56px));
  margin-top: 30px;
  gap: 22px;
}

.student-home-hero {
  grid-template-columns: minmax(0, 1.72fr) minmax(330px, 0.88fr);
  gap: 20px;
}

.student-home-intro,
.student-continue-card,
.student-home-group {
  border-color: #daddd7;
  background: #fffefa;
  box-shadow: 0 10px 30px rgba(49, 67, 57, 0.045);
}

.student-home-intro {
  position: relative;
  min-height: 320px;
  padding: 42px 290px 34px 40px;
  overflow: hidden;
  background-color: #fffdf8;
  background-image: url("/static/assets/student-home-v3/hero-study-desk.jpg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.student-home-intro > span {
  color: #203a32;
  font-size: 28px;
  font-weight: 850;
  line-height: 1.2;
}

.student-home-intro h1 {
  margin: 10px 0 27px;
  color: #6b7b73;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
}

.student-home-search {
  position: relative;
  z-index: 2;
  height: 64px;
  border-color: #86b39a;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(62, 111, 84, 0.08);
}

.student-home-search button {
  min-width: 80px;
  height: 48px;
  background: #438b63;
  font-size: 15px;
}

.student-home-subjects {
  position: relative;
  z-index: 2;
  margin-top: 22px;
  gap: 11px;
}

.student-home-subjects button {
  min-height: 38px;
  padding: 7px 14px;
  border-color: transparent;
  background: #f2f6f1;
  color: #405c50;
  font-size: 14px;
  font-weight: 700;
}

.student-home-subjects button:nth-child(2) {
  background: #fff3df;
  color: #9b6a19;
}

.student-home-subjects button:nth-child(3) {
  background: #eef3fb;
  color: #55769a;
}

.student-home-subjects button:nth-child(4) {
  background: #f4f4f1;
  color: #5f6b65;
}

.student-continue-card {
  min-height: 320px;
  padding: 27px 26px;
}

.student-section-title > span {
  padding-left: 15px;
  font-size: 19px;
}

.student-section-title > span::before {
  top: 3px;
  bottom: 3px;
  width: 4px;
  background: #4c9a6e;
}

.student-continue-body {
  min-height: 225px;
  margin-top: 12px;
  padding: 26px 70px 18px 22px;
  border: 1px solid #e0e3de;
  border-radius: 8px;
  background: #fffefb;
}

.student-continue-body strong {
  font-size: 18px;
}

.student-continue-button {
  right: 20px;
  bottom: 26px;
}

.student-home-grid {
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 0.78fr);
  gap: 20px;
}

.student-home-group {
  padding: 26px;
}

.student-feature-grid {
  margin-top: 19px;
  gap: 16px;
}

.student-feature-card,
.student-lab-card {
  min-height: 124px;
  padding: 0 20px 0 0;
  grid-template-columns: 108px minmax(0, 1fr) 22px;
  gap: 18px;
  overflow: hidden;
  border-color: #dfe3de;
  background: #fffefb;
}

.student-feature-icon {
  width: 108px;
  height: 100%;
  min-height: 122px;
  border-radius: 0;
  background-size: 65px;
}

.student-feature-icon.icon-practice-home {
  background-color: #edf5ef;
  background-image: url("/static/assets/student-home-v3/module-practice.png");
  background-size: 76px;
}

.student-feature-icon.icon-challenge {
  background-color: #fff4df;
  background-image: url("/static/assets/icons/desktop5-achievement-badge.png");
  background-size: 68px;
}

.student-feature-icon.icon-wrong {
  background-color: #fff0eb;
  background-image: url("/static/assets/student-home-v3/module-wrong.png");
  background-size: 72px;
}

.student-feature-icon.icon-english {
  background-color: #edf5ef;
  background-image: url("/static/assets/student-home-v3/module-english.png");
  background-size: 70px;
}

.student-feature-icon.icon-vocabulary {
  position: relative;
  background-color: #eef3fb;
  background-image: none;
}

.student-feature-icon.icon-vocabulary::before {
  content: "Aa";
  width: 52px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 2px solid #7390b7;
  border-radius: 6px 6px 14px 6px;
  background: #ffffff;
  color: #45688f;
  font: 800 22px/1 Georgia, serif;
  box-shadow: 7px 7px 0 #d9e5f4;
}

.student-feature-icon.icon-book {
  background-color: #fff5df;
  background-image: url("/static/assets/student-home-v3/module-books.png");
  background-size: 68px;
}

.student-feature-icon.icon-geometry {
  background-color: #f0f4e8;
  background-image: url("/static/assets/student-home-v3/module-geometry.png");
  background-size: 68px;
}

.student-feature-card.geometry .student-feature-icon {
  background-color: #f0f4e8;
}

.student-feature-icon.icon-classical {
  background-color: #eef6f0;
  background-image: url("/static/assets/student-home-v3/module-books.png");
  background-size: 66px;
}

.student-feature-card.classical .student-feature-icon {
  background-color: #eef6f0;
}

.student-feature-icon.icon-physics {
  background-color: #eef4fa;
  background-image: url("/static/assets/student-home-v3/module-physics.png");
  background-size: 70px;
}

.student-feature-card strong,
.student-lab-card strong {
  font-size: 19px;
}

.student-feature-card small,
.student-lab-card small {
  font-size: 13px;
}

.student-reading-group .student-feature-card {
  min-height: 105px;
  grid-template-columns: 92px minmax(0, 1fr) 20px;
}

.student-reading-group .student-feature-icon {
  width: 92px;
  min-height: 103px;
  background-size: 56px;
}

.student-recent-list {
  position: relative;
  margin-top: 20px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
}

.student-recent-item {
  position: relative;
  min-height: 92px;
  padding: 9px 16px 9px 0;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 11px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.student-recent-item:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 29px;
  right: 4px;
  width: 28px;
  border-top: 1px dashed #d8ddd8;
}

.student-recent-item > span:first-child {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 13px;
}

.student-recent-item:nth-child(2) > span:first-child {
  background: #fff2dc;
  color: #a66f1d;
}

.student-recent-item:nth-child(3) > span:first-child {
  background: #edf3fb;
  color: #55769c;
}

.student-recent-item:nth-child(4) > span:first-child {
  background: #fff4e3;
  color: #a9782d;
}

.student-recent-item i {
  display: none;
}

.student-recent-item strong {
  font-size: 13px;
}

.student-lab-card {
  min-height: 124px;
  margin-top: 19px;
}

@media (max-width: 1040px) {
  .student-home-intro {
    padding-right: 220px;
  }

  .student-recent-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 0;
  }

  .student-recent-item:nth-child(2)::after {
    display: none;
  }
}

@media (max-width: 820px) {
  .student-top-nav {
    min-height: 62px;
  }

  .student-home-intro {
    min-height: 0;
    padding: 26px 18px 24px;
  }

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

  .student-practice-group,
  .student-recent-group,
  .student-lab-group {
    grid-row: auto;
    grid-column: auto;
  }

  .student-home-intro > span {
    font-size: 24px;
  }

  .student-home-intro h1 {
    font-size: 15px;
  }

  .student-home-intro {
    background-image: none;
  }

  .student-feature-card,
  .student-lab-card {
    grid-template-columns: 82px minmax(0, 1fr) 18px;
    min-height: 98px;
  }

  .student-feature-icon,
  .student-reading-group .student-feature-icon {
    width: 82px;
    min-height: 96px;
    background-size: 54px;
  }

  .student-recent-list {
    grid-template-columns: 1fr;
  }

  .student-recent-item::after {
    display: none;
  }
}

/* 2026-07-12: compact, task-first student home layout. */
.student-home-dashboard {
  width: min(1280px, calc(100% - 32px));
  margin-top: 20px;
  gap: 16px;
}

.student-home-hero {
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, .75fr);
  gap: 16px;
}

.student-home-intro,
.student-continue-card {
  min-height: 268px;
}

.student-home-intro {
  padding: 30px 250px 26px 32px;
  background-position: right center;
}

.student-home-intro > span {
  font-size: 25px;
}

.student-home-intro h1 {
  margin: 7px 0 20px;
  font-size: 15px;
}

.student-home-search {
  height: 58px;
}

.student-home-subjects {
  margin-top: 15px;
}

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

.student-continue-body {
  min-height: 184px;
  margin-top: 10px;
  padding: 22px 62px 15px 20px;
}

.student-home-grid {
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 16px;
}

.student-home-group {
  padding: 22px;
}

.student-practice-group {
  grid-column: 1 / 9;
  grid-row: auto;
}

.student-reading-group {
  grid-column: 9 / 13;
}

.student-recent-group {
  grid-column: 1 / 9;
}

.student-lab-group {
  grid-column: 9 / 13;
}

.student-practice-group .student-feature-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.student-feature-card,
.student-lab-card {
  min-height: 104px;
  grid-template-columns: 78px minmax(0, 1fr) 18px;
  gap: 12px;
  padding-right: 14px;
}

.student-feature-icon,
.student-reading-group .student-feature-icon {
  width: 78px;
  min-height: 102px;
  background-size: 52px;
}

.student-practice-group .student-feature-icon {
  width: 78px;
  min-height: 102px;
}

.student-practice-group .student-feature-icon.icon-practice-home {
  background-size: 62px;
}

.student-practice-group .student-feature-icon.icon-challenge {
  background-size: 58px;
}

.student-practice-group .student-feature-icon.icon-wrong,
.student-practice-group .student-feature-icon.icon-capture {
  background-size: 58px;
}

.student-feature-card strong,
.student-lab-card strong,
.student-practice-group .student-feature-card strong {
  font-size: 17px;
}

.student-reading-group .student-feature-grid {
  gap: 10px;
}

.student-reading-group .student-feature-card {
  min-height: 88px;
  grid-template-columns: 70px minmax(0, 1fr) 18px;
}

.student-reading-group .student-feature-icon {
  width: 70px;
  min-height: 86px;
  background-size: 48px;
}

.student-reading-group .student-feature-icon.icon-geometry {
  background-size: 56px;
}

.student-recent-list {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.student-lab-card {
  min-height: 104px;
}

.student-feature-card,
.student-lab-card {
  -webkit-tap-highlight-color: rgba(63, 150, 108, 0.06);
}

.student-feature-card:focus,
.student-lab-card:focus {
  outline: none;
}

.student-feature-card:focus-visible,
.student-lab-card:focus-visible {
  border-color: rgba(63, 150, 108, 0.42);
  background: #fdfffd;
  box-shadow: 0 0 0 2px rgba(63, 150, 108, 0.07);
}

.student-feature-card:active,
.student-lab-card:active {
  border-color: rgba(63, 150, 108, 0.3);
  background: #f8fbf8;
  box-shadow: none;
  transform: none;
}

@media (max-width: 1100px) {
  .student-home-hero {
    grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr);
  }

  .student-home-intro {
    padding-right: 175px;
  }

  .student-practice-group {
    grid-column: 1 / 13;
  }

  .student-reading-group {
    grid-column: 1 / 7;
  }

  .student-recent-group {
    grid-column: 7 / 13;
  }

  .student-lab-group {
    grid-column: 1 / 13;
  }

  .student-recent-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .student-lab-card {
    margin-top: 14px;
  }
}

@media (max-width: 900px) {
  .student-home-dashboard {
    width: min(100% - 24px, 1280px);
    margin-top: 14px;
  }

  .student-home-hero {
    grid-template-columns: minmax(0, 1.08fr) minmax(270px, .92fr);
    gap: 12px;
  }

  .student-home-intro,
  .student-continue-card {
    min-height: 250px;
  }

  .student-home-intro {
    padding: 24px 20px 20px;
    background-image: none;
  }

  .student-home-intro > span {
    font-size: 22px;
  }

  .student-home-search {
    height: 54px;
  }

  .student-home-search button {
    min-width: 66px;
    height: 42px;
  }

  .student-continue-card {
    padding: 18px;
  }

  .student-continue-body {
    min-height: 174px;
    padding: 18px 54px 12px 16px;
  }

  .student-home-group {
    padding: 18px;
  }

  .student-feature-card small,
  .student-lab-card small {
    white-space: normal;
  }
}

@media (max-width: 700px) {
  .student-home-hero,
  .student-home-grid {
    grid-template-columns: 1fr;
  }

  .student-practice-group,
  .student-reading-group,
  .student-recent-group,
  .student-lab-group {
    grid-column: 1;
  }

  .student-practice-group .student-feature-grid,
  .student-recent-list {
    grid-template-columns: 1fr;
  }
}
