/* Premium customer surfaces: blue/cyan glass with compact, readable controls. */
:root{
  --premium-blue:#0c5bb8;--premium-cyan:#16a9d8;--premium-ink:#071a31;
  --premium-line:color-mix(in srgb,var(--acc) 28%,var(--line));
  --premium-glow:0 14px 32px rgb(12 91 184/.12),inset 0 1px 0 rgb(255 255 255/.75);
}

#view-market .market-search-bar{
  display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:12px;
  margin:2px 0 4px;padding:10px 12px;border:1px solid var(--premium-line);border-radius:14px;
  background:linear-gradient(110deg,color-mix(in srgb,var(--card) 96%,#d6f4ff),var(--card));box-shadow:var(--premium-glow);
}
#view-market .market-search-bar>label{font-size:12px;font-weight:600;color:var(--copy);white-space:nowrap}
#view-market .market-search-field{display:flex;align-items:center;gap:8px;min-width:0}
#view-market #pool-market-search{width:100%;min-width:0;height:44px;padding:0 13px;border:1px solid var(--line);border-radius:10px;background:var(--bg);color:var(--fg);outline-offset:2px}
#view-market #pool-market-search:focus-visible{border-color:var(--acc);box-shadow:0 0 0 3px color-mix(in srgb,var(--acc) 22%,transparent)}
#view-market #pool-market-search-clear{min-height:44px;white-space:nowrap}
#view-market #pool-market-search-status{font-size:12px;color:var(--dim);white-space:nowrap}
#view-market .pool-card{border-color:color-mix(in srgb,var(--acc) 20%,var(--line));box-shadow:0 8px 22px rgb(12 91 184/.08),inset 0 1px 0 rgb(255 255 255/.7)}
#view-market .pool-card:hover{border-color:color-mix(in srgb,var(--premium-cyan) 62%,var(--line));box-shadow:0 14px 28px rgb(12 91 184/.14),inset 0 1px 0 rgb(255 255 255/.8)}
#view-market .pool-media-fallback{display:flex;align-items:center;gap:10px;min-height:100%;padding:12px 16px;background:linear-gradient(125deg,#092543,#0f4b73 62%,#16a9d8);color:#eaf9ff}
#view-market .pool-card-media .pool-media-fallback > img.product-brand-icon{position:static;display:block;flex:0 0 40px;max-width:40px;max-height:40px;min-height:0;transform:none!important;width:40px;height:40px;padding:6px;border-radius:10px;background:#f8fdff;object-fit:contain}
#view-market .pool-media-fallback-label{font-size:15px;font-weight:600;letter-spacing:.01em}
#view-wallet .card,#view-delivery .card{border-color:color-mix(in srgb,var(--acc) 22%,var(--line));box-shadow:0 8px 24px rgb(12 91 184/.08),inset 0 1px 0 rgb(255 255 255/.72)}
#view-wallet .wallet-balance{border:1px solid color-mix(in srgb,var(--premium-cyan) 38%,var(--line));background:linear-gradient(120deg,#0b3258,#0d6d9a 72%,#16a9d8);color:#effcff;border-radius:14px;padding:16px 18px;font-size:clamp(1.45rem,4vw,2rem);font-weight:600;box-shadow:0 10px 26px rgb(12 91 184/.2),inset 0 1px 0 #ffffff38}
#view-wallet .wallet-denoms .mini,#view-wallet .wallet-rails .mini{min-height:46px;border-color:var(--premium-line);background:linear-gradient(140deg,var(--card),color-mix(in srgb,var(--acc) 5%,var(--card)))}
#view-wallet .wallet-denoms .mini.on,#view-wallet .wallet-rails .mini.on{border-color:var(--acc);box-shadow:0 0 0 2px color-mix(in srgb,var(--acc) 15%,transparent),inset 3px 0 0 var(--acc)}
#view-wallet #pool-wallet-pay{border-top:3px solid var(--premium-cyan);background:linear-gradient(135deg,var(--card),color-mix(in srgb,var(--premium-cyan) 5%,var(--card)))}
#view-wallet #pool-wallet-pay h2,#view-delivery .delivery-pane-title{color:var(--premium-blue)}
#view-delivery .pool-delivery-fleet-line{border:1px solid color-mix(in srgb,var(--premium-cyan) 42%,var(--line));border-radius:14px;background:linear-gradient(110deg,#092b4b,#0f6d98);color:#effcff;box-shadow:0 8px 20px rgb(12 91 184/.18)}
#view-delivery #pool-delivery-list .pool-order-row{border-color:color-mix(in srgb,var(--acc) 20%,var(--line));border-radius:11px;transition:border-color .16s ease,box-shadow .16s ease}
#view-delivery #pool-delivery-list .pool-order-row:hover{border-color:var(--premium-cyan);box-shadow:0 8px 18px rgb(12 91 184/.1)}
#pool-account-menu{border-color:color-mix(in srgb,var(--acc) 30%,var(--line));box-shadow:0 18px 42px rgb(7 34 66/.22),inset 0 1px 0 rgb(255 255 255/.7)}
#pool-account-menu .pool-account-line{border-color:color-mix(in srgb,var(--acc) 20%,var(--line));border-radius:10px}
/* Balance remains legible over its always-dark banking surface. */
#view-wallet .wallet-balance :is(b,.unit,.pool-wallet-unit){color:#effcff}
:root[data-theme="dark"]{--premium-blue:#8eceff;--premium-glow:0 14px 32px rgb(0 12 24/.3),inset 0 1px 0 rgb(134 199 255/.15)}
/* Dark feature surfaces carry their own readable text in both themes. */
body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback-label{color:#effbff;letter-spacing:.04em}
body[data-view="delivery"] #view-delivery .pool-delivery-fleet-line :is(.pool-delivery-fleet-kicker,.pool-delivery-fleet-note){color:#daf4ff}
body[data-view="wallet"] #view-wallet .wallet-balance{background:linear-gradient(120deg,#0b3258,#0d5377);color:#effcff}
body[data-view="wallet"] #view-wallet .wallet-balance :is(b,.unit,.pool-wallet-unit){color:#effcff}
/* References can be unbroken strings. Let the description column shrink while
   reserving enough room for ordinary coin amounts beside it. */
#view-wallet .wallet-history .wallet-hist-row{display:grid;grid-template-columns:minmax(0,1fr) fit-content(45%);align-items:start;width:100%;min-width:0;min-height:44px}
#view-wallet .wallet-hist-row > :first-child{min-width:0;overflow-wrap:anywhere}
#view-wallet .wallet-hist-label,#view-wallet .wallet-hist-label > .hint{display:block}
#view-wallet button.wallet-hist-row{appearance:none;border-top:0;border-right:0;border-left:0;color:inherit;font-family:inherit;font-weight:inherit;line-height:inherit;text-align:left;cursor:pointer}
#view-wallet button.wallet-hist-row:focus-visible{outline:2px solid var(--acc);outline-offset:3px}
#view-delivery .delivery-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:0 0 18px}
#view-delivery .delivery-filters[hidden]{display:none}
#view-delivery .delivery-filters button{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0;min-height:44px;padding:10px 12px;border:1px solid var(--premium-line);border-radius:10px;background:var(--card);color:var(--copy);font:500 12px/1.4 var(--sans)}
#view-delivery .delivery-filters button[aria-pressed="true"]{border-color:var(--acc);background:var(--accent-wash);color:var(--fg);box-shadow:inset 3px 0 0 var(--acc)}
#view-delivery .delivery-filters b{font:600 12px/1.4 var(--mono);padding:2px 6px;border-radius:6px;background:var(--bg);color:var(--fg)}
#view-delivery .delivery-filters button:focus-visible{outline:2px solid var(--acc);outline-offset:2px}
#view-delivery .delivery-filter-empty{padding:20px 12px;border:1px dashed var(--premium-line);border-radius:10px;color:var(--copy)}
@media(max-width:700px){
  #view-market .market-search-bar{grid-template-columns:1fr;gap:6px;padding:9px}
  #view-market .market-search-bar>label{font-size:12px}
  #view-market #pool-market-search-clear{min-height:44px}
  #view-market #pool-market-search-status{display:block}
  #view-wallet .wallet-balance{padding:14px;font-size:1.35rem}
  #view-wallet .wallet-denoms .mini,#view-wallet .wallet-rails .mini{min-height:48px}
}
@media(prefers-reduced-motion:reduce){#view-delivery #pool-delivery-list .pool-order-row{transition:none}#view-delivery #pool-delivery-list .pool-order-row:hover{transform:none}}
@media(forced-colors:active){
  #view-delivery .delivery-filters button,#view-delivery .delivery-filters b{background:ButtonFace;color:ButtonText;border-color:ButtonText}
  #view-delivery .delivery-filters button[aria-pressed="true"]{background:Highlight;color:HighlightText;box-shadow:none}

  body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback-label,
  body[data-view="delivery"] #view-delivery .pool-delivery-fleet-line :is(.pool-delivery-fleet-kicker,.pool-delivery-fleet-note),
  body[data-view="wallet"] #view-wallet .wallet-balance :is(b,.unit,.pool-wallet-unit){color:CanvasText}
  body[data-view="wallet"] #view-wallet .wallet-balance{background:Canvas;color:CanvasText}

  #view-market .market-search-bar,#view-market .pool-card,#view-wallet .card,#view-delivery .card,#pool-account-menu{background:Canvas;color:CanvasText;border-color:CanvasText;box-shadow:none}
  #view-market #pool-market-search{background:Canvas;color:CanvasText;border-color:CanvasText}
  #view-market .pool-media-fallback,#view-delivery .pool-delivery-fleet-line,#view-wallet .wallet-balance,#view-wallet #pool-wallet-pay{background:Canvas;color:CanvasText;border-color:CanvasText;box-shadow:none}
  #view-wallet .wallet-balance :is(b,.unit,.pool-wallet-unit),#view-wallet #pool-wallet-pay h2,#view-delivery .delivery-pane-title{color:CanvasText}
  #view-wallet .wallet-denoms .mini,#view-wallet .wallet-rails .mini,#view-wallet .wallet-denoms .mini.on,#view-wallet .wallet-rails .mini.on{background:ButtonFace;color:ButtonText;border-color:ButtonText;box-shadow:none}
  #view-market #pool-market-search:focus-visible{outline:2px solid Highlight;box-shadow:none}
}

/* Round 2 observatory finish: a quiet cyan edge makes the key customer
   surfaces read as one system while all text and controls stay in flow. */
:root{
  --customer-rim-strong:rgb(57 181 224/.68);
  --customer-section-ink:#0a559d;
  --customer-cta-shadow:0 9px 22px rgb(5 76 154/.24),inset 0 1px 0 rgb(218 248 255/.38);
}
:root[data-theme="dark"]{
  --customer-rim-strong:rgb(92 208 239/.52);
  --customer-section-ink:#9bdcff;
  --customer-cta-shadow:0 10px 26px rgb(0 4 18/.38),inset 0 1px 0 rgb(196 239 255/.24);
}
#view-auth .auth-card,
body[data-view="wallet"] #view-wallet .wallet-grid > .card,
body[data-view="wallet"] #view-wallet > .card,
body[data-view="delivery"] #view-delivery .grid-2.delivery-board > .card{
  border-top-color:var(--customer-rim-strong);
  box-shadow:0 10px 28px rgb(8 54 98/.10),inset 0 2px 0 var(--customer-rim-strong);
}
#view-auth .auth-card h1,
body[data-view="wallet"] #view-wallet h2,
body[data-view="delivery"] #view-delivery .delivery-pane-title{
  color:var(--customer-section-ink);
}
#view-auth .auth-card h1{color:var(--fg);}
body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn,
#pool-auth-form #pool-auth-submit,
#pool-verify-form #pool-verify-submit,
#view-wallet #pool-wallet-custom-go,
#view-wallet #pool-wallet-txid-form .btn,
#view-delivery .pool-delivery-empty-go{
  background:linear-gradient(112deg,#0754b4 8%,#087fa3 100%);
  border-color:#136eba;
  color:#fff;
  box-shadow:var(--customer-cta-shadow);
}
@media(hover:hover){
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn:hover:not(:disabled):not([aria-disabled="true"]),
  #pool-auth-form #pool-auth-submit:hover:not(:disabled),
  #pool-verify-form #pool-verify-submit:hover:not(:disabled),
  #view-wallet #pool-wallet-custom-go:hover:not(:disabled),
  #view-wallet #pool-wallet-txid-form .btn:hover:not(:disabled),
  #view-delivery .pool-delivery-empty-go:hover:not(:disabled){
    filter:brightness(1.06);box-shadow:0 12px 26px rgb(5 76 154/.28),inset 0 1px 0 rgb(228 250 255/.42);
  }
}
@media(max-width:700px){
  /* Keep the scan compact without changing card or control hit rectangles. */
  #view-wallet .wallet-grid{gap:12px;}
  #view-wallet > .card.gap-top{margin-top:12px;}
  #view-delivery .delivery-page-head{padding-bottom:2px;}
}
@media(forced-colors:active){
  #view-auth .auth-card,
  body[data-view="wallet"] #view-wallet .wallet-grid > .card,
  body[data-view="wallet"] #view-wallet > .card,
  body[data-view="delivery"] #view-delivery .grid-2.delivery-board > .card{
    border-top-color:CanvasText;box-shadow:none;
  }
  #view-auth .auth-card h1,
  body[data-view="wallet"] #view-wallet h2,
  body[data-view="delivery"] #view-delivery .delivery-pane-title,
  #view-auth .auth-card h1{color:CanvasText;}
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn,
  #pool-auth-form #pool-auth-submit,
  #pool-verify-form #pool-verify-submit,
  #view-wallet #pool-wallet-custom-go,
  #view-wallet #pool-wallet-txid-form .btn,
  #view-delivery .pool-delivery-empty-go{background:ButtonFace;color:ButtonText;border-color:ButtonText;box-shadow:none;filter:none;}
}

