/* DarkRoom refinement: single-photo editor surface */
html,body,#app,.editor{height:100%;min-height:100%;}
body.focused-darkroom{overflow:hidden;background:#080809;color:#ececef;color-scheme:dark;}
.editor{display:grid!important;grid-template-rows:56px minmax(0,1fr);grid-template-columns:minmax(0,1fr) 360px;inset:0;background:#080809;}
.editor.hidden{display:grid!important;}
.editor-top{grid-column:1/-1;}
.editor-stage{grid-column:1;grid-row:2;position:relative;min-width:0;min-height:0;overflow:hidden;}
.editor-panel{grid-column:2;grid-row:2;min-width:0;}
.editor-empty-picker{position:absolute;inset:0;z-index:20;display:grid;place-items:center;background:#080809;}
.editor-empty-picker.hidden{display:none!important;}
.editor-empty-card{display:flex;flex-direction:column;align-items:center;gap:12px;color:#aaa;text-align:center;}
.editor-empty-card button{height:42px;padding:0 18px;border:1px solid #343438;border-radius:8px;background:#1b1b1e;color:#f2f2f4;font-weight:650;cursor:pointer;}
.editor-empty-card button:hover{background:#242428;}
.editor-title.empty b,.editor-title.empty small{opacity:.38;}
#canvasWrap{position:relative;display:grid;place-items:center;}
#editorCanvas{position:relative!important;inset:auto!important;width:auto!important;height:auto!important;display:block!important;z-index:1;}
#beforeSplitCanvas{position:absolute!important;left:0;top:0;right:auto;bottom:auto;display:none;z-index:3;pointer-events:none;clip-path:inset(0 50% 0 0);}
#beforeSplitCanvas.active{display:block;}
#maskOverlay,#diagnosticOverlay{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;display:block;}
#maskOverlay{z-index:4;pointer-events:none;}
#diagnosticOverlay{z-index:5;pointer-events:none;}
#beforeSplitDivider{position:absolute!important;z-index:7;width:1px!important;background:#f4f4f4!important;box-shadow:0 0 0 1px rgba(0,0,0,.35);pointer-events:none;}
#beforeSplitRange{position:absolute!important;z-index:8;right:auto;bottom:auto;opacity:0!important;cursor:ew-resize;transform:none!important;}
.session-filmstrip,.focused-launchbar,#libraryView,#panelToggle,#closeEditor{display:none!important;}
#photoViewport{padding-bottom:0!important;}
.zoom-controls{bottom:14px!important;}
.histogram-block{padding-bottom:10px;}
.histogram-tone-strip{position:relative;height:30px;margin-top:-1px;border-top:1px solid #303034;}
.hist-tone-handle{position:absolute;top:5px;width:18px;height:18px;margin-left:-9px;padding:0;border:0;background:transparent;cursor:ew-resize;color:#d8d8dc;touch-action:none;}
.hist-tone-handle::before{content:"";position:absolute;left:3px;top:3px;width:0;height:0;border-left:6px solid transparent;border-right:6px solid transparent;border-bottom:10px solid currentColor;filter:drop-shadow(0 1px 1px #000);}
.hist-tone-handle:focus-visible{outline:1px solid #888;outline-offset:2px;border-radius:3px;}
.hist-tone-handle[data-tone="shadows"]{left:18%;}.hist-tone-handle[data-tone="midtones"]{left:50%;}.hist-tone-handle[data-tone="highlights"]{left:82%;}
.tool-section-header{min-height:54px;}
.crop-aspect-line{display:grid!important;grid-template-columns:1fr auto;gap:8px;align-items:end;}
.crop-aspect-line label{min-width:0;}
.crop-aspect-line select,#toolTabs select{width:100%;background:#18181b!important;color:#e8e8eb!important;border:1px solid #3a3a3f!important;border-radius:6px!important;color-scheme:dark!important;}
.preset-picker-row{display:grid;grid-template-columns:minmax(0,1fr) 34px;gap:7px;align-items:center;}
.preset-picker-row select{height:38px;padding:0 9px;}
.preset-delete{height:38px;border:1px solid #343438;border-radius:6px;background:#19191c;color:#aaa;cursor:pointer;}
.preset-delete:disabled{opacity:.28;cursor:default;}
.preset-save{display:grid!important;grid-template-columns:minmax(0,1fr) auto;gap:7px;margin-top:8px;}
.mask-create-simple{display:flex;flex-direction:column;gap:14px;}
.mask-create-simple>div:first-child>b{display:block;margin:0 0 4px;font-size:11px;line-height:1.3;font-weight:650;color:#d7d7dc;letter-spacing:0;}
.mask-create-simple .feature-note{margin:0;max-width:100%;}
.mask-create-simple .mask-methods{display:grid;grid-template-columns:1fr 1fr;gap:7px;}
.mask-brush-size{display:grid;grid-template-columns:1fr auto;grid-template-rows:auto auto;align-items:center;gap:5px 10px;color:#b9b9bf;font-size:11px;}
.mask-brush-size span{grid-column:1;grid-row:1;}
.mask-brush-size b{grid-column:2;grid-row:1;min-width:24px;color:#aaa;font-size:11px;font-weight:400;text-align:right;}
.mask-brush-size input[type=range]{grid-column:1/-1;grid-row:2;width:100%;height:3px;margin:0;accent-color:#cfcfcf;}
.mask-create-simple .mask-methods button,.mask-create-simple .mask-methods button.primary-action{min-height:34px!important;padding:7px 10px!important;border:1px solid #343439!important;border-radius:7px!important;background:#1a1a1d!important;color:#c8c8ce!important;font-size:11px!important;font-weight:500!important;line-height:1!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;cursor:pointer!important;box-shadow:none!important;}
.mask-create-simple .mask-methods button:hover,.mask-create-simple .mask-methods button.primary-action:hover{border-color:#55555c!important;background:#202024!important;color:#fff!important;}
.mask-create-simple .mask-methods button:focus-visible{outline:1px solid #888;outline-offset:2px;}
.mask-create-simple .mask-methods button::before{content:"";width:13px;height:13px;flex:0 0 13px;background:currentColor;opacity:.9;-webkit-mask-position:center;mask-position:center;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-size:contain;mask-size:contain;}
#newBrushMask::before{-webkit-mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M7 16c-1.66 0-3 1.34-3 3 0 1.33-1.08 2.4-2.4 2.4 1.18.7 2.53 1.1 4 1.1 3.87 0 7-3.13 7-7 0-.55-.45-1-1-1s-1 .45-1 1c0 2.76-2.24 5-5 5H7zm14.71-11.29a.996.996 0 0 0-1.41 0l-9.59 9.59 2.99 2.99 9.59-9.59a.996.996 0 0 0 0-1.41l-1.58-1.58z'/%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M7 16c-1.66 0-3 1.34-3 3 0 1.33-1.08 2.4-2.4 2.4 1.18.7 2.53 1.1 4 1.1 3.87 0 7-3.13 7-7 0-.55-.45-1-1-1s-1 .45-1 1c0 2.76-2.24 5-5 5H7zm14.71-11.29a.996.996 0 0 0-1.41 0l-9.59 9.59 2.99 2.99 9.59-9.59a.996.996 0 0 0 0-1.41l-1.58-1.58z'/%3E%3C/svg%3E");}
#newLassoMask::before{-webkit-mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 22a5 5 0 0 1-2-4'/%3E%3Cpath d='M3.3 14A6.8 6.8 0 0 1 2 10c0-4.4 4.5-8 10-8s10 3.6 10 8-4.5 8-10 8a12 12 0 0 1-5-1'/%3E%3Ccircle cx='5' cy='16' r='2'/%3E%3C/svg%3E");mask-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 22a5 5 0 0 1-2-4'/%3E%3Cpath d='M3.3 14A6.8 6.8 0 0 1 2 10c0-4.4 4.5-8 10-8s10 3.6 10 8-4.5 8-10 8a12 12 0 0 1-5-1'/%3E%3Ccircle cx='5' cy='16' r='2'/%3E%3C/svg%3E");}
.mask-list .local-row{grid-template-columns:minmax(0,1fr) auto auto!important;}
.mask-list .local-name{display:flex;flex-direction:column;align-items:flex-start;text-align:left;}
.mask-eye,.mask-delete{width:32px;height:30px;padding:0;border:0;background:transparent;color:#aaa;cursor:pointer;}
.mask-eye.visible{color:#f0f0f2;}
.mask-adjustments{padding-top:10px;margin-top:10px;border-top:1px solid #2b2b2f;}
.mask-adjustments h4{margin:0 0 8px;font-size:12px;color:#ccc;}
.mask-overlay{opacity:0;transition:opacity .12s ease;}
#photoViewport.painting .mask-overlay,.mask-overlay.force-visible{opacity:1;}
@media(max-width:760px){.editor{grid-template-columns:1fr}.editor-panel{position:absolute;right:0;top:56px;bottom:0;width:min(88vw,360px);z-index:30}.editor-top-actions{margin-left:auto}.editor-title{max-width:45vw}}
