/* HUD redesign. Loaded last; selectors start with body.big-house so they win over the older
   layered rules in style.css / house.css without !important. */

body.big-house {
  --panel: #0f2227e6;
  --panel-border: #6b8a8240;
  --gold: #e8b56d;
  --gold-dark: #9b703d;
  --ink: #e9f0ea;
  --muted: #92aba5;
}

/* ---- Objective card (left) ---- */
body.big-house aside {
  top: 86px;
  left: 18px;
  width: 250px;
  padding: 16px 18px 18px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 30px #0006;
}
body.big-house aside h1 {
  font-size: 22px;
  line-height: 1.1;
  margin: 6px 0 8px;
}
body.big-house aside #objective {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0 0 10px;
}
body.big-house aside .tip {
  display: none;
  font-size: 11.5px;
  line-height: 1.7;
  margin: 10px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #0a181c;
  color: #b7cac4;
}
body.big-house.show-help aside .tip {
  display: block;
}
body.big-house aside #start {
  width: 100%;
  margin-top: 12px;
  padding: 11px 16px;
  font-size: 14px;
}
body.big-house aside .legend {
  display: none;
}
body.big-house #help-toggle {
  margin-top: 10px;
  background: none;
  color: var(--muted);
  font-size: 11.5px;
  padding: 0;
  text-decoration: underline dotted;
  text-underline-offset: 3px;
}

/* ---- Hotbar (bottom) ---- */
body.big-house .toolbox {
  left: 50%;
  right: auto;
  bottom: 18px;
  transform: translateX(-50%);
  width: auto;
  max-width: calc(100vw - 32px);
  padding: 8px 10px 10px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 16px;
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 30px #0007;
  display: grid;
  grid-template-columns: auto auto;
  grid-template-areas:
    "summary summary"
    "slots actions";
  gap: 6px 10px;
  align-items: end;
}
body.big-house .toolbox-title {
  display: none;
}
body.big-house #recipe-summary {
  grid-area: summary;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  padding: 0 4px;
  margin: 0;
}
body.big-house .traps {
  grid-area: slots;
  display: flex;
  gap: 6px;
  grid-template-columns: none;
}
body.big-house .trap {
  position: relative;
  width: 62px;
  height: 62px;
  padding: 0;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #18323a;
  border: 1px solid #2f4d52;
  transition:
    transform 0.12s,
    border-color 0.12s,
    background 0.12s;
}
body.big-house .trap:hover {
  transform: translateY(-2px);
}
body.big-house .trap.selected {
  background: #2a4438;
  border-color: var(--gold);
  box-shadow:
    0 0 0 2px #e8b56d40,
    0 6px 16px #0006;
  transform: translateY(-3px);
}
body.big-house .trap .emoji {
  font-size: 28px;
  line-height: 1;
  filter: drop-shadow(0 2px 2px #0007);
}
body.big-house .trap > div {
  position: absolute;
  top: 3px;
  left: 5px;
}
/* Only the key number shows; the selected trap's name is in the summary line. */
body.big-house .trap b {
  font-size: 0;
}
body.big-house .trap kbd {
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  background: none;
  border: 0;
  padding: 0;
}
body.big-house .trap strong {
  position: absolute;
  right: -5px;
  bottom: -5px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  background: var(--gold);
  color: #17252b;
  box-shadow: 0 2px 0 var(--gold-dark);
}
/* How many more the backpack's materials can make. */
body.big-house .trap .craftable {
  position: absolute;
  right: -5px;
  top: -6px;
  min-width: 20px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
  background: #5fb88a;
  color: #10261b;
  box-shadow: 0 2px 0 #3d8a62;
}
body.big-house .trap .craftable[hidden] {
  display: none;
}
body.big-house .trap strong.empty {
  background: #2c3e42;
  color: #7f9893;
  box-shadow: none;
}
body.big-house .craft-actions {
  grid-area: actions;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
}
body.big-house .craft-actions button {
  padding: 8px 12px;
  font-size: 12px;
  border-radius: 9px;
  white-space: nowrap;
  text-align: left;
}

/* ---- Messages ---- */
body.big-house #toast {
  left: 50%;
  bottom: 128px;
  transform: translateX(-50%);
  max-width: min(560px, calc(100vw - 40px));
  text-align: center;
  backdrop-filter: blur(6px);
}
body.big-house #interact {
  top: calc(50% + 34px);
  bottom: auto;
  left: 50%;
  transform: translateX(-50%);
}

