/* Product-shaped controls, using the same floating windows as Create and Share. */
.mg-stage { position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); align-items: start; gap: clamp(24px, 4vw, 56px); padding: clamp(28px, 4.5vw, 64px); border-radius: 26px; overflow: hidden; }
.mg-stage > :not(.dz) { position: relative; z-index: 1; }
.mg-spaces { padding-top: 4px; }
.mg-switch { display: flex; align-items: center; gap: 10px; min-height: 46px; width: fit-content; max-width: 100%; padding: 9px 13px; border-radius: 12px; background: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.65); text-align: left; }
.mg-switch b { font-size: 15px; font-weight: 650; }
.mg-switch > .ic { width: 14px; height: 14px; margin-left: 7px; color: var(--ink-2); transform: rotate(180deg); }
.mg-menu.win, .mg-everything.win { background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; }
.mg-everything .win-bar { background: var(--surface-solid); }
.mg-menu { margin-top: 9px; padding: 14px 9px 9px; }
.mg-menu-label { padding: 0 10px 9px; color: var(--ink-2); font-size: 12px; font-weight: 600; }
.mg-space-list { display: grid; gap: 4px; }
.mg-space { display: flex; align-items: center; gap: 10px; min-height: 65px; padding: 10px; border-radius: 10px; text-align: left; }
.mg-space:hover { background: var(--surface-2); }
.mg-space[aria-pressed="true"] { background: var(--surface-3); }
.mg-space-icon { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: rgba(255,255,255,.8); box-shadow: inset 0 0 0 1px var(--line); font-size: 13px; font-weight: 600; }
.mg-space > span:nth-child(2) { flex: 1; min-width: 0; font-size: 14px; font-weight: 550; line-height: 1.4; }
.mg-space small { display: block; margin-top: 3px; font-size: 11px; font-weight: 400; color: var(--ink-2); line-height: 1.4; }
.mg-check { width: 15px; height: 15px; color: var(--ink-2); visibility: hidden; }
.mg-space[aria-pressed="true"] .mg-check { visibility: visible; }
.mg-everything { margin-top: 24px; }
.mg-current { margin-left: auto; color: var(--ink-2); font-size: 11.5px; }
.mg-body { padding: 24px 24px 16px; }
.mg-body h3 { font: 600 25px/1.15 var(--head); letter-spacing: -.03em; }
.mg-sub { margin-top: 7px; font-size: 12.5px; color: var(--ink-2); }
.mg-search { display: flex; align-items: center; gap: 10px; height: 46px; margin-top: 22px; padding: 0 12px; border-radius: 11px; background: rgba(255,255,255,.7); box-shadow: inset 0 0 0 1px var(--line-2); }
.mg-search.is-searching { box-shadow: inset 0 0 0 1.5px var(--ink), 0 3px 12px rgba(12,17,48,.06); }
.mg-search > .ic { width: 18px; height: 18px; color: var(--ink-2); }
.mg-query-wrap { display: flex; align-items: center; min-width: 0; font-size: 14px; user-select: none; }
.mg-caret { width: 1.5px; height: 18px; margin-left: 2px; background: var(--ink); opacity: 0; }
.mg-search.is-searching .mg-caret { animation: mg-blink .8s step-end infinite; }
.mg-stage.is-ready .mg-result { animation: mg-reveal .3s var(--ease) both; animation-delay: var(--reveal-delay, 0ms); }
@keyframes mg-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
@keyframes mg-reveal { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.mg-results { height: 174px; margin-top: 20px; overflow-y: auto; overscroll-behavior: contain; }
.mg-result { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.mg-result:last-child { border-bottom: 0; }
.mg-result .tile { width: 32px; height: 32px; border-radius: 9px; }.mg-result .tile svg { width: 18px; height: 18px; }
.mg-result b { flex: 1; min-width: 0; font-size: 14px; font-weight: 550; overflow-wrap: anywhere; }
.mg-result > span:last-child { font-size: 11px; color: var(--ink-2); }
.mg-result mark { background: #fbe9b9; color: inherit; border-radius: 3px; padding: 1px 0; }
.mg-found { border-top: 1px solid var(--line); padding: 11px 24px; text-align: right; color: var(--ink-2); font-size: 11px; }
@media (min-width: 1100px) {
  #manage .sec-head { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
}
@media (max-width: 1000px) and (min-width: 721px) {
  .mg-stage { gap: 24px; padding: 28px; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); }
  .mg-body { padding: 20px 16px 14px; }.mg-body h3 { font-size: 23px; }
}
@media (max-width: 720px) {
  .mg-stage { grid-template-columns: 1fr; gap: 22px; padding: 22px 18px; border-radius: 20px; }
  .mg-spaces { max-width: 310px; padding: 0; }.mg-menu { margin-top: 8px; }.mg-space { min-height: 54px; padding: 8px 10px; }.mg-space small { font-size: 10.5px; }.mg-everything { margin-top: 0; }
  .mg-body { padding: 20px 16px 12px; }.mg-body h3 { font-size: 23px; }.mg-query-wrap { font-size: 16px; }.mg-result { gap: 9px; }.mg-result b { font-size: 12.5px; }.mg-result > span:last-child { font-size: 10px; }.mg-current { font-size: 10px; }
}

@media (prefers-reduced-motion: reduce) { .mg-search.is-searching .mg-caret, .mg-stage.is-ready .mg-result { animation: none; } }
