:root {
    min-height: 100%;
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, .08), transparent 38rem),
        #555;
    color-scheme: dark;
    font-family: Tahoma, Verdana, sans-serif;
    color: #fff;
    --panel: #929292;
    --region-building-background: #747474;
    --panel-dark: #696969;
    --border: #111;
    --gold: #d1a33a;
    --red: #b9212f;
}

.entry-masthead {
    padding-top: clamp(2.5rem, 8vh, 6rem);
}

.entry-shell {
    width: min(520px, calc(100% - 2rem));
    margin: 0 auto 3rem;
    display: grid;
    gap: .75rem;
}

.entry-shell-wide {
    width: min(880px, calc(100% - 2rem));
}

.update-news .update-panel { border-top: 3px solid var(--gold); }
.update-news .update-panel h2 { font-size: clamp(1.2rem, 4vw, 1.65rem); }
.update-news ul { padding-left: 1.3rem; margin-bottom: 0; }
.update-news li { line-height: 1.65; margin-top: .5rem; }
.update-news form + form { margin-top: 1rem; }

.entry-panel {
    padding: clamp(1rem, 4vw, 2rem);
    background: linear-gradient(145deg, #969696, #7e7e7e);
}

.entry-panel h2 {
    margin-bottom: .4rem;
    font-size: clamp(1.6rem, 5vw, 2.3rem);
}

.entry-panel > p {
    color: #f0f0f0;
    line-height: 1.5;
}

.entry-kicker,
.world-status {
    margin-bottom: .3rem;
    color: #ffe09a !important;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.entry-form {
    display: grid;
    gap: 1rem;
    margin-top: 1.2rem;
}

.entry-form > label {
    display: grid;
    gap: .35rem;
    color: #fff;
    font-size: .82rem;
    font-weight: 700;
}

.entry-form input:not([type="radio"]) {
    width: 100%;
    min-height: 2.8rem;
    padding: .65rem .75rem;
    border: 1px solid #252525;
    border-radius: 5px;
    background: #f7f7f7;
    color: #171717;
    font: inherit;
}

.entry-form input:focus-visible,
.entry-primary:focus-visible,
.portrait-choice:has(input:focus-visible) {
    outline: 3px solid #ffe09a;
    outline-offset: 2px;
}

.entry-primary {
    min-height: 2.8rem;
    padding: .7rem 1rem;
    border: 1px solid #1d1d1d;
    border-radius: 5px;
    background: linear-gradient(#c99532, #9a681c);
    color: #fff;
    font-weight: 700;
    text-shadow: 0 1px #222;
    cursor: pointer;
}

.entry-primary:hover {
    filter: brightness(1.08);
}

.entry-alternate {
    margin: 1.25rem 0 0 !important;
    text-align: center;
}

.entry-alternate a {
    color: #fff1c9;
}

.portrait-picker {
    margin: 0;
    padding: .75rem;
    border: 1px solid #555;
    border-radius: 6px;
}

.portrait-picker legend {
    padding: 0 .35rem;
    font-size: .82rem;
    font-weight: 700;
}

.portrait-picker {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
    gap: .6rem;
}

.portrait-choice {
    position: relative;
    display: grid;
    gap: .35rem;
    padding: .5rem;
    border: 2px solid transparent;
    border-radius: 7px;
    background: rgba(45, 45, 45, .3);
    text-align: center;
    cursor: pointer;
}

.portrait-choice:has(input:checked) {
    border-color: #ffe09a;
    background: rgba(65, 48, 15, .38);
}

.portrait-choice input {
    position: absolute;
    opacity: 0;
}

.portrait-choice img {
    width: 72px;
    height: 72px;
    margin: 0 auto;
    border: 1px solid #333;
    border-radius: 50%;
    object-fit: cover;
}

.portrait-choice span {
    font-size: .68rem;
}

.world-grid {
    display: grid;
    gap: 1rem;
    margin-top: 1.2rem;
}

.world-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid #4a4a4a;
    border-radius: 7px;
    background: rgba(42, 42, 42, .25);
}

.world-card h3 {
    margin: .15rem 0 .4rem;
    font-size: 1.35rem;
}

.world-card p {
    margin: 0;
    line-height: 1.45;
}

.logout-form,
.logout-form .nav-link {
    width: 100%;
}

.logout-form .nav-link {
    background: #595959;
    cursor: pointer;
}

@media (max-width: 600px) {
    .world-card {
        grid-template-columns: 1fr;
    }

    .world-card .entry-primary {
        width: 100%;
    }
}

* {
    box-sizing: border-box;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

body {
    margin: 0;
    min-width: 320px;
}

button,
a {
    font: inherit;
}

.masthead {
    padding: 1.25rem 1rem .8rem;
    text-align: center;
}

.masthead h1 {
    margin: 0;
    font-size: clamp(3rem, 7vw, 5.2rem);
    letter-spacing: -.07em;
    line-height: .95;
}

.masthead p {
    margin: .45rem 0 0;
    color: #ddd;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .16em;
}

.game-board {
    width: min(1360px, calc(100% - 2rem));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(190px, 250px) minmax(500px, 1fr) minmax(230px, 290px);
    gap: 1rem;
    align-items: start;
}

.main-column {
    display: grid;
    min-width: 0;
    gap: .75rem;
}

.panel {
    padding: .75rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--panel);
    box-shadow: inset 0 1px rgba(255, 255, 255, .22);
}

.panel h2,
.panel h3,
.panel p {
    margin-top: 0;
}

.navigation-panel,
.character-panel {
    position: sticky;
    top: .75rem;
}

.nav-link {
    display: block;
    margin: .35rem 0;
    padding: .7rem;
    border: 1px solid #2a2a2a;
    border-radius: 5px;
    color: #fff;
    text-align: center;
    text-decoration: none;
}

.nav-link.active {
    background: #606060;
}

.nav-link.disabled {
    color: #d0d0d0;
    cursor: not-allowed;
    opacity: .62;
}

.nav-link-gems {
    display: flex;
    gap: .45rem;
    align-items: center;
    justify-content: center;
}

.nav-link-gems img {
    width: 28px;
    height: 28px;
    object-fit: contain;
    image-rendering: pixelated;
}

.leaderboard-panel {
    padding: 1rem;
}

.leaderboard-heading {
    display: flex;
    gap: 1rem;
    align-items: start;
    justify-content: space-between;
    margin-bottom: .85rem;
}

.leaderboard-heading h2,
.leaderboard-board h3,
.leaderboard-category h4 {
    margin-bottom: .25rem;
}

.leaderboard-heading p {
    margin: 0;
    color: #eee;
    font-size: .8rem;
}

.leaderboard-board-group {
    display: grid;
    gap: 1rem;
}

.leaderboard-board {
    display: grid;
    gap: .6rem;
}

.leaderboard-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: .65rem;
}

.leaderboard-category {
    min-width: 0;
    padding: .65rem;
    border: 1px solid #555;
    border-radius: 6px;
    background: rgba(40, 40, 40, .18);
}

.leaderboard-empty {
    margin: 0;
    color: #eee;
    font-size: .78rem;
}

.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .74rem;
}

.leaderboard-table th,
.leaderboard-table td {
    padding: .35rem .25rem;
    border-top: 1px solid rgba(20, 20, 20, .35);
    text-align: left;
    vertical-align: middle;
}

.leaderboard-table th:last-child,
.leaderboard-table td:last-child {
    text-align: right;
}

.leaderboard-character {
    display: inline-flex;
    min-width: 0;
    gap: .4rem;
    align-items: center;
}

.leaderboard-character img {
    width: 24px;
    height: 24px;
    flex: 0 0 auto;
    border: 1px solid #333;
    border-radius: 50%;
    object-fit: cover;
}

.leaderboard-character span {
    overflow-wrap: anywhere;
}

.leaderboard-summary .portrait {
    width: 112px;
    height: 112px;
    display: block;
    margin: 0 auto .65rem;
    border: 2px solid #2b2b2b;
    border-radius: 50%;
    object-fit: cover;
}

.weekly-rewards {
    display: grid;
    gap: .65rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid #6f5a28;
}

.weekly-rewards h3,
.weekly-rewards h4,
.weekly-rewards p,
.weekly-rewards ol {
    margin: 0;
}

.reward-pool,
.reward-grant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: .5rem;
}

.reward-pool span,
.reward-grant {
    padding: .55rem;
    border: 1px solid #6f5a28;
    border-radius: 5px;
    background: rgba(36, 31, 16, .3);
}

.reward-pool span {
    color: #fff0bd;
    font-size: .72rem;
}

.reward-grant {
    display: grid;
    gap: .35rem;
    align-content: start;
    font-size: .72rem;
}

.reward-grant.is-claimed {
    opacity: .65;
}

.reward-grant form,
.reward-grant button {
    width: 100%;
}

.region-switch {
    margin-top: .7rem;
    padding-top: .6rem;
    border-top: 1px solid #737373;
}

.region-switch h3 {
    margin: 0 0 .35rem;
    color: #f2f2f2;
    font-size: .72rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.region-switch form {
    margin: .3rem 0;
}

.region-switch-button {
    width: 100%;
    min-height: 2.2rem;
    padding: .45rem .55rem;
    border: 1px solid #2a2a2a;
    border-radius: 5px;
    background: #595959;
    color: #fff;
    cursor: pointer;
}

.region-switch-button:hover:not(:disabled),
.region-switch-button:focus-visible {
    border-color: #fff;
    background: #4a4a4a;
    outline: 2px solid var(--gold);
}

.region-switch-button:disabled {
    cursor: not-allowed;
}

.region-switch-button.active {
    border-color: #654d16;
    background: #e0b74d;
    color: #231a08;
    font-weight: 700;
}

.panel-note {
    color: #f0f0f0;
    font-size: .78rem;
    line-height: 1.5;
}

.notice {
    padding: .75rem 1rem;
    border-radius: 6px;
}

.notice-error {
    border: 1px solid #f08a94;
    background: #6f222a;
}

.notice-success {
    border: 1px solid #8bd4a0;
    background: #245c35;
}

.notice-warning {
    border: 1px solid #f2d166;
    background: #725b16;
    color: #fff5c7;
}

.notice-combat {
    border: 1px solid #78b7dc;
    background: #315d7a;
    color: #f4fbff;
}

.notice-with-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}

.notice-message {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: .7rem;
}

.notice-gather-icon {
    width: 2.5rem;
    height: 2.5rem;
    flex: 0 0 auto;
    object-fit: contain;
    image-rendering: pixelated;
}

.notice-repeat-form {
    flex: 0 0 auto;
}

.notice-repeat-action {
    padding: .45rem .7rem;
    border: 1px solid #d6f3de;
    border-radius: 5px;
    background: #e7f7eb;
    color: #173d22;
    font: inherit;
    font-size: .75rem;
    font-weight: 700;
    cursor: pointer;
}

