:root {
  --yw-opening-ink: #f2f0e6;
  --yw-opening-muted: #b9c2ba;
  --yw-opening-night: #07110e;
  --yw-opening-panel: rgba(7, 17, 14, 0.88);
  --yw-opening-brass: #e2bd62;
  --yw-opening-coral: #ed6958;
  --yw-opening-cyan: #5dd2d5;
}

body.yw-opening-active {
  overflow: hidden;
}

body[data-experience="yw01-v2"] #briefing-overlay {
  display: none !important;
}

.yw-opening[hidden],
.yw-radio[hidden],
.yw-deduction[hidden],
.yw-chapter-reveal[hidden],
.yw-opening-secondary[hidden] {
  display: none !important;
}

.yw-deduction {
  position: fixed;
  z-index: 10040;
  inset: 0;
  padding: 24px;
  display: grid;
  place-items: center;
  color: var(--yw-opening-ink);
  background: rgba(2, 7, 5, 0.74);
  backdrop-filter: blur(10px);
}

.yw-deduction__panel {
  width: min(620px, 100%);
  padding: clamp(24px, 5vw, 42px);
  border: 1px solid rgba(226, 189, 98, 0.72);
  border-radius: 4px;
  display: grid;
  gap: 14px;
  background:
    linear-gradient(135deg, rgba(226, 189, 98, 0.08), transparent 36%),
    #07130f;
  box-shadow: 0 28px 76px rgba(0, 0, 0, 0.7), inset 4px 0 0 rgba(226, 189, 98, 0.72);
}

.yw-deduction__kicker,
.yw-deduction__summary,
.yw-deduction__feedback { margin: 0; }
.yw-deduction__kicker { color: var(--yw-opening-brass); font-size: 9px; font-weight: 850; }
.yw-deduction__panel h2 { margin: 0; font-family: "STSong", "Songti SC", serif; font-size: 34px; }

@media (max-width: 620px) {
  .yw-deduction__panel h2 { font-size: 26px; }
}
.yw-deduction__summary { color: rgba(242, 240, 230, 0.66); font-size: 11px; }
.yw-deduction__options { display: grid; gap: 8px; margin-top: 8px; }

