.crop-url-hidden,
[data-field][class*="crop-url-hidden"],
.w-field.crop-url-hidden,
[data-contentpath="crop_url"] {
    display: none !important;
}

.sf-crop-editor {
    margin: 0.5rem 0 1rem 0;
    border: 1px solid var(--w-color-border-furniture, #e0e0e0);
    border-radius: 8px;
    background: var(--w-color-surface-page, #f6f6f8);
    overflow: hidden;
}

.sf-crop-header {
    padding: 0;
}

.sf-crop-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.6rem 1rem;
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--w-color-text-context, #333);
    text-align: left;
    transition: background 0.15s;
}

.sf-crop-toggle:hover {
    background: var(--w-color-surface-menus, #eee);
}

.sf-crop-toggle-icon {
    font-size: 0.7rem;
    color: var(--w-color-text-meta, #888);
    width: 1rem;
    text-align: center;
}

.sf-crop-toggle-label {
    font-weight: 600;
}

.sf-crop-preview-text {
    color: var(--w-color-primary, #007d7e);
    font-size: 0.8rem;
}

.sf-crop-body {
    padding: 1rem;
    border-top: 1px solid var(--w-color-border-furniture, #e0e0e0);
}

.sf-crop-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.sf-crop-dimensions {
    font-size: 0.75rem;
    color: var(--w-color-text-meta, #888);
    font-family: monospace;
}

.sf-crop-reset {
    padding: 0.3rem 0.6rem;
    border: 1px solid var(--w-color-border-furniture, #ddd);
    background: var(--w-color-surface-header, #fff);
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.75rem;
    color: var(--w-color-text-meta, #666);
    min-height: 32px;
}

.sf-crop-reset:hover {
    background: var(--w-color-surface-menus, #e8e8e8);
}

.sf-crop-viewport {
    position: relative;
    overflow: hidden;
    background: #000;
    border-radius: 4px;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
    max-width: 100%;
}

.sf-crop-viewport:active {
    cursor: grabbing;
}

.sf-crop-image {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

.sf-crop-no-image {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.5);
    font-size: 0.8rem;
    text-align: center;
    padding: 1rem;
}

.sf-crop-controls {
    display: flex;
    gap: 1.25rem;
    margin-top: 0.6rem;
    flex-wrap: wrap;
    align-items: center;
}

.sf-crop-zoom-group {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.sf-crop-zoom-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--w-color-text-meta, #666);
    min-width: 3rem;
}

.sf-crop-btn {
    width: 32px;
    height: 32px;
    border: 1px solid var(--w-color-border-furniture, #ddd);
    background: var(--w-color-surface-header, #fff);
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    color: var(--w-color-text-context, #333);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    user-select: none;
}

.sf-crop-btn:hover {
    background: var(--w-color-surface-menus, #e8e8e8);
    border-color: var(--w-color-primary, #007d7e);
    color: var(--w-color-primary, #007d7e);
}

.sf-crop-btn:active {
    transform: scale(0.92);
}

.sf-crop-x-value,
.sf-crop-y-value {
    font-family: monospace;
    font-size: 0.75rem;
    min-width: 2.5rem;
    text-align: center;
    color: var(--w-color-text-context, #333);
}

@media (max-width: 768px) {
    .sf-crop-controls {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .sf-crop-btn {
        width: 40px;
        height: 40px;
    }
}