/* Galaxy collection. Decoration lives on the surface, never over controls or
   live data, so cards keep their dimensions and remain still during updates. */
:root{
  --customer-surface:linear-gradient(145deg,#fff,#f5faff);
  --customer-edge:#bdd6ee;
  --customer-inset:#eef6ff;
  --customer-shadow:0 12px 32px rgb(13 57 98/.09),inset 0 1px 0 #fff;
  --customer-cta:linear-gradient(112deg,#085ac6,#087397);
  --customer-cta-hover:linear-gradient(112deg,#084eaf,#08617e);
  --customer-rim:rgb(98 190 230/.42);
  --customer-chrome:linear-gradient(112deg,#fff 32%,#eef8ff);
  --customer-popover:#fcfeff;
  --customer-raised-shadow:0 12px 30px rgb(10 47 81/.12),inset 0 1px 0 #fff;
}
:root[data-theme="dark"]{
  --customer-surface:linear-gradient(145deg,#10233a,#0a192b);
  --customer-edge:#355775;
  --customer-inset:#102a43;
  --customer-shadow:0 14px 34px rgb(0 5 17/.28),inset 0 1px 0 rgb(143 214 255/.1);
  --customer-rim:rgb(106 207 239/.26);
  --customer-chrome:linear-gradient(112deg,#0e243a 32%,#103149);
  --customer-popover:#0d2237;
  --customer-raised-shadow:0 16px 36px rgb(0 6 18/.38),inset 0 1px 0 rgb(158 224 255/.17);
}

body[data-view="market"] #view-market :is(.market-search-bar,.shelf-toolbar),
body[data-view="market"] #view-market #pool-packages .pool-card,
body[data-view="market"] #view-market #pool-other-goods .pool-card,
#view-auth .auth-card,#view-wallet .card,#view-delivery .card{
  border-color:var(--customer-edge);
  background:var(--customer-surface);
  box-shadow:var(--customer-shadow);
}
body[data-view="market"] #view-market .pool-card::before{
  background:linear-gradient(90deg,#0d6cda,#56dbf4 46%,transparent);
}
body[data-view="market"] #view-market .pool-card > .pool-card-media{
  border-bottom-color:rgb(124 211 255/.35);
  background:
    radial-gradient(ellipse at 78% 116%,rgb(24 160 199/.42),transparent 60%),
    linear-gradient(120deg,#071c35,#0e3958);
}
body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  background:
    radial-gradient(circle at 82% 24%,#efffff 0 1px,transparent 1.7px),
    radial-gradient(circle at 67% 72%,#92d8f9 0 1px,transparent 1.7px),
    radial-gradient(circle at 20% 27%,#a2dfff 0 1px,transparent 1.7px),
    radial-gradient(circle at 91% 67%,#6ccae8 0 1px,transparent 1.7px),
    radial-gradient(ellipse at 92% 106%,rgb(32 192 221/.4),transparent 57%),
    radial-gradient(ellipse at 15% -30%,rgb(32 103 192/.42),transparent 68%),
    linear-gradient(120deg,#071b31,#103c5b);
}
body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback::after{
  content:"";
  position:absolute;
  z-index:-1;
  width:72%;height:110%;right:-24%;top:5%;
  border:1px solid rgb(114 214 247/.3);
  border-radius:50%;
  box-shadow:0 0 0 16px rgb(93 189 230/.055),0 0 0 34px rgb(93 189 230/.04),inset 0 0 26px rgb(60 190 222/.1);
  transform:rotate(-32deg);
  pointer-events:none;
}
body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback > img.product-brand-icon{
  box-shadow:0 0 0 1px rgb(203 238 255/.48),0 8px 20px rgb(0 8 26/.3),0 0 25px rgb(98 211 255/.16);
}
body[data-view="market"] #view-market :is(.pool-name,.pool-price b,.pool-price .r-now){letter-spacing:-.025em}
body[data-view="market"] #view-market .coin-variant-option{
  border-color:var(--customer-edge);background:var(--customer-inset);
}
body[data-view="market"] #view-market :is(.coin-variant-option.is-selected,.coin-variant-option:has(input:checked)){
  background:color-mix(in srgb,var(--acc) 9%,var(--card));
  border-color:var(--acc);
  box-shadow:inset 3px 0 0 var(--acc),0 3px 10px rgb(15 110 184/.06);
}
body[data-view="market"] #view-market #pool-market-search{
  background:var(--card);border-color:var(--customer-edge);
}
body[data-view="market"] #view-market .shelf-tab.on,
body[data-view="market"] #view-market .shelf-tab[aria-pressed="true"]{
  background:var(--customer-inset);border-color:var(--customer-edge);color:var(--fg);
}
body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn,
#pool-auth-form .btn,#pool-verify-form .btn,#pool-auth-telegram.auth-telegram,#view-auth #pool-auth-social .auth-telegram,
#view-wallet .btn{
  background:var(--customer-cta);border-color:#136eba;color:#fff;
  box-shadow:0 7px 18px rgb(4 93 178/.2),inset 0 1px 0 rgb(187 237 255/.2);
}
#view-auth .auth-card{
  background:
    radial-gradient(ellipse at 100% 0,color-mix(in srgb,#3ebfe5 12%,transparent),transparent 45%),
    var(--customer-surface);
}
#view-auth .auth-card::before{background:linear-gradient(90deg,#0959c3,#4ed7f1 54%,transparent)}
#view-auth .auth-mark{
  background:radial-gradient(circle at 28% 16%,#3bbce5,transparent 52%),linear-gradient(145deg,#0c71d6,#063768);
  box-shadow:0 10px 24px rgb(5 91 195/.23),0 0 0 5px color-mix(in srgb,var(--acc) 6%,transparent),inset 0 1px 0 rgb(197 241 255/.5);
}
body[data-view="market"] #view-market .shelf-tabs .shelf-tab,#view-auth .auth-modes .mini{min-height:44px}
#view-auth .auth-modes{background:var(--customer-inset);border-color:var(--customer-edge)}
#view-auth .auth-modes .mini.on{border-color:var(--customer-edge);box-shadow:0 2px 8px rgb(6 48 97/.08)}
#view-auth :is(#pool-auth-form,#pool-verify-form) input{background:var(--card)}
body[data-view="wallet"] #view-wallet .wallet-balance{
  position:relative;
  isolation:isolate;
  overflow:hidden;
  flex-wrap:wrap;
  border-color:#397eaa;
  background:
    radial-gradient(circle at 85% 22%,#d4f8ff 0 1px,transparent 1.7px),
    radial-gradient(circle at 65% 72%,#83cdeb 0 1px,transparent 1.7px),
    radial-gradient(ellipse at 98% 115%,rgb(23 167 196/.44),transparent 62%),
    linear-gradient(112deg,#092742,#105b7b);
  box-shadow:inset 0 1px 0 rgb(192 235 255/.25),0 10px 22px rgb(9 74 123/.16);
}
body[data-view="wallet"] #view-wallet .wallet-balance b{
  min-width:0;max-width:100%;overflow-wrap:anywhere;
}
body[data-view="wallet"] #view-wallet .wallet-balance :is(.unit,.pool-wallet-unit){
  flex:0 0 auto;max-width:100%;
}
body[data-view="wallet"] #view-wallet .wallet-balance::after{
  content:"";position:absolute;z-index:-1;right:-6%;top:14%;width:52%;height:190%;
  border:1px solid rgb(155 230 255/.22);border-radius:50%;
  box-shadow:0 0 0 13px rgb(107 215 246/.045),0 0 0 29px rgb(107 215 246/.035);
  transform:rotate(-25deg);pointer-events:none;
}
#view-wallet :is(.wallet-denoms,.wallet-rails) .mini{
  border-color:var(--customer-edge);background:var(--customer-surface);color:var(--fg);
}
#view-wallet :is(.wallet-denoms,.wallet-rails) .mini.on{
  background:var(--customer-inset);border-color:var(--acc);box-shadow:inset 3px 0 0 var(--acc),0 3px 10px rgb(15 110 184/.07);
}
#view-wallet .wallet-hist-row{background:var(--customer-inset);box-shadow:none}
#view-wallet #pool-wallet-pay{background:var(--customer-surface);border-top-color:#25a9d2}
#view-delivery .delivery-filters button{border-color:var(--customer-edge);background:var(--customer-inset)}
#view-delivery .delivery-filters button[aria-pressed="true"]{border-color:var(--acc);background:var(--card);box-shadow:inset 3px 0 0 var(--acc),0 3px 9px rgb(15 110 184/.08)}
#view-delivery #pool-delivery-list .pool-order-row{background:var(--customer-surface);border-color:var(--customer-edge)}
#pool-account-menu{background:var(--customer-surface);border-color:var(--customer-edge)}
@media(hover:hover){
  body[data-view="market"] #view-market #pool-packages .pool-card:hover,
  body[data-view="market"] #view-market #pool-other-goods .pool-card:hover{
    border-color:#58a5d5;box-shadow:0 15px 32px rgb(10 82 143/.15),inset 0 1px 0 rgb(170 225 255/.35);
  }
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn:hover:not(:disabled):not(.is-off):not([aria-disabled="true"]),
  #pool-auth-form .btn:hover:not(:disabled),#pool-verify-form .btn:hover:not(:disabled),
  #pool-auth-telegram.auth-telegram:hover,#view-auth #pool-auth-social .auth-telegram:hover,#view-wallet .btn:hover:not(:disabled){background:var(--customer-cta-hover)}
}
@media(forced-colors:active){
  body[data-view="market"] #view-market :is(.market-search-bar,.shelf-toolbar),
  body[data-view="market"] #view-market #pool-packages .pool-card,
  body[data-view="market"] #view-market #pool-other-goods .pool-card,
  body[data-view="market"] #view-market :is(.pool-card-media,.pool-media-fallback,.coin-variant-option),
  #view-auth .auth-card,#view-auth .auth-mark,#view-auth .auth-modes,
  #view-wallet .card,#view-delivery .card,#pool-account-menu,
  body[data-view="wallet"] #view-wallet .wallet-balance,
  #view-wallet #pool-wallet-pay,#view-wallet .wallet-hist-row,
  #view-delivery #pool-delivery-list .pool-order-row{
    background:Canvas;color:CanvasText;border-color:CanvasText;box-shadow:none;
  }
  body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback{background:Canvas;color:CanvasText}
  body[data-view="market"] #view-market .pool-card-media.is-fallback .pool-media-fallback::after,
  body[data-view="wallet"] #view-wallet .wallet-balance::after{content:none}
  body[data-view="market"] #view-market #pool-market-search{background:Field;border-color:FieldText;color:FieldText}
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card .coin-row .btn,
  #pool-auth-form .btn,#pool-verify-form .btn,#pool-auth-telegram.auth-telegram,#view-auth #pool-auth-social .auth-telegram,#view-wallet .btn,
  #view-wallet :is(.wallet-denoms,.wallet-rails) .mini,
  #view-delivery .delivery-filters button{background:ButtonFace;border-color:ButtonText;color:ButtonText;box-shadow:none}
  body[data-view="market"] #view-market :is(.coin-variant-option.is-selected,.coin-variant-option:has(input:checked)),
  #view-wallet :is(.wallet-denoms,.wallet-rails) .mini.on,
  #view-auth .auth-modes .mini.on,
  #view-delivery .delivery-filters button[aria-pressed="true"]{background:Highlight;color:HighlightText;border-color:Highlight;box-shadow:none}
  /* Box shadows disappear in forced colors; keep image zoom keyboard focus visible. */
  #view-delivery #pool-delivery-detail .delivery-image-open:focus-visible{
    outline:2px solid Highlight;outline-offset:3px;
  }
}

