import 'package:flutter/material.dart';

import '../../../../common/theme/theme.dart';
import '../../../components/spacer/spacer.dart';
import 'profile_tile.dart';

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

  @override
  Widget build(BuildContext context) {
    return Container(
      margin: EdgeInsets.symmetric(horizontal: AppValue.margin),
      decoration: BoxDecoration(
        color: AppColor.surface,
        borderRadius: BorderRadius.circular(12),
        border: Border.all(color: AppColor.error.withOpacity(0.3)),
        boxShadow: [
          BoxShadow(
            color: Colors.black.withOpacity(0.05),
            blurRadius: 10,
            offset: const Offset(0, 2),
          ),
        ],
      ),
      child: Column(
        crossAxisAlignment: CrossAxisAlignment.start,
        children: [
          Padding(
            padding: const EdgeInsets.all(16),
            child: Row(
              children: [
                Icon(Icons.warning_outlined, color: AppColor.error, size: 20),
                const SpaceWidth(8),
                Text(
                  'Danger Zone',
                  style: AppStyle.xl.copyWith(
                    fontWeight: FontWeight.bold,
                    color: AppColor.error,
                  ),
                ),
              ],
            ),
          ),

          ProfileTile(
            icon: Icons.logout,
            title: 'Logout',
            subtitle: 'Sign out from your account',
            iconColor: AppColor.error,
            textColor: AppColor.error,
            onTap: () {},
          ),
        ],
      ),
    );
  }
}
