"""Visual-first final shot plans where Wan carries the main image."""

from __future__ import annotations

from dataclasses import dataclass


@dataclass(frozen=True)
class VisualFirstScene:
    scene_id: str
    duration_seconds: float
    visual_prompt: str
    minimal_overlays: tuple[str, ...]
    max_overlay_labels: int = 1
    wan_visual_primary: bool = True


@dataclass(frozen=True)
class VisualFirstShotPlan:
    candidate_id: str
    scenes: tuple[VisualFirstScene, ...]
    strategy: str = "scene_based_wan_clips"


def build_visual_first_shot_plan(candidate_id: str) -> VisualFirstShotPlan:
    return VisualFirstShotPlan(
        candidate_id=candidate_id,
        scenes=(
            VisualFirstScene(
                scene_id="s01_hook_failure",
                duration_seconds=5.0,
                visual_prompt=(
                    "Modern cinematic meeting data room, floating note fragments drift toward a glossy but hollow AI summary surface. "
                    "The summary feels polished yet empty, subtle depth of field, full-bleed vertical composition, no readable text, no logos, no UI words."
                ),
                minimal_overlays=("caption", "small USELESS stamp"),
            ),
            VisualFirstScene(
                scene_id="s02_bad_output",
                duration_seconds=7.0,
                visual_prompt=(
                    "Sleek abstract AI output surface with three quiet empty slots where owner, risk and decision should be. "
                    "Polished glass material, soft red missing signals, high-end editorial tech aesthetic, no readable text."
                ),
                minimal_overlays=("caption", "one small missing label"),
            ),
            VisualFirstScene(
                scene_id="s03_mechanism",
                duration_seconds=9.0,
                visual_prompt=(
                    "Meeting-note particles are pulled evenly into a luminous compression funnel while a decision target node remains outside the funnel and unlit. "
                    "Smooth parallax, strong visual metaphor, full-bleed cinematic vertical frame, clean negative space, no readable text."
                ),
                minimal_overlays=("caption", "small no decision target arrow"),
            ),
            VisualFirstScene(
                scene_id="s04_fix",
                duration_seconds=9.0,
                visual_prompt=(
                    "A clear decision target node lights up and note particles organize into four calm flowing lanes for blockers, owners, risks and next steps. "
                    "Elegant motion, balanced composition, subtle colored trails, no readable text or UI labels baked into the video."
                ),
                minimal_overlays=("caption", "four tiny lane labels"),
            ),
            VisualFirstScene(
                scene_id="s05_takeaway",
                duration_seconds=8.0,
                visual_prompt=(
                    "Before-and-after transformation: a blurred generic summary dissolves into a clear decision path with one highlighted target node. "
                    "Calm final resolve, premium dark editorial style, full-bleed vertical video, no readable generated text."
                ),
                minimal_overlays=("caption", "final takeaway"),
            ),
        ),
    )
