body {
  margin: 0;
  font-family: Arial, "Noto Sans TC", sans-serif;
  background: linear-gradient(180deg, #fff7ed, #fef3c7);
  color: #111827;
}

.app {
  max-width: 1100px;
  margin: auto;
  padding: 28px;
}

.hero {
  background: linear-gradient(135deg, #dc2626, #f97316);
  color: white;
  padding: 32px;
  border-radius: 28px;
  margin-bottom: 28px;
}

.card {
  background: white;
  border: 1px solid #fed7aa;
  border-radius: 20px;
  padding: 22px;
  margin: 16px 0;
  box-shadow: 0 6px 18px rgba(124,45,18,.08);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(180px,1fr));
  gap: 16px;
}

.btn {
  background: #f97316;
  color: white;
  border: none;
  padding: 11px 16px;
  border-radius: 12px;
  font-weight: bold;
  cursor: pointer;
  margin: 4px;
}

.item {
  cursor: pointer;
}

.item:hover {
  transform: translateY(-3px);
}

pre {
  white-space: pre-wrap;
  line-height: 1.8;
  font-size: 26px;
  background: #f1f5f9;
  padding: 16px;
  border-radius: 12px;
}

.vocab-card {
  display: grid;
  grid-template-columns: 40px 1fr auto;
  gap: 14px;
  background: #fffaf0;
  border: 1px solid #fed7aa;
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 12px;
}

.vocab-no {
  background: #f97316;
  color: white;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

.vocab-word {
  font-size: 30px;
  font-weight: bold;
  color: #7c2d12;
}

.vocab-pinyin {
  color: #2563eb;
}

.input {
  width: 100%;
  padding: 14px;
  font-size: 22px;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  margin-top: 12px;
}
.flash-card {
  background: #fffaf0;
  border: 2px dashed #fb923c;
  border-radius: 22px;
  min-height: 260px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  cursor: pointer;
  margin-top: 16px;
}

.flash-word {
  font-size: 72px;
  font-weight: bold;
  color: #7c2d12;
}

.flash-pinyin {
  font-size: 34px;
  font-weight: bold;
  color: #2563eb;
}

.flash-meaning {
  font-size: 28px;
  font-weight: bold;
  margin-top: 12px;
}

.flash-pos {
  display: inline-block;
  background: #ffedd5;
  color: #9a3412;
  padding: 6px 12px;
  border-radius: 999px;
  margin-top: 12px;
}

.flash-hint {
  margin-top: 12px;
  color: #92400e;
}
.writer-box {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}

.writer-char-box {
  width: 220px;
  height: 220px;
  background: white;
  border-radius: 16px;
  border: 1px solid #fed7aa;
}
.stroke-progress {
  text-align: center;
  font-size: 22px;
  font-weight: bold;
  color: #7c2d12;
  margin-bottom: 12px;
}

.stroke-complete {
  text-align: center;
  font-size: 28px;
  font-weight: bold;
  color: #16a34a;
  padding: 40px 0;
}

.writer-char-box {
  width: 260px;
  height: 260px;
  margin: auto;
  background: white;
  border-radius: 16px;
  border: 1px solid #fed7aa;
}
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
}

.dashboard-card {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 18px;
  padding: 18px;
  text-align: center;
}

.dashboard-num {
  font-size: 34px;
  font-weight: bold;
  color: #ea580c;
}

.sentence-card {
  background: #fffaf0;
  border: 1px dashed #fb923c;
  border-radius: 18px;
  padding: 20px;
  margin-top: 16px;
}

.sentence-input {
  width: 100%;
  min-height: 120px;
  margin: 16px 0;
  padding: 14px;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  font-size: 20px;
  line-height: 1.7;
}

.sentence-result {
  margin-top: 18px;
  background: #fff7ed;
  border-radius: 16px;
  padding: 18px;
  color: #7c2d12;
}

.sentence-score {
  font-size: 28px;
  font-weight: bold;
  color: #16a34a;
}
.sentence-badge{
    display:inline-block;
    margin:10px 0;
    padding:8px 14px;
    border-radius:999px;
    background:#ecfdf5;
    color:#166534;
    font-weight:bold;
}

.score-breakdown{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:12px;
    margin-top:20px;
}

.score-breakdown div{
    background:#fff;
    border:1px solid #ffd7aa;
    border-radius:12px;
    padding:12px;
    text-align:center;
    font-size:18px;
}
pre {
  font-size: 26px;
  line-height: 1.9;
}

@media (max-width: 600px) {
  pre {
    font-size: 22px;
    line-height: 1.8;
  }
}
.dialogue-line {
  font-size: 28px;
  line-height: 1.9;
  font-weight: 500;
}

.dialogue-line div:first-child {
  font-size: 30px;
  line-height: 1.9;
}

.shadow-actions .btn,
.dialogue-line .btn {
  font-size: 17px;
  padding: 12px 18px;
}

@media (max-width: 600px) {
  .dialogue-line {
    font-size: 23px;
    line-height: 1.8;
  }

  .dialogue-line div:first-child {
    font-size: 24px;
  }
}

.dialogue-line,
.shadow-line,
.shadow-card,
.shadow-item {
  font-size: 30px !important;
  line-height: 1.9 !important;
  font-weight: 500 !important;
}

.dialogue-line div,
.shadow-line div,
.shadow-card div,
.shadow-item div {
  font-size: 30px !important;
  line-height: 1.9 !important;
}

@media (max-width: 600px) {
  .dialogue-line,
  .shadow-line,
  .shadow-card,
  .shadow-item,
  .dialogue-line div,
  .shadow-line div,
  .shadow-card div,
  .shadow-item div {
    font-size: 24px !important;
  }
}