{
  "entityType": "leave",
  "title": "Leave Application",
  "columns": 12,
  "styles": {
    "containerClass": "entity-container entity-p-4",
    "titleClass": "entity-title entity-text-primary entity-mb-4",
    "sectionClass": "entity-section entity-card entity-mb-4",
    "rowClass": "entity-row entity-gap-3",
    "fieldClass": "field-container"
  },
  "sections": [
    {
      "id": "employeeInfo",
      "title": "Employee Information",
      "columns": 6,
      "styles": {
        "containerClass": "entity-section entity-card",
        "titleClass": "entity-section-title"
      },
      "rows": [
        {
          "fields": [
            {
              "id": "employeeName",
              "label": "Employee Name",
              "dataKey": "employeeName",
              "type": "text",
              "span": 12,
              "styles": {
                "valueClass": "entity-fs-5 entity-fw-bold",
                "containerClass": "field-container entity-mb-3"
              }
            }
          ]
        },
        {
          "fields": [
            {
              "id": "department",
              "label": "Department",
              "dataKey": "department",
              "type": "text",
              "span": 6
            },
            {
              "id": "position",
              "label": "Position",
              "dataKey": "position",
              "type": "text",
              "span": 6
            }
          ]
        }
      ]
    },
    {
      "id": "leaveDetails",
      "title": "Leave Details",
      "columns": 6,
      "styles": {
        "containerClass": "entity-section entity-card",
        "titleClass": "entity-section-title"
      },
      "rows": [
        {
          "fields": [
            {
              "id": "status",
              "label": "Status",
              "dataKey": "status",
              "type": "badge",
              "span": 12,
              "badgeMap": {
                "approved": {
                  "class": "field-badge status-approved",
                  "text": "Approved"
                },
                "pending": {
                  "class": "field-badge status-pending",
                  "text": "Pending"
                },
                "rejected": {
                  "class": "field-badge status-rejected",
                  "text": "Rejected"
                },
                "cancelled": {
                  "class": "field-badge badge-secondary",
                  "text": "Cancelled"
                }
              }
            }
          ]
        },
        {
          "fields": [
            {
              "id": "leaveType",
              "label": "Leave Type",
              "dataKey": "leaveType",
              "type": "text",
              "span": 4,
              "styles": {
                "valueClass": "entity-text-capitalize"
              }
            },
            {
              "id": "duration",
              "label": "Duration (Days)",
              "dataKey": "duration",
              "type": "number",
              "span": 4,
              "styles": {
                "valueClass": "entity-fw-bold"
              }
            },
            {
              "id": "balance",
              "label": "Remaining Balance",
              "dataKey": "balance.annualLeave",
              "type": "number",
              "span": 4
            }
          ]
        }
      ]
    },
    {
      "id": "dates",
      "title": "Leave Period",
      "columns": 12,
      "styles": {
        "containerClass": "entity-section entity-card",
        "titleClass": "entity-section-title"
      },
      "rows": [
        {
          "fields": [
            {
              "id": "startDate",
              "label": "Start Date",
              "dataKey": "startDate",
              "type": "date",
              "span": 4,
              "styles": {
                "valueClass": "entity-fw-bold"
              }
            },
            {
              "id": "endDate",
              "label": "End Date",
              "dataKey": "endDate",
              "type": "date",
              "span": 4,
              "styles": {
                "valueClass": "entity-fw-bold"
              }
            },
            {
              "id": "submittedDate",
              "label": "Submitted On",
              "dataKey": "submittedDate",
              "type": "datetime",
              "span": 4
            }
          ]
        }
      ]
    },
    {
      "id": "reason",
      "title": "Reason for Leave",
      "columns": 12,
      "styles": {
        "containerClass": "entity-section entity-card",
        "titleClass": "entity-section-title"
      },
      "rows": [
        {
          "fields": [
            {
              "id": "reason",
              "label": "",
              "dataKey": "reason",
              "type": "textarea",
              "span": 12,
              "styles": {
                "containerClass": "field-container entity-bg-light entity-p-3 entity-rounded",
                "valueClass": "entity-mb-0"
              }
            }
          ]
        }
      ]
    },
    {
      "id": "approval",
      "title": "Approval Details",
      "columns": 12,
      "styles": {
        "containerClass": "entity-section entity-card entity-bg-success entity-bg-opacity-10",
        "titleClass": "entity-section-title"
      },
      "rows": [
        {
          "fields": [
            {
              "id": "approvedBy",
              "label": "Approved By",
              "dataKey": "approvedBy",
              "type": "text",
              "span": 6
            },
            {
              "id": "approvalDate",
              "label": "Approval Date",
              "dataKey": "approvalDate",
              "type": "date",
              "span": 6
            }
          ]
        },
        {
          "fields": [
            {
              "id": "comments",
              "label": "Approver Comments",
              "dataKey": "comments",
              "type": "textarea",
              "span": 12,
              "styles": {
                "containerClass": "field-container entity-bg-info entity-bg-opacity-10 entity-p-3 entity-rounded",
                "valueClass": "entity-mb-0 entity-fst-italic"
              }
            }
          ]
        }
      ]
    }
  ]
}