:root {
  color-scheme: light;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  background: #deded9;
  color: #101010;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  display: grid;
  grid-template-columns: minmax(250px, 390px) minmax(360px, 430px);
  align-items: center;
  justify-content: center;
  gap: 72px;
  padding: 34px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .035) 1px, transparent 1px),
    linear-gradient(rgba(0, 0, 0, .035) 1px, transparent 1px),
    #e6e6e1;
  background-size: 28px 28px;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.desktop-note {
  max-width: 370px;
}

.desktop-note h1 {
  margin: 16px 0 14px;
  font-size: clamp(52px, 7vw, 88px);
  line-height: .94;
  letter-spacing: -.065em;
}

.desktop-note p {
  max-width: 330px;
  margin: 0;
  color: #61615d;
  font-size: 15px;
  line-height: 1.8;
}

.note-index,
.eyebrow {
  color: #6d6d69;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
}

.phone {
  width: 100%;
  height: min(860px, calc(100vh - 40px));
  min-height: 680px;
  overflow: hidden;
  display: grid;
  grid-template-rows: 52px 1fr 72px;
  background: #f5f5f2;
  border: 1px solid #111;
  border-radius: 26px;
  box-shadow: 20px 24px 0 #111;
}

.phone-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  background: #fff;
  border-bottom: 1px solid #deded9;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .12em;
}

.live-dot {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #60605d;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.header-actions a {
  color: #111;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.live-dot i {
  width: 7px;
  height: 7px;
  display: block;
  background: #111;
  border-radius: 50%;
}

.screen {
  overflow-y: auto;
  padding: 28px 24px 40px;
  scrollbar-width: thin;
}

.tabbar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: #fff;
  border-top: 1px solid #deded9;
}

.tab {
  padding: 10px 4px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: transparent;
  border: 0;
  color: #8a8a85;
  font-size: 11px;
}

.tab span {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
}

.tab.active {
  background: #111;
  color: #fff;
}

.page-title {
  margin: 10px 0 0;
  font-size: 36px;
  line-height: 1.12;
  letter-spacing: -.045em;
}

.subtitle {
  margin: 12px 0 0;
  color: #656560;
  font-size: 13px;
  line-height: 1.7;
}

.card {
  background: #fff;
  border: 1px solid #d9d9d3;
  border-radius: 12px;
}

.plan-card {
  margin-top: 28px;
  padding: 22px;
}

.plan-top,
.section-head,
.quiz-meta,
.study-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.label,
.metric-label,
.mode-desc,
.input-label {
  color: #777772;
  font-size: 11px;
}

.plan-number {
  margin-top: 2px;
  font-size: 43px;
  font-weight: 800;
  letter-spacing: -.045em;
}

.plan-number small {
  color: #a2a29d;
  font-size: 17px;
  font-weight: 500;
}

.percentage {
  padding: 6px 9px;
  background: #111;
  border-radius: 5px;
  color: #fff;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 11px;
}

.progress {
  height: 6px;
  margin-top: 18px;
  overflow: hidden;
  background: #e9e9e5;
  border-radius: 99px;
}

.progress > i {
  height: 100%;
  display: block;
  background: #111;
}

.metrics {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.metric {
  text-align: center;
  border-right: 1px solid #e4e4df;
}

.metric:last-child {
  border-right: 0;
}

.metric-value {
  font-size: 18px;
  font-weight: 750;
}

.primary,
.outline {
  width: 100%;
  min-height: 52px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 750;
}

.primary {
  background: #111;
  border: 1px solid #111;
  color: #fff;
}

.outline {
  background: #fff;
  border: 1px solid #111;
  color: #111;
}

.start-button {
  margin-top: 14px;
}

.section-head {
  margin: 30px 2px 12px;
  align-items: baseline;
  font-size: 13px;
  font-weight: 750;
}

.section-head small {
  color: #777772;
  font-size: 10px;
  font-weight: 500;
}

.quick-grid,
.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.quick-card {
  padding: 16px;
  text-align: left;
  color: #111;
}

button.quick-card {
  width: 100%;
}

.quick-card:hover,
.mode-card:hover,
.option:hover {
  border-color: #111;
}

.quick-index,
.mode-number {
  color: #898984;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
}

.quick-title {
  margin-top: 25px;
  font-size: 16px;
  font-weight: 800;
}

.quick-desc {
  margin-top: 4px;
  color: #777772;
  font-size: 10px;
}

.study-progress {
  height: 3px;
  margin-top: 13px;
  background: #ddd;
}

.study-progress i {
  height: 100%;
  display: block;
  background: #111;
}

.word-card {
  min-height: 430px;
  margin-top: 22px;
  padding: 36px 28px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 16px 38px rgba(0, 0, 0, .04);
}

.word {
  font-size: 44px;
  font-weight: 820;
  letter-spacing: -.04em;
}

.phonetic {
  margin-top: 5px;
  color: #777772;
  font-size: 15px;
}

.recall-tip {
  margin: auto 0 18px;
  color: #92928d;
  font-size: 12px;
  text-align: center;
}

.meaning {
  margin-top: 46px;
  font-size: 20px;
  font-weight: 750;
  line-height: 1.55;
}

.meaning em {
  margin-right: 6px;
  color: #777772;
  font-family: Georgia, serif;
  font-size: 13px;
  font-weight: 400;
}

.short-rule {
  width: 30px;
  height: 2px;
  margin: 25px 0;
  background: #111;
}

.example {
  margin: 0;
  font-family: Georgia, serif;
  font-size: 15px;
  line-height: 1.65;
}

.translation {
  margin: 9px 0 0;
  color: #747470;
  font-size: 12px;
  line-height: 1.6;
}

.reveal-button {
  margin-top: 14px;
}

.rating-title {
  margin: 14px 0 8px;
  color: #777772;
  font-size: 11px;
  text-align: center;
}

.rating-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
}

