.stampmaker-online-stamp-editor .smo-friendly-controls { display: grid; grid-auto-rows: max-content; align-content: start; gap: 10px; padding: 10px; }
.stampmaker-online-stamp-editor .smo-friendly-controls * { box-sizing: border-box; min-width: 0; }
.stampmaker-online-stamp-editor .smo-friendly-controls .element-state-toolbar { margin: 0; }
.stampmaker-online-stamp-editor .smo-control-section { display: grid; gap: 10px; padding: 12px; border: 1px solid #e0e7f3; border-radius: 14px; background: #fff; }
.stampmaker-online-stamp-editor .smo-control-section h3 { margin: 0; color: #243a5b; font-size: 12px; font-weight: 800; line-height: 1.3; }
.stampmaker-online-stamp-editor .smo-friendly-controls label { margin: 0; color: #566b89; font-size: 11px; font-weight: 650; }
.stampmaker-online-stamp-editor .smo-friendly-controls .control-textarea { display: grid; grid-template-columns: 1fr; gap: 0; padding: 0; border: 0; background: transparent; }
.stampmaker-online-stamp-editor .smo-friendly-controls textarea { width: 100%; min-height: 76px; max-height: 220px; margin-top: 5px; padding: 9px; resize: vertical; border: 1px solid #cedaf0; border-radius: 9px; background: #fff; color: #203758; font: 12px/1.5 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.stampmaker-online-stamp-editor .smo-friendly-controls select { width: 100%; height: auto; min-height: 37px; padding: 8px; border: 1px solid #cedaf0; border-radius: 9px; background: #fff; color: #203758; font: 12px/1.35 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; text-overflow: ellipsis; }
.stampmaker-online-stamp-editor .smo-control-font,.stampmaker-online-stamp-editor .smo-control-color { display: grid; gap: 5px; }
.stampmaker-online-stamp-editor .smo-control-type-inline { display: grid; grid-template-columns: minmax(100px,1fr) 32px 32px 36px; align-items: end; gap: 5px; }
.stampmaker-online-stamp-editor .smo-control-color-compact .smo-control-number-heading > span { display: none; }
.stampmaker-online-stamp-editor .smo-control-type-inline button.active,.stampmaker-online-stamp-editor .smo-control-quick button.active { border-color: #315efb; background: #e6edff; color: #244ee9; }
.stampmaker-online-stamp-editor .smo-control-type-inline > button { width: 32px; height: 36px; min-height: 36px; padding: 0; border-radius: 9px; font-size: 13px; }
.stampmaker-online-stamp-editor .smo-friendly-controls input[type="color"] { width: 36px; height: 36px; padding: 3px; border: 1px solid #cedaf0; border-radius: 9px; background: #fff; cursor: pointer; }
.stampmaker-online-stamp-editor .smo-control-number { display: grid; gap: 5px; }
.stampmaker-online-stamp-editor .smo-control-number-heading { display: flex; gap: 5px; align-items: center; justify-content: space-between; min-height: 22px; }
.stampmaker-online-stamp-editor .smo-control-number-heading label { overflow-wrap: anywhere; line-height: 1.25; }
.stampmaker-online-stamp-editor .smo-friendly-controls .smo-control-reset { display: inline-grid; place-items: center; flex: 0 0 24px; width: 24px; height: 22px; min-height: 22px; padding: 0; border: 0; border-radius: 6px; background: #edf2ff; color: #315efb; font-size: 17px; line-height: 1; box-shadow: none; }
.stampmaker-online-stamp-editor .smo-control-stepper { display: grid; grid-template-columns: 30px minmax(0,1fr) 30px; gap: 4px; }
.stampmaker-online-stamp-editor .smo-control-stepper > button { height: 36px; min-height: 36px; padding: 0; border: 1px solid #d6e0f4; border-radius: 8px; background: #f4f7ff; color: #315efb; font-size: 17px; line-height: 1; }
.stampmaker-online-stamp-editor .smo-control-number-field { position: relative; display: flex; align-items: center; min-height: 36px; border: 1px solid #cedaf0; border-radius: 8px; background: #fff; }
.stampmaker-online-stamp-editor .smo-control-number-field input[type="number"] { appearance: textfield; -moz-appearance: textfield; width: 100%; height: 34px; min-height: 34px; margin: 0; padding: 5px 8px; border: 0; border-radius: 8px; box-shadow: none; background: transparent; color: #203758; font: 600 12px/1.2 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.stampmaker-online-stamp-editor .smo-control-number-field:has(small) input[type="number"] { padding-inline-end: 31px; }
.stampmaker-online-stamp-editor .smo-control-number-field input::-webkit-inner-spin-button,.stampmaker-online-stamp-editor .smo-control-number-field input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.stampmaker-online-stamp-editor .smo-control-number-field small { position: absolute; inset-inline-end: 7px; color: #7386a1; font-size: 10px; pointer-events: none; }
.stampmaker-online-stamp-editor .smo-friendly-controls input[type="range"] { width: 100%; height: 17px; min-height: 17px; margin: 1px 0 0; padding: 0; accent-color: #315efb; }
.stampmaker-online-stamp-editor .smo-friendly-controls .smo-control-position { display: flex; align-items: center; justify-content: flex-start; gap: 10px; width: 100%; min-height: 63px; padding: 6px 10px; border: 1px solid #b9cafa; border-radius: 10px; background: #f4f7ff; color: #244ee9; text-align: start; }
.stampmaker-online-stamp-editor .smo-control-position-icon { flex: 0 0 45px; width: 45px; height: 45px; pointer-events: none; }
.stampmaker-online-stamp-editor .smo-control-position-icon svg { display: block; width: 45px; height: 45px; }
.stampmaker-online-stamp-editor .smo-control-position-label { font-size: 11px; font-weight: 750; line-height: 1.35; overflow-wrap: anywhere; }
.stampmaker-online-stamp-editor .smo-control-coordinates { color: #7486a1; font-size: 10px; line-height: 1.4; }
.stampmaker-online-stamp-editor .smo-friendly-controls .smo-control-fit { width: 100%; min-height: 39px; padding: 8px; border: 1px solid #315efb; border-radius: 9px; background: #315efb; color: #fff; font-size: 11px; line-height: 1.35; white-space: normal; }
.stampmaker-online-stamp-editor .smo-control-quick { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 6px; }
.stampmaker-online-stamp-editor .smo-control-quick button { width: 100%; min-height: 33px; padding: 6px; border: 1px solid #d6e0f4; border-radius: 8px; font-size: 10px; line-height: 1.3; white-space: normal; }
.stampmaker-online-stamp-editor .smo-friendly-controls .smo-control-action { display: flex; align-items: center; justify-content: center; gap: 6px; }
.stampmaker-online-stamp-editor .smo-control-action-icon { display: inline-flex; flex: 0 0 16px; width: 16px; height: 16px; pointer-events: none; }
.stampmaker-online-stamp-editor .smo-control-action-icon svg { display: block; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.stampmaker-online-stamp-editor .smo-control-action-label { min-width: 0; word-break: normal; overflow-wrap: normal; hyphens: none; }
.stampmaker-online-stamp-editor .smo-controls-more { overflow: visible; border: 1px solid #dce5f4; border-radius: 13px; background: #f8faff; }
.stampmaker-online-stamp-editor .smo-controls-more > h3 { color: #526b94; font-size: 12px; font-weight: 750; }
.stampmaker-online-stamp-editor .smo-controls-more-body { display: grid; gap: 14px; }
.stampmaker-online-stamp-editor .smo-controls-more-body > small { color: #7d8da5; font-size: 10px; line-height: 1.4; }
.stampmaker-online-stamp-editor .smo-controls-more-body .control-select { display: grid; gap: 5px; padding: 0; border: 0; background: transparent; }
.stampmaker-online-stamp-editor .smo-control-image-preview { justify-self: center; max-width: 85px; height: 70px; object-fit: contain; }
.stampmaker-online-stamp-editor .smo-friendly-controls .control-file { display: grid; gap: 5px; padding: 0; border: 0; }
.stampmaker-online-stamp-editor .smo-friendly-controls input[type="file"] { width: 100%; padding: 5px; font-size: 10px; }
.stampmaker-online-stamp-editor .smo-friendly-controls button:disabled { cursor: not-allowed; opacity: .4; }
.stampmaker-online-stamp-editor .smo-friendly-controls button:focus-visible { outline: 2px solid #86a7ff; outline-offset: 2px; }
@media(pointer:coarse) {
    .stampmaker-online-stamp-editor .smo-control-stepper > button,.stampmaker-online-stamp-editor .smo-control-number-field { min-height: 42px; }
    .stampmaker-online-stamp-editor .smo-control-number-field input[type="number"] { height: 40px; }
}
/* Keep full-height blocks inside one mobile scrollport, rather than shrinking and clipping More settings. */
@media(max-width:1000px) {
    .stampmaker-online-stamp-editor #editor-page { --mobile-control-panel-height: min(400px, calc(100vh - 24px)); }
    .stampmaker-online-stamp-editor #editor-page #element-controls {
        min-height: 0; height: 100%; max-height: 100%;
        grid-template-rows: none; grid-auto-rows: max-content; align-content: start;
        overflow-y: auto; overflow-x: hidden; overscroll-behavior-y: contain;
        -webkit-overflow-scrolling: touch; touch-action: auto;
        padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px)); scroll-padding-bottom: 24px;
    }
    @supports(height:100dvh) {
        .stampmaker-online-stamp-editor #editor-page { --mobile-control-panel-height: min(400px, calc(100dvh - 24px)); }
    }
}
