-- LidCouncil_Compat.lua
-- Minimal compatibility surface. Keep only live helpers that still abstract
-- real runtime behavior differences for the addon.

_G.LIDCOUNCIL_Compat = _G.LIDCOUNCIL_Compat or {}
local C = _G.LIDCOUNCIL_Compat

function C.After(delay, fn)
  if C_Timer and C_Timer.After then
    C_Timer.After(delay, fn)
    return
  end
  if not fn then return end
  local t = 0
  local f = CreateFrame("Frame")
  f:SetScript("OnUpdate", function(self, elapsed)
    t = t + elapsed
    if t >= delay then
      self:SetScript("OnUpdate", nil)
      self:Hide()
      fn()
    end
  end)
end
