export type SeedPgpPlaintext = {
    v: 1;
    t: "bip39";
    w: string;
    l: "en";
    pp: 0 | 1;
    fpr?: string[];
};

export type ParsedSeedPgpFrame = {
    kind: "single";
    crc16: string;
    b45: string;
    rawPayload?: boolean;
};

// Krux KEF types
export type KruxEncryptionParams = {
    label?: string;
    iterations?: number;
    version?: number;
};

export type EncryptionMode = 'pgp' | 'krux' | 'seedqr' | 'text';

export type EncryptionParams = {
    plaintext: SeedPgpPlaintext | string;
    publicKeyArmored?: string;
    messagePassword?: string;
    mode?: EncryptionMode;
    kruxLabel?: string;
    kruxIterations?: number;
    kruxVersion?: number;
};

export type DecryptionParams = {
    frameText: string;
    privateKeyArmored?: string;
    privateKeyPassphrase?: string;
    messagePassword?: string;
    mode?: EncryptionMode;
};

export type EncryptionResult = {
    framed: string | Uint8Array;
    pgpBytes?: Uint8Array;
    kefBytes?: Uint8Array; // Added for Krux binary output
    recipientFingerprint?: string;
    label?: string;
    version?: number;
    iterations?: number;
};
