/* ============================================
   mockup.buzz — Styles
   ============================================ */

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    user-select: none;
    -webkit-user-select: none;
}

/* ---- Wallpaper ---- */

#wallpaper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    z-index: 0;
    transform: scale(1.15);
}

#wallpaper.loaded {
    opacity: 1;
}

/* ---- Self Wallpaper ---- */

#self-wallpaper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out;
    overflow: hidden;
}

#self-wallpaper.active {
    opacity: 1;
}

#self-wallpaper-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(89px);
    transform: scale(2.5);
}

/* ---- Upload Area ---- */

#upload-area {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

#upload-area.drag-over {
    background-color: rgba(255, 255, 255, 0.15);
}

#upload-area.hidden {
    display: none;
}

.upload-content {
    text-align: center;
    color: #fff;
    pointer-events: none;
}

.upload-icon {
    margin-bottom: 20px;
    opacity: 0.9;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.upload-content h1 {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 8px;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.upload-content p {
    font-size: 16px;
    font-weight: 400;
    opacity: 0.85;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}

/* ---- 3D Scene ---- */

#scene {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    perspective: 1000px;
    z-index: 5;
    align-items: center;
    justify-content: center;
}

#scene.active {
    display: flex;
}

#mockup {
    transform-style: preserve-3d;
    will-change: transform;
    overflow: hidden;
    cursor: grab;
}

#mockup:active {
    cursor: grabbing;
}

#mockup-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
    -webkit-user-drag: none;
}

/* ---- Magic Wand Button ---- */

#magic-wand-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    background: #fff;
    border: none;
    border-radius: 50px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.2s ease;
    pointer-events: none;
}

#magic-wand-btn.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

#magic-wand-btn:hover {
    box-shadow: 0 6px 28px rgba(0, 0, 0, 0.22);
}

#magic-wand-btn:active {
    transform: scale(0.96);
}

/* ---- Modal ---- */

#modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#modal-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

#modal {
    background: linear-gradient(145deg, #1a1e2e, #141825);
    border-radius: 24px;
    width: 420px;
    max-width: calc(100vw - 32px);
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(56, 139, 255, 0.25) transparent;
    box-shadow:
        0 0 0 1px rgba(56, 139, 255, 0.15),
        0 4px 24px rgba(0, 0, 0, 0.5),
        0 0 80px -20px rgba(56, 139, 255, 0.2);
    transform: scale(0.92) translateY(12px);
    opacity: 0;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#modal-overlay.open #modal {
    transform: scale(1) translateY(0);
    opacity: 1;
}

#modal::-webkit-scrollbar {
    width: 5px;
}

#modal::-webkit-scrollbar-track {
    background: transparent;
}

#modal::-webkit-scrollbar-thumb {
    background: rgba(56, 139, 255, 0.25);
    border-radius: 3px;
}

#modal::-webkit-scrollbar-thumb:hover {
    background: rgba(56, 139, 255, 0.4);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 26px 0;
}

.modal-header h2 {
    font-size: 17px;
    font-weight: 600;
    color: #e4e8f1;
    letter-spacing: 0.01em;
}

#modal-close {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    cursor: pointer;
    padding: 6px;
    color: rgba(255, 255, 255, 0.45);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

#modal-close:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.modal-body {
    padding: 22px 26px 26px;
}

/* ---- Control Groups ---- */

.control-group {
    margin-bottom: 20px;
}

.control-group label {
    display: block;
    font-size: 12px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.slider-row {
    display: flex;
    align-items: center;
    gap: 14px;
}

.slider-value {
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    min-width: 42px;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

/* ---- Range Input Styling ---- */

input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    flex: 1;
    height: 5px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #388bff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(56, 139, 255, 0.5), 0 2px 6px rgba(0, 0, 0, 0.3);
    transition: box-shadow 0.2s ease, transform 0.15s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
    box-shadow: 0 0 16px rgba(56, 139, 255, 0.7), 0 2px 8px rgba(0, 0, 0, 0.3);
    transform: scale(1.1);
}

input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: #388bff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(56, 139, 255, 0.5), 0 2px 6px rgba(0, 0, 0, 0.3);
}

/* ---- Modal Actions ---- */

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    font-family: 'Inter', sans-serif;
    font-size: 13.5px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
}

.action-btn svg {
    stroke: rgba(255, 255, 255, 0.55);
    transition: stroke 0.2s ease;
}

.action-btn:hover {
    background-color: rgba(56, 139, 255, 0.08);
    border-color: rgba(56, 139, 255, 0.25);
    color: #fff;
}

.action-btn:hover svg {
    stroke: rgba(255, 255, 255, 0.85);
}

.action-btn:active {
    transform: scale(0.98);
}

