:root {
  --night: #071b17;
  --night-deep: #03100e;
  --glass: rgba(8, 31, 26, .78);
  --glass-heavy: rgba(7, 27, 23, .92);
  --glass-line: rgba(225, 203, 151, .24);
  --jade-glow: #89c2a7;
  --gold-bright: #f0d99b;
  --gold-dim: #a9884e;
  --parallax-x: 0px;
  --parallax-y: 0px;
}

body {
  background: var(--night-deep);
}

.landing {
  background-position: center;
  animation: landing-in 1.1s ease-out both;
}

.landing::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 48% -25% -20%;
  opacity: .42;
  background:
    radial-gradient(ellipse at 25% 55%, rgba(231, 239, 221, .38), transparent 34%),
    radial-gradient(ellipse at 68% 50%, rgba(220, 232, 214, .28), transparent 35%);
  filter: blur(24px);
  animation: mist-drift 18s ease-in-out infinite alternate;
  pointer-events: none;
}

.landing__content {
  animation: title-rise .9s .15s cubic-bezier(.2,.8,.2,1) both;
}

.seal {
  position: relative;
  overflow: hidden;
  background: rgba(7, 29, 24, .28);
  backdrop-filter: blur(8px);
}

.seal::after {
  content: "";
  position: absolute;
  inset: -80% auto -80% -45%;
  width: 28%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.24), transparent);
  transform: rotate(18deg);
  animation: seal-shine 5.5s 1.4s ease-in-out infinite;
}

.game-shell {
  min-height: 100vh;
  min-height: 100dvh;
  padding: 0;
  overflow: hidden;
  background: var(--night-deep);
  isolation: isolate;
}

.topbar {
  position: relative;
  z-index: 40;
  display: grid;
  height: 76px;
  padding: 0 clamp(18px, 2.4vw, 38px);
  grid-template-columns: 280px 1fr 280px;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(8,31,26,.98), rgba(12,45,37,.92) 48%, rgba(8,31,26,.98)),
    repeating-linear-gradient(90deg, transparent 0 28px, rgba(240,217,155,.025) 29px 30px);
  border-bottom: 1px solid rgba(226, 202, 145, .2);
  box-shadow: 0 10px 36px rgba(0,0,0,.26);
}

.topbar::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  opacity: .45;
  background: linear-gradient(90deg, transparent 4%, var(--gold-dim) 26%, transparent 48%, var(--gold-dim) 74%, transparent 96%);
}

.brand {
  display: flex;
  width: max-content;
  padding: 0;
  align-items: center;
  gap: 12px;
  color: var(--paper);
  background: none;
  border: 0;
  cursor: pointer;
  text-align: left;
}

.brand > i {
  display: grid;
  width: 38px;
  height: 38px;
  color: #18382f;
  background: linear-gradient(145deg, #f3dfa8, #a98245);
  border: 1px solid #f4e1ad;
  border-radius: 50% 50% 46% 54%;
  box-shadow: 0 0 24px rgba(224, 190, 112, .2);
  place-items: center;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 20px;
  font-style: normal;
}

.brand > span {
  display: grid;
  gap: 1px;
}

.brand b {
  color: #f2e6c9;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 25px;
  font-weight: 400;
  letter-spacing: .18em;
}

.brand small {
  color: rgba(231, 216, 181, .38);
  font: 7px/1.2 Georgia, serif;
  letter-spacing: .18em;
}

.time {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
}

.time > span {
  width: min(8vw, 92px);
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(226,202,145,.32));
}

.time > span:last-child {
  transform: scaleX(-1);
}

.time > div {
  display: grid;
  min-width: 205px;
}

.time small {
  color: var(--gold-bright);
  font-size: 8px;
  letter-spacing: .28em;
}

.time b {
  margin-top: 4px;
  color: rgba(245, 236, 214, .72);
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: .12em;
}

.top-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.top-actions > button:not(.sound-button) {
  display: grid;
  width: 54px;
  padding: 7px 4px;
  place-items: center;
  gap: 3px;
  color: rgba(244, 234, 211, .62);
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: color .2s, transform .2s;
}

.top-actions > button:not(.sound-button):hover {
  color: var(--gold-bright);
  transform: translateY(-2px);
}

.top-actions > button > i {
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 16px;
  font-style: normal;
}

.top-actions > button > span {
  font-size: 9px;
  letter-spacing: .12em;
}

.sound-button {
  display: flex;
  width: 40px;
  height: 40px;
  padding: 0;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: rgba(229, 205, 151, .05);
  border: 1px solid rgba(229, 205, 151, .18);
  border-radius: 50%;
  cursor: pointer;
}

.sound-button i {
  width: 2px;
  height: 10px;
  background: var(--gold-bright);
  border-radius: 2px;
  animation: sound-wave 1.1s ease-in-out infinite alternate;
}

