@tokenoftrust/storefront-runner 1.4.0 → 1.4.2-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (193) hide show
  1. package/apps/storefront/astro.config.mjs +17 -1
  2. package/apps/storefront/integrations/materialize-guard.mjs +56 -0
  3. package/apps/storefront/migrations-apps/0001_woozy_lyja.sql +22 -0
  4. package/apps/storefront/migrations-apps/0002_good_switch.sql +26 -0
  5. package/apps/storefront/migrations-apps/0003_mute_marauders.sql +12 -0
  6. package/apps/storefront/migrations-apps/meta/0001_snapshot.json +990 -0
  7. package/apps/storefront/migrations-apps/meta/0002_snapshot.json +1160 -0
  8. package/apps/storefront/migrations-apps/meta/0003_snapshot.json +1235 -0
  9. package/apps/storefront/migrations-apps/meta/_journal.json +21 -0
  10. package/apps/storefront/package.json +0 -1
  11. package/apps/storefront/public/js/dashboard-team.js +38 -2
  12. package/apps/storefront/src/components/Seo.astro +65 -1
  13. package/apps/storefront/src/components/admin/AdminBlogDetailRail.astro +878 -0
  14. package/apps/storefront/src/components/admin/AdminBlogTab.astro +1432 -0
  15. package/apps/storefront/src/components/admin/AdminCustomersTab.astro +3 -7
  16. package/apps/storefront/src/components/admin/AdminPublishTab.astro +1756 -1382
  17. package/apps/storefront/src/components/admin/AdminSubscriptionsTab.astro +1 -3
  18. package/apps/storefront/src/components/blog/BlogPaywall.astro +87 -0
  19. package/apps/storefront/src/components/blog/PostAccessBadge.astro +43 -0
  20. package/apps/storefront/src/components/blog/PostGrid.astro +57 -0
  21. package/apps/storefront/src/components/blog/ReactionBar.astro +214 -0
  22. package/apps/storefront/src/layouts/Layout.astro +48 -3
  23. package/apps/storefront/src/lib/activity/alerts.ts +426 -0
  24. package/apps/storefront/src/lib/activity/changeActorAttribution.ts +85 -0
  25. package/apps/storefront/src/lib/activity/deployVersion.ts +120 -0
  26. package/apps/storefront/src/lib/activity/ingest.ts +188 -0
  27. package/apps/storefront/src/lib/activity/ingestAuth.ts +105 -0
  28. package/apps/storefront/src/lib/activity/killSwitch.ts +80 -0
  29. package/apps/storefront/src/lib/activity/query.ts +403 -0
  30. package/apps/storefront/src/lib/activity/recordActivity.ts +101 -0
  31. package/apps/storefront/src/lib/activity/store.ts +120 -0
  32. package/apps/storefront/src/lib/activity/uiActor.ts +150 -0
  33. package/apps/storefront/src/lib/activity/workerCommit.ts +70 -0
  34. package/apps/storefront/src/lib/admin/adminShell.ts +290 -0
  35. package/apps/storefront/src/lib/admin/ai/approvalMode.ts +2 -3
  36. package/apps/storefront/src/lib/admin/ai/audit.ts +3 -5
  37. package/apps/storefront/src/lib/admin/checkoutStyleInput.ts +7 -7
  38. package/apps/storefront/src/lib/admin/checkoutStyleTarget.ts +3 -3
  39. package/apps/storefront/src/lib/admin/orderClient.ts +3 -5
  40. package/apps/storefront/src/lib/admin/services/orders.ts +17 -19
  41. package/apps/storefront/src/lib/admin/viewmodels/aiWorkflows.ts +4 -6
  42. package/apps/storefront/src/lib/admin/viewmodels/settings.ts +1 -1
  43. package/apps/storefront/src/lib/apps/adminService.ts +4 -4
  44. package/apps/storefront/src/lib/apps/adminSession.ts +53 -44
  45. package/apps/storefront/src/lib/apps/apiAuth.ts +2 -2
  46. package/apps/storefront/src/lib/apps/apiRoute.ts +2 -2
  47. package/apps/storefront/src/lib/apps/catalogMapper.ts +1 -1
  48. package/apps/storefront/src/lib/apps/credentials.ts +2 -2
  49. package/apps/storefront/src/lib/apps/gatewayKeys.ts +4 -4
  50. package/apps/storefront/src/lib/apps/healthAggregate.ts +5 -5
  51. package/apps/storefront/src/lib/apps/orders/attributionService.ts +2 -2
  52. package/apps/storefront/src/lib/apps/orders/customerHash.ts +1 -1
  53. package/apps/storefront/src/lib/apps/orders/foxyOrderClient.ts +12 -12
  54. package/apps/storefront/src/lib/apps/orders/idempotency.ts +7 -7
  55. package/apps/storefront/src/lib/apps/orders/orderForwardReceiver.ts +1 -1
  56. package/apps/storefront/src/lib/apps/orders/orderMapper.ts +2 -2
  57. package/apps/storefront/src/lib/apps/orders/ordersStore.ts +6 -6
  58. package/apps/storefront/src/lib/apps/registryService.ts +6 -6
  59. package/apps/storefront/src/lib/apps/scopes.ts +2 -2
  60. package/apps/storefront/src/lib/apps/tokenIssuer.ts +4 -4
  61. package/apps/storefront/src/lib/apps/tokenVerifier.ts +6 -6
  62. package/apps/storefront/src/lib/apps/widgets/eligibility.ts +2 -2
  63. package/apps/storefront/src/lib/apps/widgets/frameProps.ts +3 -3
  64. package/apps/storefront/src/lib/apps/widgets/launchToken.ts +4 -4
  65. package/apps/storefront/src/lib/apps/widgets/placements.ts +2 -2
  66. package/apps/storefront/src/lib/apps/widgets/renderSlot.ts +1 -1
  67. package/apps/storefront/src/lib/auth/adminEntry.ts +9 -9
  68. package/apps/storefront/src/lib/auth/identityToken.ts +6 -14
  69. package/apps/storefront/src/lib/auth/loginGate.ts +75 -13
  70. package/apps/storefront/src/lib/auth/mcpClientAssertion.ts +6 -4
  71. package/apps/storefront/src/lib/auth/operatorSession.ts +113 -0
  72. package/apps/storefront/src/lib/auth/route.ts +44 -4
  73. package/apps/storefront/src/lib/auth/session.ts +7 -8
  74. package/apps/storefront/src/lib/auth/totAccessClient.ts +8 -18
  75. package/apps/storefront/src/lib/basePath.ts +9 -2
  76. package/apps/storefront/src/lib/blog/access.ts +29 -0
  77. package/apps/storefront/src/lib/blog/collection.ts +313 -0
  78. package/apps/storefront/src/lib/blog/markdown.ts +174 -0
  79. package/apps/storefront/src/lib/blog/provider.ts +5 -0
  80. package/apps/storefront/src/lib/blog/reactions.ts +87 -0
  81. package/apps/storefront/src/lib/blog/rss.ts +92 -0
  82. package/apps/storefront/src/lib/blog/teaser.ts +83 -0
  83. package/apps/storefront/src/lib/blog/types.ts +34 -0
  84. package/apps/storefront/src/lib/blog/viewCounts.ts +243 -0
  85. package/apps/storefront/src/lib/d1/catalog.ts +2 -2
  86. package/apps/storefront/src/lib/d1/schema-apps.ts +147 -14
  87. package/apps/storefront/src/lib/dev/activityIngestToken.ts +2 -4
  88. package/apps/storefront/src/lib/dev/activityStore.ts +3 -5
  89. package/apps/storefront/src/lib/dev/apiBase.ts +1 -4
  90. package/apps/storefront/src/lib/dev/cockpitStore.ts +1 -9
  91. package/apps/storefront/src/lib/dev/devDraft.ts +1 -1
  92. package/apps/storefront/src/lib/dev/previewStatus.ts +9 -21
  93. package/apps/storefront/src/lib/dev/rendezvousBroker.ts +9 -24
  94. package/apps/storefront/src/lib/edgeCache.ts +17 -0
  95. package/apps/storefront/src/lib/env.ts +51 -0
  96. package/apps/storefront/src/lib/http/fetchTransport.ts +63 -0
  97. package/apps/storefront/src/lib/i18n.ts +25 -0
  98. package/apps/storefront/src/lib/jsonld.ts +118 -0
  99. package/apps/storefront/src/lib/monitoring/manifest.ts +11 -11
  100. package/apps/storefront/src/lib/newsletter/confirmationEmail.ts +30 -0
  101. package/apps/storefront/src/lib/newsletter/consent.ts +23 -0
  102. package/apps/storefront/src/lib/newsletter/digest.ts +117 -0
  103. package/apps/storefront/src/lib/newsletter/resendClient.ts +79 -0
  104. package/apps/storefront/src/lib/newsletter/send.ts +265 -0
  105. package/apps/storefront/src/lib/newsletter/subscribers.ts +156 -0
  106. package/apps/storefront/src/lib/publish/adminPublishTab.ts +3519 -0
  107. package/apps/storefront/src/lib/publish/apex-readiness.ts +41 -18
  108. package/apps/storefront/src/lib/publish/dispatchHealth.ts +5 -7
  109. package/apps/storefront/src/lib/publish/domainState.ts +22 -13
  110. package/apps/storefront/src/lib/publish/panelPolling.ts +78 -0
  111. package/apps/storefront/src/lib/publish/shipWorkspace.ts +100 -42
  112. package/apps/storefront/src/lib/publish/stageBundleUpload.ts +215 -0
  113. package/apps/storefront/src/lib/rate/kvWindow.ts +53 -0
  114. package/apps/storefront/src/lib/search/index.ts +2 -2
  115. package/apps/storefront/src/lib/seo/alternates.ts +42 -0
  116. package/apps/storefront/src/lib/seo/meta.ts +65 -0
  117. package/apps/storefront/src/lib/social/golive.ts +212 -0
  118. package/apps/storefront/src/lib/social/notify.ts +32 -0
  119. package/apps/storefront/src/lib/social/tokenStore.ts +171 -0
  120. package/apps/storefront/src/lib/the-build/provider.ts +27 -0
  121. package/apps/storefront/src/lib/the-build/readingTime.ts +35 -0
  122. package/apps/storefront/src/lib/the-build/toc.ts +95 -0
  123. package/apps/storefront/src/lib/tot/ToTClient.ts +1 -1
  124. package/apps/storefront/src/lib/tot/d1Client.ts +2 -2
  125. package/apps/storefront/src/lib/tot/totClientInterface.ts +3 -4
  126. package/apps/storefront/src/lib/webhooks/deliveryStore.ts +16 -17
  127. package/apps/storefront/src/middleware/index.ts +130 -2
  128. package/apps/storefront/src/pages/admin/ops-timeline.astro +420 -0
  129. package/apps/storefront/src/pages/admin.astro +52 -1206
  130. package/apps/storefront/src/pages/api/activity.ts +137 -0
  131. package/apps/storefront/src/pages/api/admin/activity-alerts.ts +73 -0
  132. package/apps/storefront/src/pages/api/apps/admin/credentials/rotate.ts +27 -1
  133. package/apps/storefront/src/pages/api/apps/admin/install.ts +26 -1
  134. package/apps/storefront/src/pages/api/apps/admin/resume.ts +24 -1
  135. package/apps/storefront/src/pages/api/apps/admin/suspend.ts +24 -1
  136. package/apps/storefront/src/pages/api/apps/admin/uninstall.ts +25 -1
  137. package/apps/storefront/src/pages/api/apps/admin/update.ts +24 -1
  138. package/apps/storefront/src/pages/api/apps/admin/webhooks/deliveries/[deliveryId]/replay.ts +11 -0
  139. package/apps/storefront/src/pages/api/apps/internal/order-forward.ts +11 -0
  140. package/apps/storefront/src/pages/api/apps/v1/attribution.ts +20 -0
  141. package/apps/storefront/src/pages/api/apps/v1/webhooks/deliveries/[deliveryId]/replay.ts +12 -0
  142. package/apps/storefront/src/pages/api/blog/[collection]/[slug]/react.ts +104 -0
  143. package/apps/storefront/src/pages/api/cache-purge.ts +11 -0
  144. package/apps/storefront/src/pages/api/dashboard/enter-vendor.ts +30 -0
  145. package/apps/storefront/src/pages/api/newsletter/[collection]/subscribe.ts +146 -0
  146. package/apps/storefront/src/pages/api/newsletter/confirm.ts +75 -0
  147. package/apps/storefront/src/pages/api/newsletter/unsubscribe.ts +90 -0
  148. package/apps/storefront/src/pages/api/publish/stage-bundle.ts +70 -0
  149. package/apps/storefront/src/pages/api/rum/vitals.ts +21 -2
  150. package/apps/storefront/src/pages/auth/login.astro +5 -4
  151. package/apps/storefront/src/pages/blog/[slug].astro +96 -16
  152. package/apps/storefront/src/pages/blog/author/[author].astro +140 -0
  153. package/apps/storefront/src/pages/blog/category/[category].astro +67 -0
  154. package/apps/storefront/src/pages/blog/index.astro +2 -0
  155. package/apps/storefront/src/pages/blog/tag/[tag].astro +65 -0
  156. package/apps/storefront/src/pages/cockpit.astro +74 -12
  157. package/apps/storefront/src/pages/dashboard/[appDomain]/team.astro +15 -11
  158. package/apps/storefront/src/pages/search.astro +1 -1
  159. package/apps/storefront/src/pages/sitemap.xml.ts +20 -0
  160. package/apps/storefront/src/pages/the-build/[slug].astro +129 -0
  161. package/apps/storefront/src/pages/the-build/index.astro +146 -0
  162. package/apps/storefront/src/pages/the-build/rss.xml.ts +33 -0
  163. package/apps/storefront/src/styles/admin.css +1080 -0
  164. package/apps/storefront/tsconfig.json +5 -0
  165. package/package.json +1 -1
  166. package/packages/public-runtime/package.json +1 -0
  167. package/packages/public-runtime/src/activity/README.md +146 -0
  168. package/packages/public-runtime/src/activity/catalog.ts +553 -0
  169. package/packages/public-runtime/src/activity/event.ts +168 -0
  170. package/packages/public-runtime/src/activity/index.ts +16 -0
  171. package/packages/public-runtime/src/activity/redaction.ts +263 -0
  172. package/packages/public-runtime/src/candidate-index.ts +13 -0
  173. package/packages/public-runtime/src/catalog-d1.ts +1 -1
  174. package/packages/public-runtime/src/customization-preview.ts +25 -2
  175. package/packages/public-runtime/src/customization-runtime.ts +125 -3
  176. package/packages/public-runtime/src/customization-versioning.ts +10 -0
  177. package/packages/public-runtime/src/index.ts +7 -0
  178. package/packages/public-runtime/src/static-bundle.ts +357 -0
  179. package/packages/public-runtime/src/tenant.ts +36 -8
  180. package/scripts/build/copy-tenant-assets.mjs +14 -4
  181. package/scripts/dev/ai-edit.mjs +1 -1
  182. package/scripts/dev/checkout-watch.mjs +2 -2
  183. package/scripts/dev/file-browser.mjs +2 -4
  184. package/scripts/dev/file-writer.mjs +1 -1
  185. package/scripts/dev/git-status.mjs +2 -2
  186. package/scripts/dev/locate-handler.mjs +3 -3
  187. package/scripts/dev/port-check.mjs +3 -3
  188. package/scripts/dev/publish.mjs +5 -9
  189. package/scripts/dev/shot.mjs +1 -1
  190. package/scripts/dev/unified-diff.mjs +8 -3
  191. package/scripts/tot-dev.mjs +6 -9
  192. package/apps/storefront/src/lib/webhooks/signing.ts +0 -29
  193. package/apps/storefront/src/lib/webhooks/webhookSigningKey.ts +0 -146