.yw-deduction__options button {
  min-height: 58px;
  padding: 10px 14px;
  border: 1px solid rgba(185, 194, 186, 0.28);
  border-radius: 3px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  color: #f4f0df;
  background: rgba(16, 37, 29, 0.76);
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.yw-deduction__options button:hover,
.yw-deduction__options button:focus-visible { border-color: var(--yw-opening-brass); background: #163d2d; }
.yw-deduction__options button > span { width: 28px; height: 28px; border: 1px solid rgba(226, 189, 98, 0.5); display: grid; place-items: center; color: var(--yw-opening-brass); font-size: 10px; }
.yw-deduction__options button strong { font-size: 12px; font-weight: 760; line-height: 1.5; }
.yw-deduction__options button.is-wrong { border-color: rgba(221, 105, 88, 0.78); background: rgba(92, 31, 25, 0.54); }
.yw-deduction__options button.is-correct { border-color: rgba(100, 191, 126, 0.9); background: rgba(25, 78, 46, 0.7); }
.yw-deduction__feedback { min-height: 48px; padding: 10px 12px; border-left: 2px solid rgba(221, 105, 88, 0.72); color: #f3b3aa; background: rgba(0, 0, 0, 0.2); font-size: 11px; line-height: 1.6; }
.yw-deduction__feedback:empty { visibility: hidden; }
.yw-deduction__feedback.is-correct { border-left-color: #65be80; color: #c9f4d4; }
.yw-deduction__confirm { min-height: 46px; padding: 0 18px; border: 1px solid #edce76; border-radius: 3px; justify-self: end; color: #13251d; background: #dfbd61; font: inherit; font-size: 11px; font-weight: 850; cursor: pointer; }

.yw-opening {
  position: fixed;
  z-index: 10000;
  inset: 0;
  min-width: 320px;
  min-height: 100dvh;
  overflow: hidden;
  color: var(--yw-opening-ink);
  background: var(--yw-opening-night);
  clip-path: inset(0 0 0 0);
  transition: clip-path 720ms cubic-bezier(0.7, 0, 0.3, 1), opacity 240ms ease;
  isolation: isolate;
}

.yw-opening.is-departing {
  clip-path: inset(49.8% 0 49.8% 0);
}

.yw-opening-scenes,
.yw-opening-shade,
.yw-opening-grain {
  position: absolute;
  inset: 0;
}

.yw-opening-scenes {
  overflow: hidden;
  background: #030806;
}

.yw-opening-scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  opacity: 0;
  filter: saturate(0.92) contrast(1.04) brightness(0.82);
  transform: scale(1.015);
  transition: opacity 900ms ease, transform 9s ease-out, filter 800ms ease, object-position 900ms ease;
}

.yw-opening-scene.is-active {
  opacity: 1;
}

.yw-opening[data-mode="intro"] .yw-opening-scene {
  filter: saturate(0.91) contrast(1.05) brightness(0.74);
  transform: scale(1.035);
}

.yw-opening-shade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(4, 10, 8, 0.92) 0%, rgba(4, 10, 8, 0.62) 31%, rgba(4, 10, 8, 0.09) 67%, rgba(4, 10, 8, 0.34) 100%),
    linear-gradient(180deg, rgba(3, 8, 6, 0.5) 0%, transparent 28%, transparent 60%, rgba(3, 8, 6, 0.82) 100%);
}

.yw-opening[data-mode="intro"] .yw-opening-shade {
  background:
    linear-gradient(180deg, rgba(3, 8, 6, 0.52) 0%, rgba(3, 8, 6, 0.05) 31%, rgba(3, 8, 6, 0.08) 56%, rgba(3, 8, 6, 0.9) 100%),
    linear-gradient(90deg, rgba(3, 8, 6, 0.22), transparent 48%, rgba(3, 8, 6, 0.12));
}

.yw-opening-grain {
  z-index: 2;
  pointer-events: none;
  opacity: 0.22;
  background-image:
    repeating-linear-gradient(0deg, transparent 0 3px, rgba(255, 255, 255, 0.025) 4px),
    repeating-linear-gradient(90deg, transparent 0 37px, rgba(226, 189, 98, 0.028) 38px 39px);
  mix-blend-mode: soft-light;
}

.yw-opening-frame {
  position: relative;
  z-index: 3;
  width: min(100% - 72px, 1400px);
  height: 100dvh;
  min-height: 540px;
  margin: 0 auto;
  display: grid;
  grid-template-rows: auto 1fr auto;
  padding: 30px 0 34px;
  transition: opacity 260ms ease, visibility 0s linear 0s;
}

.yw-opening[data-mode="intro"] .yw-opening-frame {
  opacity: 0;
  visibility: hidden;
  transition: opacity 220ms ease, visibility 0s linear 220ms;
}

.yw-opening-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.yw-opening-institution {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: rgba(242, 240, 230, 0.76);
  font-size: 11px;
  font-weight: 750;
  line-height: 1.25;
  text-transform: uppercase;
}

.yw-opening-institution svg {
  width: 30px;
  height: 30px;
  padding: 6px;
  color: var(--yw-opening-brass);
  border: 1px solid rgba(226, 189, 98, 0.68);
  background: rgba(7, 17, 14, 0.52);
}

.yw-opening-institution small {
  display: block;
  margin-top: 2px;
  color: rgba(185, 194, 186, 0.62);
  font-size: 8px;
  font-weight: 650;
}

.yw-opening-audio,
.yw-opening-autoplay,
.yw-opening-skip {
  min-height: 42px;
  border: 1px solid rgba(242, 240, 230, 0.28);
  border-radius: 3px;
  color: var(--yw-opening-ink);
  background: rgba(7, 17, 14, 0.58);
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.yw-opening-audio {
  width: 42px;
  display: grid;
  place-items: center;
}

.yw-opening-audio:hover,
.yw-opening-autoplay:hover,
.yw-opening-skip:hover {
  border-color: var(--yw-opening-brass);
  background: rgba(21, 39, 32, 0.84);
}

.yw-opening-audio svg {
  width: 18px;
  height: 18px;
}

.yw-opening-audio .audio-off-icon {
  display: none;
}

.yw-opening-audio[aria-pressed="false"] .audio-on-icon {
  display: none;
}

.yw-opening-audio[aria-pressed="false"] .audio-off-icon {
  display: block;
}

.yw-opening-scene-description {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.yw-opening-title {
  align-self: center;
  width: min(820px, 64vw);
  padding-bottom: 3vh;
  transition: opacity 260ms ease, transform 520ms ease;
}

.yw-opening[data-mode="intro"] .yw-opening-title {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-24px);
}

.yw-opening-file {
  display: flex;
  align-items: center;
  gap: 13px;
  margin: 0 0 16px;
  color: var(--yw-opening-brass);
  font-size: 13px;
  font-weight: 800;
}

.yw-opening-file::before {
  content: "";
  width: 36px;
  height: 2px;
  background: var(--yw-opening-coral);
}

.yw-opening-title h1 {
  margin: 0;
  color: #f5f1e3;
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 112px;
  font-weight: 850;
  line-height: 0.94;
  text-shadow: 0 6px 28px rgba(0, 0, 0, 0.58);
}

.yw-opening-title h1 span {
  display: block;
  color: var(--yw-opening-brass);
}

.yw-opening-tagline {
  max-width: 600px;
  margin: 28px 0 0;
  color: rgba(242, 240, 230, 0.84);
  font-size: 20px;
  line-height: 1.7;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.66);
}

.yw-opening-meta {
  width: min(100%, 760px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 30px 0 0;
  padding: 12px 0;
  border-top: 1px solid rgba(226, 189, 98, 0.38);
  border-bottom: 1px solid rgba(226, 189, 98, 0.18);
}

.yw-hub-entry {
  min-width: 0;
  min-height: 72px;
  padding: 10px 12px;
  border: 1px solid rgba(185, 194, 186, 0.25);
  border-radius: 3px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  color: var(--yw-opening-ink);
  background: rgba(7, 17, 14, 0.48);
  text-align: left;
  cursor: pointer;
  backdrop-filter: blur(8px);
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.yw-hub-entry > span {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.yw-hub-entry > svg {
  width: 34px;
  height: 34px;
  padding: 7px;
  border: 1px solid rgba(226, 189, 98, 0.48);
  color: var(--yw-opening-brass);
}

.yw-hub-entry small {
  color: rgba(185, 194, 186, 0.62);
  font-size: 8px;
  font-weight: 750;
}

.yw-hub-entry strong {
  color: var(--yw-opening-ink);
  font-size: 14px;
  font-weight: 800;
}

.yw-hub-entry em {
  overflow: hidden;
  color: rgba(226, 189, 98, 0.78);
  font-size: 9px;
  font-style: normal;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.yw-hub-entry:hover,
.yw-hub-entry:focus-visible {
  border-color: rgba(226, 189, 98, 0.78);
  background: rgba(28, 53, 43, 0.82);
  transform: translateY(-2px);
}

.yw-hub-entry:focus-visible {
  outline: 2px solid var(--yw-opening-cyan);
  outline-offset: 2px;
}

.yw-opening-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
}

.yw-opening-primary,
.yw-opening-secondary {
  min-height: 58px;
  padding: 0 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 3px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
}

.yw-opening-primary {
  position: relative;
  isolation: isolate;
  min-width: 248px;
  min-height: 66px;
  padding: 8px 30px 8px 10px;
  justify-content: flex-start;
  gap: 14px;
  overflow: hidden;
  border: 0;
  border-radius: 2px;
  color: #fff8dc;
  background:
    linear-gradient(90deg, rgba(226, 189, 98, 0.1), transparent 34%),
    #091712;
  box-shadow:
    0 0 0 1px rgba(238, 201, 111, 0.88),
    0 0 0 4px rgba(5, 14, 10, 0.9),
    0 0 0 5px rgba(226, 189, 98, 0.22),
    0 15px 34px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 247, 218, 0.1);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 0 100%);
  transition: color 160ms ease, background-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.yw-opening-primary::before,
.yw-splash__start::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 4px;
  border: 1px solid rgba(226, 189, 98, 0.24);
  pointer-events: none;
}

.yw-opening-primary::after,
.yw-splash__start::after {
  content: "";
  position: absolute;
  right: 13px;
  top: 15px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--yw-opening-cyan);
  box-shadow:
    0 13px 0 rgba(226, 189, 98, 0.72),
    0 26px 0 rgba(226, 189, 98, 0.28),
    0 0 8px rgba(93, 210, 213, 0.5);
}

.yw-opening-primary:hover {
  color: #fffdf0;
  background-color: #12271e;
  box-shadow:
    0 0 0 1px #f1cf7b,
    0 0 0 4px rgba(5, 14, 10, 0.92),
    0 0 0 5px rgba(226, 189, 98, 0.34),
    0 17px 38px rgba(0, 0, 0, 0.46),
    inset 0 1px 0 rgba(255, 247, 218, 0.15);
  transform: translateY(-1px);
}

.yw-opening-primary:active {
  transform: translateY(1px);
  box-shadow:
    0 0 0 1px rgba(238, 201, 111, 0.86),
    0 0 0 3px rgba(5, 14, 10, 0.9),
    0 0 0 4px rgba(226, 189, 98, 0.2),
    0 8px 20px rgba(0, 0, 0, 0.4);
}

.yw-opening-primary:focus-visible {
  outline: 3px solid rgba(93, 210, 213, 0.92);
  outline-offset: 6px;
}

.yw-opening-secondary {
  border: 1px solid rgba(242, 240, 230, 0.34);
  color: rgba(242, 240, 230, 0.9);
  background: rgba(7, 17, 14, 0.48);
}

.yw-opening-secondary:hover {
  border-color: rgba(226, 189, 98, 0.72);
  background: rgba(21, 39, 32, 0.78);
}

.yw-opening-primary svg,
.yw-opening-secondary svg {
  width: 18px;
  height: 18px;
}

.yw-opening-primary-instrument {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(233, 200, 111, 0.72);
  border-radius: 2px;
  display: grid;
  place-items: center;
  color: #f5d47f;
  background: rgba(6, 17, 13, 0.82);
  box-shadow:
    inset 0 0 0 3px rgba(24, 53, 40, 0.8),
    0 0 0 1px rgba(3, 10, 7, 0.9);
}

.yw-opening-primary-instrument svg {
  width: 17px;
  height: 17px;
  margin-left: 2px;
  fill: currentColor;
}

.yw-opening-primary-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
  text-align: left;
}

.yw-opening-primary-copy strong {
  font-size: 15px;
}

.yw-opening-primary-copy small {
  color: rgba(226, 189, 98, 0.72);
  font-size: 8px;
  font-weight: 750;
}

.yw-opening-footnote {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: rgba(185, 194, 186, 0.5);
  font-size: 9px;
  font-weight: 700;
}

.yw-opening-footnote span:last-child {
  color: rgba(226, 189, 98, 0.56);
}

.yw-opening-intro {
  position: absolute;
  z-index: 4;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 380ms ease 160ms, visibility 0s linear 540ms;
}

.yw-opening[data-mode="intro"] .yw-opening-intro {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition-delay: 0s;
}

.yw-opening-intro-head {
  position: absolute;
  top: 30px;
  right: max(36px, calc((100vw - 1400px) / 2));
  left: max(36px, calc((100vw - 1400px) / 2));
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.yw-opening-intro-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.yw-opening-clock {
  display: grid;
  gap: 3px;
  color: var(--yw-opening-ink);
  text-shadow: 0 3px 16px rgba(0, 0, 0, 0.72);
}

.yw-opening-clock time {
  font-size: 42px;
  font-weight: 250;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.yw-opening-clock small {
  color: var(--yw-opening-brass);
  font-size: 9px;
  font-weight: 800;
}

.yw-opening-autoplay,
.yw-opening-skip {
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 750;
}

.yw-opening-autoplay svg,
.yw-opening-skip svg {
  width: 16px;
  height: 16px;
}

.yw-opening-autoplay svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.yw-opening-autoplay[aria-pressed="true"] .autoplay-play-icon,
.yw-opening-autoplay[aria-pressed="false"] .autoplay-pause-icon {
  display: none;
}

.yw-opening-autoplay[aria-pressed="false"] {
  color: var(--yw-opening-brass);
  border-color: rgba(226, 189, 98, 0.55);
}

.yw-opening-scene-card {
  position: absolute;
  z-index: 1;
  right: max(36px, calc((100vw - 1400px) / 2));
  bottom: 204px;
  display: grid;
  justify-items: end;
  gap: 3px;
  color: rgba(242, 240, 230, 0.8);
  text-align: right;
  text-shadow: 0 3px 16px rgba(0, 0, 0, 0.86);
}

.yw-opening-scene-count {
  color: var(--yw-opening-brass);
  font-size: 9px;
  font-weight: 850;
}

.yw-opening-scene-label {
  font-size: 12px;
  font-weight: 700;
}

.yw-opening-dialogue {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  min-height: 190px;
  padding: 28px max(36px, calc((100vw - 1400px) / 2)) 30px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 32px;
  border-top: 1px solid rgba(226, 189, 98, 0.5);
  background: rgba(5, 13, 10, 0.9);
  box-shadow: 0 -22px 70px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(12px);
  transition: min-height 320ms ease, background 220ms ease;
}

.yw-opening.is-hold .yw-opening-dialogue {
  min-height: 88px;
  background: linear-gradient(180deg, rgba(5, 13, 10, 0), rgba(5, 13, 10, 0.68));
  backdrop-filter: none;
}

.yw-opening.is-hold .yw-opening-dialogue-copy {
  opacity: 0;
}

.yw-opening-dialogue-copy {
  display: grid;
  grid-template-columns: 126px minmax(0, 780px);
  gap: 28px;
  align-items: start;
  transition: opacity 220ms ease;
}

.yw-opening-speaker {
  margin: 3px 0 0;
  color: var(--yw-opening-brass);
  font-size: 11px;
  font-weight: 850;
}

.yw-opening-speaker span {
  display: block;
}

.yw-opening-speaker small {
  display: block;
  margin-top: 5px;
  color: rgba(185, 194, 186, 0.48);
  font-size: 8px;
}

.yw-opening-line {
  min-height: 68px;
  margin: 0;
  color: #f4f1e6;
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 27px;
  font-weight: 650;
  line-height: 1.55;
}

.yw-opening-dialogue-nav {
  display: grid;
  grid-template-columns: auto 52px;
  align-items: center;
  gap: 18px;
}

.yw-opening-progress-copy {
  display: grid;
  grid-template-columns: minmax(92px, 170px) auto;
  align-items: center;
  gap: 10px;
}

.yw-opening-progress {
  position: relative;
  width: clamp(92px, 12vw, 170px);
  height: 2px;
  overflow: hidden;
  background: rgba(242, 240, 230, 0.24);
}

.yw-opening-progress i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--yw-opening-brass);
  transition: width 300ms ease;
}

.yw-opening-progress-text {
  color: rgba(242, 240, 230, 0.52);
  font-size: 9px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.yw-opening-next {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid var(--yw-opening-brass);
  border-radius: 3px;
  color: #152019;
  background: var(--yw-opening-brass);
  cursor: pointer;
  box-shadow: 0 4px 0 #765a24;
}

.yw-opening-next:hover {
  background: #efcb76;
}

.yw-opening-next:active {
  transform: translateY(2px);
  box-shadow: 0 2px 0 #765a24;
}

.yw-opening-next svg {
  width: 20px;
  height: 20px;
}

.yw-radio {
  position: fixed;
  z-index: 7000;
  right: auto;
  bottom: clamp(154px, 21vh, 210px);
  left: 50%;
  width: min(610px, calc(100vw - 48px));
  min-height: 82px;
  padding: 17px 24px 17px 79px;
  color: var(--yw-opening-ink);
  border: 1px solid rgba(226, 189, 98, 0.6);
  border-radius: 3px;
  background: rgba(6, 16, 12, 0.94);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  transform: translateX(-50%);
  backdrop-filter: blur(10px);
  animation: yw-radio-in 280ms ease both;
}

.yw-radio::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 58px;
  width: 1px;
  background: rgba(226, 189, 98, 0.32);
}

.yw-radio-icon {
  position: absolute;
  top: 19px;
  left: 17px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: var(--yw-opening-brass);
}

.yw-radio-icon svg {
  width: 22px;
  height: 22px;
}

.yw-radio strong {
  display: block;
  margin-bottom: 5px;
  color: var(--yw-opening-brass);
  font-size: 9px;
  font-weight: 850;
}

.yw-radio p {
  margin: 0;
  color: rgba(242, 240, 230, 0.94);
  font-size: 15px;
  font-weight: 620;
  line-height: 1.55;
}

.yw-radio[data-tone="echo"] {
  border-color: rgba(93, 210, 213, 0.72);
}

.yw-radio[data-tone="echo"] strong,
.yw-radio[data-tone="echo"] .yw-radio-icon {
  color: var(--yw-opening-cyan);
}

.yw-radio[data-tone="complete"] {
  border-color: rgba(226, 189, 98, 0.92);
  background: rgba(12, 26, 20, 0.97);
}

.yw-chapter-reveal {
  position: fixed;
  z-index: 6800;
  top: 18%;
  right: 0;
  left: 0;
  color: var(--yw-opening-ink);
  text-align: center;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.78);
  pointer-events: none;
  animation: yw-reveal 2900ms ease both;
}

