/* Loja em ladrilhos + ficha: a grade mostra muitos itens de uma vez e o selecionado aparece inteiro ao lado. */
#root #stage #overlay .shop-panel.shop-tiles{display:grid;grid-template-columns:minmax(0,1fr) minmax(190px,26%);grid-template-rows:auto auto minmax(0,1fr) auto auto;grid-template-areas:"head head" "cats cats" "grid sheet" "notice notice" "actions actions";gap:8px 10px}
#root #stage #overlay .shop-panel.shop-tiles>.shop-heading{grid-area:head}
#root #stage #overlay .shop-panel.shop-tiles>.shop-categories{grid-area:cats}
#root #stage #overlay .shop-panel.shop-tiles>.shop-grid{grid-area:grid;display:grid;grid-template-columns:repeat(auto-fill,minmax(92px,1fr));grid-auto-rows:min-content;align-content:start;gap:6px;overflow-y:auto;min-height:0}
#root #stage #overlay .shop-panel.shop-tiles>.shop-sheet{grid-area:sheet;min-height:0;overflow-y:auto;overscroll-behavior:contain}
#root #stage #overlay .shop-panel.shop-tiles>.shop-notice{grid-area:notice}
#root #stage #overlay .shop-panel.shop-tiles>.shop-actions{grid-area:actions}
#root #stage #overlay .shop-panel.shop-tiles>.shop-grid>.shop-section{grid-column:1/-1;margin:2px 0 0}
/* Ladrilho: ícone, nome e preço. */
#root #stage #overlay .shop-tiles .shop-grid .shop-card{display:grid;grid-template-rows:auto auto;justify-items:center;align-content:start;gap:4px;padding:6px 4px;min-height:0;height:auto;cursor:pointer;text-align:center;border:2px solid #34506a;background:#132238}
#root #stage #overlay .shop-tiles .shop-grid .shop-card.selected{border-color:var(--shop-accent,#ffe087);background:color-mix(in srgb,var(--shop-accent,#ffe087) 16%,#132238);box-shadow:inset 0 -3px 0 var(--shop-accent,#ffe087)}
#root #stage #overlay .shop-tiles .shop-grid .shop-card:focus-visible{outline:3px solid #ffe087;outline-offset:2px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-item-heading{display:flex;flex-direction:column;align-items:center;gap:3px;width:100%}
#root #stage #overlay .shop-tiles .shop-grid .shop-card :is(.shop-effect,.shop-card-info,.shop-card-footer,p,.consumable-meta,.shop-owned-tag,.weapon-track-rows){display:none}
#root #stage #overlay .shop-tiles .shop-grid .shop-card :is(.shop-illustrated,.shop-item-icon,.consumable-icon){width:36px;height:36px;flex:none;margin:0}
#root #stage #overlay .shop-tiles .shop-grid .shop-card h3{font-size:7px;line-height:1.3;margin:0;min-height:2.6em;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-price{position:static;font-size:15px;padding:1px 5px;margin:0}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-price .resource-icon{width:14px;height:14px}
/* Ficha: o item inteiro, com descrição aberta. */
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card{display:flex;flex-direction:column;gap:4px;height:auto;min-height:0;box-sizing:border-box;border:2px solid var(--shop-accent,#7bcebc);background:#122035;padding:8px 10px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-card-footer{margin-top:auto}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card details>summary{font-size:15px;min-height:28px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card details p{font-size:16px;line-height:1.15;margin:4px 0}
@media (orientation:landscape) and (max-height:600px) and (pointer:coarse){
 /* Linha de cima continua título · abas · troca · verba; embaixo, grade à esquerda e ficha à direita. */
 #root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles{grid-template-columns:auto minmax(0,1fr) minmax(0,118px) minmax(0,118px);grid-template-rows:auto minmax(0,1fr) auto auto;grid-template-areas:"title cats switch wallet" "grid grid sheet sheet" "notice notice notice notice" "actions actions actions actions"}
 #root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles>.shop-grid{grid-area:grid;grid-template-columns:repeat(auto-fill,minmax(80px,1fr));overflow-y:auto}
 #root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles>.shop-sheet{grid-area:sheet}
 #root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles .shop-switch,#root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles .shop-wallet{justify-self:end}
}
#root #stage #overlay .shop-tiles .shop-grid .shop-card h3{font:15px/1 VT323,monospace;letter-spacing:0;overflow-wrap:normal;word-break:normal;hyphens:manual;text-transform:none}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-card-footer{position:sticky;bottom:-8px;margin:0 -10px -8px;padding:6px 10px 8px;background:#122035;border-top:1px solid #ffffff1a}
#stage .shop-panel:not(.shop-tiles) .consumable-price{display:none}
#root #stage #overlay .shop-tiles .shop-grid .shop-card h3{min-height:2em;max-height:2em;-webkit-line-clamp:2;line-clamp:2}
/* Ficha enxuta: textos menores e o bloco só do tamanho do conteúdo. */
#root #stage #overlay .shop-tiles .shop-sheet{align-self:start;max-height:100%}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card{padding:6px 8px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card h3{font-size:8px;line-height:1.3}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card :is(.shop-effect,.shop-level,.shop-stock){font-size:15px;line-height:1.1}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card :is(.shop-illustrated,.shop-item-icon,.consumable-icon){width:34px;height:34px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-card-footer{position:static;margin:2px 0 0;padding:0;border:0;background:none}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-card-footer button{min-height:40px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card h3{min-height:3em;max-height:3em;-webkit-line-clamp:3;line-clamp:3}
/* V340 · Ladrilho compacto: ícone e preço na mesma linha, nome curto centralizado embaixo, níveis discretos. */
#root #stage #overlay .shop-tiles .shop-grid{grid-template-columns:repeat(auto-fill,minmax(84px,1fr));gap:5px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card{gap:0;padding:4px 4px 5px;border-width:1px;box-shadow:none}
#root #stage #overlay .shop-tiles .shop-grid .shop-card.selected{border-width:2px;padding:3px 3px 4px;box-shadow:inset 0 -2px 0 var(--shop-accent,#ffe087)}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-item-heading{display:grid;grid-template-columns:auto auto;grid-template-areas:"icon price" "name name";justify-content:center;align-items:center;gap:2px 5px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-item-heading>:first-child{grid-area:icon;width:28px;height:28px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card :is(.shop-illustrated,.shop-item-icon,.consumable-icon){width:28px;height:28px;font-size:20px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-illustrated{gap:1px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-illustrated .shop-icon-frame{padding:1px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-illustrated .shop-icon-level{height:2px;gap:1px;opacity:.8}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-illustrated .shop-icon-level i{height:2px;box-shadow:none}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-price{grid-area:price;justify-self:start;font:15px/1 VT323,monospace;padding:1px 4px;border-width:1px;gap:2px}
#root #stage #overlay .shop-tiles .shop-grid .shop-card .shop-price.is-max{color:#9cffb8!important;border-color:#4f9b6c;background:#13291f}
#root #stage #overlay .shop-tiles .shop-grid .shop-card h3{grid-area:name;justify-self:stretch;min-height:0;max-height:2.1em;-webkit-line-clamp:2;line-clamp:2;font:15px/1.05 VT323,monospace;text-align:center;margin:0}
#root #stage #overlay .shop-tiles .shop-grid .shop-card :is(.shop-name-full,.weapon-attacks){display:none}
/* Ficha: nome curto em destaque e o completo logo abaixo, menor. */
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card h3{display:grid;gap:2px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-name-short{font-size:10px;line-height:1.3;color:#fff6c2}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-name-full{font:15px/1 VT323,monospace;color:#a9c3d6;letter-spacing:0;text-transform:none}
#root #stage #overlay .shop-tiles .shop-sheet .shop-price.is-max{color:#9cffb8!important;border-color:#4f9b6c;background:#13291f}
/* Ficha da arma: Ataque básico e Especial com ícone próprio; especial travado até o nível 3. */
#root #stage #overlay .shop-sheet .weapon-attacks{display:grid;gap:4px;margin:2px 0}
#root #stage #overlay .shop-sheet .weapon-attack{display:grid;grid-template-columns:24px minmax(0,1fr);gap:6px;align-items:start;padding:4px 6px;background:#0d1830;border-left:3px solid var(--shop-accent,#8fc8ff)}
#root #stage #overlay .shop-sheet .weapon-attack .weapon-attack-icon{width:24px;height:24px;box-sizing:border-box;padding:2px;background:#2a4562;border:1px solid var(--shop-accent,#7da6ab)}
#root #stage #overlay .shop-sheet .weapon-attack.locked .weapon-attack-icon{background:#1d2c3d;border-color:#5c7486}
#root #stage #overlay .shop-sheet .weapon-attack>div{display:grid;gap:1px;min-width:0}
#root #stage #overlay .shop-sheet .weapon-attack strong{font:8px/1.4 'Brasil Arcade',monospace;color:#ffe9a8}
#root #stage #overlay .shop-sheet .weapon-attack span{font:16px/1.05 VT323,monospace;color:#b9f3d8}
#root #stage #overlay .shop-sheet .weapon-attack small{font:15px/1.05 VT323,monospace;color:#ffe28a}
#root #stage #overlay .shop-sheet .weapon-attack.locked{border-left-color:#5c7486;background:#0d183088}
#root #stage #overlay .shop-sheet .weapon-attack.locked strong{color:#c6d3de}
#root #stage #overlay .shop-sheet .weapon-attack.locked span{color:#8ea3b4}
@media (orientation:landscape) and (max-height:600px) and (pointer:coarse){
 /* Celular deitado: ladrilhos mais estreitos e baixos para caber mais itens sem rolar. */
 #root #stage[data-mode=shop] #overlay .shop-panel.compact-shop.shop-tiles>.shop-grid{grid-template-columns:repeat(auto-fill,minmax(70px,1fr));gap:4px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card{padding:2px 2px 3px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card.selected{padding:1px 1px 2px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card .shop-item-heading{gap:1px 3px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card :is(.shop-illustrated,.shop-item-icon,.consumable-icon),#root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card .shop-item-heading>:first-child{width:24px;height:24px;font-size:17px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card .shop-price{font-size:14px;padding:0 3px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-grid .shop-card h3{font-size:14px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-sheet .weapon-attack{grid-template-columns:20px minmax(0,1fr);gap:4px;padding:3px 4px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-sheet .weapon-attack .weapon-attack-icon{width:20px;height:20px}
 #root #stage[data-mode=shop] #overlay .shop-tiles .shop-sheet .weapon-attack span{font-size:15px}
}

#root #stage #overlay .shop-sheet .shop-description{font-size:14px;line-height:1.45;padding:6px 0;margin:0;background:none;border:0;color:#f4edc7}

/* Texto rola; compra e equipamento permanecem na ficha. */
#root #stage #overlay .shop-panel.shop-tiles>.shop-sheet{align-self:stretch;height:100%;overflow:hidden}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card{display:grid;grid-template-columns:minmax(140px,1fr);grid-template-rows:minmax(0,1fr) auto;grid-template-areas:"body" "commands";height:100%;max-height:100%;gap:6px;overflow:hidden}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-body{grid-area:body;min-width:140px;min-height:0;overflow:auto;overscroll-behavior:contain}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card>.shop-card-footer{grid-area:commands;position:static;margin:0;display:flex;flex-wrap:nowrap;gap:6px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-sheet-card .shop-card-footer button{min-height:44px;flex:1 1 0;padding:4px 6px;font:16px/1.2 VT323,monospace}

/* A ficha ocupa uma coluna própria; o título e a descrição usam toda a largura. */
#root #stage #overlay .shop-tiles .shop-sheet .shop-item-heading{grid-template-columns:40px minmax(0,1fr);grid-template-rows:auto auto auto;grid-template-areas:"icon price" "name name" "description description";gap:6px;min-width:140px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-item-heading>:first-child{grid-area:icon}
#root #stage #overlay .shop-tiles .shop-sheet .shop-item-heading>.shop-price{grid-area:price;position:static;justify-self:end}
#root #stage #overlay .shop-tiles .shop-sheet .shop-item-heading>h3{grid-area:name;min-width:140px;overflow-wrap:normal;word-break:normal}
#root #stage #overlay .shop-tiles .shop-sheet .shop-item-heading>.shop-description{grid-area:description;min-width:140px}
#root #stage #overlay .shop-tiles .shop-sheet .shop-card-info{display:flex;flex-direction:column;align-items:stretch;gap:6px}
/* PREPARAR: full labels, dense tiles and a persistent detail viewport. */
#root #stage #overlay .prepare-central .shop-panel.shop-tiles{grid-template-columns:minmax(0,1fr) minmax(220px,30%);grid-template-rows:minmax(0,1fr) auto auto;grid-template-areas:"grid sheet" "notice notice" "actions actions";min-width:0}
#root #stage #overlay .prepare-central .shop-tiles .shop-grid{grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:5px;min-width:0}
#root #stage #overlay .prepare-central .shop-tiles .shop-card{min-height:64px;min-width:0;position:relative}
#root #stage #overlay .prepare-central .shop-tiles .shop-grid .shop-card h3{display:block;max-height:none;overflow:visible;-webkit-line-clamp:unset;line-clamp:unset;font-size:15px;overflow-wrap:anywhere}
#root #stage #overlay .prepare-central .shop-tiles .shop-section{font:15px/1.1 VT323,monospace;padding:2px;margin:0}
#root #stage #overlay .prepare-central .shop-tiles .shop-sheet :is(h3,strong,.shop-name-short){font-size:11px;line-height:1.4}
#root #stage #overlay .prepare-central .shop-tiles .shop-price{color:#ffe278}
#root #stage #overlay .prepare-central .shop-tiles .shop-price.unaffordable{color:#a6adb7;background:#192330;border-color:#687481}
#root #stage #overlay .prepare-central .shop-finance .loan-panel{width:100%;min-width:0;margin:0;padding:4px;box-sizing:border-box}
#root #stage #overlay .prepare-central .shop-finance .loan-options{display:flex;flex-wrap:wrap;min-width:0;padding:0}
#root #stage #overlay .prepare-central .shop-finance .loan-options button{flex:1 1 70px;min-width:0;min-height:40px}
#root #stage #overlay .prepare-central .shop-finance :is(.loan-actions,.loan-head){display:flex;flex-wrap:wrap;min-width:0}
#root #stage #overlay .prepare-central .shop-finance :is(.loan-badge,legend,small){font-size:11px}
#root #stage #overlay .prepare-central .shop-finance .loan-confirm{min-height:40px}
#root #stage #overlay .prepare-central .shop-sheet-card.shop-finance{display:block;overflow:auto}
.prepare-item-icon{width:100%;height:100%;image-rendering:pixelated}
.prepare-new{color:#adffca;background:#153b30;font:11px/1.3 monospace;padding:2px}
.prepare-comparison{display:flex;flex-wrap:wrap;gap:6px;font:15px/1.3 VT323,monospace}
.prepare-comparison .better{color:#9ff0b6}.prepare-comparison .worse{color:#ff9b9b}
@media(max-width:900px){
 #root #stage #overlay .prepare-central .shop-panel.compact-shop.shop-tiles{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(70px,1fr) minmax(84px,42%) auto auto;grid-template-areas:"grid" "sheet" "notice" "actions";gap:4px}
 #root #stage #overlay .prepare-central .shop-panel.compact-shop.shop-tiles>.shop-grid{grid-template-columns:repeat(auto-fill,minmax(88px,1fr))}
 #root #stage #overlay .prepare-central .shop-sheet-card{grid-template-columns:minmax(0,1fr) minmax(110px,25%);grid-template-rows:minmax(0,1fr);grid-template-areas:"body commands";padding:4px}
 #root #stage #overlay .prepare-central .shop-sheet-card>.shop-card-footer{flex-direction:column;overflow:auto}
}
/* QA: the supply SVG is bounded by the same icon box as every item. */
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .shop-card{box-sizing:border-box;height:var(--prepare-tile-height,64px);min-height:var(--prepare-tile-height,64px);max-height:var(--prepare-tile-height,64px);padding:3px;gap:0}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .shop-item-heading>:first-child{width:var(--prepare-item-icon,28px);height:var(--prepare-item-icon,28px);min-width:0;min-height:0;display:block}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .shop-item-heading>:first-child .prepare-item-icon{display:block;width:100%;height:100%;max-width:28px;max-height:28px}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .prepare-new{position:absolute;right:0;top:auto;bottom:0;font-size:11px;line-height:11px;padding:0 2px;pointer-events:none}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .prepare-selected-equipment{display:none}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-price{color:#ffe278!important;font-size:11px!important}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-price.unaffordable{color:#d0a0a0!important}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-sheet .shop-item-icon{display:block;width:28px;height:28px;min-width:0;min-height:0}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .prepare-selected-equipment{display:grid;grid-template-columns:48px minmax(0,1fr);gap:4px;align-items:center}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview{width:48px;height:60px;position:relative}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview .cp-figure-art{width:100%;height:100%;position:relative;isolation:isolate}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview :is(.portrait,.cp-back-weapon){display:block;width:100%;height:100%;object-fit:contain}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview .cp-wear{position:absolute;pointer-events:none}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview .cp-wear-weapon{inset:0;z-index:-1;width:100%;height:100%}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-equipment-preview :is(.cp-wear-special,.cp-wear-mount){width:24px;height:24px;right:0;bottom:0}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-action-price{display:none}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .prepare-comparison{font:11px/1.1 VT323,monospace;gap:2px;align-content:start}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-finance .shop-item-heading small{font:13px/1 VT323,monospace;white-space:nowrap}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet-card.shop-finance{padding:2px}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet-card.shop-finance :is(.shop-item-heading,.prepare-new){display:none}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet-card.shop-finance :is(.shop-sheet-body,.shop-card-info){min-width:0;margin:0;padding:0;gap:0}
@media(max-width:900px){
 #root #stage[data-mode=shop] #overlay{padding:2px}
 #root #stage[data-mode=shop] #overlay .prepare-central{gap:4px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-panel.compact-shop.shop-tiles{padding:2px;grid-template-rows:minmax(0,1fr) var(--prepare-phone-sheet,64px) auto auto;gap:2px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles>.shop-grid{gap:4px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-section{grid-column:var(--prepare-section-column,auto);height:var(--prepare-section-height,64px);display:flex;align-items:center;line-height:12px;padding:0;margin:0;font-size:11px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-sheet-card{grid-template-columns:minmax(0,1fr) minmax(180px,38%);grid-template-rows:minmax(0,1fr);grid-template-areas:"body commands";min-height:0;padding:2px;gap:4px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-sheet-card.shop-finance{display:block}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-card-footer{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:var(--prepare-action-rows,12px 40px);align-content:start;align-items:stretch;min-height:0;gap:2px;margin:0;padding:0}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-card-footer button{grid-row:var(--prepare-action-row,2);grid-column:auto;font:13px/1.1 VT323,monospace;min-height:40px;height:40px;padding:2px;min-width:0}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-card-footer button:only-of-type{grid-column:1/-1}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-action-price{display:flex;grid-column:1/-1;grid-row:var(--prepare-price-row,1);justify-self:start;align-items:center;margin:0;padding:0;border:0;min-height:0;line-height:12px;background:none}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-action-price svg{height:12px;width:12px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-item-heading{display:block;min-width:0;margin:0}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-item-heading>:is(.shop-item-icon,.shop-illustrated,.shop-price,.consumable-icon){display:none}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-item-heading :is(h3,.shop-description){min-width:0;padding:0;margin:0;font:11px/1.1 VT323,monospace}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-summary{display:grid;grid-template-columns:44px minmax(0,1fr);grid-template-rows:auto 1fr;min-height:54px;gap:2px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-summary>.shop-item-heading{grid-column:2;grid-row:1}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-summary .prepare-selected-equipment{display:contents}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-summary .prepare-equipment-preview{grid-column:1;grid-row:1/3;width:42px;height:54px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-summary .prepare-comparison{grid-column:2;grid-row:2}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-sheet-body{min-width:0}
}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-tiles .shop-grid .shop-finance h3{font:11px/11px VT323,monospace!important;text-align:left}
/* Phone details open over the grid; the summary keeps its approved 64px footprint. */
#root #stage[data-mode=shop] #overlay .prepare-central .shop-detail-toggle{display:none}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-health .shop-item-heading{display:grid;grid-template-columns:40px minmax(0,1fr);grid-template-areas:"icon name" "price price" "description description"}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-health .shop-item-heading>:first-child{grid-area:icon;width:34px;height:34px;display:block}
#root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-health .shop-item-heading>h3{grid-area:name;min-width:0;margin:0}
@media(max-width:900px){
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-panel.shop-tiles{position:relative}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-sheet-card{grid-template-columns:minmax(0,1fr) minmax(180px,38%) 72px;grid-template-areas:"body commands toggle"}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-sheet-card.shop-finance{display:grid;grid-template-columns:minmax(0,1fr) 72px;grid-template-areas:"body toggle"}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet .shop-detail-toggle{display:block;grid-area:toggle;align-self:center;min-width:0;min-height:40px;height:40px;padding:2px;font:11px/1.2 VT323,monospace;white-space:normal}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-panel.shop-tiles>.shop-sheet.details-open{position:absolute;grid-area:auto;inset:2px;z-index:10;height:auto;max-height:none;box-shadow:0 -4px 12px #0008}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet.details-open .shop-sheet-card{display:grid;grid-template-columns:minmax(0,1fr) 72px;grid-template-rows:minmax(0,1fr) 54px;grid-template-areas:"body body" "commands toggle"}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet.details-open .shop-sheet-body{min-height:0;max-height:100%;overflow-y:auto;scrollbar-gutter:stable;padding-right:4px}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet.details-open .shop-finance :is(.shop-item-heading,.prepare-new){display:block}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet:not(.details-open) .shop-health .shop-item-heading{display:block}
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-sheet:not(.details-open) .shop-health .shop-item-heading>:first-child{display:none}
}

/* Desvio stays above the scrollable inventory and never occupies the item sheet. */
#root #stage[data-mode=shop] #overlay .prepare-central .shop-panel.compact-shop.shop-tiles:has(>.prepare-finance){grid-template-rows:auto minmax(0,1fr) auto auto;grid-template-areas:"finance finance" "grid sheet" "notice notice" "actions actions"}
#root #stage[data-mode=shop] #overlay .prepare-central .prepare-finance{grid-area:finance;position:relative;display:grid;gap:4px;min-width:0;margin:0;padding:6px 8px;border:2px solid #82cfa0;border-radius:10px;background:#214b3a;color:#ecffe8;text-align:left;box-sizing:border-box;font:14px/1.1 VT323,monospace}
#root #stage[data-mode=shop] #overlay .prepare-finance *{box-sizing:border-box;min-width:0;white-space:normal;text-overflow:clip}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-head{display:flex;align-items:center;gap:6px;padding-right:112px;min-height:40px}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-icon{width:28px;height:28px;flex:0 0 28px}
#root #stage[data-mode=shop] #overlay .prepare-finance h3{margin:0;font:16px/1.1 VT323,monospace;color:#efffdc}
#root #stage[data-mode=shop] #overlay .prepare-finance :is(small,p,.loan-choose,.loan-quote,.loan-status strong){margin:0;font:13px/1.1 VT323,monospace;color:inherit}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-badge{padding:3px;border:1px solid #82cfa0;border-radius:4px;font:11px/1.1 VT323,monospace;color:#efffdc}
#root #stage[data-mode=shop] #overlay .prepare-finance .prepare-finance-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr)) minmax(100px,.8fr);gap:4px}
#root #stage[data-mode=shop] #overlay .prepare-finance button{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:2px;min-height:40px;padding:4px;border:1px solid #82cfa0;border-radius:5px;background:#15382b;color:#ecffe8;font:14px/1.1 VT323,monospace;cursor:pointer}
#root #stage[data-mode=shop] #overlay .prepare-finance button b{font:inherit}
#root #stage[data-mode=shop] #overlay .prepare-finance [aria-pressed=true]{background:#396745;border:2px solid #ffe278}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-confirm{background:#cfedaa;color:#15382b}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-confirm:disabled{opacity:.5}
#root #stage[data-mode=shop] #overlay .prepare-finance :is(button,summary):focus-visible{outline:2px solid #ffe278;outline-offset:1px}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-more{position:absolute;right:6px;top:6px;margin:0;z-index:11}
#root #stage[data-mode=shop] #overlay .prepare-finance summary{display:flex;align-items:center;justify-content:center;width:106px;min-height:40px;cursor:pointer;font:13px/1.1 VT323,monospace;color:#ecffe8}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-help{position:absolute;right:0;top:100%;width:min(440px,calc(100vw - 48px));max-height:40dvh;overflow:auto;padding:10px;border:2px solid #82cfa0;border-radius:6px;background:#15382b;box-shadow:0 4px 12px #0008}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-help p{margin:0 0 8px;font-size:14px}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-status{display:grid;gap:4px}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-meter{height:8px;border:1px solid #82cfa0;background:#10281d}
#root #stage[data-mode=shop] #overlay .prepare-finance .loan-meter i{display:block;height:100%;background:#cfedaa}
@media(max-width:900px){
 #root #stage[data-mode=shop] #overlay .prepare-central .shop-panel.compact-shop.shop-tiles:has(>.prepare-finance){grid-template-rows:auto minmax(0,1fr) var(--prepare-phone-sheet,64px) auto auto;grid-template-areas:"finance" "grid" "sheet" "notice" "actions"}
}
@media(max-width:900px),(max-height:430px){
 #root #stage[data-mode=shop] #overlay .prepare-central .prepare-finance{padding:2px 4px;gap:2px}
 #root #stage[data-mode=shop] #overlay .prepare-finance :is(.loan-choose,.loan-quote,.loan-reputation){display:none}
 /* Spare header width holds the subtitle; wrapping adds at most one short line above the values. */
 #root #stage[data-mode=shop] #overlay .prepare-finance .loan-head{flex-wrap:wrap;column-gap:6px;row-gap:0}
 #root #stage[data-mode=shop] #overlay .prepare-finance .loan-title{display:contents}
 #root #stage[data-mode=shop] #overlay .prepare-finance :is(h3,.loan-badge){flex:none}
 #root #stage[data-mode=shop] #overlay .prepare-finance .loan-title small{order:1;flex:none;white-space:nowrap;font-size:11px}
 #root #stage[data-mode=shop] #overlay .prepare-finance .loan-cost{font-size:11px}
 #root #stage[data-mode=shop] #overlay .prepare-finance .loan-more{top:2px;right:4px}
 #root #stage[data-mode=shop] #overlay .prepare-finance h3{font-size:14px}
 #root #stage[data-mode=shop] #overlay .prepare-finance button{font-size:12px;padding:2px}
}