.sound-button i:nth-child(2) { height: 16px; animation-delay: -.5s; }
.sound-button i:nth-child(3) { height: 7px; animation-delay: -.8s; }

.game-layout {
  position: relative;
  display: block;
  width: 100%;
  min-height: calc(100vh - 76px);
  min-height: calc(100dvh - 76px);
  margin: 0;
}

.world-stage {
  position: relative;
  min-height: calc(100vh - 76px);
  min-height: calc(100dvh - 76px);
  overflow: hidden;
  isolation: isolate;
  background: #0b211c;
}

.world-stage__art {
  position: absolute;
  z-index: -6;
  inset: -3%;
  background-position: center;
  background-size: cover;
  filter: saturate(.94) contrast(1.02);
  transform: translate3d(var(--parallax-x), var(--parallax-y), 0) scale(1.07);
  animation: landscape-reveal 1.15s cubic-bezier(.16,.8,.22,1) both;
  transition: transform .4s ease-out;
  will-change: transform;
}

.world-stage[data-location="sect"] .world-stage__art { background-image: url("./assets/images/style-baseline.png"); }
.world-stage[data-location="village"] .world-stage__art { background-image: url("./assets/images/location-village.png"); }
.world-stage[data-location="market"] .world-stage__art { background-image: url("./assets/images/location-market.png"); }
.world-stage[data-location="valley"] .world-stage__art { background-image: url("./assets/images/location-valley.png"); }
.world-stage[data-location="cavern"] .world-stage__art { background-image: url("./assets/images/location-cavern.png"); }

.world-stage__shade {
  position: absolute;
  z-index: -5;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(2,15,12,.78) 0, rgba(3,18,15,.2) 25%, transparent 46%, rgba(3,17,14,.12) 69%, rgba(2,14,12,.72) 100%),
    linear-gradient(180deg, rgba(3,16,13,.1) 0, rgba(3,16,13,.04) 34%, rgba(3,16,13,.34) 66%, rgba(2,12,10,.88) 100%);
  pointer-events: none;
}

.world-stage[data-location="valley"] .world-stage__shade,
.world-stage[data-location="cavern"] .world-stage__shade {
  background:
    linear-gradient(90deg, rgba(1,8,12,.82), transparent 33%, transparent 66%, rgba(1,7,11,.76)),
    linear-gradient(180deg, rgba(1,8,12,.08), rgba(1,8,12,.3) 65%, rgba(1,7,10,.94));
}

.world-stage__light {
  position: absolute;
  z-index: -4;
  top: -45%;
  left: 34%;
  width: 38%;
  height: 125%;
  opacity: .18;
  background: linear-gradient(90deg, transparent, rgba(255, 239, 196, .54), transparent);
  filter: blur(38px);
  transform: rotate(12deg);
  animation: light-breathe 9s ease-in-out infinite alternate;
  pointer-events: none;
}

.world-stage[data-location="valley"] .world-stage__light,
.world-stage[data-location="cavern"] .world-stage__light {
  opacity: .12;
  background: linear-gradient(90deg, transparent, rgba(127, 201, 235, .65), transparent);
}

.world-stage__mist {
  position: absolute;
  z-index: -3;
  right: -25%;
  bottom: -24%;
  left: -25%;
  height: 54%;
  opacity: .32;
  background:
    radial-gradient(ellipse at 18% 50%, rgba(232,239,222,.6), transparent 28%),
    radial-gradient(ellipse at 48% 72%, rgba(231,238,224,.48), transparent 32%),
    radial-gradient(ellipse at 80% 50%, rgba(222,234,220,.48), transparent 28%);
  filter: blur(30px);
  pointer-events: none;
  will-change: transform;
}

.world-stage__mist--one { animation: mist-one 20s ease-in-out infinite alternate; }
.world-stage__mist--two { bottom: 6%; opacity: .18; transform: scale(.82); animation: mist-two 26s ease-in-out infinite alternate; }