.yw-chapter-reveal small {
  display: block;
  margin-bottom: 8px;
  color: var(--yw-opening-brass);
  font-size: 10px;
  font-weight: 850;
}

.yw-chapter-reveal strong {
  display: block;
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 46px;
  line-height: 1.1;
}

.yw-chapter-reveal span {
  display: block;
  margin-top: 9px;
  color: rgba(242, 240, 230, 0.66);
  font-size: 11px;
  font-weight: 750;
}

body[data-experience="yw01-v2"] #replay-briefing-button.yw-replay-opening {
  display: inline-flex !important;
}

@keyframes yw-radio-in {
  from { opacity: 0; transform: translate(-50%, 14px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

@keyframes yw-reveal {
  0% { opacity: 0; transform: translateY(12px); }
  18%, 68% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-8px); }
}

@media (max-width: 900px) {
  .yw-opening-frame {
    width: calc(100% - 48px);
  }

  .yw-opening-title {
    width: min(620px, 72vw);
  }

  .yw-opening-title h1 {
    font-size: 72px;
  }

  .yw-opening-intro-head {
    right: 24px;
    left: 24px;
  }

  .yw-opening-scene-card {
    right: 24px;
  }

  .yw-opening-dialogue {
    padding-right: 24px;
    padding-left: 24px;
  }

  .yw-opening-dialogue-copy {
    grid-template-columns: 104px minmax(0, 1fr);
    gap: 18px;
  }

  .yw-opening-line {
    font-size: 23px;
  }
}

@media (max-width: 640px) {
  .yw-opening-scene {
    object-position: 64% center;
  }

  .yw-opening[data-mode="intro"][data-scene="1"] .yw-opening-scene { object-position: 70% center !important; }
  .yw-opening[data-mode="intro"][data-scene="2"] .yw-opening-scene { object-position: 72% center !important; }
  .yw-opening[data-mode="intro"][data-scene="3"] .yw-opening-scene { object-position: 40% center !important; }
  .yw-opening[data-mode="intro"][data-scene="4"] .yw-opening-scene { object-position: 63% center !important; }
  .yw-opening[data-mode="intro"][data-scene="5"] .yw-opening-scene { object-position: 72% center !important; }

  .yw-opening-shade {
    background:
      linear-gradient(180deg, rgba(4, 10, 8, 0.45) 0%, rgba(4, 10, 8, 0.1) 28%, rgba(4, 10, 8, 0.56) 59%, rgba(4, 10, 8, 0.95) 100%),
      linear-gradient(90deg, rgba(4, 10, 8, 0.46), transparent 82%);
  }

  .yw-opening-frame {
    width: calc(100% - 32px);
    min-height: 520px;
    padding: 18px 0 20px;
  }

  .yw-opening-institution {
    font-size: 9px;
  }

  .yw-opening-institution svg {
    width: 34px;
    height: 34px;
  }

  .yw-opening-title {
    align-self: end;
    width: 100%;
    padding-bottom: 62px;
  }

  .yw-opening-file {
    margin-bottom: 11px;
    font-size: 10px;
  }

  .yw-opening-title h1 {
    font-size: 54px;
    line-height: 0.98;
  }

  .yw-opening-title h1 span {
    display: inline;
  }

  .yw-opening-tagline {
    width: min(100%, 360px);
    margin-top: 16px;
    font-size: 15px;
    line-height: 1.6;
  }

  .yw-opening-meta {
    gap: 14px;
    margin-top: 18px;
    padding: 10px 0;
  }

  .yw-opening-meta span {
    min-width: 0;
  }

  .yw-opening-meta strong {
    font-size: 12px;
  }

  .yw-opening-actions {
    align-items: stretch;
    margin-top: 19px;
  }

  .yw-opening-primary,
  .yw-opening-secondary {
    min-width: 0;
    min-height: 48px;
    padding: 0 16px;
    font-size: 13px;
  }

  .yw-opening-footnote span:first-child {
    display: none;
  }

  .yw-opening-intro-head {
    top: 18px;
    right: 16px;
    left: 16px;
  }

  .yw-opening-intro-tools {
    gap: 6px;
  }

  .yw-opening-autoplay,
  .yw-opening-skip {
    min-height: 38px;
    padding: 0 9px;
    font-size: 10px;
  }

  .yw-opening-clock time {
    font-size: 34px;
  }

  .yw-opening-dialogue {
    min-height: 228px;
    padding: 23px 16px 22px;
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .yw-opening-scene-card {
    right: 16px;
    bottom: 244px;
  }

  .yw-opening.is-hold .yw-opening-scene-card {
    bottom: 102px;
  }

  .yw-opening-dialogue-copy {
    grid-template-columns: minmax(0, 1fr);
    gap: 8px;
  }

  .yw-opening-speaker {
    display: flex;
    align-items: baseline;
    gap: 8px;
  }

  .yw-opening-speaker small {
    display: inline;
    margin: 0;
  }

  .yw-opening-line {
    min-height: 72px;
    font-size: 20px;
    line-height: 1.5;
  }

  .yw-opening-dialogue-nav {
    justify-self: stretch;
    grid-template-columns: 1fr 48px;
  }

  .yw-opening-progress-copy {
    grid-template-columns: minmax(80px, 1fr) auto;
  }

  .yw-opening-progress {
    width: 100%;
  }

  .yw-opening-next {
    width: 48px;
    height: 48px;
  }

  .yw-radio {
    right: auto;
    bottom: var(--yw-radio-bottom, 190px);
    left: 50%;
    width: calc(100vw - 24px);
    min-height: 74px;
    padding: 14px 16px 14px 62px;
  }

  .yw-radio::before {
    left: 48px;
  }

  .yw-radio-icon {
    top: 15px;
    left: 12px;
  }

  .yw-radio p {
    font-size: 13px;
  }

  .yw-chapter-reveal {
    top: 14%;
  }

  .yw-chapter-reveal strong {
    font-size: 34px;
  }
}

@media (max-height: 620px) and (orientation: landscape) {
  .yw-opening-frame {
    min-height: 360px;
    padding-top: 14px;
    padding-bottom: 14px;
  }

  .yw-opening-title {
    width: 560px;
    padding-bottom: 0;
  }

  .yw-opening-title h1 {
    font-size: 58px;
  }

  .yw-opening-tagline {
    margin-top: 12px;
    font-size: 14px;
  }

  .yw-opening-meta {
    margin-top: 14px;
    padding: 7px 0;
  }

  .yw-opening-actions {
    margin-top: 15px;
  }

  .yw-opening-primary,
  .yw-opening-secondary {
    min-height: 42px;
  }

  .yw-opening-dialogue {
    min-height: 132px;
    padding-top: 20px;
    padding-bottom: 20px;
  }

  .yw-opening-scene-card {
    bottom: 148px;
  }

  .yw-opening.is-hold .yw-opening-scene-card {
    bottom: 96px;
  }

  .yw-opening-line {
    min-height: 46px;
    font-size: 21px;
  }

  .yw-opening-footnote {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .yw-opening,
  .yw-opening-scene,
  .yw-opening-title,
  .yw-opening-intro {
    transition-duration: 1ms !important;
  }

  .yw-radio,
  .yw-chapter-reveal {
    animation-duration: 1ms !important;
  }
}

/* First-load title screen. The artwork remains full bleed so the archive hall,
   rather than another interface panel, carries the opening impression. */
.yw-splash[hidden] {
  display: none !important;
}

.yw-splash {
  position: fixed;
  z-index: 11000;
  inset: 0;
  min-width: 320px;
  min-height: 100dvh;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: var(--yw-opening-ink);
  background: #06100d;
  isolation: isolate;
}

.yw-splash::before,
.yw-splash::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.yw-splash::before {
  z-index: -2;
  background-image: url("assets/opening/title-screen-v1.webp");
  background-position: center center;
  background-repeat: no-repeat;
  background-size: cover;
  filter: saturate(0.9) contrast(1.04) brightness(0.9);
  transform: scale(1.012);
  animation: yw-splash-arrive 9s ease-out both;
}

.yw-splash::after {
  z-index: -1;
  background: rgba(2, 8, 6, 0.2);
  box-shadow:
    inset 0 0 120px rgba(0, 0, 0, 0.48),
    inset 0 -130px 110px rgba(0, 0, 0, 0.28);
}

.yw-splash__content {
  width: min(100% - 48px, 920px);
  min-height: 430px;
  padding: 44px 24px 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  transform: translateY(-4vh);
  animation: yw-splash-copy-in 760ms cubic-bezier(0.2, 0.72, 0.26, 1) both;
}

.yw-splash__eyebrow {
  margin: 0 0 21px;
  color: var(--yw-opening-brass);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: 0;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.78);
}

.yw-splash__eyebrow::before,
.yw-splash__eyebrow::after {
  content: "";
  display: inline-block;
  width: 38px;
  height: 1px;
  margin: 0 13px 4px;
  background: rgba(226, 189, 98, 0.76);
}

.yw-splash h1 {
  margin: 0;
  color: #f5f1e3;
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 116px;
  font-weight: 850;
  line-height: 1;
  letter-spacing: 0;
  text-shadow:
    0 4px 0 rgba(5, 13, 10, 0.52),
    0 10px 34px rgba(0, 0, 0, 0.88);
}

.yw-splash__start {
  position: relative;
  isolation: isolate;
  min-width: 272px;
  min-height: 64px;
  margin-top: 48px;
  padding: 11px 34px;
  border: 0;
  border-radius: 2px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  color: #fff8df;
  background: rgba(7, 20, 15, 0.96);
  box-shadow:
    0 0 0 1px rgba(238, 201, 111, 0.9),
    0 0 0 4px rgba(3, 10, 7, 0.92),
    0 0 0 5px rgba(226, 189, 98, 0.24),
    0 13px 28px rgba(0, 0, 0, 0.44),
    inset 0 1px 0 rgba(255, 247, 218, 0.12);
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0;
  cursor: pointer;
  backdrop-filter: blur(8px);
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 0 100%);
  transition:
    color 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.yw-splash__start svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  stroke: currentColor;
  stroke-width: 1.7;
}

.yw-splash__start-copy {
  min-width: 0;
  display: grid;
  gap: 2px;
  justify-items: center;
  text-align: center;
}

.yw-splash__start-copy strong { font-family: "STSong", "Songti SC", "SimSun", serif; font-size: 18px; }
.yw-splash__start-copy small { color: rgba(226, 189, 98, 0.7); font-size: 8px; font-weight: 800; }

.yw-splash__start::after { display: none; }

#yw-splash .yw-splash__device-note {
  max-width: min(420px, 82vw);
  margin: 18px 0 0;
  color: rgba(242, 240, 230, 0.76);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.65;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.86);
}