@@ -0,0 +1,1080 @@
1
+ /*
2
+ * Storefront admin console styles — the white-labeled operations surface
3
+ * (apps/storefront/src/pages/admin.astro and its AdminXTab components).
4
+ *
5
+ * Global by design: admin.astro renders its own document shell instead of the
6
+ * public Layout, and every AdminXTab.astro relies on these class + token
7
+ * definitions. Externalized (not inline) so the strict CSP covers it as a
8
+ * hashed self stylesheet — see astro.config.mjs inlineStylesheets:"never".
9
+ */
10
+ :root {
11
+ color-scheme: light;
12
+ --admin-bg: #f5f7f6;
13
+ --admin-surface: #ffffff;
14
+ --admin-surface-soft: #f9fbfa;
15
+ --admin-surface-tint: #eef6f4;
16
+ --admin-ink: #16211f;
17
+ --admin-muted: #64716d;
18
+ --admin-muted-2: #8c9894;
19
+ --admin-line: #dce5e2;
20
+ --admin-line-strong: #bdcbc7;
21
+ --admin-teal: #007f79;
22
+ --admin-teal-dark: #005d58;
23
+ --admin-teal-soft: #dff4f1;
24
+ --admin-green: #137a55;
25
+ --admin-green-soft: #e3f5eb;
26
+ --admin-blue: #2458c7;
27
+ --admin-blue-soft: #e7efff;
28
+ --admin-amber: #a45d00;
29
+ --admin-amber-soft: #fff0d5;
30
+ --admin-red: #b42318;
31
+ --admin-red-soft: #fde7e4;
32
+ --admin-violet: #6941c6;
33
+ --admin-violet-soft: #efe9ff;
34
+ --admin-shadow: 0 18px 50px rgba(23, 33, 31, 0.08);
35
+ --admin-radius: 8px;
36
+ --admin-radius-sm: 6px;
37
+ --admin-scroll-offset: 104px;
38
+ --admin-font:
39
+ Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
40
+ "Segoe UI", sans-serif;
41
+ }
42
+
43
+ * {
44
+ box-sizing: border-box;
45
+ }
46
+
47
+ html {
48
+ max-width: 100%;
49
+ height: 100%;
50
+ overflow: hidden;
51
+ }
52
+
53
+ body {
54
+ margin: 0;
55
+ height: 100%;
56
+ min-height: 100vh;
57
+ background: var(--admin-bg);
58
+ color: var(--admin-ink);
59
+ font: 14px/1.5 var(--admin-font);
60
+ overflow: hidden;
61
+ }
62
+
63
+ button,
64
+ input,
65
+ select {
66
+ font: inherit;
67
+ }
68
+
69
+ button {
70
+ cursor: pointer;
71
+ }
72
+
73
+ svg {
74
+ width: 18px;
75
+ height: 18px;
76
+ stroke: currentColor;
77
+ stroke-width: 1.9;
78
+ stroke-linecap: round;
79
+ stroke-linejoin: round;
80
+ fill: none;
81
+ flex: 0 0 auto;
82
+ }
83
+
84
+ .shell {
85
+ display: grid;
86
+ grid-template-columns: 248px minmax(0, 1fr);
87
+ height: 100vh;
88
+ min-height: 0;
89
+ overflow: hidden;
90
+ }
91
+
92
+ .sidebar {
93
+ position: sticky;
94
+ top: 0;
95
+ height: 100vh;
96
+ min-height: 0;
97
+ display: flex;
98
+ flex-direction: column;
99
+ gap: 22px;
100
+ padding: 20px 16px;
101
+ overflow-y: auto;
102
+ overscroll-behavior: contain;
103
+ background: #101b18;
104
+ color: #eef7f5;
105
+ }
106
+
107
+ .brand {
108
+ display: flex;
109
+ align-items: center;
110
+ gap: 12px;
111
+ min-height: 42px;
112
+ }
113
+
114
+ .brand-mark {
115
+ width: 36px;
116
+ height: 36px;
117
+ display: grid;
118
+ place-items: center;
119
+ border-radius: var(--admin-radius);
120
+ background: #00a991;
121
+ color: #06231e;
122
+ font-weight: 800;
123
+ }
124
+
125
+ .brand b,
126
+ .store strong {
127
+ display: block;
128
+ font-size: 14px;
129
+ line-height: 1.1;
130
+ }
131
+
132
+ .brand span,
133
+ .store span {
134
+ display: block;
135
+ margin-top: 3px;
136
+ color: rgba(238, 247, 245, 0.7);
137
+ font-size: 12px;
138
+ }
139
+
140
+ .store {
141
+ display: grid;
142
+ gap: 4px;
143
+ padding: 12px;
144
+ border: 1px solid rgba(255, 255, 255, 0.12);
145
+ border-radius: var(--admin-radius);
146
+ background: rgba(255, 255, 255, 0.06);
147
+ }
148
+
149
+ /* Cross-surface hop to the developer cockpit — same card language as the
150
+ sidebar's other blocks, kept visually quieter than the nav tabs. */
151
+ .cockpit-link {
152
+ display: flex;
153
+ align-items: center;
154
+ gap: 8px;
155
+ padding: 10px 12px;
156
+ border: 1px solid rgba(255, 255, 255, 0.12);
157
+ border-radius: var(--admin-radius);
158
+ background: rgba(255, 255, 255, 0.04);
159
+ color: rgba(238, 247, 245, 0.85);
160
+ font-size: 13px;
161
+ text-decoration: none;
162
+ }
163
+ .cockpit-link:hover {
164
+ background: rgba(255, 255, 255, 0.1);
165
+ color: #fff;
166
+ }
167
+ .cockpit-link svg {
168
+ width: 15px;
169
+ height: 15px;
170
+ stroke: currentColor;
171
+ fill: none;
172
+ }
173
+
174
+ /* Signed-in-as chip (identity visibility — Trello 13075 postscript: an
175
+ owner staring at a read-only Publish tab could not tell WHO the shell
176
+ thought they were). Mirrors .store's card language; the standing line
177
+ states the resolved principal FOR THIS STORE, not a global role. */
178
+ .account {
179
+ display: grid;
180
+ grid-template-columns: auto 1fr;
181
+ gap: 10px;
182
+ align-items: center;
183
+ padding: 12px;
184
+ border: 1px solid rgba(255, 255, 255, 0.12);
185
+ border-radius: var(--admin-radius);
186
+ background: rgba(255, 255, 255, 0.06);
187
+ /* Pinned to the sidebar's lower-left (the conventional account slot) —
188
+ the sidebar is a flex column, so this soaks the remaining space. */
189
+ margin-top: auto;
190
+ }
191
+ .account .account-avatar {
192
+ display: grid;
193
+ place-items: center;
194
+ width: 32px;
195
+ height: 32px;
196
+ border-radius: 50%;
197
+ border: 1px solid rgba(255, 255, 255, 0.2);
198
+ background: rgba(255, 255, 255, 0.08);
199
+ }
200
+ .account .account-avatar svg {
201
+ width: 16px;
202
+ height: 16px;
203
+ stroke: currentColor;
204
+ fill: none;
205
+ stroke-width: 1.8;
206
+ }
207
+ .account .account-meta {
208
+ display: grid;
209
+ gap: 2px;
210
+ min-width: 0;
211
+ }
212
+ .account .account-email {
213
+ font-weight: 640;
214
+ font-size: 13px;
215
+ overflow: hidden;
216
+ text-overflow: ellipsis;
217
+ white-space: nowrap;
218
+ }
219
+ .account .account-standing {
220
+ color: rgba(238, 247, 245, 0.7);
221
+ font-size: 11px;
222
+ }
223
+ .account .account-standing[data-standing="none"] {
224
+ color: rgba(255, 196, 120, 0.9);
225
+ }
226
+ .account a {
227
+ color: inherit;
228
+ }
229
+ .account .account-signout button {
230
+ margin-top: 2px;
231
+ padding: 0;
232
+ border: 0;
233
+ background: none;
234
+ color: rgba(238, 247, 245, 0.6);
235
+ font-size: 11px;
236
+ text-decoration: underline;
237
+ cursor: pointer;
238
+ }
239
+ .account .account-signout button:hover {
240
+ color: rgba(238, 247, 245, 0.9);
241
+ }
242
+
243
+ .tenant-picker {
244
+ display: grid;
245
+ gap: 4px;
246
+ padding: 10px 12px;
247
+ border: 1px solid rgba(0, 169, 145, 0.4);
248
+ border-radius: var(--admin-radius);
249
+ background: rgba(0, 169, 145, 0.1);
250
+ }
251
+
252
+ .tenant-picker label {
253
+ color: rgba(238, 247, 245, 0.7);
254
+ font-size: 11px;
255
+ font-weight: 760;
256
+ text-transform: uppercase;
257
+ }
258
+
259
+ .tenant-picker select {
260
+ min-height: 34px;
261
+ border: 1px solid rgba(255, 255, 255, 0.2);
262
+ border-radius: var(--admin-radius-sm);
263
+ background: #101b18;
264
+ color: #eef7f5;
265
+ }
266
+
267
+ .tenant-picker-denied {
268
+ padding: 10px 12px;
269
+ border: 1px solid var(--admin-amber);
270
+ border-radius: var(--admin-radius);
271
+ background: rgba(164, 93, 0, 0.16);
272
+ color: #eef7f5;
273
+ font-size: 12px;
274
+ }
275
+
276
+ .tenant-picker-denied code {
277
+ font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
278
+ }
279
+
280
+ .nav {
281
+ display: grid;
282
+ gap: 4px;
283
+ }
284
+
285
+ .nav a {
286
+ display: flex;
287
+ align-items: center;
288
+ gap: 10px;
289
+ min-height: 40px;
290
+ padding: 0 10px;
291
+ border-radius: var(--admin-radius-sm);
292
+ color: rgba(238, 247, 245, 0.74);
293
+ text-decoration: none;
294
+ }
295
+
296
+ .nav a.active {
297
+ background: rgba(0, 169, 145, 0.18);
298
+ color: #ffffff;
299
+ }
300
+
301
+ .nav-group {
302
+ display: grid;
303
+ gap: 3px;
304
+ }
305
+
306
+ .nav-subnav {
307
+ display: grid;
308
+ gap: 2px;
309
+ margin: 0 0 3px 28px;
310
+ padding-left: 10px;
311
+ border-left: 1px solid rgba(255, 255, 255, 0.14);
312
+ }
313
+
314
+ .nav-subnav a {
315
+ min-height: 32px;
316
+ padding: 0 8px;
317
+ gap: 8px;
318
+ font-size: 12px;
319
+ }
320
+
321
+ .nav-subnav svg {
322
+ width: 16px;
323
+ height: 16px;
324
+ }
325
+
326
+ .health {
327
+ margin-top: auto;
328
+ display: grid;
329
+ gap: 9px;
330
+ padding: 12px;
331
+ border: 1px solid rgba(255, 255, 255, 0.12);
332
+ border-radius: var(--admin-radius);
333
+ background: rgba(255, 255, 255, 0.05);
334
+ }
335
+
336
+ .health-row {
337
+ display: flex;
338
+ align-items: center;
339
+ justify-content: space-between;
340
+ gap: 10px;
341
+ font-size: 12px;
342
+ color: rgba(238, 247, 245, 0.72);
343
+ }
344
+
345
+ .health-row strong {
346
+ color: #ffffff;
347
+ }
348
+
349
+ .main {
350
+ min-width: 0;
351
+ min-height: 0;
352
+ height: 100vh;
353
+ overflow-x: hidden;
354
+ overflow-y: auto;
355
+ overscroll-behavior: contain;
356
+ }
357
+
358
+ .content,
359
+ .band,
360
+ .panel,
361
+ .panel-body,
362
+ .table-wrap {
363
+ min-width: 0;
364
+ max-width: 100%;
365
+ }
366
+
367
+ .topbar {
368
+ position: sticky;
369
+ top: 0;
370
+ z-index: 30;
371
+ display: flex;
372
+ align-items: center;
373
+ justify-content: space-between;
374
+ gap: 18px;
375
+ min-height: 68px;
376
+ padding: 14px 24px;
377
+ border-bottom: 1px solid var(--admin-line);
378
+ background: rgba(245, 247, 246, 0.94);
379
+ backdrop-filter: blur(16px);
380
+ }
381
+
382
+ .page-title h1 {
383
+ margin: 0;
384
+ font-size: 22px;
385
+ font-weight: 760;
386
+ }
387
+
388
+ .page-title p {
389
+ margin: 2px 0 0;
390
+ color: var(--admin-muted);
391
+ font-size: 13px;
392
+ }
393
+
394
+ .page-title,
395
+ .page-title p,
396
+ .note,
397
+ code {
398
+ min-width: 0;
399
+ overflow-wrap: anywhere;
400
+ }
401
+
402
+ .actions {
403
+ display: flex;
404
+ flex-wrap: wrap;
405
+ gap: 8px;
406
+ }
407
+
408
+ .btn,
409
+ .icon-btn {
410
+ min-height: 38px;
411
+ display: inline-flex;
412
+ align-items: center;
413
+ justify-content: center;
414
+ gap: 8px;
415
+ border: 1px solid var(--admin-line-strong);
416
+ border-radius: var(--admin-radius-sm);
417
+ background: var(--admin-surface);
418
+ color: var(--admin-ink);
419
+ text-decoration: none;
420
+ white-space: nowrap;
421
+ }
422
+
423
+ .btn {
424
+ padding: 0 13px;
425
+ font-weight: 680;
426
+ max-width: 100%;
427
+ }
428
+
429
+ .icon-btn {
430
+ width: 38px;
431
+ padding: 0;
432
+ }
433
+
434
+ .btn.primary {
435
+ border-color: var(--admin-teal-dark);
436
+ background: var(--admin-teal);
437
+ color: #ffffff;
438
+ }
439
+
440
+ .floating-ask {
441
+ position: fixed;
442
+ right: 24px;
443
+ bottom: 24px;
444
+ z-index: 80;
445
+ min-height: 58px;
446
+ max-width: min(280px, calc(100vw - 32px));
447
+ display: inline-flex;
448
+ align-items: center;
449
+ gap: 10px;
450
+ padding: 9px 15px 9px 10px;
451
+ border: 1px solid rgba(0, 93, 88, 0.24);
452
+ border-radius: 999px;
453
+ background: var(--admin-teal);
454
+ color: #ffffff;
455
+ box-shadow: 0 16px 38px rgba(22, 33, 31, 0.22);
456
+ }
457
+
458
+ .floating-ask-icon {
459
+ width: 40px;
460
+ height: 40px;
461
+ display: grid;
462
+ place-items: center;
463
+ border-radius: 50%;
464
+ background: rgba(255, 255, 255, 0.16);
465
+ }
466
+
467
+ .floating-ask-label {
468
+ display: grid;
469
+ gap: 1px;
470
+ min-width: 0;
471
+ text-align: left;
472
+ }
473
+
474
+ .floating-ask-label strong {
475
+ font-size: 14px;
476
+ line-height: 1.1;
477
+ }
478
+
479
+ .floating-ask-label small {
480
+ max-width: 160px;
481
+ overflow: hidden;
482
+ color: rgba(255, 255, 255, 0.78);
483
+ font-size: 11px;
484
+ font-weight: 680;
485
+ line-height: 1.2;
486
+ text-overflow: ellipsis;
487
+ white-space: nowrap;
488
+ }
489
+
490
+ .content {
491
+ display: grid;
492
+ grid-template-columns: minmax(0, 1fr);
493
+ gap: 18px;
494
+ padding: 20px 24px 40px;
495
+ }
496
+
497
+ .band {
498
+ display: grid;
499
+ grid-template-columns: minmax(0, 1fr);
500
+ gap: 14px;
501
+ }
502
+
503
+ [data-admin-panel],
504
+ [data-admin-guide-section] {
505
+ scroll-margin-top: var(--admin-scroll-offset);
506
+ }
507
+
508
+ html.admin-tabs-ready [data-admin-panel] {
509
+ display: none;
510
+ }
511
+
512
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="orders"] #orders,
513
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="products"] #products,
514
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="subscriptions"] #subscriptions,
515
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="customers"] #customers,
516
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="fulfillment"] #fulfillment,
517
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="reporting"] #reporting,
518
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="ai-workflows"] #ai-workflows,
519
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="blog"] #blog,
520
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="publish"] #publish,
521
+ html.admin-tabs-ready[data-admin-mode="work-area"][data-admin-tab="settings"] #settings {
522
+ display: grid;
523
+ }
524
+
525
+ html.admin-tabs-ready[data-admin-mode="work-area"] [data-admin-guide-section],
526
+ html.admin-tabs-ready[data-admin-mode="work-area"] [data-admin-tab-help] {
527
+ display: none;
528
+ }
529
+
530
+ html[data-internal-admin-guide="false"] [data-admin-internal-only] {
531
+ display: none !important;
532
+ }
533
+
534
+ .section-title {
535
+ display: flex;
536
+ align-items: center;
537
+ justify-content: space-between;
538
+ gap: 12px;
539
+ }
540
+
541
+ .section-title h2 {
542
+ margin: 0;
543
+ font-size: 16px;
544
+ }
545
+
546
+ .section-title p {
547
+ margin: 4px 0 0;
548
+ color: var(--admin-muted);
549
+ font-size: 13px;
550
+ }
551
+
552
+ .grid {
553
+ display: grid;
554
+ grid-template-columns: minmax(0, 1fr);
555
+ gap: 12px;
556
+ }
557
+
558
+ .grid.cols-2 {
559
+ grid-template-columns: repeat(2, minmax(0, 1fr));
560
+ }
561
+
562
+ .grid.cols-3 {
563
+ grid-template-columns: repeat(3, minmax(0, 1fr));
564
+ }
565
+
566
+ .grid.cols-4 {
567
+ grid-template-columns: repeat(4, minmax(0, 1fr));
568
+ }
569
+
570
+ .panel {
571
+ border: 1px solid var(--admin-line);
572
+ border-radius: var(--admin-radius);
573
+ background: var(--admin-surface);
574
+ }
575
+
576
+ .panel-head {
577
+ display: flex;
578
+ align-items: center;
579
+ justify-content: space-between;
580
+ gap: 12px;
581
+ min-height: 50px;
582
+ padding: 13px 14px;
583
+ border-bottom: 1px solid var(--admin-line);
584
+ }
585
+
586
+ .panel-head h3 {
587
+ margin: 0;
588
+ display: flex;
589
+ align-items: center;
590
+ gap: 8px;
591
+ font-size: 15px;
592
+ }
593
+
594
+ .panel-body {
595
+ display: grid;
596
+ grid-template-columns: minmax(0, 1fr);
597
+ gap: 12px;
598
+ padding: 14px;
599
+ }
600
+
601
+ .metric {
602
+ min-height: 84px;
603
+ padding: 14px;
604
+ border: 1px solid var(--admin-line);
605
+ border-radius: var(--admin-radius);
606
+ background: var(--admin-surface);
607
+ }
608
+
609
+ .metric span,
610
+ .field label {
611
+ display: block;
612
+ color: var(--admin-muted);
613
+ font-size: 11px;
614
+ font-weight: 760;
615
+ text-transform: uppercase;
616
+ }
617
+
618
+ .metric strong {
619
+ display: block;
620
+ margin-top: 9px;
621
+ font-size: 24px;
622
+ }
623
+
624
+ .metric small {
625
+ display: block;
626
+ margin-top: 3px;
627
+ color: var(--admin-muted);
628
+ font-size: 12px;
629
+ }
630
+
631
+ .chip {
632
+ display: inline-flex;
633
+ align-items: center;
634
+ gap: 5px;
635
+ min-height: 23px;
636
+ padding: 0 8px;
637
+ border-radius: 999px;
638
+ background: var(--admin-surface-tint);
639
+ color: #3f4d49;
640
+ font-size: 12px;
641
+ font-weight: 740;
642
+ white-space: nowrap;
643
+ }
644
+
645
+ .chip.green {
646
+ background: var(--admin-green-soft);
647
+ color: var(--admin-green);
648
+ }
649
+
650
+ .chip.teal {
651
+ background: var(--admin-teal-soft);
652
+ /* Slightly darker than --admin-teal (#007f79): the shared token only
653
+ reaches ~4.26:1 against --admin-teal-soft, just under WCAG AA's
654
+ 4.5:1 for this chip's 12px text (hardening-qa a11y pass). Scoped to
655
+ this rule only — --admin-teal itself stays unchanged since it is
656
+ also used as a background (e.g. .btn.primary) where the pairing
657
+ and contrast requirement are different. */
658
+ color: #007973;
659
+ }
660
+
661
+ .chip.blue {
662
+ background: var(--admin-blue-soft);
663
+ color: var(--admin-blue);
664
+ }
665
+
666
+ .chip.amber {
667
+ background: var(--admin-amber-soft);
668
+ color: var(--admin-amber);
669
+ }
670
+
671
+ .chip.red {
672
+ background: var(--admin-red-soft);
673
+ color: var(--admin-red);
674
+ }
675
+
676
+ .chip.violet {
677
+ background: var(--admin-violet-soft);
678
+ color: var(--admin-violet);
679
+ }
680
+
681
+ .swatches {
682
+ display: grid;
683
+ grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
684
+ gap: 10px;
685
+ }
686
+
687
+ .swatch {
688
+ overflow: hidden;
689
+ border: 1px solid var(--admin-line);
690
+ border-radius: var(--admin-radius-sm);
691
+ background: var(--admin-surface);
692
+ }
693
+
694
+ .swatch-color {
695
+ min-height: 58px;
696
+ }
697
+
698
+ .swatch-meta {
699
+ padding: 10px;
700
+ }
701
+
702
+ .swatch-meta b {
703
+ display: block;
704
+ font-size: 13px;
705
+ }
706
+
707
+ .swatch-meta code,
708
+ .note code {
709
+ color: var(--admin-muted);
710
+ font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
711
+ font-size: 12px;
712
+ }
713
+
714
+ .field {
715
+ min-width: 0;
716
+ padding: 11px;
717
+ border: 1px solid var(--admin-line);
718
+ border-radius: var(--admin-radius-sm);
719
+ background: #fcfdfc;
720
+ }
721
+
722
+ .field strong {
723
+ display: block;
724
+ margin-top: 6px;
725
+ font-size: 13px;
726
+ }
727
+
728
+ .field p {
729
+ margin: 5px 0 0;
730
+ color: var(--admin-muted);
731
+ font-size: 12px;
732
+ }
733
+
734
+ .ship-gate {
735
+ display: flex;
736
+ align-items: center;
737
+ justify-content: space-between;
738
+ gap: 14px;
739
+ padding: 14px;
740
+ border: 1px solid #a6d8c0;
741
+ border-radius: var(--admin-radius);
742
+ background: #eefaf3;
743
+ }
744
+
745
+ .ship-gate.amber {
746
+ border-color: #f1c883;
747
+ background: #fff6e7;
748
+ }
749
+
750
+ .ship-gate-main,
751
+ .risk-alert-main {
752
+ display: flex;
753
+ align-items: center;
754
+ gap: 12px;
755
+ min-width: 0;
756
+ }
757
+
758
+ .seal {
759
+ width: 42px;
760
+ height: 42px;
761
+ display: grid;
762
+ place-items: center;
763
+ border-radius: 50%;
764
+ background: var(--admin-green);
765
+ color: #ffffff;
766
+ }
767
+
768
+ .ship-gate.amber .seal {
769
+ background: var(--admin-amber);
770
+ }
771
+
772
+ .ship-gate b,
773
+ .risk-alert b {
774
+ display: block;
775
+ font-size: 15px;
776
+ }
777
+
778
+ .ship-gate span,
779
+ .risk-alert span {
780
+ display: block;
781
+ margin-top: 3px;
782
+ color: var(--admin-muted);
783
+ font-size: 12px;
784
+ }
785
+
786
+ .risk-alert {
787
+ display: flex;
788
+ align-items: center;
789
+ justify-content: space-between;
790
+ gap: 14px;
791
+ padding: 12px 14px;
792
+ border: 1px solid #f1c883;
793
+ border-radius: var(--admin-radius);
794
+ background: #fff6e7;
795
+ }
796
+
797
+ /* A JS-toggled `.risk-alert` (e.g. the degraded-forge strip) must stay hidden
798
+ when `hidden` is set — the base display:flex above would otherwise win over
799
+ the UA [hidden] rule and keep it visible. */
800
+ .risk-alert[hidden] {
801
+ display: none;
802
+ }
803
+
804
+ .risk-alert svg {
805
+ color: var(--admin-amber);
806
+ }
807
+
808
+ .order-assist-grid {
809
+ display: grid;
810
+ grid-template-columns: repeat(3, minmax(0, 1fr));
811
+ gap: 10px;
812
+ }
813
+
814
+ .order-assist-card {
815
+ display: grid;
816
+ gap: 7px;
817
+ min-width: 0;
818
+ padding: 12px;
819
+ border: 1px solid var(--admin-line);
820
+ border-radius: var(--admin-radius-sm);
821
+ background: var(--admin-surface);
822
+ }
823
+
824
+ .order-assist-card strong {
825
+ font-size: 14px;
826
+ }
827
+
828
+ .order-assist-card p {
829
+ margin: 0;
830
+ color: var(--admin-muted);
831
+ font-size: 12px;
832
+ }
833
+
834
+ .tabs {
835
+ display: flex;
836
+ gap: 6px;
837
+ max-width: 100%;
838
+ overflow-x: auto;
839
+ border-bottom: 1px solid var(--admin-line);
840
+ }
841
+
842
+ .mobile-tabbar {
843
+ display: none;
844
+ }
845
+
846
+ .tab {
847
+ flex: 0 0 auto;
848
+ min-height: 38px;
849
+ display: inline-flex;
850
+ align-items: center;
851
+ padding: 0 12px;
852
+ border: 0;
853
+ border-bottom: 2px solid transparent;
854
+ background: transparent;
855
+ color: var(--admin-muted);
856
+ font-weight: 760;
857
+ text-decoration: none;
858
+ }
859
+
860
+ .tab.active {
861
+ border-color: var(--admin-teal);
862
+ color: var(--admin-ink);
863
+ }
864
+
865
+ .table-wrap {
866
+ overflow-x: auto;
867
+ border: 1px solid var(--admin-line);
868
+ border-radius: var(--admin-radius);
869
+ background: var(--admin-surface);
870
+ }
871
+
872
+ table {
873
+ width: 100%;
874
+ min-width: 860px;
875
+ border-collapse: collapse;
876
+ font-size: 13px;
877
+ }
878
+
879
+ th {
880
+ height: 38px;
881
+ padding: 0 12px;
882
+ border-bottom: 1px solid var(--admin-line);
883
+ background: var(--admin-surface-soft);
884
+ color: var(--admin-muted);
885
+ font-size: 11px;
886
+ font-weight: 760;
887
+ text-align: left;
888
+ text-transform: uppercase;
889
+ white-space: nowrap;
890
+ }
891
+
892
+ td {
893
+ height: 46px;
894
+ padding: 7px 12px;
895
+ border-bottom: 1px solid var(--admin-line);
896
+ vertical-align: middle;
897
+ }
898
+
899
+ tr:last-child td {
900
+ border-bottom: 0;
901
+ }
902
+
903
+ .subtle {
904
+ display: block;
905
+ margin-top: 2px;
906
+ color: var(--admin-muted);
907
+ font-size: 12px;
908
+ }
909
+
910
+ .money,
911
+ .action {
912
+ text-align: right;
913
+ }
914
+
915
+ .check-row {
916
+ display: grid;
917
+ grid-template-columns: minmax(120px, 0.36fr) minmax(0, 1fr) auto;
918
+ gap: 10px;
919
+ align-items: center;
920
+ padding: 10px 0;
921
+ border-bottom: 1px solid var(--admin-line);
922
+ }
923
+
924
+ .check-row:last-child {
925
+ border-bottom: 0;
926
+ }
927
+
928
+ .check-row.blocking {
929
+ margin: 0 -8px;
930
+ padding: 10px 8px;
931
+ border: 1px solid #f1c883;
932
+ border-radius: var(--admin-radius-sm);
933
+ background: #fff8ec;
934
+ }
935
+
936
+ .check-row b {
937
+ font-size: 13px;
938
+ }
939
+
940
+ .check-row p {
941
+ margin: 2px 0 0;
942
+ color: var(--admin-muted);
943
+ font-size: 12px;
944
+ }
945
+
946
+ .type-sample h3 {
947
+ margin: 0 0 8px;
948
+ font-size: 25px;
949
+ line-height: 1.12;
950
+ }
951
+
952
+ .type-sample p {
953
+ margin: 0;
954
+ color: var(--admin-muted);
955
+ }
956
+
957
+ .note {
958
+ margin: 0;
959
+ color: var(--admin-muted);
960
+ font-size: 13px;
961
+ }
962
+
963
+ @media (max-width: 1120px) {
964
+ .shell {
965
+ grid-template-columns: 76px minmax(0, 1fr);
966
+ }
967
+
968
+ .brand b,
969
+ .brand span,
970
+ .store,
971
+ .nav span,
972
+ .nav-subnav,
973
+ .health {
974
+ display: none;
975
+ }
976
+
977
+ .sidebar {
978
+ align-items: center;
979
+ padding-inline: 12px;
980
+ }
981
+
982
+ .nav a {
983
+ justify-content: center;
984
+ padding: 0;
985
+ }
986
+
987
+ .grid.cols-4,
988
+ .grid.cols-3,
989
+ .order-assist-grid {
990
+ grid-template-columns: repeat(2, minmax(0, 1fr));
991
+ }
992
+ }
993
+
994
+ @media (max-width: 760px) {
995
+ html,
996
+ body {
997
+ height: auto;
998
+ min-height: 100%;
999
+ overflow-x: hidden;
1000
+ overflow-y: auto;
1001
+ }
1002
+
1003
+ .shell {
1004
+ grid-template-columns: 1fr;
1005
+ height: auto;
1006
+ min-height: 100vh;
1007
+ overflow: visible;
1008
+ }
1009
+
1010
+ .main {
1011
+ height: auto;
1012
+ min-height: 0;
1013
+ overflow: visible;
1014
+ }
1015
+
1016
+ .sidebar {
1017
+ position: static;
1018
+ height: auto;
1019
+ overflow: visible;
1020
+ flex-direction: row;
1021
+ align-items: center;
1022
+ }
1023
+
1024
+ .nav {
1025
+ display: none;
1026
+ }
1027
+
1028
+ .mobile-tabbar {
1029
+ position: sticky;
1030
+ top: 0;
1031
+ z-index: 29;
1032
+ display: flex;
1033
+ padding-inline: 16px;
1034
+ background: rgba(245, 247, 246, 0.94);
1035
+ backdrop-filter: blur(16px);
1036
+ }
1037
+
1038
+ .topbar,
1039
+ .ship-gate,
1040
+ .risk-alert,
1041
+ .section-title,
1042
+ .panel-head {
1043
+ align-items: flex-start;
1044
+ flex-direction: column;
1045
+ }
1046
+
1047
+ .content,
1048
+ .topbar {
1049
+ padding-inline: 16px;
1050
+ }
1051
+
1052
+ .floating-ask {
1053
+ right: 16px;
1054
+ bottom: 16px;
1055
+ }
1056
+
1057
+ [data-admin-panel],
1058
+ [data-admin-guide-section] {
1059
+ scroll-margin-top: 16px;
1060
+ }
1061
+
1062
+ .actions {
1063
+ width: 100%;
1064
+ }
1065
+
1066
+ .actions .btn {
1067
+ flex: 1 1 150px;
1068
+ }
1069
+
1070
+ .grid.cols-4,
1071
+ .grid.cols-3,
1072
+ .grid.cols-2,
1073
+ .order-assist-grid {
1074
+ grid-template-columns: 1fr;
1075
+ }
1076
+
1077
+ .check-row {
1078
+ grid-template-columns: 1fr;
1079
+ }
1080
+ }