[content] src/recording.ts (typescript)
        panicStatusBarItem.hide()
        return
    }

    const secondsToRemove = (panicButtonPressCount + 1) * 10 // Show what the next press will remove
    panicStatusBarItem.text = '$(refresh)'
    panicStatusBarItem.tooltip = `Remove last ${secondsToRemove} seconds of recording (click again within 3 seconds to remove more)`
    panicStatusBarItem.command = commands.panicButton
    panicStatusBarItem.show()
}

/**
 * Deletes the last N seconds of recording data from the CSV file.
 * This is a "panic button" feature that allows users to quickly remove recent sensitive data.
 * Each successive press within 3 seconds removes more time: 10s, 20s, 30s, etc.
 * After 3 seconds of inactivity, the next press will be treated as a fresh press (10s).
 */
export async function panicButton(): Promise<void> {
    if (!recording.isRecording) {
        vscode.window.showWarningMessage('No active recording to remove data from')
        logToOutput('No active recording to remove data from', 'info')
        return
    }

    if (!recording.startDateTime) {
        vscode.window.showErrorMessage('Recording start time not available')
        logToOutput('Recording start time not available', 'error')
        return
    }

    const exportPath = getExportPath()
    if (!exportPath) {
        vscode.window.showErrorMessage('Export path not available')
        logToOutput('Export path not available', 'error')
        return
    }

    const baseFilePath = generateBaseFilePath(recording.startDateTime, false, recording.customFolderName, sessionUuid)
    if (!baseFilePath) {
        vscode.window.showErrorMessage('Could not generate file path')
        logToOutput('Could not generate file path', 'error')
        return
    }

    const filePath = path.join(exportPath, `${baseFilePath}.csv`)

    try {
        // Check if file exists
        if (!fs.existsSync(filePath)) {
            vscode.window.showWarningMessage('No recording file found to remove data from')
            logToOutput('No recording file found to remove data from', 'info')
            return
        }

        // Read the file
        const content = fs.readFileSync(filePath, 'utf-8')
        const lines = content.split('
')
        
        if (lines.length <= 1) {
            vscode.window.showWarningMessage('Recording file is empty, nothing to remove')
            logToOutput('Recording file is empty, nothing to remove', 'info')
            return
        }

        // Calculate how many lines to remove (10 seconds per press, roughly 1 line per second)
        const linesToRemove = Math.min((panicButtonPressCount + 1) * 10, lines.length - 1)
        const newLines = lines.slice(0, lines.length - linesToRemove)

        // Write back to file
        fs.writeFileSync(filePath, newLines.join('
'))

        // Update panic button state
        panicButtonPressCount++
        updatePanicButton()

        const secondsToRemove = panicButtonPressCount * 10
        vscode.window.showInformationMessage(`Successfully removed last ${secondsToRemove} seconds of recording`)
        logToOutput(`Successfully removed last ${secondsToRemove} seconds of recording`, 'info')

    } catch (error) {
        const errorMessage = `Error during panic button operation: ${error}`