.yw-splash__loader {
  width: min(360px, 86vw);
  margin-top: 38px;
  display: grid;
  gap: 9px;
  color: rgba(242, 240, 230, 0.76);
  text-align: left;
}

.yw-splash__loader[hidden],
.yw-splash__error[hidden] {
  display: none !important;
}

.yw-splash__loading-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  font-size: 10px;
  font-weight: 750;
}

.yw-splash__loading-row strong {
  color: var(--yw-opening-brass);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.yw-splash__loading-track {
  position: relative;
  height: 3px;
  overflow: hidden;
  background: rgba(242, 240, 230, 0.14);
  box-shadow: 0 0 0 1px rgba(5, 13, 10, 0.72);
}

.yw-splash__loading-track i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--yw-opening-brass);
  box-shadow: 0 0 12px rgba(226, 189, 98, 0.42);
  transition: width 180ms ease;
}

.yw-splash__loader > small {
  min-height: 14px;
  color: rgba(185, 194, 186, 0.62);
  font-size: 8px;
  font-weight: 700;
}

.yw-splash__error {
  width: min(390px, 86vw);
  margin-top: 30px;
  padding: 16px 18px;
  border: 1px solid rgba(237, 105, 88, 0.7);
  background: rgba(22, 10, 8, 0.82);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.3);
}

.yw-splash__error strong {
  color: #f2c5bd;
  font-size: 12px;
}

.yw-splash__error p {
  margin: 6px 0 12px;
  color: rgba(242, 240, 230, 0.7);
  font-size: 10px;
  line-height: 1.6;
}

.yw-splash__retry {
  min-height: 36px;
  padding: 0 16px;
  border: 1px solid rgba(226, 189, 98, 0.7);
  border-radius: 2px;
  color: #fff8df;
  background: rgba(7, 20, 15, 0.96);
  font: inherit;
  font-size: 10px;
  font-weight: 800;
  cursor: pointer;
}

.yw-splash__start:disabled {
  color: rgba(242, 240, 230, 0.46);
  background: rgba(7, 20, 15, 0.78);
  box-shadow:
    0 0 0 1px rgba(226, 189, 98, 0.34),
    0 0 0 4px rgba(3, 10, 7, 0.82),
    0 10px 24px rgba(0, 0, 0, 0.28);
  cursor: wait;
  transform: none;
}

#yw-splash.is-loading .yw-splash__start {
  margin-top: 22px;
}

#yw-splash.has-load-error .yw-splash__start,
#yw-splash.has-load-error .yw-splash__device-note {
  display: none;
}

.yw-splash__start:hover {
  color: #fffdf2;
  background-color: rgba(18, 41, 31, 0.98);
  box-shadow:
    0 0 0 1px #f1cf7b,
    0 0 0 4px rgba(3, 10, 7, 0.94),
    0 0 0 5px rgba(226, 189, 98, 0.36),
    0 15px 30px rgba(0, 0, 0, 0.48),
    inset 0 1px 0 rgba(255, 247, 218, 0.17);
}

.yw-splash__start:active {
  transform: translateY(1px);
  box-shadow:
    0 0 0 1px rgba(238, 201, 111, 0.88),
    0 0 0 3px rgba(3, 10, 7, 0.92),
    0 0 0 4px rgba(226, 189, 98, 0.22),
    0 9px 22px rgba(0, 0, 0, 0.46);
}

.yw-splash__start:focus-visible {
  outline: 3px solid rgba(93, 210, 213, 0.92);
  outline-offset: 4px;
}

@keyframes yw-splash-arrive {
  from {
    opacity: 0.78;
    transform: scale(1.04);
  }
  to {
    opacity: 1;
    transform: scale(1.012);
  }
}

@keyframes yw-splash-copy-in {
  from {
    opacity: 0;
    transform: translateY(calc(-4vh + 14px));
  }
  to {
    opacity: 1;
    transform: translateY(-4vh);
  }
}

@media (max-width: 390px) {
  .yw-splash::before {
    background-position: 50% center;
  }

  .yw-splash::after {
    background: rgba(2, 8, 6, 0.28);
    box-shadow:
      inset 0 0 72px rgba(0, 0, 0, 0.54),
      inset 0 -100px 90px rgba(0, 0, 0, 0.3);
  }

  #yw-splash .yw-splash__content {
    width: calc(100% - 28px);
    min-height: 300px;
    padding: 34px 10px 20px;
    transform: translateY(-3vh);
  }

  #yw-splash .yw-splash__eyebrow {
    margin-bottom: 14px;
    font-size: 10px;
  }

  #yw-splash .yw-splash__eyebrow::before,
  #yw-splash .yw-splash__eyebrow::after {
    width: 24px;
    margin-right: 9px;
    margin-left: 9px;
  }

  #yw-splash h1 {
    font-size: 68px;
  }

  #yw-splash .yw-splash__start {
    min-width: 224px;
    min-height: 62px;
    margin-top: 34px;
    padding: 8px 22px;
    font-size: 14px;
  }

  .yw-splash__loader {
    margin-top: 28px;
  }

  #yw-splash .yw-splash__device-note {
    max-width: 260px;
    margin-top: 14px;
    font-size: 10px;
  }

  #yw-splash.is-loading .yw-splash__start {
    margin-top: 18px;
  }

  @keyframes yw-splash-copy-in {
    from {
      opacity: 0;
      transform: translateY(calc(-3vh + 12px));
    }
    to {
      opacity: 1;
      transform: translateY(-3vh);
    }
  }
}

