#designer-app .cig-mug-tools {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    flex: none;
    gap: 8px 18px;
    padding: 8px 12px;
    background: var(--vs-surface, white);
    color: var(--vs-ink, #172739);
    border-bottom: 1px solid var(--vs-line, #d6dbe2);
    font: 500 14px/1.35 system-ui, sans-serif;
}

.cig-mug-photos, .cig-mug-font, .cig-mug-zoom {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

#designer-app .cig-mug-upload {
    min-height: 40px;
    padding: 6px 12px;
    border: 0;
    border-radius: 8px;
    color: #fff;
    background: #0965bd;
    font: inherit;
    font-weight: 650;
    cursor: pointer;
}

.cig-mug-photo-status { color: var(--vs-ink-2, #526174); }
.cig-mug-files[hidden] { display: none !important; }
.cig-mug-studio [data-item-id^="cig-mug-"] { cursor: pointer; }
.cig-mug-studio [data-cig-photo-label]::after {
    content: attr(data-cig-photo-label);
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: rgb(241 245 249 / 75%);
    color: #23364e;
    outline: 1px dashed #7e91a6;
    font: 650 14px/1 system-ui, sans-serif;
    pointer-events: none;
}
.cig-mug-studio:not(.cig-mug-has-message) [data-item-id="cig-mug-message"]::after {
    content: "Your text here";
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #556777;
    font: 500 22px/1 system-ui, sans-serif;
    pointer-events: none;
}

@media (max-width: 640px) {
    #designer-app .cig-mug-tools { gap: 6px 10px; padding: 6px 8px; }
}

#designer-app .cig-mug-edit-message,
#designer-app .cig-mug-dialog button {
    min-height: 40px;
    padding: 6px 12px;
    border: 1px solid var(--vs-line, #cbd5e1);
    border-radius: 8px;
    background: var(--vs-surface, white);
    color: inherit;
    font: inherit;
    font-weight: 650;
    cursor: pointer;
}

#designer-app .cig-mug-dialog {
    position: fixed;
    margin: auto;
    inset: 0;
    width: min(480px, calc(100vw - 24px));
    max-height: calc(100dvh - 24px);
    padding: 18px;
    border: 1px solid var(--vs-line, #cbd5e1);
    border-radius: 14px;
    background: var(--vs-surface, white);
    color: var(--vs-ink, #172739);
    font: 500 14px/1.35 system-ui, sans-serif;
}

.cig-mug-dialog::backdrop { background: rgb(15 23 42 / 60%); }
.cig-mug-dialog h2 { margin: 0 0 10px; font-size: 19px; font-weight: 700; }
.cig-mug-dialog p { margin: 8px 0; }
.cig-mug-dialog .cig-mug-apply { background: #184a82 !important; color: white !important; }
.cig-mug-dialog .cig-mug-apply:disabled { opacity: .5; cursor: default !important; }
.cig-mug-dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.cig-mug-zoom { width: 100%; gap: 12px; margin-top: 10px; }
.cig-mug-zoom input { flex: 1; }
.cig-mug-crop-frame, .cig-mug-text-preview {
    display: block;
    position: relative;
    width: 100%;
    margin-inline: auto;
    overflow: hidden;
    outline: 1px solid var(--vs-line, #77889b);
    background: #fff;
    touch-action: none;
    cursor: grab;
}
.cig-mug-crop-frame:focus-visible, .cig-mug-text-preview:focus-visible { outline: 2px solid #184a82; }
.cig-mug-crop-frame:active, .cig-mug-text-preview:active { cursor: grabbing; }
.cig-mug-crop-frame img {
    position: absolute;
    display: block;
    max-width: none !important;
    object-fit: fill;
    pointer-events: none;
    user-select: none;
}
.cig-photo-square-bleed [data-item-id^="cig-mug-photo_"] {
    clip-path: inset(var(--cig-safe-inset));
}
.cig-photo-safe-square::after, .cig-photo-safe-circle::after {
    content: "";
    position: absolute;
    inset: var(--cig-safe-inset);
    border: 2px dashed white;
    box-shadow: 0 0 0 1px #283b50;
    pointer-events: none;
}
.cig-photo-safe-circle::after { border-radius: 50%; }
.cig-slate-full-face .design-area > .content-inner {
    clip-path: var(--cig-slate-face-outline);
    box-shadow: none !important;
}
.cig-slate-bleed-crop::before {
    content: "";
    position: absolute;
    inset: var(--cig-trim-inset);
    border: 1px solid white;
    box-shadow: 0 0 0 1px #283b50;
    pointer-events: none;
    z-index: 1;
}
.cig-slate-bleed-crop::after { z-index: 1; }
.cig-mug-message-field textarea, .cig-mug-font select {
    padding: 7px 9px;
    border: 1px solid var(--vs-line, #a6afbb);
    border-radius: 7px;
    background: var(--vs-surface, white);
    color: inherit;
    font: inherit;
}
.cig-mug-message-field textarea { display: block; width: 100%; margin: 4px 0 8px; resize: vertical; }
.cig-mug-text-error { color: #a32727; }

#designer-app .cig-wrap-position-note {
    flex: none;
    margin: 0;
    padding: 8px 12px;
    background: var(--vs-surface, white);
    color: var(--vs-ink, #23364e);
    border-bottom: 1px solid var(--vs-line, #d6dbe2);
    text-align: center;
    font: 500 13px/1.35 system-ui, sans-serif;
}

@media (min-width: 641px) {
    #designer-app .cig-wrap-position-note {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        overflow: hidden;
        clip-path: inset(50%);
        white-space: nowrap;
    }
}
