/* Final interaction layer for the product editor. */
.attribute-multi-select.is-open .attribute-multi-select-trigger > i { transform: rotate(180deg); }
.attribute-multi-select-options { max-height: 196px !important; padding: 3px !important; }
.attribute-multi-select-options label { min-height: 34px !important; padding: 4px 8px !important; gap: 8px !important; font-size: 14px !important; line-height: 1.25 !important; }
.attribute-multi-select-options input[type="checkbox"] { appearance: auto !important; flex: 0 0 15px !important; width: 15px !important; height: 15px !important; min-width: 15px !important; min-height: 15px !important; margin: 0 !important; padding: 0 !important; }
.attribute-multi-select-search { padding: 7px 9px !important; }
.attribute-multi-select-panel { max-width: 360px; overflow: hidden !important; }
.attribute-form-group:has(.attribute-multi-select.is-open) { position: relative; z-index: 40; overflow: visible !important; }
.attribute-form-group:has(.attribute-multi-select.is-open) .attribute-fields-grid { overflow: visible !important; }

/* Unified multi-select behaviour: position the menu from its trigger, not the stretched grid row. */
.attribute-multi-select { align-self: start; min-height: 0; }
.attribute-multi-select-panel { top: calc(100% + 4px); display: none; grid-template-rows: auto minmax(0, 1fr) auto; width: min(360px, 100%); max-width: 100% !important; }
.attribute-multi-select.is-open .attribute-multi-select-panel { display: grid; }
.attribute-multi-select-option:focus-visible { outline: 2px solid #167055; outline-offset: -2px; }
.attribute-multi-select-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; border-top: 1px solid #e2e9e5; color: #65776f; font-size: 12px; }
.attribute-multi-select-actions button { min-height: 30px; padding: 4px 11px; border: 1px solid #167055; border-radius: 5px; background: #167055; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.attribute-multi-select-actions button:hover { background: #0f6249; }

/* Never show a browser-generated disclosure icon beside the intended one. */
.advanced-product-section > summary { display: grid !important; grid-template-columns: minmax(0, 1fr) auto !important; list-style: none !important; }
.advanced-product-section > summary::marker { display: none !important; content: "" !important; }
.advanced-product-section > summary::-webkit-details-marker { display: none !important; }
.advanced-product-section > summary > i { justify-self: end; }
.rich-upload-queue{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0}.rich-upload-queue span{display:inline-flex;align-items:center;gap:5px;padding:4px 7px;border:1px solid #d6e2dc;border-radius:5px;background:#f5f9f7;color:#45665a;font-size:12px}.rich-upload-queue button{border:0;background:transparent;padding:0;color:#5e786d;cursor:pointer}
.tiptap-image-resize-handle{box-sizing:border-box!important;display:block!important;min-width:15px!important;min-height:15px!important;width:15px!important;height:15px!important;padding:0!important;margin:0!important;line-height:0!important;aspect-ratio:1/1!important;border-radius:50%!important;flex:none!important}

.product-create-dialog .product-form-section{padding:14px 0}.product-create-dialog .product-form-section-heading{margin-bottom:10px}.product-create-dialog .field-row{margin:0}.product-create-dialog .product-form-section>:is(.settings-grid,.product-identity-form-grid,.measurement-fields,.packaging-level-grid,.attribute-form-groups){width:calc(100% - 36px);margin-left:36px}.product-create-dialog :is(.settings-grid,.product-identity-form-grid,.measurement-fields,.packaging-fields,.attribute-fields-grid,.reference-product-controls){grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.product-creation-methods{display:flex;gap:8px;margin-left:36px}.product-creation-choice{position:relative;display:block;flex:0 0 260px;width:260px;cursor:pointer}.product-creation-choice>input{position:absolute;opacity:0;pointer-events:none}.product-creation-choice>span{display:grid;width:100%;grid-template-columns:22px minmax(0,1fr);align-items:center;gap:8px;min-height:50px;padding:9px 12px;border:1px solid #d7e1dc;border-radius:7px;background:#fff;transition:border-color .15s,background .15s}.product-creation-choice i{color:#557168;font-size:17px}.product-creation-choice strong{color:#1f2d29;font-size:13px}.product-creation-choice>input:checked+span{border-color:#16805f;background:#f2faf6;box-shadow:inset 3px 0 #16805f}.product-creation-choice>input:focus-visible+span{outline:2px solid #16805f;outline-offset:2px}.reference-product-picker{display:grid;width:calc(100% - 36px);gap:7px;margin:10px 0 0 36px;padding:0;border:0;background:transparent}.reference-product-picker-heading{display:flex;align-items:center}.reference-product-picker-heading label{font-size:12px;font-weight:700}.reference-product-search{position:relative}.reference-product-search i{position:absolute;left:11px;top:50%;transform:translateY(-50%);color:#71817a}.reference-product-search input{width:100%;padding-left:34px}.reference-product-status{margin:0;color:#64756e;font-size:11px}.reference-product-status:empty{display:none}.reference-product-status:not(:empty){color:#176b50;font-weight:650}.product-create-dialog .product-identity-form-grid>.settings-grid{display:contents}.product-create-dialog .product-identity-form-grid>.image-source-picker{min-width:0}.product-create-dialog .measurement-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.product-specification-notes{margin:0}.product-specification-notes textarea{min-height:84px}.product-create-dialog .packaging-level-grid{grid-template-columns:1fr}.product-create-dialog .attribute-fields-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.product-create-dialog .field-span-2{grid-column:1/-1}.product-code-change{display:grid;width:calc(100% - 36px);grid-template-columns:18px minmax(0,1fr);align-items:start;gap:9px;margin:10px 0 0 36px;padding:10px 12px;border:1px solid #dfc98f;border-radius:7px;background:#fffaf0;color:#4b3b17}.product-code-change[hidden]{display:none}.product-code-change>i{margin-top:2px;color:#9b6d08}.product-code-change strong{font-size:12px}.product-code-change p{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:3px 0 1px;font-size:12px;font-weight:700}.product-code-change p>i{color:#8a7b58;font-size:11px}.product-code-change small{color:#74633c;font-size:11px}
@media(max-width:820px){.product-create-dialog .product-form-section>:is(.settings-grid,.product-identity-form-grid,.measurement-fields,.packaging-level-grid,.attribute-form-groups),.reference-product-picker,.product-code-change{width:100%;margin-left:0}.product-create-dialog :is(.settings-grid,.product-identity-form-grid,.measurement-fields,.packaging-fields,.attribute-fields-grid,.reference-product-controls){grid-template-columns:1fr}.product-creation-methods{flex-direction:column;margin-left:0}.product-creation-choice{flex-basis:auto;width:100%}}

/* Reference-product flow: show the picker only after its creation method is chosen. */
.reference-product-picker[hidden]{display:none!important}
.reference-product-picker{gap:13px;margin-top:13px;padding:14px 15px;border:1px solid #cde0d7;border-radius:8px;background:#f7fbf9}
.reference-product-picker-heading{align-items:flex-start;gap:10px}
.reference-product-step,.reference-product-control-step{display:grid;place-items:center;border-radius:50%;color:#176b50;background:#dceee6;font-weight:800}
.reference-product-step{width:24px;height:24px;flex:0 0 24px;font-size:11px}
.reference-product-picker-heading h4{margin:0;color:#1f2d29;font-size:13px}
.reference-product-picker-heading p{margin:3px 0 0;color:#66776f;font-size:11px;line-height:1.45}
.reference-product-controls{display:grid;grid-template-columns:minmax(0,.9fr) minmax(280px,1.25fr);gap:10px;align-items:start}
.reference-product-control{display:grid;grid-template-rows:18px 42px;gap:6px;min-width:0}
.reference-product-control>label{display:flex;height:18px;align-items:center;gap:6px;color:#40524a;font-size:11px;font-weight:750;line-height:18px}
.reference-product-control>label>span:last-child{display:flex;align-items:baseline;gap:4px;min-width:0}
.reference-product-control>label small{margin:0;color:#829089;font-size:10px;font-weight:500;line-height:1}
.reference-product-control-step{width:17px;height:17px;flex:0 0 17px;color:#fff;background:#638278;font-size:9px}
.reference-product-input-shell{position:relative;width:100%;height:42px;min-width:0}
.reference-product-input-shell i{position:absolute;inset:0 auto 0 0;z-index:1;display:grid;width:42px;height:42px;place-items:center;color:#71817a;font-size:15px;line-height:1;transform:none;pointer-events:none}
.reference-product-control :is(input,select){display:block;width:100%;height:42px;min-height:42px;margin:0;box-sizing:border-box;border:1px solid #bfcfc7;border-radius:6px;color:#1d2d26;background:#fff;font:inherit;line-height:normal}
.reference-product-search input{padding:0 12px 0 42px}
.reference-product-select select{padding-block:0}
.reference-product-control :is(input,select):focus{border-color:#5d9a83;box-shadow:0 0 0 3px rgba(18,99,75,.09);outline:0}
@media(max-width:820px){.reference-product-picker{width:100%;margin-left:0}.reference-product-controls{grid-template-columns:1fr}}
.product-create-dialog .packaging-level-grid{gap:20px}.product-create-dialog .packaging-level{border:0;background:transparent;overflow:visible}.product-create-dialog .packaging-level-heading{padding:0 0 8px;border-bottom:1px solid #d7e1dc;background:transparent}.product-create-dialog .packaging-fields{padding:10px 0 0}.product-create-dialog .attribute-form-group{border:0;background:transparent;overflow:visible}.product-create-dialog .attribute-form-group>summary{padding:0 0 8px;border-bottom:1px solid #d7e1dc;background:transparent}.product-create-dialog .attribute-form-group[open]>summary{border-bottom-color:#d7e1dc}.product-create-dialog .attribute-form-group>.settings-grid{padding:10px 0 0}
