.mm-grid-shell {
  --mm-text: #101828;
  --mm-muted: #6a7282;
  --mm-soft: #f3f4f6;
  --mm-separator: #f3f4f6;
  --mm-border: #e5e7eb;
  --mm-surface: white;
  --mm-heading: #f9fafb;
  --mm-identity: 300px;
  --mm-day: 32px;
  --mm-gap: 1px;
  color: var(--mm-text);
  min-width: 0;
  container-type: inline-size;
}
.mm-board { border-radius: 12px; }
.mm-grid-scroller {
  overflow: auto;
  height: calc(100vh - 320px + 49px);
  min-height: 349px;
  scroll-padding-top: 49px;
  background: var(--mm-surface);
}
.mm-board .mm-grid-scroller { border-radius: 11px 11px 0 0; }
.mm-grid-body { min-width: calc(var(--mm-identity) + var(--mm-count) * (var(--mm-day) + var(--mm-gap)) - var(--mm-gap)); }
.mm-grid-row, .mm-grid-head { display: flex; align-items: stretch; }
.mm-grid-head {
  position: sticky;
  top: 0;
  z-index: 3;
  height: 49px;
  border-bottom: 1px solid var(--mm-border);
  background: rgb(249 250 251 / .9);
}
.mm-grid-item { border-top: 1px solid var(--mm-separator); }
.mm-grid-ident, .mm-grid-head-name { position: sticky; left: 0; z-index: 1; width: var(--mm-identity); min-width: var(--mm-identity); flex: none; border-right: 1px solid var(--mm-separator); }
.mm-grid-ident { display: flex; gap: 12px; align-items: center; padding: 8px 8px 8px 16px; background: var(--mm-surface); }
.mm-grid-head-name { display: flex; align-items: center; padding: 16px; background: var(--mm-heading); color: var(--mm-muted); font-weight: 600; }
.mm-grid-days { display: flex; flex: 1; align-items: center; min-width: 0; gap: var(--mm-gap); }
.mm-grid-head-day, .mm-grid-day { min-width: var(--mm-day); flex: 1 0 0; text-align: center; }
.mm-grid-head-day { display: grid; align-content: center; line-height: 1; }
.mm-grid-head-day b { font-size: 10px; }
.mm-grid-head-day small { font-size: 8px; text-transform: uppercase; }
.mm-grid-day { display: grid; place-items: center; height: 32px; font-size: 10px; font-weight: 700; color: white; }
.mm-grid-day[data-level="good"] { background-color: #00c950; }
.mm-grid-day[data-level="medium"] { background-color: #fdc700; }
.mm-grid-day[data-level="low"] { background-color: #fb2c36; }
.mm-grid-day[data-level="none"] { background-color: var(--mm-soft); }

.mk-page .mm-grid-disclose {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 18px;
  height: 18px;
  padding: 2px;
  border: 0;
  border-radius: 4px;
  line-height: 0;
  background: transparent;
  color: #99a1af;
}
.mk-page .mm-grid-disclose:hover { background: var(--mm-soft); color: var(--mm-muted); }
.mm-grid-disclose svg { transition: transform .15s; }
.mm-grid-disclose[aria-expanded="true"] svg { transform: rotate(180deg); }
.mm-grid-thumb-col { display: flex; flex: none; gap: 4px; align-items: center; flex-direction: column; }
.mm-grid-thumb { position: relative; display: flex; }
.mm-grid-status { position: absolute; width: 10px; height: 10px; border-radius: 50%; border: 2px solid white; left: -2px; top: -2px; background: #00c950; }
.mm-grid-status.paused { background: #ff6900; }
.mm-grid-status.review { background: #ad46ff; }
.mm-grid-copy { min-width: 0; flex: 1; }
.mm-grid-codes, .mm-grid-stats, .mm-grid-store { display: flex; align-items: center; }
.mm-grid-code, .mm-grid-name { display: block; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.mm-grid-name { font-size: 12px; font-weight: 500; }
.mm-grid-stats { gap: 4px; flex-wrap: wrap; }
.mm-grid-stat, .mm-grid-flash-badge, .mm-grid-type { display: inline-flex; align-items: center; gap: 3px; border-radius: 4px; padding: 1px 4px; font-size: 10px; white-space: nowrap; font-weight: 600; }
.mm-grid-stat { color: #4a5565; background: #f9fafb; border: 1px solid var(--mm-border); }
.mm-grid-stat svg { stroke-width: 2; }
.mm-grid-store { text-transform: uppercase; gap: 4px; font-size: 10px; color: var(--mm-muted); }
.mm-grid-store span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mm-grid-flash-badge { background: #fffbeb; color: #b45309; }
.mm-grid-details { position: sticky; left: 0; width: calc(100cqw - 2px); max-width: 100%; }
.mm-grid-empty { display: grid; place-content: center; min-height: 120px; text-align: center; gap: 4px; color: var(--mm-muted); }
.mm-grid-empty p { margin: 0; }
.mm-grid-copy > * + * { margin-top: 3px; }
.mm-grid-codes { gap: 4px; }
.mk-page .mm-grid-code {
  min-width: 0;
  padding: 0 4px;
  font: 400 9px/1.43 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
  text-align: left;
  color: #6a7282;
  background: #f9fafb;
  border: 1px solid var(--mm-border);
  border-radius: 4px;
}
.mk-page .mm-grid-sku {
  font-size: 10px;
  margin: 0 4px 0 auto;
  max-width: 90px;
  flex: 0 1 auto;
  color: #99a1af;
  background: transparent;
  padding: 0;
  border: 0;
}
.mk-page .mm-grid-code:hover { background: #eff6ff; color: #155dfc; }
.mm-grid-day.mm-grid-campaign-day { background-image: repeating-linear-gradient(45deg, transparent, transparent 2px, rgb(0 0 0 / 10%) 2px, rgb(0 0 0 / 10%) 4px); }
.mm-grid-head-name { text-transform: uppercase; font-size: 11px; letter-spacing: .5px; }
.mm-grid-head-day { gap: 3px; }
.mm-grid-head-day small { color: var(--mm-muted); }
.mm-grid-day:focus-visible { outline: 2px solid #344054; outline-offset: -2px; }
.mm-grid-day.mm-grid-future, .mm-grid-day.mm-grid-padding-day { background: var(--mm-soft); }
.mm-grid-tip {
  position: fixed;
  z-index: 100;
  width: 208px;
  max-width: calc(100vw - 16px);
  max-height: calc(100dvh - 16px);
  overflow: auto;
  pointer-events: none;
  background: #fff;
  color: #344054;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 25px 50px -12px rgb(0 0 0 / 25%);
  font: 10px/1.43 Sora,Arial,sans-serif;
}
.mm-tip-date { display: block; font-size: 10px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: #e60076; margin: -12px -12px 12px; padding: 6px 12px; border-bottom: 1px solid #fce7f3; background: rgb(253 242 248 / 50%); }
.mm-tip-group + .mm-tip-group, .mm-tip-offer { margin-top: 12px; }
.mm-tip-group > b, .mm-tip-offer > b { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: 10px; }
.mm-tip-metric { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; color: #6a7282; }
.mm-tip-metric + .mm-tip-metric { margin-top: 4px; }
.mm-tip-metric strong { color: #1e2939; font-variant-numeric: tabular-nums; }
.mm-tip-offer { color: #92400e; }
.mm-tip-offer > b { text-transform: uppercase; }
@media(max-width: 650px) {
  .mm-grid-shell { --mm-identity: min(224px, 56vw); }
  .mm-grid-ident { padding-left: 6px; gap: 5px; }
}
@media (prefers-reduced-motion: reduce) { .mm-grid-disclose svg { transition: none; } }

.mm-grid-shopee .mm-grid-campaign-day { box-shadow: inset 0 0 0 1px #fbbf24; }
.mm-grid-ad-icon { display: grid; place-items: center; position: absolute; top: -2px; right: -2px; padding: 2px; border-radius: 50%; background: #2b7fff; color: white; }
.mm-grid-ad-metrics { display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 9px; line-height: 1.2; color: var(--mm-muted); }
.mm-grid-ad-metrics span:first-child { color: #155dfc; font-weight: 700; }
.mm-grid-type { font-weight: 700; color: var(--mm-muted); background: var(--mm-soft); }
.mm-grid-type.mm-grid-premium { color: #8200db; background: #f3e8ff; }
.mm-grid-full { display: inline-flex; align-items: center; color: #eab308; }
.mm-grid-full svg { width: 12px; height: 12px; }
.mm-grid-flash-icon { position: absolute; bottom: -4px; right: -4px; display: flex; color: #ffb900; filter: drop-shadow(0 1px 1px rgb(0 0 0 / .15)); }
.mm-grid-flash-icon svg { width: 14px; height: 14px; }
.mm-copy-input { position: fixed; inset: 0 auto auto 0; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
.mm-copy-feedback { position: fixed; z-index: 160; left: 50%; bottom: 24px; transform: translateX(-50%); border-radius: 8px; background: #1e2939; color: white; padding: 8px 12px; font: 500 12px/1.4 Sora,Arial,sans-serif; pointer-events: none; }

.mm-grid-thumb .product-thumb { border-radius: 4px; border: 1px solid var(--mm-border); }
