/* Store tiles retain their size; the enhanced links panel never enters grid flow. */
.af-store-directory .af-store-tiles {
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(min(100%,108px),1fr));
  align-items:start;
  gap:10px;
  margin:16px 0;
}
.af-store-directory .af-store-tile {
  min-width:0;
  margin:0;
  padding:0;
  border:0;
  background:none;
}
.af-store-directory .af-store-trigger,
.af-store-directory .af-store-fallback>summary {
  box-sizing:border-box;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  gap:8px;
  width:100%;
  height:108px;
  min-height:108px;
  margin:0;
  padding:10px 7px;
  border:1px solid #405363;
  border-radius:8px;
  background:#192129;
  color:#e4f3ff;
  box-shadow:none;
  text-align:center;
  text-transform:none;
  letter-spacing:normal;
  font:500 12px/1.3 Arial,sans-serif;
  cursor:pointer;
  list-style:none;
}
.af-store-directory .af-store-fallback>summary::-webkit-details-marker {display:none}
.af-store-directory .af-store-trigger:hover,
.af-store-directory .af-store-trigger[aria-expanded="true"] {background:#263847;border-color:#a9cfff}
.af-store-directory .af-store-trigger:focus-visible,
.af-store-directory .af-store-fallback>summary:focus-visible,
.af-store-panel :is(a,button):focus-visible {outline:3px solid #a9cfff;outline-offset:3px}
.af-store-directory .af-store-tile-logo {
  display:flex;
  align-items:center;
  justify-content:center;
  height:40px;
  width:100%;
  gap:2px;
}
.af-store-directory .af-store-tile-logo img {display:block;width:64px;height:40px;max-width:100%;margin:0;padding:0;object-fit:contain;background:transparent}
.af-store-directory .af-store-tile-logo img[src$="-mark.svg"] {filter:brightness(0) invert(1)}
.af-store-directory .af-store-tile-logo sup {align-self:flex-start;font:9px/1 Arial,sans-serif}
.af-store-directory .af-store-tile-name {display:block;min-height:31px;overflow-wrap:anywhere}
.af-store-directory .af-store-fallback {margin:0;padding:0;border:0;background:none}
.af-store-directory .af-store-fallback[hidden] {display:none!important}
.af-store-directory .af-store-fallback ul {list-style:none;margin:8px 0 0;padding:8px;background:#202b35;border-radius:6px}
.af-store-directory .af-store-fallback li {margin:0;padding:0}
.af-store-directory .af-store-fallback a {display:block;padding:10px 4px;font:400 12px/1.4 Arial,sans-serif;overflow-wrap:anywhere}
.af-store-panel {
  box-sizing:border-box;
  position:fixed;
  inset:auto;
  z-index:10000;
  width:320px;
  max-width:calc(100vw - 24px);
  max-height:calc(100dvh - 24px);
  margin:0;
  padding:16px;
  overflow:auto;
  overscroll-behavior:contain;
  border:1px solid #627f95;
  border-radius:10px;
  background:#192129;
  color:#e4f3ff;
  box-shadow:0 12px 40px #0008;
  color-scheme:dark;
  font:400 14px/1.45 Arial,sans-serif;
}
.af-store-panel:not([open]) {display:none}
.af-store-panel[open] {display:block}
.af-store-panel::backdrop {background:#0009}
.af-store-panel .af-store-panel-heading {display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 10px}
.af-store-panel .af-store-panel-heading h3 {margin:0;padding:0;border:0;color:#e4f3ff;font:600 17px/1.3 Arial,sans-serif;overflow-wrap:anywhere}
.af-store-panel .af-store-panel-close {flex-shrink:0;min-height:40px;margin:0;padding:8px 10px;border:1px solid #536d81;border-radius:5px;background:#202b35;color:#c9e4fc;font:500 12px/1.3 Arial,sans-serif;cursor:pointer;box-shadow:none;text-transform:none;letter-spacing:normal}
.af-store-panel ul[data-store-panel-links] {display:grid;gap:6px;list-style:none;margin:0;padding:0}
.af-store-panel ul[data-store-panel-links]>li {margin:0;padding:0;list-style:none}
.af-store-panel ul[data-store-panel-links] a {box-sizing:border-box;display:flex;align-items:center;min-height:44px;padding:10px 12px;border:1px solid #354655;border-radius:6px;background:#202b35;color:#c9e4fc;text-decoration:none;font:500 14px/1.4 Arial,sans-serif;overflow-wrap:anywhere}
.af-store-panel ul[data-store-panel-links] a:hover {background:#2b3c4b;text-decoration:underline;text-underline-offset:3px}
@media(max-width:650px) {
  .af-store-directory .af-store-tiles {grid-template-columns:repeat(auto-fill,minmax(min(100%,92px),1fr));gap:8px}
  .af-store-directory .af-store-trigger,
  .af-store-directory .af-store-fallback>summary {height:104px;min-height:104px}
  .af-store-panel[data-modal="true"] {left:12px;right:12px;top:auto;bottom:max(12px,env(safe-area-inset-bottom));width:auto;max-width:440px;margin:0 auto;border-radius:14px;padding:16px}
}
