body[data-loven-surface="cabinet"] {
  --paper: #fcfbf7; --green: #334e41; --soft: #e8ede6; --line: #d7d9ce; --ink: #28352c; --muted: #61685d;
  background: #f0f0e8; color: var(--ink); font: 17px/1.4 var(--hand-cn);
}
body[data-loven-surface="cabinet"]::before { display: none; }
#cabinet-app {
.symbols, [hidden] { display: none !important; }
svg:not(.symbols) { width: 19px; height: 19px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
button { box-shadow: none; background-image: none; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 38px; border-radius: 7px; border: 1px solid var(--line); background: var(--paper); font: inherit; color: var(--ink); }
button:hover, button:focus-visible { border-color: #79917c; color: var(--green); background: #edf0e8; }
button:focus-visible, select:focus-visible, input:focus-visible, canvas:focus-visible { outline: 2px solid #55715b; outline-offset: 2px; }
button:disabled { opacity: .4; cursor: default; }
.studio-bar { min-height: 82px; padding: 15px clamp(18px,3.2vw,62px); border-bottom: 1px solid #cdd1c6; display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--paper); }
.brand, .bar-actions, .board-bar, .board-foot, .file-info, .switcher, .history, .tools-top, .prop-title, .object-row, .finish-options, .studio-foot { display: flex; align-items: center; }
.brand { gap: 19px; }
.brand-mark { width: 88px; height: 42px; overflow: hidden; display: block; }
.brand-mark img { clip-path: polygon(0 0,100% 0,100% 71%,16% 71%,16% 80%,0 80%); width: 100%; display: block; height: auto; }
.brand-rule, .mini-rule { height: 23px; width: 1px; background: var(--line); }
.brand h1 { font-size: clamp(22px,2.1vw,30px); margin: 0; line-height: 1.15; }
.bar-actions { gap: 10px; }
.bar-actions button { padding: 2px 18px; height: 41px; }
button.primary { background: var(--green); color: #fffdf5; border-color: var(--green); }
button.primary:hover { background: #264333; }
.studio { width: min(1720px,100%); margin: 0 auto; display: grid; grid-template-columns: minmax(0,1fr) clamp(252px,21vw,306px); gap: 13px 21px; padding: clamp(17px,2.25vw,38px) clamp(16px,3.2vw,62px) 20px; align-items: start; }
.drawing-board,.tools { min-width: 0; border: 1px solid var(--line); background: var(--paper); border-radius: 12px; overflow: hidden; box-shadow: 0 5px 20px -17px #344337; }
.board-bar { padding: 11px 17px; gap: 12px; justify-content: space-between; }
.file-info { gap: 10px; font-size: 19px; min-width: 0; }
.file-info > svg { color: var(--muted); }
#file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#sample-tag { color: #656753; border: 1px solid #d7d8c8; padding: 0 7px; border-radius: 4px; font-size: 13px; white-space: nowrap; }
.switcher { flex: none; background: #e9ebe3; padding: 3px; border-radius: 6px; }
.switcher button { min-height: 29px; padding: 0 14px; font-size: 15px; background: transparent; border: 0; border-radius: 4px; }
.switcher button[aria-pressed="true"] { background: var(--paper); box-shadow: 0 1px 4px #26342626; }
.stage { position: relative; display: grid; place-items: safe center; overflow: auto; overscroll-behavior: contain; height: clamp(370px, calc(100svh - 223px), 920px); min-height: 0; background: #dddfd3; border-block: 1px solid var(--line); scrollbar-width: thin; }
#drawing { display: block; max-width: none; touch-action: none; box-shadow: 0 1px 8px #2222; }
#drawing.pan { cursor: grab; touch-action: pan-x pan-y; }
#pan[aria-pressed="true"] { background: var(--soft); }
#drawing[data-tool="select"] { cursor: default; }
#drawing:not([data-tool="select"]) { cursor: crosshair; }
.board-foot { padding: 9px 14px 9px 17px; gap: 10px; justify-content: space-between; min-height: 52px; }
#hint { color: #445641; font-size: 15px; }
.history { gap: 2px; flex: none; }
.icon-btn { width: 32px; min-height: 32px; padding: 0; font-size: 17px; border: 0; background: transparent; }
.icon-btn svg { width: 17px; height: 17px; }
.mini-rule { height: 16px; margin: 0 6px; }
#zoom-value { font-size: 13px; min-width: 34px; text-align: center; }
.tools-top,.prop-title { gap: 9px; }
.tools-top { padding: 16px 18px; border-bottom: 1px solid var(--line); }
.tools h2 { font-size: 20px; margin: 0; line-height: 1.2; }
.tools svg { color: var(--green); }
.tools-body { padding: 15px; }
.tool-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.tool-grid button { justify-content: flex-start; min-height: 44px; padding: 7px 10px; font-size: 16px; }
.tool-grid button:last-child { grid-column: span 2; }
.tool-grid button[aria-pressed="true"] { border-color: #708a72; background: var(--soft); color: #294031; }
.tool-grid button[aria-pressed="true"] svg { stroke-width: 1.9; }
.properties { border-top: 1px solid var(--line); margin-top: 17px; padding-top: 16px; }
.prop-title { margin-bottom: 14px; }
label,.field-label { display: block; margin: 0 0 4px; font-size: 15px; color: var(--muted); }
select,input { background: var(--paper); color: var(--ink); border-color: var(--line); font: inherit; border-radius: 5px; }
.object-row { gap: 4px; }
.object-row select { min-width: 0; flex: 1; }
#finishes,#note-editor,#element-props { margin-top: 13px; }
.finish-options { gap: 6px; width: 100%; }
.finish-options button { flex: 1; min-width: 0; flex-direction: column; padding: 4px 3px; gap: 2px; font-size: 14px; }
.finish-options i { display: block; width: 100%; height: 19px; border-radius: 3px; }
[data-finish="oak"] i { background: repeating-linear-gradient(4deg,#cfab77 0 2px,#c7a070 3px,#d1ae82 7px); }
[data-finish="walnut"] i { background: repeating-linear-gradient(4deg,#6f5140 0 2px,#775644 3px,#694b3d 7px); }
[data-finish="chalk"] i { background: #e4dfd3; }
.finish-options [aria-pressed="true"] { border-color: #627c65; box-shadow: 0 0 0 1px #627c65 inset; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
input[type="range"] { padding: 0; min-height: 21px; accent-color: var(--green); display: block; }
.extent { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.studio-foot { grid-column: 1/-1; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 14px; }
.studio-foot button { font-size: 14px; border: 0; background: none; padding: 0 3px; min-height: 25px; text-decoration: underline; text-underline-offset: 3px; color: var(--green); }
.project-nav { grid-column: 1/-1; display: flex; gap: 12px; align-items: center; min-width: 0; }
.project-nav button { min-height: 32px; flex-shrink: 0; padding: 0 10px; font-size: 15px; }
#project-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#import-draft { margin-left: auto; }
#empty-project { display: grid; place-items: center; }
#empty-project button { padding: 8px 16px; }
.recovery-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.recovery-actions a { color: var(--green); font-size: inherit; }
@media(max-width: 760px) {
  .studio-bar { min-height: 63px; padding: 10px 14px; }
  .brand { gap: 8px; } .brand-mark { width: 62px; height: 30px; } .brand-rule { height: 17px; }
  .brand h1 { font-size: 20px; } .bar-actions { gap: 5px; }
  .bar-actions button { padding: 0 8px; height: 35px; min-height: 35px; font-size: 15px; gap: 4px; }
  .bar-actions svg { width: 15px; height: 15px; }
  .studio { grid-template-columns: minmax(0,1fr); gap: 10px; padding: 12px 10px; }
  .stage { height: clamp(238px,55vw,410px); }
  .board-bar { padding: 7px 10px; } .file-info { gap: 6px; font-size: 16px; }
  .switcher button { padding: 0 10px; }
  .board-foot { padding: 6px 9px; flex-wrap: wrap; min-height: 40px; } .history { margin-left: auto; }
  .history .icon-btn { width: 28px; }
  .tools-top { padding: 10px 13px; } .tools-body { padding: 10px 12px; }
  .tool-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 5px; }
  .tool-grid button,.tool-grid button:last-child { grid-column: auto; justify-content: center; padding: 4px; gap: 4px; min-height: 36px; font-size: 14px; }
  .tool-grid svg { width: 14px; height: 14px; }
  .properties { margin-top: 12px; padding-top: 12px; }
  #finishes { max-width: 290px; } .studio-foot { flex-wrap: wrap; }
}
@media(max-width: 390px) { .tool-grid { grid-template-columns: repeat(3,minmax(0,1fr)); } .bar-actions svg { display: none; } }
}
