.add_emp {
  margin: 18px 0 0;
}

.add_emp .add_ext_emp {
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--brand-color, #004f32);
  border-radius: 7px;
  background: var(--brand-color, #004f32);
  color: #fff;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
}

.add_emp .add_ext_emp:hover,
.add_emp .add_ext_emp:focus-visible {
  filter: brightness(1.12);
}

.add_emp .add_ext_emp:disabled {
  display: none;
}

#ext_employee {
  margin-top: 18px;
}

#ext_employee #repeater {
  display: none;
  padding: clamp(18px, 3vw, 28px);
  border: 1px solid #dfe4e1;
  border-radius: 12px;
  background: #f7f9f8;
  box-shadow: 0 8px 24px rgba(0, 48, 31, 0.06);
}

#ext_employee .clearfix:empty {
  display: none;
}

#ext_employee .items {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 0 0 20px;
  margin: 0 0 20px;
  border-bottom: 1px solid #dfe4e1;
}

#ext_employee .item-content {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(150px, 0.55fr);
  gap: 14px;
  align-items: end;
}

#ext_employee .wood-input-group label {
  display: block;
  margin: 0 0 6px;
  font-size: 14px;
  font-weight: 600;
}

#ext_employee .wood-input-group input,
#ext_employee .wood-input-group select {
  width: 100%;
  min-height: 48px;
  margin: 0;
  border: 1px solid #bdc8c2;
  border-radius: 6px;
  background: #fff;
}

#ext_employee .wood-input-group input:focus,
#ext_employee .wood-input-group select:focus {
  border-color: var(--brand-color, #004f32);
  outline: 2px solid color-mix(in srgb, var(--brand-color, #004f32) 20%, transparent);
  outline-offset: 1px;
}

#ext_employee .repeater-heading,
#ext_employee .wood-form-submit {
  display: inline-flex;
  align-items: center;
  margin: 0 8px 0 0;
  vertical-align: middle;
}

#ext_employee button,
#ext_employee input[type="submit"] {
  width: auto;
  min-height: 44px;
  margin: 0;
  padding: 10px 18px;
  border-radius: 7px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
}

#ext_employee .repeater-add-btn {
  border: 1px solid var(--brand-color, #004f32);
  background: transparent;
  color: var(--brand-color, #004f32);
}

#ext_employee .repeater-remove-btn button {
  border: 1px solid #c8d0cc;
  background: #fff;
  color: #7c2929;
}

#ext_employee .repeater-remove-btn button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

#ext_employee input[type="submit"] {
  border: 1px solid var(--brand-color, #004f32);
  background: var(--brand-color, #004f32);
  color: #fff;
}

#ext_employee .repeater-add-btn:hover,
#ext_employee .repeater-add-btn:focus-visible,
#ext_employee .repeater-remove-btn button:hover,
#ext_employee .repeater-remove-btn button:focus-visible,
#ext_employee input[type="submit"]:hover,
#ext_employee input[type="submit"]:focus-visible {
  filter: brightness(1.1);
}

#ext_employee .wood-resonse-notice {
  margin-top: 14px;
}

/* Shared actions for the coordinator's order and employee editor. */
.woocommerce .csc-button {
  display: inline-flex;
  box-sizing: border-box;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto;
  min-height: 44px;
  margin: 0;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 7px;
  box-shadow: none;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: normal;
  text-align: center;
  text-decoration: none;
  text-transform: none;
  cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease;
}