/* Shared customer chrome: pearl/navy surfaces and a thin cyan light edge.
   Surface lighting is static; popover placement and live content stay intact. */
:root[data-theme] body:not([data-view="admin"]) .top{
  border-color:var(--customer-edge);
  background:var(--customer-chrome);
  box-shadow:0 8px 24px rgb(8 54 98/.09),inset 0 1px 0 var(--customer-rim);
  backdrop-filter:none;
  -webkit-backdrop-filter:none;
}
body:not([data-view="admin"]) .top-actions :is(.pool-theme,.pool-lang-btn,.pool-order-bell,.pool-menu-btn){
  border-color:var(--customer-edge);
  background:var(--customer-popover);
  color:var(--fg);
  box-shadow:inset 0 1px 0 var(--customer-rim);
}
body:not([data-view="admin"])[data-gate="open"] #pool-nav .nav-item.on{
  border-color:var(--customer-rim);
  background:var(--customer-chrome);
  color:var(--fg);
  box-shadow:inset 3px 0 0 var(--acc),0 4px 14px rgb(10 68 120/.07);
}
body:not([data-view="admin"]) :is(#pool-account-menu,#pool-order-inbox,#pool-lang-menu,#pool-lang-auth-menu){
  border-color:var(--customer-edge);
  background:var(--customer-popover);
  box-shadow:var(--customer-raised-shadow);
}
body:not([data-view="admin"]) #pool-account-menu .pool-account-id{
  background:var(--customer-chrome);
  border-color:var(--customer-edge);
}
body:not([data-view="admin"]) #pool-account-menu .pool-account-line,
body:not([data-view="admin"]) #pool-order-inbox .pool-order-row{
  border-color:var(--customer-edge);
  background:var(--customer-surface);
  box-shadow:none;
}
body:not([data-view="admin"]) #pool-account-menu .pool-account-line[aria-expanded="true"]{
  border-color:var(--acc);
  background:var(--customer-inset);
  box-shadow:inset 3px 0 0 var(--acc);
}
body:not([data-view="admin"]) :is(.shop-signin,#pool-wallet-topup){
  border-color:#136eba;background:var(--customer-cta);color:#fff;
  box-shadow:0 4px 12px rgb(4 93 178/.17),inset 0 1px 0 rgb(187 237 255/.25);
}
/* Cards share Fleet's quiet edge lighting instead of a separate glow system. */
body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card,
body[data-view="wallet"] #view-wallet .card,
body[data-view="delivery"] #view-delivery .card{
  border-color:var(--customer-edge);
  background:radial-gradient(ellipse at 100% 0%,rgb(48 188 235/.04),transparent 44%),var(--customer-surface);
  box-shadow:0 7px 22px rgb(8 54 98/.09),inset 0 1px 0 var(--customer-rim);
}
/* Sibling-card spacing belongs to stacked sections, not this two-column grid. */
#view-wallet .wallet-grid > .card{margin-top:0;}
#view-wallet .wallet-hist-row{
  border-color:var(--customer-edge);
  background:var(--customer-inset);
  box-shadow:none;
}
#view-delivery #pool-delivery-list .pool-order-row:is(.is-selected,[aria-selected="true"],[aria-pressed="true"]){
  border-color:var(--acc);
  background:var(--customer-inset);
  box-shadow:inset 3px 0 0 var(--acc);
}
@media(max-width:700px){
  /* The list now has its own surface; keep its title and filters off the rim. */
  #view-delivery .grid-2.delivery-board > #pool-delivery-list-card{padding:14px;}
}
@media(hover:hover){
  body:not([data-view="admin"]) .top-actions :is(.pool-theme,.pool-lang-btn,.pool-order-bell,.pool-menu-btn):hover,
  body:not([data-view="admin"]) #pool-account-menu .pool-account-line:hover,
  body:not([data-view="admin"]) #pool-order-inbox .pool-order-row:hover{
    border-color:var(--acc);background:var(--customer-inset);
  }
  body:not([data-view="admin"]) :is(.shop-signin,#pool-wallet-topup):hover:not(:disabled){background:var(--customer-cta-hover);}
}
@media(forced-colors:active){
  :root[data-theme] body:not([data-view="admin"]) .top,
  body:not([data-view="admin"]) :is(#pool-account-menu,#pool-order-inbox,#pool-lang-menu,#pool-lang-auth-menu),
  body:not([data-view="admin"]) #pool-account-menu .pool-account-id,
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card,
  body[data-view="wallet"] #view-wallet .card,
  body[data-view="delivery"] #view-delivery .card,
  #view-wallet .wallet-hist-row{background:Canvas;color:CanvasText;border-color:CanvasText;box-shadow:none;}
  body:not([data-view="admin"]) .top-actions :is(.pool-theme,.pool-lang-btn,.pool-order-bell,.pool-menu-btn),
  body:not([data-view="admin"]) :is(.shop-signin,#pool-wallet-topup),
  body:not([data-view="admin"]) #pool-account-menu .pool-account-line,
  body:not([data-view="admin"]) #pool-order-inbox .pool-order-row{background:ButtonFace;color:ButtonText;border-color:ButtonText;box-shadow:none;}
  body:not([data-view="admin"])[data-gate="open"] #pool-nav .nav-item.on,
  body:not([data-view="admin"]) #pool-account-menu .pool-account-line[aria-expanded="true"],
  #view-delivery #pool-delivery-list .pool-order-row:is(.is-selected,[aria-selected="true"],[aria-pressed="true"]){background:Highlight;color:HighlightText;border-color:Highlight;box-shadow:none;}
  /* Native forced-color text backplates can mask HighlightText. Preserve the
     system button palette and communicate selection with a Highlight outline. */
  body[data-view="wallet"] #view-wallet .wallet-rails .mini.on{
    background:ButtonFace;color:ButtonText;border-color:Highlight;
    outline:2px solid Highlight;outline-offset:-3px;
  }
  body[data-view="wallet"] #view-wallet .wallet-rails .mini.on:focus-visible{outline-offset:3px;}
}

/* One selection language across the customer journey. The blue wash denotes
   a choice; the deeper blue/cyan gradient remains reserved for an action. */
:root{
  --customer-selected:linear-gradient(112deg,#deefff,#ecfaff);
  --customer-selected-ink:#123e6c;
  --customer-control-edge:#7496b1;
  --customer-control-paper:#fbfdff;
}
:root[data-theme="dark"]{
  --customer-selected:linear-gradient(112deg,#163d5c,#103149);
  --customer-selected-ink:#e0f5ff;
  --customer-control-edge:#5c87a7;
  --customer-control-paper:#102a43;
}
body[data-view="market"] #view-market .shelf-tabs .shelf-tab:is(.on,[aria-pressed="true"]),
#view-auth .auth-modes .mini.on,
#view-wallet :is(.wallet-rails,.wallet-denoms) .mini.on,
#view-delivery .delivery-filters button[aria-pressed="true"]{
  color:var(--customer-selected-ink);
  border-color:var(--acc);
  background:var(--customer-selected);
  box-shadow:inset 0 -2px 0 var(--acc),inset 0 1px 0 var(--customer-rim);
  font-weight:600;
}
#view-delivery .delivery-filters button[aria-pressed="true"] b{
  color:var(--customer-selected-ink);background:var(--customer-popover);
}
body[data-view="market"] #view-market .coin-variant-option:has(input:checked){
  border-color:var(--acc);
  background:var(--customer-selected);
  color:var(--customer-selected-ink);
  box-shadow:inset 3px 0 0 var(--acc);
}
#view-auth :is(#pool-auth-form,#pool-verify-form) > label,
#view-wallet :is(.wallet-custom,.wallet-txid) label{
  color:var(--copy);font-weight:600;
}
#view-auth :is(#pool-auth-form,#pool-verify-form) input,
#view-wallet :is(#pool-wallet-custom-amt,#pool-wallet-txid),
body[data-view="market"] #view-market #pool-market-search{
  color:var(--fg);border-color:var(--customer-control-edge);
  background:var(--customer-control-paper);
}
#view-auth .auth-kicker{color:var(--premium-blue);font-size:11px;font-weight:600;letter-spacing:.11em;text-transform:uppercase;}
#view-auth #pool-auth-title{letter-spacing:-.045em;}
#view-auth :is(.auth-to-shop,#pool-auth-toggle-password,#pool-verify-toggle-password){
  color:var(--fg);border-color:var(--customer-control-edge);background:var(--customer-popover);box-shadow:none;
}
@media(max-width:700px){
  #view-auth #pool-auth-title{font-size:36px;line-height:1.15;}
  #view-wallet .card{padding:16px;}
  #view-delivery .grid-2.delivery-board > #pool-delivery-detail{padding:14px;}
  #view-market .market-search-bar{padding:12px;gap:8px;}
}
@media(forced-colors:active){
  /* System ButtonText avoids text backplates masking white HighlightText. */
  body[data-view="market"] #view-market .shelf-tabs .shelf-tab:is(.on,[aria-pressed="true"]),
  #view-auth .auth-modes .mini.on,
  #view-wallet :is(.wallet-rails,.wallet-denoms) .mini.on,
  #view-delivery .delivery-filters button[aria-pressed="true"],
  body[data-view="market"] #view-market .coin-variant-option:has(input:checked){
    color:ButtonText;background:ButtonFace;border-color:Highlight;box-shadow:none;
    outline:2px solid Highlight;outline-offset:-3px;
  }
  #view-delivery .delivery-filters button[aria-pressed="true"] b{color:ButtonText;background:ButtonFace;}
  #view-auth :is(#pool-auth-form,#pool-verify-form) > label,
  #view-auth .auth-kicker,
  #view-wallet :is(.wallet-custom,.wallet-txid) label{color:CanvasText;}
  #view-auth :is(#pool-auth-form,#pool-verify-form) input,
  #view-wallet :is(#pool-wallet-custom-amt,#pool-wallet-txid),
  body[data-view="market"] #view-market #pool-market-search{color:FieldText;border-color:FieldText;background:Field;}
  #view-auth :is(.auth-to-shop,#pool-auth-toggle-password,#pool-verify-toggle-password){color:ButtonText;border-color:ButtonText;background:ButtonFace;}
}