.notice-repeat-action:hover,
.notice-repeat-action:focus-visible {
    background: #fff;
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.notice-combat-action {
    padding: .45rem .9rem;
    border: 1px solid #d8effc;
    border-radius: 5px;
    background: #e5f5fd;
    color: #17384d;
    font: inherit;
    font-size: .75rem;
    font-weight: 700;
    cursor: pointer;
}

.notice-combat-action:hover,
.notice-combat-action:focus-visible {
    background: #fff;
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.region-board {
    padding: 1rem;
}

.map-stack {
    position: relative;
    width: 100%;
    max-width: 448px;
    aspect-ratio: 448 / 320;
    display: grid;
    margin: 0 auto;
    image-rendering: pixelated;
}

.map-stack img {
    width: 100%;
    grid-column: 1;
    grid-row: 1;
}

.map-stack .dungeon-map-marker {
    position: absolute;
    left: var(--dungeon-left);
    top: var(--dungeon-top);
    z-index: 3;
    width: 7.15%;
    height: auto;
    transform: translate(-50%, -50%);
    image-rendering: pixelated;
    filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .8));
}

.building-hotspots {
    position: absolute;
    inset: 0;
    z-index: 4;
}

.dungeon-hotspots {
    position: absolute;
    inset: 0;
    z-index: 5;
    pointer-events: none;
}

.dungeon-hotspot {
    position: absolute;
    left: var(--dungeon-left, 43%);
    top: var(--dungeon-top, 18%);
    width: 2.65rem;
    height: 2.65rem;
    display: grid;
    place-items: center;
    transform: translate(-50%, -50%);
    border: 2px solid #f5c965;
    border-radius: 50%;
    background: rgba(35, 26, 8, .28);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .5), 0 0 12px rgba(245, 201, 101, .9);
    color: #fff;
    text-decoration: none;
    pointer-events: auto;
}

.dungeon-hotspot > img {
    width: 1.1rem;
    height: 1.1rem;
}

.expedition-resource-overview {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, .18);
}

.expedition-resource-overview h3 {
    margin: 0 0 .65rem;
}

.expedition-resource-facts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.dungeon-hotspot > span {
    position: absolute;
    left: 50%;
    top: calc(100% + .4rem);
    min-width: max-content;
    padding: .25rem .4rem;
    transform: translateX(-50%);
    border: 1px solid #e0b74d;
    border-radius: 4px;
    background: rgba(25, 25, 25, .96);
    color: #fff;
    font-size: .65rem;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
}

.dungeon-hotspot:hover,
.dungeon-hotspot:focus-visible {
    background: rgba(111, 77, 15, .65);
    outline: 3px solid #fff;
}

.dungeon-hotspot:hover > span,
.dungeon-hotspot:focus-visible > span {
    opacity: 1;
}

.dungeon-hotspot.is-disabled {
    border-color: #aaa;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .5);
    filter: grayscale(1);
    cursor: not-allowed;
}

.building-hotspot {
    position: absolute;
    left: var(--hotspot-left);
    top: var(--hotspot-top);
    width: 2.4rem;
    height: 2.4rem;
    display: grid;
    place-items: center;
    transform: translate(-50%, -50%);
    border: 2px solid #ffe07c;
    border-radius: 50%;
    background: rgba(35, 26, 8, .42);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, .42), 0 0 12px rgba(255, 224, 124, .8);
    color: #fff;
    text-decoration: none;
}

.building-hotspot::before {
    content: "";
    width: .65rem;
    height: .65rem;
    border-radius: 50%;
    background: #ffe07c;
}

.building-hotspot span {
    position: absolute;
    left: 50%;
    bottom: calc(100% + .35rem);
    min-width: max-content;
    padding: .25rem .4rem;
    transform: translateX(-50%);
    border: 1px solid #e0b74d;
    border-radius: 4px;
    background: rgba(25, 25, 25, .94);
    color: #fff;
    font-size: .65rem;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
}

.building-hotspot:hover,
.building-hotspot:focus-visible {
    z-index: 10;
    background: rgba(209, 163, 58, .55);
    outline: 3px solid #fff;
}

.building-hotspot:hover span,
.building-hotspot:focus-visible span {
    opacity: 1;
}

.building-hotspots:has(.building-hotspot:hover, .building-hotspot:focus-visible) {
    z-index: 6;
}

.dungeon-hotspot:hover,
.dungeon-hotspot:focus-visible {
    z-index: 10;
}

.region-heading {
    margin-top: .7rem;
    display: flex;
    gap: 1rem;
    align-items: end;
    justify-content: space-between;
}

.region-heading h2 {
    margin-bottom: .2rem;
    font-size: 1.35rem;
}

.region-heading p {
    margin: 0;
    color: #eee;
    font-size: .8rem;
}

.status-chip {
    padding: .3rem .55rem;
    border: 1px solid #654d16;
    border-radius: 999px;
    background: #e0b74d;
    color: #231a08;
    font-size: .72rem;
    font-weight: 700;
    white-space: nowrap;
}

.season-chip {
    border-color: #335c49;
    background: #b9d58b;
    color: #172718;
}

.resource-pools {
    margin-top: .8rem;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .4rem;
}

.resource-pools div {
    padding: .55rem .35rem;
    border: 1px solid #3a3a3a;
    border-radius: 5px;
    background: #777;
    text-align: center;
}

.resource-pools span,
.resource-pools strong {
    display: block;
}

.resource-pools span {
    margin-bottom: .18rem;
    font-size: .72rem;
}

.resource-label {
    display: inline-flex;
    gap: .3rem;
    align-items: center;
    min-width: 0;
}

.resource-label-centered {
    justify-content: center;
}

.resource-label img {
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
    object-fit: contain;
    image-rendering: pixelated;
}

.resource-label span {
    min-width: 0;
}

.resource-pools strong {
    font-size: .82rem;
}

.region-resource-timer {
    margin-top: .7rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .45rem .8rem;
    padding: .55rem .7rem;
    border: 1px solid rgba(224, 183, 77, .55);
    border-radius: .35rem;
    background: rgba(20, 19, 13, .58);
    font-size: .76rem;
}

.region-resource-timer strong {
    color: #ffe07c;
}

.settlement-panel {
    padding: 1rem;
}

.settlement-heading {
    display: flex;
    gap: 1rem;
    align-items: start;
    justify-content: space-between;
}

.settlement-heading h2 {
    margin-bottom: .25rem;
}

.settlement-heading p,
.settlement-unavailable p {
    margin-bottom: .35rem;
    color: #eee;
    font-size: .78rem;
    line-height: 1.45;
}

.settlement-unavailable-layout {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
}

.settlement-unavailable-art {
    width: 150px;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    background: #6f601d;
}

.settlement-unavailable-art img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: pixelated;
}

.settlement-founding-costs {
    display: grid;
    max-width: 260px;
    margin: .55rem 0 0;
    gap: .2rem;
}

.settlement-founding-costs div {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    padding: .25rem .4rem;
    border: 1px solid #4b3a12;
    border-radius: 5px;
    background: rgba(0, 0, 0, .2);
    font-size: .72rem;
}

.settlement-founding-costs dt,
.settlement-founding-costs dd {
    margin: 0;
}

.settlement-founding-costs dd {
    font-weight: 700;
}

.settlement-founding-costs .is-missing {
    color: #ffd3d7;
}

.settlement-founding-costs .is-met {
    color: #c9f1c4;
}

.settlement-founding-form {
    margin-top: .6rem;
}

.settlement-founding-button {
    padding: .45rem .7rem;
    border: 1px solid #202020;
    border-radius: 5px;
    background: #606060;
    color: #fff0c3;
    font-size: .76rem;
    font-weight: 700;
    cursor: pointer;
}

.settlement-founding-button:hover,
.settlement-founding-button:focus-visible {
    border-color: #fff;
    background: #4a4a4a;
}

.building-access-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .5rem;
    margin: .8rem 0;
}

.building-access-card {
    min-width: 0;
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: .5rem;
    align-items: center;
    padding: .5rem;
    border: 1px solid #4b3a12;
    border-radius: 6px;
    background: var(--region-building-background);
    color: #fff;
    text-decoration: none;
}

a.building-access-card:hover,
a.building-access-card:focus-visible {
    border-color: #fff;
    background: #656565;
    outline: 2px solid var(--gold);
}

.building-access-card img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    image-rendering: pixelated;
}

.building-access-card strong,
.building-access-card small {
    display: block;
}

.building-access-card strong {
    color: #fff0c3;
    font-size: .76rem;
}

.building-access-card small {
    margin-top: .2rem;
    color: #eee;
    font-size: .62rem;
}

.building-access-card.is-planned {
    border-color: #555;
    filter: grayscale(1);
    opacity: .62;
}

.construction-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .6rem;
    margin: .9rem 0;
}

.construction-card {
    min-width: 0;
    padding: .7rem;
    border: 1px solid #4b3a12;
    border-radius: 6px;
    background: #696969;
}

.construction-card h3 {
    margin: .15rem 0 .25rem;
    color: #fff0c3;
    font-size: .82rem;
}

.construction-card p {
    color: #eee;
    font-size: .7rem;
    line-height: 1.4;
}

.town-storage-summary {
    margin: .85rem 0;
}

.town-storage-summary h3,
.settlement-panel > h3 {
    margin-bottom: .45rem;
    font-size: .88rem;
}

.contribution-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .55rem;
}

.contribution-card {
    min-width: 0;
    padding: .6rem;
    border: 1px solid #555;
    border-radius: 6px;
    background: #797979;
}

.contribution-heading {
    display: flex;
    gap: .5rem;
    align-items: center;
    margin-bottom: .45rem;
}

.contribution-heading img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    image-rendering: pixelated;
}

.contribution-card dl {
    margin: 0 0 .45rem;
}

.contribution-card dl div {
    display: flex;
    justify-content: space-between;
    padding: .18rem 0;
    border-bottom: 1px solid #6a6a6a;
    font-size: .68rem;
}

.contribution-card dt,
.contribution-card dd {
    margin: 0;
}

.contribution-card label {
    display: block;
    margin-bottom: .2rem;
    font-size: .68rem;
}

.contribution-card input[type="number"] {
    width: 100%;
    min-height: 2rem;
    padding: .35rem;
    border: 1px solid #333;
    border-radius: 4px;
    background: #f3f3f3;
    color: #111;
}

.contribution-card button {
    width: 100%;
    min-height: 2.2rem;
    border: 1px solid #5b4310;
    border-radius: 4px;
    background: #d1a33a;
    color: #241a07;
    cursor: pointer;
    font-weight: 700;
}

.contribution-card button:hover:not(:disabled),
.contribution-card button:focus-visible {
    border-color: #fff;
    outline: 2px solid #fff;
}

.contribution-card button:disabled,
.contribution-card input:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .5;
}

.contribution-result {
    margin: .45rem 0;
    color: #fff2c7;
    font-size: .68rem;
    line-height: 1.4;
}

.building-identity {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    padding: 1rem;
}

.building-identity > img {
    width: 120px;
    height: 120px;
    object-fit: contain;
    image-rendering: pixelated;
}

.building-identity h2 {
    margin: .4rem 0 .25rem;
    color: #fff0c3;
    font-size: 1.4rem;
}

.building-identity p {
    margin-bottom: .35rem;
    line-height: 1.45;
}

.building-module {
    padding: 1rem;
}

.building-module > h2,
.building-storage-panel > h2 {
    margin-bottom: .6rem;
    text-align: center;
    font-size: 1rem;
    font-style: italic;
}

.building-status-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .5rem;
    margin: 0;
}

.building-status-list div {
    padding: .55rem;
    border: 1px solid #5d5d5d;
    border-radius: 5px;
    background: #7a7a7a;
    text-align: center;
}

