/* Special cargo and salvage: one full-game information screen, shared custom scrollbar. */
.pq-app .pq-items-dialog { --cargo-gold:#ecd096; --cargo-ink:#082630; color:#e9e4cb; font-size:16pt; }
.pq-app .pq-items-dialog .gr-dialog__body { display:block; width:min(100%,1500px); padding:18px 24px 22px; justify-content:initial; }
.pq-app .pq-items-dialog :where(button,span,p,strong,b,h3,div) { font-size:inherit; }
.pq-items-shell { min-width:0; }
.pq-items-battle { position:sticky; top:-1px; z-index:3; display:grid; grid-template-columns:minmax(150px,1fr) auto; align-items:center; gap:20px; padding:10px 14px; margin:0 0 14px; border:1px solid #87ab9b; border-radius:12px; background:#10363f; box-shadow:0 6px 12px #02192155; }
.pq-items-battle-hull { min-width:0; }.pq-items-battle-hull__row { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:6px 14px; line-height:1.2; }.pq-items-battle-hull__row>span { display:flex; align-items:center; gap:8px; color:#bdd6c1; }.pq-items-battle-hull__row>strong { color:#f0dfb1; font-weight:500; font-variant-numeric:tabular-nums; white-space:nowrap; }
.pq-items-battle-meter { height:8px; margin-top:7px; overflow:hidden; border:1px solid #617f70; border-radius:4px; background:#051e29; }.pq-items-battle-meter>span { display:block; height:100%; background:linear-gradient(90deg,#72b6a5,#b5d2a5); }.pq-items-battle--danger .pq-items-battle-meter>span { background:linear-gradient(90deg,#c46d56,#e5a27a); }
.pq-items-battle-turn { display:flex; align-items:center; justify-content:flex-end; gap:12px; min-width:0; color:#d0d8bd; line-height:1.2; text-align:right; }.pq-items-battle-turn>span { min-width:0; }.pq-items-battle-turn>strong { flex:none; min-width:44px; color:#f2d496; font-weight:600; font-variant-numeric:tabular-nums; }.pq-items-clock--urgent { color:#f2ab86 !important; }.pq-items-battle-turn>strong[hidden] { display:none; }
.pq-items-toolbar { display:flex; align-items:center; justify-content:space-between; gap:18px; margin-bottom:18px; }
.pq-items-tabs { display:flex; gap:8px; min-width:0; }
.pq-app .pq-items-tab { display:flex; align-items:center; justify-content:center; gap:10px; min-height:52px; min-width:44px; padding:10px 16px; border:1px solid #799e92; border-radius:10px; background:#082934; color:#bdcec1; font:inherit; line-height:1.2; cursor:pointer; }
.pq-items-tab>svg { flex:none; }
.pq-items-tab>b { padding:3px 8px; border-radius:6px; background:#c4c39a12; color:#f1d99f; font-weight:500; font-variant-numeric:tabular-nums; white-space:nowrap; }
.pq-app .pq-items-tab[aria-selected=true] { border-color:#ecd096; background:#e4c68d; color:#132f34; box-shadow:inset 0 1px #fff0bc; }
.pq-items-tab[aria-selected=true]>b { background:#082b3620; color:#15353b; }
.pq-items-tab:disabled { opacity:.45; cursor:default; }
.pq-items-capacity { min-width:180px; max-width:260px; flex:0 1 260px; display:grid; gap:8px; color:#b8d1c0; }
.pq-items-capacity>span { text-align:right; line-height:1.2; }
.pq-items-capacity__bar { display:grid; grid-template-columns:repeat(10,minmax(0,1fr)); gap:4px; height:9px; }
.pq-items-capacity__bar>i { border:1px solid #617f77; border-radius:3px; background:#051e29; }
.pq-items-capacity__bar>.is-filled { border-color:#c6ce9a; background:linear-gradient(90deg,#82beac,#e2ce90); }
.pq-items-warning { display:flex; align-items:center; gap:14px; padding:14px 16px; margin-bottom:16px; border:1px solid #d6b274; border-radius:12px; background:#b88b3b15; color:#f4d8a2; }
.pq-items-warning>svg { flex:none; }
.pq-items-warning>span { flex:1; line-height:1.35; }
.pq-items-warning strong { color:#ffe0a6; }
.pq-items-warning>.pq-button { flex:none; }
.pq-items-notice { display:flex; align-items:center; gap:12px; margin-bottom:16px; padding:12px 16px; border:1px solid #719e91; border-radius:10px; color:#bddcca; background:#113d43; line-height:1.35; }
.pq-items-notice[hidden] { display:none; }.pq-items-notice>span { flex:1; min-width:0; overflow-wrap:anywhere; }
.pq-items-notice--error { color:#f4c8ad; background:#573e352e; border-color:#bb8d74; }
.pq-items-layout { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(310px,.9fr); gap:24px; align-items:start; }
.pq-app .pq-items-layout--no-detail { grid-template-columns:minmax(0,1fr); }.pq-item-detail[hidden] { display:none; }
.pq-items-cargo,.pq-item-detail { min-width:0; }
.pq-items-section-title { display:flex; align-items:baseline; justify-content:space-between; gap:16px; margin:0 0 14px; }
.pq-app .pq-items-section-title h3 { margin:0; color:#dcc899; font:inherit; font-weight:500; line-height:1.25; overflow-wrap:anywhere; }
.pq-items-section-title>span { color:#99b9ae; line-height:1.25; }
.pq-items-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.pq-app .pq-item-slot { position:relative; isolation:isolate; display:flex; flex-direction:column; align-items:center; gap:4px; width:100%; min-width:0; min-height:172px; margin:0; padding:10px 8px 14px; border:1px solid #74968b; border-radius:15px; background:radial-gradient(ellipse at 50% 28%,#74b7a01b,transparent 70%),linear-gradient(155deg,#173c44,#08232e); color:#d9dfcc; font:inherit; line-height:1.16; text-align:center; cursor:pointer; transition:border-color .15s,background .15s,transform .15s; }
.pq-item-slot__shine { position:absolute; z-index:-1; inset:0; border-radius:inherit; background:linear-gradient(140deg,#d8e5cb0b,transparent 55%); pointer-events:none; }
.pq-item-slot__art { display:flex; align-items:center; justify-content:center; flex:none; height:110px; width:100%; }
.pq-item-art { display:block; flex:none; max-width:100%; overflow:visible; filter:drop-shadow(0 7px 5px #00151b50); }
.pq-item-slot__name { display:block; min-width:0; width:100%; overflow-wrap:anywhere; }
.pq-item-slot__rarity { position:absolute; top:8px; right:8px; display:flex; color:var(--item-accent,#dfc48b); filter:drop-shadow(0 2px 3px #021e27); }
.pq-item-slot__rarity svg { width:22px; height:22px; }
.pq-item-slot--rare,.pq-item-slot--legendary { border-color:#aa9c7b; }
.pq-app .pq-item-slot--selected { border:2px solid var(--item-accent,#ead096); padding:9px 7px 13px; background:radial-gradient(ellipse at 50% 20%,#becb9326,transparent 80%),#153e45; box-shadow:0 0 0 3px #d2bc8021,inset 0 0 30px #c6ba7610; }
.pq-item-slot:hover { border-color:#e2d1a3; background-color:#17434a; }.pq-item-slot:active { transform:translateY(1px); }
.pq-app .pq-item-slot--empty { justify-content:center; min-height:172px; gap:14px; border:1px dashed #64887c70; background:#08263080; color:#88a89a; cursor:default; }
.pq-item-slot--empty>span:first-child { color:#6f958b; opacity:.6; }
.pq-item-detail { position:sticky; top:0; padding:22px; border:1px solid #a5aa81; border-radius:17px; background:radial-gradient(ellipse at 50% 0,#637c6033,transparent 70%),#092934; box-shadow:inset 0 1px #d7d4ac12; }
.pq-item-detail__identity { display:flex; flex-direction:column; gap:12px; align-items:center; text-align:center; }
.pq-item-detail__art { position:relative; display:flex; align-items:center; justify-content:center; width:190px; height:180px; border-radius:50%; background:radial-gradient(circle,#a5c9a823,transparent 68%); }
.pq-item-detail__art::before { content:''; position:absolute; inset:12px; border:1px solid #b7c79c26; border-radius:50%; }
.pq-item-detail__art::after { content:''; position:absolute; inset:24px; border:1px solid #c6cdad12; border-radius:50%; }
.pq-item-kind { color:var(--item-accent,#d8c48e); text-transform:capitalize; line-height:1.2; }
.pq-app .pq-item-detail h3 { margin:6px 0 0; color:#f0dfb6; font-size:22pt; font-family:Georgia,serif; line-height:1.15; overflow-wrap:anywhere; text-transform:none; letter-spacing:normal; }
.pq-app .pq-item-detail .pq-item-description { margin:16px 0; color:#b8cfc1; line-height:1.45; }
.pq-item-effects { display:grid; gap:9px; margin:18px 0; }
.pq-item-effect { display:grid; grid-template-columns:32px minmax(0,1fr) auto; align-items:center; gap:10px; min-height:44px; padding:9px 12px; border:1px solid #aac3a92b; border-radius:9px; color:#bfd4c2; background:#99b7a509; }
.pq-item-effect strong { color:#f1d697; font-variant-numeric:tabular-nums; white-space:nowrap; }
.pq-item-effect__amount { display:flex; flex-direction:column; align-items:flex-end; gap:3px; }.pq-item-effect__cap { display:block; color:#9ab8a9; font-weight:400; }
.pq-item-effect--damage { color:#efb58f; }.pq-item-effect--hull { color:#a9d6bd; }.pq-item-effect--crew { color:#b7cdee; }.pq-item-effect--supplies { color:#cedba5; }
.pq-item-curio { display:flex; align-items:center; gap:12px; min-height:44px; padding:12px; border:1px solid #bda5d838; border-radius:9px; color:#d0bce4; background:#b9a2d50a; line-height:1.35; }
.pq-item-curio>svg { flex:none; }
.pq-item-actions { display:flex; flex-wrap:wrap; gap:10px; margin-top:18px; }
.pq-app .pq-item-actions .pq-button { display:flex; justify-content:center; align-items:center; gap:10px; flex:1 1 150px; min-width:44px; min-height:52px; padding:10px 12px; font:inherit; line-height:1.2; }
.pq-item-actions .pq-button>svg { flex:none; }
.pq-app .pq-item-toss { background:#17363b; color:#d5bca2; border:1px solid #9a9f83; }
.pq-app .pq-item-detail .pq-item-reason { margin:12px 0 0; color:#aec7bc; font-size:16pt; line-height:1.35; }
.pq-items-empty { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:12px; min-height:180px; padding:20px 12px; text-align:center; color:#9fc3b5; }
.pq-app .pq-items-empty h3 { margin:0; color:#d9ceaa; font-size:19pt; }
.pq-app .pq-items-empty p { margin:0; color:#a8c4b6; line-height:1.4; }
.pq-items-footer { position:sticky; bottom:-1px; z-index:2; display:flex; align-items:center; justify-content:space-between; gap:18px; padding:18px 0 0; margin-top:20px; background:linear-gradient(transparent,#0b2c36 16px); }
.pq-app .pq-items-trash { display:flex; align-items:center; gap:12px; min-height:56px; min-width:44px; padding:10px 16px; border:1px dashed #8a9e8a; border-radius:12px; background:#092630; color:#bbcebc; font:inherit; line-height:1.2; cursor:pointer; }
.pq-items-trash__wave { padding-left:8px; color:#6eaaab; font-size:24pt !important; }
.pq-app .pq-items-trash:disabled { opacity:.48; cursor:default; }
.pq-app .pq-items-done { display:flex; align-items:center; justify-content:center; gap:12px; min-height:56px; min-width:44px; padding:10px 18px; font:inherit; }
.pq-items-dragging .pq-items-trash { border-style:solid; border-color:#f1ca8e; background:#87634533; box-shadow:0 0 24px #c7974d1a; }
.pq-items-trash-ready .pq-items-trash { border-color:#ffe4ac; background:#aa744e55; box-shadow:0 0 0 4px #d9bb8433; }
.pq-app .pq-items-dialog button:disabled { opacity:.48; cursor:default; }
@media (min-width:1250px) { .pq-items-grid { grid-template-columns:repeat(5,minmax(0,1fr)); } }
@media (max-width:1050px) { .pq-items-layout { grid-template-columns:minmax(0,1.35fr) minmax(270px,1fr); gap:18px; }.pq-items-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:9px; }.pq-item-detail { padding:18px; }.pq-item-detail__art { width:150px; height:140px; }.pq-item-detail__art .pq-item-art { width:136px; height:136px; }.pq-app .pq-item-slot { min-height:166px; } }
@media (max-width:760px) { .pq-app .pq-items-dialog .gr-dialog__body { padding:12px 16px 16px; }.pq-items-toolbar { align-items:stretch; flex-wrap:wrap; gap:10px; margin-bottom:14px; }.pq-items-tabs { flex:1 0 100%; }.pq-items-tab { flex:1; }.pq-items-capacity { flex:1; min-width:0; max-width:none; grid-template-columns:auto minmax(80px,1fr); align-items:center; }.pq-items-capacity>span { text-align:left; }.pq-items-layout { grid-template-columns:minmax(0,1fr); gap:16px; }.pq-items-cargo { order:2; }.pq-item-detail { order:1; position:static; padding:16px; }.pq-item-detail__identity { flex-direction:row; align-items:center; text-align:left; gap:16px; }.pq-item-detail__art { width:112px; height:110px; flex:none; }.pq-item-detail__art .pq-item-art { width:108px; height:108px; }.pq-item-effects { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; margin:12px 0; }.pq-item-effect { grid-template-columns:28px minmax(0,1fr); gap:7px; padding:9px; }.pq-item-effect strong { grid-column:2; }.pq-items-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }.pq-item-slot__art { height:94px; }.pq-item-slot__art .pq-item-art { width:92px; height:92px; }.pq-app .pq-item-slot { min-height:148px; }.pq-items-footer { gap:10px; }.pq-items-warning { flex-wrap:wrap; gap:10px; }.pq-items-warning>span { flex:1 1 180px; }.pq-items-warning>.pq-button { margin-left:42px; } }
@media (max-width:420px) { .pq-app .pq-items-dialog .gr-dialog__head { padding:8px 12px; gap:8px; }.pq-app .pq-items-dialog .gr-dialog__head h2 { font-size:20pt; }.pq-app .pq-items-dialog .gr-dialog__body { padding:10px 12px 14px; }.pq-app .pq-items-tab { gap:6px; padding:9px 8px; min-height:48px; }.pq-items-tab>svg { display:none; }.pq-items-tab>b { padding:2px 5px; }.pq-item-detail { padding:12px; }.pq-item-detail__art { width:82px; height:88px; }.pq-item-detail__art .pq-item-art { width:84px; height:84px; }.pq-item-detail__identity { gap:10px; }.pq-app .pq-item-detail h3 { font-size:20pt; }.pq-item-effects { grid-template-columns:minmax(0,1fr); }.pq-item-effect { grid-template-columns:28px minmax(0,1fr) auto; }.pq-item-effect strong { grid-column:auto; }.pq-items-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }.pq-app .pq-items-done,.pq-app .pq-items-trash { padding:10px; gap:8px; }.pq-items-trash__wave { display:none; }.pq-items-footer { align-items:stretch; }.pq-items-footer>button { flex:1; }.pq-items-notice { flex-wrap:wrap; padding:10px; }.pq-item-actions .pq-button { flex-basis:100%; } }
@media (max-height:500px) and (min-width:500px) { .pq-app .pq-items-dialog .gr-dialog__head { padding:4px 14px; }.pq-app .pq-items-dialog .gr-dialog__head h2 { font-size:20pt; }.pq-app .pq-items-dialog .gr-dialog__body { padding:10px 16px; }.pq-items-toolbar { flex-wrap:nowrap; gap:12px; margin-bottom:12px; }.pq-items-tabs { flex:1; }.pq-app .pq-items-tab { min-height:44px; padding:8px 10px; gap:8px; }.pq-items-tab>svg { display:none; }.pq-items-capacity { flex:0 1 150px; display:grid; grid-template-columns:minmax(0,1fr); gap:6px; }.pq-items-capacity>span { text-align:right; }.pq-items-layout { grid-template-columns:minmax(0,1fr) minmax(260px,1.2fr); gap:16px; }.pq-items-cargo { order:initial; }.pq-item-detail { order:initial; padding:12px; position:sticky; }.pq-item-detail__identity { flex-direction:row; gap:10px; text-align:left; }.pq-item-detail__art { width:70px; height:74px; }.pq-item-detail__art .pq-item-art { width:74px; height:74px; }.pq-app .pq-item-detail h3 { font-size:20pt; }.pq-app .pq-item-description { margin:10px 0; }.pq-item-effects { grid-template-columns:minmax(0,1fr); gap:6px; margin:10px 0; }.pq-item-effect { grid-template-columns:28px minmax(0,1fr) auto; min-height:44px; padding:7px 9px; }.pq-item-effect strong { grid-column:auto; }.pq-items-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }.pq-app .pq-item-slot,.pq-app .pq-item-slot--empty { min-height:130px; }.pq-item-slot__art { height:76px; }.pq-item-slot__art .pq-item-art { width:76px; height:76px; }.pq-items-section-title { margin-bottom:8px; }.pq-item-actions { margin-top:10px; gap:8px; }.pq-app .pq-item-actions .pq-button { flex-basis:100%; min-height:44px; padding:8px 10px; }.pq-items-footer { margin-top:12px; padding-top:12px; }.pq-app .pq-items-done,.pq-app .pq-items-trash { min-height:44px; padding:8px 12px; }.pq-items-warning { padding:10px 12px; margin-bottom:12px; }.pq-items-warning>.pq-button { min-height:44px; padding:8px 12px; } }
@media (prefers-reduced-motion:reduce) { .pq-item-slot { transition:none; } }
@media (max-width:420px) { .pq-items-footer>.pq-items-trash { flex:0 0 48px; justify-content:center; padding:8px; }.pq-items-footer>.pq-items-trash>span { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }.pq-items-footer>.pq-items-done { flex:1; } }
/* Leave a real gutter for the common custom rail at every viewport size. */
.pq-app .pq-items-dialog .gr-dialog__body.gr-scroll-needed { padding-right:48px; }
@media (max-width:760px) { .pq-items-warning { flex-wrap:nowrap; padding:10px 12px; gap:10px; }.pq-items-warning>svg { display:none; }.pq-items-warning>span { flex:1; min-width:0; }.pq-items-warning>.pq-button { margin:0; padding:8px 10px; min-height:44px; } }
@media (max-width:420px) { .pq-items-battle { grid-template-columns:minmax(0,1fr) minmax(0,1fr); padding:9px 10px; gap:12px; }.pq-items-battle-hull__row>span>svg { display:none; }.pq-items-battle-turn { display:grid; grid-template-columns:minmax(0,1fr); gap:5px; }.pq-items-battle-turn>strong { min-width:0; } }
@media (max-height:500px) and (min-width:500px) { .pq-items-footer { position:static; }.pq-items-battle { padding:8px 12px; margin-bottom:10px; grid-template-columns:minmax(150px,1fr) auto; }.pq-items-battle-hull__row>span>svg { display:none; } }

/* During short live turns, every carried item is one nearby touch away. */
@media (max-width:650px) and (min-height:501px) {
 .pq-items-dialog--battle .pq-items-cargo { order:0; }
 .pq-items-dialog--battle .pq-item-detail { order:1; }
 .pq-items-dialog--battle .pq-items-grid { grid-template-columns:repeat(5,minmax(0,1fr)); gap:6px; }
 .pq-app .pq-items-dialog--battle .pq-item-slot { min-height:56px; padding:4px; gap:0; border-radius:9px; }
 .pq-app .pq-items-dialog--battle .pq-item-slot--selected { padding:3px; }
 .pq-items-dialog--battle .pq-item-slot__art { width:100%; height:44px; }
 .pq-items-dialog--battle .pq-item-slot__art .pq-item-art { width:44px; height:44px; filter:none; }
 .pq-items-dialog--battle .pq-item-slot__name,.pq-items-dialog--battle .pq-item-slot--empty>span:last-child { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
 .pq-items-dialog--battle .pq-item-slot__rarity { top:1px; right:1px; }
 .pq-items-dialog--battle .pq-item-slot__rarity svg { width:14px; height:14px; }
 .pq-items-dialog--battle .pq-item-slot--empty { gap:0; }
 .pq-items-dialog--battle .pq-item-slot--empty>span:first-child svg { width:28px; height:28px; }
 .pq-app .pq-items-dialog--battle .pq-item-detail .pq-item-description { display:none; }
}

/* The current battle item has one persistent Use action, never a second copy. */
.pq-app .pq-items-use { min-height:56px; min-width:44px; padding:10px 16px; gap:10px; font:inherit; }
@media (max-width:650px) {
 .pq-items-dialog--battle .pq-items-footer>.pq-items-trash { display:none; }
 .pq-items-dialog--battle .pq-items-footer>.pq-items-use,.pq-items-dialog--battle .pq-items-footer>.pq-items-done { flex:1 1 0; min-width:0; padding:10px; gap:8px; }
 .pq-items-dialog--battle .pq-items-footer>.pq-items-use>svg,.pq-items-dialog--battle .pq-items-footer>.pq-items-done>svg { display:none; }
}

@media (max-width:650px) and (min-height:501px) {
 .pq-items-dialog--battle.pq-items-dialog--single .pq-items-toolbar { display:none; }
 .pq-items-dialog--battle .pq-item-detail__art,.pq-items-dialog--battle .pq-item-kind { display:none; }
 .pq-items-dialog--battle .pq-item-detail__identity { display:block; }
 .pq-app .pq-items-dialog--battle .pq-item-detail h3 { margin:0; }
 .pq-items-dialog--battle .pq-item-effects { margin:10px 0; }
}