.action-btn.primary {
    background: linear-gradient(135deg, #388bff, #2b6fcc);
    color: #fff;
    border-color: rgba(56, 139, 255, 0.4);
    box-shadow: 0 0 20px rgba(56, 139, 255, 0.25), 0 2px 8px rgba(0, 0, 0, 0.3);
}

.action-btn.primary:hover {
    background: linear-gradient(135deg, #4d9aff, #388bff);
    border-color: rgba(56, 139, 255, 0.6);
    box-shadow: 0 0 28px rgba(56, 139, 255, 0.35), 0 4px 12px rgba(0, 0, 0, 0.3);
}

.action-btn.primary svg {
    stroke: #fff;
}

/* ---- Watermark ---- */

#watermark {
    position: fixed;
    bottom: 7px;
    left: 10px;
    z-index: 8;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.64rem;
    font-weight: 400;
    color: rgba(0, 0, 0, 0.85);
    text-shadow: 0px 1px 3px rgba(0, 0, 0, 0.89);
    pointer-events: none;
    white-space: pre;
}

#watermark.light {
    color: rgba(255, 255, 255, 0.95);
    text-shadow: 0px 1px 3px rgba(255, 255, 255, 0.89);
}

#watermark:empty {
    display: none;
}

/* ---- Watermark Text Input ---- */

#watermark-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    font-family: 'DM Sans', sans-serif;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.85);
    background: rgba(255, 255, 255, 0.04);
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

#watermark-input::placeholder {
    color: rgba(255, 255, 255, 0.25);
}

#watermark-input:focus {
    border-color: rgba(56, 139, 255, 0.4);
    box-shadow: 0 0 12px rgba(56, 139, 255, 0.15);
}

/* ---- Toggle Buttons ---- */

.toggle-row {
    display: flex;
    gap: 8px;
}

.toggle-btn {
    flex: 1;
    padding: 9px 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    font-family: 'Inter', sans-serif;
    font-size: 13px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.45);
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.toggle-btn.active {
    background: linear-gradient(135deg, #388bff, #2b6fcc);
    border-color: rgba(56, 139, 255, 0.4);
    color: #fff;
    box-shadow: 0 0 14px rgba(56, 139, 255, 0.2);
}

.toggle-btn:not(.active):hover {
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.07);
    color: rgba(255, 255, 255, 0.7);
}

/* ---- Text Zone (displayed text above mockup) ---- */

#text-zone {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 25%;
    z-index: 6;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#text-zone.active,
#text-zone.has-text {
    opacity: 1;
    z-index: 50;
}

#text-zone.has-text,
#text-zone.active {
    pointer-events: auto;
}

#scene-text {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: clamp(20px, 4vw, 48px);
    font-weight: 600;
    text-align: center;
    color: #ffffff;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.25);
    padding: 0 24px;
    cursor: pointer;
    word-break: break-word;
    max-width: 80%;
    line-height: 1.3;
    transition: opacity 0.3s ease;
}

#scene-text.editing {
    opacity: 1;
    pointer-events: auto;
    cursor: text;
    caret-color: currentColor;
    outline: none;
    min-height: 1.3em;
    min-width: 2px;
    user-select: text;
    -webkit-user-select: text;
}

#scene-text.editing:empty::before {
    content: 'Type your text...';
    opacity: 0.4;
    pointer-events: none;
}

#scene-text:empty:not(.editing) {
    display: none;
}

#scene-text:not(.editing):hover {
    opacity: 0.8;
}

/* ---- Text Edit Overlay (input only, top 25%) ---- */

#text-edit-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 25%;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#text-edit-overlay.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* ---- Text Input ---- */

#text-input-wrap {
    width: 80%;
    max-width: 600px;
    display: flex;
    justify-content: center;
}

#text-input {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: clamp(20px, 4vw, 48px);
    font-weight: 600;
    text-align: center;
    color: #ffffff;
    background: none;
    border: none;
    outline: none;
    caret-color: currentColor;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.25);
    min-width: 2px;
    min-height: 1.3em;
    max-width: 100%;
    word-break: break-word;
    line-height: 1.3;
}

#text-input:empty::before {
    content: 'Type your text...';
    opacity: 0.4;
    pointer-events: none;
}

#text-input:focus {
    outline: none;
}

/* ---- Text Options Panel (bottom-docked floating tile) ---- */

#text-options-panel {
    position: fixed;
    bottom: 13px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    z-index: 50;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#text-options-panel.active {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

#text-options-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 16px 20px;
    background: rgba(30, 30, 30, 0.65);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.25);
    max-width: calc(100vw - 24px);
}

/* ---- Color Picker ---- */

#color-picker {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.color-swatch {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.2s ease,
                box-shadow 0.2s ease;
    padding: 0;
    outline: none;
}

.color-swatch:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 0.7);
}

.color-swatch.active {
    transform: scale(1.2);
    border-color: #fff;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.color-custom-wrap {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.35);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.2s ease,
                box-shadow 0.2s ease;
    cursor: pointer;
    position: relative;
    background: conic-gradient(red, yellow, lime, aqua, blue, magenta, red);
}