.building-status-list dt,
.building-status-list dd {
    margin: 0;
    font-size: .7rem;
}

.building-status-list dt {
    margin-bottom: .2rem;
    color: #f2d88d;
    font-weight: 700;
}

.facility-cards,
.upgrade-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .55rem;
}

.facility-card {
    min-width: 0;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: .65rem;
    padding: .65rem;
    border: 1px solid #555;
    border-radius: 6px;
    background: #797979;
}

.facility-card > img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.facility-card h3 {
    margin: 0 0 .2rem;
    color: #fff0c3;
    font-size: .85rem;
}

.facility-card strong,
.facility-card p {
    display: block;
    margin: .2rem 0;
    font-size: .7rem;
    line-height: 1.4;
}

.facility-card.is-available {
    border-color: #79bd8b;
}

.facility-card.is-unavailable {
    filter: grayscale(.65);
    opacity: .68;
}

.settlement-upgrade-form {
    margin-top: .65rem;
}

.settlement-upgrade-button {
    width: 100%;
    min-height: 2.35rem;
    padding: .45rem .7rem;
    border: 1px solid #f0cf78;
    border-radius: 4px;
    background: #4d3a12;
    color: #fff4cf;
    cursor: pointer;
    font-weight: 700;
    text-shadow: 0 1px 1px #000;
}

.settlement-upgrade-button:hover:not(:disabled),
.settlement-upgrade-button:focus-visible {
    border-color: #fff;
    background: #6a5019;
    outline: 2px solid var(--gold);
}

.settlement-upgrade-button:disabled {
    border-color: #777;
    background: #3f3f3f;
    color: #f1f1f1;
    cursor: not-allowed;
    opacity: 1;
}

.maintenance-result {
    margin: .6rem 0 0;
    padding: .55rem;
    border: 1px solid #d4ad43;
    border-radius: 5px;
    background: rgba(67, 53, 14, .45);
    color: #ffe7a0;
}

.seed-market-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .55rem;
    margin-top: .75rem;
}

.seed-market-card {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: .6rem;
    padding: .6rem;
    border: 1px solid #80672b;
    border-radius: 5px;
    background: #6d6d6d;
}

.seed-market-card > img {
    width: 48px;
    height: 48px;
    image-rendering: pixelated;
}

.seed-market-card strong,
.seed-market-card span {
    display: block;
    font-size: .75rem;
}

.seed-market-card form {
    display: flex;
    gap: .35rem;
    margin-top: .45rem;
}

.seed-market-card input[type="number"] {
    width: 4rem;
}

.module-link {
    display: inline-block;
    margin-top: .35rem;
    color: #fff0c3;
    font-size: .72rem;
    font-weight: 700;
}

.contextual-panel > p {
    color: #eee;
    font-size: .78rem;
    line-height: 1.45;
}

.spirit-home-status {
    margin-top: .7rem;
}

.spirit-home-action {
    margin-top: .7rem;
}

.spirit-home-action button {
    min-height: 2.2rem;
    padding: .45rem .7rem;
    border: 1px solid #5b4310;
    border-radius: 4px;
    background: #d1a33a;
    color: #241a07;
    cursor: pointer;
    font-weight: 700;
}

.spirit-home-action button:hover:not(:disabled),
.spirit-home-action button:focus-visible {
    border-color: #fff;
    outline: 2px solid #fff;
}

.spirit-home-action button:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .55;
}

.production-facility {
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--panel);
    box-shadow: inset 0 1px rgba(255, 255, 255, .22);
}

.production-facility-heading,
.production-active-state {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: .8rem;
    align-items: center;
}

.production-facility-heading > img,
.production-active-state > img {
    width: 72px;
    height: 96px;
    object-fit: contain;
    image-rendering: pixelated;
}

.production-facility-heading h3,
.production-active-state h4 {
    margin: 0 0 .25rem;
    color: #fff0c3;
}

.production-facility-heading p,
.production-active-state p {
    margin: .2rem 0;
    font-size: .72rem;
    line-height: 1.4;
}

.production-storage,
.production-active-state,
.production-action-group,
.production-result-panel {
    margin-top: .8rem;
    padding: .7rem;
    border: 1px solid #555;
    border-radius: 6px;
    background: #797979;
}

.production-storage h4,
.production-action-group h4,
.production-result-panel h4 {
    margin: 0 0 .55rem;
    color: #f2d88d;
    font-size: .82rem;
    text-transform: uppercase;
}

.production-balance-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .4rem;
}

.production-balance-grid div {
    min-width: 0;
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr) auto;
    gap: .4rem;
    align-items: center;
    padding: .4rem;
    border: 1px solid #686868;
    border-radius: 4px;
    background: #727272;
    font-size: .68rem;
}

.production-balance-grid img,
.production-balance-form > img {
    width: 24px;
    height: 24px;
    object-fit: contain;
    image-rendering: pixelated;
}

.production-actions-grid {
    display: grid;
    grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
    gap: .6rem;
}

.production-balance-form,
.production-recipe-card {
    min-width: 0;
    margin-top: .5rem;
    padding: .55rem;
    border: 1px solid #5c5c5c;
    border-radius: 5px;
    background: #737373;
}

.production-balance-form {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: .35rem .5rem;
    align-items: center;
}

.production-balance-form p,
.production-recipe-card p {
    margin: .25rem 0;
    font-size: .68rem;
    line-height: 1.35;
}

.production-balance-form p,
.production-balance-form button {
    grid-column: 1 / -1;
}

.production-balance-form input,
.production-recipe-card input {
    width: 100%;
    min-height: 2rem;
    padding: .3rem;
    border: 1px solid #333;
    border-radius: 4px;
    background: #f3f3f3;
    color: #111;
}

.production-balance-form button,
.production-recipe-card button {
    width: 100%;
    min-height: 2.2rem;
    border: 1px solid #5b4310;
    border-radius: 4px;
    background: #d1a33a;
    color: #241a07;
    cursor: pointer;
    font-weight: 700;
}

.production-balance-form button:disabled,
.production-balance-form input:disabled,
.production-recipe-card button:disabled,
.production-recipe-card input:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .5;
}

.production-recipe-card h5 {
    margin: 0 0 .25rem;
    color: #fff0c3;
    font-size: .78rem;
}

.production-recipe-card dl {
    margin: .45rem 0;
}

.production-recipe-card dl div {
    display: grid;
    grid-template-columns: 4rem 1fr;
    gap: .4rem;
    padding: .2rem 0;
    border-bottom: 1px solid #686868;
    font-size: .66rem;
}

.production-recipe-card dt,
.production-recipe-card dd {
    margin: 0;
}

.production-countdown {
    color: #ffe28c;
    font-weight: 700;
}

.production-result-panel p {
    margin: .25rem 0;
    font-size: .7rem;
    line-height: 1.4;
}

.building-storage-panel {
    position: sticky;
    top: .75rem;
}

.building-storage-panel h3 {
    margin: .8rem 0 .35rem;
    color: #f2d88d;
    font-size: .78rem;
    text-transform: uppercase;
}

.actions-panel h2,
.activity-panel h2 {
    margin-bottom: .55rem;
    text-align: center;
    font-size: 1rem;
    font-style: italic;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(72px, 1fr));
    gap: .45rem;
}

.action-grid form {
    margin: 0;
}

.image-action {
    width: 100%;
    min-height: 94px;
    padding: .35rem;
    border: 1px solid #202020;
    border-radius: 5px;
    background: #606060;
    color: #fff;
    cursor: pointer;
}

.image-action-link {
    display: block;
    text-align: center;
    text-decoration: none;
}

.image-action-link.is-disabled {
    pointer-events: none;
    filter: grayscale(1);
    opacity: .45;
}

.image-action:hover:not(:disabled),
.image-action:focus-visible {
    border-color: #fff;
    background: #4a4a4a;
    outline: 2px solid var(--gold);
}

.image-action:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .45;
}

.image-action img {
    display: block;
    width: 64px;
    height: 64px;
    margin: 0 auto .2rem;
    image-rendering: pixelated;
}

.image-action span {
    display: block;
    min-height: 1.7em;
    font-size: .72rem;
}

.activity-panel ol {
    max-height: 17rem;
    margin: 0;
    padding: 0;
    overflow: auto;
    list-style: none;
}

.activity-panel li {
    display: grid;
    grid-template-columns: 5rem 1fr;
    gap: .5rem;
    padding: .48rem .3rem;
    border-top: 1px solid #686868;
    font-size: .8rem;
    line-height: 1.35;
}

.activity-panel time {
    color: #f0d58d;
    font-variant-numeric: tabular-nums;
}

.character-heading {
    display: flex;
    gap: .7rem;
    align-items: center;
    margin-bottom: .7rem;
}

.character-heading img,
.combatant.player > .character-portrait-link > img {
    width: 72px;
    height: 72px;
    border: 2px solid #333;
    border-radius: 4px;
    object-fit: cover;
    image-rendering: pixelated;
}

.character-heading h2 {
    margin: 0 0 .15rem;
    font-size: 1.1rem;
}

.character-heading p {
    margin: 0;
}

.meter {
    position: relative;
    height: 22px;
    margin: .4rem 0;
    overflow: hidden;
    border: 1px solid #333;
    border-radius: 999px;
    background: #555;
}

.meter span {
    display: block;
    height: 100%;
    background: linear-gradient(#5ee685, #1eaa4e);
}

.meter-red span {
    background: linear-gradient(#ff8d8d, #dc2020);
}

.meter b {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: .68rem;
    text-shadow: 0 1px 2px #000;
}

.recovery-timer {
    margin: .35rem 0 .55rem;
    text-align: center;
}

.recovery-button {
    padding: .22rem .55rem;
    border: 1px solid #b78b38;
    border-radius: 4px;
    background: #57451f;
    color: #fff0b5;
    font-size: .72rem;
    cursor: pointer;
}

.recovery-button:hover:not(:disabled),
.recovery-button:focus-visible {
    border-color: #ffe09a;
    background: #715b29;
    outline: 1px solid #ffe09a;
}

.recovery-button:disabled {
    border-color: #6b613f;
    background: #3f3b30;
    color: #c9bd91;
    cursor: default;
}

.stat-list {
    margin: .8rem 0;
}

.stat-list div {
    display: flex;
    justify-content: space-between;
    padding: .3rem 0;
    border-bottom: 1px solid #777;
}

.stat-list dt,
.stat-list dd {
    margin: 0;
    font-size: .78rem;
}

.crafted-consumables > div {
    min-height: 2.4rem;
    align-items: center;
}

.crafted-consumables .resource-label img {
    width: 2rem;
    height: 2rem;
}

.materials {
    max-height: 13rem;
    overflow: auto;
    padding-right: 3px;
    scrollbar-gutter: stable;
}

.equipment-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .4rem;
}

.equipment-slot {
    position: relative;
    min-height: 86px;
    display: grid;
    grid-template-rows: minmax(2.1em, auto) 1fr;
    place-items: center;
    gap: .15rem;
    padding: .25rem;
    border: 1px solid #555;
    background: #787878;
    text-align: center;
}

.equipment-slot-label {
    align-self: start;
    min-width: 0;
    color: #f5f5f5;
    font-size: .62rem;
    line-height: 1.05;
}

.equipment-slot img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.equipment-slot-broken img {
    filter: grayscale(1);
    opacity: .55;
}

.equipment-durability {
    position: absolute;
    right: 2px;
    bottom: 2px;
    padding: 1px 3px;
    background: #111;
    font-size: .62rem;
}

.equipment-slot-broken .equipment-durability {
    background: #6f222a;
}

.equipment-slot-empty {
    opacity: .55;
}

.equipment-empty-mark {
    width: 38px;
    height: 38px;
    border: 1px dashed #d2d2d2;
    border-radius: 4px;
}

.inventory-board,
.backpack-panel,
.repair-panel {
    padding: 1rem;
}

.inventory-heading {
    display: flex;
    gap: 1rem;
    align-items: start;
    justify-content: space-between;
}

.inventory-heading h2 {
    margin-bottom: .25rem;
}

.inventory-heading p,
.inventory-section > p {
    margin-bottom: 0;
    color: #eee;
    font-size: .8rem;
    line-height: 1.45;
}

.backpack-sort-control {
    display: grid;
    gap: .25rem;
    min-width: 12rem;
    color: #eee;
    font-size: .72rem;
    font-weight: 700;
}

.backpack-sort-control select {
    width: 100%;
    border: 1px solid #9a7a45;
    border-radius: 4px;
    background: #201b14;
    color: #fff;
    padding: .42rem .5rem;
}

.inventory-section {
    margin-top: 1rem;
}

.inventory-section h3 {
    margin-bottom: .5rem;
    padding-bottom: .3rem;
    border-bottom: 1px solid #747474;
    font-size: .9rem;
    font-style: italic;
}

.inventory-slot-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .55rem;
}

