:root {
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  color: #ecdfc4;
  background: #0c1718;
  font-synthesis: none;
  --gold: #d7b87b;
  --paper: #eee4cc;
  --ink: #23342f;
  --teal: #203d38;
  --line: #c1a36a59;
  --muted: #a6b5a4;
  --serif: "Songti SC", "STSong", "Noto Serif CJK SC", serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-width: 320px;
}
button,
input {
  font: inherit;
}
button {
  color: inherit;
  cursor: pointer;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #2a453d;
  transition:
    background 0.16s,
    border-color 0.16s,
    transform 0.16s;
}
button:hover:not(:disabled) {
  background: #3d5c4c;
  border-color: #e6cc90;
}
button:active:not(:disabled) {
  transform: translateY(1px);
}
button:disabled {
  opacity: 0.42;
  cursor: default;
}
button:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid #e9c67f;
  outline-offset: 3px;
}
button[hidden],
[hidden] {
  display: none !important;
}
button.primary {
  background: linear-gradient(135deg, #e9cd91, #c6a267);
  color: #26392f;
  border: 1px solid #ffe7aa;
  font-weight: 650;
  box-shadow: 0 3px 13px #081a1540;
  padding: 12px 24px;
}
button.primary:hover:not(:disabled) {
  background: linear-gradient(135deg, #f9e0a9, #d3b578);
}
button.secondary {
  padding: 10px 16px;
  background: #234339;
  color: #eee2c3;
}
button.quiet {
  background: transparent;
  border-color: transparent;
  padding: 9px 13px;
  color: #bdc7b2;
}
button.quiet:hover {
  background: #d6bd7a10;
}
button.text-button {
  border: 0;
  background: none;
  color: #efd19b;
  font-size: 13px;
  padding: 5px 0;
  text-align: left;
}
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gold);
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: var(--serif);
}
small {
  font-size: 11px;
}
p {
  line-height: 1.8;
}
.muted {
  color: #a9b4a2;
  font-size: 12px;
  line-height: 1.8;
}
.loading,
.load-error {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
}
.loading h1 {
  font-size: 42px;
  letter-spacing: 7px;
}
.loading p {
  color: #b0bba5;
  font-size: 13px;
}
.seal,
.mini-seal {
  display: grid;
  place-items: center;
  background: #a84c35;
  color: #f5ddae;
  border: 1px solid #d18a62;
  font-family: var(--serif);
  transform: rotate(-4deg);
}
.seal {
  width: 56px;
  height: 56px;
  font-size: 34px;
}
.title-screen {
  min-height: 100svh;
  position: relative;
  overflow: hidden;
  background: #233d2f;
}
.title-scenery,
.title-vignette {
  position: absolute;
  inset: 0;
}
.title-scenery {
  background: url("/art/summit.webp") center/cover;
  transform: scale(1.06);
  animation: scene-reveal 3s ease-out both;
}
.title-vignette {
  background:
    linear-gradient(90deg, #0a2323f2 0%, #132d2ac7 35%, #153b2630 70%),
    linear-gradient(0deg, #0a1c1cee, transparent 45%, #102d2d55);
}
.title-top {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px 5vw;
  color: #c5cdb5;
  font-size: 11px;
  letter-spacing: 3px;
}
.title-copy {
  position: relative;
  z-index: 2;
  margin: 7vh 0 10vh 12vw;
  max-width: 480px;
  animation: rise-in 0.9s ease-out both;
}
.title-copy > .eyebrow {
  font-size: 13px;
  letter-spacing: 6px;
}
.title-copy h1 {
  font-size: clamp(56px, 6.8vw, 100px);
  font-weight: 800;
  letter-spacing: 6px;
  line-height: 1.1;
  margin: 25px 0 14px;
  color: #f6e6bb;
  text-shadow:
    2px 4px 0 #274638,
    0 12px 40px #001e1e;
}
.title-copy h1 span {
  display: block;
  margin-left: 30px;
}
.title-sub {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 30px 0;
  color: #e3c68a;
  font-family: var(--serif);
  font-size: 22px;
  letter-spacing: 8px;
}
.title-sub i {
  width: 35px;
  height: 1px;
  background: #d4ae6c;
}
.title-poem {
  font-family: var(--serif);
  font-size: 16px;
  letter-spacing: 3px;
  color: #d5ddbf;
  line-height: 2.2;
}
.title-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin-top: 40px;
}
.title-button {
  display: flex;
  justify-content: space-between;
  gap: 45px;
  align-items: center;
  width: 330px;
  text-align: left;
  font-size: 18px !important;
  padding: 17px 24px !important;
  font-family: var(--serif);
}
.title-button span {
  font-size: 11px;
  font-family: system-ui;
  font-weight: 400;
}
.continue-hint {
  font-size: 11px;
  color: #b0c1a8;
  margin-top: 14px;
}
.title-actors {
  position: absolute;
  width: 48vw;
  right: 5vw;
  bottom: 10vh;
  height: 65vh;
  pointer-events: none;
  filter: drop-shadow(0 20px 13px #08282260);
}
.portrait {
  object-fit: contain;
  user-select: none;
}
.title-actors .portrait {
  position: absolute;
  object-fit: contain;
  image-rendering: auto;
}
.hero-one {
  width: 26vw;
  height: 49vh;
  left: 8vw;
  bottom: 0;
  z-index: 2;
}
.hero-two {
  width: 20vw;
  height: 40vh;
  right: -1vw;
  bottom: 4vh;
  z-index: 3;
  transform: rotate(3deg);
}
.hero-three {
  width: 18vw;
  height: 37vh;
  left: -3vw;
  bottom: 9vh;
  opacity: 0.9;
}
.title-footer {
  position: absolute;
  bottom: 0;
  padding: 28px 5vw;
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-size: 10px;
  letter-spacing: 2px;
  color: #bac6ab;
}
.game-shell {
  max-width: 1440px;
  min-height: 100svh;
  margin: auto;
  background: #142725;
  box-shadow: 0 0 120px #0008;
}
.topbar {
  height: 76px;
  display: flex;
  align-items: center;
  padding: 0 30px;
  gap: 28px;
  border-bottom: 1px solid #bda37252;
  background: linear-gradient(180deg, #203732, #162b28);
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  background: none;
  border: 0;
  padding: 0;
  text-align: left;
  white-space: nowrap;
}
.brand > span:last-child {
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: 2px;
  color: #f0dbad;
}
.brand small {
  display: block;
  font: 9px system-ui;
  letter-spacing: 6px;
  margin-top: 4px;
  color: #bcbd9d;
}
.mini-seal {
  width: 35px;
  height: 39px;
  font-size: 25px;
}
.player-info {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 115px;
}
.player-info b {
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 500;
}
.player-info span {
  font-size: 10px;
  color: #b9bea1;
}
.resources {
  display: flex;
  gap: 28px;
  margin-left: auto;
}
.resources > span {
  display: grid;
  grid-template-columns: auto auto;
  column-gap: 8px;
  align-items: center;
}
.resources i {
  grid-row: span 2;
  font-style: normal;
  color: #e1c287;
  font-size: 23px;
}
.resources b {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.5px;
}
.resources small {
  color: #9ead99;
  font-size: 9px;
  margin-top: 2px;
}
.top-actions {
  display: flex;
  gap: 8px;
  align-items: center;
}
.top-actions button {
  background: #152c29;
  width: 31px;
  height: 31px;
  font-size: 17px;
  color: #c6c9af;
  border-color: #8d9e7750;
}
.top-actions button.on {
  color: #f1d196;
  border-color: #d7b87b;
}
.top-actions > span {
  font-size: 9px;
  color: #91b09b;
  margin-right: 6px;
}
.stage-wrap {
  position: relative;
  overflow: hidden;
  background: #2a4438;
  isolation: isolate;
}
.stage-wrap canvas {
  display: block;
  width: 100%;
  aspect-ratio: 1000/640;
  outline: none;
  max-height: calc(100svh - 235px);
  object-fit: contain;
  background: #233c30;
}
.scene-heading {
  position: absolute;
  z-index: 1;
  top: 22px;
  left: 30px;
  right: 30px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  pointer-events: none;
  text-shadow: 0 2px 9px #082b25;
}
.scene-heading h2 {
  font-size: 27px;
  letter-spacing: 5px;
  margin-top: 5px;
  color: #fff0c7;
}
.scene-heading .eyebrow {
  font-size: 9px;
  color: #e6d8ae;
}
.scene-heading > p {
  font-family: var(--serif);
  font-size: 12px;
  letter-spacing: 2px;
  margin-top: 10px;
  color: #e4dfc2;
}
.objective {
  position: absolute;
  left: 28px;
  top: 112px;
  width: 200px;
  padding: 18px;
  background: linear-gradient(135deg, #15332ce8, #12322bb8);
  border-left: 2px solid #d0ac70;
  box-shadow: 0 8px 25px #0a2a1720;
  z-index: 1;
}
.objective .eyebrow {
  font-size: 9px;
}
.objective h3 {
  font-size: 16px;
  margin: 9px 0;
  color: #f5ddb0;
  letter-spacing: 2px;
}
.objective p {
  font-size: 11px;
  color: #d1d9b9;
  margin: 6px 0 8px;
  line-height: 1.9;
}
.objective > small {
  font-size: 9px;
  color: #bbc7ad;
  line-height: 1.7;
  display: block;
}
.quest-ready {
  display: block;
  background: none;
  border: 0;
  color: #d9de9b;
  font-size: 10px;
  padding: 8px 0 0;
}
.scene-controls {
  position: absolute;
  right: 24px;
  bottom: 24px;
  z-index: 1;
  display: flex;
  gap: 8px;
}
.scene-button {
  background: #12342be8;
  padding: 8px 13px;
  color: #f2ddb4;
  font-size: 11px;
  border-color: #d7b87b80;
}
.scene-button.subtle {
  background: #152d2caa;
  color: #d9c9b5;
}
.world-hint {
  position: absolute;
  left: 28px;
  bottom: 27px;
  font-size: 10px;
  letter-spacing: 1px;
  color: #f8e9bd;
  text-shadow: 0 1px 4px #173827;
}
.battle-side {
  position: absolute;
  right: 25px;
  top: 110px;
  width: 155px;
  pointer-events: none;
  background: #102d2980;
  padding: 12px;
  border-top: 1px solid #c3b27d60;
}
.battle-side p {
  font-size: 9px;
  color: #e0dcc0;
  line-height: 1.8;
  margin-top: 8px;
}
.battle-side .eyebrow {
  font-size: 8px;
}
.battle-pause {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: #0e262b42;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  backdrop-filter: none;
  pointer-events: none;
}
.battle-pause p {
  font-size: 12px;
  margin-top: 14px;
  text-shadow: 0 2px 4px #132727;
}
.party-strip {
  display: flex;
  justify-content: center;
  gap: 1px;
  position: relative;
  background: linear-gradient(180deg, #1a3630, #152c28);
  min-height: 76px;
  border-top: 1px solid #c4a06566;
  border-bottom: 1px solid #c4a06522;
  padding: 0 16px;
}
.party-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: none;
  border: 0;
  border-radius: 0;
  padding: 7px 20px;
  max-width: 250px;
  flex: 1;
  position: relative;
}
.party-hero:after {
  content: "";
  position: absolute;
  right: 0;
  height: 35px;
  width: 1px;
  background: #e4c79220;
}
.party-hero > .portrait {
  width: 44px;
  height: 64px;
  object-position: center 18%;
}
.party-hero > div {
  min-width: 100px;
  text-align: left;
}
.party-name {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-family: var(--serif);
  font-size: 14px;
}
.party-name small {
  font: 10px system-ui;
  color: #ccba93;
}
.party-role {
  display: block;
  font-size: 9px;
  color: #b6c0a6;
  margin-top: 5px;
}
.tiny-bar {
  display: block;
  height: 3px;
  background: #0d2522;
  margin-top: 7px;
  width: 100%;
}
.tiny-bar i {
  display: block;
  height: 100%;
  background: #9fc48c;
  transition: width 0.3s;
}
.fallen {
  filter: grayscale(1);
  opacity: 0.5;
}
.party-empty {
  background: none;
  border: 1px dashed #aeb99450;
  max-width: 180px;
  align-self: center;
  height: 52px;
  flex: 1;
  font-size: 19px;
  min-width: 90px;
}
.party-empty small {
  display: block;
  font-size: 9px;
  margin-top: 5px;
  color: #afbaa4;
}
.command-strip {
  display: flex;
  justify-content: center;
  gap: 25px;
  align-items: center;
  background: #142d28;
  padding: 10px 20px;
  border-bottom: 1px solid #b9a06c40;
}
.tactic-resource {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 140px;
}
.tactic-resource > span {
  font-size: 10px;
  color: #c8c5aa;
}
.tactic-resource > b {
  font-size: 17px;
  color: #e8c57f;
  letter-spacing: 5px;
}
.tactic-resource > small {
  font-size: 9px;
  color: #a6b59c;
}
.command-buttons {
  display: flex;
  gap: 8px;
}
.command-buttons > button {
  position: relative;
  padding: 9px 28px 9px 34px;
  text-align: left;
  min-width: 125px;
  background: linear-gradient(145deg, #304c3b, #203b30);
}
.command-buttons b {
  display: block;
  font-family: var(--serif);
  font-size: 15px;
  color: #f1dbaf;
}
.command-buttons small {
  display: block;
  font-size: 8px;
  margin-top: 4px;
  color: #b9c3a4;
}
.command-buttons em {
  font-size: 8px;
  font-style: normal;
  color: #e4c57d;
  position: absolute;
  right: 7px;
  top: 8px;
}
.command-buttons kbd {
  position: absolute;
  left: 9px;
  top: 12px;
  border: 1px solid #c8b88370;
  color: #d9cca4;
  padding: 2px 4px;
  font-size: 9px;
  border-radius: 2px;
}
.bottom-nav {
  display: flex;
  justify-content: center;
  gap: 5px;
  padding: 11px 20px;
  background: linear-gradient(180deg, #1c352f, #172d28);
}
.nav-button {
  display: flex;
  align-items: center;
  gap: 9px;
  background: transparent;
  border-color: transparent;
  padding: 9px 18px;
  font-size: 11px;
  color: #c1c8af;
  white-space: nowrap;
}
.nav-button > span {
  font-family: var(--serif);
  font-size: 18px;
  color: #d0b47c;
}
.nav-button.active {
  border-color: #c4a06555;
  background: #d8c2860a;
  color: #f2ddb1;
}
.game-footer {
  font-size: 9px;
  display: flex;
  justify-content: space-between;
  padding: 0 25px 12px;
  color: #8fa38c;
  letter-spacing: 0.5px;
}
dialog {
  border: 1px solid #bca16b7a;
  border-radius: 9px;
  background: linear-gradient(135deg, #234038, #142e29);
  color: #e9dfc5;
  padding: 0;
  width: min(640px, calc(100vw - 32px));
  max-height: calc(100svh - 48px);
  box-shadow: 0 22px 90px #061819a6;
  overflow: hidden;
}
dialog.wide {
  width: min(950px, calc(100vw - 32px));
}
dialog[open] {
  display: flex;
  flex-direction: column;
  animation: rise-in 0.2s ease-out;
}
dialog::backdrop {
  background: #051d20b3;
  backdrop-filter: blur(5px);
}
.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #d6b77c40;
  padding: 20px 27px;
  background: linear-gradient(90deg, #d1b97c0c, transparent);
  flex: none;
}
.modal-head .eyebrow {
  font-size: 8px;
  letter-spacing: 3px;
}
.modal-head h2 {
  font-size: 24px;
  letter-spacing: 3px;
  margin-top: 4px;
  color: #f3dfb5;
  font-weight: 600;
}
.close-button {
  border: 0;
  background: none;
  width: 32px;
  height: 32px;
  color: #c6cbb2;
  font-size: 27px;
}
.modal-body {
  padding: 24px 28px;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #8b8e6580 transparent;
}
.modal-foot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 28px;
  border-top: 1px solid #c2a77140;
  flex: none;
  background: #0b272222;
}
.intro-text {
  font-size: 12px;
  color: #c4d0b6;
  line-height: 1.95;
  margin-bottom: 20px;
}
.story-text {
  font-family: var(--serif);
  font-size: 16px;
  line-height: 2;
  letter-spacing: 0.5px;
  color: #e7dfc2;
  margin: 13px 0 22px;
}
.field-label {
  display: block;
  color: #d4caab;
  font-size: 12px;
  margin: 22px 0;
}
.field-label input {
  display: block;
  width: 100%;
  margin-top: 9px;
  border: 1px solid #a594675f;
  background: #112d27;
  padding: 13px;
  color: #f4e5be;
  border-radius: 4px;
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 2px;
}
.difficulty {
  display: flex;
  gap: 10px;
  border: 0;
  margin: 0;
  padding: 0;
}
.difficulty legend {
  font-size: 12px;
  color: #c2c4a4;
  margin-bottom: 10px;
}
.difficulty label {
  position: relative;
  flex: 1;
  padding: 16px 10px;
  background: #0c2a253d;
  border: 1px solid #b6a06b45;
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
}
.difficulty input {
  position: absolute;
  top: 8px;
  right: 8px;
  accent-color: #d6bc83;
  width: 12px;
  height: 12px;
}
.difficulty label:has(input:checked) {
  border-color: #d6bc83;
  background: #d6bc8312;
}
.difficulty b {
  display: block;
  font: 20px var(--serif);
  color: #e4d1a7;
}
.difficulty span {
  display: block;
  font-size: 9px;
  color: #afbfa6;
  margin-top: 9px;
}
.notice {
  font-size: 11px;
  color: #e6c291;
  padding: 12px;
  background: #dca5570a;
  border-left: 2px solid #dca557;
  margin-top: 20px;
}
.tutorial-art {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 22px;
  height: 145px;
  margin-bottom: 20px;
}
.tutorial-art img {
  width: 90px;
  max-height: 145px;
  filter: drop-shadow(0 7px 8px #001e1b66);
}
.tutorial-steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 20px;
}
.tutorial-steps p {
  display: flex;
  gap: 18px;
}
.tutorial-steps b {
  font-family: var(--serif);
  font-size: 15px;
  min-width: 100px;
  color: #e4cb94;
}
.tutorial-steps span {
  font-size: 11px;
  color: #c4ceb2;
}
.campaign-scroll {
  margin: 12px -4px;
}
.chapter-section {
  margin-bottom: 30px;
  border-bottom: 1px solid #baa06d30;
  padding: 0 0 25px;
}
.chapter-section:last-child {
  border: 0;
  margin-bottom: 0;
  padding-bottom: 0;
}
.chapter-title {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
}
.chapter-title > span {
  font-size: 9px;
  color: #e6c98e;
  border: 1px solid #bea56c66;
  padding: 5px;
}
.chapter-title h3 {
  font-size: 20px;
  letter-spacing: 3px;
  color: #e5d6ae;
}
.chapter-title p {
  font-size: 10px;
  margin-left: auto;
  color: #9fb59d;
}
.stage-path {
  display: flex;
  justify-content: space-around;
  gap: 8px;
  position: relative;
}
.stage-path:before {
  content: "";
  position: absolute;
  height: 1px;
  background: linear-gradient(90deg, transparent, #bcaa7766, transparent);
  top: 31px;
  left: 8%;
  right: 8%;
  z-index: 0;
}
.stage-node {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: transparent;
  border: 0;
  min-width: 120px;
  padding: 0 10px;
}
.stage-node:hover:not(:disabled) {
  background: none;
}
.node-emblem {
  font-family: var(--serif);
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  background: #15342c;
  border: 1px solid #b69b6155;
  border-radius: 50%;
  font-size: 23px;
  color: #afbc9d;
  box-shadow:
    inset 0 0 0 5px #16312a,
    inset 0 0 0 6px #80926b30;
  transition: transform 0.2s;
}
.stage-node:hover:not(:disabled) .node-emblem {
  transform: translateY(-4px);
}
.stage-node b {
  font: 14px var(--serif);
  margin-top: 12px;
  color: #d0d4b5;
  letter-spacing: 1px;
}
.stage-node small {
  font-size: 9px;
  margin-top: 6px;
  color: #95ae97;
}
.stage-node.cleared .node-emblem {
  color: #bbd6b5;
  background: #365540;
  border-color: #7ba37b;
}
.stage-node.current .node-emblem {
  background: radial-gradient(#d8bd7a, #ae8c52);
  color: #22392e;
  border-color: #f2dda2;
  box-shadow:
    0 0 24px #d8bd7a30,
    inset 0 0 0 5px #d4b77d,
    inset 0 0 0 6px #f6e1ac90;
}
.stage-node.current b,
.stage-node.current small {
  color: #efd59e;
}
.stage-node.boss .node-emblem {
  border-radius: 9px;
  transform: rotate(-5deg);
}
.stage-preview {
  height: 190px;
  position: relative;
  background-size: cover;
  background-position: center 52%;
  margin: -24px -28px 20px;
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  isolation: isolate;
  border-bottom: 1px solid #c7b07b50;
}
.stage-preview:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #102f28ef, transparent);
  z-index: -1;
}
.stage-preview > span {
  font-size: 11px;
  color: #d5d7b7;
  letter-spacing: 2px;
}
.stage-preview h3 {
  font: 26px var(--serif);
  letter-spacing: 3px;
  color: #f4dfad;
  margin-top: 10px;
}
.boss-mark {
  position: absolute;
  right: 30px;
  top: 25px;
  color: #f3cead;
  font: 16px var(--serif);
  letter-spacing: 3px;
  padding: 8px 10px;
  background: #873d2b99;
  border: 1px solid #dc986377;
  transform: rotate(3deg);
}
.encounter-enemies {
  display: flex;
  justify-content: space-evenly;
  gap: 12px;
  margin-bottom: 20px;
}
.encounter-enemies > div {
  display: flex;
  align-items: center;
  gap: 8px;
}
.encounter-enemies .portrait {
  height: 73px;
  width: 60px;
}
.encounter-enemies span {
  font-size: 11px;
}
.encounter-enemies small {
  display: block;
  color: #c4c3a2;
  margin-top: 5px;
}
.reward-preview {
  display: flex;
  gap: 20px;
  padding: 15px 0;
  border-block: 1px solid #b7a16b40;
  font-size: 12px;
  color: #dfd1ab;
  line-height: 1.9;
}
.reward-preview b {
  font-family: var(--serif);
  color: #d7be85;
  white-space: nowrap;
}
.reward-preview span {
  font-size: 11px;
}
.tip {
  padding: 14px 15px;
  background: #d3bb7610;
  color: #c9d5af;
  font-size: 11px;
  line-height: 1.9;
  border-radius: 3px;
  margin: 18px 0;
}
.story-scene {
  height: 330px;
  display: flex;
  align-items: flex-end;
  gap: 20px;
  background-size: cover;
  background-position: center;
  isolation: isolate;
  position: relative;
  margin: -24px -28px 0;
  padding: 25px 32px 30px;
}
.story-scene:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #163e2cdd, transparent);
  z-index: -1;
}
.story-scene > .portrait {
  height: 245px;
  width: 200px;
  filter: drop-shadow(0 10px 12px #0e2a2066);
}
.story-seal {
  font: 55px var(--serif);
  line-height: 1.3;
  color: #ffe4ad66;
  width: 150px;
  text-align: center;
  flex: none;
}
.story-bubble {
  padding: 22px 24px;
  background: #102e28e8;
  border: 1px solid #c8ab7259;
  border-radius: 5px;
  flex: 1;
  min-height: 130px;
}
.story-bubble > b {
  display: block;
  font: 18px var(--serif);
  color: #e1c895;
  letter-spacing: 2px;
  margin-bottom: 10px;
}
.story-bubble p {
  font: 17px/2 var(--serif);
  color: #f2e8cb;
  letter-spacing: 1px;
}
.story-progress {
  display: flex;
  gap: 5px;
  justify-content: center;
  padding-top: 17px;
}
.story-progress i {
  width: 18px;
  height: 3px;
  background: #8ba17b44;
}
.story-progress i.lit {
  background: #d4bc83;
}
.hero-layout {
  display: grid;
  grid-template-columns: 175px 1fr;
  gap: 28px;
}
.hero-list {
  border-right: 1px solid #b3a37133;
  padding-right: 18px;
  max-height: min(560px, max(120px, calc(100dvh - 300px)));
  overflow-y: auto;
  overscroll-behavior-y: contain;
  align-self: start;
}
.hero-tab {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  background: none;
  margin-bottom: 5px;
  padding: 5px 8px;
  text-align: left;
}
.hero-tab.selected {
  border-color: #ceb47870;
  background: #c9b1770d;
}
.hero-tab .portrait {
  width: 35px;
  height: 49px;
}
.hero-tab b {
  font-family: var(--serif);
  font-size: 14px;
}
.hero-tab small {
  display: block;
  font-size: 9px;
  color: #adbd9f;
  margin-top: 5px;
}
.hero-list > .muted {
  font-size: 9px;
  margin-top: 20px;
}
.hero-showcase {
  display: flex;
  align-items: center;
  gap: 28px;
  min-height: 160px;
}
.hero-showcase > .portrait {
  width: 120px;
  height: 175px;
  filter: drop-shadow(0 8px 12px #09291e90);
}
.hero-showcase > div {
  flex: 1;
}
.hero-showcase h3 {
  font-size: 30px;
  letter-spacing: 3px;
  color: #f6dfab;
  margin: 8px 0 10px;
}
.hero-showcase h3 small {
  font: 12px system-ui;
  margin-left: 12px;
  color: #d7bd88;
  letter-spacing: 0;
}
.hero-showcase p {
  font-size: 11px;
  color: #b9c8aa;
  margin-bottom: 12px;
}
.hero-showcase small {
  font-size: 9px;
  color: #9fb79a;
}
.xp-bar {
  height: 3px;
  background: #0b2821;
  max-width: 220px;
  margin-bottom: 7px;
}
.xp-bar i {
  display: block;
  height: 3px;
  background: #c5b178;
}
.stats-row {
  display: flex;
  justify-content: space-around;
  padding: 16px 0;
  margin-top: 10px;
  border-block: 1px solid #c7ad7633;
}
.stats-row > span {
  display: flex;
  flex-direction: column;
  text-align: center;
  gap: 7px;
}
.stats-row small {
  font-size: 10px;
  color: #aabd9e;
}
.stats-row b {
  font-size: 20px;
  font-weight: 400;
  color: #efdfb4;
}
.skill-description {
  padding: 18px 0;
}
.skill-description b {
  font: 16px var(--serif);
  color: #dbc18b;
}
.skill-description p {
  font-size: 11px;
  color: #b5c7a6;
  margin-top: 7px;
}
.equipment-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.equipment-slots button {
  padding: 12px 9px;
  text-align: left;
  background: #102e2766;
}
.equipment-slots small {
  display: block;
  font-size: 9px;
  color: #97af91;
}
.equipment-slots b {
  display: block;
  font: 13px var(--serif);
  color: #e4d5ad;
  margin: 8px 0;
}
.equipment-slots span {
  font-size: 9px;
  line-height: 1.7;
  color: #9fba96;
  display: block;
}
.hero-actions {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-top: 16px;
}
.hero-actions span {
  font-size: 10px;
  color: #97af91;
}
.hero-actions button {
  font-size: 11px;
}
.formation-section {
  margin-top: 24px;
  border-top: 1px solid #c4a77533;
  padding-top: 22px;
}
.formation-section h3 {
  font-size: 16px;
  color: #dbc38f;
  letter-spacing: 2px;
}
.formation-section h3 small {
  font: 9px system-ui;
  letter-spacing: 0;
  color: #9db293;
  margin-left: 10px;
}
.formation-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 9px;
  margin-top: 15px;
}
.formation-options > button {
  padding: 13px 11px;
  background: #112e26;
  text-align: left;
}
.formation-options > button.selected {
  background: #c7ac6e12;
  border-color: #dbbf7e;
}
.formation-options b {
  font: 15px var(--serif);
  color: #dece9f;
}
.formation-options small {
  display: block;
  color: #a6bc9a;
  font-size: 9px;
  line-height: 1.8;
  margin-top: 7px;
}
.modal-resources {
  font-size: 11px;
  color: #a9bfa0;
  padding: 0 0 15px;
}
.modal-resources b {
  color: #e5cb91;
  font-weight: 400;
}
.item-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.item-row {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 14px 16px;
  background: #0c292260;
  border: 1px solid #a3945e3a;
  border-radius: 4px;
}
.item-icon {
  width: 44px;
  height: 47px;
  background: linear-gradient(135deg, #4a6244, #294b34);
  border: 1px solid #839c5f99;
  display: grid;
  place-items: center;
  font: 25px var(--serif);
  color: #d9d7a2;
  flex: none;
  border-radius: 5px;
}
.rarity-2 .item-icon {
  background: linear-gradient(135deg, #426571, #213d51);
  border-color: #92b5cd88;
  color: #c2e3df;
}
.rarity-3 .item-icon {
  background: linear-gradient(135deg, #7c6136, #4d3824);
  border-color: #e0b868;
  color: #ffe3a1;
}
.item-row > div {
  flex: 1;
}
.item-row h3 {
  font-size: 15px;
  letter-spacing: 1px;
  color: #e6d8ad;
}
.item-row h3 small {
  font: 9px system-ui;
  color: #a4b99b;
  letter-spacing: 0;
  margin-left: 10px;
}
.item-row p {
  font-size: 11px;
  color: #beccaa;
  margin-top: 6px;
}
.item-row div > small {
  font-size: 9px;
  display: block;
  color: #92ac8e;
  margin-top: 5px;
  line-height: 1.7;
}
.item-row button {
  font-size: 11px;
  white-space: nowrap;
}
.section-label {
  font: 18px var(--serif);
  color: #e0c48d;
  letter-spacing: 2px;
  margin: 25px 0 18px;
}
.shop-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.shop-grid article {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 18px 12px;
  gap: 9px;
  border: 1px solid #af9a6238;
  border-radius: 4px;
  background: #0e2c263d;
  text-align: center;
}
.shop-grid b {
  font: 16px var(--serif);
  color: #dfcea0;
}
.shop-grid small {
  font-size: 9px;
  color: #a6bc9d;
  min-height: 30px;
  line-height: 1.7;
}
.shop-grid button {
  font-size: 10px;
}
.quest-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.quest-row {
  display: flex;
  gap: 18px;
  align-items: center;
  border: 1px solid #b8a06845;
  border-radius: 4px;
  padding: 16px;
  background: #0b28223d;
}
.quest-row > div:nth-child(2) {
  flex: 1;
}
.quest-stamp {
  width: 43px;
  height: 45px;
  border: 1px solid #9cb38f55;
  display: grid;
  place-items: center;
  font: 23px var(--serif);
  color: #afc29c;
  transform: rotate(-4deg);
  background: #2e473833;
}
.quest-row h3 {
  font-size: 17px;
  letter-spacing: 2px;
  color: #e1cea0;
}
.quest-row p {
  font-size: 11px;
  color: #b4c6a6;
  margin-top: 5px;
}
.quest-row p b {
  margin-left: 15px;
  color: #d3c691;
  font-size: 10px;
  font-weight: 400;
}
.quest-row small {
  display: block;
  color: #9db193;
  font-size: 9px;
  line-height: 1.8;
  margin-top: 3px;
}
.quest-row button {
  font-size: 10px;
  min-width: 80px;
  padding: 10px 12px;
}
.quest-row.done {
  opacity: 0.55;
}
.quest-row.done .quest-stamp {
  color: #d1a783;
  border-color: #bd8b5d77;
}
.training-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.training-list > button {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  text-align: left;
  background: #102d2666;
}
.training-number {
  font: 34px var(--serif);
  color: #d8b77c99;
}
.training-list button div {
  flex: 1;
}
.training-list b {
  font: 20px var(--serif);
  color: #e0cca0;
  letter-spacing: 2px;
}
.training-list p {
  font-size: 11px;
  color: #b5c6a5;
  margin-top: 6px;
}
.training-list small {
  font-size: 9px;
  color: #9fb797;
  display: block;
  margin-top: 5px;
}
.exploration-seal {
  font: 60px var(--serif);
  display: grid;
  place-items: center;
  width: 100px;
  height: 100px;
  border: 1px solid #d0b57b70;
  border-radius: 50%;
  color: #dbc28a;
  background: #a8bd6f0b;
  margin: 0 auto 25px;
}
.result-banner {
  display: flex;
  align-items: center;
  gap: 30px;
  padding: 25px;
  background: radial-gradient(ellipse at left, #b9a4601c, transparent);
  border-bottom: 1px solid #baa26940;
}
.result-banner > span {
  font: 65px var(--serif);
  color: #e1c58b;
  text-shadow: 0 0 30px #d2b37240;
}
.result-banner p {
  font-size: 10px;
  letter-spacing: 3px;
  color: #c0caaa;
}
.result-banner h3 {
  font-size: 24px;
  letter-spacing: 3px;
  margin-top: 9px;
  color: #f0ddb3;
}
.result-banner.defeat > span {
  font-size: 38px;
  color: #b3c3ad;
}
.battle-rewards {
  display: flex;
  gap: 25px;
  padding: 18px 0;
  border-block: 1px solid #bda46e40;
}
.battle-rewards > span {
  font-size: 10px;
  color: #a8be9e;
}
.battle-rewards b {
  display: block;
  font: 21px var(--serif);
  color: #e8cb8b;
  margin-top: 7px;
}
.level-notice {
  color: #dbd6a4;
  font-size: 11px;
  margin-top: 18px;
  padding-left: 12px;
  border-left: 2px solid #c8b37c;
}
.recruit-reveal {
  display: flex;
  align-items: center;
  gap: 25px;
  padding: 20px;
  background: radial-gradient(ellipse at 30%, #d5b66d13, transparent);
}
.recruit-reveal .portrait {
  width: 110px;
  height: 145px;
  filter: drop-shadow(0 7px 10px #041c1860);
}
.recruit-reveal small {
  font-size: 10px;
  color: #b6c5a4;
  letter-spacing: 1px;
}
.recruit-reveal h3 {
  font-size: 28px;
  letter-spacing: 3px;
  color: #f1d6a0;
  margin: 10px 0;
}
.recruit-reveal h3 span {
  font-size: 12px;
  color: #c8bb8c;
  margin-left: 15px;
  letter-spacing: 1px;
}
.recruit-reveal p {
  font-size: 11px;
  color: #bdd0ad;
  margin-bottom: 10px;
}
.defeat-tips {
  font-size: 12px;
  line-height: 2.3;
  color: #becbac;
  padding-left: 20px;
}
.ending-scene {
  text-align: center;
  position: relative;
  isolation: isolate;
  padding: 20px 20px 0;
}
.ending-scene:before {
  content: "";
  position: absolute;
  inset: -24px -28px 0;
  background:
    linear-gradient(#12362c55, #15382aee),
    url("/art/summit.webp") center/cover;
  z-index: -1;
}
.ending-scene h3 {
  font-size: 46px;
  line-height: 1.5;
  letter-spacing: 9px;
  color: #f8e7b7;
  margin: 22px 0;
}
.ending-scene p {
  font-family: var(--serif);
  font-size: 14px;
  line-height: 2.2;
  letter-spacing: 2px;
  color: #dfdfbd;
  margin-bottom: 15px;
}
.ending-party {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  height: 165px;
  margin: 20px 0;
  gap: 8px;
}
.ending-party img {
  width: 12%;
  height: 150px;
  filter: drop-shadow(0 7px 8px #142a1a80);
}
p.ending-quote {
  font-size: 20px;
  margin: 20px 0 30px;
  color: #efdaa2;
}
.ending-stats {
  display: flex;
  justify-content: space-around;
  gap: 15px;
  padding: 22px 0;
  border-block: 1px solid #c2a77150;
  margin-bottom: 18px;
}
.ending-stats > span {
  font-size: 10px;
  color: #b9c5a5;
}
.ending-stats b {
  display: block;
  font: 21px var(--serif);
  margin-top: 7px;
  color: #e5cea0;
}
.save-info {
  background: #102c2650;
  padding: 18px 20px;
  border: 1px solid #b49c6840;
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}
.save-info > b {
  font: 22px var(--serif);
  letter-spacing: 2px;
  color: #e5cfa0;
}
.save-info > span {
  font-size: 12px;
  color: #c0cdad;
}
.save-info > small {
  font-size: 10px;
  color: #9eb694;
}
.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.settings-grid > button {
  text-align: left;
  padding: 16px !important;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.settings-grid b {
  font: 17px var(--serif);
  color: #ddc898;
}
.settings-grid small {
  color: #a8bf9d;
  font-size: 10px;
}
.settings-bottom {
  display: flex;
  justify-content: space-between;
  padding-top: 20px;
  border-top: 1px solid #c4ac7533;
  margin-top: 20px;
  font-size: 11px;
}
details {
  margin-top: 20px;
  color: #9fb796;
  font-size: 11px;
}
summary {
  cursor: pointer;
  color: #cbbd91;
}
details p {
  margin-top: 10px;
}
.about-evidence h3 {
  color: #dcc38c;
  font: 18px var(--serif);
  margin: 20px 0 10px;
  letter-spacing: 2px;
}
.about-evidence p {
  color: #b1c7a6;
  font-size: 12px;
  line-height: 2;
}
.empty-state {
  padding: 30px;
  text-align: center;
  color: #bcc8a9;
  font-size: 13px;
}
.empty-state p {
  font-size: 11px;
  margin-top: 10px;
}
#toasts {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: min(90vw, 600px);
  pointer-events: none;
}
.toast {
  background: #102f2cf2;
  border: 1px solid #c1aa7580;
  border-radius: 5px;
  padding: 12px 22px;
  box-shadow: 0 5px 25px #09211f66;
  color: #efe0bd;
  font-size: 12px;
  line-height: 1.8;
  text-align: center;
  animation: rise-in 0.2s ease-out;
  pointer-events: none;
}
@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes scene-reveal {
  from {
    transform: scale(1.12);
  }
  to {
    transform: scale(1.06);
  }
}
@media (min-width: 1100px) {
  .stage-wrap {
    display: flex;
    justify-content: center;
    background: #0f2723;
  }
  .stage-wrap canvas {
    width: auto;
    max-width: 100%;
    height: calc(100svh - 247px);
    max-height: 840px;
  }
  .game-shell:has(.command-strip:not([hidden])) .stage-wrap canvas {
    height: calc(100svh - 334px);
  }
  .game-shell:has(.command-strip:not([hidden])) .scene-heading h2 {
    font-size: 24px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective {
    max-width: 165px;
    top: 95px;
    padding: 12px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective p {
    font-size: 10px;
  }
  .game-shell:has(.command-strip:not([hidden])) .battle-side {
    width: 135px;
    top: 95px;
  }
  .game-shell:has(.command-strip:not([hidden])) .scene-controls {
    bottom: 12px;
  }
  .game-shell:has(.command-strip:not([hidden])) .party-strip {
    min-height: 70px;
  }
  .game-shell:has(.command-strip:not([hidden])) .party-hero > .portrait {
    height: 56px;
  }
  .topbar {
    height: 76px;
  }
}
@media (max-width: 1000px) {
  .topbar {
    gap: 15px;
    padding: 0 18px;
  }
  .resources {
    gap: 18px;
  }
  .brand > span:last-child {
    font-size: 18px;
  }
  .player-info {
    min-width: 100px;
  }
  .bottom-nav {
    gap: 0;
    padding: 9px;
  }
  .nav-button {
    padding: 8px 13px;
    font-size: 10px;
    gap: 7px;
  }
  .objective {
    width: 170px;
    left: 20px;
    top: 95px;
    padding: 13px;
  }
  .objective p {
    font-size: 10px;
  }
  .objective h3 {
    font-size: 14px;
  }
  .scene-heading {
    top: 17px;
    left: 21px;
    right: 21px;
  }
  .scene-heading h2 {
    font-size: 24px;
  }
  .battle-side {
    right: 18px;
    width: 130px;
    top: 90px;
  }
  .party-hero {
    padding: 6px 12px;
  }
  .command-strip {
    gap: 15px;
    padding-inline: 12px;
  }
  .command-buttons > button {
    min-width: 115px;
    padding-right: 20px;
  }
  .tactic-resource {
    min-width: 120px;
  }
  .title-copy {
    margin-left: 9vw;
  }
  .title-actors {
    right: 3vw;
    width: 49vw;
  }
  .title-copy h1 {
    font-size: 75px;
  }
}
@media (max-width: 760px) {
  .title-copy {
    margin: 8vh 0 12vh 8vw;
  }
  .title-copy h1 {
    font-size: 66px;
  }
  .title-top {
    padding: 20px 6vw;
    font-size: 9px;
    letter-spacing: 1px;
  }
  .title-actors {
    opacity: 0.65;
    right: -12vw;
    bottom: 12vh;
    transform: scale(1.3);
    transform-origin: right bottom;
    width: 60vw;
  }
  .hero-one {
    width: 34vw;
    height: 40vh;
    left: 5vw;
  }
  .hero-two {
    width: 27vw;
    height: 34vh;
    right: 0;
  }
  .hero-three {
    display: none;
  }
  .title-vignette {
    background:
      linear-gradient(90deg, #0a2323f0 0%, #12342bc9 48%, #193b2933),
      linear-gradient(0deg, #0a2323, transparent 70%);
  }
  .title-copy > .eyebrow {
    font-size: 10px;
    letter-spacing: 4px;
  }
  .title-sub {
    font-size: 18px;
  }
  .title-poem {
    font-size: 13px;
  }
  .title-footer {
    font-size: 8px;
    letter-spacing: 1px;
    padding: 20px 6vw;
  }
  .title-footer span:last-child {
    display: none;
  }
  .title-button {
    width: 285px;
  }
  .title-actions {
    margin-top: 30px;
  }
  .topbar {
    height: 66px;
    padding: 0 12px;
    gap: 12px;
  }
  .brand > span:last-child {
    font-size: 15px;
    letter-spacing: 1px;
  }
  .brand small {
    font-size: 7px;
    letter-spacing: 4px;
  }
  .mini-seal {
    width: 28px;
    height: 32px;
    font-size: 21px;
  }
  .brand {
    gap: 7px;
  }
  .player-info {
    display: none;
  }
  .resources {
    gap: 14px;
  }
  .resources i {
    font-size: 19px;
    column-gap: 5px;
  }
  .resources b {
    font-size: 13px;
  }
  .resources small {
    font-size: 8px;
  }
  .top-actions {
    gap: 5px;
  }
  .top-actions > span {
    display: none;
  }
  .top-actions button {
    width: 27px;
    height: 29px;
    font-size: 15px;
  }
  .stage-wrap canvas {
    max-height: none;
    aspect-ratio: 1000/750;
    object-fit: fill;
  }
  .scene-heading {
    top: 14px;
    left: 16px;
    right: 16px;
  }
  .scene-heading h2 {
    font-size: 21px;
    letter-spacing: 3px;
  }
  .scene-heading > p {
    display: none;
  }
  .scene-heading .eyebrow {
    font-size: 8px;
    letter-spacing: 1px;
  }
  .objective {
    top: 83px;
    left: 14px;
    width: 140px;
    padding: 10px;
    border-left-width: 1px;
  }
  .objective .eyebrow {
    font-size: 8px;
    letter-spacing: 1px;
  }
  .objective h3 {
    font-size: 13px;
    letter-spacing: 1px;
    margin: 6px 0;
  }
  .objective p {
    font-size: 9px;
    line-height: 1.75;
  }
  .objective .text-button {
    font-size: 10px;
  }
  .objective > small {
    font-size: 8px;
  }
  .quest-ready {
    font-size: 8px;
  }
  .world-hint {
    left: 16px;
    bottom: 18px;
    font-size: 8px;
    letter-spacing: 0;
  }
  .scene-controls {
    right: 12px;
    bottom: 14px;
    gap: 5px;
  }
  .scene-button {
    padding: 6px 8px;
    font-size: 9px;
  }
  .battle-side {
    display: none;
  }
  .party-strip {
    min-height: 70px;
    padding: 0 5px;
  }
  .party-hero {
    padding: 5px;
    gap: 3px;
  }
  .party-hero > .portrait {
    width: 32px;
    height: 50px;
  }
  .party-hero > div {
    min-width: 0;
    flex: 1;
  }
  .party-name {
    font-size: 12px;
    gap: 3px;
  }
  .party-name small {
    font-size: 8px;
  }
  .party-role {
    font-size: 7px;
    line-height: 1.6;
  }
  .party-empty {
    max-width: 90px;
    font-size: 16px;
    height: 45px;
  }
  .party-empty small {
    font-size: 7px;
  }
  .bottom-nav {
    padding: 8px 4px;
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0;
  }
  .nav-button {
    flex-direction: column;
    gap: 5px;
    padding: 7px 0;
    font-size: 9px;
  }
  .nav-button span {
    font-size: 19px;
  }
  .game-footer {
    padding: 0 12px 12px;
    font-size: 8px;
  }
  .game-footer span:last-child {
    display: none;
  }
  .command-strip {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px 8px;
  }
  .tactic-resource {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
  }
  .tactic-resource > span {
    font-size: 9px;
  }
  .tactic-resource > b {
    font-size: 14px;
    letter-spacing: 3px;
  }
  .tactic-resource > small {
    font-size: 8px;
  }
  .command-buttons {
    gap: 5px;
    width: 100%;
  }
  .command-buttons > button {
    flex: 1;
    min-width: 0;
    padding: 10px 4px;
    text-align: center;
  }
  .command-buttons kbd {
    display: none;
  }
  .command-buttons b {
    font-size: 14px;
  }
  .command-buttons small {
    font-size: 7px;
  }
  .command-buttons em {
    position: static;
    display: block;
    margin-top: 5px;
    font-size: 8px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective {
    width: 116px;
    top: 75px;
    padding: 8px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective p {
    font-size: 8px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective > small {
    display: none;
  }
  .game-shell:has(.command-strip:not([hidden])) .stage-wrap canvas {
    aspect-ratio: 1000/730;
  }
  dialog {
    width: calc(100vw - 20px);
    max-height: calc(100svh - 24px);
    border-radius: 7px;
  }
  dialog.wide {
    width: calc(100vw - 20px);
  }
  .modal-head {
    padding: 15px 18px;
  }
  .modal-head h2 {
    font-size: 21px;
  }
  .modal-body {
    padding: 18px;
  }
  .modal-foot {
    padding: 13px 18px;
    gap: 7px;
  }
  .modal-foot button {
    font-size: 11px;
    padding: 11px 14px;
  }
  .intro-text {
    font-size: 11px;
  }
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .hero-list {
    display: flex;
    overflow: auto;
    gap: 5px;
    border: 0;
    border-bottom: 1px solid #b3a37133;
    padding: 0 0 10px;
  }
  .hero-tab {
    flex-direction: column;
    width: 70px;
    min-width: 70px;
    gap: 2px;
    padding: 7px 4px;
    text-align: center;
  }
  .hero-tab .portrait {
    height: 45px;
    width: 40px;
  }
  .hero-tab b {
    font-size: 12px;
  }
  .hero-tab small {
    font-size: 8px;
    margin-top: 3px;
  }
  .hero-list > .muted {
    display: none;
  }
  .hero-showcase {
    gap: 15px;
    min-height: 130px;
  }
  .hero-showcase > .portrait {
    width: 90px;
    height: 140px;
  }
  .hero-showcase h3 {
    font-size: 26px;
  }
  .hero-showcase p {
    font-size: 10px;
  }
  .hero-showcase .eyebrow {
    font-size: 8px;
    letter-spacing: 1px;
  }
  .stats-row {
    padding: 12px 0;
    margin-top: 5px;
  }
  .stats-row b {
    font-size: 18px;
  }
  .skill-description {
    padding: 16px 0;
  }
  .equipment-slots {
    gap: 6px;
  }
  .equipment-slots button {
    padding: 10px 7px;
  }
  .equipment-slots b {
    font-size: 11px;
  }
  .equipment-slots span {
    font-size: 8px;
  }
  .hero-actions span {
    font-size: 9px;
  }
  .formation-options {
    grid-template-columns: repeat(2, 1fr);
  }
  .formation-options > button {
    padding: 11px;
  }
  .formation-options b {
    font-size: 14px;
  }
  .hero-actions {
    gap: 10px;
  }
  .chapter-title {
    flex-wrap: wrap;
    gap: 8px;
  }
  .chapter-title p {
    width: 100%;
    margin: 0;
  }
  .chapter-title h3 {
    font-size: 19px;
  }
  .stage-node {
    min-width: 0;
    padding: 0 3px;
    flex: 1;
  }
  .node-emblem {
    width: 45px;
    height: 45px;
    font-size: 20px;
  }
  .stage-node b {
    font-size: 11px;
    letter-spacing: 0;
  }
  .stage-node small {
    font-size: 8px;
  }
  .stage-path {
    gap: 2px;
  }
  .stage-path:before {
    top: 23px;
  }
  .chapter-title {
    margin-bottom: 15px;
  }
  .chapter-section {
    padding-bottom: 22px;
    margin-bottom: 22px;
  }
  .stage-preview {
    margin: -18px -18px 16px;
    padding: 22px;
    height: 170px;
  }
  .stage-preview h3 {
    font-size: 21px;
    letter-spacing: 1px;
  }
  .stage-preview > span {
    font-size: 9px;
  }
  .boss-mark {
    font-size: 12px;
    right: 20px;
    top: 20px;
  }
  .encounter-enemies {
    gap: 6px;
  }
  .encounter-enemies > div {
    flex-direction: column;
    gap: 5px;
    flex: 1;
  }
  .encounter-enemies .portrait {
    height: 65px;
    width: 50px;
  }
  .encounter-enemies span {
    font-size: 10px;
    text-align: center;
  }
  .encounter-enemies small {
    font-size: 9px;
    margin-top: 3px;
  }
  .reward-preview {
    gap: 12px;
    font-size: 11px;
  }
  .reward-preview span {
    font-size: 10px;
  }
  .story-scene {
    margin: -18px -18px 0;
    height: 330px;
    padding: 18px;
    gap: 10px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
  }
  .story-scene > .portrait {
    height: 150px;
    width: 100px;
    position: absolute;
    top: 18px;
    left: 20px;
  }
  .story-seal {
    height: 120px;
    font-size: 40px;
    text-align: left;
  }
  .story-bubble {
    z-index: 1;
    flex: none;
    min-height: 110px;
    padding: 18px;
    width: 100%;
  }
  .story-bubble > b {
    font-size: 15px;
    margin-bottom: 7px;
  }
  .story-bubble p {
    font-size: 15px;
    line-height: 1.9;
  }
  .tutorial-steps p {
    gap: 12px;
  }
  .tutorial-steps b {
    min-width: 86px;
    font-size: 13px;
  }
  .tutorial-steps span {
    font-size: 10px;
  }
  .tutorial-art {
    height: 120px;
  }
  .tutorial-art img {
    max-height: 120px;
    width: 75px;
  }
  .difficulty {
    gap: 6px;
  }
  .difficulty label {
    padding: 17px 5px 12px;
  }
  .difficulty b {
    font-size: 18px;
  }
  .difficulty span {
    font-size: 8px;
  }
  .item-row {
    gap: 10px;
    padding: 12px 10px;
  }
  .item-icon {
    width: 35px;
    height: 40px;
    font-size: 22px;
  }
  .item-row h3 {
    font-size: 13px;
    letter-spacing: 0;
  }
  .item-row h3 small {
    display: block;
    font-size: 8px;
    margin: 5px 0 0;
  }
  .item-row p {
    font-size: 9px;
  }
  .item-row div > small {
    font-size: 8px;
  }
  .item-row button {
    padding: 8px 10px;
    font-size: 10px;
  }
  .shop-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .shop-grid article {
    padding: 14px 9px;
  }
  .shop-grid b {
    font-size: 14px;
  }
  .shop-grid small {
    font-size: 8px;
  }
  .shop-grid button {
    font-size: 9px;
    padding: 9px;
  }
  .quest-row {
    gap: 10px;
    padding: 12px 10px;
  }
  .quest-stamp {
    width: 33px;
    height: 36px;
    font-size: 20px;
  }
  .quest-row h3 {
    font-size: 15px;
    letter-spacing: 1px;
  }
  .quest-row p {
    font-size: 10px;
  }
  .quest-row small {
    font-size: 8px;
  }
  .quest-row button {
    font-size: 9px;
    min-width: 60px;
    padding: 9px 7px;
  }
  .quest-row p b {
    margin-left: 7px;
    font-size: 9px;
  }
  .story-text {
    font-size: 14px;
    line-height: 2;
  }
  .result-banner {
    gap: 18px;
    padding: 18px 10px;
  }
  .result-banner > span {
    font-size: 55px;
  }
  .result-banner h3 {
    font-size: 19px;
    letter-spacing: 1px;
  }
  .result-banner p {
    font-size: 9px;
    letter-spacing: 1px;
  }
  .battle-rewards {
    gap: 20px;
    flex-wrap: wrap;
  }
  .battle-rewards > span {
    font-size: 9px;
  }
  .battle-rewards b {
    font-size: 19px;
  }
  .recruit-reveal {
    gap: 15px;
    padding: 15px 0;
  }
  .recruit-reveal .portrait {
    width: 90px;
    height: 120px;
  }
  .recruit-reveal h3 {
    font-size: 24px;
    letter-spacing: 1px;
  }
  .recruit-reveal h3 span {
    font-size: 10px;
    margin-left: 8px;
  }
  .recruit-reveal p {
    font-size: 10px;
  }
  .ending-scene h3 {
    font-size: 34px;
    letter-spacing: 6px;
  }
  .ending-scene p {
    font-size: 12px;
    letter-spacing: 1px;
  }
  .ending-scene:before {
    inset: -18px -18px 0;
  }
  .ending-party {
    height: 110px;
    gap: 0;
  }
  .ending-party img {
    height: 100px;
    width: 14%;
  }
  .ending-stats {
    gap: 8px;
  }
  .ending-stats > span {
    font-size: 8px;
  }
  .ending-stats b {
    font-size: 17px;
  }
  .ending-quote {
    font-size: 17px !important;
  }
  .settings-grid {
    gap: 8px;
  }
  .settings-grid b {
    font-size: 15px;
  }
  .settings-grid small {
    font-size: 9px;
  }
  .settings-grid > button {
    padding: 13px !important;
  }
  .game-shell {
    min-height: 100svh;
  }
  .scene-wrap {
    min-height: 0;
  }
}
@media (max-width: 400px) {
  .topbar {
    gap: 9px;
    padding: 0 9px;
  }
  .resources {
    gap: 9px;
  }
  .resources > span {
    column-gap: 4px;
  }
  .resources i {
    font-size: 16px;
  }
  .resources b {
    font-size: 12px;
  }
  .brand > span:last-child {
    font-size: 13px;
  }
  .mini-seal {
    width: 25px;
    height: 29px;
    font-size: 19px;
  }
  .brand small {
    letter-spacing: 3px;
  }
  .top-actions button {
    width: 25px;
  }
  .title-copy h1 {
    font-size: 58px;
  }
  .title-copy {
    margin-left: 7vw;
  }
  .title-button {
    width: 265px;
  }
  .party-hero > .portrait {
    width: 26px;
    height: 45px;
  }
  .party-name {
    font-size: 11px;
  }
  .party-name small {
    font-size: 7px;
  }
  .party-role {
    font-size: 6px;
  }
  .party-strip {
    min-height: 63px;
  }
  .scene-heading h2 {
    font-size: 19px;
  }
  .objective {
    width: 125px;
    top: 75px;
  }
  .world-hint {
    font-size: 7px;
  }
  .tactic-resource {
    gap: 7px;
  }
  .tactic-resource > small {
    font-size: 7px;
  }
  .nav-button {
    font-size: 8px;
  }
  .scene-button {
    font-size: 8px;
  }
  .game-footer {
    font-size: 7px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation: none !important;
    transition: none !important;
  }
}
.route-tabs {
  display: flex;
  gap: 6px;
  border-bottom: 1px solid #baa16e40;
  margin: -4px 0 20px;
  padding-bottom: 12px;
}
.route-tabs button {
  background: transparent;
  border-color: transparent;
  padding: 9px 18px;
  color: #aabd9e;
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 2px;
}
.route-tabs button.selected {
  color: #ecd39c;
  border-color: #c7a96a70;
  background: #c7a96a0c;
}
.book-intro {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 15px 0 25px;
}
.book-seal {
  font: 60px var(--serif);
  color: #e2c38b;
  display: grid;
  place-items: center;
  min-width: 100px;
  height: 110px;
  border: 1px solid #c2a66e70;
  background: linear-gradient(135deg, #bba26813, #19372b);
  transform: rotate(-4deg);
}
.book-intro h3 {
  font-size: 25px;
  letter-spacing: 4px;
  color: #e9d3a5;
  margin-bottom: 10px;
}
.book-intro p {
  font-size: 12px;
  color: #b5c8aa;
  line-height: 1.9;
}
.book-intro small {
  display: block;
  font-size: 9px;
  color: #92ac8c;
  margin-top: 12px;
}
.book-shelves {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.book-volume {
  display: flex;
  padding: 0;
  text-align: left;
  overflow: hidden;
  background: linear-gradient(120deg, #2c4536, #123026);
  border: 1px solid #b9a36d59;
  min-height: 155px;
  box-shadow: 0 4px 14px #051f1833;
}
.book-volume > div {
  padding: 18px 18px 18px 20px;
  flex: 1;
}
.volume-spine {
  font: 25px var(--serif);
  color: #d9c38f;
  width: 44px;
  display: grid;
  place-items: center;
  border-right: 1px solid #c8aa7044;
  background: linear-gradient(90deg, #0e251f, #35543a, #1e3b2d);
  flex: none;
}
.book-volume small {
  font-size: 9px;
  color: #a9b99a;
  letter-spacing: 2px;
}
.book-volume h3 {
  font-size: 23px;
  color: #e4cfa0;
  letter-spacing: 3px;
  margin: 10px 0;
}
.book-volume p {
  font: 11px var(--serif);
  color: #b7c7a6;
  letter-spacing: 1px;
}
.book-volume div > span {
  font-size: 9px;
  color: #91af8b;
  display: block;
  margin-top: 15px;
}
.book-volume.read {
  border-color: #a8ba8770;
}
.book-volume.read .volume-spine {
  color: #d6dbab;
}
.book-source {
  border-top: 1px solid #bda57140;
  padding-top: 18px;
}
.fragment-notice {
  font-size: 12px;
  color: #ddca98;
  margin-top: 18px;
  padding: 12px 15px;
  border: 1px solid #c6aa7040;
  background: #c1aa6b09;
  line-height: 1.9;
}
.fragment-notice > span {
  display: inline-grid;
  place-items: center;
  width: 27px;
  height: 29px;
  border: 1px solid #b59e6370;
  margin-right: 12px;
  font: 18px var(--serif);
  transform: rotate(-5deg);
}
.choice-intro {
  text-align: center;
  padding: 5px 0 25px;
}
.choice-intro > span {
  font: 55px var(--serif);
  color: #cbb17c90;
}
.choice-intro h3 {
  font-size: 25px;
  color: #ecd6aa;
  letter-spacing: 3px;
  margin: 20px 0 14px;
}
.choice-intro p {
  font-size: 12px;
  color: #aebfa0;
}
.book-choices {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 24px;
}
.book-choices > button {
  padding: 25px;
  background: linear-gradient(135deg, #37513a66, #0b2a22);
  text-align: left;
  border-color: #bda16870;
}
.book-choices b {
  font: 21px var(--serif);
  color: #e9cd94;
  letter-spacing: 2px;
}
.book-choices p {
  font: 14px/2 var(--serif);
  color: #c1d0b0;
  margin: 14px 0;
}
.book-choices small {
  font-size: 10px;
  color: #b3bd8e;
  line-height: 1.9;
}
.book-epilogue {
  text-align: center;
  position: relative;
  isolation: isolate;
  padding: 15px 10px 30px;
}
.book-epilogue:before {
  content: "";
  position: absolute;
  inset: -24px -28px 0;
  background:
    linear-gradient(#112a24d9, #142f26fa),
    url("/art/town.webp") center/cover;
  z-index: -1;
}
.book-epilogue h3 {
  font: 42px/1.6 var(--serif);
  letter-spacing: 8px;
  color: #edd5a2;
  margin: 24px 0;
}
.book-epilogue p {
  font: 15px/2.3 var(--serif);
  letter-spacing: 2px;
  color: #c5d0b3;
  margin-bottom: 15px;
}
.fragment-collection {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 30px;
}
.fragment-collection > span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 10px 13px;
  color: #a5b49a;
  opacity: 0.35;
}
.fragment-collection b {
  font: 20px var(--serif);
  writing-mode: vertical-rl;
  letter-spacing: 5px;
  padding: 14px 8px;
  border: 1px solid #a9ac7159;
  background: #d4b67a0a;
  min-height: 90px;
  color: #d3ba85;
}
.fragment-collection small {
  font-size: 8px;
}
.fragment-collection > span.lit {
  opacity: 1;
}
.fragment-collection > span.lit b {
  color: #efd8a4;
  border-color: #d6ba7a9c;
  box-shadow: 0 0 22px #d6ba7a12;
}
.abstract-portrait {
  display: grid;
  place-items: center;
  font: 40px var(--serif);
  color: #bce1df;
  min-width: 50px;
}
.abstract-portrait.stone {
  font-size: 25px;
  border-radius: 50%;
  background: radial-gradient(at 35% 30%, #68777a, #12262a 70%);
  width: 50px !important;
  height: 50px !important;
  margin: 12px 0;
  color: #d5ceb4;
}
.abstract-portrait.shade {
  color: #c3aadd;
}
@media (max-width: 760px) {
  .route-tabs button {
    font-size: 13px;
    padding: 8px 14px;
  }
  .book-intro {
    gap: 15px;
    padding: 5px 0 20px;
  }
  .book-seal {
    min-width: 60px;
    height: 75px;
    font-size: 40px;
  }
  .book-intro h3 {
    font-size: 20px;
    letter-spacing: 2px;
  }
  .book-intro p {
    font-size: 10px;
  }
  .book-intro small {
    font-size: 8px;
    line-height: 1.8;
  }
  .book-shelves {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .book-volume {
    min-height: 125px;
  }
  .book-volume > div {
    padding: 15px 18px;
  }
  .book-volume h3 {
    font-size: 21px;
    margin: 7px 0;
  }
  .book-volume div > span {
    font-size: 8px;
    margin-top: 10px;
  }
  .volume-spine {
    width: 40px;
    font-size: 23px;
  }
  .book-volume p {
    font-size: 10px;
  }
  .book-volume small {
    font-size: 8px;
  }
  .book-choices {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .book-choices > button {
    padding: 18px;
  }
  .book-choices b {
    font-size: 18px;
    letter-spacing: 1px;
  }
  .book-choices p {
    font-size: 12px;
    margin: 10px 0;
  }
  .book-choices small {
    font-size: 9px;
  }
  .choice-intro h3 {
    font-size: 20px;
    letter-spacing: 2px;
  }
  .choice-intro p {
    font-size: 10px;
  }
  .book-epilogue h3 {
    font-size: 33px;
  }
  .book-epilogue p {
    font-size: 12px;
    letter-spacing: 1px;
  }
  .book-epilogue:before {
    inset: -18px -18px 0;
  }
  .fragment-collection {
    gap: 0;
  }
  .fragment-collection > span {
    padding: 8px;
  }
  .fragment-collection b {
    font-size: 18px;
    min-height: 80px;
    padding: 12px 7px;
  }
  .fragment-collection small {
    font-size: 7px;
  }
  .fragment-notice {
    font-size: 10px;
    padding: 10px;
  }
  .fragment-notice > span {
    width: 23px;
    height: 26px;
    font-size: 16px;
    margin-right: 8px;
  }
}
.result-stars {
  color: #e7c682;
  font-size: 18px;
  letter-spacing: 3px;
  margin: 8px 0;
}
.result-stars > span {
  color: #b9aa7b55;
}
.result-stars small {
  display: block;
  font: 9px system-ui;
  letter-spacing: 1px;
  color: #b7c3a1;
  margin-top: 5px;
}
.order-buttons {
  display: flex;
  gap: 5px;
  margin-left: auto;
}
.order-buttons button {
  font-size: 9px;
  padding: 7px;
  background: #17382b;
}
.hero-actions {
  flex-wrap: wrap;
}
.hero-actions > span {
  font-size: 9px;
}
.sell-button {
  background: transparent;
  color: #96ad8b;
  font-size: 9px;
  padding: 7px;
  border-color: transparent;
}
.sell-button:hover {
  color: #e2c58b;
}
.item-row .sell-button {
  font-size: 9px;
  padding: 7px;
}
.stage-wrap canvas:focus-visible {
  outline: 2px solid #d9bc7e;
  outline-offset: -3px;
}
@media (max-width: 760px) {
  .order-buttons {
    margin-left: 0;
  }
  .order-buttons button {
    font-size: 8px;
    padding: 6px;
  }
  .hero-actions {
    gap: 8px;
  }
  .hero-actions button {
    font-size: 10px;
    padding: 9px 11px;
  }
  .item-row .sell-button {
    font-size: 8px;
    padding: 5px;
  }
  .item-row {
    flex-wrap: wrap;
  }
  .item-row > .sell-button {
    margin-left: auto;
  }
  .result-stars {
    font-size: 16px;
  }
  .result-stars small {
    font-size: 8px;
  }
  .result-banner h3 {
    font-size: 17px;
  }
}
.loading-cast {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  min-height: 210px;
}
.loading-cast p {
  font-size: 12px;
  color: #bac8aa;
  letter-spacing: 2px;
}
.loading-cast .seal {
  animation: rise-in 1s ease-in-out alternate infinite;
}
.mobile-journal {
  display: none;
}
@media (max-width: 760px) {
  .game-shell {
    display: flex;
    flex-direction: column;
  }
  .topbar,
  .stage-wrap,
  .party-strip,
  .command-strip,
  .bottom-nav,
  .game-footer {
    flex-shrink: 0;
  }
  .mobile-journal {
    display: block;
    flex: 1;
    padding: 18px 20px 22px;
    background: linear-gradient(180deg, #19352d40, #10292130);
    border-top: 1px solid #c2ae751a;
    min-height: 120px;
  }
  .mobile-journal > .eyebrow {
    font-size: 8px;
    letter-spacing: 2px;
    color: #bba878;
  }
  .mobile-journal > p {
    font-family: var(--serif);
    font-size: 11px;
    color: #a4b899;
    line-height: 2.1;
    margin-top: 12px;
    letter-spacing: 1px;
  }
  .journal-lines {
    display: grid;
    gap: 8px;
    margin-top: 13px;
  }
  .journal-lines p {
    font-size: 10px;
    line-height: 1.7;
    color: #b3c5a6;
  }
  .journal-lines small {
    font-size: 8px;
    color: #7f9c81;
    margin-right: 15px;
    display: inline-block;
    min-width: 22px;
  }
  .journal-progress {
    display: flex;
    gap: 15px;
    margin-top: 15px;
    flex-wrap: wrap;
  }
  .journal-progress > span {
    font-size: 8px;
    color: #88a482;
    line-height: 1.7;
  }
  .journal-progress > span.found {
    color: #d2c99b;
  }
  .game-footer {
    padding-top: 10px;
    border-top: 1px solid #a6956420;
  }
  .game-shell:has(.command-strip:not([hidden])) .mobile-journal {
    min-height: 125px;
  }
}
#modal:has(.loading-cast) .close-button {
  visibility: hidden;
}
.ending-party img {
  max-width: calc(
    (100% - (var(--cast-count, 7) - 1) * 8px) / var(--cast-count, 7)
  );
}
@media (max-width: 760px) {
  .ending-party img {
    max-width: calc(100% / var(--cast-count, 7));
  }
}
.difficulty-settings {
  border-top: 1px solid #c4ad7533;
  margin-top: 24px;
  padding-top: 20px;
}
.difficulty-settings h3 {
  font-size: 16px;
  color: #ddc58e;
  letter-spacing: 2px;
}
.difficulty-settings small {
  font: 9px system-ui;
  color: #98b08d;
  letter-spacing: 0;
  margin-left: 8px;
}
.difficulty-settings > div {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}
.difficulty-settings button {
  flex: 1;
  background: #153329;
  padding: 11px;
  font-family: var(--serif);
  font-size: 15px;
  color: #aabe9d;
}
.difficulty-settings button.selected {
  border-color: #cbb078;
  color: #ecd4a3;
  background: #c0a56710;
}
.enemy-targets {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 12px;
}
.enemy-targets > button {
  background: #0b29245e;
  border-color: #a98f6140;
  padding: 8px;
  text-align: left;
}
.enemy-targets b {
  font: 11px var(--serif);
  color: #e1d0a8;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.enemy-targets small {
  font-size: 8px;
  color: #a6bb9d;
  display: block;
  margin-top: 5px;
  line-height: 1.4;
}
.enemy-hp {
  display: block;
  height: 3px;
  background: #152b25;
  margin-top: 7px;
}
.enemy-hp > i {
  display: block;
  height: 100%;
  background: #d6937e;
}
.enemy-targets button.focused {
  border-color: #e5c58a;
  background: #ba9e5515;
}
.enemy-targets button.danger small {
  color: #f0b789;
}
.enemy-targets button.danger {
  border-color: #dca16b90;
}
.side-log {
  margin-top: 14px;
  border-top: 1px solid #c2a16b30;
  padding-top: 2px;
}
.battle-side {
  pointer-events: auto;
  z-index: 3;
}
.battle-side .eyebrow {
  font-size: 8px;
  letter-spacing: 1px;
}
.battle-side .side-log p {
  font-size: 8px;
  line-height: 1.7;
  margin-top: 8px;
}
.mobile-journal .enemy-targets {
  flex-direction: row;
  gap: 7px;
  margin-top: 13px;
}
.mobile-journal .enemy-targets > button {
  flex: 1;
  min-width: 0;
  padding: 8px 6px;
}
.mobile-journal .enemy-targets b {
  font-size: 10px;
}
.mobile-journal .enemy-targets small {
  font-size: 7px;
}
.mobile-journal .journal-lines {
  margin-top: 12px;
}
.mobile-journal .enemy-targets button.focused {
  border-color: #d4b77f;
}
.scene-controls {
  z-index: 3;
}
.book-chapter-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}
.book-chapter-tabs button {
  padding: 9px 14px;
  font: 14px var(--serif);
  background: #15342b;
  color: #b4c2a3;
}
.book-chapter-tabs button.selected {
  color: #e9d09b;
  border-color: #ccb175;
  background: #c4a76d10;
}
@media (max-width: 760px) {
  .book-chapter-tabs button {
    font-size: 12px;
    padding: 8px 11px;
  }
}
.skill-description > small {
  display: block;
  color: #97b18e;
  font-size: 10px;
  margin-bottom: 10px;
}
.skill-description > b {
  display: block;
}
.hero-manual {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #bea47030;
  font-size: 10px;
  color: #8fa986;
}
.hero-manual > b {
  font: 14px var(--serif);
  color: #dac694;
  font-weight: 400;
}
.hero-manual button {
  font-size: 10px;
  margin-left: auto;
  color: #e4c98e;
  padding: 7px 10px;
}
.martial-intro {
  display: flex;
  align-items: center;
  gap: 22px;
  padding-bottom: 22px;
  border-bottom: 1px solid #c2aa7040;
  margin-bottom: 24px;
}
.martial-intro > .portrait {
  height: 125px;
  width: 95px;
}
.martial-intro h3 {
  font-size: 25px;
  letter-spacing: 3px;
  color: #e7cf9a;
  margin: 10px 0;
}
.martial-intro p {
  font-size: 11px;
  color: #b0c3a1;
  line-height: 1.9;
}
.martial-intro small {
  font-size: 10px;
  color: #9bb493;
  display: block;
  margin-top: 13px;
}
.martial-intro small > b {
  color: #e1c78a;
  font-weight: 400;
}
.manual-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.manual-card {
  padding: 20px;
  border: 1px solid #bba26750;
  background: linear-gradient(120deg, #30473350, #102d2366);
  border-radius: 4px;
}
.manual-card.equipped {
  border-color: #dec082;
  box-shadow: inset 0 0 24px #cbb3770b;
}
.manual-heading {
  display: flex;
  gap: 15px;
  align-items: center;
}
.manual-heading > span {
  font: 31px var(--serif);
  color: #cbb17a;
  display: grid;
  place-items: center;
  min-width: 47px;
  height: 53px;
  border: 1px solid #b79f6370;
  background: #a4a86808;
}
.manual-heading small {
  color: #9ab28d;
  font-size: 9px;
  letter-spacing: 1px;
}
.manual-heading h3 {
  font-size: 22px;
  letter-spacing: 3px;
  color: #e8d0a0;
  margin-top: 7px;
}
.manual-card > p {
  font: 12px/1.8 var(--serif);
  color: #aabf9d;
  margin: 16px 0 12px;
  letter-spacing: 1px;
}
.manual-effect {
  font-size: 11px;
  color: #c9d4b5;
  padding: 11px 0;
  border-block: 1px solid #b5a16b30;
}
.manual-effect > b {
  color: #efd49a;
  font-weight: 500;
  margin-left: 7px;
}
.manual-cost {
  font-size: 8px;
  line-height: 1.8;
  color: #8fa888;
  display: block;
  margin: 11px 0 14px;
  min-height: 15px;
}
.manual-actions {
  display: flex;
  gap: 9px;
}
.manual-actions button {
  font-size: 10px;
  padding: 9px 13px;
}
.manual-source {
  margin-top: 22px;
  font-size: 10px;
}
@media (max-width: 760px) {
  .hero-manual {
    gap: 9px;
    padding: 10px 0;
  }
  .hero-manual > b {
    font-size: 12px;
  }
  .hero-manual button {
    font-size: 9px;
  }
  .martial-intro {
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 18px;
  }
  .martial-intro > .portrait {
    height: 100px;
    width: 70px;
  }
  .martial-intro h3 {
    font-size: 20px;
    letter-spacing: 2px;
  }
  .martial-intro p {
    font-size: 9px;
  }
  .martial-intro small {
    font-size: 8px;
    line-height: 1.7;
  }
  .manual-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .manual-card {
    padding: 17px;
  }
  .manual-heading h3 {
    font-size: 21px;
  }
  .manual-heading > span {
    font-size: 27px;
    min-width: 42px;
    height: 48px;
  }
  .manual-effect {
    font-size: 10px;
  }
  .manual-cost {
    font-size: 8px;
  }
  .manual-actions button {
    font-size: 10px;
  }
}
.formation-brief {
  display: flex;
  align-items: center;
  gap: 23px;
  margin-bottom: 22px;
}
.formation-diagram {
  width: 210px;
  height: 120px;
  position: relative;
  flex: none;
  background:
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent 49px,
      #8d9c6f20 50px
    ),
    repeating-linear-gradient(
      0deg,
      transparent 0,
      transparent 29px,
      #8d9c6f20 30px
    ),
    linear-gradient(135deg, #19372b, #0e291f);
  border: 1px solid #af9d6850;
  border-radius: 4px;
}
.formation-rear,
.formation-front {
  position: absolute;
  font-size: 8px;
  letter-spacing: 1px;
  color: #839d7f;
  bottom: 5px;
}
.formation-rear {
  left: 9px;
}
.formation-front {
  right: 9px;
}
.formation-dot {
  position: absolute;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border: 1px solid #d5bd7d;
  background: #3c5840;
  border-radius: 50%;
  font-size: 10px;
  color: #eed7a4;
  transform: translate(-50%, -50%);
  box-shadow: 0 2px 8px #071f1a44;
}
.formation-brief > div:last-child > b {
  font: 20px var(--serif);
  color: #e3cc99;
  letter-spacing: 2px;
}
.formation-brief p {
  font-size: 11px;
  color: #b3c3a4;
  margin-top: 9px;
}
.formation-brief small {
  display: block;
  color: #8ea888;
  font-size: 9px;
  line-height: 1.9;
  margin-top: 10px;
}
@media (max-width: 760px) {
  .formation-brief {
    gap: 15px;
  }
  .formation-diagram {
    width: 135px;
    height: 110px;
  }
  .formation-dot {
    width: 19px;
    height: 19px;
    font-size: 8px;
  }
  .formation-brief > div:last-child > b {
    font-size: 17px;
  }
  .formation-brief p {
    font-size: 9px;
    line-height: 1.8;
  }
  .formation-brief small {
    font-size: 8px;
  }
  .formation-rear,
  .formation-front {
    font-size: 7px;
    letter-spacing: 0;
  }
}
.top-actions .save-warning {
  color: #ecc18e;
}
.reload-link {
  display: inline-block;
  padding: 12px 25px;
  color: #203a30;
  background: #d8bc83;
  border: 1px solid #f2dba2;
  border-radius: 4px;
  text-decoration: none;
  font-size: 14px;
}
.reload-link:hover {
  background: #ecd19a;
}
.load-error p {
  color: #b6c7ac;
  font-size: 13px;
  max-width: 90vw;
  overflow-wrap: anywhere;
}
.tower-entry {
  margin: 0 0 20px;
}
.tower-entry > button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 18px;
  padding: 18px 22px;
  text-align: left;
  border: 1px solid #c4a76f78;
  background: linear-gradient(110deg, #4d583a44, #16372b);
}
.tower-entry > button > span {
  font: 34px var(--serif);
  color: #e2c68d;
}
.tower-entry b {
  font: 20px var(--serif);
  letter-spacing: 2px;
  color: #e8d09e;
}
.tower-entry small {
  display: block;
  font-size: 10px;
  color: #aec09d;
  margin-top: 9px;
}
.tower-entry em {
  font-style: normal;
  margin-left: auto;
  color: #dac38a;
}
.tower-layout {
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 28px;
}
.tower-art {
  border: 1px solid #b9a16955;
  border-radius: 5px;
  overflow: hidden;
  background: #123024;
  align-self: start;
}
.tower-art svg {
  width: 100%;
  display: block;
}
.tower-info {
  padding: 15px 0;
}
.tower-info > .eyebrow {
  font-size: 9px;
  letter-spacing: 1.5px;
}
.tower-info > h3 {
  font-size: 27px;
  letter-spacing: 3px;
  color: #ead3a3;
  margin: 17px 0 15px;
}
.tower-records {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 0;
  border-block: 1px solid #bba16b40;
}
.tower-records > span {
  font-size: 10px;
  color: #9eb595;
}
.tower-records b {
  display: block;
  font: 23px var(--serif);
  color: #e2c78e;
  margin-top: 8px;
}
.tower-party {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 22px 0;
}
.tower-party > div {
  display: flex;
  gap: 11px;
  align-items: center;
  padding: 8px;
  background: #0b292144;
  border: 1px solid #9ea26c20;
  border-radius: 3px;
}
.tower-party .portrait {
  width: 38px;
  height: 57px;
}
.tower-party > div > span {
  flex: 1;
  min-width: 0;
}
.tower-party b {
  font: 14px var(--serif);
  color: #e1d0a6;
}
.tower-party small {
  display: block;
  color: #9cb18f;
  font-size: 8px;
  margin-top: 7px;
}
.tower-health {
  display: block;
  height: 3px;
  background: #123228;
  margin-top: 8px;
}
.tower-health em {
  display: block;
  height: 100%;
  background: #a6c28c;
}
.tower-party .exhausted {
  filter: grayscale(1);
  opacity: 0.5;
}
.tower-rule {
  font-size: 10px;
  color: #9cb391;
  line-height: 2;
  margin: 18px 0;
}
.tower-boons {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 17px;
}
.tower-boons span {
  font-size: 9px;
  color: #d9c58d;
  padding: 7px;
  border: 1px solid #bca36a40;
  background: #c9ad6409;
  border-radius: 2px;
}
.tower-boons > small {
  color: #92ac89;
  font-size: 9px;
  line-height: 1.8;
}
.tower-blessing {
  border-top: 1px solid #c3aa7044;
  margin: 24px 0 0;
  padding-top: 23px;
}
.tower-blessing > h3 {
  font-size: 20px;
  color: #e1c993;
  letter-spacing: 2px;
  margin-bottom: 18px;
}
.tower-blessing > div {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.tower-blessing button {
  text-align: left;
  padding: 20px;
  background: linear-gradient(135deg, #40523655, #123225);
  border-color: #bca56a70;
}
.tower-blessing button > span {
  font: 37px var(--serif);
  color: #d9ba7a;
  display: block;
  margin-bottom: 19px;
}
.tower-blessing b {
  font: 19px var(--serif);
  letter-spacing: 2px;
  color: #ecd3a0;
}
.tower-blessing p {
  font-size: 11px;
  color: #b2c4a0;
  line-height: 1.9;
  margin-top: 14px;
}
.tower-blessing.standalone {
  border: 0;
  padding: 0;
  margin-bottom: 22px;
}
.tower-source {
  font-size: 10px;
  margin-top: 24px;
  border-top: 1px solid #bca36b33;
  padding-top: 17px;
}
.tower-chest {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 23px 0;
  padding: 23px;
  background: radial-gradient(ellipse at left, #d0ae6420, transparent);
  border: 1px solid #ccac674a;
}
.tower-chest > .item-icon {
  width: 58px;
  height: 64px;
  font-size: 32px;
}
.tower-chest small {
  font-size: 9px;
  color: #b2c39e;
  letter-spacing: 2px;
}
.tower-chest h3 {
  font-size: 25px;
  color: #edd3a0;
  letter-spacing: 3px;
  margin: 8px 0;
}
.tower-chest p {
  font-size: 11px;
  color: #b5c6a4;
}
.modal-foot {
  flex-wrap: wrap;
}
@media (max-width: 760px) {
  .tower-layout {
    grid-template-columns: 95px 1fr;
    gap: 16px;
  }
  .tower-art {
    margin-top: 12px;
  }
  .tower-info {
    padding-top: 8px;
  }
  .tower-info > .eyebrow {
    font-size: 7px;
    letter-spacing: 0;
  }
  .tower-info > h3 {
    font-size: 20px;
    letter-spacing: 1px;
    line-height: 1.5;
    margin: 10px 0;
  }
  .tower-info .intro-text {
    font-size: 9px;
    line-height: 1.9;
    margin-bottom: 14px;
  }
  .tower-records {
    gap: 8px;
    padding: 14px 0;
  }
  .tower-records > span {
    font-size: 7px;
  }
  .tower-records b {
    font-size: 17px;
    margin-top: 7px;
  }
  .tower-party {
    grid-template-columns: 1fr;
    gap: 7px;
    margin: 15px 0;
  }
  .tower-party > div {
    padding: 5px 7px;
    gap: 9px;
  }
  .tower-party .portrait {
    width: 25px;
    height: 40px;
  }
  .tower-party b {
    font-size: 12px;
  }
  .tower-party small {
    font-size: 7px;
    margin-top: 4px;
  }
  .tower-health {
    margin-top: 6px;
  }
  .tower-rule {
    font-size: 8px;
    line-height: 1.9;
  }
  .tower-boons span {
    font-size: 7px;
    padding: 6px;
  }
  .tower-boons > small {
    font-size: 8px;
  }
  .tower-blessing > div {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .tower-blessing button {
    padding: 17px;
    display: grid;
    grid-template-columns: 42px 1fr;
    column-gap: 14px;
  }
  .tower-blessing button > span {
    grid-row: span 2;
    font-size: 33px;
    margin: 0;
    align-self: center;
  }
  .tower-blessing b {
    font-size: 18px;
  }
  .tower-blessing p {
    font-size: 10px;
    margin-top: 9px;
  }
  .tower-blessing > h3 {
    font-size: 17px;
    letter-spacing: 1px;
  }
  .tower-source {
    font-size: 9px;
    margin-top: 20px;
  }
  .tower-chest {
    padding: 17px;
    gap: 15px;
  }
  .tower-chest > .item-icon {
    width: 47px;
    height: 53px;
    font-size: 27px;
  }
  .tower-chest h3 {
    font-size: 22px;
  }
  .tower-chest p {
    font-size: 10px;
  }
  .tower-entry > button {
    padding: 16px;
    gap: 14px;
  }
  .tower-entry b {
    font-size: 17px;
    letter-spacing: 1px;
  }
  .tower-entry small {
    font-size: 8px;
  }
  .tower-entry > button > span {
    font-size: 29px;
  }
  .game-shell:has(.command-strip:not([hidden])) .objective {
    display: none;
  }
  .game-shell:has(.command-strip:not([hidden])) .scene-controls {
    top: 12px;
    bottom: auto;
    right: 10px;
    gap: 4px;
  }
  .game-shell:has(.command-strip:not([hidden])) .scene-button {
    font-size: 10px;
    min-height: 44px;
    padding: 8px 10px;
  }
  .journal-tip {
    font-size: 9px;
    color: #a8bb99;
    line-height: 1.9;
    margin-top: 13px;
    padding-top: 12px;
    border-top: 1px solid #ab9c6427;
  }
}
.title-recovery {
  max-width: 410px;
  color: #e4c59d;
  font-size: 11px;
  line-height: 1.8;
  margin-top: 14px;
}
.title-recovery button,
.damaged-notice button {
  padding: 8px 10px;
  min-height: 40px;
  color: #efd6a1;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.damaged-notice {
  margin-top: 14px;
  color: #c9b395;
  font-size: 11px;
  line-height: 1.8;
}
.combat-report {
  margin-top: 22px;
  border: 1px solid #bda36b38;
  background: #102b242d;
  border-radius: 5px;
}
.combat-report > summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  cursor: pointer;
  padding: 17px 20px;
  min-height: 52px;
  list-style: none;
}
.combat-report > summary::-webkit-details-marker {
  display: none;
}
.combat-report > summary > span {
  font: 18px var(--serif);
  color: #e7d09a;
}
.combat-report > summary > small {
  font-size: 10px;
  color: #b9c2a6;
}
.combat-report > summary > i {
  margin-left: auto;
  font-style: normal;
  font-size: 10px;
  color: #c2b184;
}
.combat-report[open] > summary > i {
  font-size: 0;
}
.combat-report[open] > summary > i::after {
  content: "收起 ↑";
  font-size: 10px;
}
.combat-report-body {
  padding: 0 20px 18px;
}
.combat-report-body > p:first-child {
  font-size: 10px;
  color: #aebda4;
  display: flex;
  gap: 6px;
  align-items: center;
  margin: 0 0 10px;
}
.combat-report-body > p:first-child > b {
  color: #d8b675;
  font-weight: 400;
}
.combat-report-body > p:first-child > em {
  color: #8fc3a5;
  font-style: normal;
}
.combat-report-body > p:first-child > span {
  margin-left: auto;
}
.combat-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-top: 1px solid #d6c28e17;
}
.combat-row > .portrait {
  width: 40px;
  height: 60px;
  object-fit: contain;
}
.combat-row-main {
  flex: 1;
  min-width: 0;
}
.combat-row-main > div:first-child {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 7px;
}
.combat-row-main b {
  font: 15px var(--serif);
  color: #ecdaa8;
}
.combat-row-main small {
  font-size: 9px;
  color: #9caf98;
}
.contribution-bar {
  display: flex;
  height: 5px;
  background: #15342b;
  border-radius: 3px;
  overflow: hidden;
}
.contribution-bar i {
  background: linear-gradient(90deg, #9b854f, #dbc180);
}
.contribution-bar em {
  background: linear-gradient(90deg, #74a98d, #a4d1b5);
}
.combat-numbers {
  display: flex;
  gap: 16px;
  font-size: 10px;
  color: #d3c29c;
  margin-top: 7px;
  flex-wrap: wrap;
}
.combat-numbers span:nth-child(2) {
  color: #a3c9ad;
}
.combat-row-main .combat-extra {
  display: block;
  margin-top: 5px;
  font-size: 9px;
}
.combat-report-note {
  color: #93a48c;
  font-size: 9px;
  line-height: 1.8;
  margin: 10px 0 0;
}
.combat-supply {
  font-size: 10px;
  color: #b4c8a7;
  margin: 10px 0;
}
.combat-supply b {
  color: #d8c590;
}
@media (max-width: 600px) {
  .combat-report > summary {
    padding: 14px;
    gap: 7px;
  }
  .combat-report > summary > span {
    font-size: 16px;
  }
  .combat-report > summary > small {
    font-size: 9px;
  }
  .combat-report-body {
    padding: 0 14px 14px;
  }
  .combat-row {
    gap: 8px;
  }
  .combat-row > .portrait {
    width: 31px;
  }
  .combat-numbers {
    gap: 10px;
    font-size: 9px;
  }
}
.invitation-intro {
  padding: 8px 0 26px;
  border-bottom: 1px solid #beab7533;
  margin-bottom: 25px;
}
.invitation-intro h3 {
  font: 32px/1.5 var(--serif);
  letter-spacing: 3px;
  color: #ecdaaa;
  margin: 12px 0;
}
.invitation-intro p {
  max-width: 580px;
  font-size: 12px;
  color: #b9c6aa;
  line-height: 2;
}
.invitation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.invitation-card {
  display: flex;
  gap: 15px;
  border: 1px solid #bba16b42;
  border-radius: 5px;
  padding: 22px 18px;
  background: linear-gradient(135deg, #2d49372e, #112e2826);
}
.invitation-card.joined {
  border-color: #a2bc825e;
}
.invitation-portrait {
  display: flex;
  align-items: center;
  flex-direction: column;
  min-width: 77px;
  justify-content: center;
}
.invitation-portrait .portrait {
  height: 125px;
  width: 90px;
  object-fit: contain;
  filter: drop-shadow(0 7px 8px #0a1f1c);
}
.invitation-portrait > span {
  font-size: 9px;
  letter-spacing: 2px;
  color: #adbc9d;
  margin-top: 12px;
}
.invitation-card.joined .invitation-portrait > span {
  color: #e5d29c;
}
.invitation-copy {
  flex: 1;
  min-width: 0;
}
.invitation-copy > small {
  font-size: 9px;
  color: #c9b883;
  letter-spacing: 2px;
}
.invitation-copy h3 {
  font: 26px var(--serif);
  color: #ead7a4;
  margin: 7px 0 10px;
  letter-spacing: 2px;
}
.invitation-copy > p {
  font-size: 10px;
  line-height: 1.8;
  color: #b5c1a5;
  margin-bottom: 13px;
}
.invitation-gate {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 10px;
  color: #8a9c89;
}
.invitation-gate .met {
  color: #bfc99f;
}
.invitation-copy > .invitation-level {
  display: block;
  margin: 13px 0;
  font-size: 8px;
  letter-spacing: 0;
  color: #a9b49a;
}
.invitation-copy > button {
  font-size: 10px;
  min-height: 42px;
  padding: 10px 15px;
}
.invitation-source {
  font-size: 10px;
  line-height: 1.9;
  color: #94a48b;
  margin-top: 23px;
}
@media (max-width: 600px) {
  .invitation-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .invitation-intro h3 {
    font-size: 27px;
  }
  .invitation-intro p {
    font-size: 11px;
  }
  .invitation-card {
    padding: 20px 15px;
    gap: 17px;
  }
  .invitation-copy h3 {
    font-size: 24px;
  }
  .invitation-portrait .portrait {
    height: 130px;
    width: 80px;
  }
  .invitation-copy > button {
    min-height: 44px;
  }
  .route-tabs {
    gap: 5px;
  }
  .route-tabs button {
    padding: 10px 12px;
    font-size: 11px;
    min-height: 44px;
  }
}
.party-presets {
  margin-top: 25px;
  border-top: 1px solid #bba36e3a;
  padding-top: 20px;
}
.party-presets > summary {
  cursor: pointer;
  font: 20px var(--serif);
  color: #e0c991;
  padding: 8px 0;
}
.party-presets > summary small {
  font: 10px system-ui;
  color: #a6b29a;
  margin-left: 12px;
}
.party-presets > p {
  font-size: 10px;
  color: #aab99e;
  line-height: 1.9;
  margin: 12px 0 18px;
}
.party-preset-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.party-preset {
  border: 1px solid #b7a26d3a;
  border-radius: 4px;
  padding: 16px;
  background: #1231284d;
}
.party-preset label {
  display: block;
  font-size: 10px;
  color: #bcbe9c;
}
.party-preset input {
  display: block;
  width: 100%;
  margin-top: 8px;
  border: 1px solid #bba36e52;
  border-radius: 3px;
  background: #0f2a23;
  color: #ead7a6;
  min-height: 40px;
  padding: 10px;
  font: 14px var(--serif);
}
.party-preset input::placeholder {
  font: 10px system-ui;
  color: #82967f;
}
.party-preset > p {
  font-size: 10px;
  color: #d3d2b1;
  line-height: 1.8;
  min-height: 35px;
  margin: 12px 0 7px;
}
.party-preset > small {
  display: block;
  line-height: 1.7;
  color: #a5b497;
  font-size: 9px;
}
.party-preset > div {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 15px;
}
.party-preset button {
  font-size: 9px;
  min-height: 40px;
  padding: 8px 11px;
}
@media (max-width: 600px) {
  .party-preset-grid {
    grid-template-columns: 1fr;
  }
  .party-presets > summary {
    font-size: 18px;
  }
  .party-presets > summary small {
    display: block;
    margin: 7px 0 0;
  }
  .party-preset {
    padding: 16px;
  }
  .party-preset > p {
    min-height: 0;
  }
  .party-preset button {
    min-height: 44px;
  }
}
.region-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.region-card {
  padding: 0;
  text-align: left;
  overflow: hidden;
  background: #12342b;
  border: 1px solid #b5a16c50;
}
.region-card > div {
  height: 145px;
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  isolation: isolate;
}
.region-card > div::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, #102c2830, #102c28a3);
  z-index: -1;
}
.region-card > div > span {
  font: 50px var(--serif);
  color: #f0d99e;
  text-shadow: 0 2px 10px #18382b;
}
.region-card > div > small {
  position: absolute;
  left: 16px;
  bottom: 12px;
  color: #e1d4ae;
  font-size: 10px;
  letter-spacing: 1px;
}
.region-card > section {
  padding: 20px;
}
.region-card h3 {
  font: 23px var(--serif);
  color: #e9d7a5;
  margin-bottom: 10px;
  letter-spacing: 2px;
}
.region-card p {
  font-size: 11px;
  line-height: 1.9;
  color: #b6c3a4;
  min-height: 42px;
}
.region-card section > b {
  display: block;
  font-size: 10px;
  color: #d8c590;
  margin-top: 13px;
  font-weight: 400;
}
.region-card.locked {
  opacity: 0.5;
  filter: saturate(0.5);
}
.exploration-source {
  font-size: 10px;
  color: #9eae93;
  line-height: 1.9;
  margin-top: 22px;
}
.field-journal-list article {
  display: flex;
  gap: 18px;
  border-top: 1px solid #c5ae7433;
  padding: 22px 0;
}
.field-journal-list article > span {
  font: 25px var(--serif);
  color: #a9b494;
  min-width: 30px;
  text-align: center;
  padding-top: 3px;
}
.field-journal-list article.found > span {
  color: #d9c28a;
}
.field-journal-list article > div {
  flex: 1;
  min-width: 0;
}
.field-journal-list small {
  font-size: 9px;
  color: #a8b394;
  letter-spacing: 2px;
}
.field-journal-list h3 {
  font: 21px var(--serif);
  color: #e4d1a0;
  margin: 7px 0 10px;
}
.field-journal-list p {
  font-size: 12px;
  color: #bac7aa;
  line-height: 1.9;
}
.field-journal-list button {
  min-height: 42px;
  font-size: 10px;
  margin-top: 12px;
  padding: 9px 15px;
}
.riddle-heading {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 5px 0 25px;
}
.riddle-heading > span {
  font: 60px var(--serif);
  color: #d9bd81;
  border: 1px solid #c7ab6c55;
  padding: 12px 20px;
}
.riddle-heading small {
  font-size: 10px;
  color: #b8bd9b;
  letter-spacing: 3px;
}
.riddle-heading h3 {
  font: 25px/1.5 var(--serif);
  color: #ead5a1;
  margin-top: 9px;
}
.riddle-clues {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
  margin-bottom: 22px;
}
.riddle-clues article {
  padding: 18px;
  background: #12322880;
  border: 1px dashed #a7ad7a40;
  border-radius: 4px;
}
.riddle-clues article.found {
  border-style: solid;
  border-color: #b6a46c55;
}
.riddle-clues b {
  font: 17px var(--serif);
  color: #ddc995;
}
.riddle-clues p {
  font-size: 11px;
  color: #b8c5a7;
  line-height: 1.9;
  margin-top: 11px;
}
.riddle-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
}
.riddle-options > button {
  display: flex;
  align-items: center;
  gap: 20px;
  text-align: left;
  padding: 17px 20px;
  min-height: 64px;
}
.riddle-options > button > span {
  font: 27px var(--serif);
  color: #d8c18a;
}
.riddle-options > button > b {
  font-weight: 400;
  font-size: 13px;
  line-height: 1.8;
}
.game-shell[data-mode="explore"] .scene-controls {
  top: 16px;
  bottom: auto;
}
@media (max-width: 600px) {
  .region-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .region-card > div {
    height: 120px;
  }
  .region-card > section {
    padding: 17px;
  }
  .region-card h3 {
    font-size: 22px;
  }
  .field-journal-list article {
    gap: 12px;
    padding: 19px 0;
  }
  .field-journal-list p {
    font-size: 11px;
  }
  .field-journal-list button {
    min-height: 44px;
  }
  .riddle-heading {
    gap: 15px;
  }
  .riddle-heading > span {
    font-size: 38px;
    padding: 12px 15px;
  }
  .riddle-heading h3 {
    font-size: 20px;
  }
  .riddle-clues {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .riddle-clues article {
    padding: 15px;
  }
  .riddle-options > button {
    gap: 12px;
    padding: 13px 15px;
  }
  .riddle-options > button > b {
    font-size: 11px;
  }
  .game-shell[data-mode="explore"] .objective {
    display: none;
  }
  .game-shell[data-mode="explore"] .scene-controls {
    top: 12px;
    right: 10px;
  }
  .game-shell[data-mode="explore"] .scene-button {
    min-height: 44px;
    font-size: 10px;
    padding: 8px 12px;
  }
}
.inventory-tools {
  margin: 20px 0 18px;
}
.item-filters {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.item-filters button {
  padding: 9px 17px;
  background: transparent;
  border-color: #b5a46c38;
  color: #aebb9e;
  font-size: 11px;
  min-height: 40px;
}
.item-filters button.selected {
  color: #ecd7a1;
  border-color: #cfb47990;
  background: #bca56916;
}
.item-search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px;
  gap: 15px;
}
.item-search-row label {
  font-size: 9px;
  color: #aeb99b;
  letter-spacing: 1px;
}
.item-search-row input,
.item-search-row select {
  display: block;
  width: 100%;
  margin-top: 7px;
  padding: 11px 12px;
  min-height: 44px;
  border: 1px solid #b4a26d4d;
  background: #102c25;
  color: #ead9ad;
  border-radius: 4px;
  font: 12px system-ui;
  color-scheme: dark;
}
.item-search-row input::placeholder {
  font-size: 11px;
  color: #8da087;
}
#item-count {
  font-size: 10px;
  color: #9eac91;
  margin-top: 12px;
}
.item-comparison {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin: 8px 0;
  font-size: 10px;
  color: #9dae96;
}
.item-comparison span {
  padding: 3px 6px;
  background: #13332980;
  border-radius: 3px;
}
.item-comparison .gain {
  color: #a8d8ad;
}
.item-comparison .loss {
  color: #ebaf9c;
  background: #533b2a35;
}
.item-comparison.current {
  color: #d8c48b;
}
@media (max-width: 600px) {
  .item-filters {
    gap: 6px;
  }
  .item-filters button {
    padding: 9px 11px;
    min-height: 44px;
    font-size: 10px;
  }
  .item-search-row {
    grid-template-columns: minmax(0, 1fr) 105px;
    gap: 10px;
  }
  .item-search-row input,
  .item-search-row select {
    font-size: 11px;
    padding: 10px 9px;
  }
  .item-search-row input::placeholder {
    font-size: 9px;
  }
  .item-comparison {
    font-size: 9px;
    gap: 4px;
  }
}
.recipient-item {
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 0 0 25px;
  margin-bottom: 22px;
  border-bottom: 1px solid #bda66d3d;
}
.recipient-item > .item-icon {
  font-size: 38px;
  width: 75px;
  height: 82px;
}
.recipient-item small {
  font-size: 10px;
  color: #b4bea0;
}
.recipient-item h3 {
  font: 27px var(--serif);
  color: #ead7a2;
  margin: 7px 0 9px;
}
.recipient-item p {
  font-size: 11px;
  color: #c2c7a8;
}
.recipient-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 15px;
}
.recipient-card {
  display: flex;
  gap: 16px;
  align-items: center;
  border: 1px solid #bca76c3d;
  border-radius: 4px;
  padding: 19px;
  background: #13322859;
}
.recipient-card.current {
  border-color: #c9b47788;
}
.recipient-card > .portrait {
  height: 93px;
  width: 65px;
  object-fit: contain;
}
.recipient-card > div {
  flex: 1;
  min-width: 0;
}
.recipient-card small {
  font-size: 9px;
  color: #aebe9d;
}
.recipient-card h3 {
  font: 21px var(--serif);
  color: #e9d39c;
  margin: 7px 0 9px;
}
.recipient-card h3 small {
  font: 9px system-ui;
  margin-left: 10px;
}
.recipient-card button {
  font-size: 10px;
  min-height: 42px;
  padding: 9px 15px;
  margin-top: 8px;
}
@media (max-width: 600px) {
  .recipient-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .recipient-card {
    padding: 17px;
    gap: 13px;
  }
  .recipient-card button {
    min-height: 44px;
  }
  .recipient-item {
    gap: 14px;
  }
  .recipient-item h3 {
    font-size: 24px;
  }
}
.party-rage {
  display: block;
  height: 3px;
  background: #102923;
  border-radius: 2px;
  overflow: hidden;
  margin-top: 4px;
}
.party-rage i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #9b8148, #e5c786);
  transition: width 0.2s;
}
.ultimate-status {
  display: block;
  font-size: 9px;
  line-height: 1.7;
  color: #c4b487;
  margin-top: 3px;
}
.party-hero:disabled {
  opacity: 1;
}
.party-hero.ultimate-ready::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid #d6b671b3;
  border-radius: 4px;
  box-shadow: inset 0 0 18px #d5b46b1a;
  pointer-events: none;
}
.party-hero.ultimate-ready .ultimate-status {
  color: #f0d392;
}
.party-hero.ultimate-queued::before {
  border-color: #91cfb5;
  box-shadow: inset 0 0 18px #8ec8ad1c;
}
.party-hero.ultimate-queued .ultimate-status {
  color: #a6dec4;
}
.ultimate-mode {
  background: #28453963;
  border-color: #b8a16763;
  color: #d5c18e;
  min-height: 34px;
  font-size: 10px;
  padding: 7px 11px;
  align-self: flex-start;
}
.ultimate-mode[aria-pressed="true"] {
  background: #bda56d1c;
  color: #eed399;
  border-color: #d8b774a6;
}
.battle-hero-profile {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 7px 0 22px;
}
.battle-hero-profile .portrait {
  height: 150px;
  width: 110px;
  object-fit: contain;
}
.battle-hero-profile h3 {
  font: 30px var(--serif);
  color: #ead4a0;
  letter-spacing: 3px;
  margin: 10px 0 12px;
}
.battle-hero-profile p {
  font-size: 12px;
  color: #c3cbaa;
  line-height: 1.9;
}
.battle-manual {
  font-size: 11px;
  color: #b9c4a4;
  margin: 15px 0;
}
@media (max-width: 600px) {
  .tactic-resource {
    flex-wrap: wrap;
    gap: 6px 10px;
  }
  .ultimate-mode {
    min-height: 44px;
    align-self: center;
    font-size: 9px;
    padding: 7px 11px;
  }
  .ultimate-status {
    font-size: 7px;
    letter-spacing: 0;
    line-height: 1.5;
  }
  .party-rage {
    margin-top: 3px;
    height: 2px;
  }
  .battle-hero-profile {
    gap: 17px;
  }
  .battle-hero-profile .portrait {
    height: 125px;
    width: 85px;
  }
  .battle-hero-profile h3 {
    font-size: 26px;
  }
  .battle-hero-profile p {
    font-size: 10px;
  }
}

@media (max-width: 600px) {
  .game-shell[data-mode="battle"] .party-name small {
    display: none;
  }
}
@media (max-width: 380px) {
  .party-hero > .portrait {
    width: 24px;
    height: 44px;
  }
  .party-hero {
    padding: 5px 3px;
    gap: 2px;
  }
  .party-name {
    font-size: 11px;
  }
  .game-shell:not([data-mode="battle"]) .party-name {
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
  }
}
.practice-entry {
  margin: 20px 0 12px;
}
.practice-entry > button {
  width: 100%;
  display: flex;
  align-items: center;
  text-align: left;
  gap: 20px;
  padding: 20px 24px;
  border-color: #a7c19a66;
  background: linear-gradient(120deg, #45624842, #173b2d25);
}
.practice-entry > button > span {
  font: 35px var(--serif);
  color: #b9d1a6;
  border-right: 1px solid #b4b77c3d;
  padding-right: 20px;
}
.practice-entry > button > div {
  flex: 1;
}
.practice-entry b {
  display: block;
  font: 22px var(--serif);
  color: #d3d8ae;
  letter-spacing: 3px;
}
.practice-entry small {
  display: block;
  font-size: 10px;
  color: #aabe9b;
  margin-top: 8px;
}
.practice-entry em {
  font-style: normal;
  color: #c4cfaa;
  font-size: 20px;
}
.practice-intro {
  margin: 4px 0 27px;
  padding-bottom: 24px;
  border-bottom: 1px solid #bfa9713a;
}
.practice-intro h3 {
  font: 32px/1.5 var(--serif);
  color: #e4d4a3;
  letter-spacing: 2px;
  margin: 12px 0;
}
.practice-intro p {
  font-size: 12px;
  line-height: 2;
  color: #b9c7a9;
  max-width: 610px;
}
.practice-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.practice-course {
  display: flex;
  text-align: left;
  gap: 19px;
  align-items: center;
  padding: 22px 19px;
  background: #16372b6e;
  border-color: #b8a66d45;
}
.practice-course > span {
  font: 35px var(--serif);
  color: #c7c594;
  min-width: 38px;
  text-align: center;
}
.practice-course > div {
  flex: 1;
  min-width: 0;
}
.practice-course small {
  font-size: 9px;
  letter-spacing: 2px;
  color: #a6b79a;
}
.practice-course h3 {
  font: 20px var(--serif);
  color: #e2d0a1;
  margin: 8px 0 10px;
}
.practice-course p {
  font-size: 11px;
  line-height: 1.9;
  color: #b0bea0;
}
.practice-course b {
  display: block;
  margin-top: 12px;
  font-size: 10px;
  font-weight: 400;
  color: #cec391;
}
.practice-course.completed {
  border-color: #9fbd8c70;
}
.practice-source {
  font-size: 10px;
  line-height: 1.9;
  color: #98ad91;
  margin-top: 24px;
}
.practice-lesson {
  display: flex;
  align-items: center;
  gap: 22px;
  margin: 3px 0 23px;
}
.practice-lesson > span {
  font: 52px var(--serif);
  color: #d3c28a;
  padding: 12px 20px;
  border: 1px solid #b4ad7257;
}
.practice-lesson small {
  font-size: 9px;
  color: #abb999;
  letter-spacing: 2px;
}
.practice-lesson h3 {
  font: 24px/1.5 var(--serif);
  color: #e7d3a0;
  margin-top: 9px;
}
.practice-instructions {
  font-size: 11px;
  line-height: 2.1;
  color: #b9c5aa;
  padding-left: 20px;
  margin: 20px 0;
}
.practice-result {
  padding: 8px 0 20px;
  text-align: center;
}
.practice-result > span {
  display: block;
  font: 74px var(--serif);
  color: #cfbc85;
  margin: 8px 0 18px;
}
.practice-result small {
  font-size: 10px;
  letter-spacing: 2px;
  color: #aebf9e;
}
.practice-result h3 {
  font: 29px var(--serif);
  color: #ead4a0;
  margin: 18px 0;
}
.practice-result p {
  font-size: 13px;
  color: #c1c9ab;
  line-height: 2.1;
  max-width: 540px;
  margin: 0 auto;
  text-align: left;
}
.tactic-resource > .practice-cue {
  max-width: 210px;
  color: #e5d498;
  line-height: 1.9;
  font-size: 10px;
}
@media (max-width: 600px) {
  .practice-grid {
    grid-template-columns: 1fr;
    gap: 13px;
  }
  .practice-intro h3 {
    font-size: 27px;
  }
  .practice-intro p {
    font-size: 11px;
  }
  .practice-course {
    padding: 18px 16px;
    gap: 14px;
  }
  .practice-course h3 {
    font-size: 19px;
  }
  .practice-entry > button {
    padding: 16px;
    gap: 14px;
  }
  .practice-entry b {
    font-size: 19px;
  }
  .practice-lesson {
    gap: 15px;
  }
  .practice-lesson > span {
    font-size: 36px;
    padding: 12px 15px;
  }
  .practice-lesson h3 {
    font-size: 20px;
  }
  .practice-result h3 {
    font-size: 25px;
  }
  .practice-result p {
    font-size: 12px;
  }
  .tactic-resource > .practice-cue {
    flex-basis: 100%;
    max-width: none;
    font-size: 10px;
    text-align: center;
  }
}
.volume-control {
  display: block;
  margin: 21px 0 5px;
  font-size: 11px;
  color: #bdc5a5;
}
.volume-control > span {
  float: right;
  color: #e0c894;
  font-size: 11px;
}
.volume-control input {
  display: block;
  width: 100%;
  accent-color: #d0b57a;
  min-height: 40px;
  margin: 7px 0 0;
  cursor: pointer;
}
@media (max-width: 600px) {
  .volume-control input {
    min-height: 44px;
  }
}

/* Mobile readability: preserve original scene proportions; keep controls outside the art. */
@media (max-width: 600px) {
  .party-strip {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 5px;
    padding: 7px 8px;
  }
  .party-hero {
    max-width: none;
    min-height: 84px;
    justify-content: flex-start;
    padding: 7px 8px;
    gap: 7px;
    border: 1px solid #b9a27222;
    border-radius: 4px;
  }
  .party-hero::after {
    display: none;
  }
  .party-hero > .portrait,
  .game-shell:has(.command-strip:not([hidden])) .party-hero > .portrait {
    width: 39px;
    height: 62px;
  }
  .party-name {
    font-size: 14px;
    gap: 3px;
  }
  .party-name small,
  .game-shell[data-mode="battle"] .party-name small {
    display: inline;
    font: 9px system-ui;
  }
  .game-shell:not([data-mode="battle"]) .party-name {
    flex-direction: row;
    align-items: center;
  }
  .party-role {
    font-size: 11px;
    line-height: 1.5;
    margin-top: 4px;
  }
  .ultimate-status {
    font-size: 10px;
    line-height: 1.5;
  }
  .party-rage {
    height: 3px;
    margin-top: 4px;
  }
  .tiny-bar {
    margin-top: 5px;
  }
  .party-empty {
    max-width: none;
    min-height: 84px;
    height: auto;
  }
  .party-empty small {
    font-size: 10px;
  }
  .command-buttons small {
    font-size: 10px;
    line-height: 1.6;
  }
  .command-buttons em {
    font-size: 10px;
  }
  .tactic-resource > span,
  .tactic-resource > small {
    font-size: 10px;
  }
  .ultimate-mode {
    font-size: 11px;
  }
  .nav-button {
    font-size: 10px;
    letter-spacing: 0;
  }
  .scene-button {
    min-height: 40px;
    font-size: 11px;
  }
  .mobile-journal .enemy-targets b {
    font-size: 13px;
  }
  .mobile-journal .enemy-targets small {
    font-size: 10px;
    line-height: 1.7;
  }
  .mobile-journal .enemy-targets > button {
    min-height: 78px;
  }
  .mobile-journal .journal-lines p {
    font-size: 11px;
  }
  .mobile-journal .journal-tip {
    font-size: 12px;
    line-height: 1.9;
  }
}
@media (max-width: 380px) {
  .topbar {
    padding-inline: 8px;
    gap: 8px;
  }
}
@media (max-width: 600px) {
  .game-shell:has(.command-strip:not([hidden])) .scene-controls,
  .game-shell[data-mode="explore"] .scene-controls {
    position: relative;
    inset: auto;
    justify-content: flex-end;
    padding: 8px 10px;
    background: #142f29;
    border-top: 1px solid #bdac7c33;
  }
  .game-shell[data-mode="battle"] .battle-pause {
    bottom: 61px;
  }
  .game-shell[data-mode="explore"] .world-hint {
    display: none;
  }
}
@media (max-width: 600px) {
  .topbar {
    height: auto;
    min-height: 86px;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 4px 12px;
    padding: 8px 12px;
  }
  .brand {
    grid-column: 1;
    grid-row: 1;
  }
  .top-actions {
    grid-column: 2;
    grid-row: 1;
    gap: 6px;
  }
  .top-actions button {
    width: 44px;
    height: 44px;
    font-size: 18px;
  }
  .resources {
    grid-column: 1 / -1;
    grid-row: 2;
    margin-left: 0;
    justify-content: space-between;
    gap: 8px;
  }
  .resources > span {
    display: flex;
    gap: 5px;
  }
  .resources i {
    font-size: 17px;
  }
  .resources b {
    font-size: 13px;
    letter-spacing: 0;
  }
  .resources small {
    font-size: 10px;
    margin-top: 0;
  }
  .stage-wrap canvas,
  .game-shell:has(.command-strip:not([hidden])) .stage-wrap canvas {
    aspect-ratio: 1000 / 640;
  }
}

/* The pause notice never intercepts character targeting. Resume is in the control bar. */
.battle-pause strong {
  font: 27px var(--serif);
  color: #ead5a1;
  letter-spacing: 7px;
  text-shadow: 0 2px 9px #102d27;
}
.battle-pause p {
  text-align: center;
  line-height: 1.8;
}
@media (max-width: 600px) {
  button,
  .game-shell button,
  dialog button {
    min-width: 44px;
    min-height: 44px;
  }
  .close-button {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
  }
}

.stored-equipment {
  padding: 17px 19px;
  margin: 12px 0 20px;
  border: 1px solid #c1a56d66;
  background: #b69e6710;
  border-radius: 5px;
}
.stored-equipment h3 {
  font: 19px var(--serif);
  color: #e8d19c;
  margin-bottom: 10px;
}
.stored-equipment p {
  font-size: 12px;
  line-height: 1.9;
  color: #bdc8aa;
}
.stored-equipment small {
  display: block;
  font-size: 11px;
  color: #aabc9e;
  margin-top: 6px;
}
.stored-equipment > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid #b2a27433;
  margin-top: 13px;
  padding-top: 13px;
}
.stored-equipment b {
  font-size: 13px;
  color: #e1cfaa;
}
