/* Playable game panels reuse the approved stone skin and optimized illustrations. */
body[data-gameplay="true"] .preview-controls {display:none!important;}
/* Locked training destinations stay visible; only their actions are unavailable. */
body[data-gameplay="true"] #submenus .is-level-locked {cursor:not-allowed;}
body[data-gameplay="true"] #submenus .is-level-locked>.icon {filter:saturate(.3);opacity:.48;}
.submenu-level-lock {position:absolute;z-index:3;left:50%;bottom:8%;transform:translateX(-50%);display:flex;align-items:center;justify-content:center;gap:2px;white-space:nowrap;padding:1px 3px;border:1px solid #ab956c;border-radius:4px;background:#dfd0ad;color:#645035;font:600 clamp(7px,.72vw,10px)/1.15 system-ui,sans-serif;pointer-events:none;}
.submenu-level-lock svg {width:8px;height:10px;flex:0 0 8px;}
body:is([data-preview="tablet"],[data-preview="web"]) .submenu-level-lock {position:static;transform:none;align-self:center;margin-left:auto;}
body[data-gameplay="true"] #equipment-test-tools,
body[data-gameplay="true"] .phone-equipment,
body[data-gameplay="true"] .equipment-grid,
body[data-gameplay="true"] .character-preview {display:none!important;}
body[data-gameplay="true"] .empty-window {padding:0!important;overflow:hidden;}
body[data-gameplay="true"] .empty-window-body {position:relative;width:100%;height:100%;min-height:0;}
#game-runtime {position:absolute;inset:0 8.1%;z-index:4;color:#493e2a;font:11px/1.35 system-ui,sans-serif;min-height:0;overflow:hidden;text-size-adjust:100%;-webkit-text-size-adjust:100%;}
body:not([data-preview="phone"]) #game-runtime {inset:0;}
/* Both rails reveal this same page field; only the accepted inner bevel is overlaid. */
body[data-gameplay="true"][data-preview="phone"] .painted-interior .scene {background:#c9b99a var(--stone-page-background) center/100% 100% no-repeat;}
body[data-gameplay="true"][data-preview="phone"] .painted-interior .interior-window {background:transparent!important;}
/* Mobile/tablet have one fixed scene viewport; scrolling never paints a bar. */
body:is([data-preview="phone"],[data-preview="tablet"]) #game-runtime :is(.g2-scroll,.g2-scroll *,.g2-dialog,.g2-dialog *) {scrollbar-width:none!important;-ms-overflow-style:none;}
body:is([data-preview="phone"],[data-preview="tablet"]) #game-runtime :is(.g2-scroll,.g2-scroll *,.g2-dialog,.g2-dialog *)::-webkit-scrollbar {display:none!important;width:0!important;height:0!important;}
body:is([data-preview="phone"],[data-preview="tablet"]) #game-runtime .g2-scroll {overflow-y:auto!important;overflow-x:hidden;scrollbar-gutter:auto;touch-action:pan-y;}
#game-runtime * {box-sizing:border-box;}
.g2-shell {height:100%;display:flex;flex-direction:column;min-height:0;position:relative;}
.g2-scroll {flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-color:#88754c99 transparent;scrollbar-width:thin;padding:5px 9px 8px;}
.g2-scroll:has(> .g2-heading) {padding-top:20px;}
.g2-feedback {position:absolute!important;width:1px;height:1px;padding:0!important;border:0!important;}
.g2-error-note {position:absolute;z-index:20;bottom:5px;left:9px;right:9px;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:5px 8px;border:1px solid #af7153;border-radius:4px;background:#6b2c23;color:#fff0d6;font-size:11px;box-shadow:0 2px 5px #38221e44;}
.g2-error-note .g2-button {min-height:32px;padding:3px 8px;font-size:10px;}
.g2-heading {display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 15px;margin:0 0 7px;}
.g2-heading h1 {font:700 14px/1.2 Georgia,serif;margin:0;color:#4d3a23;}
.g2-heading p {margin:0;font-size:11px;color:#756249;}
#game-runtime h2,.g2-dialog h2 {font:700 13px/1.25 Georgia,serif;margin:0 0 5px;color:#4d3a23;}
#game-runtime h3,.g2-dialog h3 {font:700 12px/1.3 Georgia,serif;margin:5px 0;}
#game-runtime p,.g2-dialog p {margin:5px 0 9px;}
.g2-tabs {display:flex;gap:5px;flex-wrap:wrap;margin:4px 0 9px;}
.g2-button,.g2-tabs button,#game-runtime select,#game-runtime input,.g2-dialog input,.g2-dialog select {font:inherit;}
.g2-button {min-height:44px;max-width:100%;padding:9px 14px;border:1px solid #8c7049;border-radius:5px;background:linear-gradient(#953d2e,#66261e);color:#f8e6bf;cursor:pointer;font-family:Georgia,serif;font-weight:700;white-space:normal;display:inline-flex;align-items:center;justify-content:center;gap:6px;text-align:center;}
.g2-button.stone-ui {padding:8px 13px;min-height:44px;}
.g2-secondary {background:linear-gradient(#e3d4af,#c7b58f);color:#53412b;text-shadow:none;border:1px solid #aa936e;box-shadow:inset 0 1px #f6e8c6;}
.g2-button:disabled {opacity:1;cursor:not-allowed;color:#8b795c!important;background:var(--stone-code-skin,linear-gradient(#dfd1ac,#cabb96)) center/100% 100% no-repeat;box-shadow:none;text-shadow:none!important;filter:none;}
.g2-button:focus-visible,.g2-map-pin:focus-visible,.g2-item:focus-visible,.g2-character-slot:focus-visible {outline:3px solid #9b6b30;outline-offset:1px;}
.g2-tabs .g2-button {min-height:36px;padding:5px 10px;font-size:11px;}
.g2-selected {background:linear-gradient(#953d2e,#66261e)!important;color:#fff0d0!important;border-color:#a87839!important;box-shadow:inset 0 1px #d99568;}
.g2-action-line {display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-top:9px;}
.g2-action-line>.g2-button:last-child {margin-left:auto;}
.g2-panel,.g2-recipe,.g2-shop-offer,.g2-costume {padding:10px!important;min-width:0;}
.g2-panel p,.g2-hint {font-size:12px;color:#756148;}
.g2-hint {margin:8px 0;line-height:1.5;}
.g2-empty {padding:18px 12px;text-align:center;color:#76634b;display:grid;place-items:center;min-height:80px;}
.g2-empty strong {font-family:Georgia,serif;font-size:13px;}
.g2-empty p {max-width:470px;}
.g2-positive,.g2-ready {color:#366843;}
.g2-negative {color:#9c2f24;}
.g2-timer,.g2-badge {display:inline-flex;gap:5px;align-items:center;font-size:12px;color:#796144;}
.g2-badge {padding:3px 8px;border:1px solid #aa936e;border-radius:4px;}
.g2-materials {display:flex;gap:5px 13px;flex-wrap:wrap;font-size:12px;color:#6d593e;margin:5px 0 10px;}
.g2-materials span {padding:3px 6px;background:#eadfbe70;border-radius:3px;}
.g2-costs {color:#786344;font-size:12px;line-height:1.7;}
.g2-costs span {display:inline-flex;gap:3px;align-items:center;}
.g2-split {display:grid;grid-template-columns:1fr 1fr;gap:13px;align-items:start;}
.g2-three-columns {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-bottom:12px;}
.g2-recipe-grid,.g2-shop-grid {display:grid;grid-template-columns:repeat(auto-fit,minmax(185px,1fr));gap:10px;}
.g2-list {display:grid;gap:7px;margin-top:9px;}
.g2-list-row {display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px;border-bottom:1px solid #b29a74;color:#53412c;}
.g2-list-row strong {font-family:Georgia,serif;font-size:12px;}
.g2-list-row small,.g2-upgrade-row small,.g2-market-row small {display:block;font-size:11px;color:#7d674b;margin-top:3px;}
.g2-list-row .g2-button {flex-shrink:0;}
.g2-table {border-collapse:collapse;width:100%;font-size:11px;}
.g2-table th,.g2-table td {padding:6px 8px;text-align:left;border-bottom:1px solid #af9975;}
.g2-table th {font:600 10px/1.3 system-ui;color:#695238;}
.g2-scroll:has(> .g2-table) {padding-top:20px;}
.g2-own-row {background:#ded0ac;}
#game-runtime label,.g2-dialog label {display:grid;gap:4px;font-size:12px;color:#725a3b;margin-bottom:9px;}
#game-runtime input,#game-runtime select,.g2-dialog input,.g2-dialog select {min-height:40px;max-width:100%;width:100%;border:1px solid #a38b62;border-radius:4px;background:#eadbb8;color:#493a26;padding:7px 8px;}
#game-runtime input:focus,.g2-dialog input:focus,#game-runtime select:focus {outline:2px solid #a57b3f;outline-offset:1px;}
.g2-inline-form {display:flex;flex-wrap:wrap;align-items:end;gap:8px;margin:12px 0;}
.g2-inline-form label {margin:0;}
.g2-inline-form input {max-width:140px;}
#game-runtime details,.g2-dialog details {margin-top:10px;padding:8px;border-top:1px solid #b6a079;}
#game-runtime summary,.g2-dialog summary {cursor:pointer;min-height:32px;}

.g2-stat-symbol {display:grid;place-items:center;color:#8a6837;}
.g2-gold {display:inline-flex;gap:4px;align-items:center;white-space:nowrap;}

/* Map and encounters. */
.g2-region-list {display:flex;gap:5px;overflow-x:auto;padding-bottom:7px;margin-bottom:5px;scrollbar-width:thin;}
.g2-energy-line {display:flex;align-items:center;gap:9px;justify-content:space-between;margin-bottom:8px;}
.g2-energy-line .g2-button {min-height:34px;padding:5px 9px;font-size:11px;}
.g2-region-list .g2-button {display:grid;flex:0 0 115px;gap:2px;text-align:left;justify-content:stretch;min-height:51px;padding:6px 9px;font-size:12px;}
.g2-region-list small {font:10px system-ui;opacity:.8;}
.g2-map {position:relative;height:160px;overflow:hidden;margin-bottom:9px;border:1px solid #9b8867;border-radius:8px;box-shadow:inset 0 1px 4px #76633b66;background:#b6c8bd;}
.g2-map>svg {width:100%;height:100%;}
.g2-map-pin {position:absolute;transform:translate(-50%,-50%);width:34px;height:34px;border-radius:50%;border:2px solid #e2ca92;background:#6b6448;color:#fff0c9;font-weight:700;cursor:pointer;box-shadow:0 2px 4px #32261470;}
.g2-map-pin:disabled {background:#7e7d69;opacity:.65;font-size:11px;cursor:not-allowed;}
.g2-expedition-detail {display:grid;grid-template-columns:minmax(130px,.8fr) minmax(0,2fr);gap:12px;padding:12px!important;}
.g2-expedition-detail>div:first-child p {font-size:12px;color:#7b6447;}
.g2-enemy-list {display:flex;gap:6px;flex-wrap:wrap;}
.g2-enemy-list .g2-button {display:grid;justify-items:center;gap:3px;flex:1;min-width:96px;font-size:12px;}
.g2-enemy-list small {font:11px system-ui;}
.g2-dungeon-stages {display:flex;gap:7px;margin:12px 0;}
.g2-dungeon-stages span {width:36px;height:36px;border:1px solid #9a835d;border-radius:50%;display:grid;place-content:center;font-size:11px;background:#cbb892;}
.g2-dungeon-stages .current {background:#81382b;color:#ffeccc;border-color:#d0a061;}
.g2-dungeon-stages .complete {background:#7d8a65;color:#f2e9d4;}
.g2-duel-layout {display:grid;grid-template-columns:1fr 1.2fr;gap:12px;}
.g2-opponents {display:grid;gap:6px;align-content:start;}
.g2-opponents>.g2-button {display:flex;justify-content:start;gap:10px;text-align:left;min-height:60px;}
.g2-opponents strong,.g2-opponents small {display:block;}
.g2-opponents small {font:11px system-ui;margin-top:3px;}
.g2-opponent-icon {display:grid;place-items:center;flex:0 0 34px;}
.g2-duel-preview {padding:13px!important;}
.g2-duel-preview h2 {font-size:19px;text-align:center;}
.g2-duel-preview h2 span {font:12px system-ui;color:#957c55;}
.g2-duel-preview .g2-table th,.g2-duel-preview .g2-table td {text-align:center;padding:7px 5px;}
.g2-report-row {background:#dfcfad;border:1px solid #ac9670;border-radius:5px;text-align:left;cursor:pointer;}
.g2-report-summary {display:flex;gap:8px 18px;flex-wrap:wrap;font-size:12px;padding:8px 0;margin-bottom:9px;border-block:1px solid #b19a75;}
.g2-report-summary span {white-space:nowrap;}
.g2-loot-grid {display:flex;gap:8px;flex-wrap:wrap;margin:10px 0;}
.g2-loot-grid>div {width:100px;display:grid;gap:4px;text-align:center;font-size:11px;}
.g2-loot-grid img {width:80px;height:80px;object-fit:contain;justify-self:center;}

/* Inventory and economy. */
.g2-inventory-controls {display:flex;flex-wrap:wrap;align-items:center;gap:8px 15px;justify-content:space-between;}
.g2-inventory-controls label {display:flex!important;align-items:center;gap:7px;}
.g2-inventory-controls select {width:135px!important;}
.g2-inventory-grid {display:grid;grid-template-columns:repeat(auto-fill,64px);gap:6px;justify-content:start;}
.g2-item.stone-ui {position:relative;width:64px!important;max-width:64px;height:64px;min-width:0;padding:5px!important;cursor:pointer;border:0;}
.g2-item img {width:100%;height:100%;object-fit:contain;pointer-events:none;}
.g2-item[data-rarity="rare"] {box-shadow:inset 0 0 0 2px #648c9b66;border-radius:7px;}
.g2-item[data-rarity="epic"] {box-shadow:inset 0 0 0 2px #9171aa88;border-radius:7px;}
.g2-item[data-rarity="legendary"] {box-shadow:inset 0 0 0 2px #c59945aa;border-radius:7px;}
.g2-item-level {position:absolute;right:5px;bottom:3px;background:#d7c69bdb;color:#594123;font:700 10px Georgia,serif;padding:1px 4px;border-radius:3px;pointer-events:none;}
.g2-equipped {position:absolute;top:4px;right:5px;color:#7c3626;text-shadow:0 1px #fff2d0;font-size:12px;}
.g2-pagination {display:flex;gap:10px;align-items:center;justify-content:center;margin:12px 0 0;}
.g2-pagination .g2-button {min-height:36px;font-size:12px;}
.g2-upgrade-row {display:grid;grid-template-columns:80px 1fr auto;gap:10px;align-items:center;border-bottom:1px solid #af9770;padding:6px;}
.g2-upgrade-row strong {font-family:Georgia,serif;}
.g2-recipe {display:flex;flex-direction:column;align-items:start;}
.g2-recipe .g2-button {margin-top:auto;}
.g2-costume-grid {display:grid;grid-template-columns:repeat(auto-fit,minmax(145px,1fr));gap:10px;}
.g2-costume {text-align:center;}
.g2-costume>img {height:160px;width:100%;object-fit:contain;object-position:top;}
.g2-costume h2 {font-size:15px!important;}
.g2-shop-offer {display:flex;align-items:center;flex-direction:column;text-align:center;}
.g2-shop-offer>img {width:75px;height:75px;object-fit:contain;}
.g2-shop-offer .g2-button {margin-top:auto;}
.g2-market-row {display:grid;grid-template-columns:60px minmax(100px,1fr) auto auto;align-items:center;gap:10px;padding:8px;border-bottom:1px solid #af9770;}
.g2-market-row>img {height:60px;width:60px;object-fit:contain;}
.g2-quest {display:flex;align-items:center;gap:10px;justify-content:space-between;padding:12px!important;}
.g2-quest small {display:block;color:#7a603e;margin-top:5px;}
.g2-quest h2 {font-size:12px!important;}

/* Native modal: focus, Escape and backdrop belong to the browser. */
.g2-dialog {position:fixed;inset:0;margin:auto;max-width:min(660px,94vw);max-height:90dvh;width:calc(100vw - 28px);padding:24px 14px 14px;border:2px solid #9d8055;border-radius:10px;background:linear-gradient(135deg,#e3d4b0,#cbbb99);color:#4d3b26;box-shadow:0 14px 50px #0009;font:12px/1.4 system-ui;overflow:auto;scrollbar-width:thin;scrollbar-color:#88754c99 transparent;}
.g2-dialog::backdrop {background:#0a1017b3;backdrop-filter:blur(2px);}
.g2-dialog-close {position:absolute;right:6px;top:4px;width:38px;height:38px;font-size:26px;line-height:1;border:0;color:#735535;background:transparent;cursor:pointer;}
.g2-item-detail {display:grid;grid-template-columns:140px 1fr;gap:15px;padding-top:10px;}
.g2-detail-art {width:140px;height:170px;object-fit:contain;}
.g2-item-stats,.g2-comparison {display:flex;flex-wrap:wrap;gap:7px 13px;font-size:13px;margin:10px 0;}
.g2-item-detail .g2-action-line {margin-top:13px;}
.g2-item-detail .g2-button {min-height:40px;padding:7px 10px;font-size:12px;}
.g2-dialog form .g2-button {margin-top:5px;}
/* Landscape encounters put target selection and the primary action first. */
.g2-sr-only {position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;}
.g2-scroll:has(> .g2-expeditions-page) {padding-top:20px;}
.g2-expeditions-heading {display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 5px;min-height:44px;}
.g2-expeditions-heading h1 {font:700 20px/1.15 Georgia,serif;margin:0;color:#4d3a23;}
.g2-expeditions-heading>div>span {font-size:11px;color:#756249;}
#game-runtime .g2-region-select {margin:0;width:52%;max-width:360px;min-width:170px;}
#game-runtime .g2-region-select select {min-height:44px;font-size:12px;padding:6px;}
.g2-expeditions-toolbar {display:flex;align-items:center;justify-content:space-between;gap:7px;margin-bottom:6px;}
.g2-expeditions-toolbar .g2-tabs {flex:0 0 auto;margin:0;flex-wrap:nowrap;}
.g2-expeditions-toolbar .g2-tabs .g2-button {min-height:44px;}
.g2-expeditions-toolbar .g2-energy-line {margin:0;justify-content:end;gap:6px;min-width:0;}
.g2-expeditions-toolbar .g2-energy-line>.g2-button {min-height:44px;padding:6px 9px;white-space:nowrap;}
.g2-expeditions-toolbar .g2-timer {font-size:10px;flex-wrap:wrap;max-width:75px;}
.g2-expedition-workspace {min-height:0;}
.g2-expedition-workspace.g2-with-map {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px;align-items:start;}
.g2-expeditions-page .g2-map {height:176px;margin:0;}
.g2-expeditions-page .g2-map-pin {width:44px;height:44px;font-size:12px;}
.g2-expeditions-page .g2-enemy-list {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;}
.g2-expeditions-page .g2-enemy-list .g2-button {min-width:0;min-height:54px;display:flex;flex-direction:column;gap:2px;padding:5px 6px;line-height:1.15;font-size:11px;}
.g2-enemy-title {display:flex;align-items:center;justify-content:center;gap:4px;}
.g2-enemy-title strong {font-weight:600;}
.g2-expeditions-page .g2-enemy-list small {font-size:10px;}
.g2-with-map .g2-enemy-list {grid-template-columns:repeat(2,minmax(0,1fr));}
.g2-encounter-action {display:flex;align-items:center;gap:8px;justify-content:space-between;margin-top:6px;min-height:44px;}
.g2-encounter-action>div {font-size:11px;color:#735c3c;}
.g2-encounter-action small {display:block;font-size:10px;max-width:270px;}
.g2-encounter-action>.g2-button {flex:0 0 auto;min-height:44px;font-size:12px;}
.g2-encounter-action>.g2-timer,.g2-encounter-action>.g2-ready {font-size:11px;}
#game-runtime .g2-expedition-info {margin-top:7px;padding:4px 0;border-color:#b6a079;font-size:11px;color:#7c674a;}
#game-runtime .g2-expedition-info summary {min-height:28px;}
.g2-dungeon-heading {display:flex;align-items:baseline;justify-content:space-between;gap:10px;}
.g2-dungeon-heading span {font-size:11px;}
.g2-dungeon-heading h3 {margin:0;}
.g2-expeditions-page .g2-dungeon-stages {margin:7px 0;}
@media(max-width:700px){
  .g2-expeditions-toolbar .g2-timer {display:none;}
  .g2-expeditions-toolbar .g2-button {font-size:11px;padding-inline:8px;}
  .g2-expedition-workspace.g2-with-map {grid-template-columns:1fr;}
  .g2-expeditions-page .g2-enemy-list {grid-template-columns:repeat(4,minmax(0,1fr));}
  .g2-expeditions-page .g2-enemy-list .stone-icon {display:none;}
  .g2-encounter-action {gap:5px;}
  .g2-encounter-action>.g2-button {padding-inline:9px;}
}
@media(max-width:900px){
  .g2-expedition-detail {grid-template-columns:1fr;}
  .g2-expedition-detail>div:first-child p {display:none;}
  .g2-region-list .g2-button {flex-basis:105px;}
  .g2-three-columns {grid-template-columns:repeat(3,minmax(135px,1fr));}
}
@media(max-width:580px){
  .g2-split,.g2-duel-layout {grid-template-columns:1fr;}
  .g2-three-columns {grid-template-columns:1fr;}
  .g2-market-row {grid-template-columns:48px 1fr auto;gap:6px;}
  .g2-market-row>img {width:48px;height:48px;}
  .g2-market-row>.g2-button {grid-column:2/4;}
  .g2-item-detail {grid-template-columns:90px 1fr;}
  .g2-detail-art {width:90px;height:120px;}
  .g2-item-detail .g2-action-line {grid-column:1/-1;}
  .g2-tabs {gap:4px;}
  .g2-tabs .g2-button {padding:5px 8px;font-size:11px;}
}

/* One compact training surface: all five decisions stay visible in landscape. */
.g2-scroll:has(> .g2-training-page) {padding:16px 8px 6px;overflow:hidden;}
.g2-training-page {height:100%;min-height:0;display:flex;flex-direction:column;}
.g2-training-page .g2-training-list {display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;flex:1;min-height:0;max-height:240px;}
.g2-training-list .g2-training-row {display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:40px minmax(0,1fr) 20px 22px 44px;gap:3px;min-width:0;min-height:0;padding:8px!important;text-align:center;align-items:center;}
.g2-stat-heading {display:grid;justify-items:center;gap:2px;}
.g2-stat-heading .g2-stat-symbol {display:flex;align-items:center;justify-content:center;}
.g2-training-list .g2-stat-heading strong {font:700 12px/1.15 Georgia,serif;white-space:nowrap;}
.g2-training-effects {list-style:none;padding:0;margin:2px 0 0;text-align:left;align-self:start;color:#685437;font:10.5px/1.25 system-ui,sans-serif;}
.g2-training-effects li {position:relative;padding-left:8px;margin:0 0 3px;}
.g2-training-effects li::before {content:'–';position:absolute;left:0;}
.g2-training-list .g2-stat-value {font:700 14px/1.1 Georgia,serif;white-space:nowrap;}
.g2-training-list .g2-stat-value small {font:10px/1.1 system-ui;color:#836d50;}
.g2-training-list .g2-gold {display:flex;align-items:center;gap:4px;justify-content:center;font:11px/1.2 system-ui;min-width:0;}
.g2-training-coin {display:block;object-fit:contain;width:20px;height:20px;flex:0 0 20px;}
.g2-training-list .g2-training-row .g2-button {display:flex;width:100%!important;min-height:44px;height:44px;padding:3px!important;border:0;border-radius:0;background:var(--stone-code-skin) center/100% 100% no-repeat;box-shadow:none;font:700 10px/1.1 Georgia,serif;letter-spacing:0;white-space:nowrap;grid-column:auto;grid-row:auto;}
.g2-training-list .g2-training-row .g2-button:disabled {color:#7b684c!important;}
.g2-training-list .g2-training-row .g2-button:focus:not(:focus-visible) {outline:0;}
.g2-training-list .g2-training-row .g2-gold {grid-column:auto;grid-row:auto;}
.g2-scroll::-webkit-scrollbar,.g2-dialog::-webkit-scrollbar,.g2-region-list::-webkit-scrollbar {width:5px;height:5px;background:transparent;}
.g2-scroll::-webkit-scrollbar-track,.g2-dialog::-webkit-scrollbar-track,.g2-region-list::-webkit-scrollbar-track {background:transparent;border:0;box-shadow:none;}
.g2-scroll::-webkit-scrollbar-thumb,.g2-dialog::-webkit-scrollbar-thumb,.g2-region-list::-webkit-scrollbar-thumb {background:#88754c99;border:0;border-radius:8px;}
.g2-scroll::-webkit-scrollbar-button,.g2-dialog::-webkit-scrollbar-button,.g2-region-list::-webkit-scrollbar-button {display:none;width:0;height:0;}
.g2-scroll::-webkit-scrollbar-corner,.g2-dialog::-webkit-scrollbar-corner {background:transparent;}
@supports selector(::-webkit-scrollbar){
  /* Chromium ignores WebKit scrollbar parts when standard colours are set. */
  #game-runtime :is(.g2-scroll,.g2-dialog,.g2-region-list,.g2-opponents,.g2-duel-preview) {scrollbar-width:auto;scrollbar-color:auto;}
  :is(.g2-scroll,.g2-dialog,.g2-region-list,.g2-opponents,.g2-duel-preview)::-webkit-scrollbar {width:5px;height:5px;background:transparent;}
  :is(.g2-scroll,.g2-dialog,.g2-region-list,.g2-opponents,.g2-duel-preview)::-webkit-scrollbar-track {background:transparent;box-shadow:none;border:0;}
  :is(.g2-scroll,.g2-dialog,.g2-region-list,.g2-opponents,.g2-duel-preview)::-webkit-scrollbar-thumb {background:#88754c99;border:0;border-radius:8px;}
  :is(.g2-scroll,.g2-dialog,.g2-region-list,.g2-opponents,.g2-duel-preview)::-webkit-scrollbar-button {display:none;width:0;height:0;}
}
.g2-forge-fields {display:grid;grid-template-columns:minmax(0,1fr) 86px;gap:10px;}
#game-runtime .g2-forge-fields label {margin:0;}
.g2-forge-form .g2-action-line {margin-top:6px;gap:5px 10px;}
.g2-forge-form .g2-costs {font-size:11px;}
#game-runtime .g2-forge-help {font-size:11px;margin-top:6px;padding:3px 0;}
.g2-forge-help summary {min-height:28px!important;}
.g2-expeditions-heading h1 {font-size:14px;}
#game-runtime .g2-duel-preview h2 {font-size:13px;}
.g2-scroll:has(> .g2-arena-page) {padding-top:16px;}
.g2-arena-page {height:100%;min-height:0;display:flex;flex-direction:column;gap:5px;}
.g2-arena-toolbar {display:flex;align-items:center;justify-content:space-between;gap:8px;flex:0 0 auto;}
.g2-arena-toolbar .g2-heading,.g2-arena-toolbar .g2-tabs {margin:0;}
.g2-arena-toolbar .g2-tabs {flex-wrap:nowrap;gap:4px;}
.g2-arena-toolbar .g2-tabs .g2-button {font-size:11px;padding:5px 8px;min-height:36px;}
.g2-arena-page .g2-duel-layout {flex:1;min-height:0;grid-template-columns:minmax(0,.9fr) minmax(0,1.3fr);gap:8px;}
.g2-arena-page .g2-opponents {overflow:auto;min-height:0;gap:4px;scrollbar-width:thin;scrollbar-color:#88754c99 transparent;}
.g2-arena-page .g2-opponents>.g2-button {min-height:44px;padding:5px 7px;gap:5px;font-size:12px;}
.g2-arena-page .g2-opponents small {font-size:10px;}
.g2-arena-page .g2-opponent-icon {flex-basis:24px;}
.g2-arena-page .g2-duel-preview {overflow:auto;min-height:0;padding:8px!important;scrollbar-width:thin;scrollbar-color:#88754c99 transparent;}
#game-runtime .g2-duel-preview h2 {white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:0 0 2px;}
#game-runtime .g2-duel-key {font-size:10px;text-align:center;margin:1px 0 4px;}
.g2-duel-stats {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;}
.g2-duel-stats>div {display:grid;justify-items:center;gap:2px;padding:4px 2px;border-block:1px solid #b8a37b;}
.g2-duel-stats span {font-size:11px;}
.g2-duel-stats strong {font:700 16px/1.1 Georgia,serif;}
.g2-duel-stats small {font-size:12px;color:#80674b;}
.g2-duel-preview .g2-action-line {margin-top:5px;gap:4px;font-size:11px;}
.g2-duel-preview .g2-action-line>.g2-button {font-size:12px;padding:6px 10px;}
#game-runtime .g2-party-note {font-size:10px;margin:4px 0;}
@media(max-height:360px) and (orientation:landscape){
  .g2-scroll:has(> .g2-training-page) {padding-top:13px;padding-bottom:4px;}
  .g2-training-list .g2-training-row {grid-template-rows:32px minmax(0,1fr) 18px 18px 44px;padding:4px!important;gap:2px;}
  .g2-stat-heading {gap:1px;}
  .g2-stat-heading .stone-icon {width:18px;height:18px;}
  .g2-training-list .g2-stat-heading strong {font-size:10.5px;}
  .g2-training-effects {font-size:9.5px;line-height:1.15;margin-top:0;}
  .g2-training-effects li {margin-bottom:2px;}
  .g2-training-list .g2-training-row .g2-button {font-size:9px;}
  .g2-training-coin {width:18px;height:18px;flex-basis:18px;}
  .g2-training-list .g2-stat-value {font-size:14px;}
  #game-runtime .g2-duel-key {display:none;}
  .g2-duel-stats>div {padding:2px 0;gap:1px;}
  .g2-duel-preview .g2-action-line {margin-top:3px;}
}

/* Campaign journal and in-place results share the same stable scene frame. */
.g2-x-detail-dialog {max-width:min(660px,94vw);font-size:11px;padding-top:28px;}
.g2-x-detail-dialog .g2-dialog-close {width:44px;height:44px;top:0;right:0;}
.g2-x-detail-title {padding-right:30px;margin-bottom:10px;}
.g2-x-detail-title h2 {font-size:15px;margin:0 0 3px;}
.g2-x-detail-title>span {font-size:11px;color:#786244;}
.g2-x-detail-grid {display:grid;grid-template-columns:112px minmax(0,1fr);gap:12px;align-items:start;}
.g2-x-detail-image {display:block;width:112px;height:112px;overflow:hidden;border-radius:4px;}
.g2-x-detail-image>.g2-x-encounter-art {display:block;width:100%;height:100%;}
.g2-x-detail-values {margin:0;}
.g2-x-detail-values>div {display:grid;grid-template-columns:98px minmax(0,1fr);gap:6px;padding:3px 0;border-bottom:1px solid #ae97734d;}
.g2-x-detail-values dt {color:#786244;}
.g2-x-detail-values dd {margin:0;font-weight:600;}
.g2-x-detail-values dd small {font-size:10px;font-weight:400;}
.g2-x-detail-note {font-size:10px;color:#756046;}
.g2-x-detail-drops {display:grid;gap:3px;margin:8px 0;padding:7px 0;border-block:1px solid #ae977366;}
.g2-training-detail-title {display:flex;align-items:center;gap:10px;margin:0 30px 12px 0;color:#685237;}
.g2-training-detail-title h2 {font-size:16px;margin:0 0 2px;}
.g2-training-detail-title span {color:#7b6547;font-size:11px;}
.g2-training-detail-effects {margin:8px 0 12px;padding-left:18px;line-height:1.6;}
.g2-training-detail-cost {display:flex;align-items:center;gap:5px;}
.g2-training-detail-pending {color:#7b6547;}
.g2-character-stat-help>p {font-size:11px;color:#756147;}
.g2-character-stat-help article {padding:6px 0;border-bottom:1px solid #ad98704d;}
.g2-character-stat-help article>div {display:flex;justify-content:space-between;gap:12px;font-size:12px;}
.g2-character-stat-help article>p {margin:4px 0!important;font-size:11px;color:#786449;}
/* Read-only equipment details overlay the scene; opening it never changes the grid. */
.g2-e-detail-dialog {width:min(460px,calc(100vw - 24px));max-width:460px;max-height:min(390px,90dvh);padding:12px;font-size:11px;line-height:1.3;}
.g2-e-detail-dialog .g2-dialog-close {top:0;right:0;width:44px;height:44px;font-size:26px;}
.g2-e-item-detail>header {display:grid;grid-template-columns:68px minmax(0,1fr);align-items:center;gap:9px;padding-right:36px;min-width:0;}
.g2-e-item-detail>header>img {display:block;width:68px;height:68px;object-fit:contain;}
#game-runtime .g2-e-item-detail h2 {margin:0 0 4px;font:700 14px/1.2 Georgia,serif;overflow-wrap:anywhere;}
#game-runtime .g2-e-item-detail>header p {margin:3px 0;font-size:10px;}
.g2-e-detail-stats {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 12px;margin:8px 0;}
.g2-e-detail-stats>div {display:flex;justify-content:space-between;gap:8px;padding:4px 0;border-bottom:1px solid #ac966c66;}
.g2-e-detail-stats dt {color:#786044;}
.g2-e-detail-stats dd {margin:0;font:700 12px/1.2 Georgia,serif;}
#game-runtime .g2-e-detail-comparison h3 {margin:5px 0;font-size:11px;}
.g2-e-detail-comparison>div {display:flex;flex-wrap:wrap;gap:4px 12px;font-size:10px;}
.g2-e-item-detail>footer {display:grid;gap:3px;border-top:1px solid #ac966c66;margin-top:8px;padding-top:7px;font-size:10px;color:#786044;}
.g2-e-utility-detail {padding:8px 36px 0 0;}
.g2-e-utility-detail h2 {font-size:14px;}
.g2-e-utility-detail p {font-size:11px;}
.g2-e-page [data-equipment-item-id] {-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-y;}
@media(max-height:360px){
  .g2-e-detail-dialog {padding:10px;max-height:92dvh;}
  .g2-e-item-detail>header {grid-template-columns:52px minmax(0,1fr);gap:7px;}
  .g2-e-item-detail>header>img {width:52px;height:52px;}
  .g2-e-detail-stats {margin:5px 0;}
  .g2-e-detail-stats>div {padding:3px 0;}
}
@media(max-width:600px){
  .g2-x-detail-grid {grid-template-columns:88px minmax(0,1fr);gap:9px;}
  .g2-x-detail-image {width:88px;height:88px;}
  .g2-x-detail-values>div {grid-template-columns:88px minmax(0,1fr);font-size:10px;}
}
.g2-scroll:has(> .g2-quests-page) {padding-top:16px;}
.g2-quest-toolbar {display:flex;align-items:center;justify-content:space-between;gap:7px;margin-bottom:6px;}
.g2-quest-toolbar .g2-tabs {margin:0;gap:3px;flex-wrap:nowrap;}
.g2-quest-toolbar .g2-tabs .g2-button {font-size:10px;padding:4px 7px;min-height:36px;}
#game-runtime .g2-quest-chapter {margin:0;flex:0 1 175px;min-width:145px;}
#game-runtime .g2-quest-chapter select {min-height:36px;font-size:10px;padding:5px;}
.g2-quest-list {display:grid;gap:5px;}
.g2-quest-list .g2-quest {padding:5px 7px!important;gap:8px;min-height:56px;}
.g2-quest-info {display:grid;gap:4px;text-align:left;min-height:44px;min-width:0;flex:1;border:0;background:transparent;padding:2px;color:#5d462d;cursor:pointer;align-content:center;}
.g2-quest-info strong {font:700 11px/1.2 Georgia,serif;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.g2-quest-info span {font:10px/1.25 system-ui;}
.g2-quest-list .g2-quest>.g2-button {flex:0 0 90px;min-height:44px;font-size:10px;padding:4px!important;}
.g2-quest-locked .g2-quest-info {color:#897957;}
.g2-expeditions-page .g2-enemy-list {position:relative;display:grid;grid-template-columns:none!important;grid-auto-flow:column;grid-auto-columns:110px;gap:5px;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:thin;scrollbar-color:#88754c99 transparent;padding-bottom:5px;}
.g2-expeditions-page .g2-enemy-list .g2-button {min-height:52px;font-size:10.5px;}
.g2-battle-result {min-height:0;display:grid;align-content:start;gap:5px;padding:8px;border:1px solid #aa936e;border-radius:5px;background:#e5d5ad44;}
.g2-battle-result>div:first-child {display:flex;justify-content:space-between;align-items:center;gap:8px;}
.g2-battle-result strong {font:700 13px/1.2 Georgia,serif;}
#game-runtime .g2-battle-result p {font-size:11px;margin:0;}
.g2-result-loot {display:flex;gap:5px;}
.g2-result-loot img {width:42px;height:42px;object-fit:contain;}
.g2-battle-result .g2-action-line {margin-top:2px;}
.g2-battle-result .g2-button {font-size:11px;min-height:36px;padding:4px 8px;}
.g2-inline-item-result {display:flex;align-items:center;gap:8px;margin-top:8px;border-top:1px solid #b09a72;padding-top:6px;}
.g2-inline-item-result>span {display:grid;gap:3px;min-width:0;}
.g2-inline-item-result strong {font-size:12px;}
.g2-inline-item-result small {font-size:10px;color:#7c6749;}
.g2-inline-item-result .g2-button {min-height:36px;font-size:11px;}
@media(max-width:620px){
  #game-runtime .g2-quest-chapter {flex-basis:145px;}
  .g2-quest-toolbar {gap:4px;}
  .g2-quest-toolbar .g2-tabs .g2-button {padding-inline:5px;font-size:9.5px;}
}
