
  .content-wrapper:has(.as) { background:#f5f7fb; }
  .as { --as-blue:#2563eb; --as-blue-d:#1d4ed8; --as-tint:#eaf1ff; --as-ink:#0f172a; --as-text:#334155;
        --as-mute:#64748b; --as-line:#e6e9ef; --as-bg:#f5f7fb;
        /* cards follow Settings > Style Decoration > Card Style (radius, fill, border) */
        --as-card:var(--mk-card-bg,#fff); --as-r:var(--mk-card-radius,14px); --as-edge:var(--mk-card-border,1px solid #e6e9ef);
        --as-shadow:0 1px 2px rgba(15,23,42,.04); --as-shadow-up:0 8px 22px rgba(15,23,42,.08);
        display:grid; grid-template-columns:256px minmax(0,1fr); min-height:calc(100vh - 64px);
        background:var(--as-bg); color:var(--as-ink); line-height:1.5;
        font-size:var(--mk-font,14px); -webkit-font-smoothing:antialiased; }
  .as.as-kh { line-height:1.7; }
  .as *, .as *:before, .as *:after { box-sizing:border-box; }
  .as a { color:inherit; text-decoration:none; }
  .as a:hover { text-decoration:none; }
  .as a.as-more, .as a.as-app-c, .as .as-note a, .as .as-up a { color:var(--as-blue); }
  .as a.as-pill { color:var(--as-blue); }
  .as a.as-pill.blue, .as a.as-pill.blue:hover { color:#fff; }
  .as :focus-visible { outline:2px solid var(--as-blue); outline-offset:2px; border-radius:8px; }
  .as-sys .as-cat { white-space:normal; }

  /* ---------------------------------------------------------------- sidebar */
  .as-side { background:var(--as-card); border-right:1px solid var(--as-line); padding:16px 12px 20px;
             position:sticky; top:0; align-self:start; height:calc(100vh - 64px); overflow:auto;
             display:flex; flex-direction:column; gap:1px; scrollbar-width:thin; }
  /* the lines keep their height and the sidebar scrolls (a flex column would squeeze them) */
  .as-side > *, .as-side-foot > * { flex-shrink:0; }
  .as-search { display:flex; align-items:center; gap:9px; background:var(--as-bg); border:1px solid var(--as-line);
               border-radius:10px; padding:8px 12px; margin:0 0 12px; color:var(--as-mute); transition:border-color .15s, box-shadow .15s; }
  .as-search:focus-within { border-color:var(--as-blue); box-shadow:0 0 0 3px var(--as-tint); background:#fff; }
  .as-search input { border:0; background:transparent; outline:0; flex:1; min-width:0; font:inherit; font-size:calc(var(--mk-font,14px) * 1); color:var(--as-ink); }
  .as-search.big { background:#fff; padding:12px 16px; border-radius:12px; margin:0 0 18px; box-shadow:var(--as-shadow); }
  .as-search.big input { font-size:calc(var(--mk-font,14px) * 1.0714); }
  /* the switch: company apps | 3rd-party apps */
  .as-nav { display:flex; align-items:center; gap:11px; padding:7px 10px; border-radius:10px; font-size:calc(var(--mk-font,14px) * 1); line-height:1.5;
            color:var(--as-text); white-space:nowrap; overflow:hidden; transition:background .12s, color .12s; }
  .as-nav:hover { background:var(--as-bg); color:var(--as-ink); }
  /* Install from file… in the sidebar: a real button */
  .as-side-btn { display:flex; align-items:center; justify-content:center; gap:9px; width:100%; min-height:42px; margin-top:6px; padding:0 14px; border:0; border-radius:12px; background:var(--as-blue,#2563eb); color:#fff; font:700 calc(var(--mk-font,14px) * 1) system-ui,sans-serif; cursor:pointer; box-shadow:0 4px 12px rgba(37,99,235,.28); transition:background .15s, transform .1s; }
  .as-side-btn:hover { background:var(--as-blue-d,#1d4ed8); }
  .as-side-btn:active { transform:scale(.98); }
  .as a.as-side-btn.alt, .as a.as-side-btn.alt:hover { color:var(--as-blue,#2563eb); text-decoration:none; }
  .as-side-btn.alt { background:#fff; box-shadow:inset 0 0 0 1.5px var(--as-blue,#2563eb); margin-top:0; }
  .as-side-btn.alt:hover { background:var(--as-tint,#eaf1ff); }
  .as-side-btn .as-out { font-size:.8em; opacity:.75; }
  .as .as-top a.as-up-top { text-decoration:none; }
  .as-side-btn .as-nt { flex:0 1 auto; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
  .as-nav.on { background:var(--as-tint); color:var(--as-blue-d); font-weight:600; }
  .as-nav .as-ni { width:26px; flex:0 0 26px; text-align:center; color:var(--as-mute); font-size:calc(var(--mk-font,14px) * 1.1429); }
  .as-nav.on .as-ni { color:var(--as-blue); }
  .as-nav .as-nt { flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; }
  .as-nav.sub { padding-left:14px; }
  .as-nav .as-nc { font-size:calc(var(--mk-font,14px) * 0.8571); color:var(--as-mute); font-weight:500; font-variant-numeric:tabular-nums; }
  .as-nav.on .as-nc { color:var(--as-blue-d); }
  .as-cdot { width:26px; height:26px; flex:0 0 26px; border-radius:8px; display:inline-flex; align-items:center;
             justify-content:center; color:#fff; font-size:calc(var(--mk-font,14px) * 0.9286); }
  .as-cdot.img { background:none; border-radius:0; }
  .as-cdot.img img { width:100%; height:100%; object-fit:contain; display:block; }
  .as-sh { font-size:calc(var(--mk-font,14px) * 0.7857); font-weight:700; color:var(--as-mute); margin:18px 10px 6px; text-transform:uppercase; letter-spacing:.06em; }
  .as-kh .as-sh { text-transform:none; letter-spacing:0; font-size:calc(var(--mk-font,14px) * 0.8571); }
  .as-badge { background:#ef4444; color:#fff; border-radius:999px; min-width:20px; height:20px; padding:0 6px;
              font-size:calc(var(--mk-font,14px) * 0.8571); font-weight:600; display:inline-flex; align-items:center; justify-content:center; line-height:1; }
  .as-side-foot { margin-top:auto; padding-top:12px; border-top:1px solid var(--as-line); display:flex; flex-direction:column; gap:1px; }
  .as-side-toggle { display:none; }

  /* ---------------------------------------------------------------- main */
  .as-main { padding:28px 36px 90px; min-width:0; }
  .as-main > * { max-width:1240px; }
  .as-top { display:flex; align-items:center; gap:12px; margin-bottom:18px; flex-wrap:wrap; }
  .as-h1 { font-size:calc(var(--mk-font,14px) * 1.8571); font-weight:700; letter-spacing:-.01em; margin:0; line-height:1.3; flex:1; min-width:0; color:var(--as-ink); }
  .as-kh .as-h1 { font-size:calc(var(--mk-font,14px) * 1.7143); line-height:1.6; letter-spacing:0; }
  .as-h2 { font-size:calc(var(--mk-font,14px) * 1.2857); font-weight:700; margin:0; line-height:1.4; color:var(--as-ink); }
  .as-sec { margin:30px 0 12px; display:flex; align-items:center; gap:10px; }
  /* Update All at work: done / total and the percentage */
  .as-prog { margin:0 0 14px; padding:var(--mk-card-pad,14px) 16px; background:var(--mk-card-bg,#fff); border:var(--mk-card-border,1px solid #e5e9f0); border-radius:var(--mk-card-radius,14px); }
  .as-prog-top { display:flex; align-items:baseline; justify-content:space-between; gap:12px; color:var(--as-text); }
  .as-prog-top b { color:var(--as-blue-d); font-size:calc(var(--mk-font,14px) * 1.2857); }
  .as-prog-bar { height:8px; margin:10px 0 6px; border-radius:99px; background:var(--as-tint); overflow:hidden; }
  .as-prog-bar i { display:block; height:100%; border-radius:99px; background:var(--as-blue); transition:width .6s ease; }
  /* Updates page: one status card (owner 2026-11-23) */
  .as-hero { margin:0 0 22px; padding:20px 22px; border-radius:18px; border:1px solid #cfe9d9; background:linear-gradient(135deg,#f0fbf4,#fff 70%); box-shadow:var(--as-shadow); }
  .as-hero.todo { border-color:#cfdcf8; background:linear-gradient(135deg,#eef4ff,#fff 70%); }
  .as-hero.busy { border-color:#cfdcf8; background:linear-gradient(135deg,#e7f0ff,#fff 75%); }
  .as-hero-row { display:flex; align-items:center; gap:16px; flex-wrap:wrap; }
  .as-hero-ico { width:54px; height:54px; flex:0 0 54px; border-radius:50%; display:inline-flex; align-items:center; justify-content:center; background:#22a559; color:#fff; font-size:24px; box-shadow:0 6px 16px rgba(34,165,89,.28); }
  .as-hero.todo .as-hero-ico, .as-hero.busy .as-hero-ico { background:var(--as-blue); box-shadow:0 6px 16px rgba(37,99,235,.28); }
  .as-hero-tx { flex:1 1 220px; min-width:0; display:flex; flex-direction:column; gap:2px; }
  .as-hero-tx b { font-size:calc(var(--mk-font,14px) * 1.3571); font-weight:700; color:var(--as-ink); }
  .as-hero-tx span { color:var(--as-mute); }
  .as-hero-btn { padding:10px 20px; font-size:calc(var(--mk-font,14px) * 1.0714); }
  .as-hero .as-prog { margin:16px 0 0; padding:0; background:transparent; border:0; box-shadow:none; }
  .as-hero .as-prog-top b { font-size:calc(var(--mk-font,14px) * 1.7); font-weight:800; line-height:1; }
  .as-sec .as-h2 { flex:0 1 auto; min-width:0; }
  .as-sec .as-cdot { width:28px; height:28px; flex:0 0 28px; }
  .as-top + .as-sec-g, .as-banner + .as-sec-g { margin-top:6px; }
  .as-sec-n { font-size:calc(var(--mk-font,14px) * 0.9286); color:var(--as-mute); background:#e9edf4; border-radius:999px; padding:1px 9px; font-weight:600;
              font-variant-numeric:tabular-nums; }
  /* a fine line runs from the label to the edge (or to "See all"), setting the heading apart
     from its cards (owner 2026-11-22) */
  .as-sec:after { content:''; flex:1 1 24px; min-width:24px; height:1px; order:1;
                  background:linear-gradient(90deg, #d5dbe6 0%, var(--as-line) 60%, rgba(230,233,239,0) 100%); }
  .as-sec .as-more, .as-sec .as-sub { order:2; }
  .as-more { color:var(--as-blue); font-size:calc(var(--mk-font,14px) * 1); font-weight:600; white-space:nowrap; }
  .as-more:hover { color:var(--as-blue-d); }
  .as-sub { color:var(--as-mute); font-size:calc(var(--mk-font,14px) * 1); }
  .as-btn-s { border:1px solid var(--as-line); background:#fff; color:var(--as-text); border-radius:10px; padding:7px 14px; font-size:calc(var(--mk-font,14px) * 1);
              font-weight:600; cursor:pointer; font-family:inherit; display:inline-flex; align-items:center; gap:7px; transition:border-color .12s, color .12s; }
  /* "Install from File…" is in the sidebar: the copy at the top of a page is the phone's,
     which has no sidebar (owner 2026-11-22: "remove on the top") */
  .as-top .as-up-top { display:none; }
  .as-btn-s:hover { border-color:var(--as-blue); color:var(--as-blue); }
  .as-btn-s i { color:var(--as-blue); }

  /* the icon: the shared module icon (manage_plugins.module_icon_html) in a rounded square */
  .as-sq { width:52px; height:52px; flex:0 0 52px; border-radius:13px; overflow:hidden; display:inline-flex;
           align-items:center; justify-content:center; position:relative; background:#eef1f6;
           box-shadow:0 0 0 1px rgba(15,23,42,.06); }
  .as-sq > span, .as-sq > img, .as-sq > a { width:100% !important; height:100% !important; min-width:0 !important;
           border-radius:0 !important; box-shadow:none !important; font-size:calc(var(--mk-font,14px) * 1.6429) !important; display:flex !important;
           align-items:center; justify-content:center; }
  .as-sq img { width:100% !important; height:100% !important; object-fit:cover; }
  .as-sq svg { width:62% !important; height:62% !important; }
  .as-sq.big { width:104px; height:104px; flex:0 0 104px; border-radius:24px; }
  .as-sq.big > span { font-size:calc(var(--mk-font,14px) * 3.2857) !important; }
  .as-sq.mid { width:44px; height:44px; flex:0 0 44px; border-radius:11px; }
  .as-sq.mid > span { font-size:calc(var(--mk-font,14px) * 1.4286) !important; }

  /* ---------------------------------------------------------------- the app card */
  .as-sw-w { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
  .as-icw { position:relative; display:inline-flex; flex:0 0 auto; }
  .as-newdot { position:absolute; top:-7px; right:-7px; z-index:1; min-width:20px; height:20px; padding:0 5px; border-radius:999px; background:#dc2626; color:#fff; border:2px solid #fff;
               font-size:calc(var(--mk-font,14px) * 0.7857); font-weight:700; line-height:16px; text-align:center; pointer-events:none; }
  .as a.as-sh-a { display:block; color:var(--as-mute); } .as a.as-sh-a:hover { color:var(--as-blue); }
  .as-own { display:flex; flex-direction:column; gap:1px; }
  /* the list table (app_store/_table.html): the look is Settings > Table Style's; only the cells' insides are here */
  .as-tbl { background:var(--as-card); border:var(--as-edge); border-radius:var(--as-r); padding:10px 12px; min-width:0; }
  .as-tbl .table { background:var(--as-card); }
  .as-tbl td { vertical-align:middle !important; }
  .as-tbl .as-tr { cursor:pointer; }
  .as-tbl .as-c-ic { width:64px; text-align:center; }
  .as-tbl .as-c-ver, .as-tbl .as-c-st { white-space:nowrap; }
  .as-tbl td.as-c-app { min-width:200px; }
  .as-tbl td.as-c-app .as-desc { min-height:0; max-width:60ch; margin-top:2px; }
  .as-st-t { display:inline-block; padding:2px 10px; border-radius:999px; background:#eef1f6; color:var(--as-mute); font-size:calc(var(--mk-font,14px) * 0.8571); font-weight:600; white-space:normal; }
  .as-st-t.on { background:#dcfce7; color:#166534; } .as-st-t.off { background:#fee2e2; color:#991b1b; }
  /* as cards: the picture, the name and the words in the middle, the buttons at the foot */
  .as .as-tbl table.mk-grid-view[class][class][class][class][class] > tbody > tr.as-tr { padding-top:16px !important; }
  .as .as-tbl table.mk-grid-view[class][class][class][class][class] > tbody > tr > td.as-c-ic { order:-1; justify-content:center; width:auto !important; padding:4px 0 8px !important; }
  .as .as-tbl table.mk-grid-view[class][class][class][class][class] > tbody > tr > td.as-c-ic img { width:100% !important; height:100% !important; border-radius:0 !important; }
  .as .as-tbl table.mk-grid-view[class][class][class][class][class] > tbody > tr > td.as-c-app { flex-direction:column; align-items:center; gap:2px; text-align:center; }
  .as .as-tbl table.mk-grid-view[class][class][class][class][class] > tbody > tr > td:is(.as-c-ic, .as-c-app)::before { display:none !important; }
  .as-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(290px,1fr)); gap:14px; }
  .as-tile { display:flex; flex-direction:column; gap:10px; padding:16px; min-width:0; background:var(--as-card);
             border:var(--as-edge); border-radius:var(--as-r); box-shadow:var(--as-shadow);
             transition:border-color .15s, box-shadow .15s, transform .15s; cursor:pointer; }
  .as-tile .as-act, .as-tile .as-note { cursor:default; }
  .as-tile:hover { border-color:#c9d6ee; box-shadow:var(--as-shadow-up); transform:translateY(-1px); }
  .as-tile-h { display:flex; align-items:center; gap:12px; min-width:0; }
  .as-tile-f { display:flex; align-items:center; gap:10px; margin-top:auto; padding-top:10px; border-top:1px solid #f0f2f6; min-height:43px; }
  .as-meta { font-size:calc(var(--mk-font,14px) * 0.8571); color:var(--as-mute); flex:1; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
             font-variant-numeric:tabular-nums; }
  .as-tx { flex:1; min-width:0; }
  .as-name { font-size:calc(var(--mk-font,14px) * 1.0714); font-weight:600; display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--as-ink); }
  a.as-name:hover { color:var(--as-blue); }
  .as-cat { font-size:calc(var(--mk-font,14px) * 0.8929); color:var(--as-mute); display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
  .as-dev { display:flex; align-items:center; gap:6px; flex-wrap:wrap; font-size:calc(var(--mk-font,14px) * 0.8571); color:var(--as-mute); margin-top:1px; }
  .as .as-dev a { color:var(--as-blue); }
  .as-dev-b { background:#eef1f6; color:var(--as-text); border-radius:999px; padding:0 7px; font-size:calc(var(--mk-font,14px) * 0.7857); font-weight:600; line-height:18px; }
  .as-hero .as-dev { color:rgba(255,255,255,.85); }
  .as-desc { font-size:calc(var(--mk-font,14px) * 0.9286); color:var(--as-text); display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden;
             min-height:2.9em; }
  .as-kh .as-desc { min-height:3.3em; }
  .as-act { flex:0 0 auto; display:flex; align-items:center; gap:8px; }
  .as-act form { margin:0; }

  /* buttons */
  .as-pill { display:inline-flex; align-items:center; justify-content:center; min-width:76px; height:32px; padding:0 14px;
             border-radius:9px; border:0; background:var(--as-tint); color:var(--as-blue); font-weight:600; font-size:calc(var(--mk-font,14px) * 0.9643);
             cursor:pointer; font-family:inherit; white-space:nowrap; line-height:1; transition:background .12s, color .12s; }
  .as-pill:hover { background:#dbe7ff; color:var(--as-blue-d); }
  .as-pill.blue { background:var(--as-blue); color:#fff; } .as-pill.blue:hover { background:var(--as-blue-d); color:#fff; }
  .as-pill.grey { background:#eef1f6; color:var(--as-mute); cursor:default; }
  .as-pill.off { background:transparent; color:var(--as-mute); box-shadow:inset 0 0 0 1px #d8dee8; }
  .as-pill.off:hover { background:#fdecec; color:#b91c1c; box-shadow:inset 0 0 0 1px #f5c2c2; }
  /* Active / Inactive: the module's state, and the click that flips it. Light green / light red. */
  .as-pill.as-st { border:0; font-weight:700; }
  .as-pill.as-st.active { background:#dcfce7; color:#166534; box-shadow:inset 0 0 0 1px #bbf7d0; }
  .as-pill.as-st.active:hover { background:#bbf7d0; color:#14532d; }
  .as-pill.as-st.inactive { background:#fee2e2; color:#991b1b; box-shadow:inset 0 0 0 1px #fecaca; }
  .as-pill.as-st.inactive:hover { background:#fecaca; color:#7f1d1d; }
  /* Delete (an uninstalled app, for good): red */
  .as-pill.as-del { background:#dc2626; color:#fff; border:0; font-weight:700; box-shadow:0 3px 10px rgba(220,38,38,.28); }
  .as-pill.as-del:hover { background:#b91c1c; color:#fff; }
  .as-pill.as-st.static { cursor:default; }
  .as-pill.as-st.static:hover { background:#fee2e2; color:#991b1b; }
  .as-act form.js-uninstall { margin:0; }
  /* a card's footer: the version on its own line, then its buttons together in the middle of the card (owner 2026-11-24) */
  .as-tile .as-tile-f { flex-direction:column; align-items:stretch; gap:8px; }
  .as-tile .as-tile-f .as-meta { flex:0 0 auto; text-align:center; }
  .as-tile .as-tile-f .as-act { flex:0 0 auto; justify-content:center; flex-wrap:wrap; width:100%; }
  .as-tile .as-tile-f .as-act form { display:flex; }
  .as-gone { display:block; margin:6px 0 0; padding:8px 10px; border-radius:10px; background:#fff7e6; color:#92400e; font-size:12.5px; font-weight:600; line-height:1.4; }
  .as-gone small { display:block; margin-top:2px; font-weight:500; color:#a16207; }
  .as-pill:disabled { opacity:.6; cursor:wait; }
  .as-note { font-size:calc(var(--mk-font,14px) * 0.8571); color:var(--as-mute); background:#eef1f6; border-radius:999px; padding:4px 10px; line-height:1.35;
             max-width:170px; text-align:center; }
  .as-note.warn { color:#b45309; background:#fef3c7; }
  .as-ver-new { color:#15803d; font-weight:700; white-space:nowrap; }
  .as .as-note.as-new { background:#dcfce7; color:#166534; text-decoration:none; }
  .as-note a { color:var(--as-blue); }
  /* the switch */
  .as-sw { position:relative; display:inline-block; width:44px; height:26px; flex:0 0 44px; margin:0; }
  .as-sw input { opacity:0; width:0; height:0; position:absolute; }
  .as-sw span { position:absolute; inset:0; cursor:pointer; background:#d5dbe6; border-radius:26px; transition:.2s; }
  .as-sw span:before { content:""; position:absolute; height:22px; width:22px; left:2px; top:2px; background:#fff;
                       border-radius:50%; transition:.2s; box-shadow:0 1px 3px rgba(15,23,42,.25); }
  .as-sw input:checked + span { background:#22c55e; }
  .as-sw input:checked + span:before { transform:translateX(18px); }
  .as-sw input:focus-visible + span { box-shadow:0 0 0 3px var(--as-tint); }
  .as-sw input:disabled + span { opacity:.45; cursor:not-allowed; }

  /* ---------------------------------------------------------------- featured banner */
  .as-hero { border-radius:18px; padding:26px 28px; color:#fff; display:flex; gap:22px; align-items:center; position:relative;
             overflow:hidden; min-height:176px; box-shadow:0 10px 26px rgba(15,23,42,.10); }
  .as-hero:before { content:''; position:absolute; right:-70px; top:-90px; width:300px; height:300px; border-radius:50%;
                    background:rgba(255,255,255,.10); }
  .as-hero:after { content:''; position:absolute; right:110px; bottom:-120px; width:220px; height:220px; border-radius:50%;
                   background:rgba(255,255,255,.07); }
  .as-hero .as-sq { box-shadow:0 8px 22px rgba(0,0,0,.22); }
  .as-hero-k { font-size:calc(var(--mk-font,14px) * 0.8214); font-weight:700; letter-spacing:.07em; text-transform:uppercase; opacity:.85; }
  .as-kh .as-hero-k { letter-spacing:0; text-transform:none; font-size:calc(var(--mk-font,14px) * 0.9286); }
  .as-hero-n { font-size:calc(var(--mk-font,14px) * 1.8571); font-weight:700; line-height:1.25; margin:4px 0 6px; }
  .as-kh .as-hero-n { line-height:1.55; }
  .as-hero-d { font-size:calc(var(--mk-font,14px) * 1.0357); opacity:.93; max-width:62ch; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
  .as-hero .as-act { margin-top:14px; }
  .as-hero .as-pill { background:#fff; color:var(--as-ink); height:36px; padding:0 18px; }
  .as-hero .as-pill:hover { background:#f1f5f9; color:var(--as-ink); }
  .as .as-hero a.as-pill, .as .as-hero a.as-pill:hover, .as .as-hero a.as-pill.blue, .as .as-hero a.as-pill.blue:hover { color:var(--as-ink); }  /* beats `.as a.as-pill.blue` white text on this white pill */
  .as-hero .as-note { background:rgba(255,255,255,.2); color:#fff; }
  .as-hero-x { position:relative; min-width:0; z-index:1; }

  /* category chips (Discover) and category cards (Categories, 3rd-Party Apps) */
  /* the chips are the phone's way to a category: on a wider screen the sidebar already lists them */
  .as-chips { display:none; gap:8px; margin:18px 0 4px; }
  .as-chipc { display:inline-flex; align-items:center; gap:8px; background:#fff; border:1px solid var(--as-line); border-radius:999px;
              padding:5px 12px 5px 6px; font-size:calc(var(--mk-font,14px) * 0.9286); font-weight:600; color:var(--as-text); transition:border-color .12s, color .12s; }
  .as-chipc:hover { border-color:var(--as-blue); color:var(--as-blue); }
  .as-chipc .as-cdot { width:22px; height:22px; flex:0 0 22px; border-radius:50%; font-size:calc(var(--mk-font,14px) * 0.7857); }
  .as-chipc small { color:var(--as-mute); font-weight:500; font-size:calc(var(--mk-font,14px) * 0.8571); }
  .as-cats { display:grid; grid-template-columns:repeat(auto-fill,minmax(210px,1fr)); gap:12px; }
  .as-cats-m { display:none; }                      /* shown on a phone only (below) */
  .as-catc { display:flex; align-items:center; gap:12px; padding:14px; border-radius:var(--as-r); background:#fff; border:1px solid var(--as-line);
             font-weight:600; font-size:calc(var(--mk-font,14px) * 1); color:var(--as-ink); box-shadow:var(--as-shadow); transition:border-color .15s, box-shadow .15s; }
  .as-catc:hover { border-color:#c9d6ee; box-shadow:var(--as-shadow-up); }
  .as-catc .as-cdot { width:38px; height:38px; flex:0 0 38px; border-radius:10px; font-size:calc(var(--mk-font,14px) * 1.2143); }
  .as-catc small { display:block; color:var(--as-mute); font-weight:400; font-size:calc(var(--mk-font,14px) * 0.8929); }
  .as-cathd { display:flex; align-items:center; gap:14px; padding-bottom:16px; margin-bottom:20px; position:relative; }
  /* the same line under a category's own heading, with a short stroke of the store's blue at its start */
  .as-cathd:after { content:''; position:absolute; left:0; right:0; bottom:0; height:1px;
                    background:linear-gradient(90deg, #d5dbe6 0%, var(--as-line) 60%, rgba(230,233,239,0) 100%); }
  .as-cathd:before { content:''; position:absolute; left:0; bottom:-1px; width:46px; height:3px; border-radius:3px; background:var(--as-blue); z-index:1; }
  .as-cathd .as-cdot { width:46px; height:46px; flex:0 0 46px; border-radius:12px; font-size:calc(var(--mk-font,14px) * 1.5); }

  /* ---------------------------------------------------------------- lists (Installed, Updates) */
  .as-list { background:var(--as-card); border:var(--as-edge); border-radius:var(--as-r); box-shadow:var(--as-shadow); overflow:hidden; }
  .as-row { display:flex; align-items:center; gap:14px; padding:12px 16px; border-bottom:1px solid #f0f2f6; min-width:0; transition:background .12s; }
  .as-row:last-child { border-bottom:0; }
  .as-row:hover { background:#fafbfd; }
  .as-row .as-sq { width:44px; height:44px; flex:0 0 44px; border-radius:11px; }
  .as-row .as-sq > span { font-size:calc(var(--mk-font,14px) * 1.4286) !important; }
  .as-row .as-desc { min-height:0; }
  .as-list > .as-empty { border:0; box-shadow:none; background:transparent; }
  .as-small { font-size:calc(var(--mk-font,14px) * 0.8571); color:var(--as-mute); }
  .as-ok { color:#16a34a; } .as-bad { color:#dc2626; }
  .as-sys { display:flex; align-items:center; gap:16px; padding:16px; border-radius:var(--as-r); background:#fff; border:1px solid var(--as-line);
            box-shadow:var(--as-shadow); margin-bottom:6px; }
  .as-sys-ico { width:52px; height:52px; flex:0 0 52px; border-radius:13px; display:flex; align-items:center; justify-content:center;
                color:#fff; font-weight:800; font-size:calc(var(--mk-font,14px) * 2); background:linear-gradient(145deg,#60a5fa 0%,#2563eb 60%,#4f46e5 100%); }
  .as-help { background:#fff; border:1px solid var(--as-line); border-radius:12px; padding:12px 16px; font-size:calc(var(--mk-font,14px) * 0.9286); color:var(--as-text); margin-top:22px; }
  .as-help b { display:block; margin-bottom:2px; color:var(--as-ink); }
  .as-empty { color:var(--as-mute); text-align:center; padding:44px 16px; background:#fff; border:1px dashed #d5dbe6; border-radius:var(--as-r); }
  .as-grid > .as-empty { grid-column:1 / -1; }
  .as-banner { background:#fffbeb; color:#92400e; border:1px solid #fde68a; border-radius:10px; padding:10px 14px; font-size:calc(var(--mk-font,14px) * 0.9286); margin-bottom:14px; }
  .as-hint { background:var(--as-tint); color:#1e3a8a; border-radius:10px; padding:10px 14px; font-size:calc(var(--mk-font,14px) * 0.9286); margin-bottom:16px;
             display:flex; gap:10px; align-items:flex-start; }
  .as-hint i { margin-top:3px; color:var(--as-blue); }

  /* ---------------------------------------------------------------- one app */
  .as-app { display:flex; gap:22px; align-items:center; background:#fff; border:1px solid var(--as-line); border-radius:18px;
            padding:22px; box-shadow:var(--as-shadow); }
  .as-app-n { font-size:calc(var(--mk-font,14px) * 1.7857); font-weight:700; line-height:1.3; margin:0; color:var(--as-ink); }
  .as-kh .as-app-n { line-height:1.6; }
  .as-app-c { color:var(--as-blue); font-size:calc(var(--mk-font,14px) * 1); font-weight:600; }
  .as-app-acts { margin-top:12px; display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
  .as-app-acts .as-pill { height:36px; padding:0 18px; }
  .as-stats { display:grid; grid-template-columns:repeat(auto-fit,minmax(130px,1fr)); gap:10px; margin:14px 0 4px; }
  .as-stat { text-align:left; padding:12px 14px; background:#fff; border:1px solid var(--as-line); border-radius:12px; min-width:0; }
  .as-stat small { display:block; font-size:calc(var(--mk-font,14px) * 0.7857); color:var(--as-mute); font-weight:700; text-transform:uppercase; letter-spacing:.05em; }
  .as-kh .as-stat small { text-transform:none; letter-spacing:0; font-size:calc(var(--mk-font,14px) * 0.8571); }
  .as-stat b { display:block; font-size:calc(var(--mk-font,14px) * 1.1429); color:var(--as-ink); font-weight:600; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; margin-top:2px; }
  .as-p { font-size:calc(var(--mk-font,14px) * 1.0357); margin:6px 0 0; white-space:pre-line; overflow-wrap:anywhere; color:var(--as-text); max-width:80ch; }
  .as-hist { margin-top:8px; }
  .as-hist-r { padding:10px 0; border-top:1px solid var(--as-line); }
  .as-info { display:grid; grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:0 28px; background:#fff; border:1px solid var(--as-line);
             border-radius:var(--as-r); padding:6px 18px; }
  .as-info > div { padding:10px 0; border-bottom:1px solid #f0f2f6; min-width:0; }
  .as-info small { display:block; color:var(--as-mute); font-size:calc(var(--mk-font,14px) * 0.8929); }
  .as-info span { font-size:calc(var(--mk-font,14px) * 1.0357); overflow-wrap:anywhere; }
  .as-chip { display:inline-block; background:#eef1f6; border-radius:999px; padding:1px 10px; margin:2px 4px 2px 0; font-size:calc(var(--mk-font,14px) * 0.9286); }
  a.as-chip:hover { background:var(--as-tint); color:var(--as-blue); }
  .as-chip.warn { background:#fef3c7; color:#b45309; }
  .as-kid { display:flex; align-items:center; gap:10px; padding:9px 0; border-bottom:1px solid var(--as-line); font-size:calc(var(--mk-font,14px) * 1); }
  .as-kid i { width:18px; text-align:center; color:var(--as-mute); }
  .as-kid .as-tx { flex:1; }
  .as-danger { border:0; background:none; color:#dc2626; font-weight:600; font-size:calc(var(--mk-font,14px) * 1); cursor:pointer; padding:10px 0; font-family:inherit; }
  .as-danger:hover { color:#b91c1c; }

  /* ---------------------------------------------------------------- the sheet (Install from file…) */
  .as-sheet { position:fixed; inset:0; background:rgba(15,23,42,.45); display:none; align-items:center; justify-content:center;
              z-index:2100; padding:16px; }
  .as-sheet.on { display:flex; }
  .as-sheet-b { background:#fff; border-radius:16px; width:min(560px,100%); max-height:92vh; overflow:auto;
                box-shadow:0 30px 80px rgba(15,23,42,.3); animation:asUp .22s ease-out; }
  @keyframes asUp { from { transform:translateY(18px); opacity:0; } to { transform:none; opacity:1; } }
  .as-sheet-h { display:flex; align-items:center; padding:14px 18px; border-bottom:1px solid var(--as-line); font-weight:700; font-size:calc(var(--mk-font,14px) * 1.1429); }
  .as-sheet-h button { margin-left:auto; border:0; background:none; color:var(--as-blue); font-weight:600; font-size:calc(var(--mk-font,14px) * 1.0714); cursor:pointer; font-family:inherit; }
  .as-sheet-c { padding:16px 18px; }
  .as-field { display:block; margin:0 0 12px; font-size:calc(var(--mk-font,14px) * 0.9286); color:var(--as-text); font-weight:600; }
  .as-field input, .as-field select, .as-field textarea { display:block; width:100%; margin-top:4px; border:1px solid #d5dbe6;
             border-radius:10px; padding:9px 11px; font:inherit; font-size:calc(var(--mk-font,14px) * 1.0714); font-weight:400; background:#fff; color:var(--as-ink); }
  .as-field input:focus, .as-field select:focus, .as-field textarea:focus { outline:0; border-color:var(--as-blue); box-shadow:0 0 0 3px var(--as-tint); }
  .as-field textarea { min-height:64px; resize:vertical; }
  .as-drop { border:2px dashed #cbd5e1; border-radius:14px; padding:22px; text-align:center; color:var(--as-mute); cursor:pointer;
             display:flex; flex-direction:column; align-items:center; justify-content:center; gap:6px; margin-bottom:14px; transition:border-color .12s, background .12s; }
  .as-drop:hover { border-color:var(--as-blue); background:#f8faff; }
  .as-drop i { font-size:calc(var(--mk-font,14px) * 2); color:var(--as-blue); display:block; margin:0 auto; }
  .as-drop input { display:none; }
  .as-bigbtn { display:block; width:100%; border:0; border-radius:12px; background:var(--as-blue); color:#fff; font-size:calc(var(--mk-font,14px) * 1.0714);
               font-weight:600; padding:12px; cursor:pointer; font-family:inherit; transition:background .12s; }
  .as-bigbtn:hover { background:var(--as-blue-d); }
  .as-bigbtn:disabled { opacity:.6; cursor:wait; }
  .as-card-info { display:flex; gap:12px; align-items:center; background:var(--as-bg); border-radius:12px; padding:12px; margin-bottom:14px; }
  .as-up { padding:10px 0; border-top:1px solid var(--as-line); font-size:calc(var(--mk-font,14px) * 1); }
  .as-up a { color:var(--as-blue); }

  /* desktop / iPad: the store fills the window under the top bar; the sidebar and the page scroll apart */
  @media (min-width:701px) {
    .as { height:calc(100vh - var(--as-head, 64px)); min-height:0; overflow:hidden; }
    /* ...and the page behind does not scroll as well (owner 2026-11-22: "double scroll bar"):
       the store's own two panes are the only things that scroll. --as-head is set to the real
       height of the bar above by the page's script, so the store reaches the bottom exactly. */
    body:has(#as-root) { overflow:hidden; }
    /* ...nor the box the store sits in (it also holds the page footer, 92px more than the
       window): that was the second bar beside the store's own (owner 2026-11-22) */
    #scrollable-container:has(#as-root) { overflow:hidden !important; }
    .as-side { position:static; height:100%; }
    .as-main { height:100%; overflow-y:auto; overscroll-behavior:contain; scroll-behavior:smooth; }
  }
  @media (prefers-reduced-motion:reduce) {
    .as-main { scroll-behavior:auto; }
    .as-tile, .as-tile:hover { transition:none; transform:none; }
  }
  /* ---------------------------------------------------------------- the phone's tab bar */
  .as-tabs { display:none; }
  /* ---------------------------------------------------------------- iPad: an icon rail, open on demand */
  @media (max-width:1100px) and (min-width:701px) {
    .as { grid-template-columns:64px minmax(0,1fr); }
    .as-side { padding:12px 8px; }
    .as-side .as-nt, .as-side .as-nc, .as-side .as-sh, .as-side .as-search input, .as-side .as-badge-t { display:none; }
    .as-side .as-search { justify-content:center; padding:8px 0; margin:0 0 8px; }
    .as-nav { justify-content:center; padding:8px 0; position:relative; }
    .as-nav .as-badge { position:absolute; top:0; right:2px; min-width:16px; height:16px; font-size:calc(var(--mk-font,14px) * 0.7143); padding:0 4px; }
    .as-side-toggle { display:flex; }
    .as.as-open { grid-template-columns:240px minmax(0,1fr); }
    .as.as-open .as-side .as-nt, .as.as-open .as-side .as-sh, .as.as-open .as-side .as-nc { display:block; }
    .as.as-open .as-side .as-search input { display:block; }
    .as.as-open .as-side .as-search { justify-content:flex-start; padding:8px 12px; }
    .as.as-open .as-nav { justify-content:flex-start; padding:8px 10px; }
    .as.as-open .as-nav .as-badge { position:static; }
    .as-main { padding:22px 24px 80px; }
    .as-grid { grid-template-columns:repeat(auto-fill,minmax(240px,1fr)); }
  }
  /* ---------------------------------------------------------------- phone */
  @media (max-width:700px) {
    /* the store's own tab bar takes the bottom of the screen: the shell's dock steps aside */
    body:has(.as-tabs) #mac-dock, body:has(.as-tabs) #dock-stack { display:none !important; }
    .as { grid-template-columns:minmax(0,1fr); min-height:0; }
    .as-side { display:none; }
    .as-top .as-up-top { display:inline-flex; }
    .as-main { padding:14px 14px 96px; }
    .as-h1 { font-size:calc(var(--mk-font,14px) * 1.7143); }
    .as-grid { grid-template-columns:minmax(0,1fr); gap:10px; }
    .as-tile { padding:14px; }
    .as-desc { min-height:0; }
    .as-hero { flex-direction:column; align-items:flex-start; padding:20px; min-height:0; gap:14px; }
    .as-hero .as-sq.big { width:76px; height:76px; flex-basis:76px; border-radius:18px; }
    .as-hero-n { font-size:calc(var(--mk-font,14px) * 1.5714); }
    .as-chips { display:flex; flex-wrap:nowrap; overflow-x:auto; scrollbar-width:none; margin-right:-14px; padding-right:14px; }
    .as-chips::-webkit-scrollbar { display:none; }
    .as-chipc { flex:0 0 auto; }
    .as-app { flex-direction:row; gap:14px; align-items:flex-start; padding:16px; }
    .as-app .as-sq.big { width:84px; height:84px; flex-basis:84px; border-radius:20px; }
    .as-app-n { font-size:calc(var(--mk-font,14px) * 1.4286); }
    .as-cats, .as-cats-m { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:10px; }
    .as-catc { padding:11px; gap:9px; font-size:calc(var(--mk-font,14px) * 0.9286); }
    .as-catc .as-cdot { width:32px; height:32px; flex-basis:32px; font-size:calc(var(--mk-font,14px) * 1); }
    .as-sec { margin-top:24px; }
    .as-row { padding:12px; gap:11px; }
    .as-tabs { display:flex; position:fixed; left:0; right:0; bottom:0; z-index:1500; background:rgba(255,255,255,.94);
               -webkit-backdrop-filter:saturate(180%) blur(20px); backdrop-filter:saturate(180%) blur(20px);
               border-top:1px solid var(--as-line); padding:6px 0 calc(6px + env(safe-area-inset-bottom)); }
    .as-tab { flex:1; display:flex; flex-direction:column; align-items:center; gap:2px; font-size:calc(var(--mk-font,14px) * 0.7143); color:var(--as-mute);
              position:relative; min-width:0; }
    .as-tab i { font-size:calc(var(--mk-font,14px) * 1.3571); }
    .as-tab span { max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; padding:0 2px; }
    .as-tab.on { color:var(--as-blue); font-weight:600; }
    .as-tab .as-badge { position:absolute; top:-4px; left:calc(50% + 6px); min-width:18px; height:18px; font-size:calc(var(--mk-font,14px) * 0.7857); }
    .as-sheet { align-items:flex-end; padding:0; }
    .as-sheet-b { border-radius:16px 16px 0 0; }
  }

  /* a module just installed: its card comes in with a pop, a glowing ring and a "New" tag, then is a normal card again */
  .as-tile.as-new { position:relative; z-index:2; animation:as-new-in .7s cubic-bezier(.2,1.3,.4,1), as-new-glow 1.2s ease-in-out .7s 3; }
  .as-tile.as-new::after { content:attr(data-newlabel); position:absolute; top:-9px; right:14px; padding:3px 10px; border-radius:99px; background:#2563eb; color:#fff; font:800 11px/1.4 system-ui,sans-serif; letter-spacing:.04em; text-transform:uppercase; box-shadow:0 4px 10px rgba(37,99,235,.4); animation:as-new-tag .5s .3s both; }
  @keyframes as-new-in { from { opacity:0; transform:translateY(18px) scale(.86); } to { opacity:1; transform:none; } }
  @keyframes as-new-glow { 0%,100% { box-shadow:0 0 0 0 rgba(37,99,235,.55); } 50% { box-shadow:0 0 0 14px rgba(37,99,235,0); } }
  @keyframes as-new-tag { from { opacity:0; transform:translateY(6px) scale(.7); } to { opacity:1; transform:none; } }
