@model SchoolDto
@{
    ViewData["Title"] = Model.Name;
}

<div class="d-flex justify-content-between align-items-center mb-3">
    <h2>@Model.Name</h2>
    <div class="d-flex gap-2">
        <a asp-action="Edit" asp-route-id="@Model.SchoolId" class="btn btn-outline-primary">Edit</a>
        <a asp-controller="Student" asp-action="Index" asp-route-schoolId="@Model.SchoolId" class="btn btn-outline-secondary">Students</a>
        <a asp-action="Index" class="btn btn-secondary">Back</a>
    </div>
</div>

<partial name="_Notification" />

<div class="card shadow-sm" style="max-width: 600px;">
    <div class="card-body">
        <dl class="row mb-0">
            <dt class="col-sm-4">Short Name</dt>
            <dd class="col-sm-8">@(string.IsNullOrEmpty(Model.ShortName) ? "—" : Model.ShortName)</dd>

            <dt class="col-sm-4">Level</dt>
            <dd class="col-sm-8">@Model.SchoolLevel</dd>

            <dt class="col-sm-4">Zone</dt>
            <dd class="col-sm-8">@Model.ZoneName</dd>

            <dt class="col-sm-4">Students</dt>
            <dd class="col-sm-8">@Model.StudentCount</dd>

            <dt class="col-sm-4">Status</dt>
            <dd class="col-sm-8">
                @if (Model.IsActive)
                {
                    <span class="badge bg-success">Active</span>
                }
                else
                {
                    <span class="badge bg-secondary">Inactive</span>
                }
            </dd>
        </dl>
    </div>
</div>
