-- =============================================================
--  rCastbar – Localization: enUS (default)
--  All other locales override keys from this table.
-- =============================================================

-- Metatable: unknown key returns the key itself (safe fallback)
local L = setmetatable({}, { __index = function(_, k) return k end })
rCastbar_L = L

-- ── Tabs ──────────────────────────────────────────────────────
L["General"]  = "General"
L["Player"]   = "Player"
L["Target"]   = "Target"

-- ── Bottom bar ────────────────────────────────────────────────
L["Close"]     = "Close"
L["GUI Scale"] = "GUI Scale"
L["GUI_RESIZE_GRIP"] = "Drag to resize the settings window. Size is saved."

-- ── Layout ────────────────────────────────────────────────────
L["Layout"]   = "Layout"

L["Enabled"]      = "Enabled"
L["Enabled_Desc"] = "Enable / disable the castbar. Requires reload."

L["Width"]      = "Width"
L["Width_Desc"] = "Bar width in pixels."
L["Width_Fmt"]  = "%d px"

L["DynamicWidth"]      = "Adapt width to spell name"
L["DynamicWidth_Desc"] = "Automatically adjusts bar width to the spell name length. The configured width acts as minimum."

L["FontSize"]      = "Font Size"
L["FontSize_Desc"] = "Font size for spell name and time."
L["FontSize_Fmt"]  = "%d pt"

L["TimeToHold"]      = "Fail Display Duration"
L["TimeToHold_Desc"] = "Seconds to show 'Interrupted / Failed'."
L["TimeToHold_Fmt"]  = "%.1f s"

L["ShowIcon"]      = "Show Icon"
L["ShowIcon_Desc"] = "Shows the spell icon to the left of the castbar."

L["ShowLatency"]      = "Show Latency Safezone"
L["ShowLatency_Desc"] = "Shows a red zone at the bar end (network latency)."

L["ShowSpellName"]      = "Show Spell Name"
L["ShowSpellName_Desc"] = "Shows the spell name on the castbar."

L["ShowTime"]      = "Show Cast Time"
L["ShowTime_Desc"] = "Shows the remaining cast time on the castbar."

-- ── Fade ──────────────────────────────────────────────────────
L["Fade"] = "Fade"

L["FadeEnable"]      = "Enable Fade"
L["FadeEnable_Desc"] = "Smoothly fades the castbar in and out."

L["FadeIn"]      = "Fade In"
L["FadeIn_Desc"] = "Fade-in duration in seconds."

L["FadeOut"]      = "Fade Out"
L["FadeOut_Desc"] = "Fade-out duration in seconds."

L["FadeTime_Fmt"] = "%.2f s"

-- ── Successful Cast ───────────────────────────────────────────
L["SuccessSection"] = "Successful Cast"

L["CastSuccess"]      = "Show Success Flash"
L["CastSuccess_Desc"] = "Briefly flashes the castbar in success color when a cast completes."

-- ── Colors ────────────────────────────────────────────────────
L["Colors"]          = "Colors"
L["Colors_Note"]     = "Color changes take effect immediately."

L["ClassColor"]      = "Use Class Color"
L["ClassColor_Desc"] = "Colors the bar in the class color of the player / target."

L["ColorCast"]       = "Bar Color (Cast)"
L["ColorBg"]         = "Background Color"
L["ColorEmpowerTick"] = "Empower Stage Line"
L["ColorFail"]       = "Failed / Interrupted"
L["ColorSuccess"]    = "Success Color"
L["ColorShield"]     = "Shield Color (not interruptible)"
L["ColorShieldBg"]   = "Shield Background"
L["ResetColors"]     = "Reset Colors"

-- ── Position ──────────────────────────────────────────────────
L["Position"]      = "Position"
L["Position_Note"] = "Move: Shift + Left-click on the castbar to drag."

L["SnapToGrid"]      = "Snap to grid (10 px)"
L["SnapToGrid_Desc"] = "When enabled, castbar positions snap to a 10-pixel grid while dragging (Shift+drag) and when using arrow keys in Edit Mode."

L["XOffset"] = "X Offset"
L["YOffset"] = "Y Offset"

L["ReloadUI"] = "Reload UI (apply all changes)"

-- ── General Tab ───────────────────────────────────────────────
L["EditMode"]         = "Edit Mode"
L["EditMode_Note"]    = "In edit mode you can move the castbars freely. Grid, X/Y coordinates, arrow keys for fine-tuning."
L["EditMode_Enable"]  = "Enable Edit Mode"
L["EditMode_Disable"] = "Disable Edit Mode  |cff00ff00[ON]|r"

L["Reset"]      = "Reset"
L["Reset_Note"] = "Resets all rCastbar settings and reloads the UI."
L["ResetBtn"]   = "Reset Settings (Reload)"

L["Commands"] = "Commands: /rcastbar  |  /rcb"

-- ── Blizzard Panel ────────────────────────────────────────────
L["BlizzSubtitle"] = "by Imithat & selias2k"
L["BlizzDesc"]     = "Standalone Castbar Addon - Player & Target."
L["OpenSettings"]  = "Open Settings"

-- ── Minimap Tooltip ───────────────────────────────────────────
L["Tooltip_Click"] = "Click: Open / close settings"
L["Tooltip_Drag"]  = "Drag: Change position on minimap"
L["Preview"]       = "Preview"
L["ShiftDrag"]     = "SHIFT + DRAG"
L["EditModeLabel"] = "Castbar - EDIT MODE"

-- ── Minimap Toggle ────────────────────────────────────────────
L["ShowMinimapIcon"]       = "Show Minimap Icon"
L["ShowMinimapIcon_Desc"]  = "Shows or hides the rCastbar minimap button."
L["Minimap_ReloadTitle"]   = "UI Reload Required"
L["Minimap_ReloadBody"]    = "Changing the minimap icon visibility requires a UI reload to take effect."
L["Minimap_BtnReload"]     = "Reload UI"
L["Minimap_BtnCancel"]     = "Cancel"
L["FailedText"]            = "Failed"
L["InterruptedText"]       = "Interrupted"