@media (max-height: 620px) and (orientation: landscape) {
  #yw-splash .yw-splash__content {
    min-height: 250px;
    padding-top: 20px;
    padding-bottom: 16px;
    transform: translateY(-2vh);
  }

  #yw-splash .yw-splash__eyebrow {
    margin-bottom: 10px;
    font-size: 10px;
  }

  #yw-splash h1 {
    font-size: 78px;
  }

  #yw-splash .yw-splash__start {
    min-height: 56px;
    margin-top: 22px;
  }

  #yw-splash .yw-splash__device-note {
    margin-top: 10px;
    font-size: 9px;
  }

  @keyframes yw-splash-copy-in {
    from {
      opacity: 0;
      transform: translateY(calc(-2vh + 10px));
    }
    to {
      opacity: 1;
      transform: translateY(-2vh);
    }
  }
}

@media (max-height: 420px) {
  #yw-splash {
    overflow-y: auto;
    scrollbar-width: none;
  }

  #yw-splash::-webkit-scrollbar { width: 0; }

  #yw-splash .yw-splash__content {
    min-height: 320px;
    padding: 14px 16px;
    transform: none;
  }

  #yw-splash .yw-splash__eyebrow {
    margin-bottom: 6px;
    font-size: 9px;
  }

  #yw-splash h1 {
    font-size: 58px;
  }

  #yw-splash .yw-splash__loader {
    margin-top: 14px;
  }

  #yw-splash .yw-splash__start,
  #yw-splash.is-loading .yw-splash__start {
    min-height: 52px;
    margin-top: 14px;
  }

  #yw-splash .yw-splash__device-note {
    margin-top: 8px;
    font-size: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .yw-splash::before,
  .yw-splash__content {
    animation: none !important;
  }

  .yw-splash__start {
    transition-duration: 1ms !important;
  }
}

/* Lobby workstations */
.yw-hub-tools[hidden],
.yw-hub-view[hidden],
.yw-inspection-hotspot[hidden] {
  display: none !important;
}

.yw-hub-tools {
  position: absolute;
  z-index: 12;
  inset: 0;
  padding: 24px;
  display: grid;
  place-items: center;
  overflow: auto;
  color: var(--yw-opening-ink);
  background: rgba(2, 8, 6, 0.86);
  backdrop-filter: blur(10px);
  animation: yw-hub-in 220ms ease-out both;
}

.yw-hub-tools-shell {
  width: min(1240px, 100%);
  height: min(790px, calc(100dvh - 48px));
  min-height: 520px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid rgba(226, 189, 98, 0.68);
  border-radius: 4px;
  background: #09130f;
  box-shadow:
    14px 18px 0 rgba(0, 0, 0, 0.34),
    inset 0 0 0 3px rgba(226, 189, 98, 0.06);
}

.yw-hub-tools-header {
  position: relative;
  min-height: 92px;
  padding: 19px 76px 17px 24px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(226, 189, 98, 0.34);
  background:
    repeating-linear-gradient(90deg, transparent 0 39px, rgba(226, 189, 98, 0.028) 40px),
    #102119;
}

.yw-hub-tools-header p,
.yw-hub-tools-header h2,
.yw-hub-tools-header span {
  margin: 0;
}

.yw-hub-tools-header p {
  color: var(--yw-opening-brass);
  font-size: 9px;
  font-weight: 800;
}

.yw-hub-tools-header h2 {
  margin-top: 3px;
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 30px;
  line-height: 1.1;
}

.yw-hub-tools-header span {
  display: block;
  margin-top: 5px;
  color: rgba(185, 194, 186, 0.74);
  font-size: 11px;
}

.yw-hub-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(185, 194, 186, 0.44);
  border-radius: 3px;
  display: grid;
  place-items: center;
  color: var(--yw-opening-ink);
  background: rgba(7, 17, 14, 0.62);
  cursor: pointer;
}

.yw-hub-close:hover,
.yw-hub-close:focus-visible {
  border-color: var(--yw-opening-brass);
  color: var(--yw-opening-brass);
}

.yw-hub-close:focus-visible,
.yw-inspection-rotation button:focus-visible,
.yw-inspection-hotspot:focus-visible,
.yw-compare-orders:focus-visible,
.yw-journal-inspection-link:focus-visible,
.yw-paper-tab:focus-visible {
  outline: 2px solid var(--yw-opening-cyan);
  outline-offset: 2px;
}

.yw-hub-close svg,
.yw-inspection-rotation svg,
.yw-compare-orders svg,
.yw-journal-inspection-link svg {
  width: 18px;
  height: 18px;
}

.yw-hub-tools-body {
  min-height: 0;
  overflow: hidden;
}

.yw-hub-view {
  width: 100%;
  height: 100%;
  overflow: auto;
}

@keyframes yw-hub-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Lobby directory */
.yw-hub-directory {
  padding: 24px;
  background:
    linear-gradient(rgba(226, 189, 98, 0.035) 1px, transparent 1px) 0 0 / 100% 26px,
    #0b1712;
}

.yw-hub-directory-progress {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid rgba(185, 194, 186, 0.24);
  background: rgba(20, 39, 31, 0.82);
}

.yw-hub-directory-progress span {
  min-width: 0;
  min-height: 64px;
  padding: 12px 16px;
  display: grid;
  align-content: center;
  gap: 3px;
  border-right: 1px solid rgba(185, 194, 186, 0.2);
}

.yw-hub-directory-progress span:last-child { border-right: 0; }
.yw-hub-directory-progress small { color: rgba(185, 194, 186, 0.6); font-size: 8px; font-weight: 800; }
.yw-hub-directory-progress strong { color: var(--yw-opening-brass); font-size: 17px; }

.yw-hub-level-list {
  margin-top: 20px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
}

.yw-hub-level-list h3 {
  grid-column: 1 / -1;
  min-width: 0;
  margin: 12px 0 2px;
  padding: 0 2px 8px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid rgba(226, 189, 98, 0.3);
  color: rgba(242, 240, 230, 0.88);
  font-size: 12px;
}

.yw-hub-level-list h3:first-child { margin-top: 0; }
.yw-hub-level-list h3 small { color: rgba(226, 189, 98, 0.58); font-size: 8px; }

.yw-hub-level {
  width: 100%;
  min-width: 0;
  min-height: 66px;
  padding: 9px 11px;
  border: 1px solid rgba(185, 194, 186, 0.3);
  border-radius: 2px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  color: var(--yw-opening-ink);
  background: rgba(19, 38, 30, 0.72);
  text-align: left;
  cursor: pointer;
}

.yw-hub-level > span:first-child {
  width: 32px;
  height: 32px;
  border: 1px solid rgba(226, 189, 98, 0.48);
  display: grid;
  place-items: center;
  color: var(--yw-opening-brass);
  font-size: 10px;
  font-weight: 800;
}

.yw-hub-level > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.yw-hub-level strong,
.yw-hub-level small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.yw-hub-level strong { font-size: 12px; }
.yw-hub-level small { color: rgba(185, 194, 186, 0.66); font-size: 9px; }
.yw-hub-level em { color: var(--yw-opening-brass); font-size: 9px; font-style: normal; font-weight: 800; }

.yw-hub-level-result {
  min-width: 92px;
  display: grid;
  justify-items: end;
  gap: 5px;
}

.yw-level-stamps {
  display: inline-flex;
  gap: 4px;
}

.yw-level-stamps i {
  width: 22px;
  height: 22px;
  border: 1px dashed rgba(185, 194, 186, 0.36);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: rgba(185, 194, 186, 0.38);
  background: rgba(2, 9, 6, 0.28);
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 10px;
  font-style: normal;
  font-weight: 850;
}

.yw-level-stamps i.is-earned {
  border-style: double;
  border-color: #e1bb57;
  color: #fff2ba;
  background: #7c5722;
  box-shadow: inset 0 0 0 2px rgba(255, 235, 164, 0.12), 0 0 8px rgba(226, 189, 98, 0.14);
}

.yw-hub-level:hover,
.yw-hub-level:focus-visible,
.yw-hub-level.is-active {
  border-color: rgba(226, 189, 98, 0.82);
  background: rgba(35, 67, 53, 0.86);
}