/* Uploaded artwork already carries its brand; show the branded fallback only
   when no upload is available or the image-error handler has selected it. */
body[data-view="market"] #view-market .pool-card-media:not(.is-fallback):has(> img) > .pool-media-fallback{display:none;}
@media(max-width:700px){
  #view-market .market-search-bar{
    grid-template-columns:minmax(0,1fr) auto;
    grid-template-rows:auto auto;
    gap:6px 10px;
  }
  #view-market .market-search-bar > label{grid-column:1;grid-row:1;margin:0;min-width:0;}
  #view-market #pool-market-search-status{grid-column:2;grid-row:1;margin:0;align-self:center;}
  #view-market .market-search-field{grid-column:1/-1;grid-row:2;}
  body[data-view="market"] #view-market :is(#pool-packages,#pool-other-goods) .pool-card > .pool-card-media.is-fallback{
    aspect-ratio:auto;
    min-height:112px;
  }
  body[data-view="market"] #view-market .pool-card-media.is-fallback > .pool-media-fallback{
    min-height:112px;
    padding-block:14px;
  }
}

/* Keep the category shelf touch-scrollable while making clipped labels
   discoverable on narrow screens. The fade sits on the existing toolbar,
   never on the scroll node, so keyboard focus and horizontal scrolling remain
   native. */