/* ---- Small screens: shrink the hotbar, drop the side actions ---- */
@media (max-width: 860px) {
  body.big-house aside {
    width: 200px;
    padding: 12px 14px;
  }
  body.big-house aside h1 {
    font-size: 17px;
  }
  body.big-house aside #objective {
    display: none;
  }
  body.big-house .trap {
    width: 46px;
    height: 46px;
  }
  body.big-house .trap .emoji {
    font-size: 21px;
  }
  body.big-house .toolbox {
    grid-template-columns: auto;
    grid-template-areas:
      "summary"
      "slots"
      "actions";
  }
  body.big-house .craft-actions {
    flex-direction: row;
    justify-content: center;
  }
  body.big-house #toast {
    bottom: 170px;
  }
}
body.big-house #recipe-summary b {
  color: var(--ink);
}
body.big-house #recipe-summary .ready {
  color: var(--gold);
  font-weight: 700;
}

/* ---- Footer: only the restart link remains (burglar cards already show their status) ---- */
body.big-house footer {
  left: auto;
  right: 18px;
  bottom: 18px;
  width: auto;
}
body.big-house footer > span {
  display: none;
}
@media (max-width: 860px) {
  body.big-house footer {
    bottom: auto;
    top: 64px;
  }
}

/* ---- Short or narrow windows: keep the centre of the screen clear ---- */
@media (max-width: 860px), (max-height: 620px) {
  body.big-house aside h1,
  body.big-house aside #objective,
  body.big-house #floor-map .floor-list,
  body.big-house #floor-map .map-key,
  body.big-house #floor-map .area-note {
    display: none;
  }
  body.big-house aside {
    top: auto;
    bottom: 18px;
    left: 18px;
    width: 170px;
    padding: 10px 12px;
  }
  body.big-house aside #start {
    padding: 8px 10px;
    font-size: 12px;
  }
  body.big-house #floor-map {
    width: 170px;
  }
  body.big-house #thief-health {
    top: 76px;
    width: min(360px, 46vw);
  }
  body.big-house #thief-health small {
    display: none;
  }
  body.big-house .toolbox {
    left: auto;
    right: 50%;
    transform: translateX(50%);
  }
}
@media (max-width: 860px) and (max-height: 620px) {
  /* Very small: hotbar slots only. */
  body.big-house .craft-actions,
  body.big-house #recipe-summary {
    display: none;
  }
  body.big-house aside {
    bottom: auto;
    top: 140px;
  }
}

