import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:flutter_svg/flutter_svg.dart';

import '../../../../core/styles/app_images.dart';
import '../widgets/bottom_version_widget.dart';

class SplashLayout extends StatelessWidget {
  const SplashLayout({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Colors.white,
      body: SizedBox(
        width: 1.sw,
        height: 1.sh,
        child: Stack(
          children: [
            Positioned.fill(
              child: SvgPicture.asset(
                AppImages.splashBg,
                width: 1.sw,
                height: 1.sh,
                fit: BoxFit.cover,
              ),
            ),
            Positioned.fill(
              child: Align(
                alignment: Alignment.center,
                child: SvgPicture.asset(
                  AppImages.splashLogo,
                ),
              ),
            ),
            const Positioned(
              bottom: 0,
              child: Align(
                alignment: Alignment.bottomCenter,
                child: BottomVersionWidget(),
              ),
            ),
          ],
        ),
      ),
    );
  }
}