@media(max-width:700px){
  body[data-view="market"] #view-market > .shelf-toolbar{
    position:relative;
  }
  body[data-view="market"] #view-market > .shelf-toolbar::after{
    content:"";
    position:absolute;
    z-index:2;
    inset-block:1px;
    inset-inline-end:1px;
    width:clamp(20px,8vw,30px);
    border-radius:0 14px 14px 0;
    background:linear-gradient(90deg,transparent,color-mix(in srgb,var(--premium-cyan) 16%,var(--card) 84%));
    pointer-events:none;
  }
  /* The support shortcut occupies the toolbar's second grid column when it
     is available; keep the cue on the scroll region instead of tinting that
     actionable button. */
  body[data-view="market"] #view-market > .shelf-toolbar:has(> .market-support-inline:not([hidden]))::after{
    inset-inline-end:56px;
  }
}
@media(forced-colors:active){
  body[data-view="market"] #view-market > .shelf-toolbar::after{content:none;}
}

/* Mobile storefront: leave a clear lower window for the galaxy, while
   bringing catalogue controls closer to the first screen. Content remains
   in normal flow so longer translations and zoom can grow the hero. */
@media(max-width:430px){
  body[data-view="market"] #view-market .sky-hero{
    min-height:336px;
    padding-top:20px;
    padding-bottom:64px;
  }
  body[data-view="market"] #view-market .sky-hero-eyebrow{margin-bottom:12px;}
  body[data-view="market"] #view-market .sky-hero-lead{margin-top:12px;}
  body[data-view="market"] #view-market .sky-hero-points{margin-top:12px;}
  body[data-view="market"] #view-market .sky-hero-copy::before{
    content:"";
    position:absolute;
    z-index:-1;
    inset:-8px -24px -24px;
    background:linear-gradient(180deg,transparent,rgb(4 19 38/.2) 20%,rgb(4 19 38/.72) 52%,rgb(4 19 38/.72) calc(100% - 24px),transparent);
    pointer-events:none;
  }
}
@media(min-width:401px) and (max-width:430px){
  body[data-view="market"] #view-market .sky-hero{min-height:380px;}
}
@media(forced-colors:active){
  body[data-view="market"] #view-market .sky-hero-copy::before{content:none;}
}