.spirit-particles {
  position: absolute;
  z-index: -2;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.spirit-particles i {
  position: absolute;
  top: var(--y);
  left: var(--x);
  width: 3px;
  height: 3px;
  opacity: .2;
  background: #f5e2a8;
  border-radius: 50%;
  box-shadow: 0 0 8px 2px rgba(238, 213, 149, .34);
  transform: scale(var(--scale));
  animation: spirit-rise var(--duration) var(--delay) ease-in-out infinite;
}

.world-stage[data-location="valley"] .spirit-particles i,
.world-stage[data-location="cavern"] .spirit-particles i {
  background: #8bd4ee;
  box-shadow: 0 0 8px 2px rgba(98, 193, 228, .42);
}

.world-stage__location {
  position: absolute;
  z-index: 5;
  top: clamp(24px, 4vh, 46px);
  left: clamp(290px, 22vw, 360px);
  display: grid;
  min-width: 160px;
  padding-left: 16px;
  color: white;
  border-left: 2px solid var(--gold-bright);
  text-shadow: 0 3px 14px rgba(0,0,0,.72);
  animation: location-enter .7s .12s ease-out both;
}

.world-stage__location::before {
  content: "";
  position: absolute;
  top: 0;
  left: -5px;
  width: 8px;
  height: 8px;
  background: var(--gold-bright);
  border-radius: 50%;
  box-shadow: 0 0 16px rgba(240,217,155,.7);
}

.world-stage__location > span {
  color: rgba(246,237,216,.58);
  font-size: 9px;
  letter-spacing: .2em;
}

.world-stage__location > b {
  margin: 3px 0 6px;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 30px;
  font-weight: 400;
  letter-spacing: .08em;
}

.world-stage__location > div {
  display: flex;
  align-items: center;
  gap: 4px;
}

.world-stage__location > div i {
  width: 4px;
  height: 4px;
  background: var(--cinnabar);
  border-radius: 50%;
}

.world-stage__location > div em {
  margin-left: 5px;
  color: rgba(246,237,216,.46);
  font-size: 8px;
  font-style: normal;
  letter-spacing: .1em;
}

.status-card {
  position: absolute;
  z-index: 12;
  top: 26px;
  bottom: 26px;
  left: 24px;
  width: 244px;
  padding: 22px 18px;
  overflow: hidden;
  color: var(--paper);
  background:
    linear-gradient(145deg, rgba(14,50,41,.9), rgba(5,24,20,.84)),
    repeating-linear-gradient(0deg, transparent 0 6px, rgba(255,255,255,.016) 7px 8px);
  border: 1px solid var(--glass-line);
  border-radius: 3px 18px 3px 18px;
  box-shadow: 0 24px 64px rgba(0,0,0,.34), inset 0 0 42px rgba(78,139,113,.06);
  backdrop-filter: blur(18px) saturate(1.1);
  animation: status-enter .65s cubic-bezier(.2,.75,.2,1) both;
}

.status-card::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid rgba(229,205,151,.08);
  border-radius: 2px 14px 2px 14px;
  pointer-events: none;
}

.ornament {
  position: absolute;
  width: 48px;
  height: 48px;
  opacity: .34;
  pointer-events: none;
}

.ornament::before,
.ornament::after {
  content: "";
  position: absolute;
  background: var(--gold-bright);
}

.ornament::before { width: 48px; height: 1px; }
.ornament::after { width: 1px; height: 48px; }
.ornament--tl { top: 10px; left: 10px; }
.ornament--br { right: 10px; bottom: 10px; transform: rotate(180deg); }

.status-card__head {
  position: relative;
  display: grid;
  grid-template-columns: 54px 1fr auto;
  align-items: center;
  gap: 12px;
  margin: 4px 0 18px;
}

.avatar-sigil {
  position: relative;
  display: grid;
  width: 52px;
  height: 52px;
  color: var(--gold-bright);
  background: radial-gradient(circle, #386554 0, #173e34 56%, #0a2821 100%);
  border: 1px solid rgba(238,214,156,.44);
  border-radius: 50%;
  place-items: center;
  box-shadow: 0 0 0 4px rgba(231,205,145,.04), 0 0 24px rgba(93,160,132,.16);
}

.avatar-sigil span {
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 22px;
}

.avatar-sigil i {
  position: absolute;
  inset: -6px;
  border: 1px dashed rgba(230,207,153,.2);
  border-radius: 50%;
  animation: rune-spin 24s linear infinite;
}

.status-card__head p {
  margin: 0;
  color: rgba(241,230,207,.48);
  font-size: 9px;
  letter-spacing: .08em;
}

.status-card__head h2 {
  margin: 3px 0 0;
  color: #f5ecd9;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 21px;
  font-weight: 400;
  letter-spacing: .12em;
}

.status-card .icon-button--small {
  width: 28px;
  height: 28px;
  color: var(--gold-bright);
  background: rgba(232,205,143,.05);
  border-color: rgba(232,205,143,.18);
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 12px;
}

.status-card__divider {
  display: flex;
  margin: 0 0 14px;
  align-items: center;
  gap: 8px;
  color: rgba(229,205,151,.25);
  font: 7px Georgia, serif;
  letter-spacing: .16em;
}

.status-card__divider::before,
.status-card__divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, rgba(229,205,151,.18));
}

.status-card__divider::after { transform: scaleX(-1); }

.realm-line {
  display: flex;
  margin: 0 0 18px;
  align-items: flex-end;
  justify-content: space-between;
}

.realm-line > div {
  display: grid;
  gap: 2px;
}