.color-custom-wrap:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 0.7);
}

.color-custom-wrap.active {
    transform: scale(1.2);
    border-color: #fff;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

#color-custom {
    position: absolute;
    top: -4px;
    left: -4px;
    width: 36px;
    height: 36px;
    border: none;
    padding: 0;
    cursor: pointer;
    opacity: 0;
}

/* ---- Font Picker ---- */

#font-picker {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 4px 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex-wrap: wrap;
    justify-content: center;
}

.font-option {
    padding: 5px 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
    white-space: nowrap;
}

.font-option:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.3);
}

.font-option.active {
    background: #fff;
    color: #1a1a1a;
    border-color: #fff;
    transform: scale(1.04);
}

/* ---- Text Shadow Controls ---- */

#text-shadow-controls {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    width: 100%;
}

.ts-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ts-row label {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
    min-width: 90px;
    white-space: nowrap;
}

.ts-row input[type="range"] {
    flex: 1;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
}

.ts-row input[type="range"]::-webkit-slider-thumb {
    width: 16px;
    height: 16px;
    background: #fff;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.ts-row input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: #fff;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.ts-value {
    font-family: 'Inter', sans-serif;
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    min-width: 34px;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.ts-color-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.ts-color-btn {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    cursor: pointer;
    padding: 0;
    outline: none;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.2s ease,
                box-shadow 0.2s ease;
}

.ts-color-btn:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 0.7);
}

.ts-color-btn.active {
    transform: scale(1.2);
    border-color: #fff;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

.ts-color-custom-wrap {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.35);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.2s ease,
                box-shadow 0.2s ease;
    cursor: pointer;
    position: relative;
    background: conic-gradient(red, yellow, lime, aqua, blue, magenta, red);
}

.ts-color-custom-wrap:hover {
    transform: scale(1.15);
    border-color: rgba(255, 255, 255, 0.7);
}

.ts-color-custom-wrap.active {
    transform: scale(1.2);
    border-color: #fff;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

.ts-color-custom-wrap input[type="color"] {
    position: absolute;
    top: -4px;
    left: -4px;
    width: 32px;
    height: 32px;
    border: none;
    padding: 0;
    cursor: pointer;
    opacity: 0;
}

/* ---- Confirm / Cancel Buttons ---- */

#text-edit-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding-top: 6px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 2px;
}

#text-confirm-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: #fff;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.2s ease;
}

#text-confirm-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 28px rgba(0, 0, 0, 0.22);
}

#text-confirm-btn:active {
    transform: scale(0.95);
}

#text-confirm-btn svg {
    stroke: #1a1a1a;
}

#text-cancel-btn {
    background: none;
    border: none;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 8px;
    transition: color 0.2s ease, background-color 0.2s ease;
}

#text-cancel-btn:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

/* ---- Background blur group visibility ---- */

#bg-blur-group {
    display: block;
}

/* ---- Mockup transition for text mode ---- */

#mockup {
    transition: box-shadow 0.15s ease, border-radius 0.15s ease, transform 0.45s cubic-bezier(0, 0, 0.2, 1);
}

/* ---- Drop Overlay (replace image) ---- */

#drop-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 200;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

#drop-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.drop-overlay-content {
    text-align: center;
    color: #fff;
}

.drop-overlay-content svg {
    margin-bottom: 12px;
    opacity: 0.9;
}

.drop-overlay-content p {
    font-size: 20px;
    font-weight: 600;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

/* ---- Hide Cursor for Export ---- */

body.hide-cursor,
body.hide-cursor * {
    cursor: none !important;
}

/* ---- Mobile Bottom Sheet ---- */

@media (max-width: 600px) {
    #modal-overlay {
        align-items: flex-end;
    }

    #modal {
        width: 100%;
        max-width: 100%;
        border-radius: 24px 24px 0 0;
        max-height: 85vh;
        transform: translateY(100%);
        opacity: 1;
    }

    #modal-overlay.open #modal {
        transform: translateY(0);
    }

    .upload-content h1 {
        font-size: 22px;
    }

    .upload-content p {
        font-size: 14px;
    }

    #magic-wand-btn {
        bottom: 20px;
        right: 20px;
    }

    .color-swatch {
        width: 30px;
        height: 30px;
    }

    .color-custom-wrap {
        width: 30px;
        height: 30px;
    }

    #text-confirm-btn {
        width: 48px;
        height: 48px;
    }

    #text-cancel-btn {
        font-size: 15px;
        padding: 10px 18px;
    }

    #text-options-panel {
        bottom: 8px;
    }

    #text-options-inner {
        padding: 12px 14px;
        gap: 8px;
    }

    .ts-row label {
        min-width: 76px;
        font-size: 10px;
    }

    .font-option {
        padding: 4px 9px;
        font-size: 11px;
    }
}