/* ---- Title screen ---- */
#title {
  position: absolute;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at 50% 30%, #13284acc, #050b16f2 75%);
  backdrop-filter: blur(6px);
  overflow: hidden;
}
#title[hidden] {
  display: none;
}
.title-card {
  position: relative;
  width: min(560px, calc(100vw - 40px));
  text-align: center;
  color: #e9f0ea;
}
.title-star {
  display: block;
  font-size: 34px;
  color: #ffd56b;
  text-shadow: 0 0 24px #ffd56b99;
  animation: title-twinkle 2.4s ease-in-out infinite;
}
#title h2 {
  margin: 4px 0 2px;
  font-size: clamp(34px, 6vw, 58px);
  letter-spacing: 1px;
  text-shadow: 0 4px 24px #000a;
}
.title-sub {
  margin: 0 0 22px;
  color: #e8b56d;
  letter-spacing: 3px;
  font-size: 12px;
  text-transform: uppercase;
}
.title-steps {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: 0 0 22px;
  display: grid;
  gap: 8px;
  text-align: left;
}
.title-steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 30px 1fr;
  column-gap: 12px;
  align-items: center;
  padding: 10px 14px;
  border-radius: 12px;
  background: #0f2227d9;
  border: 1px solid #6b8a8240;
}
.title-steps li::before {
  content: counter(step);
  grid-row: span 2;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #17252b;
  background: #e8b56d;
}
.title-steps b {
  font-size: 14px;
}
.title-steps span {
  font-size: 12.5px;
  color: #a9beb8;
}
#title-start {
  background: #e8b56d;
  color: #17252b;
  border-radius: 10px;
  padding: 14px 34px;
  font-size: 17px;
  font-weight: 800;
  box-shadow: 0 5px 0 #9b703d;
  transition: transform 0.1s;
}
#title-start:hover {
  transform: translateY(-2px);
}
#title-start:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 #9b703d;
}
.title-keys {
  display: block;
  margin-top: 16px;
  color: #7f9893;
  font-size: 11.5px;
}
/* Soft falling snow drawn with layered radial gradients. */
.title-snow,
.title-snow::after {
  position: absolute;
  inset: -100% 0 0;
  background-image:
    radial-gradient(2px 2px at 20px 30px, #fff9, transparent),
    radial-gradient(2px 2px at 140px 80px, #fff8, transparent),
    radial-gradient(3px 3px at 90px 160px, #fffa, transparent),
    radial-gradient(2px 2px at 200px 220px, #fff7, transparent),
    radial-gradient(3px 3px at 250px 40px, #fff9, transparent);
  background-size: 280px 260px;
  animation: title-snow 14s linear infinite;
  pointer-events: none;
}
.title-snow::after {
  content: "";
  inset: 0;
  background-size: 190px 210px;
  opacity: 0.6;
  animation-duration: 9s;
}
@keyframes title-snow {
  to {
    transform: translateY(50%);
  }
}
@keyframes title-twinkle {
  50% {
    opacity: 0.55;
    transform: scale(0.9) rotate(20deg);
  }
}
@media (max-height: 620px) {
  .title-steps span {
    display: none;
  }
  .title-steps li::before {
    grid-row: auto;
  }
  .title-sub {
    margin-bottom: 12px;
  }
}

/* ---- Comic impact words ---- */
.pow {
  position: absolute;
  translate: -50% -50%;
  rotate: var(--tilt, 0deg);
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 1px;
  color: var(--pow, #ffd56b);
  -webkit-text-stroke: 2px #1b1410;
  paint-order: stroke fill;
  text-shadow:
    3px 3px 0 #1b1410,
    0 0 18px #0008;
  pointer-events: none;
  animation: pow-in 0.22s cubic-bezier(0.2, 1.8, 0.4, 1);
  white-space: nowrap;
}
@keyframes pow-in {
  from {
    scale: 0.2;
  }
  to {
    scale: 1;
  }
}

/* ---- Backpack and recipe cards ---- */
body.big-house #backpack {
  border-radius: 16px;
}
body.big-house #inventory-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 6px;
}
body.big-house #inventory-list .item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 9px;
  background: #1a3439;
}
body.big-house #inventory-list .item i {
  font-style: normal;
  font-size: 16px;
}
body.big-house #inventory-list .item b {
  margin-left: auto;
  color: var(--gold);
}
body.big-house #inventory-list .item.none {
  opacity: 0.45;
}
body.big-house #inventory-list .item.none b {
  color: var(--muted);
}
body.big-house #recipe-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 8px;
  margin-top: 14px;
}
body.big-house #recipe-list .recipe {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: #16302f;
  border: 1px solid #2f4d52;
}
body.big-house #recipe-list .recipe.ready {
  border-color: var(--gold);
  background: #233b31;
}
body.big-house .recipe-head {
  display: flex;
  align-items: center;
  gap: 10px;
}
body.big-house .recipe-icon {
  font-size: 24px;
}
body.big-house .recipe-head b {
  font-size: 15px;
}
body.big-house .recipe-head small {
  margin-left: auto;
  color: var(--muted);
}
body.big-house .recipe .chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
body.big-house .recipe .chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 9px;
  border-radius: 20px;
  font-size: 12px;
}
body.big-house .recipe .chip em {
  font-style: normal;
  font-weight: 800;
  margin-left: 4px;
  padding: 0 6px;
  border-radius: 8px;
  background: #0006;
}
body.big-house .recipe .chip.have {
  background: #2e5a43;
  color: #d9f5e3;
}
body.big-house .recipe .chip.need {
  background: #2a3a3d;
  color: #9fb3ad;
}
body.big-house .recipe > small {
  font-size: 11.5px;
  color: var(--muted);
}
body.big-house .recipe button {
  align-self: flex-start;
  margin-top: 2px;
  padding: 8px 18px;
  border-radius: 8px;
  font-weight: 800;
  background: var(--gold);
  color: #17252b;
  box-shadow: 0 3px 0 var(--gold-dark);
}
body.big-house .recipe button:disabled {
  background: #2a3a3d;
  color: #7f9893;
  box-shadow: none;
  cursor: default;
}
body.big-house #recipe-list .recipe-head small {
  display: inline;
  margin-left: auto;
  font-size: 11.5px;
}

