import 'package:flutter/material.dart';

import 'package:pweb/utils/dimensions.dart';


class PaymentSectionCard extends StatelessWidget {
  final Widget child;
  final EdgeInsetsGeometry? padding;

  const PaymentSectionCard({
    super.key,
    required this.child,
    this.padding,
  });

  @override
  Widget build(BuildContext context) {
    final dimensions = AppDimensions();
    final theme = Theme.of(context);

    return Material(
      elevation: dimensions.elevationSmall,
      borderRadius: BorderRadius.circular(dimensions.borderRadiusMedium),
      color: theme.colorScheme.onSecondary,
      clipBehavior: Clip.antiAlias,
      child: Padding(
        padding: padding ?? EdgeInsets.all(dimensions.paddingLarge),
        child: child,
      ),
    );
  }
}
