@inherits LayoutComponentBase
@implements IDisposable
@inject WebClientTpos.Client.Services.ThemeStateService ThemeState

@* EN: Theme providers moved to App.razor (FRONT-W-06) — light mode (IsDarkMode=false) set via ThemeStateService. *@
@* VI: Theme providers đã chuyển về App.razor (FRONT-W-06) — light mode (IsDarkMode=false) đặt qua ThemeStateService. *@

<div style="min-height:100vh;background:#F9FAFB;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;">
    @Body
</div>

@code {
    protected override void OnInitialized()
    {
        // EN: Switch to light mode for customer-facing pages (FRONT-W-06).
        // VI: Chuyển sang light mode cho trang khách hàng (FRONT-W-06).
        ThemeState.SetTheme(AppTheme.DefaultDark, isDarkMode: false);
    }

    public void Dispose()
    {
        // EN: Restore dark mode when leaving customer layout (FRONT-W-06).
        // VI: Khôi phục dark mode khi rời layout khách hàng (FRONT-W-06).
        ThemeState.RestoreDefault();
    }
}