.rating {
  min-height: 54px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid #d5d5d0;
  border-radius: 7px;
  color: #111;
  font-size: 12px;
  font-weight: 750;
}

.rating small {
  margin-top: 3px;
  color: #858580;
  font-size: 9px;
  font-weight: 400;
}

.rating.dark {
  background: #111;
  border-color: #111;
  color: #fff;
}

.rating.dark small {
  color: #bdbdb8;
}

.mode-card {
  width: 100%;
  margin-top: 15px;
  padding: 20px;
  display: grid;
  grid-template-columns: 40px 1fr auto;
  align-items: center;
  color: #111;
  text-align: left;
}

.mode-card:first-of-type {
  margin-top: 30px;
}

.mode-title {
  font-size: 16px;
  font-weight: 750;
}

.mode-desc {
  margin-top: 5px;
}

.arrow {
  font-size: 21px;
}

.practice-note {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid #d8d8d3;
  color: #6d6d68;
  font-size: 12px;
  line-height: 1.7;
}

.quiz-word {
  margin-top: 54px;
  font-size: 42px;
  font-weight: 820;
  letter-spacing: -.04em;
  text-align: center;
}

.prompt {
  margin-top: 8px;
  color: #777772;
  font-size: 12px;
  text-align: center;
}

.options {
  margin-top: 38px;
  display: grid;
  gap: 9px;
}

.option {
  min-height: 52px;
  padding: 10px 14px;
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid #d8d8d3;
  border-radius: 7px;
  color: #111;
  text-align: left;
}

.option-index {
  width: 28px;
  height: 28px;
  background: #eee;
  border-radius: 50%;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  line-height: 28px;
  text-align: center;
}

.option.correct {
  border: 2px solid #111;
}

.option.correct .option-index {
  background: #111;
  color: #fff;
}

.option.wrong {
  opacity: .4;
}

.feedback {
  margin-top: 17px;
  color: #656560;
  font-size: 11px;
  text-align: center;
}

.feedback .primary {
  margin-top: 11px;
}

.definition-card {
  margin-top: 34px;
  padding: 34px 22px;
  text-align: center;
}

.part {
  color: #777772;
  font-family: Georgia, serif;
  font-size: 13px;
  font-style: italic;
}

.definition {
  margin-top: 10px;
  font-size: 24px;
  font-weight: 760;
  line-height: 1.45;
}

.hint {
  margin-top: 22px;
  color: #878782;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
}

.input-label {
  margin-top: 30px;
}

.word-input {
  width: 100%;
  height: 58px;
  margin-top: 7px;
  padding: 0 15px;
  background: #fff;
  border: 2px solid #111;
  border-radius: 7px;
  outline: none;
  font-size: 22px;
  font-weight: 750;
  letter-spacing: .06em;
}

.word-input.correct {
  background: #111;
  color: #fff;
}

.word-input.wrong {
  border-style: dashed;
}

.answer-line {
  margin-top: 12px;
  font-size: 13px;
  font-weight: 750;
  text-align: center;
}

.quiz-action {
  margin-top: 18px;
}

.result {
  padding-top: 74px;
  text-align: center;
}

.result-score {
  margin-top: 12px;
  font-size: 74px;
  font-weight: 850;
  letter-spacing: -.06em;
}

.result-score small {
  color: #a0a09b;
  font-size: 24px;
  font-weight: 500;
}

.result-title {
  font-size: 20px;
  font-weight: 750;
}

.result .primary {
  margin-top: 30px;
}

.hero-stat {
  margin-top: 28px;
  padding: 28px 22px;
}

.hero-number {
  font-size: 58px;
  font-weight: 850;
  line-height: 1;
}

.hero-label,
.stat-label {
  margin-top: 7px;
  color: #777772;
  font-size: 11px;
}

.stat-grid {
  margin-top: 10px;
}

.stat-card {
  padding: 18px;
}

.stat-number {
  font-size: 24px;
  font-weight: 800;
}

.stats-note {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid #d8d8d3;
  color: #777772;
  font-size: 11px;
  line-height: 1.75;
}

.empty,
.loading,
.error {
  padding: 100px 10px 0;
  color: #777772;
  text-align: center;
}

.done-mark {
  width: 58px;
  height: 58px;
  margin: 0 auto 20px;
  background: #111;
  border-radius: 50%;
  color: #fff;
  font-size: 28px;
  line-height: 58px;
}

.done-title {
  color: #111;
  font-size: 24px;
  font-weight: 800;
}

@media (max-width: 820px) {
  body {
    min-height: 100dvh;
    display: block;
    padding: 0;
    background: #f5f5f2;
  }

  .desktop-note {
    display: none;
  }

  .phone {
    width: 100%;
    height: 100dvh;
    min-height: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
}
