:root {
  color: #1f2d2a;
  background: #dde8e3;
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

button {
  border: 0;
  font: inherit;
}

.phone-shell {
  width: min(390px, 100%);
  height: min(780px, calc(100vh - 48px));
  min-height: 560px;
  border-radius: 28px;
  background: #101715;
  padding: 12px;
  box-shadow: 0 22px 60px rgba(18, 42, 34, 0.22);
}

.screen {
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  background: #f6faf8;
}

#app {
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.page {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 16px 16px 78px;
  -webkit-overflow-scrolling: touch;
}

.practice-page-host {
  padding: 16px 14px;
  padding-bottom: 96px;
}

.home-hero {
  margin: -16px -16px 0;
  padding: 18px 16px 0;
  background:
    radial-gradient(circle at 82% 4%, rgba(204, 242, 147, 0.78), transparent 34%),
    linear-gradient(135deg, #fffefa 0%, #eef9e9 48%, #f8fff6 100%);
}

.home-brand-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: start;
  gap: 10px;
  margin-bottom: 12px;
}

.home-brand {
  color: #161f1d;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.1;
}

.home-brand span {
  color: #18a86f;
}

.home-tagline {
  margin-top: 6px;
  color: #4d5d5a;
  font-size: 13px;
  font-weight: 600;
}

.streak-card {
  min-width: 66px;
  padding: 6px 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  text-align: center;
  color: #119b68;
  font-weight: 800;
}

.streak-label {
  font-size: 10px;
}

.streak-card strong {
  font-size: 22px;
  line-height: 1.1;
}

.avatar-badge {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid #fff;
  border-radius: 999px;
  background: linear-gradient(145deg, #f6b37d, #65c879);
  color: #fff;
  font-size: 17px;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(46, 120, 84, 0.18);
}

.hero-study-card {
  position: relative;
  min-height: 156px;
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr 64px;
  align-items: center;
  gap: 4px;
  padding: 18px 0 18px 14px;
  border-radius: 22px 44px 0 0;
  background: linear-gradient(135deg, #31d699, #079a69);
  color: #fff;
}

.spark {
  position: absolute;
  left: 16px;
  top: 20px;
  color: #ffe66f;
  font-size: 18px;
}

.hero-copy {
  position: relative;
  z-index: 1;
  padding-left: 18px;
}

.hero-greeting {
  font-size: 17px;
  font-weight: 900;
  line-height: 1.25;
}

.hero-progress-text,
.hero-quote {
  margin-top: 10px;
  font-size: 12px;
  font-weight: 700;
}

.hero-progress {
  height: 8px;
  margin-top: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
}

.hero-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ffd45a, #ffa32e);
}

.book-stack {
  position: relative;
  height: 136px;
}

.book-stack .cap {
  position: absolute;
  right: 4px;
  top: 2px;
  width: 58px;
  height: 32px;
  border-radius: 8px;
  transform: skewY(-10deg);
  background: #26323a;
  box-shadow: 0 10px 16px rgba(16, 43, 38, 0.28);
}

.book {
  position: absolute;
  right: -6px;
  width: 76px;
  height: 26px;
  border-radius: 8px;
  background: #fff;
  box-shadow: inset 0 -8px 0 rgba(0, 0, 0, 0.08), 0 10px 18px rgba(17, 80, 65, 0.14);
}

.book-a {
  top: 44px;
  background: #12c5ad;
}

.book-b {
  top: 72px;
  background: #91dc36;
}

.book-c {
  top: 100px;
  background: #ffd040;
}

.dashboard-card {
  margin-top: 14px;
  padding: 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 12px 34px rgba(24, 54, 47, 0.08);
}

.card-title-row,
.task-progress-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.task-layout {
  display: grid;
  grid-template-columns: 1fr 108px;
  gap: 12px;
  align-items: center;
}

.task-main .muted {
  font-size: 15px;
}

.task-progress-row {
  margin: 14px 0;
  color: #4c5d59;
  font-weight: 700;
}

.task-progress {
  flex: 1;
  margin-top: 0;
}

.pill-button {
  height: 52px;
  border-radius: 999px;
  background: linear-gradient(135deg, #16b878, #20c889);
  box-shadow: 0 12px 22px rgba(25, 169, 116, 0.22);
}

.clipboard-illustration {
  width: 96px;
  height: 116px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 12px;
  border-radius: 18px;
  background:
    linear-gradient(#9eb4d0 0 0) 28px 42px / 42px 6px no-repeat,
    linear-gradient(#9eb4d0 0 0) 28px 62px / 42px 6px no-repeat,
    linear-gradient(#9eb4d0 0 0) 28px 82px / 42px 6px no-repeat,
    linear-gradient(145deg, #edf6ff, #cfdff5);
  color: #fff;
  font-size: 24px;
  font-weight: 900;
  box-shadow: inset 0 0 0 8px rgba(255, 255, 255, 0.52);
}

.home-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  text-align: center;
}

.home-stats div + div {
  border-left: 1px solid #edf1ef;
}

.home-stats strong {
  display: block;
  color: #15ad73;
  font-size: 27px;
  font-weight: 900;
}

.home-stats .orange {
  color: #ff970f;
}

.home-stats .blue {
  color: #2f82ff;
}

.home-stats span {
  color: #64736f;
  font-size: 13px;
}

.quick-actions {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.quick-action-card {
  min-height: 112px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: 18px;
  background: #f5fbf8;
  color: #17231f;
}

.quick-action-card span {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  font-size: 24px;
  box-shadow: 0 8px 16px rgba(25, 72, 63, 0.14);
}

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

.quick-action-card em {
  color: #6d7a77;
  font-size: 12px;
  font-style: normal;
}

.quick-action-card.green span {
  background: linear-gradient(145deg, #4be0a2, #10ae70);
}

.quick-action-card.amber span {
  background: linear-gradient(145deg, #ffc94d, #ff940e);
}

.quick-action-card.blue span {
  background: linear-gradient(145deg, #64adff, #2f80ed);
}

.quick-action-card.rose span {
  background: linear-gradient(145deg, #ff8393, #f2435c);
}

.exam-banner {
  min-height: 138px;
  display: grid;
  grid-template-columns: 1fr 132px;
  align-items: center;
  margin-top: 14px;
  padding: 18px 20px;
  overflow: hidden;
  border-radius: 20px;
  background: linear-gradient(135deg, #e6fff3, #dff7ee);
}

.exam-banner-title {
  color: #0f8f60;
  font-size: 24px;
  font-weight: 900;
}

.mini-button {
  min-width: 102px;
  height: 34px;
  margin-top: 12px;
  border-radius: 999px;
  background: #13aa72;
  color: #fff;
  font-weight: 800;
}

.target-illustration {
  position: relative;
  width: 116px;
  height: 116px;
  border-radius: 999px;
  background:
    radial-gradient(circle, #fff 0 18%, #d9ff74 19% 34%, #fff 35% 48%, #c9f04e 49% 65%, #fff 66%);
  box-shadow: 0 12px 24px rgba(46, 127, 61, 0.16);
}

.target-illustration span {
  position: absolute;
  left: 52px;
  top: 10px;
  width: 4px;
  height: 92px;
  border-radius: 999px;
  transform: rotate(48deg);
  background: #e58c24;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid #e5eee9;
  backdrop-filter: blur(10px);
}

.brand {
  font-size: 18px;
  font-weight: 700;
}

.status {
  color: #0f7f5c;
  font-size: 12px;
  font-weight: 700;
}

.hero {
  background: #eaf8f1;
  border-radius: 8px;
  padding: 18px 16px;
  margin-bottom: 14px;
}

.eyebrow {
  color: #0f7f5c;
  font-size: 13px;
  font-weight: 700;
}

.title {
  margin-top: 6px;
  color: #1f2d2a;
  font-size: 20px;
  font-weight: 700;
}

.subtitle,
.muted {
  margin-top: 6px;
  color: #6b7c78;
  font-size: 13px;
  line-height: 1.5;
}

.card {
  margin-bottom: 12px;
  padding: 16px;
  border: 1px solid #e5eee9;
  border-radius: 8px;
  background: #fff;
}

.section-title {
  margin-bottom: 10px;
  font-size: 17px;
  font-weight: 700;
}

.stats-row,
.tabbar,
.grid {
  display: flex;
  gap: 8px;
}

.stat-item,
.grid-item {
  flex: 1;
  text-align: center;
}

.stat-value {
  color: #0f7f5c;
  font-size: 20px;
  font-weight: 800;
}

.grid-item {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #f6faf8;
  color: #1f2d2a;
  font-size: 13px;
  font-weight: 700;
}

.progress {
  height: 8px;
  margin-top: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5eee9;
}

.progress-fill {
  height: 100%;
  background: #19a974;
}

.primary-button,
.ghost-button {
  width: 100%;
  height: 44px;
  margin-top: 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
}

.primary-button {
  background: #19a974;
  color: #fff;
}

.ghost-button {
  background: #eaf8f1;
  color: #0f7f5c;
}

.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.auth-tab {
  flex: 1;
  height: 38px;
  border-radius: 8px;
  background: #f6faf8;
  color: #6b7c78;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
}

.auth-tab.active {
  background: #eaf8f1;
  color: #0f7f5c;
}

.auth-input {
  width: 100%;
  height: 42px;
  margin-top: 10px;
  padding: 0 12px;
  border: 1px solid #e5eee9;
  border-radius: 8px;
  background: #fff;
  color: #1f2d2a;
  font-size: 14px;
  box-sizing: border-box;
}

.wechat-reserved {
  margin-top: 12px;
  color: #8a9692;
  font-size: 12px;
  text-align: center;
}

.option {
  width: 100%;
  min-height: 48px;
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #e5eee9;
  border-radius: 8px;
  background: #fff;
  color: #1f2d2a;
  text-align: left;
}

.option.selected {
  border-color: #19a974;
  background: #eaf8f1;
}

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

.practice-back {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: #eaf8f1;
  color: #0f7f5c;
  cursor: pointer;
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
}

.compact-title {
  font-size: 20px;
}

.nav-submit {
  flex: 0 0 auto;
  min-width: 84px;
  height: 38px;
  border-radius: 999px;
  background: #16a96f;
  color: #fff;
  font-weight: 800;
}

.practice-card {
  padding-bottom: 18px;
}

.practice-result {
  margin-top: 14px;
}

.practice-bottom-bar {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 24;
  width: min(100%, 390px);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin: 0;
  padding: 8px 8px calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid #e5eee9;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 -10px 28px rgba(31, 68, 55, 0.1);
  transform: translateX(-50%);
}

.practice-bottom-bar button {
  min-height: 52px;
  border-radius: 8px;
  background: transparent;
  color: #283a35;
}

.practice-bottom-bar span,
.practice-bottom-bar em {
  display: block;
  font-style: normal;
}

.practice-bottom-bar span {
  font-size: 20px;
}

.practice-bottom-bar em {
  margin-top: 4px;
  font-size: 12px;
}

.answer-sheet-mask {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: rgba(12, 28, 22, 0.42);
}

.answer-sheet {
  width: min(100%, 390px);
  max-height: 76vh;
  overflow: auto;
  padding: 16px;
  border-radius: 18px 18px 0 0;
  background: #fff;
}

.sheet-header,
.sheet-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.sheet-header button {
  color: #16a96f;
  font-weight: 800;
}

.sheet-summary {
  color: #6a7772;
  font-size: 12px;
}

.sheet-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.sheet-item {
  aspect-ratio: 1;
  border: 1px solid #e4ece8;
  border-radius: 999px;
  background: #fff;
  color: #1f2c29;
}

.sheet-item.current {
  border-color: #16a96f;
  background: #16a96f;
  color: #fff;
}

.sheet-item.answered {
  background: #e7f8ef;
}

.sheet-item.wrong {
  background: #fff1f1;
  border-color: #ff8f8f;
}

.tag {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eaf8f1;
  color: #0f7f5c;
  font-size: 12px;
  font-weight: 700;
}

.tag-warning {
  background: #fff6e6;
  color: #b76b00;
}

.tabbar {
  flex: 0 0 auto;
  z-index: 3;
  padding: 8px 10px 12px;
  border-top: 1px solid #e5eee9;
  background: #fff;
}

.tabbar button {
  flex: 1;
  height: 44px;
  border-radius: 8px;
  background: transparent;
  color: #6b7c78;
  cursor: pointer;
  font-size: 13px;
}

.tabbar button.active {
  background: #eaf8f1;
  color: #0f7f5c;
  font-weight: 800;
}

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

.bank-showcase {
  min-height: 118px;
  display: grid;
  grid-template-columns: 1fr 116px;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  padding: 14px 16px;
  overflow: hidden;
  border-radius: 18px;
  background:
    radial-gradient(circle at 92% 12%, rgba(116, 217, 111, 0.22), transparent 26%),
    linear-gradient(135deg, #f0fff5, #e4f7ed);
  box-shadow: 0 14px 28px rgba(40, 95, 72, 0.08);
}

.showcase-title {
  color: #066936;
  font-size: 17px;
  font-weight: 900;
}

.showcase-subtitle {
  margin-top: 7px;
  color: #74817d;
  font-size: 11px;
  font-weight: 700;
}

.showcase-button {
  min-width: 88px;
  height: 32px;
  margin-top: 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, #1ecf8b, #12a76d);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
}

.showcase-books {
  position: relative;
  height: 98px;
}

.showcase-cap,
.showcase-book {
  position: absolute;
  right: 0;
}

.showcase-cap {
  top: 4px;
  width: 68px;
  height: 32px;
  border-radius: 7px;
  transform: skewY(-10deg);
  background: #242f36;
}

.showcase-book {
  width: 102px;
  height: 24px;
  border-radius: 7px;
  box-shadow: inset 0 -6px 0 rgba(0, 0, 0, 0.08);
}

.showcase-book.a {
  top: 38px;
  background: #49d185;
}

.showcase-book.b {
  top: 62px;
  background: #ffd140;
}

.showcase-book.c {
  top: 86px;
  background: #4d78e8;
}

.certificate-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

.certificate-card {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 22px 10px 16px;
  border-radius: 18px;
  background: #fff;
  color: var(--module-color);
  box-shadow: 0 12px 26px rgba(24, 54, 47, 0.08);
  text-align: center;
}

.certificate-card:nth-child(1),
.certificate-card:nth-child(2) {
  grid-column: span 3;
}

.certificate-card:nth-child(3),
.certificate-card:nth-child(4),
.certificate-card:nth-child(5) {
  min-height: 148px;
  grid-column: span 2;
}

.module-rank {
  position: absolute;
  left: 0;
  top: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom-right-radius: 28px;
  background: var(--module-color);
  color: #fff;
  font-size: 21px;
  font-weight: 900;
}

.certificate-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: color-mix(in srgb, var(--module-color) 14%, #fff);
  font-size: 24px;
  font-weight: 900;
}

.certificate-card strong {
  font-size: 17px;
  font-weight: 900;
}

.certificate-card em {
  color: #717e7a;
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  line-height: 1.55;
}

.module-arrow {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: color-mix(in srgb, var(--module-color) 14%, #fff);
  font-size: 24px;
  font-weight: 900;
}

.module-green {
  --module-color: #12b96f;
}

.module-blue {
  --module-color: #1f73de;
}

.module-purple {
  --module-color: #8a52ed;
}

.module-amber {
  --module-color: #ff9316;
}

.module-rose {
  --module-color: #f34f80;
}

.inline-back {
  margin-bottom: 12px;
  background: transparent;
  color: #0f7f5c;
  font-size: 14px;
  font-weight: 800;
}

@media (max-width: 768px) {
  :root {
    background: #f6faf8;
  }

  body {
    display: block;
    min-height: 100vh;
    padding: 0;
    background: #f6faf8;
  }

  .phone-shell {
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    padding: 0;
    border-radius: 0;
    background: #f6faf8;
    box-shadow: none;
  }

  .screen {
    height: 100vh;
    border-radius: 0;
  }
}
