<?xml version="1.0" encoding="UTF-8"?>

<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.ComboBox?>
<?import javafx.scene.control.Label?>
<?import javafx.scene.control.PasswordField?>
<?import javafx.scene.control.TextField?>
<?import javafx.scene.layout.HBox?>
<?import javafx.scene.layout.Region?>
<?import javafx.scene.layout.VBox?>
<?import javafx.scene.text.Font?>

<VBox prefWidth="480.0" spacing="14.0" xmlns="http://javafx.com/javafx/25" xmlns:fx="http://javafx.com/fxml/1" fx:controller="org.example.petshopdesktop.controllers.dialogcontrollers.StaffRegisterDialogController">
   <padding>
      <Insets bottom="18.0" left="18.0" right="18.0" top="18.0" />
   </padding>
   <children>
      <Label text="Create Staff Account" textFill="#2C3E50">
         <font>
            <Font name="System Bold" size="18.0" />
         </font>
      </Label>

      <Label fx:id="lblError" text="" textFill="#FF6B6B" wrapText="true" />

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="First Name" />
                  <TextField fx:id="txtFirstName" promptText="First name" />
               </children>
            </VBox>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Last Name" />
                  <TextField fx:id="txtLastName" promptText="Last name" />
               </children>
            </VBox>
         </children>
      </HBox>

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Email" />
                  <TextField fx:id="txtEmail" promptText="name@petshop.com" />
               </children>
            </VBox>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Phone" />
                  <TextField fx:id="txtPhone" promptText="123-456-7890" />
               </children>
            </VBox>
         </children>
      </HBox>

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Username" />
                  <TextField fx:id="txtUsername" promptText="username" />
               </children>
            </VBox>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Password" />
                  <PasswordField fx:id="txtPassword" promptText="password" />
               </children>
            </VBox>
         </children>
      </HBox>

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Confirm Password" />
                  <PasswordField fx:id="txtPasswordConfirm" promptText="confirm password" />
               </children>
            </VBox>
            <Region HBox.hgrow="ALWAYS" />
         </children>
      </HBox>

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Role" />
                  <ComboBox fx:id="cbRole" maxWidth="1.7976931348623157E308" promptText="Select Role" />
               </children>
            </VBox>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Staff Role" />
                  <ComboBox fx:id="cbStaffRole" maxWidth="1.7976931348623157E308" promptText="Select Staff Role" />
               </children>
            </VBox>
         </children>
      </HBox>

      <HBox spacing="10.0">
         <children>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Status" />
                  <ComboBox fx:id="cbActive" maxWidth="1.7976931348623157E308" promptText="Select Status" />
               </children>
            </VBox>
            <VBox spacing="6.0" HBox.hgrow="ALWAYS">
               <children>
                  <Label text="Primary Store" />
                  <ComboBox fx:id="cbStore" maxWidth="1.7976931348623157E308" promptText="Select Store" />
               </children>
            </VBox>
         </children>
      </HBox>

      <HBox alignment="CENTER_RIGHT" spacing="10.0">
         <children>
            <Button mnemonicParsing="false" onAction="#btnCancelClicked" text="Cancel" />
            <Button fx:id="btnCreate" mnemonicParsing="false" onAction="#btnCreateClicked" style="-fx-background-color: #4ECDC4; -fx-text-fill: white; -fx-cursor: hand;" text="Create" />
         </children>
      </HBox>
   </children>
</VBox>
