.cinema-practice {
  --cinema-bg: #090b12;
  --cinema-surface: #141720;
  --cinema-surface-2: #1c202b;
  --cinema-line: #323541;
  --cinema-text: #f5f4f9;
  --cinema-muted: #a0a2b0;
  --cinema-violet: #b99aff;
  --cinema-coral: #ff7b8e;
  --cinema-mint: #76d6bf;
  min-height: 100dvh;
  height: 100dvh;
  overflow: hidden;
  color: var(--cinema-text);
  background: radial-gradient(ellipse 42% 32% at 50% 48%, #171523 0%, transparent 100%), var(--ref-bg, var(--cinema-bg));
  font-family: Inter, "Segoe UI", "Microsoft YaHei", sans-serif;
}

.cinema-practice .ref-game-top {
  flex: none;
  min-height: 62px;
  height: auto;
  padding: 9px clamp(18px, 3vw, 42px);
  border-bottom: 1px solid var(--cinema-line);
  background: #0c0e16;
  color: var(--cinema-text);
}
.cinema-practice .ref-game-top > div,
.cinema-practice .ref-game-top nav { gap: 9px; }
.cinema-practice .studio-brand { color: var(--cinema-text); font: 750 16px/1.2 "Segoe UI", "Microsoft YaHei", sans-serif; white-space: nowrap; }
.cinema-practice .studio-brand span { color: var(--cinema-violet); }
.cinema-divider { height: 18px; width: 1px; background: var(--cinema-line); margin: 0 5px; }
.cinema-crumb { color: var(--cinema-muted); font-size: 12px; white-space: nowrap; }
.cinema-crumb span { padding: 0 5px; color: #676878; }
.cinema-practice .ref-back,
.cinema-practice .ref-game-top nav button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 11px;
  border: 1px solid var(--cinema-line);
  border-radius: 10px;
  background: #151821;
  color: #d9d8e4;
  font-size: 11px;
  line-height: 1.1;
  white-space: nowrap;
  transition: border-color .18s ease, background-color .18s ease, transform .18s ease;
}
.cinema-practice .ref-game-top button:hover { border-color: #846caf; background: #252030; color: var(--cinema-text); transform: translateY(-1px); }
.cinema-practice .ref-game-top nav svg { color: var(--cinema-violet); }
.cinema-practice .ref-mode-pop { top: calc(100% + 8px); width: 168px; background: #191b25; border-color: #494454; }
.cinema-practice .ref-mode-pop button { color: var(--cinema-text); }
.cinema-more { display: inline-flex; gap: 8px; }

.cinema-practice .ref-game-sub {
  flex: none;
  min-height: 49px;
  height: auto;
  padding: 8px clamp(18px, 3vw, 42px);
  gap: 12px;
  border-bottom: 1px solid #22242e;
  background: #0c0e16;
}
.cinema-practice .ref-timer { display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px; background: #191b25; border-color: #393947; color: var(--cinema-text); }
.cinema-practice .ref-timer svg { color: var(--cinema-violet); }
.cinema-practice .ref-main-modes { background: #191b25; border-color: #393947; }
.cinema-practice .ref-main-modes button { color: #aeb0bf; }
.cinema-practice .ref-main-modes button.active { background: #38304e; color: #f4eaff; box-shadow: inset 0 0 0 1px #8d6cce; }
.cinema-image-toggle { display: inline-flex; align-items: center; gap: 8px; border: 1px solid #393947; border-radius: 10px; background: #191b25; color: #b8b7c5; padding: 5px 10px; font-size: 11px; }
.cinema-toggle-track { width: 30px; height: 17px; padding: 2px; border-radius: 20px; background: #515260; transition: background-color .2s ease; }
.cinema-toggle-track::after { content: ""; display: block; width: 13px; height: 13px; border-radius: 50%; background: white; box-shadow: 0 1px 3px #0006; transition: transform .2s ease; }
.cinema-image-toggle.active .cinema-toggle-track { background: #8262d4; }
.cinema-image-toggle.active .cinema-toggle-track::after { transform: translateX(13px); }
.cinema-practice .ref-course-name { color: #8c8d9c; }

.cinema-practice .ref-game-center {
  flex: 1 1 auto;
  min-height: 0;
  display: block;
  overflow: auto;
  padding: 15px 18px 16px;
  scrollbar-color: #555363 transparent;
}
.cinema-practice .ref-question {
  width: min(760px, 100%);
  min-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 13px;
  margin: 0 auto;
  text-align: center;
}
.cinema-practice .ref-question.cinema-enter { animation: cinema-enter .36s cubic-bezier(.2,.7,.2,1) both; }
.cinema-practice .ref-question.is-reviewing { gap: 9px; }
.cinema-practice .ref-question.is-reviewing .cinema-prompt { gap: 5px; }
.cinema-practice .ref-question.is-reviewing .cinema-prompt h1 { font-size: 21px; }
.cinema-practice .ref-question.is-reviewing .cinema-prompt .ref-voice-actions { display: none; }
.cinema-prompt { display: flex; flex-direction: column; align-items: center; gap: 12px; width: 100%; }
.cinema-kicker { display: inline-flex; align-items: center; gap: 8px; color: var(--cinema-violet); font-size: 11px; font-weight: 700; letter-spacing: .07em; }
.cinema-kicker i { display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: #777387; }
.cinema-practice .ref-question h1 { margin: 0; color: var(--cinema-text); font-size: clamp(23px, 2.5vw, 35px); font-weight: 730; line-height: 1.4; text-wrap: balance; }
.cinema-practice .ref-voice-actions { gap: 8px; justify-content: center; flex-wrap: wrap; }
.cinema-practice .ref-voice-actions button { padding: 7px 12px; border: 1px solid #3d3d4b; border-radius: 9px; background: #1a1d28; color: #c6c6d1; font-size: 11px; transition: border-color .18s ease, background-color .18s ease, transform .18s ease; }
.cinema-practice .ref-voice-actions button:first-child { background: #322842; border-color: #694e8b; color: #eadcff; }
.cinema-practice .ref-voice-actions button:hover { border-color: var(--cinema-violet); transform: translateY(-1px); }
.cinema-scene { position: relative; width: min(340px, 100%); aspect-ratio: 16/9; margin: 0; overflow: hidden; border: 1px solid #51485d; border-radius: 16px; box-shadow: 0 18px 55px #0008, 0 0 0 4px #ffffff07; background: #2d2735; }
.cinema-scene img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cinema-scene figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 14px 10px; background: linear-gradient(transparent, #0c0c15c9); color: #fff; font-size: 11px; font-weight: 650; text-align: left; }
.cinema-practice .ref-chunks { justify-content: center; flex-wrap: wrap; margin: 0; padding: 0; }
.cinema-practice .ref-chunks span { padding: 6px 10px; background: #1a1d28; border: 1px solid #353544; border-radius: 7px; color: #a3a4b1; }
.cinema-practice .ref-chunks .active { color: #ebdcff; background: #312741; border-color: #825fad; }
.cinema-practice .ref-chunks .done { color: var(--cinema-mint); }

.cinema-answer { width: 100%; max-width: 730px; padding: 17px 20px 18px; border: 1px solid #353440; border-radius: 16px; background: linear-gradient(180deg, #1b1d27 0%, #171922 100%); box-shadow: 0 18px 50px #0004; text-align: left; }
.cinema-answer-top { display: flex; align-items: center; justify-content: space-between; color: #e7e4ee; font-size: 12px; font-weight: 700; }
.cinema-answer-top small { color: #9494a3; font-size: 11px; font-weight: 500; }
.cinema-word-instruction { margin: 12px 0 3px; color: #9b98ac; font-size: 11px; text-align: center; }
.cinema-practice .ref-word-line { justify-content: center; gap: 8px; margin: 10px 0 8px; }
.cinema-practice .ref-word { flex: 0 1 auto; width: max(65px, var(--word-width, 5ch)); min-width: 65px; max-width: 100%; min-height: 66px; padding: 7px 9px; border: 0; border-bottom: 2px solid #6e6c7e; border-radius: 5px 5px 0 0; background: #ffffff05; color: var(--cinema-text); font-size: 18px; overflow-wrap: anywhere; transition: border-color .16s ease, background-color .16s ease, transform .16s ease; }
.cinema-practice .ref-word-clue { width: 100%; min-height: 17px; padding: 0; border: 0; background: none; color: #a3a2b0; font-size: 11px; line-height: 1.2; cursor: help; }
.cinema-practice .ref-word-input { width: 100%; min-width: 0; height: 27px; padding: 0; border: 0; outline: 0; background: transparent; color: var(--ref-answer, #fff); font: 650 18px/1.3 Inter, "Segoe UI", sans-serif; text-align: center; box-shadow: none; }
.cinema-practice .ref-word-input::placeholder { color: #777682; }
.cinema-practice .ref-word:focus-within { background: #30263e; border-color: #bd94f8; box-shadow: 0 6px 16px #0003; }
.cinema-practice .ref-word.good { background: #24463b62; border-color: var(--cinema-mint); }
.cinema-practice .ref-word.bad { background: #6e273442; border-color: var(--cinema-coral); }
.cinema-practice .ref-word:hover { transform: translateY(-2px); }
.cinema-practice .studio-input-label { margin: 0 0 7px; color: #9b9ba9; font-size: 11px; }
.cinema-practice .ref-answer-input { display: block; width: 100%; min-height: 62px; height: auto; max-height: 200px; margin: 0; padding: 12px 13px; border: 1px solid #474450; border-radius: 10px; outline: none; background: #10121b; color: var(--cinema-text); text-align: left; resize: vertical; line-height: 1.45; font-size: var(--ref-font-size, 20px) !important; box-shadow: none; }
.cinema-practice .ref-answer-input:focus { border-color: #a480e4; box-shadow: 0 0 0 3px #9d72d22e; }
.cinema-practice .ref-answer-input::placeholder { color: #727381; font-size: 14px; }
.cinema-answer-actions { display: flex; align-items: center; gap: 8px; margin-top: 11px; }
.cinema-answer-actions button { display: inline-flex; align-items: center; justify-content: center; gap: 5px; padding: 8px 11px; border: 1px solid #40404d; border-radius: 8px; background: #242632; color: #c0bfcc; font-size: 11px; transition: border-color .18s ease, background-color .18s ease, transform .18s ease; }
.cinema-answer-actions button:hover { border-color: #9f7ed9; background: #302a40; transform: translateY(-1px); }
.cinema-answer-actions .cinema-submit { margin-left: auto; border-color: #9975d8; background: #8d67d0; color: white; font-weight: 750; }
.cinema-answer-actions .cinema-submit:hover { background: #a17be1; }
.cinema-practice .ref-word-tip,.cinema-practice .ref-hint,.cinema-practice .ref-result,.cinema-practice .ref-feedback { max-width: none; margin: 12px 0 0; border-radius: 8px; background: #262131; border-color: #5f4a80; color: #e8ddf6; }
.cinema-practice .ref-feedback { justify-content: flex-start; animation: cinema-feedback .32s ease-out both; }
.cinema-practice .ref-feedback.correct,.cinema-practice .ref-feedback.correct-part { border-color: #468c79; background: #1b342e; }
.cinema-practice .ref-feedback.wrong { border-color: #a45765; background: #3a232c; }
.cinema-review { width: 100%; max-width: 760px; padding: 18px 22px; border: 1px solid #44514c; border-radius: 18px; background: linear-gradient(145deg, #1c292a, #171e28 58%, #1b1d29); box-shadow: 0 22px 54px #0005; text-align: left; animation: cinema-feedback .34s ease-out both; }
.cinema-review-heading { display: flex; align-items: center; gap: 12px; }
.cinema-review-check { display: grid; place-items: center; width: 38px; height: 38px; flex: none; border-radius: 12px; background: #3dc39b28; color: #73e5bd; font-size: 23px; font-weight: 800; }
.cinema-review-heading div { flex: 1; min-width: 0; }
.cinema-review-heading small { display: block; margin-bottom: 3px; color: #9bdbcb; font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.cinema-review-heading h2 { margin: 0; color: #f6f9f7; font-size: clamp(20px, 2vw, 26px); line-height: 1.25; }
.cinema-review-heading button,.cinema-review-next { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid #5b8a7e; border-radius: 9px; background: #25443e; color: #d8fff1; font-size: 12px; font-weight: 700; cursor: pointer; }
.cinema-review-heading button { padding: 9px 11px; }
.cinema-grammar-note { margin: 12px 0 14px; padding: 10px 13px; border-left: 3px solid #68d3ad; border-radius: 0 8px 8px 0; background: #ffffff0a; color: #c9d6d4; font-size: 13px; line-height: 1.5; }
.cinema-review-words { display: flex; flex-wrap: wrap; justify-content: center; gap: 9px; }
.cinema-review-word { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; min-width: 91px; max-width: 100%; padding: 9px 13px 8px; border: 1px solid #474d59; border-bottom: 3px solid #8cc8be; border-radius: 12px; background: #232832; color: #fff; font: inherit; cursor: pointer; transition: transform .18s ease, border-color .18s ease, background .18s ease; }
.cinema-review-word:hover { transform: translateY(-3px); border-color: #83ddc4; background: #2b3941; }
.cinema-review-word:focus-visible { outline: 2px solid #9fe8d0; outline-offset: 3px; }
.cinema-ipa { min-height: 18px; color: #b5bdc8; font-size: 12px; white-space: nowrap; }
.cinema-word-pos { padding: 3px 8px; border-radius: 20px; background: #906bc84a; color: #e3ccff; font-size: 11px; font-weight: 750; }
.cinema-review-word:nth-child(3n + 2) .cinema-word-pos { background: #d28a3940; color: #ffd6a4; }
.cinema-review-word:nth-child(3n) .cinema-word-pos { background: #368da840; color: #aceeff; }
.cinema-review-word strong { max-width: 100%; overflow-wrap: anywhere; color: #fff; font-size: clamp(17px, 2vw, 25px); line-height: 1.2; }
.cinema-word-number { color: #929ba5; font-size: 10px; }
.cinema-review-translation { margin: 14px 0 5px; color: #f5f6f6; font-size: 20px; font-weight: 700; text-align: center; }
.cinema-review-source { display: block; color: #9da9aa; font-size: 10px; text-align: center; }
.cinema-review-next { display: flex; margin: 12px auto 0; padding: 10px 17px; }
.cinema-practice .puzzle-area { max-width: none; margin: 20px 0; }

.cinema-bottom { flex: none; padding: 0 clamp(18px, 3vw, 42px) 12px; background: linear-gradient(#0b0d15ed, #0b0d15); border-top: 1px solid #272832; }
.cinema-progress { width: min(920px, 100%); height: 5px; margin: 12px auto 9px; overflow: hidden; border-radius: 5px; background: #41404b; }
.cinema-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #aa79ee, #df91d3); }
.cinema-progress-enter span { animation: cinema-fill .6s cubic-bezier(.2,.7,.2,1) both; }
.cinema-practice .ref-hotkeys { position: static; display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; max-width: 100%; margin: 0; padding: 0; border: 0; background: transparent; }
.cinema-practice .ref-hotkeys button { padding: 7px 10px; border: 1px solid #373945; border-radius: 8px; background: #1a1d27; color: #d1d0da; font-size: 10px; }
.cinema-practice .ref-hotkeys button:first-child,.cinema-practice .ref-hotkeys button:last-child { color: #efe0ff; border-color: #665183; }
.cinema-practice .ref-hotkeys button:hover { border-color: #a783df; color: #fff; background: #2b2540; }

@keyframes cinema-enter { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@keyframes cinema-feedback { from { opacity: 0; transform: translateY(5px) scale(.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes cinema-fill { from { transform: scaleX(0); transform-origin: left; } to { transform: scaleX(1); transform-origin: left; } }

@media (max-width: 1120px) {
  .cinema-crumb { display: none; }
  .cinema-practice .ref-game-top nav { overflow-x: auto; flex-wrap: nowrap; max-width: 100%; }
}
@media (max-width: 700px) {
  .cinema-practice { height: 100dvh; }
  .cinema-practice .ref-game-top { flex-wrap: wrap; padding: 9px 13px; }
  .cinema-practice .ref-game-top nav { width: 100%; overflow-x: auto; flex-wrap: nowrap; }
  .cinema-practice .ref-game-top nav button { font-size: 11px; }
  .cinema-practice .ref-game-sub { flex-wrap: wrap; gap: 7px; padding: 7px 13px; }
  .cinema-practice .ref-course-name { display: none; }
  .cinema-practice .ref-game-center { padding: 16px 12px 22px; }
  .cinema-practice .ref-question { gap: 13px; justify-content: flex-start; }
  .cinema-practice .ref-question h1 { font-size: 23px; }
  .cinema-scene { width: min(370px, 100%); }
  .cinema-answer { padding: 14px 12px; }
  .cinema-review { padding: 16px 12px; }
  .cinema-review-heading button { padding: 8px; font-size: 11px; }
  .cinema-review-words { gap: 6px; }
  .cinema-review-word { min-width: 79px; padding: 9px 7px 8px; }
  .cinema-ipa { font-size: 10px; }
  .cinema-practice .ref-word { min-width: 52px; min-height: 54px; }
  .cinema-practice .ref-word-input { font-size: 16px; }
  .cinema-bottom { padding: 0 10px 8px; }
  .cinema-practice .ref-hotkeys { flex-wrap: nowrap; overflow-x: auto; justify-content: flex-start; }
  .cinema-practice .ref-hotkeys button { flex: none; }
}
@media (prefers-reduced-motion: reduce) {
  .cinema-practice *, .cinema-practice *::before, .cinema-practice *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
