.outfitter { --outfitter-line:#665e4c; --outfitter-gold:#efca86; --outfitter-panel:#201d1b; }
.outfitter [data-shelf="vials"] { --shelf-ink:#9ce1dd; --shelf-halo:#2b4b4d; }
.outfitter [data-shelf="healing"] { --shelf-ink:#ffb79c; --shelf-halo:#53382e; }
.outfitter [data-shelf="care"] { --shelf-ink:#b9d996; --shelf-halo:#3b462d; }
.outfitter [data-shelf="remedies"] { --shelf-ink:#d7bcf7; --shelf-halo:#453854; }
body[data-stage-section="Outfitter"] .stage-companion #layout { grid-template-columns:minmax(0,1fr); }
body[data-stage-section="Outfitter"] .stage-companion #layout > #view { min-width:0; grid-column:1; grid-row:1; }
body[data-stage-section="Outfitter"] .stage-companion #layout > :is(#expedition-map,#field-log) { display:none; }
.outfitter-store { display:grid; gap:1rem; }
.outfitter-hero { display:flex; align-items:flex-end; justify-content:space-between; gap:1.25rem; min-height:13rem; padding:clamp(1.2rem,4vw,2.75rem); border:1px solid var(--outfitter-line); border-radius:.85rem; background:linear-gradient(90deg,#211b17 3%,#211b17ba 34%,#211b1730 78%),linear-gradient(0deg,#211b17a8,transparent 80%),url('/battle-backgrounds/town-preview.webp') center 54% / cover; }
.stage-companion #view .outfitter-hero h2 { margin:0; padding:0; border:0; background:none; max-width:23ch; color:#fff3dd; text-transform:none; font:700 clamp(2rem,5vw,3.85rem)/1.02 Georgia,serif; letter-spacing:-.035em; text-wrap:balance; }
.outfitter-hero p { margin:.65rem 0 0; color:#f4e5cb; }
.outfitter-hero .stage-kicker,.outfitter-counter .stage-kicker { margin:0 0 .52rem; color:var(--outfitter-gold); }
.outfitter-wallet { flex:none; min-width:12rem; max-width:100%; display:grid; gap:.22rem; padding:.85rem 1rem; border:1px solid #9f8662; border-radius:.65rem; background:#231d17ed; box-shadow:0 8px 28px #18120e70; }
.outfitter-wallet small { color:#f2c684; font-size:.76rem; letter-spacing:.11em; font-weight:750; }
.outfitter-wallet strong { font-size:1.35rem; color:#fff3dd; font-variant-numeric:tabular-nums; }
.outfitter-wallet span { color:#e6dac7; font-size:.86rem; overflow-wrap:anywhere; }
.outfitter-floor { display:grid; align-items:start; grid-template-columns:minmax(0,1fr) minmax(15.25rem,19rem); gap:1rem; }
.outfitter-shelves { min-width:0; }
.outfitter-shelf-buttons { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:.55rem; }
.outfitter-shelf-buttons button { display:flex; align-items:center; justify-content:flex-start; text-align:left; gap:.65rem; background:linear-gradient(120deg,var(--shelf-halo),var(--outfitter-panel)); padding:.65rem; min-width:0; border:1px solid var(--outfitter-line); border-radius:.55rem; color:#fff0df; }
.outfitter-shelf-buttons button[aria-pressed="true"] { border-color:var(--shelf-ink); box-shadow:inset 0 0 0 1px var(--shelf-ink); }
.outfitter-shelf-buttons small { display:block; font-size:.76rem; margin-top:.2rem; color:#f3e1cc; }
.outfitter-shelf-buttons svg { flex:0 0 1.45rem; width:1.45rem; color:var(--shelf-ink); }
.outfitter-toolbar { display:flex; align-items:flex-end; gap:.7rem; flex-wrap:wrap; }
.outfitter-toolbar button[aria-pressed="true"] { border-color:var(--outfitter-gold); color:var(--outfitter-gold); }
.outfitter-toolbar label { flex:1 1 13rem; margin:0; font-size:.9rem; }
.outfitter-toolbar input { width:100%; min-height:2.4rem; }
[data-shop-catalog] { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,13rem),1fr)); gap:.7rem; }
.outfitter-product { display:flex; flex-direction:column; padding:.8rem; gap:.35rem; min-width:0; border:1px solid var(--outfitter-line); border-radius:.65rem; background:radial-gradient(130px 110px at 15% 0,var(--shelf-halo),transparent),var(--outfitter-panel); }
.outfitter-product-top { display:flex; align-items:center; justify-content:space-between; gap:.35rem; }
.outfitter-product-icon { display:grid; place-items:center; width:2.5rem; height:2.5rem; border-radius:.6rem; background:#1b1815b0; color:var(--shelf-ink); border:1px solid #ffffff42; }
.outfitter-product-icon svg { width:1.45rem; }
.stage-companion #view .outfitter-product h3 { margin:.32rem 0 0; padding:0; border:0; background:none; text-transform:none; color:#fff3dd; font-size:1.1rem; }
.outfitter-product p { margin:0; color:#e6dac7; line-height:1.45; }
.outfitter-product .outfitter-detail { font-weight:650; color:var(--shelf-ink); font-size:.9rem; }
.outfitter-product button { margin-top:auto; align-self:flex-start; padding-inline:.82rem; }
.outfitter-amount { font-weight:700; color:var(--outfitter-gold); font-variant-numeric:tabular-nums; text-align:right; }
.outfitter-empty { grid-column:1/-1; min-height:5rem; }
.outfitter-counter { position:sticky; top:1rem; background:linear-gradient(150deg,#2f251a,var(--outfitter-panel)); font-size:.95rem; }
.outfitter-counter h3 { font-size:1.22rem; }
.outfitter-counter > button { margin-top:.65rem; }
.outfitter-counter [data-shop-total] { border-top:1px solid var(--outfitter-line); margin-top:.65rem; padding-top:.5rem; }
.outfitter-counter [data-shop-total] p { display:flex; gap:.55rem; justify-content:space-between; }
.outfitter-counter [data-shop-op="checkout"] { width:100%; }
.outfitter-short { color:#ffb899; }
.outfitter-foot { display:flex; flex-wrap:wrap; justify-content:space-between; gap:.45rem; padding:.45rem .15rem; color:var(--muted); font-size:.88rem; }
.outfitter-pack { margin-top:1rem; }
.outfitter-head,.outfitter-item { display:flex; align-items:center; justify-content:space-between; gap:.65rem; }
.outfitter-head h2 { margin:0; }
.outfitter-head [data-wallet] { color:var(--outfitter-gold); white-space:nowrap; }
.outfitter-item { min-width:0; flex-wrap:wrap; padding:.5rem 0; border-bottom:1px solid var(--outfitter-line); }
.outfitter-item > div { min-width:0; flex:1 0 100%; overflow-wrap:anywhere; }
.outfitter-item small { display:block; opacity:.85; }
.outfitter-item button { white-space:nowrap; }
.outfitter-line input { width:4.25rem; }
.outfitter [data-shop-status]:empty { display:none; }
.outfitter-rewards output { display:block; margin:.6rem 0; color:#efd999; font-weight:700; }
.outfitter-recipients { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,13rem),1fr)); gap:.45rem; margin:.65rem 0; }
.outfitter-recipients label { display:flex; align-items:center; gap:.4rem; }
@media (max-width:800px) {
  .outfitter-floor { grid-template-columns:minmax(0,1fr); }
  .outfitter-counter { position:static; }
}
@media (max-width:530px) {
  .outfitter-hero { align-items:start; flex-direction:column; }
  .outfitter-shelf-buttons { grid-template-columns:minmax(0,1fr); }
  .outfitter-shelf-buttons small { display:inline; padding-inline-start:.5rem; }
}

.outfitter-treatment { width:min(34rem,calc(100% - 2rem)); }
@media (min-width:531px) and (max-width:1020px) {
  .outfitter-shelf-buttons { grid-template-columns:repeat(2,minmax(0,1fr)); }
}

#layout.outfitter-layout :is(#map-column-resizer,#map-width-tools) { display:none; }


/* Shop chrome follows the selected Scanner palette; shelf accents identify their categories. */
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion .outfitter {
  --outfitter-line: var(--stage-line);
  --outfitter-gold: var(--stage-amber);
  --outfitter-panel: var(--stage-surface-end);
}
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion .outfitter-hero {
  background: linear-gradient(90deg,var(--stage-base) 3%,color-mix(in srgb,var(--stage-base) 75%,transparent) 36%,color-mix(in srgb,var(--stage-base) 29%,transparent) 82%),url('/battle-backgrounds/town-preview.webp') center 54% / cover;
}
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion .outfitter-wallet {
  border-color: var(--stage-line);
  background: var(--stage-rail);
}
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion .outfitter-wallet small { color: var(--stage-amber); }
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion :is(.outfitter-hero h2,.outfitter-hero p,.outfitter-wallet strong,.outfitter-wallet span,.outfitter-product h3,.outfitter-product p:not(.outfitter-detail),.outfitter-shelf-buttons small) { color: var(--stage-paper); }
:root[data-scanner-theme]:not([data-scanner-theme="graphite"]) .stage-companion .outfitter-counter {
  background: linear-gradient(150deg,var(--stage-surface-start),var(--outfitter-panel));
}

/* The licence readout lives in the welcome banner, outside the shelves it reveals. */
.outfitter-hero > div:first-child { min-width:0; }
.outfitter-passport {
  display:flex; align-items:center; gap:.65rem; width:fit-content; max-width:100%; margin-top:.85rem; padding:.36rem .65rem .36rem .4rem;
  border:1px solid var(--outfitter-line); border-radius:.55rem; background:color-mix(in srgb,var(--outfitter-panel) 94%,transparent);
  color:var(--stage-paper,#fff3dd);
}
.outfitter-passport-photo {
  position:relative; display:grid; place-items:center; flex:0 0 2.55rem; width:2.55rem; height:2.8rem;
  overflow:hidden; background:#0b181ecc;
  border:1px solid color-mix(in srgb,var(--outfitter-gold) 65%,var(--outfitter-line)); border-radius:.33rem;
}
.outfitter-passport-photo img { display:block; width:100%; height:100%; min-height:0; object-fit:cover; }
.outfitter-passport-photo img[src$="ranger-service-seal.png"] { object-fit:contain; padding:.22rem; }
.outfitter-passport-photo i {
  display:none; position:absolute; inset:0 0 auto; height:2px; background:var(--outfitter-gold);
  box-shadow:0 0 10px 2px var(--outfitter-gold),0 -10px 19px 3px var(--outfitter-gold);
}
.outfitter-passport-readout { min-width:0; overflow-wrap:anywhere; }
.outfitter-passport-readout > small {
  display:block; color:var(--outfitter-gold); text-transform:uppercase; font-size:.71rem; font-weight:800; letter-spacing:.075em;
}
.outfitter-passport-line { display:grid; align-items:center; text-transform:uppercase; font-size:.82rem; font-weight:750; letter-spacing:.045em; }
.outfitter-passport-line > span { grid-area:1/1; visibility:hidden; }
[data-passport-phase="scan"] [data-passport-check],
[data-passport-phase="rank"] [data-passport-rank],
[data-passport-phase="welcome"] [data-passport-welcome],
[data-passport-phase="verified"] [data-passport-welcome] { visibility:visible; }
.outfitter-store:not([data-passport-phase="verified"]) [data-passport-stamp] { visibility:hidden; }
[data-passport-phase="scan"] .outfitter-passport-photo i,
[data-passport-phase="rank"] .outfitter-passport-photo i { display:block; animation:outfitter-passport-sweep .65s ease-in-out both; }
@keyframes outfitter-passport-sweep { from { transform:translateY(0); opacity:0; } 17%,79% {opacity:1;} to { transform:translateY(2.6rem); opacity:0; } }
.outfitter-floor[aria-busy="true"] { visibility:hidden; }
@media (prefers-reduced-motion:no-preference) {
  [data-passport-phase="verified"] .outfitter-floor { animation:outfitter-shelf-in .14s ease-out both; }
  @keyframes outfitter-shelf-in { from { opacity:0; } }
}