/* ---- Header stats never wrap mid-value ---- */
body.big-house .stats strong,
body.big-house .stats small {
  white-space: nowrap;
}
@media (max-width: 860px) {
  body.big-house .stats {
    gap: 14px;
  }
  body.big-house .stats strong {
    font-size: 16px;
  }
  body.big-house .stats small {
    font-size: 8px;
    letter-spacing: 1px;
  }
  body.big-house .brand small {
    display: none;
  }
}

/* ---- Burglar card flashes when he takes damage ---- */
#thief-health article.hurt {
  animation: card-hurt 0.45s ease-out;
}
#thief-health article.hurt .health-track span {
  animation: bar-hurt 0.45s ease-out;
}
@keyframes card-hurt {
  20% {
    transform: translateY(-3px) scale(1.04);
    box-shadow:
      0 0 0 2px #ff6b5e,
      0 8px 24px #ff6b5e55;
  }
}
@keyframes bar-hurt {
  20% {
    filter: brightness(2.2);
  }
}

/* ---- Pause menu ---- */
#pause-menu {
  position: absolute;
  inset: 0;
  z-index: 55;
  display: grid;
  place-items: center;
  background: #050b16b3;
  backdrop-filter: blur(5px);
}
#pause-menu[hidden] {
  display: none;
}
.pause-card {
  width: min(520px, calc(100vw - 40px));
  padding: 26px 28px;
  border-radius: 18px;
  background: #0f2227f2;
  border: 1px solid #6b8a8255;
  text-align: center;
  box-shadow: 0 20px 60px #000a;
}
.pause-card h2 {
  margin: 0;
  font-size: 34px;
}
.pause-card p {
  margin: 6px 0 18px;
  color: #92aba5;
  font-size: 13px;
}
.pause-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.pause-actions button {
  padding: 11px 18px;
  border-radius: 9px;
  font-weight: 700;
  background: #2b4a50;
  color: #e7efe9;
  box-shadow: 0 4px 0 #142b30;
}
.pause-actions #pause-resume {
  background: #e8b56d;
  color: #17252b;
  box-shadow: 0 4px 0 #9b703d;
}
.pause-keys {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px 14px;
  text-align: left;
  font-size: 12px;
  color: #b7cac4;
}
.pause-keys kbd {
  display: inline-block;
  min-width: 18px;
  padding: 1px 5px;
  margin-right: 4px;
  border-radius: 5px;
  background: #1e3a40;
  border: 1px solid #3c5b5f;
  color: #e9f0ea;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
}