.woocommerce .csc-button--primary {
  border-color: var(--brand-color, #004f32);
  background: var(--brand-color, #004f32);
  color: var(--brand-text-color, #fff);
}

.woocommerce .csc-button--primary:hover {
  background: color-mix(in srgb, var(--brand-color, #004f32) 90%, #000);
  color: var(--brand-text-color, #fff);
}

.woocommerce .csc-button--secondary {
  border-color: #bdc8c2;
  background: #fff;
  color: var(--brand-color, #004f32);
}

.woocommerce .csc-button--secondary:hover {
  border-color: var(--brand-color, #004f32);
  background: #f3f6f4;
  color: var(--brand-color, #004f32);
}

.woocommerce .csc-button:focus-visible,
.woocommerce .csc-account-table-wrap:focus-visible,
.woocommerce .csc-resend-link:focus-visible {
  outline: 2px solid var(--brand-color, #004f32);
  outline-offset: 3px;
}

.woocommerce .csc-button--compact {
  min-height: 38px;
  padding: 8px 12px;
  font-size: 13px;
  white-space: nowrap;
}

/* Account tables stay readable without widening the page on small screens. */
.woocommerce .csc-account-table-wrap {
  max-width: 100%;
  margin: 0 0 24px;
  overflow-x: auto;
  border: 1px solid #dfe4e1;
  border-radius: 10px;
  background: #fff;
}

.woocommerce table.csc-employee-table,
.woocommerce .csc-order-details table.order_details {
  width: 100%;
  margin: 0;
  border: 0;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  font-size: 14px;
  line-height: 1.5;
}

.woocommerce table.csc-employee-table {
  min-width: 760px;
  table-layout: auto;
}

.woocommerce table.csc-employee-table th,
.woocommerce table.csc-employee-table td,
.woocommerce .csc-order-details table.order_details th,
.woocommerce .csc-order-details table.order_details td {
  padding: 16px;
  border: 0;
  border-bottom: 1px solid #e8ede9;
  text-align: left;
  vertical-align: middle;
}

.woocommerce table.csc-employee-table thead th,
.woocommerce .csc-order-details table.order_details thead th {
  background: #f3f6f4;
  color: #47594f;
  font-size: 13px;
  font-weight: 600;
}

.woocommerce table.csc-employee-table tbody tr:nth-child(even) {
  background: #fafbf9;
}

.woocommerce table.csc-employee-table tbody tr:hover {
  background: #f3f6f4;
}

.woocommerce table.csc-employee-table tbody tr:last-child td,
.woocommerce .csc-order-details table.order_details tfoot tr:last-child > * {
  border-bottom: 0;
}

.woocommerce .csc-employee-number {
  width: 32px;
  color: #6b786f;
  font-variant-numeric: tabular-nums;
}

.woocommerce .csc-employee-name {
  color: #263b2f;
  font-weight: 600;
}

.woocommerce .csc-employee-email {
  overflow-wrap: anywhere;
}

.woocommerce .csc-employee-price {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.woocommerce .csc-resend-link {
  display: block;
  width: fit-content;
  margin-top: 5px;
  font-size: 12px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.woocommerce .csc-employee-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 160px;
}

.woocommerce .csc-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.woocommerce .csc-status::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.woocommerce .csc-status--complete {
  background: #e9f4ec;
  color: #27633b;
}

.woocommerce .csc-status--pending {
  background: #fcf3df;
  color: #805e16;
}

.woocommerce .csc-order-details table.order_details {
  margin-bottom: 28px;
  overflow: hidden;
  border: 1px solid #dfe4e1;
  border-radius: 10px;
}

.woocommerce .csc-order-details table.order_details tfoot th {
  font-weight: 500;
}

.woocommerce .csc-order-details table.order_details tfoot tr:last-child {
  background: #f3f6f4;
  font-weight: 700;
}

/* This wrapper deliberately does not repeat WooCommerce's content column. */
.woocommerce .csc-employee-editor {
  box-sizing: border-box;
  width: 100%;
  padding: clamp(20px, 3vw, 32px);
  border: 1px solid #dfe4e1;
  border-radius: 12px;
  background: #fff;
}

.woocommerce .csc-employee-editor h2 {
  margin: 0 0 24px;
}

.woocommerce form.csc-employee-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  border: 0;
}

.woocommerce form.csc-employee-form .form-row {
  float: none;
  clear: none;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
}

.woocommerce form.csc-employee-form .form-row-wide,
.woocommerce .csc-password-change,
.woocommerce .csc-form-actions {
  grid-column: 1 / -1;
}

.woocommerce form.csc-employee-form label {
  display: block;
  margin: 0 0 7px;
  color: #34483c;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
}

.woocommerce form.csc-employee-form .input-text {
  box-sizing: border-box;
  width: 100%;
  height: auto;
  min-height: 48px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #bdc8c2;
  border-radius: 6px;
  background: #fff;
  box-shadow: none;
  color: #263b2f;
  font: inherit;
  line-height: 1.5;
}

.woocommerce form.csc-employee-form .input-text:focus {
  border-color: var(--brand-color, #004f32);
  outline: 2px solid color-mix(in srgb, var(--brand-color, #004f32) 20%, transparent);
  outline-offset: 1px;
}

.woocommerce .csc-password-change > summary {
  width: fit-content;
  list-style: none;
}

.woocommerce .csc-password-change > summary::-webkit-details-marker {
  display: none;
}

.woocommerce .csc-password-change > summary::after {
  content: "+";
}

.woocommerce .csc-password-change[open] > summary::after {
  content: "\2212";
}

.woocommerce .csc-password-change[open] .reset_password_wrap {
  margin-top: 18px;
}

.woocommerce .csc-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 20px;
  border-top: 1px solid #e8ede9;
}

.woocommerce .csc-employee-notice {
  margin-bottom: 24px;
  padding: 12px 16px;
  border-left: 3px solid var(--brand-color, #004f32);
  border-radius: 4px;
  background: #f3f6f4;
  color: #263b2f;
}

@media (max-width: 600px) {
  .woocommerce form.csc-employee-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .woocommerce .csc-form-actions .csc-button {
    width: 100%;
  }
}

@media (max-width: 780px) {
  #ext_employee .items,
  #ext_employee .item-content {
    display: grid;
    grid-template-columns: 1fr;
  }

  #ext_employee .repeater-remove-btn {
    justify-self: start;
  }
}