.yw-hub-level.is-complete { box-shadow: inset 4px 0 0 #4c8a62; }
.yw-hub-level.is-locked { cursor: not-allowed; filter: grayscale(0.65); opacity: 0.45; }
.yw-hub-empty { color: rgba(185, 194, 186, 0.7); }

/* Story archive */
.yw-hub-review {
  padding: 24px;
  background:
    linear-gradient(rgba(226, 189, 98, 0.035) 1px, transparent 1px) 0 0 / 100% 26px,
    #0b1712;
}

.yw-story-review-status {
  min-height: 70px;
  padding: 13px 16px;
  border: 1px solid rgba(185, 194, 186, 0.24);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: rgba(20, 39, 31, 0.82);
}

.yw-story-review-status p,
.yw-story-review-status span { margin: 0; }
.yw-story-review-status p { display: grid; gap: 3px; }
.yw-story-review-status small { color: rgba(226, 189, 98, 0.65); font-size: 8px; font-weight: 850; }
.yw-story-review-status strong { font-family: "STSong", "Songti SC", "SimSun", serif; font-size: 20px; }
.yw-story-review-status > span { color: rgba(185, 194, 186, 0.68); font-size: 10px; }

.yw-story-review-list {
  margin-top: 16px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px 12px;
}

.yw-story-review-item {
  min-width: 0;
  min-height: 74px;
  padding: 10px 12px;
  border: 1px solid rgba(185, 194, 186, 0.28);
  border-radius: 3px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 11px;
  color: var(--yw-opening-ink);
  background: rgba(17, 34, 27, 0.82);
  text-align: left;
}

.yw-story-review-item.is-unlocked { cursor: pointer; }
.yw-story-review-item.is-unlocked:hover,
.yw-story-review-item.is-unlocked:focus-visible {
  border-color: rgba(226, 189, 98, 0.82);
  background: rgba(35, 67, 53, 0.9);
  outline: none;
}

.yw-story-review-item.is-locked { opacity: 0.42; }
.yw-story-review-number {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(226, 189, 98, 0.48);
  display: grid;
  place-items: center;
  color: var(--yw-opening-brass);
  font-size: 10px;
  font-weight: 850;
}

.yw-story-review-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.yw-story-review-copy small,
.yw-story-review-copy strong,
.yw-story-review-copy em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.yw-story-review-copy small { color: rgba(226, 189, 98, 0.62); font-size: 8px; font-weight: 750; }
.yw-story-review-copy strong { font-size: 12px; }
.yw-story-review-copy em { color: rgba(185, 194, 186, 0.62); font-size: 9px; font-style: normal; }
.yw-story-review-item > svg { width: 20px; height: 20px; color: var(--yw-opening-brass); }

/* Inspection desk */
.yw-hub-inspection {
  position: relative;
  background:
    linear-gradient(90deg, rgba(3, 9, 7, 0.08) 0%, rgba(3, 9, 7, 0.06) 52%, rgba(3, 9, 7, 0.64) 100%),
    linear-gradient(180deg, rgba(3, 9, 7, 0.05), rgba(3, 9, 7, 0.3)),
    url("assets/inspection/inspection-desk.webp") center / cover no-repeat;
}

.yw-inspection-case-tabs {
  position: absolute;
  z-index: 4;
  top: 16px;
  left: 20px;
  display: flex;
  gap: 6px;
}

.yw-inspection-case-tabs button {
  min-width: 118px;
  min-height: 42px;
  padding: 7px 12px;
  border: 1px solid rgba(226, 189, 98, 0.34);
  border-radius: 3px;
  display: grid;
  justify-items: start;
  gap: 1px;
  color: rgba(242, 240, 230, 0.68);
  background: rgba(5, 15, 11, 0.82);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
  cursor: pointer;
}

.yw-inspection-case-tabs button small { color: rgba(185, 194, 186, 0.56); font-size: 7px; }
.yw-inspection-case-tabs button.is-active { border-color: rgba(226, 189, 98, 0.9); color: #fff4c9; background: rgba(29, 59, 46, 0.94); }
.yw-inspection-case-tabs button.is-complete small { color: #86c99d; }
.yw-inspection-case-tabs button:disabled { cursor: not-allowed; filter: grayscale(0.7); opacity: 0.34; }

.yw-inspection-workbench {
  min-height: 100%;
  padding: 70px 24px 24px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(390px, 0.72fr);
  align-items: end;
  gap: 22px;
}

.yw-inspection-stage-column {
  min-width: 0;
  display: grid;
  justify-items: center;
  align-content: end;
  gap: 10px;
}

.yw-inspection-stage {
  --inspection-turn: 0deg;
  position: relative;
  width: min(45vh, 360px);
  height: min(45vh, 360px);
  min-width: 250px;
  min-height: 250px;
  display: grid;
  place-items: center;
  touch-action: pan-y;
  cursor: grab;
  isolation: isolate;
}

.yw-inspection-stage.is-dragging { cursor: grabbing; }

.yw-inspection-stage-ring {
  position: absolute;
  z-index: -1;
  inset: 11%;
  border: 1px solid rgba(226, 189, 98, 0.58);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(226, 189, 98, 0.13), rgba(6, 15, 11, 0.18) 64%, transparent 66%);
  box-shadow:
    0 28px 38px rgba(0, 0, 0, 0.5),
    inset 0 0 0 9px rgba(28, 22, 12, 0.38),
    0 0 0 8px rgba(92, 65, 25, 0.22);
  transform: perspective(600px) rotateX(64deg) translateY(25%);
}

.yw-inspection-stage > img {
  width: 73%;
  height: 73%;
  object-fit: contain;
  filter: drop-shadow(0 22px 15px rgba(0, 0, 0, 0.64)) saturate(0.86) brightness(0.88);
  transform: none;
  transition: filter 180ms ease;
  user-select: none;
  -webkit-user-drag: none;
}

.yw-inspection-stage:focus-visible {
  outline: 2px solid rgba(93, 210, 213, 0.88);
  outline-offset: 2px;
}

.yw-inspection-hotspot {
  position: absolute;
  z-index: 2;
  min-width: 54px;
  min-height: 44px;
  padding: 5px 7px;
  border: 1px solid #f0cb72;
  border-radius: 2px;
  display: grid;
  place-items: center;
  color: #fff5ce;
  background: rgba(16, 42, 33, 0.92);
  box-shadow: 0 0 0 4px rgba(226, 189, 98, 0.12), 0 5px 16px rgba(0, 0, 0, 0.4);
  cursor: pointer;
  animation: yw-hotspot-pulse 1.8s ease-in-out infinite;
}

.yw-inspection-hotspot[data-hotspot="seal"] { top: 39%; left: 51%; transform: translate(-50%, -50%); }
.yw-inspection-hotspot[data-hotspot="serial"] { top: 52%; left: 50%; transform: translate(-50%, -50%); }
.yw-inspection-hotspot[data-hotspot="scratch"] { top: 68%; left: 70%; transform: translate(-50%, -50%); }
.yw-inspection-hotspot span { font-size: 10px; font-weight: 850; }
.yw-inspection-hotspot small { font-size: 8px; font-weight: 700; }

.yw-inspection-hotspot.is-checked {
  border-color: #75c290;
  color: #e5ffed;
  background: rgba(32, 91, 57, 0.94);
  animation: none;
}

@keyframes yw-hotspot-pulse {
  50% { box-shadow: 0 0 0 8px rgba(226, 189, 98, 0.04), 0 5px 16px rgba(0, 0, 0, 0.4); }
}

.yw-inspection-rotation {
  width: min(100%, 390px);
  min-height: 50px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 48px;
  align-items: center;
  border: 1px solid rgba(226, 189, 98, 0.5);
  border-radius: 3px;
  background: rgba(6, 18, 13, 0.88);
  backdrop-filter: blur(7px);
}

.yw-inspection-rotation button {
  width: 48px;
  height: 48px;
  border: 0;
  display: grid;
  place-items: center;
  color: var(--yw-opening-brass);
  background: transparent;
  cursor: pointer;
}

.yw-inspection-rotation span { min-width: 0; display: grid; justify-items: center; gap: 2px; }
.yw-inspection-rotation small { color: rgba(185, 194, 186, 0.62); font-size: 8px; }
.yw-inspection-rotation strong { font-size: 11px; }

.yw-inspection-finding {
  width: min(100%, 540px);
  min-height: 82px;
  padding: 12px 15px;
  border-left: 3px solid var(--yw-opening-brass);
  display: grid;
  align-content: center;
  gap: 3px;
  background: rgba(5, 15, 11, 0.82);
  backdrop-filter: blur(8px);
}

.yw-inspection-finding span { color: var(--yw-opening-brass); font-size: 8px; font-weight: 800; }
.yw-inspection-finding strong { font-size: 13px; }
.yw-inspection-finding p { margin: 0; color: rgba(242, 240, 230, 0.68); font-size: 10px; line-height: 1.45; }

.yw-inspection-records {
  min-width: 0;
  display: grid;
  justify-items: center;
  align-content: end;
  gap: 12px;
}

.yw-paper-stack {
  position: relative;
  width: min(100%, 390px);
  height: 372px;
}

.yw-task-paper {
  position: absolute;
  top: 0;
  left: 50%;
  width: 272px;
  height: 342px;
  padding: 38px 22px 20px;
  overflow: hidden;
  border: 1px solid #8f855f;
  color: #1c241f;
  background:
    repeating-linear-gradient(0deg, transparent 0 26px, rgba(57, 74, 63, 0.12) 27px),
    #e7e2cb;
  box-shadow: 8px 12px 0 rgba(0, 0, 0, 0.34);
  transition: transform 260ms ease, opacity 180ms ease;
}

.yw-task-paper-old { transform: translateX(-58%) rotate(-3deg); }
.yw-task-paper-new { transform: translateX(-42%) translate(23px, 18px) rotate(2deg); }
.yw-paper-stack[data-front="old"] .yw-task-paper-old,
.yw-paper-stack[data-front="new"] .yw-task-paper-new { z-index: 2; }
.yw-paper-stack[data-front="old"] .yw-task-paper-new,
.yw-paper-stack[data-front="new"] .yw-task-paper-old { z-index: 1; filter: brightness(0.8); }

.yw-paper-tab {
  position: absolute;
  top: 0;
  right: 0;
  min-height: 30px;
  padding: 0 10px;
  border: 0;
  border-left: 1px solid #9d8c56;
  border-bottom: 1px solid #9d8c56;
  color: #302d21;
  background: #d5c78e;
  font-size: 9px;
  font-weight: 800;
  cursor: pointer;
}

.yw-task-paper p,
.yw-task-paper h3 { margin: 0; }
.yw-task-paper > p { color: #716843; font-size: 8px; font-weight: 800; }
.yw-task-paper h3 { margin-top: 4px; padding-bottom: 11px; border-bottom: 2px solid #30382f; font-family: "STSong", "Songti SC", serif; font-size: 19px; }
.yw-task-paper dl { margin: 17px 0 0; display: grid; gap: 12px; }
.yw-task-paper dl div { display: flex; justify-content: space-between; gap: 12px; border-bottom: 1px solid rgba(46, 58, 49, 0.35); }
.yw-task-paper dt { color: #606b63; font-size: 10px; }
.yw-task-paper dd { margin: 0; font-size: 10px; font-weight: 850; }

.yw-paper-seal {
  position: absolute;
  right: 24px;
  bottom: 40px;
  width: 70px;
  height: 70px;
  border: 3px double #9b3e34;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #9b3e34;
  font-family: "STSong", "Songti SC", serif;
  font-size: 15px;
  font-weight: 850;
  transform: rotate(-12deg);
  opacity: 0.78;
}

.yw-paper-signature { position: absolute; right: 22px; bottom: 28px; color: #51665b; font-size: 10px; border-bottom: 1px solid #51665b; }

.yw-paper-stack[data-mode="compare"] {
  width: min(100%, 560px);
}

.yw-paper-stack[data-mode="compare"] .yw-task-paper {
  width: 250px;
  height: 332px;
  filter: none;
}

.yw-paper-stack[data-mode="compare"] .yw-task-paper-old { left: 0; transform: none; }
.yw-paper-stack[data-mode="compare"] .yw-task-paper-new { right: 0; left: auto; transform: none; }

.yw-paper-stack[data-mode="compare"] .paper-diff-row {
  margin: -3px -6px;
  padding: 3px 6px;
  border: 1px solid #b94b3f;
  color: #7f251f;
  background: rgba(222, 103, 87, 0.16);
}

.yw-compare-orders,
.yw-journal-inspection-link {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid var(--yw-opening-brass);
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff8dc;
  background: #1d3b2e;
  font: inherit;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.yw-compare-orders:disabled { cursor: not-allowed; filter: grayscale(0.7); opacity: 0.5; }
.yw-compare-result { max-width: 430px; min-height: 30px; margin: 0; color: rgba(242, 240, 230, 0.68); font-size: 10px; line-height: 1.45; text-align: center; }
.yw-compare-result.is-alert { color: #ffb4a9; font-weight: 750; }
.yw-compare-result.has-dialogue {
  width: min(430px, 100%);
  padding: 9px 12px;
  border-left: 2px solid rgba(226, 189, 98, 0.8);
  color: rgba(246, 242, 226, 0.9);
  background: rgba(3, 12, 8, 0.58);
  text-align: left;
}

.yw-inspection-dialogue-lines { display: grid; gap: 5px; width: 100%; }
.yw-inspection-dialogue-line { display: grid; grid-template-columns: 48px minmax(0, 1fr); align-items: start; gap: 8px; }
.yw-inspection-dialogue-line strong { color: var(--yw-opening-brass); font-size: 9px; font-style: normal; font-weight: 850; white-space: nowrap; }
.yw-inspection-dialogue-line em { color: inherit; font-size: inherit; font-style: normal; font-weight: 500; line-height: 1.55; }
.yw-deduction__summary.has-dialogue { padding: 10px 12px; border-left: 2px solid rgba(226, 189, 98, 0.7); color: rgba(244, 240, 224, 0.86); background: rgba(0, 0, 0, 0.18); }
.yw-deduction__feedback.has-dialogue { display: grid; gap: 9px; }
.yw-deduction-verdict { display: block; }

.yw-inspection-guide[hidden] { display: none !important; }

.yw-inspection-guide {
  position: fixed;
  z-index: 40;
  width: min(286px, calc(100vw - 24px));
  padding: 13px 15px 14px;
  border: 1px solid rgba(234, 198, 105, 0.9);
  border-radius: 3px;
  display: grid;
  gap: 4px;
  color: #f5f0de;
  background: rgba(7, 22, 16, 0.97);
  box-shadow: 0 13px 34px rgba(0, 0, 0, 0.58), inset 3px 0 0 #d8b24d;
}

.yw-inspection-guide-step {
  color: #d8b24d;
  font-size: 8px;
  font-weight: 850;
}

.yw-inspection-guide-title {
  font-family: "STSong", "Songti SC", "SimSun", serif;
  font-size: 15px;
}

.yw-inspection-guide-copy {
  margin: 0;
  color: rgba(242, 240, 230, 0.74);
  font-size: 10px;
  line-height: 1.55;
}

.yw-inspection-guide-confirm {
  min-height: 34px;
  margin-top: 6px;
  padding: 0 15px;
  border: 1px solid #e0ba59;
  border-radius: 2px;
  justify-self: end;
  color: #17271f;
  background: #dfbd61;
  font: inherit;
  font-size: 10px;
  font-weight: 850;
  cursor: pointer;
}

.is-inspection-guide-target {
  z-index: 30 !important;
  outline: 2px solid #f0ca6c !important;
  outline-offset: 5px;
  box-shadow: 0 0 0 7px rgba(226, 189, 98, 0.16), 0 0 24px rgba(226, 189, 98, 0.3) !important;
}

.yw-inspection-rotation.is-inspection-guide-target,
.yw-inspection-rotation button.is-inspection-guide-target,
.yw-inspection-finding.is-inspection-guide-target,
.yw-compare-orders.is-inspection-guide-target,
.yw-compare-result.is-inspection-guide-target {
  position: relative;
}

.yw-inspection-hotspot.is-inspection-guide-target,
.yw-inspection-rotation button.is-inspection-guide-target,
.yw-inspection-finding.is-inspection-guide-target,
.yw-compare-orders.is-inspection-guide-target {
  animation: yw-inspection-guide-pulse 1.4s ease-in-out infinite;
}

@keyframes yw-inspection-guide-pulse {
  50% { outline-color: #fff0a9; box-shadow: 0 0 0 10px rgba(226, 189, 98, 0.07), 0 0 27px rgba(226, 189, 98, 0.42); }
}

/* Private review ledger */
.yw-hub-journal {
  padding: 24px;
  background:
    linear-gradient(rgba(56, 75, 64, 0.09) 1px, transparent 1px) 0 0 / 100% 27px,
    #e4e0cd;
  color: #1b2821;
}

.yw-journal-summary {
  display: grid;
  grid-template-columns: 150px 150px minmax(0, 1fr);
  border-top: 2px solid #28392f;
  border-bottom: 1px solid #7e8b83;
}

.yw-journal-summary > span {
  min-height: 74px;
  padding: 12px 16px;
  display: grid;
  align-content: center;
  gap: 3px;
  border-right: 1px solid #a5aea8;
}

.yw-journal-summary small { color: #74622e; font-size: 8px; font-weight: 850; }
.yw-journal-summary strong { font-size: 25px; }
.yw-journal-summary p { align-self: center; margin: 0; padding: 12px 18px; color: #536159; font-size: 11px; line-height: 1.55; }

.yw-journal-list {
  margin: 22px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 18px;
  list-style: none;
}

.yw-journal-list li {
  min-width: 0;
  min-height: 72px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #9ba59e;
}

.yw-journal-list li > span {
  width: 28px;
  height: 28px;
  border: 1px solid #77847c;
  display: grid;
  place-items: center;
  color: #6e5a22;
  font-size: 9px;
  font-weight: 850;
}

.yw-journal-list p { min-width: 0; margin: 0; display: grid; gap: 3px; }
.yw-journal-list strong { font-size: 12px; }
.yw-journal-list small { color: #5f6d65; font-size: 9px; line-height: 1.45; white-space: normal; }
.yw-journal-list em { min-width: 48px; padding: 4px 6px; border: 1px solid; font-size: 8px; font-style: normal; font-weight: 850; text-align: center; }
.yw-journal-list .is-confirmed em { border-color: #3e7550; color: #2f6843; background: rgba(62, 117, 80, 0.1); }
.yw-journal-list .is-pending em { border-color: #9c7130; color: #815a22; border-style: dashed; }
.yw-journal-inspection-link { margin-top: 24px; color: #17271f; background: #d5b556; }

@media (max-width: 1000px) {
  .yw-hub-tools-shell { height: calc(100dvh - 32px); }
  .yw-inspection-workbench {
    align-items: start;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 12px;
  }
  .yw-inspection-stage { width: min(38vh, 320px); height: min(38vh, 320px); }
  .yw-paper-stack { transform: scale(0.88); transform-origin: center bottom; }
  .yw-inspection-records { align-content: center; }
}

@media (max-width: 760px) {
  .yw-opening-title { width: min(100%, 680px); }
  .yw-opening-title h1 { font-size: 82px; }
  .yw-opening-tagline { font-size: 17px; }
  .yw-opening-meta { width: 100%; }
  .yw-hub-entry { min-height: 66px; padding: 8px; grid-template-columns: 28px minmax(0, 1fr); gap: 7px; }
  .yw-hub-entry > svg { width: 28px; height: 28px; padding: 6px; }
  .yw-hub-entry strong { font-size: 12px; }
  .yw-hub-entry small { font-size: 7px; }
  .yw-story-review-list { grid-template-columns: 1fr; }
  .yw-story-review-status { align-items: flex-start; flex-direction: column; gap: 5px; }
  .yw-hub-entry em { font-size: 8px; }

  .yw-hub-tools { padding: 0; place-items: stretch; }
  .yw-hub-tools-shell { width: 100%; height: 100dvh; min-height: 0; border: 0; border-radius: 0; }
  .yw-hub-tools-header { min-height: 82px; padding: 14px 66px 13px 16px; }
  .yw-hub-tools-header h2 { font-size: 25px; }
  .yw-hub-tools-header span { overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
  .yw-hub-close { top: 18px; right: 16px; width: 42px; height: 42px; }
  .yw-hub-directory,
  .yw-hub-review { padding: 16px; }
  .yw-hub-level-list { grid-template-columns: 1fr; }
  .yw-hub-level { grid-template-columns: 34px minmax(0, 1fr) auto; }
  .yw-hub-level-result { min-width: 82px; }
  .yw-level-stamps i { width: 20px; height: 20px; font-size: 9px; }
  .yw-hub-directory-progress span { min-height: 58px; padding: 9px; }
  .yw-hub-directory-progress strong { font-size: 14px; }

  .yw-hub-inspection { background-position: 42% center; }
  .yw-inspection-workbench {
    min-height: 100%;
    padding: 66px 12px calc(18px + env(safe-area-inset-bottom));
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 20px;
  }
  .yw-inspection-stage-column { gap: 8px; }
  .yw-inspection-stage { width: min(78vw, 330px); height: min(78vw, 330px); min-width: 230px; min-height: 230px; }
  .yw-inspection-finding { min-height: 78px; }
  .yw-inspection-records { width: 100%; padding-top: 8px; }
  .yw-inspection-case-tabs { top: 10px; left: 12px; right: 12px; }
  .yw-inspection-case-tabs button { min-width: 0; flex: 1 1 0; }
  .yw-paper-stack,
  .yw-paper-stack[data-mode="compare"] { width: min(100%, 390px); height: 354px; transform: none; }
  .yw-paper-stack[data-mode="compare"] { height: 692px; }
  .yw-paper-stack[data-mode="compare"] .yw-task-paper { width: min(272px, calc(100vw - 58px)); height: 330px; }
  .yw-paper-stack[data-mode="compare"] .yw-task-paper-old { top: 0; left: 50%; transform: translateX(-50%); }
  .yw-paper-stack[data-mode="compare"] .yw-task-paper-new { top: 346px; right: auto; left: 50%; transform: translateX(-50%); }
  .yw-journal-summary { grid-template-columns: 1fr 1fr; }
  .yw-journal-summary p { grid-column: 1 / -1; border-top: 1px solid #a5aea8; }
  .yw-journal-list { grid-template-columns: 1fr; gap: 4px; }
}

@media (max-width: 640px) {
  .yw-deduction { padding: 12px; }
  .yw-deduction__panel { padding: 22px 16px; }
  .yw-deduction__options button { min-height: 54px; padding: 9px 10px; grid-template-columns: 28px minmax(0, 1fr); gap: 9px; }
  .yw-opening-title {
    padding-bottom: 22px;
  }
  .yw-opening-title h1 {
    font-size: 64px;
  }
  .yw-opening-tagline {
    margin-top: 14px;
    font-size: 15px;
  }
  .yw-opening-meta {
    gap: 5px;
    margin-top: 15px;
    padding: 8px 0;
  }
  .yw-hub-entry {
    min-height: 58px;
    padding: 6px;
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    text-align: center;
  }
  .yw-hub-entry > svg { width: 24px; height: 24px; padding: 5px; }
  .yw-hub-entry > span { justify-items: center; }
  .yw-hub-entry small,
  .yw-hub-entry em { display: none; }
  .yw-hub-entry strong { font-size: 11px; }
  .yw-opening-actions { margin-top: 14px; }
  .yw-opening-primary { min-width: 210px !important; min-height: 58px !important; padding: 5px 14px 5px 7px !important; }
  .yw-opening-primary-instrument { width: 44px; height: 44px; }
  .yw-opening-primary-copy strong { font-size: 13px; }
  .yw-opening-secondary { min-height: 48px; }
  .yw-journal-summary > span { min-height: 62px; }
  .yw-journal-list li { grid-template-columns: 28px minmax(0, 1fr); }
  .yw-journal-list em { grid-column: 2; justify-self: start; }
}

@media (max-height: 620px) and (orientation: landscape) {
  .yw-opening-title { width: 700px; }
  .yw-opening-title h1 { font-size: 68px; }
  .yw-opening-tagline { margin-top: 10px; font-size: 14px; }
  .yw-opening-meta { margin-top: 11px; padding: 6px 0; }
  .yw-hub-entry { min-height: 54px; padding-top: 5px; padding-bottom: 5px; }
  .yw-opening-actions { margin-top: 10px; }
  .yw-opening-primary { min-height: 54px; }
  .yw-opening-primary-instrument { width: 40px; height: 40px; }
  .yw-hub-tools { padding: 0; }
  .yw-hub-tools-shell { width: 100%; height: 100dvh; min-height: 0; border: 0; }
  .yw-hub-tools-header { min-height: 68px; padding-top: 9px; padding-bottom: 9px; }
  .yw-hub-tools-header h2 { font-size: 22px; }
  .yw-hub-close { top: 12px; }
  .yw-inspection-workbench { grid-template-columns: minmax(0, 1fr) 340px; padding: 58px 18px 10px; }
  .yw-inspection-stage { width: 230px; height: 230px; min-width: 0; min-height: 0; }
  .yw-inspection-finding { min-height: 60px; padding: 8px 12px; }
  .yw-paper-stack { height: 285px; transform: scale(0.72); }
  .yw-paper-stack[data-mode="compare"] { width: 540px; height: 285px; transform: scale(0.72); }
  .yw-compare-result { min-height: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .yw-hub-tools,
  .yw-inspection-hotspot,
  .yw-opening-primary-instrument::before {
    animation: none !important;
  }

  .yw-inspection-stage > img,
  .yw-task-paper,
  .yw-hub-entry,
  .yw-opening-primary,
  .yw-splash__start {
    transition-duration: 1ms !important;
  }

  .yw-inspection-hotspot.is-inspection-guide-target,
  .yw-inspection-rotation button.is-inspection-guide-target,
  .yw-inspection-finding.is-inspection-guide-target,
  .yw-compare-orders.is-inspection-guide-target {
    animation: none !important;
  }
}

/* A permanent route-breakthrough mark must survive active and hover states. */
.yw-hub-level.is-route-breakthrough,
.yw-hub-level.is-route-breakthrough:hover,
.yw-hub-level.is-route-breakthrough:focus-visible,
.yw-hub-level.is-route-breakthrough.is-active {
  border: 2px solid #d2a126;
  box-shadow:
    inset 0 0 0 2px rgba(255, 235, 164, 0.16),
    inset 4px 0 0 #d2a126,
    0 0 12px rgba(226, 189, 98, 0.32);
}

.yw-resource-preparation[hidden] {
  display: none !important;
}

.yw-resource-preparation {
  position: fixed;
  z-index: 13000;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #eff2eb;
  background: rgba(5, 12, 9, 0.82);
  backdrop-filter: blur(5px);
}

.yw-resource-preparation__panel {
  width: min(420px, 100%);
  padding: 30px 32px 28px;
  border: 1px solid rgba(186, 161, 91, 0.56);
  border-radius: 6px;
  background: #16211c;
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.42);
  text-align: center;
}

.yw-resource-preparation__panel:focus {
  outline: none;
}

.yw-resource-preparation__spinner {
  width: 30px;
  height: 30px;
  margin: 0 auto 18px;
  display: block;
  border: 2px solid rgba(226, 188, 85, 0.22);
  border-top-color: #e2bc55;
  border-radius: 50%;
  animation: yw-resource-spin 0.9s linear infinite;
}

.yw-resource-preparation__panel > p {
  margin: 0 0 8px;
  color: #c9a957;
  font: 600 10px/1.4 "Segoe UI", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

.yw-resource-preparation__panel h2 {
  margin: 0;
  font: 600 26px/1.25 "STSong", "Songti SC", "SimSun", serif;
  letter-spacing: 0;
}

.yw-resource-preparation__track {
  position: relative;
  height: 2px;
  margin: 22px 0 17px;
  display: block;
  overflow: hidden;
  background: rgba(229, 231, 223, 0.14);
}

.yw-resource-preparation__track i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 42%;
  background: #d4b45e;
  animation: yw-resource-scan 1.35s ease-in-out infinite;
}

.yw-resource-preparation__panel small {
  display: block;
  color: rgba(239, 242, 235, 0.72);
  font-size: 12px;
  line-height: 1.7;
}

.yw-resource-preparation__actions {
  margin-top: 22px;
  display: flex;
  justify-content: center;
  gap: 10px;
}

.yw-resource-preparation__actions[hidden] {
  display: none !important;
}

.yw-resource-preparation__actions button {
  min-height: 40px;
  padding: 0 18px;
  border: 1px solid rgba(226, 188, 85, 0.64);
  border-radius: 4px;
  color: #f4f0df;
  background: rgba(226, 188, 85, 0.12);
  cursor: pointer;
}

.yw-resource-preparation__actions button:last-child {
  border-color: rgba(239, 242, 235, 0.24);
  background: transparent;
}

.yw-resource-preparation[data-state="error"] .yw-resource-preparation__spinner {
  border-color: #b65d4d;
  animation: none;
}

.yw-resource-preparation[data-state="error"] .yw-resource-preparation__track {
  display: none;
}

@keyframes yw-resource-spin {
  to { transform: rotate(360deg); }
}

@keyframes yw-resource-scan {
  0% { transform: translateX(-110%); }
  55%, 100% { transform: translateX(350%); }
}

@media (prefers-reduced-motion: reduce) {
  .yw-resource-preparation__spinner,
  .yw-resource-preparation__track i {
    animation-duration: 3s;
  }
}