.realm-line small {
  color: rgba(238,227,202,.38);
  font-size: 8px;
  letter-spacing: .12em;
}

.realm-line span {
  color: var(--gold-bright);
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 19px;
}

.realm-line > b {
  display: grid;
  color: #a9d4bd;
  text-align: right;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 14px;
  font-weight: 400;
}

.realm-line > b em {
  color: rgba(211,229,219,.35);
  font: 7px system-ui, sans-serif;
  font-style: normal;
  letter-spacing: .12em;
}

.status-card .resource {
  margin: 13px 0;
}

.resource > div:first-child {
  display: flex;
  margin-bottom: 6px;
  align-items: baseline;
  justify-content: space-between;
  color: rgba(245,237,218,.48);
  font-size: 9px;
  letter-spacing: .08em;
}

.resource b {
  color: rgba(248,240,222,.85);
  font-size: 11px;
  font-weight: 500;
}

.resource b em {
  color: rgba(248,240,222,.32);
  font-size: 8px;
  font-style: normal;
  font-weight: 400;
}

.meter {
  position: relative;
  height: 5px;
  overflow: visible;
  background: rgba(255,255,255,.07);
  border-radius: 10px;
}

.meter__fill {
  position: relative;
  z-index: 2;
  display: block;
  height: 100%;
  border-radius: inherit;
  transition: width .7s cubic-bezier(.2,.8,.2,1);
}

.meter__glow {
  position: absolute;
  z-index: 1;
  inset: -3px 0;
  opacity: .14;
  background: currentColor;
  filter: blur(5px);
}

