* {
  box-sizing: border-box;
}
html,
body,
main {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
body {
  background: #141716;
  color: #e6e3d8;
  font-family: Georgia, "Times New Roman", serif;
}
main {
  position: relative;
  isolation: isolate;
}
canvas,
#shade,
#wound,
#white {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
canvas {
  pointer-events: auto;
  touch-action: none;
}
#shade {
  background:
    linear-gradient(
      90deg,
      rgba(9, 12, 12, 0.91),
      rgba(11, 14, 14, 0.78) 23%,
      rgba(11, 14, 14, 0.3) 45%,
      transparent 62%
    ),
    linear-gradient(0deg, #0d1011, transparent 21%, transparent 86%, #141716aa);
}
.playing #shade {
  background:
    radial-gradient(ellipse at center, transparent 50%, #090a0b60),
    linear-gradient(0deg, #0b0c0c9a, transparent 24%);
}
header {
  position: absolute;
  inset: 0 4.5% auto;
  height: 75px;
  display: flex;
  align-items: center;
  gap: 13px;
  border-bottom: 1px solid #c2b89333;
  color: #e3d8bf;
}
.crest {
  width: 29px;
  height: 35px;
  color: #bda679;
}
.crest svg {
  height: 100%;
  fill: currentColor;
}
.brand,
small,
.eyebrow,
#titlefoot,
nav,
dt,
.primary,
#hint,
#act {
  font-family: Arial, sans-serif;
}
.brand {
  font: 600 12px Georgia;
  letter-spacing: 0.24em;
}
nav {
  margin-left: auto;
  display: flex;
  gap: 18px;
  align-items: center;
}
button {
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}
button:focus-visible {
  outline: 2px solid #e7c47a;
  outline-offset: 4px;
}
nav button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 2px;
  font: 12px Arial;
  color: #e0dccf;
}
nav i {
  height: 14px;
  border-left: 1px solid #99998065;
}
nav svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}
nav [aria-pressed="false"] svg {
  opacity: 0.65;
}
.keyicon {
  font-size: 20px;
}
#title {
  position: absolute;
  left: 8.5%;
  top: 50%;
  transform: translateY(-46%);
}
.eyebrow,
#caption small,
#items small {
  font: 600 10px Arial;
  letter-spacing: 0.23em;
  color: #d3ba87;
}
.eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
}
.eyebrow b,
#caption b {
  display: inline-block;
  width: 34px;
  height: 1px;
  background: #c6aa75;
}
h1 {
  font-weight: 400;
  font-size: clamp(72px, min(9vw, 16vh), 152px);
  line-height: 0.8;
  letter-spacing: -0.06em;
  margin: 26px 0 21px;
  text-shadow: 0 2px 12px #12141455;
  color: #e9e5d8;
}
h1 em {
  font-style: normal;
  color: #cebc95;
}
.orn {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #ae9469;
  width: 175px;
  font-size: 19px;
}
.orn b {
  width: 38%;
  height: 1px;
  background: #a38c626b;
}
.orn b:last-child {
  flex: 1;
}
#title p {
  font-size: clamp(14px, 1.35vw, 20px);
  line-height: 1.55;
  color: #c5c2b7;
  margin: 13px 0 24px;
}
.primary {
  border: 1px solid #ab956c;
  background: #333027d9;
  box-shadow:
    inset 0 0 0 3px #191b19,
    inset 0 0 0 4px #87765765;
  padding: 15px 21px;
  color: #ede2c8;
  display: inline-flex;
  align-items: center;
  gap: 38px;
  font: 16px Georgia;
}
.primary:hover {
  background: #544831;
}
.primary span + span {
  font-size: 21px;
  line-height: 12px;
}
#caption {
  position: absolute;
  right: 7%;
  bottom: 16%;
  text-align: right;
  text-shadow: 0 2px 7px #000;
}
#caption small,
#caption strong {
  display: block;
}
#caption b {
  margin: 0 0 10px;
}
#caption small {
  font-size: 9px;
}
#caption strong {
  font-weight: 400;
  font-size: clamp(17px, 2vw, 28px);
  margin-top: 5px;
}
#titlefoot {
  position: absolute;
  left: 4.5%;
  bottom: 25px;
  font: italic 13px Georgia;
  color: #aea799;
}
#titlefoot span {
  font-style: normal;
  color: #cfb27d;
  border: 1px solid #746c55;
  padding: 3px 6px;
}
#hud {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.playing header {
  border: 0;
  height: 50px;
}
.playing header .brand,
.playing header .crest {
  visibility: hidden;
}
.playing header nav {
  z-index: 1;
}
#meters {
  position: absolute;
  left: 4%;
  top: 5%;
  display: flex;
  align-items: center;
}
.humanity {
  background: radial-gradient(#39403d, #111917 60%, #9c8864 64%, #151719 72%);
  border: 2px ridge #ad9573;
  border-radius: 50%;
  width: 52px;
  height: 52px;
  text-align: center;
  line-height: 46px;
  font-size: 24px;
  text-shadow: 0 2px #000;
  z-index: 1;
}
.bars {
  margin-left: -6px;
}
.bar {
  height: 12px;
  border: 2px ridge #a79578;
  background: #231b1b;
  position: relative;
  box-shadow: 0 1px 3px #080908;
}
.bar b,
.bar s {
  display: block;
  height: 100%;
  position: absolute;
  left: 0;
  top: 0;
}
.bar s {
  background: #d0a360;
  width: 100%;
  transition: width 0.65s 0.24s;
}
.hp {
  width: clamp(120px, 22vw, 345px);
}
.hp b,
.enemy b {
  background: linear-gradient(#a94b40, #792b29 70%, #4a1717);
  width: 100%;
}
.sp {
  width: 72%;
  height: 9px;
  margin-top: 3px;
}
.sp b {
  background: linear-gradient(#758e52, #455b35);
  width: 100%;
}
#items {
  position: absolute;
  left: 4%;
  bottom: 14%;
  display: flex;
  align-items: center;
  gap: 12px;
  text-shadow: 0 2px 3px #000;
}
.equip {
  background: #171815bc;
  border: 3px ridge #897654;
  width: 66px;
  height: 71px;
  position: relative;
  box-shadow: inset 0 0 18px #000;
}
.equip svg {
  width: 100%;
  height: 100%;
}
.equip span {
  position: absolute;
  bottom: 1px;
  right: 3px;
  font-size: 20px;
}
#items small {
  font-size: 8px;
}
#items strong {
  display: block;
  font-weight: 400;
  font-size: 17px;
  margin-top: 4px;
}
#souls {
  position: absolute;
  right: 4%;
  bottom: 13%;
  border-block: 1px solid #9c8965;
  background: #171815b0;
  padding: 5px 16px;
  color: #e7d7ae;
}
#bossbar {
  position: absolute;
  bottom: 5%;
  left: 12%;
  width: 72%;
  font-size: clamp(18px, 2vw, 26px);
  text-shadow: 1px 2px 3px #000;
  animation: reveal 0.8s ease-out;
}
.enemy {
  margin-top: 5px;
  height: 13px;
}
#phase {
  font-size: 10px;
  letter-spacing: 0.15em;
  color: #e3b27b;
}
#hint,
#act {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
}
#hint {
  bottom: 14%;
  font-size: 12px;
  color: #e3dfd1;
  text-shadow: 1px 1px 5px #000;
}
#act {
  bottom: 20%;
  pointer-events: auto;
  background: #111615d9;
  border-block: 1px solid #9b8a65;
  padding: 10px 24px;
  font-family: Georgia;
  font-size: 17px;
}
#banner {
  position: absolute;
  left: 0;
  top: 37%;
  width: 100%;
  text-align: center;
  font-size: clamp(32px, 6vw, 92px);
  font-variant: small-caps;
  letter-spacing: 0.04em;
  color: #d3ba83;
  text-shadow: 0 2px 8px #020403;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, #10110fab, transparent);
}
#banner:not(:empty) {
  padding: 12px;
}
#banner.dead {
  color: #b14031;
}
#lock {
  position: absolute;
  color: white;
  font: 21px Arial;
  transform: translate(-50%, -50%);
  text-shadow: 0 0 3px black;
}
#wound {
  box-shadow: inset 0 0 100px 25px #841e14;
  opacity: 0;
}
#white {
  background: #e3e2d7;
  opacity: 0;
  z-index: 2;
}
dialog {
  width: min(395px, 90vw);
  background: #1c201e;
  color: #e9e2d4;
  border: 1px solid #958465;
  padding: 28px 32px;
  box-shadow: 0 10px 80px #080a09;
}
dialog::backdrop {
  background: #080b0ab8;
}
dialog h2 {
  font-weight: 400;
  font-size: 39px;
  margin: 9px 0 18px;
}
.cross {
  position: absolute;
  right: 14px;
  top: 9px;
  font-size: 26px;
  color: #c8bea9;
}
dl {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0;
  margin: 0;
}
dt,
dd {
  font: 13px Arial;
  padding: 8px 0;
  border-bottom: 1px solid #aaa79922;
}
dd {
  color: #c7b58f;
  margin: 0;
  text-align: right;
}
dialog p {
  color: #b9b4a8;
  font-style: italic;
  font-size: 14px;
}
dialog .primary {
  padding: 10px 24px;
}
#touch {
  display: none;
}
body.playing #touch:not([hidden]) {
  pointer-events: none;
}
@media (pointer: coarse) {
  body.playing #touch:not([hidden]) {
    display: flex;
    position: absolute;
    inset: auto 14px 7%;
    justify-content: space-between;
  }
  .pad {
    display: grid;
    grid-template-columns: repeat(3, 38px);
    gap: 4px;
  }
  .pad button {
    pointer-events: auto;
    touch-action: none;
    background: #202321b0;
    border: 1px solid #b6a079;
    padding: 8px;
    color: #efe6d5;
  }
  .pad button:first-child {
    grid-column: 2;
  }
  .pad button:nth-child(2) {
    grid-column: 1;
  }
  .actions {
    grid-template-columns: repeat(2, 47px);
  }
  .actions button:first-child,
  .actions button:nth-child(2) {
    grid-column: auto;
  }
  #items {
    bottom: 23%;
  }
}
[hidden] {
  display: none !important;
}
@keyframes reveal {
  from {
    opacity: 0;
    transform: scaleX(0.7);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (max-width: 600px) {
  header {
    height: 58px;
  }
  .brand {
    font-size: 10px;
  }
  nav {
    gap: 8px;
  }
  nav button {
    font-size: 11px;
  }
  #title {
    left: 6%;
    transform: translateY(-34%);
  }
  h1 {
    font-size: clamp(62px, 14vw, 87px);
  }
  .eyebrow {
    font-size: 8px;
    gap: 7px;
  }
  .eyebrow b {
    width: 18px;
  }
  #caption {
    bottom: 8%;
    right: 6%;
  }
  #caption small {
    font-size: 7px;
  }
  #titlefoot {
    font-size: 11px;
  }
  .humanity {
    width: 39px;
    height: 39px;
    line-height: 34px;
    font-size: 18px;
  }
  #items strong {
    font-size: 12px;
  }
  .equip {
    width: 43px;
    height: 49px;
  }
  .playing nav button span:not(.keyicon) {
    display: none;
  }
  .playing nav {
    gap: 3px;
  }
  #hint {
    bottom: 32%;
    width: 90%;
  }
  #act {
    bottom: 37%;
    font-size: 14px;
  }
  #bossbar {
    bottom: 3%;
    left: 5%;
    width: 90%;
  }
}
@media (max-height: 540px) and (min-width: 601px) {
  header {
    height: 46px;
  }
  h1 {
    font-size: 65px;
    margin: 12px 0;
  }
  #title p {
    margin: 4px 0 12px;
  }
  #title {
    transform: translateY(-44%);
  }
  .primary {
    padding: 11px 18px;
  }
  #titlefoot {
    bottom: 12px;
  }
}
@media (min-width: 641px) {
  #bossbar {
    left: 4%;
    width: min(75%, calc(96% - 376px));
  }
}
#banner {
  transition: opacity 0.2s;
}
.playing header {
  pointer-events: none;
}
.playing header nav {
  pointer-events: auto;
}
@media (min-width: 601px) {
  #caption {
    left: 49%;
    right: auto;
    bottom: 5.5%;
    text-align: left;
  }
  #caption b {
    display: none;
  }
  #caption strong {
    font-size: clamp(16px, 1.6vw, 23px);
  }
}
@media (max-width: 600px) and (min-height: 541px) {
  #title {
    top: auto;
    bottom: 12%;
    transform: none;
  }
  h1 {
    font-size: clamp(49px, 13.5vw, 72px);
    line-height: 0.95;
    margin: 14px 0 8px;
  }
  h1 br {
    display: none;
  }
  h1 em:before {
    content: " ";
  }
  .orn {
    width: 141px;
  }
  #title p {
    margin: 6px 0 17px;
  }
  #caption {
    right: 6%;
    bottom: 4%;
  }
  #shade {
    background:
      linear-gradient(
        0deg,
        #101313 5%,
        #121515e6 23%,
        #151918a6 40%,
        transparent 62%
      ),
      linear-gradient(90deg, #121515a6, transparent 80%);
  }
}
#grip {
  pointer-events: auto;
  display: block;
  border: 0;
  padding: 3px 0;
  color: #cdc2a7;
  font: italic 12px Georgia;
  line-height: 1.3;
  text-shadow: 0 1px 3px #080b08;
}
#grip:hover {
  color: #ffde9e;
}
#grip:before {
  content: "⚔";
  font-style: normal;
  margin-right: 4px;
}
#grip[aria-pressed="true"] {
  color: #e9bf7e;
}
#banner[data-place="true"] {
  font-size: clamp(28px, 4.7vw, 68px);
}
@media (max-width: 600px) {
  #grip {
    font-size: 11px;
  }
  .actions {
    grid-template-columns: repeat(3, 43px);
  }
}
dialog {
  max-height: 90vh;
  overflow: auto;
}
details {
  font: 12px Arial;
  color: #c5b593;
  margin-top: 12px;
}
summary {
  cursor: pointer;
}
details p {
  font: 13px/1.45 Georgia;
}
body[data-state="fight"] #hint,
body[data-state="path"] #hint {
  top: 61px;
  bottom: auto;
  left: auto;
  right: 4.5%;
  width: auto;
  transform: none;
  background: #171b17a6;
  padding: 5px 9px;
  border-left: 1px solid #ac966a;
}
#hint:empty {
  display: none;
}
#souls {
  bottom: max(82px, 13%);
}
@media (min-width: 601px) {
  #act {
    left: 4%;
    transform: none;
    bottom: 32%;
    font-size: 15px;
    padding: 10px 14px;
  }
}
@media(max-height:600px){dialog{padding:18px 26px}dialog h2{font-size:30px;margin:5px 0 9px}dt,dd{padding:5px 0}dialog p{margin:9px 0}dialog .primary{padding:7px 20px}}
@media(pointer:coarse){#souls{bottom:24%}.actions button,.pad button{padding:9px 1px;font:12px Georgia}body[data-state=path] #hint{top:max(98px,12%)}#act{bottom:32%;width:max-content;max-width:95%;padding:9px 18px}}
