/* Local V7 editor panels. Customer-facing brand styles remain untouched. */
.builder-workspace-v4[data-builder-shell] :is(.builder-layout-panel-v7, .builder-brand-panel-v7) {
  min-width: 0;
  color: var(--bw-ink);
}
.builder-workspace-v4[data-builder-shell] :is(.builder-layout-panel-v7, .builder-brand-panel-v7) .builder-design-heading {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 28px;
}
.builder-workspace-v4[data-builder-shell] :is(.builder-layout-panel-v7, .builder-brand-panel-v7) .builder-design-heading :is(h3, label) {
  margin: 0; min-width: 0; font-size: 12px; line-height: 1.4; font-weight: 650; color: var(--bw-ink);
}
.builder-workspace-v4[data-builder-shell] :is(.builder-layout-panel-v7, .builder-brand-panel-v7) .builder-design-section {
  display: grid; gap: 10px; margin: 0; padding: 14px 0; border: 0; border-bottom: 1px solid var(--bw-line); border-radius: 0; background: none;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-website-display { padding-top: 0; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-map {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr) minmax(0, 1fr);
  grid-template-rows: auto 108px auto; gap: 6px; margin: 0; padding: 7px;
  border: 1px solid var(--bw-line); border-radius: 12px; background: #f8f9fc;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area {
  min-height: 44px; padding: 7px 4px; gap: 4px; align-content: center;
  border-radius: 7px; box-shadow: none; transition: background 120ms ease, border-color 120ms ease;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area :is(strong, small) {
  min-width: 0; max-width: 100%; line-height: 1.3; text-align: center; overflow-wrap: anywhere;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area strong { font-size: 12px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area small { font-size: 10px; font-weight: 450; color: inherit; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area:is(.is-top-bar, .is-bottom-bar) {
  display: flex; justify-content: center; gap: 8px; min-height: 44px;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area.is-off { color: #798599; background: #fff; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area.is-on { color: #3653bb; background: #edf2ff; border-color: #ced9fc; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area.is-selected { border-color: #5268ee; box-shadow: 0 0 0 1px #5268ee; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-area:focus-visible { outline: 2px solid #3659ee; outline-offset: 3px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-viewer-symbol { display: flex; color: #6079c9; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-layout-viewer-symbol .icon { width: 24px; height: 24px; }
.builder-workspace-v4[data-builder-shell] .builder-design-caption { margin: 0; color: var(--bw-muted); font-size: 11px; line-height: 1.5; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details {
  margin: 0; padding: 0; border: 0; border-bottom: 1px solid var(--bw-line); border-radius: 0;
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary {
  padding: 15px 0; min-height: 48px; font-size: 12px; font-weight: 600; line-height: 1.4; color: var(--bw-ink);
}
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details[open] { padding-bottom: 14px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-template-grid > button { padding: 10px 6px; gap: 7px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-mini { width: 68px; height: 94px; padding: 6px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-move-controls { margin: 0; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-move-controls > summary { padding: 6px 0; font-size: 11px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-move-controls button { min-height: 36px; margin-top: 6px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 { display: grid; gap: 0; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-current-profile { display: grid; gap: 8px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-revision { display: grid; gap: 8px; margin: 0; padding: 0 0 14px; border: 0; border-bottom: 1px solid var(--bw-line); font-size: 11px; color: var(--bw-muted); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-revision.is-older { padding: 10px; border: 1px solid #f0dfb6; border-radius: 8px; background: #fffbf2; color: #745721; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-presets { margin: 0; gap: 7px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-presets button { padding: 9px 5px; min-height: 56px; font-size: 11px; font-weight: 600; box-shadow: none; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-presets button[aria-pressed="true"] { box-shadow: 0 0 0 1px #5268ee; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-colors { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; border: 0; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color { gap: 7px; padding: 9px; border: 1px solid var(--bw-line); border-radius: 8px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color > span:first-child { overflow: visible; white-space: normal; text-overflow: clip; font-size: 11px; line-height: 1.4; font-weight: 550; color: var(--bw-ink); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color > span:last-child { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color input[type="color"] { flex: 0 0 32px; width: 32px; height: 28px; min-height: 28px; padding: 2px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color code { font-size: 10px; line-height: 1.4; color: var(--bw-muted); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-more-colors > summary { padding: 7px 0 0; color: var(--bw-muted); font-size: 11px; cursor: pointer; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-more-colors[open] > summary { padding-bottom: 10px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure { margin: 0; border: 0; border-bottom: 1px solid var(--bw-line); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary { display: flex; align-items: center; gap: 9px; min-height: 48px; padding: 14px 0; list-style: none; font-size: 12px; font-weight: 600; line-height: 1.4; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary::-webkit-details-marker { display: none; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary > .icon { flex: 0 0 18px; width: 18px; height: 18px; color: #7287ad; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary > span { margin-left: auto; min-width: 0; color: var(--bw-muted); font-size: 10px; font-weight: 450; text-transform: capitalize; overflow-wrap: anywhere; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary::after { content: ""; flex: 0 0 6px; width: 6px; height: 6px; border-right: 1px solid #8794aa; border-bottom: 1px solid #8794aa; transform: rotate(-45deg); margin-right: 3px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure[open] > summary::after { transform: rotate(45deg); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-design-fields { display: grid; gap: 12px; padding-bottom: 14px; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 :is(.builder-design-fields, .builder-brand-profile-management) label { display: grid; gap: 5px; min-width: 0; font-size: 11px; font-weight: 550; color: var(--bw-ink); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-inline-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-inline-3 > label:first-child { grid-column: 1 / -1; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-profile-management { display: grid; gap: 10px; padding: 16px 0 0; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-profile-management > button { width: 100%; min-height: 40px; margin: 0; padding: 9px 10px; font-size: 12px; line-height: 1.4; white-space: normal; }
.builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 :is(input, select) { min-width: 0; max-width: 100%; }

@container builder-inspector (max-width: 280px) {
  .builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-colors { grid-template-columns: minmax(0, 1fr); }
  .builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 .builder-brand-color { grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 6px; }
  .builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 :is(.builder-brand-inline, .builder-brand-inline-3, .builder-brand-labels fieldset) { grid-template-columns: minmax(0, 1fr); }
  .builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary { flex-wrap: wrap; }
  .builder-workspace-v4[data-builder-shell] .builder-brand-panel-v7 > .builder-design-disclosure > summary > span { display: none; }
}

/* Match the element and Viewer inspectors. */
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-design-heading :is(h3, label) { display: inline-flex; align-items: center; gap: 9px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-design-heading .icon { width: 18px; height: 18px; color: #6e80a3; flex: 0 0 18px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary { display: flex; align-items: center; justify-content: flex-start; gap: 9px; list-style: none; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary::-webkit-details-marker { display: none; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary > strong { font: inherit; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary > .icon { width: 18px; height: 18px; flex: 0 0 18px; color: #6e80a3; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary > span { margin-left: auto; color: var(--bw-muted); font-size: 11px; font-weight: 400; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 > details > summary::after { margin-left: auto; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-color { display: flex; align-items: center; gap: 10px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-color input { width: 42px; min-width: 42px; min-height: 34px; padding: 3px; margin-left: auto; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-area-color code { font-size: 11px; color: var(--bw-muted); }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-template-grid > button { display: flex; flex-direction: column; align-items: center; min-height: 150px; padding: 12px 8px; gap: 12px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-mini { box-sizing: border-box; width: 76px; height: 104px; min-height: 104px; flex: 0 0 104px; overflow: hidden; grid-template-rows: 3px 1fr 1fr 3px 10px; gap: 4px; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-mini > span { min-height: 0; }
.builder-workspace-v4[data-builder-shell] .builder-layout-panel-v7 .builder-sidebar-template-grid > button > strong { flex: 0 0 auto; font-size: 12px; line-height: 1.4; }

.builder-brand-manage-link { border: 0; background: transparent; padding: 0; color: #526487; font: inherit; font-size: 11px; text-align: left; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.builder-brand-preset-library > summary { cursor: pointer; font-size: 11px; color: #526487; padding: 0 0 8px; }
.builder-brand-preset-library:not([open]) .brand-presets-hide,
.builder-brand-preset-library[open] .brand-presets-show { display: none; }
.brand-preset-swatches > i:nth-child(1) { background: var(--p-accent); }
.brand-preset-swatches > i:nth-child(2) { background: var(--p-surface); }
.brand-preset-swatches > i:nth-child(3) { background: var(--p-text); }
.brand-manager { padding: 24px; box-sizing: border-box; width: min(700px, calc(100vw - 32px)); max-height: min(760px, calc(100dvh - 40px)); overflow: auto; }
.brand-manager-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand-manager-heading h2 { margin: 0; }
.brand-manager > p { color: #566177; font-size: 13px; }
.brand-manager-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.brand-manager-tools > input { flex: 1 1 200px; min-width: 0; }
.brand-manager-tools label { display: flex; align-items: center; gap: 7px; font-size: 13px; }
.brand-manager-tools input[type="checkbox"] { width: 16px; min-height: 16px; }
.brand-manager-profile { display: grid; grid-template-columns: minmax(0, 1fr) minmax(140px, auto); align-items: start; gap: 14px; padding: 16px 0; border-bottom: 1px solid #e1e6ef; font-size: 13px; }
.brand-manager-profile > div:first-child { display: grid; gap: 5px; overflow-wrap: anywhere; }
.brand-manager-profile small { color: #66738a; }
.brand-manager-profile-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: end; align-items: start; }
.brand-manager-profile-actions button { min-height: 32px; padding: 6px 10px; font-size: 12px; }
.brand-manager-profile-actions button:disabled { opacity: .45; cursor: not-allowed; }
.brand-manager-profile details { flex: 1 1 150px; max-width: 280px; }
.brand-manager-profile summary { cursor: pointer; padding: 7px 0; color: #526487; }
.brand-manager-profile ul { list-style: none; padding: 0; margin: 6px 0; }
.brand-manager-profile li { display: grid; gap: 4px; padding: 7px 0; overflow-wrap: anywhere; }
.brand-manager-profile li span { font-size: 11px; color: #66738a; }
.brand-manager-confirm { display: flex; flex-wrap: wrap; gap: 8px; justify-content: end; }
.brand-manager-confirm > span { flex-basis: 100%; text-align: right; }
@media (max-width: 520px) {
  .brand-manager-profile { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .brand-manager-profile-actions { justify-content: start; }
}