.inventory-slot-grid-tools {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.inventory-slot-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: .25rem;
    align-items: center;
    padding: .55rem .35rem;
    border: 1px solid #545454;
    border-radius: 6px;
    background: #7d7d7d;
    text-align: center;
}

.inventory-slot-card.is-broken,
.backpack-item.is-broken {
    border-color: #9d303a;
    background: #745b5d;
}

.inventory-slot-card h4 {
    width: 100%;
    margin: 0 0 .15rem;
    color: #f2dfaa;
    font-size: .7rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.inventory-slot-card strong {
    min-height: 2.3em;
    font-size: .78rem;
    line-height: 1.15;
}

.legacy-slot {
    position: relative;
    width: 64px;
    height: 64px;
    flex: 0 0 64px;
    image-rendering: pixelated;
}

.legacy-slot-frame,
.legacy-item-art {
    position: absolute;
    inset: 0;
    width: 64px;
    height: 64px;
    object-fit: contain;
    image-rendering: pixelated;
}

.legacy-slot-frame {
    z-index: 0;
}

.legacy-item-art {
    z-index: 1;
}

.item-stack-count {
    position: absolute;
    right: 2px;
    bottom: 2px;
    z-index: 2;
    min-width: 1.3rem;
    padding: .08rem .28rem;
    border: 1px solid #f4e4b6;
    border-radius: 999px;
    background: rgba(17, 17, 17, .92);
    color: #fff;
    font-size: .66rem;
    font-weight: 700;
    line-height: 1.15;
    text-align: center;
    text-shadow: 0 1px 1px #000;
}

.is-broken .legacy-item-art {
    filter: grayscale(1);
    opacity: .55;
}

.item-material,
.empty-slot-label {
    color: #eee;
    font-size: .68rem;
}

.durability-line {
    color: #fff;
    font-size: .7rem;
    font-variant-numeric: tabular-nums;
}

.durability-line.broken {
    color: #ffd4d8;
    font-weight: 700;
}

.broken-badge {
    display: inline-block;
    padding: .18rem .35rem;
    border: 1px solid #e78790;
    border-radius: 999px;
    background: #6f222a;
    color: #fff;
    font-size: .62rem;
    font-weight: 700;
}

.inventory-actions {
    width: 100%;
    display: grid;
    gap: .3rem;
    margin-top: auto;
    padding-top: .35rem;
}

.inventory-actions form {
    margin: 0;
}

.inventory-actions button,
.return-region-link {
    width: 100%;
    min-height: 2rem;
    padding: .35rem .45rem;
    border: 1px solid #262626;
    border-radius: 4px;
    background: #555;
    color: #fff;
    cursor: pointer;
    font-size: .68rem;
    text-decoration: none;
}

.inventory-actions button:hover:not(:disabled),
.inventory-actions button:focus-visible,
.return-region-link:hover,
.return-region-link:focus-visible {
    border-color: #fff;
    background: #454545;
    outline: 2px solid var(--gold);
}

.inventory-actions button:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.inventory-actions .repair-button {
    border-color: #765a18;
    background: #c8982b;
    color: #211705;
    font-weight: 700;
}

.backpack-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .55rem;
    margin-top: .8rem;
}

.backpack-subheading {
    margin: 1rem 0 -.25rem;
    padding-top: .75rem;
    border-top: 1px solid #747474;
    font-size: .85rem;
}

.backpack-item {
    min-width: 0;
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: .65rem;
    padding: .6rem;
    border: 1px solid #545454;
    border-radius: 6px;
    background: #7d7d7d;
}

.backpack-item h3 {
    margin: 0 0 .2rem;
    font-size: .85rem;
}

.backpack-item p {
    margin: .15rem 0;
    color: #eee;
    font-size: .7rem;
}

.repair-panel {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: .8rem;
    align-items: start;
}

.repair-panel > img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    image-rendering: pixelated;
}

.repair-panel h2 {
    margin-bottom: .3rem;
    font-size: 1rem;
}

.repair-panel p {
    margin: .25rem 0;
    font-size: .78rem;
    line-height: 1.45;
}

.repair-panel .balance-note {
    color: #f5dda0;
}

.inventory-summary {
    text-align: center;
}

.crafting-board {
    padding: 1rem;
}

.crafting-tabs {
    display: flex;
    gap: .45rem;
    margin: 1rem 0;
    overflow-x: auto;
}

.crafting-tabs a {
    min-width: max-content;
    padding: .5rem .75rem;
    border: 1px solid #393939;
    border-radius: 5px;
    background: #666;
    color: #fff;
    font-size: .75rem;
    text-decoration: none;
}

.crafting-tabs a:hover,
.crafting-tabs a:focus-visible {
    border-color: #fff;
    outline: 2px solid var(--gold);
}

.crafting-back-to-categories {
    display: inline-block;
    margin-top: .7rem;
    padding: .4rem .6rem;
    color: #fff0bd;
    font-size: .75rem;
}

#crafting-categories {
    scroll-margin-top: 1rem;
}

.crafting-category {
    scroll-margin-top: 1rem;
}

.crafting-category + .crafting-category {
    margin-top: 1.25rem;
}

.crafting-category > h3 {
    margin-bottom: .55rem;
    padding-bottom: .35rem;
    border-bottom: 1px solid #747474;
    font-size: 1rem;
    font-style: italic;
}

.recipe-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .6rem;
}

.recipe-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: .55rem;
    padding: .65rem;
    border: 1px solid #4d4d4d;
    border-radius: 6px;
    background: #7d7d7d;
}

.recipe-card.is-unavailable {
    background: #727272;
}

.recipe-card.is-unavailable .recipe-art img {
    filter: grayscale(1);
    opacity: .48;
}

.recipe-art {
    width: 76px;
    height: 76px;
    display: grid;
    place-items: center;
    border: 1px solid #505050;
    border-radius: 5px;
    background: #666;
}

.recipe-art img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    image-rendering: pixelated;
}

.recipe-card-top {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: .65rem;
    align-items: start;
}

.recipe-card-heading,
.recipe-card-details {
    min-width: 0;
}

.recipe-card h4 {
    margin: 0 0 .25rem;
    color: #fff0c3;
    font-size: .88rem;
}

.recipe-card h5 {
    margin: 0 0 .25rem;
    color: #f4e4b6;
    font-size: .66rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.recipe-description,
.recipe-result,
.recipe-requirements,
.maximum-craftable {
    margin: .25rem 0;
    font-size: .68rem;
    line-height: 1.35;
}

.recipe-description {
    color: #eee;
}

.recipe-result {
    color: #e7d49d;
}

.recipe-requirements {
    color: #ffd3d7;
    font-weight: 700;
}

.recipe-costs {
    margin: 0 0 .45rem;
}

.recipe-costs div {
    display: flex;
    gap: .35rem;
    justify-content: space-between;
    padding: .2rem 0;
    border-bottom: 1px solid #727272;
    font-size: .64rem;
}

.recipe-costs dt,
.recipe-costs dd {
    margin: 0;
}

.recipe-costs dt {
    display: inline-flex;
    gap: .25rem;
    align-items: center;
}

.recipe-costs img {
    width: 16px;
    height: 16px;
    object-fit: contain;
    image-rendering: pixelated;
}

.recipe-costs .is-missing {
    color: #ffd3d7;
}

.recipe-stats {
    display: grid;
    gap: .15rem;
    margin: .45rem 0;
    padding-top: .35rem;
    border-top: 1px solid #727272;
}

.recipe-stats div {
    display: flex;
    justify-content: space-between;
    font-size: .68rem;
}

.recipe-stats dt,
.recipe-stats dd {
    margin: 0;
}

.recipe-stats dt {
    color: #f4e4b6;
}

.recipe-card form {
    margin-top: .55rem;
}

.recipe-card label {
    display: block;
    margin-bottom: .2rem;
    font-size: .64rem;
}

.crafting-quantity {
    display: grid;
    grid-template-columns: 3.75rem 4.5rem;
    gap: .35rem;
    justify-content: start;
}

.crafting-quantity input,
.crafting-quantity button {
    width: 100%;
    min-height: 2rem;
    border: 1px solid #2b2b2b;
    border-radius: 4px;
    font: inherit;
}

.crafting-quantity input {
    padding: .3rem;
    background: #eee;
    color: #111;
}

.crafting-quantity button {
    background: #c8982b;
    color: #211705;
    cursor: pointer;
    font-size: .7rem;
    font-weight: 700;
}

.crafting-quantity button:disabled,
.crafting-quantity input:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.maximum-craftable {
    color: #fff;
    font-variant-numeric: tabular-nums;
}

.facility-list dd {
    color: #f1d385;
}

.facility-list dd.requirement-available {
    color: #c9ffd6;
}

.facility-list dd.requirement-missing {
    color: #ffd3d7;
}

.requirement-status {
    display: inline-grid;
    width: 1.15rem;
    height: 1.15rem;
    margin-left: .25rem;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    font-size: .82rem;
    font-weight: 900;
    line-height: 1;
}

.requirement-available .requirement-status {
    background: #276d3c;
}

.requirement-missing .requirement-status {
    background: #842b34;
}

.crafting-summary h3 {
    margin: .85rem 0 .3rem;
    font-size: .85rem;
}

.backpack-icon {
    width: 96px;
    height: 96px;
    object-fit: contain;
    image-rendering: pixelated;
}

.return-region-link {
    display: grid;
    place-items: center;
    margin-top: .7rem;
}

.world-map-layout {
    width: min(980px, calc(100% - 2rem));
    margin: 1.5rem auto;
}

.world-map-panel {
    padding: 1rem;
}

.world-map-heading {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 1rem;
}

.world-map-heading h2,
.world-map-heading p {
    margin-top: 0;
}

.world-map-grid {
    width: min(800px, 100%);
    aspect-ratio: 1;
    display: grid;
    grid-template-columns: repeat(50, 1fr);
    margin: 1rem auto;
    border: 2px solid #b58b36;
    background: #182117;
}

.world-map-cell {
    position: relative;
    padding: 0;
    border: 0;
    border-radius: 0;
    cursor: crosshair;
    min-width: 0;
    background: #35442f;
    box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .06);
}

