.franchise-roles-table th:first-child,
.franchise-roles-table td:first-child {
  width: 70%;
}

.franchise-roles-table th:nth-child(2),
.franchise-roles-table td:nth-child(2) {
  width: 23%;
}

.franchise-roles-table th:last-child,
.franchise-roles-table td:last-child {
  width: 7%;
}

.franchise-role-name {
  display: inline-block;
  margin-right: 8px;
}

.franchise-role-identity {
  align-items: center;
  display: flex;
  min-height: 34px;
}

.franchise-role-drag-handle {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 4px;
  color: #686864;
  cursor: grab;
  display: inline-flex;
  flex: 0 0 34px;
  height: 34px;
  justify-content: center;
  margin: -5px 6px -5px -8px;
  padding: 0;
  width: 34px;
}

.franchise-role-drag-handle:hover {
  background: #f1f1ed;
  color: #231f20;
}

.franchise-role-drag-handle:active {
  cursor: grabbing;
}

.franchise-role-drag-handle:focus-visible {
  outline: 3px solid #f5a706;
  outline-offset: 1px;
}

.franchise-role-drag-handle:disabled {
  cursor: wait;
  opacity: 0.45;
}

.franchise-role-drag-handle svg {
  height: 20px;
  width: 20px;
}

.franchise-roles-table tr.is-dragging {
  opacity: 0.45;
}

.franchise-roles-table tr.drop-before td {
  box-shadow: inset 0 3px 0 #f5a706;
}

.franchise-roles-table tr.drop-after td {
  box-shadow: inset 0 -3px 0 #f5a706;
}

.franchise-roles-table .icon-command svg {
  height: 18px;
  width: 18px;
}

.franchise-role-dialog {
  max-width: 760px;
}

.franchise-role-fields {
  max-width: 440px;
}

.franchise-role-permissions input:focus-visible,
.danger-command:focus-visible {
  outline: 3px solid #f5a706;
  outline-offset: 2px;
}

.franchise-role-permissions-wrap {
  border: 1px solid #d8d8d4;
  margin-top: 24px;
  max-height: min(420px, 48vh);
  overflow: auto;
}

.franchise-role-permissions {
  border-collapse: collapse;
  min-width: 650px;
  width: 100%;
}

.franchise-role-permissions th,
.franchise-role-permissions td {
  border-bottom: 1px solid #e3e3df;
  padding: 13px 16px;
}

.franchise-role-permissions thead th {
  background: #f7f7f4;
  color: #666660;
  font-size: 11px;
  font-weight: 800;
  position: sticky;
  text-transform: uppercase;
  top: 0;
  z-index: 1;
}

.franchise-role-permissions thead th:first-child,
.franchise-role-permissions tbody th {
  text-align: left;
  width: 48%;
}

.franchise-role-permissions thead th:not(:first-child),
.franchise-role-permissions td {
  text-align: center;
  width: 13%;
}

.franchise-role-permissions tbody th {
  font-size: 13px;
}

.franchise-role-permissions tbody tr:last-child th,
.franchise-role-permissions tbody tr:last-child td {
  border-bottom: 0;
}

.franchise-role-permissions input {
  accent-color: #231f20;
  height: 18px;
  margin: 0;
  width: 18px;
}

.franchise-role-permissions input:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.franchise-role-actions {
  align-items: center;
}

.franchise-role-action-spacer {
  flex: 1;
}

.danger-command {
  align-items: center;
  background: #ffffff;
  border: 1px solid #a52020;
  border-radius: 4px;
  color: #8b1818;
  cursor: pointer;
  display: inline-flex;
  font-size: 14px;
  font-weight: 800;
  justify-content: center;
  min-height: 42px;
  padding: 10px 16px;
}

.danger-command:hover {
  background: #fff0f0;
}

.danger-command:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

@media (max-width: 720px) {
  .franchise-roles-table td:first-child {
    grid-column: 1;
    grid-row: 1;
  }

  .franchise-roles-table td:nth-child(2) {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .franchise-roles-table td:last-child {
    grid-column: 2;
    grid-row: 1 / 3;
    place-self: center end;
  }

  .franchise-role-permissions-wrap {
    max-height: 42vh;
  }

  .franchise-role-actions {
    grid-template-columns: 1fr 1fr;
  }

  .franchise-role-actions .danger-command {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .franchise-role-action-spacer {
    display: none;
  }
}
