:root {
  color-scheme: dark;
  font: 100%/1.5 system-ui, sans-serif;
  background: #101712;
  color: #f1f5ee;
  --muted: #bdcbbd;
  --accent: #d0ee63;
}

* { box-sizing: border-box; }
body { margin: 0; }
a, button { color: var(--accent); }
.masthead { padding: 1rem clamp(1rem, 5vw, 4rem); border-bottom: 1px solid #3c4a3e; }
.brand { display: inline-flex; gap: .625rem; align-items: center; font-weight: 750; text-decoration: none; color: inherit; }
.brand img { object-fit: contain; }
main, footer { width: min(30rem, calc(100% - 2rem)); margin-inline: auto; }
main { margin-top: clamp(2rem, 7vw, 5rem); }
h1 { margin: 0 0 .625rem; font-size: clamp(1.9rem, 7vw, 2.7rem); line-height: 1.12; }
p, small, footer { color: var(--muted); }
strong { color: #f1f5ee; overflow-wrap: anywhere; }
form { display: grid; gap: .5rem; margin-top: 1.5rem; }
label { font-weight: 650; }
input + label { margin-top: .5rem; }
input, button { font: inherit; }
input { width: 100%; min-height: 2.875rem; padding: .6rem .75rem; color: inherit; background: #19241c; border: 1px solid #738574; border-radius: .4rem; }
button { cursor: pointer; border: 0; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
button:disabled { opacity: .65; cursor: wait; }
.primary { min-height: 2.875rem; padding: .65rem .9rem; margin-top: .6rem; border-radius: .4rem; color: #172012; background: var(--accent); font-weight: 750; }
.links, footer { display: flex; flex-wrap: wrap; gap: .35rem 1.25rem; margin-top: 1rem; }
.links button, .switch button { background: transparent; padding: .3rem 0; text-decoration: underline; text-underline-offset: .16em; }
.account-level { margin-block: 1.25rem; padding: 1rem; border: 1px solid #3c4a3e; border-radius: .4rem; background: #19241c; }
.account-level h2 { margin: 0; color: var(--accent); }
.account-level p { margin: .35rem 0; }
.account-level progress { width: 100%; height: .8rem; accent-color: var(--accent); }
.account-level.rpg-panel { margin-block: 1.25rem; }
.account-level.rpg-panel .rpg-panel-header { margin-bottom: .65rem; }
.account-level.rpg-panel :is(small, [data-profile-message]) { color: var(--rpg-muted, var(--muted)); }
.account-level.rpg-panel .primary { color: var(--rpg-well, #172012); background: var(--rpg-trim, var(--accent)); }
.account-level.rpg-panel progress { accent-color: var(--rpg-trim, var(--accent)); }
#owner-xp-testing { margin-top: 1rem; }
#owner-xp-testing summary { cursor: pointer; color: var(--accent); }
.avatar-options { border: 0; margin: .75rem 0 0; padding: 0; min-width: 0; }
.avatar-options legend { font-weight: 650; margin-bottom: .5rem; }
.avatar-options > div { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 96px), 1fr)); gap: .4rem; }
.avatar-options label {
  display: grid; position: relative; justify-items: center; gap: .15rem; padding: .4rem .2rem;
  min-width: 0; text-align: center; grid-template-columns: minmax(0, 1fr); align-content: start;
  background: #101712; border: 1px solid #738574; border-radius: .35rem; cursor: pointer; font-size: .8rem;
}
.avatar-options label span { width: 100%; white-space: nowrap; line-height: 1.2; }
.avatar-options label:has(:checked) { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.avatar-options label:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.avatar-options input { position: absolute; opacity: 0; inset: 0; margin: 0; min-height: 0; cursor: pointer; }
.avatar-options img { image-rendering: pixelated; }
.account-profile { scroll-margin-top: 1rem; }
#inventory { margin: 20px 0; scroll-margin-top: 1rem; }
.account-reward-shortcuts { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.account-profile form + small { display: block; margin-top: .75rem; }
[data-profile-message] { margin: 0; }
[data-profile-message]:empty { display: none; }
[data-profile-message][data-error] { color: #ffc1b2; }
#account-message:empty { display: none; }
#account-message[data-error] { color: #ffc1b2; }
footer { border-top: 1px solid #3c4a3e; margin-top: 2.5rem; padding-block: 1rem; }
