.nav-xp {
  background: linear-gradient(135deg, #5b5ef4, #7209b7);
  color: white; font-weight: 800; font-size: 0.8rem;
  padding: 0.3rem 0.8rem; border-radius: 50px;
}

/* ===== HERO ===== */
.wt-hero {
  padding: 3rem 4rem 2rem; text-align: center;
  background: linear-gradient(145deg, #eef0ff 0%, #fce7ff 50%, #fff0e8 100%);
}
.wt-hero h1 { font-size: 2.2rem; font-weight: 900; margin-bottom: 0.5rem; }
.wt-hero p { color: var(--muted); font-size: 1.05rem; max-width: 600px; margin: 0 auto; }

/* ===== LAYOUT ===== */
.wt-container { max-width: 860px; margin: 0 auto; padding: 2rem 1.5rem; }
.wt-section { background: var(--bg); }
.wt-section:nth-child(even) { background: white; }
.wt-card {
  background: white; border-radius: var(--radius-lg); padding: 2rem;
  box-shadow: var(--shadow); border: 2px solid rgba(91,94,244,0.08);
}
.wt-card-title { font-size: 1.3rem; font-weight: 900; margin-bottom: 0.5rem; }
.wt-card-sub { color: var(--muted); font-size: 0.92rem; margin-bottom: 1.5rem; }

/* ===== TASK PICKER ===== */
.wt-task-picker {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}
.wt-task-option {
  padding: 1.2rem 0.8rem; border-radius: 16px;
  border: 2.5px solid #e8eaff; background: #fafbff;
  text-align: center; cursor: pointer;
  transition: all 0.25s ease;
}
.wt-task-option:hover {
  border-color: #5b5ef4; background: #f0f2ff;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(91,94,244,0.15);
}
.wt-task-option.selected {
  border-color: #5b5ef4;
  background: linear-gradient(135deg, #5b5ef4, #7209b7);
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(91,94,244,0.3);
}
.wt-task-option.selected .wt-task-icon,
.wt-task-option.selected .wt-task-name,
.wt-task-option.selected .wt-task-desc { color: white; }
.wt-task-icon { font-size: 1.8rem; margin-bottom: 0.3rem; }
.wt-task-name { font-weight: 900; font-size: 0.9rem; margin-bottom: 0.1rem; }
.wt-task-desc { font-size: 0.72rem; color: #94a3b8; font-weight: 700; }

/* ===== PROMPT BOX ===== */
.wt-prompt-box {
  background: linear-gradient(135deg, #f5f6ff, #fef5ff);
  border: 2px solid #e8eaff; border-radius: 16px;
  padding: 1.5rem; margin-bottom: 1.5rem;
  animation: fadeSlideDown 0.3s ease;
}
@keyframes fadeSlideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
.wt-prompt-label {
  font-size: 0.72rem; font-weight: 900; text-transform: uppercase;
  letter-spacing: 1px; color: #64748b; margin-bottom: 0.5rem;
}
.wt-prompt-text {
  font-size: 1.1rem; font-weight: 800; line-height: 1.7;
  color: var(--text); margin-bottom: 0.75rem;
}
.wt-prompt-meta {
  display: flex; align-items: center; gap: 0.6rem; flex-wrap: wrap;
}
.wt-prompt-badge {
  background: linear-gradient(135deg, #5b5ef4, #7209b7);
  color: white; font-weight: 800; font-size: 0.75rem;
  padding: 0.25rem 0.7rem; border-radius: 50px;
}
.wt-prompt-marks {
  font-weight: 800; font-size: 0.8rem; color: #059669;
  background: #ecfdf5; padding: 0.25rem 0.7rem; border-radius: 50px;
}
.wt-new-prompt-btn {
  margin-left: auto; background: none; border: 1.5px solid #e8eaff;
  padding: 0.3rem 0.75rem; border-radius: 50px;
  font-family: 'Nunito', sans-serif; font-weight: 800; font-size: 0.78rem;
  cursor: pointer; color: #64748b; transition: all 0.15s;
}
.wt-new-prompt-btn:hover { border-color: #5b5ef4; color: #5b5ef4; }

/* ===== MODE TOGGLE ===== */
.wt-mode-toggle {
  display: flex; gap: 0.5rem; margin-bottom: 1.25rem;
  background: #f5f6ff; border-radius: 14px; padding: 0.35rem;
}
.wt-mode-btn {
  flex: 1; padding: 0.7rem; border-radius: 11px;
  border: none; background: transparent;
  font-family: 'Nunito', sans-serif; font-weight: 800; font-size: 0.88rem;
  cursor: pointer; color: #64748b; transition: all 0.2s;
  display: flex; align-items: center; justify-content: center; gap: 0.4rem;
}
.wt-mode-btn.active {
  background: white; color: #5b5ef4;
  box-shadow: 0 2px 8px rgba(91,94,244,0.15);
}
.wt-mode-btn:hover:not(.active) { color: #5b5ef4; }
.wt-mode-icon { font-size: 1.1rem; }

/* ===== TYPE AREA ===== */
.wt-textarea {
  width: 100%; padding: 1rem 1.2rem;
  border: 2px solid #e8eaff; border-radius: 16px;
  font-family: 'Nunito', sans-serif; font-size: 0.95rem;
  font-weight: 600; line-height: 1.8; color: var(--text);
  outline: none; resize: vertical; min-height: 200px;
  transition: border-color 0.2s;
}
.wt-textarea:focus { border-color: #5b5ef4; }
.wt-textarea-sm { min-height: 140px; font-size: 0.9rem; }
.wt-type-footer {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 0.5rem; padding: 0 0.25rem;
}
.wt-word-count, .wt-char-count {
  font-size: 0.78rem; font-weight: 700; color: #94a3b8;
}

/* ===== CAMERA AREA ===== */
.wt-cam-instructions {
  text-align: center; padding: 1rem 0 1.25rem;
}
.wt-cam-instructions p { font-weight: 800; font-size: 0.95rem; color: var(--text); }
.wt-cam-tip { font-size: 0.82rem !important; color: #94a3b8 !important; font-weight: 700 !important; margin-top: 0.3rem; }

.wt-cam-options {
  display: flex; gap: 1rem; justify-content: center; margin-bottom: 1.25rem;
}
.wt-cam-btn {
  display: flex; flex-direction: column; align-items: center; gap: 0.4rem;
  padding: 1.5rem 2rem; border-radius: 16px;
  border: 3px dashed #d0d4f8; background: #fafbff;
  cursor: pointer; transition: all 0.25s;
  font-family: 'Nunito', sans-serif; font-weight: 800; font-size: 0.88rem;
  color: var(--text);
}
.wt-cam-btn:hover {
  border-color: #5b5ef4; background: #f0f2ff;
  transform: translateY(-2px);
}
.wt-cam-icon { font-size: 2rem; }

/* ===== IMAGE PREVIEW ===== */
.wt-img-preview {
  position: relative; text-align: center;
  margin-bottom: 1rem; animation: fadeSlideDown 0.3s ease;
}
.wt-img-preview img {
  max-width: 100%; max-height: 400px;
  border-radius: 16px; border: 2px solid #e8eaff;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.wt-img-remove {
  position: absolute; top: 0.75rem; right: 0.75rem;
  background: rgba(220,38,38,0.9); color: white;
  border: none; border-radius: 50px; padding: 0.4rem 0.8rem;
  font-family: 'Nunito', sans-serif; font-weight: 800; font-size: 0.78rem;
  cursor: pointer; transition: background 0.2s;
}
.wt-img-remove:hover { background: #dc2626; }

/* ===== OCR PROGRESS ===== */
.wt-ocr-status {
  margin-bottom: 1rem; animation: fadeSlideDown 0.3s ease;
}
.wt-ocr-bar {
  height: 8px; background: #eeeeff; border-radius: 50px;
  overflow: hidden; margin-bottom: 0.5rem;
}
.wt-ocr-fill {
  height: 100%; border-radius: 50px; width: 0%;
  background: linear-gradient(90deg, #5b5ef4, #7209b7);
  transition: width 0.4s ease;
}
.wt-ocr-text {
  font-size: 0.82rem; font-weight: 800; color: #5b5ef4;
}

/* ===== OCR REVIEW ===== */
.wt-ocr-review {
  margin-bottom: 1rem; animation: fadeSlideDown 0.3s ease;
}
.wt-ocr-label {
  font-size: 0.85rem; font-weight: 800; margin-bottom: 0.5rem;
  color: var(--text);
}
.wt-ocr-label em { color: #f59e0b; font-style: normal; font-weight: 700; }
.wt-ocr-confirm-btn {
  background: #ecfdf5; border: 1.5px solid #6ee7b7; color: #059669;
  padding: 0.4rem 1rem; border-radius: 50px;
  font-family: 'Nunito', sans-serif; font-weight: 800; font-size: 0.82rem;
  cursor: pointer; transition: all 0.15s;
}
.wt-ocr-confirm-btn:hover { background: #d1fae5; }

/* ===== SUBMIT BUTTON ===== */
.wt-submit-btn {
  width: 100%; margin-top: 1.25rem; font-size: 1.05rem; padding: 1rem;
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
}
.wt-submit-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }
.spinner {
  width: 18px; height: 18px; border: 3px solid rgba(255,255,255,0.3);
  border-top-color: white; border-radius: 50%;
  animation: spin 0.6s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ===== FEEDBACK SECTION ===== */
.wt-feedback-section { background: linear-gradient(160deg, #f0f2ff 0%, #fef5ff 100%) !important; }
.wt-fb-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem;
}

/* Score Ring */
.wt-score-ring {
  position: relative; width: 100px; height: 100px;
}
.wt-score-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-bg {
  fill: none; stroke: #eeeeff; stroke-width: 10;
}
.ring-fill {
  fill: none; stroke: url(#scoreGrad); stroke-width: 10;
  stroke-linecap: round; stroke-dasharray: 327;
  stroke-dashoffset: 327; transition: stroke-dashoffset 1s ease;
}
.ring-text {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  text-align: center; line-height: 1;
}
.ring-score { font-size: 1.8rem; font-weight: 900; color: var(--text); display: block; }
.ring-total { font-size: 0.75rem; font-weight: 700; color: #94a3b8; }

/* Score Bars */
.wt-score-bars {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 0.75rem; margin-bottom: 1.5rem;
}
.wt-score-bar-item {
  background: #fafbff; border-radius: 12px;
  padding: 0.75rem 1rem; border: 1.5px solid #eeeeff;
}
.wt-sb-label {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 0.4rem;
}
.wt-sb-name { font-size: 0.78rem; font-weight: 800; color: var(--text); }
.wt-sb-score { font-size: 0.78rem; font-weight: 900; color: #5b5ef4; }
.wt-sb-bar {
  height: 6px; background: #eeeeff; border-radius: 50px; overflow: hidden;
}
.wt-sb-fill {
  height: 100%; border-radius: 50px;
  background: linear-gradient(90deg, #5b5ef4, #7209b7);
  transition: width 0.8s ease;
}

/* Detailed Feedback */
.wt-fb-details { margin-bottom: 1.5rem; }
.wt-fb-item {
  padding: 1rem; border-radius: 12px;
  border-left: 4px solid; margin-bottom: 0.75rem;
  background: white;
}
.wt-fb-item.error { border-left-color: #f87171; }
.wt-fb-item.warning { border-left-color: #fbbf24; }
.wt-fb-item.good { border-left-color: #34d399; }
.wt-fb-item-header {
  display: flex; align-items: center; gap: 0.5rem;
  font-weight: 800; font-size: 0.88rem; margin-bottom: 0.3rem;
}
.wt-fb-item-text {
  font-size: 0.85rem; color: var(--muted); line-height: 1.7;
}
.wt-fb-item-original {
  font-size: 0.82rem; background: #fef2f2; padding: 0.4rem 0.7rem;
  border-radius: 8px; margin-top: 0.4rem; color: #dc2626;
  text-decoration: line-through; display: inline-block;
}
.wt-fb-item-corrected {
  font-size: 0.82rem; background: #ecfdf5; padding: 0.4rem 0.7rem;
  border-radius: 8px; margin-top: 0.3rem; color: #059669;
  display: inline-block;
}

/* Corrected version */
.wt-corrected { margin-bottom: 1.5rem; }
.wt-corrected h3 { font-size: 1.05rem; font-weight: 900; margin-bottom: 0.75rem; }
.wt-corrected-text {
  background: #ecfdf5; border: 2px solid #a7f3d0; border-radius: 14px;
  padding: 1.25rem; font-size: 0.92rem; line-height: 1.8;
  color: #065f46;
}

/* Tips */
.wt-tips { margin-bottom: 1.5rem; }
.wt-tips h3 { font-size: 1.05rem; font-weight: 900; margin-bottom: 0.75rem; }
.wt-tips-list {
  list-style: none; padding: 0;
  display: flex; flex-direction: column; gap: 0.5rem;
}
.wt-tips-list li {
  font-size: 0.88rem; font-weight: 700; color: var(--text);
  padding: 0.6rem 1rem; background: #fafbff;
  border-radius: 10px; border: 1.5px solid #eeeeff;
  padding-left: 2rem; position: relative; line-height: 1.6;
}
.wt-tips-list li::before {
  content: '💡'; position: absolute; left: 0.6rem; top: 0.55rem;
}

/* Actions */
.wt-fb-actions {
  display: flex; gap: 0.75rem; flex-wrap: wrap;
}

/* ===== PAST LIST ===== */
.wt-past-section { background: var(--bg) !important; }
.wt-past-list {
  display: flex; flex-direction: column; gap: 0.75rem; margin-top: 1rem;
}
.wt-empty {
  text-align: center; padding: 2rem; color: var(--muted);
  font-size: 0.92rem; font-weight: 700;
}
.wt-past-card {
  display: flex; align-items: center; gap: 1rem;
  background: white; border-radius: var(--radius); padding: 1rem 1.25rem;
  box-shadow: var(--shadow); transition: all 0.2s;
  border: 2px solid transparent;
}
.wt-past-card:hover { border-color: rgba(91,94,244,0.15); transform: translateX(4px); }
.wt-past-icon { font-size: 1.5rem; }
.wt-past-info { flex: 1; }
.wt-past-title { font-weight: 800; font-size: 0.92rem; }
.wt-past-date { font-size: 0.78rem; color: var(--muted); }
.wt-past-score {
  font-weight: 900; font-size: 1.1rem; padding: 0.3rem 0.8rem;
  border-radius: 50px; min-width: 50px; text-align: center;
}
.wt-past-score.high { background: rgba(6,214,160,0.15); color: #059669; }
.wt-past-score.mid { background: rgba(251,191,36,0.15); color: #b45309; }
.wt-past-score.low { background: rgba(248,113,113,0.15); color: #dc2626; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .wt-hero { padding: 2rem 1.5rem 1.5rem; }
  .wt-hero h1 { font-size: 1.6rem; }
  .wt-container { padding: 1.5rem 1rem; }
  .wt-card { padding: 1.25rem; }
  .wt-task-picker { grid-template-columns: repeat(2, 1fr); }
  .wt-cam-options { flex-direction: column; align-items: center; }
  .wt-cam-btn { width: 100%; flex-direction: row; padding: 1rem 1.5rem; }
  .wt-score-bars { grid-template-columns: 1fr; }
  .wt-fb-header { flex-direction: column; align-items: flex-start; }
  .wt-fb-actions { flex-direction: column; }
  .wt-fb-actions .btn { width: 100%; }
}
