/* Interactive menu preview. Colours and sizes are per-instance custom properties so each menu can differ. */
.mp { --mp-accent: #8b45f5; --mp-fs: 13px; --mp-bg: #111216; --mp-panel: #17181d; --mp-line: rgba(255, 255, 255, .06); --mp-text: #e8e9ee; --mp-dim: #8d909b; font-size: var(--mp-fs); }
.mp-win { background: var(--mp-bg) linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px) 0 0 / 22px 22px; background-image: linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .018) 1px, transparent 1px); background-size: 22px 22px; border: 1px solid rgba(255, 255, 255, .1); border-radius: 12px; overflow: hidden; color: var(--mp-text); box-shadow: 0 40px 90px rgba(0, 0, 0, .55), 0 0 0 1px rgba(0, 0, 0, .4); letter-spacing: -.01em; }
.mp svg { width: 1.25em; height: 1.25em; flex: none; }
.mp-top { position: relative; height: 40px; display: flex; align-items: center; justify-content: center; border-bottom: 1px solid var(--mp-line); background: rgba(0, 0, 0, .18); }
.mp-logo { position: absolute; left: 16px; color: var(--mp-dim); display: grid; }
.mp-logo svg { width: 18px; height: 18px; }
.mp-tabs { display: flex; gap: 4px; height: 100%; align-items: center; }
.mp-tab { position: relative; width: 30px; height: 28px; display: grid; place-items: center; border-radius: 7px; color: var(--mp-dim); transition: color .15s, background .15s; }
.mp-tab svg { width: 17px; height: 17px; }
.mp-tab:hover { color: var(--mp-text); }
.mp-tab.is-active { color: var(--mp-accent); background: color-mix(in srgb, var(--mp-accent) 14%, transparent); }
.mp-tab.is-active::after { content: ""; position: absolute; left: 6px; right: 6px; bottom: -6px; height: 2px; border-radius: 2px; background: var(--mp-accent); }
.mp-body { display: grid; grid-template-columns: 120px minmax(0, 1fr); min-height: 440px; }
.mp-side { display: flex; flex-direction: column; padding: 10px 4px 10px; border-right: 1px solid var(--mp-line); background: rgba(0, 0, 0, .14); }
.mp-side-title { font-size: 1.15em; font-weight: 600; padding: 0 4px 8px; }
.mp-pages { display: flex; flex-direction: column; gap: 2px; }
.mp-page { display: flex; align-items: center; gap: 6px; height: 26px; padding: 0 6px; border-radius: 6px; color: var(--mp-dim); text-align: left; transition: color .15s, background .15s; }
.mp-page:hover { color: var(--mp-text); }
.mp-page.is-active { color: var(--mp-accent); background: color-mix(in srgb, var(--mp-accent) 13%, transparent); }
.mp-brand { margin-top: auto; text-align: center; color: var(--mp-accent); font-weight: 500; padding-top: 12px; }
.mp-main { padding: 10px 12px 16px; min-width: 0; }
.mp-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.mp-crumb { color: var(--mp-dim); white-space: nowrap; }
.mp-crumb b { color: var(--mp-accent); font-weight: 500; }
.mp-search { width: 150px; max-width: 45%; height: 24px; background: none; border: 0; border-bottom: 1px solid transparent; color: var(--mp-text); font-size: 1em; text-align: center; }
.mp-search::placeholder { color: var(--mp-text); opacity: .85; }
.mp-search:focus { outline: none; border-bottom-color: var(--mp-accent); }
.mp-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.mp-cols.is-single { grid-template-columns: 1fr; }
.mp-col { display: grid; gap: 10px; min-width: 0; }
.mp-group { background: var(--mp-panel); border-radius: 8px; padding: 6px 12px; }
.mp-row { display: flex; align-items: center; gap: 6px; min-height: 27px; color: var(--mp-dim); flex-wrap: wrap; }
.mp-row.is-on { color: var(--mp-text); }
.mp-row.is-on > .mp-ic { color: var(--mp-accent); }
.mp-group > .mp-row { position: relative; }
.mp-opt-btn { border-radius: 4px; padding: 2px; transition: color .15s, background .15s; }
.mp-opt-btn:hover, .mp-opt-btn[aria-expanded="true"] { color: var(--mp-accent); opacity: 1; background: color-mix(in srgb, var(--mp-accent) 14%, transparent); }
.mp-opt-btn:focus-visible, .mp-key:focus-visible, .mp-figure path:focus-visible { outline: 2px solid var(--mp-accent); outline-offset: 2px; }
.mp-sub { position: absolute; z-index: 6; top: calc(100% - 2px); left: 18px; right: 30px; padding: 8px 10px 6px; border-radius: 8px; background: #1b1c22; border: 1px solid rgba(255, 255, 255, .08); box-shadow: 0 16px 40px rgba(0, 0, 0, .6); color: var(--mp-dim); }
.mp-sub-title { display: flex; align-items: center; gap: 8px; font-size: 1.12em; font-weight: 600; color: var(--mp-text); padding-bottom: 4px; }
.mp-sub .mp-select { width: 110px; }
.mp-key { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 8px 0 4px; border-radius: 4px; background: #23242a; color: var(--mp-text); font-weight: 500; }
.mp-key svg { color: var(--mp-accent); background: color-mix(in srgb, var(--mp-accent) 20%, transparent); border-radius: 3px; padding: 2px; width: 1.5em; height: 1.5em; }
.mp-key.is-listening { outline: 1px solid var(--mp-accent); color: var(--mp-accent); }
.mp-body-pick { display: grid; justify-items: center; gap: 8px; padding: 10px 0 6px; }
.mp .mp-figure { width: 132px; height: 288px; overflow: visible; }
.mp-figure path { cursor: pointer; stroke: rgba(0, 0, 0, .45); stroke-width: 1; transition: fill .16s, filter .16s; filter: drop-shadow(0 0 5px color-mix(in srgb, currentColor 0%, transparent)); }
.mp-figure path:not(.is-ignored) { filter: brightness(1) drop-shadow(0 0 4px rgba(255, 255, 255, .12)); }
.mp-figure path:hover { filter: brightness(1.25); }
.mp-legend { display: grid; grid-template-columns: auto auto; gap: 4px 28px; color: var(--mp-text); }
.mp-legend span { display: flex; align-items: center; gap: 6px; }
.mp-legend span:first-child { grid-column: 1 / -1; justify-self: center; }
.mp-legend i { width: 11px; height: 11px; border-radius: 2px; }
.mp-hint { margin: 2px 0 0; color: var(--mp-dim); font-size: .92em; }
.mp-below { grid-column: 1 / -1; }
.mp-row.is-dis { opacity: .35; }
.mp-ic { display: grid; width: 1.25em; }
.mp-ic:empty { display: none; }
.mp-label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mp-opt { display: grid; color: var(--mp-dim); opacity: .8; }
.mp-opt svg { width: 1.05em; height: 1.05em; }
.mp-switch { position: relative; width: 32px; height: 16px; border-radius: 10px; background: #2b2c33; flex: none; transition: background .16s; }
.mp-switch::after { content: ""; position: absolute; top: 3px; left: 4px; width: 10px; height: 10px; border-radius: 50%; background: #6c6e78; transition: transform .16s, background .16s; }
.mp-switch[aria-checked="true"] { background: var(--mp-accent); }
.mp-switch[aria-checked="true"]::after { transform: translateX(14px); background: #d9d2ee; }
.mp-switch:disabled { cursor: not-allowed; }
.mp-slider { padding: 2px 0 8px; }
.mp-slider .mp-label { color: var(--mp-dim); }
.mp-val { color: var(--mp-dim); font-variant-numeric: tabular-nums; }
.mp-slider input { flex: 0 0 100%; -webkit-appearance: none; appearance: none; height: 14px; margin: 4px 0 0; background: none; cursor: pointer; }
.mp-slider input::-webkit-slider-runnable-track { height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--mp-accent) var(--p), #2b2c33 var(--p)); }
.mp-slider input::-moz-range-track { height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--mp-accent) var(--p), #2b2c33 var(--p)); }
.mp-slider input::-webkit-slider-thumb { -webkit-appearance: none; width: 9px; height: 9px; margin-top: -3px; border-radius: 50%; background: var(--mp-accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--mp-accent) 25%, transparent); }
.mp-slider input::-moz-range-thumb { width: 9px; height: 9px; border: 0; border-radius: 50%; background: var(--mp-accent); }
.mp-select { width: 128px; max-width: 50%; height: 26px; padding: 0 8px; border-radius: 4px; border: 0; background: #23242a; color: var(--mp-text); font: inherit; font-weight: 500; text-align: left; cursor: pointer; }
.mp-select:focus-visible, .mp-switch:focus-visible, .mp-btn:focus-visible, .mp-page:focus-visible, .mp-tab:focus-visible, .mp-slider input:focus-visible, .mp-color:focus-visible { outline: 2px solid var(--mp-accent); outline-offset: 2px; }
.mp-multi { position: relative; width: 128px; max-width: 50%; }
.mp-multi-btn { width: 100%; max-width: none; }
.mp-multi-btn span { display: block; overflow: hidden; white-space: nowrap; }
.mp-pop { position: absolute; z-index: 5; top: calc(100% + 4px); right: 0; min-width: 100%; padding: 6px; border-radius: 6px; background: #23242a; border: 1px solid rgba(255, 255, 255, .1); box-shadow: 0 12px 30px rgba(0, 0, 0, .5); display: grid; gap: 2px; }
.mp-pop label { display: flex; align-items: center; gap: 8px; padding: 4px 6px; border-radius: 4px; white-space: nowrap; color: var(--mp-text); cursor: pointer; }
.mp-pop label:hover { background: rgba(255, 255, 255, .06); }
.mp-pop input { accent-color: var(--mp-accent); }
.mp-color { width: 16px; height: 16px; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; overflow: hidden; }
.mp-color::-webkit-color-swatch-wrapper { padding: 0; }
.mp-color::-webkit-color-swatch { border: 0; border-radius: 50%; }
.mp-color::-moz-color-swatch { border: 0; border-radius: 50%; }
.mp-btns { display: flex; gap: 8px; padding: 4px 0; }
.mp-btn { flex: 1; height: 26px; background: #3a3a3d; color: #fff; font-weight: 500; transition: background .15s; }
.mp-btn:hover:not(:disabled) { background: #4a4a4e; }
.mp-btn:disabled { opacity: .55; cursor: not-allowed; }
.mp-empty { grid-column: 1 / -1; color: var(--mp-dim); padding: 28px 8px; text-align: center; margin: 0; }
.mp-foot { min-height: 20px; margin-top: 10px; font-size: 13.5px; text-align: center; }
.mp-status { color: var(--mp-accent); font-weight: 600; }
.menu-wrap { max-width: 900px; margin: 0 auto; }

@media (max-width: 720px) {
  .mp-body { grid-template-columns: 1fr; min-height: 0; }
  .mp-side { flex-direction: row; align-items: center; gap: 6px; border-right: 0; border-bottom: 1px solid var(--mp-line); padding: 6px 8px; overflow-x: auto; }
  .mp-side-title, .mp-brand { display: none; }
  .mp-pages { flex-direction: row; }
  .mp-page { white-space: nowrap; height: 30px; padding: 0 10px; }
  .mp-cols { grid-template-columns: 1fr; }
  .mp-main { min-height: 320px; }
  .mp-switch { width: 38px; height: 20px; }
  .mp-switch::after { top: 4px; width: 12px; height: 12px; }
  .mp-switch[aria-checked="true"]::after { transform: translateX(18px); }
  .mp-row { min-height: 34px; }
  .mp-tab { width: 40px; height: 32px; }
}

/* Sidebar layout (Krush menus): sections and pages down the left, a page's sub-tabs as pills across the top. */
.mp-l-side { --mp-bg: #121317; --mp-panel: #16171b; --mp-line: rgba(255, 255, 255, .055); }
.mp-l-side .mp-win { background: var(--mp-bg); }
.mp-l-side .mp-body { grid-template-columns: 158px minmax(0, 1fr); min-height: 380px; }
.mp-l-side .mp-side { padding: 16px 8px; background: #0f1013; }
.mp-l-side .mp-tabs { flex-direction: column; align-items: stretch; gap: 2px; height: auto; }
.mp-sec { color: var(--mp-dim); font-size: .9em; padding: 14px 8px 6px; }
.mp-sec:first-child { padding-top: 2px; }
.mp-l-side .mp-tab { width: auto; height: 26px; display: flex; align-items: center; gap: 8px; padding: 0 8px; border-radius: 6px; font-size: .95em; }
.mp-l-side .mp-tab svg { width: 13px; height: 13px; }
.mp-l-side .mp-tab.is-active { background: none; }
.mp-l-side .mp-tab.is-active::after { display: none; }
.mp-l-side .mp-main { padding: 0 0 16px; }
.mp-l-side .mp-bar { align-items: flex-start; padding: 12px 14px 10px; margin: 0; border-bottom: 1px solid var(--mp-line); }
.mp-l-side .mp-crumb { color: var(--mp-text); font-size: .95em; line-height: 1.4; }
.mp-l-side .mp-crumb div { display: flex; align-items: center; gap: 6px; }
.mp-l-side .mp-crumb svg { width: 11px; height: 11px; color: var(--mp-accent); }
.mp-crumb-sub { padding-left: 14px; position: relative; }
.mp-crumb-sub::before { content: ""; position: absolute; left: 4px; top: -2px; width: 7px; height: 9px; border-left: 1px solid var(--mp-dim); border-bottom: 1px solid var(--mp-dim); opacity: .6; }
.mp-bar-ic { display: flex; gap: 12px; color: var(--mp-dim); padding-top: 4px; }
.mp-bar-ic svg { width: 14px; height: 14px; }
.mp-l-side .mp-pages { flex-direction: row; flex-wrap: wrap; gap: 2px; width: fit-content; max-width: calc(100% - 28px); margin: 14px 14px 12px; padding: 3px; border: 1px solid #25262c; border-radius: 6px; }
.mp-l-side .mp-page { height: 26px; padding: 0 10px; font-size: .9em; border-radius: 4px; }
.mp-l-side .mp-page.is-active { color: var(--mp-accent); background: #1f2026; }
.mp-l-side .mp-cols { padding: 0 14px; gap: 12px; }
.mp-l-side .mp-group { border: 1px solid #23242a; border-radius: 6px; padding: 6px 12px; }
.mp-l-side .mp-row { min-height: 24px; font-size: .95em; }
.mp-l-side .mp-row .mp-color { width: 9px; height: 9px; margin-right: 6px; }
.mp-l-side .mp-switch { width: 22px; height: 12px; }
.mp-l-side .mp-switch::after { top: 2px; left: 3px; width: 8px; height: 8px; }
.mp-l-side .mp-switch[aria-checked="true"] { background: color-mix(in srgb, var(--mp-accent) 75%, #000); }
.mp-l-side .mp-switch[aria-checked="true"]::after { transform: translateX(9px); background: #e6dcff; }
.mp-l-side .mp-select { height: 20px; width: 98px; font-size: .9em; }
.mp-l-side .mp-multi { width: 98px; }
.mp-l-side .mp-opt { opacity: .7; margin-right: 4px; }
@media (max-width: 720px) {
  .mp-l-side .mp-body { grid-template-columns: 1fr; }
  .mp-l-side .mp-tabs { flex-direction: row; overflow-x: auto; }
  .mp-l-side .mp-sec { display: none; }
  .mp-l-side .mp-tab { white-space: nowrap; height: 32px; }
  .mp-l-side .mp-switch { width: 30px; height: 16px; }
  .mp-l-side .mp-switch::after { top: 3px; width: 10px; height: 10px; }
  .mp-l-side .mp-switch[aria-checked="true"]::after { transform: translateX(13px); }
  .mp-l-side .mp-row { min-height: 32px; }
  .mp-l-side .mp-row .mp-color { width: 14px; height: 14px; }
}
