.roster-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 16px 12px 0;
  flex-wrap: wrap;

  &-text {
    h1 {
      margin: 0;
      font-size: 22px;
      font-weight: 700;
      color: #111827;

      em {
        font-style: italic;
        color: var(--action-primary-default, #834dd0);
        font-weight: 600;
      }
    }

    p {
      margin: 2px 0 0;
      font-size: 13px;
      color: #6b7280;
    }
  }
}

.roster-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px 18px;
  margin-bottom: 4px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.roster-grid-container {
  margin-top: 20px;
  overflow-x: auto;
}

.roster-grid {
  min-width: 920px;
}

.roster-grid-header,
.roster-row {
  display: grid;
  grid-template-columns: 190px 1fr 1fr 160px 130px 130px;
  align-items: center;
  gap: 16px;
}

.roster-grid-header {
  padding: 0 18px 10px;

  span {
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #94a3b8;
    font-weight: 600;
  }
}

.roster-grid-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.roster-row {
  background: #fff;
  border: 1px solid #edeef2;
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition: box-shadow 0.15s ease, border-color 0.15s ease;

  &:hover {
    border-color: #e2e4ea;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.07);
  }
}

.col-workstation {
  .ws-code {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #0f172a;
  }

  .ws-name {
    font-size: 12px;
    font-weight: 500;
    color: #64748b;
    margin-top: 2px;
  }
}

.assigned-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 10px;
  padding: 9px 12px;
}

.op-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}

.op-name {
  font-size: 13px;
  font-weight: 500;
  color: #1f2937;
  cursor: pointer;

  &:hover {
    text-decoration: underline;
  }
}

.btn-assign-link {
  color: var(--action-primary-default, #834dd0);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;

  &:hover {
    text-decoration: underline;
  }
}

.readonly-select,
.readonly-time {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 8px 10px;
  background: #fff;
  font-size: 13px;
  color: #374151;

  .field-icon {
    color: #9ca3af;
    flex-shrink: 0;
  }
}

.gap-warning {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 12px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13px;
  line-height: 1.5;

  .gap-warning-icon {
    flex-shrink: 0;
    margin-top: 1px;
    color: #d97706;
  }

  &:not(:last-child) {
    margin-bottom: 8px;
  }
}

.assign-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.assign-modal {
  background: #fff;
  border-radius: 10px;
  width: min(480px, 92vw);
  padding: 20px 24px 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.assign-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;

  h2 {
    font-size: 18px;
    margin: 0;
  }

  .assign-modal-close {
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
    color: #6b7280;

    &:hover {
      color: #111827;
    }
  }
}

.assign-modal-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.assign-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;

  button {
    border-radius: 6px;
    padding: 8px 18px;
    font-size: 14px;
    cursor: pointer;
  }

  .btn-cancel {
    background: #fff;
    border: 1px solid #d1d5db;
    color: #374151;
  }

  .btn-confirm {
    background: var(--button-primary-bg-default);
    border: 1px solid var(--button-primary-bg-default);
    color: var(--button-primary-text-default);
  }
}