.meter__fill--hp { background: linear-gradient(90deg, #914a42, #dd7f6c); box-shadow: 0 0 8px rgba(221,127,108,.25); }
.meter__fill--mana { background: linear-gradient(90deg, #397083, #75b7ca); box-shadow: 0 0 8px rgba(117,183,202,.25); }
.meter__fill--cultivation { background: linear-gradient(90deg, #997331, #eccb76); box-shadow: 0 0 8px rgba(236,203,118,.25); }
.meter__fill--enemy { background: linear-gradient(90deg, #7d302b, #d26353); }

.currency-row {
  display: grid;
  margin: 20px 0 16px;
  padding: 13px 0;
  grid-template-columns: repeat(3, 1fr);
  border-block: 1px solid rgba(230,209,163,.1);
}

.currency-row span {
  display: grid;
  gap: 4px;
  text-align: center;
}

.currency-row span + span { border-left: 1px solid rgba(230,209,163,.09); }
.currency-row small { color: rgba(240,230,207,.35); font-size: 8px; letter-spacing: .08em; }
.currency-row b { color: var(--gold-bright); font-family: Georgia, serif; font-size: 14px; font-weight: 400; }

.location-chip {
  display: grid;
  width: 100%;
  padding: 12px;
  grid-template-columns: 30px 1fr auto;
  align-items: center;
  gap: 9px;
  color: inherit;
  text-align: left;
  background: rgba(2,18,14,.3);
  border: 1px solid rgba(227,207,161,.13);
  border-radius: 2px 9px 2px 9px;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s;
}

.location-chip:hover {
  transform: translateY(-2px);
  background: rgba(74,123,102,.12);
  border-color: rgba(227,207,161,.3);
}

.location-chip__mark {
  display: grid;
  width: 28px;
  height: 28px;
  color: var(--gold-bright);
  border: 1px solid rgba(227,207,161,.22);
  border-radius: 50%;
  place-items: center;
  font-family: "STKaiti", "KaiTi", serif;
  font-style: normal;
}

.location-chip > span {
  display: grid;
  color: rgba(240,230,207,.38);
  font-size: 8px;
}

.location-chip > span small {
  margin-top: 2px;
  color: rgba(240,230,207,.25);
  font-size: 7px;
}

.location-chip > b {
  grid-column: 2;
  grid-row: 1;
  margin-top: 13px;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 14px;
  font-weight: 400;
}

.location-chip > em {
  grid-column: 3;
  grid-row: 1;
  color: var(--gold-bright);
  font-size: 20px;
  font-style: normal;
}

.action-dock {
  position: absolute;
  z-index: 12;
  top: 50%;
  right: 24px;
  width: 184px;
  padding: 14px 10px;
  color: var(--paper);
  background: linear-gradient(155deg, rgba(12,45,37,.86), rgba(5,24,20,.82));
  border: 1px solid var(--glass-line);
  border-radius: 16px 3px 16px 3px;
  box-shadow: 0 24px 64px rgba(0,0,0,.3), inset 0 0 34px rgba(93,153,127,.05);
  backdrop-filter: blur(18px) saturate(1.1);
  transform: translateY(-50%);
  animation: actions-enter .65s .08s cubic-bezier(.2,.75,.2,1) both;
}

.action-dock::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(229,205,151,.07);
  border-radius: 12px 2px 12px 2px;
  pointer-events: none;
}

.action-dock > p {
  display: flex;
  margin: 2px 8px 8px;
  align-items: flex-end;
  justify-content: space-between;
}

.action-dock > p span { color: var(--gold-bright); font: 14px "STKaiti", "KaiTi", serif; letter-spacing: .12em; }
.action-dock > p small { color: rgba(238,222,186,.28); font: 6px Georgia, serif; letter-spacing: .14em; }

.action-dock > button {
  position: relative;
  display: grid;
  width: 100%;
  min-height: 55px;
  padding: 7px 9px;
  grid-template-columns: 35px 1fr auto;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-align: left;
  background: transparent;
  border: 0;
  border-top: 1px solid rgba(230,209,163,.07);
  cursor: pointer;
  transition: background .2s, transform .2s;
}

.action-dock > button:hover {
  z-index: 2;
  background: linear-gradient(90deg, rgba(229,205,151,.11), transparent);
  transform: translateX(-4px);
}

.action-dock > button > i {
  display: grid;
  width: 32px;
  height: 32px;
  color: var(--gold-bright);
  background: radial-gradient(circle, rgba(197,164,87,.13), transparent 70%);
  border: 1px solid rgba(216,188,121,.2);
  border-radius: 50%;
  place-items: center;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 15px;
  font-style: normal;
  transition: transform .35s, box-shadow .35s;
}

.action-dock > button:hover > i {
  box-shadow: 0 0 18px rgba(231,202,133,.2);
  transform: rotate(12deg) scale(1.06);
}

.action-dock > button > span { display: grid; gap: 2px; }
.action-dock > button b { color: #f1e6cb; font-size: 11px; letter-spacing: .08em; }
.action-dock > button small { color: rgba(242,232,209,.34); font-size: 8px; }
.action-dock > button > em { color: rgba(237,219,177,.2); font: 7px Georgia, serif; font-style: normal; }
.action-dock > button.is-ready > i { animation: ready-pulse 2s ease-in-out infinite; }

.story-wrap {
  position: absolute;
  z-index: 14;
  right: 232px;
  bottom: 92px;
  left: 286px;
  pointer-events: none;
}

.scene-card,
.combat-card {
  position: relative;
  max-width: 820px;
  margin: 0 auto;
  padding: 22px 26px 20px;
  overflow: hidden;
  color: var(--paper);
  background:
    linear-gradient(140deg, rgba(7,31,26,.94), rgba(10,41,34,.86)),
    repeating-linear-gradient(0deg, transparent 0 4px, rgba(255,255,255,.013) 5px 6px);
  border: 1px solid rgba(238,216,166,.28);
  border-radius: 3px 20px 3px 20px;
  box-shadow: 0 28px 80px rgba(0,0,0,.42), inset 0 0 60px rgba(77,137,112,.055);
  backdrop-filter: blur(20px) saturate(1.12);
  animation: scene-reveal .52s cubic-bezier(.2,.8,.2,1) both;
  pointer-events: auto;
}

.scene-card::before {
  content: "";
  position: absolute;
  inset: 7px;
  width: auto;
  height: auto;
  margin: 0;
  background: none;
  border: 1px solid rgba(234,211,158,.07);
  border-radius: 2px 15px 2px 15px;
  pointer-events: none;
}

.scene-card--danger { border-color: rgba(213,112,91,.46); }
.scene-card--mystery { border-color: rgba(168,148,198,.42); }
.scene-card--wealth { border-color: rgba(224,185,94,.48); }

.scene-card__corner {
  position: absolute;
  width: 48px;
  height: 48px;
  opacity: .32;
  pointer-events: none;
}

.scene-card__corner::before,
.scene-card__corner::after {
  content: "";
  position: absolute;
  background: var(--gold-bright);
}

.scene-card__corner::before { width: 48px; height: 1px; }
.scene-card__corner::after { width: 1px; height: 48px; }
.scene-card__corner--tl { top: 10px; left: 10px; }
.scene-card__corner--br { right: 10px; bottom: 10px; transform: rotate(180deg); }

.scene-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.scene-card__kicker {
  margin: 0;
  color: var(--gold-bright);
  font-size: 8px;
  letter-spacing: .24em;
}

.scene-card h1 {
  margin: 4px 0 0;
  color: #fff7e7;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: clamp(24px, 2.4vw, 33px);
  font-weight: 400;
  letter-spacing: .08em;
}

.scene-card__seal {
  display: grid;
  width: 36px;
  height: 36px;
  color: rgba(255,240,208,.9);
  background: rgba(161,65,52,.62);
  border: 1px solid rgba(245,196,177,.36);
  border-radius: 3px;
  place-items: center;
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 17px;
  transform: rotate(3deg);
}

.scene-card--wealth .scene-card__seal { background: rgba(151,112,39,.7); }
.scene-card--mystery .scene-card__seal { background: rgba(95,77,130,.72); }

.scene-card__rule {
  display: grid;
  margin: 12px 0 10px;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 8px;
  color: rgba(236,211,153,.42);
  font-size: 6px;
}

.scene-card__rule i { height: 1px; background: linear-gradient(90deg, rgba(236,211,153,.34), transparent); }
.scene-card__rule i:last-child { transform: scaleX(-1); }

.scene-card__text {
  margin: 0;
  color: rgba(250,242,224,.76);
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 15px;
  line-height: 1.78;
  letter-spacing: .035em;
}

.scene-choices {
  display: grid;
  margin-top: 16px;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 8px;
}

.story-choice {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 58px;
  padding: 8px 11px;
  grid-template-columns: 26px 1fr auto;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-align: left;
  background: linear-gradient(110deg, rgba(246,229,189,.06), rgba(255,255,255,.018));
  border: 1px solid rgba(235,217,177,.12);
  border-radius: 2px 8px 2px 8px;
  cursor: pointer;
  transition: border-color .2s, background .2s, transform .2s, box-shadow .2s;
}

.story-choice::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 2px;
  opacity: 0;
  background: var(--gold-bright);
  transition: opacity .2s;
}

.story-choice:hover {
  z-index: 2;
  background: linear-gradient(110deg, rgba(246,229,189,.12), rgba(255,255,255,.035));
  border-color: rgba(235,217,177,.32);
  box-shadow: 0 8px 24px rgba(0,0,0,.18);
  transform: translateY(-2px);
}

.story-choice:hover::before { opacity: 1; }
.story-choice > span { color: rgba(237,215,165,.48); font: 8px Georgia, serif; letter-spacing: .06em; }
.story-choice > b { overflow: hidden; color: #f2e7ce; font-size: 11px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.story-choice > small { grid-column: 2; color: rgba(242,232,209,.34); font-size: 8px; }
.story-choice > i { grid-column: 3; grid-row: 1 / 3; color: rgba(240,217,160,.56); font-size: 19px; font-style: normal; transition: transform .2s; }
.story-choice:hover > i { transform: translateX(3px); }

.free-action {
  position: absolute;
  z-index: 15;
  right: 232px;
  bottom: 18px;
  left: 286px;
  display: grid;
  width: auto;
  max-width: 820px;
  margin: 0 auto;
  gap: 5px;
}

.free-action label {
  color: rgba(244,232,207,.42);
  font-size: 8px;
  letter-spacing: .09em;
  text-shadow: 0 2px 8px rgba(0,0,0,.6);
}

.free-action label span {
  margin-right: 6px;
  color: var(--gold-bright);
  font-family: "STKaiti", "KaiTi", serif;
  font-size: 11px;
}

.free-action > div {
  position: relative;
  display: grid;
  grid-template-columns: 38px 1fr auto;
  overflow: hidden;
  background: rgba(5,23,19,.76);
  border: 1px solid rgba(232,214,174,.18);
  border-radius: 2px 12px 2px 12px;
  box-shadow: 0 12px 34px rgba(0,0,0,.2);
  backdrop-filter: blur(14px);
}

.free-action > div > i {
  display: grid;
  color: var(--gold-bright);
  background: rgba(229,204,144,.06);
  border-right: 1px solid rgba(229,204,144,.12);
  place-items: center;
  font-family: "STKaiti", "KaiTi", serif;
  font-style: normal;
}

.free-action input {
  min-width: 0;
  min-height: 44px;
  padding: 0 13px;
  color: var(--paper);
  background: transparent;
  border: 0;
  border-radius: 0;
  outline: 0;
}

.free-action input::placeholder { color: rgba(240,230,208,.26); }
.free-action input:focus { box-shadow: inset 0 -1px var(--gold-dim); }

.free-action button {
  display: flex;
  padding: 0 16px;
  align-items: center;
  gap: 8px;
  color: var(--gold-bright);
  background: linear-gradient(90deg, rgba(176,137,64,.08), rgba(176,137,64,.17));
  border: 0;
  border-left: 1px solid rgba(221,190,121,.2);
  border-radius: 0;
  cursor: pointer;
}

.free-action button i { font-style: normal; transition: transform .2s; }
.free-action button:hover i { transform: translateX(3px); }
.free-action :disabled { opacity: .38; cursor: not-allowed; }

.combat-card {
  max-width: 720px;
  border-color: rgba(216,109,88,.42);
}

.combat-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.combat-card__head p { margin: 0; color: rgba(239,217,187,.5); font-size: 8px; letter-spacing: .14em; }
.combat-card__head h2 { margin: 4px 0 10px; color: #fff2e1; font-family: "STKaiti", "KaiTi", serif; font-size: 30px; font-weight: 400; }
.combat-card__head > span { padding: 4px 8px; color: #f4c9bd; border: 1px solid rgba(207,97,79,.4); font-size: 8px; letter-spacing: .12em; }
.combat-message { min-height: 42px; margin: 14px 0; color: rgba(247,237,218,.72); font-family: "STKaiti", "KaiTi", serif; line-height: 1.65; }
.combat-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.combat-actions button { display: grid; min-height: 66px; padding: 8px; place-items: center; color: inherit; background: rgba(255,255,255,.035); border: 1px solid rgba(235,216,176,.12); border-radius: 2px 7px 2px 7px; cursor: pointer; transition: .2s; }
.combat-actions button:hover { background: rgba(187,84,68,.13); border-color: rgba(221,126,105,.4); transform: translateY(-2px); }
.combat-actions b { font-family: "STKaiti", "KaiTi", serif; font-size: 20px; font-weight: 400; }
.combat-actions span { color: rgba(242,232,210,.42); font-size: 8px; }

.mobile-tabs { display: none; }

.panel-backdrop {
  background: rgba(1,12,10,.72);
  backdrop-filter: blur(6px);
}

.side-panel {
  width: min(540px, 94vw);
  color: #263c36;
  background:
    linear-gradient(rgba(248,242,226,.96), rgba(224,214,192,.98)),
    repeating-linear-gradient(0deg, transparent 0 4px, rgba(39,76,64,.035) 5px 6px);
  border-left: 1px solid rgba(234,211,158,.42);
  box-shadow: -36px 0 100px rgba(0,0,0,.44);
  animation: panel-unroll .36s cubic-bezier(.2,.8,.2,1);
}

.side-panel > header {
  position: relative;
  min-height: 96px;
  padding: 18px 22px 16px 30px;
  background:
    linear-gradient(110deg, #103a30, #08251f),
    repeating-linear-gradient(90deg, transparent 0 24px, rgba(255,255,255,.018) 25px 26px);
  border-bottom: 1px solid var(--gold-dim);
}

.side-panel > header::after {
  content: "";
  position: absolute;
  right: 64px;
  bottom: 15px;
  width: 80px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(238,214,156,.4), transparent);
}

.side-panel > header h2 { font-size: 27px; letter-spacing: .08em; }
.side-panel__body { height: calc(100% - 96px); padding: 28px; }

.map-place,
.inventory-list article,
.people-list article,
.save-grid button,
.import-button {
  border-radius: 2px 10px 2px 10px;
  transition: border-color .2s, background .2s, transform .2s;
}

.map-place:hover,
.inventory-list article:hover,
.people-list article:hover,
.save-grid button:hover,
.import-button:hover {
  transform: translateY(-2px);
}

.map-place.is-current {
  box-shadow: inset 3px 0 var(--jade-500);
}

.mobile-tabs button i {
  font-family: "STKaiti", "KaiTi", serif;
  font-style: normal;
}

@keyframes landing-in { from { opacity: 0; } }
@keyframes title-rise { from { opacity: 0; transform: translateY(22px); } }
@keyframes seal-shine { 0%,72% { left: -45%; } 100% { left: 130%; } }
@keyframes mist-drift { to { transform: translate3d(8%, -4%, 0) scale(1.08); } }
@keyframes sound-wave { to { transform: scaleY(.45); opacity: .45; } }
@keyframes landscape-reveal { from { opacity: 0; filter: saturate(.7) blur(5px); transform: scale(1.12); } }
@keyframes light-breathe { to { opacity: .3; transform: rotate(16deg) translateX(10%); } }
@keyframes mist-one { to { transform: translate3d(9%, -7%, 0) scale(1.06); } }
@keyframes mist-two { to { transform: translate3d(-8%, 5%, 0) scale(.92); } }
@keyframes spirit-rise { 0%,100% { opacity: 0; transform: translateY(18px) scale(var(--scale)); } 28% { opacity: .46; } 72% { opacity: .2; } 100% { transform: translateY(-70px) translateX(16px) scale(var(--scale)); } }
@keyframes location-enter { from { opacity: 0; transform: translateX(-14px); } }
@keyframes status-enter { from { opacity: 0; transform: translateX(-24px); } }
@keyframes actions-enter { from { opacity: 0; transform: translate(24px,-50%); } }
@keyframes scene-reveal { from { opacity: 0; transform: translateY(22px) scale(.985); } }
@keyframes rune-spin { to { transform: rotate(360deg); } }
@keyframes ready-pulse { 50% { color: white; border-color: rgba(240,217,155,.62); box-shadow: 0 0 22px rgba(230,198,124,.26); } }
@keyframes panel-unroll { from { opacity: .5; transform: translateX(52px); } }

@media (max-width: 1280px) {
  .status-card { left: 16px; width: 220px; }
  .action-dock { right: 16px; width: 168px; }
  .story-wrap,
  .free-action { right: 200px; left: 250px; }
  .world-stage__location { left: 258px; }
}

@media (max-width: 1020px) {
  .topbar { grid-template-columns: 220px 1fr 180px; }
  .status-card { display: none; }
  .story-wrap,
  .free-action { left: 28px; }
  .world-stage__location { left: 30px; }
  .action-dock { width: 158px; }
}

@media (max-width: 760px) {
  .game-shell { overflow: visible; }
  .topbar {
    height: 60px;
    padding: 0 12px;
    grid-template-columns: auto 1fr auto;
  }
  .brand { gap: 8px; }
  .brand > i { width: 32px; height: 32px; font-size: 17px; }
  .brand b { font-size: 19px; letter-spacing: .08em; }
  .brand small { display: none; }
  .time { gap: 0; }
  .time > span,
  .time small { display: none; }
  .time > div { min-width: 0; }
  .time b { margin: 0; font-size: 10px; letter-spacing: .06em; white-space: nowrap; }
  .top-actions > button:not(.sound-button) { display: none; }
  .sound-button { width: 34px; height: 34px; }
  .game-layout,
  .world-stage { min-height: calc(100vh - 60px); min-height: calc(100dvh - 60px); }
  .world-stage__art { inset: -2%; background-position: center; transform: scale(1.06); }
  .world-stage__shade {
    background: linear-gradient(180deg, rgba(2,15,12,.08), rgba(2,15,12,.16) 36%, rgba(2,14,12,.52) 62%, rgba(2,12,10,.96) 100%);
  }
  .world-stage__mist { opacity: .22; }
  .status-card,
  .action-dock { display: none; }
  .world-stage__location { top: 18px; left: 18px; padding-left: 11px; }
  .world-stage__location > b { font-size: 24px; }
  .world-stage__location > div { display: none; }
  .story-wrap { right: 9px; bottom: 116px; left: 9px; }
  .scene-card,
  .combat-card { max-width: none; padding: 18px 16px 15px; border-radius: 2px 14px 2px 14px; }
  .scene-card h1 { font-size: 24px; }
  .scene-card__seal { width: 31px; height: 31px; font-size: 15px; }
  .scene-card__text { max-height: 102px; overflow-y: auto; font-size: 13px; line-height: 1.68; }
  .scene-card__rule { margin: 9px 0 8px; }
  .scene-choices { max-height: 184px; grid-template-columns: 1fr; overflow-x: hidden; overflow-y: auto; }
  .story-choice { min-height: 48px; grid-template-columns: 24px 1fr auto; }
  .story-choice > small { display: none; }
  .story-choice > i { grid-row: 1; }
  .free-action { right: 9px; bottom: 64px; left: 9px; }
  .free-action label { display: none; }
  .free-action > div { grid-template-columns: 34px 1fr auto; }
  .free-action input { min-height: 44px; font-size: 11px; }
  .free-action button { padding: 0 12px; font-size: 11px; }
  .free-action button i { display: none; }
  .mobile-tabs {
    position: fixed;
    z-index: 50;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    height: calc(58px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    grid-template-columns: repeat(5, 1fr);
    background: rgba(5,25,21,.96);
    border-top: 1px solid rgba(231,206,150,.2);
    box-shadow: 0 -12px 36px rgba(0,0,0,.3);
    backdrop-filter: blur(18px);
  }
  .mobile-tabs::before {
    content: "";
    position: absolute;
    top: -1px;
    right: 10%;
    left: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-dim), transparent);
  }
  .mobile-tabs button {
    display: grid;
    padding: 5px 2px;
    place-items: center;
    gap: 1px;
    color: rgba(242,232,210,.52);
    background: none;
    border: 0;
    font-size: 8px;
  }
  .mobile-tabs button i { color: var(--gold-bright); font-size: 15px; }
  .side-panel { width: 100vw; }
  .combat-actions { grid-template-columns: repeat(4, 1fr); }
  .combat-actions button { min-height: 54px; }
  .combat-actions span { display: none; }
}

@media (max-width: 420px) {
  .brand > i { display: none; }
  .scene-card__text { max-height: 86px; }
  .scene-choices { max-height: 165px; }
  .free-action button span { white-space: nowrap; }
  .side-panel__body { padding: 20px 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .landing,
  .landing__content,
  .landing::after,
  .seal::after,
  .world-stage__art,
  .world-stage__light,
  .world-stage__mist,
  .spirit-particles i,
  .avatar-sigil i,
  .sound-button i,
  .status-card,
  .action-dock,
  .scene-card,
  .world-stage__location {
    animation: none !important;
  }
  .world-stage__art { transform: scale(1.04); }
}