.world-map-cell.is-ocean, .world-map-legend i.is-ocean { background: #4688b6; }
.world-map-cell.is-ground, .world-map-legend i.is-ground { background: #cdb58a; }

.world-map-cell.has-dungeon {
    background: #9c5d2d;
}

.world-map-cell.is-sealed {
    background: #aeb5bd;
}

.world-map-cell.is-current {
    background: #4fbcff;
    box-shadow: 0 0 0 2px #fff;
    z-index: 2;
}

.world-map-cell:hover,
.world-map-cell:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 0;
    z-index: 3;
}

.world-map-cell.has-settlement::after,
.world-map-legend i.has-settlement::after {
    content: '';
    position: absolute;
    inset: 22%;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 0 0 1px #161616;
    pointer-events: none;
}

.world-map-legend i.has-settlement { position: relative; }
.world-map-details { min-height: 2.5em; }

.world-map-open,
.building-action-link {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: .4rem;
    padding: .5rem;
    color: inherit;
    font-weight: 700;
    text-decoration: none;
}

.world-map-open img, .building-action-link img { width: 64px; height: 64px; image-rendering: pixelated; }
.world-map-open:hover, .world-map-open:focus-visible,
.building-action-link:hover, .building-action-link:focus-visible { outline: 2px solid #d39d3e; }

.world-map-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    font-size: .8rem;
}

.world-map-legend span {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
}

.world-map-legend i {
    width: .8rem;
    height: .8rem;
    border: 1px solid rgba(255, 255, 255, .7);
    background: #35442f;
}

.world-map-legend i.is-current { background: #4fbcff; }

.world-map-legend i.has-dungeon { background: #9c5d2d; }
.world-map-legend i.is-sealed { background: #aeb5bd; }

.combat-result-layout {
    width: min(900px, calc(100% - 2rem));
    margin: 1.5rem auto;
}

.combat-victory {
    padding: 0;
    overflow: hidden;
}

.combat-victory-continue {
    width: 100%;
    padding: 2rem;
    display: grid;
    justify-items: center;
    gap: 1rem;
    border: 0;
    background: radial-gradient(circle at top, #4c421f, #17140c 68%);
    color: #fff;
    cursor: pointer;
}

.combat-defeat .combat-victory-continue {
    background: radial-gradient(circle at top, #54272b, #180d0f 68%);
}

.combat-defeat .combat-defeated-portrait {
    filter: drop-shadow(0 0 1.25rem rgba(215, 83, 83, .45));
    transform: none;
}

.combat-defeat .combat-reward-card {
    border-color: #b86b6b;
    background: rgba(32, 13, 16, .86);
}

.combat-defeat .combat-reward-card strong {
    color: #ffaaa2;
}

.combat-loss-grid {
    grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
}

.combat-result-summary {
    font-weight: 700;
    color: #f1d6c9;
}

.combat-defeated-creature {
    position: relative;
    width: min(19rem, 70vw);
    min-height: 13rem;
    display: grid;
    place-items: center;
}

.combat-defeated-portrait {
    max-width: 100%;
    max-height: 15rem;
    filter: grayscale(.8) brightness(.55);
    transform: rotate(-6deg);
}

.combat-corpse-mark {
    position: absolute;
    bottom: .25rem;
    width: 4rem;
    image-rendering: pixelated;
}

.combat-victory-title {
    font-size: clamp(1.35rem, 4vw, 2.2rem);
}

.combat-reward-grid {
    width: min(38rem, 100%);
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .75rem;
}

.combat-reward-card {
    min-height: 7rem;
    display: grid;
    place-items: center;
    align-content: center;
    gap: .3rem;
    padding: .75rem;
    border: 1px solid #d4ad43;
    border-radius: .5rem;
    background: rgba(20, 18, 10, .82);
}

.combat-reward-card img {
    width: 2rem;
    height: 2rem;
    object-fit: contain;
    image-rendering: pixelated;
}

.combat-reward-card strong {
    color: #ffe07c;
    font-size: 1.2rem;
}

.leaderboard-reward-result .combat-victory-continue {
    cursor: default;
}

.leaderboard-reward-grid {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
}

.leaderboard-reward-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .65rem;
}

.leaderboard-reward-actions button {
    min-width: 12rem;
}

.combat-board {
    display: grid;
    gap: .75rem;
    padding: 1rem;
}

.combatant {
    min-height: 126px;
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 1rem;
    align-items: center;
    padding: .8rem;
    border: 1px solid #333;
    border-radius: 6px;
    background: #858585;
}

.combatant.creature > img {
    width: 96px;
    height: 96px;
    object-fit: contain;
    image-rendering: pixelated;
}

.combatant h2 {
    margin-bottom: .25rem;
}

.combatant p {
    font-size: .8rem;
}

.versus {
    text-align: center;
    color: #f1d385;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .18em;
    text-transform: uppercase;
}

.combat-actions {
    grid-template-columns: repeat(3, 1fr);
}

.dungeon-board,
.dungeon-difficulty-panel,
.dungeon-creature-reference,
.dungeon-combat-panel,
.dungeon-shrine-panel,
.dungeon-room-clear,
.dungeon-purpose-panel,
.dungeon-results-panel,
.dungeon-empty-state {
    padding: 1rem;
}

.dungeon-board > h2,
.dungeon-difficulty-panel > h2,
.dungeon-creature-reference > h2,
.dungeon-shrine-panel > h2,
.dungeon-room-clear > h2,
.dungeon-purpose-panel > h2,
.dungeon-results-panel > h2 {
    margin-bottom: .65rem;
    text-align: center;
}

.dungeon-heading {
    display: flex;
    gap: .75rem;
    align-items: start;
    justify-content: space-between;
    margin-bottom: .7rem;
}

.dungeon-heading h2 {
    margin-bottom: .2rem;
}

.dungeon-heading p {
    margin: 0;
    color: #eee;
    font-size: .78rem;
}

.dungeon-map {
    position: relative;
    width: 100%;
    max-width: 448px;
    aspect-ratio: 448 / 320;
    margin: 0 auto;
    overflow: visible;
    border: 1px solid #242424;
    border-radius: 4px;
    background: #171724;
    image-rendering: pixelated;
}

.dungeon-map > img {
    width: 100%;
    height: 100%;
    display: block;
}

.dungeon-target {
    position: absolute;
    left: var(--target-left);
    top: var(--target-top);
    z-index: 2;
    transform: translate(-50%, -50%);
}

.dungeon-target form {
    margin: 0;
}

.dungeon-target button {
    position: relative;
    width: 48px;
    height: 48px;
    padding: 4px;
    border: 2px solid #f1d385;
    border-radius: 50%;
    background: rgba(20, 20, 20, .68);
    cursor: pointer;
}

.dungeon-target button:hover:not(:disabled),
.dungeon-target button:focus-visible {
    border-color: #fff;
    outline: 3px solid var(--gold);
}

.dungeon-target button:disabled {
    cursor: not-allowed;
    opacity: .7;
}

.dungeon-target img {
    width: 36px;
    height: 36px;
    object-fit: contain;
    image-rendering: pixelated;
}

.dungeon-target span {
    position: absolute;
    left: 50%;
    bottom: calc(100% + .25rem);
    min-width: max-content;
    max-width: 13rem;
    padding: .25rem .4rem;
    transform: translateX(-50%);
    border: 1px solid #d5b860;
    border-radius: 4px;
    background: rgba(20, 20, 20, .95);
    color: #fff;
    font-size: .62rem;
    pointer-events: none;
    opacity: 0;
}

.dungeon-target:hover span,
.dungeon-target:focus-within span,
.dungeon-target.is-selected span {
    opacity: 1;
}

.dungeon-target.is-selected button {
    border-color: #fff;
    box-shadow: 0 0 0 3px var(--gold);
}

.dungeon-target.is-defeated {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
}

.dungeon-target.is-defeated img {
    width: 32px;
    height: 32px;
}

.dungeon-status-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .4rem;
    margin-top: .7rem;
}

.dungeon-status-grid div {
    min-width: 0;
    padding: .5rem;
    border: 1px solid #555;
    border-radius: 4px;
    background: #777;
    text-align: center;
}

.dungeon-status-grid span,
.dungeon-status-grid strong {
    display: block;
}

.dungeon-status-grid span {
    color: #eee;
    font-size: .65rem;
}

.dungeon-status-grid strong {
    margin-top: .18rem;
    color: #fff0c3;
    font-size: .75rem;
}

.dungeon-entry-message {
    padding: .55rem;
    border: 1px solid #e0b74d;
    border-radius: 4px;
    background: #6b5928;
    text-align: center;
}

.dungeon-difficulty-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .5rem;
}

.dungeon-difficulty-card {
    min-width: 0;
    padding: .65rem;
    border: 1px solid #555;
    border-radius: 5px;
    background: #797979;
}

.dungeon-difficulty-card h3 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .35rem;
    margin-bottom: .5rem;
    color: #fff0c3;
    text-align: center;
}

.seal-eligible-chip {
    padding: .08rem .28rem;
    border: 1px solid #5b4310;
    border-radius: 999px;
    background: #e0b74d;
    color: #231a08;
    font-size: .55rem;
    font-weight: 700;
    line-height: 1.2;
    text-transform: uppercase;
}

.dungeon-difficulty-card dl {
    margin: 0 0 .6rem;
}

.dungeon-difficulty-card dl div {
    display: flex;
    gap: .3rem;
    justify-content: space-between;
    padding: .2rem 0;
    border-bottom: 1px solid #686868;
    font-size: .63rem;
}

.dungeon-difficulty-card dt,
.dungeon-difficulty-card dd {
    margin: 0;
}

.dungeon-difficulty-card dd {
    text-align: right;
}

.dungeon-difficulty-card button,
.dungeon-room-clear button,
.dungeon-return-button {
    width: 100%;
    min-height: 2.35rem;
    padding: .45rem .7rem;
    border: 1px solid #5b4310;
    border-radius: 4px;
    background: #d1a33a;
    color: #241a07;
    cursor: pointer;
    font-weight: 700;
}

.dungeon-difficulty-card button:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .45;
}

.dungeon-creature-reference > div {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: .4rem;
}

.dungeon-creature-reference figure {
    margin: 0;
    padding: .4rem;
    border: 1px solid #555;
    background: #777;
    text-align: center;
}

.dungeon-creature-reference img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    image-rendering: pixelated;
}

.dungeon-creature-reference figcaption {
    min-height: 2.2em;
    font-size: .62rem;
}

.dungeon-combatants {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .6rem;
}

.dungeon-combatants .combatant {
    grid-template-columns: 84px minmax(0, 1fr);
}

.dungeon-combatants .combatant.creature > img {
    width: 76px;
    height: 76px;
}

.dungeon-combat-actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-top: .65rem;
}

