html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: absolute;
    display: block;
    width: 8rem;
    height: 8rem;
    inset: 20vh 0 auto 0;
    margin: 0 auto 0 auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}body { background-color: #121210; color: #f2f0e5; font-family: "Segoe UI", sans-serif; }
.desktop-shell { margin: 24px; }
html:has(dialog[open]) { overflow: hidden; }
.desktop-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; font-size: 27px; }
.desktop-shell select { background: #1b1b18; color: inherit; border: 1px solid #6d654f; }
.desktop-tabs { display: flex; flex-wrap: wrap; gap: 2px; margin-bottom: 12px; }
.desktop-tabs a, .scene-action { display: inline-block; padding: 7px 12px; color: #f2f0e5; background: #1b1b18; border: 1px solid #6d654f; text-decoration: none; }
.desktop-tabs a.active, .desktop-tabs a:hover, .scene-action:hover { background: #163c43; color: #a9f1df; }
.desktop-scene { position: relative; width: 100%; aspect-ratio: 16 / 9;  }
.scene-action { position: absolute; top: 16px; left: 16px; }
.desktop-development { padding: 24px; font-size: 16px; } .desktop-development h1 { font-size: 24px; margin-bottom: 20px; }
.character-audit { margin: 14px 0; padding-top: 10px; }
.character-audit h2 { margin: 0; color: wheat; }
.character-audit-table { overflow: auto; max-height: 52vh; }
.character-audit table { width: 100%; border-collapse: collapse; }
.character-audit :is(th,td) { padding: 8px; text-align: left; border-bottom: 1px solid #5a4d31; }
.character-audit thead { background: #24231e; color: wheat; }
.character-audit tbody tr:nth-child(odd) { background: #191916; }
.character-audit tbody tr:nth-child(even) { background: #20201c; }
.character-audit details { margin-top: 10px; }
.equipment-manual-target { margin-top: 12px; padding: 10px; }
.equipment-manual-target form { display: grid; gap: 8px; margin-top: 9px; }
.equipment-manual-fields { display: grid; gap: 6px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.equipment-manual-fields label { display: grid; gap: 3px; }
.equipment-manual-fields input { width: 100%; }
.equipment-manual-target fieldset label { display: inline-flex; gap: 4px; margin: 3px 10px 3px 0; }
.equipment-manual-target form > button { justify-self: start; }
.damage-verification { padding: 20px; }
.damage-verification h1 { font-size: 24px; }
.damage-inputs, .damage-cards { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 12px; }
.damage-inputs label { display: grid; gap: 4px; }
.damage-inputs input { background: #1b1b18; color: inherit; border: 1px solid #6d654f; }
.damage-cards article { flex: 1 1 160px; background: #1b1b18; padding: 12px; }
.damage-cards h2 { font-size: 18px; color: #60d7c6; }
.scene-menu { position: absolute; top: 1.4%; right: 1%; display: flex; flex-wrap: wrap; gap: 3px; } .scene-menu .scene-action { position: static; font-size: 12px; }
.costume-simulation { display: grid; grid-template-columns: minmax(240px, 310px) minmax(0, 1fr); gap: 14px; margin: 12px 0; }
.costume-products, .costume-results { background: #1b1b18; border: 1px solid #726141; padding: 12px; }
.costume-products { max-height: 70vh; overflow-y: auto; }
.costume-products label { display: block; padding: 3px 0; }
.costume-products h3, .costume-results h3 { color: #f3c477; font-size: 18px; margin-top: 12px; }
.costume-products h4, .costume-results h4 { font-size: 16px; margin-top: 10px; }
.costume-results { overflow-x: auto; }
.costume-results th, .costume-results td { padding: 4px 8px; border-bottom: 1px solid #726141; }
@media (max-width: 760px) { .costume-simulation { grid-template-columns: 1fr; } }
.farm-support-choice { display: block; }
.scene-equipped, .scene-inventory { position: absolute; right: 1%; width: 10.45%; background: #161411ed; border: 2px ridge #726141; color: #f2f0e5; padding: 4px; }
.scene-equipped { top: 20%; }
.scene-inventory { top: 56%; }
.scene-equipped h2, .scene-inventory h2 { font-size: clamp(8px, .75vw, 12px); line-height: 1.15; text-align: center; padding: 2px; margin: 0; color: #f3c477; }
[data-scene-panel] > h2 { cursor: grab; touch-action: none; user-select: none; }
[data-scene-panel] > h2:active { cursor: grabbing; }
.scene-equipped .scene-equipment-grid { position: relative; aspect-ratio: 160 / 162; }
.scene-equipped .scene-equipment-grid button { position: absolute; min-height: 0; aspect-ratio: auto; border-radius: 5px; }
.scene-costumes .scene-equipment-grid { aspect-ratio: 132 / 234; }
.scene-costume-silhouette { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.scene-supports { display: flex; gap: 2px; margin-top: 2px; border-top: 1px solid #5a4d31; padding-top: 2px; }
.scene-supports button { width: 23%; display: grid; place-items: center; }
.scene-supports .scene-optimize { flex: 1; width: auto; aspect-ratio: auto; white-space: normal; line-height: 1.1; }
.scene-supports button span { color: #c7a152; }
.scene-support-picker { width: 100%; }
.scene-gear-commands { display: flex; gap: 3px; margin-top: 3px; }
.scene-gear-commands button { width: 23%; }
.scene-gear-commands img { width: 100%; object-fit: contain; }
.scene-utility-panel {
    position: absolute; z-index: 3; left: 1%; top: 12%; width: min(410px, 48%); max-height: 70%; overflow: auto;
}
.scene-character-dialog { width: min(650px, 94vw); max-height: 84dvh; overflow-y: auto; color: wheat; }
.scene-character-dialog::backdrop { background: #0009; }
.scene-character-dialog > .farm-window-title { position: sticky; top: 0; z-index: 1; }
.scene-character-dialog > button { margin-top: 8px; }
.scene-items-dialog { width: min(950px, 94vw); }
.scene-skill-bar { display: flex; align-items: center; justify-content: center; gap: 3px; }
.scene-skill-bar .scene-skill { width: clamp(24px, 3.2vw, 42px); aspect-ratio: 1; padding: 2px; border-radius: 6px; }
.scene-skill img { display: block; width: 100%; }
.scene-skill[aria-pressed="true"] img { opacity: .48; }
.scene-buff-bar { position: absolute; left: 12px; top: 48px; display: flex; gap: 6px; }
.scene-buff-bar img { width: 28px; height: 28px; object-fit: contain; image-rendering: pixelated; }
.scene-costumes { top: 29.09%; right: 11.48%; width: 7.95%; }
.scene-equipped button, .scene-inventory-item { padding: 2px; border: 1px solid #605641; background: #201a12; color: inherit; text-overflow: ellipsis; overflow: hidden; white-space: nowrap; font-size: 10px; }
.scene-equipped button:disabled { color: #a29a89; background: #151413; }
.scene-inventory-grid { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); grid-template-rows: repeat(9,1fr); aspect-ratio: 5 / 9; gap: 1px; }
.scene-inventory-cell { border: 1px solid #5d5241; border-radius: 4px; background: #151413; }
.scene-inventory-item { z-index: 1; }
.scene-inventory-item.inventory-selected { outline: 1px solid #ffd84a; box-shadow: 0 0 5px #ffd84a; }
.equipment-icon { display: block; height: 100%; width: 100%; object-fit: contain; } .scene-equipped button { min-height: 24px; aspect-ratio: 1; } .scene-inventory-item { min-height: 0; }
.scene-character { position: absolute; left: 16.4773%; top: 47.4747%; width: 19.8864%; height: 40.404%; }
.scene-character-name { position: absolute; z-index: 1; left: 7.1429%; top: -10.25%; color: #ffd700; font-size: clamp(.57rem, .73vw, .88rem); text-shadow: 0 2px 2px #000; pointer-events: none; }
.scene-target span { position: static; width: 100%; text-align: center; color: #f3c477; text-shadow: 0 2px 2px #000; }
.scene-character-name span { color: #00bfff; }
.scene-character img, .scene-target img { min-height: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom center; }
.scene-target { position: absolute; bottom: 11.6%; left: 60.8%; transform: translateX(-50%); width: 45%; height: 47%; display: flex; flex-direction: column; align-items: center; text-decoration: none; }
.target-guide { padding: 10px 0; }
.target-guide-stats { display: flex; flex-wrap: wrap; gap: 12px; margin: 8px 0; }
.target-guide-map { display: block; max-width: min(100%, 520px); }
.loot-groups { display: grid; grid-template-columns: repeat(auto-fit,minmax(210px,1fr)); gap: 8px; }
.loot-groups section { border: 1px solid #726141; background: #161411; padding: 8px; }
.loot-groups h4 { color: #f3c477; font-size: 15px; }
.loot-row { display: flex; align-items: center; gap: 6px; min-height: 26px; }
.loot-row img { width: 26px; height: 26px; object-fit: contain; }
.farm-window, .scene-equipped, .scene-inventory { background: linear-gradient(#0e0e0d38,#0e0e0d38), url("../assets/wiki/farm-stone-texture.png") repeat; background-size: auto,160px 100px; border: 1px solid #726141; }
.scene-equipped, .scene-inventory { border: 2px ridge #9d8e75; border-radius: 6px; box-shadow: inset 0 0 0 2px #221d15, 0 2px 4px #0009; }
.farm-window { gap: 0 12px; padding: 0 10px 10px; }
.farm-window-title, .scene-equipped h2, .scene-inventory h2 { color: wheat; background: linear-gradient(#7d4627,#371e13 48%,#6f3418); border: 1px solid #8d7763; }
.farm-window-title { grid-column: 1 / -1; margin: 0 -10px 10px; padding: 2px 8px; font-size: 13px; }
.costume-simulation .costume-products, .costume-simulation .costume-results { background: transparent; }
.character-stats-sheet { width: min(100%, 365px); margin-bottom: 12px; }
.character-stat-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 8px; }
.character-stat-tiles dt { font-size: 12px; font-weight: normal; color: wheat; }
.character-stat-tiles dd { margin: 0; padding: 2px 5px; text-align: right; border: 1px solid #5a4d31; background: #080807; }
.character-extra-stats summary { color: wheat; padding: 3px 5px; border-bottom: 1px solid #5a4d31; }
.equipment-advice .equipment-icon { width: 38px; height: 48px; }
.equipment-opportunity { border: 1px solid #5a4d31; background: #171512; padding: 8px 12px; margin: 6px 0; }
.equipment-opportunity p { margin: 2px 0; }
.combat-dashboard { display: grid; grid-template-columns: minmax(240px, .85fr) minmax(0, 1.15fr); gap: 8px; margin-top: 10px; align-items: start; }
.farm-dashboard { grid-template-columns: minmax(0, .96fr) minmax(0, 1fr) minmax(0, .54fr) minmax(0, .95fr) minmax(0, 1fr); }
.combat-column { padding: 8px 9px 12px; min-width: 0; color: wheat; }
.combat-column > .farm-window-title, .combat-column h3.farm-window-title { margin: 0 0 8px; text-align: center; font-size: 13px; font-weight: normal; }
.combat-column h3.farm-window-title { margin-top: 9px; }
.combat-column label { display: block; }
.combat-column :is(input, select, textarea) { max-width: 100%; }
.combat-column > details { margin: 6px 0; }
.combat-column details > summary { color: wheat; border: 1px solid #5a4d31; padding: 3px 5px; }
.farm-dashboard .combat-column { height: clamp(540px, 77dvh, 960px); overflow: auto; scrollbar-color: #675e4c #24211a; }
.combat-column .hit-results { background: #131210; margin: 8px 0; padding: 5px; border: 1px solid #5a4d31; }
.combat-column .hit-results h2 { background: linear-gradient(#7d4627,#371e13 48%,#6f3418); color: wheat; text-align: center; margin: 0 0 7px; font-size: 14px; padding: 3px; }
.combat-column .hit-results table { width: 100%; font-size: 11px; }
.combat-column .hit-results :is(th, td) { padding: 3px 4px; }
.farm-character-column p, .farm-costume-column p, .farm-costume-column ul { font-size: 13px; margin: 0 0 6px; }
.farm-dashboard-action { display: block; border: 1px solid #5a4d31; padding: 4px; text-align: center; color: wheat; }
.farm-equipment-slots, .farm-costume-slots { display: grid; gap: 3px; max-width: 265px; margin: 4px auto 12px; padding: 6px; border: 2px ridge #7b6a4e; background: #383227; }
.farm-equipment-slots { grid-template: repeat(4,1fr) / repeat(4,minmax(0,1fr)); aspect-ratio: 1; }
.farm-costume-slots { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.farm-equipment-slots button, .farm-costume-gear-slot { display: grid; place-items: center; min-height: 29px; border: 1px solid #88714d; border-radius: 6px; padding: 2px; background: #14130f; }
@media (max-width: 1100px) {
    .farm-dashboard { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .farm-dashboard .combat-column { height: auto; max-height: 73dvh; }
}
@media (max-width: 780px) {
    .farm-dashboard, .combat-dashboard { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 530px) {
    .farm-dashboard, .combat-dashboard { grid-template-columns: minmax(0, 1fr); }
    .farm-dashboard .combat-column { max-height: none; }
}
.yin-yang-slots { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 8px; margin: 8px 0; }
.yin-yang-slots fieldset { border: 1px solid #5a4d31; padding: 5px 9px; }
.yin-yang-slots legend { float: none; width: auto; color: wheat; font-size: 14px; }
.yin-yang-estimate { color: #ffd800; }
.costume-products .costume-product { display: flex; align-items: center; gap: 5px; min-height: 29px; }
.costume-product-icon { width: 24px; height: 26px; object-fit: contain; vertical-align: middle; }
.costume-added { color: #ffd800; }
.costume-removed { color: #ff9f43; }
.costume-results td.costume-highlight { color: #fff; background: #1c524f; box-shadow: inset 0 0 0 1px #4abeb5; }
.costume-dialog { padding: 0; color: wheat; background: #131310; border: 1px solid #726141; width: min(1160px, calc(100vw - 16px)); height: min(980px, calc(100dvh - 16px)); max-width: none; max-height: none; }
.costume-dialog-wide { width: calc(100vw - 16px); height: calc(100dvh - 16px); }
.costume-dialog::backdrop { background: #0009; }
.costume-dialog .costume-simulation { margin: 0; border: 0; height: 100%; padding: 0 16px 14px; grid-template-columns: minmax(240px, 288px) minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr) auto; }
.costume-titlebar { margin: 0 -16px 16px; display: flex; align-items: center; gap: 6px; min-height: 24px; }
.costume-titlebar img { width: 16px; height: 16px; object-fit: contain; }
.costume-titlebar span { flex-grow: 1; }
.costume-titlebar button { background: transparent; color: wheat; border: 0; min-width: 25px; padding: 0; }
.costume-dialog .costume-results { margin-top: 27px; }
.costume-dialog .costume-products, .costume-dialog .costume-results { padding: 0; border: 0; scrollbar-color: #675e4c #24211a; }
.costume-dialog .costume-products { display: flex; flex-direction: column; max-height: none; overflow: hidden; }
.costume-dialog .costume-results, .costume-product-list { overflow: auto; min-height: 0; scrollbar-color: #675e4c #24211a; }
.costume-products > button { color: #ffda00; margin: 6px 0 4px; min-height: 34px; }
.costume-products > label select { width: min(190px, 100%); min-height: 27px; }
.costume-products > label:nth-of-type(2) select { width: min(240px, 100%); }
.costume-search-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 10px 8px 4px 0; }
.costume-search-heading :is(h3, h4) { margin: 0; }
.costume-products .costume-search { position: relative; padding: 0; width: 124px; color: wheat; }
.costume-search input { width: 100%; padding-left: 24px; font-size: 13px; }
.costume-search::before { content: ""; position: absolute; top: 7px; left: 8px; width: 9px; height: 9px; border: 1px solid currentColor; border-radius: 50%; pointer-events: none; }
.costume-search::after { content: ""; position: absolute; top: 17px; left: 6px; width: 6px; border-top: 1px solid currentColor; transform: rotate(-45deg); pointer-events: none; }
.costume-browser { position: relative; display: grid; grid-template-columns: minmax(220px, 310px) minmax(0, 1fr); gap: 12px; }
.costume-catalog { padding: 4px 6px; background: #131310; max-height: 72vh; overflow: auto; scrollbar-color: #675e4c #24211a; }
.costume-catalog .costume-search { position: relative; display: block; color: wheat; max-width: 210px; }
.costume-catalog > p { margin: 8px 0 6px; font-size: 12px; }
.costume-catalog-card { display: block; width: 100%; padding: 6px 10px; margin-bottom: 5px; text-align: left; border-radius: 4px; background: linear-gradient(#402918,#171512); }
.costume-catalog-card[aria-pressed="true"] { border-color: #e4b73d; }
.costume-catalog-card > span { display: flex; align-items: center; gap: 8px; }
.costume-catalog-card img { width: 36px; height: 45px; }
.costume-catalog-card small { display: block; margin: 3px 0 0; }
.costume-set-details { padding: 6px 8px; color: wheat; }
.costume-set-details > h2 { padding-right: 38px; color: #ffd800; font-size: 23px; font-weight: normal; }
.costume-set-details > p { margin: 0 0 6px; font-size: 13px; }
.costume-detail-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.costume-detail-part h3, .costume-tier h3 { margin: 4px 0; font-size: 16px; font-weight: normal; }
.costume-detail-part ul, .costume-tier ul { margin: 0 0 8px; padding: 0; list-style: none; }
.costume-detail-part li { display: flex; align-items: center; min-height: 38px; gap: 8px; }
.costume-detail-part img { width: 32px; height: 36px; }
.costume-detail-part .missing-part { color: #f0a661; }
.costume-detail-part .equipped-part, .costume-tier.active-tier h3 { color: #8ced9f; }
.costume-tier { background: #131310; border: 1px solid #5a4d31; margin-bottom: 8px; padding: 7px 11px; font-size: 13px; }
.costume-tier h3 { color: #ffd800; }
.costume-tier.active-tier { border-color: #63a773; }
@media (max-width: 730px) {
    .costume-browser, .costume-detail-columns { grid-template-columns: minmax(0, 1fr); }
    .costume-catalog { max-height: 33vh; }
}
.costume-products > h2 { color: #ffda00; font-size: 21px; font-weight: 400; margin: 2px 0 4px; }
.costume-products > p { font-size: 12px; line-height: 1.3; margin: 0 0 8px; }
.costume-products input[type="checkbox"] { accent-color: #a8864a; }
.costume-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 12px; padding: 10px 5px 2px; }
.costume-actions button { padding: 7px 18px; }
.costume-preview-grid { display: grid; grid-template-columns: minmax(0, .88fr) minmax(0, 1fr); gap: 12px; margin-bottom: 16px; }
.costume-set-card, .costume-change-list li { background: #131310; border: 1px solid #5a4d31; }
.costume-set-card { min-height: 208px; padding: 8px 14px; }
.costume-set-card p { margin: 12px 0 6px; font-size: 18px; }
.costume-set-card ul, .costume-change-list { margin: 0; padding: 0; list-style: none; }
.costume-set-card .costume-many-pieces { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 8px; }
.costume-set-card li, .costume-change-list li { display: flex; align-items: center; gap: 8px; min-height: 32px; }
.costume-change-list li { margin-top: 2px; padding: 2px 8px; }
.costume-simulation details > summary { padding: 1px 8px; text-align: center; background: linear-gradient(#7d4627,#371e13 48%,#6f3418); border: 1px solid #8d7763; }
.costume-source-table, .costume-calculation table { width: 100%; margin-top: 6px; font-size: 13px; }
.costume-source-table thead, .costume-source-table tfoot { background: linear-gradient(#412b1b,#1d1811); color: #ffd800; }
.costume-source-table :is(th, td):not(:first-child) { width: 85px; text-align: right; }
.costume-source-table tbody th { font-weight: normal; }
.costume-calculation thead { color: #ffd800; }
.costume-calculation tbody th { font-weight: normal; }
.costume-calculation :is(th, td) { padding: 3px 5px; border-bottom: none; line-height: 1.27; }
.costume-calculation tbody td:last-child { color: #82dd9a; }
.costume-calculation tbody tr:nth-child(odd) { background: #1716128a; }
.costume-calculation .costume-active-bonus { color: #ffd800; outline: 1px solid #a98b27; outline-offset: -1px; }
.costume-calculation .costume-active-bonus td:last-child { color: inherit; }
.costume-calculation { overflow-x: auto; margin-bottom: 12px; }
.costume-status-line { height: 46px; display: flex; align-items: center; gap: 0 12px; }
.costume-status-line h3, .costume-status-line p { margin: 0; }
.costume-status-line h3 { flex: 0 0 auto; color: wheat; font-weight: 400; }
.costume-status-line p { min-width: 0; max-height: 100%; overflow-y: auto; }
.costume-status-line .costume-no-improvement, .costume-status-line .costume-gain {
    color: #ffdd00; background: #2c2014; border: 1px solid #8f6d21; padding: 2px 6px;
}
.costume-status-line .costume-no-improvement { font-size: 16px; font-weight: 600; }
@media (max-width: 840px) { .costume-preview-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 680px) {
    .costume-dialog .costume-simulation { height: auto; min-height: 100%; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; }
    .costume-dialog .costume-products { max-height: 40vh; }
    .costume-status-line { height: 70px; align-content: center; align-items: start; flex-direction: column; gap: 3px; }
    .costume-status-line h3 { flex-shrink: 0; }
}
.desktop-shell button, .desktop-shell input:not([type=checkbox]), .desktop-shell textarea { color: wheat; background: #171613; border: 1px solid #726141; }
.desktop-shell button:not(:disabled):hover { color: #fff4cc; border-color: #f3c477; }
.desktop-shell :is(button,select,input,textarea,a):focus-visible { outline: 2px solid #f3c477; outline-offset: 2px; }
.player-combat details { margin: 8px 0; } .player-combat label { display: inline-flex; align-items: center; gap: 6px; margin: 4px; } .player-combat input[type=number] { width: 90px; }
.scene-damage {
    position: absolute; inset: auto 0 0; display: grid; grid-template-columns: 37% auto 1fr;
    align-items: center; gap: 8px; padding: 5px; color: wheat; background: #101012ed; border-top: 2px solid #84724b;
}
.scene-hit-ranges { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 3px; }
.scene-range { display: grid; gap: 3px; min-width: 0; padding: 4px; font-size: clamp(.51rem, .82vw, .74rem); border: 1px solid currentColor; border-radius: 3px; }
.scene-range strong { color: wheat; }
.scene-range.hit-kind-0 { color: #a4bfc4; }
.scene-range.hit-kind-1 { color: #ffd560; }
.scene-range.hit-kind-2 { color: #8bc9f3; }
.scene-range.hit-kind-3 { color: #ffab69; }
.scene-hit-average { display: grid; margin: 0; font-size: .72rem; }
.scene-damage :is(output,[role="status"]) { position: absolute; bottom: 100%; left: 45%; max-width: 48%; margin: 0; padding: 3px 7px; background: #171613e8; font-weight: bold; }
.scene-damage:has(output) [role="status"] { bottom: calc(100% + 1.7em); }
.scene-hit-outgoing { color: gold; }
.scene-hit-incoming { color: #ff9d85; }
@media (max-width: 850px) {
    .scene-damage { grid-template-columns: 1fr; gap: 3px; }
    .scene-hit-average { display: none; }
}
.scene-character-model { position: absolute; left: -4.2857%; top: -12.5%; width: 125.7143%; height: 125%; }
.scene-character-model > canvas { width: 100%; height: 100%; visibility: hidden; touch-action: none; cursor: grab; }
.scene-character-model > canvas.model-ready { visibility: visible; }
.scene-character-model > .scene-character-sprites { position: absolute; inset: 0; visibility: visible; object-fit: contain; object-position: bottom center; }
.scene-character-model > img { position: absolute; inset: 0; }
.scene-character-model > img[hidden] { display: none; }
.scene-target > a { text-align: center; color: #f3c477; text-shadow: 0 2px 2px #000; }
.scene-target > canvas { position: absolute; inset: 20px 0 0; width: 100%; height: calc(100% - 20px); visibility: hidden; touch-action: none; cursor: grab; }
.scene-target > canvas.model-ready { visibility: visible; }
.scene-target > img[hidden] { display: none; }
.scene-target > canvas { transform-origin: bottom center; }
.scene-actor { position: absolute; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; }
.scene-actor > a { text-align: center; color: #f3c477; text-shadow: 0 2px 2px #000; text-decoration: none; }
.scene-target > a {
    position: absolute; top: calc((1 - var(--actor-scale, 1)) * 94% - .15em); z-index: 2;
    color: #ffd700; font-size: clamp(.58rem, .8vw, .78rem);
}
.scene-forest-metin::after {
    content: ""; position: absolute; width: 50%; height: 100%; bottom: 0; left: 25%;
    pointer-events: none; z-index: 1; transform-origin: center bottom; scale: var(--actor-scale, 1);
    mask-image: radial-gradient(ellipse closest-side, #000 82%, transparent);
    background:
        radial-gradient(ellipse 25% 14% at 15% 38%, #86dbd486, transparent),
        radial-gradient(ellipse 21% 16% at 88% 53%, #85ded676, transparent),
        radial-gradient(ellipse 22% 12% at 19% 72%, #4ca79658, transparent),
        radial-gradient(ellipse 26% 12% at 80% 88%, #52cbd94d, transparent);
}
.scene-visual-skill {
    position: absolute; left: 30%; top: 40%; width: 40%; height: 34%; z-index: 3; pointer-events: none;
    animation: scene-skill-preview 750ms ease-out both;
}
.scene-visual-skill-1, .scene-visual-skill-4 { border: 5px solid #bdf8fd; border-radius: 50%; }
.scene-visual-skill-4 { top: 65%; height: 13%; border-color: #f5a429; }
.scene-visual-skill:is(.scene-visual-skill-2, .scene-visual-skill-3)::before,
.scene-visual-skill span {
    content: ""; position: absolute; top: 50%; width: 100%; height: 6px;
    transform: rotate(-48deg); border-radius: 60%; background: #fbedbd;
}
.scene-visual-skill span:first-child { left: -24%; }
.scene-visual-skill span:last-child { left: 24%; }
@keyframes scene-skill-preview { from { opacity: 1; scale: .35; } to { opacity: 0; scale: 1.3; } }
@media (prefers-reduced-motion: reduce) { .scene-visual-skill { animation-duration: 1ms; } }
.scene-actor > canvas { position: absolute; inset: 20px 0 0; width: 100%; height: calc(100% - 20px); visibility: hidden; touch-action: none; cursor: grab; transform-origin: bottom center; }
.scene-actor > canvas.model-ready { visibility: visible; }
.scene-actor > img { min-height: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom center; }
.scene-actor > img[hidden] { display: none; }
.scene-pet { left: 39.4%; bottom: 12.1%; width: 16%; height: 15%; }
.scene-growth-pet { left: 14%; top: 57%; width: 28%; height: 39%; }
.scene-growth-pet > a { color: #7cdd87; }
.scene-mount { left: 48.3%; bottom: 14.1%; width: 21%; height: 24%; }
.consumable-tabs { display: flex; gap: .25rem; flex-wrap: wrap; }
.consumable-tabs button { padding: .3rem .45rem; }
.consumable-tabs button[aria-pressed="true"] { border-color: #c7a84d; color: #fff080; }
.consumable-hint { font-size: .78rem; margin: .4rem 0; }
.consumable-group { margin: .55rem 0; }
.consumable-group h4 { font-size: .87rem; margin: 0 0 .25rem; color: #e8cf91; }
.consumable-icons { display: flex; flex-wrap: wrap; gap: 4px; }
.consumable-icons button { display: grid; place-items: center; width: 37px; height: 37px; padding: 2px; background: #151310; }
.consumable-icons button[aria-pressed="true"] { border-color: #d6b34a; background: #392c14; box-shadow: inset 0 0 5px #a38330; }
.consumable-icons img { width: 31px; height: 31px; object-fit: contain; }
.farm-equipment-slots, .farm-costume-slots {
    display: block; position: relative; padding: 0; background-size: 100% 100%;
    image-rendering: pixelated;
}
.farm-equipment-slots { max-width: 308px; aspect-ratio: 328 / 377; background-image: url("../assets/wiki/farm-gear-frame.png"); }
.farm-costume-slots { max-width: 197px; aspect-ratio: 197 / 280; background-image: url("../assets/wiki/farm-costume-frame.png"); }
.farm-equipment-slots button, .farm-costume-slots .farm-costume-gear-slot {
    position: absolute; min-height: 0; aspect-ratio: auto; border-color: transparent;
    border-radius: 0; background: transparent; overflow: hidden;
}
.farm-equipment-slots button:hover, .farm-costume-slots .farm-costume-gear-slot:hover { border-color: #c2a048; background: #51412b60; }
.farm-costume-choose select { width: 100%; }
.farm-equipment-slots img, .farm-costume-slots img { max-width: 100%; max-height: 100%; object-fit: contain; }
.farm-equipment-slots .farm-yin-shortcut img { width: 95%; height: 95%; transform: scale(1.1); image-rendering: auto; }
.farm-page-heading { font-size: 1.25rem; margin: 2px 0 5px; color: #f0d599; }
.farm-page-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 12px; color: wheat; }
.farm-page-tools h2 { font-size: 1rem; margin: 0; }
.farm-page-tools a { color: wheat; }
.farm-page-tools input[type="file"] { max-width: min(100%, 260px); }
.farm-page-header:has(.farm-page-tools) {
    position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 0 14px; margin-bottom: 8px;
}
.farm-page-header:has(.farm-page-tools) .farm-page-heading {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); margin: 0;
}
.farm-page-header:has(.farm-page-tools) .farm-toolbar { margin: 2px 0; }
.farm-page-header > :is(.farm-toolbar-status, .farm-toolbar-confirm) { order: 1; flex-basis: 100%; }
.farm-page-header .scenario-commands { display: flex; align-items: center; gap: 6px; }
.farm-page-header .scenario-commands label { position: relative; cursor: pointer; }
.farm-page-header .scenario-commands input[type="file"] {
    width: 1px; height: 1px; padding: 0; border: 0; position: absolute; clip-path: inset(50%);
}
.farm-page-header .scenario-commands:focus-within label { text-decoration: underline; }
.farm-character-summary-actions { display: flex; gap: 4px; margin: 6px 0; }
.farm-character-summary-actions button { flex: 1; padding: 3px; font-size: .72rem; }
.farm-character-summary-actions button[aria-pressed="true"] { border-color: #c2a048; color: #ffd560; }
.farm-character-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px; margin: 4px 0 7px; }
.farm-character-summary div { display: flex; align-items: center; justify-content: space-between; gap: 4px; padding: 4px; background: #171510; font-size: .71rem; }
.farm-character-summary dd { margin: 0; white-space: nowrap; color: wheat; }
.farm-character-speed { margin: 5px 0 0; font-size: .73rem; color: wheat; }
.farm-level-value { width: 100%; background: transparent; padding: 0 4px; border-color: transparent; }
.farm-level-value:hover, .farm-level-value:focus-visible { border-color: #98794a; }
.farm-level-dialog { width: min(390px, 90vw); color: wheat; }
.farm-level-dialog::backdrop { background: #0009; }
.farm-level-dialog .character-progress-form { display: grid; gap: 7px; padding: 11px; }
.farm-level-dialog label { display: flex; align-items: center; justify-content: space-between; gap: 7px; }
.farm-level-dialog input[type="number"] { max-width: 7em; }
.character-progress-actions { display: inline-flex; gap: 6px; }
.farm-target-preview { margin: 0 0 8px; text-align: center; }
.farm-target-preview img { display: block; width: 100%; height: 105px; object-fit: contain; image-rendering: pixelated; }
.farm-target-preview figcaption { font-size: .85rem; }
.farm-dashboard .combat-column { height: clamp(540px, calc(100dvh - 220px), 1020px); }
@media (max-width: 1120px) { .farm-dashboard .combat-column { height: auto; } }
.farm-target-open { width: 100%; margin: 4px 0; }
.target-selection-fields { margin: 4px 0; }
.target-selection-fields select, .target-selection-fields input { width: 100%; }
.farm-hit-stage { display: grid; place-items: center; height: 80px; border: 1px solid #5a4d31; background: #090806; margin-bottom: 8px; }
.farm-hit-stage output { color: #ffcc6d; font-size: 1.2em; animation: farm-hit-rise 1s ease-out both; }
.farm-hit-subtitle { margin: 4px 0 7px; text-align: center; color: wheat; font-size: .73rem; }
.farm-hit-results .hit-kind-0 th { color: wheat; }
.farm-hit-results .hit-kind-1 th { color: #ffd560; }
.farm-hit-results .hit-kind-2 th { color: #8bc9f3; }
.farm-hit-results .hit-kind-3 th { color: #ffab69; }
.farm-hit-odds-label { color: tan; margin: 6px 0 2px; font-size: .72rem; }
.farm-hit-odds { display: flex; height: 7px; border: 1px solid #67583c; background: #090806; }
.farm-hit-odds .hit-kind-0 { background: wheat; }
.farm-hit-odds .hit-kind-1 { background: #ffd560; }
.farm-hit-odds .hit-kind-2 { background: #8bc9f3; }
.farm-hit-odds .hit-kind-3 { background: #ffab69; }
.farm-hit-odds .hit-kind-block { background: slategray; }
.farm-hit-block { margin: 7px 0; font-size: .75rem; color: wheat; }
.farm-hit-expected {
    display: grid; justify-items: center; gap: 2px; margin: 7px 0; padding: 8px;
    background: #14130f; border: 1px solid #67583c; color: #ffd560;
}
.farm-hit-results tbody tr { background: #090806; border-bottom: 1px solid #5a4d31; }
.target-information-dialog { width: min(1060px, 94vw); }
.target-information-grid { display: grid; grid-template-columns: 1.12fr 1fr; gap: 8px; }
.target-information-grid > section { background: #171510; border: 1px solid #5a4d31; padding: 10px; }
.target-information-hero { display: flex; align-items: start; gap: 9px; }
.target-information-hero .costume-product-icon { flex: 0 0 auto; width: 92px; height: 100px; object-fit: contain; }
.target-information-hero h2, .target-information-hero p { margin: 0 0 5px; }
.target-map-zoom { display: grid; place-items: center; width: 100%; margin-top: 5px; }
.target-map-zoom img { height: 128px; object-fit: contain; }
.target-map-zoom[aria-expanded="true"] img { height: min(400px, 52dvh); }
@media (max-width: 700px) {
    .target-information-grid { grid-template-columns: 1fr; }
}
@keyframes farm-hit-rise { from { transform: translateY(10px); } to { transform: translateY(-10px); opacity: .15; } }
@media (prefers-reduced-motion: reduce) { .farm-hit-stage output { animation: none; } }
.farm-alchemy-board {
    position: relative; width: min(100%, 282px); aspect-ratio: 282 / 330;
    margin: .4rem auto; background: url("../assets/alchemy-reference-v31.png") center / 100% 100%;
}
.farm-alchemy-board button { position: absolute; padding: 0; min-height: 0; border: 1px solid transparent; background: #0004; }
.farm-alchemy-board button:is(:hover, :focus-visible, [aria-pressed="true"]) { border-color: #ffdb54; background: transparent; }
.farm-alchemy table { width: 100%; }
.farm-alchemy input[type="number"] { width: 5.5rem; }
.farm-target-preview p { margin: .3rem 0 0; font-size: .78rem; line-height: 1.35; }
.farm-costume-slots .farm-mount-slot {
    position: absolute; padding: 0; min-height: 0; border: 1px solid transparent; background: transparent;
}
.farm-costume-slots .farm-mount-slot:hover { border-color: #c2a048; }
.farm-pet-choice { display: flex; gap: .3rem; align-items: center; }
.farm-pet-choice img { width: 30px; height: 30px; object-fit: contain; }
.farm-costume-empty { margin: 5px 0 8px; color: wheat; font-size: .73rem; }
.farm-toolbar { display: flex; gap: 6px; flex-wrap: wrap; margin: 4px 0 8px; }
.farm-toolbar > :is(button, a, label), .farm-toolbar-confirm {
    border: 1px solid #67583c; background: #171510; color: wheat; padding: 4px 12px;
}
.farm-toolbar > button:disabled { color: #8c8169; }
.farm-toolbar > a { text-decoration: none; }
.farm-toolbar-file { position: relative; cursor: pointer; }
.farm-toolbar-file input { position: absolute; inset: 0; opacity: 0; width: 100%; cursor: pointer; }
.farm-toolbar-file:focus-within { outline: 2px solid #e0b947; }
.farm-toolbar-confirm p, .farm-toolbar-status { margin: 0 0 5px; color: wheat; }
.owned-items, .owned-item-editor { padding: 9px; margin: 6px 0 12px; color: wheat; }
.owned-items > label { display: inline-block; margin-right: 8px; }
.owned-items ul { list-style: none; margin: 8px 0; padding: 0; }
.owned-items li { display: flex; gap: .5rem; align-items: center; border: 1px solid #67583c; padding: 4px; margin-bottom: 3px; background: #171510; }
.owned-items li > div { flex: 1; }
.owned-items li small { display: block; }
.owned-items li .equipment-icon { width: 32px; height: 36px; object-fit: contain; }
.desktop-shell:has(.farm-page-heading) {
    position: relative; margin: 9px 16px; background: url("../assets/wiki/farm-stone-texture.png") repeat;
}
.farm-menu-toggle { display: none; }
.desktop-shell:has(.farm-page-heading) .desktop-navigation { position: absolute; inset: 0 auto auto 0; z-index: 4; }
.desktop-shell:has(.farm-page-heading) .desktop-brand,
.desktop-shell:has(.farm-page-heading) .desktop-tabs:not(.farm-menu-open) { display: none; }
.desktop-shell:has(.farm-page-heading) .farm-menu-toggle {
    display: grid; place-items: center; width: 35px; height: 35px; padding: 0;
}
.desktop-shell:has(.farm-page-heading) .desktop-tabs { display: grid; padding: 4px; background: #171510; border: 1px solid #67583c; }
.desktop-shell:has(.farm-page-heading) .desktop-tabs a { padding: 4px 8px; }
.desktop-shell:has(.farm-page-heading) .farm-page-header { padding-left: 42px; min-height: 38px; }
.desktop-shell:has(.desktop-scene) { position: relative; margin: 0; }
.desktop-shell:has(.desktop-scene) .desktop-navigation { position: absolute; left: 40%; top: .8vw; z-index: 5; }
.desktop-shell:has(.desktop-scene) .desktop-brand,
.desktop-shell:has(.desktop-scene) .desktop-tabs:not(.farm-menu-open) { display: none; }
.desktop-shell:has(.desktop-scene) .farm-menu-toggle {
    display: grid; place-items: center; width: clamp(25px, 2.75vw, 48px); aspect-ratio: 1; padding: 0;
}
.desktop-shell:has(.desktop-scene) .farm-menu-toggle img { width: 100%; height: auto; }
.desktop-shell:has(.desktop-scene) .desktop-tabs { display: grid; padding: 4px; background: #171510; border: 1px solid #67583c; }

@media (min-width: 1121px) and (min-height: 600px) {
    .desktop-shell:has(.farm-dashboard) { display: flex; flex-direction: column; height: calc(100dvh - 18px); }
    .desktop-shell:has(.farm-dashboard) > :not(.farm-dashboard) { flex-shrink: 0; }
    .farm-dashboard { flex: 1 1 auto; min-height: 0; align-items: stretch; }
    .farm-dashboard .combat-column { height: auto; min-height: 0; }
}
@media (max-width: 1120px) { .farm-dashboard .combat-column { height: auto; } }
.farm-character-identity { display: flex; align-items: center; gap: 7px; margin: .2rem 0 .55rem; }
.farm-character-identity img { width: 40px; height: 42px; }
.farm-character-identity p { margin: 0; }
.farm-character-class { margin: 3px 3px 0 0; max-width: 100%; padding: 2px 4px; font-size: .74rem; }
.character-stat-icon-tile { display: grid; grid-template-columns: 26px minmax(0, 1fr); align-items: center; gap: 3px; }
.character-stat-icon-tile img { display: block; width: 25px; height: 25px; object-fit: contain; image-rendering: pixelated; }
.character-stat-icon-tile dd { text-align: center; font-size: .82rem; }

.farm-character-card { float: right; width: 28px; height: 28px; padding: 1px; margin-left: 4px; }
.farm-character-card img { display: block; width: 100%; height: 100%; object-fit: contain; }
.farm-character-card-bonuses { clear: both; margin-bottom: 6px; padding: 5px; background: #171510; border: 1px solid #67583c; }
.farm-character-card-bonuses ul { padding-left: 20px; }

.farm-gear-toggle { width: 100%; margin: 0 0 .4rem; }
.farm-gear-editor { margin-bottom: .55rem; }
.farm-effects > .warehouse-bonus { margin: .2rem 0 .45rem; }
.farm-effects > .warehouse-bonus > summary { border: 0; padding: 1px 0; font-size: .84rem; }
.warehouse-bonus select { width: 100%; }
.farm-target-modes { display: flex; gap: 4px; justify-content: center; margin: 0 0 7px; }
.farm-target-modes button { padding: 4px 7px; }
.farm-target-modes button[aria-pressed="true"] { border-color: #b49348; color: #ffdd53; background: #2f2618; }
.farm-outgoing-panel > details, .farm-incoming-panel > details { margin: 6px 0; }
.combat-totals { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 4px 10px; margin-top: 6px; }
.combat-totals dt { font-weight: normal; }
.combat-totals dd { margin: 0; text-align: right; }
.farm-yohara-context { color: #d3a8ea; font-size: .82rem; margin: .35rem 0; }
.farm-yohara-context dl { display: grid; grid-template-columns: auto 1fr; margin: .15rem 0; gap: 2px 6px; }
.farm-yohara-context dd { margin: 0; }
.farm-costume-extras { margin-top: 8px; padding: 6px; border: 1px solid #67583c; background: #32251a; }
.farm-costume-extras h3 { font-size: .88rem; margin: 0 0 5px; }
.farm-costume-extras :is(select,input[type="search"]) { width: 100%; }
.farm-set-part-field { display: grid; gap: 3px; margin: 5px 0; font-size: .75rem; }
.farm-set-part-field > button { display: flex; justify-content: space-between; text-align: left; padding: 3px 5px; }
.farm-set-part-options { display: grid; max-height: 190px; overflow: auto; }
.farm-set-part-options button { display: flex; align-items: center; gap: 4px; text-align: left; padding: 3px; }
.farm-set-part-options button[aria-pressed="true"] { color: #ffd560; }
.farm-set-part-options .costume-product-icon { width: 22px; height: 22px; object-fit: contain; }
.farm-set-part-preview { padding: 4px; background: #19150f; color: wheat; }
.farm-set-part-preview p { margin: 3px 0; }
.farm-mini-set-list { max-height: 245px; overflow: auto; margin: 4px 0; }
.farm-mini-set-list .costume-catalog-card { display: flex; align-items: center; gap: 4px; color: wheat; font-size: .77rem; text-decoration: none; }
.scene-menubar { position: absolute; top: 1.4%; right: 1%; left: 43.2%; display: flex; flex-wrap: wrap; align-items: start; gap: 4px; }
.scene-menubar .scene-menu { position: static; }
.scene-menubar .farm-toolbar { margin: 0; font-size: 12px; }
.scene-menubar .farm-toolbar > :is(button, label) { padding: 5px 8px; }
.scene-menubar .farm-toolbar-confirm, .scene-menubar .farm-toolbar-status { position: absolute; top: 100%; right: 0; }
.farm-comparison-page { padding: 10px; }
.farm-comparison-page h2 { font-size: 1.1rem; }
.target-picker-dialog {
    position: fixed; width: min(980px, 95vw); max-height: min(720px, 93dvh);
    color: wheat; padding: 10px; margin: auto; overflow: auto;
}
.target-picker-dialog::backdrop { background: #000a; }
.target-picker-dialog > :is(p, header) { margin: 0 0 7px; }
.target-picker-filters, .target-picker-dialog footer { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
.target-picker-filters label { display: flex; align-items: center; gap: 4px; }
.target-picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(155px, 1fr)); gap: 7px; padding: 3px; max-height: 52dvh; overflow: auto; }
.target-picker-grid button { display: grid; justify-items: center; gap: 4px; padding: 5px; }
.target-picker-grid img { width: 100%; height: 84px; object-fit: contain; }
.target-picker-dialog footer { margin-top: 7px; }
.target-picker-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.target-picker-window-buttons { display: flex; flex-shrink: 0; gap: 3px; }
.target-picker-title .target-picker-window-buttons button { width: 32px; height: 27px; padding: 0; font-size: 17px; line-height: 1; }
.target-picker-dialog.target-picker-full[open] {
    display: grid; grid-template-rows: auto auto auto minmax(0, 1fr) auto;
    width: calc(100vw - 16px); height: calc(100dvh - 16px); max-width: none; max-height: none;
}
.target-picker-full .target-picker-grid { max-height: none; min-height: 0; align-content: start; }
.target-picker-restore { position: fixed; right: 12px; bottom: 12px; z-index: 10; }

.farm-name-editor { display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.farm-name-editor input { width: 82px; min-width: 0; padding: 2px 4px; }
.farm-name-editor button { padding: 2px 5px; }

.farm-toolbar-logo { position: absolute; top: 0; left: 0; }

.farm-character-card-dialog { width: min(340px, 94vw); min-height: min(280px, 80dvh); }

.costume-browser .costume-browser-close { position: absolute; top: 6px; right: 8px; width: 30px; height: 27px; padding: 0; font-size: 20px; line-height: 1; }

.farm-yin-yang-dialog { width: min(850px, 94vw); }

.harmony-dialog { box-sizing: border-box; width: min(312px, 94vw); max-height: 94dvh; padding: 0; color: wheat; }
.harmony-dialog::backdrop { background: #0009; }
.harmony-title { display: flex; gap: 6px; align-items: center; margin: 0; padding: 0 4px; min-height: 22px; }
.harmony-title img { width: 16px; height: 16px; }
.harmony-title span { flex: 1; }
.harmony-title button { color: wheat; background: transparent; border: 0; min-width: 28px; padding: 0; }
.harmony-body { padding: 19px 12px 12px; }
.harmony-body h2 { font-size: .83rem; font-weight: normal; text-align: center; margin: 0; border: 1px solid #806a48; background: linear-gradient(#803e15,#45210e); }
.harmony-board { position: relative; width: min(268px,100%); aspect-ratio: 268 / 276; margin: 8px auto 3px; }
.harmony-ring { position: absolute; inset: 4.35% 3.73% 5.8%; border: 2px solid #685b41; border-radius: 50%; background: radial-gradient(ellipse,#39322b,#151311); }
.harmony-ring::after { content: "☯"; position: absolute; inset: 0; display: grid; place-items: center; font-size: clamp(110px,67vw,219px); color: #eed4a9; opacity: .11; line-height: 1; }
.harmony-board svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.harmony-board path { fill: none; stroke: #423c35; stroke-width: 1.5px; }
.harmony-board .harmony-gold { stroke: #bd8e21; stroke-width: 3px; }
.harmony-board .harmony-blue { stroke: #00bfff; stroke-width: 3px; }
.harmony-slot { position: absolute; transform: translate(-50%,-50%); width: 18.28%; aspect-ratio: 1; text-align: center; }
.harmony-slot > div { width: 100%; height: 100%; padding: 4px; border: 2px solid #67583c; border-radius: 4px; background: #1a1817; }
.harmony-slot img { width: 100%; height: 100%; object-fit: contain; }
.harmony-slot small { display: block; font-size: .62rem; white-space: nowrap; }
.harmony-body p { min-height: 2.7em; font-size: .8rem; margin: 6px 3px 8px; }
.harmony-body footer { display: flex; justify-content: space-between; gap: 6px; }
.harmony-body footer button { padding: 6px 12px; }