/* ---- Objective checklist ---- */
body.big-house #checklist {
  list-style: none;
  margin: 10px 0 0;
  padding: 0;
  display: grid;
  gap: 5px;
  font-size: 12px;
}
body.big-house #checklist li {
  position: relative;
  padding-left: 22px;
  color: #7f9893;
}
body.big-house #checklist li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1px;
  width: 13px;
  height: 13px;
  border-radius: 4px;
  border: 1.5px solid #4c6a69;
}
body.big-house #checklist li.next {
  color: var(--ink);
  font-weight: 700;
}
body.big-house #checklist li.next::before {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px #e8b56d33;
}
body.big-house #checklist li.done {
  color: #8fcfa8;
  text-decoration: line-through;
  text-decoration-color: #8fcfa877;
}
body.big-house #checklist li.done::before {
  content: "✓";
  border-color: #3f8f62;
  background: #3f8f62;
  color: #fff;
  font-size: 10px;
  line-height: 12px;
  text-align: center;
}
@media (max-width: 860px), (max-height: 620px) {
  body.big-house #checklist {
    display: none;
  }
}

/* ---- Present icons in the header ---- */
body.big-house #gifts {
  display: none;
}
#gift-icons {
  display: flex;
  gap: 3px;
  margin-top: 4px;
}
#gift-icons i {
  width: 13px;
  height: 13px;
  border-radius: 3px;
  background:
    linear-gradient(#ffe08a, #ffe08a) center / 3px 100% no-repeat,
    linear-gradient(#ffe08a, #ffe08a) center / 100% 3px no-repeat,
    #e05a4f;
  box-shadow: 0 2px 0 #9b3a33;
  transition:
    opacity 0.3s,
    filter 0.3s,
    transform 0.3s;
}
#gift-icons i.carried {
  opacity: 0.5;
  transform: translateY(2px);
  animation: gift-warn 0.8s ease-in-out infinite;
}
#gift-icons i.stolen {
  opacity: 0.25;
  filter: grayscale(1);
  box-shadow: none;
}
@keyframes gift-warn {
  50% {
    opacity: 0.2;
  }
}

/* ---- Announcement banner ---- */
#announce {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  pointer-events: none;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
#announce[hidden] {
  display: none;
}
#announce strong {
  font-size: clamp(40px, 7vw, 76px);
  font-weight: 900;
  letter-spacing: 6px;
  color: #fff4d6;
  text-shadow:
    0 0 30px #ffb34788,
    0 4px 0 #6b3d1c;
}
#announce small {
  font-size: 15px;
  letter-spacing: 2px;
  color: #e8b56d;
  text-transform: uppercase;
}
#announce.show {
  animation: announce 2.6s ease-out forwards;
}
@keyframes announce {
  0% {
    opacity: 0;
    transform: translateX(-50%) scale(1.4);
    letter-spacing: 18px;
  }
  12% {
    opacity: 1;
    transform: translateX(-50%) scale(1);
  }
  80% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) translateY(-14px);
  }
}

/* ---- Win celebration ---- */
.celebration {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.celebration i {
  position: absolute;
  top: -20px;
  width: 9px;
  height: 14px;
  border-radius: 2px;
  animation: confetti-fall linear forwards;
}
@keyframes confetti-fall {
  to {
    transform: translate(var(--drift), 110vh) rotate(var(--spin));
  }
}
#modal.won > div:not(.celebration) {
  box-shadow:
    0 0 0 2px #e8b56d66,
    0 20px 80px #e8b56d33;
}
/* The confetti layer is a direct child of #modal; undo the card styling #modal > div applies. */
#modal > .celebration {
  position: absolute;
  inset: 0;
  max-width: none;
  padding: 0;
  margin: 0;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

/* Narrow or short windows: objective card top-left under the header, clear of the hotbar. */
@media (max-width: 860px), (max-height: 620px) {
  body.big-house aside {
    top: 70px;
    bottom: auto;
    width: 156px;
  }
}