.dungeon-shrine-panel > p,
.dungeon-room-clear > p,
.dungeon-purpose-panel > p {
    text-align: center;
}

.dungeon-shrine-actions {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

.dungeon-results-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .4rem;
}

.dungeon-results-list div {
    display: flex;
    justify-content: space-between;
    padding: .55rem;
    border: 1px solid #555;
    border-radius: 4px;
    background: #777;
}

.dungeon-results-list dt,
.dungeon-results-list dd {
    margin: 0;
    font-size: .76rem;
}

.dungeon-return-button {
    display: block;
    width: max-content;
    min-width: 12rem;
    margin: .8rem auto 0;
    text-align: center;
    text-decoration: none;
}

.dungeon-result-heading {
    margin-top: .7rem;
    text-align: center;
}

.dungeon-result-heading p {
    margin: .55rem 0 0;
}

.farming-board,
.farm-action-panel,
.farm-storage {
    padding: 1rem;
}

.farming-heading {
    display: flex;
    gap: 1rem;
    align-items: end;
    justify-content: space-between;
    margin-bottom: .8rem;
}

.farming-heading-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .45rem;
    justify-content: flex-end;
}

.farming-heading h2,
.farm-action-panel h2,
.farm-storage h2 {
    margin-bottom: .25rem;
}

.farming-heading p {
    margin: 0;
    color: #eee;
    font-size: .8rem;
    line-height: 1.45;
}

.farm-field-frame {
    width: max-content;
    max-width: 100%;
    margin: 0 auto;
    padding: .45rem;
    border: 1px solid #3b3b3b;
    border-radius: 6px;
    background: #858585;
}

.farm-field-grid {
    display: grid;
    grid-template-columns: repeat(5, 48px);
    grid-template-rows: repeat(5, 48px);
}

.farm-field-grid > img,
.farm-plot,
.farm-plot > img {
    width: 48px;
    height: 48px;
}

.farm-field-grid > img,
.farm-plot > img {
    display: block;
    object-fit: fill;
    image-rendering: pixelated;
}

.farm-plot {
    position: relative;
    display: block;
    padding: 0;
    overflow: hidden;
    border: 0;
    background: #ad5a42;
    color: #fff;
    text-decoration: none;
}

.farm-plot:focus-visible {
    z-index: 2;
    outline: 3px solid #fff;
    outline-offset: -3px;
}

.farm-plot-unlocked {
    box-shadow: inset 0 0 0 2px rgba(221, 196, 124, .45);
}

.farm-plot-planted {
    box-shadow: inset 0 0 0 2px rgba(83, 134, 62, .72);
}

.farm-plot-ready {
    box-shadow: inset 0 0 0 3px #f3cf57;
}

.farm-plot-unlocking {
    box-shadow: inset 0 0 0 2px #78a9d8;
}

.farm-plot.is-selected {
    z-index: 1;
    outline: 3px solid #fff;
    outline-offset: -3px;
}

.farm-plot .farm-selection-overlay {
    position: absolute;
    z-index: 1;
    inset: 0;
    pointer-events: none;
}

.farm-plot.is-selected .farm-plot-number {
    border-color: #fff;
    background: #f3cf57;
    color: #211705;
}

.farm-plot-locked img,
.farm-plot-unlocking img {
    filter: grayscale(1) brightness(.48);
}

.farm-lock,
.farm-unlock-mark {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: rgba(15, 15, 15, .43);
    color: #f1d385;
    font-size: 1.8rem;
    font-weight: 900;
    line-height: 1;
    text-shadow: 0 1px 2px #000;
}

.farm-unlock-mark {
    color: #b9d8ff;
    font-size: 1.05rem;
    letter-spacing: 0;
}

.farm-plot-number,
.farm-ready-mark {
    position: absolute;
    z-index: 2;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .65);
    border-radius: 999px;
    background: rgba(17, 17, 17, .8);
    color: #fff;
    font-size: .58rem;
    font-weight: 700;
    line-height: 1;
}

.farm-plot-number {
    left: 2px;
    bottom: 2px;
    width: 16px;
    height: 16px;
}

.farm-ready-mark {
    top: 2px;
    right: 2px;
    width: 17px;
    height: 17px;
    border-color: #fff3b3;
    background: #9b6d00;
}

.farm-state-legend {
    display: flex;
    flex-wrap: wrap;
    gap: .65rem 1rem;
    justify-content: center;
    margin-top: .8rem;
    color: #f4f4f4;
    font-size: .68rem;
}

.farm-state-legend span {
    display: inline-flex;
    gap: .3rem;
    align-items: center;
}

.legend-swatch {
    width: 12px;
    height: 12px;
    display: inline-block;
    border: 2px solid #ddc47c;
    background: #ad5a42;
}

.legend-selected {
    border-color: #fff;
}

.legend-planted {
    border-color: #53863e;
    background: #6e8b46;
}

.legend-ready {
    border-color: #f3cf57;
    background: #b8891c;
}

.legend-unlocking {
    border-color: #78a9d8;
    background: #3a5975;
}

.legend-locked {
    border-color: #484848;
    background: #333;
}

.farm-selection-prompt,
.farm-action-panel > p {
    margin-bottom: 0;
    color: #eee;
    font-size: .8rem;
}

.selected-plot-summary,
.seed-selection,
.harvest-selection,
.growth-status {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: .8rem;
    align-items: start;
}

.selected-plot-summary {
    margin-bottom: .8rem;
    padding-bottom: .7rem;
    border-bottom: 1px solid #737373;
}

.selected-plot-summary img,
.seed-selection > img,
.harvest-selection > img,
.growth-status > img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    image-rendering: pixelated;
}

.selected-plot-summary h3,
.seed-selection h3,
.harvest-selection h3,
.growth-status h3 {
    margin: 0 0 .2rem;
    color: #fff0c3;
    font-size: .9rem;
}

.selected-plot-summary p,
.seed-selection p,
.harvest-selection p,
.growth-status p {
    margin: .2rem 0;
    font-size: .76rem;
    line-height: 1.45;
}

.plot-state-label {
    font-weight: 700;
}

.plot-state-ready {
    color: #ffe28c;
}

.plot-state-locked,
.farm-action-warning {
    color: #ffd3d7;
}

.seed-selection form,
.harvest-selection form {
    margin-top: .55rem;
}

.seed-selection button,
.harvest-selection button {
    min-width: 9rem;
    min-height: 2.25rem;
    padding: .4rem .7rem;
    border: 1px solid #342609;
    border-radius: 4px;
    background: #c8982b;
    color: #211705;
    cursor: pointer;
    font-weight: 700;
}

.seed-selection button:hover:not(:disabled),
.seed-selection button:focus-visible,
.harvest-selection button:hover,
.harvest-selection button:focus-visible {
    border-color: #fff;
    outline: 2px solid var(--gold);
}

.seed-selection button:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .45;
}

.farm-seed-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .65rem;
}

.farm-seed-card {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: .65rem;
    padding: .65rem;
    border: 1px solid #626262;
    border-radius: 5px;
    background: #747474;
}

.farm-seed-card > img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.farm-seed-card h3,
.farm-seed-card p {
    margin: 0 0 .3rem;
}

.farm-seed-card form {
    margin-top: .45rem;
}

.farm-seed-card button {
    padding: .4rem .55rem;
    border: 1px solid #342609;
    border-radius: 4px;
    background: #c8982b;
    color: #211705;
    cursor: pointer;
    font-weight: 700;
}

.farm-seed-card button:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .45;
}

.farm-countdown {
    color: #f0d58d;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.farm-storage-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .65rem;
    margin-top: .7rem;
}

.farm-storage-grid div {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    gap: .65rem;
    align-items: center;
    padding: .6rem;
    border: 1px solid #555;
    border-radius: 5px;
    background: #7b7b7b;
}

.farm-storage-grid img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    image-rendering: pixelated;
}

.farm-storage-grid span {
    font-size: .78rem;
}

.farm-storage-grid strong {
    min-width: 2.2rem;
    color: #fff0c3;
    font-size: 1.05rem;
    text-align: right;
}

.farm-cycle-panel {
    text-align: center;
}

.farm-time-art {
    width: 112px;
    height: 73px;
    margin: 0 auto .75rem;
    border: 1px solid #333;
    object-fit: contain;
    image-rendering: pixelated;
}

.farm-growable-list {
    margin-top: .85rem;
    text-align: left;
}

.farm-growable-list h3 {
    margin: 0 0 .45rem;
    color: #fff0c3;
    font-size: .85rem;
    text-align: center;
}

.farm-growable-list ul {
    display: grid;
    gap: .45rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.farm-growable-list li {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: .25rem .55rem;
    align-items: center;
    padding: .45rem;
    border: 1px solid #565656;
    border-radius: 5px;
    background: #747474;
}

.farm-growable-list img {
    grid-row: span 2;
    width: 34px;
    height: 34px;
    object-fit: contain;
    image-rendering: pixelated;
}

.farm-growable-list span {
    color: #fff;
    font-size: .78rem;
    font-weight: 700;
}

.farm-growable-list small {
    color: #e6e6e6;
    font-size: .65rem;
    line-height: 1.25;
}

.expedition-board {
    padding: 1rem;
}

.expedition-map {
    overflow: hidden;
    border-radius: 4px;
    background: #74621b;
}

.expedition-map img {
    height: 100%;
    object-fit: fill;
}

.expedition-heading,
.expedition-section-heading {
    display: flex;
    gap: 1rem;
    align-items: end;
    justify-content: space-between;
}

.expedition-heading {
    margin-top: .7rem;
}

.expedition-heading h2,
.expedition-section-heading h2 {
    margin-bottom: .2rem;
}

.expedition-heading p,
.expedition-section-heading span {
    margin: 0;
    color: #eee;
    font-size: .78rem;
}

.expedition-controls {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr);
    gap: 1rem;
    align-items: center;
    margin-top: .85rem;
    padding-top: .85rem;
    border-top: 1px solid #747474;
}

.expedition-movement {
    width: max-content;
    display: grid;
    grid-template-areas:
        "nw n ne"
        "w center e"
        "sw s se";
    grid-template-columns: repeat(3, 44px);
    grid-template-rows: repeat(3, 44px);
    gap: .25rem;
    margin: 0 auto;
}

.expedition-movement form {
    margin: 0;
}

.expedition-movement .move-nw { grid-area: nw; }
.expedition-movement .move-n { grid-area: n; }
.expedition-movement .move-ne { grid-area: ne; }
.expedition-movement .move-w { grid-area: w; }
.expedition-movement .move-e { grid-area: e; }
.expedition-movement .move-sw { grid-area: sw; }
.expedition-movement .move-s { grid-area: s; }
.expedition-movement .move-se { grid-area: se; }

.expedition-movement button {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    padding: 4px;
    border: 1px solid #3d2c09;
    border-radius: 6px;
    background: #6f6f6f;
    cursor: pointer;
}

.expedition-movement button:hover,
.expedition-movement button:focus-visible {
    border-color: #fff;
    background: #5d5d5d;
    outline: 2px solid var(--gold);
}

.expedition-movement img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    image-rendering: pixelated;
}

.movement-center {
    grid-area: center;
    display: grid;
    place-items: center;
    border: 1px solid #4a4a4a;
    border-radius: 6px;
    background: #777;
    color: #fff0c3;
    font-size: .62rem;
    font-weight: 700;
    line-height: 1;
}

