/*
 * File: D:\shadowed-realms-mobile\ShadowedRealmsMobile\src\server\ShadowedRealms.Shared\DTOs\Alliance\CoalitionDissolutionRequestDto.cs
 * Created: 2025-10-22
 * Last Modified: 2025-10-22
 * Description: Request DTO for coalition dissolution operations
 * Last Edit Notes: Initial implementation for coalition termination input validation
 */

using System.ComponentModel.DataAnnotations;

namespace ShadowedRealms.Shared.DTOs.Alliance
{
    /// <summary>
    /// Request DTO for coalition dissolution operations
    /// </summary>
    public class CoalitionDissolutionRequestDto
    {
        /// <summary>
        /// Reason for dissolving the coalition
        /// </summary>
        [Required]
        [StringLength(300)]
        public string DissolutionReason { get; set; } = string.Empty;

        /// <summary>
        /// Resource distribution plan for member alliances
        /// </summary>
        public Dictionary<string, object>? ResourceDistribution { get; set; }

        /// <summary>
        /// Whether to notify all members before dissolution
        /// </summary>
        public bool NotifyMembers { get; set; } = true;

        /// <summary>
        /// Grace period before dissolution takes effect (hours)
        /// </summary>
        [Range(0, 168)] // 0 to 7 days
        public int GracePeriodHours { get; set; } = 24;

        /// <summary>
        /// Final message to coalition members
        /// </summary>
        [StringLength(500)]
        public string? FinalMessage { get; set; }

        /// <summary>
        /// Whether to preserve coalition statistics for historical records
        /// </summary>
        public bool PreserveStatistics { get; set; } = true;

        /// <summary>
        /// Emergency dissolution (immediate, bypasses grace period)
        /// </summary>
        public bool EmergencyDissolution { get; set; } = false;

        /// <summary>
        /// Confirmation that the requesting player understands the consequences
        /// </summary>
        [Required]
        public bool ConfirmDissolution { get; set; }

        /// <summary>
        /// Additional dissolution parameters
        /// </summary>
        public Dictionary<string, object>? DissolutionParameters { get; set; }
    }
}