/* ---- Danger indicators ---- */
.danger-arrow {
  position: absolute;
  width: 0;
  height: 0;
  translate: -50% -50%;
  rotate: var(--angle, 0rad);
  border-left: 14px solid transparent;
  border-right: 14px solid transparent;
  border-bottom: 24px solid #f17d68;
  filter: drop-shadow(0 0 6px #f17d68aa) drop-shadow(0 2px 2px #0008);
  animation: danger-pulse var(--pulse, 1s) ease-in-out infinite;
  pointer-events: none;
  display: none;
  z-index: 30;
}
.danger-arrow.chasing {
  border-bottom-color: #ff3b30;
  filter: drop-shadow(0 0 10px #ff3b30) drop-shadow(0 2px 2px #0008);
}
@keyframes danger-pulse {
  50% {
    scale: 1.25;
  }
}
.danger-alert {
  position: absolute;
  translate: -50% -100%;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: none;
  text-align: center;
  line-height: 30px;
  font-size: 22px;
  font-weight: 900;
  color: #fff;
  background: #ff3b30;
  box-shadow:
    0 0 0 3px #fff,
    0 0 16px #ff3b30;
  animation: danger-pulse 0.5s ease-in-out infinite;
  pointer-events: none;
  z-index: 30;
}

/* ---- Action prompt under the crosshair ---- */
body.big-house #interact {
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 13px;
  background: #0f2227e6;
  border: 1px solid var(--panel-border);
  backdrop-filter: blur(4px);
}
body.big-house #interact kbd {
  display: inline-block;
  min-width: 20px;
  padding: 1px 6px;
  margin-right: 2px;
  border-radius: 5px;
  background: var(--gold);
  color: #17252b;
  font-family: inherit;
  font-weight: 800;
  font-size: 12px;
  text-align: center;
  box-shadow: 0 2px 0 var(--gold-dark);
}

/* ---- Pause menu settings ---- */
.pause-settings {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
  text-align: left;
}
.pause-settings label {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 10px;
  font-size: 13px;
  color: #d4e2dc;
}
.pause-settings output {
  color: #e8b56d;
  font-weight: 700;
}
.pause-settings select {
  font: inherit;
  color: #f3efe6;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  padding: 4px 8px;
}
.pause-settings select option {
  color: #111;
}
.pause-settings input[type="range"] {
  grid-column: 1 / -1;
  width: 100%;
  accent-color: #e8b56d;
}

/* ---- Burglar health cards: portrait badge + coloured bar ---- */
body.big-house #thief-health article {
  display: grid;
  grid-template-columns: 34px 1fr;
  column-gap: 10px;
  align-items: center;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  backdrop-filter: blur(6px);
}
body.big-house #thief-health article > .health-track {
  grid-column: 1 / -1;
  margin-top: 6px;
}
.thief-badge {
  grid-row: span 1;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  position: relative;
  background: #e2b48c;
  box-shadow: inset 0 -3px 0 #0002;
  overflow: hidden;
}
/* Eye-mask band and a little face. */
.thief-badge::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 14px;
  height: 7px;
  background:
    radial-gradient(circle at 35% 50%, #fff 2px, transparent 2.5px),
    radial-gradient(circle at 65% 50%, #fff 2px, transparent 2.5px), #15171b;
}
/* Hat. */
.thief-badge::after {
  content: "";
  position: absolute;
  left: -2px;
  right: -2px;
  top: -6px;
  height: 18px;
  border-radius: 50% 50% 4px 4px;
}
.thief-badge.stout::after {
  background: linear-gradient(#c0392b 75%, #e8e2d4 75%);
}
.thief-badge.lanky {
  background: #d9a582;
}
.thief-badge.lanky::before {
  background:
    radial-gradient(circle at 35% 50%, #fff 2px, transparent 2.5px),
    radial-gradient(circle at 65% 50%, #fff 2px, transparent 2.5px), transparent;
}
.thief-badge.lanky::after {
  background: #6b5442;
  height: 13px;
  top: -2px;
  border-radius: 50% 50% 0 0;
}
body.big-house #thief-health .health-track span {
  transition:
    width 0.3s,
    background 0.3s;
}
@media (max-width: 860px), (max-height: 620px) {
  body.big-house #thief-health article {
    grid-template-columns: 24px 1fr;
  }
  .thief-badge {
    width: 24px;
    height: 24px;
  }
  .thief-badge::before {
    top: 9px;
    height: 5px;
  }
}
