// Layout tokens used across the installer screens.
//
// Sizes/spacings come from the figma export — keeping them in one
// module makes future visual tweaks (and per-form-factor overrides)
// easy. Colour tokens themselves still come from the active ltk theme
// (`ltk::theme_palette()`); these constants are pure geometry.

// ── Spacing ──────────────────────────────────────────────────────────────────

pub const PAGE_PADDING_H:   f32 = 24.0;
pub const SECTION_SPACING:  f32 = 24.0;
pub const TIGHT_SPACING:    f32 = 8.0;
pub const ITEM_SPACING:     f32 = 16.0;

// ── Type ─────────────────────────────────────────────────────────────────────

pub const TITLE_SIZE:    f32 = 26.0;
pub const SUBTITLE_SIZE: f32 = 14.0;
pub const BODY_SIZE:     f32 = 15.0;
pub const SMALL_SIZE:    f32 = 12.0;

// ── Surfaces ─────────────────────────────────────────────────────────────────

pub const CARD_RADIUS:   f32 = 16.0;
pub const PILL_RADIUS:   f32 = 28.0;

// ── Controls ─────────────────────────────────────────────────────────────────

// Shared height for buttons, toggles, radios and single-line text fields,
// replacing ltk's stock fluid 48 px (which grows to 72 px on large surfaces).
pub fn control_height() -> ltk::Length
{
	ltk::Length::vh( 5.0 ).clamp( 24.0, 40.0 )
}

// Button-label and text-field font size paired with `control_height`,
// replacing ltk's stock fluid 16 px (which grows to 24 px on large surfaces).
pub fn control_font_size() -> ltk::Length
{
	ltk::Length::vh( 2.0 ).clamp( 12.0, 14.0 )
}

// ── Indicator ────────────────────────────────────────────────────────────────

pub const DOT_SIZE:    f32 = 6.0;
pub const DOT_ACTIVE:  f32 = 18.0; // pill width for the active step
pub const DOT_SPACING: f32 = 6.0;
