.br-page .page-head{margin-bottom:14px}
.br-page-head{align-items:center}
.br-pro-badge{display:inline-flex;align-items:center;min-height:30px;padding:0 12px;border:1px solid #f0c7c4;border-radius:999px;background:#fff7f6;color:var(--red);font-size:8px;font-weight:950;letter-spacing:.08em;white-space:nowrap}
.br-local-note{display:flex;align-items:flex-start;gap:10px;margin-bottom:16px;padding:13px 15px;border:1px solid #cce7dc;border-radius:14px;background:#f0faf6;color:#286b55;font-size:9px;line-height:1.55}
.br-local-note .icon{flex:none;width:18px;height:18px}.br-local-note strong{color:#15543f}
.br-workspace{display:grid;grid-template-columns:350px minmax(0,1fr);gap:16px;align-items:start}
.br-controls{display:grid;gap:0;padding:0;overflow:hidden}
.br-control-section{display:grid;gap:12px;padding:17px;border-bottom:1px solid var(--line)}
.br-control-section:last-child{border-bottom:0}
.br-section-head{display:flex;align-items:flex-start;gap:10px}
.br-section-head>span{display:grid;place-items:center;flex:none;width:25px;height:25px;border-radius:8px;background:#fff0ef;color:var(--red);font-size:8px;font-weight:950}
.br-section-head h3{margin:0;font-size:11px}.br-section-head p{margin:3px 0 0;color:var(--muted);font-size:8px;line-height:1.45}
.br-dropzone{display:grid;place-items:center;min-height:122px;padding:18px;border:1.5px dashed #c7ccd4;border-radius:14px;background:#fafafb;text-align:center;cursor:pointer;transition:.2s}
.br-dropzone:hover,.br-dropzone:focus,.br-dropzone.dragging{outline:0;border-color:var(--red);background:#fff6f5}
.br-dropzone .upload-circle{margin:0 0 8px}.br-dropzone strong{font-size:10px}.br-dropzone>span:not(.upload-circle){margin-top:4px;color:var(--muted);font-size:8px}.br-dropzone button{margin-top:10px}
.br-color-row{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:end}
.br-color-row>label{display:grid;gap:6px;color:#5c626d;font-size:8px;font-weight:850}
.br-color-field{display:flex;align-items:center;gap:8px;min-height:43px;padding:6px 10px;border:1px solid var(--line);border-radius:11px;background:#fafafb}
.br-color-field input{width:32px;height:29px;padding:0;border:0;background:transparent;cursor:pointer}.br-color-field strong{font-size:9px}
.br-color-actions{display:flex;gap:6px}.br-color-actions button{height:43px;padding:8px 9px;font-size:7px}
.br-range{display:grid;gap:7px}.br-range>span{display:flex;justify-content:space-between;color:#5b616c;font-size:9px;font-weight:850}.br-range output{color:var(--red)}
.br-range input{height:6px;padding:0;border:0;border-radius:99px;background:#e7e9ed;accent-color:var(--red);box-shadow:none}
.br-range small{color:var(--muted);font-size:7px;line-height:1.4}
.br-analyze{width:100%;min-height:42px;font-size:8px}
.br-rule-note{display:flex;gap:8px;padding:10px;border-radius:11px;background:#f3f7ff;color:#45658f;font-size:8px;line-height:1.5}
.br-rule-note .icon{flex:none;width:15px;height:15px}
.br-tools{display:grid;grid-template-columns:repeat(2,1fr);gap:6px}
.br-tools button{min-height:35px;padding:7px 5px;border:1px solid var(--line);border-radius:9px;background:#fff;color:#6b717b;font-size:7px;font-weight:950}
.br-tools button:hover{border-color:#efb5b1;color:var(--red)}.br-tools button.active{border-color:var(--red);background:#fff1f0;color:var(--red)}
.br-history{display:grid;grid-template-columns:1fr 1fr;gap:7px}.br-history button{font-size:7px}
.br-removal-menu{border:1px solid #efb5b1;border-radius:12px;background:#fff8f7;overflow:hidden}
.br-removal-menu summary{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:12px;color:var(--red);font-size:8px;font-weight:950;cursor:pointer;list-style:none}
.br-removal-menu summary::-webkit-details-marker{display:none}
.br-removal-menu summary:after{content:"＋";font-size:13px}.br-removal-menu[open] summary:after{content:"−"}
.br-removal-menu summary small{margin-left:auto;color:#8c6c69;font-size:7px;font-weight:800}
.br-removal-panel{display:grid;gap:11px;padding:0 12px 12px;border-top:1px solid #f3cfcd}
.br-removal-panel>.br-api-field{margin-top:11px}
.br-target-color{display:grid;grid-template-columns:75px 1fr;gap:7px;align-items:end}
.br-target-color label{display:grid;gap:5px;color:var(--muted);font-size:7px;font-weight:900}
.br-target-color input[type="color"]{width:100%;height:37px;padding:4px;border:1px solid var(--line);border-radius:9px;background:#fff;cursor:pointer}
.br-target-color button{height:37px;font-size:7px}
.br-removal-hint{margin:0;padding:9px;border-radius:9px;background:#fff;color:#75615f;font-size:7px;line-height:1.5}
.br-removal-hint.warning{background:#fff6df;color:#8a5b00}
.br-removal-actions{display:grid;grid-template-columns:1fr 1fr;gap:6px}
.br-removal-actions button{min-height:35px;padding:7px 6px;font-size:6.5px}
.br-removal-actions button:last-child{grid-column:1/-1}
.br-selection-preview{position:absolute;inset:0;z-index:3;pointer-events:none}
.br-palette-list{display:grid;gap:6px;max-height:280px;overflow:auto}
.br-palette-list>p{margin:0;padding:10px;border:1px dashed var(--line);border-radius:9px;color:var(--muted);font-size:7px;line-height:1.5}
.br-palette-item{display:grid;grid-template-columns:30px minmax(0,1fr) auto;gap:7px;align-items:center;padding:7px;border:1px solid var(--line);border-radius:10px;background:#fff}
.br-palette-item.selected{border-color:var(--red);box-shadow:inset 0 0 0 1px var(--red)}
.br-palette-item.hidden-color{opacity:.58;background:#f5f5f6}
.br-palette-swatch{width:29px;height:29px;border:2px solid #fff;border-radius:8px;box-shadow:0 0 0 1px #cfd3d9}
.br-palette-meta{min-width:0}.br-palette-meta strong,.br-palette-meta small{display:block}.br-palette-meta strong{font-size:8px}.br-palette-meta small{margin-top:3px;color:var(--muted);font-size:6.5px}
.br-palette-buttons{display:flex;gap:3px}.br-palette-buttons button{min-width:27px;height:27px;padding:0 5px;border:1px solid var(--line);border-radius:7px;background:#fff;color:#5f6670;font-size:7px;font-weight:900}.br-palette-buttons button:hover{border-color:var(--red);color:var(--red)}
.br-palette-actions button:last-child{grid-column:1/-1}
.br-help{margin:0;color:var(--muted);font-size:8px;line-height:1.5}
.br-preview-column{display:grid;gap:14px;min-width:0}
.br-preview-panel{overflow:hidden}
.br-preview-toolbar{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:11px 13px;border-bottom:1px solid var(--line)}
.br-view-tabs{display:flex;gap:3px;padding:3px;border-radius:10px;background:#f0f1f3}
.br-view-tabs button{border:0;border-radius:8px;padding:8px 9px;background:transparent;color:#7d838e;font-size:7px;font-weight:950;white-space:nowrap}
.br-view-tabs button.active{background:#fff;color:var(--ink);box-shadow:0 3px 10px rgba(17,19,24,.08)}
.br-zoom{display:flex;align-items:center;gap:4px}.br-zoom button{display:grid;place-items:center;min-width:29px;height:29px;padding:0 7px;border:1px solid var(--line);border-radius:8px;background:#fff;color:#555c66;font-size:11px;font-weight:900}.br-zoom button:last-child{font-size:7px}.br-zoom strong{min-width:45px;color:#606671;font-size:8px;text-align:center}
.br-backgrounds{display:flex;align-items:center;gap:7px;padding:8px 13px;border-bottom:1px solid var(--line);background:#fafafb}
.br-backgrounds>span{margin-right:2px;color:var(--muted);font-size:7px;font-weight:900}
.br-backgrounds button{width:21px;height:21px;padding:0;border:2px solid #fff;border-radius:50%;box-shadow:0 0 0 1px #d1d5db}
.br-backgrounds button.active{box-shadow:0 0 0 2px var(--red)}
.br-backgrounds .checker{background-color:#fff;background-image:linear-gradient(45deg,#cbd0d7 25%,transparent 25%),linear-gradient(-45deg,#cbd0d7 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#cbd0d7 75%),linear-gradient(-45deg,transparent 75%,#cbd0d7 75%);background-size:8px 8px;background-position:0 0,0 4px,4px -4px,-4px 0}
.br-backgrounds .white{background:#fff}.br-backgrounds .black{background:#111318}.br-backgrounds .red{background:#b92925}
.br-canvas-shell{position:relative;display:grid;place-items:center;min-height:520px;overflow:hidden;touch-action:none;user-select:none;transition:background .2s}
.br-canvas-shell.br-bg-checker{background-color:#e8eaee;background-image:linear-gradient(45deg,#d8dbe1 25%,transparent 25%),linear-gradient(-45deg,#d8dbe1 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#d8dbe1 75%),linear-gradient(-45deg,transparent 75%,#d8dbe1 75%);background-size:24px 24px;background-position:0 0,0 12px,12px -12px,-12px 0}
.br-canvas-shell.br-bg-white{background:#fff}.br-canvas-shell.br-bg-black{background:#111318}.br-canvas-shell.br-bg-red{background:#a9201d}
.br-canvas-shell canvas{display:block;position:relative;z-index:1;width:0;height:0;max-width:none;max-height:none;transform-origin:center;filter:drop-shadow(0 14px 25px rgba(17,19,24,.14));cursor:grab}
.br-canvas-shell[data-tool="protect"] canvas,.br-canvas-shell[data-tool="erase"] canvas{cursor:none}.br-canvas-shell[data-tool="color-select"] canvas,.br-canvas-shell[data-tool="manual-background"] canvas{cursor:crosshair}.br-canvas-shell.panning canvas{cursor:grabbing}
.br-preview-empty{display:grid;place-items:center;gap:8px;position:absolute;z-index:2;max-width:310px;padding:30px;border:1px solid rgba(255,255,255,.85);border-radius:17px;background:rgba(255,255,255,.94);text-align:center;box-shadow:0 10px 35px rgba(17,19,24,.08)}
.br-empty-icon{display:grid;place-items:center;width:43px;height:43px;border-radius:14px;background:#fff0ef;color:var(--red)}.br-empty-icon .icon{width:21px;height:21px}
.br-preview-empty strong{font-size:12px}.br-preview-empty>span:last-child{color:var(--muted);font-size:9px;line-height:1.55}
.br-brush-cursor{position:absolute;z-index:4;border:1.5px solid #fff;border-radius:50%;pointer-events:none;box-shadow:0 0 0 1px rgba(17,19,24,.65);transform:translate(-50%,-50%)}
.br-preview-footer{display:flex;justify-content:space-between;gap:12px;padding:10px 13px;border-top:1px solid var(--line);color:var(--muted);font-size:8px}
.br-result-panel{display:grid;grid-template-columns:1fr 1fr;gap:11px;padding:14px}
.br-info-card{display:flex;align-items:flex-start;gap:10px;padding:13px;border:1px solid var(--line);border-radius:12px;background:#fafafb}
.br-info-card .icon{flex:none;width:18px;height:18px;color:var(--red)}.br-info-card strong,.br-info-card span{display:block}.br-info-card strong{font-size:10px}.br-info-card span{margin-top:4px;color:var(--muted);font-size:8px;line-height:1.5}
.br-quality-panel{display:grid;gap:14px;padding:16px}
.br-quality-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px}.br-quality-head h3{margin:3px 0 5px;font-size:12px}.br-quality-head p:not(.eyebrow){margin:0;color:var(--muted);font-size:8px;line-height:1.5}
.br-quality-score{display:flex;align-items:baseline;justify-content:center;min-width:86px;padding:10px;border:1px solid var(--line);border-radius:14px;background:#fafafb}.br-quality-score strong{font-size:25px}.br-quality-score span{color:var(--muted);font-size:8px}.br-quality-score[data-state="excellent"],.br-quality-score[data-state="good"]{border-color:#a9dfc6;background:#f1fbf6;color:#176b4d}.br-quality-score[data-state="check"]{border-color:#f1d18b;background:#fff9eb;color:#996000}.br-quality-score[data-state="poor"]{border-color:#efb6b3;background:#fff3f2;color:#ae2a25}
.br-quality-settings{display:grid;grid-template-columns:1fr 1fr;gap:9px}.br-unit-field{display:grid;grid-template-columns:1fr auto;align-items:center;border:1px solid var(--line);border-radius:9px;background:#fff;overflow:hidden}.br-unit-field input{border:0!important;border-radius:0!important}.br-unit-field b{padding:0 10px;color:var(--muted);font-size:8px}
.br-quality-actions{display:grid;grid-template-columns:1.2fr 1fr 1.2fr;gap:7px}.br-quality-actions button{font-size:7px}
.br-quality-summary{padding:11px;border-radius:11px;background:#f3f7ff;color:#46658f}.br-quality-summary p{margin:0;font-size:8px;line-height:1.55}.br-quality-summary strong{color:var(--ink)}
.br-quality-issues{display:grid;gap:7px}.br-quality-issue{display:grid;grid-template-columns:12px minmax(0,1fr) auto;gap:9px;align-items:start;padding:10px;border:1px solid var(--line);border-radius:10px;background:#fafafb}.br-quality-issue i{width:10px;height:10px;margin-top:2px;border-radius:50%;background:#e2a428}.br-quality-issue.error i{background:#c93630}.br-quality-issue strong,.br-quality-issue span{display:block}.br-quality-issue strong{font-size:8px}.br-quality-issue span{margin-top:3px;color:var(--muted);font-size:7px;line-height:1.45}.br-quality-issue button{padding:5px 7px;font-size:6px}
.br-quality-certificate{padding:12px;border:1px solid #b7dec9;border-radius:11px;background:#f1fbf6;color:#27674e;font-size:7.5px;line-height:1.65;white-space:pre-line}
.br-export-panel{display:grid;grid-template-columns:minmax(180px,1fr) auto;gap:15px;align-items:center;padding:16px}
.br-export-panel h3{margin:3px 0 5px;font-size:12px}.br-export-panel p:not(.eyebrow){margin:0;color:var(--muted);font-size:8px;line-height:1.5}
.br-actions{display:flex;align-items:center;gap:7px}.br-actions button{min-height:42px;font-size:7px;white-space:nowrap}
.br-progress{grid-column:1/-1;display:flex;align-items:center;gap:9px;padding:10px 12px;border-radius:10px;background:#f3f7ff;color:#46658f;font-size:8px;font-weight:800}
.br-progress i{width:15px;height:15px;border:2px solid #a9bad1;border-top-color:#46658f;border-radius:50%;animation:br-spin .75s linear infinite}
.br-progress.hidden{display:none}.br-message{grid-column:1/-1;min-height:16px;margin:0;color:var(--muted);font-size:8px}.br-message.success{color:var(--green)}.br-message.error{color:var(--danger)}
.mobile-nav .js-bg-nav .icon{stroke-width:1.65}
@keyframes br-spin{to{transform:rotate(360deg)}}
@media(max-width:1120px){.br-workspace{grid-template-columns:315px minmax(0,1fr)}.br-canvas-shell{min-height:450px}.br-preview-toolbar{align-items:flex-start;flex-wrap:wrap}.br-zoom{margin-left:auto}}
@media(max-width:850px){.br-page-head{align-items:flex-start}.br-pro-badge{display:none}.br-workspace{grid-template-columns:1fr}.br-controls{order:2}.br-preview-column{order:1}.br-canvas-shell{min-height:410px}.mobile-nav{grid-template-columns:repeat(6,1fr)}}
@media(max-width:600px){.br-quality-settings,.br-quality-actions{grid-template-columns:1fr}.br-quality-head{align-items:center}.br-local-note{font-size:8px}.br-preview-toolbar{display:grid;gap:8px}.br-view-tabs{width:100%;overflow-x:auto}.br-view-tabs button{flex:1}.br-zoom{margin:0}.br-canvas-shell{min-height:350px}.br-preview-footer{display:grid}.br-result-panel{grid-template-columns:1fr}.br-export-panel{grid-template-columns:1fr}.br-actions{display:grid;grid-template-columns:1fr}.br-color-row{grid-template-columns:1fr}.br-color-actions{display:grid;grid-template-columns:1fr 1fr}.br-color-actions button{width:100%}}
@media(max-width:380px){.br-canvas-shell{min-height:310px}.br-view-tabs button{padding:8px 7px;font-size:6px}.br-tools{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){.br-progress i{animation:none}.br-canvas-shell{transition:none}}

/* Semantic background-removal workspace */
.br-api-field{display:grid;gap:6px;color:var(--muted);font-size:8px;font-weight:800;letter-spacing:.04em}
.br-api-field input,.br-api-field select{width:100%;min-height:38px;padding:9px 10px;border:1px solid var(--line);border-radius:9px;background:#fff;color:var(--ink);font:inherit;letter-spacing:0}
.br-api-field input:focus,.br-api-field select:focus{outline:2px solid rgba(214,49,43,.16);border-color:var(--red)}
.br-api-field select{appearance:auto}
.br-api-row{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:8px}
.br-status{display:inline-flex;align-items:center;gap:7px;color:var(--muted);font-size:8px;font-weight:900}
.br-status:before{content:"";width:8px;height:8px;border-radius:50%;background:#a3aab5;box-shadow:0 0 0 4px rgba(163,170,181,.12)}
.br-status[data-state="ready"]{color:var(--green)}.br-status[data-state="ready"]:before{background:var(--green);box-shadow:0 0 0 4px rgba(21,128,61,.12)}
.br-status[data-state="error"]{color:var(--danger)}.br-status[data-state="error"]:before{background:var(--danger);box-shadow:0 0 0 4px rgba(185,28,28,.1)}
.br-status[data-state="checking"]:before{animation:br-pulse 1s ease-in-out infinite}
.br-mode-grid{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-bottom:10px}
.br-mode-grid button{display:grid;gap:3px;min-height:58px;padding:10px;border:1px solid var(--line);border-radius:10px;background:#fff;text-align:left;color:var(--ink);cursor:pointer}
.br-mode-grid button strong{font-size:8px}.br-mode-grid button small{color:var(--muted);font-size:7px}
.br-mode-grid button:hover{border-color:#d8aaa8}.br-mode-grid button.active{border-color:var(--red);background:#fff5f4;box-shadow:inset 0 0 0 1px var(--red)}
.br-mode-grid button:disabled{opacity:.5;cursor:wait}
.br-cancel{width:100%;margin-top:7px}
.br-stages{display:grid;gap:6px;margin:10px 0 0;padding:0;list-style:none;counter-reset:br-stage}
.br-stages li{display:flex;align-items:center;gap:8px;color:#9aa0aa;font-size:8px}
.br-stages li:before{counter-increment:br-stage;content:counter(br-stage);display:grid;place-items:center;width:18px;height:18px;flex:none;border:1px solid #d8dce2;border-radius:50%;background:#fff;font-size:7px;font-weight:900}
.br-stages li.active{color:var(--ink);font-weight:900}.br-stages li.active:before{border-color:var(--red);color:var(--red);animation:br-pulse 1s ease-in-out infinite}
.br-stages li.done{color:var(--green)}.br-stages li.done:before{content:"✓";border-color:var(--green);background:#effaf3}
.br-stages li.error{color:var(--danger)}.br-stages li.error:before{content:"!";border-color:var(--danger);background:#fff1f1}
.br-check{display:flex;align-items:flex-start;gap:9px;margin-top:10px;padding:10px;border:1px solid var(--line);border-radius:10px;background:#fafafb;cursor:pointer}
.br-check input{margin-top:2px;accent-color:var(--red)}.br-check span,.br-check strong,.br-check small{display:block}
.br-check strong{font-size:8px}.br-check small{margin-top:3px;color:var(--muted);font-size:7px;line-height:1.45}
.br-matte-color{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:8px;align-items:stretch}
.br-matte-color .br-check{margin-top:0}
.br-matte-color>input[type="color"]{width:44px;height:100%;min-height:58px;padding:5px;border:1px solid var(--line);border-radius:10px;background:#fff;cursor:pointer}
.br-matte-color>input[type="color"]:disabled{opacity:.38;cursor:not-allowed}
.br-view-tabs{flex-wrap:wrap}.br-view-tabs button{white-space:nowrap}
.br-backgrounds .gray{background:#777d86}.br-backgrounds .green{background:#18794e}
.br-custom-color{display:grid;place-items:center;width:23px;height:23px;overflow:hidden;border:1px solid var(--line);border-radius:50%;background:conic-gradient(red,#ff0,#0f0,#0ff,#00f,#f0f,red);cursor:pointer}
.br-custom-color input{width:32px;height:32px;opacity:0;cursor:pointer}
.br-canvas-shell.br-bg-gray{background:#777d86}.br-canvas-shell.br-bg-green{background:#18794e}.br-canvas-shell.br-bg-custom{background-image:none}
.br-canvas-shell canvas{width:auto;height:auto;max-width:none;max-height:none;will-change:transform}
.br-canvas-shell canvas.is-brushing{cursor:none}
.br-split-control{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:9px;padding:7px 12px;border-top:1px solid var(--line);background:#fafafb;color:var(--muted);font-size:8px;font-weight:900}
.br-split-control input{accent-color:var(--red)}.br-split-control output{min-width:32px;text-align:right}
.br-info-card.warning{border-color:#efc46c;background:#fffaf0}.br-info-card.warning .icon{color:#c17a08}
.br-message.warning{color:#a55c00}
@keyframes br-pulse{50%{opacity:.45;transform:scale(.9)}}
@media(max-width:600px){.br-mode-grid{grid-template-columns:1fr}.br-canvas-shell{min-height:360px}.br-view-tabs button{flex:0 0 auto}.br-api-row{align-items:flex-start;flex-direction:column}}
@media(prefers-reduced-motion:reduce){.br-status:before,.br-stages li.active:before{animation:none}}


/* Professional three-panel background-removal studio */
.br-page:not(.hidden){display:flex;flex-direction:column;min-height:calc(100dvh - 92px)}
.br-workspace{
  display:grid;
  grid-template-areas:"left center right";
  grid-template-columns:minmax(230px,280px) minmax(560px,1fr) minmax(245px,295px);
  gap:10px;
  align-items:stretch;
  height:calc(100dvh - 235px);
  min-height:590px;
  overflow:hidden;
  transition:grid-template-columns .22s ease;
}
.br-controls{grid-area:left}
.br-preview-column{grid-area:center}
.br-right-controls{grid-area:right}
.br-controls,.br-right-controls{
  height:100%;
  min-height:0;
  max-height:none;
  padding:0;
  overflow-x:hidden;
  overflow-y:auto;
  overscroll-behavior:contain;
  scrollbar-color:#c5c9d0 transparent;
  scrollbar-width:thin;
}
.br-controls::-webkit-scrollbar,.br-right-controls::-webkit-scrollbar{width:7px}
.br-controls::-webkit-scrollbar-thumb,.br-right-controls::-webkit-scrollbar-thumb{border:2px solid transparent;border-radius:10px;background:#c5c9d0;background-clip:padding-box}
.br-right-controls{display:flex;flex-direction:column;gap:0}
.br-side-title{
  position:sticky;
  z-index:8;
  top:0;
  display:grid;
  gap:3px;
  padding:13px 15px;
  border-bottom:1px solid var(--line);
  background:rgba(255,255,255,.97);
  backdrop-filter:blur(12px);
}
.br-side-title>span{color:var(--red);font-size:7px;font-weight:950;letter-spacing:.17em}
.br-side-title>strong{font-size:11px}.br-side-title>small{color:var(--muted);font-size:7px;line-height:1.4}
.br-right-controls>.br-control-section,.br-right-controls>.panel{flex:none}
.br-right-controls>.panel{border:0;border-top:1px solid var(--line);border-radius:0;box-shadow:none}
.br-right-controls>.br-quality-panel{padding:14px}
.br-right-controls>.br-quality-panel .br-quality-head{align-items:center}
.br-right-controls>.br-quality-panel .br-quality-head>div:first-child p:not(.eyebrow){display:none}
.br-right-controls>.br-quality-settings,.br-right-controls>.br-quality-actions{grid-template-columns:1fr}
.br-right-controls>.br-export-panel{display:grid;grid-template-columns:1fr;padding:14px}
.br-right-controls>.br-export-panel .br-actions{display:grid;grid-template-columns:1fr}
.br-right-controls>.br-export-panel .br-actions button{width:100%;white-space:normal}
.br-preview-column{
  display:grid;
  grid-template-rows:minmax(0,1fr) auto;
  gap:10px;
  height:100%;
  min-width:0;
  min-height:0;
  overflow:hidden;
}
.br-preview-panel{
  display:grid;
  grid-template-rows:auto auto auto minmax(0,1fr) auto;
  min-height:0;
  overflow:hidden;
}
.br-canvas-shell{height:100%;min-height:0!important}
.br-result-panel{padding:10px}
.br-result-panel .br-info-card{padding:10px}
.br-preview-toolbar{position:relative;flex-wrap:wrap}
.br-panel-toggles{display:flex;gap:5px;order:-1;width:100%;justify-content:space-between}
.br-panel-toggles button{
  display:inline-flex;
  align-items:center;
  gap:6px;
  min-height:27px;
  padding:5px 9px;
  border:1px solid var(--line);
  border-radius:8px;
  background:#fff;
  color:#777e89;
  font-size:7px;
  font-weight:950;
  letter-spacing:.04em;
}
.br-panel-toggles button.active{border-color:#d7aaa8;background:#fff5f4;color:var(--red)}
.br-panel-toggles button span{font-size:10px;line-height:1}
.br-workspace.br-left-collapsed{grid-template-columns:0 minmax(560px,1fr) minmax(245px,295px)}
.br-workspace.br-right-collapsed{grid-template-columns:minmax(230px,280px) minmax(560px,1fr) 0}
.br-workspace.br-left-collapsed.br-right-collapsed{grid-template-columns:0 minmax(560px,1fr) 0}
.br-workspace.br-left-collapsed>.br-controls,.br-workspace.br-right-collapsed>.br-right-controls{
  visibility:hidden;
  opacity:0;
  pointer-events:none;
}
.br-controls,.br-right-controls{transition:opacity .16s ease}
@media(max-width:1500px) and (min-width:1101px){
  .br-workspace{grid-template-columns:minmax(210px,245px) minmax(500px,1fr) minmax(225px,260px)}
  .br-workspace.br-left-collapsed{grid-template-columns:0 minmax(500px,1fr) minmax(225px,260px)}
  .br-workspace.br-right-collapsed{grid-template-columns:minmax(210px,245px) minmax(500px,1fr) 0}
  .br-workspace.br-left-collapsed.br-right-collapsed{grid-template-columns:0 minmax(500px,1fr) 0}
  .br-view-tabs button{padding:7px 6px;font-size:6.5px}
}
@media(max-width:1100px){
  .br-page:not(.hidden){display:block;min-height:0}
  .br-workspace,.br-workspace.br-left-collapsed,.br-workspace.br-right-collapsed,.br-workspace.br-left-collapsed.br-right-collapsed{
    grid-template-areas:"center" "left" "right";
    grid-template-columns:1fr;
    height:auto;
    min-height:0;
    overflow:visible;
  }
  .br-preview-column{order:1;height:auto;overflow:visible}
  .br-controls{order:2;height:auto;max-height:70dvh}
  .br-right-controls{order:3;height:auto;max-height:70dvh}
  .br-workspace.br-left-collapsed>.br-controls,.br-workspace.br-right-collapsed>.br-right-controls{display:none}
  .br-preview-panel{min-height:560px}
  .br-canvas-shell{min-height:410px!important}
}
@media(max-width:600px){
  .br-workspace{gap:9px}
  .br-preview-panel{min-height:480px}
  .br-canvas-shell{min-height:340px!important}
  .br-panel-toggles button{flex:1;justify-content:center}
}
@media(prefers-reduced-motion:reduce){
  .br-workspace,.br-controls,.br-right-controls{transition:none}
}

.br-canvas-pan{
  position:absolute;
  z-index:6;
  top:12px;
  left:12px;
  display:inline-flex;
  align-items:center;
  gap:7px;
  min-height:34px;
  padding:8px 12px;
  border:1px solid rgba(17,19,24,.18);
  border-radius:10px;
  background:rgba(255,255,255,.94);
  color:#555c66;
  box-shadow:0 7px 20px rgba(17,19,24,.14);
  backdrop-filter:blur(10px);
  font-size:7px;
  font-weight:950;
  letter-spacing:.06em;
  cursor:pointer;
}
.br-canvas-pan span{font-size:14px;line-height:1}
.br-canvas-pan:hover,.br-canvas-pan.active{border-color:var(--red);background:var(--red);color:#fff}
.br-canvas-pan:focus-visible{outline:3px solid rgba(214,49,43,.25);outline-offset:2px}
@media(max-width:600px){.br-canvas-pan{top:8px;left:8px;min-height:32px;padding:7px 10px}}

/* Keep the central studio geometrically stable between images and results */
@media(min-width:1101px){
  .br-workspace{height:clamp(590px,calc(100dvh - 235px),900px)}
  .br-preview-column{grid-template-rows:minmax(0,1fr) 84px}
  .br-preview-panel{height:100%;min-height:0}
  .br-result-panel{
    height:84px;
    min-height:84px;
    max-height:84px;
    overflow:hidden;
    align-content:stretch;
  }
  .br-result-panel .br-info-card{min-width:0;overflow:hidden}
  .br-result-panel .br-info-card span{display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:2}
  .br-canvas-shell{height:100%;min-height:0!important}
}

/* Fullscreen mode dedicated to the background-removal studio */
body.br-studio-active{height:100dvh;overflow:hidden;background:#eef0f3}
body.br-studio-active .public-topbar,
body.br-studio-active .app-sidebar,
body.br-studio-active .app-topbar,
body.br-studio-active .mobile-nav{display:none!important}
body.br-studio-active .app-shell,
body.br-studio-active .app-workspace{width:100%;height:100dvh;min-height:0;margin:0!important;overflow:hidden}
body.br-studio-active .app-content{
  box-sizing:border-box;
  width:100%;
  max-width:none;
  height:100dvh;
  margin:0;
  padding:8px;
  overflow:hidden;
}
body.br-studio-active #bgRemoverView{
  display:flex;
  flex-direction:column;
  width:100%;
  height:100%;
  min-height:0;
  animation:none;
}
body.br-studio-active #bgRemoverView>.br-page-head,
body.br-studio-active #bgRemoverView>.br-local-note{display:none}
body.br-studio-active .br-workspace{
  flex:1;
  width:100%;
  height:auto;
  min-height:0;
  max-height:none;
}
.br-canvas-fullscreen{
  position:absolute;
  z-index:6;
  top:12px;
  right:12px;
  display:inline-flex;
  align-items:center;
  gap:7px;
  min-height:34px;
  padding:8px 12px;
  border:1px solid rgba(17,19,24,.18);
  border-radius:10px;
  background:rgba(32,36,42,.94);
  color:#fff;
  box-shadow:0 7px 20px rgba(17,19,24,.18);
  backdrop-filter:blur(10px);
  font-size:7px;
  font-weight:950;
  letter-spacing:.06em;
  cursor:pointer;
}
.br-canvas-fullscreen span{font-size:14px;line-height:1}
.br-canvas-fullscreen:hover,.br-canvas-fullscreen.active{border-color:var(--red);background:var(--red);color:#fff}
.br-canvas-fullscreen:focus-visible{outline:3px solid rgba(214,49,43,.25);outline-offset:2px}
@media(max-width:600px){.br-canvas-fullscreen{top:8px;right:8px;min-height:32px;padding:7px 10px}}
@media(max-width:1100px){
  body.br-studio-active .app-content{padding:6px;overflow:auto}
  body.br-studio-active #bgRemoverView{height:auto;min-height:100dvh}
  body.br-studio-active .br-workspace{height:auto;overflow:visible}
}

.br-assistant-actions{display:grid;gap:7px}
.br-assistant-actions button{width:100%;min-height:38px;font-size:7px}
.br-assistant-actions button.active{border-color:var(--red);background:#fff0ef;color:var(--red)}
