import 'package:flutter/material.dart';

class CustomAppBar extends StatefulWidget implements PreferredSizeWidget {
  const CustomAppBar({super.key, required this.title, this.actions});

  @override
  State<CustomAppBar> createState() => _CustomAppBarState();

  @override
  Size get preferredSize => const Size.fromHeight(100);

  final String title;
  final List<Widget>? actions;
}

class _CustomAppBarState extends State<CustomAppBar> {
  @override
  Widget build(BuildContext context) {
    return AppBar(
      elevation: 0.0,
      toolbarHeight: 100,
      backgroundColor: Colors.white,
      foregroundColor: Colors.black,
      title: Padding(
        padding: const EdgeInsets.only(top: 50.0),
        child: Text(
          widget.title,
          style: const TextStyle(
            fontFamily: 'Product Sans',
            fontWeight: FontWeight.w900,
            fontSize: 46.0,
            color: Color(0xFF323438),
          ),
        ),
      ),
      actions: widget.actions,
    );
  }
}
