/* Quiet controls matched to the original graphite panels. */
#compass{max-width:260px;gap:4px;padding:0;margin:12px auto 0;grid-template-rows:repeat(3,48px);border:0;border-radius:0;background:none;box-shadow:none}
#compass .direction{min-height:48px!important;padding:3px!important;border:1px solid #606468!important;border-radius:2px!important;background:#242628!important;box-shadow:none;color:#d6dadd!important}
#compass .direction strong{gap:4px;font-size:14px;line-height:20px;color:#e0e5e8;text-shadow:none}
#compass .direction strong::before{width:12px;height:14px;background-image:url('graphite-arrow.svg')}
#compass .direction span{font-size:9px!important;line-height:14px;color:#b8bdc2!important}
#compass .direction:disabled{opacity:.35;filter:none}
#compass .direction:not(:disabled):hover{background:#33373a!important;border-color:#9edcff!important;box-shadow:none}
#compass .compass-refresh{width:38px;height:38px;min-height:38px;border:1px solid #606468!important;border-radius:2px!important;background:#242628!important;box-shadow:none}
#compass .compass-refresh:hover{background:#33373a!important;border-color:#9edcff!important}
#compass .compass-refresh img{width:20px;height:20px}
.b_foot .fantasy-nav,.b_foot .fantasy-nav.female-icon{width:25px;height:25px;margin:0 auto 3px;background-size:contain;background-position:center;background-repeat:no-repeat;filter:none}
.b_foot .nav-0{background-image:url('graphite-location.svg')}
.b_foot .nav-1{background-image:url('graphite-map.svg')}
.b_foot .nav-2,.b_foot .nav-2.female-icon{background-image:url('graphite-character.svg')}
.b_foot .nav-3{background-image:url('graphite-quests.svg')}
.b_foot .nav-4{background-image:url('graphite-chat.svg')}
.b_foot button{min-height:48px!important;background:#242628!important;border:1px solid #606468!important;border-radius:2px!important;padding:5px 2px!important;color:#d8dde1!important}
.b_foot button[aria-current=page]{background:#30383d!important;border-color:#83b1c8!important;color:#e5f4fb!important}
.b_foot button:hover{background:#33373a!important;border-color:#9edcff!important}
#hotel-view .building-exit{text-align:center}#hotel-view #hotel-rest{display:block;margin:12px auto}

.profile-actions{display:flex;flex-wrap:wrap;justify-content:center;gap:8px 18px;padding:12px 4px;border-top:1px solid #494d50}.profile-actions a{font-size:13px}

.world-map-overview{margin-bottom:18px}.world-map-overview summary{cursor:pointer;font-size:15px;font-weight:600;color:#e2ebf1;padding:8px 0}.world-player-position{text-align:center;color:#f2d386;font-size:13px;padding:7px;border:1px solid #675d42;background:#292923;margin:2px 0 8px}#world-overview svg{display:block;width:100%;max-height:270px}#world-city-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:8px}.world-city-card{display:flex;flex-direction:column;padding:9px;border:1px solid #526570;border-radius:4px;background:#242a2e;gap:3px}.world-city-card strong{color:#d9edf8}.world-city-card span{font-size:11px;color:#c2cdd4}.world-city-card small{font-size:10px;color:#a2b4bf}.map-instruction{font-size:12px;color:#b8c8d1}.map-key{flex-wrap:wrap;gap:10px!important;font-size:11px}.map-scroll{border:1px solid #494d50;border-radius:5px;background:#222629;padding:5px}#city-map .map-node{border-radius:3px!important;background:#292d30!important;border-color:#444d53!important;color:#8d9ba4!important;opacity:1}#city-map .map-node.map-building{background:#293842!important;color:#b6d8ec!important;border-color:#637b8b!important;font-weight:700}#city-map .map-node.map-gate{background:#34332b!important;color:#dfd2a6!important}#city-map .map-node.neighbor:not(:disabled){background:#2a3c47!important;border-color:#9edcff!important;color:#d7effc!important}#city-map .map-node.current{background:#68512c!important;color:#fff!important}.map-current{font-size:13px}.map-player{font-weight:700}@media(max-width:420px){.world-city-card{padding:7px}#world-city-list{gap:5px}.world-city-card span{font-size:10px}}

#mine-view .building-exit,#vein-view .building-exit{text-align:center}#mine-dig{display:block;margin:12px auto}#vein-reserve{text-align:center;color:#f2d386;font-weight:600}.world-mine-list{margin:10px 0}.world-mine-list summary{font-size:12px;color:#d8c7a1}#world-mine-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}#city-map .map-node.map-mine{color:#edcf87!important;border-color:#947b45!important;background:#363127!important}

.mining-confirm{max-width:280px;margin:12px auto;text-align:center}.mining-confirm img{display:block;margin:8px auto;border:1px solid #6895a6}.mining-confirm input{max-width:170px;margin:auto;text-align:center}

.character-menu-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 14px;background:#232729;border-bottom:1px solid #42494d}.character-menu-row a{color:#a3d4e8;text-decoration:none}.character-menu-row a:hover{text-decoration:underline}.menu-value{color:#c9e6f0;font-weight:600;min-width:30px;text-align:right}.menu-caption{color:#9ba9b0;font-size:12px}.craft-table{width:100%;border-collapse:collapse;margin:14px 0;background:#232729}.craft-table th,.craft-table td{padding:12px 14px;border:1px solid #48545b;text-align:left}.craft-table th{background:#1b1f21;color:#acbcc5;font-size:13px;font-weight:500}.craft-table th:last-child,.craft-table td:last-child{text-align:center;width:100px}.craft-table a{color:#a3d4e8}.stat-points-total{padding:12px 14px;background:#232c31;border-left:2px solid #7ba7bc;color:#d5e5ed}.stats-form{max-width:360px;margin:18px auto}.stats-form label{display:block;margin-bottom:14px}.stats-form select,.stats-form input{width:100%;box-sizing:border-box;background:#1d2225;color:#dce6eb;border:1px solid #668595;padding:10px;border-radius:3px}.stats-form button{width:100%;background:#2b3941;border:1px solid #709eb3;color:#d9e9f0}
#game #stats-form{display:block;width:100%;max-width:360px;box-sizing:border-box;margin:18px auto;padding:16px;border:1px solid #668595;background:#232729;border-radius:3px}
#game #stats-form label{margin:0 0 14px;text-align:left}
#game #stats-form :is(input,select,button){display:block;width:100%;max-width:none;box-sizing:border-box;margin:6px 0 0}
#game #stats-form button{margin-top:16px}
#stats-view .stat-points-total,#stats-view .b>p:not(.building-exit){text-align:center}
#game form.mining-confirm{width:100%;max-width:280px;box-sizing:border-box;margin:12px auto}

#vein-status{text-align:center;margin:10px auto 14px}#vein-view .title,#vein-view #mine-dig,#mine-view a[data-view="vein"]{color:#e5c26b}#vein-view #mine-dig:disabled{color:#a59161}#mine-view a[data-view="vein"]:hover{color:#f4d78d}
#vein-mined-amount,#mining-log{text-align:center;margin:12px auto;max-width:520px}#mining-log p{margin:6px 0;line-height:1.6}#mining-log{padding:8px 10px;border-top:1px solid #42494d}#inventory-mined-amount{text-align:center}

.mining-skill-gain{color:#ef777b;font-weight:600}

#location-mining-log{text-align:center;margin:10px auto 14px}#mining-log .mining-skill-gain,#location-mining-log .mining-skill-gain{color:#ef777b!important;font-weight:600}

/* Full-height starting characters, keep the PNG transparency. */
#character-view .character-card img, #public-profile .character-card img { width:220px; height:330px; object-fit:contain; object-position:center; background:transparent; border:0; flex-shrink:0; }
#character-view .character-card, #public-profile .character-card { gap:24px; }
@media(max-width:480px) { #character-view .character-card img, #public-profile .character-card img { width:160px; height:240px; } #character-view .character-card, #public-profile .character-card { gap:12px; padding:8px 0; } }
@media(max-width:340px) { #character-view .character-card, #public-profile .character-card { flex-direction:column; } }

.experience-panel{margin:12px 0 18px;padding:12px;background:#202224;border:1px solid #494d50;text-align:center}.experience-panel p{margin:4px 0 8px}

.mining-pending-amount { text-align:center; color:#e5c691; font-weight:600; margin:10px 0 8px; }

.game-version-footer { display:block; text-align:center; color:#aeb4b9; font-size:12px; padding:12px 8px 16px; margin-top:8px; border-top:1px solid #494d50; }

.inventory-elixirs { margin:16px 0; border:1px solid #494d50; background:#252729; }
.inventory-section-title { margin:0; padding:10px 12px; background:#1c1e20; border-bottom:1px solid #494d50; text-align:center; color:#d8c29e; font-size:15px; }
.inventory-elixir-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; padding:12px; }
.inventory-elixir-grid .inventory-item { display:flex; flex-direction:column; padding:12px; border:1px solid #494d50; background:#292b2d; }
.inventory-elixir-grid .inventory-item button { align-self:flex-start; margin-top:auto; }
.inventory-elixir-grid > .muted { grid-column:1/-1; text-align:center; }
@media(max-width:480px) { .inventory-elixir-grid { grid-template-columns:1fr; } }

.elixir-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; margin-bottom:12px; }
.elixir-heading h3 { margin:0; overflow-wrap:anywhere; }
.elixir-info { position:relative; flex-shrink:0; }
.elixir-info summary { display:flex; align-items:center; justify-content:center; width:28px; height:28px; border:1px solid #606468; border-radius:50%; background:#202224; color:#9edcff; cursor:pointer; font-weight:600; list-style:none; }
.elixir-info summary::-webkit-details-marker { display:none; }
.elixir-info summary:focus-visible { outline:2px solid #9edcff; outline-offset:3px; }
.elixir-info[open] summary { background:#303a40; border-color:#9edcff; }
.elixir-description { position:absolute; top:36px; right:0; width:min(230px,70vw); z-index:4; padding:10px 12px; border:1px solid #606468; background:#202224; box-shadow:0 5px 14px #0006; }
.elixir-description p { margin:4px 0; }

.tavern-menu-row { display:grid; grid-template-columns:minmax(0,1fr) auto auto; align-items:center; gap:12px; }
.tavern-menu-row .tavern-buy { min-height:34px; padding:5px 12px; font-size:13px; }
@media(max-width:400px) { .tavern-menu-row { grid-template-columns:minmax(0,1fr) auto; gap:5px 10px; } .tavern-menu-row .tavern-price { grid-column:1; grid-row:2; } .tavern-menu-row .tavern-buy { grid-column:2; grid-row:1/3; } }

#tavern-view a[data-view="tavern-chat"] { color:#78d394; }
#tavern-view a[data-view="tavern-chat"]:hover { color:#a2e8b6; }

/* Patch 0.1.60: blue city building names. */
.sign-bank,
.sign-townhall,
.sign-tavern,
.sign-bank small,
.sign-townhall small,
.sign-tavern small,
#hotel-entry > span,
#hotel-title,
#bank-panel > .title,
#location-summary:has(#townhall-entry:not([hidden])) #location-name {
  color: #74bcf5 !important;
}

/* Patch 0.1.61: player ranking and location nicknames. */
.location-players { display:flex; flex-direction:column; align-items:center; gap:5px; margin:12px 0; text-align:center; }
.location-players a { max-width:100%; overflow-wrap:anywhere; }
.ranking-table-wrap { overflow-x:auto; margin:14px 0; }
.ranking-table { width:100%; border-collapse:collapse; background:#232729; }
.ranking-table th,.ranking-table td { padding:11px 10px; border-bottom:1px solid #42494d; text-align:left; }
.ranking-table th { background:#1b1f21; color:#acbcc5; font-size:13px; font-weight:500; }
.ranking-table th:first-child,.ranking-table td:first-child,.ranking-table th:nth-child(3),.ranking-table td:nth-child(3) { text-align:center; }
.ranking-table th:last-child,.ranking-table td:last-child { text-align:right; white-space:nowrap; }
.ranking-table td:nth-child(2) { overflow-wrap:anywhere; }
.ranking-self { background:#2a353c; }
.ranking-pagination { display:flex; justify-content:center; align-items:center; gap:14px; margin:16px 0; }
@media(max-width:480px) { .ranking-table th,.ranking-table td { padding:9px 5px; font-size:12px; } }

.player-clan-label { color:#a3d4e8; font-size:12px; overflow-wrap:anywhere; }

.ranking-tabs { display:flex; justify-content:center; gap:10px; margin:14px 0; }
.ranking-tabs button[aria-pressed="true"] { background:#303e47; border-color:#8fc0df; color:#b6ddf7; }

#character-nav-label { max-width:100%; overflow-wrap:anywhere; line-height:1.3; font-size:11px; color:#58cf83; }

/* Patch 0.1.64: clan standings and management link. */
.clan-ranking-heading { display:flex; align-items:center; gap:14px; flex-wrap:wrap; }
.clan-ranking-place { min-width:64px; color:#d5bc85; }
.clan-ranking-heading .fantasy-crest { width:48px; height:48.3px; }
#clan-content .clan-management-link { display:inline-block; color:#ff6464; margin:12px 0; }
#clan-content .clan-management-link:hover { color:#ff9292; }
.clan-management-panel { padding:12px; border:1px solid #42494d; margin-bottom:16px; }

/* Patch 0.1.67: bronze clan headings; description remains ordinary text. */
#clan-content h2, #clan-content h3 { color:#d8c29e !important; font-weight:700; }

/* Patch 0.1.68: clan statistics beside the name. */
.clan-ranking-heading { display:grid; grid-template-columns:64px 48px minmax(0,1fr); gap:14px; align-items:center; }
.clan-ranking-heading > a { overflow-wrap:anywhere; }
.clan-ranking-stats { display:flex; flex-direction:column; gap:5px; text-align:right; font-size:13px; white-space:nowrap; }
@media(max-width:480px) { .clan-ranking-heading { grid-template-columns:50px 36px minmax(0,1fr); gap:7px; } .clan-ranking-place { min-width:0; font-size:12px; } .clan-ranking-heading .fantasy-crest { width:36px; height:36.225px; } .clan-ranking-stats { font-size:11px; } }

/* Patch 0.1.70: centered clan name. */
#clan-content > h2 { text-align:center; }

/* Patch 0.1.71: separate clan creation action from the crest gallery. */
#clan-create-form #create-emblems { margin-bottom:24px; border-bottom:1px solid #494d50; }
#clan-create-form > button[type="submit"] { display:block; position:static; width:100%; max-width:320px; box-sizing:border-box; min-height:48px; margin:24px auto 0; padding:12px 20px !important; background:#3d3428 !important; border:1px solid #c6a56d !important; color:#f2dfb9 !important; font-weight:700; border-radius:3px; }
#clan-create-form > button[type="submit"]:hover { background:#50422f !important; border-color:#e1c48f !important; }
#clan-create-form > button[type="submit"]:focus-visible { outline:2px solid #eed6a9; outline-offset:3px; }

/* Patch 0.1.72: small Loren portrait inside his quests. */
.quest-npc-portrait { display:flex; align-items:center; gap:12px; margin:12px 0; }
.quest-npc-portrait img { display:block; width:80px; height:84px; object-fit:contain; flex:0 0 80px; }
.quest-npc-portrait .quest-npc-name { margin:0; }

/* Patch 0.1.73: personal level-up notice on the location. */
.location-level-notice { margin:8px 0; padding:0; text-align:center; color:#70cf8c; font-weight:700; border:0; background:transparent; }

/* Patch 0.1.74: experience thresholds. */
.experience-table-wrap { overflow-x:auto; margin:14px 0; }
.experience-table { width:100%; border-collapse:collapse; background:#232729; }
.experience-table th,.experience-table td { padding:11px 10px; border-bottom:1px solid #42494d; text-align:right; }
.experience-table th { background:#1b1f21; color:#d8c29e; font-size:13px; }
.experience-table td { white-space:nowrap; }
.experience-table th:first-child,.experience-table td:first-child { text-align:left; }
.experience-current { background:#384438; color:#b4e8bd; font-weight:700; }
@media(max-width:480px) { .experience-table th,.experience-table td { padding:9px 6px; font-size:12px; } }

/* Patch 0.1.75: Kopeika mine at 1S/1W. */
#mine-entry.mine-kopeika > span,#mine-title.mine-kopeika { color:#74bcf5 !important; }

/* Patch 0.1.76: premium and larger chat smileys. */
.new-player-gift { display:flex; align-items:center; gap:12px; margin:16px 0 20px; padding:14px; border:1px solid #59666d; background:#262a2c; color:#e5e9eb; }
.new-player-gift p { margin:6px 0 0; font-size:13px; color:#d5d9dc; }
.new-player-gift strong { color:#e5e9eb; line-height:1.5; }
.gift-icon { font-size:32px; line-height:1; flex-shrink:0; }
.premium-status { padding:12px; border:1px solid #9d8258; color:#e5cfaa; }
.premium-offers { display:flex; flex-direction:column; gap:12px; margin:20px 0; }
.message-smiley { display:inline-block; font-size:26px; line-height:1.25; vertical-align:middle; }
.smiley-picker button { font-size:28px !important; min-width:44px; min-height:44px; }

.stat-reset-service { margin-top:24px; padding-top:16px; border-top:1px solid #494d50; }
.stat-reset-service h3 { color:#d8c29e; }
#stat-reset-confirmation { margin:14px 0; padding:12px; border:1px solid #955454; }

/* Patch 0.1.79: online status colors. */
.details .status-online { color:#58cf83 !important; }
.details .status-offline { color:#ff7474 !important; }

/* Patch 0.1.80: messages at the world and city borders. */
.location-boundary { color:#d8c29e; text-align:center; padding:14px; margin:16px 0; border:1px solid #6b6050; background:#202426; line-height:1.6; }

.location-level-notice a { color:#9edcff; font-weight:700; text-decoration:underline; }
.location-level-notice a:hover { color:#d5efff; }

/* Patch 0.1.84: ore mine and separate inventory category. */
.ore-name { color:#74bcf5 !important; }
.ore-panel { text-align:center; }
.ore-panel button { margin:12px auto; }
.inventory-ore { margin:16px 0; padding:14px; border:1px solid #59666d; background:#262a2c; }
.inventory-ore h3 { margin-top:0; color:#d8c29e; }

/* Patch 0.1.85: twenty ore resources. */
.ore-item-group h4 { color:#d8c29e; margin:18px 0 8px; }
.ore-item-row { display:grid; grid-template-columns:minmax(0,1fr) auto auto; gap:10px; padding:12px 0; border-bottom:1px solid #454d51; align-items:start; }
.ore-item-row details { position:relative; }
.ore-item-row summary { cursor:pointer; color:#9edcff; font-weight:bold; }

.ore-item-row details p { font-size:13px; }
.ore-top-grade { color:#e5c26b; font-weight:bold; }

/* Patch 0.1.90: separate ore inventory pages. */
#inventory-ore-attack-items,#inventory-ore-defense-items { margin:16px 0; padding:0 12px; }

/* Patch 0.1.92: ore information expands inside the row. */
.ore-item-row .elixir-info[open] { grid-column:1 / -1; width:100%; min-width:0; }
.ore-item-row .elixir-info[open] summary { margin-left:auto; }
.ore-item-row .elixir-description { position:static; top:auto; right:auto; width:auto; max-width:100%; margin-top:10px; box-sizing:border-box; box-shadow:none; overflow-wrap:anywhere; }

/* Patch 0.1.94: miners appear in a centered row below the timer. */
.mine-player-nicks:not([hidden]) { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:8px 16px; margin:12px 0; text-align:center; }
.mine-player-nicks > span { display:inline-block; }

/* Patch 0.1.95: active vein links; cooldown clicks only refresh state. */
.mining-vein-link { display:inline-block; margin:16px auto 14px; text-decoration:underline; cursor:pointer; }
#mine-dig.mining-vein-link { color:#e5c26b; }
#mine-dig.mining-vein-link:hover { color:#f4d78d; }

/* Patch 0.1.103: compact building art and item information icons. */
/* Patch 0.1.104: small colorful sprites within the existing graphite interface. */
.game-menu-icon{display:inline-block;width:24px;height:24px;object-fit:contain;vertical-align:middle;margin:0 8px 0 0;flex-shrink:0;pointer-events:none}
.title .game-menu-icon,.building-sign .game-menu-icon{width:22px;height:22px}
.character-menu-row a,.service-links a{display:inline-flex;align-items:center}
.b_foot .nav-0{background-image:url('ui-icons/location-104.webp')}
.b_foot .nav-1{background-image:url('ui-icons/map-104.webp')}
.b_foot .nav-2{background-image:url('ui-icons/character-104.webp')}
.b_foot .nav-2.female-icon{background-image:url('ui-icons/character-female-104.webp')}
.b_foot .nav-3{background-image:url('ui-icons/guide-104.webp')}
.b_foot .nav-4{background-image:url('ui-icons/communication-104.webp')}
.fantasy-crest{height:64px;background-size:contain;background-position:center}
.clan-crest.fantasy-crest{width:90px;height:90px}
.clan-ranking-heading .fantasy-crest{width:48px;height:48px}
@media(max-width:480px){.clan-ranking-heading .fantasy-crest{width:36px;height:36px}}
.building-illustration {display:block;width:220px;max-width:100%;height:auto;aspect-ratio:3/2;object-fit:cover;margin:14px auto 18px;border:1px solid #59666d;border-radius:5px;}
.item-info-icon {display:block;width:72px;height:72px;object-fit:contain;margin:0 auto 10px;}

.inventory-item .elixir-heading {flex-wrap:wrap;}
.inventory-item .elixir-info[open] {flex-basis:100%;width:100%;}
.inventory-item .elixir-info[open] summary {margin-left:auto;}
.inventory-item .elixir-description {position:static;top:auto;right:auto;width:auto;max-width:100%;margin-top:10px;box-sizing:border-box;box-shadow:none;overflow-wrap:anywhere;}

/* Combat uses the game's existing graphite surfaces and typography. */
.combat-controls,.monster-pagination{display:flex;justify-content:center;align-items:center;gap:12px;margin:16px 0;flex-wrap:wrap}
#combat-content>h2,#combat-content>p{text-align:center}
#combat-content details button{display:block;margin:8px 0;width:100%}
.combat-log{list-style:none;text-align:center;padding:12px 0 0;border-top:1px solid #46525a;margin-top:18px}
.combat-log li{padding:8px 0}
.combat-result{color:#ff6363;font-weight:bold}
#monster-admin-content input,#monster-admin-content select{width:100%;box-sizing:border-box}

/* Patch 0.1.106: center mine headings and vein links. */
#game #mine-title,#game #ore-title { text-align:center; }
#game #mine-dig.mining-vein-link,#game #ore-dig.mining-vein-link {
 display:block;
 width:fit-content;
 max-width:100%;
 margin:16px auto 14px;
 text-align:center;
}
.combat-controls { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:6px; }
.combat-controls button { min-width:0; padding:8px 5px; font-size:13px; }
.monster-study { padding:8px 12px; border:1px solid #59666d; background:#262a2c; text-align:center; }
.monster-hp-bar { display:block; width:230px; max-width:100%; height:10px; margin:10px auto 16px; padding:0; appearance:none; border:1px solid #59666d; border-radius:2px; background:#1b1e20; overflow:hidden; }
.monster-hp-bar::-webkit-progress-bar { background:#1b1e20; }
.monster-hp-bar::-webkit-progress-value { background:#bf3b42; }
.monster-hp-bar::-moz-progress-bar { background:#bf3b42; }

/* Patch 0.1.108: compact centered battle layout. */
#game #combat-content .combat-controls { display:grid; grid-template-columns:minmax(0,1fr); width:230px; max-width:100%; margin:16px auto; gap:6px; }
#game #combat-content .combat-controls button { width:100%; text-align:center; }
#game #combat-content .combat-kit { text-align:center; }
#game #combat-content .combat-kit summary { text-align:center; list-style-position:inside; }
#game #combat-content .combat-kit button { max-width:320px; margin:8px auto; text-align:center; }
.combat-victory-notice { text-align:center; color:#e5c26b; font-weight:600; margin:4px 0 12px; padding:0; border:0; background:none; }

/* Patch 0.1.109: unboxed wilderness heading and resource header. */
#game #location-pointer.plain-location-heading { display:table; width:fit-content !important; max-width:100%; box-sizing:border-box; margin:0 auto 14px !important; padding:7px 12px !important; background:transparent !important; border:1px solid #59666d !important; box-shadow:none !important; text-align:center; }
#game .sticky_header { background:transparent !important; border:0 !important; box-shadow:none !important; }

/* Patch 0.1.111: remove the outer movement panel. */
#game #location-view > .b:has(> #compass) { background:transparent !important; border:0 !important; box-shadow:none !important; }

/* Patch 0.1.113: recovery countdown beneath the city gate link. */
#exits > #rest-status { width:100%; text-align:center; margin:8px auto 12px; }

/* Patch 0.1.114: more prominent vein links. */
#game #mine-dig.mining-vein-link { font-weight:700; color:#ffd56a !important; }
#game #mine-dig.mining-vein-link:hover { color:#ffe6a3 !important; }
#game #ore-dig.mining-vein-link { font-weight:700; color:#9edcff !important; }
#game #ore-dig.mining-vein-link:hover { color:#d5efff !important; }

/* Temple recovery area. */
.sanctuary-panel { text-align:center; margin:12px auto; max-width:520px; }
#sanctuary-rest #rest-status { text-align:center; margin:12px auto; }

.bootstrap-loading { text-align:center; padding:30px 12px; color:#b8bdc2; }

#monster-admin-content input[type="checkbox"] { width:auto; min-height:0; margin:0 8px 0 0; vertical-align:middle; }
#game .resource { height:28px; line-height:26px; background:#41484e; border-color:#7b8993; }
#game .resource .value { padding:0 5px; font-size:13px; font-weight:750; color:#fff; text-align:center; font-variant-numeric:tabular-nums; text-shadow:-1px -1px 0 #161a1d,1px -1px 0 #161a1d,-1px 1px 0 #161a1d,1px 1px 0 #161a1d; }
@media(max-width:420px){#game .status-bars .resource .value { font-size:11.5px; padding:0 2px; }}
.online-player-name { min-width:0; overflow-wrap:anywhere; }
#game #mine-dig.mining-vein-link,#game #ore-dig.mining-vein-link { border:1px solid #68757f; border-radius:2px; padding:5px 12px; background:transparent; line-height:1.5; }

.combat-heal-form { margin:0; display:grid; gap:6px; }
.combat-heal-form select { margin:0; min-width:0; text-align:center; }

.combat-kit-form { display:grid; gap:6px; width:230px; max-width:100%; margin:10px auto 0; }
.combat-kit-form select { margin:0; min-width:0; text-align:center; }
#game #combat-content .combat-kit-form button { width:100%; margin:0; }

#game #combat-content .combat-controls button,#game #combat-content .combat-heal-form select,#game #combat-content .combat-kit-form select,#game #combat-content .combat-kit-form button { width:100%; min-height:42px; padding:8px 5px; font-size:13px; line-height:1.4; text-align:center; box-sizing:border-box; }
.quest-npc-menu-row { text-align:center; margin:16px 0; }
.quest-npc-menu-row a { display:block; font-weight:700; }
.quest-npc-menu-row small { display:block; color:#b8bdc2; margin-top:4px; }
.b_foot .nav-inventory { background-image:url('ui-icons/inventory-104.webp'); }
#game:has(#combat-view:not([hidden])) .b_foot { display:none !important; }
#game #combat-content .combat-kit { width:230px; max-width:100%; box-sizing:border-box; margin:16px auto 0; padding:0; text-align:center; }
#game:has(#combat-view:not([hidden])) .online-count,
body:has(#game:not([hidden]) #combat-view:not([hidden])) .game-version-footer { display:none !important; }
#game #combat-content .combat-heal-form,
#game #combat-content .combat-kit-form { border:0; padding:0; border-radius:0; box-shadow:none; background:transparent; }
#game #combat-content .combat-heal-form { margin:0; }
#game #combat-content .combat-kit-form { margin:0 auto; }
#game #combat-content .combat-kit { border:0; }
#game #combat-content :is(.combat-heal-form,.combat-kit-form) select:focus { outline-color:#aeb4b9 !important; border-color:#aeb4b9 !important; }
/* Compact graphite combat choices, independent of the system select palette. */
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice { position:relative; margin:0; width:100%; min-width:0; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary { list-style:none; cursor:pointer; position:relative; box-sizing:border-box; min-height:36px; padding:8px 24px; border:1px solid #606468; border-radius:2px; background:#242628; color:#e1e3e5; font-size:13px; line-height:18px; text-align:center; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary::-webkit-details-marker { display:none; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary::after { content:'⌄'; position:absolute; right:9px; color:#b8bdc2; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary[aria-disabled=true] { opacity:.5; cursor:default; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options { position:static; width:100%; box-sizing:border-box; margin-top:4px; max-height:180px; overflow-y:auto; padding:0; border:1px solid #73787c; background:#242628; box-shadow:0 4px 10px #0005; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options button { display:block; width:100%; margin:0; padding:7px 4px; border:0 !important; border-radius:0; background:#242628 !important; color:#e1e3e5 !important; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options button:is(:hover,:focus-visible,[aria-pressed=true]) { background:#41464a !important; color:#fff !important; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice :focus-visible { outline:1px solid #b8bdc2 !important; outline-offset:1px; }
#game #combat-content .combat-controls { gap:4px; margin:10px auto; }
#game #combat-content :is(.combat-heal-form,.combat-kit-form) { gap:4px; }
#game #combat-content .combat-controls button,#game #combat-content .combat-kit-form button { min-height:36px; padding:7px 5px; line-height:20px; }
#game #combat-content .combat-kit { margin-top:10px; }
#game #combat-content > h2 { font-size:18px; margin:6px 0 8px; }
#game #combat-content > p { margin:6px 0; }
#game #combat-content .monster-hp-bar { margin:8px auto 10px; }
#game #combat-content .combat-log { margin:10px 0; padding-top:6px; }
#game #combat-content .combat-log li { padding:4px 0; }
#game #combat-content .combat-controls,#game #combat-content .combat-kit,#game #combat-content .combat-kit-form { width:210px; max-width:100%; }
#game #combat-content .combat-controls button,#game #combat-content .combat-kit-form button { min-height:32px; padding:5px; line-height:20px; font-size:12px; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary { min-height:32px; padding:5px 22px; line-height:20px; font-size:12px; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary,
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options { border-color:#83b1c8; box-shadow:0 0 3px #83b1c833; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice :focus-visible { outline-color:#9edcff !important; }

#game #location-spells { width:210px; max-width:100%; margin:12px auto 0; }
#game #location-spells .location-spell-form { display:grid; gap:4px; margin:0; padding:0; border:0; background:transparent; }
#game #location-spells .location-spell-form > button { min-height:32px; padding:5px; line-height:20px; font-size:12px; width:100%; margin:0; }
#location-view #vision-result { text-align:center; margin-top:12px; overflow-wrap:anywhere; }
#game #location-pointer.plain-location-heading { margin-bottom:8px !important; padding:5px 10px !important; }
#game #location-view > .b:has(> #compass) { padding:8px 10px; margin-bottom:6px; }
#game #location-view .building-entry { padding:5px 4px; gap:2px; }
#game #location-view .gate-quest-npc { margin:8px auto; padding:8px 4px; gap:4px; }
#game #location-view #compass { margin-top:8px; }
#game #location-spells { margin-top:8px; }
#game #location-spells .location-kit-form { margin-top:8px; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice .combat-choice-options > button { position:relative; min-height:32px; box-sizing:border-box; margin:0 !important; padding:5px 20px; font-size:12px; line-height:20px; background:#242628 !important; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice .combat-choice-options > button + button { border-top:1px solid #69747c !important; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice .combat-choice-options > button[aria-pressed=true] { background:#363d42 !important; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice .combat-choice-options > button:is(:hover,:focus-visible) { background:#454d53 !important; }
#game #location-action-log { margin:6px auto 8px; padding:0; border:0; background:transparent; text-align:center; color:#e5c26b; font-size:13px; line-height:1.5; overflow-wrap:anywhere; }
#game #location-action-log p { margin:3px 0; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options { max-height:162px; overflow-y:auto; overscroll-behavior:contain; scrollbar-width:thin; scrollbar-color:#7f919b #242628; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice .combat-choice-options > button { height:32px; min-height:32px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options::-webkit-scrollbar { width:6px; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options::-webkit-scrollbar-track { background:#242628; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice-options::-webkit-scrollbar-thumb { background:#7f919b; border-radius:3px; }
.local-action-line { color:#e5c26b; text-align:center; overflow-wrap:anywhere; }
#game #location-pointer { display:table; width:fit-content !important; max-width:100%; box-sizing:border-box; margin:0 auto 8px !important; padding:5px 10px !important; background:transparent !important; border:1px solid #68757f !important; border-radius:2px !important; box-shadow:none !important; text-align:center; }
#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) :is(.combat-kit-form,.location-kit-form) .combat-choice-options { max-height:98px; margin-top:0; overflow-y:scroll; scrollbar-gutter:stable; }
#game .chat-preview { margin:10px auto 0; padding:8px 0 0; border-top:1px solid #59666d; font-size:12px; }
#game .chat-preview-header { display:flex; align-items:center; justify-content:center; gap:8px; }
#game .chat-preview-header > a { font-weight:600; }
#game .chat-preview-toggle { width:24px; min-height:24px; padding:0; line-height:22px; font-size:16px; color:#b8d9eb; background:transparent; border:1px solid #68757f; border-radius:2px; }
#game .chat-preview-line { margin:6px 0 0; padding:5px 2px 0; border-top:1px solid #41494e; overflow-wrap:anywhere; }
#game .chat-preview-line small { color:#aeb4b9; font-size:10px; }
#game .chat-preview-body { white-space:pre-wrap; }
#game .chat-preview { width:280px; max-width:100%; margin-top:7px; padding-top:5px; font-size:11px; line-height:1.35; }
#game .chat-preview-header { gap:5px; }
#game .chat-preview-toggle { width:20px; min-height:20px; font-size:14px; line-height:18px; }
#game .chat-preview-line { margin-top:3px; padding:3px 1px 0; }
#game .chat-preview-line small { font-size:9px; }
#game .chat-preview-line br { display:none; }
#game .chat-preview-body::before { content:' — '; white-space:normal; }
#game :is(#mining-log,#ore-log,#location-mining-log,#location-ore-log) { width:100%; max-width:520px; margin:8px auto; padding:0; border:0; background:transparent; box-shadow:none; text-align:center; font-size:13px; }
#game :is(#mining-log,#ore-log,#location-mining-log,#location-ore-log) p { margin:2px 0; padding:0; line-height:1.45; text-align:center; }
#game :is(#mining-log,#ore-log,#location-mining-log,#location-ore-log) small { font-size:inherit; color:#c8cdd1; }
#game #compass { width:210px; max-width:100%; grid-template-columns:repeat(3,minmax(0,1fr)); grid-template-rows:repeat(3,38px); gap:6px; margin:10px auto 0; padding:0; }
#game #compass .direction { min-height:38px !important; height:38px; padding:0 !important; }
#game #compass .direction strong { font-size:13px; line-height:20px; font-weight:600; }
#game #compass .direction span,#game #compass .direction small { display:none !important; }
#game #compass .nw { grid-column:1; grid-row:1; }
#game #compass .north { grid-column:2; grid-row:1; }
#game #compass .ne { grid-column:3; grid-row:1; }
#game #compass .west { grid-column:1; grid-row:2; }
#game #compass .east { grid-column:3; grid-row:2; }
#game #compass .sw { grid-column:1; grid-row:3; }
#game #compass .south { grid-column:2; grid-row:3; }
#game #compass .se { grid-column:3; grid-row:3; }
#game #location-view #vision-result { width:fit-content; max-width:min(100%,420px); box-sizing:border-box; margin:6px auto 8px; padding:6px 10px; border:1px solid #687f8c; border-radius:2px; background:transparent; text-align:center; }
#game #location-view #vision-result h3 { margin:0 0 5px; font-size:13px; line-height:1.35; }
#game #location-view #vision-result p { margin:3px 0; font-size:12px; line-height:1.4; }
/* Let short game screens end after their content instead of filling the viewport. */
body:has(#game:not([hidden])) { min-height:0; }
.page:has(#game:not([hidden])) { padding-bottom:6px !important; }
#game .view:not([hidden]) > .b:last-child { margin-bottom:0; }
#game :is(.location-activity,#location-action-log,#inventory-bonuses,#vision-result):empty { display:none; margin:0; padding:0; border:0; }
#game :is(#mine-entry,#ore-entry) .mine-kind-line,#game :is(#mine-entry,#ore-entry) .mine-name-line { display:block; text-align:center; line-height:1.4; }
#game :is(#mine-entry,#ore-entry) .mine-kind-line { margin-bottom:1px; }
.location-experience { max-width:100%; margin:0 auto 6px; text-align:center; }
#location-experience-label { display:block; color:#c5cdd2; font-size:11px; line-height:1.3; }
#character-view .character-card { gap:16px; padding:4px 0; align-items:center; }
#character-view .character-card > img { width:132px; height:198px; }
#character-view .character-card p { margin:5px 0; }
#character-view #character-name { overflow-wrap:anywhere; }
:is(#character-view,#profile-view) .experience-panel { margin:8px 0 12px; padding:8px 10px; background:transparent; }
:is(#character-view,#profile-view) .experience-panel .quest-progress { height:10px; margin:6px 0; }
:is(#character-view,#profile-view) .experience-panel p { margin:3px 0; font-size:12px; }
#character-view .character-data-group { margin:10px 0 0; }
#character-view .character-data-group h3, #character-view .character-data-group summary { margin:0; padding:7px 0; color:#d7bb83; font-size:13px; font-weight:600; border-bottom:1px solid #4b5358; }
#character-view .character-data-group summary { cursor:pointer; }
#character-view .details { margin:0; }
#character-view .details > div { padding:7px 0; gap:12px; }
#character-view .details dt { font-size:12px; }
#character-view .details dd { font-size:13px; overflow-wrap:anywhere; min-width:0; }
#character-view .character-links .title { margin-bottom:2px; }
#character-view .character-menu-row { padding:0; background:transparent; }
#character-view .character-menu-row:last-child { border-bottom:0; }
#character-view .character-menu-row a { padding:9px 5px; flex:1; min-width:0; }
#character-view .menu-value { padding-right:8px; }
#character-view .character-account > button { display:block; margin:8px auto 0; }
@media(max-width:380px) { #character-view .character-card { flex-direction:row; gap:10px; } #character-view .character-card > img { width:100px; height:150px; } #character-view .character-card h2 { font-size:17px; } }
#services-view .service-section-heading { margin:12px 0 8px; color:#d7bb83; font-size:14px; }
#services-view .premium-status { padding:8px; font-size:12px; }
#services-view .stat-reset-service { margin-top:14px; padding-top:10px; }
#services-view .service-links { margin-top:14px; padding-top:8px; border-top:1px solid #4b5358; }
#character-online-status, #public-profile .character-card .status-online { color:#58cf83; font-size:12px; }
#public-profile .character-card .status-offline { color:#ff7474; font-size:12px; }
#character-online-status::before, #public-profile .character-card .status-online::before, #public-profile .character-card .status-offline::before { content:""; display:inline-block; width:7px; height:7px; margin-right:6px; border-radius:50%; background:currentColor; vertical-align:1px; }
#character-view .character-card { position:relative; padding-top:22px; }
#character-view #character-online-status { position:absolute; top:0; right:0; margin:0; white-space:nowrap; }
#character-view .character-card > div { min-width:0; }
#character-clan { font-size:12px; overflow-wrap:anywhere; }
#character-about-view .details > div, #character-attributes-view .details > div { padding:7px 0; gap:12px; }
#character-about-view .details dd, #character-attributes-view .details dd { overflow-wrap:anywhere; min-width:0; }
#settings-view #logout { display:block; width:fit-content; margin:12px auto; }
#settings-view .muted { margin:12px 0; font-size:12px; }
#public-profile .character-card { position:relative; padding:22px 0 6px; gap:16px; align-items:center; }
#public-profile .character-card > img { width:132px; height:198px; }
#public-profile .character-card > div { min-width:0; }
#public-profile .character-card h2 { overflow-wrap:anywhere; }
#public-profile .character-card p { margin:5px 0; }
#public-profile .character-card > .status-online, #public-profile .character-card > .status-offline { position:absolute; right:0; top:0; margin:0; white-space:nowrap; }
#public-profile .public-profile-clan { font-size:12px; overflow-wrap:anywhere; }
#public-profile .public-profile-menu { margin:8px 0; }
#public-profile .character-menu-row { padding:0; background:transparent; }
#public-profile .character-menu-row a { display:flex; align-items:center; padding:9px 5px; width:100%; }
#public-profile .profile-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px 12px; padding:10px 0; }
.public-profile-subtitle { text-align:center; }
#profile-about-view .details > div, #profile-attributes-view .details > div { padding:7px 0; gap:12px; }
#profile-about-view .details dd, #profile-attributes-view .details dd { overflow-wrap:anywhere; min-width:0; }
@media(max-width:380px) { #public-profile .character-card { flex-direction:row; gap:10px; } #public-profile .character-card > img { width:100px; height:150px; } #public-profile .character-card h2 { font-size:17px; } #public-profile .profile-actions { grid-template-columns:1fr; } }
.clan-ranking-table { width:100%; border-collapse:collapse; table-layout:fixed; font-size:13px; }
.clan-ranking-table th, .clan-ranking-table td { padding:9px 7px; border-bottom:1px solid #4b5358; text-align:left; overflow-wrap:anywhere; }
.clan-ranking-table th { color:#bdc8ce; font-size:12px; }
.clan-ranking-table th:first-child { width:60px; }
.clan-ranking-table th:last-child { width:90px; }
.clan-ranking-table td:first-child, .clan-ranking-table td:last-child, .clan-ranking-table th:last-child { text-align:right; }
#profile-crafts-content .craft-table td:first-child { text-align:left; }
#profile-crafts-content .game-menu-icon { vertical-align:middle; margin-right:7px; }
#location-experience-label .experience-remaining-number { color:#ff7474; }
.fantasy-crest { display:none !important; }
.clan-ranking-heading { display:block; }
.clan-ranking-heading > a { display:inline; width:auto; max-width:100%; overflow-wrap:break-word; word-break:normal; font-size:14px; }
#location-action-log .location-message-row { color:#82caff; }
.location-message-panel { max-width:360px; margin:0 auto 9px; }
.location-message-panel #location-message-recipient { text-align:center; color:#9edcff; font-weight:600; }
.location-message-panel textarea { width:100%; box-sizing:border-box; min-height:64px; }
.location-message-panel #location-message-send { display:block; margin:8px auto; }
.location-message-panel .muted { text-align:center; font-size:11px; }
#game #combat-content .combat-controls { gap:7px; }
#game #combat-content :is(.combat-heal-form,.combat-kit-form) { gap:7px; }
#game #location-spells { margin-top:14px; }
#game #location-spells .location-spell-form { gap:6px; }

/* Compact clan directory. */
#game .clan-list-links{margin:8px 0 12px}
#game :is(.clan-list-total,.clan-list-range){margin:3px 0}
#game .game-clan-list{padding-left:25px;margin:10px 0}
#game .game-clan-list li{margin:0 0 10px;padding:0}
#game .game-clan-name{display:flex;align-items:center;gap:6px}
#game .game-clan-name a{overflow-wrap:anywhere}
#game .game-clan-list li p{margin:3px 0 0}
#game .game-clan-list .fantasy-crest{display:inline-block!important;width:30px;height:30px;min-width:30px;background-size:contain;background-repeat:no-repeat;flex:none}

#game .clan-list-title{text-align:center}
#game .crest-option .fantasy-crest{display:inline-block!important;width:30px;height:30px;min-width:30px;background-size:contain;background-repeat:no-repeat}

#game .clan-card-title{display:flex;justify-content:center;align-items:center;gap:8px;margin:4px 0 14px}
#game .clan-card-title .fantasy-crest{display:inline-block!important;width:30px;height:30px;flex:0 0 30px;background-size:contain;background-repeat:no-repeat}
#game .clan-card-facts{display:grid;grid-template-columns:minmax(100px,1fr) minmax(0,2fr);gap:8px 12px;margin:0 0 12px}
#game .clan-card-facts dt{color:#b2c4ce}#game .clan-card-facts dd{margin:0;text-align:right;overflow-wrap:anywhere}
#game .clan-card-section{border-top:1px solid #484d50;padding:8px 0;margin:0}
#game .clan-card-section summary{cursor:pointer;color:#a9d8ef}
#game .clan-recruitment{margin:10px 0}
#game .clan-members-table{width:100%;border-collapse:collapse;margin:8px 0 12px}
#game .clan-members-table :is(th,td){padding:8px;text-align:left;border-bottom:1px solid #484d50}
#game .clan-members-table :is(th,td):last-child{text-align:right}
#game .clan-member-role{display:block;color:#aebdc5;margin-top:2px}
#game .clan-management-panel{margin:12px 0;padding:8px;border:1px solid #535d63}
#game .clan-management-panel summary{cursor:pointer;color:#a9d8ef}
#game .clan-member-management{padding:8px 0;border-bottom:1px solid #484d50}
#game .clan-member-management>div{display:flex;flex-wrap:wrap;gap:6px 12px;margin-top:5px}

#game .invitation-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:6px}

/* 162: original clan card flow, aligned with the graphite theme. */
#game #clan-content>h2{color:#e7edf0!important;font-size:18px;line-height:1.4;margin:4px 0 16px;text-align:center}
#game #clan-content>h3{color:#a9d8ef!important;font-size:14px;line-height:1.4;margin:14px 0 7px;text-align:left}
#game .clan-classic-leadership{margin:0 0 12px}
#game .clan-classic-role{margin:7px 0;line-height:1.6;text-align:left}
#game .clan-classic-label{display:inline-block;min-width:112px;color:#b2c4ce}
#game .clan-classic-text{margin:0 0 12px;line-height:1.6;text-align:left;overflow-wrap:anywhere}
#game .clan-classic-metadata{margin:12px 0}
#game .clan-classic-metadata p{margin:6px 0;text-align:left}
#game .clan-member-list{margin:8px 0 12px}
#game .clan-classic-member{margin:8px 0;line-height:1.7;text-align:left}
#game .clan-inline-actions{display:inline-flex;gap:5px 10px;flex-wrap:wrap;margin-left:10px;font-size:12px}
#game #clan-view>.b>.building-exit{text-align:center;margin:14px 0 3px}

#game :is(#mining-log,#ore-log,#location-mining-log,#location-ore-log) .location-message-row{color:#82caff}
#game :is(#mining-log,#ore-log,#location-mining-log,#location-ore-log,#location-action-log) .location-message-row small{color:inherit}

#game .location-message-panel{width:100%;max-width:300px;padding:9px;box-sizing:border-box;margin:0 auto 8px}
#game .location-message-panel>.title{padding:6px 8px;margin-bottom:7px;font-size:13px;min-height:0}
#game .location-message-panel #location-message-recipient{margin:0 0 7px}
#game #location-message-form{border:0;box-shadow:none;background:transparent;padding:0;margin:0}
#game #location-message-form label{margin:0;font-size:12px;gap:4px}
#game #location-message-body{min-height:46px;height:46px;padding:6px;font-size:13px;line-height:1.35}
#game #location-message-send{padding:5px 12px!important;min-height:29px;margin:7px auto}
#game .location-message-panel>.muted{font-size:10px;line-height:1.35;margin:5px 0}
#game .location-message-panel>.building-exit{margin:8px 0 2px;font-size:12px;line-height:1.5;text-align:center}
#game .location-combat-row{color:#e2c68e}
#game .location-combat-row small{color:inherit}

#game :is(#player-interaction-controls,#npc-target-actions){width:100%;max-width:236px;display:flex;flex-direction:column;gap:7px;margin:10px auto}
#game :is(#player-interaction-controls,#npc-target-actions) .player-action-form{display:flex;flex-direction:column;gap:5px;width:100%;border:0;background:transparent;padding:0;margin:0;box-shadow:none}
#game :is(#player-interaction-controls,#npc-target-actions) :is(button,.combat-choice){width:100%;box-sizing:border-box;min-height:30px;font-size:12px}
#game :is(#player-interaction-controls,#npc-target-actions) button{padding:5px 8px!important;margin:0}
#game :is(#player-interaction-controls,#npc-target-actions) .combat-choice summary{padding:6px 20px 6px 7px;min-height:0;text-align:center}
#game :is(#player-interaction-controls,#npc-target-actions) .combat-choice-options{max-height:100px;overflow-y:auto}
#game #player-target-status{text-align:center;margin:7px 0;font-size:12px}

#game #location-boundary{background:transparent;border:0;box-shadow:none;padding:0;margin:8px auto;max-width:520px;text-align:center;line-height:1.5}

#game .location-combat-row.location-combat-hit{color:#ef777b}

#game .player-target-bars{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px;margin:7px 0 10px}
#game .player-target-bars .resource{width:100%;min-width:0;box-sizing:border-box;height:22px;line-height:20px}
#game .player-target-bars .resource .value{font-size:9.5px;padding:0 1px;font-weight:700}

#game .location-combat-row.location-combat-magic,#game .combat-log .location-combat-magic{color:#70cf8c}
#game .combat-log .location-combat-hit{color:#ef777b}

#game .location-combat-death{color:#ef777b;font-weight:700}

#game .spell-mana-hint{margin:0;padding:0;color:#ef777b;text-align:center;font-size:11px;line-height:1.35;overflow-wrap:anywhere}

#game :is(#combat-content,#location-spells,:is(#player-interaction-controls,#npc-target-actions)) .combat-choice summary.kit-empty[aria-disabled=true]{color:#ef777b;opacity:1}

#game .inventory-functions{display:grid;gap:6px;width:236px;max-width:100%;margin:12px auto;padding:0;border:0;background:transparent;box-shadow:none}
#game .inventory-functions select,#game .inventory-functions button{width:100%;box-sizing:border-box;min-height:34px;margin:0;font-size:12px}
#game .inventory-functions select{border:1px solid #86bad1;background:#242628;color:#e1e3e5;padding:6px 9px;border-radius:2px}
#game .inventory-functions p{font-size:11px;line-height:1.4;text-align:center;margin:0}

#game .inventory-functions label{font-size:12px;margin:0}
#game .inventory-functions input{width:100%;box-sizing:border-box;margin:4px 0}
#game .inventory-functions small{display:block;font-size:10px;line-height:1.4;color:#b7cbd8}

#game .character-equipment-slots{margin:8px 0}
#game .equipment-slot{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:9px 0;border-bottom:1px solid #46525a}
#game .equipment-slot-info{display:flex;flex-direction:column;gap:4px;min-width:0}
#game .equipment-slot-info strong{display:flex;align-items:center;gap:6px;font-size:13px}
#game .equipment-slot-info>.muted{font-size:11px;padding-left:30px}
#game .equipment-slot-actions>button{margin:0;min-height:30px;padding:4px 10px;font-size:12px;flex-shrink:0}

#game .equipment-slot-actions{display:flex;align-items:center;gap:8px;flex-shrink:0}
#game .equipment-slot-details{position:relative;margin:0;padding:0;border:0;background:transparent}
#game .equipment-slot-details>summary{display:flex;align-items:center;justify-content:center;list-style:none;cursor:pointer;color:#9edcff;width:26px;height:26px;font-size:20px;line-height:1}
#game .equipment-slot-details>summary::-webkit-details-marker{display:none}
#game .equipment-slot-details>summary:focus-visible{outline:1px solid #9edcff;outline-offset:2px}
#game .equipment-slot-description{position:absolute;right:0;top:calc(100% + 5px);z-index:5;width:210px;max-width:60vw;box-sizing:border-box;padding:9px;border:1px solid #7195a8;border-radius:2px;background:#303335;color:#e1e3e5;font-size:12px;line-height:1.4;box-shadow:0 3px 8px #0005}
#game .equipment-slot-description p{margin:5px 0 0}

#game #equipment-resources-form{padding:0;border:0;background:transparent;margin:10px 0}
#game .craft-resource-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:7px 0;border-bottom:1px solid #46525a}
#game .craft-resource-row label{display:grid;grid-template-columns:18px 1fr;gap:2px 7px;align-items:center;flex:1;margin:0;font-size:12px;min-width:0}
#game .craft-resource-row label>input{margin:0;width:16px;height:16px}
#game .craft-resource-row small{grid-column:2;font-size:10px;color:#aec7d8}
#game .craft-resource-row>input{width:64px;min-width:0;margin:0;padding:5px;box-sizing:border-box;font-size:12px}
#game #equipment-resources-form>button,#game #equipment-create-final{display:block;margin:8px auto;min-width:160px;font-size:12px;padding:6px 12px}
#game #equipment-resource-total{text-align:center;font-size:11px;margin:7px 0}
#game .equipment-confirmation h3{text-align:center;color:#e5c26b;font-size:15px;margin:6px 0 10px}
#game .equipment-confirmation>p,#game .equipment-confirmation li{font-size:12px;line-height:1.5}
#game #equipment-creation-chance{text-align:center}

#game .craft-resource-row label>span,#game #equipment-confirmation-resources li{color:#ef777b}

#game .equipment-item-card{width:245px;max-width:65vw;max-height:65vh;overflow:auto;text-align:left}
#game .equipment-item-card>h3{font-size:14px;margin:7px 0;text-align:center}
#game .equipment-item-card>img{display:block;margin:5px auto;width:88px;height:88px}
#game .equipment-item-card h4{font-size:11px;color:#b9cddd;margin:10px 0 3px}
#game .equipment-item-card p{font-size:11px;line-height:1.4;margin:3px 0}
#game .equipment-success,#game .equipment-equipped{color:#70cf8c}
#game .equipment-failure{color:#ef777b}
#game .equipment-resource-help{font-size:11px;line-height:1.5;margin:0 0 10px}
#game .equipment-inventory-row .equipment-slot-info>.muted{padding-left:0;font-size:11px;overflow-wrap:anywhere}
#game .equipment-inventory-row .equipment-slot-info>strong{font-size:12px}

#game .inventory-pagination{display:flex;align-items:center;justify-content:center;gap:12px;margin:10px 0 4px;font-size:12px}
#game .inventory-pagination button{font-size:12px;padding:5px 9px;min-height:30px;margin:0}

#game #inventory-items>.inventory-pagination{grid-column:1/-1}

#game #equipment-result-content{text-align:center;font-size:12px;line-height:1.5}
#game #equipment-result-content>p{margin:7px 0}
#game #equipment-result-content>h3{font-size:13px;margin:7px 0}
#game #equipment-result-content>.equipment-slot-details{display:block;width:100%;margin:8px auto 0}
#game #equipment-result-content>.equipment-slot-details>summary{margin:0 auto}
#game #equipment-result-content .equipment-item-card{position:static;inset:auto;width:260px;max-width:100%;max-height:none;overflow:visible;margin:8px auto 0;text-align:center;box-shadow:none}

#game .equipment-slot{flex-wrap:wrap}
#game .equipment-slot-info{flex:1 1 150px}
#game .equipment-inline-info{flex:0 0 100%;width:100%;min-width:0}
#game .equipment-inline-info .equipment-item-card{position:static;inset:auto;width:260px;max-width:100%;max-height:none;overflow:visible;margin:4px auto 0;text-align:center;box-shadow:none}

#game .inventory-functions-help{max-width:460px;margin:8px auto 12px;font-size:11px;line-height:1.5}
#game .inventory-functions-help>summary{cursor:pointer;text-align:center;color:#9edcff;padding:3px 0}
#game .inventory-functions-help>div{padding:3px 0;text-align:left;color:#b9cddd}
#game .inventory-functions-help p{margin:6px 0}
#game .inventory-functions-help strong{color:#e1e3e5}
/* Illustrated world atlas */
#game #world-overview svg{display:block;width:100%;height:auto;max-height:none;touch-action:manipulation}
#game .illustrated-map-panel{padding:10px}
#game #world-player-position{text-align:center;margin:12px 0 8px;color:#d9dfdf}
#game .world-map-toolbar{display:flex;justify-content:center;gap:8px;margin:8px 0 12px}
#game .world-map-toolbar button{padding:8px 14px;min-width:0}
#game .world-map-toolbar [aria-pressed=true]{border-color:#d6c18b;color:#f1dcaa;background:#3b4038}
#game .atlas-marker{cursor:pointer;outline:none}
#game .atlas-marker:focus circle,#game .atlas-marker:hover circle{stroke:#fff4c9;stroke-width:3}
#game #world-map-selection{min-height:48px;text-align:center;padding:12px 5px;display:flex;flex-direction:column;gap:6px;color:#c2ccd0}
#game #world-map-selection strong{color:#e7d3a5}
#game .world-map-legend{font-size:12px;text-align:center;line-height:1.9;color:#ccd3ce}
#game .world-map-legend span{color:#c29aff}
#game .map-help{text-align:center;font-size:11px;line-height:1.5}
#game .map-directory{border-top:1px solid #4a504c;padding-top:12px;margin-top:12px}
#game .map-directory h3{margin:0 0 10px;font-size:13px;color:#b8dcf1}
#game #world-city-list,#game #world-mine-list{display:block;margin:8px 0}
#game .map-directory-row{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;text-align:left;border:0;border-bottom:1px solid #454e47;background:transparent;padding:10px 4px;box-sizing:border-box;font-size:12px}
#game .map-directory-row span{min-width:0;overflow-wrap:anywhere}
#game .map-directory-row small{white-space:nowrap;color:#b4c5ce;font-size:11px}
#game :is(#gem-log,#location-gem-log){width:100%;max-width:520px;margin:8px auto;padding:0;border:0;background:transparent;box-shadow:none;text-align:center;font-size:13px}
#game :is(#gem-log,#location-gem-log) p{margin:2px 0;line-height:1.45;text-align:center}
#game :is(#gem-log,#location-gem-log) small{font-size:inherit;color:inherit}
#game #gem-entry :is(.mine-kind-line,.mine-name-line){display:block;text-align:center;line-height:1.4}
#game #gem-player-nicks{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin:10px 0}

#game .illustrated-map-panel{padding-bottom:90px}

#game .borin-workshop{display:flex;justify-content:center;flex-wrap:wrap;gap:8px;margin:16px 0}
#game .borin-workshop h3{width:100%;text-align:center;margin:0 0 6px}
#game .borin-workshop button{padding:8px 12px;min-width:0}
#game #gate-quest-npc .quest-npc-portrait img{width:80px;height:84px;object-fit:cover;object-position:top}

#game .clan-experience-bonus{font-size:11px;margin:6px 0;color:#bcd5bb}
#game .clan-experience-bonus h3{font-size:13px;margin:8px 0;color:#8ed59a}
#game .clan-experience-bonus p{font-size:11px;line-height:1.5;margin:5px 0;color:#b9c7ce}

#game .clan-experience-label{color:#8ed59a;font-size:inherit}

/* Equipped slots around the character portrait. */
#game :is(#character-view,#public-profile) .avatar-equipment{position:relative;flex:0 0 212px;width:212px;height:244px;min-width:0;display:flex;align-items:flex-start;justify-content:center;padding:0}
#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{width:132px;height:198px;object-fit:contain;border:0;background:transparent}
#game :is(#character-view,#public-profile) .avatar-equipment-slot{position:absolute;width:40px;min-width:0;height:48px;min-height:0;padding:3px 1px;border:1px solid #75818a;border-radius:4px;background:#20272a;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:1px;box-sizing:border-box}
#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-icon{width:28px;height:28px;object-fit:contain;border:0;background:transparent}
#game .avatar-equipment-slot span{font-size:8px;line-height:10px;color:#c0cdd3}
#game .avatar-equipment-slot.is-empty .avatar-equipment-icon{opacity:.45}
#game .avatar-equipment-slot.is-equipped{border-color:#c9aa66}
#game .avatar-equipment-slot[aria-expanded=true]{outline:2px solid #ead49c;outline-offset:2px}
#game .avatar-slot-weapon{left:0;top:76px}
#game .avatar-slot-shield{right:0;top:76px}
#game .avatar-slot-armor{bottom:0;left:calc(50% - 20px)}
#game .avatar-equipment-info{padding:12px 8px;margin:8px 0 12px;border:1px solid #58656c;background:transparent;text-align:center}
#game .avatar-equipment-info[hidden]{display:none}
#game .avatar-equipment-info .equipment-item-card{position:static;inset:auto;max-height:none;width:100%;max-width:100%;margin:0;padding:0;border:0;overflow:visible;box-shadow:none;text-align:center;background:transparent}
#game .avatar-equipment-info-actions{display:flex;justify-content:center;gap:8px;margin-top:12px}
#game .avatar-equipment-info-actions button{width:auto;min-width:80px;padding:7px 12px}
@media(max-width:480px){#game :is(#character-view,#public-profile) .character-card{gap:10px}#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:170px;width:170px;height:212px}#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{width:104px;height:162px}#game :is(#character-view,#public-profile) .avatar-equipment-slot{width:34px;height:44px}#game .avatar-slot-weapon,#game .avatar-slot-shield{top:64px}#game .avatar-slot-armor{left:calc(50% - 17px)}}
@media(max-width:360px){#game :is(#character-view,#public-profile) .character-card{flex-direction:column}#game :is(#character-view,#public-profile) .avatar-equipment{flex:0 0 212px}}

/* Equipment column and a single jewelry row, shared by both profiles. */
#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:188px;width:188px;height:254px}
#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{position:absolute;right:0;top:0;margin:0;width:132px;height:198px}
#game .avatar-slot-weapon,#game .avatar-slot-armor,#game .avatar-slot-shield{left:0;right:auto;bottom:auto}
#game .avatar-slot-weapon{top:8px}#game .avatar-slot-armor{top:64px}#game .avatar-slot-shield{top:120px}
#game .avatar-slot-jewelry1,#game .avatar-slot-jewelry2,#game .avatar-slot-jewelry3{top:auto;bottom:0}
#game .avatar-slot-jewelry1{left:56px;right:auto}#game .avatar-slot-jewelry2{left:102px;right:auto}#game .avatar-slot-jewelry3{left:auto;right:0}
@media(max-width:480px){#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:158px;width:158px;height:212px}#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{width:104px;height:162px}#game .avatar-slot-weapon{top:5px}#game .avatar-slot-armor{top:55px}#game .avatar-slot-shield{top:105px}#game .avatar-slot-jewelry1{left:48px}#game .avatar-slot-jewelry2{left:86px}}
@media(max-width:360px){#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:212px}}

#game .jewelry-slot-picker{flex:0 0 100%;display:flex;flex-wrap:wrap;justify-content:center;gap:6px;padding:8px 0}
#game .jewelry-slot-picker p{width:100%;text-align:center;margin:3px 0}
#game .jewelry-slot-picker button{font-size:11px;min-width:0;padding:7px}

/* Teleport uses the same compact spacing for windows and city destinations. */
#game #teleport-content{max-width:480px;margin:0 auto}
#game .teleport-summary{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:16px;padding:16px 0}
#game .teleport-summary>div{min-width:0}#game .teleport-summary>div:last-child{text-align:right}
#game .teleport-summary small{display:block;color:#9db2be;font-size:10px;margin-bottom:5px}
#game .teleport-summary strong{font-size:12px;overflow-wrap:anywhere}
#game .teleport-section{padding:15px 0 10px;border-top:1px solid #465057}
#game .teleport-section-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:0 0 10px}
#game .teleport-section-heading h3{margin:0;font-size:13px;color:#dfc698}
#game .teleport-section-heading>small{font-size:10px;color:#b2c4ce;white-space:nowrap}
#game #teleport-content .teleport-open{display:block;width:100%;max-width:320px;margin:12px auto 8px;padding:0;border:0;border-radius:0;box-shadow:none;background:transparent}
#game #teleport-content .teleport-open label{display:block;margin:0;text-align:left;font-size:11px}
#game #teleport-content .teleport-open input{width:100%;box-sizing:border-box;height:34px;margin:6px 0 10px;padding:7px 9px;font-size:11px}
#game #teleport-content .teleport-open>button{display:block;width:100%;min-height:34px;margin:0;padding:7px 12px;font-size:11px}
#game .teleport-note,#game .teleport-empty,#game .teleport-warning{margin:8px 0;font-size:10px;line-height:1.6}
#game .teleport-note,#game .teleport-empty{color:#aabcc6}#game .teleport-warning{color:#ef777b}
#game .teleport-window{display:flex;gap:12px;align-items:center;min-height:48px;padding:8px 0;border-bottom:1px solid #404a50}
#game .teleport-window:last-child{border-bottom:0}#game .teleport-destination{flex:1;min-width:0}
#game .teleport-destination strong{display:block;font-size:12px;font-weight:600;overflow-wrap:anywhere}
#game .teleport-destination small{display:block;margin-top:4px;color:#9db2be;font-size:10px}
#game .teleport-window button{width:auto;flex-shrink:0;min-width:78px;min-height:32px;padding:6px 10px;font-size:11px;margin:0}
#game .teleport-actions{display:flex;align-items:center;gap:6px;flex-shrink:0}
#game .teleport-window button.teleport-close{min-width:30px;width:30px;padding:4px;color:#aebcc4;font-size:16px}
#game .teleport-city-status{width:114px;flex-shrink:0;text-align:right;color:#8c9ba3;font-size:10px}
#game .teleport-city-status.is-current{color:#78c995}
#game .location-teleport-row{color:#bca9e5}
@media(max-width:360px){#game .teleport-summary{gap:10px}#game .teleport-section-heading{gap:8px}#game .teleport-window{gap:8px}#game .teleport-city-status{width:98px}#game .teleport-window button{min-width:70px;padding:6px 8px}}

#game #world-overview{position:relative}#game .map-object-tooltip{position:absolute;z-index:2;box-sizing:border-box;width:240px;max-width:calc(100% - 16px);padding:10px 32px 10px 12px;background:#252d29;border:1px solid #a99b75;box-shadow:0 3px 12px #0008;transform:translate(-50%,-100%);margin-top:-20px;pointer-events:auto;text-align:left}#game .map-object-tooltip.is-below{transform:translate(-50%,0);margin-top:20px}#game .map-object-tooltip strong{display:block;font-size:12px;color:#ead6ab;overflow-wrap:anywhere}#game .map-object-tooltip small{display:block;margin-top:5px;font-size:11px;color:#c3d2da}#game .map-object-tooltip button{position:absolute;right:3px;top:3px;width:26px;min-width:0;height:26px;min-height:0;margin:0;padding:0;border:0;background:transparent;color:#cbd3d8;font-size:18px}

#game .form-spell-help{font-size:10px;line-height:1.5;text-align:center;margin:7px 0}#game .form-spell-help[hidden]{display:none}

#game .player-form-label{color:#78c995;font-size:11px;white-space:nowrap}

/* Mail conversations */
#game .mail-panel { min-width:0; }
#game .mail-online { display:block; text-align:center; margin:12px 0; }
#game .mail-start { display:flex; align-items:end; gap:8px; margin:16px 0; }
#game .mail-start label { flex:1; min-width:0; margin:0; }
#game .mail-start input { width:100%; box-sizing:border-box; }
#game .mail-start button { width:auto; margin:0; }
#game .mail-dialog { display:flex; flex-direction:column; gap:6px; width:100%; text-align:left; margin:0; padding:12px; border:0; border-bottom:1px solid #485054; background:transparent; }
#game .mail-dialog-title { display:flex; align-items:center; justify-content:space-between; width:100%; font-weight:bold; }
#game .mail-badge { color:#fff; background:#665086; border-radius:12px; padding:2px 7px; }
#game .mail-snippet { display:block; width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#game .mail-dialog small { color:#a6c5d9; }
#game .mail-peer { display:block; text-align:center; font-weight:bold; margin:14px 0; }
#game .mail-messages { display:flex; flex-direction:column; gap:10px; max-height:45vh; min-height:100px; overflow-y:auto; padding:8px 3px; }
#game .mail-bubble { align-self:flex-start; max-width:85%; padding:8px 10px; background:#343c41; border-radius:8px; overflow-wrap:anywhere; box-sizing:border-box; }
#game .mail-bubble.mail-own { align-self:flex-end; background:#354947; }
#game .mail-bubble small { display:block; color:#b5cbd4; font-size:10px; }
#game .mail-bubble p { margin:5px 0; white-space:pre-wrap; }
#game .mail-reply { display:flex; align-items:end; gap:8px; margin-top:14px; }
#game .mail-reply textarea { flex:1; min-width:0; box-sizing:border-box; margin:0; }
#game .mail-reply button { width:auto; margin:0; }
#game .chat-preview-header { flex-wrap:nowrap; }
@media(max-width:400px){#game .mail-reply { flex-direction:column; align-items:stretch; }#game .mail-reply textarea { width:100%; }}

#game .combat-technique-form { display:flex; flex-direction:column; gap:5px; width:100%; margin:8px auto; }
#game .combat-technique-form > small { text-align:center; color:#aac8dc; }
#game .combat-technique-form > button { width:100%; }
#game .combat-technique-form .spell-mana-hint { margin:0; }
#game .ability-setting { display:flex; align-items:center; gap:8px; margin:8px 0; }
#game .ability-setting input { width:16px; height:16px; margin:0; flex:none; }

#game .ability-order-row { display:flex; align-items:center; justify-content:space-between; gap:8px; border-bottom:1px solid #485054; padding:5px 0; }
#game .ability-order-row .ability-setting { flex:1; min-width:0; }
#game .ability-setting small { display:block; font-size:10px; color:#aac8dc; margin-top:4px; }
#game .ability-order-buttons { display:flex; gap:4px; flex:none; }
#game .ability-order-buttons button { width:30px; min-width:30px; padding:5px; margin:0; }

#game .avatar-slot-book { left:0; right:auto; top:176px; bottom:auto; }
@media(max-width:480px){#game .avatar-slot-book { top:155px; }}

#game .book-scroll-slots { display:flex; flex-wrap:wrap; justify-content:center; gap:6px; margin:12px auto; }
#game .book-scroll-slots span { display:flex; width:42px; height:48px; align-items:center; justify-content:center; border:1px solid #7b6d50; border-radius:3px; color:#9aafb9; font-size:10px; background:#283034; }

#game [data-mail-link] { display:inline-flex; align-items:center; gap:5px; white-space:nowrap; }
#game .mail-link-badge { display:inline-flex; align-items:center; justify-content:center; min-width:21px; min-height:21px; padding:1px 6px; border-radius:11px; background:#ca2639; color:#fff; font-size:12px; line-height:19px; font-weight:700; text-decoration:none; box-sizing:border-box; }
#game .mail-badge { background:#ca2639; color:#fff; }

#game .mail-reply { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:start; }
#game .mail-body-label { grid-column:1/-1; margin:0; min-width:0; }
#game .mail-body-label textarea { display:block;width:100%; }
#game .mail-reply .smiley-bar { min-width:0; margin:0; }
#game .mail-reply .smiley-picker { display:flex; flex-wrap:wrap; gap:3px; max-width:100%; }
#game .mail-reply .smiley-picker button { min-width:32px;min-height:32px;padding:3px; }
#game .mail-delivery-status { grid-column:1/-1;color:#adbec7;font-size:10px;overflow-wrap:anywhere; }
#game .mail-receipt { margin-top:5px; }
#game .mail-receipt.is-read { color:#81c89f; }

#game .world-online-footer{text-align:center;font-size:12px;padding:8px 0;margin:0;}#game .world-online-footer a{color:inherit;text-decoration:none;}#game .world-online-footer a:hover{text-decoration:underline;}

/* Mine support and centered player roster. */
#game .mine-player-nicks:not([hidden]){display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;margin:12px 0;text-align:center;}
#game .mine-player-nicks>span{display:block;max-width:100%;overflow-wrap:anywhere;}
#game .mining-support{margin:14px auto 0;}

#game .city-animal-link{color:var(--ui-text-red,#ff6262)!important}#game .city-animal-row{margin:6px 0;text-align:center}#game #auction-content :is(input,select),#game #auction-controls select{max-width:100%;box-sizing:border-box}#game #auction-content label,#game #auction-controls label{display:block;margin:8px 0}#game #auction-content article{overflow-wrap:anywhere}
/* 231: one question-mark control; item cards stay within the document flow. */
#game summary.item-info-trigger{display:flex!important;align-items:center;justify-content:center;box-sizing:border-box;width:30px!important;height:30px!important;min-width:30px;min-height:30px;padding:0!important;border:1px solid currentColor;border-radius:50%;background:var(--ui-control-bg,#202224)!important;color:var(--ui-control-fg,#9edcff)!important;font:700 17px/1 Arial,sans-serif;list-style:none!important;cursor:pointer;text-indent:0}
#game summary.item-info-trigger::marker{content:''}#game summary.item-info-trigger::-webkit-details-marker{display:none}#game summary.item-info-trigger::after{content:none!important}#game summary.item-info-trigger:focus-visible{outline:2px solid currentColor;outline-offset:3px}
#game :is(.equipment-slot-description,.elixir-description){position:static!important;transform:none!important;width:100%;max-width:100%;max-height:none;box-sizing:border-box;overflow-wrap:anywhere;overflow:auto;margin-top:8px;box-shadow:none}
#game .equipment-inventory-row:has(details[open]){flex-wrap:wrap}#game .equipment-inventory-row:has(details[open])>.equipment-slot-actions{flex-basis:100%;display:flex;align-items:flex-start;flex-wrap:wrap}#game .equipment-inventory-row details[open]{flex:1;min-width:0}
#game .elixir-heading:has(details[open]){flex-wrap:wrap}#game .elixir-heading>details[open]{flex-basis:100%;min-width:0}#game .fish-item-info>div{box-sizing:border-box;max-width:100%}
#game #market-content article{overflow-wrap:anywhere;min-width:0}#game #market-content details[open]{width:100%;max-width:100%}#game #market-content label{display:block;margin:10px 0}#game #market-content :is(input,select){max-width:100%;box-sizing:border-box}#game .market-confirm{padding:10px;border:1px solid currentColor;margin:10px 0}#game .market-confirm button{margin:4px}

/* 231: a single layout for every quest giver. */
#game #npc-quest-dialog .quest-card{max-width:640px;margin:0 auto;padding:12px 0;min-width:0;overflow-wrap:anywhere;box-sizing:border-box}
#game #npc-quest-dialog .quest-npc-portrait{display:flex;justify-content:center;align-items:center;margin:12px auto 18px;gap:0}
#game #npc-quest-dialog .quest-npc-portrait img{width:96px;height:100px;object-fit:contain;flex:0 0 96px;display:block}
#game #npc-quest-dialog .quest-card>h3,#game #npc-quest-dialog .quest-reward{text-align:center}
#game #npc-quest-dialog .quest-progress{display:block;width:100%;max-width:100%;box-sizing:border-box;margin:14px 0}
#game #npc-quest-dialog .quest-card>button{display:block;margin:12px auto;max-width:100%;white-space:normal}
#game #npc-quest-dialog .quest-card>a{display:block;margin:14px 0;text-align:center;overflow-wrap:anywhere}
#game #npc-quest-dialog .borin-workshop{display:flex;flex-wrap:wrap;justify-content:center;gap:8px}#game #npc-quest-dialog .borin-workshop h3{width:100%;text-align:center}

/* 232: message and skill colors apply to every location/mining log. */
#game .location-message-row{color:var(--ui-text-blue,#82caff)!important}
#game .location-message-row :is(span,strong,small,time){color:inherit!important}
#game .digger-skill-gain{color:var(--ui-text-red,#ef777b)!important;font-weight:600}

/* Slightly larger portraits; keep equipment slots and profile text separate. */
#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:204px;width:204px;height:278px;}
#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{width:148px;height:222px;}
#game :is(#character-view,#public-profile) .character-card h2{overflow-wrap:anywhere;}
@media(max-width:480px){#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:174px;width:174px;height:238px;}#game :is(#character-view,#public-profile) .avatar-equipment .avatar-equipment-portrait{width:116px;height:174px;}}
@media(max-width:360px){#game :is(#character-view,#public-profile) .avatar-equipment{flex-basis:238px;}}

/* Shared painted equipment icons; slot positions stay unchanged. */
#game .equipment-inventory-row .equipment-slot-info{display:grid;grid-template-columns:44px minmax(0,1fr);column-gap:10px;align-items:center}
#game .equipment-inventory-row .equipment-slot-info>.equipment-fantasy-icon{grid-column:1;grid-row:1 / span 3;width:44px;height:44px;object-fit:contain;background:transparent;border:0}
#game .equipment-inventory-row .equipment-slot-info>:not(.equipment-fantasy-icon){grid-column:2}
#game :is(#character-view,#public-profile) .avatar-equipment-slot.is-empty .avatar-equipment-icon{opacity:.75}
#game .release-news-herald{display:flex;align-items:center;gap:12px}
#game .release-news-herald>img{flex:0 0 88px;width:88px;height:88px;object-fit:contain;border:0;background:transparent}
#game .brewing-result-image{width:180px;height:180px;object-fit:contain;display:block;margin:12px auto}
@media(max-width:480px){#game .release-news-herald>img{flex-basis:72px;width:72px;height:72px}}

html[data-theme] #game#game [data-news-link]{color:var(--ui-text-red,#ed6969)!important}
html[data-theme] #game#game [data-mail-link]{color:var(--ui-text-green,#70d887)!important}
#game .temple-panel{text-align:center}#game .temple-interior{display:block;width:100%;max-width:600px;height:auto;max-height:340px;object-fit:cover;margin:12px auto;border:0}
html[data-theme] #game#game .temple-blue{color:var(--ui-text-blue,#79bfff)!important}
#game .temple-cleric{display:flex;align-items:center;justify-content:center;gap:12px;margin:16px auto 6px}#game .temple-cleric img{object-fit:contain;border:0;background:transparent}
#game .temple-dialog{text-align:left;max-width:560px;margin:16px auto}#game .temple-dialog summary{cursor:pointer;padding:8px 0}#game .temple-dialog details{margin:8px 0}
#game #quest-list .quest-npc-menu-row{display:flex;align-items:center;gap:12px;margin:0;padding:10px 4px;border-bottom:1px solid var(--ui-border,#455058);text-align:left}
#game #quest-list .quest-npc-portrait{flex:0 0 64px;width:64px;margin:0;display:block}#game #quest-list .quest-npc-portrait img{display:block;width:64px;height:68px;object-fit:contain;margin:0}
#game #quest-list .quest-npc-menu-text{display:flex;min-width:0;flex:1;flex-direction:column;gap:5px}#game #quest-list .quest-npc-menu-text small{margin:0;display:block}
#game #quests-view{padding-bottom:85px}