.expedition-facts {
    margin: 0;
}

.expedition-facts div {
    display: flex;
    justify-content: space-between;
    padding: .4rem .5rem;
    border-bottom: 1px solid #707070;
    font-size: .75rem;
}

.expedition-facts dt,
.expedition-facts dd {
    margin: 0;
}

.expedition-facts dd {
    color: #fff0c3;
    font-weight: 700;
}

.explorers-panel {
    padding: 1rem;
}

.explorer-grid {
    display: flex;
    flex-wrap: wrap;
    gap: .65rem;
    margin-top: .75rem;
}

.explorer-grid figure {
    width: 82px;
    margin: 0;
    padding: .45rem;
    border: 1px solid #545454;
    border-radius: 6px;
    background: #7a7a7a;
    text-align: center;
}

.explorer-grid img {
    width: 64px;
    height: 64px;
    object-fit: cover;
    object-position: top;
    image-rendering: pixelated;
}

.explorer-grid figcaption {
    margin-top: .3rem;
    overflow-wrap: anywhere;
    color: #fff0c3;
    font-size: .65rem;
}

.expedition-command-panel form {
    margin: 0;
}

.expedition-enter-button {
    width: 100%;
    display: grid;
    gap: .4rem;
    place-items: center;
    padding: .65rem;
    border: 1px solid #5b4310;
    border-radius: 6px;
    background: #d1a33a;
    color: #241a07;
    cursor: pointer;
    font-weight: 700;
}

.expedition-enter-button:hover,
.expedition-enter-button:focus-visible {
    border-color: #fff;
    outline: 2px solid #fff;
}

.expedition-enter-button img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    image-rendering: pixelated;
}

.gems-title-panel {
    padding: .65rem .8rem;
    text-align: center;
}

.gems-title-panel h2 {
    margin-bottom: .25rem;
}

.gems-title-panel p {
    margin-bottom: 0;
    color: #eee;
    font-size: .75rem;
}

.gems-entry {
    min-height: 270px;
    display: grid;
    place-items: center;
    align-content: center;
    text-align: center;
}

.gems-entry h2,
.gems-entry p {
    margin-bottom: .65rem;
}

.gems-jackpot-art {
    width: 100px;
    height: 100px;
    object-fit: contain;
    image-rendering: pixelated;
}

.gems-entry form {
    margin: .25rem 0;
}

.gems-start-button {
    min-width: 170px;
    display: grid;
    gap: .35rem;
    place-items: center;
    padding: .55rem .8rem;
    border: 1px solid #3d2c09;
    border-radius: 7px;
    background: #c9972d;
    color: #211705;
    cursor: pointer;
    font-weight: 700;
}

.gems-start-button img {
    width: 54px;
    height: 54px;
    object-fit: contain;
    image-rendering: pixelated;
}

.gems-start-button:hover:not(:disabled),
.gems-start-button:focus-visible {
    border-color: #fff;
    outline: 2px solid var(--gold);
}

.gems-start-button:disabled,
.gems-command-button:disabled {
    cursor: not-allowed;
    filter: grayscale(1);
    opacity: .5;
}

.gems-insufficient {
    color: #ffd3d7;
    font-weight: 700;
}

.gems-target-panel {
    padding: .8rem;
}

.gems-target {
    display: grid;
    grid-template-columns: minmax(120px, .7fr) minmax(220px, 1.3fr);
    gap: 1rem;
    align-items: center;
}

.gems-target > div {
    text-align: center;
}

.gems-target h2 {
    margin-bottom: .4rem;
    text-decoration: underline;
}

.gems-target img {
    width: 72px;
    height: 72px;
    object-fit: contain;
    image-rendering: pixelated;
}

.gems-live-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .45rem;
    margin: 0;
}

.gems-live-stats div {
    padding: .5rem;
    border: 1px solid #666;
    border-radius: 5px;
    background: #7b7b7b;
    text-align: center;
}

.gems-live-stats dt,
.gems-live-stats dd {
    margin: 0;
}

.gems-live-stats dt {
    color: #eee;
    font-size: .68rem;
}

.gems-live-stats dd {
    margin-top: .2rem;
    color: #fff0c3;
    font-size: .86rem;
    font-weight: 700;
}

.gems-latest {
    margin: .75rem 0 0;
    padding: .5rem;
    border-radius: 5px;
    text-align: center;
    font-weight: 700;
}

.gems-latest.is-match {
    border: 1px solid #285f37;
    background: #4d8a5e;
}

.gems-latest.is-miss {
    border: 1px solid #744044;
    background: #8a5559;
}

.gems-board-panel {
    overflow: hidden;
}

.gems-board {
    width: min(100%, 370px);
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: .3rem;
    margin: 0 auto;
}

.gems-cell {
    aspect-ratio: 1;
    min-width: 0;
    display: grid;
    place-items: center;
    margin: 0;
    border: 1px solid #484848;
    border-radius: 6px;
    background: #777;
}

.gems-cell button {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    padding: 2px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    cursor: pointer;
}

.gems-cell img {
    width: min(100%, 64px);
    height: min(100%, 64px);
    object-fit: contain;
    image-rendering: pixelated;
}

.gems-cell.is-hidden {
    background: #6f6f6f;
}

.gems-cell.is-hidden button:hover,
.gems-cell.is-hidden button:focus-visible {
    background: #858585;
    outline: 3px solid #fff0c3;
    outline-offset: -3px;
}

.gems-cell.is-revealed {
    border-width: 2px;
}

.gems-cell.is-revealed.is-match {
    border-color: #f0d45c;
    background: #7b743f;
}

.gems-cell.is-revealed.is-miss {
    border-color: #4f6375;
    background: #66727d;
}

.gems-cell.is-closed {
    filter: grayscale(.7);
    opacity: .72;
}

.gems-result-panel {
    text-align: center;
}

.gems-result-panel h2 {
    color: #fff0c3;
}

.gems-result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .6rem;
    justify-content: center;
}

.gems-result-actions form {
    margin: 0;
}

.gems-command-button {
    min-height: 2.4rem;
    padding: .5rem .8rem;
    border: 1px solid #444;
    border-radius: 5px;
    background: #737373;
    color: #fff;
    cursor: pointer;
    font-weight: 700;
}

.gems-command-button.is-primary {
    border-color: #5c4310;
    background: #c9972d;
    color: #211705;
}

.gems-command-button:hover:not(:disabled),
.gems-command-button:focus-visible {
    border-color: #fff;
    outline: 2px solid var(--gold);
}

.gems-character-panel .portrait {
    display: block;
    margin: 0 auto;
}

.gems-empty-winners {
    color: #eee;
    font-size: .76rem;
    text-align: center;
}

.gems-winner-list {
    display: grid;
    gap: .45rem;
    margin: .6rem 0 0;
    padding: 0;
    list-style: none;
}

.gems-winner-list li {
    display: grid;
    gap: .12rem;
    padding: .45rem;
    border: 1px solid #686868;
    border-radius: 5px;
    background: #7c7c7c;
    font-size: .72rem;
}

.gems-winner-list span {
    color: #fff0c3;
    font-weight: 700;
}

.gems-winner-list time {
    color: #e4e4e4;
    font-size: .64rem;
}

footer {
    padding: 1.2rem;
    color: #ddd;
    text-align: center;
    font-size: .72rem;
}

@media (max-width: 980px) {
    .game-board {
        grid-template-columns: 1fr minmax(230px, 300px);
    }

    .navigation-panel {
        position: static;
        grid-column: 1 / -1;
        display: flex;
        gap: .45rem;
        align-items: center;
        overflow-x: auto;
    }

    .navigation-panel h2,
    .navigation-panel hr,
    .navigation-panel .panel-note {
        display: none;
    }

    .navigation-panel .nav-link {
        min-width: 8rem;
        margin: 0;
    }

    .region-switch {
        display: flex;
        gap: .45rem;
        align-items: center;
        margin: 0;
        padding: 0;
        border: 0;
    }

    .region-switch h3 {
        display: none;
    }

    .region-switch form {
        margin: 0;
    }

    .region-switch-button {
        min-width: 8rem;
        white-space: nowrap;
    }
}

