/* ══════════════════════════════════════════════════════════════
   motaanh.css — Mô Tả Ảnh (S65)
   Dark-first, html[data-theme="light"] override
   ══════════════════════════════════════════════════════════════ */

:root {
  --mta-accent: #d4af37;
  --mta-correct: #4caf50;
  --mta-wrong: #ef5350;
}

* { box-sizing: border-box; }

body {
  margin: 0; padding: 0;
  background: var(--ytt-bg-0, #0f0f12);
  color: var(--ytt-text-1, #f5f6fa);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  overflow-y: auto; overflow-x: hidden;
}
html[data-theme="light"] body { background: #f5f0eb; color: #2c3840; }

/* ── Main container ──────────────────────────────────────── */
.mta-main {
  max-width: 640px; margin: 0 auto;
  padding: 12px 14px 32px;
  display: flex; flex-direction: column; gap: 10px;
}

/* ── Header ─────────────────────────────────────────────── */
.mta-header {
  display: flex; align-items: center; justify-content: space-between;
}
.mta-header-info { display: flex; align-items: center; gap: 8px; }
.mta-img-counter { font-size: 0.8rem; color: var(--ytt-text-2, #a4b0be); }
.mta-difficulty-badge {
  font-size: 0.72rem; font-weight: 700; padding: 2px 8px;
  border-radius: 20px; background: rgba(212,175,55,0.15);
  color: var(--mta-accent); border: 1px solid rgba(212,175,55,0.3);
}
html[data-theme="light"] .mta-difficulty-badge { background: #fdf6e3; border-color: #e8d78a; color: #8a6800; }

.mta-header-btns { display: flex; gap: 6px; }
.mta-nav-btn {
  width: 34px; height: 34px; border-radius: 8px;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12);
  color: var(--ytt-text-1, #f5f6fa); font-size: 0.85rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s;
}
.mta-nav-btn:hover { background: rgba(255,255,255,0.14); }
.mta-shuffle { color: var(--mta-accent); }
html[data-theme="light"] .mta-nav-btn { background: #fff; border-color: #ddd; color: #4a5568; }
html[data-theme="light"] .mta-nav-btn:hover { background: #f0ebe4; }

/* ── Image display ──────────────────────────────────────── */
.mta-image-wrap {
  position: relative; width: 100%;
  border-radius: 14px; overflow: hidden;
  background: rgba(255,255,255,0.04);
  aspect-ratio: 4/3;
}
.mta-img {
  width: 100%; height: 100%; object-fit: cover;
  display: block; transition: opacity 0.3s;
}
.mta-img.loading { opacity: 0; }
.mta-img-loading {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; color: rgba(255,255,255,0.3);
  pointer-events: none;
}
html[data-theme="light"] .mta-image-wrap { background: #e8e0d8; }

/* ── Hint row ───────────────────────────────────────────── */
.mta-hint-row { display: flex; flex-direction: column; gap: 6px; }
.mta-hint-toggle {
  display: flex; align-items: center; gap: 6px;
  background: none; border: none; cursor: pointer;
  color: var(--mta-accent); font-size: 0.82rem; font-weight: 600;
  padding: 4px 0; width: fit-content;
}
.mta-chevron { transition: transform 0.2s; font-size: 0.7rem; }
.mta-chevron.open { transform: rotate(180deg); }
.mta-hint-chips {
  display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 0;
}
.mta-hint-chip {
  padding: 4px 10px; border-radius: 20px;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12);
  font-size: 0.8rem; cursor: default;
  display: flex; align-items: center; gap: 4px;
}
.mta-hint-chip .zh { font-weight: 700; }
.mta-hint-chip .py { color: var(--ytt-text-2, #a4b0be); font-size: 0.72rem; }
html[data-theme="light"] .mta-hint-chip { background: #fff; border-color: #ddd; color: #333; }
html[data-theme="light"] .mta-hint-chip .py { color: #888; }

/* ── Input area ─────────────────────────────────────────── */
.mta-input-area {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 14px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px;
}
html[data-theme="light"] .mta-input-area { background: #fff; border-color: #e0d8d0; }

.mta-input-row { display: flex; gap: 8px; align-items: flex-start; }
.mta-mic-btn {
  width: 40px; height: 40px; min-width: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15);
  color: var(--ytt-text-2, #a4b0be); font-size: 0.9rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.15s; align-self: flex-end;
}
.mta-mic-btn:hover { background: rgba(212,175,55,0.15); color: var(--mta-accent); }
.mta-mic-btn.listening {
  background: rgba(239,83,80,0.2); color: #ef5350; border-color: #ef5350;
  animation: mta-pulse 1s infinite;
}
@keyframes mta-pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(239,83,80,0.5); }
  50%      { box-shadow: 0 0 0 10px rgba(239,83,80,0); }
}
html[data-theme="light"] .mta-mic-btn { background: #f0ebe4; border-color: #d4c4b0; color: #7a6a55; }

.mta-input {
  flex: 1; background: none; border: none; outline: none; resize: none;
  color: var(--ytt-text-1, #f5f6fa); font-size: 0.95rem; line-height: 1.5;
  font-family: inherit; min-height: 72px;
}
.mta-input::placeholder { color: rgba(164,176,190,0.6); }
html[data-theme="light"] .mta-input { color: #2c3840; }
html[data-theme="light"] .mta-input::placeholder { color: #aaa; }

.mta-input-footer { display: flex; align-items: center; justify-content: space-between; }
.mta-char-count { font-size: 0.75rem; color: var(--ytt-text-2, #a4b0be); }

.mta-submit-btn {
  background: linear-gradient(135deg, #b85c38, #8a3e23);
  border: none; border-radius: 22px; padding: 9px 20px;
  color: #fff; font-size: 0.88rem; font-weight: 700;
  cursor: pointer; display: flex; align-items: center; gap: 7px;
  transition: filter 0.15s;
}
.mta-submit-btn:hover:not(:disabled) { filter: brightness(1.15); }
.mta-submit-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Result panel ───────────────────────────────────────── */
.mta-result {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 14px;
}
html[data-theme="light"] .mta-result { background: #fff; border-color: #e0d8d0; }

.mta-result-header { display: flex; align-items: center; gap: 16px; }

/* Score ring */
.mta-score-ring { position: relative; width: 64px; height: 64px; flex-shrink: 0; }
.mta-score-svg { width: 64px; height: 64px; transform: rotate(-90deg); }
.mta-score-bg { fill: none; stroke: rgba(255,255,255,0.08); stroke-width: 5; }
.mta-score-arc {
  fill: none; stroke: var(--mta-accent); stroke-width: 5;
  stroke-linecap: round; transition: stroke-dashoffset 0.8s ease;
}
.mta-score-arc.good { stroke: var(--mta-correct); }
.mta-score-arc.bad  { stroke: var(--mta-wrong); }
.mta-score-num {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; font-weight: 800; color: var(--ytt-text-1, #f5f6fa);
}

.mta-result-meta { flex: 1; }
.mta-encouragement { font-size: 0.9rem; color: var(--ytt-text-1, #f5f6fa); line-height: 1.4; }
.mta-tv-award {
  margin-top: 6px; display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 10px; border-radius: 20px;
  background: rgba(212,175,55,0.15); color: var(--mta-accent);
  font-size: 0.82rem; font-weight: 700;
}
html[data-theme="light"] .mta-tv-award { background: #fdf6e3; }

/* Section wrappers */
.mta-section-wrap { display: flex; flex-direction: column; gap: 6px; }
.mta-section-title {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.05em;
  color: var(--ytt-text-2, #a4b0be); text-transform: uppercase;
}
html[data-theme="light"] .mta-section-title { color: #888; }

/* Corrections */
.mta-corrections { display: flex; flex-direction: column; gap: 6px; }
.mta-correction-item {
  background: rgba(239,83,80,0.08); border: 1px solid rgba(239,83,80,0.2);
  border-radius: 8px; padding: 8px 12px; font-size: 0.87rem;
}
.mta-correction-item .orig { color: #ef9a9a; text-decoration: line-through; }
.mta-correction-item .fixed { color: var(--mta-correct); font-weight: 700; }
.mta-correction-item .exp { font-size: 0.78rem; color: var(--ytt-text-2, #a4b0be); margin-top: 3px; }
html[data-theme="light"] .mta-correction-item { background: #fff3f3; border-color: #ffc0c0; }
html[data-theme="light"] .mta-correction-item .orig { color: #c62828; }
html[data-theme="light"] .mta-correction-item .exp { color: #666; }

/* Model answer */
.mta-model-zh { font-size: 1.05rem; font-weight: 600; line-height: 1.6; }
.mta-model-py { font-size: 0.82rem; color: var(--ytt-text-2, #a4b0be); margin-top: 2px; }
.mta-model-vi { font-size: 0.82rem; color: var(--ytt-text-2, #a4b0be); font-style: italic; margin-top: 2px; }
html[data-theme="light"] .mta-model-py,
html[data-theme="light"] .mta-model-vi { color: #888; }

.mta-play-btn {
  margin-top: 6px; padding: 6px 14px; border-radius: 20px;
  background: rgba(212,175,55,0.12); border: 1px solid rgba(212,175,55,0.25);
  color: var(--mta-accent); font-size: 0.8rem; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  transition: background 0.15s; width: fit-content;
}
.mta-play-btn:hover { background: rgba(212,175,55,0.2); }

/* Vocab chips */
.mta-vocab-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mta-vocab-chip {
  padding: 5px 12px; border-radius: 20px;
  background: rgba(46,125,140,0.12); border: 1px solid rgba(46,125,140,0.25);
  font-size: 0.82rem; cursor: default;
}
.mta-vocab-chip .vz { font-weight: 700; }
.mta-vocab-chip .vp { font-size: 0.72rem; color: var(--ytt-text-2, #a4b0be); }
.mta-vocab-chip .vv { font-size: 0.72rem; color: var(--ytt-text-2, #a4b0be); }
html[data-theme="light"] .mta-vocab-chip { background: #e8f4f7; border-color: #b0d8e0; }
html[data-theme="light"] .mta-vocab-chip .vp,
html[data-theme="light"] .mta-vocab-chip .vv { color: #667; }

/* Result actions */
.mta-result-actions { display: flex; gap: 10px; }
.mta-retry-btn {
  flex: 1; padding: 10px; border-radius: 10px;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  color: var(--ytt-text-1, #f5f6fa); font-size: 0.88rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.mta-retry-btn:hover { background: rgba(255,255,255,0.1); }
.mta-next-img-btn {
  flex: 1; padding: 10px; border-radius: 10px;
  background: linear-gradient(135deg, #2e7d8c, #1a4f5e);
  border: none; color: #fff; font-size: 0.88rem; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
.mta-next-img-btn:hover { filter: brightness(1.1); }
html[data-theme="light"] .mta-retry-btn { background: #f5f0eb; border-color: #d4c4b0; color: #333; }

/* ── Mobile ─────────────────────────────────────────────── */
@media (max-width: 480px) {
  .mta-main { padding: 10px 10px 24px; gap: 8px; }
  .mta-img { border-radius: 10px; }
  .mta-submit-btn { padding: 8px 14px; font-size: 0.82rem; }
}


/* == HSKK Home mode grid == */
.mta-home{padding:16px 14px 32px;max-width:640px;margin:0 auto;}
.mta-home-header{text-align:center;margin-bottom:20px;}
.mta-home-title{font-size:1.3rem;font-weight:800;margin:0 0 6px;color:var(--ytt-text-1,#f5f6fa);}
.mta-home-desc{font-size:0.82rem;color:var(--ytt-text-2,#a4b0be);margin:0 0 12px;}
html[data-theme=light] .mta-home-title{color:#2c3840;}
.mta-hsk-badge-row{display:flex;gap:8px;justify-content:center;flex-wrap:wrap;}
.mta-hsk-badge{padding:5px 14px;border-radius:20px;font-size:0.8rem;font-weight:700;cursor:pointer;border:1px solid rgba(212,175,55,0.3);color:var(--ytt-text-2,#a4b0be);background:rgba(255,255,255,0.05);transition:all 0.15s;}
.mta-hsk-badge.active,.mta-hsk-badge:hover{background:rgba(212,175,55,0.15);color:var(--mta-accent,#d4af37);border-color:rgba(212,175,55,0.5);}
html[data-theme=light] .mta-hsk-badge{background:#f5f0eb;border-color:#d4c4b0;color:#7a6a55;}
html[data-theme=light] .mta-hsk-badge.active{background:#fdf6e3;color:#8a6800;}
.mta-mode-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;}
.mta-mode-card{background:rgba(255,255,255,0.04);border:1px solid rgba(255,255,255,0.1);border-radius:14px;padding:18px 14px;text-align:left;cursor:pointer;display:flex;flex-direction:column;gap:4px;transition:background 0.15s,border-color 0.15s;}
.mta-mode-card:hover{background:rgba(255,255,255,0.08);border-color:rgba(212,175,55,0.4);}
.mta-mode-card.mta-mode-soon{opacity:0.55;cursor:default;}
.mta-mode-card.mta-mode-soon:hover{background:rgba(255,255,255,0.04);border-color:rgba(255,255,255,0.1);}
html[data-theme=light] .mta-mode-card{background:#fff;border-color:#e0d8d0;}
html[data-theme=light] .mta-mode-card:hover{background:#f5f0eb;border-color:#c4a87a;}
.mta-mode-icon{font-size:1.5rem;color:var(--mta-accent,#d4af37);margin-bottom:4px;}
.mta-mode-label{font-size:0.72rem;font-weight:700;letter-spacing:0.06em;text-transform:uppercase;color:var(--ytt-text-2,#a4b0be);}
.mta-mode-name{font-size:1rem;font-weight:800;color:var(--ytt-text-1,#f5f6fa);}
.mta-mode-desc{font-size:0.78rem;color:var(--ytt-text-2,#a4b0be);line-height:1.4;}
.mta-mode-tag{font-size:0.72rem;color:rgba(164,176,190,0.6);margin-top:4px;}
html[data-theme=light] .mta-mode-name{color:#2c3840;}
html[data-theme=light] .mta-mode-label,html[data-theme=light] .mta-mode-desc,html[data-theme=light] .mta-mode-tag{color:#888;}
.mta-back-btn{background:none;border:none;color:var(--ytt-text-2,#a4b0be);cursor:pointer;font-size:0.82rem;padding:4px 0;display:flex;align-items:center;gap:6px;}
.mta-back-btn:hover{color:var(--ytt-text-1,#f5f6fa);}
.mta-hints-accordion{display:flex;flex-direction:column;gap:6px;}
.mta-acc-item{border-radius:10px;overflow:hidden;border:1px solid rgba(255,255,255,0.08);}
html[data-theme=light] .mta-acc-item{border-color:#e0d8d0;}
.mta-acc-toggle{width:100%;padding:10px 14px;background:rgba(255,255,255,0.04);border:none;text-align:left;color:var(--ytt-text-1,#f5f6fa);cursor:pointer;display:flex;align-items:center;gap:8px;font-size:0.85rem;font-weight:600;}
.mta-acc-toggle .mta-chevron{margin-left:auto;font-size:0.75rem;transition:transform 0.2s;}
.mta-acc-toggle:hover{background:rgba(255,255,255,0.08);}
html[data-theme=light] .mta-acc-toggle{background:#f5f0eb;color:#333;}
.mta-acc-body{padding:10px 14px;background:rgba(255,255,255,0.02);}
html[data-theme=light] .mta-acc-body{background:#fff;}
.mta-tips-list{margin:0 0 8px;padding-left:18px;}
.mta-tips-list li{font-size:0.82rem;color:var(--ytt-text-1,#f5f6fa);margin-bottom:4px;line-height:1.4;}
html[data-theme=light] .mta-tips-list li{color:#333;}
.mta-starter{font-size:0.82rem;padding:6px 10px;border-radius:8px;background:rgba(212,175,55,0.1);color:var(--mta-accent,#d4af37);}
.mta-starter-label{font-weight:700;}
.mta-observe-actions{display:flex;gap:10px;align-items:center;}
.mta-start-speak-btn{flex:1;padding:12px;border-radius:10px;background:linear-gradient(135deg,#b85c38,#8a3e23);border:none;color:#fff;font-size:0.95rem;font-weight:700;cursor:pointer;display:flex;align-items:center;justify-content:center;gap:8px;}
.mta-start-speak-btn:hover{filter:brightness(1.12);}
.mta-skip-btn{padding:12px 16px;border-radius:10px;font-size:0.82rem;background:rgba(255,255,255,0.05);border:1px solid rgba(255,255,255,0.1);color:var(--ytt-text-2,#a4b0be);cursor:pointer;}
html[data-theme=light] .mta-skip-btn{background:#f5f0eb;border-color:#d4c4b0;color:#666;}
.mta-observe-timer{position:absolute;top:10px;right:10px;background:rgba(0,0,0,0.6);color:#fff;font-size:1.1rem;font-weight:800;padding:6px 12px;border-radius:20px;display:flex;align-items:center;gap:2px;}
.mta-image-small{max-height:200px;}
.mta-speak-panel{background:rgba(255,255,255,0.04);border:1px solid rgba(255,255,255,0.1);border-radius:14px;padding:16px;display:flex;flex-direction:column;gap:12px;}
html[data-theme=light] .mta-speak-panel{background:#fff;border-color:#e0d8d0;}
.mta-speak-status{display:flex;align-items:center;gap:10px;font-size:0.9rem;color:var(--ytt-text-1,#f5f6fa);}
.mta-pulse-ring{width:12px;height:12px;border-radius:50%;background:#ef5350;animation:mta-pulse 1s infinite;}
.mta-interim-text{min-height:60px;font-size:1rem;color:var(--ytt-text-1,#f5f6fa);line-height:1.6;background:rgba(255,255,255,0.03);border-radius:8px;padding:10px 12px;}
html[data-theme=light] .mta-interim-text{color:#2c3840;background:#f5f0eb;}
.mta-speak-timer{height:4px;background:rgba(255,255,255,0.1);border-radius:2px;}
.mta-speak-timer-bar{height:100%;width:0;background:var(--mta-accent,#d4af37);border-radius:2px;transition:width 1s linear;}
.mta-done-btn{padding:10px 20px;border-radius:22px;font-size:0.88rem;font-weight:700;background:var(--mta-correct,#4caf50);border:none;color:#fff;cursor:pointer;display:flex;align-items:center;gap:8px;width:fit-content;}
.mta-done-btn:hover{filter:brightness(1.1);}
.mta-transcript-display{font-size:0.95rem;line-height:1.6;color:var(--ytt-text-1,#f5f6fa);background:rgba(255,255,255,0.04);border-radius:8px;padding:10px 12px;}
html[data-theme=light] .mta-transcript-display{background:#f5f0eb;color:#2c3840;}
.mta-model-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:6px;}
.mta-save-vocab-btn{padding:6px 14px;border-radius:20px;font-size:0.8rem;cursor:pointer;background:rgba(46,125,140,0.12);border:1px solid rgba(46,125,140,0.3);color:#2e7d8c;display:inline-flex;align-items:center;gap:6px;}
.mta-save-vocab-btn:disabled{opacity:0.6;cursor:not-allowed;}
html[data-theme=light] .mta-save-vocab-btn{background:#e8f4f7;border-color:#b0d8e0;}
.mta-followup-q{font-size:1rem;font-weight:600;color:var(--ytt-text-1,#f5f6fa);background:rgba(212,175,55,0.08);border-left:3px solid var(--mta-accent,#d4af37);padding:10px 14px;border-radius:0 8px 8px 0;}
.mta-followup-hint{font-size:0.75rem;color:var(--ytt-text-2,#a4b0be);margin-top:4px;}
html[data-theme=light] .mta-followup-q{background:#fdf6e3;color:#2c3840;}

/* ══ S66: Gallery, Tabs, Flip, Progress ═══════════════════════ */

/* ── Gallery view ─────────────────────────────────────────── */
.mta-gallery-view { max-width: 720px; margin: 0 auto; padding: 10px 14px 40px; }

.mta-gallery-header {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 10px; flex-wrap: wrap;
}
.mta-gallery-title {
  flex: 1; display: flex; align-items: center; gap: 8px;
  font-size: 1rem; font-weight: 700; color: var(--ytt-text-1, #f5f6fa);
}
.mta-gallery-count { font-size: 0.75rem; color: var(--ytt-text-2, #a4b0be); font-weight: 400; }
.mta-gallery-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.mta-filter-btn {
  padding: 4px 12px; border-radius: 16px; font-size: 0.75rem; font-weight: 600;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12);
  color: var(--ytt-text-2, #a4b0be); cursor: pointer; transition: all 0.15s;
}
.mta-filter-btn.active {
  background: rgba(212,175,55,0.18); border-color: rgba(212,175,55,0.4);
  color: var(--mta-accent, #d4af37);
}
html[data-theme="light"] .mta-filter-btn { background: #f0ebe4; border-color: #d4c4b0; color: #666; }
html[data-theme="light"] .mta-filter-btn.active { background: #fdf6e3; border-color: #e8d78a; color: #8a6800; }

/* Progress bar tổng gallery */
.mta-gallery-progress {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 14px;
}
.mta-gallery-progress-bar {
  flex: 1; height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px;
  transition: width 0.4s ease;
  background: linear-gradient(90deg, var(--mta-accent, #d4af37) var(--w, 0%), rgba(255,255,255,0.08) var(--w, 0%));
}
.mta-gallery-progress-bar { /* override inline style */ }
.mta-gallery-progress-text { font-size: 0.72rem; color: var(--ytt-text-2, #a4b0be); white-space: nowrap; }

/* Grid ảnh 3 cột desktop, 2 cột mobile */
.mta-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
@media (max-width: 520px) { .mta-gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; } }

.mta-gallery-loading {
  grid-column: 1 / -1; text-align: center;
  color: var(--ytt-text-2, #a4b0be); padding: 40px 0;
}

.mta-gallery-empty {
  grid-column: 1 / -1; text-align: center;
  color: var(--ytt-text-2, #a4b0be); padding: 40px 0;
}
.mta-gallery-empty i { font-size: 2rem; margin-bottom: 10px; display: block; opacity: 0.4; }
.mta-gallery-empty p { font-size: 0.88rem; }

/* Card */
.mta-card {
  border-radius: 10px; overflow: hidden; cursor: pointer;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  transition: transform 0.18s, box-shadow 0.18s;
}
.mta-card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(0,0,0,0.4); }
.mta-card--done { border-color: rgba(212,175,55,0.3); }
html[data-theme="light"] .mta-card { background: #fff; border-color: #e0d8d0; }
html[data-theme="light"] .mta-card--done { border-color: #e8d78a; }

.mta-card-thumb {
  position: relative; aspect-ratio: 4/3; overflow: hidden;
  background: rgba(255,255,255,0.05);
}
.mta-card-img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.25s;
}
.mta-card:hover .mta-card-img { transform: scale(1.05); }

.mta-card-score-badge {
  position: absolute; top: 6px; right: 6px;
  font-size: 0.72rem; font-weight: 800; padding: 2px 7px;
  border-radius: 12px; line-height: 1.6;
  background: rgba(0,0,0,0.7); backdrop-filter: blur(4px);
}
.mta-card-score-badge.good { color: #69f0ae; border: 1px solid rgba(76,175,80,0.5); }
.mta-card-score-badge.ok   { color: var(--mta-accent, #d4af37); border: 1px solid rgba(212,175,55,0.4); }
.mta-card-score-badge.low  { color: #ff7070; border: 1px solid rgba(239,83,80,0.4); }

.mta-card-new-badge {
  position: absolute; top: 6px; right: 6px;
  font-size: 0.65rem; padding: 2px 7px; border-radius: 12px;
  background: rgba(0,0,0,0.6); color: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.15);
}

.mta-card-info { padding: 8px 10px; }
.mta-card-topic { font-size: 0.82rem; font-weight: 600; color: var(--ytt-text-1, #f5f6fa); }
.mta-card-zh { font-size: 0.72rem; color: var(--ytt-text-2, #a4b0be); margin-top: 1px; }
.mta-card-attempts { font-size: 0.65rem; color: var(--mta-accent, #d4af37); margin-top: 2px; }
html[data-theme="light"] .mta-card-topic { color: #2c3840; }
html[data-theme="light"] .mta-card-zh { color: #666; }

/* ── Session header mới ────────────────────────────────────── */
.mta-img-topic {
  font-size: 0.85rem; font-weight: 600; color: var(--ytt-text-1, #f5f6fa);
  max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.mta-phase-indicator { display: flex; align-items: center; gap: 6px; }
.mta-phase-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,0.15); transition: all 0.2s;
}
.mta-phase-dot.active { background: var(--mta-accent, #d4af37); box-shadow: 0 0 6px rgba(212,175,55,0.5); }
.mta-phase-dot.done { background: var(--mta-correct, #4caf50); }

/* ── Image: fix overflow — chiều cao tối đa 45vh ──────────── */
.mta-image-wrap { position: relative; overflow: hidden; border-radius: 12px; }
.mta-img {
  width: 100%; display: block;
  max-height: 45vh; object-fit: cover;
}
.mta-image-small .mta-img { max-height: 180px; }
.mta-img-loading {
  position: absolute; inset: 0; background: rgba(0,0,0,0.3);
  display: flex; align-items: center; justify-content: center;
  color: var(--mta-accent, #d4af37); font-size: 1.2rem;
}

/* ── Prepare timer bar ─────────────────────────────────────── */
.mta-prepare-bar {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 8px 14px;
}
html[data-theme="light"] .mta-prepare-bar { background: #fff; border-color: #e0d8d0; }
.mta-prepare-label { font-size: 0.75rem; color: var(--ytt-text-2, #a4b0be); margin-bottom: 6px; }
.mta-prepare-timer-wrap { display: flex; align-items: center; gap: 10px; }
.mta-prepare-timer-bar {
  flex: 1; height: 6px; background: rgba(255,255,255,0.08); border-radius: 3px; overflow: hidden;
}
.mta-prepare-timer-bar::after {
  content: ''; display: block; height: 100%; width: 0;
  background: var(--mta-accent, #d4af37); border-radius: 3px;
  transition: width 1s linear;
}
.mta-prepare-countdown { font-size: 1rem; font-weight: 700; color: var(--mta-accent, #d4af37); min-width: 36px; }

/* ── Tabs ──────────────────────────────────────────────────── */
.mta-tabs {
  display: flex; border-bottom: 1px solid rgba(255,255,255,0.1);
  margin-bottom: 0;
}
.mta-tab-btn {
  flex: 1; padding: 8px 4px; border: none; background: none;
  color: var(--ytt-text-2, #a4b0be); font-size: 0.8rem; cursor: pointer;
  border-bottom: 2px solid transparent; transition: all 0.15s;
  display: flex; align-items: center; justify-content: center; gap: 5px;
}
.mta-tab-btn.active { color: var(--mta-accent, #d4af37); border-bottom-color: var(--mta-accent, #d4af37); }
.mta-tab-btn:hover:not(.active) { color: var(--ytt-text-1, #f5f6fa); }
html[data-theme="light"] .mta-tabs { border-bottom-color: #e0d8d0; }
html[data-theme="light"] .mta-tab-btn { color: #888; }
html[data-theme="light"] .mta-tab-btn.active { color: #8a6800; border-bottom-color: #c9960c; }

.mta-tab-panel { padding: 12px 2px; }

/* Nháp textarea */
.mta-draft-hint {
  font-size: 0.75rem; color: var(--ytt-text-2, #a4b0be);
  background: rgba(212,175,55,0.08); border-radius: 8px;
  padding: 6px 10px; margin-bottom: 8px;
}
html[data-theme="light"] .mta-draft-hint { background: #fdf6e3; }
.mta-draft-area {
  width: 100%; min-height: 100px; padding: 10px 12px;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px; color: var(--ytt-text-1, #f5f6fa); font-size: 0.9rem;
  line-height: 1.6; resize: vertical; font-family: inherit;
}
.mta-draft-area:focus { outline: none; border-color: rgba(212,175,55,0.4); }
html[data-theme="light"] .mta-draft-area { background: #fff; border-color: #d4c4b0; color: #2c3840; }

/* Strategy tips (tab Mẹo thi) */
.mta-strategy-tips { display: flex; flex-direction: column; gap: 6px; margin-bottom: 10px; }
.mta-tip-item {
  font-size: 0.82rem; color: var(--ytt-text-1, #f5f6fa); line-height: 1.4;
  display: flex; align-items: flex-start; gap: 6px;
}
.mta-tip-item i { color: var(--mta-correct, #4caf50); margin-top: 2px; flex-shrink: 0; }
html[data-theme="light"] .mta-tip-item { color: #333; }
.mta-starter-box {
  background: rgba(212,175,55,0.1); border-radius: 8px; padding: 8px 12px;
  font-size: 0.82rem;
}
.mta-starter-label { font-weight: 700; color: var(--mta-accent, #d4af37); display: block; margin-bottom: 4px; }
.mta-starter-zh { color: var(--ytt-text-1, #f5f6fa); line-height: 1.5; }
html[data-theme="light"] .mta-starter-zh { color: #2c3840; }

/* Keyword chips (tab Từ khóa) */
.mta-keyword-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.mta-kw-chip {
  padding: 6px 10px; border-radius: 20px; font-size: 0.78rem;
  background: rgba(46,125,140,0.1); border: 1px solid rgba(46,125,140,0.25);
  color: var(--ytt-text-1, #f5f6fa); cursor: pointer; transition: background 0.15s;
  display: flex; align-items: center; gap: 4px;
}
.mta-kw-chip:hover { background: rgba(46,125,140,0.2); }
.mta-kw-chip .zh { font-weight: 700; color: #5bc8d8; }
.mta-kw-chip .py { color: var(--ytt-text-2, #a4b0be); font-size: 0.72rem; }
.mta-kw-chip .vp { color: var(--ytt-text-2, #a4b0be); font-size: 0.72rem; }
html[data-theme="light"] .mta-kw-chip { background: #e8f4f7; border-color: #b0d8e0; color: #2c3840; }

/* Tip ribbon xoay vòng */
.mta-tip-ribbon {
  font-size: 0.78rem; color: var(--ytt-text-2, #a4b0be);
  background: rgba(255,255,255,0.04); border-radius: 8px;
  padding: 7px 12px; text-align: center;
  transition: opacity 0.4s ease;
}
html[data-theme="light"] .mta-tip-ribbon { background: #f0ebe4; color: #666; }

/* Prepare actions */
.mta-prepare-actions { display: flex; gap: 10px; align-items: center; }
.mta-start-speak-btn {
  flex: 1; padding: 12px; border-radius: 10px;
  background: linear-gradient(135deg, #b85c38, #8a3e23); border: none;
  color: #fff; font-size: 0.95rem; font-weight: 700; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.mta-start-speak-btn:hover { filter: brightness(1.12); }
.mta-skip-btn {
  padding: 12px 16px; border-radius: 10px; font-size: 0.82rem;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  color: var(--ytt-text-2, #a4b0be); cursor: pointer;
}
html[data-theme="light"] .mta-skip-btn { background: #f5f0eb; border-color: #d4c4b0; color: #666; }

/* ── Flip card (nháp → hidden khi speak) ──────────────────── */
.mta-flip-container {
  perspective: 1000px; height: 80px;
  position: relative; margin-bottom: 6px;
}
.mta-flip-front, .mta-flip-back {
  position: absolute; inset: 0;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border-radius: 10px; padding: 10px 14px;
  transition: transform 0.5s ease;
  display: flex; align-items: center;
}
.mta-flip-front {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  transform: rotateY(0deg);
  overflow: hidden;
}
.mta-flip-back {
  background: rgba(212,175,55,0.1); border: 1px solid rgba(212,175,55,0.25);
  transform: rotateY(180deg);
  justify-content: center; gap: 10px; color: var(--mta-accent, #d4af37);
  font-size: 0.85rem;
}
.mta-flip-container.flipped .mta-flip-front { transform: rotateY(-180deg); }
.mta-flip-container.flipped .mta-flip-back  { transform: rotateY(0deg); }
.mta-draft-preview {
  font-size: 0.82rem; color: var(--ytt-text-2, #a4b0be);
  overflow: hidden; max-height: 60px;
  white-space: pre-wrap; word-break: break-word;
}
.mta-draft-hidden-msg { text-align: center; display: flex; align-items: center; gap: 8px; }
.mta-draft-hidden-msg i { font-size: 1rem; }
html[data-theme="light"] .mta-flip-front { background: #fff; border-color: #e0d8d0; }
html[data-theme="light"] .mta-flip-back { background: #fdf6e3; border-color: #e8d78a; }

/* ── Speak timer wrap ──────────────────────────────────────── */
.mta-speak-timer-wrap { display: flex; align-items: center; gap: 10px; }
.mta-speak-timer-track {
  flex: 1; height: 5px; background: rgba(255,255,255,0.1); border-radius: 3px; overflow: hidden;
}
.mta-speak-timer-bar {
  height: 100%; width: 0; background: var(--mta-accent, #d4af37); border-radius: 3px;
  transition: width 1s linear;
}
.mta-speak-countdown { font-size: 0.9rem; font-weight: 700; color: var(--mta-accent, #d4af37); min-width: 34px; }
.mta-speak-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mta-pause-btn {
  padding: 8px 16px; border-radius: 20px; font-size: 0.82rem; font-weight: 600;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.15);
  color: var(--ytt-text-1, #f5f6fa); cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
}
.mta-pause-btn:hover { background: rgba(255,255,255,0.12); }
html[data-theme="light"] .mta-pause-btn { background: #f0ebe4; border-color: #d4c4b0; color: #2c3840; }

/* ── Result enhancements ───────────────────────────────────── */
.mta-transcript-details {
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; padding: 8px 14px;
}
.mta-transcript-details summary {
  cursor: pointer; font-size: 0.82rem; color: var(--ytt-text-2, #a4b0be);
  user-select: none;
}
html[data-theme="light"] .mta-transcript-details { background: #f5f0eb; border-color: #e0d8d0; }
.mta-best-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 0.75rem; font-weight: 700; color: #ffd700;
  background: rgba(255,215,0,0.15); border: 1px solid rgba(255,215,0,0.3);
  border-radius: 12px; padding: 3px 10px;
}
.mta-result-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.mta-gallery-btn {
  flex: 1; padding: 10px 16px; border-radius: 22px; font-size: 0.85rem; font-weight: 700;
  background: rgba(46,125,140,0.12); border: 1px solid rgba(46,125,140,0.3);
  color: #5bc8d8; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px;
}
.mta-gallery-btn:hover { background: rgba(46,125,140,0.2); }
html[data-theme="light"] .mta-gallery-btn { background: #e8f4f7; border-color: #b0d8e0; color: #2e7d8c; }

/* ── HSKK badge row — level 1-6 ───────────────────────────── */
.mta-hsk-badge-row { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 8px; }
.mta-hsk-badge {
  padding: 5px 14px; border-radius: 20px; font-size: 0.78rem; font-weight: 700;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.15);
  color: var(--ytt-text-2, #a4b0be); cursor: pointer; transition: all 0.15s;
}
.mta-hsk-badge.active {
  background: rgba(212,175,55,0.18); border-color: rgba(212,175,55,0.5);
  color: var(--mta-accent, #d4af37);
}
html[data-theme="light"] .mta-hsk-badge { background: #f0ebe4; border-color: #d4c4b0; color: #666; }
html[data-theme="light"] .mta-hsk-badge.active { background: #fdf6e3; border-color: #c9960c; color: #8a6800; }

/* Back button shared */
.mta-back-btn {
  padding: 6px 12px; border-radius: 8px; font-size: 0.82rem;
  background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12);
  color: var(--ytt-text-1, #f5f6fa); cursor: pointer;
  display: flex; align-items: center; gap: 5px;
}
.mta-back-btn:hover { background: rgba(255,255,255,0.12); }
html[data-theme="light"] .mta-back-btn { background: #f0ebe4; border-color: #d4c4b0; color: #2c3840; }

/* ══ S66 UX Overhaul: Fixed Viewport Session ═══════════════════ */

/* ── Session shell: 100dvh no-scroll ──────────────────────── */
.mta-session-shell {
  height: 100dvh; min-height: 0;
  display: flex; flex-direction: column;
  overflow: hidden;
  background: var(--ytt-bg-0, #0f0f12);
  position: relative;
}
html[data-theme="light"] .mta-session-shell { background: #f5f0eb; }

/* ── Session header ────────────────────────────────────────── */
.mta-session-hdr {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px;
  background: rgba(0,0,0,0.35);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  flex-shrink: 0;
  backdrop-filter: blur(8px);
  z-index: 10;
}
html[data-theme="light"] .mta-session-hdr {
  background: rgba(255,255,255,0.92);
  border-bottom-color: rgba(0,0,0,0.1);
}
.mta-session-meta {
  flex: 1; display: flex; align-items: center; gap: 6px;
  overflow: hidden;
  min-width: 0;
}
.mta-session-tools { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* ── Timer badge (đồng hồ rung lắc) ───────────────────────── */
.mta-timer-badge {
  display: flex; align-items: center; gap: 5px;
  padding: 4px 10px; border-radius: 20px;
  background: rgba(212,175,55,0.18);
  border: 1.5px solid rgba(212,175,55,0.45);
  font-weight: 700; font-size: 0.9rem;
  color: var(--mta-accent, #d4af37);
  transition: background 0.3s, border-color 0.3s, color 0.3s;
  min-width: 62px; justify-content: center;
}
.mta-timer-icon { font-size: 0.78rem; }
.mta-timer-num  { letter-spacing: 0.04em; }

/* Trạng thái vàng cảnh báo (<30s) */
.mta-timer-badge.warn {
  background: rgba(251,140,0,0.22);
  border-color: rgba(251,140,0,0.6);
  color: #fb8c00;
}
/* Trạng thái đỏ nguy hiểm + shake (<10s) */
.mta-timer-badge.danger {
  background: rgba(239,83,80,0.22);
  border-color: rgba(239,83,80,0.7);
  color: #ef5350;
  animation: mta-shake 0.45s infinite;
}
@keyframes mta-shake {
  0%,100% { transform: rotate(0deg) translateX(0); }
  20%      { transform: rotate(-4deg) translateX(-2px); }
  40%      { transform: rotate(4deg)  translateX(2px); }
  60%      { transform: rotate(-3deg) translateX(-1px); }
  80%      { transform: rotate(2deg)  translateX(1px); }
}
html[data-theme="light"] .mta-timer-badge       { background: #fffbe6; border-color: #e8d78a; color: #8a6800; }
html[data-theme="light"] .mta-timer-badge.warn  { background: #fff3e0; border-color: #ffb74d; color: #e65100; }
html[data-theme="light"] .mta-timer-badge.danger{ background: #ffebee; border-color: #ef9a9a; color: #c62828; }

/* ── Lightbulb tips button ─────────────────────────────────── */
.mta-tip-btn {
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(212,175,55,0.15);
  border: 1.5px solid rgba(212,175,55,0.35);
  color: var(--mta-accent, #d4af37);
  font-size: 0.9rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.mta-tip-btn:hover { background: rgba(212,175,55,0.28); transform: scale(1.08); }
html[data-theme="light"] .mta-tip-btn { background: #fdf6e3; border-color: #e8d78a; color: #8a6800; }

/* ── Tips popup (absolute over session) ───────────────────── */
.mta-tips-popup {
  position: absolute; top: 52px; right: 8px;
  width: min(340px, calc(100% - 16px));
  z-index: 200;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,0.5));
  animation: mta-popup-in 0.2s ease;
}
@keyframes mta-popup-in {
  from { opacity: 0; transform: translateY(-8px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}
.mta-tips-card {
  background: #1e1b2e;
  border: 1px solid rgba(212,175,55,0.35);
  border-radius: 14px; padding: 14px 16px;
}
html[data-theme="light"] .mta-tips-card {
  background: #fff; border-color: #e8d78a;
}
.mta-tips-card-hdr {
  display: flex; align-items: center; gap: 7px;
  font-size: 0.88rem; font-weight: 700;
  color: var(--mta-accent, #d4af37);
  margin-bottom: 10px;
}
.mta-tips-card-hdr i { font-size: 0.85rem; }
.mta-tips-close {
  margin-left: auto; width: 22px; height: 22px;
  border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,0.1);
  color: var(--ytt-text-2, #a4b0be); font-size: 0.75rem;
  display: flex; align-items: center; justify-content: center;
}
.mta-tips-close:hover { background: rgba(255,255,255,0.18); }
html[data-theme="light"] .mta-tips-close { background: #f0ebe4; color: #555; }

/* ── Prepare phase layout ──────────────────────────────────── */
.mta-step-prepare {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column;
  overflow: hidden;
}

/* Image area: chiều cao CỐ ĐỊNH ~40% viewport — không flex:1 */
.mta-img-area {
  flex: 0 0 42dvh;        /* fixed 42% viewport height */
  max-height: 42dvh;
  position: relative; overflow: hidden;
  background: #000;
}
.mta-img-area--small { flex: 0 0 130px; max-height: 130px; }

.mta-img-cover {
  width: 100%; height: 100%;
  object-fit: contain;   /* hiện đủ ảnh, không cắt */
  display: block;
  background: #0a0a10;   /* letterbox background */
}

/* ── Bottom panel: flex:1 — chiếm phần còn lại sau ảnh ───── */
.mta-bottom-panel {
  flex: 1; min-height: 0;
  background: var(--ytt-bg-1, #131318);
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column;
  overflow: hidden;
}
html[data-theme="light"] .mta-bottom-panel {
  background: #fff; border-top-color: rgba(0,0,0,0.08);
}

/* Tabs trong bottom panel */
.mta-bottom-panel .mta-tabs {
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding: 0 12px;
}
html[data-theme="light"] .mta-bottom-panel .mta-tabs {
  border-bottom-color: rgba(0,0,0,0.08);
}

/* Tab scroller: flex:1 → lấp không gian giữa tabs và action row */
.mta-tab-scroller {
  flex: 1; min-height: 0;
  overflow-y: auto;
  padding: 8px 12px 4px;
}
.mta-tab-scroller .mta-draft-area {
  min-height: 0; height: 100%;
  max-height: none;
  resize: none; /* trong flex container không cần resize */
}
.mta-tab-scroller .mta-draft-hint {
  font-size: 0.72rem; padding: 4px 8px; margin-bottom: 6px;
}

/* ── Action row: center-align, buttons tự nhiên ────────────── */
.mta-action-row {
  display: flex; gap: 10px; align-items: center;
  justify-content: center;          /* center thay vì stretch */
  padding: 10px 16px 14px;
  flex-shrink: 0;
}

/* Button system — width tự nhiên theo content */
.mta-btn {
  padding: 11px 24px; border-radius: 12px;
  font-size: 0.88rem; font-weight: 700;
  cursor: pointer; border: none;
  display: inline-flex; align-items: center; gap: 7px;
  transition: filter 0.15s, transform 0.1s;
  white-space: nowrap;
}
.mta-btn:hover  { filter: brightness(1.1); }
.mta-btn:active { transform: scale(0.97); }

.mta-btn-primary {
  /* KHÔNG flex:1 — tự nhiên theo content */
  min-width: 180px;
  background: linear-gradient(135deg, #c0533a, #8a3e23);
  color: #fff;
  box-shadow: 0 3px 12px rgba(192,83,58,0.35);
}
.mta-btn-success {
  min-width: 180px;
  background: linear-gradient(135deg, #2e7d52, #1b5e38);
  color: #fff;
  box-shadow: 0 3px 12px rgba(46,125,82,0.35);
}
.mta-btn-ghost {
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.15);
  color: var(--ytt-text-2, #a4b0be);
  min-width: 80px;
}
html[data-theme="light"] .mta-btn-ghost {
  background: #f0ebe4; border-color: #d4c4b0;
  color: #2c3840; font-weight: 700;
}

/* ── Speak phase layout ────────────────────────────────────── */
.mta-step-speak {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column;
  overflow: hidden;
}

/* ── Light mode: text đen đậm toàn bộ ─────────────────────── */
html[data-theme="light"] .mta-session-shell,
html[data-theme="light"] .mta-session-shell * {
  color: #1a1a1a;
}
/* Override exceptions (buttons dùng màu riêng) */
html[data-theme="light"] .mta-btn-primary,
html[data-theme="light"] .mta-btn-success { color: #fff !important; }
html[data-theme="light"] .mta-timer-badge       { color: #8a6800 !important; }
html[data-theme="light"] .mta-timer-badge.warn  { color: #e65100 !important; }
html[data-theme="light"] .mta-timer-badge.danger{ color: #c62828 !important; }
html[data-theme="light"] .mta-phase-dot         { background: rgba(0,0,0,0.15); }
html[data-theme="light"] .mta-phase-dot.active  { background: var(--mta-accent, #d4af37); }
html[data-theme="light"] .mta-tab-btn           { color: #555; font-weight: 600; }
html[data-theme="light"] .mta-tab-btn.active    { color: #8a6800; font-weight: 700; }
html[data-theme="light"] .mta-draft-area {
  background: #f9f5f0; border-color: #d4c4b0;
  color: #1a1a1a; font-weight: 500;
}
html[data-theme="light"] .mta-keyword-chips .mta-kw-chip { color: #1a1a1a; font-weight: 600; }
html[data-theme="light"] .mta-kw-chip .zh { color: #0d6072; }
html[data-theme="light"] .mta-speak-panel { background: #f0ebe4; border-color: #d4c4b0; }
html[data-theme="light"] .mta-interim-text { color: #1a1a1a; background: #f9f5f0; }
html[data-theme="light"] .mta-flip-front   { background: #f9f5f0; border-color: #d4c4b0; }
html[data-theme="light"] .mta-draft-preview { color: #1a1a1a; font-weight: 600; }
html[data-theme="light"] .mta-strategy-tips .mta-tip-item { color: #1a1a1a; font-weight: 600; }
html[data-theme="light"] .mta-starter-box { background: #fdf6e3; color: #1a1a1a; }
html[data-theme="light"] .mta-starter-zh  { color: #1a1a1a; font-weight: 700; }
