/* styles.css */
:root { font-family: Inter, ui-rounded, system-ui, sans-serif; color: #f8f1dc; background: #0d1713; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 70% 20%, #31503b 0, #14251d 35%, #0d1713 70%); }
#notice { position: fixed; z-index: 10; top: 1rem; left: 50%; transform: translateX(-50%); width: min(560px, calc(100% - 2rem)); padding: .9rem 1.2rem; border: 1px solid #eebc65; border-radius: 10px; background: #172820; color: #f8f1dc; box-shadow: 0 8px 30px #0009; }
#notice.error { border-color: #ff766b; color: #ffd7d3; }
button, input, select { font: inherit; }
button { cursor: pointer; }
header, footer { display: flex; justify-content: space-between; padding: 1.3rem clamp(1.2rem, 5vw, 5rem); color: #b9c9b8; border-bottom: 1px solid #ffffff18; }
header strong { letter-spacing: .12em; }
header strong span, .eyebrow, a { color: #eebc65; }
.online { color: #75d69d; }
main { max-width: 1100px; margin: auto; padding: 3rem 1.4rem; }
.hero { text-align: center; margin-bottom: 3rem; }
.hero #profile { display: flex; justify-content: center; gap: .5rem; max-width: 420px; margin: 1rem auto; }
.progress-card { display: grid; grid-template-columns: auto minmax(120px, 260px) auto; align-items: center; justify-content: center; gap: .65rem; margin: 1rem auto; color: #e8dcb8; font-size: .82rem; }
.progress-card > span { color: #eebc65; font-weight: 800; }.progress-card small { color: #b9c9b8; }
.progress-track { overflow: hidden; height: 12px; border: 2px solid #694b2d; border-radius: 999px; background: #0d1713; box-shadow: inset 0 2px 4px #0008; }
.progress-track :where(i) { display: block; width: 0; height: 100%; background: linear-gradient(90deg, #eebc65, #ffdf7f); transition: width .4s ease; }
.health { width: fit-content; margin: -.4rem auto .8rem; padding: .3rem .7rem; border-radius: 999px; background: #321e20; color: #ffaaa2; font-size: .82rem; }
.hero h1, .auth h1 { font: 700 clamp(2.5rem, 7vw, 5.5rem)/.95 Georgia, serif; margin: .25em 0; }
.eyebrow { font-weight: 800; font-size: .75rem; letter-spacing: .18em; }
.card, .shadow { border: 1px solid #ffffff1c; background: #172820e8; color: inherit; border-radius: 18px; }
.card { padding: 1.5rem; margin-bottom: 1.5rem; }
.auth { max-width: 500px; margin: 5vh auto; padding: 2rem; }
.tabs { display: flex; margin-bottom: 1rem; }
.tabs button { flex: 1; background: transparent; color: #aaa; border: 0; border-bottom: 2px solid #456; padding: .8rem; }
.tabs .active { color: #eebc65; border-color: #eebc65; }
form { display: grid; gap: .7rem; }
input, select, form button, #actions button, .minor, .duel button, [data-accept], [data-suspend] { border: 1px solid #ffffff24; border-radius: 9px; background: #263a2f; color: #fff; padding: .75rem; }
.error, .danger { color: #ff9b91; }
.questionnaire form { grid-template-columns: 2fr 1fr 1fr auto; align-items: center; padding: .6rem 0; border-top: 1px solid #ffffff12; }
.account-actions { display: grid; grid-template-columns: 2fr 1fr; gap: 1rem; }
.account-actions > div { display: grid; align-content: start; gap: .7rem; }
.account-actions button { border: 1px solid #ffffff24; border-radius: 9px; background: #263a2f; color: #fff; padding: .75rem; }
.columns { display: grid; grid-template-columns: minmax(0, 2fr) minmax(240px, 1fr); gap: 1.5rem; }
.players { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.guide { display: grid; grid-template-columns: 1.4fr 1fr; align-items: center; gap: 1.5rem; border-color: #eebc6566; background: linear-gradient(120deg, #2d4935, #172820); }.guide h2, .guide p { margin: .25rem 0; }.guide > div > p:last-child { color: #c2d0c0; }.guide-steps { display: grid; gap: .45rem; }.guide-steps span { padding: .55rem .7rem; border-radius: 7px; background: #0d171388; color: #9eaea0; }.guide-steps span.done { color: #dff7c9; box-shadow: inset 4px 0 #75d69d; }.zone-label { margin: 0 0 .5rem; color: #eebc65; font-size: .75rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.zone-nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-bottom: 1rem; }.zone-nav button { display: grid; gap: .25rem; padding: .85rem; border: 2px solid #4b674f; border-radius: 10px; background: #172820; color: #f8f1dc; text-align: left; box-shadow: 0 5px #09100c; }.zone-nav button:hover:not(:disabled) { border-color: #eebc65; transform: translateY(-2px); }.zone-nav button.active { border-color: #eebc65; background: #2d4935; cursor: default; }.zone-nav small { color: #91a596; }
.village-card { padding: 1rem; background: #253d30; box-shadow: 0 14px 35px #050b0788; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 1rem; padding: .35rem .5rem 1rem; }
.section-title h2, .section-title p { margin: 0; }
.section-title > p { color: #b9c9b8; font-size: .9rem; }
#map { position: relative; isolation: isolate; overflow: hidden; height: clamp(360px, 55vw, 560px); border: 5px solid #694b2d; border-radius: 12px; background-color: #65a653; background-image: radial-gradient(circle at 20% 30%, #8bc368 0 3px, transparent 4px), radial-gradient(circle at 72% 68%, #4b913e 0 3px, transparent 4px), linear-gradient(#ffffff08 50%, transparent 50%); background-size: 83px 71px, 97px 89px, 100% 8px; cursor: crosshair; box-shadow: inset 0 0 0 3px #a77842, inset 0 0 35px #284d2588; image-rendering: pixelated; }
#map::after { content: ''; position: absolute; z-index: 8; inset: 0; pointer-events: none; box-shadow: inset 0 0 28px #14251d88; }
#map:focus-visible { outline: 4px solid #eebc65; outline-offset: 3px; }
.zone-forest { background: #6f9d4b !important; background-image: none !important; }.zone-forest .house, .zone-forest .garden, .zone-forest .well, .zone-forest .bridge { display: none; }.zone-forest .river { right: auto; left: 7%; width: 12%; transform: rotate(-4deg); }.zone-forest .path { background: #9b7a4d; border-color: #795b37; box-shadow: inset 0 0 0 4px #b6925c; }.zone-forest .map-hint { background: #244f2d; }
.zone-deep-forest { background: #244936 !important; background-image: none !important; border-color: #294e3d !important; box-shadow: inset 0 0 0 3px #396950, inset 0 0 90px #06110d !important; }.zone-deep-forest .house, .zone-deep-forest .garden, .zone-deep-forest .well, .zone-deep-forest .tree, .zone-deep-forest .river, .zone-deep-forest .bridge { display: none; }.zone-deep-forest .path { background: #304c3d; border-color: #21392e; box-shadow: inset 0 0 0 4px #41614f; }.zone-deep-forest .map-hint { background: #10241c; border-color: #75d69d; color: #c9ffda; }
.path { position: absolute; z-index: -1; background: #d6b477; border: 4px solid #b18b52; box-shadow: inset 0 0 0 4px #e4c98e; }
.path-horizontal { left: -4%; right: -4%; top: 44%; height: 19%; transform: rotate(-2deg); }
.path-vertical { top: -8%; bottom: -8%; left: 43%; width: 14%; transform: rotate(4deg); }
.river { position: absolute; z-index: -2; top: 0; bottom: 0; right: 2%; width: 6%; background: repeating-linear-gradient(0deg, #55bad0 0 8px, #78d5df 8px 14px, #43a3bf 14px 22px); border-inline: 5px solid #d4c27b; box-shadow: 0 0 0 5px #477f3f; }
.bridge { position: absolute; z-index: 0; right: 1%; top: 54%; width: 10%; height: 14%; background: repeating-linear-gradient(90deg, #9b6035 0 13px, #c8864c 13px 25px); border: 5px solid #603d28; box-shadow: 0 5px #372519; }
.house { position: absolute; z-index: 1; width: 105px; height: 72px; background: #e9c578; border: 5px solid #704129; border-radius: 3px; box-shadow: inset 0 -10px #c99252, 0 8px #315c31; pointer-events: none; }
.building-layer { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; image-rendering: pixelated; }

.house::before { content: ''; position: absolute; left: -14px; right: -14px; top: -47px; height: 50px; background: #b8573f; border: 5px solid #704129; clip-path: polygon(50% 0, 100% 70%, 91% 100%, 9% 100%, 0 70%); }
.house span { position: absolute; width: 25px; height: 38px; bottom: 0; left: 35px; background: #704129; border: 4px solid #4a2c20; }
.house-left { left: 7%; top: 19%; transform: scale(.9); }
.house-right { right: 4%; bottom: 8%; transform: scale(.72); }
.tree { position: absolute; z-index: 1; width: 52px; height: 52px; border-radius: 45% 55% 48% 52%; background: #2f7138; border: 5px solid #20502c; box-shadow: inset 8px 8px #469348, 5px 8px #315c31; pointer-events: none; }
.tree::after { content: ''; position: absolute; z-index: -1; width: 13px; height: 30px; left: 15px; top: 39px; background: #81502e; border: 3px solid #58361f; }
.tree-one { left: 36%; top: 84%; translate: -50% -50%; }.tree-two { left: 28%; top: 91%; translate: -50% -50%; transform: scale(.8); }.tree-three { left: 68%; top: 10%; translate: -50% -50%; transform: scale(.75); }
.garden { position: absolute; left: 19%; top: 5%; display: grid; grid-template-columns: repeat(3, 13px); gap: 9px; padding: 8px; background: #754b2e; border: 4px solid #a97642; transform: rotate(-3deg); pointer-events: none; }
.garden i { width: 9px; height: 9px; border-radius: 50%; background: #ffd34f; box-shadow: 0 0 0 4px #fff2a1; }
.well { position: absolute; z-index: 1; left: 60.5%; top: 27%; width: 54px; height: 39px; translate: -50% -50%; border-radius: 50%; background: #24506a; border: 9px solid #9c9d8a; box-shadow: 0 5px #545c55; pointer-events: none; }
.map-hint { position: absolute; z-index: 1; left: 50%; top: 66%; transform: translateX(-50%); padding: .35rem .65rem; background: #3c2c20cc; border: 2px solid #d8b56f; border-radius: 5px; color: #ffe8aa; font: 700 .67rem/1 ui-monospace, monospace; text-transform: uppercase; white-space: nowrap; pointer-events: none; }
.pawn { position: absolute; z-index: 5; width: 46px; height: 58px; padding: 0; transform: translate(-50%, -68%); border: 0; background: transparent !important; color: inherit; filter: drop-shadow(0 5px 2px #17351d88); transition: left .5s linear, top .5s linear, transform .15s; }
.pawn:not(.self):hover, .pawn:not(.self):focus-visible { transform: translate(-50%, -72%) scale(1.12); }
.pawn.self { pointer-events: none; }
.pawn.is-moving .character { animation: character-step .24s steps(2) infinite; }
@keyframes character-step { 25% { translate: 0 -4px; rotate: -2deg; } 75% { translate: 0 -2px; rotate: 2deg; } }
#destination { position: absolute; z-index: 2; display: none; width: 18px; height: 10px; translate: -50% -50%; border: 3px solid #fff2a1; border-radius: 50%; box-shadow: 0 0 0 2px #694b2d88; pointer-events: none; animation: destination-pulse .7s ease-out infinite alternate; }
#destination.visible { display: block; }
@keyframes destination-pulse { to { transform: scale(.7); opacity: .55; } }
.character { display: block; position: relative; width: 100%; height: 100%; }
.character-renderer { position: absolute; left: 50%; bottom: 0; width: 68px; height: 91px; translate: -50% 0; pointer-events: none; }
.pawn.character-shadow, .pawn.character-male, .pawn.character-female { width: 68px; height: 91px; transform: translate(-50%, -100%); }
.pawn.character-shadow:not(.self):hover, .pawn.character-shadow:not(.self):focus-visible,
.pawn.character-male:not(.self):hover, .pawn.character-male:not(.self):focus-visible,
.pawn.character-female:not(.self):hover, .pawn.character-female:not(.self):focus-visible { transform: translate(-50%, -100%) scale(1.08); }
.character-sprite { display: block; width: 68px; height: 90.5px; background-repeat: no-repeat; image-rendering: auto; transform-origin: 50% 100%; }
/* Combat is a distinct visual state, so walking and breathing cannot overwrite it.
   The seven poses read as guard, wind-up, crouch, strike, contact, recovery, rest. */
#self.player-attack-ready .character-renderer { transform: translate(calc(var(--attack-back-x, 0px) * .35),calc(var(--attack-back-y, 0px) * .35)) rotate(calc(var(--attack-rotate, 0deg) * -.18)); }
#self.player-attacking .character-renderer { animation: player-attack-body var(--attack-duration,520ms) cubic-bezier(.22,.7,.2,1) both; }
#self.attack-direction-left { --attack-x: calc(var(--attack-lunge) * -1); --attack-y: 0px; --attack-back-x: var(--attack-lunge); --attack-back-y: 0px; --attack-rotate: -7deg; --impact-left: -9px; --impact-top: 43px; }
#self.attack-direction-right { --attack-x: var(--attack-lunge); --attack-y: 0px; --attack-back-x: calc(var(--attack-lunge) * -1); --attack-back-y: 0px; --attack-rotate: 7deg; --impact-left: 61px; --impact-top: 43px; }
#self.attack-direction-up { --attack-x: 0px; --attack-y: calc(var(--attack-lunge) * -.7); --attack-back-x: 0px; --attack-back-y: calc(var(--attack-lunge) * .45); --attack-rotate: -3deg; --impact-left: 31px; --impact-top: 4px; }
#self.attack-direction-down { --attack-x: 0px; --attack-y: calc(var(--attack-lunge) * .7); --attack-back-x: 0px; --attack-back-y: calc(var(--attack-lunge) * -.45); --attack-rotate: 3deg; --impact-left: 31px; --impact-top: 78px; }
@keyframes player-attack-body {
  0% { transform: translate(0,0) rotate(0) scale(1); }
  20% { transform: translate(calc(var(--attack-back-x) * .28),calc(var(--attack-back-y) * .28)) rotate(calc(var(--attack-rotate) * -.2)); }
  36% { transform: translate(calc(var(--attack-back-x) * .5),calc(var(--attack-back-y) * .5)) rotate(calc(var(--attack-rotate) * -.45)); }
  55% { transform: translate(var(--attack-x),var(--attack-y)) rotate(var(--attack-rotate)); }
  64% { transform: translate(calc(var(--attack-x) * .9),calc(var(--attack-y) * .9)) rotate(calc(var(--attack-rotate) * .72)); }
  82% { transform: translate(calc(var(--attack-back-x) * .1),calc(var(--attack-back-y) * .1)) rotate(calc(var(--attack-rotate) * -.08)); }
  100% { transform: translate(0,0) rotate(0) scale(1); }
}
#self.player-attacking::after { content:''; position:absolute; z-index:9; left:var(--impact-left); top:var(--impact-top); width:18px; height:18px; border:3px solid #fff0b4; border-left-color:transparent; border-radius:50%; opacity:0; pointer-events:none; animation:player-punch-impact var(--attack-duration,520ms) ease-out both; }
#self.attack-sword.player-attacking::after { width:42px; height:42px; border-width:5px; border-color:#d9fbff #d9fbff transparent transparent; filter:drop-shadow(0 0 5px #bffcff); }

@keyframes player-punch-impact { 0%,45% { opacity:0; transform:scale(.35) rotate(-45deg); } 53% { opacity:1; transform:scale(1.2) rotate(20deg); } 68%,100% { opacity:0; transform:scale(1.65) rotate(70deg); } }
@keyframes player-sword-swing { 0% { rotate:-35deg; } 32% { rotate:-70deg; } 58% { rotate:75deg; } 100% { rotate:28deg; } }

.avatar-forest { --avatar: #78b96b; }
.avatar-sunset { --avatar: #e88b62; }
.avatar-ocean { --avatar: #64a9d8; }
.avatar-hidden { --avatar: #101512; }
.stage-0 { color: #59635c !important; filter: brightness(.55) drop-shadow(0 5px 2px #17351d88); }
.stage-1 { border-color: var(--avatar) !important; }
.stage-2 { background: color-mix(in srgb, var(--avatar) 35%, #172820) !important; }
.stage-3 { background: color-mix(in srgb, var(--avatar) 65%, #172820) !important; color: #fff !important; }
.stage-4, .stage-5 { background: var(--avatar) !important; color: #102017 !important; filter: drop-shadow(0 0 8px var(--avatar)); }
.stage-5 { box-shadow: 0 0 0 3px #f8f1dc55, 0 5px 16px #0008; }
.shadow { padding: 1.3rem; transition: transform .2s, border-color .2s; }
.shadow:hover { transform: translateY(-4px); border-color: #eebc6588; }
.shadow i { display: grid; place-items: center; margin: auto auto 1rem; width: 90px; height: 100px; border-radius: 50% 50% 35% 35%; background: #0d1713; font: italic 3rem Georgia; color: #eebc65; }
.shadow i.portrait { position: relative; overflow: hidden; background: linear-gradient(#7fb4bc 0 62%, #6e9c55 62%) !important; border: 3px solid #d8b56f; filter: none; }
.portrait .character { transform: scale(1.45); transform-origin: center bottom; top: 13px; }
.portrait.stage-0 .character { filter: brightness(.45); }
.shadow b, .shadow small { display: block; }
.shadow small { color: #91a596; margin-top: .4rem; }
.ranking h2 { margin-top: .15rem; }.rank-row { display: grid; grid-template-columns: 2rem 1fr auto; gap: .45rem; align-items: center; padding: .55rem 0; border-top: 1px solid #ffffff12; font-size: .85rem; }.rank-row.self { color: #ffe094; }.rank-row strong { overflow: hidden; text-overflow: ellipsis; }.rank-row small { color: #91a596; }
.daily { border-color: #eebc6555; background: linear-gradient(145deg, #263f31, #172820); }.daily h2 { margin: .2rem 0; }.daily > p:not(.eyebrow) { color: #b9c9b8; font-size: .85rem; }.quest-goal { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-top: 1px solid #ffffff12; }.quest-goal.done { color: #75d69d; }.daily button { width: 100%; margin-top: .7rem; padding: .7rem; border: 2px solid #8d6636; border-radius: 8px; background: #eebc65; color: #172820; font-weight: 800; }.daily button:disabled { cursor: default; opacity: .55; }
.inventory-card .section-title { padding-inline: 0; }.inventory-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)); gap: .75rem; }.item-stack { display: grid; grid-template-columns: 2.5rem 1fr auto; align-items: center; gap: .6rem; min-height: 72px; padding: .65rem; border: 2px solid #715437; border-radius: 9px; background: #263a2f; box-shadow: inset 0 0 0 2px #ffffff08; }.item-icon { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 7px; background: #172820; font-size: 1.5rem; }.item-stack strong, .item-stack small { display: block; }.item-stack small { color: #91a596; }.item-stack button { border: 0; background: transparent; color: #ffaaa2; font-size: 1.1rem; }.empty-slot { min-height: 72px; border: 2px dashed #ffffff18; border-radius: 9px; }
.duel { display: flex; align-items: center; gap: .6rem; padding: .6rem 0; border-top: 1px solid #ffffff12; }
.duel span { margin-right: auto; }
.challenge-picker { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.7rem; margin-top:1rem; }
.challenge-card,.challenge-arena { border:1px solid #d8bd6999; border-radius:14px; padding:.85rem; background:linear-gradient(145deg,#183c31,#2e4934); box-shadow:inset 0 0 24px #9cff9a12; }
.challenge-card h3,.challenge-arena h4 { color:#ffe9a8; margin:.25rem 0; }
.challenge-art { display:block; font-size:2rem; filter:drop-shadow(0 0 8px #caff92); }
.challenge-runes { background:linear-gradient(145deg,#24264f,#58345f); }
.challenge-fireflies { background:linear-gradient(145deg,#153b38,#315632); }
.challenge-controls { display:flex; flex-wrap:wrap; gap:.45rem; margin-top:.6rem; }
.firefly-sequence { letter-spacing:.5rem; color:#f7ff9b; font-size:1.35rem; }
@media (max-width:700px){.challenge-picker{grid-template-columns:1fr}.challenge-card{padding:.65rem}.challenge-controls button{min-height:44px;flex:1 1 30%}}
@media (prefers-reduced-motion:reduce){.challenge-card,.challenge-art{animation:none!important;transition:none!important}}
.modal { position: fixed; z-index: 2; left: 50%; top: 50%; width: min(560px, calc(100% - 2rem)); transform: translate(-50%, -50%); text-align: center; box-shadow: 0 20px 80px #000c; }
.close { position: absolute; right: 1rem; top: .5rem; background: none; border: 0; color: white; font-size: 2rem; }
#actions { display: flex; gap: .7rem; justify-content: center; flex-wrap: wrap; }
footer { font-size: .8rem; border: 0; }
.map-legend { display: flex; gap: 1.25rem; flex-wrap: wrap; padding: .8rem .4rem 0; color: #b9c9b8; font-size: .78rem; }
.map-legend span { display: flex; align-items: center; gap: .35rem; }
.map-legend i { width: 10px; height: 10px; border-radius: 50%; background: #eebc65; }.map-legend .legend-player { background: #75d69d; }
.map-legend .legend-monster { background: #b4e251; }
.monster { position: absolute; z-index: 6; width: 100px; height: 88px; padding: 25px 8px 13px; translate: -50% -58%; border: 0; background: #172820dd; border-radius: 12px; color: #fff; filter: drop-shadow(0 7px 3px #17351d99); box-shadow: 0 0 0 3px #eebc65; animation: monster-alert 1.1s ease-in-out infinite alternate; }.monster-name { position: absolute; left: 50%; top: 5px; translate: -50%; width: max-content; max-width: 150px; overflow: hidden; text-overflow: ellipsis; font-size: .68rem; font-weight: 900; white-space: nowrap; text-shadow: 0 2px #000; }.monster > small { position: absolute; left: 0; right: 0; bottom: 2px; font-size: .6rem; }.monster-sprite { display: block; position: relative; width: 54px; height: 40px; margin: auto; border: 4px solid #314525; border-radius: 55% 50% 42% 48%; background: #8fc64e; box-shadow: inset 8px 9px #b7e66c; }.monster-sprite::before { content: ''; position: absolute; left: 11px; top: 17px; width: 5px; height: 5px; border-radius: 50%; background: #1f281b; box-shadow: 19px 0 #1f281b; }.monster-sprite::after { content: ''; position: absolute; left: 19px; bottom: 5px; width: 10px; height: 3px; border-bottom: 2px solid #39502a; }.monster:hover .monster-sprite, .monster:focus-visible .monster-sprite { transform: scale(1.15); }.monster-hp { position: absolute; left: 8px; right: 8px; bottom: 12px; height: 8px; border: 2px solid #26351e; background: #2c1b1c; }.monster-hp i { display: block; height: 100%; background: #e55f55; }.monster.dead { opacity: .5; filter: grayscale(1); pointer-events: none; animation: none; }@keyframes monster-alert { to { translate: -50% -63%; box-shadow: 0 0 0 5px #eebc6533; } }
/* Presets sélectionnés dans public/world.js. */
.forge.skin-ember { background: #dfae68; }.forge.skin-ember::before { background: #843d32; }
.forge.skin-slate { background: #aab0ad; }.forge.skin-slate::before { background: #4e5960; }
.market.skin-meadow { background: #d8c979; }.market.skin-meadow::before { background: #4f7b48; }
.market.skin-harvest { background: #e2ad5c; }.market.skin-harvest::before { background: #9b5434; }

.map-legend .legend-portal { background: #ba8cff; }.portal { position: absolute; z-index: 5; width: 76px; min-height: 82px; translate: -50% -50%; border: 3px solid #dfc4ff; border-radius: 50% 50% 12px 12px; background: radial-gradient(ellipse, #c994ff88, #3a2456 60%); color: #fff; box-shadow: 0 0 18px #ba8cff; animation: portal-glow 1.2s ease-in-out infinite alternate; }.portal span { display: block; color: #f4deff; font-size: 1.7rem; }.portal strong { display: block; font-size: .58rem; line-height: 1.15; }.portal:hover { filter: brightness(1.25); }@keyframes portal-glow { to { box-shadow: 0 0 30px #dcbcff; } }
[hidden] { display: none !important; }
@media (max-width: 760px) { .questionnaire form, .columns, .account-actions, .guide { grid-template-columns: 1fr; } .players { grid-template-columns: 1fr; } .zone-nav { grid-template-columns: 1fr; }.section-title { display: block; }.section-title > p { margin-top: .5rem; } #map { height: 420px; } .house-right { display: none; } .portal { width: 62px; }.portal strong { font-size: .5rem; } footer { display: block; text-align: center; } }

/* Grand monde défilant : la fenêtre montre une partie de la carte et suit le héros. */
.map-viewport { position: relative; overflow: hidden; height: min(68vh, 680px); min-height: 440px; border: 5px solid #694b2d; border-radius: 12px; background: #101b16; }
.map-viewport #map { width: 1600px; height: 1000px; max-width: none; border: 0; border-radius: 0; }

/* Les outils personnels restent accessibles sans encombrer la carte. */
.side-tools { position: fixed; z-index: 100; right: .75rem; top: 42%; display: grid; gap: .65rem; transform: translateY(-50%); }
.side-tools button { display: grid; place-items: center; width: 66px; min-height: 64px; padding: .45rem; border: 2px solid #715437; border-radius: 14px; background: #172820; color: #f8f1dc; box-shadow: 0 6px 18px #0008; }
.side-tools button:hover, .side-tools button[aria-expanded="true"] { border-color: #eebc65; background: #2d4935; transform: translateX(-4px); }
.side-tools span { font-size: 1.5rem; }.side-tools small { font-size: .65rem; }
.drawer { position: fixed; z-index: 21; right: 5.8rem; top: 50%; overflow: auto; width: min(620px, calc(100vw - 8rem)); max-height: calc(100vh - 2rem); margin: 0; transform: translateY(-50%); border-color: #eebc6577; box-shadow: 0 20px 80px #000d; }
.drawer-close { position: sticky; z-index: 1; float: right; top: 0; width: 2.3rem; height: 2.3rem; border: 1px solid #ffffff33; border-radius: 50%; background: #263a2f; color: #fff; font-size: 1.4rem; }
.adventure-drawer > section { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid #ffffff18; }
.adventure-drawer .guide { display: block; padding: 1rem; margin: 1rem 0 0; }
.adventure-drawer .guide-steps { margin-top: .75rem; }
.adventure-summary h3, .adventure-summary p { margin: .25rem 0; }
.adventure-summary .map-legend { padding: .75rem 0 0; }
.monster.attacking { pointer-events: none; animation: monster-hit .18s ease-in-out infinite alternate; }
@keyframes monster-hit { to { filter: brightness(1.8) drop-shadow(0 0 12px #fff); transform: scale(.92); } }
.map-legend .legend-npc { background: #ffdc6a; box-shadow: 0 0 0 2px #714c25; }
.house b { position: absolute; left: 50%; bottom: -24px; translate: -50%; padding: 4px 7px; border: 2px solid #6c4828; border-radius: 4px; background: #f1d18b; color: #4a2c20; font: 800 10px/1 ui-monospace, monospace; white-space: nowrap; }

.npc { position: absolute; z-index: 7; display: grid; place-items: center; width: 82px; min-height: 90px; padding: 20px 4px 4px; translate: -50% -65%; border: 0; background: transparent; color: #fff5d6; filter: drop-shadow(0 5px 3px #0008); }
.npc:hover, .npc:focus-visible { scale: 1.08; }
.npc-role { position: absolute; top: 0; padding: 3px 6px; border: 2px solid #704129; border-radius: 5px; background: #f1d18b; color: #4a2c20; font: 800 9px/1 ui-monospace, monospace; }
.npc-sprite { display: grid; place-items: center; width: 44px; height: 52px; border: 3px solid #493324; border-radius: 45% 45% 9px 9px; background: linear-gradient(#efbd88 0 48%, #496f8f 48%); box-shadow: inset 0 5px #754b2e; }
.npc-sprite i { margin-top: 17px; font-style: normal; font-size: 18px; }.npc strong { font-size: 11px; text-shadow: 0 2px #000; }
.npc-dialog { border-color: #eebc65; }.npc-dialog > button:last-child { padding: .75rem 1rem; border: 2px solid #8d6636; border-radius: 8px; background: #eebc65; color: #172820; font-weight: 800; }.npc-close { position: absolute; right: 1rem; top: .5rem; border: 0; background: none; color: white; font-size: 2rem; }

@media (max-width: 760px) {
  .map-viewport { height: 62vh; min-height: 380px; }
  .map-viewport #map { width: 1200px; height: 800px; }
  .side-tools { top: 32%; right: .35rem; bottom: auto; grid-template-columns: 1fr; transform: none; }
  .side-tools button { width: 58px; min-height: 54px; }
  .side-tools button:hover, .side-tools button[aria-expanded="true"] { transform: translateX(-4px); }
  .drawer { right: 4.2rem; top: .5rem; bottom: .5rem; width: calc(100vw - 1rem); max-height: none; transform: none; }
}

/* Positions de jeu prédéfinies : aucune propriété style intégrée n’est nécessaire. */
.pos-x-0 { left: 0%; } .pos-y-0 { top: 0%; } .percent-0 { width: 0%; }
.pos-x-1 { left: 1%; } .pos-y-1 { top: 1%; } .percent-1 { width: 1%; }
.pos-x-2 { left: 2%; } .pos-y-2 { top: 2%; } .percent-2 { width: 2%; }
.pos-x-3 { left: 3%; } .pos-y-3 { top: 3%; } .percent-3 { width: 3%; }
.pos-x-4 { left: 4%; } .pos-y-4 { top: 4%; } .percent-4 { width: 4%; }
.pos-x-5 { left: 5%; } .pos-y-5 { top: 5%; } .percent-5 { width: 5%; }
.pos-x-6 { left: 6%; } .pos-y-6 { top: 6%; } .percent-6 { width: 6%; }
.pos-x-7 { left: 7%; } .pos-y-7 { top: 7%; } .percent-7 { width: 7%; }
.pos-x-8 { left: 8%; } .pos-y-8 { top: 8%; } .percent-8 { width: 8%; }
.pos-x-9 { left: 9%; } .pos-y-9 { top: 9%; } .percent-9 { width: 9%; }
.pos-x-10 { left: 10%; } .pos-y-10 { top: 10%; } .percent-10 { width: 10%; }
.pos-x-11 { left: 11%; } .pos-y-11 { top: 11%; } .percent-11 { width: 11%; }
.pos-x-12 { left: 12%; } .pos-y-12 { top: 12%; } .percent-12 { width: 12%; }
.pos-x-13 { left: 13%; } .pos-y-13 { top: 13%; } .percent-13 { width: 13%; }
.pos-x-14 { left: 14%; } .pos-y-14 { top: 14%; } .percent-14 { width: 14%; }
.pos-x-15 { left: 15%; } .pos-y-15 { top: 15%; } .percent-15 { width: 15%; }
.pos-x-16 { left: 16%; } .pos-y-16 { top: 16%; } .percent-16 { width: 16%; }
.pos-x-17 { left: 17%; } .pos-y-17 { top: 17%; } .percent-17 { width: 17%; }
.pos-x-18 { left: 18%; } .pos-y-18 { top: 18%; } .percent-18 { width: 18%; }
.pos-x-19 { left: 19%; } .pos-y-19 { top: 19%; } .percent-19 { width: 19%; }
.pos-x-20 { left: 20%; } .pos-y-20 { top: 20%; } .percent-20 { width: 20%; }
.pos-x-21 { left: 21%; } .pos-y-21 { top: 21%; } .percent-21 { width: 21%; }
.pos-x-22 { left: 22%; } .pos-y-22 { top: 22%; } .percent-22 { width: 22%; }
.pos-x-23 { left: 23%; } .pos-y-23 { top: 23%; } .percent-23 { width: 23%; }
.pos-x-24 { left: 24%; } .pos-y-24 { top: 24%; } .percent-24 { width: 24%; }
.pos-x-25 { left: 25%; } .pos-y-25 { top: 25%; } .percent-25 { width: 25%; }
.pos-x-26 { left: 26%; } .pos-y-26 { top: 26%; } .percent-26 { width: 26%; }
.pos-x-27 { left: 27%; } .pos-y-27 { top: 27%; } .percent-27 { width: 27%; }
.pos-x-28 { left: 28%; } .pos-y-28 { top: 28%; } .percent-28 { width: 28%; }
.pos-x-29 { left: 29%; } .pos-y-29 { top: 29%; } .percent-29 { width: 29%; }
.pos-x-30 { left: 30%; } .pos-y-30 { top: 30%; } .percent-30 { width: 30%; }
.pos-x-31 { left: 31%; } .pos-y-31 { top: 31%; } .percent-31 { width: 31%; }
.pos-x-32 { left: 32%; } .pos-y-32 { top: 32%; } .percent-32 { width: 32%; }
.pos-x-33 { left: 33%; } .pos-y-33 { top: 33%; } .percent-33 { width: 33%; }
.pos-x-34 { left: 34%; } .pos-y-34 { top: 34%; } .percent-34 { width: 34%; }
.pos-x-35 { left: 35%; } .pos-y-35 { top: 35%; } .percent-35 { width: 35%; }
.pos-x-36 { left: 36%; } .pos-y-36 { top: 36%; } .percent-36 { width: 36%; }
.pos-x-37 { left: 37%; } .pos-y-37 { top: 37%; } .percent-37 { width: 37%; }
.pos-x-38 { left: 38%; } .pos-y-38 { top: 38%; } .percent-38 { width: 38%; }
.pos-x-39 { left: 39%; } .pos-y-39 { top: 39%; } .percent-39 { width: 39%; }
.pos-x-40 { left: 40%; } .pos-y-40 { top: 40%; } .percent-40 { width: 40%; }
.pos-x-41 { left: 41%; } .pos-y-41 { top: 41%; } .percent-41 { width: 41%; }
.pos-x-42 { left: 42%; } .pos-y-42 { top: 42%; } .percent-42 { width: 42%; }
.pos-x-43 { left: 43%; } .pos-y-43 { top: 43%; } .percent-43 { width: 43%; }
.pos-x-44 { left: 44%; } .pos-y-44 { top: 44%; } .percent-44 { width: 44%; }
.pos-x-45 { left: 45%; } .pos-y-45 { top: 45%; } .percent-45 { width: 45%; }
.pos-x-46 { left: 46%; } .pos-y-46 { top: 46%; } .percent-46 { width: 46%; }
.pos-x-47 { left: 47%; } .pos-y-47 { top: 47%; } .percent-47 { width: 47%; }
.pos-x-48 { left: 48%; } .pos-y-48 { top: 48%; } .percent-48 { width: 48%; }
.pos-x-49 { left: 49%; } .pos-y-49 { top: 49%; } .percent-49 { width: 49%; }
.pos-x-50 { left: 50%; } .pos-y-50 { top: 50%; } .percent-50 { width: 50%; }
.pos-x-51 { left: 51%; } .pos-y-51 { top: 51%; } .percent-51 { width: 51%; }
.pos-x-52 { left: 52%; } .pos-y-52 { top: 52%; } .percent-52 { width: 52%; }
.pos-x-53 { left: 53%; } .pos-y-53 { top: 53%; } .percent-53 { width: 53%; }
.pos-x-54 { left: 54%; } .pos-y-54 { top: 54%; } .percent-54 { width: 54%; }
.pos-x-55 { left: 55%; } .pos-y-55 { top: 55%; } .percent-55 { width: 55%; }
.pos-x-56 { left: 56%; } .pos-y-56 { top: 56%; } .percent-56 { width: 56%; }
.pos-x-57 { left: 57%; } .pos-y-57 { top: 57%; } .percent-57 { width: 57%; }
.pos-x-58 { left: 58%; } .pos-y-58 { top: 58%; } .percent-58 { width: 58%; }
.pos-x-59 { left: 59%; } .pos-y-59 { top: 59%; } .percent-59 { width: 59%; }
.pos-x-60 { left: 60%; } .pos-y-60 { top: 60%; } .percent-60 { width: 60%; }
.pos-x-61 { left: 61%; } .pos-y-61 { top: 61%; } .percent-61 { width: 61%; }
.pos-x-62 { left: 62%; } .pos-y-62 { top: 62%; } .percent-62 { width: 62%; }
.pos-x-63 { left: 63%; } .pos-y-63 { top: 63%; } .percent-63 { width: 63%; }
.pos-x-64 { left: 64%; } .pos-y-64 { top: 64%; } .percent-64 { width: 64%; }
.pos-x-65 { left: 65%; } .pos-y-65 { top: 65%; } .percent-65 { width: 65%; }
.pos-x-66 { left: 66%; } .pos-y-66 { top: 66%; } .percent-66 { width: 66%; }
.pos-x-67 { left: 67%; } .pos-y-67 { top: 67%; } .percent-67 { width: 67%; }
.pos-x-68 { left: 68%; } .pos-y-68 { top: 68%; } .percent-68 { width: 68%; }
.pos-x-69 { left: 69%; } .pos-y-69 { top: 69%; } .percent-69 { width: 69%; }
.pos-x-70 { left: 70%; } .pos-y-70 { top: 70%; } .percent-70 { width: 70%; }
.pos-x-71 { left: 71%; } .pos-y-71 { top: 71%; } .percent-71 { width: 71%; }
.pos-x-72 { left: 72%; } .pos-y-72 { top: 72%; } .percent-72 { width: 72%; }
.pos-x-73 { left: 73%; } .pos-y-73 { top: 73%; } .percent-73 { width: 73%; }
.pos-x-74 { left: 74%; } .pos-y-74 { top: 74%; } .percent-74 { width: 74%; }
.pos-x-75 { left: 75%; } .pos-y-75 { top: 75%; } .percent-75 { width: 75%; }
.pos-x-76 { left: 76%; } .pos-y-76 { top: 76%; } .percent-76 { width: 76%; }
.pos-x-77 { left: 77%; } .pos-y-77 { top: 77%; } .percent-77 { width: 77%; }
.pos-x-78 { left: 78%; } .pos-y-78 { top: 78%; } .percent-78 { width: 78%; }
.pos-x-79 { left: 79%; } .pos-y-79 { top: 79%; } .percent-79 { width: 79%; }
.pos-x-80 { left: 80%; } .pos-y-80 { top: 80%; } .percent-80 { width: 80%; }
.pos-x-81 { left: 81%; } .pos-y-81 { top: 81%; } .percent-81 { width: 81%; }
.pos-x-82 { left: 82%; } .pos-y-82 { top: 82%; } .percent-82 { width: 82%; }
.pos-x-83 { left: 83%; } .pos-y-83 { top: 83%; } .percent-83 { width: 83%; }
.pos-x-84 { left: 84%; } .pos-y-84 { top: 84%; } .percent-84 { width: 84%; }
.pos-x-85 { left: 85%; } .pos-y-85 { top: 85%; } .percent-85 { width: 85%; }
.pos-x-86 { left: 86%; } .pos-y-86 { top: 86%; } .percent-86 { width: 86%; }
.pos-x-87 { left: 87%; } .pos-y-87 { top: 87%; } .percent-87 { width: 87%; }
.pos-x-88 { left: 88%; } .pos-y-88 { top: 88%; } .percent-88 { width: 88%; }
.pos-x-89 { left: 89%; } .pos-y-89 { top: 89%; } .percent-89 { width: 89%; }
.pos-x-90 { left: 90%; } .pos-y-90 { top: 90%; } .percent-90 { width: 90%; }
.pos-x-91 { left: 91%; } .pos-y-91 { top: 91%; } .percent-91 { width: 91%; }
.pos-x-92 { left: 92%; } .pos-y-92 { top: 92%; } .percent-92 { width: 92%; }
.pos-x-93 { left: 93%; } .pos-y-93 { top: 93%; } .percent-93 { width: 93%; }
.pos-x-94 { left: 94%; } .pos-y-94 { top: 94%; } .percent-94 { width: 94%; }
.pos-x-95 { left: 95%; } .pos-y-95 { top: 95%; } .percent-95 { width: 95%; }
.pos-x-96 { left: 96%; } .pos-y-96 { top: 96%; } .percent-96 { width: 96%; }
.pos-x-97 { left: 97%; } .pos-y-97 { top: 97%; } .percent-97 { width: 97%; }
.pos-x-98 { left: 98%; } .pos-y-98 { top: 98%; } .percent-98 { width: 98%; }
.pos-x-99 { left: 99%; } .pos-y-99 { top: 99%; } .percent-99 { width: 99%; }
.pos-x-100 { left: 100%; } .pos-y-100 { top: 100%; } .percent-100 { width: 100%; }

/* Interface immersive : le monde devient la page, les systèmes deviennent le HUD. */
body.game-active { overflow: hidden; background: #101b16; }
body.game-active > header, body.game-active > footer { display: none; }
body.game-active main { width: 100vw; max-width: none; height: 100dvh; margin: 0; padding: 0; }
.game-shell { position: fixed; isolation: isolate; inset: 0; overflow: hidden; background: #101b16; }
.world-layer { position: absolute; z-index: 0; inset: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: #101b16; }
.game-shell .map-viewport { width: 100%; height: 100%; min-height: 0; border: 0; border-radius: 0; }
.game-shell .map-viewport #map { width: max(1600px, 145vw); height: max(1000px, 145vh); }
.player-hud { position: fixed; z-index: 30; left: 1rem; top: 1rem; width: min(330px, calc(100vw - 7rem)); padding: .8rem 1rem; border: 2px solid #715437; border-radius: 14px; background: #172820ed; box-shadow: 0 8px 30px #0009; pointer-events: none; }
.player-hud p { margin: .2rem 0; }.player-hud strong { display: block; font: 700 1.15rem Georgia, serif; }
.player-hud .progress-card { grid-template-columns: auto 1fr; justify-content: stretch; margin: .55rem 0; }.player-hud .progress-card small { grid-column: 1 / -1; }.player-hud .health { margin: .35rem 0 0; }
.zone-hud { position: fixed; z-index: 25; left: 50%; bottom: 1rem; display: grid; grid-template-columns: 220px minmax(430px, 620px); align-items: end; gap: .8rem; width: min(900px, calc(100vw - 10rem)); translate: -50%; pointer-events: none; }
.zone-hud > div { padding: .7rem 1rem; border: 2px solid #715437; border-radius: 12px; background: #172820ed; box-shadow: 0 7px 25px #0008; }.zone-hud h1, .zone-hud p { margin: .15rem 0; }.zone-hud h1 { font: 700 1.25rem Georgia, serif; }.zone-hud #zoneDescription { color: #b9c9b8; font-size: .75rem; }
.zone-hud .zone-nav { grid-template-columns: repeat(3, 1fr); margin: 0; pointer-events: auto; }.zone-hud .zone-nav button { min-height: 62px; padding: .55rem; box-shadow: 0 3px #09100c; }.zone-hud .zone-nav small { display: none; }
.hud-guide { position: fixed; z-index: 20; top: 1rem; left: 50%; display: block; width: min(440px, 40vw); max-height: 120px; margin: 0; padding: .75rem 1rem; translate: -50%; overflow: hidden; pointer-events: none; }.hud-guide h2 { font-size: 1rem; }.hud-guide p:last-child { font-size: .72rem; }.hud-guide .guide-steps { display: none; }
.game-shell > .map-legend { position: fixed; z-index: 15; left: 1rem; bottom: 1rem; max-width: 240px; padding: .55rem .7rem; border-radius: 8px; background: #172820d9; pointer-events: none; }
.game-shell .side-tools { top: 50%; }
.game-shell .drawer { z-index: 110; background: #172820f7; backdrop-filter: blur(8px); }
.adventure-drawer > section { margin: 1rem 0; padding-top: .7rem; border-top: 1px solid #ffffff1c; }.adventure-drawer .players { grid-template-columns: repeat(2, 1fr); }
.game-shell .modal { z-index: 120; }

@media (max-width: 900px) {
  .hud-guide { top: auto; right: 5rem; bottom: 8rem; left: auto; width: min(360px, calc(100vw - 6rem)); max-height: 92px; translate: none; }
  .zone-hud { left: .6rem; right: 4.7rem; bottom: .6rem; display: block; width: auto; translate: none; }.zone-hud > div { display: none; }.zone-hud .zone-nav { gap: .35rem; }.zone-hud .zone-nav button { min-height: 54px; padding: .4rem; font-size: .7rem; }
  .game-shell > .map-legend { display: none; }
}
@media (max-width: 560px) {
  .player-hud { left: .5rem; top: .5rem; width: calc(100vw - 4.7rem); padding: .55rem .7rem; }.player-hud .eyebrow { font-size: .6rem; }.player-hud .progress-card { font-size: .68rem; }
  .hud-guide { display: none; }
  .game-shell .side-tools { top: 44%; }
  .game-shell .drawer { right: 4.2rem; width: calc(100vw - 4.7rem); }
  .adventure-drawer .players, .questionnaire form, .account-actions { grid-template-columns: 1fr; }
  .game-shell .map-viewport #map { width: 1200px; height: 900px; }
}

/* Ambiances vivantes et retour visuel de l'équipement. */
#map::before { content: ''; position: absolute; z-index: 2; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 48%, transparent 42%, #10261a38 100%); mix-blend-mode: multiply; }
.zone-forest::before { background: radial-gradient(circle at 20% 15%, #ddff9c24 0 8%, transparent 18%), radial-gradient(circle at 72% 60%, transparent 35%, #102b1a66 100%) !important; }
.river { animation: water-flow 2.4s linear infinite; }
.zone-deep-forest .zone-decor { animation: crystal-glow 2.8s ease-in-out infinite alternate; }

@keyframes water-flow { to { background-position-y: 44px; } }
@keyframes crystal-glow { to { filter: brightness(1.25) drop-shadow(0 0 18px #65ddea); } }

@media (prefers-reduced-motion: reduce) {
  .pawn, .progress-track i { transition-duration: .01ms; }
  .pawn.is-moving .character, .river, .zone-deep-forest .zone-decor, .monster.attacking, .monster.enraged, .slime-projectile, .slime-jump-warning, .slime-impact { animation: none !important; }
  /* Keep direction/state feedback, but remove the decorative breathing and
     repeated limb cycle. The pawn position remains server-driven. */
  .character-sprite.state-idle, .character-sprite.state-settling { animation: none !important; background-position-x: 0 !important; }
  .character-sprite.state-walking { animation: none !important; background-position-x: -408px !important; }
  html { scroll-behavior: auto; }
}

/* Bâtiments visitables : dimensions alignées sur les collisions serveur. */
.house-left { left: 4%; top: 9%; width: 17%; height: 29%; transform: none; }
.house-right { right: 2%; bottom: 4%; width: 16%; height: 30%; transform: none; }

.inn { left: 6%; top: 24%; width: 16%; height: 18%; }
.forge { left: 73%; top: 20%; width: 16%; height: 19%; }
.academy { left: 14%; top: 45%; width: 16%; height: 17%; }
.shop { left: 73%; top: 64%; width: 15%; height: 15%; }
.bank { left: 56%; top: 80%; width: 16%; height: 15%; }
.market { left: 5%; top: 68%; width: 19%; height: 26%; }
.house { background-image: repeating-linear-gradient(90deg, #0000000b 0 2px, transparent 2px 28px); transition: filter .25s, opacity .25s; }
.house span { left: 44%; }.house-right span { top: 0; bottom: auto; }
.house.interior-open { z-index: 0; background-color: #7b5b3d; background-image: repeating-linear-gradient(90deg, #8d6947 0 22px, #79583c 22px 26px); box-shadow: inset 0 0 0 8px #4b3425, inset 0 20px 35px #0005; }
.house.interior-open::before { opacity: .12; }
.house.interior-open span { opacity: .2; }
/* Mairie / Guilde JRPG : silhouette plus riche, sans modifier son emprise 40–60 / 5–21. */

/* Les PNG remplacent entièrement le décor CSS, mais restent ancrés sur l'entrée logique. */

/* Les créatures et avatars vivent directement dans le monde, sans carte opaque. */
.monster { width: 112px; height: 104px; padding: 25px 8px 13px; background: transparent; border-radius: 0; box-shadow: none; filter: drop-shadow(0 9px 4px #10231799); transition: left 1.5s linear, top 1.5s linear, filter .2s; }
.monster-name { top: -3px; padding: 3px 7px; border: 1px solid #ffffff2b; border-radius: 999px; background: #172820c9; }
.monster-hp { left: 17px; right: 17px; bottom: 5px; }
.monster > small { bottom: -8px; text-shadow: 0 2px 2px #000; }
.monster-sprite { width: 66px; height: 52px; image-rendering: pixelated; }
.slime { scale: var(--slime-scale, 1); transform-origin: 50% 80%; }
.slime .monster-sprite { border-radius: 58% 58% 42% 42%; border-color: #245b38; background: radial-gradient(circle at 37% 35%, #e8ffd9 0 4px, transparent 5px), linear-gradient(#8ee968, #3aa855); box-shadow: inset 0 -10px #278949, 0 8px 0 -5px #193e2b; }
.slime .monster-sprite::before { top: 21px; background: #123520; box-shadow: 23px 0 #123520; }
.slime .monster-sprite::after { border-color: #123520; }
.monster-deep-slime .monster-sprite { border-color: #293c4e; background: radial-gradient(circle at 37% 35%, #dcfff2 0 4px, transparent 5px), linear-gradient(#6bcfa2, #386c83); box-shadow: inset 0 -10px #315872, 0 8px 0 -5px #172d35; }
.monster-forest-slime.skin-amber .monster-sprite { background: linear-gradient(#f0cf62, #bb793b); }.monster-deep-slime.skin-toxic .monster-sprite { background: linear-gradient(#c4ef55, #488c3a); }
.slime-size-0 { --slime-scale: .72; }.slime-size-1 { --slime-scale: .82; }.slime-size-2 { --slime-scale: .92; }.slime-size-3 { --slime-scale: 1.02; }.slime-size-4 { --slime-scale: 1.12; }.slime-size-5 { --slime-scale: 1.22; }.slime-size-6 { --slime-scale: 1.32; }.slime-size-7 { --slime-scale: 1.42; }.slime-size-8 { --slime-scale: 1.52; }.slime-size-9 { --slime-scale: 1.62; }.slime-size-10 { --slime-scale: 1.72; }
.slime.state-jump_prepare .monster-sprite { animation: slime-charge .35s ease-in-out infinite alternate; filter: brightness(1.35); }.slime.state-jump { opacity: .75; translate: -50% -85%; }
#mapEffects { position: absolute; z-index: 7; inset: 0; pointer-events: none; }.slime-projectile, .slime-jump-warning, .slime-impact { position: absolute; display: block; translate: -50% -50%; }
.slime-projectile { width: 15px; height: 15px; border-radius: 50%; background: #95ffb4; box-shadow: 0 0 12px #53e68c; transition: left 1.5s linear, top 1.5s linear; animation: slime-spit .45s linear infinite; }
.slime-jump-warning, .slime-impact { width: 70px; height: 35px; border: 4px solid #ffe66d; border-radius: 50%; background: #ffdf5422; animation: slime-warning .45s ease-in-out infinite alternate; }.slime-impact { border-color: #79ff99; background: #63ff843d; animation: slime-impact .5s ease-out both; }
@keyframes slime-charge { to { transform: scaleX(1.2) scaleY(.75); } } @keyframes slime-spit { to { rotate: 360deg; } } @keyframes slime-warning { to { scale: 1.25; opacity: .45; } } @keyframes slime-impact { to { scale: 1.8; opacity: 0; } }
.monster-rank { position: absolute; z-index: 2; top: 16px; left: 50%; translate: -50% -100%; padding: 2px 6px; border: 1px solid #ffe790; border-radius: 999px; background: #5e3616e8; color: #fff1a6; font: 900 8px/1.2 ui-monospace, monospace; letter-spacing: .12em; text-transform: uppercase; box-shadow: 0 0 10px #ffc84d77; }
.monster-elite { filter: drop-shadow(0 9px 4px #10231799) drop-shadow(0 0 9px #ffca55aa); }
.monster-elite .monster-sprite { border-color: #e5b94d; }
.monster-elite .monster-sprite > i { position: absolute; z-index: -1; left: 50%; top: -18px; width: 36px; height: 20px; translate: -50%; background: #f4c84d; clip-path: polygon(0 100%, 5% 20%, 30% 62%, 50% 0, 70% 62%, 95% 20%, 100% 100%); filter: drop-shadow(0 2px #6c421a); }
.monster.enraged:not(.dead) { animation: monster-rage .32s ease-in-out infinite alternate; }
.monster.enraged .monster-hp i { background: #ff3737; box-shadow: 0 0 8px #ff3737; }
.monster.enraged > small { color: #ffb2a8; font-weight: 900; text-transform: uppercase; }
@keyframes monster-rage { to { filter: brightness(1.2) drop-shadow(0 9px 4px #10231799) drop-shadow(0 0 14px #ff493d); transform: translateY(-2px) rotate(1deg); } }
.pawn { width: 54px; height: 70px; filter: drop-shadow(0 8px 3px #10231799); transition: left .18s linear, top .18s linear, transform .15s; will-change: left, top; }

/* Particules d'ambiance légères pour les plans promotionnels. */
.ambient-particles { position: absolute; z-index: 3; inset: 0; overflow: hidden; pointer-events: none; }
.ambient-particles i { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: #fff2a1; box-shadow: 0 0 10px #ffe06a; opacity: .55; animation: ambient-drift 7s ease-in-out infinite alternate; }
.ambient-particles i:nth-child(1) { left: 12%; top: 28%; }.ambient-particles i:nth-child(2) { left: 28%; top: 72%; animation-delay: -2s; }.ambient-particles i:nth-child(3) { left: 46%; top: 38%; animation-delay: -4s; }.ambient-particles i:nth-child(4) { left: 65%; top: 78%; animation-delay: -1s; }.ambient-particles i:nth-child(5) { left: 79%; top: 22%; animation-delay: -5s; }.ambient-particles i:nth-child(6) { left: 91%; top: 61%; animation-delay: -3s; }
.zone-deep-forest .ambient-particles i { background: #bfffd3; box-shadow: 0 0 14px #65de91; }.zone-forest .ambient-particles i { background: #dfff87; box-shadow: 0 0 12px #a8e85d; }
@keyframes ambient-drift { from { translate: -8px 8px; scale: .7; opacity: .2; } to { translate: 14px -22px; scale: 1.3; opacity: .8; } }

/* Mode de capture : H masque le HUD sans interrompre le monde. */

@media (prefers-reduced-motion: reduce) { .ambient-particles i { animation: none; } }

/* Village central : quelques grandes couches normalisées remplacent l'ancien croisement. */
#villageScene, #villageScene > div, #villageScene i { position: absolute; pointer-events: none; }
#villageScene, .village-terrain, .village-grass { inset: 0; }
.zone-forest #villageScene, .zone-cave #villageScene { display: none; }
.zone-village { background: #62a94f !important; background-image: none !important; }
.village-grass { z-index: -5; background-color: #63aa50; background-image: radial-gradient(circle, #a7d767 0 2px, transparent 3px), radial-gradient(circle, #397f3d 0 2px, transparent 3px), linear-gradient(115deg, #ffffff0b, transparent 45%); background-position: 8px 12px, 42px 36px, 0 0; background-size: 54px 48px, 67px 61px, 100% 100%; box-shadow: inset 0 0 90px #285d2a66; }
.village-plaza { z-index: -3; left: 29%; top: 31%; width: 43%; height: 45%; border: 5px solid #cfaa68; border-radius: 46% 50% 44% 48%; background-color: #ddc081; background-image: radial-gradient(circle at 25% 30%, #efd69d 0 2px, transparent 3px), linear-gradient(25deg, transparent 47%, #c9a76b55 48% 51%, transparent 52%); background-size: 39px 35px, 28px 24px; box-shadow: inset 0 0 0 5px #efd79b88, 0 3px 8px #335d2c66; }
.village-roads { inset: 0; z-index: -2; }
.scene-road { height: 7%; border: 4px solid #c39c61; border-radius: 999px; background-color: #ddbd7d; background-image: radial-gradient(ellipse, #efd59c 0 2px, transparent 3px); background-size: 25px 19px; box-shadow: inset 0 0 0 3px #f1d49a66; transform-origin: center; }
.scene-road-hall { left: 46%; top: 18%; width: 8%; height: 18%; }
.scene-road-inn { left: 19%; top: 34%; width: 18%; transform: rotate(7deg); }
.scene-road-forge { left: 65%; top: 34%; width: 17%; transform: rotate(-7deg); }
.scene-road-academy { left: 23%; top: 50%; width: 14%; transform: rotate(-4deg); }
.scene-road-shop { left: 67%; top: 61%; width: 14%; transform: rotate(6deg); }
.scene-road-bank { left: 61%; top: 72%; width: 7%; height: 13%; transform: rotate(-12deg); }
.scene-road-market { left: 20%; top: 71%; width: 19%; transform: rotate(-8deg); }
.scene-road-bridge { left: 69%; top: 57%; width: 25%; transform: rotate(-2deg); }
.scene-road-west-recess { left: 4%; top: 53%; width: 29%; transform: rotate(3deg); }
.village-water { inset: 0; z-index: -1; }
.village-water .river { display: block; position: absolute; inset: 0 2% 0 auto; width: 6%; border-inline: 5px solid #8ea85a; background: repeating-linear-gradient(0deg, #42a9ca 0 8px, #70d1df 8px 14px, #328faf 14px 22px); box-shadow: 0 0 0 4px #426f38; }
.village-water .bridge { display: block; position: absolute; right: 1%; top: 54%; width: 10%; height: 14%; border: 5px solid #665041; border-radius: 35% 35% 8px 8px; background: repeating-linear-gradient(90deg, #a46c42 0 13px, #d09a60 13px 25px); box-shadow: inset 0 5px #e0b77c, 0 5px #3c2d25; }
.village-west-recess { z-index: -1; left: 0; top: 45%; width: 12%; height: 21%; border-radius: 0 48% 48% 0; background: #75b65a; box-shadow: inset -7px 0 #43833e; }
.village-vegetation { inset: 0; z-index: 1; }
.scene-vegetation { width: 12%; height: 8%; border-radius: 50%; background: radial-gradient(circle at 12% 50%, #8ed05d 0 9%, #347a39 10% 19%, transparent 20%), radial-gradient(circle at 44% 45%, #69b64a 0 12%, #286733 13% 24%, transparent 25%), radial-gradient(circle at 78% 55%, #98d864 0 10%, #397d3a 11% 22%, transparent 23%); filter: drop-shadow(0 4px 2px #234d2b66); }
.scene-vegetation-north-west { left: 1%; top: 2%; }.scene-vegetation-north { left: 25%; top: 1%; }.scene-vegetation-north-east { right: 10%; top: 2%; }.scene-vegetation-west { left: 0; top: 28%; }.scene-vegetation-south-west { left: 25%; bottom: 0; }.scene-vegetation-south { left: 44%; bottom: 0; }.scene-vegetation-south-east { right: 10%; bottom: 0; }.scene-vegetation-riverbank { right: 5%; top: 38%; transform: rotate(90deg); }
.scene-flower-bed { width: 70px; height: 34px; border: 3px solid #3f762f; border-radius: 50%; background-color: #4d913c; background-image: radial-gradient(circle, #ffe77a 0 3px, #e95970 4px 6px, transparent 7px), radial-gradient(circle, #fff4b2 0 3px, #8e69cf 4px 6px, transparent 7px); background-position: 5px 4px, 24px 18px; background-size: 38px 30px; box-shadow: inset 0 -5px #326a2d88, 0 4px 4px #244e2866; }
.scene-flower-bed-plaza-west { left: 27%; top: 43%; transform: rotate(-12deg); }
.scene-flower-bed-plaza-east { left: 72%; top: 48%; transform: rotate(13deg); }
.scene-flower-bed-riverbank { right: 7%; top: 73%; transform: rotate(78deg); }
.village-furniture { inset: 0; z-index: 2; }
.scene-furniture { width: 38px; height: 13px; border: 3px solid #503721; border-radius: 4px; background: repeating-linear-gradient(0deg,#a96e39 0 4px,#744829 4px 7px); box-shadow: 0 5px #31502d; }
.scene-furniture-bench-nw { left: 35%; top: 37%; }.scene-furniture-bench-ne { left: 63%; top: 37%; }.scene-furniture-bench-sw { left: 35%; top: 68%; }.scene-furniture-bench-se { left: 63%; top: 68%; }
.scene-furniture[class*="lamp"] { width: 9px; height: 42px; border: 0; border-radius: 5px; background: linear-gradient(90deg,#352a24,#80603c,#352a24); box-shadow: 0 0 10px #ffd873; }
.scene-furniture[class*="lamp"]::before { content: ''; position: absolute; left: -7px; top: -12px; width: 17px; height: 19px; border: 3px solid #49351f; background: #ffd56b; clip-path: polygon(20% 0,80% 0,100% 75%,50% 100%,0 75%); }
.scene-furniture-lamp-nw { left: 38%; top: 39%; }.scene-furniture-lamp-ne { left: 62%; top: 39%; }.scene-furniture-lamp-sw { left: 38%; top: 66%; }.scene-furniture-lamp-se { left: 62%; top: 66%; }
.scene-furniture-quest-board { left: 69%; top: 45%; width: 45px; height: 32px; border: 5px solid #684526; background: #c88b4c; box-shadow: 0 10px #593a23; }
.portal-hub { position: absolute; z-index: 6; left: 2%; top: 55%; }
.portal-hub .portal-gate { position: relative; inset: auto; translate: 0 -50%; }
.portal-choices { position: absolute; left: 82px; top: -58px; display: grid; gap: 6px; width: 130px; padding: 8px; border: 2px solid #dfc4ff; border-radius: 10px; background: #17281ff0; box-shadow: 0 8px 20px #10231799; }
.portal-choices[hidden] { display: none; }
.portal-choices button { padding: 7px; border: 1px solid #ba8cff; border-radius: 7px; background: #3a2456; color: #fff; }

/* Le Village gagne de l'espace physique sans agrandir ses sprites ni ses bâtiments. */
.game-shell .map-viewport #map.zone-village { width: 2000px; height: 1400px; }
.zone-village { --building-x-scale: .8; --building-y-scale: .714286; }

@media (max-width: 900px) {
  .game-shell .map-viewport #map.zone-village { width: 1600px; height: 1120px; }
  .zone-village { --building-x-scale: 1; --building-y-scale: .892857; }
}
@media (max-width: 560px) {
  .game-shell .map-viewport #map.zone-village { width: 1400px; height: 980px; }
  .zone-village { --building-x-scale: .857143; --building-y-scale: .918367; }
}

/* Échelle native du monde, calibrée séparément du HUD et de la caméra. */
.zone-village .pawn { width: 46px; height: 60px; }
.zone-village .character-renderer { scale: .68; transform-origin: 50% 100%; }

.zone-village .scene-furniture { width: 36px; height: 12px; }
.zone-village .scene-furniture[class*="lamp"] { width: 8px; height: 39px; }
.zone-village .scene-furniture-quest-board { width: 42px; height: 30px; }
.zone-village .portal { width: 72px; min-height: 78px; }

/* Map transfers place the player immediately before the camera measures it. */
#map .pawn.self.camera-arrival { transition: none !important; }

/* The central square label belongs to the village, not combat maps. */
#map:not(.zone-village) .map-hint { display: none; }

/* Match local interpolation to acknowledged movement on slower connections. */
#map .pawn.self { left: clamp(34px, var(--actor-left, 50%), calc(100% - 34px)) !important; top: clamp(62px, var(--actor-top, 50%), 100%) !important; }
#map .pawn { transition: none; }
/* Keep essential locomotion continuous in every accessibility mode. Decorative
   motion and the character's pose cycle can still be reduced independently. */

/* Pages dédiées accessibles sous le portrait. */
.player-hud .hud-profile { min-width: 0; }
.player-hud .hud-shortcuts { display: flex; justify-content: center; gap: 3px; margin-top: 7px; pointer-events: auto; }
.player-hud .hud-shortcuts button { display: grid; place-items: center; flex: 0 0 26px; width: 26px; height: 30px; padding: 3px; border: 1px solid #ac9764; border-radius: 6px; background: #14281f; color: #efd18e; }
.hud-shortcuts svg { width: 19px; height: 19px; }
.player-hud .hud-shortcuts button:hover { background: #35533d; border-color: #ffe7ac; }
.hud-shortcuts button:focus-visible, .hub-page button:focus-visible { outline: 2px solid #ffe7ac; outline-offset: 3px; }
.hub-page { position: fixed; inset: 0; width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; border: 0; color: #f7edd3; background: radial-gradient(ellipse at 85% 0%, #38544488, transparent 55%), #101f19; overflow-y: auto; overscroll-behavior: contain; }
.hub-page::backdrop { background: #101f19; }
.hub-inner { max-width: 1100px; margin: auto; padding: 28px clamp(18px, 5vw, 70px) 40px; }
.hub-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 52px; }
.hub-header span { color: #d4b574; font: 700 14px Georgia, serif; letter-spacing: .18em; }
.hub-page button { border: 1px solid #917a4c; border-radius: 7px; background: #20382c; color: #f2dcab; padding: 12px 18px; min-height: 44px; }
.hub-page button:disabled { opacity: .65; cursor: default; }
.hub-page h1 { color: #f5e4bb; font: 500 clamp(32px, 6vw, 54px)/1.1 Georgia, serif; margin: 12px 0; }
.hub-page h2, .hub-page h3 { color: #f5e4bb; font-family: Georgia, serif; }
.hub-eyebrow { color: #c9ab70; font-size: 11px; letter-spacing: .18em; }
.hub-lead, .hub-page p { line-height: 1.6; }
.hub-lead, .hub-card p, .hub-feature p, .hub-note { color: #b9cabc; }
.hub-tabs { display: flex; gap: 10px; margin: 30px 0 24px; }
.hub-tabs [aria-selected="true"] { background: #cfb273; color: #14281f; border-color: #eed79d; }
.hub-feature { padding: clamp(20px, 4vw, 36px); border: 1px solid #8e794a80; border-radius: 14px; background: linear-gradient(120deg, #2b4738, #162b22); margin: 24px 0; }
.hub-status { display: inline-block; padding: 4px 9px; border: 1px solid #b49b6266; border-radius: 20px; color: #e0c385; font-size: 12px; }
.hub-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 30px; }
.hub-card { display: flex; flex-direction: column; align-items: start; border: 1px solid #697c555e; border-radius: 14px; padding: 24px; background: #1c3228; }
.hub-card-art { display: grid; place-items: center; width: 100%; height: 110px; margin-bottom: 20px; color: #dfc486; font-size: 64px; background: radial-gradient(ellipse, #b8a36325, transparent 70%); }
.hub-card h3 { margin-bottom: 0; }
.hub-card p { flex: 1; }
.hub-card button { width: 100%; font-size: 12px; }
.hub-footer { margin-top: 40px; border-top: 1px solid #b49b6230; padding-top: 20px; color: #a3b5a7; font-size: 12px; }
@media (max-width: 600px) { .hub-grid { grid-template-columns: 1fr; } .hub-header { margin-bottom: 32px; } .hub-header span { font-size: 10px; letter-spacing: .08em; } .hub-card-art { height: 70px; } .player-hud .hud-shortcuts { gap: 1px; } .player-hud .hud-shortcuts button { flex-basis: 24px; width: 24px; height: 28px; } }
.player-hud:has(.hud-profile) { grid-template-columns: 84px minmax(0, 1fr); }
.hud-profile .hud-portrait { width: 72px; margin-inline: auto; }
@media (max-width: 600px) { .player-hud:has(.hud-profile) { grid-template-columns: 76px minmax(0, 1fr); } .hud-profile .hud-portrait { width: 54px; } }

/* Wandering mystery uses the existing shadow artwork, independently of players. */
#map .mystery-actor { position: absolute; width: 48px; height: 62px; padding: 0; border: 0; border-radius: 0; background: transparent; transform: translate(-50%, -100%); transition: left 1s linear, top 1s linear; box-shadow: none; overflow: visible; }
.mystery-actor .character-sprite { position: absolute; left: -10px; bottom: 0; transform: scale(.7); }
.mystery-actor .character-sprite.state-idle { animation: none; }
.mystery-question { position: absolute; left: 11px; top: -27px; width: 26px; height: 30px; border: 1px solid #e4c780; border-radius: 10px; background: #14281fec; color: #ffe6a1; font: bold 23px/28px Georgia, serif; box-shadow: 0 0 12px #e4c78055; }
.mystery-actor:focus-visible { outline: 2px solid #ffe6a1; outline-offset: 4px; }
.mystery-dialog { position: fixed; inset: 0; width: min(560px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); margin: auto; padding: clamp(18px, 4vw, 30px); overflow-y: auto; border: 1px solid #b59a62; border-radius: 16px; color: #f4edd7; background: linear-gradient(145deg, #243e32, #10251b); box-shadow: 0 20px 80px #0009; }
.mystery-dialog::backdrop { background: #06140fc9; }
.mystery-dialog h2, .mystery-dialog h3 { color: #f0d89e; font-family: Georgia, serif; }
.mystery-dialog p, .mystery-dialog li { line-height: 1.5; }
.mystery-dialog section, #mysteryGuessForm { margin-top: 22px; }
.mystery-dialog button { min-height: 44px; }
.mystery-clue-box { padding: 14px 18px; background: #071b1380; border: 1px solid #b59a6255; border-radius: 10px; }
#mysteryClues { padding-left: 22px; } #mysteryClues li + li { margin-top: 9px; }
#mysteryStatus { padding: 10px 12px; border-left: 3px solid #b59a62; background: #06170f66; }
#mysteryMoves, #mysterySuggestions { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
#mysteryGuessForm { display: block; } #mysteryGuessForm label { display: block; }
#mysteryQuery { width: 100%; margin-top: 8px; }
#mysterySearchStatus { font-size: 12px; color: #c4d0bd; }
#mysteryGuess { width: 100%; }
@media (prefers-reduced-motion: reduce) { #map .mystery-actor { transition: none; } .mystery-actor .character-sprite { animation: none; } }

.zone-village #mysteryActors { display: contents; }
#map:not(.zone-village) #mysteryActors { display: none; }

/* Forest props now use the authoritative SVG footprints. */
.zone-forest .zone-decor, .zone-deep-forest .zone-decor { display: none; }

/* Premiers pas : guide visible sans bloquer le monde. */
.newcomer-guide {
  position: fixed;
  z-index: 18;
  top: 82px;
  left: 18px;
  width: min(390px, calc(100vw - 36px));
  padding: 18px;
  border: 1px solid #d8b56f99;
  border-radius: 14px;
  background: linear-gradient(145deg, #203b2eef, #10251bf2);
  box-shadow: 0 18px 55px #0009, inset 0 1px #ffffff0d;
  backdrop-filter: blur(8px);
}
.newcomer-guide[hidden] { display: none; }
.newcomer-guide-head { display: flex; align-items: start; justify-content: space-between; gap: 12px; }
.newcomer-guide-head .eyebrow { margin: 0 0 5px; }
.newcomer-guide h2 { margin: 0; color: #f4dda8; font: 500 23px/1.1 Georgia, serif; }
.newcomer-guide-head > button {
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #a98e5d66;
  border-radius: 50%;
  background: #10251b;
  color: #ddc589;
}
.newcomer-guide > p { margin: 13px 0; color: #c0cdbf; font-size: 13px; line-height: 1.55; }
.newcomer-steps { display: grid; gap: 8px; padding: 0; margin: 0 0 14px; list-style: none; }
.newcomer-steps li { display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-items: center; padding: 9px; border: 1px solid #ffffff12; border-radius: 9px; background: #071b1370; }
.newcomer-steps li > span { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid #9d885966; border-radius: 50%; color: #c6b17e; font-size: 11px; font-weight: 800; }
.newcomer-steps strong { display: block; color: #ead9b1; font-size: 12px; }
.newcomer-steps small { display: block; margin-top: 2px; color: #90a398; font-size: 10px; line-height: 1.45; }
.newcomer-steps li.done { border-color: #75d69d55; background: #173b2a8c; }
.newcomer-steps li.done > span { border-color: #75d69d; background: #2a6743; color: #e6ffe9; }
.newcomer-steps li.done > span::before { content: '✓'; }
.newcomer-steps li.done > span { font-size: 0; }
.newcomer-steps li.done > span::before { font-size: 12px; }
.newcomer-action { width: 100%; min-height: 42px; border: 1px solid #d8b56f88; border-radius: 8px; background: #cfac66; color: #12231a; font-weight: 800; font-size: 11px; }
.newcomer-action:hover { background: #e1c47f; }
@media (max-width: 600px) {
  .newcomer-guide { top: 68px; left: 10px; width: calc(100vw - 20px); padding: 14px; }
  .newcomer-guide h2 { font-size: 20px; }
  .newcomer-steps small { font-size: 9px; }
}

/* First combat: make one nearby creature self-explanatory until the first victory. */
.monster.tutorial-target:not(.dead)::before {
  content: 'PREMIÈRE CIBLE';
  position: absolute;
  z-index: 12;
  left: 50%;
  top: -28px;
  translate: -50% 0;
  width: max-content;
  padding: 5px 8px;
  border: 1px solid #ffe09a;
  border-radius: 999px;
  background: #13271fed;
  color: #ffe7ad;
  font: 900 8px/1 ui-monospace, monospace;
  letter-spacing: .08em;
  box-shadow: 0 0 0 4px #14271f88, 0 0 16px #eebc6577;
  pointer-events: none;
}
.monster.tutorial-target:not(.dead)::after {
  content: '';
  position: absolute;
  z-index: -1;
  inset: -12px -10px;
  border: 2px solid #ffe09aa8;
  border-radius: 50%;
  pointer-events: none;
  animation: tutorial-monster-ring 1.35s ease-out infinite;
}
@keyframes tutorial-monster-ring {
  0% { scale: .86; opacity: .95; }
  75%,100% { scale: 1.18; opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .monster.tutorial-target:not(.dead)::after { animation: none; opacity: .65; }
}

/* First journey: point new players toward the direct forest exit. */
.portal.tutorial-portal {
  outline: 3px solid #ffe09acc;
  outline-offset: 6px;
}
.portal.tutorial-portal::after {
  content: 'VERS LA FORÊT';
  position: absolute;
  left: 50%;
  top: calc(100% + 13px);
  translate: -50% 0;
  width: max-content;
  padding: 5px 8px;
  border: 1px solid #ffe09a;
  border-radius: 999px;
  background: #13271fee;
  color: #ffe7ad;
  font: 900 8px/1 ui-monospace, monospace;
  letter-spacing: .08em;
  box-shadow: 0 0 14px #eebc6555;
  pointer-events: none;
}

/* A single contextual target, without moving its collision anchor. */
.npc.tutorial-target::after,.mystery-actor.tutorial-target::after {
  content:""; position:absolute; inset:-8px; border:2px solid #f4d35e; border-radius:50%;
  box-shadow:0 0 0 5px rgb(244 211 94 / 20%); pointer-events:none; animation:tutorial-target-pulse 1.4s ease-in-out infinite;
}
.newcomer-controls { display:flex; gap:.5rem; flex-wrap:wrap; }
@keyframes tutorial-target-pulse { 50% { opacity:.5; transform:scale(1.04); } }
@media (prefers-reduced-motion: reduce) { .npc.tutorial-target::after,.mystery-actor.tutorial-target::after { animation:none; } }
.journal-slots{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:.55rem;margin:1rem 0}.journal-slot,.question-card,.selene-spaces article{display:grid;gap:.35rem;border:1px solid #d8bd6970;border-radius:12px;padding:.75rem;background:linear-gradient(145deg,#17382e,#273f31)}.journal-slot small,.question-card small{color:#d8bd69}.question-catalog{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.65rem}.question-catalog fieldset{border:1px solid #7fae7b55;border-radius:10px}.question-choice{display:block;padding:.35rem}.selene-spaces{display:grid;grid-template-columns:1fr 1fr;gap:.7rem}.question-community{margin-top:1rem}.question-community form{display:grid;gap:.6rem}.question-community fieldset{display:grid;gap:.35rem}.question-card strong{color:#fff0ac}.privacy-help{padding:.7rem;border-left:3px solid #b9db83;background:#102b2288}
@media(max-width:700px){.journal-slots{grid-template-columns:1fr}.question-catalog,.selene-spaces{grid-template-columns:1fr}.questionnaire.drawer{max-width:100vw}.question-card button{min-height:44px}}

/* natural-village.css */
/* Loaded after legacy skins. Geometry lives in shared/village-layout.js. */
.game-shell .map-viewport #map.zone-village { width: 3000px; height: 2000px; }
#map.zone-village { isolation: isolate; background: #83a852 !important; }
.zone-village #villageScene { position: absolute; inset: 0; z-index: 0; }

.terrain-paint { image-rendering: auto; }
#map:not(.zone-village) #villageScene, #map:not(.zone-village) #mapBuildings { display: none; }
.zone-village #mapBuildings, .zone-village #mapPlayers, .zone-village #mapNpcs { display: contents; }

/* Two fixed iron straps visibly attach each board to the timber above it. */

.zone-village .pawn {
  width: 46px; height: 60px; transform: translate(-50%, -100%);
  /* Depth must follow the displayed feet, not jump to the destination early. */
  transition: left .18s linear, top .18s linear, z-index .18s linear, transform .15s;
}
@media (prefers-reduced-motion: reduce) {
  .zone-village .pawn { transition: none; }
}
.zone-village .pawn:not(.self):hover, .zone-village .pawn:not(.self):focus-visible { transform: translate(-50%, -100%) scale(1.08); }
.zone-village .character-renderer { scale: .68; transform-origin: 50% 100%; }
.zone-village .npc { width: 46px; min-height: 60px; height: 60px; padding: 0; translate: -50% -100%; }
.zone-village .npc-role { display: none; }
.zone-village .npc > strong { position: absolute; top: -19px; font-size: 10px; white-space: nowrap; padding: 2px 4px; background: #405237dd; border-radius: 4px; }
.zone-village .npc-sprite { scale: .75; transform-origin: 50% 100%; position: absolute; bottom: 0; }
.zone-village .portal-hub { left: 100px; top: 1720px; z-index: 1900; translate: none; }
.zone-village .forest-exit { left: 2960px; top: 1720px; z-index: 1900; width: 70px; min-height: 70px; border-color: #b7c493; background: #53724c; box-shadow: none; animation: none; }
.zone-village .map-hint { left: 1450px; top: 1335px; z-index: 20; color: #697050; background: transparent; border: 0; font-size: 16px; letter-spacing: .12em; }
.zone-village .ambient-particles, .zone-village .zone-decor { display: none; }
.zone-village #destination { z-index: 30; }
.zone-village::before { display: none; }
/* Forest limits follow the full map, never the moving viewport. */

.forest-boundary-art { display: block; width: 100%; height: 100%; }

.zone-deep-forest .forest-boundary-art { filter: saturate(.94); }
.zone-forest .pawn.self, .zone-deep-forest .pawn.self { z-index: 9; }
.world-passage { z-index: 8; }
/* The frame and empty stone bowl stay fixed; only the energy rotates. */

.portal-vortex-spin svg { display: block; width: 100%; height: 100%; fill: none; stroke: var(--portal-light); stroke-width: 2; opacity: .75; }

#map .portal-choices { z-index: 10; left: 170px; top: -110px; width: 180px; }
@keyframes root-vortex-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
 }
/* Keep the village frame inside the world at the existing travel point. */

/* Compact character card: portrait, location, health, then experience. */
.player-hud { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 12px; width: 340px; max-width: calc(100vw - 90px); padding: 12px; border: 1px solid #b6a16b; border-radius: 16px; background: linear-gradient(145deg, #243e32f5, #14281ff5); box-shadow: 0 5px 18px #10201666, inset 0 1px #f5e3ac22; }
.hud-portrait { position: relative; align-self: start; height: 90px; overflow: hidden; border: 1px solid #ac9764; border-radius: 12px; background: radial-gradient(ellipse at 50% 30%, #789361, #293e30 75%); }
.hud-portrait#hudProfileButton { display: block; width: 100%; min-height: 0; padding: 0; color: inherit; cursor: pointer; pointer-events: auto; }
.hud-portrait#hudProfileButton:hover, .hud-portrait#hudProfileButton[aria-expanded="true"] { border-color: #f4d48a; }
.hud-portrait#hudProfileButton:focus-visible { outline: 3px solid #f4d48a; outline-offset: 3px; }
.hud-portrait .character-sprite { position: absolute; left: 50%; top: 0; margin-left: -34px; transform: scale(1.35); transform-origin: 50% 20%; }
.hud-portrait #level { position: absolute; bottom: 0; left: 0; right: 0; padding: 4px 0; background: #14281feb; color: #f4d48a; text-align: center; font: 700 10px/1.2 system-ui, sans-serif; }
.hud-details { min-width: 0; }
.player-hud #identity { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #fff2d2; font: 700 16px/1.25 Georgia, serif; }
.player-hud .hud-location { margin: 3px 0 9px; color: #bacaaf; font: 11px/1.3 system-ui, sans-serif; }
.hud-meter-heading { display: flex; justify-content: space-between; gap: 6px; color: #e5eee0; font: 11px/1.3 system-ui, sans-serif; }
.hud-meter-heading small { font: inherit; }
.hud-health-track, .player-hud .progress-track { overflow: hidden; height: 7px; margin-top: 3px; border: 1px solid #8b9b6c66; border-radius: 8px; background: #0d1a15; box-shadow: inset 0 1px 3px #0005; }
.hud-health-track i { display: block; height: 100%; background: linear-gradient(90deg, #a53845, #f07877); transition: width .4s ease; }
.hud-health-track.is-low { border-color: #ffaba0; }
.hud-xp-heading { margin-top: 7px; color: #d9c796; }
.player-hud .progress-track { height: 5px; }
.player-hud .progress-track i { background: linear-gradient(90deg, #b08a41, #f1d384); }
@media (max-width: 560px) {
  .player-hud { left: 8px; top: 8px; width: 292px; max-width: calc(100vw - 80px); grid-template-columns: 54px minmax(0, 1fr); gap: 8px; padding: 9px; border-radius: 12px; }
  .hud-portrait { height: 77px; }
  .hud-portrait .character-sprite { transform: scale(1.05); }
  .hud-portrait #level { font-size: 9px; }
  .player-hud #identity { font-size: 14px; }
  .player-hud .hud-location { font-size: 10px; margin-bottom: 6px; }
  .hud-meter-heading { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) { .hud-health-track i { transition: none; } }

/* Ripples drift slowly inside the river; bank and collision bounds stay fixed. */
.river-ripples { animation: river-ripples 8s ease-in-out infinite alternate; }
@keyframes river-ripples { to { transform: translateY(12px); opacity: .55; } }
@media (prefers-reduced-motion: reduce) { .river-ripples { animation: none; } }

/* slimes.css */
/* Body size and bounce never scale or move the name, level or health. */
#map .illustrated-slime { width: calc(112px * var(--slime-scale, 1)); height: calc(108px * var(--slime-scale, 1)); padding: 0; scale: none; translate: -50% -85%; overflow: visible; background: transparent; border: 0; box-shadow: none; filter: none; animation: none; }
.illustrated-slime .slime-body { position: absolute; inset: 0; pointer-events: none; }
.slime-body::after { content: ''; position: absolute; width: 54%; height: 9%; left: 23%; bottom: 4%; border-radius: 50%; background: #0c171f45; filter: blur(2px); }
.slime-bounce { display: block; position: absolute; inset: 0; z-index: 1; transform-origin: 50% 92%; animation: slime-soft-bounce 1.3s ease-in-out infinite; }
.slime-art { display: block; position: absolute; inset: 0; background-image: none; background-size: 300% 200%; background-repeat: no-repeat; background-position: 0 0; }
.family-dark .slime-art { background-position-y: 100%; }
.phase-grown .slime-art { background-position-x: 50%; }
.phase-elder .slime-art { background-position-x: 100%; }
.phase-grown .slime-bounce { animation-duration: 1.5s; }
.phase-elder .slime-bounce { animation-duration: 1.8s; }
.illustrated-slime .slime-caption { position: absolute; bottom: 100%; left: 50%; translate: -50% 0; width: 136px; padding: 4px 6px; border-radius: 7px; background: #10251feb; border: 1px solid #afc69480; pointer-events: none; text-shadow: none; }
.family-dark .slime-caption { background: #19152aee; border-color: #ba9ee580; }
.slime-heading { display: flex; align-items: center; justify-content: space-between; gap: 5px; white-space: nowrap; font: 700 11px/1.3 system-ui, sans-serif; color: #fff5df; }
.slime-level { padding: 2px 4px; border-radius: 4px; background: #e6cb81; color: #241f14; font-size: 10px; flex-shrink: 0; }
.slime-health { display: block; height: 5px; overflow: hidden; background: #060c0b; border-radius: 4px; margin-top: 4px; }
.slime-health i { display: block; height: 100%; background: #89d878; transition: width .2s; }
.family-dark .slime-health i { background: #b997ef; }
.illustrated-slime.enraged .slime-health i { background: #ff857b; }
.slime-health-text { display: block; color: #e2e5d9; font: 10px/1.4 system-ui, sans-serif; text-align: center; margin-top: 2px; }
.slime-mouth { display: none; position: absolute; left: 44%; top: 75%; width: 12%; height: 9%; border-radius: 50%; background: #f3d5ff; box-shadow: 0 0 10px 4px #c589ff; }
.state-spit_prepare .slime-mouth { display: block; animation: slime-mouth-glow .5s ease-in-out infinite alternate; }
.state-spit_prepare .slime-bounce { animation: slime-inhale .5s ease-in-out infinite alternate; }
.state-ranged .slime-bounce { animation: slime-release .4s ease-out; }
.state-jump_prepare .slime-bounce { animation: slime-inhale .35s ease-in-out infinite alternate; }
.state-jump .slime-bounce { animation: none; transform: translateY(-24px) scale(.92,1.08); }
.state-recover .slime-bounce { animation: slime-release .5s ease-out; }
#mapEffects .slime-projectile { width: 18px; height: 15px; background: radial-gradient(circle at 35% 30%, #ffedff, #c08bff 35%, #633095 80%); box-shadow: 0 0 9px #bd80ff; }
#mapEffects .slime-impact { border-color: #c99df9; background: #ac77ef40; }
@keyframes slime-soft-bounce { 0%,100% { transform: translateY(0) scale(1.02,.98); } 45% { transform: translateY(-5px) scale(.98,1.02); } 80% { transform: translateY(0) scale(1.035,.965); } }
@keyframes slime-inhale { from { transform: scale(1.02,.98); } to { transform: scale(1.12,.91); } }
@keyframes slime-mouth-glow { to { box-shadow: -8px 0 7px #d596ff, 8px 0 7px #d596ff, 0 0 14px 5px #c589ff; } }
@keyframes slime-release { 0% { transform: scale(.92,1.07); } 55% { transform: scale(1.06,.94); } 100% { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { #map .slime-bounce, #map .slime-mouth { animation: none; transform: none; } #mapEffects .slime-projectile { animation: none; } .slime-health i { transition: none; } }

.slime-intent { display: block; color: #ffd79b; font: 700 10px/1.35 system-ui,sans-serif; white-space: normal; text-align: center; }
.slime-intent:empty { display: none; }
.state-spit_prepare .slime-caption, .state-jump_prepare .slime-caption { border: 2px solid #ffbb73; }
#map .combat-selected .slime-body::before { content: ''; position: absolute; inset: 78% 4% -4%; border: 3px solid #ffe5a2; border-radius: 50%; box-shadow: 0 0 10px #ffe5a280; }
#map .combat-out-of-range .slime-body::before { border-style: dashed; border-color: #ff9d8c; }
.combat-target { position: fixed; z-index: 80; left: 16px; bottom: 16px; width: min(285px,calc(100vw - 100px)); padding: 14px; border: 1px solid #ceb16c; border-radius: 12px; background: #10251ff5; color: #f6edcd; box-shadow: 0 4px 20px #0006; }
.combat-target.combat-target-opposite { left: auto; right: 84px; }
.combat-target strong, .combat-target span { display: block; margin-right: 20px; }
.combat-target p { font-size: 12px; margin: 8px 0; }
#combatClear { position: absolute; top: 3px; right: 3px; border: 0; background: transparent; color: white; font-size: 22px; }
#combatAttack { width: 100%; min-height: 42px; }
#combatThreat { color: #ffc888; font-weight: 700; }
.combat-loot { position: fixed; z-index: 81; left: 16px; bottom: 16px; max-width: min(420px,calc(100vw - 100px)); padding: 12px; background: #10251ff5; border: 1px solid #d8c27e; border-radius: 10px; color: #ffe5a2; pointer-events: none; }
.combat-target:not([hidden]) ~ .combat-loot { bottom: 240px; }
#mapEffects .combat-number { position: absolute; z-index: 3000; transform: translate(-50%,-100%); padding: 4px 7px; background: #15231dd9; border-radius: 6px; font: 800 19px system-ui,sans-serif; color: #fff0b4; text-shadow: 0 1px 3px #000; animation: combat-number-rise 1.3s ease-out forwards; }
#mapEffects .damage-received { color: #ffada7; border: 1px solid #ff8077; }
@keyframes combat-number-rise { to { opacity: 0; translate: 0 -40px; } }
@media (prefers-reduced-motion: reduce) { #mapEffects .combat-number { animation: none; } }
#combatAttack { border: 1px solid #d6bd7d; border-radius: 7px; background: linear-gradient(#e5cc8b,#b79a5c); color: #17251d; font-weight: 800; }
#combatAttack:disabled { background: #263c31; color: #c1cdbb; border-color: #69816a; cursor: default; }
#combatAttack:focus-visible, #combatClear:focus-visible { outline: 2px solid #fff0b4; outline-offset: 3px; }
@media (max-width: 520px) { .combat-target.combat-target-opposite { right: 76px; width: min(250px,calc(100vw - 92px)); } }

/* npcs.css */
/* One RGBA source, eight feet-aligned pairs. No sprite DOM replacement on ticks. */
.npc-character { --npc-row: 0; --npc-delay: 0s; --npc-cycle: 7s; }
.npc-art-selene { --npc-row: 0; --npc-delay: -1s; --npc-cycle: 8.7s; }
.npc-art-borin { --npc-row: 1; --npc-delay: -2.4s; --npc-cycle: 5.9s; }
.npc-art-mina { --npc-row: 2; --npc-delay: -4s; --npc-cycle: 7.7s; }
.npc-art-nelis { --npc-row: 3; --npc-delay: -1.8s; --npc-cycle: 8.1s; }
.npc-art-gaspard { --npc-row: 4; --npc-delay: -5.2s; --npc-cycle: 9.3s; }
.npc-art-gribsin { --npc-row: 5; --npc-delay: -3s; --npc-cycle: 6.7s; }
.npc-art-maera { --npc-row: 6; --npc-delay: -6s; --npc-cycle: 10.1s; }
.npc-art-alya { --npc-row: 7; --npc-delay: -4.6s; --npc-cycle: 8.9s; }
.zone-village .npc.npc-character, .npc.npc-character { width: 64px; height: 72px; min-height: 72px; padding: 0; display: block; translate: -50% -100%; overflow: visible; filter: none; }
.npc.npc-character::before { content: ''; position: absolute; width: 30px; height: 7px; border-radius: 50%; background: #152b3559; bottom: -3px; left: 17px; pointer-events: none; }
.zone-village .npc-character .npc-sprite, .npc-character .npc-sprite, .npc-portrait .npc-sprite { display: block; position: absolute; bottom: -2px; left: 0; width: 64px; height: 72px; scale: 1; border: 0; border-radius: 0; box-shadow: none; margin: 0; background: none; transform-origin: 50% 70px; image-rendering: auto; animation: npc-gesture var(--npc-cycle, 8s) steps(1, end) var(--npc-delay, 0s) infinite, npc-breathe 3.8s ease-in-out var(--npc-delay, 0s) infinite; }
.zone-village .npc-character > strong, .npc-character > strong { position: absolute; top: -17px; left: 50%; translate: -50% 0; padding: 3px 6px; border: 1px solid #d8be77; border-radius: 5px; background: #182b26ed; color: #fff6d8; font: 700 11px/1.1 system-ui, sans-serif; white-space: nowrap; text-shadow: 0 1px 2px #000; pointer-events: none; }
.zone-village .npc-character .npc-role, .npc-character .npc-role { display: none; position: absolute; top: 75px; left: 50%; translate: -50% 0; width: max-content; max-width: 120px; padding: 3px 5px; font: 700 10px/1.2 system-ui, sans-serif; background: #f5e2b8; color: #253a2e; pointer-events: none; }
.npc-character:hover .npc-role, .npc-character:focus-visible .npc-role { display: block; }
.npc.npc-character:hover { scale: 1; }
.npc.npc-character:focus-visible { scale: 1; outline: 2px solid #ffe49b; outline-offset: 3px; border-radius: 8px; }
.npc-portrait { display: block; position: relative; width: 64px; height: 72px; margin: 0 auto 12px; }
.npc-portrait .npc-sprite { animation: none; }
@keyframes npc-gesture { 0%, 72%, 100% { background-position-x: 0; } 76%, 90% { background-position-x: -64px; } }
@keyframes npc-breathe { 0%, 100% { transform: scaleY(1); } 50% { transform: scaleY(1.008); } }
@media (prefers-reduced-motion: reduce) { .zone-village .npc-character .npc-sprite, .npc-character .npc-sprite, .npc-portrait .npc-sprite { animation: none; transform: none; background-position-x: 0; } }
.npc-workshop { max-width: min(560px, 94vw); }
.npc-workshop article { display: grid; gap: 9px; padding: 14px 0; border-bottom: 1px solid #baa16a55; }
.npc-workshop article small, #npcServiceStatus, #guildNotice { color: #c1cbb7; line-height: 1.6; }
.npc-workshop button { min-height: 40px; }
#bankTransfer { grid-template-columns: 1fr 1fr; }
#bankTransfer label, #bankTransfer input { grid-column: 1 / -1; }
.selene-guide { padding: 12px 14px; border: 1px solid #d8be7766; border-radius: 10px; background: #13261f; }
.selene-guide ol { margin: 8px 0 0; padding-left: 1.35rem; color: #d8dfd2; line-height: 1.55; }
#shadowProposalForm { display: grid; gap: 12px; margin: 14px 0 20px; }
#shadowProposalForm label, #shadowProposalForm fieldset { display: grid; gap: 6px; }
#shadowProposalForm fieldset { margin: 0; padding: 12px; border: 1px solid #baa16a55; border-radius: 9px; }
#shadowProposalForm input:not([type="checkbox"]), #shadowProposalForm textarea { width: 100%; box-sizing: border-box; }
#shadowProposalForm textarea { min-height: 72px; resize: vertical; }
#shadowProposalForm .check-line { grid-template-columns: auto 1fr; align-items: start; }
#shadowProposals ol { margin: 6px 0; padding-left: 1.35rem; color: #c1cbb7; }
#premiumCatalog, #premiumPackages { display: grid; gap: 8px; }
@media (max-width: 620px) { .npc-workshop { inset: 8px; max-width: none; max-height: calc(100dvh - 16px); overflow-y: auto; } }

/* home.css */
/* Homepage rules are scoped so the game's interface keeps its own layout. */
html { scroll-behavior: smooth; }
body:not(.game-active) { background: #0e211e; }
.site-main { max-width: none; width: 100%; padding: 0; }
.home-header { height: 84px; padding: 0 5%; align-items: center; gap: 30px; background: #0b1c19; border-bottom: 1px solid #bca16b35; }
.home-wordmark { display: inline-flex; align-items: center; gap: 12px; color: #e4c68b; text-decoration: none; font: 700 21px/1 Georgia,serif; letter-spacing: .14em; }
.home-sigil { display: grid; place-items: center; width: 32px; height: 40px; border: 1px solid #c8a86c; font: 28px Georgia,serif; clip-path: polygon(50% 0,100% 14%,100% 83%,50% 100%,0 83%,0 14%); }
.home-header nav { display: flex; justify-content: center; flex: 1; gap: clamp(20px,4vw,52px); }
.home-header nav a, .home-nav-login { color: #dddcc9; text-decoration: none; font-size: 12px; letter-spacing: .06em; }
.home-nav-login { border: 1px solid #ab92604f; padding: 12px 20px; color: #e7cf99; }
.home-nav-login span { margin-left: 20px; }
.home-header a:hover, .home-footer a:hover { color: #fff2cc; }
.home-hero { position: relative; min-height: 730px; display: flex; flex-direction: column; justify-content: center; isolation: isolate; }
.home-hero-art, .home-hero-shade { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.home-hero-art { object-fit: cover; object-position: center 55%; }
.home-hero-shade { background: linear-gradient(90deg,#071a19eb 0%,#08211ab3 29%,#061e1920 67%,#061a194d),linear-gradient(0deg,#0e211e 0%,transparent 32%,#06171430); }
.home-hero-content { width: min(1320px,90%); margin: 0 auto; padding: 75px 0 92px; display: grid; grid-template-columns: minmax(0,1fr) 350px; align-items: center; gap: clamp(35px,6vw,100px); }
.home-kicker { font: 600 10px/1.6 system-ui,sans-serif; letter-spacing: .19em; color: #ddbf83; margin: 0 0 22px; }
.home-intro h1 { font: 500 clamp(42px,5.8vw,86px)/1.05 Georgia,serif; color: #f1deb4; letter-spacing: .045em; margin: 0 0 23px; text-shadow: 0 3px 20px #0006; }
.home-tagline { font: 400 clamp(28px,3.2vw,46px)/1.17 Georgia,serif; color: #fff9e8; margin: 0 0 24px; }
.home-intro-copy { max-width: 410px; margin: 0 0 32px; font-size: 14px; line-height: 1.9; color: #d0d9cc; }
.home-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.home-button { display: inline-flex; justify-content: center; align-items: center; gap: 22px; min-height: 49px; padding: 15px 22px; border-radius: 0; border: 1px solid #d7b371; font: 700 11px/1.3 system-ui,sans-serif; letter-spacing: .07em; text-decoration: none; cursor: pointer; transition: background .18s, box-shadow .18s; }
.home-button-gold { background: #d6b679; color: #172b23; box-shadow: inset 0 0 0 3px #e9d09566; }
.home-button-gold:hover { background: #ebce91; box-shadow: 0 0 24px #d3b57233; }
.home-button-outline { background: transparent; color: #dfc58e; }
.home-button:disabled { cursor: default; opacity: .55; }
.home-text-link { font-size: 11px; letter-spacing: .035em; color: #ebd4a2; text-decoration: none; border-bottom: 1px solid #d8bd7e70; padding: 9px 0; }
.home-text-link span { margin-left: 10px; }
.home-alpha { margin-top: 24px; font-size: 10px; letter-spacing: .035em; color: #afc2b0; }
#auth.home-auth { position: relative; width: 100%; max-width: none; margin: 0; padding: 30px 28px 20px; background: #0a211fed; border: 1px solid #d4bb7a66; border-radius: 0; box-shadow: 0 15px 45px #04161450; }
#auth.home-auth::before { content: ''; position: absolute; top: -5px; left: 50%; width: 8px; height: 8px; border: 1px solid #e0c58a; background: #163429; transform: rotate(45deg); }
#auth .home-kicker { font-size: 8px; margin-bottom: 12px; }
#auth h2 { font: 400 27px/1.15 Georgia,serif; margin: 0 0 24px; color: #f3e6c5; }
#auth .tabs { margin-bottom: 22px; gap: 14px; }
#auth .tabs button { font-size: 11px; padding: 10px 0; color: #94aaa0; border-color: #3b5248; }
#auth .tabs button.active { color: #edce8d; border-color: #ddbb77; }
#auth form { gap: 8px; }
#auth label { font-size: 10px; color: #c9d2c4; }
#auth input { min-width: 0; width: 100%; font-size: 12px; padding: 12px; border: 1px solid #5b716257; border-radius: 0; background: #071a18a8; color: #f9efda; margin-bottom: 8px; }
#auth input::placeholder { color: #79938a; }
#auth input:focus { outline: 1px solid #dfc18b; outline-offset: 2px; }
#auth .home-button { margin-top: 10px; }
#auth .error { font-size: 12px; line-height: 1.5; margin: 12px 0 0; }
#auth .error:empty { display: none; }
.home-auth-note { font: 10px/1.7 system-ui,sans-serif; color: #91a89b; text-align: center; margin: 18px 0 0; }
.home-hero-foot { position: absolute; bottom: 22px; left: 5%; right: 5%; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: #8ea59b; font-size: 8px; letter-spacing: .14em; }
.home-hero-foot a { color: #d3bd88; text-decoration: none; }
.home-principles { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); padding: 34px max(5%,calc((100vw - 1200px)/2)); background: #0e211e; border-bottom: 1px solid #9c966134; }
.home-principles > div { position: relative; padding: 4px 25px 4px 50px; border-right: 1px solid #6c846143; }
.home-principles > div:last-child { border-right: 0; }
.home-principles > div > span { position: absolute; left: 20px; top: 8px; color: #a78b58; font: 12px Georgia,serif; }
.home-principles h2 { font: 400 19px Georgia,serif; color: #e6d9b8; margin: 0 0 8px; }
.home-principles p { font-size: 10px; line-height: 1.8; color: #8fa79b; margin: 0; }
.home-section { padding: 85px max(6%,calc((100vw - 1160px)/2)); scroll-margin-top: 24px; }
.home-section-heading { display: flex; align-items: end; justify-content: space-between; gap: 45px; margin-bottom: 34px; }
.home-section-heading h2, .home-support h2 { font: 400 clamp(30px,3.3vw,46px)/1.15 Georgia,serif; margin: 0; }
.home-section-heading .home-kicker { margin-bottom: 12px; }
.home-section-heading > p { max-width: 330px; font-size: 12px; line-height: 1.8; margin: 0 0 3px; }
.home-universe { background: #f0eddf; color: #18362c; }
.home-universe .home-kicker { color: #8a7042; }
.home-universe .home-section-heading > p { color: #6c7567; }
.home-trailer { position: relative; aspect-ratio: 2.15; overflow: hidden; background: #14382c; outline: 1px solid #b4a883; outline-offset: 6px; }
.home-trailer > img { width: 100%; height: 100%; object-fit: cover; object-position: center 56%; filter: brightness(.54); }
.home-trailer-placeholder { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; text-align: center; color: #f6ebd3; background: linear-gradient(0deg,#051b2060,transparent); }
.home-play-mark { display: grid; place-items: center; width: 56px; height: 56px; border: 1px solid #e2c282; border-radius: 50%; color: #f5dd9f; font-size: 35px; margin-bottom: 18px; }
.home-trailer-placeholder .home-kicker { margin: 0 0 10px; color: #ddc694; font-size: 9px; }
.home-trailer-placeholder h3 { font: 30px Georgia,serif; margin: 0 0 12px; }
.home-trailer-placeholder > p:last-child { font-size: 12px; margin: 0; color: #dfdfcb; }
.home-trailer video { display: block; width: 100%; height: 100%; object-fit: contain; background: #081712; }
.home-video-caption { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 20px; }
.home-video-caption p { color: #6b7364; font-size: 11px; }
.home-video-caption .home-text-link { color: #52623c; border-color: #aaa480; white-space: nowrap; }
.home-journal { background: #102620; color: #e9dec1; }
.home-journal .home-section-heading > p { color: #99afa0; }
.home-journal-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 28px; align-items: start; }
.journal-entry { min-width: 0; }
.journal-art { height: 190px; display: grid; place-items: center; border: 1px solid #9c996c40; overflow: hidden; position: relative; }
.journal-art::after { content: ''; position: absolute; inset: 0; box-shadow: inset 0 -30px 45px #0a201956; pointer-events: none; }
.journal-art-village { background: radial-gradient(ellipse at 50% 70%,#7e9859,#314d3c); }
.journal-art-village span { display: block; width: 270px; height: 190px; background: url('/assets/home/news-village.webp') center/contain no-repeat; }
.journal-art-npcs { background: radial-gradient(ellipse at 50% 75%,#648e6c,#263f37); }
.journal-art-npcs span { display: block; width: 128px; height: 144px; background: url('/assets/home/news-nelis.webp') center/contain no-repeat; image-rendering: pixelated; }
.journal-art-slimes { background: radial-gradient(ellipse at 50% 70%,#66834c,#20372f); }
.journal-art-slimes span { display: block; width: 175px; height: 175px; background: url('/assets/home/news-slime.webp') center/contain no-repeat; }
.journal-body { padding-top: 20px; }
.journal-meta { color: #c1a66b; font: 500 8px/1.7 system-ui,sans-serif; letter-spacing: .07em; margin: 0 0 13px; }
.journal-body h3 { font: 400 24px/1.2 Georgia,serif; margin: 0 0 12px; }
.journal-body > p:not(.journal-meta), .journal-body details p { font-size: 12px; line-height: 1.9; color: #9eb4a6; }
.journal-body details { border-top: 1px solid #75856345; padding-top: 14px; margin-top: 20px; }
.journal-body summary { color: #d5bd85; font-size: 10px; cursor: pointer; }
.journal-body details[open] summary { margin-bottom: 12px; }
.home-support { display: grid; grid-template-columns: 60px minmax(0,1fr) auto; gap: 34px; align-items: center; border-block: 1px solid #c7b47d30; background: radial-gradient(ellipse at 10% 40%,#244431,#142b25 65%); }
.home-support-emblem { color: #c9ad6a; font-size: 64px; }
.home-support .home-kicker { margin-bottom: 12px; }
.home-support h2 { font-size: 36px; }
.home-support p:not(.home-kicker) { font-size: 12px; line-height: 1.8; color: #acbba8; max-width: 510px; }
.home-support .home-support-status { font-size: 10px; color: #c6b184; }
.home-advertisement { padding: 35px 5% 42px; text-align: center; background: #0c1d19; }
.home-advertisement > p { font-size: 8px; letter-spacing: .18em; color: #75877c; }
#advertisementSlot { margin: 15px auto 0; max-width: 970px; min-height: 90px; border: 1px dashed #77906b45; display: grid; place-items: center; color: #7b8e80; font-size: 11px; }
#advertisementSlot a, #advertisementSlot img { display: block; max-width: 100%; }
.home-footer { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 24px; padding: 38px 6%; border-top: 1px solid #9b9c6626; background: #081814; }
.home-footer .home-wordmark { font-size: 17px; }
.home-footer > p { font: italic 15px Georgia,serif; text-align: right; color: #8fa394; margin: 0; }
.home-footer > div { display: flex; flex-wrap: wrap; gap: 24px; }
.home-footer > div a, .home-footer small { color: #819689; font-size: 10px; text-decoration: none; }
.home-footer small { text-align: right; }
.game-active #landing { display: none; }
#landing a:focus-visible, #landing button:focus-visible, .home-header a:focus-visible, .home-footer a:focus-visible, #landing summary:focus-visible { outline: 2px solid #dec184; outline-offset: 5px; }
[aria-disabled="true"][data-open-auth] { opacity: .65; cursor: progress; }
.home-wake-actions { display: grid; gap: 14px; margin-top: 24px; }
#wakeStatus { font-size: 12px; line-height: 1.8; color: #dbd9bd; }
@media(max-width:1050px) {
  .home-hero-content { gap: 30px; grid-template-columns: minmax(0,1fr) 320px; }
  .home-actions { gap: 15px; }
  .home-header { gap: 20px; }
  .home-header nav { gap: 20px; }
  .home-wordmark { font-size: 17px; }
  .home-support { grid-template-columns: 40px minmax(0,1fr); gap: 24px; }
  #donationAction { grid-column: 2; }
}
@media(max-width:760px) {
  .home-header { height: auto; min-height: 72px; padding: 17px 5%; flex-wrap: wrap; gap: 18px; }
  .home-header nav { order: 3; flex-basis: 100%; justify-content: space-between; border-top: 1px solid #bba47225; padding-top: 14px; }
  .home-header nav a { font-size: 10px; }
  .home-nav-login { margin-left: auto; padding: 9px 12px; font-size: 10px; }
  .home-nav-login span { margin-left: 8px; }
  .home-sigil { width: 23px; height: 30px; font-size: 20px; }
  .home-hero-content { grid-template-columns: 1fr; width: 88%; padding: 58px 0 70px; gap: 45px; }
  .home-hero-art { object-position: 57% top; }
  .home-hero-shade { background: linear-gradient(0deg,#0e211e 3%,#0b221bae 44%,#061a1980),linear-gradient(90deg,#071c18c9,transparent); }
  .home-intro h1 { font-size: clamp(38px,9vw,66px); }
  .home-tagline { font-size: 33px; }
  .home-kicker { font-size: 8px; }
  .home-intro-copy { font-size: 13px; }
  .home-alpha { line-height: 1.8; }
  #auth.home-auth { max-width: 440px; justify-self: center; padding: 27px 24px; }
  .home-hero-foot { font-size: 7px; gap: 10px; }
  .home-hero-foot > span:first-child { display: none; }
  .home-principles { grid-template-columns: 1fr; gap: 24px; padding: 30px 6%; }
  .home-principles > div { border-right: 0; padding-left: 40px; }
  .home-principles > div > span { left: 5px; }
  .home-principles p { font-size: 11px; }
  .home-section { padding: 52px 6%; }
  .home-section-heading { display: block; margin-bottom: 28px; }
  .home-section-heading > p { margin-top: 18px; max-width: none; }
  .home-section-heading h2 { font-size: 35px; }
  .home-trailer { aspect-ratio: 1.25; }
  .home-trailer-placeholder h3 { font-size: 25px; }
  .home-trailer-placeholder > p:last-child { font-size: 11px; }
  .home-video-caption { align-items: start; flex-direction: column; gap: 4px; }
  .home-journal-grid { grid-template-columns: 1fr; gap: 36px; }
  .journal-art { height: 205px; }
  .journal-body h3 { font-size: 26px; }
  .home-support { grid-template-columns: 1fr; text-align: center; gap: 15px; }
  .home-support-emblem { font-size: 45px; }
  .home-support h2 { font-size: 32px; }
  #donationAction { grid-column: 1; }
  .home-advertisement { padding-inline: 6%; }
  .home-footer { grid-template-columns: 1fr; justify-items: center; gap: 22px; }
  .home-footer > p, .home-footer small { text-align: center; }
  .home-footer > div { justify-content: center; gap: 18px; }
}
@media(prefers-reduced-motion:reduce) { html { scroll-behavior: auto; } .home-button { transition: none; } }

#auth #resumeGame { width: 100%; margin: 0 0 18px; }

/* Compact welcome: a panoramic introduction followed by one editorial row. */
.home-header { height: 60px; }
.home-hero { min-height: 0; }
.home-hero-content { padding: 24px 0 34px; grid-template-columns: minmax(0,1fr) 340px; gap: 40px; }
.home-intro h1 { font-size: clamp(42px,5vw,68px); margin-bottom: 12px; }
.home-kicker { margin-bottom: 12px; }
.home-tagline { font-size: 30px; margin-bottom: 12px; }
.home-intro-copy { line-height: 1.6; margin-bottom: 18px; max-width: 440px; }
.home-alpha { margin: 14px 0 0; font-size: 11px; }
.home-button { min-height: 42px; padding: 11px 18px; font-size: 12px; }
#auth.home-auth { padding: 20px 22px 14px; border-color: #d4bb7a35; }
#auth h2 { font-size: 25px; margin-bottom: 12px; }
#auth .home-kicker { font-size: 9px; margin-bottom: 8px; }
#auth .tabs { margin-bottom: 12px; }
#auth .tabs button { font-size: 12px; padding: 8px 0; }
#auth .tabs button[data-mode="register"] { color: #edd19a; }
#auth form { gap: 5px; }
#auth label { font-size: 11px; }
#auth input { padding: 10px; margin-bottom: 4px; font-size: 13px; }
#auth .home-button { margin-top: 5px; }
.home-auth-note { margin-top: 8px; font-size: 11px; }
.home-hero-foot { bottom: 8px; }
.home-dashboard { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; padding: 20px 5%; background: #102620; }
.home-dashboard .home-section { padding: 0; background: transparent; color: #e9dec1; min-width: 0; }
.home-section-heading { gap: 14px; margin-bottom: 12px; align-items: center; }
.home-section-heading h2 { font-size: 25px; }
.home-section-heading .home-kicker { margin-bottom: 4px; font-size: 9px; color: #c3ab7a; }
.home-text-link { font-size: 12px; }
button.home-text-link { border: 0; border-bottom: 1px solid #d8bd7e40; border-radius: 0; background: transparent; cursor: pointer; padding: 6px 0; text-align: left; }
.home-trailer { height: 176px; aspect-ratio: auto; outline: none; border: 1px solid #a99b6830; }
.home-play-mark { width: 34px; height: 34px; font-size: 25px; margin-bottom: 8px; }
.home-trailer-placeholder { padding: 12px; }
.home-trailer-placeholder h3 { font-size: 23px; margin-bottom: 7px; }
.home-trailer-placeholder .home-kicker { margin-bottom: 4px; }
.home-video-caption { margin-top: 5px; gap: 12px; }
.home-video-caption p { color: #a2b3a4; margin: 4px 0; }
.home-video-caption .home-text-link { color: #dfc68e; border-color: #aaa48045; }
.home-journal-grid { grid-template-columns: 1fr; gap: 8px; }
.journal-entry { display: grid; grid-template-columns: 78px minmax(0,1fr); gap: 14px; align-items: center; padding-bottom: 8px; border-bottom: 1px solid #9baf9230; }
.journal-entry:last-child { border: 0; padding-bottom: 0; }
.journal-art { height: 62px; border: 0; }
.journal-art span { width: 100%; height: 100%; }
.journal-art-npcs span { width: 48px; }
.journal-art-slimes span { width: 62px; }
.journal-body { padding: 0; }
.journal-meta { font-size: 9px; margin: 0 0 3px; letter-spacing: .025em; }
.journal-body h3 { font-size: 18px; margin: 0 0 3px; }
.journal-body h3 button { font: inherit; color: inherit; text-align: left; padding: 0; border: 0; background: none; border-radius: 0; cursor: pointer; }
.journal-body h3 button:hover { color: #ffe3a9; text-decoration: underline; }
.journal-body > p:not(.journal-meta) { font-size: 11px; line-height: 1.4; margin: 0; }
.home-support { padding: 12px 5%; grid-template-columns: 35px minmax(0,1fr) auto; gap: 18px; border-color: #c7b47d1c; }
.home-support-emblem { font-size: 34px; }
.home-support .home-kicker { margin-bottom: 2px; font-size: 9px; }
.home-support h2 { font-size: 23px; }
.home-support .home-support-status { margin: 4px 0 0; font-size: 11px; }
.home-button-outline { border-color: #b7a06b50; }
.home-advertisement { padding: 8px 5% 12px; }
.home-advertisement > p { margin: 0 0 6px; }
#advertisementSlot { min-height: 50px; margin-top: 0; border-color: #77906b25; }
.home-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 14px; padding: 14px 5%; }
.home-footer .home-wordmark { font-size: 14px; }
.home-footer > p { display: none; }
.home-footer > div a, .home-footer small { font-size: 11px; }
.home-archive { width: min(680px,90vw); max-height: 85dvh; overflow: auto; padding: 28px; background: #102620; color: #e9dec1; border: 1px solid #bda27370; }
.home-archive::backdrop { background: #03130ed9; }
.home-archive form { display: flex; justify-content: end; }
.home-archive form button { background: transparent; color: #ead2a0; border: 1px solid #bda27350; padding: 9px 14px; cursor: pointer; }
.home-archive h2 { font: 30px Georgia,serif; }
.home-archive article { padding: 18px 0; border-top: 1px solid #bda27330; }
.home-archive time { color: #bfa675; font-size: 12px; }
.home-archive h3 { font: 23px Georgia,serif; margin: 10px 0; }
.home-archive article p { font-size: 14px; line-height: 1.8; color: #c0cdbf; }
@media(max-width:1050px) {
  .home-dashboard { gap: 24px; }
  .home-section-heading { flex-wrap: wrap; gap: 6px; }
  #donationAction { grid-column: auto; }
  .home-intro-copy { max-width: 350px; }
}
@media(max-width:760px) {
  .home-header { height: auto; }
  .home-hero-content { grid-template-columns: 1fr; padding: 34px 0 38px; gap: 28px; }
  .home-intro h1 { font-size: clamp(36px,9vw,58px); }
  .home-intro-copy { max-width: 440px; }
  .home-alpha { line-height: 1.7; }
  #auth.home-auth { padding: 24px; }
  #auth input { font-size: 16px; }
  .home-dashboard { grid-template-columns: 1fr; gap: 30px; padding: 26px 6%; }
  .home-trailer { height: auto; aspect-ratio: 1.6; }
  .home-video-caption { flex-direction: row; align-items: center; }
  .journal-entry { grid-template-columns: 76px minmax(0,1fr); min-height: 88px; }
  .journal-body > p:not(.journal-meta) { font-size: 12px; }
  .home-support { grid-template-columns: 1fr; gap: 12px; padding: 24px 6%; }
  .home-support-emblem { display: none; }
  #donationAction { grid-column: 1; }
  .home-footer { justify-content: center; padding-block: 20px; }
  .home-archive { padding: 20px; }
}
@media(min-width:1060px) {
  .home-hero-content { padding-block: 10px 18px; }
  .home-hero-foot { bottom: 4px; }
  .home-dashboard { padding-block: 12px; }
  .home-trailer { height: 160px; }
  .journal-art { height: 54px; }
  .home-support { padding-block: 8px; }
  .home-advertisement { padding-block: 6px 8px; }
  .home-footer { padding-block: 10px; }
}

/* comfort.css */
/* Ossdarine comfort panels: no change to map geometry or combat warning layers. */
.comfort-panel { --comfort-font: 14px; font-size: var(--comfort-font); }
body[data-comfort-text="large"] .comfort-panel { --comfort-font: 16px; }
body[data-comfort-text="extra"] .comfort-panel { --comfort-font: 18px; }
body.game-active .drawer.comfort-panel { position: fixed; inset: 80px 86px 16px auto; width: min(730px, calc(100vw - 120px)); max-height: none; z-index: 42; margin: 0; padding: 26px; overflow-y: auto; overscroll-behavior: contain; border: 1px solid #a48b55; border-radius: 18px; background: linear-gradient(140deg, #1c382d, #0e231b 75%); box-shadow: 0 24px 80px #0009; color: #eee7d4; }
.comfort-panel[hidden], .comfort-panel [hidden] { display: none !important; }
.comfort-panel h2 { margin: 0 35px 18px 0; font: 500 2em/1.1 Georgia,serif; color: #f0d79d; }
.comfort-panel h3 { font: 500 1.4em/1.2 Georgia,serif; color: #efdaad; }
.comfort-panel h4 { font-size: 1.05em; margin: 0 0 .65em; color: #f5dfaa; }
.comfort-panel p, .comfort-panel label, .comfort-panel li { font-size: 1em; line-height: 1.6; }
.comfort-panel button, .comfort-panel input, .comfort-panel select { font-size: 1em; min-height: 44px; border: 1px solid #78856b; border-radius: 8px; padding: .6em .8em; background: #203b2e; color: #f6edd5; }
.comfort-panel button { font-weight: 600; }
.comfort-panel button:hover:not(:disabled) { border-color: #eccb82; background: #2e4e39; }
.comfort-panel button:disabled { opacity: .55; cursor: not-allowed; }
.comfort-panel .drawer-close { min-height: 36px; width: 36px; height: 36px; padding: 0; position: absolute; top: 16px; right: 16px; }
.comfort-panel :focus-visible, #comfortConfirm :focus-visible { outline: 3px solid #f6d994; outline-offset: 3px; }
.comfort-heading { display: flex; align-items: start; flex-wrap: wrap; gap: 12px; justify-content: space-between; }
.comfort-heading h2, .comfort-heading p { margin-bottom: 8px; }
.comfort-full { color: #ffc08f; font-weight: 700; }
.comfort-panel .comfort-muted { color: #b1c2b2; font-size: .9em; }
.comfort-toolbar { display: grid; grid-template-columns: minmax(0,1fr) minmax(120px,.5fr); gap: 12px; }
.comfort-toolbar label { display: grid; gap: 4px; }
.comfort-toolbar input, .comfort-toolbar select { width: 100%; min-width: 0; }
.comfort-filters, .comfort-tabs { display: flex; flex-wrap: wrap; gap: 7px; margin: 16px 0; }
.comfort-filters button, .comfort-tabs button { padding: .5em .7em; }
.comfort-filters [aria-pressed="true"], .comfort-tabs [aria-pressed="true"] { background: #c6a260; color: #10261b; border-color: #edd298; }
.comfort-bag-layout { display: grid; grid-template-columns: minmax(0,1fr) minmax(220px,.85fr); align-items: start; gap: 18px; }
#inventory.comfort-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; background: transparent; }
.comfort-panel .comfort-slot { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: start; gap: 7px; min-height: 112px; width: 100%; padding: 12px 6px; border: 1px solid #62785b; background: linear-gradient(#2b4835,#173124); text-align: center; }
.comfort-slot.selected { box-shadow: inset 0 0 0 2px #e6c888; }
.comfort-slot .comfort-icon { font-size: 28px; line-height: 1.2; }
.comfort-slot strong { font-size: .8em; overflow-wrap: anywhere; }
.comfort-quantity { font: 700 .85em/1.2 system-ui,sans-serif; color: #fff1c7; }
.comfort-badges { display: grid; gap: 3px; font-size: .66em; color: #ffdf94; }
.comfort-empty { display: grid; place-items: center; min-height: 85px; border: 1px dashed #4c6351; border-radius: 9px; color: #8b9c77; background: #0c201788; }
.comfort-item-detail { border: 1px solid #ad925a77; padding: 18px; border-radius: 12px; background: #0c1e16; }
.comfort-item-detail h3 { margin: 8px 0; overflow-wrap: anywhere; }
.comfort-item-detail button { width: 100%; margin-top: 8px; }
.comfort-category { color: #c8b783; letter-spacing: .08em; font-size: .8em !important; }
.comfort-detail-symbol { color: #cfb779; font-size: 38px; }
.comfort-comparison { margin: 8px 0; }
.comfort-comparison div, .comfort-stats div { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: .55em 0; border-bottom: 1px solid #88987744; }
.comfort-comparison dd, .comfort-stats dd { margin: 0; }
.comfort-panel .gain { color: #a6e5b1; }.comfort-panel .loss { color: #ffb8a5; }
.comfort-panel .comfort-danger { color: #ffd0bd; border-color: #ac7760; }
.comfort-character-layout { display: grid; grid-template-columns: 170px minmax(0,1fr); gap: 18px; }
.comfort-portrait { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 230px; padding: 18px; border: 1px solid #8f805455; border-radius: 13px; text-align: center; background: radial-gradient(ellipse at center,#426342,#11251c 72%); }
.comfort-portrait .character-sprite { position: relative; flex: 0 0 91px; width: 68px; height: 91px; transform: none; margin: 8px auto; }
.comfort-portrait h3 { margin: 14px 0 5px; overflow-wrap: anywhere; }.comfort-portrait p { margin: 3px; }
.comfort-equipment-slots { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.comfort-equipment-slots button { display: grid; gap: 6px; text-align: left; min-width: 0; overflow-wrap: anywhere; }
.comfort-equipment-slots span { color: #d6c693; font-size: .85em; }.comfort-equipment-slots strong { font-size: .9em; }.comfort-equipment-slots small { color: #b8c4ae; font-size: .8em; }
.comfort-owned { display: flex; flex-wrap: wrap; gap: 8px; }
.comfort-profile { border-top: 1px solid #81906955; margin-top: 22px; padding-top: 18px; }
.comfort-profile summary { min-height: 44px; cursor: pointer; color: #f0d79d; }
.comfort-profile #profile { display: grid; width: 100%; max-width: none; text-align: left; }
.comfort-setting { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px 0; border-bottom: 1px solid #7b8e7155; }
.comfort-setting select { min-width: 115px; max-width: 50%; }.comfort-setting input[type="checkbox"] { flex: 0 0 24px; width: 24px; height: 24px; min-height: 24px; accent-color: #ccab69; }
.comfort-panel .account-actions { grid-template-columns: 1fr; }.comfort-panel #password { margin-bottom: 18px; }
.comfort-panel #comfortReset { margin-top: 16px; }
#comfortConfirm { width: min(460px,calc(100vw - 28px)); border: 1px solid #d6ba7a; border-radius: 16px; background: #162e22; color: #f1e5c8; padding: 25px; box-shadow: 0 20px 80px #000b; }
#comfortConfirm::backdrop { background: #07140dc9; }#comfortConfirm h2 { font: 26px Georgia,serif; }#comfortConfirm p { line-height: 1.7; overflow-wrap: anywhere; }.comfort-dialog-actions { display: flex; gap: 12px; justify-content: end; }.comfort-dialog-actions button { min-height: 44px; padding: 10px 18px; background: #294636; border: 1px solid #b29b65; color: #f5e6c2; border-radius: 8px; }
#npcWorkshop .comfort-market-card, #npcWorkshop .comfort-recipe { padding: 18px; margin-bottom: 12px; border: 1px solid #8c885555; border-radius: 12px; background: #11291c; }
.comfort-market-card label { display: flex; align-items: center; gap: 12px; }.comfort-market-card input { width: 100px; min-height: 44px; }.comfort-market-card button, .comfort-recipe button { min-height: 44px; padding: 8px 14px; margin: 5px 8px 0 0; border: 1px solid #b9a16d; border-radius: 8px; background: #254834; color: #f1dfb5; }.comfort-market-card button:disabled,.comfort-recipe button:disabled { opacity: .5; }.comfort-recipe li { margin: 7px 0; }
body.comfort-hide-monster-names .monster:not(:hover):not(:focus-visible):not(.targeted) .slime-name { visibility: hidden; }
body.comfort-hide-monster-levels .monster:not(:hover):not(:focus-visible):not(.targeted) .slime-level { visibility: hidden; }
body.comfort-no-particles .ambient-particles { display: none; }
body.comfort-reduced-motion .ambient-particles *, body.comfort-reduced-motion .river, body.comfort-reduced-motion .character-sprite.state-idle { animation: none !important; }
@media(prefers-reduced-motion:reduce) { .comfort-portrait .character-sprite { animation: none !important; } }
@media(max-width:650px) {
  body.game-active .drawer.comfort-panel { inset: 66px 70px 12px 8px; width: auto; padding: 20px 14px; border-radius: 13px; }
  .comfort-bag-layout { grid-template-columns: 1fr; }.comfort-character-layout { grid-template-columns: 1fr; }.comfort-portrait { min-height: 180px; }.comfort-toolbar { grid-template-columns: 1fr; }
  #inventory.comfort-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }.comfort-equipment-slots { grid-template-columns: 1fr 1fr; }
  .comfort-panel .comfort-setting { flex-wrap: wrap; }.comfort-panel .comfort-setting select { max-width: 100%; }
}
@media(max-height:450px) { body.game-active .drawer.comfort-panel { top: 8px; bottom: 8px; }.comfort-portrait { min-height: 150px; } }

body.game-active .drawer.comfort-panel { transform: none; z-index: 110; }
body.game-active #notice { z-index: 200; }

/* Explicit active styles outrank inherited panel button backgrounds. */
#comfortFilters button[aria-pressed="true"], .comfort-tabs button[aria-pressed="true"] { background: #d4b16f; color: #10261b; border-color: #f3d49b; }
@media (max-width:650px) {
  .comfort-panel>.eyebrow { margin: 0 36px 10px 0; font-size: 11px; }
  .comfort-heading { display: block; }
  .comfort-heading h2 { margin-bottom: 8px; font-size: 26px; }
  .comfort-heading #inventoryCapacity { margin: 0; font-size: 12px; }
  .comfort-panel #gold { margin: 8px 0 12px; }
  .comfort-toolbar { grid-template-columns: minmax(0,1fr) 112px; gap: 8px; }
  .comfort-toolbar label { font-size: 12px; }
  .comfort-filters { gap: 5px; margin: 12px 0; }
  .comfort-filters button { font-size: 11px; min-height: 44px; }
}

/* storage.css */
.personal-chest { position:absolute; width:60px; height:55px; padding:0; border:0; border-radius:8px; background:transparent; transform:translate(-50%,-94%); cursor:pointer; overflow:visible; }
.personal-chest[hidden] { display:none; }
.personal-chest svg { display:block; width:100%; height:100%; overflow:visible; filter:drop-shadow(0 2px 2px #102518bb); }
.personal-chest:hover,.personal-chest:focus-visible { background:transparent; outline:2px solid #f1d588; outline-offset:5px; }
.personal-chest .chest-lid { transform-origin:70px 35px; transition:transform .18s ease; }
.personal-chest.is-open .chest-lid { transform:translateY(-5px) rotate(-7deg); }
.personal-chest-label { position:absolute; left:50%; top:100%; transform:translateX(-50%); display:block; width:max-content; max-width:135px; padding:4px 7px; border:1px solid #cba35d88; border-radius:7px; background:#12291fec; color:#ffe8ad; font:700 11px/1.3 system-ui,sans-serif; pointer-events:none; }
.personal-chest-label small { display:block; font-size:9px; color:#dae0cc; }
.storage-dialog { width:min(960px,calc(100vw - 24px)); max-width:calc(100vw - 24px); max-height:calc(100dvh - 24px); padding:24px; border:1px solid #c4a269; border-radius:18px; margin:auto; overflow:auto; background:linear-gradient(150deg,#20382d,#0b1d17); color:#ede6d3; box-shadow:0 20px 70px #000a; box-sizing:border-box; }
.storage-dialog::backdrop { background:#04120ab0; backdrop-filter:blur(3px); }
.storage-dialog[open] { display:block; }
.storage-dialog:not([open]) { display:none; }
.storage-header { display:flex; align-items:start; justify-content:space-between; gap:12px; }
.storage-header h2 { margin:0; color:#f1d999; font:500 28px/1.1 Georgia,serif; }
.storage-header .eyebrow { font-size:9px; }
#storageClose { min-width:44px; min-height:44px; padding:0; font-size:23px; background:#284635; border:1px solid #ceb17a88; border-radius:9px; color:#f5dfad; }
#storageStatus { min-height:1.5em; padding:10px 12px; border-radius:8px; background:#061910aa; color:#d5e3cb; font-size:13px; overflow-wrap:anywhere; }
.storage-containers { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
.storage-containers.bag-only { grid-template-columns:1fr; }
.storage-container { min-width:0; border:1px solid #b698594d; padding:12px; border-radius:12px; background:#10251d; }
.storage-container-heading { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:12px; }
.storage-container-heading h3 { color:#efd398; font-size:17px; margin:0; }
.storage-container-heading>span { flex-shrink:0; font-size:12px; }
.storage-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; margin-bottom:12px; }
.bag-only .storage-grid { grid-template-columns:repeat(6,minmax(0,1fr)); }
.storage-slot { position:relative; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:4px; width:100%; min-width:0; min-height:102px; border:1px solid #96734488; background:linear-gradient(155deg,#294332,#15291f); border-radius:9px; padding:17px 4px 8px; color:#eae1cb; }
.storage-slot strong { font:600 11px/1.25 system-ui,sans-serif; overflow-wrap:anywhere; }
.storage-slot>span:last-child { font-size:11px; }
.storage-slot[draggable=true] { cursor:grab; }
.storage-slot.empty { background:#091c14; border-style:dashed; color:#769080; }
.storage-slot.empty>span:first-of-type { font-size:25px; }
.storage-slot.selected { border:2px solid #f5d88e; background:#3b4c2c; }
.storage-slot.destination:not(:disabled):hover { outline:2px solid #ade0b1; outline-offset:1px; }
.storage-slot:focus-visible { outline:3px solid #ffe6a7; outline-offset:2px; }
.storage-index { position:absolute; top:4px; left:6px; color:#a9bcac; font-size:10px; }
.storage-item-icon { font-size:26px; line-height:1.1; pointer-events:none; }
.storage-selection { margin-top:18px; padding:16px; border:1px solid #bda16a66; border-radius:12px; background:#182f23; }
.storage-selection h3 { margin:0 0 10px; color:#ffe2a0; font-size:19px; }
.storage-selection p,.storage-footer p { font-size:12px; line-height:1.65; color:#b7c8b8; }
.storage-selection-actions { display:flex; flex-wrap:wrap; align-items:end; gap:10px; }
.storage-selection-actions label { display:grid; gap:7px; font-size:12px; max-width:180px; }
.storage-selection-actions input { width:100%; min-height:44px; box-sizing:border-box; }
.storage-dialog button:not(.storage-slot):not(#storageClose),#organizeBag { min-height:44px; white-space:normal; padding:10px 12px; background:#2a4936; border:1px solid #a88b5599; border-radius:8px; color:#f1ddb0; font-weight:600; font-size:12px; }
#organizeBag { margin-bottom:12px; width:100%; }
.storage-dialog button:disabled { opacity:.5; cursor:not-allowed; }
.storage-footer { display:flex; align-items:center; gap:18px; margin-top:18px; }
@media(max-width:700px) { .storage-containers { grid-template-columns:1fr; } .bag-only .storage-grid { grid-template-columns:repeat(3,minmax(0,1fr)); } .storage-dialog { padding:14px; } .storage-header h2 { font-size:23px; } }
@media(max-width:380px) { .storage-container { padding:9px; } .storage-grid { gap:5px; } .storage-slot { min-height:100px; } .storage-selection { padding:12px; } .storage-selection-actions>* { width:100%; max-width:none!important; } .storage-footer { flex-direction:column; align-items:stretch; gap:4px; } }
@media(prefers-reduced-motion:reduce) { .personal-chest .chest-lid { transition:none; } }
/* Override generic page-header and button spacing inside the storage dialog. */
.storage-header { position:static; padding:0; margin:0; min-height:0; background:transparent; border:0; }
.storage-dialog .storage-slot { padding:17px 4px 8px; }
.storage-footer { padding:0; background:transparent; border:0; }

/* dungeons.css */
.dungeon-panel { position:absolute; z-index:9; right:1.5rem; top:1.5rem; width:min(300px,calc(100% - 3rem)); padding:1rem; border:2px solid #d9a94d; border-radius:12px; background:#100d16ee; color:#f8edcf; box-shadow:0 10px 30px #000a; }
.dungeon-panel h3,.dungeon-panel p { margin:.25rem 0 .65rem; }.dungeon-panel small { display:block;color:#cbbd9c }.dungeon-panel button { margin:.25rem .25rem 0 0;padding:.55rem .75rem;border:1px solid #d9a94d;border-radius:7px;background:#352042;color:#fff3cc; }
.dungeon-gate { position:absolute;left:60%;top:50%;translate:-50% -50%;width:76px;height:96px;border:5px solid #d9a94d;border-radius:50% 50% 42% 42%;background:radial-gradient(ellipse,#7e50a6 0 24%,#09070d 60%);box-shadow:0 0 22px #e2b957aa,inset 0 0 18px #000;z-index:4;color:#ffe9a7;font-size:1.5rem; }
.world-dungeon-gate{left:80%;border-color:#c9d3ff;background:radial-gradient(ellipse,#46608f 0 24%,#05070e 60%)}
.zone-dungeon { background:radial-gradient(circle at 50% 45%,#523b5d,#18141e 70%)!important;background-image:repeating-radial-gradient(ellipse at center,#ffffff08 0 4px,transparent 5px 35px)!important;border-color:#6d526f!important;box-shadow:inset 0 0 90px #050307!important; }
.zone-dungeon #villageScene, .zone-dungeon #mapBuildings, .zone-dungeon .zone-decor, .zone-dungeon .ambient-particles { display:none!important; }
.dungeon-stairs { position:absolute;z-index:4;top:50%;translate:-50% -50%;padding:.8rem;border:2px solid #c99f4d;border-radius:9px;background:#271b30;color:#fff0ba }.dungeon-stairs.previous{left:8%}.dungeon-stairs.next{left:88%}.dungeon-leave{position:absolute;z-index:4;left:50%;top:84%;translate:-50% -50%;padding:.6rem;border:1px solid #b88b48;border-radius:8px;background:#171019;color:#f8edcf}
@media(max-width:600px){.dungeon-panel{top:.75rem;right:.75rem;width:min(260px,calc(100% - 1.5rem));font-size:.82rem}}
@media(prefers-reduced-motion:reduce){.dungeon-gate{animation:none}}
#dungeonScene{position:absolute;inset:0;pointer-events:none}.dungeon-walls,.dungeon-fog-grid{position:absolute;inset:0;pointer-events:none}.dungeon-wall{position:absolute;display:block;background:linear-gradient(135deg,#253c34,#18261f 45%,#5d7d56);border:1px solid #83c87a;box-shadow:0 0 12px #83ff9670,inset 0 0 9px #07110b;z-index:3}.dungeon-fog-grid{display:grid;grid-template-columns:repeat(10,1fr);grid-template-rows:repeat(8,1fr);top:12%;bottom:12%;z-index:7}.dungeon-fog{background:#05070a;transition:opacity .25s}.dungeon-fog.visible{opacity:0}.dungeon-fog.remembered{opacity:.58;background:#17221e}.dungeon-fog.unknown{opacity:.96}.dungeon-secret{pointer-events:auto;position:absolute;translate:-50% -50%;z-index:8;width:42px;height:42px;border:2px solid #e3c35c;border-radius:45%;background:radial-gradient(circle,#dcff87,#315d45 48%,#15151b);color:#fff4a6;box-shadow:0 0 18px #baff82}.dungeon-secret.opened{filter:grayscale(.7);opacity:.7}.dungeon-minimap{position:absolute;left:1rem;bottom:1rem;width:150px;height:92px;display:grid;grid-template-columns:repeat(10,1fr);grid-template-rows:repeat(8,1fr);z-index:10;border:2px solid #d9a94d;background:#0a0d0c;padding:3px;box-shadow:0 5px 18px #000}.dungeon-minimap .dungeon-fog{position:static;border:1px solid #35463b}.dungeon-minimap .visible{background:#86d982;opacity:.85}.dungeon-minimap .remembered{background:#46584c;opacity:.75}.dungeon-minimap .unknown{background:#090b0a;opacity:1}

.dungeon-x-26{left:26%}.dungeon-x-38{left:38%}.dungeon-x-42{left:42%}.dungeon-x-45{left:45%}.dungeon-x-48{left:48%}.dungeon-x-52{left:52%}.dungeon-x-61{left:61%}.dungeon-x-76{left:76%}.dungeon-y-12{top:12%}.dungeon-y-25{top:25%}.dungeon-y-38{top:38%}.dungeon-y-43{top:43%}.dungeon-y-46{top:46%}.dungeon-y-49{top:49%}.dungeon-y-54{top:54%}.dungeon-y-60{top:60%}.dungeon-y-66{top:66%}.dungeon-w-4{width:4%}.dungeon-w-16{width:16%}.dungeon-h-4{height:4%}.dungeon-h-22{height:22%}.dungeon-h-24{height:24%}.dungeon-h-25{height:25%}.dungeon-h-28{height:28%}.dungeon-h-34{height:34%}
.dungeon-y-57{top:57%}.dungeon-y-63{top:63%}.dungeon-y-69{top:69%}.dungeon-h-19{height:19%}.dungeon-h-31{height:31%}

.dungeon-secret-passage{position:absolute;translate:-50% -50%;z-index:8;color:#cfff9b;font-size:2rem;text-shadow:0 0 12px #8fff7c}.dungeon-clue{color:#dfffad;font-style:italic}.dungeon-x-32{left:32%}.dungeon-x-40{left:40%}.dungeon-x-42{left:42%}.dungeon-x-46{left:46%}.dungeon-y-14{top:14%}.dungeon-y-20{top:20%}.dungeon-y-30{top:30%}.dungeon-y-31{top:31%}.dungeon-y-39{top:39%}.dungeon-w-2{width:2%}.dungeon-w-10{width:10%}.dungeon-h-2{height:2%}.dungeon-h-18{height:18%}

.dungeon-x-44{left:44%}
.dungeon-instability{margin:.55rem 0}.dungeon-instability span,.dungeon-instability small{display:block}.dungeon-instability i{display:block;height:7px;margin:.3rem 0;border:1px solid #655378;border-radius:9px;background:#09070d;overflow:hidden}.dungeon-instability i b{display:block;height:100%;background:linear-gradient(90deg,#7cd889,#d9a94d,#bd4f80)}
.dungeon-loot{pointer-events:auto;position:absolute;translate:-50% -50%;z-index:8;padding:.35rem .5rem;border:1px solid #ffe08a;border-radius:999px;background:#33250d;color:#fff1ad;box-shadow:0 0 15px #ffd96999}
.dungeon-rupture-timer{display:block;margin:.5rem 0;color:#ff6b72;text-shadow:0 0 9px #b00030}
.monster-player-ghost{filter:grayscale(.45) hue-rotate(155deg);opacity:.82;text-shadow:0 0 12px #b9e9ff}

/* storybook.css */
/* The illustrated renderer is the only game appearance. */
.storybook-character { display: none; width: 68px; height: 91px; pointer-events: none; image-rendering: auto; }
.storybook-preview .character-sprite[data-storybook-ready] { background-image: none !important; animation: none !important; }
.storybook-preview .character-sprite[data-storybook-ready] > .storybook-character { display: block; }
.storybook-preview .character-sprite[data-storybook-loading] { background-image:none!important; }
.storybook-preview .character-sprite:is([data-storybook-loading],[data-storybook-failed]):not([data-storybook-ready])::after { content:'';position:absolute;left:23px;bottom:2px;width:22px;height:6px;border:1px solid #dfcf9b88;border-radius:50%;background:#182e2866; }

.storybook-preview #map .pawn:has([data-storybook-ready]) { background: transparent !important; }
.storybook-preview #map.zone-village .character-renderer { scale: .82; }
.storybook-preview .player-hud { width: 306px; background: #19372df2; border-color: #cbb787; box-shadow: 0 8px 30px #0c221d33; }
.storybook-preview .player-hud .hud-portrait { background: radial-gradient(ellipse at 50% 35%, #668156, #1b3c32); }
.storybook-preview .side-tools button { border-radius: 13px; background: #19372df2; border: 1px solid #cbb78799; box-shadow: 0 4px 15px #0c221d25; }
.storybook-preview .drawer { background: linear-gradient(150deg, #203d33fa, #142e29fa); border: 1px solid #cbb78799; border-radius: 17px; }

.storybook-preview .npc-sprite[data-storybook-npc] { bottom: 0; background: none !important; animation: none !important; image-rendering: auto; }
.storybook-npc { position: absolute; bottom: 0; left: -4px; width: 72px; height: 74px; pointer-events: none; transform-origin: 50% 100%; }
.storybook-preview .npc-character .storybook-npc { animation: storybook-npc-breathe 4.8s ease-in-out var(--npc-delay, 0s) infinite; }
.storybook-preview .npc-character > strong { background: #203b30ed; border-color: #d1bf87aa; border-radius: 7px; font-weight: 500; }
.storybook-preview #npcPanel { background: linear-gradient(140deg, #243f33fa, #152d27fc); border: 1px solid #cbb787aa; border-radius: 18px; box-shadow: 0 16px 45px #0b201955; }
.storybook-preview .npc-portrait:has([data-storybook-npc]) { width: 112px; height: 118px; margin-bottom: 14px; }
.storybook-preview .npc-portrait [data-storybook-npc] { left: 24px; bottom: 0; transform: scale(1.5); transform-origin: 50% 100%; }
@keyframes storybook-npc-breathe { 50% { transform: scaleY(1.012); } }
@media (prefers-reduced-motion: reduce) { .storybook-preview .npc-character .storybook-npc { animation: none; } }
.storybook-preview .comfort-reduced-motion .npc-character .storybook-npc { animation: none; }
@media (max-width:600px) {
  .storybook-preview .player-hud { width: 265px; max-width: calc(100vw - 82px); }
  .storybook-preview .side-tools button { border-radius: 10px; }
}

/* season-pass.css */
#seasonPanel { --season-gold: #d9bd78; }
.season-header { display:flex; justify-content:space-between; align-items:end; gap:24px; margin:18px 0 22px; }
.season-header h2 { font:500 clamp(30px, 4vw, 48px)/1.08 Georgia,serif; margin:8px 0; }
.season-header p { margin:5px 0; color:#c8d3b7; }
.season-progress { min-width:220px; display:grid; gap:8px; color:#f2e3b8; }
.season-progress strong { font:500 23px Georgia,serif; }
.season-progress small { color:#d0d7c0; }
.season-progress progress { width:100%; height:13px; accent-color:#dbc77e; }
.season-upcoming { padding:10px 16px; border:1px solid #c3a66b66; border-radius:8px; background:#294639; }
.season-layout { display:grid; grid-template-columns:minmax(0,1fr) 255px; gap:16px; }
.season-map { position:relative; min-height:510px; overflow:hidden; border:10px solid #5f5a3a; border-radius:22px; box-shadow:inset 0 0 0 2px #d6b675, 0 15px 45px #0008; background:linear-gradient(180deg,#e3cf9b80,#4277542b 35%,#16372845 85%),url('/assets/storybook/world/forest-paths-v2.webp') center/cover; }
.season-map::after { content:''; pointer-events:none; position:absolute; inset:0; box-shadow:inset 0 0 80px #071e18a8; }
.season-map-village,.season-map-ruins { position:absolute; z-index:1; top:26%; color:#ffe6ac; font:50px Georgia,serif; text-shadow:0 5px 4px #1a271e,0 0 16px #e5c67c; }
.season-map-village { left:3%; } .season-map-ruins { right:3%; }
.season-track-label { position:absolute; z-index:4; left:50%; transform:translateX(-50%); padding:6px 14px; border:1px solid #dec58296; border-radius:20px; color:#f9eac1; background:#142a21e9; white-space:nowrap; font:600 14px Georgia,serif; letter-spacing:.08em; }
.season-track-label.free { top:7%; } .season-track-label.paid { bottom:7%; }
.season-track-label small { font:11px system-ui,sans-serif; letter-spacing:normal; color:#c8d2bc; margin-left:8px; }
.season-path { position:absolute; inset:0; width:100%; height:100%; z-index:1; overflow:visible; filter:drop-shadow(0 3px 3px #14271d); }
.season-path path { fill:none; stroke:#ecd29a; stroke-width:1.7; stroke-linecap:round; stroke-dasharray:1.3 .7; }
.season-step { position:absolute; z-index:3; left:var(--x); top:var(--y); transform:translate(-50%,-50%); display:grid; place-items:center; width:35px; height:35px; border:2px solid #e7ce8a; border-radius:50%; color:#fff1c9; font:700 17px Georgia,serif; text-shadow:0 2px 3px #000; background:#253a2d; box-shadow:0 3px 8px #071a16; }
#seasonPanel .season-reward { position:absolute; z-index:4; left:var(--x); top:calc(var(--y) - 105px); transform:translate(-50%,-50%); padding:0; width:58px; height:58px; min-height:0; display:grid; place-items:center; border-radius:50%; border:2px solid #bbdc9b; background:radial-gradient(circle,#456a4d,#193e2b); box-shadow:0 0 12px #bce29285,0 4px 10px #061810; font-size:27px; }
#seasonPanel .season-reward.paid { top:calc(var(--y) + 105px); border-color:#e3be72; background:radial-gradient(circle,#725539,#2a261e); box-shadow:0 0 12px #e3bb7680,0 4px 10px #061810; }
#seasonPanel .season-reward.locked { filter:saturate(.7); opacity:.83; }
#seasonPanel .season-reward.claimed { box-shadow:0 0 18px #c3eb9f,0 4px 10px #061810; }
#seasonPanel .season-reward.landmark { width:70px; height:70px; font-size:36px; }
#seasonPanel .season-reward:focus-visible { outline:3px solid white; outline-offset:4px; }
.season-traveler { position:absolute; z-index:5; width:46px; height:61px; transform:translate(-50%,-92%); transition:left 1.1s ease,top 1.1s ease; pointer-events:none; filter:drop-shadow(0 4px 3px #102315); }
.season-traveler .character-sprite { transform:scale(.52); transform-origin:0 0; animation:none; }
.season-map-controls { position:absolute; z-index:6; bottom:8%; left:50%; transform:translateX(-50%); display:flex; align-items:center; gap:10px; color:#f1e5be; background:#142b22e9; padding:4px 9px; border-radius:18px; white-space:nowrap; }
#seasonPanel .season-map-controls button { padding:4px 10px; min-height:32px; border:0; border-radius:50%; }
.season-detail { padding:24px 18px; border:1px solid #c2a36d; border-radius:12px; background:linear-gradient(155deg,#244536,#152d25); box-shadow:inset 0 0 35px #0b1d19; }
.season-detail h3 { font:500 26px Georgia,serif; margin:8px 0 28px; }
.season-detail-eyebrow { color:#d3bd80; font-size:11px; letter-spacing:.13em; }
.season-detail-item { border-top:1px solid #8eac826a; padding:18px 0; display:grid; gap:12px; }
.season-detail-item.paid { border-color:#cfad6c8c; }
.season-detail-item small { color:#d0e5bb; font-weight:700; letter-spacing:.08em; }
.season-detail-item.paid small { color:#e7ca8c; }
.season-detail-item strong { font:500 20px Georgia,serif; }
.season-detail-item p { font-size:13px; margin:0; }
.season-detail-item button { font-size:13px; padding:8px; }
.season-choices { display:grid; gap:8px; border:0; padding:0; margin:0; }
.season-choices legend { font-size:12px; margin-bottom:8px; }
.season-choices label { display:flex; gap:7px; font-size:12px; align-items:center; cursor:pointer; }
.season-help { color:#c9d6bf; font-size:13px; margin:18px 0; }
@media (max-width:850px) { .season-layout { grid-template-columns:1fr; } .season-detail { display:grid; grid-template-columns:1fr 1fr; gap:14px; } .season-detail h3,.season-detail-eyebrow { grid-column:1/-1; } }
@media (max-width:600px) { .season-header { align-items:stretch; flex-direction:column; } .season-map { min-height:420px; } #seasonPanel .season-reward { width:42px; height:42px; font-size:20px; top:calc(var(--y) - 82px); } #seasonPanel .season-reward.paid { top:calc(var(--y) + 82px); } #seasonPanel .season-reward.landmark { width:50px; height:50px; font-size:25px; } .season-step { width:27px; height:27px; font-size:13px; } .season-detail { display:block; } .season-track-label { font-size:11px; } }
@media (prefers-reduced-motion:reduce) { .season-traveler { transition:none; } }

/* world-routes.css */
/* Warm paper and forest leather carry the existing village interface into exploration. */
#worldAtlasButton{white-space:normal;color:#f2e5bc}
.game-shell.scene-changing::after{content:'Les routes s’ouvrent…';position:fixed;inset:76px 0 0;z-index:300;display:grid;place-items:center;background:#17382bf5;color:#eedbb3;font:25px Georgia;pointer-events:all}
.routes-dialog{width:min(1220px,96vw);max-width:96vw;max-height:94dvh;padding:0;border:1px solid #bea269;border-radius:16px;background:#182f28;color:#eee4c7;box-shadow:0 25px 80px #081b1ed9;overflow:auto}
.routes-dialog::backdrop{background:#0b181dcc;backdrop-filter:blur(3px)}
.routes-dialog header{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:20px 26px;border-bottom:1px solid #c7b87950;background:url('/assets/storybook/ui/forest-leather.webp') center/cover}
.routes-dialog h2{font:30px/1.1 Georgia,serif;margin:6px 0;color:#f5e6ba}.routes-dialog header small{letter-spacing:2px;color:#d1c38d;font-size:10px}
.routes-dialog button{min-height:44px;border:1px solid #a7925e;border-radius:7px;background:#304a37;color:#f6ecd0;padding:9px 14px;cursor:pointer;font:600 13px system-ui}
.routes-dialog button:hover{background:#405d3f}.routes-dialog button:disabled{opacity:.55;cursor:not-allowed}.routes-dialog button:focus-visible{outline:3px solid #f9dd86;outline-offset:3px}
.routes-dialog button[aria-pressed=true]{border-color:#ffe3a1;box-shadow:inset 0 0 0 1px #ffe3a1}
.routes-dialog .atlas-route-choice[aria-pressed=true],.routes-dialog .atlas-pin[aria-pressed=true]{background:#756039;color:#fff3d0;border-color:#ffe3a1;box-shadow:0 0 0 2px #f9dc92,0 5px 14px #081b1dad}
.routes-dialog .atlas-back{display:block;margin-top:10px;background:transparent;color:#334b35;border-color:#806c4c}
.atlas-route-list{display:flex;gap:8px;overflow-x:auto;overscroll-behavior-inline:contain;scrollbar-color:#9b8758 #203b31;padding:10px 16px;background:#213b31;border-bottom:1px solid #bba56c55}
.routes-dialog .atlas-route-choice{flex:none;display:flex;align-items:center;gap:7px;max-width:165px;min-height:40px;padding:6px 10px;background:#294437;font-size:12px;white-space:nowrap}
.atlas-route-choice span{font:18px Georgia,serif}.routes-dialog .atlas-route-choice.unknown{border-style:dashed;color:#d6d3bd}.routes-dialog .atlas-route-choice.locked{color:#d8c5ab}.routes-dialog .atlas-route-choice.visited{color:#fff0c0}
.atlas-layout{display:grid;grid-template-columns:minmax(0,1fr) 275px}.atlas-scroll{overflow:auto;background:#183529}.atlas-land{position:relative;min-width:620px;aspect-ratio:3/2}.atlas-land>img{width:100%;height:100%;object-fit:cover;display:block}.atlas-pins{position:absolute;inset:0;pointer-events:none}
.routes-dialog .atlas-pin{position:absolute;translate:-50% -50%;padding:3px 6px;background:#18342de8;min-width:42px;max-width:134px;pointer-events:auto;border-radius:12px;box-shadow:0 3px 6px #10251c80;font-size:11px}.atlas-pin b{display:block;font:20px Georgia}.atlas-pin span{display:block;line-height:1.25}.atlas-pin.unknown{background:#293c3cec;color:#dbd9c5;border-style:dashed}.atlas-pin.locked{color:#d8c5ab}.atlas-pin.visited{background:#2e5033e8;color:#fff0c0}
.atlas-detail{padding:24px 20px;background:#eee1c2 url('/assets/storybook/ui/vellum.webp') center/cover;color:#293827}.atlas-detail h3{font:28px/1.1 Georgia;margin:9px 0 16px}.atlas-detail p{font:14px/1.6 system-ui}.atlas-detail>small,.atlas-specialty small{font:10px system-ui;letter-spacing:1.4px;text-transform:uppercase}.atlas-specialty{border-block:1px solid #806c4c50;padding:13px 0}.atlas-specialty strong{display:block;margin-top:8px;font:17px Georgia}.atlas-portrait{height:85px;width:70px;margin:8px auto}.atlas-portrait .character-sprite{position:relative;display:block;width:70px;height:90px}.routes-note{font-size:12px!important;opacity:.8}
.routes-dialog footer{display:flex;gap:14px;flex-wrap:wrap;align-items:center;padding:14px 24px;border-top:1px solid #9c9d6655}.atlas-legend{flex:1;min-width:230px;font-size:12px;margin:0}.routes-dialog [data-recall-status]{font-size:12px;color:#cfceb3}
.routes-workshop{width:min(870px,95vw)}.routes-work-content{padding:20px 26px;display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:22px}.routes-work-content h3{font:23px Georgia;margin:0 0 14px;color:#e6d09a}.routes-work-content article{background:#eee1c2 url('/assets/storybook/ui/vellum.webp') center/cover;color:#293827;padding:17px;margin-bottom:14px;border-radius:10px}.routes-work-content h4{font:20px Georgia;margin:0 0 10px}.routes-work-content p{font-size:13px;line-height:1.5}.route-ingredients{padding:0;list-style:none;font-size:13px}.route-ingredients li{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:9px 0}.route-ingredients li:not(.enough) b{color:#9a361f}.route-ingredients small{display:block;font-size:10px;opacity:.8}.route-dye-options{display:flex;gap:8px;flex-wrap:wrap}.routes-npc-button{margin-top:10px!important;width:100%}
#regionalResources{display:contents}#map .regional-resource{position:absolute;width:105px;height:115px;min-height:0;translate:-50% -85%;border:0;padding:0;background:none;box-shadow:none;cursor:pointer;overflow:visible}
.resource-art{position:absolute;inset:0;background-image:url('/assets/storybook/regions/resources.webp');background-size:400% 300%;background-repeat:no-repeat;filter:drop-shadow(1px 5px 3px #1b241c55)}
.resource-label{position:absolute;bottom:103%;left:50%;translate:-50% 0;white-space:nowrap;background:#18352ceb;border:1px solid #bfa877;border-radius:5px;padding:5px 8px;color:#f6e8bc;font:12px system-ui;opacity:0;pointer-events:none}.regional-resource:hover .resource-label,.regional-resource:focus-visible .resource-label,.regional-resource.near .resource-label{opacity:1}
.regional-resource:focus-visible{outline:2px solid #f5dca1;border-radius:50%}#map .regional-resource.resting{filter:saturate(.25);opacity:.5}.regional-resource.resting .resource-art{scale:.65;transform-origin:50% 90%}
#map .regional-resource.fishing{width:95px;height:58px;translate:-50% -20%}.fishing-water{display:block;position:absolute;inset:10%;border:2px solid #d5eeebcc;border-radius:50%;box-shadow:0 0 0 9px #d7f4ed30,inset 0 0 0 8px #d7f4ed20;transform:scaleY(.6)}.regional-resource.near .fishing-water{animation:route-water 2.5s ease-in-out infinite}
.resource-action{position:absolute;z-index:80;left:50%;bottom:24px;translate:-50% 0;width:min(390px,calc(100vw - 24px));background:#19352df5;border:1px solid #c1ab72;border-radius:13px;padding:17px 20px;color:#f7e9c6;box-shadow:0 10px 35px #0a201780}.resource-action strong{font:22px Georgia}.resource-action p{font:14px system-ui;margin:10px 0}.resource-action progress{width:100%;height:9px;accent-color:#c7b36b}.resource-action>div{display:flex;gap:12px;margin-top:12px}.resource-action button{min-height:44px;padding:8px 18px}.resource-action.bite{border-color:#ffe59e}.resource-action.bite [data-finish]{background:#e3c16f;color:#182a22}
#map .portal.ancient-gate{width:205px;height:205px}#map .portal.regional-return{width:190px;height:190px}
@keyframes route-water{50%{opacity:.55;scale:1.08}}
.resource-action button{border:1px solid #bfa877;border-radius:7px;background:#304a37;color:#f6ecd0;cursor:pointer}.resource-action button:disabled{opacity:.55;cursor:not-allowed}
@media(max-width:850px){.atlas-layout{grid-template-columns:minmax(0,1fr)}.atlas-scroll{width:100%}.atlas-detail{display:block;padding:18px}.atlas-portrait{display:none}.atlas-detail p{margin:9px 0}.atlas-land{min-width:620px}.routes-dialog h2{font-size:24px}.routes-dialog header{padding:16px}.routes-work-content{padding:16px;grid-template-columns:1fr}.routes-dialog footer{padding:14px;gap:10px}.atlas-legend{flex-basis:100%}}
@media(prefers-reduced-motion:reduce){.regional-resource.near .fishing-water{animation:none}}
.reduce-motion .regional-resource.near .fishing-water{animation:none}

.regional-item-art{display:inline-block;width:64px;height:64px;background:url(/assets/storybook/regions/resources.webp) no-repeat;background-size:400% 300%;vertical-align:middle}
.regional-art-0{background-position:0.0% 0.0%;}
.regional-art-1{background-position:33.33333333333333% 0.0%;}
.regional-art-2{background-position:66.66666666666666% 0.0%;}
.regional-art-3{background-position:100.0% 0.0%;}
.regional-art-4{background-position:0.0% 50.0%;}
.regional-art-5{background-position:33.33333333333333% 50.0%;}
.regional-art-6{background-position:66.66666666666666% 50.0%;}
.regional-art-7{background-position:100.0% 50.0%;}
.regional-art-8{background-position:0.0% 100.0%;}
.regional-art-9{background-position:33.33333333333333% 100.0%;}
.regional-art-10{background-position:66.66666666666666% 100.0%;}
.regional-art-11{background-position:100.0% 100.0%;}
.atlas-footpaths{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;overflow:visible}
.atlas-footpaths line{stroke:#f5d886;stroke-width:.5;stroke-dasharray:1.4 .7;filter:drop-shadow(0 0 .3px #362211)}

/* overland.css */
#overlandExits{position:absolute;inset:0;pointer-events:none;z-index:10000}
.overland-exit{position:absolute;transform:translate(-50%,-50%);pointer-events:auto;max-width:180px;min-height:44px;padding:7px 12px;border:1px solid #b9a06e;border-radius:8px;background:#243b2eed;color:#fff3d6;font:600 13px/1.3 Georgia,serif;box-shadow:0 2px 6px #0008;cursor:pointer}
.overland-exit:hover,.overland-exit.near{background:#3e583e;outline:1px solid #d9c592}
.overland-exit:focus-visible{outline:3px solid #fff;outline-offset:3px}
.overland-exit:disabled{opacity:.65;cursor:default}
@media(max-width:480px){.overland-exit{max-width:140px;min-height:44px;font-size:12px}}
@media(prefers-reduced-motion:reduce){.overland-exit{transition:none}}
.frontier-mill{position:absolute;left:49%;top:42%;transform:translate(-50%,-50%);z-index:24;min-width:44px;width:44px;min-height:44px;padding:0;border:1px solid #bc9a65;border-radius:50%;background:#364331e8;color:#fff4dc;font:600 13px/1.2 Georgia,serif;cursor:pointer}
.frontier-mill:hover,.frontier-mill:focus-visible,.frontier-mill.selected{outline:2px solid #f5d897;background:#4a5b45}
.frontier-site-label{position:absolute;left:50%;bottom:calc(100% + 8px);transform:translateX(-50%);width:max-content;max-width:220px;padding:7px 10px;border-radius:8px;background:#173c32ed;color:#fff1ce;opacity:0;pointer-events:none;white-space:nowrap}
.frontier-mill:hover .frontier-site-label,.frontier-mill:focus-visible .frontier-site-label,.frontier-mill.selected .frontier-site-label{opacity:1}
.frontier-mill[hidden]{display:none}
.frontier-mill::before{display:inline-block;margin-right:5px}
.frontier-mill.frontier-mill::before{content:'🌾'}
.frontier-mill.frontier-workbench::before{content:'⚙️'}
.frontier-mill.frontier-dryer::before{content:'🍄'}
.frontier-mill.frontier-pontoon::before{content:'🪢'}
.frontier-mill.frontier-smokehouse::before{content:'🔥'}
.frontier-mill.frontier-rack::before{content:'🌿'}
.frontier-mill.frontier-lining::before{content:'🧵'}
.frontier-dialog article{padding:12px;border:1px solid #8c7654;border-radius:8px}
.frontier-studies{position:absolute;inset:0;pointer-events:none;z-index:10001}
.frontier-studies button{position:absolute;transform:translate(-50%,-50%);pointer-events:auto;min-height:44px;max-width:145px;padding:6px 9px;border:1px solid #d4bc88;border-radius:8px;background:#2d3e3aed;color:#f8edcd;font:600 12px/1.2 Georgia,serif;box-shadow:0 2px 6px #0008;cursor:pointer}
.frontier-studies button:hover,.frontier-studies button:focus-visible{outline:2px solid #f8df9b;background:#52645a}
.frontier-studies button:disabled{opacity:.65}
/* Wild creatures retain their own painted silhouettes and telegraphed actions. */
#map .illustrated-wildlife {width:104px;height:96px;padding:0;translate:-50% -85%;overflow:visible;background:transparent;border:0;box-shadow:none;filter:none;animation:none;}
.illustrated-wildlife .slime-body{position:absolute;inset:0;pointer-events:none;}
.illustrated-wildlife .slime-bounce{display:block;position:absolute;inset:0;transform-origin:50% 88%;transition:transform .2s ease-out;animation:none;}
.illustrated-wildlife .slime-art{display:block;position:absolute;inset:0;background:none;}
.illustrated-wildlife .slime-art img{width:100%;height:100%;object-fit:contain;object-position:center bottom;filter:drop-shadow(0 6px 3px #17251d88);}
.illustrated-wildlife.monster-road-bandit{width:88px;height:110px;}
.illustrated-wildlife.monster-ridge-wolf{width:118px;height:94px;}
.illustrated-wildlife .slime-body::after{content:'';position:absolute;width:64%;height:8%;left:18%;bottom:2%;border-radius:50%;background:#15241c66;filter:blur(3px);}
.illustrated-wildlife .slime-caption{position:absolute;bottom:100%;left:50%;translate:-50% 0;width:146px;padding:4px 6px;border-radius:7px;background:#273123eb;border:1px solid #d5b77caa;pointer-events:none;}
.illustrated-wildlife.state-warn .slime-caption,.illustrated-wildlife.state-windup .slime-caption{border-color:#efab60;box-shadow:0 0 9px #e8a75588;}
.illustrated-wildlife.state-windup .slime-bounce{transform:translateY(2px) scale(1.08,.94);}
.illustrated-wildlife.state-charge .slime-bounce{transform:translateY(-3px) scale(.96,1.04);}
.illustrated-wildlife.state-recover .slime-bounce{transform:scale(1.02,.98);}
@media(prefers-reduced-motion:reduce){.illustrated-wildlife .slime-bounce{transition:none;}}

.azuronde-boat-marker{position:absolute;transform:translate(-50%,-72%);z-index:10002;min-width:92px;min-height:58px;padding:5px 8px;border:1px solid #cbb47d;border-radius:12px;background:#173a35e8;color:#fff1c9;box-shadow:0 4px 14px #0c252066;cursor:pointer;font:600 12px/1.15 Georgia,serif}
.azuronde-boat-marker span{display:block;font-size:24px;line-height:1}.azuronde-boat-marker small{display:block;margin-top:3px;font-size:10px}
.azuronde-boat-marker:hover,.azuronde-boat-marker:focus-visible,.azuronde-boat-marker.near{outline:2px solid #f0d99a;background:#28534b}
.azuronde-boat-marker:disabled{opacity:.6;cursor:default}
.azuronde-boat-dialog [data-boat-body]{padding:0 20px 16px}.azuronde-boat-destinations{display:grid;gap:10px}
.azuronde-boat-destinations button{display:grid;gap:4px;text-align:left;padding:12px;border:1px solid #9d875d;border-radius:10px;background:#203e35;color:#f8eac3}
.azuronde-boat-destinations button span{font-size:12px;color:#c6d3c4}
@media(max-width:480px){.azuronde-boat-marker{min-width:74px;max-width:112px}.azuronde-boat-dialog [data-boat-body]{padding-left:12px;padding-right:12px}}

/* The painted work surface is the target; its name is a transient tooltip. */
.frontier-painted-hotspot{transform:none;max-width:none;min-width:44px;min-height:44px;padding:0;background:transparent;border:2px solid transparent;box-shadow:none}
.frontier-painted-hotspot::before{display:none}
.frontier-painted-hotspot .frontier-site-label{bottom:calc(100% + 8px)}
.frontier-painted-hotspot:hover,.frontier-painted-hotspot:focus-visible,.frontier-painted-hotspot.selected{border-color:#d5b575;background:#e8bf6118;outline:2px solid #183b32;outline-offset:2px}
.frontier-painted-hotspot:hover .frontier-site-label,.frontier-painted-hotspot:focus .frontier-site-label,.frontier-painted-hotspot.selected .frontier-site-label{opacity:1}


/* MMO situational HUD: compact, map-first, and non-blocking. */
.scene-status{gap:7px;flex-wrap:wrap}.scene-status #connectionStatus{font-size:10px;letter-spacing:.05em;opacity:.78}
#connectionStatus[data-state="slow"]{color:#f1c96a}#connectionStatus[data-state="reconnecting"],#connectionStatus[data-state="offline"]{color:#ef8b78}
#partyMarkers{position:absolute;inset:0;pointer-events:none;z-index:2380}
.party-marker{position:absolute;translate:-50% -115%;min-width:26px;height:26px;border-radius:50%;border:2px solid #9fd9cf;background:#173c32dc;color:#f8efd2;display:grid;place-items:center;font:700 11px Georgia,serif;box-shadow:0 0 0 3px #9fd9cf22,0 3px 8px #0007}
.party-marker::after{content:'';position:absolute;top:100%;left:50%;translate:-50% 0;border:5px solid transparent;border-top-color:#9fd9cf}
.party-marker.is-leader{border-color:#efd17f}.party-marker.is-leader::before{content:'♛';position:absolute;bottom:95%;font-size:12px;color:#efd17f}
.party-ping{position:absolute;translate:-50% -50%;width:38px;height:38px;border:3px solid #f2d77e;border-radius:50%;box-shadow:0 0 0 8px #f2d77e22;animation:party-ping 1s ease-out infinite;pointer-events:none}
.party-ping::after{content:'!';position:absolute;inset:0;display:grid;place-items:center;font:800 16px Georgia,serif;color:#fff3bd;text-shadow:0 1px 3px #000}
@keyframes party-ping{0%{scale:.78;opacity:1}100%{scale:1.18;opacity:.3}}
.objective-tracker{position:absolute;left:18px;top:76px;z-index:82;width:min(330px,calc(100vw - 36px));padding:10px 12px;border:1px solid #b9a56c88;border-radius:10px;background:#18382de8;color:#f5ebcb;box-shadow:0 4px 14px #0005;pointer-events:none}
.objective-tracker small{display:block;font:700 10px/1.2 Georgia,serif;letter-spacing:.12em;color:#d8c287}.objective-tracker strong{display:block;margin:3px 0;font:700 15px/1.25 Georgia,serif}.objective-tracker span{display:block;font-size:12px;opacity:.88}
.activity-log{position:absolute;right:18px;bottom:126px;z-index:82;width:min(310px,calc(100vw - 36px));display:grid;gap:6px;pointer-events:none}
.activity-entry{justify-self:end;padding:7px 10px;border-radius:8px;background:#172f29e8;border:1px solid #9e8d6066;color:#f6edcf;font-size:12px;box-shadow:0 3px 10px #0004;animation:activity-in .2s ease-out}
.activity-entry.loss{border-color:#b96e6088}.activity-entry.gain{border-color:#7ca87888}
@keyframes activity-in{from{opacity:0;translate:8px 0}to{opacity:1;translate:0 0}}
#map [data-monster][data-targeting-you="true"] .slime-caption{border-color:#ef7c61!important;box-shadow:0 0 0 2px #ef7c6133,0 0 12px #ef7c6166}
#map [data-monster][data-targeting-you="true"]::before{content:'⚠';position:absolute;left:50%;bottom:115%;translate:-50% 0;color:#ffb38f;font-size:16px;text-shadow:0 2px 3px #000;pointer-events:none}
#map [data-monster].state-patrol{filter:saturate(.92)}#map [data-monster].state-warn{filter:drop-shadow(0 0 5px #e9b25b88)}#map [data-monster].state-chase{filter:drop-shadow(0 0 5px #df7f5d88)}#map [data-monster].state-return{opacity:.86}
@media(max-width:700px){.objective-tracker{top:66px;left:8px;width:min(280px,calc(100vw - 16px))}.activity-log{right:8px;bottom:118px;width:min(260px,calc(100vw - 16px))}}
@media(prefers-reduced-motion:reduce){.party-ping,.activity-entry{animation:none}}

.party-members{display:grid;gap:6px}.party-members p{display:flex;justify-content:space-between;gap:12px;margin:0;padding:7px 9px;border:1px solid #8f7c5350;border-radius:8px}.party-members small{opacity:.78}.party-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}
.performance-alerts{padding:10px 12px;border:1px solid #8c765455;border-radius:9px;margin:8px 0 14px}.performance-alerts strong{color:#e8ad73}.performance-alerts p{margin:4px 0}
.economy-metrics{display:grid;gap:8px}.economy-metrics>p{margin:0}.economy-flow-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.economy-flow-grid section{display:grid;gap:3px;padding:9px;border:1px solid #8c765455;border-radius:8px}.economy-flow-grid small{display:block;opacity:.86}
@media(max-width:600px){.economy-flow-grid{grid-template-columns:1fr}}

/* cendrelame-production.css */
.cendrelame-workshops,.regional-production-workshops{position:absolute;inset:0;pointer-events:none;z-index:8}
.cendrelame-workshops[hidden],.regional-production-workshops[hidden]{display:none}
.production-mine-visual{position:absolute;inset:0;pointer-events:none;z-index:1}
.production-mine-clean{position:absolute;left:var(--mine-clean-left,4.6875%);top:var(--mine-clean-top,34.1797%);width:var(--mine-clean-width,9.4401%);height:var(--mine-clean-height,8.59375%);background-image:var(--mine-clean-image,url('/assets/storybook/regions/cendrelame-mine-clean.webp'));background-position:center;background-size:100% 100%;background-repeat:no-repeat;pointer-events:none;z-index:1}
.production-wagon{position:absolute;left:var(--mine-wagon-left,10.1%);top:var(--mine-wagon-top,38.5%);width:var(--mine-wagon-width,4.5%);height:var(--mine-wagon-height,5%);transform:translate(-50%,-50%);background-image:var(--mine-wagon-image,url('/assets/storybook/regions/cendrelame-wagon.webp'));background-position:center;background-size:contain;background-repeat:no-repeat;pointer-events:none;z-index:1}
.production-mine-visual[data-mine-state="working"] .production-wagon,.cendrelame-workshops[data-mine-state="working"]>.production-wagon{visibility:hidden;opacity:0}
.production-mine-visual.departing[data-mine-state="working"] .production-wagon,.cendrelame-workshops.departing[data-mine-state="working"]>.production-wagon{visibility:visible;opacity:1;animation:mine-cart-depart .85s ease-in forwards}
.production-forge-sparks{position:absolute;left:80.5%;top:48.5%;width:4%;height:7%;pointer-events:none;opacity:0;z-index:2;background:radial-gradient(circle,#ffdc76 0 7%,transparent 9%) 12% 38%/30% 45%,radial-gradient(circle,#ff9f36 0 8%,transparent 10%) 70% 12%/42% 38%,radial-gradient(circle,#fff0a8 0 6%,transparent 9%) 85% 80%/30% 36%;background-repeat:no-repeat}
.production-forge-sparks.active{animation:forge-spark .7s ease-out both}
@keyframes mine-cart-depart{from{transform:translate(-50%,-50%);clip-path:inset(0 0 0 0);opacity:1}65%{clip-path:inset(0 0 0 0);opacity:1}to{transform:translate(calc(-50% + var(--mine-depart-x,-64%)),calc(-50% + var(--mine-depart-y,-75%)));clip-path:inset(0 0 100% 0);opacity:0}}
@keyframes forge-spark{0%{opacity:0;transform:translateY(10%)}25%{opacity:1}100%{opacity:0;transform:translateY(-28%)}}
.production-hotspot{position:absolute;pointer-events:auto;background:transparent;border:2px solid transparent;border-radius:12px;cursor:pointer;min-width:44px;min-height:44px;padding:0}
.production-hotspot:hover,.production-hotspot:focus-visible{border-color:#d5b575;background:#e8bf6120;outline:2px solid #183b32;outline-offset:2px}
.production-site-label{position:absolute;bottom:0;left:50%;transform:translate(-50%,70%);display:block;width:max-content;max-width:240px;padding:6px 10px;border-radius:8px;background:#173c32ed;color:#fff1ce;font-size:13px;opacity:0;pointer-events:none}
.production-hotspot:hover .production-site-label,.production-hotspot:focus-visible .production-site-label{opacity:1}
.production-dialog{box-sizing:border-box;padding:0;width:min(680px,calc(100vw - 24px));max-height:85dvh;overflow:auto}
.production-dialog [data-production-body],.production-dialog [data-production-message]{padding:0 20px 12px}
.production-dialog header{position:sticky;top:0;z-index:1}
.production-dialog [data-production-message]{min-height:1.5em}
.production-recipes{display:grid;gap:12px}
.production-recipes article{border:1px solid #af966050;border-radius:12px;padding:16px}
.production-recipes h3{margin:0 0 8px}
.production-recipes ul{padding-left:20px}
.production-recipes li{padding:3px 0}
.production-recipes li strong{float:right}
.production-dialog button{min-height:44px}
.production-countdown{font-size:1.35rem;font-variant-numeric:tabular-nums}
.production-note{font-size:.9rem;opacity:.85}
@media(max-width:480px){.production-dialog [data-production-body],.production-dialog [data-production-message]{padding-left:12px;padding-right:12px}.production-recipes article{padding:12px}}
@media(prefers-reduced-motion:reduce){.production-hotspot{transition:none}.production-mine-visual.departing[data-mine-state="working"] .production-wagon,.cendrelame-workshops.departing[data-mine-state="working"]>.production-wagon{visibility:hidden;animation:none}.production-forge-sparks.active{animation:none}}

.production-bonus-ready{padding:10px 12px;border:1px solid #aa8d52;border-radius:10px;background:#efe4c326;font-weight:700}
.rewarded-video-dialog{box-sizing:border-box;padding:0;width:min(720px,calc(100vw - 24px));max-height:90dvh;overflow:auto}
.rewarded-video-body{padding:0 20px 18px}
.rewarded-video-dialog video{display:block;width:100%;max-height:56dvh;background:#111;border-radius:12px;margin:0 0 12px}
.rewarded-video-dialog button{min-height:44px}
@media(max-width:480px){.rewarded-video-body{padding-left:12px;padding-right:12px}}

/* storybook-combat.css */
/* One drawing space anchored at the old sprite's feet, with room for a real swing. */
.storybook-preview .character-sprite { overflow: visible; }
.storybook-preview .storybook-character { position: absolute; width: 120px; height: 120px; left: -26px; top: -26px; }
.storybook-preview .character-renderer:has([data-storybook-gear]) > .character-weapon { display: none; }
.storybook-preview #self:has([data-storybook-ready]).player-attacking .character-renderer,
.storybook-preview #self:has([data-storybook-ready]).player-attack-ready .character-renderer { animation: none; }
.storybook-preview #self:has([data-storybook-ready])::before,
.storybook-preview .pawn:has([data-storybook-ready])::after { display: none; }
.item-illustration { display: inline-block; width: 42px; height: 42px; object-fit: contain; vertical-align: middle; filter: drop-shadow(0 2px 2px #0004); }
.comfort-grid .item-illustration, .storage-item-icon .item-illustration { width: 54px; height: 54px; }
.comfort-item-detail h3 .item-illustration, .storage-selection h3 .item-illustration { width: 70px; height: 70px; }
.comfort-equipment-slots .item-illustration { width: 38px; height: 38px; }
#map .illustrated-slime[data-creature-ready] { opacity: 1; transform: none; transition: filter .2s; }
[data-creature-ready] .slime-bounce { animation: none !important; transform: none !important; }
[data-creature-ready] .slime-art { background-image: none; }
[data-creature-ready] .slime-mouth, [data-creature-ready] .slime-body::after { display: none; }
.creature-canvas { display: block; position: absolute; bottom: 0; left: 0; width: 100%; height: auto; pointer-events: none; }
#map [data-creature-family="lich"], #map [data-creature-family="ghost"] { filter: none; }
[data-creature-family="lich"] .slime-caption, [data-creature-family="ghost"] .slime-caption { bottom: 135%; }
.combat-ground-warning, .combat-landing, .painted-acid-impact, .painted-acid-projectile { position: absolute; pointer-events: none; translate: -50% -50%; }
.combat-ground-warning { box-sizing: border-box; border: 3px dashed #efd893; border-radius: 50%; background: #b9751925; box-shadow: 0 0 0 2px #35260977, inset 0 0 22px #dc942331; }
.combat-ground-warning::after { content: ''; position: absolute; inset: 7px; border: 1px solid #ecd490a0; border-radius: inherit; }
.combat-ground-warning[data-phase="JUMP"] { border-style: solid; background: #bc701b39; }
.combat-landing { border: 3px solid #c9ae71aa; box-shadow: 0 0 16px #b3a07266, inset 0 0 10px #b3a07266; border-radius: 50%; scale: var(--ring-scale, 1); }
.painted-acid-projectile { width: 54px; height: 54px; z-index: 4; }
.painted-acid-projectile::after { content: ''; position: absolute; bottom: -4px; left: 19px; width: 19px; height: 7px; border-radius: 50%; background: #15251935; filter: blur(2px); }
.painted-acid-projectile canvas { width: 100%; height: 100%; object-fit: contain; rotate: var(--acid-angle, 0rad); transform-origin: center; position: relative; top: -12px; }
.painted-acid-impact { width: 112px; height: 88px; scale: var(--splash-scale, 1); }
.painted-acid-impact canvas { width: 100%; height: 100%; }
.comfort-reduced-motion .combat-ground-warning { box-shadow: none; }
@media (prefers-reduced-motion: reduce) { .combat-ground-warning { box-shadow: none; } }

[data-creature-family="undead"] .creature-canvas { width: 135%; left: -17.5%; bottom: -5%; }
[data-creature-family="undead"] .slime-caption { bottom: 128%; }
.slime-name { min-width: 0; white-space: normal; overflow-wrap: anywhere; }

/* Player weapon projectiles are presentation-only. Server combat resolves the hit. */
.weapon-projectile{position:absolute;z-index:2450;translate:-50% -50%;pointer-events:none;width:42px;height:8px;transform:rotate(var(--projectile-angle,0deg));transform-origin:50% 50%;filter:drop-shadow(0 1px 2px #08161199)}
.weapon-projectile::before{content:'';position:absolute;left:2px;right:7px;top:3px;height:2px;border-radius:2px;background:#b98d4f}
.weapon-projectile::after{content:'';position:absolute;right:0;top:1px;width:0;height:0;border-left:8px solid #d4d8cc;border-top:3px solid transparent;border-bottom:3px solid transparent}
.weapon-projectile-arrow{width:48px}
.weapon-projectile-arrow::before{background:linear-gradient(90deg,#6a4b2f,#c39b5b)}
.weapon-projectile-bolt{width:38px;height:10px}
.weapon-projectile-bolt::before{height:3px;top:3px;background:#5a4531}
.weapon-projectile-bolt::after{border-left-color:#879096;border-top-width:4px;border-bottom-width:4px;top:1px}
.player-attacking.attack-dagger .character-renderer{filter:drop-shadow(0 0 3px #d8d9e2)}
.player-attacking.attack-axe .character-renderer,.player-attacking.attack-mace .character-renderer{filter:drop-shadow(0 2px 3px #35281d88)}
.player-attacking.attack-spear .character-renderer{filter:drop-shadow(0 0 4px #ddd4b755)}
.player-attacking.attack-greatsword .character-renderer{filter:drop-shadow(0 0 5px #d5ca9166)}
@media(prefers-reduced-motion:reduce){.weapon-projectile{filter:none}}

/* Immediate authoritative hit confirmation while the slower world refresh catches up. */
#map [data-monster].combat-hit-confirmed .slime-bounce{filter:brightness(1.18) drop-shadow(0 0 7px #f1d08a99);transform:scale(.97,1.03)}
@media(prefers-reduced-motion:reduce){#map [data-monster].combat-hit-confirmed .slime-bounce{transform:none;filter:brightness(1.08)}}

/* painted-world.css */
/* The prototype's camera, scale and palette, applied to the real game UI. */
:root { --scene-ink:#f5efd8; --scene-muted:#b7c8b8; --scene-gold:#dcc38c; --scene-green:#172e28; --scene-line:#b4c99e33; }
.game-shell { color:var(--scene-ink); background:#152c26; }
.scene-topbar { position:absolute;z-index:40;top:0;left:0;right:0;height:76px;display:flex;align-items:center;justify-content:space-between;padding:0 28px;gap:20px;background:#152c26;border-bottom:1px solid var(--scene-line); }
.scene-brand {display:flex;gap:12px;align-items:center;color:var(--scene-ink);text-decoration:none;letter-spacing:3px;font:600 18px Georgia,serif;}
.scene-brand small {display:block;letter-spacing:.5px;font:11px system-ui;color:#aebfb1;margin-top:5px;}
.scene-crest {width:38px;height:44px;border:1px solid #bdae78;border-radius:17px 17px 21px 21px;display:grid;place-items:center;font:27px Georgia,serif;color:#e5d3a3;box-shadow:inset 0 0 0 4px #a7996933;}
.scene-status {font:10px system-ui;letter-spacing:2px;display:flex;align-items:center;gap:9px;color:#b9c9b5;}
.scene-status i {width:5px;height:5px;border-radius:50%;background:#bdcf83;box-shadow:0 0 10px #aec978;}
#sceneLight {background:transparent;border:1px solid var(--scene-line);border-radius:8px;padding:11px 13px;font-size:13px;color:var(--scene-ink);}
#sceneLight[aria-pressed=true] {background:#ffffff0a;border-color:#dcc38c;}
.game-shell .world-layer {top:76px;}
.game-shell .map-viewport {background:#183728;}
.game-shell .map-viewport #map.painted-world {width:var(--scene-width,1536px);height:var(--scene-height,1024px);max-width:none;min-width:0;min-height:0;background:#183728!important;isolation:isolate;position:relative;}
#map.painted-world::before,#map.painted-world::after {display:none!important;}
#map.painted-world #villageScene,#map.painted-world #mapPlayers,#map.painted-world #mapNpcs,#map.painted-world #mapPortals,#map.painted-world #mysteryActors {display:contents!important;}
#map.painted-world #mapBuildings, #map.painted-world .ambient-particles, #map.painted-world .zone-decor, #map.painted-world .map-hint {display:none!important;}
.painted-backdrop {position:absolute;left:0;top:0;width:var(--scene-width,1536px);height:var(--scene-height,1024px);z-index:1;pointer-events:none;image-rendering:auto;}
.painted-foreground {position:absolute;pointer-events:none;transition:opacity .2s;}
.painted-foreground.actor-behind {opacity:.7;}
.game-shell .world-layer::after {content:'';position:absolute;inset:0;pointer-events:none;z-index:3;background:linear-gradient(0deg,#061a2755,transparent 24%,transparent 80%,#09202122);box-shadow:inset 0 0 100px #11262333;}
.golden-hour .world-layer::after {background:radial-gradient(ellipse at 25% 0%,#ffcf7648,transparent 70%),linear-gradient(0deg,#52231344,transparent 40%);}
.painted-world .pawn {width:68px;height:98px;translate:none;transform:translate(-50%,-100%);transition:none;box-shadow:none;border:0;}
.painted-world .pawn.self {left:var(--actor-left)!important;top:var(--actor-top)!important;}
.storybook-preview #map.painted-world .character-renderer {scale:1.1136;transform-origin:50% 100%;}
#map.painted-world .pawn::after {content:'';display:block;position:absolute;left:10px;bottom:-3px;width:48px;height:16px;border-radius:50%;background:#12251c44;z-index:-1;}
#map.painted-world .pawn:not(.self):hover,#map.painted-world .pawn:not(.self):focus-visible {transform:translate(-50%,-100%);filter:drop-shadow(0 0 5px #ead79a);}
#map.painted-world .npc-character {width:74px;height:98px;min-height:98px;translate:-50% -100%;}
#map.painted-world .npc-character .npc-sprite {left:5px;bottom:0;scale:1.3;transform-origin:50% 100%;}
#map.painted-world .npc-character > strong {top:-25px;font:500 11px system-ui;padding:6px 10px;border:1px solid #c9bf7c66;background:#1a322bdd;border-radius:7px;color:#dae0c4;}
#map.painted-world .npc-character::before {width:48px;height:14px;bottom:-3px;left:12px;background:#12251c33;}
#map.painted-world .npc-role {top:102px;}
.scene-door {position:absolute;translate:-50% -100%;width:100px;height:84px;border:0!important;padding:0!important;background:transparent!important;box-shadow:none!important;cursor:pointer;color:#f3e6b9;}
.scene-door:after {content:'⌄';position:absolute;bottom:-8px;left:40%;font:22px Georgia;color:#f9e9af;text-shadow:0 1px 5px #273e24;}
.scene-door span {position:absolute;bottom:25px;left:50%;translate:-50% 0;white-space:nowrap;padding:7px 10px;border:1px solid #c9bf7c66;border-radius:7px;background:#1a322bdd;font:500 11px system-ui;color:#dae0c4;}
.scene-door:hover span,.scene-door:focus-visible span {border-color:#f4d393;background:#234334;}
.scene-place {position:absolute;z-index:20;top:99px;left:26px;display:flex;gap:12px;align-items:center;padding:12px 18px;background:#172e29d9;border:1px solid #d2cc9d40;border-radius:12px;pointer-events:none;box-shadow:0 6px 20px #13292130;}
.scene-place>span {font-size:22px;color:#d8c08b;}.scene-place small {display:block;font:9px system-ui;letter-spacing:1.7px;color:#bcccac;margin-bottom:5px;text-transform:uppercase;}.scene-place strong {font:20px Georgia,serif;font-weight:400;}
.scene-camera {position:absolute;z-index:25;left:26px;top:193px;display:flex;padding:3px;background:#183028df;border:1px solid var(--scene-line);border-radius:8px;}
.scene-camera button {background:transparent;border:0;color:var(--scene-ink);width:34px;height:32px;padding:0;font-size:20px;border-radius:5px;}
.scene-camera button:hover,.scene-camera button[aria-pressed=true]{background:#ffffff12;}
.game-shell .player-hud,.storybook-preview .game-shell .player-hud {top:auto;bottom:26px;left:26px;width:290px;max-width:calc(100vw - 94px);padding:13px;border-radius:12px;border:1px solid #d6c8994d;background:#173329ed;box-shadow:0 8px 35px #14251430;grid-template-columns:62px minmax(0,1fr);gap:10px;}
.game-shell .hud-profile {align-self:center;}.game-shell .hud-portrait{width:62px;height:76px;border:1px solid #bdae7880;border-radius:12px;}.game-shell .hud-portrait .character-sprite {transform:scale(.9);}
.game-shell .player-hud #identity {font:14px/1.3 Georgia,serif;font-weight:400;}.game-shell .player-hud .hud-location {font-size:10px;}.game-shell .hud-meter-heading{font-size:10px;}
.game-shell .side-tools {right:24px;top:50%;gap:9px;max-height:calc(100dvh - 120px);overflow:auto;scrollbar-width:none;}
.game-shell .side-tools button {width:62px;min-height:60px;border:1px solid #b4c99e55;border-radius:11px;background:#19372de8;box-shadow:0 4px 15px #0c221d25;font-weight:400;}
.game-shell .side-tools span {font-size:23px;}.game-shell .side-tools small {font-size:10px;color:#c7d2bd;}
.game-shell .side-tools button:hover,.game-shell .side-tools button[aria-expanded=true]{border-color:#dcc38c;background:#294738;}
.game-shell .drawer,.game-shell #npcPanel {top:99px;right:100px;bottom:auto;transform:none;max-height:calc(100dvh - 122px);background:linear-gradient(150deg,#203b33f5,#142d29fa);border:1px solid #d6cda15c;border-radius:16px;box-shadow:0 18px 50px #09291c55;backdrop-filter:blur(14px);}
.game-shell .drawer h2,.game-shell #npcPanel h2 {font:28px Georgia,serif;font-weight:400;color:#f5efd8;}.game-shell .drawer h3{font:20px Georgia,serif;font-weight:400;}.game-shell .drawer p {color:#bfcebc;line-height:1.65;}
.game-shell .drawer-close {background:#ffffff09;border:1px solid var(--scene-line);font-weight:300;}
.equipment-extras {display:flex;gap:10px;margin:16px 0;}.equipment-extras button{width:44px;height:40px;padding:8px;background:#234033;border:1px solid #b4c99e33;border-radius:7px;}.equipment-extras svg{width:24px;height:24px;}
.scene-controls {position:absolute;z-index:20;bottom:24px;left:50%;transform:translateX(-50%);margin:0;font-size:10px;background:#153127aa;border-radius:20px;padding:8px 14px;color:#d5ddc9;pointer-events:none;white-space:nowrap;}.scene-controls span {font-size:9px;letter-spacing:1px;color:#ead7a1;}.scene-controls em{font-style:normal;margin:0 7px;}
.scene-interact {position:absolute;z-index:26;bottom:70px;left:50%;translate:-50% 0;padding:12px 20px;border:1px solid #edd59e;border-radius:10px;background:#203a2af5;color:#ead7a1;font-size:13px;box-shadow:0 5px 30px #15261377;}
.scene-changing .world-layer {opacity:.35;transition:opacity .15s;}.world-layer {transition:opacity .15s;}
.game-shell .newcomer-guide {top:auto;bottom:174px;left:26px;max-width:290px;background:#173329ed;border-color:#d6c8994d;border-radius:12px;}
.game-shell .combat-target {top:96px;bottom:auto;}.game-shell #dungeonPanel {top:24px;right:100px;}
#notice {z-index:300;top:88px;border:1px solid #cfbb8966;border-radius:10px;background:#1b352bf2;color:#f0dfb7;}
@media(max-width:900px){.scene-status{display:none;}.scene-topbar{padding:0 18px;}.game-shell .side-tools{right:12px;}.game-shell .drawer,.game-shell #npcPanel{right:86px;}}
@media(max-width:600px){
 .scene-topbar{height:64px;padding:0 12px;gap:8px;}.scene-brand{font-size:15px;letter-spacing:2px;gap:8px;}.scene-brand small{font-size:8px;letter-spacing:0;}.scene-crest{width:29px;height:36px;font-size:22px;}#sceneLight{font-size:18px;padding:8px;}#sceneLight span{display:none;}
 .game-shell .world-layer{top:64px;}.scene-place{top:77px;left:13px;padding:10px 12px;max-width:calc(100vw - 70px);}.scene-place strong{font-size:16px;}.scene-place small{font-size:8px;letter-spacing:.7px;}.scene-place>span{font-size:17px;}.scene-camera{top:157px;left:13px;}.scene-camera button{width:29px;height:28px;font-size:19px;}
 .game-shell .player-hud,.storybook-preview .game-shell .player-hud{bottom:12px;left:12px;width:250px;max-width:calc(100vw - 82px);padding:9px;grid-template-columns:48px minmax(0,1fr);gap:8px;}.game-shell .hud-portrait{width:48px;height:64px;}.game-shell .hud-portrait .character-sprite{transform:scale(.74);}.game-shell .player-hud #identity{font-size:12px;}.game-shell .hud-location{font-size:9px;}.game-shell .hud-xp-heading{margin-top:5px;}
 .game-shell .side-tools{right:10px;top:42%;max-height:calc(100dvh - 195px);gap:7px;transform:translateY(-30%);}.game-shell .side-tools button{width:49px;min-height:49px;padding:5px;border-radius:9px;}.game-shell .side-tools span{font-size:20px;}.game-shell .side-tools small{font-size:9px;}
 .game-shell .drawer,.game-shell #npcPanel{top:76px;left:10px;right:69px;bottom:12px;width:auto;max-width:none;max-height:none;padding:16px;border-radius:13px;}.game-shell .drawer h2,.game-shell #npcPanel h2{font-size:23px;}.scene-controls{display:none;}.scene-interact{left:auto;right:12px;bottom:134px;translate:none;font-size:11px;padding:10px;max-width:calc(100vw - 24px);}.game-shell .newcomer-guide{bottom:147px;left:12px;width:calc(100vw - 90px);max-width:260px;}.game-shell .combat-target{left:12px;right:70px;top:202px;width:auto;}.game-shell .combat-loot{bottom:135px;}.game-shell #dungeonPanel{top:134px;right:70px;max-width:calc(100vw - 90px);}#notice{top:auto;bottom:135px;width:calc(100vw - 24px);left:12px;transform:none;}
}
@media(prefers-reduced-motion:reduce){.painted-foreground,.world-layer{transition:none;}}

.game-shell .map-viewport #map.painted-world {box-shadow:none;image-rendering:auto;}

#map.painted-world .painted-player-name {position:absolute;left:50%;top:-27px;translate:-50% 0;white-space:nowrap;padding:6px 10px;border:1px solid #c9bf7c66;border-radius:7px;background:#1a322bdd;font:500 11px system-ui;color:#dae0c4;pointer-events:none;}
#map.painted-world .mystery-actor {width:68px;height:98px;}
#map .mystery-actor.has-motion-path {transition:none;}
#map.painted-world .mystery-actor .character-sprite {position:absolute;left:0;bottom:0;scale:1.1136;transform:none;transform-origin:50% 100%;}
#map.painted-world .mystery-question {top:-23px;left:28px;background:#18372c;color:#ead7a1;}
#map.painted-world .personal-chest {width:90px;height:85px;background:transparent!important;border:0!important;box-shadow:none!important;}
#map.painted-world .personal-chest svg {visibility:hidden;}

#map.painted-world #mapMonsters {display:contents;}
#map.painted-world #mapEffects {z-index:2300;}

#map.painted-world .world-passage {z-index:2100;}

.scene-door[data-world-portal="village-heights"] span{bottom:-22px;}
.scene-door[data-portal="forest"]{height:44px;}
.scene-door[data-portal="forest"] span:before{content:'';display:inline-block;width:6px;height:6px;border-radius:50%;margin-right:6px;background:var(--portal-accent,#eed781);box-shadow:0 0 6px var(--portal-accent,#eed781);}
.scene-door:disabled span{color:#929b8f;border-color:#62695f;}
.game-shell .side-tools svg{width:25px;height:25px;display:block;margin:0 auto;fill:none;stroke:#dec994;stroke-width:1.35;stroke-linecap:round;stroke-linejoin:round;}

.game-shell #map.zone-dungeon{background:#223a31 url('/assets/storybook/world/dungeon-floor.webp') center/100% 100% no-repeat!important;box-shadow:inset 0 0 95px #0a171a99!important;image-rendering:auto;}
.game-shell .dungeon-wall{background:#52604b url('/assets/storybook/world/dungeon-floor.webp') center/480px 320px;border:1px solid #8d926963;border-top:5px solid #a6a783;box-shadow:5px 9px 7px #091a1b80,inset 0 0 6px #283728;border-radius:3px;}
.game-shell .dungeon-panel{background:#19352ef5;border:1px solid #bca66a70;border-radius:12px;color:#ede2c0;}
.game-shell .dungeon-panel h3{font:21px Georgia,serif;font-weight:400;}
.game-shell .dungeon-panel button,.game-shell .dungeon-stairs,.game-shell .dungeon-leave{background:#233e30ed;border:1px solid #bfa86a;color:#e9d7a5;}

#map.painted-world .slime-caption{bottom:63%;width:125px;padding:4px 6px;border-color:#d2c69c66;background:#17342dea;}
#map.painted-world .slime-heading{font-weight:500;}
#map.painted-world .slime-health{height:4px;}
#map.painted-world .dungeon-gate{border:1px solid #dec18f;border-radius:48% 48% 35% 35%;background:radial-gradient(ellipse,#b29c7d77,#253b2bf2 66%);box-shadow:0 0 14px #e2b95766,inset 0 0 14px #b29e7777;}

.game-shell .drawer,.game-shell #npcPanel,.game-shell .storage-dialog{scrollbar-width:thin;scrollbar-color:#6d8567 #19352e;}

/* Keep a new adventurer's objective available without covering the walking area. */
@media(max-width:600px){
 .game-shell .newcomer-guide{max-height:148px;overflow:auto;scrollbar-width:thin;scrollbar-color:#6d8567 #19352e;padding:10px;}
 .game-shell .newcomer-guide h2{font-size:16px;}
 .game-shell .newcomer-guide>p{font-size:11px;line-height:1.4;margin:8px 0;}
 .game-shell .newcomer-guide-head>button{width:auto;flex-basis:auto;height:28px;padding:3px 7px;border-radius:7px;font-size:10px;}
}

/* Dungeon floors share the village camera, actor feet and painted scale. */
.game-shell .map-viewport #map.painted-world.zone-dungeon {background:#182a2a url('/assets/storybook/dungeon/cavern-floor.webp') center/100% 100% no-repeat!important;box-shadow:none!important;}
.game-shell .map-viewport #map.painted-world.zone-dungeon[data-dungeon-theme=crypt] {background-image:url('/assets/storybook/dungeon/crypt-floor.webp')!important;}
#map.painted-world #dungeonScene:not([hidden]){display:contents;}
#map.painted-world #dungeonScene[hidden]{display:none;}
.dungeon-masonry {position:absolute;pointer-events:none;}
.dungeon-wall-art {position:absolute;left:-3px;top:-15px;width:calc(100% + 6px);height:calc(100% + 15px);filter:drop-shadow(4px 6px 3px #06181960);}
.dungeon-mist {position:absolute;inset:0;width:100%;height:100%;z-index:2240;pointer-events:none;}
#map.painted-world .dungeon-stairs {width:148px;height:165px;translate:-50% -88%;padding:0;background:none!important;border:0!important;box-shadow:none;border-radius:0;pointer-events:auto;}
.dungeon-stairs img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(2px 5px 4px #06181760);}
#map.painted-world .dungeon-stairs span{position:absolute;left:50%;bottom:-14px;translate:-50% 0;white-space:nowrap;padding:5px 10px;border:1px solid #b6b28170;border-radius:6px;background:#18322eee;font:11px system-ui;color:#f0e4b7;}
#map.painted-world .dungeon-stairs:hover img,#map.painted-world .dungeon-stairs:focus-visible img {filter:drop-shadow(0 0 8px #f0dfa299);}
#map.painted-world .dungeon-exit span {border-color:#d6e7ac;background:#203c30f2;color:#f3f4ce;}
#map.painted-world .dungeon-exit span:before {content:'↗';margin-right:6px;color:#d0efae;}
#map.painted-world .dungeon-exit.victory img {filter:drop-shadow(0 0 10px #d5e5a877);}
#map.painted-world .dungeon-secret{width:68px;height:66px;background:none;border:0;box-shadow:none;translate:-50% -85%;padding:0;border-radius:0;}
.dungeon-secret img{width:100%;height:100%;object-fit:contain;}
#map.painted-world .dungeon-secret.opened{filter:saturate(.5);opacity:.75;}
.dungeon-hidden-door{position:absolute;translate:-50% -50%;color:#ecdd97;text-shadow:0 0 8px #dcfa88;font-size:26px;}
.dungeon-compass{position:absolute;z-index:19;left:26px;top:260px;width:184px;border:1px solid #b1b99c50;border-radius:10px;padding:10px;background:#132a27eb;box-shadow:0 6px 25px #061c1b40;pointer-events:none;color:#d5dcc3;}
.dungeon-compass>div{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;font:10px system-ui;letter-spacing:.8px;}
.dungeon-compass strong{font-weight:500;}.dungeon-compass span{color:#a6bead;font-size:10px;}
.dungeon-compass canvas{display:block;width:100%;height:auto;border:1px solid #a6b89530;border-radius:4px;}
.dungeon-compass small{display:flex;gap:6px;align-items:center;font:9px system-ui;margin-top:8px;color:#a7bbac;}
.dungeon-compass small i{width:5px;height:5px;border-radius:50%;background:#f3d699;}.dungeon-compass small b{font-size:13px;font-weight:400;margin-left:auto;color:#ddc690;}
.game-shell.in-dungeon #dungeonPanel{top:24px;right:100px;width:252px;padding:16px;background:#142c29ed;border:1px solid #adb79460;box-shadow:0 10px 30px #061c1b44;}
.dungeon-heading>small{font:9px system-ui;letter-spacing:1.7px;color:#a7bdad;}
.game-shell.in-dungeon .dungeon-panel h3{font:22px/1.15 Georgia,serif;color:#f1e7c7;margin:8px 0 9px;}
.game-shell.in-dungeon .dungeon-panel .dungeon-heading p{font:12px/1.5 system-ui;color:#c6d1b6;margin:0 0 13px;}
.dungeon-panel details{border-top:1px solid #98ad8c33;padding-top:10px;}
.dungeon-panel summary{font:11px system-ui;cursor:pointer;color:#dbc794;}.dungeon-panel summary span{float:right;font-size:10px;color:#a3baa7;}
.dungeon-expedition{padding-top:10px;max-height:250px;overflow:auto;scrollbar-width:thin;}
.dungeon-expedition>small{font:11px/1.6 system-ui;margin-bottom:5px;}
.game-shell.in-dungeon .dungeon-panel button{font:11px system-ui;padding:8px 10px;}
.dungeon-clue{font:12px/1.6 Georgia,serif;border-top:1px solid #aeb98740;padding-top:10px;margin-top:10px;}
.dungeon-clue p{margin:0!important;color:#e3d49b;}
.in-dungeon .scene-place{max-width:380px;}
.in-dungeon .scene-place strong{font-size:21px;}.in-dungeon .scene-place small{font-size:9px;}
.in-dungeon .scene-camera{top:195px;}
.in-dungeon[data-dungeon-theme=crypt] .dungeon-compass,.game-shell.in-dungeon[data-dungeon-theme=crypt] #dungeonPanel{background:#1b2935ef;border-color:#a2b1c567;}
.in-dungeon[data-dungeon-theme=crypt] .scene-place{background:#1b2935e8;}
.in-dungeon[data-dungeon-theme=crypt] .dungeon-heading>small{color:#acc2d0;}
@media(max-width:900px){.game-shell.in-dungeon #dungeonPanel{right:86px;width:230px;}.dungeon-compass{width:154px;}}
@media(max-width:600px){
 .in-dungeon .scene-place{right:65px;max-width:none;}.in-dungeon .scene-place strong{font-size:16px;}.in-dungeon .scene-place small{font-size:8px;letter-spacing:.3px;}
 .in-dungeon .scene-camera{top:157px;}
 .dungeon-compass{left:13px;top:204px;width:105px;padding:7px;border-radius:7px;}.dungeon-compass>div{font-size:8px;letter-spacing:0;margin-bottom:5px;}.dungeon-compass small{font-size:8px;margin-top:4px;}.dungeon-compass span{font-size:8px;}
 .game-shell.in-dungeon #dungeonPanel{top:auto;bottom:146px;right:70px;left:12px;width:auto;max-width:none;padding:10px 12px;max-height:32dvh;overflow:auto;scrollbar-width:thin;}
 .game-shell.in-dungeon .dungeon-panel h3{font-size:16px;margin:4px 0;}.dungeon-heading>small{font-size:8px;}.game-shell.in-dungeon .dungeon-panel .dungeon-heading p{font-size:10px;margin-bottom:7px;}
 .dungeon-panel details{padding-top:7px;}.dungeon-expedition{max-height:none;}.in-dungeon .scene-interact{bottom:135px;right:12px;left:auto;max-width:calc(100vw - 24px);z-index:28;}
 .in-dungeon .newcomer-guide{display:none;}
}
.dungeon-compass{left:auto;right:100px;top:auto;bottom:26px;}
.dungeon-atmosphere{position:absolute;inset:0;z-index:2;pointer-events:none;background:radial-gradient(ellipse at 60% 50%,#3fd2ad14,transparent 65%);}
[data-dungeon-floor="2"] .dungeon-atmosphere{background:linear-gradient(135deg,#07524229,#6b704916);}
[data-dungeon-floor="3"] .dungeon-atmosphere{background:radial-gradient(ellipse at 68% 50%,#469fb638,#102c5430);}
[data-dungeon-floor="4"] .dungeon-atmosphere{background:radial-gradient(ellipse at 40% 25%,#ad82c837,#243e6230);}
[data-dungeon-floor="5"] .dungeon-atmosphere{background:radial-gradient(ellipse at 68% 50%,#ffe18132,#15303122 65%);}
[data-dungeon-theme=crypt][data-dungeon-floor="5"] .dungeon-atmosphere{background:radial-gradient(ellipse at 68% 50%,#9362b841,#1d294f2e 65%);}
@media(max-width:900px){.dungeon-compass{right:86px;}}
@media(max-width:600px){.dungeon-compass{left:13px;right:auto;top:160px;bottom:auto;}}
.scene-camera svg{width:18px;height:18px;vertical-align:middle;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;}
#map.painted-world.zone-dungeon [data-creature-family=lich] .slime-caption,
#map.painted-world.zone-dungeon [data-creature-family=ghost] .slime-caption{bottom:95%;}
#map.painted-world.zone-dungeon .slime-caption{width:148px;min-width:148px;white-space:nowrap;}

/* stone-portals.css */
/* One painted structure; the living aperture sits behind the alpha-cut stone. */
#map .portal.stone-portal,#map .dungeon-gate.stone-portal {
 --portal-base:#8e5814;--portal-accent:#ffd858;--portal-light:#fff5bc;
 position:absolute;width:236px;height:236px;min-height:0;padding:0;border:0;border-radius:0;
 background:transparent;box-shadow:none;animation:none;translate:-50% -94%;overflow:visible;
}
#map .stone-portal .stone-portal-art {position:absolute;inset:0;pointer-events:none;}
#map .stone-portal .portal-stone-frame {position:absolute;inset:0;width:100%;height:100%;object-fit:contain;z-index:2;filter:drop-shadow(1px 5px 3px #14261870);transition:filter .8s ease;}
#map .stone-portal .portal-vortex {position:absolute;left:29.5%;top:22%;width:43%;height:58%;border-radius:50% 50% 14% 14% / 33% 33% 13% 13%;z-index:1;}
#map .stone-portal[data-awake=true] .portal-stone-frame {filter:drop-shadow(1px 5px 3px #14261870) drop-shadow(0 0 5px color-mix(in srgb,var(--portal-accent) 38%,transparent));}
#map .stone-portal > strong,#map .stone-portal > .portal-status {position:absolute;left:50%;translate:-50% 0;width:max-content;max-width:230px;padding:4px 8px;border:1px solid #b9c28d55;border-radius:5px;background:#183125ed;color:#f1e8c8;text-shadow:none;pointer-events:auto;}
#map .stone-portal > strong {top:96%;font:600 12px/1.25 system-ui;}
#map .stone-portal > .portal-status {top:calc(96% + 27px);font:10px/1.3 system-ui;color:#c9d3b1;}
#map .stone-portal:hover {filter:none;}
#map .stone-portal:focus-visible {outline:2px solid #ead298;outline-offset:5px;}
#map .stone-portal:disabled {opacity:1;cursor:not-allowed;}
#map .stone-portal:disabled > strong {color:#a8afa0;}
#map .stone-portal[data-awake=true] > strong {border-color:#d3c385;}
@media(prefers-reduced-motion:reduce){#map .stone-portal .portal-stone-frame{transition:none;}}

/* Dungeon silhouettes differ from the travel arch, with measured alpha openings. */
#map .dungeon-gate[data-entrance=normal] {width:264px;height:264px;translate:-50% -88%;}
#map .dungeon-gate[data-entrance=normal] .portal-vortex {left:32%;top:26.5%;width:36%;height:38%;border-radius:2%;}
#map .dungeon-gate[data-entrance=world] {width:330px;height:330px;}
#map .dungeon-gate[data-entrance=world] .portal-vortex {left:35%;top:33%;width:30%;height:47%;border-radius:50% 50% 12% 12% / 36% 36% 12% 12%;}
#map .dungeon-gate[data-entrance=world] > strong,#map .dungeon-gate[data-entrance=world] > .portal-status {background:#162b3bed;border-color:#96b7c677;}
#map .dungeon-gate[data-entrance=world] > strong {color:#e3eff6;}
#map .dungeon-gate[data-entrance=world] > .portal-status {color:#bcd9e9;}

/* interface-polish.css */
/* Visual audit 1–5: controls, Sélène's fields, icons, public portraits and duels. */
.ui-icon { display:inline-block; width:1.2em; height:1.2em; flex:none; vertical-align:-.2em; pointer-events:none; }
.game-symbol { width:1.65em; height:1.65em; }

body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) button:not(:where(.shadow,.comfort-slot,.storage-slot,[data-equipped-slot],.drawer-close,.close,.npc-close,#storageClose)) {
  appearance:none; min-height:44px; padding:10px 15px; border:1px solid #bda472; border-radius:8px;
  color:#f7ebca; font:600 14px/1.35 system-ui,sans-serif; text-shadow:0 1px 1px #06160faa;
  background:#254437 linear-gradient(180deg,#3a5a49d9,#1b352be8);
  background-image:linear-gradient(180deg,#31523bdd,#142c22e8),url('/assets/storybook/ui/forest-leather.webp');
  background-size:auto,192px; box-shadow:inset 0 1px 0 #dcd0a333,0 2px 5px #051b1840;
  cursor:pointer; transition:background-color .15s,border-color .15s,box-shadow .15s;
}
body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) button:not(:where(.shadow,.comfort-slot,.storage-slot,[data-equipped-slot],.drawer-close,.close,.npc-close,#storageClose)):hover:not(:disabled) {
  border-color:#f1d196; box-shadow:inset 0 0 0 1px #dec18655,0 3px 10px #061d1555; color:#fff3d2;
}
body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) button:not(:where(.drawer-close,.close,.npc-close,#storageClose)):disabled {
  color:#b9c2ae; border-color:#727966; opacity:.65; cursor:not-allowed; box-shadow:none; text-shadow:none;
}
body.game-active #game :is(#saveQuestionSelection,#shadowProposalForm button[type=submit],#questionProposalForm button[type=submit],#npcService,#newcomerAdventure,[data-accept-duel],[data-propose-challenge],[data-firefly-submit],#mysteryBegin,#mysteryGuess,#comfortFilters [aria-pressed=true],.comfort-tabs [aria-pressed=true]) {
  color:#1c2d20; text-shadow:none; border-color:#e9d09a;
  background-color:#d4b573; background-image:linear-gradient(#efcf8ae0,#bb955ada),url('/assets/storybook/ui/vellum.webp');
  box-shadow:inset 0 1px 0 #fff1c9,0 2px 6px #081c1355;
}
body.game-active #game :is(#saveQuestionSelection,#shadowProposalForm button[type=submit],#questionProposalForm button[type=submit],#npcService,#newcomerAdventure,[data-accept-duel],[data-propose-challenge],[data-firefly-submit],#mysteryBegin,#mysteryGuess,#comfortFilters [aria-pressed=true],.comfort-tabs [aria-pressed=true]):hover:not(:disabled) { color:#12291c; }
body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) :is(.danger,.comfort-danger) { border-color:#b48172; color:#ffe0d1; }
body.game-active #game .newcomer-guide-head>button { width:auto; height:auto; flex:0 0 auto; padding:8px; font-size:11px; }
body.game-active #game .newcomer-guide-head>div { min-width:0; }
body.game-active #game .newcomer-controls { display:flex; flex-wrap:nowrap; gap:8px; margin-bottom:9px; }
body.game-active #game .newcomer-controls button { min-width:0; padding:9px 10px; font-size:12px; }
body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) :is(button,input,select,textarea,summary):focus-visible { outline:3px solid #f3d795; outline-offset:3px; }
body.game-active #game :is(.drawer,.modal,.mystery-dialog) :is(input:not([type=checkbox]),select,textarea) { box-sizing:border-box; min-height:44px; color:#f1e7ce; background:#1b352a; border:1px solid #8d9c77; border-radius:7px; padding:10px 12px; font:inherit; max-width:100%; }
body.game-active #game :is(.drawer,.modal,.mystery-dialog) textarea { width:100%; min-height:86px; resize:vertical; line-height:1.6; }
body.game-active #game :is(.drawer,.modal,.mystery-dialog) input[type=checkbox] { accent-color:#ba995f; width:18px; height:18px; vertical-align:middle; }
body.game-active #game :is(.drawer,.modal,.mystery-dialog) :is(input,textarea)::placeholder { color:#b4c0ac; opacity:1; }

/* Sélène writes on warm paper, within the existing service panel. */
body.game-active #game #npcSelene :is(textarea,input:not([type=checkbox]),select) {
  color:#2d3725; border:1px solid #b69a64; border-radius:6px;
  background-color:#e4d1a7; background-image:linear-gradient(#f1dfbde8,#e8d5ace0),url('/assets/storybook/ui/vellum.webp');
  background-size:auto,256px; box-shadow:inset 0 2px 5px #573d221c;
}
body.game-active #game #npcSelene :is(textarea,input,select)::placeholder { color:#5e674e; }
body.game-active #game #npcSelene textarea { padding:12px 14px; }
body.game-active #game #npcSelene label { color:#e5d6b5; }
body.game-active #game #npcSelene fieldset { border:1px solid #b9a17377; border-radius:9px; padding:16px; }
body.game-active #game #npcSelene legend { color:#edd09a; padding:0 8px; }
body.game-active #game #npcSelene :is(textarea,input:not([type=checkbox]),select):disabled { opacity:.7; cursor:not-allowed; }

/* Preserve the public identity stage, and frame the same painted body as on the map. */
.storybook-preview #players .shadow { border:1px solid #ad966559; background:linear-gradient(150deg,#254236ed,#142a23f2); }
.storybook-preview #players .shadow:hover,.storybook-preview #players .shadow:focus-visible { border-color:#ebd098; }
.storybook-preview #players .portrait.social-portrait {
  display:block; position:relative; width:112px; height:122px; margin:0 auto 14px; overflow:hidden;
  border:2px solid #bba173; border-radius:48% 48% 30% 30%;
  background:radial-gradient(ellipse at 50% 35%,#65704b,#213e30 68%)!important;
  box-shadow:inset 0 0 0 4px #122c2880,0 4px 14px #07180e50;
}
.storybook-preview #players .social-portrait.stage-0 { background:radial-gradient(ellipse at 50% 35%,#3f5145,#152b24 70%)!important; }
.storybook-preview #players .social-portrait .character-sprite {
  display:block; position:absolute; left:50%; top:20px; width:68px; height:91px;
  margin:0; transform:translateX(-50%) scale(1.05); transform-origin:50% 50%;
}
.storybook-preview #players .social-portrait .storybook-character { width:120px; height:120px; left:-26px; top:-26px; }
#players .shadow b { overflow-wrap:anywhere; }
#gold .ui-icon,#premiumBalance .ui-icon { color:#e2c077; width:21px; height:21px; margin-right:5px; }
.storage-slot.empty .ui-icon { width:27px; height:27px; color:#b3bfa0; }
#premiumCatalog strong>.ui-icon { width:28px; height:28px; color:#e4c485; margin-right:7px; }
.challenge-art .ui-icon { width:30px; height:30px; margin-right:6px; }
.firefly-sequence { display:flex; flex-wrap:wrap; gap:8px; }
.firefly-token { display:inline-flex; color:#eed89e; }
.challenge-controls button .ui-icon,[data-mystery-move] .ui-icon { margin-right:5px; }
#duels:focus { outline:none; }
#duels { scroll-margin-block:20px; }
#duels .duel { display:block; padding:18px; margin:12px 0; }
#duels .duel>h4 { font-size:18px; line-height:1.35; }
#duels .duel>p { margin:8px 0; }
#duels .duel>span { display:block; margin:0 0 12px; }
#duels .duel>button { margin:0 6px 6px 0; }
#duels .challenge-controls { gap:8px; margin:14px 0; }
#duels .challenge-controls button { flex:1 1 28%; }
#duels .challenge-controls>p { flex-basis:100%; margin:0 0 6px; }
#duels details { margin-top:12px; }
@media(max-width:650px) {
  body.game-active #game :is(.drawer,.modal,.newcomer-guide,.mystery-dialog,#comfortConfirm,#storageDialog) button:not(:where(.shadow,.comfort-slot,.storage-slot,[data-equipped-slot],.drawer-close,.close,.npc-close,#storageClose)) { font-size:12px; padding:10px 12px; }
  body.game-active #game #npcSelene fieldset { padding:10px; min-width:0; }
  .storybook-preview #players .portrait.social-portrait { width:100px; height:112px; }
}
@media(prefers-reduced-motion:reduce) { body.game-active #game button { transition:none!important; } }
body.comfort-reduced-motion #game button { transition:none!important; }

/* adventure-polish.css */
/* Audit 6–10: world annotations, compact expedition, games, meetings and book. */
#worldLabels{position:fixed;inset:0;z-index:18;pointer-events:none;}
.world-label{position:absolute;max-width:172px;min-width:88px;padding:6px 9px;border:1px solid #d0bb7d88;border-radius:7px;background:#142d25f2;box-shadow:0 2px 8px #00170e55;text-align:center;color:#f4e6bd;line-height:1.25;pointer-events:auto;cursor:pointer;}
.world-label b{display:block;font:600 11px/1.3 system-ui;}.world-label small{display:block;color:#c4d0ad;font:10px/1.4 system-ui;}.world-label small:empty{display:none;}
.world-label:after{content:'';position:absolute;top:-5px;left:var(--pointer-x);width:7px;height:7px;background:#1a362c;border-top:1px solid #d0bb7d88;border-left:1px solid #d0bb7d88;transform:rotate(45deg);}
.world-label[data-above=true]:after{top:auto;bottom:-5px;transform:rotate(225deg);}
#map .screen-label-source>strong,#map .screen-label-source>.portal-status,#map .scene-door.screen-label-source>span,#map .dungeon-stairs.screen-label-source>span,#map .screen-label-source>.slime-caption{visibility:hidden!important;}
#dungeonMapToggle{display:none;}

/* A painted playing surface keeps the interactive symbols real and readable. */
#duels .challenge-stage{padding:18px 20px 20px;margin:16px -6px 8px;min-height:190px;border:1px solid #b4a57177;border-radius:12px;background:linear-gradient(#06211735,#08261a38),url('/assets/storybook/ui/board-rps.webp') center/cover;box-shadow:inset 0 0 25px #00150c66;}
#duels .challenge-runes .challenge-stage{background-image:linear-gradient(#081d2633,#081c2544),url('/assets/storybook/ui/board-runes.webp');}
#duels .challenge-fireflies .challenge-stage{background-image:linear-gradient(#06211730,#08261a30),url('/assets/storybook/ui/board-fireflies.webp');}
#duels .board-score{display:flex;align-items:center;justify-content:center;gap:26px;text-align:center;text-shadow:0 2px 4px #00150e;}
#duels .board-score span{display:grid;gap:4px;font-size:12px;margin:0;}
#duels .board-score b{font:32px Georgia;color:#ffdda0;}
#duels .board-score i{font:11px system-ui;color:#d4dcbd;}
#duels .board-turn{text-align:center;color:#f6e9c7;font-size:12px;line-height:1.5;background:#092219c9;border-radius:20px;padding:6px 12px;margin:12px auto;max-width:95%;}
#duels .board-tally{display:block;text-align:center;font:20px Georgia;color:#ffdda0;margin:0;text-shadow:0 2px 4px #00150e;}
body.game-active #game #duels .board-choice{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:8px;min-width:0;min-height:92px;padding:12px 5px;background:linear-gradient(#d8bc80ee,#a88449ee);border:2px solid #ead4a0;color:#1b3024;border-radius:14px;box-shadow:inset 0 0 0 3px #68532755,0 4px 0 #443817aa;text-shadow:none;text-transform:capitalize;}
#duels .board-choice .ui-icon{width:34px;height:34px;margin:0;}
body.game-active #game #duels .challenge-runes .board-choice{background:linear-gradient(#496165f5,#283b42f5);color:#e3e7c2;border-color:#8ea49e;border-radius:28% 32% 20% 23%;}
body.game-active #game #duels .challenge-fireflies .board-choice{min-height:72px;box-shadow:inset 0 0 16px #dbdd6630,0 0 10px #ddcc5020;border:1px solid #c7b06c;border-radius:13px;background:#233d27ed;color:#f2d894;}
#duels .challenge-controls .firefly-inputs{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;width:100%;}
#duels .firefly-inputs .board-choice{font-size:10px;}
#duels .firefly-sequence{justify-content:center;gap:12px;}
#duels .firefly-token{border:1px solid #e6c76c;border-radius:50%;padding:11px;background:radial-gradient(#f8e69a33,#3a532adc);box-shadow:0 0 14px #dedd6655;color:#ffdc80;}
#duels .firefly-token .ui-icon{width:25px;height:25px;}
#duels .firefly-draft{flex-basis:100%;text-align:center;min-height:34px;padding:8px!important;border:1px dashed #bfb87b66;border-radius:7px;background:#082116d9;color:#ebdab0;font-size:12px;}
#duels .board-round-result{padding:10px 12px;border-left:3px solid #d9b873;background:#193a29;color:#e8d19f;font-size:12px;line-height:1.5;}
.round-arrived{animation:round-reveal .45s ease-out;}
@keyframes round-reveal{from{opacity:.35;transform:translateY(5px)}to{opacity:1;transform:none}}
#duels .board-rematch{margin-top:14px;}
#duelHistory>summary{padding:10px 0;color:#c7bd94;cursor:pointer;}
#duelHistory .challenge-stage{min-height:0;background:#173426;}
#duelHistory .board-score,#duelHistory .board-turn{display:none;}
.challenge-card .challenge-art{display:flex;align-items:center;justify-content:center;min-height:90px;border-radius:9px;background:linear-gradient(#0b281b55,#10271acc),url('/assets/storybook/ui/board-rps.webp') center/cover;color:#ecd093;}
.challenge-runes .challenge-art{background-image:linear-gradient(#10232e44,#162b38bb),url('/assets/storybook/ui/board-runes.webp');}
.challenge-fireflies .challenge-art{background-image:linear-gradient(#0b281b33,#10271aaa),url('/assets/storybook/ui/board-fireflies.webp');}

/* The meeting uses only the same public appearance as the community list. */
#game #panel{background:#173229f7;border:1px solid #c3ac76;padding:28px;max-height:calc(100dvh - 110px);overflow:auto;}
.meeting-heading{display:flex;align-items:center;gap:24px;text-align:left;margin:20px 0;}
.meeting-heading>div{min-width:0;}#panel #opponent{margin:0 0 10px;overflow-wrap:anywhere;font:30px Georgia;}
#meetingReveal{color:#bec7ab;font-size:12px;margin:0 0 10px;}
#meetingSeals{display:flex;gap:7px;}#meetingSeals i{width:11px;height:11px;border:1px solid #9e946a;border-radius:50%;background:#142b23;}#meetingSeals .revealed{background:#d5b16c;box-shadow:0 0 5px #deb86650;}
.storybook-preview #meetingPortrait{display:block;flex:none;position:relative;width:126px;height:148px;overflow:hidden;border:2px solid #bba173;border-radius:48% 48% 30% 30%;background:radial-gradient(ellipse at 50% 35%,#65704b,#213e30 68%);box-shadow:inset 0 0 0 4px #122c2880;}
.storybook-preview #meetingPortrait .character-sprite{display:block;position:absolute;left:50%;top:35px;width:68px;height:91px;margin:0;transform:translateX(-50%) scale(1.18);}
.storybook-preview #meetingPortrait .storybook-character{width:120px;height:120px;left:-26px;top:-26px;}
#panel #message{font-size:14px;line-height:1.6;color:#d8d9bb;}
#panel #actions{display:block;}.meeting-primary{display:flex;gap:10px;}.meeting-primary button{flex:1;}
body.game-active #game #panel [data-action=invite]{color:#182f22;background:linear-gradient(#ecd393,#bf9b59);border-color:#e5cb8e;text-shadow:none;}
.meeting-more{margin-top:18px;border-top:1px solid #aeb78b44;padding-top:12px;text-align:left;}.meeting-more summary{font-size:12px;color:#bbcab0;cursor:pointer;padding:8px 0;}.meeting-more>div{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px;}

/* Bound leather outside; warm paper and dark ink inside. */
#game #questionsDrawer.journal-book{background:linear-gradient(90deg,#4b3324,#2a291e 5%,#26382a 7%,#173229 100%);border:2px solid #ad8e58;box-shadow:inset 5px 0 0 #bb966855,0 12px 36px #051b1655;}
#questionsDrawer .journal-heading{display:block;padding:0 8px;border:0;}.journal-heading .eyebrow{color:#d1b87e;font-size:10px;letter-spacing:1.8px;}.journal-heading h2{font-family:Georgia,serif!important;margin:8px 0!important;}.journal-heading>p:last-child{color:#c3c6a8;font-size:13px;margin:0 0 18px;}
.journal-tabs{display:flex;gap:5px;margin:0 7px;}
body.game-active #game #questionsDrawer .journal-tabs button{flex:1;padding:10px 5px;border-radius:9px 9px 0 0;font-size:12px;min-width:0;}
body.game-active #game #questionsDrawer .journal-tabs [aria-selected=true]{color:#2b3927;background:#e6d4b0;border-color:#dcc698;border-bottom-color:#e6d4b0;box-shadow:none;text-shadow:none;}
.journal-page{padding:22px 22px 15px;border-radius:7px;background:linear-gradient(90deg,#b7985960,transparent 10%),linear-gradient(#f0dfbbea,#e4cfa8e8),url('/assets/storybook/ui/vellum.webp');border:1px solid #bca170;color:#2c3928;min-height:400px;}
#questionsDrawer #guildNotice{font-size:12px;line-height:1.5;margin:0 0 20px;padding-bottom:12px;border-bottom:1px solid #8a744e55;color:#576146;}
.journal-progress{display:flex;gap:16px;align-items:center;font-size:13px;}.journal-progress strong{white-space:nowrap;}.journal-page progress{width:100%;height:8px;accent-color:#526c3b;}
#questionsDrawer .journal-slots{grid-template-columns:1fr;gap:0;margin:18px 0;}
#questionsDrawer .journal-slot{display:flex;align-items:center;gap:14px;border:0;border-bottom:1px solid #997e4940;background:none;border-radius:0;padding:14px 0;box-shadow:none;}
#questionsDrawer .journal-slot small{display:block;font-size:10px;color:#6a6546;margin-bottom:5px;}
#questionsDrawer .journal-slot strong{font:16px/1.4 Georgia;color:#39472c;}
.journal-seal{display:grid;place-items:center;flex:none;width:32px;height:32px;border:1px dashed #927843;border-radius:50%;font:17px Georgia;color:#7f744f;}
.journal-slot.selected .journal-seal{border-style:solid;background:#baa06725;}.journal-slot.answered .journal-seal{background:#4f673c;color:#f8e9c3;border-color:#607343;}
.journal-page summary{font-size:14px;padding:12px 0;cursor:pointer;color:#3a5031;}.journal-page .privacy-help{font-size:12px;line-height:1.5;color:#3c4b2c;background:#c6b98655;border-color:#7a874d;}
#questionsDrawer #questions form{padding:14px 0;border-bottom:1px solid #937e5055;display:grid;gap:10px;}
#questionsDrawer #questions label{font-size:13px;color:#34472b;display:grid;gap:6px;}
body.game-active #game #questionsDrawer .journal-page select{color:#263a24;background:#f8edcd;border-color:#a88e58;font-size:13px;}
#questionsDrawer .question-catalog{grid-template-columns:1fr;gap:12px;}.journal-page h3{color:#30492c!important;font:21px Georgia;}.journal-page .question-choice{font-size:12px;line-height:1.5;}.journal-page fieldset{border-color:#9b895877;}.journal-page legend{font:16px Georgia;color:#4d6039;}
#questionsDrawer .journal-private{font:italic 12px/1.5 Georgia;color:#535438;border-top:1px solid #a58d5255;margin:20px 0 0;padding-top:14px;}
.journal-goal{display:grid;gap:8px;margin:20px 0;font-size:13px;}

@media(max-width:600px){
 .world-label{max-width:135px;padding:5px 7px;}.world-label b{font-size:10px;}.world-label small{font-size:9px;}
 .in-dungeon .scene-place{display:none;}
 .game-shell.in-dungeon #dungeonPanel{top:12px;bottom:auto;left:12px;right:72px;padding:9px 12px;max-height:50dvh;z-index:27;}
 .game-shell.in-dungeon #dungeonPanel .dungeon-heading h3{font-size:15px;margin:3px 0;}
 .game-shell.in-dungeon #dungeonPanel .dungeon-heading p{margin:4px 0;font-size:10px;}
 .game-shell.in-dungeon #dungeonPanel summary{min-height:35px;padding:9px 0;font-size:11px;}
 .game-shell.in-dungeon #dungeonPanel .dungeon-expedition button{min-height:44px;font-size:12px;}
 .in-dungeon .scene-camera{top:215px;left:12px;}.in-dungeon .scene-camera button{width:34px;height:36px;}
 .in-dungeon #dungeonMapToggle{display:grid;place-items:center;position:absolute;right:12px;top:76px;width:48px;height:54px;padding:5px;border:1px solid #b4a27388;border-radius:9px;background:#172f26f0;color:#e7d39f;z-index:29;font-size:9px;}
 #dungeonMapToggle svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.5;}
 .in-dungeon #dungeonCompass{display:none;top:70px;right:12px;left:auto;width:170px;z-index:28;}
 .in-dungeon.mobile-map-open #dungeonCompass{display:block;}
 .game-shell.in-dungeon .player-hud{bottom:12px;padding:8px;grid-template-columns:42px minmax(0,1fr);gap:7px;max-width:calc(100vw - 82px);min-height:79px;}
 .in-dungeon .player-hud .hud-profile{width:42px;}.in-dungeon .player-hud .hud-portrait{width:42px;height:57px;}
 .in-dungeon .player-hud .hud-location,.in-dungeon .player-hud .hud-xp-heading,.in-dungeon .player-hud .progress-track{display:none;}
 .in-dungeon .player-hud .hud-shortcuts{display:none;}.in-dungeon .player-hud .hud-details{align-self:center;}.in-dungeon .player-hud #identity{font-size:11px;margin-bottom:8px;}
 .in-dungeon .scene-interact{bottom:105px;left:12px;right:72px;max-width:none;min-height:44px;font-size:11px;}
 .game-shell.in-dungeon .side-tools{right:12px;gap:5px;}.game-shell.in-dungeon .side-tools button{width:48px;min-height:48px;padding:4px;}.in-dungeon .side-tools svg{width:23px;height:23px;}
 #duels .duel{padding:12px;}#duels .duel>h4{font-size:16px;}#duels .challenge-stage{padding:14px 8px;margin-left:-5px;margin-right:-5px;}
 #duels .board-score{gap:18px;}.board-score b{font-size:26px;}
 body.game-active #game #duels .board-choice{min-height:78px;padding:10px 3px;font-size:11px;}
 #duels .board-choice .ui-icon{width:26px;height:26px;}#duels .challenge-controls .firefly-inputs{grid-template-columns:repeat(3,minmax(0,1fr));}
 #duels .firefly-token{padding:8px;}#duels .firefly-token .ui-icon{width:22px;height:22px;}
 #game #panel{padding:20px;max-width:calc(100vw - 22px);}.meeting-heading{gap:15px;}#panel #opponent{font-size:22px;}
 .storybook-preview #meetingPortrait{width:100px;height:128px;}.storybook-preview #meetingPortrait .character-sprite{top:22px;transform:translateX(-50%);}
 .meeting-primary button{min-width:0;font-size:12px;}
 .journal-page{padding:17px 13px 12px;}.journal-progress{display:grid;gap:7px;}.journal-heading{padding:0;}.journal-heading .eyebrow{font-size:8px;letter-spacing:1px;}
 #questionsDrawer .journal-slot strong{font-size:14px;}.journal-seal{width:28px;height:28px;}#questionsDrawer .journal-slot{gap:10px;}
 body.game-active #game #questionsDrawer .journal-tabs button{font-size:10px;padding:10px 3px;}
}
@media(prefers-reduced-motion:reduce){.round-arrived{animation:none!important;}}
body.comfort-reduced-motion .round-arrived{animation:none!important;}

/* belongings-polish.css */
/* Audit 11–15. Existing painted art, parchment and leather; live data stays authoritative. */
body.game-active #game :is(#adventureDrawer,#equipmentDrawer,#inventoryDrawer,#npcWorkshop) {
  --paper: url('/assets/storybook/ui/vellum.webp'); --leather: url('/assets/storybook/ui/forest-leather.webp');
  background:linear-gradient(130deg,#223d30ed,#122b23f7),var(--leather); background-size:auto,384px;
}
body.game-active #game #adventureDrawer { width:min(760px,calc(100vw - 120px)); padding:26px; }
#adventureDrawer>h2 { margin:0 36px 20px 0; font:30px/1.15 Georgia,serif; }
.adventure-tabs { display:flex; gap:8px; margin:0 0 20px; padding-bottom:14px; border-bottom:1px solid #bda47266; }
body.game-active #game .adventure-tabs button { display:flex; align-items:center; justify-content:center; gap:7px; flex:1; min-width:0; padding:12px 8px; }
body.game-active #game #adventureDrawer .adventure-tabs [aria-selected=true] { background:linear-gradient(#edd59ce0,#c3a470de),var(--paper); color:#233729; text-shadow:none; border-color:#eed397; box-shadow:inset 0 0 0 2px #fff4ce44; }
.adventure-count { display:inline-grid; place-items:center; width:19px; height:19px; border-radius:50%; background:#e8c780; color:#203125; font-size:11px; }
.adventure-page[hidden] { display:none!important; }
.adventure-page>section { margin:0 0 16px; padding:18px; border:1px solid #a8966744; border-radius:12px; background:#13291ea6; }
#adventurePage-journey>.adventure-summary { background:linear-gradient(90deg,#173328f5,#173328bc),url('/assets/storybook/world/forest.webp') center/cover; border-color:#b5a16d77; }
.adventure-page h3 { margin:0 0 10px; font:23px/1.25 Georgia,serif; color:#eed5a1; }
.adventure-page p { line-height:1.65; }
#mapHelp { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; padding-top:8px; }
#mapHelp>span { display:flex; flex-direction:column; align-items:center; gap:7px; padding:10px 4px; background:#11281db3; border:1px solid #b39c6155; border-radius:9px; color:#eadbbc; font:12px/1.2 system-ui; }
#mapHelp i { display:block; position:relative; width:58px; height:64px; border-radius:0; background:none; overflow:hidden; }
#mapHelp .character-sprite { position:absolute; top:0; left:50%; width:68px; height:91px; margin:0; transform:translateX(-50%) scale(.68); transform-origin:50% 0; }
#mapHelp .storybook-character { position:absolute; width:110px; height:110px; left:-21px; top:-13px; }
#mapHelp .npc-sprite { position:absolute; left:0; top:0; width:58px; height:64px; }
.storybook-preview #mapHelp .npc-sprite { background:none; }
#mapHelp .storybook-npc { position:absolute; width:64px; height:66px; left:-3px; top:-2px; }
#mapHelp .legend-creature { width:60px; height:64px; background:url('/assets/storybook/combat/slime-poses.webp') 0 0 / 240px 300px no-repeat; }
.adventure-page #players { grid-template-columns:repeat(auto-fit,minmax(145px,1fr)); }

/* A wardrobe arranged around the actual animated character, never an illustration pasted over it. */
#comfortCharacter .comfort-character-layout { display:grid; grid-template-columns:minmax(115px,1fr) minmax(170px,1.5fr) minmax(115px,1fr); grid-template-rows:repeat(4,minmax(94px,auto)); gap:10px; padding:16px; border:1px solid #b99c6377; border-radius:15px; background:radial-gradient(ellipse at 50% 42%,#66744988,#0f281ebb 67%),var(--leather); background-size:auto,384px; }
#comfortCharacter .comfort-portrait { grid-column:2; grid-row:1/span 4; min-height:0; padding:6px 2px 12px; border:0; border-radius:42% 42% 12px 12px; background:radial-gradient(ellipse,#8d996149,transparent 70%); justify-content:center; overflow:hidden; }
.equipment-stage { position:relative; width:100%; height:260px; flex:none; }
#comfortCharacter .comfort-portrait .character-sprite { position:absolute; left:50%; top:24px; width:68px; height:91px; margin:0; transform:translateX(-50%) scale(2.2); transform-origin:50% 0; }
#comfortCharacter .comfort-portrait .storybook-character { position:absolute; width:120px; height:120px; top:-13px; left:-26px; }
#comfortCharacter .comfort-portrait h3 { margin:4px 0 8px; font:22px/1.25 Georgia,serif; max-width:100%; }
#comfortCharacter .comfort-portrait p { font-size:12px; margin:3px 0; }
#comfortCharacter .comfort-equipment-slots { display:contents; }
#comfortCharacter [data-equipped-slot=head] { grid-area:1/1; } #comfortCharacter [data-equipped-slot=torso] { grid-area:2/1; }
#comfortCharacter [data-equipped-slot=arms] { grid-area:3/1; } #comfortCharacter [data-equipped-slot=weapon] { grid-area:4/1; }
#comfortCharacter [data-equipped-slot=charm] { grid-area:1/3; } #comfortCharacter [data-equipped-slot=shield] { grid-area:2/3; }
#comfortCharacter [data-equipped-slot=legs] { grid-area:3/3; } #comfortCharacter [data-equipped-slot=feet] { grid-area:4/3; }
body.game-active #game #comfortCharacter .equipment-slot { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; padding:8px; border:1px solid #a38c5b77; border-radius:12px; background:linear-gradient(150deg,#3b46309c,#0e261ea6); text-align:center; }
body.game-active #game #comfortCharacter .equipment-slot.vacant { opacity:1; cursor:default; box-shadow:inset 0 2px 12px #04160d88; }
#comfortCharacter .equipment-slot .equipment-label { font:11px/1.3 system-ui; text-transform:uppercase; letter-spacing:.08em; color:#d4c29a; }
#comfortCharacter .equipment-slot strong { color:#a6b79a; font-size:10px; line-height:1.2; }
#comfortCharacter .equipment-slot.occupied { border-color:#d0b47a; background:linear-gradient(#516347bb,#203b2be8); }
#comfortCharacter .equipment-slot.occupied strong { color:#f3deb0; }
.equipment-art { height:42px; display:grid; place-items:center; }
#comfortCharacter .equipment-art img { width:46px; height:46px; margin:0; object-fit:contain; }
.equipment-silhouette { width:34px; height:34px; color:#8f9c78; opacity:.55; }
#comfortCharacter .comfort-stats { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; margin:16px 0; }
#comfortCharacter .comfort-stats div { display:grid; grid-template-rows:auto 1fr; align-items:start; justify-content:center; gap:5px; padding:12px 6px; border:1px solid #b69c6455; border-radius:9px; background:#10261dab; text-align:center; }
#comfortCharacter .comfort-stats dd { grid-row:1; font:24px Georgia,serif; color:#edcf92; }
#comfortCharacter .comfort-stats dt { grid-row:2; font:11px/1.4 system-ui; color:#c3ccb5; }

/* Stitched satchel pockets, a wooden private chest, and a parchment object sheet. */
body.game-active #game #inventoryDrawer { background:linear-gradient(120deg,#3d3d27e8,#152d22f5),var(--leather); background-size:auto,300px; }
#inventory.comfort-grid { padding:12px; gap:9px; border:1px solid #b2986259; border-radius:15px; background:linear-gradient(#483d27c4,#2a291ccc),var(--leather); box-shadow:inset 0 3px 14px #03170caa,inset 0 0 0 4px #9680592b; }
body.game-active #game #inventory .comfort-slot { padding:10px 5px; min-height:124px; border:1px solid #b099665e; border-top:2px solid #ac966387; border-radius:8px 8px 16px 16px; background:linear-gradient(120deg,#7464494f,#24291dbc),var(--leather); background-size:auto,192px; box-shadow:inset 0 -4px 7px #071c1366,0 2px 3px #061e1699; }
#inventory .comfort-empty { border:1px solid #b5a17d33; border-top:2px solid #b5a17d55; border-radius:8px 8px 16px 16px; background:linear-gradient(#172217c9,#373827c4); box-shadow:inset 0 4px 10px #061b11aa; min-height:80px; color:#8d917369; }
body.game-active #game #inventory .comfort-slot.selected { outline:2px solid #f0d492; outline-offset:1px; border-color:#eed7a4; background:linear-gradient(#90774b77,#3e442dc4),var(--leather); }
#inventory .comfort-icon .item-illustration { width:52px; height:52px; margin:0; }
.comfort-slot .comfort-quantity { position:absolute; top:5px; right:5px; padding:2px 5px; background:#10241de8; border:1px solid #b59a6366; border-radius:5px; }
.comfort-badges { display:flex; flex-wrap:wrap; justify-content:center; gap:3px; }
.comfort-badges>span { padding:3px 5px; border-radius:3px; line-height:1.3; }
.comfort-badges .badge-equipped { color:#e0edd2; background:#284b37; border:1px solid #8caf8388; }
.comfort-badges .badge-favorite { color:#342c17; background:#dfc183; border:1px solid #f5d89a; }
.comfort-badges .badge-new { color:#d7e8f6; background:#284853; border:1px solid #8bb8c1; }
#comfortItem { background:linear-gradient(#f1dfb3d4,#d9c394e6),var(--paper); background-size:auto,280px; color:#35402e; border:1px solid #b69b65; border-radius:8px 8px 18px 8px; box-shadow:0 4px 12px #03180f55; }
#comfortItem :is(h3,h4,p,.comfort-category,.comfort-muted) { color:#4b5439; }
#comfortItem .gain { color:#23622e; } #comfortItem .loss { color:#923723; }
.item-detail-heading { display:flex; align-items:center; gap:10px; }
.item-detail-art { flex:none; width:64px; height:74px; display:grid; place-items:center; border:1px solid #aa8c5580; border-radius:40% 40% 7px 7px; background:#bc9c6b38; }
#comfortItem .item-detail-art img { width:62px; height:66px; object-fit:contain; margin:0; }
#comfortItem .comfort-comparison div { border-color:#826d3c55; }
#storageDialog .storage-bag { background:linear-gradient(#493f2cd9,#343423ef),url('/assets/storybook/ui/forest-leather.webp'); background-size:auto,256px; border:1px solid #b59b6980; border-radius:20px 20px 13px 13px; box-shadow:inset 0 0 0 4px #bd9d6233; }
#storageDialog .storage-chest { background:repeating-linear-gradient(0deg,#704c2b00 0 48px,#140e0880 49px 52px),linear-gradient(90deg,#473624,#785739 46%,#3d3224); border:3px solid #a68a50; border-radius:12px; box-shadow:inset 0 0 0 3px #282b22,0 4px 12px #071a1466; }
#storageDialog .storage-slot { background:linear-gradient(#403e2cbb,#1c281cf0); border-color:#b39c6570; box-shadow:inset 0 2px 6px #03170ca8; }
#storageDialog .storage-chest .storage-slot { background:#201d16aa; border:1px solid #b2956399; border-radius:5px; }
#storageDialog .storage-slot.empty { border-style:solid; background:#1b251bcc; }
#storageDialog .storage-slot.empty .ui-icon { color:#a5a28066; width:20px; }
#storageDialog .storage-slot.selected { outline:2px solid #f1d394; outline-offset:1px; background:#64603f; }
#storageDialog .storage-slot.destination:not(:disabled) { border-color:#c8d7a0; }
#storageDialog .storage-item-icon img { width:48px; height:48px; margin:0; }

/* Service identities come from the resident and their already illustrated interior. */
body.game-active #game #npcWorkshop:is([data-service=blacksmith],[data-service=instructor],[data-service=merchant]) { width:min(760px,calc(100vw - 120px)); max-width:none; }
.service-banner { display:flex; align-items:center; gap:16px; min-height:116px; margin:0 0 12px; padding:10px 20px; border:1px solid #a79b7077; border-radius:12px; background:#172f23; overflow:hidden; }
#npcWorkshop[data-service=blacksmith] .service-banner { background:linear-gradient(90deg,#2c211ad6,#382719cc),url('/assets/storybook/world/inside-forge.webp') center 50%/cover; border-color:#bc8b5980; }
#npcWorkshop[data-service=instructor] .service-banner { background:linear-gradient(90deg,#212b3aca,#233441c9),url('/assets/storybook/world/inside-academy.webp') center/cover; border-color:#b7bc9299; }
#npcWorkshop[data-service=merchant] .service-banner { background:linear-gradient(90deg,#293322ce,#2b3526a8),url('/assets/storybook/world/inside-market.webp') center/cover; }
.service-portrait { flex:none; position:relative; width:86px; height:100px; }
.service-portrait .npc-sprite { display:block; position:absolute; width:72px; height:90px; left:7px; bottom:0; }
.service-portrait .storybook-npc { width:100px; height:103px; bottom:0; left:-14px; }
.service-banner .eyebrow { margin:0 0 6px; color:#efd5a0; font-size:11px; }
.service-banner p { margin:0; color:#e0e3d0; }
#npcWorkshop :is(#npcForge,#npcMarket)>h3 { margin:16px 0 12px; }
#npcWorkshop #npcServiceStatus { margin:8px 0; font-size:12px; color:#bccbb6; }
#npcWorkshop .comfort-recipe { padding:16px; margin:0 0 14px; border:1px solid #b0916277; border-radius:9px; background:linear-gradient(130deg,#3b3126,#1e2c22); }
#npcWorkshop[data-service=instructor] .comfort-recipe { border-color:#909c9b80; background:linear-gradient(120deg,#2c3c42,#1c2d31); }
.recipe-product { display:flex; align-items:center; gap:14px; }
.recipe-product>div { min-width:0; flex:1; }
.recipe-product p { margin:3px 0; color:#c5cbb8; font-size:13px; line-height:1.5; }
.recipe-art { display:grid; place-items:center; flex:none; width:78px; height:78px; border:1px solid #ac97676b; border-radius:12px; background:radial-gradient(ellipse,#87764666,#14282099); }
#npcWorkshop .recipe-art img { width:74px; height:74px; margin:0; object-fit:contain; }
#npcWorkshop .recipe-ingredients { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin:14px 0; padding:0; list-style:none; }
#npcWorkshop .recipe-ingredients li { display:flex; align-items:center; gap:8px; padding:7px 9px; margin:0; border:1px solid #9c906744; border-radius:7px; background:#0f201d60; font-size:12px; }
.recipe-ingredients li>span:last-child { display:flex; flex-direction:column; min-width:0; }
.recipe-ingredients img { width:40px; height:40px; margin:0; flex:none; }
.recipe-ingredients strong { color:#e0ddc6; font-size:12px; font-weight:500; }
.recipe-ingredients small { margin-top:3px; font-size:11px; }
.recipe-footer { display:flex; align-items:center; flex-wrap:wrap; gap:8px; padding-top:10px; border-top:1px solid #b3976555; }
.recipe-footer p { margin:0; font-size:12px; flex:1 1 130px; }
#npcWorkshop .recipe-footer button { margin:0; }
body.game-active #game #npcWorkshop .recipe-compare { border-color:#88907788; background:transparent; font-size:12px; }

/* Mina's shelves: a visible product, unit price and purchase controls on one shelf. */
#npcMarket>p { font-size:12px; color:#bfccb5; }
#npcMarket>h4 { margin:18px 0 12px; padding:7px 11px; border-block:1px solid #bda37170; background:#6a583022; color:#e7cd99; font:18px Georgia,serif; }
#npcWorkshop .comfort-market-card { display:grid; grid-template-columns:minmax(0,1fr) 168px; column-gap:18px; padding:14px 16px; margin:0 0 12px; border:1px solid #a48a5866; border-bottom:5px solid #7b6340; border-radius:8px; background:linear-gradient(100deg,#51492eaf,#253a29ef),var(--leather); box-shadow:0 4px 6px #071e1659,inset 0 1px 0 #ceb38130; }
.market-product { display:flex; gap:12px; align-items:center; grid-area:1/1; min-width:0; }
.market-product>div { min-width:0; }
#npcWorkshop .market-product h4 { margin:0 0 5px; font:18px/1.2 Georgia,serif; }
#npcWorkshop .market-product p { margin:0; font-size:12px; line-height:1.5; color:#c7d0ba; }
.market-art { display:grid; place-items:center; flex:none; width:76px; height:82px; border-radius:50% 50% 9px 9px; background:radial-gradient(ellipse,#a2966155,#1b2a1d33); }
#npcWorkshop .market-art img { width:74px; height:74px; margin:0; object-fit:contain; filter:drop-shadow(0 3px 3px #061a1260); }
.market-price { grid-area:2/1; display:flex; align-items:center; justify-content:space-between; gap:8px; padding:8px 0 0; }
.market-price strong { font-size:18px; color:#edcf8e; white-space:nowrap; }
.market-price strong span { font:11px system-ui; color:#d1c79d; }
.market-price small { font-size:11px; text-align:right; color:#c4cdb6; }
.market-purchase { grid-area:1/2/span 2; display:grid; gap:8px; align-content:center; padding-left:14px; border-left:1px solid #b29a6066; }
#npcWorkshop .market-purchase label { display:flex; justify-content:space-between; gap:8px; margin:0; font-size:12px; }
body.game-active #game #npcWorkshop .market-purchase input { width:66px; padding:7px; min-height:44px; }
.market-purchase>strong { font-size:12px; color:#e9d7b2; }
#npcWorkshop .market-purchase button { margin:0; width:100%; }
#npcWorkshop [data-market-reason] { grid-column:1/-1; margin:10px 0 0; padding-top:8px; border-top:1px solid #b69e6066; font-size:12px; }
@media(max-width:650px) {
 body.game-active #game :is(#adventureDrawer,#npcWorkshop:is([data-service=blacksmith],[data-service=instructor],[data-service=merchant])) { inset:66px 70px 12px 8px; width:auto; padding:20px 12px; }
 #adventureDrawer>h2 { font-size:25px; }
 .adventure-tabs { gap:4px; }
 body.game-active #game .adventure-tabs button { gap:4px; padding:9px 3px; font-size:11px; flex-wrap:wrap; }
 .adventure-tabs .ui-icon { width:16px; height:16px; }
 .adventure-page>section { padding:12px; }
 #mapHelp { gap:4px; } #mapHelp>span { font-size:10px; padding:7px 2px; }
 #mapHelp i { width:42px; height:52px; } #mapHelp .legend-creature { width:44px; height:52px; background-size:176px 220px; }
 #mapHelp .character-sprite { transform:translateX(-50%) scale(.55); } #mapHelp .storybook-npc { width:48px; height:50px; }
 #comfortCharacter .comfort-character-layout { grid-template-columns:minmax(0,1fr) minmax(74px,1.25fr) minmax(0,1fr); grid-template-rows:repeat(4,minmax(83px,auto)); padding:7px; gap:5px; }
 body.game-active #game #comfortCharacter .equipment-slot { padding:6px 3px; gap:4px; }
 #comfortCharacter .equipment-slot .equipment-label { font-size:9px; letter-spacing:0; }
 #comfortCharacter .equipment-slot strong { font-size:9px; }
 .equipment-art { height:32px; } #comfortCharacter .equipment-art img { width:34px; height:34px; } .equipment-silhouette { width:26px; height:26px; }
 .equipment-stage { height:160px; } #comfortCharacter .comfort-portrait .character-sprite { top:22px; transform:translateX(-50%) scale(1.15); }
 #comfortCharacter .comfort-portrait h3 { font-size:14px; } #comfortCharacter .comfort-portrait p { font-size:10px; }
 #comfortCharacter .comfort-stats { gap:4px; } #comfortCharacter .comfort-stats dd { grid-row:1; font-size:21px; } #comfortCharacter .comfort-stats dt { grid-row:2; font-size:10px; }
 #inventory.comfort-grid { padding:8px; gap:6px; } body.game-active #game #inventory .comfort-slot { min-height:115px; padding:10px 3px; }
 #inventory .comfort-icon .item-illustration { width:44px; height:44px; }
 .service-banner { padding:8px; gap:8px; min-height:96px; } .service-portrait { width:58px; height:86px; }
 .service-portrait .npc-sprite { width:50px; height:74px; left:0; } .service-portrait .storybook-npc { width:72px; height:75px; left:-9px; }
 .service-banner .eyebrow { font-size:9px; line-height:1.5; letter-spacing:.08em; } .service-banner p { font-size:11px; }
 #npcWorkshop .comfort-recipe { padding:12px; } .recipe-art { width:56px; height:62px; } #npcWorkshop .recipe-art img { width:54px; height:58px; }
 .recipe-product { gap:9px; } .recipe-product p { font-size:11px; } #npcWorkshop .recipe-product h4 { font-size:15px; }
 #npcWorkshop .recipe-ingredients { grid-template-columns:1fr; gap:6px; } .recipe-footer { gap:6px; } .recipe-footer>* { flex-basis:100%; } .recipe-footer button { width:100%; }
 #npcWorkshop .comfort-market-card { grid-template-columns:1fr; padding:12px; gap:9px; }
 .market-product { gap:8px; } .market-art { width:56px; height:66px; } #npcWorkshop .market-art img { width:54px; height:60px; }
 #npcWorkshop .market-product h4 { font-size:16px; } #npcWorkshop .market-product p { font-size:11px; }
 .market-price { grid-area:2/1; padding:0; } .market-price small { max-width:100px; }
 .market-purchase { grid-area:3/1; grid-template-columns:1fr 1fr; align-items:center; padding:9px 0 0; border-left:0; border-top:1px solid #b29a6066; }
 #npcWorkshop .market-purchase label { font-size:11px; } .market-purchase>strong { text-align:right; font-size:11px; } #npcWorkshop .market-purchase button { grid-column:1/-1; }
}
@media(max-width:360px) {
 .adventure-tabs .ui-icon { display:none; } .adventure-page>section { padding:9px; }
 #mapHelp { grid-template-columns:repeat(2,minmax(0,1fr)); }
 #comfortCharacter .comfort-character-layout { grid-template-columns:minmax(0,1fr) 76px minmax(0,1fr); padding:4px; gap:3px; }
 #comfortCharacter .equipment-slot .equipment-label { font-size:8px; }
 .comfort-toolbar { grid-template-columns:1fr; }
 .market-purchase { grid-template-columns:1fr; } .market-purchase>strong { text-align:left; }
}

.equipment-identity { min-width:0; max-width:100%; text-align:center; }
@media(max-width:650px) {
 #comfortCharacter .comfort-portrait { display:contents; }
 #comfortCharacter .equipment-stage { grid-area:1/2/span 4; align-self:center; }
 #comfortCharacter .equipment-identity { grid-column:1/-1; padding:10px 3px 4px; border-top:1px solid #af996044; }
 #comfortCharacter .equipment-identity h3 { font-size:16px; }
 #comfortCharacter .equipment-identity p { display:inline-block; margin:3px 8px; font-size:11px; }
}
@media(max-height:450px) {
 body.game-active #game #npcPanel { top:72px; bottom:8px; max-height:calc(100dvh - 80px); overflow-y:auto; overscroll-behavior:contain; }
}

#npcWorkshop[data-service=blacksmith] { --service-row:1; }
#npcWorkshop[data-service=merchant] { --service-row:2; }
#npcWorkshop[data-service=instructor] { --service-row:6; }

/* village-services.css */
/* Audit 16–20: village crafts, live fitting, currency, portraits and company. */
.catalog-art{display:block;width:110px;height:110px;flex:none;background-image:url('/assets/storybook/ui/catalog-atlas.webp');background-repeat:no-repeat;background-size:300% 200%;filter:drop-shadow(0 4px 4px #071c1950);}
.catalog-cell-0{background-position:0 0}.catalog-cell-1{background-position:50% 0}.catalog-cell-2{background-position:100% 0}.catalog-cell-3{background-position:0 100%}.catalog-cell-4{background-position:50% 100%}.catalog-cell-5{background-position:100% 100%}
body.game-active #game #npcWorkshop:is([data-service=provisioner],[data-service=banker],[data-service=innkeeper]){width:min(850px,calc(100vw - 120px));max-width:none;padding:26px;}
#npcWorkshop[data-service=provisioner]{background:linear-gradient(125deg,#253b44ee,#152d2bf5),url('/assets/storybook/ui/forest-leather.webp');}
#npcPremium:not([hidden]){display:grid;grid-template-columns:minmax(230px,.85fr) minmax(300px,1.3fr);gap:12px 20px;}
#npcPremium>h3,#npcPremium>#premiumBalance{grid-column:1/-1;margin:0;}
#npcPremium>h3,#npcBank>h3{font:24px/1.25 Georgia,serif;color:#efd9aa;}
#npcPremium>#premiumBalance{padding:10px 0;color:#b8dce0;font-size:13px;}
#premiumBalance .ui-icon{color:#a6dce7;}
#cosmeticFitting{align-self:start;position:sticky;top:0;padding:20px 12px 12px;border:1px solid #afaa7f80;border-radius:48% 48% 12px 12px;background:radial-gradient(ellipse at 50% 40%,#71817b80,#142d2e 70%);text-align:center;overflow:hidden;}
.fitting-heading{display:grid;gap:7px;padding-top:26px;}.fitting-heading .eyebrow{font-size:10px;letter-spacing:.13em;color:#c5c9ae;}.fitting-heading strong{font:24px Georgia,serif;color:#f5e3ba;}
.fitting-stage{height:280px;position:relative;margin:5px 0;}
.fitting-stage:after{content:'';position:absolute;width:75%;height:35px;left:12.5%;bottom:14px;border:1px solid #c6c6a577;border-radius:50%;background:radial-gradient(ellipse,#71877880,#142923);box-shadow:0 5px 0 #102925,0 6px 0 #a9b39344;}
#cosmeticFitting .character-sprite{position:absolute;left:50%;top:40px;width:68px;height:91px;margin:0;transform:translateX(-50%) scale(2.15);transform-origin:50% 0;z-index:1;}
#cosmeticFitting .storybook-character{position:absolute;width:120px;height:120px;left:-26px;top:-13px;}
#cosmeticFitting .fitting-controls{display:flex;gap:5px;justify-content:center;}
body.game-active #game #cosmeticFitting .fitting-controls button{padding:9px 8px;font-size:12px;}
body.game-active #game #npcPremium [aria-pressed=true]{border-color:#e4d1a2;box-shadow:inset 0 0 0 1px #e4d1a27a;color:#fff0c9;}
#fittingNote{font-size:11px;line-height:1.6;color:#bacbbc;margin:12px 0 0;}
.fitting-pass{position:absolute;inset:0;display:grid;place-items:center;z-index:1;}.fitting-pass .catalog-art{width:250px;height:250px;}
.fitting-leaves{display:none;position:absolute;inset:0;z-index:2;pointer-events:none;}
#cosmeticFitting[data-preview=trail-leaves] .fitting-leaves{display:block;}
.fitting-leaf{position:absolute;bottom:16px;left:18%;color:#c3bc68;transform:rotate(-30deg);}.fitting-leaf .ui-icon{width:28px;height:28px;}
.leaf-1{left:36%;bottom:25px;color:#90ac6b;transform:rotate(42deg)}.leaf-2{left:67%;bottom:40px;transform:rotate(-50deg)}.leaf-3{left:23%;bottom:80px;color:#8eb176;transform:rotate(15deg)}.leaf-4{left:74%;bottom:108px;color:#93ac70;transform:rotate(80deg)}
#cosmeticFitting.is-walking .fitting-leaf{animation:fitting-leaf 2.6s ease-out infinite;}.leaf-1{animation-delay:-.5s!important}.leaf-2{animation-delay:-1s!important}.leaf-3{animation-delay:-1.5s!important}.leaf-4{animation-delay:-2s!important}
@keyframes fitting-leaf{0%{opacity:0;translate:0 10px;rotate:0deg}25%{opacity:1}100%{opacity:0;translate:-30px -90px;rotate:80deg}}
#premiumCatalog{display:grid;gap:12px;align-content:start;}
#premiumCatalog .premium-product{display:grid;grid-template-columns:112px minmax(0,1fr);gap:14px;padding:14px;margin:0;border:1px solid #b1a67766;border-radius:11px;background:linear-gradient(130deg,#42564477,#182e2aee);}
body.game-active #game #npcPremium .premium-look{align-self:start;display:grid;justify-items:center;gap:5px;padding:2px 0 8px;min-height:0;border:1px solid #81938188;border-radius:45% 45% 8px 8px;background:radial-gradient(ellipse,#60726766,#132d2a70);font-size:11px;}
.premium-look .catalog-art{width:110px;height:110px;}
#premiumCatalog h4{font:20px/1.2 Georgia,serif;color:#f0d8a4;margin:0 0 7px;}
#premiumCatalog p{font-size:12px;line-height:1.5;color:#c5d1be;margin:0 0 7px;}
#premiumCatalog .premium-price{color:#b5dce0;font-size:15px;font-weight:600;}.premium-price span{font-size:11px;font-weight:400;}
.premium-product-copy>small{display:block;font-size:11px;color:#bdc9b6;margin:0 0 8px;}
body.game-active #game #premiumCatalog [data-premium-buy]{width:100%;margin:0;}
.bank-balances{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:16px 0;}
.bank-balance{display:flex;flex-direction:column;gap:12px;padding:17px 12px;border:1px solid #b89c6480;border-radius:10px;background:radial-gradient(ellipse at 80% 0,#b5934733,transparent 65%),#24362b;}
.bank-balance>span{display:flex;align-items:center;gap:7px;color:#e5c483;font-size:12px;}.bank-balance .ui-icon{width:24px;height:24px;}
.bank-balance>strong{font:29px/1.1 Georgia,serif;color:#f1dab0;overflow-wrap:anywhere;}.bank-balance strong small{font:12px system-ui;}.bank-balance>small{color:#b4c1ad;font-size:11px;}
.bank-balance.shards{border-color:#85b8ba90;background:radial-gradient(ellipse at 80% 0,#6497a233,transparent 65%),#203b39;}.bank-balance.shards>span,.bank-balance.shards>strong{color:#b6e1e7;}
#bankTransfer{display:grid;grid-template-columns:minmax(140px,1fr) 1fr 1fr;gap:10px;padding:18px;border:1px solid #ad966e66;border-radius:10px;background:#0e281e7a;}
#bankTransfer>label,#bankTransfer>.bank-amount-hint{grid-column:1/-1;margin:0;}.bank-amount-hint{font-size:11px;line-height:1.5;color:#c1cbb5;}
#bankTransfer>input{width:100%;min-width:0;margin:0;grid-column:auto;}#bankTransfer>button{margin:0;}
#npcBank>.premium-pack-title{margin:24px 0 6px;}#premiumPaymentNotice{font-size:12px;color:#b7c8bb;line-height:1.6;}
#premiumPackages{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;}
#premiumPackages .premium-package{display:flex;flex-direction:column;align-items:center;padding:8px 12px 14px;margin:0;border:1px solid #819a8180;border-radius:12px;background:linear-gradient(140deg,#4d645140,#182d27);text-align:center;}
.premium-package .catalog-art{width:140px;height:140px;max-width:100%;}.premium-package h4{font:19px/1.2 Georgia,serif;margin:0 0 8px;color:#e9d4a8;}.premium-amount{color:#bce5e9;font-size:18px;}.premium-amount small{font-size:11px;font-weight:400;}.package-euros{font-size:12px;color:#c6d0bd;padding:8px 0 12px;}
body.game-active #game #premiumPackages button{margin-top:auto;width:100%;font-size:11px;padding:10px 5px;opacity:1;color:#b2c1b2;}
/* Closer, profession-framed portraits, painted from the existing NPC atlas. */
body.game-active #game #npcPanel{--portrait-tone:#5e7155;--portrait-line:#b2ae78;width:min(590px,calc(100vw - 32px));max-height:calc(100dvh - 100px);overflow-y:auto;padding:26px;text-align:left;background:linear-gradient(120deg,#324333eb,#142c23f7),url('/assets/storybook/ui/forest-leather.webp');border:1px solid #bbab79;}
#npcPanel[data-profession=blacksmith]{--portrait-tone:#976644;--portrait-line:#ce9b63;}#npcPanel[data-profession=banker]{--portrait-tone:#55746a;--portrait-line:#bbc296;}#npcPanel[data-profession=provisioner],#npcPanel[data-profession=instructor]{--portrait-tone:#617b8e;--portrait-line:#abbcaf;}
.npc-dialogue-heading{display:grid;grid-template-columns:190px minmax(0,1fr);gap:22px;align-items:center;margin:0 0 18px;}
body.game-active #game #npcPortrait{width:190px;height:190px;margin:0;border:1px solid var(--portrait-line);border-radius:48% 48% 12px 12px;overflow:hidden;background:radial-gradient(ellipse at 50% 35%,var(--portrait-tone),#1b3228 80%);box-shadow:inset 0 0 0 5px #112a2560,0 4px 12px #0a201744;}
#npcPortrait .npc-sprite{left:50%;bottom:5px;translate:-50% 0;transform:scale(1.65);transform-origin:50% 100%;}
#npcPortrait[data-dialogue-ready] .npc-sprite{visibility:hidden;}
.npc-dialogue-art{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;transform-origin:50% 100%;animation:npc-greeting 5.5s ease-in-out infinite;}
@keyframes npc-greeting{0%,65%,100%{transform:rotate(0) translateY(1px)}78%{transform:rotate(-.65deg) translateY(0)}90%{transform:rotate(.35deg) translateY(0)}}
#npcProfessionEmblem{display:grid;place-items:center;width:42px;height:42px;margin-bottom:15px;border:1px solid var(--portrait-line);border-radius:50%;background:#172e22;color:#e5c58c;}#npcProfessionEmblem .ui-icon{width:23px;height:23px;}
#npcPanel #npcRole{font-size:10px;letter-spacing:.12em;line-height:1.6;color:#cbd1b3;margin:0 0 8px;}#npcPanel #npcName{font:36px/1.1 Georgia,serif;color:#f5e0b5;margin:0;}
#npcPanel #npcDescription{padding:19px;margin:0 0 18px;border:1px solid #beaa7a;border-radius:6px 6px 15px 6px;background:linear-gradient(#eddbb5e8,#d7c293ef),url('/assets/storybook/ui/vellum.webp');color:#36412c;font:16px/1.65 Georgia,serif;}
#npcPanel #npcService{width:100%;}
/* Medallions describe only public ranks; no portraits are inferred. */
#leaderboard .rank-row{display:grid;grid-template-columns:46px minmax(0,1fr) auto;gap:12px;align-items:center;padding:11px 12px;margin:7px 0;border:1px solid #ac976354;border-radius:9px;background:linear-gradient(100deg,#46543d7a,#172e2388);}
#leaderboard .rank-row.self{border-color:#c9b580;background:linear-gradient(100deg,#64734488,#294b3688);}
.rank-medallion{position:relative;display:grid;place-items:center;width:40px;height:48px;color:#a5ae8a;}.rank-medallion>.ui-icon{position:absolute;inset:0;width:40px;height:48px;}.rank-medallion>b{position:relative;top:-5px;font:17px Georgia;}
[data-place="1"] .rank-medallion{color:#f1ce83;}[data-place="2"] .rank-medallion{color:#c4d4d4;}[data-place="3"] .rank-medallion{color:#cd9e78;}
#leaderboard strong{font-size:14px;overflow-wrap:anywhere;}#leaderboard strong>small{display:block;font-size:10px;color:#e3ce99;margin-top:4px;}#leaderboard .rank-row>small{font-size:11px;color:#c4ceb8;}
.community-empty{display:flex;align-items:center;gap:15px;min-width:0;padding:17px 12px;border:1px dashed #a3956460;border-radius:10px;background:radial-gradient(ellipse at 0 0,#71825733,transparent 80%);}
.community-empty-art{display:grid;place-items:center;flex:none;width:58px;height:64px;border:1px solid #b9a57966;border-radius:45% 45% 30% 30%;color:#d6bd84;background:radial-gradient(ellipse,#53674788,#20362ba0);box-shadow:inset 0 0 0 4px #263b2b80;}.community-empty-art>.ui-icon{width:31px;height:31px;}
.community-empty strong{color:#e7d4a5;font:18px/1.3 Georgia,serif;}.community-empty p{font-size:12px;color:#bfcbb6;margin:6px 0 0;line-height:1.55;}
#npcWorkshop[data-service=innkeeper] .service-banner{background:linear-gradient(90deg,#3c2e20e0,#3d3022aa),url('/assets/storybook/world/inside-inn.webp') center/cover;border-color:#c29c62;}
#npcWorkshop[data-service=innkeeper]{--service-row:4;}.inn-companion{display:flex;align-items:center;gap:12px;padding:16px;border:1px solid #bba47480;border-radius:9px;background:#31433388;}.inn-companion>div{flex:1;}.inn-companion small{display:block;margin-top:5px;color:#b9ceb0;font-size:11px;}
#npcRecruit>[data-community-open]{margin-top:14px;}
.friend-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:14px;border:1px solid #9b916754;border-radius:9px;background:#253c2c80;}.friend-row>span,.friend-row>small{flex-basis:100%;font-size:12px;color:#c0ccb8;}.friend-row[data-online=true]>.ui-icon{color:#b5d48e;}
/* Timber signs remain proxies for the original accessible entrance controls. */
.world-label .sign-emblem{display:none;}.world-label.village-sign{display:flex;align-items:center;gap:7px;max-width:195px;min-width:108px;padding:7px 11px 7px 7px;border:1px solid #b89d68;border-bottom:3px solid #342d1b;border-radius:5px 9px 8px 5px;background:repeating-linear-gradient(0deg,#8b714a00 0 12px,#322a1a22 13px 14px),linear-gradient(110deg,#755b38,#493c28);box-shadow:inset 0 1px 0 #e7cb8666,inset 0 0 0 3px #251f1526,0 3px 5px #09211688;text-align:left;}
.world-label.village-sign .sign-emblem{display:grid;place-items:center;width:29px;height:34px;flex:none;border:1px solid #c2aa7166;border-radius:50% 50% 5px 5px;color:#ecd294;background:#2e3322;}.sign-emblem>.ui-icon{width:20px;height:20px;}
.world-label.village-sign b{font:600 11px/1.3 Georgia,serif;color:#f3e0b1;}.world-label.village-sign small{color:#d7c399;font:9px/1.5 system-ui;}
.world-label.village-sign:after{background:#55412b;border-color:#c0a471;}.world-label.village-sign:hover,.world-label.village-sign[data-focused=true]{border-color:#ffe1a2;box-shadow:0 0 0 2px #c7af7588,0 3px 8px #09211699;}
.world-label.village-sign[data-sign-kind=district]{background:repeating-linear-gradient(0deg,transparent 0 12px,#b59b4930 13px 14px),linear-gradient(110deg,#4c5736,#333e29);border-radius:4px 16px 16px 4px;}
@media(max-width:900px){#npcPremium:not([hidden]){grid-template-columns:1fr;}#cosmeticFitting{position:relative;max-width:100%;border-radius:16px;}.fitting-heading{padding-top:0;}.fitting-stage{height:250px;}.fitting-stage:after{width:220px;left:calc(50% - 110px);}#cosmeticFitting .character-sprite{top:18px;}.fitting-leaves{width:280px;left:calc(50% - 140px);}.bank-balances{gap:7px;}.bank-balance{padding:12px 9px;}.bank-balance>span{font-size:10px;}.bank-balance>strong{font-size:24px;}}
@media(max-width:650px){
 body.game-active #game #npcWorkshop:is([data-service=provisioner],[data-service=banker],[data-service=innkeeper]){inset:66px 70px 12px 8px;width:auto;padding:20px 12px;}
 #premiumCatalog .premium-product{grid-template-columns:80px minmax(0,1fr);padding:10px;gap:9px;}.premium-look .catalog-art{width:78px;height:78px;}#premiumCatalog h4{font-size:18px;}
 .bank-balances{grid-template-columns:1fr;}.bank-balance{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:7px;}.bank-balance>small{grid-column:1/-1;}.bank-balance>span{font-size:11px;}.bank-balance>strong{font-size:23px;}
 #bankTransfer{grid-template-columns:1fr 1fr;padding:12px;gap:8px;}#bankTransfer>input{grid-column:1/-1;}
 #premiumPackages{grid-template-columns:1fr;}.premium-package .catalog-art{width:165px;height:165px;}
 body.game-active #game #npcPanel{padding:20px 16px;max-height:calc(100dvh - 90px);}.npc-dialogue-heading{grid-template-columns:120px minmax(0,1fr);gap:16px;}body.game-active #game #npcPortrait{width:120px;height:140px;}#npcPanel #npcName{font-size:29px;}#npcProfessionEmblem{width:32px;height:32px;margin-bottom:10px;}#npcPanel #npcDescription{font-size:15px;padding:15px;}
 #leaderboard .rank-row{grid-template-columns:40px minmax(0,1fr);gap:4px 9px;padding:9px;}#leaderboard .rank-row>small{grid-column:2;font-size:10px;}.rank-medallion{grid-row:1/span 2;}
 .community-empty{align-items:flex-start;gap:10px;padding:14px 10px;}.community-empty-art{width:40px;height:49px;}.community-empty-art>.ui-icon{width:24px;height:24px;}.community-empty strong{font-size:16px;}.inn-companion{flex-wrap:wrap;}.inn-companion button{width:100%;}
 .world-label.village-sign{max-width:155px;min-width:100px;gap:5px;padding:5px 7px 5px 5px;}.world-label.village-sign .sign-emblem{width:24px;height:30px;}.world-label.village-sign b{font-size:10px;}.world-label.village-sign small{font-size:8px;}
}
@media(max-height:500px){body.game-active #game #npcPanel{top:72px;bottom:auto;max-height:calc(100dvh - 80px);transform:translateX(-50%);}}
@media(prefers-reduced-motion:reduce){.npc-dialogue-art,#cosmeticFitting .fitting-leaf{animation:none!important;}}
body.comfort-reduced-motion .npc-dialogue-art,body.comfort-reduced-motion #cosmeticFitting .fitting-leaf{animation:none!important;}

#leaderboard .rank-medallion>b{display:block;color:inherit;font-weight:600;}

/* expedition-polish.css */
/* Audit 21–25: readable creatures, boss identity, explored cartography and mobile space. */
.world-label[data-kind=creature][data-detailed=false]:not([data-boss=true]){min-width:0;max-width:80px;padding:3px 7px;border-color:#c3c09266;border-radius:10px;background:#173228d9;box-shadow:0 2px 4px #071c1599;}
.world-label[data-kind=creature][data-detailed=false]:not([data-boss=true]) b{display:none;}
.world-label[data-kind=creature][data-detailed=false]:not([data-boss=true]) small{font:600 10px/1.3 system-ui;color:#ece0b4;}
.world-label[data-kind=creature][data-selected=true]{border-color:#f0da99;background:#273d2bf7;box-shadow:0 0 0 1px #e2cd8b80,0 3px 8px #071c1588;}
.world-label[data-kind=creature][data-alert=true]{border-color:#dbaa75;}
.world-label[data-kind=creature][data-boss=true]{border-color:#d4b168;background:linear-gradient(#4d5231,#213b2d);}
body.comfort-hide-monster-names .world-label[data-kind=creature][data-selected=false] b{display:none;}
body.comfort-hide-monster-levels .world-label[data-kind=creature][data-detailed=false] small{display:none;}
body.comfort-hide-monster-levels .world-label[data-kind=creature][data-detailed=false]:not([data-boss=true]){display:none;}
.dungeon-wall-canvas{position:absolute;pointer-events:none;image-rendering:auto;}
/* The boss banner is based solely on a boss currently visible to this player. */
#bossEncounter{position:fixed;left:50%;top:99px;translate:-50% 0;z-index:21;display:flex;gap:14px;align-items:center;width:min(450px,calc(100vw - 56px));padding:13px 20px;border:1px solid #c7b175;border-radius:36px 36px 13px 13px;background:linear-gradient(120deg,#354934ed,#132b23f5),url('/assets/storybook/ui/forest-leather.webp');box-shadow:0 4px 20px #061b1670,inset 0 0 0 4px #dab98515;pointer-events:none;}
#bossEncounter[hidden]{display:none;}
.boss-seal{display:grid;place-items:center;flex:none;width:46px;height:52px;border:1px solid #beaa73;border-radius:48% 48% 16% 16%;color:#e9c77f;background:radial-gradient(ellipse,#86724b,#253b2d);box-shadow:inset 0 0 0 3px #122e2766;}.boss-seal .ui-icon{width:30px;height:30px;}
.boss-copy{min-width:0;flex:1;}.boss-kind{font:8px/1.3 system-ui;letter-spacing:.17em;color:#c6c8a5;margin:0 0 5px;}
#bossEncounter h2{font:25px/1.15 Georgia,serif;color:#f4dda4;margin:0 0 8px;}
.boss-health{height:16px;padding:2px;border:1px solid #bfa36b;border-radius:8px;background:#10201c;box-shadow:inset 0 1px 3px #0009;overflow:hidden;}
.boss-health>i{display:block;height:100%;border-radius:5px;background:linear-gradient(#c0cb75,#7c9d4c);transition:width .18s;box-shadow:inset 0 1px 0 #eef0b7;}
.boss-numbers{font:10px/1.4 system-ui;color:#ded5b3;text-align:right;margin:5px 0 0;}
#bossEncounter[data-world=true]{width:min(490px,calc(100vw - 56px));border:2px solid #a2b7c9;border-radius:6px 32px 6px 32px;background:linear-gradient(110deg,#273d50f5,#1c243cf5),url('/assets/storybook/ui/forest-leather.webp');box-shadow:inset 0 0 0 4px #9ab6c42b,0 0 23px #7aa6ba30,0 7px 25px #07141b80;}
#bossEncounter[data-world=true] h2{color:#e6e3ce;}#bossEncounter[data-world=true] .boss-seal{height:60px;width:52px;border-color:#aab8c7;background:radial-gradient(ellipse,#506b85,#232c43);color:#c5dceb;border-radius:5px 40% 5px 40%;}
#bossEncounter[data-world=true] .boss-kind{color:#a9cadb;}#bossEncounter[data-world=true] .boss-health{height:20px;border-color:#96acc4;}#bossEncounter[data-world=true] .boss-health>i{background:linear-gradient(#aeb7e4,#627cb2);box-shadow:inset 0 1px 0 #e2e8f8;}
#game:has(.drawer:not([hidden]),.modal:not([hidden]),dialog[open]) #bossEncounter{display:none;}
/* A parchment map, without revealing geometry or objectives outside discovery. */
#game .dungeon-compass{width:238px;padding:13px;border:1px solid #bda474;border-radius:12px;background:linear-gradient(#304334f2,#182e26f5),url('/assets/storybook/ui/forest-leather.webp');box-shadow:inset 0 0 0 3px #c9b27c20,0 5px 18px #041a1580;}
#game .dungeon-compass[data-theme=crypt]{background:linear-gradient(#263b47f2,#1a2b34f5),url('/assets/storybook/ui/forest-leather.webp');border-color:#9aafae;}
#dungeonCompass>.compass-heading{display:flex;justify-content:space-between;gap:6px;margin:0 0 7px;font:12px/1.3 Georgia,serif;letter-spacing:0;color:#ebd5a1;}
#dungeonCompass .compass-percent{font:11px system-ui;color:#dbc28b;}
.compass-floor{font:10px/1.4 system-ui;color:#becdb6;margin:0 0 9px;}
.compass-paper{position:relative;padding:6px;border:1px solid #a99563;border-radius:6px;background:linear-gradient(#d5c18bdc,#baaa7edc),url('/assets/storybook/ui/vellum.webp');box-shadow:inset 0 0 8px #463e2566;}
#dungeonCompass .compass-paper canvas{border:1px solid #59633f;border-radius:2px;width:100%;height:auto;}
#dungeonCompass .compass-north{position:absolute;right:10px;top:8px;text-align:center;color:#d9ca96;font:10px/1.15 Georgia;}
#dungeonCompass>.compass-legend{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin:10px 0 0;font:9px/1.2 system-ui;letter-spacing:0;}
#dungeonCompass .compass-legend>span{display:flex;gap:5px;align-items:center;color:#d0d5bb;font:9px/1.2 system-ui;}.compass-legend .ui-icon{width:12px;height:12px;color:#e1c992;}.map-you{width:7px;height:7px;border-radius:50%;background:#fff0b9;border:1px solid #39583c;}
.compass-objective{font:10px/1.5 Georgia;color:#dfc994;margin:10px 0 0;border-top:1px solid #a8955f50;padding-top:8px;}
@media(max-width:1100px) and (min-width:651px){#bossEncounter{top:252px;width:390px;}#bossEncounter[data-world=true]{width:410px;}#game .dungeon-compass{width:205px;}}
@media(max-width:650px){
 #bossEncounter,#bossEncounter[data-world=true]{left:12px;right:72px;top:237px;width:auto;translate:none;gap:9px;padding:10px 12px;border-radius:12px;}
 #bossEncounter h2{font-size:20px;margin-bottom:6px;}.boss-kind{font-size:7px;letter-spacing:.08em;}.boss-seal,#bossEncounter[data-world=true] .boss-seal{width:32px;height:42px;}.boss-seal .ui-icon{width:23px;height:23px;}.boss-numbers{font-size:9px;}
 .game-shell.in-dungeon.has-visible-boss .scene-camera{top:345px;}
 .game-shell.in-dungeon.has-visible-boss #combatTarget{top:395px;}
 #game .dungeon-compass{width:205px;max-width:calc(100vw - 24px);padding:11px;}
 .in-dungeon.mobile-map-open #bossEncounter,.in-dungeon:has(#dungeonPanel details[open]) #bossEncounter{display:none;}
}
/* Reflow the existing five shortcuts into a compact header while a menu is open. */
@media(max-width:650px), (max-height:500px) and (max-width:950px){
 body.game-active #game:has(.drawer:not([hidden])) .side-tools{position:fixed;left:8px;right:8px;top:66px;bottom:auto;transform:none;translate:none;display:flex;flex-direction:row;justify-content:center;gap:5px;z-index:115;padding:4px;border:1px solid #9b98625c;border-radius:10px;background:#152f26fa;}
 body.game-active #game:has(.drawer:not([hidden])) .side-tools button{width:auto;min-width:44px;flex:1;min-height:47px;height:47px;padding:3px 2px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:2px;}
 body.game-active #game:has(.drawer:not([hidden])) .side-tools button svg{width:21px;height:21px;}
 body.game-active #game:has(.drawer:not([hidden])) .side-tools button small{font-size:9px;line-height:1.2;}
 body.game-active #game .drawer:is(#adventureDrawer,#equipmentDrawer,#inventoryDrawer,#npcWorkshop,#accountDrawer,#questionsDrawer){inset:128px 8px 8px;width:auto;max-width:none;max-height:none;padding:16px 14px;border-radius:12px;transform:none;}
 body.game-active #game .drawer>.drawer-close{position:sticky;float:right;top:0;right:0;z-index:15;width:40px;height:40px;min-height:40px;margin:-4px -2px 4px 8px;border:1px solid #a49a6977;border-radius:8px;background:#19382e;color:#efdbac;}
 body.game-active #game .drawer>h2{margin:4px 0 15px;font-size:25px;}
 #comfortCharacter .comfort-character-layout{grid-template-columns:minmax(0,1fr) minmax(95px,1.15fr) minmax(0,1fr);grid-template-rows:repeat(4,minmax(65px,auto));gap:5px;padding:8px;}
 #comfortCharacter .equipment-stage{height:156px;align-self:center;}#comfortCharacter .comfort-portrait .character-sprite{top:18px;transform:translateX(-50%) scale(1.2);}
 body.game-active #game #comfortCharacter .equipment-slot{padding:5px 4px;gap:3px;}.equipment-art{height:28px;}#comfortCharacter .equipment-art img{width:32px;height:32px;}.equipment-silhouette{width:25px;height:25px;}
 #comfortCharacter .equipment-slot .equipment-label{font-size:10px;letter-spacing:0;}#comfortCharacter .equipment-slot strong{font-size:9px;}
 #comfortCharacter .equipment-identity{padding:8px 0 0;}#comfortCharacter .equipment-identity h3{font-size:17px;margin:0 0 4px;}#comfortCharacter .equipment-identity p{font-size:10px;}
 #comfortCharacter .comfort-stats{margin:12px 0;}.comfort-toolbar{grid-template-columns:minmax(0,1fr) 116px;gap:9px;}
 #comfortFilters{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;margin:12px 0;}
 body.game-active #game #comfortFilters button{font-size:11px;padding:8px 4px;min-width:0;}
 #inventory.comfort-grid{grid-template-columns:repeat(3,minmax(0,1fr));padding:7px;gap:6px;}body.game-active #game #inventory .comfort-slot{min-height:105px;padding:8px 4px;}
 .adventure-tabs{clear:both;}.journal-tabs{clear:both;}
 #npcPremium:not([hidden]){grid-template-columns:1fr;}#cosmeticFitting{position:relative;}
 #game:has(.drawer:not([hidden])) :is(.scene-interact,.scene-camera,#dungeonMapToggle){visibility:hidden;}
}
@media(max-width:360px){body.game-active #game .drawer:is(#adventureDrawer,#equipmentDrawer,#inventoryDrawer,#npcWorkshop,#accountDrawer,#questionsDrawer){padding:14px 10px;}#comfortCharacter .comfort-character-layout{grid-template-columns:minmax(0,1fr) 88px minmax(0,1fr);padding:6px;gap:4px;}.comfort-toolbar{grid-template-columns:1fr 100px;}#comfortFilters{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-height:500px) and (max-width:950px){
 body.game-active #game:has(.drawer:not([hidden])) .side-tools{top:8px;left:auto;width:300px;}
 body.game-active #game .drawer:is(#adventureDrawer,#equipmentDrawer,#inventoryDrawer,#npcWorkshop,#accountDrawer,#questionsDrawer){top:66px;}
 .in-dungeon .scene-place{display:none;}
 #bossEncounter,#bossEncounter[data-world=true]{top:84px;left:26px;right:auto;translate:none;width:300px;padding:8px 12px;}.boss-seal{display:none;}#bossEncounter h2{font-size:18px;}
 .game-shell.in-dungeon #dungeonPanel{top:12px;padding:9px 12px;max-height:calc(100dvh - 105px);}
 .in-dungeon #dungeonPanel .dungeon-heading h3{font-size:15px;margin:3px 0;}.in-dungeon #dungeonPanel .dungeon-heading p{font-size:10px;}
 .in-dungeon #dungeonPanel summary{font-size:11px;min-height:35px;}
 .in-dungeon #dungeonMapToggle{display:grid;place-items:center;position:fixed;left:344px;right:auto;top:84px;width:48px;height:54px;padding:5px;border:1px solid #b4a27388;border-radius:9px;background:#172f26f0;color:#e7d39f;z-index:29;font-size:9px;}
 #dungeonMapToggle svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.5;}
 #game.in-dungeon .dungeon-compass{display:none;position:fixed;left:344px;right:auto;top:146px;width:176px;max-height:calc(100dvh - 158px);overflow:auto;z-index:28;}
 #game.in-dungeon.mobile-map-open .dungeon-compass{display:block;}.compass-objective,.compass-floor{display:none;}
}
@media(prefers-reduced-motion:reduce){.boss-health>i{transition:none;}}
body.comfort-reduced-motion .boss-health>i{transition:none;}

/* interior-services.css */
/* Interior scale is independent of the camera: feet remain on the server position. */
.interior-furniture{position:absolute;pointer-events:none;image-rendering:auto;}
.storybook-preview #map.painted-world[class*="zone-inside-"] .character-renderer{scale:1.6147;transform-origin:50% 100%;}
#map.painted-world[class*="zone-inside-"] .npc-character .npc-sprite{scale:1.885;}
#map.painted-world[class*="zone-inside-"] .npc-character{height:143px;min-height:143px;}
#map.painted-world[class*="zone-inside-"] .pawn::after{left:2px;width:64px;height:19px;}
#map.painted-world[class*="zone-inside-"] .npc-character::before{left:3px;width:65px;height:18px;}
#game #npcWorkshop:is([data-service=merchant],[data-service=archivist]){width:750px;max-width:calc(100vw - 140px);}
#npcWorkshop:is([data-service=merchant],[data-service=archivist])>.eyebrow{margin-bottom:8px;}
#npcWorkshop:is([data-service=merchant],[data-service=archivist])>h2{font-size:27px;margin:0 0 16px;}
#npcWorkshop:is([data-service=merchant],[data-service=archivist]) #npcServiceStatus{font-size:11px;margin:10px 0 15px;}
#npcWorkshop:is([data-service=merchant],[data-service=archivist]) .service-banner{min-height:100px;margin-bottom:0;padding:10px 20px;}
#npcWorkshop:is([data-service=merchant],[data-service=archivist]) .service-portrait{height:84px;width:76px;flex:none;}
#npcWorkshop:is([data-service=merchant],[data-service=archivist]) .service-portrait .storybook-npc{width:78px;height:81px;left:-3px;bottom:0;transform:none;}
.market-gold{display:flex;align-items:center;justify-content:flex-end;gap:7px;font:14px Georgia;color:#eed9a2;}
.market-gold .ui-icon{width:20px;height:20px;}
.market-modes{display:flex;gap:10px;border-bottom:1px solid #b49a6255;margin:12px 0 20px;}
#game .market-modes button{flex:1;display:flex;align-items:center;justify-content:center;gap:12px;min-height:50px;border-radius:10px 10px 0 0;background:#1b382d;border:1px solid #87946580;border-bottom:0;color:#d5d9b9;font:18px Georgia;}
#game .market-modes button[aria-selected=true]{background:linear-gradient(#787440,#474f2e);border-color:#ddc785;color:#fff0be;box-shadow:inset 0 2px 0 #f0d698;}
.market-modes .ui-icon,.market-return .ui-icon{width:26px;height:26px;}
#npcMarket .market-mode-panel>h3{font:22px Georgia;margin:0 0 13px;color:#eee0b9;}.market-help{font-size:11px;color:#bfcfb9;}
#npcMarket .comfort-market-card{display:grid;grid-template-columns:minmax(0,1fr) 175px;gap:6px 16px;padding:13px 15px;margin:9px 0;}
#npcMarket .market-product{grid-column:1;gap:11px;align-items:center;}
#npcMarket .market-art{width:54px;height:54px;flex:none;}#npcMarket .market-art img{width:54px;height:54px;}
#npcMarket .market-product h4{font-size:17px;line-height:1.25;margin:0;}#npcMarket .market-product p{display:none;}
#npcMarket .market-price{grid-column:1;margin:0;display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:11px;}
#npcMarket .market-price strong{font-size:15px;}.market-price small{font-size:10px;}
#npcMarket .market-purchase{grid-column:2;grid-row:1/3;display:grid;grid-template-columns:1fr 66px;gap:6px 8px;align-content:center;border-left:1px solid #a59a6055;padding-left:14px;}
#npcMarket .market-purchase label{display:contents;font-size:10px;}
#npcMarket .market-purchase input{width:66px;padding:6px 7px;min-height:34px;}
#npcMarket .market-purchase strong,#npcMarket .market-purchase button{grid-column:1/-1;font-size:12px;}
#npcMarket .market-purchase button{min-height:37px;padding:7px;}
#npcMarket [data-market-reason]{grid-column:1/-1;margin:3px 0 0;font-size:10px;}
#game .market-return{display:flex;align-items:center;gap:10px;margin:20px 0 0;font-size:14px;}
.selene-home>h3{font:24px Georgia;color:#f0deae;margin:18px 0;}
.selene-choices{display:grid;grid-template-columns:1fr 1fr;gap:16px;}
#game .selene-choices>button{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:13px;min-height:270px;padding:24px 18px;border:1px solid #bca46e;border-radius:12px;background:radial-gradient(ellipse at top,#385346,#172f28);color:#f0dfb4;text-align:center;}
.selene-choices>button>.ui-icon{width:65px;height:65px;color:#d6bd80;}
.selene-choices strong{font:22px/1.2 Georgia;}.selene-choices span{font:13px/1.6 system-ui;color:#c9d7bf;max-width:220px;}
.selene-choices b{font:15px Georgia;display:block;width:100%;padding:12px;border:1px solid #c7b270;border-radius:8px;background:linear-gradient(#667144,#32432d);margin-top:auto;}
.selene-choices>button:hover,.selene-choices>button:focus-visible{box-shadow:inset 0 0 0 2px #d9c892;outline:2px solid #e6cf91;outline-offset:3px;}
.selene-links{display:flex;flex-wrap:wrap;gap:6px;justify-content:space-between;padding-top:17px;border-top:1px solid #baac6b55;margin-top:22px;}
#game .selene-links button{background:transparent;border:0;display:flex;align-items:center;gap:7px;padding:9px 3px;font-size:11px;color:#d6d9bc;}
.selene-links .ui-icon{width:19px;height:19px;}
#game .selene-return{font-size:12px;padding:8px 12px;margin:4px 0 15px;background:#233d30;}
.selene-page>h3{font:24px Georgia;color:#f0dfb7;margin:10px 0 17px;}
.selene-writing-help{font-size:12px;color:#c2d0b7;padding:10px;border:1px solid #af9f6455;border-radius:8px;margin:12px 0;}.selene-writing-help summary{cursor:pointer;}
.creation-progress{padding:11px 14px;border:1px solid #c1ab6e77;border-radius:9px;background:#314731;color:#efdaad;font:15px Georgia;}
.creation-step{padding:19px;border:1px solid #a9956355;border-radius:10px;background:linear-gradient(120deg,#dfd0a2f2,#efe1b9f5),url('/assets/storybook/ui/vellum.webp');color:#34482d;}
#game #npcSelene .creation-step label{display:grid;gap:7px;margin:0 0 16px;font:13px/1.5 system-ui;color:#3d4c30;}
#game #npcSelene .creation-step label.check-line{display:flex;align-items:flex-start;gap:10px;margin:16px 0;}
#game #npcSelene .creation-step input:not([type=checkbox]),#game #npcSelene .creation-step textarea,#game #npcSelene .creation-step select{width:100%;box-sizing:border-box;min-height:43px;padding:10px 12px;border:1px solid #9d8d5d;border-radius:7px;background:#fff4d6;color:#253e2b;font:14px/1.5 system-ui;}
#game #npcSelene .creation-step textarea{min-height:85px;resize:vertical;}
#game #npcSelene .creation-step fieldset{margin:0;padding:13px;border:1px solid #ae9c69;border-radius:8px;}
.creation-step legend{padding:0 7px;font:15px Georgia;color:#405335;}
.creation-step fieldset>input{margin:5px 0;}.creation-step p{font-size:12px;line-height:1.6;}
.creation-step #questionPreview,.shadow-review{padding:17px;border:1px solid #a79359;border-radius:8px;background:#f7e9c5;color:#31462d;box-shadow:0 2px 5px #74623625;}
.creation-step #questionPreview strong,.shadow-review h4{font:20px Georgia;color:#30472e;}.creation-step li{line-height:1.6;margin:8px 0;}
#game #npcSelene .creation-step button[type=submit]{width:100%;margin-top:15px;min-height:46px;background:linear-gradient(#56623a,#29402d);color:#ffefc0;border-color:#756637;}
.creation-controls{display:flex;justify-content:space-between;gap:12px;margin:15px 0;}.creation-controls button{min-height:43px;}.creation-controls [data-creation-next]{margin-left:auto;}
.selene-proposal-list h4{font:20px Georgia;color:#efddb3;margin:22px 0 10px;}.selene-list-empty{padding:18px;border:1px dashed #b6a26c;color:#cbd5b9;border-radius:9px;font-size:13px;line-height:1.6;}
#npcSelene [hidden],#npcMarket [hidden]{display:none!important;}
@media(max-width:650px),(max-height:500px) and (max-width:950px){
 #game #npcWorkshop:is([data-service=merchant],[data-service=archivist]){width:auto;max-width:none;}
 #npcWorkshop:is([data-service=merchant],[data-service=archivist])>h2{font-size:23px;}
 #npcWorkshop:is([data-service=merchant],[data-service=archivist]) .service-banner{padding:8px 12px;min-height:90px;}
 .selene-choices{gap:10px;}#game .selene-choices>button{padding:17px 9px;min-height:250px;gap:10px;}.selene-choices strong{font-size:19px;}.selene-choices span{font-size:11px;}.selene-choices b{font-size:12px;padding:11px 5px;}.selene-choices>button>.ui-icon{width:45px;height:45px;}
 #npcMarket .comfort-market-card{grid-template-columns:minmax(0,1fr) 115px;padding:11px 10px;gap:7px 8px;}#npcMarket .market-product{gap:8px;}#npcMarket .market-product h4{font-size:14px;}#npcMarket .market-art,#npcMarket .market-art img{width:38px;height:38px;}#npcMarket .market-price{display:grid;gap:4px;}#npcMarket .market-purchase{padding-left:8px;grid-template-columns:1fr 47px;}#npcMarket .market-purchase input{width:47px;}
 .creation-step{padding:13px;}.selene-links{gap:3px;}#game .selene-links button{font-size:10px;}.creation-step fieldset{padding:9px!important;}
}
@media(max-width:350px){.selene-choices{grid-template-columns:1fr;}#game .selene-choices>button{min-height:200px;}.selene-links{justify-content:flex-start;gap:8px;}}

/* mystery-dialog.css */
#mysteryDialog{width:min(920px,calc(100vw - 24px));max-height:calc(100dvh - 24px);padding:0;overflow:auto;background:#142e26 url('/assets/storybook/ui/forest-leather.webp') center/cover;scrollbar-width:thin;}
#mysteryDialog .mystery-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:20px 26px;border-bottom:1px solid #c5ac6d66;background:#10261eef;}
#mysteryDialog .eyebrow{margin:0 0 6px;font-size:10px;letter-spacing:2px;color:#c8b985;}
#mysteryDialog h2{margin:0;font:28px/1.15 Georgia,serif;}
#mysteryDialog #mysteryClose{flex:none;width:44px;padding:0;}
.mystery-content{display:grid;grid-template-columns:230px minmax(0,1fr);gap:22px;padding:22px;}
.mystery-identity{text-align:center;padding:12px;background:#10281bd9;border:1px solid #c8b77d55;border-radius:10px;}
#mysteryPortrait{height:175px;position:relative;background:radial-gradient(ellipse,#78956355,transparent 70%);}
#mysteryPortrait .character-sprite{position:absolute;left:50%;bottom:10px;transform:translateX(-50%) scale(1.8);transform-origin:50% 100%;}
#mysteryDialog .mystery-secret{font:italic 16px/1.5 Georgia,serif;color:#d8cd9d;}
.mystery-progress{display:flex;gap:6px;justify-content:center;}
.mystery-progress span{display:grid;place-items:center;width:29px;height:31px;border:1px solid #b5ab7766;border-radius:50% 50% 9px 9px;color:#b7bfaa;background:#11271f;}
.mystery-progress .earned{background:#d6bd7a;color:#203a29;border-color:#f0dda1;}
#mysteryDialog #mysteryProgressLabel{font-size:12px;color:#c2cdb7;margin:9px 0 17px;}
#mysteryDialog #mysteryBalance{font-size:13px;border-top:1px solid #b4ae7344;padding-top:14px;color:#ead69a;}
.mystery-investigation{min-width:0;}
.mystery-tabs{display:flex;gap:7px;margin-bottom:16px;}
#mysteryDialog .mystery-tabs button{flex:1;padding:9px 7px;font-size:13px;}
#mysteryDialog .mystery-tabs [aria-selected=true]{background:#d1b777;color:#142e22;border-color:#f0daa1;}
#mysteryDialog section,#mysteryDialog #mysteryGuessForm{margin:0;}
#mysteryDialog [hidden]{display:none!important;}
.mystery-game-board{min-height:230px;padding:25px 20px;border:1px solid #c4ac74;border-radius:12px;text-align:center;background:linear-gradient(#0b261e55,#0d261bbb),url('/assets/storybook/ui/board-rps.webp') center/cover;}
.mystery-game-board[data-game=runes]{background-image:linear-gradient(#0b261e55,#0d261be8),url('/assets/storybook/ui/board-runes.webp');}
.mystery-game-board[data-game=fireflies]{background-image:linear-gradient(#0b261e55,#0d261be8),url('/assets/storybook/ui/board-fireflies.webp');}
.mystery-game-picker{display:flex;gap:7px;margin-bottom:12px;}
#mysteryDialog .mystery-game-picker button{flex:1;min-width:0;display:flex;justify-content:center;align-items:center;gap:6px;padding:8px 5px;font-size:11px;background:#123329;border-color:#9a9b6966;}
#mysteryDialog .mystery-game-picker [aria-pressed=true]{color:#ffecb0;border-color:#e5c77a;box-shadow:inset 0 0 18px #b2ac5f22;}
.mystery-game-picker .ui-icon{width:25px;height:25px;margin:0;}
.mystery-game-actions{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin-top:15px;}
#mysteryDialog .mystery-game-actions button{font-size:12px;}
#mysteryDuelStage{padding:12px 0 2px;}
#mysteryDialog #mysteryResultTitle{font:28px/1.2 Georgia,serif;margin:3px 0 18px;outline-offset:5px;}
.mystery-result-win{color:#f7df96;}.mystery-result-draw{color:#dddcc1;}.mystery-result-loss{color:#f1b5a0;}
.mystery-contestants{display:grid;grid-template-columns:minmax(0,1fr) 20px minmax(0,1fr);gap:8px;align-items:center;}
.mystery-contestants>div{display:grid;gap:10px;min-width:0;font-size:12px;color:#dcdcc5;}
.mystery-hidden-choice,.mystery-revealed-choice{display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:8px;min-height:90px;padding:12px 6px;background:#0b201dd9;border:1px solid #b8aa6b88;border-radius:12px;box-shadow:inset 0 0 20px #a5b87316;}
.mystery-hidden-choice{font:42px Georgia,serif;color:#e9d59b;}
.mystery-versus{font:italic 22px Georgia,serif;color:#c7b879;}
.mystery-symbol{display:inline-flex;flex-direction:column;align-items:center;gap:7px;font-size:12px;}
.mystery-symbol .ui-icon{width:42px;height:42px;margin:0;}
.mystery-result-explanation{font-size:13px;line-height:1.5;}.mystery-result-reward{font-size:12px;color:#e9d799;line-height:1.5;}
#mysteryEnergy,.mystery-stage-caption,#mysteryChoicePrompt{font-size:13px;color:#f0dea1;line-height:1.5;}
.mystery-memory-light{min-height:92px;display:grid;place-items:center;}.mystery-memory-light .ui-icon{width:55px;height:55px;}
.mystery-sequence-step{font-size:12px;color:#cbd0b5;}
#mysteryMemoryAnswer{display:flex;flex-wrap:wrap;justify-content:center;gap:7px;margin-top:15px;min-height:50px;}
#mysteryMemoryAnswer .ui-icon{width:27px;height:27px;}
.mystery-empty-symbol{display:grid;place-items:center;width:32px;height:45px;border:1px dashed #b9b78a88;border-radius:5px;color:#d0c896;}
.mystery-game-board[data-phase=animating] .mystery-hidden-choice{animation:mystery-duel-choice .46s ease-in-out infinite alternate;}
.mystery-game-board[data-phase=animating] .mystery-contestants>div:last-child .mystery-hidden-choice{animation-delay:-.23s;}
.mystery-game-board[data-phase=result] .mystery-revealed-choice{animation:mystery-choice-reveal .3s ease-out both;}
@keyframes mystery-duel-choice{from{transform:translateY(3px) rotate(-5deg);border-color:#b8aa6b88;}to{transform:translateY(-5px) rotate(5deg);border-color:#f5d28b;box-shadow:0 0 18px #d6c68033;}}
@keyframes mystery-choice-reveal{from{transform:scale(.94);opacity:.3;}to{transform:scale(1);opacity:1;}}
@media(prefers-reduced-motion:reduce){.mystery-game-board[data-phase] .mystery-hidden-choice,.mystery-game-board[data-phase] .mystery-revealed-choice{animation:none;}}
.mystery-game-board[data-phase=result]{padding:16px;}
.mystery-game-board[data-phase=result] .mystery-free,.mystery-game-board[data-phase=result] #mysteryGameRule{display:none;}
#mysteryDialog .mystery-game-board[data-phase=result] h3{font-size:18px;margin:0 0 6px;}
#mysteryDialog .mystery-game-board[data-phase=result] #mysteryResultTitle{font-size:26px;margin:0 0 12px;}
.mystery-game-board[data-phase=result] .mystery-result-explanation,.mystery-game-board[data-phase=result] .mystery-result-reward{margin:10px 0;}
@media(min-width:651px){
 #mysteryDialog .mystery-heading{padding:12px 24px;}.mystery-content{padding:18px;gap:18px;}.mystery-tabs{margin-bottom:10px;}
}
.mystery-free{font-size:10px;letter-spacing:2px;color:#eee0a5;}
#mysteryDialog h3{font:22px/1.2 Georgia,serif;margin:16px 0 10px;}
#mysteryDialog .mystery-rule{font-size:12px;color:#bdcbb8;line-height:1.6;}
#mysteryMoves{display:flex;justify-content:center;gap:8px;margin-top:20px;}
#mysteryDialog #mysteryMoves button{display:flex;flex-direction:column;align-items:center;gap:8px;flex:1;min-width:0;padding:14px 5px;font-size:12px;}
#mysteryMoves .ui-icon{width:32px;height:32px;margin:0;}
.mystery-game-board[data-game=fireflies] #mysteryMoves{flex-wrap:wrap;gap:5px;}
#mysteryDialog .mystery-game-board[data-game=fireflies] #mysteryMoves button{flex:1 1 50px;padding:10px 3px;}
#mysteryDialog .mystery-game-board[data-game=fireflies] .mystery-symbol{font-size:10px;}
.mystery-game-board[data-game=fireflies] .mystery-revealed-choice .ui-icon{width:26px;height:26px;}
#mysteryDialog .mystery-clue-box,#mysteryGuessForm{padding:18px 20px;border-radius:10px;background:#eddfbc url('/assets/storybook/ui/vellum.webp') center/cover;color:#3c412d;border:1px solid #cfb478;}
#mysteryDialog .mystery-clue-box h3,#mysteryGuessForm h3{color:#38432f;}
#mysteryClues{padding-left:24px;margin-bottom:0;}#mysteryClues li{padding:8px 0;border-bottom:1px solid #7d784f44;}
#mysteryGuessForm p,#mysteryGuessForm label{font-size:13px;line-height:1.5;}
#mysteryGuessForm label{display:block;margin-bottom:7px;font-weight:600;}
#mysteryQuery{width:100%;}
#mysteryDialog #mysterySearchStatus{font-size:12px;}
#mysteryDialog #mysteryGuess{width:100%;font-size:13px;}
#mysterySuggestions{display:grid;gap:6px;max-height:155px;overflow:auto;}
.mystery-footer{padding:12px 24px;border-top:1px solid #c5ac6d66;background:#10261ef5;}
#mysteryDialog #mysteryStatus{padding:0;margin:0;min-height:24px;border:0;background:none;font-size:13px;line-height:1.5;}
@media(max-width:650px){
 #mysteryDialog .mystery-heading{padding:15px;}#mysteryDialog h2{font-size:23px;}
 .mystery-content{grid-template-columns:1fr;padding:12px;gap:12px;}
 .mystery-identity{display:grid;grid-template-columns:75px 1fr;gap:2px 10px;padding:8px;align-items:center;}
 #mysteryPortrait{grid-row:1/4;height:100px;}#mysteryPortrait .character-sprite{transform:translateX(-50%);bottom:0;}
 #mysteryDialog .mystery-secret{display:none;}#mysteryDialog #mysteryProgressLabel{margin:4px 0;font-size:11px;}
 #mysteryDialog #mysteryBalance{border:0;padding:0;margin:3px 0;font-size:12px;}
 .mystery-game-board{padding:18px 12px;min-height:220px;}.mystery-footer{padding:10px 15px;}
 #mysteryDialog .mystery-tabs button{font-size:12px;}.mystery-progress span{width:25px;height:27px;}
}

/* forest-paths.css */
#map:is(.zone-forest,.zone-deep-forest,.zone-cave) .portal.stone-portal{width:180px;height:180px;}
#map:is(.zone-forest,.zone-deep-forest) .dungeon-gate[data-entrance=normal]{width:216px;height:216px;}
#map:is(.zone-forest,.zone-deep-forest) .dungeon-gate[data-entrance=world]{width:286px;height:286px;}
.forest-ambience{position:absolute;inset:0;z-index:2;pointer-events:none;}
.forest-ambience i{position:absolute;width:5px;height:5px;border-radius:50%;background:#ecdf8d;box-shadow:0 0 12px #d2e394;opacity:.5;animation:forest-drift 9s ease-in-out infinite;}
.zone-deep-forest .forest-ambience i{background:#a9dec7;box-shadow:0 0 14px #79c6c9;}
@keyframes forest-drift{0%,100%{translate:0 0;opacity:.2;}50%{translate:16px -22px;opacity:.65;}}
.comfort-reduced-motion .forest-ambience,.comfort-no-particles .forest-ambience{display:none;}
@media(prefers-reduced-motion:reduce){.forest-ambience{display:none;}}

.zone-deep-forest .painted-foreground{filter:brightness(.84) saturate(.82);}

/* channel-status.css */
/* A compact, non-interactive status: never covers the movement/camera controls. */
#game .channel-activity-badge {
  display: inline-flex; align-items: center; flex: 0 1 auto; gap: .45rem;
  padding: .4rem .7rem; border: 1px solid #a8bb8b70; border-radius: 999px;
  background: #18291fed; color: #ebefd6; font: 600 .75rem/1.35 system-ui, sans-serif;
  letter-spacing: .015em; max-width: 100%; overflow-wrap: anywhere;
}
#game .channel-activity-badge::before { content: '◈'; color: #d7c486; }
#game .channel-activity-card {
  margin: .75rem 0 1rem; padding: 1rem; border: 1px solid #a2ad7b80; border-radius: .8rem;
  background: linear-gradient(125deg, #253a2df5, #15261ff5); color: #f2eddb;
  box-shadow: inset 3px 0 #b8b784; overflow-wrap: anywhere;
}
#game .channel-activity-card h3 { margin: 0 0 .65rem; color: #eadab0; font-size: 1.05rem; }
#game .channel-activity-card p { margin: .4rem 0; color: inherit; font-size: .88rem; line-height: 1.5; }
#game .channel-activity-card .channel-activity-timer { font-weight: 700; color: #f6dfac; }
#game .channel-activity-card .channel-activity-note { color: #d3dbca; font-size: .8rem; }
#game .channel-activity-urgent { border-color: #d79c78; box-shadow: inset 3px 0 #d79c78; }
#game .channel-activity-urgent .channel-activity-timer { color: #ffbb9b; }
#game .channel-activity-badge[hidden], #game .channel-activity-card[hidden] { display: none !important; }
@media (max-width: 640px) {
  #game .scene-topbar { display: grid; grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 36px 20px; gap: 0 8px; align-content: center; }
  #game .scene-brand { grid-column: 1; grid-row: 1; }
  #game .scene-status { display: none; }
  #game #sceneLight { grid-column: 2; grid-row: 1 / span 2; justify-self: end; }
  #game .channel-activity-badge { grid-column: 1; grid-row: 2; justify-self: start;
    align-self: start; border: 0; background: transparent; }
  #game .channel-activity-badge { font-size: .66rem; padding: .25rem .5rem; margin: 0; }
  #game .channel-activity-card { padding: .8rem; }
}

/* lake-workshops.css */
.lake-stations{display:contents}.lake-hotspot{position:absolute;translate:-50% -50%;z-index:2400;border:0;background:transparent;box-shadow:none;cursor:pointer;padding:0;min-height:44px;min-width:44px;border-radius:16px}
.lake-hotspot:hover,.lake-hotspot:focus-visible,.lake-hotspot.selected{outline:2px solid #eed29188;background:#eed2910b}
.lake-hotspot span,.painted-door span{position:absolute;left:50%;top:0;bottom:auto;translate:-50% -110%;white-space:nowrap;padding:7px 11px;border:1px solid #cbbb85;border-radius:7px;background:#19382def;color:#fff1cc;font:13px Georgia;opacity:0;pointer-events:none;transition:opacity .12s}
.lake-hotspot:hover span,.lake-hotspot:focus-visible span,.lake-hotspot.selected span,.painted-door:hover span,.painted-door:focus-visible span,.painted-door.selected span{opacity:1}
.painted-door{z-index:2400!important;border-radius:8px;min-width:44px;min-height:44px}.painted-door:after{display:none}.painted-door:hover,.painted-door:focus-visible,.painted-door.selected{outline:2px solid #f1d296;background:#fff3bd14!important}.painted-door.opening{box-shadow:inset 0 0 28px #ffe7a995!important}
.lake-workshop-dialog{width:min(580px,94vw)}.lake-workshop-dialog [data-recipes]{padding:0 22px 18px;display:grid;gap:12px}.lake-workshop-dialog article,.lake-workshop-dialog section{border:1px solid #b8a16b66;border-radius:9px;padding:12px}.lake-workshop-dialog button{min-height:44px}.lake-workshop-dialog [data-message]{padding:0 22px}
.lake-work-progress{position:absolute;z-index:85;left:50%;bottom:68px;translate:-50% 0;width:min(330px,90vw);padding:15px;background:#19372df5;border:1px solid #cbb77a;border-radius:12px;color:#f4e9c7}.lake-work-progress strong{font:20px Georgia}.lake-work-progress p{margin:8px 0}.lake-work-progress progress{width:100%;accent-color:#d3b775}.lake-work-progress button{margin-top:10px;min-height:44px}.lake-work-progress[hidden]{display:none}
.fishing-setup [data-fishing-body]{padding:0 22px 22px}.fishing-setup button{min-height:44px;margin:6px}
@media(prefers-reduced-motion:reduce){.lake-hotspot span,.painted-door span{transition:none}}

#map .azuronde-boat-marker{width:140px;height:90px;min-width:0;min-height:0;padding:0;border:0;background:none;box-shadow:none;z-index:2350;transform:translate(-135%,-72%)}
.azuronde-boat-marker img{display:block;width:100%;height:100%;filter:drop-shadow(0 3px 2px #123d3855)}
.azuronde-boat-marker small{position:absolute;bottom:95%;left:50%;translate:-50% 0;padding:6px 8px;white-space:nowrap;background:#173a35ec;border-radius:7px;opacity:0}
.azuronde-boat-marker:hover small,.azuronde-boat-marker:focus-visible small{opacity:1}#map .azuronde-boat-marker:hover,#map .azuronde-boat-marker:focus-visible{outline:0;background:none;filter:drop-shadow(0 0 3px #ffe0a0)}
#map .pawn[data-lake-activity=sailing]{transform:translate(calc(-50% + var(--sail-x,0px)),calc(-100% + var(--sail-y,0px)))!important;z-index:2300!important}
#map .pawn[data-lake-activity=sailing] .lake-riding-boat{position:absolute;left:50%;translate:-50% 0;bottom:-36px;width:176px;height:98px;max-width:none;pointer-events:none;z-index:0}
#map .pawn[data-lake-activity=sailing] .character-renderer{z-index:1}
#map .pawn[data-lake-activity=sailing]::after{display:none}

/* gathering.css */
#map .regional-resource.gathering-tree{width:70px;height:85px;background:transparent;border:0;box-shadow:none;translate:-50% -75%;transform:none;border-radius:40%;z-index:2200}
#map .regional-resource.gathering-tree:hover,#map .regional-resource.gathering-tree:focus-visible{outline:2px solid #ddc37baa;background:#efd59b0d}
#map .regional-resource.gathering-tree .resource-label{opacity:0;position:absolute;bottom:100%;left:50%;translate:-50% 0;white-space:nowrap}
#map .regional-resource.gathering-tree:hover .resource-label,#map .regional-resource.gathering-tree:focus-visible .resource-label{opacity:1}
.painted-foreground.tree-being-cut{transform-origin:50% 100%;animation:tree-cut-reaction 1s var(--gather-delay,0ms) 1}
@keyframes tree-cut-reaction{0%,50%,78%,100%{transform:rotate(0)}56%{transform:rotate(.75deg)}63%{transform:rotate(-.45deg)}}
#resourceAction{width:min(320px,calc(100vw - 32px));background:#19372deb;border-color:#bba57099;padding:13px 16px}
#resourceAction .gathering-cue{display:flex;align-items:center;gap:10px;min-height:30px;color:#e5d7b4;font-size:13px}
#resourceAction .gathering-cue i{width:7px;height:7px;flex:0 0 7px;border-radius:50%;background:#c4ae70;box-shadow:0 0 0 4px #c4ae7015}
#resourceAction.bite .gathering-cue i{background:#fff3aa;box-shadow:0 0 0 6px #fff3aa33}
#resourceAction [data-action-status]{margin:6px 0 10px;line-height:1.4}
#resourceAction button{min-height:44px}
#map .regional-resource.mining-active::after{content:attr(data-mining-hits);position:absolute;left:50%;bottom:0;translate:-50% 0;padding:3px 8px;border:1px solid #cfb279;border-radius:12px;background:#19372df2;color:#ffe6ac;font:bold 13px system-ui;pointer-events:none}
#resourceAction.mining .gathering-cue i{background:#ead09a}
@media(prefers-reduced-motion:reduce){.painted-foreground.tree-being-cut{animation:none}}
.comfort-reduced-motion .painted-foreground.tree-being-cut{animation:none}

#map .regional-resource.fishing-active .resource-label{opacity:0}

/* aurivale-farm.css */
.farm-layer{position:absolute;inset:0;pointer-events:none;z-index:8}.farm-layer button{position:absolute;transform:translate(-50%,-50%);pointer-events:auto;cursor:pointer;border:1px solid transparent;background:transparent;padding:0;color:#f9d588}.farm-object:hover,.farm-object:focus-visible{border-color:#efd395;border-radius:35%;background:#ffd17014}.farm-plot{border-radius:45%;font-size:clamp(12px,1.6vw,25px);text-shadow:0 2px 4px #382608}.farm-plot[data-stage=seed]{font-size:12px;opacity:.75}.farm-plot[data-stage=growing]{filter:saturate(.65);opacity:.85}.farm-plot[data-stage=ready]{filter:drop-shadow(0 0 4px #edce73)}.farm-plot:hover,.farm-plot:focus-visible{border-color:#efd395;background:#ffd17018}.farm-dialog button{margin:5px}.farm-dialog article{border-top:1px solid #ad875733;padding:10px 0}.regional-resource.fruit-tree{translate:none!important;background:none!important;border:0!important;box-shadow:none!important;transform:translate(-50%,-50%);clip-path:polygon(29% 4%,60% 0,86% 16%,100% 46%,92% 72%,74% 95%,42% 100%,14% 84%,0 54%,9% 23%);border-radius:0;min-width:0;min-height:0}.regional-resource.fruit-tree:hover,.regional-resource.fruit-tree:focus-visible{background:#ffe68e24!important;filter:drop-shadow(0 0 3px #ffdf8c)}.regional-resource.fruit-tree .resource-label{display:none}.regional-resource.fruit-tree.resting{opacity:.5}
.farm-dialog{width:min(580px,94vw);padding:0 20px 20px}.farm-dialog header{margin:0 -20px 16px}.farm-dialog p{line-height:1.5}.farm-dialog h3{font:20px Georgia,serif}.farm-dialog button{min-height:44px}.farm-dialog [data-farm-message]:empty{display:none}

/* graphics3d/graphics.css */
.graphics-toolbar{position:absolute;z-index:32;left:50%;top:88px;transform:translateX(-50%);display:flex;flex-wrap:wrap;align-items:center;gap:6px;max-width:calc(100% - 40px);padding:7px 9px;background:#13282be8;color:#e5dcc7;border:1px solid #c4a46a66;border-radius:9px;font:12px system-ui}
.graphics-toolbar[hidden],.graphics-surface[hidden]{display:none}
.graphics-toolbar button,.graphics-toolbar select{width:auto;min-height:30px;padding:4px 9px;border:1px solid #ba9d6666;border-radius:5px;background:#263d40;color:#fff4d7;font:inherit}
.graphics-toolbar small{color:#b4c9bf;font-size:10px}
.graphics-surface{position:absolute;inset:0;overflow:hidden;background:#809899;z-index:2}
.graphics-surface canvas{display:block;width:100%;height:100%;outline:none;touch-action:none}
.graphics-active #map{visibility:hidden;pointer-events:none}
.graphics-active #mapViewport{pointer-events:none}
.graphics-active .scene-controls,.graphics-active #sceneCamera{display:none}
.graphics-labels{position:absolute;inset:0;pointer-events:none;overflow:hidden}
.graphics-pin{position:absolute;left:0;top:0;pointer-events:auto;white-space:nowrap;min-height:28px;max-width:225px;padding:4px 8px!important;border:1px solid #d6b26b88!important;border-radius:5px!important;background:#182e30e8!important;color:#f0e4c7!important;font:11px system-ui!important;box-shadow:0 3px 8px #10272550;text-shadow:none!important;transform-origin:center;cursor:pointer}
.graphics-pin[data-kind=monster]{border-color:#e0a28b!important;color:#ffd9ca!important}
.graphics-pin:focus-visible{outline:3px solid #f6e3ab}
.graphics-pin[hidden]{display:none}
.graphics-help{position:absolute;left:50%;bottom:15px;transform:translateX(-50%);width:max-content;max-width:92%;padding:6px 12px;border-radius:20px;background:#152c35b8;color:#eadfc6;font:11px system-ui;pointer-events:none}
@media(max-width:700px){.graphics-toolbar{left:8px;top:156px;transform:none;max-width:calc(100% - 16px)}.graphics-toolbar small{display:none}.graphics-pin{font-size:10px!important}.graphics-help{bottom:145px;font-size:9px}.graphics-toolbar label{font-size:10px}}