@media (max-width: 720px) {
    .masthead {
        padding-top: .8rem;
    }

    .game-board {
        width: calc(100% - 1rem);
        max-width: 560px;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }

    .navigation-panel,
    .main-column,
    .character-panel,
    .building-storage-panel {
        width: 100%;
        min-width: 0;
        max-width: 100%;
    }

    .character-panel {
        position: static;
        order: 2;
    }

    .main-column {
        order: 0;
    }

    .navigation-panel {
        order: 1;
    }

    .navigation-panel .nav-link-gems {
        min-width: 9.5rem;
        gap: .2rem;
        padding: .7rem .25rem;
        font-size: .85rem;
    }

    .nav-link-gems img {
        width: 14px;
        height: 14px;
    }

    .resource-pools {
        grid-template-columns: repeat(2, 1fr);
    }

    .action-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .inventory-slot-grid,
    .inventory-slot-grid-tools {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .recipe-grid {
        grid-template-columns: 1fr;
    }

    .building-access-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .construction-grid {
        grid-template-columns: 1fr;
    }

    .building-storage-panel {
        position: static;
        order: 2;
    }

    .building-status-list {
        grid-template-columns: 1fr;
    }

    .production-actions-grid {
        grid-template-columns: 1fr;
    }

    .farming-heading {
        align-items: start;
    }

    .settlement-unavailable-layout {
        grid-template-columns: 110px minmax(0, 1fr);
    }

    .settlement-unavailable-art {
        width: 110px;
    }

    .combatant {
        grid-template-columns: 78px 1fr;
    }

    .combatant.creature > img {
        width: 72px;
        height: 72px;
    }

    .dungeon-difficulty-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dungeon-status-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dungeon-creature-reference > div {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dungeon-combatants {
        grid-template-columns: 1fr;
    }

    .dungeon-shrine-actions {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .expedition-controls {
        grid-template-columns: 1fr;
    }

    .gems-target {
        grid-template-columns: minmax(110px, .65fr) minmax(0, 1.35fr);
    }
}

@media (max-width: 400px) {
    .panel {
        padding: .55rem;
        border-radius: 7px;
    }

    .region-board {
        padding: .45rem;
    }

    .region-heading {
        display: block;
        padding: 0 .25rem;
    }

    .status-chip {
        display: inline-block;
        margin-top: .45rem;
    }

    .action-grid,
    .combat-actions {
        grid-template-columns: repeat(2, 1fr);
    }

    .activity-panel li {
        grid-template-columns: 1fr;
        gap: .12rem;
    }

    .backpack-grid {
        grid-template-columns: 1fr;
    }

    .inventory-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .backpack-sort-control {
        min-width: 0;
    }

    .building-hotspot {
        width: 2rem;
        height: 2rem;
    }

    .dungeon-hotspot {
        width: 2.25rem;
        height: 2.25rem;
    }

    .dungeon-hotspot > img {
        width: 1rem;
        height: 1rem;
    }

    .notice-with-action {
        align-items: stretch;
        flex-direction: column;
    }

    .notice-repeat-action {
        width: 100%;
    }

    .notice-combat-action {
        width: 100%;
    }

    .building-access-grid,
    .construction-grid,
    .contribution-grid,
    .facility-cards {
        grid-template-columns: 1fr;
    }

    .production-balance-grid {
        grid-template-columns: 1fr;
    }

    .building-identity {
        grid-template-columns: 82px minmax(0, 1fr);
        gap: .65rem;
    }

    .building-identity > img {
        width: 82px;
        height: 82px;
    }

    .farm-field-grid {
        grid-template-columns: repeat(5, 40px);
        grid-template-rows: repeat(5, 40px);
    }

    .farm-field-grid > img,
    .farm-plot,
    .farm-plot > img {
        width: 40px;
        height: 40px;
    }

    .farm-storage-grid {
        grid-template-columns: 1fr;
    }

    .farming-heading {
        display: block;
    }

    .farming-heading-actions {
        justify-content: flex-start;
        margin-top: .55rem;
    }

    .settlement-unavailable-layout {
        grid-template-columns: 1fr;
    }

    .settlement-unavailable-art {
        width: 100%;
        max-width: 220px;
        margin: 0 auto;
    }

    .dungeon-difficulty-grid,
    .dungeon-results-list {
        grid-template-columns: 1fr;
    }

    .dungeon-map {
        width: calc(100vw - 2rem);
        max-width: 448px;
    }

    .dungeon-target button {
        width: 42px;
        height: 42px;
    }

    .dungeon-target img {
        width: 31px;
        height: 31px;
    }

    .dungeon-combat-actions,
    .dungeon-shrine-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .expedition-heading,
    .expedition-section-heading {
        display: block;
    }

    .expedition-section-heading span {
        display: block;
        margin-top: .2rem;
    }

    .gems-target {
        grid-template-columns: 1fr;
        gap: .55rem;
    }

    .gems-target img {
        width: 60px;
        height: 60px;
    }

    .gems-live-stats {
        gap: .3rem;
    }

    .gems-live-stats div {
        padding: .4rem .25rem;
    }

    .gems-board {
        gap: .2rem;
    }

}

/* Raise the whole transformed target, not just its label, above adjacent sprites. */
.dungeon-target.is-selected { z-index: 3; }
.dungeon-target:hover, .dungeon-target:focus-within { z-index: 10; }
.dungeon-target span { z-index: 1; min-width: 0; width: max-content; max-width: min(13rem, 65vw); white-space: normal; }
.dungeon-target button:disabled { opacity: 1; }
.dungeon-notice-icons { display: inline-flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.dungeon-notice-icons img { width: 36px; height: 36px; object-fit: contain; image-rendering: pixelated; }
.level-up-board { max-width: 680px; margin: 2rem auto; padding: 1.5rem; text-align: center; }
.level-up-board > .character-portrait-link > img { width: 96px; height: 96px; object-fit: contain; image-rendering: pixelated; }
.level-up-number { color: var(--gold); font-size: 2.5rem; margin: 1rem 0; }

.dungeon-target[data-label-align="left"] span { left: 0; transform: none; }
.dungeon-target[data-label-align="right"] span { left: auto; right: 0; transform: none; }

.artifact-collection { margin: 1rem 0; }
.artifact-grid { display: flex; flex-wrap: wrap; gap: .75rem; }
.artifact-card { display: flex; flex-direction: column; align-items: center; gap: .35rem; padding: .6rem; border: 1px solid #444; border-radius: 5px; }
.artifact-card img { width: 64px; height: 64px; image-rendering: pixelated; filter: grayscale(1); opacity: .5; }
.artifact-card.is-found { border-color: var(--gold); }
.artifact-card.is-found img { filter: none; opacity: 1; }
.item-upgrade { margin: .5rem 0; font-size: .8rem; }
.item-upgrade p { margin: .35rem 0; }
.item-upgrade button { max-width: 100%; white-space: normal; }
.meter-satiety > span { background: #c8aa79; }
.food-effects { margin: 12px 0; }
/* Cooking shares Backpack and Crafting components and their typography. */
.well-art { width: 128px; max-width: 100%; height: auto; }
.cooking-water-controls { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; }
.cooked-inventory .food-effects, .cooking-summary .food-effects { font-size: .7rem; line-height: 1.45; }
.cooked-inventory .food-effects h3, .cooking-summary .food-effects h3 { font-size: .85rem; }
.cooking-water-controls .crafting-quantity { grid-template-columns: 3.75rem 6.5rem; }
[data-well] button { min-height: 38px; padding: 7px 10px; border: 1px solid #555; border-radius: 4px; background: #aaa; color: #fff; font: inherit; cursor: pointer; max-width: 100%; }
[data-well] button:disabled { background: #777; color: #ddd; cursor: not-allowed; opacity: .7; }
[data-well] button:focus-visible { outline: 2px solid #f0d296; outline-offset: 2px; }

.cooking-icon { width: 64px; height: 64px; object-fit: contain; image-rendering: pixelated; vertical-align: middle; }
.potion-strength { position: absolute; right: 0; bottom: 0; z-index: 2; padding: .1rem .25rem; border: 1px solid #d6bb72; border-radius: 4px; background: #29251e; color: #fff0c3; font-size: .7rem; font-weight: 700; line-height: 1.2; }

/* Shared effect presentation can accommodate food and future magical effects. */
.food-effects h3 { font-size: .8rem; margin: .5rem 0; }
.active-effects-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .35rem; align-items: start; }
.active-effect { min-width: 0; padding: .3rem; background: #777; border: 1px solid #666; border-radius: 4px; }
.effect-icon { display: block; width: 32px; height: 32px; max-width: 32px; max-height: 32px; object-fit: contain; }
.effect-details { margin-top: .25rem; font-size: .625rem; line-height: 1.3; overflow-wrap: anywhere; }
.effect-details strong { display: block; font-size: inherit; }
.effect-details p { margin: .2rem 0; }
.effect-details [data-countdown] { white-space: normal; }
.effects-icons-only .active-effects-grid { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .4rem; }
.effects-icons-only .active-effect { position: relative; padding: 0; border: 0; background: none; }
.effect-icon-trigger { display: block; width: 32px; height: 32px; padding: 0; border: 0; background: transparent; cursor: help; }
.effect-icon-trigger:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.effects-icons-only .effect-details { position: absolute; z-index: 40; top: 100%; left: 0; width: min(210px, 65vw); padding: .5rem; margin: 0; background: #303030; border: 1px solid #c8aa79; border-radius: 4px; color: #fff; box-shadow: 0 3px 10px #0008; visibility: hidden; opacity: 0; }
.effects-icons-only .active-effect:hover .effect-details, .effects-icons-only .active-effect:focus-within .effect-details { visibility: visible; opacity: 1; }

/* Supplied LPC alchemy scenes preserve their native pixel art. */
.alchemy-building-actions { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.alchemy-resource-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 1rem; }
.alchemy-resource-grid form + form { margin-top: .6rem; }
.alchemy-table-visual { margin: 1rem 0; padding: 2rem 1rem; text-align: center; border: 1px solid #73543b; border-radius: 12px; background: radial-gradient(ellipse at 50% 80%, #59432c, #211b18 75%); }
.alchemy-scene { display: block; width: min(100%, 640px); height: 320px; object-fit: contain; image-rendering: pixelated; margin: 0 auto 1rem; }
.building-action-link .alchemy-tier-icon { width: 80px; height: 64px; object-fit: contain; image-rendering: pixelated; }
.facility-card[data-upgrade="alchemy-table"] > img { width: 96px; height: 80px; object-fit: contain; image-rendering: pixelated; }
.alchemy-table-visual[data-alchemy-tier="2"] { border-color: #aaa9a4; }
.alchemy-table-visual[data-alchemy-tier="3"] { border-color: #d4b35a; }
.alchemy-table-visual figcaption { color: #f5e1bb; }

.character-portrait-link {
    display: inline-block;
    flex-shrink: 0;
    line-height: 0;
    border-radius: 4px;
}
.character-portrait-link:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 4px;
}

.leaderboard-summary > .character-portrait-link,
.gems-character-panel > .character-portrait-link {
    display: block;
    width: fit-content;
    margin-inline: auto;
}

.profile-panel-button { display: inline-block; text-decoration: none; }


.stat-purchase-history { max-height: 20rem; overflow-y: auto; padding-left: 3.5rem; scrollbar-gutter: stable; }
.stat-purchase-history li { min-height: 2rem; line-height: 1.5; padding-block: .25rem; box-sizing: border-box; }
.world-map-cell.has-characters::before,
.world-map-legend i.has-characters::before {
    content: ''; position: absolute; width: 35%; height: 35%; min-width: 3px; min-height: 3px;
    top: 5%; right: 5%; border-radius: 50%; background: #45fff0; box-shadow: 0 0 3px #45fff0;
    z-index: 1; pointer-events: none; animation: crystal-tracker-pulse 1.6s ease-in-out infinite;
}
.world-map-legend i.has-characters { position: relative; }
@keyframes crystal-tracker-pulse { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) {
    .world-map-cell.has-characters::before, .world-map-legend i.has-characters::before { animation: none; }
}

/* Maritime ship artwork is large enough to distinguish the personal tiers. */
.facility-card[data-ship-tier] { grid-template-columns: minmax(0, 1fr); }
.facility-card[data-ship-tier] > img { width: 100%; height: 144px; object-fit: contain; image-rendering: pixelated; }
.facility-card[data-upgrade="drydock"] > img { width: 80px; height: 80px; }

.meter-movement { margin: .65rem 0; }
.meter-movement > span { background: linear-gradient(#bceaff, #79c9ed); }
.meter-movement > b { color: #122f42; text-shadow: 0 1px 1px #e6f7ff; }

/* Compact administrative navigation, shared by game and account screens. */
a.admin-link {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 24px;
    margin: 2px 0;
    padding: 3px 8px;
    border: 1px solid #756b4e;
    border-radius: 4px;
    background: #24251f;
    color: #e5dbb4;
    font: 11px/1.4 system-ui, sans-serif;
    text-decoration: none;
}
a.admin-link:hover { background: #37392d; border-color: #b5a46c; }
a.admin-link:focus-visible { outline: 2px solid #e5dbb4; outline-offset: 3px; }

.farm-compost-panel {
    margin-top: .75rem;
    padding: .75rem;
    border: 1px solid #817865;
    border-radius: .4rem;
    background: var(--region-building-background);
}
.farm-compost-panel button:not(.compost-box) {
    color: #000;
    background-color: #dac9a7;
}
.compost-summary {
    display: grid;
    grid-template-columns: fit-content(32%) minmax(0, 1fr);
    align-items: center;
    gap: .75rem;
    margin-bottom: .6rem;
}
.compost-details { font-size: .875rem; line-height: 1.4; }
.compost-details p { margin: 0; font-size: inherit; }
.compost-details p + p { margin-top: .25rem; }
.compost-box {position:relative; display:inline-block; padding:0; border:0; background:transparent}
.compost-box img {display:block; max-width:100%; image-rendering:pixelated}
.compost-box i {position:absolute; bottom:0; width:6px}
.compost-input {left:0; background:#53a950}
.compost-output {right:0; background:#cdb58a}
.farm-plot img.farm-compost-mark {position:absolute; left:3px; top:3px; width:16px; height:16px}
.fertilizer-level {width:76px; height:8px; accent-color:#53a950}

