/* Katalog Stüdyo 0.2 · soft, restrained, quiet UI */
:root{--ink:#2b3730;--muted:#8b998f;--line:#e5eae3;--green:#385e46;--surface:#f8f9f7}
body{font-family:-apple-system,BlinkMacSystemFont,"Helvetica Neue",Arial,sans-serif;background:#f8f9f7;color:var(--ink)}
.shell{background:#f8f9f7}.main{background:#f8f9f7;min-width:0}.sidebar{background:#fff}.content{max-width:1720px;margin:0 auto;padding:38px 40px 64px}.topbar{background:#fff}
.sidebar .nav-link{font-weight:540}.side-bottom small,.app-version{color:#76907c}
.btn{white-space:nowrap}.table-scroll{overflow-x:auto}.cell-actions{white-space:nowrap}.cell-actions .btn{margin:0 3px}.stat{min-height:130px}.panel-header{align-items:center}.count-pill{white-space:nowrap}
.sortable-list{padding:5px 16px 14px}.sort-row{display:flex;align-items:center;gap:14px;border-bottom:1px solid #eef1eb;min-height:56px;padding:8px 10px;background:#fff;font-size:12px;cursor:grab;color:#46564b}.sort-row:last-child{border-bottom:0}.sort-row:active{cursor:grabbing}.sort-row.dragging{opacity:.35;background:#edf3ed}.sort-row:hover{background:#fafbf9}.sort-row strong{font-size:12px;font-weight:620}.sort-row .row-end{margin-left:auto;display:flex;gap:8px;align-items:center}.sort-row small{color:#93a097}.drag-grip{font-size:19px;color:#a5b5a9;cursor:grab;user-select:none;touch-action:none}.color-square{width:27px;height:27px;border:1px solid #d8ded8;border-radius:5px;flex-shrink:0;display:inline-block}.compact-sort{padding:0;border:1px solid var(--line);border-radius:9px;max-height:190px;overflow:auto}.compact-sort .sort-row{min-height:39px;padding:4px 9px;font-size:11px;gap:8px}.compact-sort .color-square{width:18px;height:18px}.compact-sort .drag-grip{font-size:15px}.color-stack{display:flex;gap:4px;align-items:center}.color-stack small{font-size:10px;margin-left:5px;color:#879887}
.size-chips,.pack-sizes{display:flex;gap:5px;flex-wrap:wrap}.size-chips span{border:1px solid #e6ebe5;border-radius:7px;display:flex;gap:8px;align-items:center;padding:7px 9px}.size-chips span b{font-size:11px}.size-chips span small{font-size:10px;color:#768578}.wrap-inline{flex-wrap:wrap;gap:15px}.field textarea{min-height:65px;font-family:inherit;font-size:12px;padding:10px;border:1px solid #e2e9df;border-radius:8px}
.media-filters{display:flex;gap:8px;margin-bottom:20px;flex-wrap:wrap}.filter-pill{border:1px solid var(--line);border-radius:22px;background:white;color:#758476;font-size:11px;padding:9px 15px;cursor:pointer}.filter-pill.active{background:#eaf1e9;border-color:#b4cbb6;color:#395b42;font-weight:650}.media-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(185px,1fr));gap:16px}.media-card{border:1px solid var(--line);border-radius:12px;overflow:hidden;background:white}.media-card img{width:100%;aspect-ratio:5/4;object-fit:contain;background:#f0f2ee}.media-meta{display:flex;flex-direction:column;gap:5px;padding:12px}.media-meta strong{font-size:11px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.media-meta span{font-size:10px;color:#879588;text-transform:capitalize}
.choice-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.layout-choice{display:flex;flex-direction:column;gap:7px;position:relative;border:1px solid #e3eae2;border-radius:10px;padding:16px;cursor:pointer}.layout-choice input{position:absolute;right:13px;top:13px}.layout-choice b{font-size:12px}.layout-choice small{font-size:10px;color:#95a195}.settings-grid{display:grid;grid-template-columns:1.1fr 1fr;gap:18px}.settings-grid>.panel{display:flex;flex-direction:column;gap:15px}.settings-grid .section-desc{line-height:1.7}.language-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.language-grid label{font-size:11px;display:flex;gap:6px;align-items:center}.language-grid input,.field input[type=checkbox]{min-height:auto;width:auto;accent-color:#3f7651}.settings-grid .search{width:100%;padding:9px;border:1px solid var(--line);border-radius:8px;font-size:12px}.translation-list{margin-top:22px}.translation-row{display:grid;grid-template-columns:1fr 1.1fr auto;align-items:center;gap:15px;border-top:1px solid var(--line);padding:12px 3px}.translation-row>div{display:flex;flex-direction:column;gap:5px}.translation-row small{color:#94a098;font-size:10px}.translation-row strong{font-size:12px;font-weight:540}.translation-input{width:100%;border:1px solid var(--line);padding:10px 12px;border-radius:7px;color:#435447;font-size:12px;outline:none}.translation-input:focus{border-color:#aec4ae}.quick-steps{display:grid;gap:16px;margin:24px 0}.quick-steps div{font-size:12px}.quick-steps span{color:#7c9d81;font-size:11px;font-weight:750;margin-right:16px}.note-card{background:#f3f6f1;color:#718675;padding:14px 16px;border-radius:9px;font-size:11px;line-height:1.7}
/* Editor canvas typography: relative to A4 paper, not browser font scaling. */
.editor-shell{grid-template-columns:176px minmax(350px,1fr) 288px;gap:18px}.editor-stage{background:#eff2ee;min-height:790px;overflow:visible;align-items:flex-start}.editor-stage .canvas{width:min(100%,570px);box-shadow:0 8px 30px #223e2920}.editor-stage .canvas .page-node{font-family:-apple-system,BlinkMacSystemFont,'Helvetica Neue',Arial,sans-serif}.page-node.type-swatches,.page-node.type-package,.page-node.type-fabric{overflow:hidden;line-height:1.1}.page-node.type-fabric{display:flex;align-items:center;font-weight:420}.page-node.type-catalogName{display:flex;align-items:center;line-height:1.06;overflow:hidden}.page-node.type-coverImage{background:#e9ece8}.page-node.type-logo{background:transparent}.page-node.type-image .node-inner,.page-node.type-coverImage .node-inner,.page-node.type-logo .node-inner{overflow:hidden}.page-node .frame-image{width:100%;height:100%;display:block;object-fit:cover;transform-origin:center center}.frame-placeholder{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:7px;width:100%;height:100%;background:#eef0ec;color:#a4afa6}.frame-placeholder span{font-size:5cqw}.frame-placeholder small{font-size:1.3cqw;letter-spacing:.11em}.page-node.selectable{cursor:pointer}.page-node.selected-element{outline:2px solid #4d9062;outline-offset:2px;z-index:10;overflow:visible}.page-node.selected-element .node-inner{overflow:hidden}.props input[type=range]{width:100%;accent-color:#42724f}
.swatch-display{width:100%;height:100%;display:flex;flex-direction:column;min-height:0}.swatch-heading{font-size:1.75cqw;letter-spacing:.05em;color:#7e8a81;font-weight:650;padding-bottom:1.1cqw;flex:none}.swatch-columns{display:flex;flex:1;min-height:0;gap:1.4cqw}.swatch-column{flex:1;min-width:0;display:flex;flex-direction:column;gap:.28cqw}.swatch-entry{height:2.45cqw;min-height:0;display:flex;gap:.6cqw;align-items:center;white-space:nowrap;min-width:0;font-size:1.58cqw;line-height:1}.swatch-entry span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.swatch-rect{display:inline-block;width:2.25cqw;height:2.25cqw;flex:0 0 2.25cqw;border:1px solid #cdd5cc;background-size:cover;background-position:center}.pack-display{height:100%;width:100%;font-size:1.7cqw}.pack-top{display:flex;align-items:flex-end;gap:1cqw;margin-bottom:.9cqw}.pack-top>div{display:flex;flex-direction:column;gap:.25cqw}.pack-top small{font-size:1.38cqw;font-weight:700;color:#879589;letter-spacing:.04em}.pack-top strong{font-size:3.2cqw;line-height:1.2;font-weight:620}.pack-top strong span{font-size:1.5cqw;font-weight:440;color:#6e7a70}.pack-sizes{display:flex;flex-wrap:nowrap;gap:.35cqw;overflow:hidden}.pack-sizes>div{background:#f2f5f1;padding:.55cqw .3cqw;border-radius:.45cqw;flex:1;display:flex;gap:.3cqw;align-items:center;justify-content:center;flex-direction:column;min-width:0}.pack-sizes>div span{font-size:1.45cqw;font-weight:650}.pack-sizes>div b{font-size:1.25cqw;color:#78847a}.watermark-overlay{position:absolute;top:50%;left:50%;font-size:5.1cqw;font-weight:800;letter-spacing:.08em;white-space:nowrap;pointer-events:none;z-index:20;color:#2d5842}.watermark-overlay img{width:27cqw;max-height:12cqw;object-fit:contain}.overflow-title{position:absolute;top:10%;left:9%;font-size:4cqw;font-weight:650}.overflow-swatches{position:absolute;top:26%;left:10%;width:82%;height:65%}.overflow-swatches .swatch-heading{font-size:2.6cqw}.overflow-swatches .swatch-entry{font-size:2cqw;height:3.1cqw}.overflow-swatches .swatch-rect{width:3cqw;height:3cqw;flex-basis:3cqw}.pages-list{max-height:400px;overflow:auto}.pages-list .page-chip{display:block}.page-chip small{font-size:10px;color:#849288}.props .field{margin-bottom:14px}.props .field input:disabled{background:#f6f8f4}
@media(max-width:1260px){.editor-shell{grid-template-columns:142px minmax(330px,1fr) 250px;gap:13px}.content{padding:27px 25px}.editor-stage .canvas{width:min(100%,515px)}}
@media(max-width:1050px){.sidebar{width:84px;flex-basis:84px}.editor-shell{grid-template-columns:125px minmax(260px,1fr) 210px}.editor-stage{min-height:600px}.swatch-entry{font-size:1.75cqw}}
@media(max-width:780px){.editor-shell{display:flex;flex-direction:column}.editor-shell>aside{width:100%}.editor-stage{width:100%;min-height:0}.editor-stage .canvas{width:min(100%,560px)}.settings-grid{grid-template-columns:1fr}.translation-row{grid-template-columns:1fr;gap:8px}.media-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.page-chip{display:inline-block!important;width:auto!important}.catalog-grid{grid-template-columns:1fr}.choice-grid{grid-template-columns:1fr}.content{padding:20px 14px}}
.swatch-heading{min-height:4.45cqw;padding-bottom:.7cqw}.swatch-entry{min-height:0;font-size:1.78cqw}.swatch-rect{width:2.75cqw;height:2.75cqw;flex-basis:2.75cqw}

/* 0.2.1: minimal smart guides and clean logo frame */
.smart-toggle{display:flex;gap:9px;align-items:center;font-size:11px;color:#486150;cursor:pointer;padding:9px 4px}
.smart-toggle input{accent-color:#3e6c4d;width:15px;height:15px}
.snap-guide{position:absolute;z-index:100;pointer-events:none;opacity:.96}
.snap-guide-x{top:0;bottom:0;width:1px;background:#34a7a2;transform:translateX(-.5px);box-shadow:0 0 0 .3px #34a7a2}
.snap-guide-y{left:0;right:0;height:1px;background:#34a7a2;transform:translateY(-.5px);box-shadow:0 0 0 .3px #34a7a2}
.logo-placeholder{background:rgba(237,243,237,.74)!important;border:1px dashed #b7c9b9;color:#60836a}
.page-node.type-logo .frame-image{object-fit:contain}
#editor-canvas .page-node{touch-action:none}

/* 0.3 · In-app, read-only, high-fidelity PDF preview */
.content:has(.preview-layout){max-width:none;padding:24px 30px 34px}
.preview-layout{height:calc(100vh - 132px);display:flex;flex-direction:column;gap:13px;min-height:600px}
.preview-toolbar{background:#fff;border:1px solid #e6ece5;border-radius:13px;display:flex;align-items:center;justify-content:space-between;gap:15px;padding:16px 20px;flex-wrap:wrap}
.preview-info .eyebrow{margin-bottom:5px;letter-spacing:1.3px;font-size:9px}
.preview-info h1{margin:0;font-size:19px;font-weight:680;letter-spacing:-.5px}
.preview-info p{margin:4px 0 0;color:#93a196;font-size:11px}
.preview-actions{display:flex;gap:7px;flex-wrap:wrap}
.preview-container{flex:1;min-height:0;border-radius:12px;border:1px solid #dfe7de;overflow:hidden;background:#e7eae7}
.preview-frame{border:0;display:block;width:100%;height:100%;background:#e8ece7}
.preview-footer{font-size:11px;color:#8e9c90;padding:0 5px}
@media(max-width:760px){.content:has(.preview-layout){padding:12px}.preview-layout{height:calc(100dvh - 85px);min-height:530px}.preview-toolbar{padding:12px}.preview-actions .btn{font-size:11px;padding:7px}.preview-info p{font-size:10px}}

/* v0.3: image-independent in-app preview with page navigation and zoom */
.preview-mode-toggle{display:flex;align-items:center;gap:4px;padding:3px;border:1px solid var(--line);border-radius:9px;background:#f9fbf8}
.preview-mode-toggle .btn{border-color:transparent}
.preview-two-pane{height:100%;display:flex;min-height:0}
.preview-rail{width:178px;flex:0 0 178px;padding:18px 11px;background:#fff;border-right:1px solid #dfe7de;overflow:auto}
.preview-rail .rail-caption{margin:2px 10px 14px}
.preview-page-link{width:100%;display:flex;align-items:center;gap:10px;border:1px solid transparent;background:#fff;border-radius:9px;margin-bottom:5px;text-align:left;cursor:pointer;padding:9px 7px;color:#4f5d51}
.preview-page-link:hover{background:#f6f9f6}.preview-page-link.selected{background:#ebf3eb;border-color:#b7d0bc}
.preview-page-number{width:27px;height:37px;background:#f0f2ef;border:1px solid #e7eae5;border-radius:4px;font-size:11px;font-weight:650;display:grid;place-items:center;color:#59705d;flex:none}
.preview-page-link strong{display:block;font-size:11px}.preview-page-link small{display:block;font-size:10px;margin-top:4px;color:#86998b}
.preview-paper-stage{display:flex;flex-direction:column;align-items:stretch;justify-content:stretch;flex:1;min-width:0;min-height:0}
.preview-paper-scroll{flex:1;min-height:0;overflow:auto;display:flex;align-items:flex-start;justify-content:center;padding:25px}
.preview-paper{max-width:none!important;min-width:0;flex:none;box-shadow:0 8px 35px #253e2f25;border:1px solid #dfe5dc}
.preview-controls{flex:none;display:flex;align-items:center;justify-content:center;gap:8px;padding:10px;background:#fff;border-top:1px solid #dce4da}
.preview-controls .btn{padding:8px 11px}.preview-controls .btn:disabled{opacity:.38;cursor:default}
.preview-count{font-size:11px;color:#607566;min-width:45px;text-align:center;font-variant-numeric:tabular-nums}
.preview-control-divider{margin:0 10px;width:1px;height:22px;background:#e1e7df}
@media(max-width:760px){.preview-rail{width:95px;flex-basis:95px;padding:7px 4px}.preview-page-link{gap:5px;padding:7px 4px}.preview-page-number{width:22px;height:31px}.preview-page-link strong,.preview-page-link small{font-size:9px}.preview-paper-scroll{padding:13px}.preview-controls{gap:3px;padding:6px 3px}.preview-controls .btn{padding:7px 6px;font-size:10px}}

/* Product detail editor: full page with compact tabs and explicit save. */
.product-open{padding:0;border:0;background:none;font:inherit;font-weight:650;color:#2b4732;cursor:pointer}.product-open:hover{text-decoration:underline}
.product-detail{max-width:1130px;margin:0 auto}.product-tabs{display:flex;gap:25px;border-bottom:1px solid #e1e8df;margin:0 0 19px}
.product-tab{font:inherit;font-size:12px;color:#798879;cursor:pointer;padding:14px 4px;background:none;border:0;border-bottom:2px solid transparent}
.product-tab.active{font-weight:700;color:#335840;border-bottom-color:#40694a}
.product-section{display:none}.product-section.active{display:block}.product-section .panel{min-height:250px}.product-section .form-grid{max-width:960px}
.product-section .field textarea{min-height:140px}.product-section .checkbox-colors{margin-top:24px}
.product-subtitle{margin-top:30px}.product-color-list{max-height:none;margin-top:12px}
.product-photo-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(145px,1fr));gap:15px;margin:23px 0}.product-photo-grid .gallery-item{width:auto}.product-photo-grid .gallery-item img{width:100%;height:215px;object-fit:contain;background:#f1f3ef}
.product-upload{display:flex;align-items:flex-end;flex-wrap:wrap;gap:14px}.product-upload .field{flex:1;min-width:165px}
.product-pack-preview{max-width:610px;border-top:1px solid #e2e8e0;margin-top:25px;padding-top:22px;display:flex;gap:30px;flex-direction:column}
.product-pack-preview>div:first-child{display:flex;flex-direction:column;gap:5px}.product-pack-preview small{font-size:10px;font-weight:700;color:#8b9a8e}.product-pack-preview strong{font-size:22px}
.product-pack-sizes{display:flex;gap:9px;flex-wrap:wrap}.product-pack-sizes span{padding:14px 16px;border:1px solid #e0e7dd;border-radius:9px;background:#f7f9f6;font-size:12px}.product-pack-sizes b{padding-left:9px}
.product-save-footer{position:sticky;bottom:8px;z-index:5;margin:22px auto 0;padding:15px 20px;background:#fff;border:1px solid #e2e8df;border-radius:12px;display:flex;gap:12px;align-items:center;justify-content:space-between;box-shadow:0 7px 22px #1b3f2520}
@media(max-width:760px){.product-tabs{gap:15px}.product-upload{display:block}.product-save-footer{bottom:0}}
/* v0.5 · compact, single-page product workflow */
[hidden]{display:none!important}
.single-product{max-width:1280px}
.single-product #product-form{display:grid;gap:16px}
.single-product .product-compact{min-height:unset;padding:22px 26px}
.single-product .product-compact textarea{min-height:66px;resize:vertical}
.single-product .section-heading{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin:0 0 16px}
.single-product .section-heading h3{font-size:14px;color:#263c2c;font-weight:680;margin:0}
.single-product .section-heading small{font-size:11px;color:#9fa9a1}
.single-product .checkbox-colors{display:flex;gap:7px;flex-wrap:wrap;margin:0 0 16px}
.single-product .color-choice{margin:0}
.single-product .product-color-list{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;background:transparent;border:0}
.single-product .product-color-list .sort-row{background:#f8faf7;border:1px solid #e9eee8;border-radius:8px;padding:8px 10px}
.single-product .product-colors-order-label{font-size:11px;font-weight:650;margin:7px 0 9px;color:#7a897d}
.single-product .pack-inline{display:grid;grid-template-columns:minmax(225px,1fr) minmax(250px,1.5fr);gap:20px;align-items:end;margin-top:14px;padding-top:18px;border-top:1px solid #edf1eb}
.single-product .pack-inline .product-pack-preview{margin:0}
.single-product .product-photo-grid{grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:12px;margin:10px 0 16px}
.single-product .product-photo-grid .gallery-item img{height:190px}
.bulk-upload-drop{border:1.5px dashed #b5c9bb;border-radius:12px;min-height:125px;background:#f7faf7;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:5px;padding:18px 20px;transition:.15s}
.bulk-upload-drop.drag-hover{background:#e7f4e8;border-color:#46734f}
.bulk-upload-drop strong{font-size:12px;color:#344d38}
.bulk-upload-drop small{font-size:11px;color:#7c9080}
.bulk-upload-drop .bulk-upload-icon{font-size:25px;color:#64866b}
.bulk-upload-drop input[type=file]{max-width:310px;font-size:11px;margin:6px auto 0}
.bulk-upload-controls{display:grid;grid-template-columns:minmax(160px,1fr) minmax(180px,1fr) auto;gap:12px;align-items:end;margin:14px 0}
.bulk-upload-controls button{height:37px}
.single-product .product-save-footer{margin:0;bottom:8px}
/* template toolbox state & per-item controls */
.tool-item{display:flex;align-items:center;border:1px solid #e7ebe6;border-radius:8px;margin:0 0 6px;background:#fff;min-height:39px;overflow:hidden}
.tool-item.is-added{border-color:#bfcebF;background:#f0f7f0}
.tool-label{display:flex;align-items:center;gap:7px;flex:1;min-width:0;cursor:pointer;border:0;background:transparent;text-align:left;font-size:10px;color:#495f4c;padding:9px 7px}
.tool-label .tool-icon{font-size:14px;width:18px;color:#63866b;text-align:center}
.tool-label .tool-name{flex:1;white-space:normal;line-height:1.25}
.tool-label small{font-weight:700;color:#4c7957}
.tool-toggle{height:31px;min-width:26px;font-size:15px;background:#fff;border:1px solid #e4ebe3;border-radius:6px;margin:2px;color:#3f6a47;cursor:pointer}
.tool-toggle:disabled{opacity:.24;cursor:default}
.tool-toggle:hover:not(:disabled){background:#e6f0e7}
/* template editor fields */
.props input[data-prop=background],.props input[data-prop=color],#template-bg-hex{font-family:ui-monospace,monospace;letter-spacing:.01em}
.page-node.type-price{display:flex;align-items:center;font-weight:600;white-space:normal;line-height:1.1}
/* pricing lists */
.price-editor{max-width:1140px;margin:0 auto}
.price-editor .two{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.price-row{border-bottom:1px solid #e9eee8;padding:15px 4px}
.price-row-main{display:flex;align-items:center;gap:16px;justify-content:space-between}
.price-row-main>div{display:flex;flex-direction:column;gap:3px}
.price-row-main strong{font-size:13px;color:#273c2d}
.price-row-main small{font-size:11px;color:#8c9a8e}
.price-input-label{display:flex;align-items:center;gap:12px;font-size:11px;color:#728474}
.price-input-label input{width:160px}
.price-color-details{margin:10px 0 0 20px;font-size:11px;color:#647b68}
.price-color-details summary{cursor:pointer;user-select:none}
.price-colors-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:12px 0}
.price-colors-grid label{display:flex;gap:7px;align-items:center;background:#fafbf9;padding:8px;border:1px solid #ecf0eb;border-radius:6px;font-size:10px}
.price-colors-grid input{margin-left:auto;max-width:110px;min-width:80px}
.price-catalog-options{background:#f5f8f4;border:1px solid #e4ebe1;padding:13px;border-radius:8px}
.price-catalog-options .two{display:grid;grid-template-columns:1fr 1fr;gap:10px}
/* catalog creation / filters */
.catalog-selection-toolbar{display:grid;grid-template-columns:1.1fr 1fr 1fr;gap:7px;margin:10px 0}
.catalog-selection-buttons{display:flex;gap:8px;margin-bottom:8px}
.catalog-modal-products .product-check{min-height:44px}
/* customer notes */
.notes-summary{padding:11px 14px;border:1px solid #e6ece5;background:#f8faf7;border-radius:8px;display:flex;flex-direction:column;gap:4px}
.notes-summary strong{font-size:13px}.notes-summary small{font-size:11px;color:#89978d}
.notes-timeline{max-height:250px;overflow:auto;margin:14px 0}
.note-item{padding:10px 13px;margin:0 0 8px;border-left:3px solid #b6cbb8;background:#f8faf7;border-radius:4px}
.note-item strong{font-size:11px}.note-item p{font-size:12px;margin:5px 0;white-space:pre-wrap}.note-item small{font-size:10px;color:#8a958a}
/* precise swatch sizing is set on element style; do not override below */
.swatch-rect{min-width:0;min-height:0}
.swatch-entry{max-width:100%}
@media(max-width:920px){.single-product .pack-inline{grid-template-columns:1fr}.bulk-upload-controls{grid-template-columns:1fr 1fr}.bulk-upload-controls button{grid-column:span 2}.catalog-selection-toolbar{grid-template-columns:1fr}}
@media(max-width:650px){.single-product .product-compact{padding:16px}.single-product .product-color-list,.price-colors-grid{grid-template-columns:1fr 1fr}.bulk-upload-controls{grid-template-columns:1fr}.bulk-upload-controls button{grid-column:auto}.price-editor .two{grid-template-columns:1fr}.price-row-main{align-items:start;flex-direction:column}.price-colors-grid{grid-template-columns:1fr}}
.gallery-item{position:relative}
.gallery-photo-check{position:absolute;top:7px;left:8px;display:grid;place-items:center;background:#ffffffd9;border-radius:6px;padding:4px;z-index:1}
.gallery-photo-check input{accent-color:#3d6f49}
.gallery-acts{display:flex;gap:4px;flex-wrap:wrap;justify-content:flex-end}
.gallery-acts .btn{font-size:10px;padding:4px 6px}
.bulk-photo-assign{display:flex;gap:10px;align-items:center;flex-wrap:wrap;background:#f5f8f4;padding:10px 12px;border:1px solid #e7ede5;border-radius:8px;margin:6px 0 15px}
.bulk-photo-assign span{font-size:11px;color:#596d5d}
.bulk-photo-assign select{max-width:240px}

/* v0.5.1: hierarchical categories */
.category-tree{display:flex;flex-direction:column;gap:12px}
.category-group{display:block!important;background:#fff;border:1px solid #e4e9e2;border-radius:12px;padding:11px 14px}
.category-group-head{display:flex;align-items:center;gap:12px;min-height:36px}
.category-group-head strong{font-size:13px}
.category-group-head small,.subcategory-row small{color:#819087;font-size:11px}
.subcategory-sort{margin:7px 0 0 23px;border-left:2px solid #edf0ea;padding-left:13px}
.subcategory-row{display:flex;min-height:34px;align-items:center;gap:12px;border-bottom:1px solid #f1f2ef;padding:5px 0}
.subcategory-empty{padding:9px 0;margin:0;font-size:11px}
.category-group .row-end,.subcategory-row .row-end{margin-left:auto;display:flex;gap:5px}
.category-tree .dragging{opacity:.5}
@media(max-width:800px){.category-group-head,.subcategory-row{flex-wrap:wrap}.category-group .row-end{width:100%;justify-content:flex-end}}

/* v0.5.2: text placement, visual color controls and undo */
.page-node.type-text .node-inner,.page-node.type-code .node-inner,.page-node.type-name .node-inner,.page-node.type-fabric .node-inner,.page-node.type-price .node-inner,.page-node.type-catalogName .node-inner{display:flex;flex-direction:column;justify-content:inherit;align-items:stretch;min-height:100%;white-space:normal;}
.color-picker-row{display:flex;align-items:center;gap:8px;}
.props .field input[type=color]{appearance:none;-webkit-appearance:none;cursor:pointer;flex:0 0 43px;width:43px;height:39px;min-height:39px;padding:3px;border:1px solid #d5dfd5;border-radius:9px;background:#fff;}
.props .field input[type=color]::-webkit-color-swatch-wrapper{padding:0}
.props .field input[type=color]::-webkit-color-swatch{border:1px solid #d1d6d1;border-radius:5px;}
.color-picker-row .color-hex{flex:1;min-width:0;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-variant-numeric:tabular-nums;}
.color-presets{display:flex;gap:5px;flex-wrap:wrap;margin-top:3px}.color-preset{width:20px;height:20px;border:1px solid #ccc;box-shadow:0 1px 3px #0001;border-radius:5px;cursor:pointer}.color-preset:hover{outline:2px solid #3a6844;outline-offset:2px}
.color-transparent{display:flex;align-items:center;gap:6px;font-size:11px;color:#58695e;cursor:pointer}.color-transparent input{min-height:auto!important;width:14px!important;margin:0}
.alignment-buttons{display:flex;border:1px solid #dbe5db;border-radius:9px;overflow:hidden}.alignment-buttons button{display:grid;place-items:center;flex:1;padding:9px 0;background:white;border:0;border-right:1px solid #e5ebe5;color:#798b7e;cursor:pointer}.alignment-buttons button:last-child{border-right:0}.alignment-buttons button.active{color:#2d6740;background:#e5f2e8;box-shadow:inset 0 0 0 1px #9dc5a6}.alignment-buttons button:focus-visible{outline:2px solid #477b54;outline-offset:-2px}

/* v0.5.2: direct image assignment with status */
.product-photo-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(162px,1fr));gap:12px;margin-bottom:14px}
.gallery-item{border:1px solid #e3e9e3;border-radius:11px;overflow:hidden;background:white;min-width:0}
.gallery-item.is-main{border-color:#7aaa85;box-shadow:0 0 0 1px #a1c6a8;}
.gallery-image-wrap{position:relative}.gallery-image-wrap img{width:100%;aspect-ratio:4/5;object-fit:cover;display:block}.gallery-photo-check{position:absolute;top:7px;left:7px;z-index:2;display:flex;align-items:center;justify-content:center;background:#fff;border-radius:5px;padding:5px;box-shadow:0 2px 6px #0002}.gallery-photo-check input{margin:0}
.main-image-tag{position:absolute;top:6px;right:5px;background:#245d35;color:white;font-size:9px;padding:5px;border-radius:5px;z-index:2;letter-spacing:.04em}
.gallery-photo-info{padding:10px;display:flex;flex-direction:column;gap:8px}.gallery-filename{font-size:10px;color:#677367;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gallery-photo-info .field{gap:3px}.gallery-photo-info .field label{font-size:9px}.gallery-photo-info .field select{font-size:11px;width:100%;height:34px;padding:5px}.gallery-actions{display:flex;align-items:center;flex-wrap:wrap;gap:5px}.gallery-actions button{font-size:10px;padding:7px 9px}.image-status{font-size:9px;color:#396d47}
.bulk-photo-assign{display:flex;align-items:center;flex-wrap:wrap;gap:8px;background:#f6f8f6;padding:12px;border-radius:9px;margin-bottom:15px}.bulk-photo-assign span{font-size:11px}.bulk-photo-assign select{min-height:33px;min-width:155px;flex:1}.bulk-photo-assign small{font-size:10px;color:#627263}.copy-images-check{margin:16px 0;font-size:12px}.copy-images-check input{width:17px;height:17px}

/* v0.6 access control: minimalist login */
body.auth-lock .shell,body.auth-lock #modal-root{display:none!important}
.auth-screen{min-height:100vh;background:#f4f5f1;display:none;align-items:center;justify-content:center;padding:24px}
body.auth-lock .auth-screen{display:flex}
.auth-spinner{font-size:13px;color:#7a817a}
.auth-card{background:#fff;border:1px solid #e5e8e1;box-shadow:0 18px 55px rgba(33,47,37,.07);border-radius:18px;padding:36px 36px 25px;width:100%;max-width:416px}
.auth-logo{display:flex;align-items:center;justify-content:center;width:49px;height:49px;border-radius:13px;background:#243f2d;color:white;font-size:24px;font-weight:700;letter-spacing:-2px;margin-bottom:24px}
.auth-logo span{color:#b1c9af}.auth-title{font-size:23px;font-weight:650;letter-spacing:-.6px;color:#1f3227}.auth-subtitle{margin:5px 0 24px;color:#7b877e;font-size:13px}
.auth-row{margin-bottom:16px}.auth-row label{display:block;font-size:12px;color:#4d6153;font-weight:550;margin-bottom:7px}.auth-row input{width:100%;border:1px solid #d9e2d7;background:#fdfefd;border-radius:9px;padding:12px 13px;font-size:14px;outline:0;box-sizing:border-box}
.auth-row input:focus{border-color:#5e8b69;box-shadow:0 0 0 3px #e6eee6}.auth-helper{font-size:11px;line-height:1.6;color:#718174;display:block;margin:-5px 0 15px}.auth-error{color:#ac3232;min-height:17px;font-size:12px;margin:4px 0 8px}.auth-submit{width:100%;justify-content:center;min-height:44px}.auth-foot{font-size:11px;color:#a0a8a1;text-align:center;margin-top:22px}
.user-chip{border:0;background:transparent;color:inherit;cursor:pointer;font:inherit;font-weight:600;margin-right:8px;white-space:nowrap}.user-chip:hover{text-decoration:underline}.read-only-user{font-size:13px;border:1px solid #e7ebe7;background:#f5f7f4;border-radius:8px;padding:10px;color:#455a4a}
[hidden]{display:none!important}
@media(max-width:540px){.auth-card{padding:28px 24px 22px}.user-chip{max-width:100px;overflow:hidden;text-overflow:ellipsis}}

.home-catalog-scroll{max-height:370px;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin;padding-right:8px;overscroll-behavior:contain}.home-catalog-scroll:focus-visible{outline:2px solid #8fac92;border-radius:6px}
@media(max-width:760px){.home-catalog-scroll{max-height:310px}}
.notes-activity{border-top:1px solid #e2e8e1;margin:15px 0;padding:14px 0}.notes-activity h4{font-size:12px;font-weight:650;margin:0 0 7px}.note-audit{font-size:12px;padding:7px 4px;border-bottom:1px solid #f0f3ef;color:#536759}.note-audit small{float:right;color:#8a988c;font-size:11px}

/* Color swatch visibility and direct pattern upload */
.color-kind-choices{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.color-mode-choice{display:flex;align-items:center;gap:7px;padding:11px;border:1px solid #dce5dc;border-radius:10px;cursor:pointer;flex-wrap:wrap}
.color-mode-choice:has(input:checked){background:#edf5ef;border-color:#8bb999}.color-mode-choice input{width:15px;height:15px;min-height:15px;margin:0}.color-mode-choice strong{font-size:12px}.color-mode-choice small{width:100%;margin-left:23px;color:#879489;font-size:10px}.color-kind-icon{font-size:19px;color:#749578}
.pattern-preview-box{display:flex;gap:14px;align-items:start;background:#f7f8f6;border:1px dashed #becabd;border-radius:11px;padding:13px}.pattern-preview{display:grid;place-items:center;flex:0 0 88px;width:88px;height:88px;border:1px solid #d2dcd1;background:#e8eee6;border-radius:8px;font-size:11px;color:#748474;text-align:center;overflow:hidden}.pattern-preview img{width:100%;height:100%;object-fit:cover}.pattern-inputs{display:flex;flex-direction:column;min-width:0;flex:1;gap:8px}.pattern-inputs input[type=file]{font-size:11px;max-width:100%}.pattern-inputs small{font-size:11px;line-height:1.4;color:#788679}.pattern-inputs select{min-width:0;width:100%}
.color-example{display:flex;align-items:center;gap:12px;border:1px solid #e3eae3;border-radius:9px;padding:12px 13px;font-size:13px;font-weight:550}.color-example .color-square{width:32px;height:32px;flex:0 0 32px}.catalog-meta-secondary{font-size:11px!important;color:#7e907e!important;margin-top:3px!important}
@media(max-width:520px){.color-kind-choices{grid-template-columns:1fr}.pattern-preview-box{flex-direction:column}}

/* v0.7: responsive color tiles, without wasting the second desktop column. */
.color-list-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px 12px;padding:12px!important}
.color-list-grid .sort-row{border:1px solid #edf1ed;background:#fff;border-radius:8px;min-height:42px;padding:7px 10px;display:flex;align-items:center;gap:9px;min-width:0}
.color-list-grid .sort-row strong{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;flex:1}
.color-list-grid .sort-row.dragging{opacity:.5;background:#eaf2e9}
.color-list-grid .color-square{flex:0 0 20px}
/* Dashboard tasks: intentionally contained so the catalog listing keeps its space. */
.task-home{display:flex;flex-direction:column;min-height:270px}
.task-home .panel-header{align-items:center;gap:10px;margin-bottom:8px}
.task-home .panel-header h3{margin:0 0 4px}
.task-home .panel-header small{font-size:11px}
.task-filterbar{display:flex;gap:5px;margin:9px 0 7px}
.task-filter{cursor:pointer;color:#738278;background:transparent;border:1px solid #e7ece6;padding:6px 10px;border-radius:8px;font-size:11px}
.task-filter.active{color:#274b34;border-color:#c7d9c9;background:#edf4ed;font-weight:700}
.task-home-scroll{max-height:386px;overflow-y:auto;scrollbar-width:thin;overscroll-behavior:contain}
.task-row{display:flex;align-items:flex-start;gap:9px;padding:11px 2px;border-bottom:1px solid #edf1ec;min-width:0}
.task-row.done strong{text-decoration:line-through;color:#98a29a}.task-row.done{opacity:.75}
.task-complete{display:flex;align-items:center;margin-top:3px;cursor:pointer}.task-complete input{width:17px;height:17px;accent-color:#355e43;cursor:pointer}
.task-main{flex:1;min-width:0}.task-main strong{display:block;font-size:12px;white-space:normal;line-height:1.4;font-weight:600}
.task-meta{display:flex;flex-wrap:wrap;gap:2px 5px;color:#849187;font-size:10px;line-height:1.6;margin-top:3px}
.task-meta .task-late{color:#bd4b45;font-weight:750}.task-meta .task-today{color:#9a622f;font-weight:700}
.task-priority{color:#a65f39;font-weight:700}.task-edit{border:0;background:transparent;color:#66786b;cursor:pointer;border-radius:7px;padding:4px 6px;min-width:22px}.task-edit:hover{background:#eaf1eb}
.task-trash{color:#b66b64}.task-empty{font-size:12px;color:#89968c;padding:22px 5px;line-height:1.5}
@media(max-width:790px){.color-list-grid{grid-template-columns:minmax(0,1fr)}.task-home-scroll{max-height:330px}}
